aboutsummaryrefslogtreecommitdiff
path: root/src/client/View/Page.elm
blob: 70153179a842cbfa62667d8f870dfa295ffa7eec (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
module View.Page
  ( renderPage
  ) where

import Html exposing (..)

import Model exposing (Model)
import Model.View exposing (..)

import View.Header exposing (renderHeader)
import View.Loading exposing (renderLoading)
import View.SignIn exposing (renderSignIn)
import View.Payments exposing (renderPayments)

renderPage : Model -> Html
renderPage model =
  div
    []
    [ renderHeader model
    , renderMain model
    ]

renderMain : Model -> Html
renderMain model =
  case model.view of
    LoadingView ->
      renderLoading
    SignInView signInView ->
      renderSignIn model signInView
    PaymentView paymentsView ->
      renderPayments model paymentsView