style-directives: push styles in to styles array on Element

pull/5923/head
pmurray73 6 years ago committed by Tan Li Hau
parent 6c3718dcf6
commit b2a9e67b0f

@ -7,6 +7,7 @@ import Transition from './Transition';
import Animation from './Animation';
import Action from './Action';
import Class from './Class';
import Style from './Style';
import Text from './Text';
import { namespaces } from '../../utils/namespaces';
import map_children from './shared/map_children';
@ -121,6 +122,7 @@ export default class Element extends Node {
actions: Action[] = [];
bindings: Binding[] = [];
classes: Class[] = [];
styles: Style[] = [];
handlers: EventHandler[] = [];
lets: Let[] = [];
intro?: Transition = null;
@ -203,6 +205,11 @@ export default class Element extends Node {
this.classes.push(new Class(component, this, scope, node));
break;
// @paul
case 'Style':
this.styles.push(new Style(component, this, scope, node));
break;
case 'EventHandler':
this.handlers.push(new EventHandler(component, this, scope, node));
break;

Loading…
Cancel
Save