Modernize bgcolor
@vibraphone why the css contains style/classes for other components? Why d3 in that component?
model.container.querySelector('.bg-color-container').style.backgroundColor = model.color;
What was the API change that you wanted? ;-)
@jourdain d3 is in there because I'm comfy with it. I will clean up the CSS. The API change I really wanted was what's mentioned in the commit: adopting the newInstance(publicAPI, model) API instead of just providing a constructor that takes an element and a color. I presume that part is OK?
@vibraphone why the css contains style/classes for other components? Why d3 in that component?
model.container.querySelector('.bg-color-container').style.backgroundColor = model.color;
What was the API change that you wanted? ;-)
@jourdain d3 is in there because I'm comfy with it. I will clean up the CSS. The API change I really wanted was what's mentioned in the commit: adopting the newInstance(publicAPI, model) API instead of just providing a constructor that takes an element and a color. I presume that part is OK?
@jourdain I've removed d3 and cleaned up the CSS.
LGTM otherwise
@jourdain @aronhelser Thanks for the feedback.
Thinking about it, you should have a destroy() method that call setContainer(null) and call the "parent" destroy. You might be able to handle it by pushing a callback that does that in model.subscritions... ;-) It is kind of sneaky but that will make a more complete example. If you want we can talk about it on a hangout so I can explain what I mean.