diff options
author | Sean Whitton <spwhitton@spwhitton.name> | 2015-03-17 06:20:57 +0000 |
---|---|---|
committer | Sean Whitton <spwhitton@spwhitton.name> | 2015-03-17 06:20:57 +0000 |
commit | 65542e5f0f2cd31a943f090e41c53f1a6f572da3 (patch) | |
tree | 3a040196a8b6496df1605ebc7c74b44a902c1bd4 | |
parent | d29bc3e2f6bfd229c58a25741ee79ebe5bd87e55 (diff) | |
download | sariulclocks-65542e5f0f2cd31a943f090e41c53f1a6f572da3.tar.gz |
bring rankings table into bootstrap's layout engine
-rw-r--r-- | src/Utils/Classes.hs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Utils/Classes.hs b/src/Utils/Classes.hs index 091b41d..5451b73 100644 --- a/src/Utils/Classes.hs +++ b/src/Utils/Classes.hs @@ -8,6 +8,7 @@ import Types.Scores import Utils.Xhtml import Data.List (sortBy) import Data.Function (on) +import Text.XHtml.Bootstrap -- Make the columns with rankingColumns, and then transpose them so -- that we can make HTML. @@ -24,7 +25,8 @@ rankings :: Page Html rankings = do session <- getSession scores <- getScores - return (table ! [htmlAttr "class" (noHtml +++ "table table-bordered table-centered table-chunky")] + return (thediv # "container" << thediv # "col-md-12" << + table ! [htmlAttr "class" (noHtml +++ "table table-bordered table-centered table-chunky")] << foldr (\row acc -> (tr << row) +++ acc) noHtml (rankings' (currentClass session) scores)) -- rankings :: Maybe Class -> ScoresList -> Html |