Skip to content

[css-transitions-2] Should @starting-style add a teensy bit of specifity? #11263

Open
@tabatkins

Description

@tabatkins

See https://youtu.be/DNXEORSk4GU?si=FaHmoCzBpQPF9eeS&t=1161 for context. In this video, the dev explains that they used to put @starting-style at the top of their rule, which felt more natural, but now that we've changed how Nesting works, that no longer works - the plain declarations are no longer shifted above the nested rules, so the @starting-style styles lose due to order-of-appearance. Instead, you have to put @starting-style below your other declarations.

This feels like a frustrating footgun. Would it make sense to have @starting-style introduce a new, lowest bit of specificity, so it'll win over plain declarations in the same parent rule regardless of the order it appears in?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions