-
Notifications
You must be signed in to change notification settings - Fork 75
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
Allow list-item action slots to have an independent disabled state form the list-item #5664
Comments
@jcfranco @benelan @eriklharper What are your thoughts about how disabling could work here?
Other ideas? |
@geospatialem any a11y concerns with a disabled component having non-disabled child(ren)? |
@benelan This sounds like a very solid use case. From the a11y perspective, its not a known or expected pattern, so would need to consult with a few other a11y professionals to determine the best path forward on the enhancement. Can report back here in a few weeks once a few of us can convene together. |
Yeah if we disable the component it will get |
Disabled is not a valid attribute on the This will allow you to disabled the control but allow the tooltips and other icon buttons to still be accessible. |
@driskull @geospatialem Please refer to Nat's response above. |
@nattarnoff I'm not following your comment. I don't see a |
Since the "content" button is internal to the component and not slotted, we would need to be able to disable via a prop or something like that if we want to support this without breaking changes. |
@driskull as the |
Its also a custom element, so we can put As for the
|
@driskull I went through the Codepen at the top of the description. The problem with how it is written now is that the second icon in the first From the first description paragraph of the linked MDN article (emphasis mine):
Aria-disabled cascades. Once set, the children cannot be unset. Putting these attributes on the container and not the controls causes problems. I've put together a sample using a basic UL to demonstrate: https://codepen.io/nattarnoff/pen/dyeVgdV?editors=1111 You still need to move the attributes from the parent (rendered |
Yes, it's working as designed right now. If a component is disabled, all things inside it are disabled as well. I think we would need to engineer a way to disable only specific parts of the component. If we need to rethink how this is engineered, we can do that.
I think it's up to the user to disable anything they slot into the component. Since they can slot custom components like |
The Field Maps web app is looking to use the list component for listing and selecting layers. In some cases a layer is not selectable, but we still want to be able to perform actions on it (e.g. "Delete"), or show accessible error iconography w/ tooltips. |
@ethanbdev, @nwhittaker Could you provide info on priority/impact for this? |
This issue is one of several that are blocking an effort in Field Maps Designer to refactor the list of layers and group-layers as a
Our current implementation is a combination of custom components and For prioritization, our refactoring issue is beginning to block other issues (that would like to make use of the |
For web analysis, its blocking a design to communicate licensing information to users. I would put p3 - want for upcoming milestone if @nwhittaker agrees or wants to put it higher |
Thanks all for the great discussions and insights to use cases. Calcite is proceeding with the above request on |
**Related Issue:** #5664 ## Summary - add `unavailable` property to `list-item`. - add e2e test - add entry in story - update demo
Installed and assigned for verification. |
Description
The use case is that a list item (GP tool) is disabled, but we want to show an information icon that the user can interact with either on hover / click to give help to the user on why this item (GP tool) is disabled. This would occur when the licensing is not sufficient to use the tool and we need to direct them to information on getting the license / seeing more information about the licensing level.
Right now, the actions inherit the disabled state from the list-item, so there is no way to provide user interaction on those actions.
Blocked issues: #8373
Acceptance Criteria
The scope of the issue would be the list-item respecting the
disabled
attribute on itself and any slotted actions independently.Relevant Info
Which Component
calcite-list-item
Example Use Case
https://codepen.io/eborgen/pen/WNyvagJ
Esri team
ArcGIS Map Viewer
The text was updated successfully, but these errors were encountered: