| summaryrefslogtreecommitdiff |
diff options
Diffstat (limited to 'src/ElmModule')
| -rw-r--r-- | src/ElmModule/Init.elm | 18 | ||||
| -rw-r--r-- | src/ElmModule/Subscriptions.elm | 15 | ||||
| -rw-r--r-- | src/ElmModule/Update.elm | 23 | ||||
| -rw-r--r-- | src/ElmModule/View.elm | 26 |
4 files changed, 82 insertions, 0 deletions
diff --git a/src/ElmModule/Init.elm b/src/ElmModule/Init.elm new file mode 100644 index 0000000..9af3cce --- /dev/null +++ b/src/ElmModule/Init.elm @@ -0,0 +1,18 @@ +module ElmModule.Init exposing (init) + +-- Local Module ---------------------------------------------------------------- +import Struct.Flags +import Struct.Event +import Struct.Model + +-------------------------------------------------------------------------------- +-- LOCAL ----------------------------------------------------------------------- +-------------------------------------------------------------------------------- + +-------------------------------------------------------------------------------- +-- EXPORTED -------------------------------------------------------------------- +-------------------------------------------------------------------------------- +init : Struct.Flags.Type -> (Struct.Model.Type, (Cmd Struct.Event.Type)) +init flags = + -- TODO: read flags and request story. + (model, Cmd.none) diff --git a/src/ElmModule/Subscriptions.elm b/src/ElmModule/Subscriptions.elm new file mode 100644 index 0000000..c2b9fbe --- /dev/null +++ b/src/ElmModule/Subscriptions.elm @@ -0,0 +1,15 @@ +module ElmModule.Subscriptions exposing (..) + +-- Local Module ---------------------------------------------------------------- +import Struct.Model +import Struct.Event + +-------------------------------------------------------------------------------- +-- LOCAL ----------------------------------------------------------------------- +-------------------------------------------------------------------------------- + +-------------------------------------------------------------------------------- +-- EXPORTED -------------------------------------------------------------------- +-------------------------------------------------------------------------------- +subscriptions : Struct.Model.Type -> (Sub Struct.Event.Type) +subscriptions model = Sub.none diff --git a/src/ElmModule/Update.elm b/src/ElmModule/Update.elm new file mode 100644 index 0000000..a4b827a --- /dev/null +++ b/src/ElmModule/Update.elm @@ -0,0 +1,23 @@ +module ElmModule.Update exposing (update) + +-- Elm ------------------------------------------------------------------------- + +-- Local Module ---------------------------------------------------------------- +import Struct.Event +import Struct.Model + +-------------------------------------------------------------------------------- +-- LOCAL ----------------------------------------------------------------------- +-------------------------------------------------------------------------------- + +-------------------------------------------------------------------------------- +-- EXPORTED -------------------------------------------------------------------- +-------------------------------------------------------------------------------- +update : ( + Struct.Event.Type -> + Struct.Model.Type -> + (Struct.Model.Type, (Cmd Struct.Event.Type)) + ) +update event model = + case event of + Struct.Event.None -> (model, Cmd.none) diff --git a/src/ElmModule/View.elm b/src/ElmModule/View.elm new file mode 100644 index 0000000..fb99b89 --- /dev/null +++ b/src/ElmModule/View.elm @@ -0,0 +1,26 @@ +module ElmModule.View exposing (view) + +-- Elm ------------------------------------------------------------------------- +import Html +import Html.Attributes + +-- Local Module ---------------------------------------------------------------- +import Struct.Event +import Struct.Model + +-------------------------------------------------------------------------------- +-- LOCAL ----------------------------------------------------------------------- +-------------------------------------------------------------------------------- + +-------------------------------------------------------------------------------- +-- EXPORTED -------------------------------------------------------------------- +-------------------------------------------------------------------------------- +view : Struct.Model.Type -> (Html.Html Struct.Event.Type) +view model = + (Html.div + [ + (Html.Attributes.class "fullscreen-module") + ] + [ + ] + ) |


