26 lines
859 B
Haskell
26 lines
859 B
Haskell
{-# LANGUAGE OverloadedStrings #-}
|
|
module Common where
|
|
import Lucid.Base
|
|
import Lucid.Html5
|
|
import qualified Data.Text as T
|
|
type Name = T.Text
|
|
type Key = T.Text
|
|
type Students = [(Key, Name)]
|
|
|
|
layout :: Html() -> Html ()
|
|
layout bodyContent =
|
|
doctypehtml_ $ do
|
|
head_ $ do
|
|
link_ [ rel_ "stylesheet", href_ "https://unpkg.com/milligram/dist/milligram.min.css" ]
|
|
style_ $ T.unlines
|
|
[ "form { text-align:center; width: 70%; margin: 0 auto; }"
|
|
, "h1 { text-align: center; }"
|
|
, "h2 { text-align: center; }"
|
|
, "h3 { text-align: center; }"
|
|
, "p { text-align: center; }"
|
|
, "label { display: inline-flex; align-items: center; gap: 6px;}"
|
|
]
|
|
title_ "Каждому по заслугам"
|
|
meta_ [charset_ "utf-8"]
|
|
meta_ [name_ "viewport", content_ "width=device-width, initial-scale=1"]
|
|
body_ bodyContent
|