Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Sascha Herzinger
AdaCharts
Commits
bb9f81d9
Commit
bb9f81d9
authored
Jan 23, 2019
by
Sascha Herzinger
Browse files
fixed disappearing label issue
parent
5b52fdcd
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/charts/impl/Heatmap.js
View file @
bb9f81d9
...
...
@@ -40,6 +40,8 @@ export default class extends Chart {
this
.
tooltipValuePrefix
=
''
;
this
.
tooltipRowPrefix
=
''
;
this
.
tooltipColPrefix
=
''
;
this
.
xLabel
=
''
;
this
.
yLabel
=
''
;
}
static
get
name
()
{
...
...
@@ -82,6 +84,8 @@ export default class extends Chart {
this
.
textToChartRatio
=
typeof
textToChartRatio
===
'
undefined
'
?
this
.
textToChartRatio
:
textToChartRatio
;
this
.
colLabelPos
=
typeof
colLabelPos
===
'
undefined
'
?
this
.
colLabelPos
:
colLabelPos
;
this
.
rowLabelPos
=
typeof
rowLabelPos
===
'
undefined
'
?
this
.
rowLabelPos
:
rowLabelPos
;
this
.
xLabel
=
typeof
xLabel
===
'
undefined
'
?
this
.
xLabel
:
xLabel
;
this
.
yLabel
=
typeof
yLabel
===
'
undefined
'
?
this
.
yLabel
:
yLabel
;
this
.
tooltipValuePrefix
=
typeof
tooltipValuePrefix
===
'
undefined
'
?
this
.
tooltipValuePrefix
:
tooltipValuePrefix
;
this
.
tooltipRowPrefix
=
typeof
tooltipRowPrefix
===
'
undefined
'
?
this
.
tooltipRowPrefix
:
tooltipRowPrefix
;
this
.
tooltipColPrefix
=
typeof
tooltipColPrefix
===
'
undefined
'
?
this
.
tooltipColPrefix
:
tooltipColPrefix
;
...
...
@@ -153,7 +157,7 @@ export default class extends Chart {
return
`translate(
${
this
.
width
/
2
}
,
${
yTrans
}
)`
;
})
.
style
(
'
font-size
'
,
`
${
AXIS_LABEL_FONT_SIZE
}
px`
)
.
text
(
xLabel
);
.
text
(
this
.
xLabel
);
this
.
svg
.
selectAll
(
'
.y-axis-label
'
)
.
remove
();
...
...
@@ -168,7 +172,7 @@ export default class extends Chart {
return
`translate(
${
xTrans
}
,
${
this
.
height
/
2
}
)rotate(-90)`
;
})
.
style
(
'
font-size
'
,
`
${
AXIS_LABEL_FONT_SIZE
}
px`
)
.
text
(
yLabel
);
.
text
(
this
.
yLabel
);
const
rect
=
this
.
memory
.
selectAll
(
'
rect
'
)
.
data
(
this
.
data
,
d
=>
`
${
d
.
row
}
-
${
d
.
col
}
`
);
...
...
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