diff options
Diffstat (limited to 'src/View/Timer.elm')
-rw-r--r-- | src/View/Timer.elm | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/src/View/Timer.elm b/src/View/Timer.elm index 668bf08..13f071c 100644 --- a/src/View/Timer.elm +++ b/src/View/Timer.elm @@ -18,15 +18,20 @@ import Update.UpdateTimer (..) timerView : (Id, Timer) -> Html timerView (id, timer) = div - [ class "timer" ] - [ div - [ class "block" ] - [ text timer.name ] - , div - [ class <| "timerTime block" ++ (if timer.isRunning then " isRunning" else "") + [ class <| "timer" ++ (if timer.isRunning then " isRunning" else "") ] + [ button + [ class "name block" , onClick (Signal.send updates (UpdateTimer id ToggleRunning)) ] + [ text timer.name ] + , div + [ class <| "time block" ] [ text (timeView timer.time) ] + , button + [ class <| "remove block" + , onClick (Signal.send updates (RemoveTimer id)) + ] + [ i [ class "fa fa-fw fa-remove" ] [] ] ] timeView : Time -> String |