From fafca0895021f95310e19b72eff91ba0bb08b3f4 Mon Sep 17 00:00:00 2001 From: pmurray73 Date: Sun, 24 Jan 2021 10:29:23 -0500 Subject: [PATCH] obviously incorrect hard-coded color --- .../compile/render_dom/wrappers/Element/index.ts | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/src/compiler/compile/render_dom/wrappers/Element/index.ts b/src/compiler/compile/render_dom/wrappers/Element/index.ts index 2d1d362f09..69adaa1823 100644 --- a/src/compiler/compile/render_dom/wrappers/Element/index.ts +++ b/src/compiler/compile/render_dom/wrappers/Element/index.ts @@ -911,20 +911,14 @@ export default class ElementWrapper extends Wrapper { this.node.styles.forEach(style_directive => { // @FIXME: + // I'm not sure how to set the right value expression here // Hmm, I thought this would work: // const { name, expression: { node: expression } } = style_directive; // const updater = b`@set_style(${this.var}, "${name}", ${expression}, false)`; + - // But that results in this, and `myColor` is undefined: - - /* - c() { - p$ = element$("p"); - set_style$(p$, "color", myColor, false); - }, - */ - + // @FIXME: This is obviously wrong, hardcoding the color const { name } = style_directive; const updater = b`@set_style(${this.var}, "${name}", "red", false)`;