mirror of
https://gitlab.com/upRootNutrition/website.git
synced 2025-06-15 20:15:12 -05:00
feat: added contact page template
This commit is contained in:
parent
1501624920
commit
2a0b5f25ca
6 changed files with 133 additions and 1 deletions
3
frontend/src/Contact/Helpers.elm
Normal file
3
frontend/src/Contact/Helpers.elm
Normal file
|
@ -0,0 +1,3 @@
|
|||
module Contact.Helpers exposing (..)
|
||||
|
||||
import Contact.Types exposing (..)
|
3
frontend/src/Contact/Methods/Discord.elm
Normal file
3
frontend/src/Contact/Methods/Discord.elm
Normal file
|
@ -0,0 +1,3 @@
|
|||
module Contact.Methods.Discord exposing (..)
|
||||
|
||||
import Contact.Types exposing (..)
|
2
frontend/src/Contact/Types.elm
Normal file
2
frontend/src/Contact/Types.elm
Normal file
|
@ -0,0 +1,2 @@
|
|||
module Contact.Types exposing (..)
|
||||
|
103
frontend/src/Pages/Contact.elm
Normal file
103
frontend/src/Pages/Contact.elm
Normal file
|
@ -0,0 +1,103 @@
|
|||
module Pages.Contact exposing (Model, Msg, page)
|
||||
|
||||
import Config.Colour as T exposing (..)
|
||||
import Config.Format as O exposing (..)
|
||||
import Config.Identity as I exposing (..)
|
||||
import Effect exposing (Effect)
|
||||
import Element exposing (..)
|
||||
import Element.Font as F
|
||||
import Html
|
||||
import Html.Attributes as H exposing (style)
|
||||
import Layouts
|
||||
import Page exposing (Page)
|
||||
import Route exposing (Route)
|
||||
import Shared exposing (..)
|
||||
import View exposing (View)
|
||||
|
||||
|
||||
page : Shared.Model -> Route () -> Page Model Msg
|
||||
page shared route =
|
||||
Page.new
|
||||
{ init = init
|
||||
, update = update
|
||||
, subscriptions = subscriptions
|
||||
, view = view
|
||||
}
|
||||
|> Page.withLayout toLayout
|
||||
|
||||
|
||||
toLayout : Model -> Layouts.Layout Msg
|
||||
toLayout model =
|
||||
Layouts.Navbar {}
|
||||
|
||||
|
||||
|
||||
-- INIT
|
||||
|
||||
|
||||
type alias Model =
|
||||
{}
|
||||
|
||||
|
||||
init : () -> ( Model, Effect Msg )
|
||||
init () =
|
||||
( {}
|
||||
, Effect.none
|
||||
)
|
||||
|
||||
|
||||
|
||||
-- UPDATE
|
||||
|
||||
|
||||
type Msg
|
||||
= NoOp
|
||||
|
||||
|
||||
update : Msg -> Model -> ( Model, Effect Msg )
|
||||
update msg model =
|
||||
case msg of
|
||||
NoOp ->
|
||||
( model
|
||||
, Effect.none
|
||||
)
|
||||
|
||||
|
||||
|
||||
-- SUBSCRIPTIONS
|
||||
|
||||
|
||||
subscriptions : Model -> Sub Msg
|
||||
subscriptions model =
|
||||
Sub.none
|
||||
|
||||
|
||||
|
||||
-- VIEW
|
||||
|
||||
|
||||
view : Model -> View Msg
|
||||
view model =
|
||||
{ title = contactName
|
||||
, attributes = []
|
||||
, element = contactContainer
|
||||
}
|
||||
|
||||
|
||||
contactContainer : Element msg
|
||||
contactContainer =
|
||||
topLevelContainer contactList
|
||||
|
||||
|
||||
contactList : Element msg
|
||||
contactList =
|
||||
none
|
||||
|
||||
|
||||
|
||||
-- column
|
||||
-- pageList
|
||||
-- <|
|
||||
-- List.map contactMaker
|
||||
-- [
|
||||
-- ]
|
|
@ -78,4 +78,25 @@ subscriptions model =
|
|||
|
||||
view : Model -> View Msg
|
||||
view model =
|
||||
View.fromString "Pages.Home_"
|
||||
{ title = homeName
|
||||
, attributes = []
|
||||
, element = homeContainer
|
||||
}
|
||||
|
||||
|
||||
homeContainer : Element msg
|
||||
homeContainer =
|
||||
topLevelContainer homeList
|
||||
|
||||
|
||||
homeList : Element msg
|
||||
homeList =
|
||||
none
|
||||
|
||||
|
||||
|
||||
-- column
|
||||
-- pageList
|
||||
-- <|
|
||||
-- List.map homeMaker
|
||||
-- []
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 75 KiB After Width: | Height: | Size: 7.8 KiB |
Loading…
Add table
Add a link
Reference in a new issue