aboutsummaryrefslogtreecommitdiff
path: root/src/Main.elm
diff options
context:
space:
mode:
authorAkshay <[email protected]>2020-11-22 17:06:42 +0000
committerAkshay <[email protected]>2020-11-22 17:06:42 +0000
commit86bd94ec91e88f3a50a02daf051fcca316db09a5 (patch)
tree16e8bc17ffaf27b3938991b8a4b825dbfd6ad6c5 /src/Main.elm
parentdea97903678804c9b82039dddf7b3c461dfa514e (diff)
begin work on layouting and global styling
Diffstat (limited to 'src/Main.elm')
-rw-r--r--src/Main.elm23
1 files changed, 14 insertions, 9 deletions
diff --git a/src/Main.elm b/src/Main.elm
index 620ef7c..4ca4934 100644
--- a/src/Main.elm
+++ b/src/Main.elm
@@ -4,7 +4,7 @@ import Array exposing (..)
4import Base exposing (..) 4import Base exposing (..)
5import Browser 5import Browser
6import Css 6import Css
7import Css.Global exposing (global, selector) 7import Css.Global exposing (everything, global, selector)
8import Data exposing (..) 8import Data exposing (..)
9import Html 9import Html
10import Html.Styled exposing (..) 10import Html.Styled exposing (..)
@@ -217,15 +217,20 @@ currentContents model =
217 217
218view : Model -> Html Msg 218view : Model -> Html Msg
219view model = 219view model =
220 pre [] 220 div []
221 [ p [] [ text ("POS: " ++ viewProgress model) ] 221 [ div []
222 , p [] [ text ("WPM: " ++ viewWpm model) ] 222 [ viewWordLengthOptions
223 , p [] [ text ("ACC: " ++ viewAccuracy model.words) ] 223 , viewStats model
224 , viewWordLengthOptions 224 ]
225 , toPara model.words model.currentWord (currentContents model) 225 , div []
226 , styledInput [ onInput handleInputChanged, value model.inputBox ] [] 226 [ toPara model.words model.currentWord (currentContents model)
227 , styledButton [ onClick Redo ] [ text "redo" ] 227 , div []
228 [ styledInput [ onInput handleInputChanged, value model.inputBox ] []
229 , styledButton [ onClick Redo ] [ text "redo" ]
230 ]
231 ]
228 , global [ selector "li:not(:last-child)::after" [ Css.property "content" "' / '" ] ] 232 , global [ selector "li:not(:last-child)::after" [ Css.property "content" "' / '" ] ]
233 , global [ everything [ Css.fontFamily Css.monospace ] ]
229 ] 234 ]
230 235
231 236