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
Evgeny
c3-closed
Commits
b678c157
Commit
b678c157
authored
May 10, 2014
by
Masayuki Tanaka
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix category axis when init
parent
a4bb085b
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
14 deletions
+16
-14
c3.js
c3.js
+16
-14
c3.min.js
c3.min.js
+0
-0
No files found.
c3.js
View file @
b678c157
...
...
@@ -3053,6 +3053,21 @@
transitions
=
transitions
||
generateAxisTransitions
(
durationForAxis
);
// MEMO: call axis to generate ticks and get those length, then update translate with them
if
(
withUpdateTranslate
)
{
if
(
__axis_rotated
)
{
axes
.
x
.
call
(
xAxis
);
axes
.
subx
.
call
(
subXAxis
);
}
else
{
axes
.
y
.
call
(
yAxis
);
axes
.
y2
.
call
(
y2Axis
);
}
updateSizes
();
updateScales
();
updateSvgSize
();
transformAll
(
false
);
}
// update legend and transform each g
if
(
withLegend
&&
__legend_show
)
{
updateLegend
(
mapToIds
(
c3
.
data
.
targets
),
options
,
transitions
);
...
...
@@ -3100,19 +3115,6 @@
// Update axis label
updateAxisLabels
(
withTransition
);
// MEMO: need to be called after axis updated because updated tick's width will be used
if
(
withUpdateTranslate
)
{
updateSizes
();
updateScales
();
updateSvgSize
();
transformAll
(
false
);
// update axis again
axes
.
x
.
call
(
xAxis
);
axes
.
y
.
call
(
yAxis
);
axes
.
y2
.
call
(
y2Axis
);
axes
.
subx
.
call
(
subXAxis
);
}
// show/hide if manual culling needed
if
(
withUpdateXDomain
&&
targetsToShow
.
length
)
{
if
(
__axis_x_tick_culling
&&
tickValues
)
{
...
...
@@ -4609,7 +4611,7 @@
textUpdate
=
tickUpdate
.
select
(
"text"
);
if
(
isCategory
)
{
tickOffset
=
Math
.
ceil
((
scale1
(
1
)
-
scale1
(
0
))
/
2
);
tickOffset
=
Math
.
round
((
scale1
(
1
)
-
scale1
(
0
))
/
2
);
tickX
=
tickCentered
?
0
:
tickOffset
;
}
else
{
tickOffset
=
tickX
=
0
;
...
...
c3.min.js
View file @
b678c157
This source diff could not be displayed because it is too large. You can
view the blob
instead.
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