module LoggedIn.View exposing ( view ) import Html exposing (..) import Html.Attributes exposing (..) import Page import Msg exposing (Msg) import Model exposing (Model) import LoggedData import LoggedIn.Model as LoggedInModel import LoggedIn.Home.View as HomeView import LoggedIn.Income.View as UserView import LoggedIn.Stat.View as StatView view : Model -> LoggedInModel.Model -> Html Msg view model loggedIn = div [ class "loggedIn" ] [ let loggedData = LoggedData.build model loggedIn in case model.page of Page.Home -> HomeView.view loggedData loggedIn.home Page.Income -> UserView.view loggedData loggedIn.income Page.Statistics -> StatView.view loggedData ]