From 65c5829a3f91329884b5da3cdf3d7c3ef23ac990 Mon Sep 17 00:00:00 2001 From: fr33domlover Date: Fri, 6 May 2016 10:26:11 +0000 Subject: [PATCH] Set centrally in Foundation using breadcrumbs --- src/Vervis/Foundation.hs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/Vervis/Foundation.hs b/src/Vervis/Foundation.hs index eb1d9ec..2596b2f 100644 --- a/src/Vervis/Foundation.hs +++ b/src/Vervis/Foundation.hs @@ -27,7 +27,7 @@ import Yesod.Core.Types (Logger) import qualified Yesod.Core.Unsafe as Unsafe --import qualified Data.CaseInsensitive as CI -import Data.Text as T (pack) +import Data.Text as T (pack, intercalate) --import qualified Data.Text.Encoding as TE import Text.Jasmine.Local (discardm) @@ -97,6 +97,7 @@ instance Yesod App where master <- getYesod mmsg <- getMessage mperson <- maybeAuth + (title, bcs) <- breadcrumbs -- We break up the default layout into two components: -- default-layout is the contents of the body tag, and @@ -105,7 +106,8 @@ instance Yesod App where -- you to use normal widget features in default-layout. pc <- widgetToPageContent $ do - --addStylesheet $ StaticR css_bootstrap_css + setTitle $ toHtml $ + T.intercalate " :: " (map snd bcs) <> " :: " <> title $(widgetFile "default-layout") withUrlRenderer $(hamletFile "templates/default-layout-wrapper.hamlet")