The <Dialog> Element

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

CodeRabbit: AI Code Reviews for Developers
Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.
coderabbit.ai
featured
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com
featured
  • dialog-polyfill

    Polyfill for the HTML dialog element

    > - Z-index has no effect in the top-layer. No need to compete for a higher z-index.

    This is the kind of boring feature that can end up saving huge amounts of developer time. Z-indexing in CSS is kind of annoying and I've seen projects just detach dialogs from their normal position in the DOM entirely to get around stacking errors before.

    ----

    Minor question:

    > - There is only one `top-layer` but it can have many children. Last opened === current element on top.

    Is this true? The spec says:

    > The top layer is an ordered set of elements, rendered in the order they appear in the set. The last element in the set is rendered last, and thus appears on top.

    I'm still playing around with `dialog` elements, so you may well be right, I'm just having trouble finding the actual spec rules about what happens when there are multiple dialogs and they're being simultaneously manipulated.

    ----

    > - Not supported in Safari <= 15.3

    Worth noting that there is a polyfill (https://github.com/GoogleChrome/dialog-polyfill), but that the polyfill comes with some fairly large limitations, specifically that they don't advise dialogs be used as children of elements with their own stacking context.

    This is reasonable, but also... my first thought when I originally ran into `dialog` was "finally I can stop worrying about which of my elements create new stacking contexts!" -- so it does decrease the usefulness quite a bit.

  • CodeRabbit

    CodeRabbit: AI Code Reviews for Developers. Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.

    CodeRabbit logo
  • WHATWG HTML Standard

    HTML Standard

    Here's a long conversation on it from 2016: https://github.com/whatwg/html/issues/1929

    It has something to do with interfering with automatic focus on the dialog when it pops up as a modal.

  • kill-sticky

    Bookmarklet to remove sticky elements and restore scrolling to web pages!

    In the meantime, NoScript[1] frequently avoids them entirely by just showing the page contents with no JS at all, and Kill Sticky[2] cleans up the ones that require JS to show you the content you actually want.

    [1] NoScript for Firefox & Chrome-based browsers: https://noscript.net/getit/

    [2] Kill Sticky bookmarklet for all browsers including mobile: https://github.com/t-mart/kill-sticky

    Or, a Firefox extension that adds a toolbar button: https://addons.mozilla.org/en-US/firefox/addon/kill-sticky/

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • Platform Strategy and Its Discontents: The web is losing. A comeback is possible

    2 projects | news.ycombinator.com | 29 Oct 2024
  • How should the new <selectedoption> element work?

    2 projects | news.ycombinator.com | 22 Oct 2024
  • How to learn HTML: 46 great sites, courses and books (all free)

    3 projects | dev.to | 29 Sep 2024
  • SVG Triangle of Compromise

    2 projects | news.ycombinator.com | 29 Jul 2024
  • The importance of reading and writing valid HTML

    2 projects | dev.to | 20 Jul 2024

Did you konow that JavaScript is
the 3rd most popular programming language
based on number of metions?