Re: [csswg-drafts] [css-display] Interaction gotchas when delaying the effect of `display: none` (#8389)

Re `inert`: for reference, it was last discussed in issue #7021, and the reasons it was not implemented in CSS were:
* Need more experience with the `inert` attribute's use cases
* The semantics would be atypical as they relate to inheritance and no ability to override an ancestor.

However, the discussion in the issue indicated it wouldn't be very hard for the existing browser engines to add a CSS version (and in fact they use cascade / CSS infrastructure under the hood to implement the attribute already).

> > During the transition above, inert could behave as yes.
> 
> Is there a way to express this with a user-agent style or something?

I'm not sure there is a simple way to express this. If there is, it would be nice to help authors avoid exit animation bugs.

> > If the developer wants the element to be interactive during the transition, they can override this default:
> 
> If this isn't an important use case, then could we just make dialogs and popovers inert while transitioning to display:none without adding a new CSS property for inert?

One option could be to make all top layer elements inert during a transition in or out of the top layer (and spec it along with the proposed top-layer property, see #8189). And then add `inert` to allow developers to opt into inert during other animations.


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


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

Received on Tuesday, 7 February 2023 00:07:07 UTC