Make our default layout stylesheet handle area as flexbox, similar to backoffice styling. (#13534)

This commit is contained in:
Niels Lyngsø
2022-12-13 09:35:34 +01:00
committed by GitHub
parent f017c27db8
commit e4d1c65081
2 changed files with 6 additions and 0 deletions

View File

@@ -22,6 +22,9 @@
}
.umb-block-grid__area {
position: relative;
height: 100%;
display: flex;
flex-direction: column;
--umb-block-grid__area-calc: calc(var(--umb-block-grid--area-column-span) / var(--umb-block-grid--area-grid-columns, 1));
width: calc(var(--umb-block-grid__area-calc) * 100% - (1 - var(--umb-block-grid__area-calc)) * var(--umb-block-grid--areas-column-gap, 0px));
}

View File

@@ -28,6 +28,9 @@
}
.umb-block-grid__area {
position: relative;
height: 100%;
display: flex;
flex-direction: column;
/* For small devices we scale columnSpan by three, to make everything bigger than 1/3 take full width: */
grid-column-end: span min(calc(var(--umb-block-grid--area-column-span, 1) * 3), var(--umb-block-grid--area-grid-columns));
grid-row: span var(--umb-block-grid--area-row-span, 1);