Commit 767a2828 authored by Sascha Herzinger's avatar Sascha Herzinger
Browse files

minor text placement improvements

parent b1c84bb1
......@@ -43,7 +43,7 @@
upperQuartile,
median,
lowerQuartile,
lowerWhisker
lowerWhisker,
});
}
return boxplots;
......
......@@ -287,7 +287,7 @@ export default class extends Chart {
.append('text')
.attr('class', 'ac-box-value ac-box-value-upper-whisker')
.merge(upperWhiskerValue)
.attr('transform', d => `translate(${x(d.group) + x.bandwidth() - x.bandwidth() / 3}, ${y(d.upperWhisker)})`)
.attr('transform', d => `translate(${x(d.group) + x.bandwidth() - x.bandwidth() / 2 + 5}, ${y(d.upperWhisker)})`)
.attr('text-anchor', 'start')
.style('dominant-baseline', 'central')
.style('opacity', 0)
......@@ -303,7 +303,7 @@ export default class extends Chart {
.append('text')
.attr('class', 'ac-box-value ac-box-value-lower-whisker')
.merge(lowerWhiskerValue)
.attr('transform', d => `translate(${x(d.group) + x.bandwidth() - x.bandwidth() / 3}, ${y(d.lowerWhisker)})`)
.attr('transform', d => `translate(${x(d.group) + x.bandwidth() - x.bandwidth() / 2 + 5}, ${y(d.lowerWhisker)})`)
.attr('text-anchor', 'start')
.style('dominant-baseline', 'central')
.style('opacity', 0)
......@@ -319,7 +319,7 @@ export default class extends Chart {
.append('text')
.attr('class', 'ac-box-value ac-box-value-upper-quartile')
.merge(upperQuartileValue)
.attr('transform', d => `translate(${x(d.group)}, ${y(d.upperQuartile)})`)
.attr('transform', d => `translate(${x(d.group) - 5}, ${y(d.upperQuartile)})`)
.attr('text-anchor', 'end')
.style('dominant-baseline', 'central')
.style('opacity', 0)
......@@ -335,7 +335,7 @@ export default class extends Chart {
.append('text')
.attr('class', 'ac-box-value ac-box-value-lower-quartile')
.merge(lowerQuartileValue)
.attr('transform', d => `translate(${x(d.group)}, ${y(d.lowerQuartile)})`)
.attr('transform', d => `translate(${x(d.group) - 5}, ${y(d.lowerQuartile)})`)
.attr('text-anchor', 'end')
.style('dominant-baseline', 'central')
.style('opacity', 0)
......@@ -351,7 +351,7 @@ export default class extends Chart {
.append('text')
.attr('class', 'ac-box-value ac-box-value-median')
.merge(medianValue)
.attr('transform', d => `translate(${x(d.group) + x.bandwidth()}, ${y(d.median)})`)
.attr('transform', d => `translate(${x(d.group) + x.bandwidth() + 5}, ${y(d.median)})`)
.attr('text-anchor', 'start')
.style('dominant-baseline', 'central')
.style('opacity', 0)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment