aboutsummaryrefslogtreecommitdiff
path: root/src/server/Design/Global.hs
blob: 149769c9b5da9b4bdf474a9e954e5919770a116a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
{-# LANGUAGE OverloadedStrings #-}

module Design.Global
  ( globalDesign
  ) where

import Clay

import Data.Text.Lazy (Text)

import qualified Design.Header as Header
import qualified Design.SignIn as SignIn
import qualified Design.LoggedIn as LoggedIn
import qualified Design.Form as Form
import qualified Design.Dialog as Dialog

import Design.Animation.Keyframes

import Design.Color as Color
import Design.Helper as Helper
import Design.Constants as Constants

globalDesign :: Text
globalDesign = renderWith compact [] global

global :: Css
global = do

  header ? Header.design
  ".signIn" ? SignIn.design
  ".loggedIn" ? LoggedIn.design
  ".dialog" ? Dialog.design
  Form.design

  allKeyframes

  body ? do
    minWidth (px 320)
    fontFamily ["Cantarell"] [sansSerif]

  a ? cursor pointer

  h1 ? do
    fontSize (px 24)
    color Color.chestnutRose
    "margin-bottom" -: "3vh"

  ul ? do
    "margin-bottom" -: "3vh"
    "margin-left" -: "1vh"
    li <? do
      "margin-bottom" -: "2vh"
      before & do
        content (stringContent "• ")
        color Color.chestnutRose
        "margin-right" -: "0.3vw"
      ul <? do
        "margin-left" -: "3vh"
        "margin-top" -: "2vh"

  ".dialog" ? ".content" ? button ? do
    ".confirm" & Helper.defaultButton Color.chestnutRose Color.white (px Constants.inputHeight) Constants.focusLighten
    ".undo" & Helper.defaultButton Color.silver Color.white (px Constants.inputHeight) Constants.focusLighten

  svg ? height (pct 100)