react-scoped-css icon indicating copy to clipboard operation
react-scoped-css copied to clipboard

Scoping doesn't work with css @container queries

Open Wiktor102 opened this issue 1 year ago • 1 comments

The data attributes aren't added to CSS selectors inside an @container query. This effectively disables scoping for all styles applied within an @container rule. Take the following example: image The above code only works because of the !important keyword.

Wiktor102 avatar Jun 25 '24 20:06 Wiktor102

This shortcoming causes specificity issues: the attribute selector has an additional (0, 1, 0) specificity. Refer to this example: image

Wiktor102 avatar Jun 26 '24 06:06 Wiktor102