Commit fe49666e authored by Ricardo J. Mendez's avatar Ricardo J. Mendez

Small display change: using m for minutes instead of min

Fixed outdated comment.
parent 1567f65c
......@@ -94,7 +94,7 @@
(into #{})))
(defn time-display
"Returns a display string for a number of milliseconds"
"Returns a display string for a number of seconds"
[seconds]
(letfn [(time-label [major major-label minor minor-label]
(apply str (concat [major major-label]
......@@ -102,7 +102,7 @@
(cond
(< seconds 1) "< 1s"
(< seconds 60) (str seconds "s")
(< seconds 3600) (time-label (quot seconds 60) "min" (rem seconds 60) "s")
(< seconds 86400) (time-label (quot seconds 3600) "h" (quot (rem seconds 3600) 60) "min")
(< seconds 3600) (time-label (quot seconds 60) "m" (rem seconds 60) "s")
(< seconds 86400) (time-label (quot seconds 3600) "h" (quot (rem seconds 3600) 60) "m")
:else (time-label (quot seconds 86400) "d" (quot (rem seconds 86400) 3600) "h")))
)
\ No newline at end of file
......@@ -226,7 +226,7 @@
[:tr
[:td {:class "col-sm-2"}
(time-display (:time tab))]
[:td {:class "col-sm-8"}
[:td {:class "col-sm-7"}
[:a
{:href url :target "_blank"}
(if favicon
......@@ -234,7 +234,7 @@
:width 16
:height 16}])
display]]
[:td {:class "col-sm-2"}
[:td {:class "col-sm-3"}
[:i (merge {:class "fa fa-circle" :style {:color color}})]
(time-display (quot age-ms 1000))]
]))))))
......
......@@ -59,16 +59,16 @@
1 "1s"
3 "3s"
49 "49s"
60 "1min"
61 "1min 1s"
119 "1min 59s"
120 "2min"
124 "2min 4s"
762 "12min 42s"
60 "1m"
61 "1m 1s"
119 "1m 59s"
120 "2m"
124 "2m 4s"
762 "12m 42s"
3600 "1h"
3610 "1h"
3660 "1h 1min"
8659 "2h 24min"
3660 "1h 1m"
8659 "2h 24m"
86592 "1d"
124076 "1d 10h"
248996 "2d 21h"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment