From 380729ff7a7f7030cc17f531d850917a5706e4f4 Mon Sep 17 00:00:00 2001 From: nsensfel Date: Mon, 15 Oct 2018 17:35:19 +0200 Subject: Clicking on the character selects it. --- src/roster-editor/src/View/CharacterCard.elm | 7 ++++++- src/roster-editor/src/View/Controlled.elm | 2 +- src/roster-editor/src/View/GlyphManagement.elm | 2 +- src/roster-editor/src/View/PortraitSelection.elm | 2 +- src/roster-editor/src/View/WeaponSelection.elm | 2 +- 5 files changed, 10 insertions(+), 5 deletions(-) (limited to 'src/roster-editor') diff --git a/src/roster-editor/src/View/CharacterCard.elm b/src/roster-editor/src/View/CharacterCard.elm index b6575d8..96968bc 100644 --- a/src/roster-editor/src/View/CharacterCard.elm +++ b/src/roster-editor/src/View/CharacterCard.elm @@ -321,7 +321,12 @@ get_minimal_html char = (Html.Attributes.class "info-card"), (Html.Attributes.class "info-card-minimal"), (Html.Attributes.class "character-card"), - (Html.Attributes.class "character-card-minimal") + (Html.Attributes.class "character-card-minimal"), + (Html.Events.onClick + (Struct.Event.CharacterSelected + (Struct.Character.get_index char) + ) + ) ] [ (get_name char), diff --git a/src/roster-editor/src/View/Controlled.elm b/src/roster-editor/src/View/Controlled.elm index 5e703b7..0487f3c 100644 --- a/src/roster-editor/src/View/Controlled.elm +++ b/src/roster-editor/src/View/Controlled.elm @@ -26,7 +26,7 @@ get_html model = Nothing -> (Util.Html.nothing) (Just char) -> (Html.div - [(Html.Attributes.class "roster-editor-controlled")] + [(Html.Attributes.class "controlled")] [ (Html.Lazy.lazy (View.CharacterCard.get_full_html) diff --git a/src/roster-editor/src/View/GlyphManagement.elm b/src/roster-editor/src/View/GlyphManagement.elm index 2bf41f2..bcb8873 100644 --- a/src/roster-editor/src/View/GlyphManagement.elm +++ b/src/roster-editor/src/View/GlyphManagement.elm @@ -20,7 +20,7 @@ get_html model = (Html.div [ (Html.Attributes.class "selection-window"), - (Html.Attributes.class "roster-editor-glyph-management") + (Html.Attributes.class "glyph-management") ] [ (Html.text "Glyph Management") diff --git a/src/roster-editor/src/View/PortraitSelection.elm b/src/roster-editor/src/View/PortraitSelection.elm index 804e58c..f94197b 100644 --- a/src/roster-editor/src/View/PortraitSelection.elm +++ b/src/roster-editor/src/View/PortraitSelection.elm @@ -20,7 +20,7 @@ get_html model = (Html.div [ (Html.Attributes.class "selection-window"), - (Html.Attributes.class "roster-editor-portrait-selection") + (Html.Attributes.class "portrait-selection") ] [ (Html.text "Portrait Selection") diff --git a/src/roster-editor/src/View/WeaponSelection.elm b/src/roster-editor/src/View/WeaponSelection.elm index 0d15b77..8c79e3e 100644 --- a/src/roster-editor/src/View/WeaponSelection.elm +++ b/src/roster-editor/src/View/WeaponSelection.elm @@ -20,7 +20,7 @@ get_html model = (Html.div [ (Html.Attributes.class "selection-window"), - (Html.Attributes.class "roster-editor-weapon-selection") + (Html.Attributes.class "weapon-selection") ] [ (Html.text "Weapon Selection") -- cgit v1.2.3-70-g09d2