W3C home > Mailing lists > Public > public-css-archive@w3.org > March 2020

Re: [csswg-drafts] [dialog element] <dialog> positioning should be describable in CSS (#4645)

From: fantasai via GitHub <sysbot+gh@w3.org>
Date: Sat, 07 Mar 2020 00:56:53 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-596024077-1583542612-sysbot+gh@w3.org>
Details on the proposal:
* The dialog is assigned to the "top layer" (which needs to be defined in css-position-3 once it's rewritten).
* DOM snapshots the top/bottom of the viewport as inset property values when the dialog is opened, and rewrites those values if the viewport is resized.
* The dialog is also assigned `align-self: safe center`; this takes care of the centering within the viewport.

I think the one question I can think of wrt CSS interaction is where the `inset` values are injected, if it's at the preshint level or into the style attribute or something else. Depends on what's reasonably implementable and what's reasonably Web-compatible...

@keithjgrant Together with selecting on [open], I think this should allow for animations and transitions of most aspects of dialog layout.

@annevk Does that make sense, or do you need more info for the HTML spec parts of this?

GitHub Notification of comment by fantasai
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/4645#issuecomment-596024077 using your GitHub account
Received on Saturday, 7 March 2020 00:56:55 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:42:02 UTC