You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@superset.apache.org by mi...@apache.org on 2022/07/06 16:05:30 UTC
[superset] 04/11: fix(big-number): big number gets cut off on a Dashboard (#20488)
This is an automated email from the ASF dual-hosted git repository.
michaelsmolina pushed a commit to branch 2.0
in repository https://gitbox.apache.org/repos/asf/superset.git
commit 4b2397f0c74fbef5da68ac55d5d2a1b8a905eed4
Author: Stephen Liu <75...@qq.com>
AuthorDate: Thu Jun 30 16:19:38 2022 +0800
fix(big-number): big number gets cut off on a Dashboard (#20488)
(cherry picked from commit 24a53c38c68108c47af9f7685542fcb8378915bf)
---
.../plugins/plugin-chart-echarts/src/BigNumber/BigNumberViz.tsx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/superset-frontend/plugins/plugin-chart-echarts/src/BigNumber/BigNumberViz.tsx b/superset-frontend/plugins/plugin-chart-echarts/src/BigNumber/BigNumberViz.tsx
index a77dc54173..d14cc7dcef 100644
--- a/superset-frontend/plugins/plugin-chart-echarts/src/BigNumber/BigNumberViz.tsx
+++ b/superset-frontend/plugins/plugin-chart-echarts/src/BigNumber/BigNumberViz.tsx
@@ -152,7 +152,7 @@ class BigNumberVis extends React.PureComponent<BigNumberVisProps> {
document.body.append(container);
const fontSize = computeMaxFontSize({
text,
- maxWidth: width,
+ maxWidth: width - 8, // Decrease 8px for more precise font size
maxHeight,
className: 'header-line',
container,