I've created the following scss definition:
.regionBackgroundHighlighter
{
.highlight
{
fill:#CCCCCC;
opacity:0.5;
stroke:black;
stroke-width:0;
display:inline;
visibility:visible;
}
}I'm trying to set this css class to an element as follows but the style isn't getting applied:
d3.select(regionBackground).classed('regionBackgroundHighlighter highlight', true);In Chrome Dev Tools, regionBackground shows both regionBackgroundHighlighter and highlight in its classList[] but the actual style isn't getting applied to the element. However if I pass the same class definition as one-level un-nested class then the style gets applied as expected:
.regionBackgroundHighlight
{
fill:#CCCCCC;
opacity:0.5;
stroke:black;
stroke-width:0;
display:inline;
visibility:visible;
}
d3.select(regionBackground).classed('regionBackgroundHighlight', true);Do I need to use the d3 classed() function differently for the type of css structure I have defined in my first example above?
blah...blah..blah.classed('regionBackgroundHighlight', true).classed('highlight', true)
--
You received this message because you are subscribed to the Google Groups "d3-js" group.
To unsubscribe from this group and stop receiving emails from it, send an email to d3-js+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.