mirror of
https://github.com/NoRedInk/noredink-ui.git
synced 2024-12-02 23:52:22 +03:00
Reorganize the file a bit
This commit is contained in:
parent
ef219d7259
commit
4faffae6db
@ -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
|
||||
|
Loading…
Reference in New Issue
Block a user