Skip to content

The easy-to-use open source Business Intelligence and Embedded Analytics tool that lets everyone work with data :bar_chart:

Fix icon and text vertical alignment in incremental transform alert (#79681)

Egor Grushin24b402cf958a
diff --git a/frontend/src/metabase/ui/components/feedback/Alert/Alert.module.css b/frontend/src/metabase/ui/components/feedback/Alert/Alert.module.css
index 7c570d925b9..5f59f3d3c65 100644
--- a/frontend/src/metabase/ui/components/feedback/Alert/Alert.module.css
+++ b/frontend/src/metabase/ui/components/feedback/Alert/Alert.module.css
@@ -1,5 +1,6 @@
.root {
--alert-control-size: 24px;
+ --alert-line-height: 20px;
padding: var(--mantine-spacing-lg) var(--mantine-spacing-md)
var(--mantine-spacing-lg) var(--mantine-spacing-lg);
@@ -40,7 +41,7 @@
.message {
font-size: var(--mantine-font-size-md);
- line-height: 20px;
+ line-height: var(--alert-line-height);
color: var(--mb-color-text-secondary);
}
@@ -54,7 +55,21 @@
color: var(--mb-color-text-primary);
}
+.root:not(:has(.title)) {
+ & .icon {
+ height: var(--alert-line-height);
+ }
+
+ & .closeButton {
+ margin-block: calc(
+ (var(--alert-line-height) - var(--alert-control-size)) / 2
+ );
+ }
+}
+
.root[data-size="compact"] {
+ --alert-line-height: 16px;
+
padding: var(--mantine-spacing-md) 12px var(--mantine-spacing-md)
var(--mantine-spacing-md);
@@ -70,7 +85,6 @@
& .message {
font-size: var(--mantine-font-size-sm);
- line-height: 16px;
}
}