diff --git a/index.html b/index.html index 3a11c359..9ad74006 100644 --- a/index.html +++ b/index.html @@ -4,7 +4,7 @@ --- -
@@ -43,7 +43,7 @@

Installation


Demos


-

Default timepicker. Value = ()

+

Default timepicker. Value = ()

@@ -154,7 +154,7 @@

Demos


Inside a modal with backdrop enabled, inputs disabled and with a preset value.

-
- - diff --git a/js/bootstrap-timepicker.js b/js/bootstrap-timepicker.js index c8208bbf..dfaf452c 100644 --- a/js/bootstrap-timepicker.js +++ b/js/bootstrap-timepicker.js @@ -29,6 +29,7 @@ this.template = options.template; this.appendWidgetTo = options.appendWidgetTo; this.showWidgetOnAddonClick = options.showWidgetOnAddonClick; + this.timeSeparator = options.timeSeparator; this._init(); }; @@ -242,10 +243,10 @@ templateContent; if (this.showInputs) { - hourTemplate = ''; - minuteTemplate = ''; - secondTemplate = ''; - meridianTemplate = ''; + hourTemplate = ''; + minuteTemplate = ''; + secondTemplate = ''; + meridianTemplate = ''; } else { hourTemplate = ''; minuteTemplate = ''; @@ -255,24 +256,24 @@ templateContent = ''+ ''+ - ''+ + ''+ ''+ - ''+ + ''+ (this.showSeconds ? ''+ - '' + '' : '') + (this.showMeridian ? ''+ - '' + '' : '') + ''+ ''+ ' '+ - ''+ + ''+ ' '+ (this.showSeconds ? - ''+ + ''+ '' : '') + (this.showMeridian ? @@ -281,16 +282,16 @@ : '') + ''+ ''+ - ''+ + ''+ ''+ - ''+ + ''+ (this.showSeconds ? ''+ - '' + '' : '') + (this.showMeridian ? ''+ - '' + '' : '') + ''+ '
   
'+ hourTemplate +':' + this.timeSeparator + ''+ minuteTemplate +':' + this.timeSeparator + ''+ secondTemplate +'
  
'; @@ -1089,7 +1090,8 @@ showMeridian: true, template: 'dropdown', appendWidgetTo: 'body', - showWidgetOnAddonClick: true + showWidgetOnAddonClick: true, + timeSeparator: ':' }; $.fn.timepicker.Constructor = Timepicker;