Auto-wrap SomeMessage on fieldSettingsLabel
This commit is contained in:
parent
ce1f691f43
commit
a3fdf21121
@ -346,8 +346,8 @@ customErrorMessage msg field = field { fieldParse = \ts -> fmap (either
|
|||||||
(const $ Left msg) Right) $ fieldParse field ts }
|
(const $ Left msg) Right) $ fieldParse field ts }
|
||||||
|
|
||||||
-- | Generate a 'FieldSettings' from the given label.
|
-- | Generate a 'FieldSettings' from the given label.
|
||||||
fieldSettingsLabel :: SomeMessage master -> FieldSettings master
|
fieldSettingsLabel :: RenderMessage master msg => msg -> FieldSettings master
|
||||||
fieldSettingsLabel msg = FieldSettings msg Nothing Nothing Nothing []
|
fieldSettingsLabel msg = FieldSettings (SomeMessage msg) Nothing Nothing Nothing []
|
||||||
|
|
||||||
-- | Generate an 'AForm' that gets its value from the given action.
|
-- | Generate an 'AForm' that gets its value from the given action.
|
||||||
aformM :: GHandler sub master a -> AForm sub master a
|
aformM :: GHandler sub master a -> AForm sub master a
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
name: yesod-form
|
name: yesod-form
|
||||||
version: 1.0.0.1
|
version: 1.0.0.2
|
||||||
license: MIT
|
license: MIT
|
||||||
license-file: LICENSE
|
license-file: LICENSE
|
||||||
author: Michael Snoyman <michael@snoyman.com>
|
author: Michael Snoyman <michael@snoyman.com>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user