Re: [csswg-drafts] [css-ui] Support setting offscreen content inert (#10711)

is `visibility: inert` a possibility?   does this need to be its own property?  just curious.  visibility: hidden already completely removes content from the a11y tree. but often inert content doesn't need to be 100% hidden (though per the guidance I helped at to the HTML spec, we would generally want some visual indicator that the content is not currently meant to be accessible).  So a default UA style of some lower level opacity/transparency would probably be good (and then allow authors to override this as needed ).

i'd be warry of doing anything with `opacity: 0` and inertness.  i know there's plenty of instances of opacity: 0 in the wild which are being used for visually hidden content that is not meant to be hidden to AT.  Making that content inert would likely break a lot of websites.

also agree with aaron that generally i think applying inertness with CSS could be handy. it'd make some UI a lot easier to build due to the lack of `inert=false` with the HTML attribute.

the only worry i have with that is inadvertently making content not inert when it really should have been.  e.g., marking an element as not inert with CSS which makes sense for that component/in the normal document flow - but then a user invokes a modal dialog.  Does that content become inert, stay not inert?   Maybe if a modal dialog exists in the top layer, any document-level not-inert content becomes inert.  But if someone needed a modal dialog AND a notification popover, well that popover is in the top layer now, and if it was marked as being not-inert, then could help solve stuff like https://github.com/whatwg/html/issues/9936

-- 
GitHub Notification of comment by scottaohara
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/10711#issuecomment-2310950905 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Monday, 26 August 2024 19:44:08 UTC