Browse Source

Fix rotated tick for subchart - #743

pull/779/head
Masayuki Tanaka 10 years ago
parent
commit
bfffa3c4b3
  1. 6
      c3.js
  2. 6
      c3.min.js
  3. 1
      src/axis.js
  4. 5
      src/subchart.js

6
c3.js

@ -4353,6 +4353,7 @@
// rotate tick text if needed
if (!config.axis_rotated && config.axis_x_tick_rotate) {
$$.rotateTickText($$.axes.x, transitions.axisX, config.axis_x_tick_rotate);
$$.rotateTickText($$.axes.subx, transitions.axisSubX, config.axis_x_tick_rotate);
}
};
@ -5144,11 +5145,6 @@
// update subchart elements if needed
if (withSubchart) {
// rotate tick text if needed
if (!config.axis_rotated && config.axis_x_tick_rotate) {
$$.rotateTickText($$.axes.subx, transitions.axisSubX, config.axis_x_tick_rotate);
}
// extent rect
if (!$$.brush.empty()) {
$$.brush.extent($$.x.orgDomain()).update();

6
c3.min.js vendored

File diff suppressed because one or more lines are too long

1
src/axis.js

@ -368,5 +368,6 @@ c3_chart_internal_fn.redrawAxis = function (transitions, isHidden) {
// rotate tick text if needed
if (!config.axis_rotated && config.axis_x_tick_rotate) {
$$.rotateTickText($$.axes.x, transitions.axisX, config.axis_x_tick_rotate);
$$.rotateTickText($$.axes.subx, transitions.axisSubX, config.axis_x_tick_rotate);
}
};

5
src/subchart.js

@ -99,11 +99,6 @@ c3_chart_internal_fn.redrawSubchart = function (withSubchart, transitions, durat
// update subchart elements if needed
if (withSubchart) {
// rotate tick text if needed
if (!config.axis_rotated && config.axis_x_tick_rotate) {
$$.rotateTickText($$.axes.subx, transitions.axisSubX, config.axis_x_tick_rotate);
}
// extent rect
if (!$$.brush.empty()) {
$$.brush.extent($$.x.orgDomain()).update();

Loading…
Cancel
Save