module Model.Timer ( Timer , initialTimer ) where import List import Time exposing (Time) import Model.TimerState exposing (..) type alias Timer = { creationTime : Time , name : Maybe String , initialTime : Time , currentTime : Time , state : TimerState } initialTimer : Time -> Timer initialTimer creationTime = let initialTime = 5 * 60 * 1000 in { creationTime = creationTime , name = Nothing , initialTime = initialTime , currentTime = initialTime , state = Idle }