Browse Source

Rename onend to done in flow API - #314

pull/319/head
Masayuki Tanaka 11 years ago
parent
commit
b8c21eb32e
  1. 6
      c3.js
  2. 4
      c3.min.js
  3. 10
      htdocs/samples/api_flow.html

6
c3.js

@ -4050,7 +4050,7 @@
flowEnd = getValueOnIndex(c3.data.targets[0].values, flowIndex + flowLength),
orgDomain = x.domain(), domain,
durationForFlow = options.flow.duration || duration,
onend = options.flow.onend || function () {},
done = options.flow.done || function () {},
wait = generateWait();
// remove head data after rendered
@ -4157,7 +4157,7 @@
.attr("height", __axis_rotated ? rectW : height);
// callback for end of flow
onend();
done();
});
} : null);
@ -4983,7 +4983,7 @@
index: baseValue.index,
length: length,
duration: isValue(args.duration) ? args.duration : __transition_duration,
onend: args.onend,
done: args.done,
orgDataCount: orgDataCount,
},
withLegend: true,

4
c3.min.js vendored

File diff suppressed because one or more lines are too long

10
htdocs/samples/api_flow.html

@ -68,7 +68,7 @@
],
duration: 1500,
onend: function () {
done: function () {
// Load 2 data without data2 and remove 1 data
chart.flow({
columns: [
@ -78,7 +78,7 @@
length: 0,
duration: 1500,
onend: function () {
done: function () {
chart.flow({
columns: [
['data1', 200, 300],
@ -87,7 +87,7 @@
],
length: 2,
duration: 1500,
onend: function () {
done: function () {
chart.flow({
columns: [
@ -101,7 +101,7 @@
}
});
}// onend
}// done
});
},
@ -164,7 +164,7 @@
['data3', 200, 300],
],
duration: 1500,
onend: function () {
done: function () {
chart.flow({
columns: [
['data1', 200],

Loading…
Cancel
Save