Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The progress 0 is shown above a progress bar with labelProgress is false #696

Closed
longntx opened this issue Apr 11, 2023 · 0 comments · Fixed by #698
Closed

The progress 0 is shown above a progress bar with labelProgress is false #696

longntx opened this issue Apr 11, 2023 · 0 comments · Fixed by #698

Comments

@longntx
Copy link

longntx commented Apr 11, 2023

Describe the bug
With settings:

progress: 0,
labelText: false
labelProgress: false

The progress 0 is shown above a progress bar.

To Reproduce
Steps to reproduce the behavior:

  1. Clone source code.
  2. On branch main, run yarn run start:storybook
  3. Select Progress, set property progress to 0
  4. See error

Expected behavior
The 0 won't be shown if labelProgress is false

Screenshots
Flowbite_react_progress_bug

System information:

  • Device: MacBook pro 13, M1, 2020
  • Resolution: 2560 × 1600
  • OS: Mac OS Ventura 13.3.1
  • Browser: Brave
  • Version: Version 1.50.114 Chromium: 112.0.5615.49 (Official Build) (arm64)

Project information:

  • Tailwind: 3.0.0
  • Flowbite: 1.4.7
  • Flowbite React: 0.1.2
  • Type: CRA

Additional context
Add any other context about the problem here.

SrivatsaRUpadhya added a commit to SrivatsaRUpadhya/flowbite-react that referenced this issue Apr 13, 2023
… at progress value is 0

The conditional rendring using the '&&' would return 0 on condition being false which would get
displayed when progress value is 0. This was fixed using ternary operator instead. And also the
label would get hidden at low progress values which is now fixed.

fix themesberg#696
rluders pushed a commit to SrivatsaRUpadhya/flowbite-react that referenced this issue Apr 17, 2023
… at progress value is 0

The conditional rendring using the '&&' would return 0 on condition being false which would get
displayed when progress value is 0. This was fixed using ternary operator instead. And also the
label would get hidden at low progress values which is now fixed.

fix themesberg#696
rluders added a commit that referenced this issue Apr 17, 2023
…ss == 0 (#698)

* fix: group list styling (#668)

* fix: group list styling

* fix: borders between list group items

---------

Co-authored-by: Mees van Dongen <[email protected]>
Co-authored-by: Ricardo Lüders <[email protected]>

* fix(progress.tsx): progress bar shows labels even when it is disabled at progress value is 0

The conditional rendring using the '&&' would return 0 on condition being false which would get
displayed when progress value is 0. This was fixed using ternary operator instead. And also the
label would get hidden at low progress values which is now fixed.

fix #696

* style(default.ts): changed progress bar label(inside label) color for light mode

* fix(components/progressbar): fix progressbar showing label when progress == 0

---------

Co-authored-by: Mees van Dongen <[email protected]>
Co-authored-by: Ricardo Lüders <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant