Resolves #172, horizontal labels should be baseline-aligned by default

This commit is contained in:
mdgriffith 2020-05-20 09:40:08 -04:00
parent 4d7e114ac1
commit 5b7dc58fb1
2 changed files with 8 additions and 4 deletions

View File

@ -1612,28 +1612,28 @@ applyLabel attrs label input =
Internal.element
Internal.asColumn
(Internal.NodeName "label")
attrs
(Internal.htmlClass classes.inputLabel :: attrs)
(Internal.Unkeyed [ labelElement, input ])
Below ->
Internal.element
Internal.asColumn
(Internal.NodeName "label")
attrs
(Internal.htmlClass classes.inputLabel :: attrs)
(Internal.Unkeyed [ input, labelElement ])
OnRight ->
Internal.element
Internal.asRow
(Internal.NodeName "label")
attrs
(Internal.htmlClass classes.inputLabel :: attrs)
(Internal.Unkeyed [ input, labelElement ])
OnLeft ->
Internal.element
Internal.asRow
(Internal.NodeName "label")
attrs
(Internal.htmlClass classes.inputLabel :: attrs)
(Internal.Unkeyed [ labelElement, input ])

View File

@ -257,6 +257,7 @@ classes =
, inputMultilineParent = "imlp"
, inputMultilineFiller = "imlf"
, inputMultilineWrapper = "implw"
, inputLabel = "lbl"
-- link
, link = "lnk"
@ -1358,6 +1359,9 @@ baseSheet =
, Descriptor (dot classes.spaceEvenly)
[ Prop "justify-content" "space-between"
]
, Descriptor (dot classes.inputLabel)
[ Prop "align-items" "baseline"
]
]
, Descriptor (dot classes.column)
[ Prop "display" "flex"