Added liftHandler function
This commit is contained in:
parent
839efad98b
commit
cb51f4fa8e
@ -9,6 +9,7 @@ module Yesod.Widget
|
||||
( -- * Datatype
|
||||
GWidget
|
||||
, Widget
|
||||
, liftHandler
|
||||
-- * Unwrapping
|
||||
, widgetToPageContent
|
||||
, applyLayoutW
|
||||
@ -95,6 +96,11 @@ instance Monoid (GWidget sub master ()) where
|
||||
-- | A 'GWidget' specialized to when the subsite and master site are the same.
|
||||
type Widget y = GWidget y y
|
||||
|
||||
-- | Lift an action in the 'GHandler' monad into an action in the 'GWidget'
|
||||
-- monad.
|
||||
liftHandler :: GHandler sub master a -> GWidget sub master a
|
||||
liftHandler = GWidget . lift . lift . lift . lift . lift . lift . lift . lift
|
||||
|
||||
-- | Set the page title. Calling 'setTitle' multiple times overrides previously
|
||||
-- set values.
|
||||
setTitle :: Html () -> GWidget sub master ()
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
name: yesod
|
||||
version: 0.4.0.3
|
||||
version: 0.4.1
|
||||
license: BSD3
|
||||
license-file: LICENSE
|
||||
author: Michael Snoyman <michael@snoyman.com>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user