From a5ca9d8cbe4ce8618f9c2856a8725ef65aaf9698 Mon Sep 17 00:00:00 2001 From: Felix Hamann Date: Thu, 29 Mar 2018 00:59:40 +0200 Subject: [PATCH] more robust form layout --- templates/widgets/form.lucius | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/templates/widgets/form.lucius b/templates/widgets/form.lucius index ee3c5cf5a..b16b91603 100644 --- a/templates/widgets/form.lucius +++ b/templates/widgets/form.lucius @@ -8,8 +8,8 @@ form { position: relative; display: flex; display: grid; - grid-template-columns: repeat(2, minmax(150px, max-content)); - grid-auto-columns: minmax(150px, max-content); + grid-template-columns: 25% 300px; + grid-auto-columns: 25%; grid-gap: 5px; justify-content: flex-start; align-items: center; @@ -30,6 +30,11 @@ form { border-left: 8px solid var(--errorbase) !important; } +.form-group__label { + width: 25%; + white-space: nowrap; +} + @media (max-width: 999px) { .form-group { grid-template-columns: 1fr; @@ -37,9 +42,9 @@ form { align-items: baseline; margin-top: 17px; flex-direction: column; + + > * { + width: 100%; + } } } - -.form-group__label { - width: 25%; -}