Skip to content

Commit

Permalink
Merge pull request #89 from dexma/fix-gauge-correct-indicator-resizing
Browse files Browse the repository at this point in the history
fix(gauge):correct indicator resizing behaviour
  • Loading branch information
Xolsk authored May 3, 2023
2 parents 444108d + 7552a98 commit 449e94b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/Gauge.js
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ const renderIndicatorLabel = (
let textBox = currentChart.indicatorLabel.getBBox();
if (
textBox.width >
currentChart.axes[1].axisGroup.element.getBoundingClientRect().width * 0.7
currentChart.chartWidth / indicator.value.toString().length
) {
currentChart.indicatorLabel.attr({
text: applyScientific(parseFloat(indicator.value), decimalSeparator, 2),
Expand Down

0 comments on commit 449e94b

Please sign in to comment.