aboutsummaryrefslogtreecommitdiff
path: root/src/Design/Global.hs
blob: 379d61208daaf08a0c39da4b3e038fb0a8d8782c (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
66
{-# LANGUAGE OverloadedStrings #-}

module Design.Global
  ( compactDesign
  ) where

import qualified Data.Text.Lazy as T
import Data.Monoid ((<>))

import Clay

import qualified Design.Color as Color
import qualified Design.Media as Media
import Design.Header (headerCss)
import Design.Resume (resumeCss)
import Design.Projects (projectsCss)
import Design.NotFound (notFoundCss)

compactDesign :: T.Text
compactDesign = renderWith compact [] $ global

global :: Css
global =
  body ? do
    color Color.black
    marginBottom (px 40)
    Media.mobile $ fontSize (px 16)
    Media.tabletDesktop $ fontSize (px 18)

    h1 ? do
      fontFamily [] [monospace]
      fontWeight bold
      color Color.red

      Media.mobile $ do
        lineHeight (px 30)
        fontSize (px 22)
        marginBottom (px 20)
        marginTop (px 35)

      Media.tablet $ do
        lineHeight (px 40)
        fontSize (px 27)
        marginBottom (px 35)
        marginTop (px 45)

      Media.desktop $ do
        lineHeight (px 50)
        fontSize (px 30)
        marginBottom (px 40)
        marginTop (px 55)

    a ? do
      textDecoration none
      color Color.link
      transition "color" (sec 0.3) easeOut (sec 0)
      focus & outline solid (px 0) Color.white

    (a # hover) <> (a # focus) ? do
      textDecoration underline
      color Color.blue

    headerCss
    resumeCss
    projectsCss
    notFoundCss