Reorganize the file a bit

This commit is contained in:
Tessa Kelly 2019-04-04 11:38:34 -07:00
parent ef219d7259
commit 4faffae6db

View File

@ -126,42 +126,6 @@ buildCheckbox model labelView =
viewLockedCheckbox model labelView
positioning : Style
positioning =
batch
[ display inlineBlock
, padding4 (px 13) zero (px 13) (px 35)
]
textStyle : Style
textStyle =
batch
[ Fonts.baseFont
, fontSize (px 16)
, fontWeight (int 600)
, color Colors.navy
]
labelClass : IsSelected -> Html.Styled.Attribute msg
labelClass isSelected =
case isSelected of
Selected ->
toClassList [ "Label", "Checked" ]
NotSelected ->
toClassList [ "Label", "Unchecked" ]
PartiallySelected ->
toClassList [ "Label", "Indeterminate" ]
toClassList : List String -> Html.Styled.Attribute msg
toClassList =
List.map (\a -> ( "checkbox-V3__" ++ a, True )) >> Attributes.classList
viewSquareCheckbox : Model msg -> (String -> Html.Html msg) -> Html.Html msg
viewSquareCheckbox model labelView =
let
@ -300,6 +264,42 @@ viewDisabledLabel model labelView icon =
]
labelClass : IsSelected -> Html.Styled.Attribute msg
labelClass isSelected =
case isSelected of
Selected ->
toClassList [ "Label", "Checked" ]
NotSelected ->
toClassList [ "Label", "Unchecked" ]
PartiallySelected ->
toClassList [ "Label", "Indeterminate" ]
toClassList : List String -> Html.Styled.Attribute msg
toClassList =
List.map (\a -> ( "checkbox-V5__" ++ a, True )) >> Attributes.classList
positioning : Style
positioning =
batch
[ display inlineBlock
, padding4 (px 13) zero (px 13) (px 35)
]
textStyle : Style
textStyle =
batch
[ Fonts.baseFont
, fontSize (px 16)
, fontWeight (int 600)
, color Colors.navy
]
viewIcon : List Style -> Icon -> Html.Html msg
viewIcon styles (Icon icon) =
Html.div