(input-time
&
{:keys [model minimum maximum] :as args :or {minimum 0 maximum 2359}})
I return the markup for an input box which will accept and validate times. Parameters - refer input-time-args above
I return the markup for an input box which will accept and validate times. Parameters - refer input-time-args above
(text->time text)
return as a time int, the contents of 'text'
return as a time int, the contents of 'text'
(time->text time)
return a string of format HH:MM for 'time'
return a string of format HH:MM for 'time'
(valid-text? text)
Return true if text passes basic time validation. Can't do to much validation because user input might not be finished. Why? On the way to entering 6:30, you must pass through the invalid state of '63'. So we only really check against the triple-extracting regular expression
Return true if text passes basic time validation. Can't do to much validation because user input might not be finished. Why? On the way to entering 6:30, you must pass through the invalid state of '63'. So we only really check against the triple-extracting regular expression
(valid-time? time)
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close