Browse Source

Move style for legend background to css - #326

pull/340/head
Masayuki Tanaka 10 years ago
parent
commit
86b4131cb2
  1. 7
      c3.css
  2. 11
      c3.js
  3. 2
      c3.min.js

7
c3.css

@ -132,6 +132,13 @@
font-size: 12px;
}
.c3-legend-background {
opacity: 0.75;
fill: white;
stroke: lightgray;
stroke-width: 1
}
/*-- Tooltip --*/
.c3-tooltip {

11
c3.js

@ -4698,13 +4698,10 @@
// Set background for inset legend
if (isLegendInset && maxWidth !== 0) {
legend.insert('g', '.' + CLASS.legendItem)
.attr("class", CLASS.legendBackground).append('rect')
.style('opacity', 0.75)
.style('fill', 'white')
.style('stroke', 'lightgray')
.style('stroke-width', 1)
.attr('height', getLegendHeight() - 10)
.attr('width', maxWidth * (step + 1) + 10);
.attr("class", CLASS.legendBackground)
.append('rect')
.attr('height', getLegendHeight() - 10)
.attr('width', maxWidth * (step + 1) + 10);
}
texts = legend.selectAll('text')

2
c3.min.js vendored

File diff suppressed because one or more lines are too long
Loading…
Cancel
Save