moving toward configuring new repos in the webapp

This commit is contained in:
Joey Hess 2012-08-03 14:36:16 -04:00
parent 2d4f1441c8
commit b1a5a4f985
13 changed files with 147 additions and 67 deletions

View file

@ -22,9 +22,13 @@ import Data.Text (Text)
import qualified Data.Map as M
import Control.Concurrent
sideBarDisplay :: Widget
sideBarDisplay = do
sideBarDisplay :: Maybe Widget -> Widget
sideBarDisplay onsidebar = do
let content = do
{- If a widget was passed to include on the sidebar, display
- it above alerts. -}
maybe noop id onsidebar
{- Any yesod message appears as the first alert. -}
maybe noop rendermessage =<< lift getMessage
@ -83,7 +87,7 @@ getSideBarR nid = do
- to avoid slowing down user actions like closing alerts. -}
liftIO $ threadDelay 100000
page <- widgetToPageContent sideBarDisplay
page <- widgetToPageContent $ sideBarDisplay Nothing
hamletToRepHtml $ [hamlet|^{pageBody page}|]
{- Called by the client to close an alert. -}