Module
MVC.Variant.View
- Package
- purescript-mvc
- Repository
- thought2/purescript-mvc
#ViewVariantProps Source
type ViewVariantProps :: (Type -> Type) -> Type
type ViewVariantProps html = { view :: forall msg. ViewArgs html msg -> html msg }
#CaseKeyToVariant Source
class CaseKeyToVariant :: Row Type -> Constraint
class CaseKeyToVariant (rcase :: Row Type) where
Members
caseKeyToVariant :: CaseKey -> Maybe (Variant rcase)
Instances
(CaseKeyToVariantRL rl rcase, RowToList rcase rl) => CaseKeyToVariant rcase
#CaseKeyToVariantRL Source
class CaseKeyToVariantRL :: RowList Type -> Row Type -> Constraint
class CaseKeyToVariantRL (rl :: RowList Type) (rcase :: Row Type) | rl -> rcase where
Members
caseKeyToVariantRL :: Proxy rl -> CaseKey -> Maybe (Variant rcase)
Instances
CaseKeyToVariantRL Nil ()
(CaseKeyToVariantRL rl' rcase', Cons sym Unit rcase' rcase, Lacks sym rcase', IsSymbol sym, Union rcase' rcasex rcase) => CaseKeyToVariantRL (Cons sym x rl') rcase
#GetSymRL Source
#ViewVariant Source
class ViewVariant :: (Type -> Type) -> Row Type -> Row Type -> Row Type -> Row Type -> Constraint
class ViewVariant (html :: Type -> Type) (views :: Row Type) (rcase :: Row Type) (rmsg :: Row Type) (rsta :: Row Type) where
Members
viewVariant :: ViewVariantProps html -> (Record views -> VariantState rsta -> html (VariantMsg rcase rmsg))
Instances
(ViewVariantRL rl html views rmsg rsta, RowToList views rl, CaseKeyToVariant rcase, Functor html, GetKeys rl, GetSym rsta) => ViewVariant html views rcase rmsg rsta
#ViewVariantRL Source
class ViewVariantRL :: RowList Type -> (Type -> Type) -> Row Type -> Row Type -> Row Type -> Constraint
class ViewVariantRL (rl :: RowList Type) (html :: Type -> Type) (views :: Row Type) (rmsg :: Row Type) (rsta :: Row Type) | rl -> rmsg rsta where
Members
viewVariantRL :: Proxy rl -> Record views -> Variant rsta -> html (Variant rmsg)
Instances
ViewVariantRL Nil html views () ()
(ViewVariantRL rl' html views rmsg' rsta', Cons sym msg rmsg' rmsg, Cons sym sta rsta' rsta, Cons sym (sta -> html msg) viewsx views, Lacks sym rmsg', Lacks sym rsta', Functor html, IsSymbol sym, Union rmsg' rmsgx rmsg) => ViewVariantRL (Cons sym x rl') html views rmsg rsta