remove stylesheet property from state (#14429)

pull/14430/head
Rich Harris 1 month ago committed by GitHub
parent 2b5c0e791e
commit d2ce0a79ae
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -7,7 +7,6 @@ import { get_attribute_chunks, is_text_attribute } from '../../../utils/ast.js';
/** /**
* @typedef {{ * @typedef {{
* stylesheet: Compiler.Css.StyleSheet;
* element: Compiler.AST.RegularElement | Compiler.AST.SvelteElement; * element: Compiler.AST.RegularElement | Compiler.AST.SvelteElement;
* from_render_tag: boolean; * from_render_tag: boolean;
* }} State * }} State
@ -61,9 +60,9 @@ export function prune(stylesheet, element) {
const parent = get_element_parent(element); const parent = get_element_parent(element);
if (!parent) return; if (!parent) return;
walk(stylesheet, { stylesheet, element: parent, from_render_tag: true }, visitors); walk(stylesheet, { element: parent, from_render_tag: true }, visitors);
} else { } else {
walk(stylesheet, { stylesheet, element, from_render_tag: false }, visitors); walk(stylesheet, { element, from_render_tag: false }, visitors);
} }
} }

Loading…
Cancel
Save