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

Fix addLabels having no effect for progressBar #473

Merged

Conversation

Cube707
Copy link
Contributor

@Cube707 Cube707 commented Nov 28, 2024

I implemented the fix, but am unsure if all three lables should be hidden or if the center one should be left

closes #472

@Cube707 Cube707 changed the title Fix addLabelshavving no effect for progressBar Fix addLabels having no effect for progressBar Nov 28, 2024
@mProjectsCode
Copy link
Owner

Not sure. I would say no, as otherwise there is no way of knowing what the value of the progress bar is when the labels are hidden.

@Cube707
Copy link
Contributor Author

Cube707 commented Nov 29, 2024

Not sure. I would say no, as otherwise there is no way of knowing what the value of the progress bar is when the labels are hidden

I was thinking, that maybe one explicitly only want the visual feedback while handling the numeric values separately via a textbox?

The slider also has only the visual feedback with labels of, so it might be more consistent?

@Cube707
Copy link
Contributor Author

Cube707 commented Nov 29, 2024

for reference, this is what I currently work on (here I hid the labels via CSS)
image

@mProjectsCode
Copy link
Owner

Fair. I think no labels at all are fine.

@mProjectsCode
Copy link
Owner

mProjectsCode commented Dec 7, 2024

Maybe a tooltip on hover is a good idea though. This can simply be done by setting an aria-label on the progress bar.

@Cube707 Cube707 force-pushed the fix/addlabels-progressbar branch from 287cb34 to a7c2487 Compare December 8, 2024 19:41
@@ -125,9 +125,12 @@
aria-valuemin={props.minValue}
aria-valuemax={props.maxValue}
aria-valuenow={value}
aria-label={value}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I experimented a bit with with switching to aria-labeledby in case the labels are shown, but could get it to work. also this required a unique ID on the mb-progress-bar-value which adds unnecessary overhead

@Cube707 Cube707 marked this pull request as ready for review December 8, 2024 19:44
@mProjectsCode mProjectsCode merged commit 3f2057e into mProjectsCode:master Dec 8, 2024
@mProjectsCode
Copy link
Owner

thanks

@Cube707 Cube707 deleted the fix/addlabels-progressbar branch December 8, 2024 20:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

addLabels is ignored by the ProgressBar
2 participants