0
0
mirror of https://github.com/sveltejs/svelte.git synced 2024-11-29 00:22:05 +01:00

Merge branch 'gh-3135' of https://github.com/btk5h/svelte into btk5h-gh-3135

This commit is contained in:
Rich Harris 2019-07-01 12:53:21 -04:00
commit bff7dace5b
3 changed files with 20 additions and 1 deletions

View File

@ -315,7 +315,14 @@ export default class Stylesheet {
leave: (node: Node) => {
if (node.type === 'Rule' || node.type === 'Atrule') stack.pop();
if (node.type === 'Atrule') current_atrule = stack[stack.length - 1] as Atrule;
if (node.type === 'Atrule') {
current_atrule = null;
for (let i = stack.length - 1; i >= 0; i--) {
if (stack[i] instanceof Atrule) {
current_atrule = stack[i] as Atrule;
}
}
}
}
});
} else {

View File

@ -0,0 +1 @@
div.svelte-xyz{@apply --funky-div;}

View File

@ -0,0 +1,11 @@
<div></div>
<style>
div {
@apply --funky-div;
}
div {
}
</style>