-
Notifications
You must be signed in to change notification settings - Fork 3
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
Custom delegation attributes #5
Comments
I'll mention this when syncing back with the AOM group. My understanding is for the delegates* options to remain as booleans, based on delegatesFocus, and probably the consecutive delegatesLabel. There is much we can optimize here on how we use but I need to understand what the implementation constraints are to keep the working path. |
Add reference to OpenUICG Popup API
What's the use case here? As author of the custom element how are you using that Could you provide an example? |
Sure, consider shoelaces' input, which uses the label attribute to label the control in the shadow root |
In that case the web component itself is dealing with Wouldn't the web component just set That custom attribute is defined by the web component author, so I don't see why we need some kind of magic outside the web component like |
I have a working use case of Demo: https://clshortfuse.github.io/materialdesignweb/components/textinput.html
Placeholder is sometimes used as a label fallback, but that's not always proper. The placeholder is more a hint than a label. For example, my search box should probably be scripted as this: <mdw-input type=search aria-label=Search placeholder="cat pictures" icon=search> Visually, users can infer search based on the icon and its location. But for screen-readers, they need the aria-label. In interest of thoroughness, here's what with a |
I tend to agree with @mrego that I don't really see how this use case aligns with cross-root aria delegation/reflection. The main issue here is that there is no actual crossing of ARIA roots – a So e.g. for this example: this.attachShadow({ mode: 'open', delegatesAriaLabel: 'label' }) There's no need for something like connectedCallback() {
this.shadowRoot.querySelector('input').ariaLabel = this.label
} Is there a specific ask for the cross-root ARIA API? And how would it be an improvement over the above manual assignment of |
Closing per discussion in cross-root ARIA F2F breakout, @bennypowers considers this issue covered by other proposals/issues. |
From the explainer:
Consider if the author of x-foo already implements a
label
attribute.and they would like to use that value as the aria-label.
What about this api (imperative)
or declarative (assuming #3)
The text was updated successfully, but these errors were encountered: