-
Notifications
You must be signed in to change notification settings - Fork 120
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
Ability to disable toggle visiblity behavior on legend items. #1055
Comments
Thank you @hbharding I think we can go with:
The consistency issue created with that change is neglectable and is replaced by a better UX |
# [29.2.0](v29.1.0...v29.2.0) (2021-05-25) ### Bug Fixes * **legend:** disable handleLabelClick for one legend item ([#1134](#1134)) ([a7242af](a7242af)), closes [#1055](#1055) ### Features * **a11y:** add alt text for all chart types ([#1118](#1118)) ([9e42229](9e42229)), closes [#1107](#1107) * **legend:** specify number of columns on floating legend ([#1159](#1159)) ([c2e4652](c2e4652)), closes [#1158](#1158) * simple screenspace constraint solver ([#1141](#1141)) ([eb11480](eb11480))
🎉 This issue has been resolved in version 29.2.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
# [29.2.0](elastic/elastic-charts@v29.1.0...v29.2.0) (2021-05-25) ### Bug Fixes * **legend:** disable handleLabelClick for one legend item ([opensearch-project#1134](elastic/elastic-charts#1134)) ([e485174](elastic/elastic-charts@e485174)), closes [opensearch-project#1055](elastic/elastic-charts#1055) ### Features * **a11y:** add alt text for all chart types ([opensearch-project#1118](elastic/elastic-charts#1118)) ([e1c7489](elastic/elastic-charts@e1c7489)), closes [opensearch-project#1107](elastic/elastic-charts#1107) * **legend:** specify number of columns on floating legend ([opensearch-project#1159](elastic/elastic-charts#1159)) ([ed3736e](elastic/elastic-charts@ed3736e)), closes [opensearch-project#1158](elastic/elastic-charts#1158) * simple screenspace constraint solver ([opensearch-project#1141](elastic/elastic-charts#1141)) ([af9dd96](elastic/elastic-charts@af9dd96))
Is your feature request related to a problem? Please describe.
We have charts in Observability that only ever plot 1 or 2 pieces of information. Users are able to click on a legend item to toggle the visibility of data. While this feature is useful when there are many pieces of data being shown (it allows the user to focus), it doesn't seem like it provides any value when the chart only has a single legend item.
Describe the solution you'd like
A way for developers to disable the toggle capability when it's not desired.
Describe alternatives you've considered
Consistency / expected behavior might be a concern. Some charts would allow toggling visibility (current default behavior), whereas other may not. How would a user know when this toggle behavior is available?
A simple solution could be to just remove this capability when there is only a single legend item. This behavior could apply to all chart types. If more than 1 legend item exists, then the toggle visibility feature would become available.
Additional context
See screenshots
Checklist
Delete any items that are not applicable to this feature request.
The text was updated successfully, but these errors were encountered: