Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
c3-closed
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
charts
c3-closed
Commits
88ac4618
Commit
88ac4618
authored
Sep 10, 2014
by
Masayuki Tanaka
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'santazhang-api-query-axis-range'
parents
b5d90f33
45777a95
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
34 additions
and
0 deletions
+34
-0
c3.js
c3.js
+17
-0
c3.min.js
c3.min.js
+0
-0
api.axis.js
src/api.axis.js
+17
-0
No files found.
c3.js
View file @
88ac4618
...
...
@@ -5987,6 +5987,12 @@
config
.
axis_y_max
=
config
.
axis_y2_max
=
max
;
}
$$
.
redraw
({
withUpdateOrgXDomain
:
true
,
withUpdateXDomain
:
true
});
}
else
{
return
{
x
:
config
.
axis_x_max
,
y
:
config
.
axis_y_max
,
y2
:
config
.
axis_y2_max
};
}
};
c3_chart_fn
.
axis
.
min
=
function
(
min
)
{
...
...
@@ -6000,12 +6006,23 @@
config
.
axis_y_min
=
config
.
axis_y2_min
=
min
;
}
$$
.
redraw
({
withUpdateOrgXDomain
:
true
,
withUpdateXDomain
:
true
});
}
else
{
return
{
x
:
config
.
axis_x_min
,
y
:
config
.
axis_y_min
,
y2
:
config
.
axis_y2_min
};
}
};
c3_chart_fn
.
axis
.
range
=
function
(
range
)
{
if
(
arguments
.
length
)
{
if
(
isDefined
(
range
.
max
))
{
this
.
axis
.
max
(
range
.
max
);
}
if
(
isDefined
(
range
.
min
))
{
this
.
axis
.
min
(
range
.
min
);
}
}
else
{
return
{
max
:
this
.
axis
.
max
(),
min
:
this
.
axis
.
min
()
};
}
};
...
...
c3.min.js
View file @
88ac4618
This source diff could not be displayed because it is too large. You can
view the blob
instead.
src/api.axis.js
View file @
88ac4618
...
...
@@ -20,6 +20,12 @@ c3_chart_fn.axis.max = function (max) {
config
.
axis_y_max
=
config
.
axis_y2_max
=
max
;
}
$$
.
redraw
({
withUpdateOrgXDomain
:
true
,
withUpdateXDomain
:
true
});
}
else
{
return
{
x
:
config
.
axis_x_max
,
y
:
config
.
axis_y_max
,
y2
:
config
.
axis_y2_max
};
}
};
c3_chart_fn
.
axis
.
min
=
function
(
min
)
{
...
...
@@ -33,11 +39,22 @@ c3_chart_fn.axis.min = function (min) {
config
.
axis_y_min
=
config
.
axis_y2_min
=
min
;
}
$$
.
redraw
({
withUpdateOrgXDomain
:
true
,
withUpdateXDomain
:
true
});
}
else
{
return
{
x
:
config
.
axis_x_min
,
y
:
config
.
axis_y_min
,
y2
:
config
.
axis_y2_min
};
}
};
c3_chart_fn
.
axis
.
range
=
function
(
range
)
{
if
(
arguments
.
length
)
{
if
(
isDefined
(
range
.
max
))
{
this
.
axis
.
max
(
range
.
max
);
}
if
(
isDefined
(
range
.
min
))
{
this
.
axis
.
min
(
range
.
min
);
}
}
else
{
return
{
max
:
this
.
axis
.
max
(),
min
:
this
.
axis
.
min
()
};
}
};
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment