hrbrmstr / taucharts

:bar_chart: An R htmlwidget interface to the TauCharts javascript library
http://rpubs.com/hrbrmstr/taucharts
Other
65 stars 10 forks source link

Custom color palettes not working with legend #24

Closed hrbrmstr closed 9 years ago

hrbrmstr commented 9 years ago
tauchart(mtcars) %>%
  tau_point("wt", "mpg", color="cyl") %>%
  tau_color_tableau() %>% 
  tau_legend()

image

When I use Developer Tools to inspect it, it looks like the color should be being applied, but it's not showing up.

timelyportfolio commented 9 years ago

Looks like just needs some extra CSS to color the div used in the legend. div does not use fill like SVG elements. I'll submit pull in just a bit after a little more testing.

hrbrmstr commented 9 years ago

thx. I thought it might be something like that. I also need to file an issue regarding widget size since I cld not really duplicate the example on the taucharts home page at all sizing-wise.

On Wed, Aug 5, 2015 at 9:56 PM, timelyportfolio notifications@github.com wrote:

Looks like just needs some extra CSS to color the div used in the legend. div does not use fill like SVG elements. I'll submit pull in just a bit after a little more testing.

— Reply to this email directly or view it on GitHub https://github.com/hrbrmstr/taucharts/issues/24#issuecomment-128208889.

timelyportfolio commented 9 years ago

Ok, want me to pull master?

hrbrmstr commented 9 years ago

actually, i just sync'd dev with master (including your cleanup PR) so we can work off of that for a while

timelyportfolio commented 9 years ago

Dang, this is going to be trickier than I thought, and might be best handled in the legend plugin. Can get color, but then behavior is different.

hrbrmstr commented 9 years ago

it did look like they did some "creative" stuff there. i'm not sure they really thought through custom colors, but then again it's only at 0.5.0 so they def get some slack :-)

On Wed, Aug 5, 2015 at 10:06 PM, timelyportfolio notifications@github.com wrote:

Dang, this is going to be trickier than I thought, and might be best handled in the legend plugin. Can get color, but then behavior is different.

— Reply to this email directly or view it on GitHub https://github.com/hrbrmstr/taucharts/issues/24#issuecomment-128212595.

timelyportfolio commented 9 years ago

Think I'm just tired. I think it is complete.

timelyportfolio commented 9 years ago

One thing is the legend does not match the opacity of the svg. Even though the legend plugin does not do this, I guess we could since we are overriding CSS anyways. Is it worth it?

hrbrmstr commented 9 years ago

mebbe post as a feature req in the taucharts lib?

On Thu, Aug 6, 2015 at 4:07 PM, timelyportfolio notifications@github.com wrote:

One thing is the legend does not match the opacity of the svg. Even though the legend plugin does not do this, I guess we could since we are overriding CSS anyways. Is it worth it?

— Reply to this email directly or view it on GitHub https://github.com/hrbrmstr/taucharts/issues/24#issuecomment-128489799.