Extend from $.fn.spinner.defaults. Override defaults with $.fn.timespinner.defaults.
The timespinner is created based on spinner. It is same as numberspinner but display the time value. The timespinner allows the user to increase or decrease the time by clicking small spinner buttons on the right of component.
Create timespinner from markup.
Create timespinner using javascript.
The properties extend from spinner, below is the added properties for timespinner.
Name | Type | Description | Default |
---|---|---|---|
separator | string | The separator between hour and minute and second. | : |
showSeconds | boolean | Defines if to show the second information. | false |
highlight | number | The field to highlight initially, 0 = hours, 1 = minutes, бн | 0 |
The events extend from spinner.
The methods extend from spinner, below is the overridden methods for timespinner.
Name | Parameter | Description |
---|---|---|
options | none | Return the options object. |
setValue | value |
Set the timespinner value.
Code example: $('#ss').timespinner('setValue', '17:45'); // set timespinner value var v = $('#ss').timespinner('getValue'); // get timespinner value alert(v); |
getHours | none | Get the current hour value. |
getMinutes | none | Get the current minute value. |
getSeconds | none | Get the current second value. |