aboutsummaryrefslogtreecommitdiff
path: root/src/View/Round.elm
diff options
context:
space:
mode:
Diffstat (limited to 'src/View/Round.elm')
-rw-r--r--src/View/Round.elm14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/View/Round.elm b/src/View/Round.elm
new file mode 100644
index 0000000..81f4f8c
--- /dev/null
+++ b/src/View/Round.elm
@@ -0,0 +1,14 @@
+module View.Round
+ ( roundView
+ ) where
+
+import Model.Round (..)
+
+import View.Time (timeView)
+
+roundView : Round -> String
+roundView round =
+ let score = toString round.score
+ hits = "hit" ++ (if round.score > 1 then "s" else "")
+ duration = timeView round.duration
+ in score ++ " " ++ hits ++ " within " ++ duration