Commit 7e02bab5 authored by Masayuki Tanaka's avatar Masayuki Tanaka Committed by masayuki

Fix ygrid

parent c4ee971a
...@@ -614,16 +614,7 @@ ...@@ -614,16 +614,7 @@
// Y-Grid // Y-Grid
if (__grid_y_show) { if (__grid_y_show) {
grid.append('g') grid.append('g').attr('class', 'ygrids')
.attr('class', 'ygrids')
.selectAll(".ygrid")
.data(y.ticks(10))
.enter().append("line")
.attr("class", "ygrid")
.attr("x1", 0)
.attr("x2", width)
.attr("y1", y)
.attr("y2", y)
} }
if (__grid_y_lines) { if (__grid_y_lines) {
grid.append('g') grid.append('g')
...@@ -905,7 +896,7 @@ ...@@ -905,7 +896,7 @@
if (__legend_show) drawLegend(targets) if (__legend_show) drawLegend(targets)
// Update main chart with settings // Update main chart with settings
update() update(false, true)
// Draw chart for each data // Draw chart for each data
draw(targets) draw(targets)
...@@ -918,6 +909,8 @@ ...@@ -918,6 +909,8 @@
var barX, barY, barW, barH var barX, barY, barW, barH
var rectWidth var rectWidth
withY = (typeof withY === 'undefined') ? false : withY
x.domain(brush.empty() ? x2.domain() : brush.extent()) x.domain(brush.empty() ? x2.domain() : brush.extent())
// ticks for x-axis // ticks for x-axis
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment