File tree Expand file tree Collapse file tree 3 files changed +12
-6
lines changed
delivery-calculator/src/App/Widgets
miso-functora/src/Functora/Miso/Widgets Expand file tree Collapse file tree 3 files changed +12
-6
lines changed Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ fav st =
1717 Dialog. dialog
1818 ( Dialog. defOpts
1919 & # optsKeyed
20- .~ " fav"
20+ .~ Just " fav"
2121 )
2222 Dialog. Args
2323 { Dialog. argsModel = st,
Original file line number Diff line number Diff line change @@ -126,7 +126,7 @@ menu st =
126126 & # optsTitleIcon
127127 .~ Just Icon. IconSettings
128128 & # optsKeyed
129- .~ (" menu" :: Unicode )
129+ .~ Just (" menu" :: Unicode )
130130 & # optsTitle
131131 .~ Just " Settings"
132132 )
Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ data Opts model action = Opts
2929 optsFooterRight :: [View action ] -> [View action ],
3030 optsExtraOnClose :: model -> model ,
3131 optsFlexContent :: Bool ,
32- optsKeyed :: Unicode ,
32+ optsKeyed :: Maybe Unicode ,
3333 optsIcon :: Icon. Icon -> View action
3434 }
3535 deriving stock (Generic )
@@ -45,7 +45,7 @@ defOpts =
4545 optsFooterRight = id ,
4646 optsExtraOnClose = id ,
4747 optsFlexContent = True ,
48- optsKeyed = mempty ,
48+ optsKeyed = Nothing ,
4949 optsIcon = Icon. icon @ Icon. Fa
5050 }
5151
@@ -58,12 +58,18 @@ dialog opts args =
5858 if not opened
5959 then mempty
6060 else
61- [ keyed (optsKeyed opts <> " -overlay" )
61+ [ maybe
62+ id
63+ (keyed . (<> " -overlay" ))
64+ (optsKeyed opts)
6265 $ FixedOverlay. fixedOverlay
6366 [ role_ " button" ,
6467 onClick $ closeDialogAction opts args
6568 ],
66- keyed (optsKeyed opts <> " -content" )
69+ maybe
70+ id
71+ (keyed . (<> " -content" ))
72+ (optsKeyed opts)
6773 . nodeHtml " dialog" [boolProp " open" True ]
6874 $ Flex. flexLeftRight
6975 header_
You can’t perform that action at this time.
0 commit comments