summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/ElmModule')
-rw-r--r--src/ElmModule/Update.elm4
-rw-r--r--src/ElmModule/View.elm14
2 files changed, 18 insertions, 0 deletions
diff --git a/src/ElmModule/Update.elm b/src/ElmModule/Update.elm
index a4b827a..3dbad82 100644
--- a/src/ElmModule/Update.elm
+++ b/src/ElmModule/Update.elm
@@ -6,6 +6,8 @@ module ElmModule.Update exposing (update)
import Struct.Event
import Struct.Model
+import Update.Story
+
--------------------------------------------------------------------------------
-- LOCAL -----------------------------------------------------------------------
--------------------------------------------------------------------------------
@@ -21,3 +23,5 @@ update : (
update event model =
case event of
Struct.Event.None -> (model, Cmd.none)
+ (Struct.Event.ChoiceSelected ix) ->
+ ((Update.Story.select_choice ix model), Cmd.none)
diff --git a/src/ElmModule/View.elm b/src/ElmModule/View.elm
index fb99b89..f93928c 100644
--- a/src/ElmModule/View.elm
+++ b/src/ElmModule/View.elm
@@ -8,6 +8,7 @@ import Html.Attributes
import Struct.Event
import Struct.Model
+import View.PlayerInput
--------------------------------------------------------------------------------
-- LOCAL -----------------------------------------------------------------------
--------------------------------------------------------------------------------
@@ -22,5 +23,18 @@ view model =
(Html.Attributes.class "fullscreen-module")
]
[
+ (Html.div
+ [
+ (Html.Attributes.class "tonkadur-errors")
+ ]
+ model.ui.displayed_errors
+ ),
+ (Html.div
+ [
+ (Html.Attributes.class "tonkadur-texts")
+ ]
+ model.ui.displayed_texts
+ ),
+ (View.PlayerInput.get_html model)
]
)