mirror of https://github.com/sveltejs/svelte
fix: `:global()` compound selector validation tweak (#10287)
Allow type selector in `:global()` when it's at a start of a compound selector fixes #10286pull/10291/head
parent
340934917a
commit
c8da99646a
@ -0,0 +1,5 @@
|
|||||||
|
---
|
||||||
|
"svelte": patch
|
||||||
|
---
|
||||||
|
|
||||||
|
fix: allow type selector in `:global()` when it's at a start of a compound selector
|
@ -0,0 +1,14 @@
|
|||||||
|
[
|
||||||
|
{
|
||||||
|
"code": "invalid-css-global-selector-list",
|
||||||
|
"message": ":global(...) must not contain type or universal selectors when used in a compound selector",
|
||||||
|
"start": {
|
||||||
|
"line": 5,
|
||||||
|
"column": 5
|
||||||
|
},
|
||||||
|
"end": {
|
||||||
|
"line": 5,
|
||||||
|
"column": 17
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
@ -0,0 +1,8 @@
|
|||||||
|
<style>
|
||||||
|
:global(div):first-child {
|
||||||
|
color: red;
|
||||||
|
}
|
||||||
|
.foo:global(div):first-child {
|
||||||
|
color: red;
|
||||||
|
}
|
||||||
|
</style>
|
Loading…
Reference in new issue