From e97853abc9fe26ce3bbb1ba1d782c735067f2afc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torkel=20=C3=96degaard?= Date: Wed, 8 May 2019 17:21:17 +0200 Subject: [PATCH] Singlestat: fixed centering issue for very small panels (#16944) --- public/sass/components/_panel_singlestat.scss | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/public/sass/components/_panel_singlestat.scss b/public/sass/components/_panel_singlestat.scss index 708fd65de94..7854ac2093f 100644 --- a/public/sass/components/_panel_singlestat.scss +++ b/public/sass/components/_panel_singlestat.scss @@ -6,16 +6,17 @@ } .singlestat-panel-value-container { - line-height: 1; + // line-height 0 is imporant here as the font-size is on this + // level but overriden one level deeper and but the line-height: is still + // based on the base font size on this level. Using line-height: 0 fixes that + line-height: 0; display: table-cell; vertical-align: middle; text-align: center; position: relative; z-index: 1; - font-size: 3em; font-weight: $font-weight-semi-bold; - // helps make the title feel more centered when there is a panel title - padding-bottom: $panel-padding; + font-size: 38px; } // Helps