@tabworthy/components 0.10.1 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/tabworthy-components.cjs.js +1 -1
- package/dist/cjs/tabworthy-dates-calendar_2.cjs.entry.js +2 -2
- package/dist/cjs/tabworthy-times-picker.cjs.entry.js +39 -5
- package/dist/cjs/tabworthy-times.cjs.entry.js +14 -7
- package/dist/collection/components/tabworthy-modal/tabworthy-dates-modal.js +2 -2
- package/dist/collection/components/tabworthy-times/tabworthy-times.js +35 -7
- package/dist/collection/components/tabworthy-times-picker/tabworthy-times-picker.js +80 -5
- package/dist/components/{p-D0CX07Ep.js → p-CIQgnOXj.js} +1 -1
- package/dist/components/p-D_zy0B-F.js +1 -0
- package/dist/components/tabworthy-dates-modal.js +1 -1
- package/dist/components/tabworthy-dates.js +1 -1
- package/dist/components/tabworthy-times-picker.js +1 -1
- package/dist/components/tabworthy-times.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/tabworthy-components.js +1 -1
- package/dist/esm/tabworthy-dates-calendar_2.entry.js +2 -2
- package/dist/esm/tabworthy-times-picker.entry.js +39 -5
- package/dist/esm/tabworthy-times.entry.js +14 -7
- package/dist/tabworthy-components/p-8eada3fd.entry.js +1 -0
- package/dist/tabworthy-components/p-dc960590.entry.js +1 -0
- package/dist/tabworthy-components/{p-42e77ac7.entry.js → p-f1688c61.entry.js} +1 -1
- package/dist/tabworthy-components/tabworthy-components.esm.js +1 -1
- package/dist/types/components/tabworthy-times/tabworthy-times.d.ts +2 -0
- package/dist/types/components/tabworthy-times-picker/tabworthy-times-picker.d.ts +11 -0
- package/dist/types/components.d.ts +27 -0
- package/package.json +1 -1
- package/dist/components/p-DDp2dGlo.js +0 -1
- package/dist/tabworthy-components/p-327d119d.entry.js +0 -1
- package/dist/tabworthy-components/p-a67ad7af.entry.js +0 -1
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -6,7 +6,7 @@ var appGlobals = require('./app-globals-V2Kpy_OQ.js');
|
|
|
6
6
|
const defineCustomElements = async (win, options) => {
|
|
7
7
|
if (typeof window === 'undefined') return undefined;
|
|
8
8
|
await appGlobals.globalScripts();
|
|
9
|
-
return index.bootstrapLazy([["tabworthy-times-picker.cjs",[[2,"tabworthy-times-picker",{"hours":[1026],"minutes":[1026],"useTwelveHourFormat":[4,"use-twelve-hour-format"],"labels":[16],"labelsSrOnly":[4,"labels-sr-only"],"disabled":[4],"elementClassName":[1,"element-class-name"],"internalHours":[32],"internalMinutes":[32],"period":[32]},null,{"hours":[{"watchHours":0}],"minutes":[{"watchMinutes":0}]}]]],["tabworthy-dates-calendar_2.cjs",[[262,"tabworthy-dates-calendar",{"clearButtonContent":[1,"clear-button-content"],"closeButtonContent":[1,"close-button-content"],"disabled":[4],"modalIsOpen":[4,"modal-is-open"],"disableDate":[16],"elementClassName":[1,"element-class-name"],"firstDayOfWeek":[2,"first-day-of-week"],"range":[4],"labels":[16],"locale":[1],"nextMonthButtonContent":[1,"next-month-button-content"],"nextYearButtonContent":[1,"next-year-button-content"],"previousMonthButtonContent":[1,"previous-month-button-content"],"previousYearButtonContent":[1,"previous-year-button-content"],"minDate":[1,"min-date"],"maxDate":[1,"max-date"],"inline":[4],"showClearButton":[4,"show-clear-button"],"showCloseButton":[4,"show-close-button"],"showMonthStepper":[4,"show-month-stepper"],"showTodayButton":[4,"show-today-button"],"showYearStepper":[4,"show-year-stepper"],"showKeyboardHint":[4,"show-keyboard-hint"],"showHiddenTitle":[4,"show-hidden-title"],"startDate":[1,"start-date"],"todayButtonContent":[1,"today-button-content"],"value":[1040],"currentDate":[32],"hoveredDate":[32],"weekdays":[32]},null,{"modalIsOpen":[{"watchModalIsOpen":0}],"firstDayOfWeek":[{"watchFirstDayOfWeek":0}],"locale":[{"watchLocale":0}],"range":[{"watchRange":0}],"startDate":[{"watchStartDate":0}],"value":[{"watchValue":0}]}],[257,"tabworthy-dates-modal",{"label":[1],"inline":[4],"placement":[1],"offset":[16],"appendTo":[1,"append-to"],"closing":[32],"showing":[32],"positioned":[32],"open":[64],"close":[64],"getState":[64],"setTriggerElement":[64],"updatePosition":[64]},[[10,"click","handleClick"]],{"showing":[{"watchShowing":0}]}]]],["tabworthy-times.cjs",[[2,"tabworthy-times",{"id":[513],"value":[1025],"range":[4],"label":[1],"placeholder":[1],"locale":[1],"disabled":[4],"minDate":[1,"min-date"],"maxDate":[1,"max-date"],"startDate":[1,"start-date"],"referenceDate":[1,"reference-date"],"useTwelveHourFormat":[4,"use-twelve-hour-format"],"timesLabels":[16],"datesCalendarLabels":[16],"timesPickerLabels":[16],"inline":[4],"hasError":[1028,"has-error"],"showYearStepper":[4,"show-year-stepper"],"showMonthStepper":[4,"show-month-stepper"],"showClearButton":[4,"show-clear-button"],"showCloseButton":[4,"show-close-button"],"showTodayButton":[4,"show-today-button"],"calendarButtonContent":[1,"calendar-button-content"],"disableDate":[16],"elementClassName":[1,"element-class-name"],"firstDayOfWeek":[2,"first-day-of-week"],"format":[1],"inputShouldFormat":[8,"input-should-format"],"disableFreeformInput":[4,"disable-freeform-input"],"inputClass":[1,"input-class"],"appendTo":[1,"append-to"],"internalValue":[32],"selectedDate":[32],"selectedHours":[32],"selectedMinutes":[32],"errorState":[32],"disabledState":[32],"clearValue":[64]},null,{"value":[{"watchValue":0}],"disabled":[{"watchDisabled":0}],"hasError":[{"watchHasError":0}]}]]],["tabworthy-dates.cjs",[[2,"tabworthy-dates",{"id":[513],"value":[1025],"range":[4],"label":[1],"placeholder":[1],"locale":[1],"disabled":[4],"minDate":[1,"min-date"],"maxDate":[1,"max-date"],"startDate":[1,"start-date"],"referenceDate":[1,"reference-date"],"useStrictDateParsing":[4,"use-strict-date-parsing"],"datesLabels":[16],"datesCalendarLabels":[16],"inline":[4],"hasError":[1028,"has-error"],"nextMonthButtonContent":[1,"next-month-button-content"],"nextYearButtonContent":[1,"next-year-button-content"],"showYearStepper":[4,"show-year-stepper"],"showMonthStepper":[4,"show-month-stepper"],"showClearButton":[4,"show-clear-button"],"showCloseButton":[4,"show-close-button"],"showTodayButton":[4,"show-today-button"],"inputShouldFormat":[8,"input-should-format"],"showKeyboardHint":[4,"show-keyboard-hint"],"disableDate":[16],"elementClassName":[1,"element-class-name"],"firstDayOfWeek":[2,"first-day-of-week"],"format":[1],"quickButtons":[16],"todayButtonContent":[1,"today-button-content"],"calendarButtonContent":[1,"calendar-button-content"],"showQuickButtons":[4,"show-quick-buttons"],"disableFreeformInput":[4,"disable-freeform-input"],"inputClass":[1,"input-class"],"appendTo":[1,"append-to"],"internalValue":[32],"errorState":[32],"disabledState":[32],"parseDate":[64]},null,{"disabled":[{"watchDisabled":0}],"value":[{"watchValue":0}]}]]]], options);
|
|
9
|
+
return index.bootstrapLazy([["tabworthy-times-picker.cjs",[[2,"tabworthy-times-picker",{"hours":[1026],"minutes":[1026],"seconds":[1026],"useTwelveHourFormat":[4,"use-twelve-hour-format"],"showSeconds":[4,"show-seconds"],"labels":[16],"labelsSrOnly":[4,"labels-sr-only"],"disabled":[4],"elementClassName":[1,"element-class-name"],"internalHours":[32],"internalMinutes":[32],"internalSeconds":[32],"period":[32]},null,{"hours":[{"watchHours":0}],"minutes":[{"watchMinutes":0}],"seconds":[{"watchSeconds":0}]}]]],["tabworthy-dates-calendar_2.cjs",[[262,"tabworthy-dates-calendar",{"clearButtonContent":[1,"clear-button-content"],"closeButtonContent":[1,"close-button-content"],"disabled":[4],"modalIsOpen":[4,"modal-is-open"],"disableDate":[16],"elementClassName":[1,"element-class-name"],"firstDayOfWeek":[2,"first-day-of-week"],"range":[4],"labels":[16],"locale":[1],"nextMonthButtonContent":[1,"next-month-button-content"],"nextYearButtonContent":[1,"next-year-button-content"],"previousMonthButtonContent":[1,"previous-month-button-content"],"previousYearButtonContent":[1,"previous-year-button-content"],"minDate":[1,"min-date"],"maxDate":[1,"max-date"],"inline":[4],"showClearButton":[4,"show-clear-button"],"showCloseButton":[4,"show-close-button"],"showMonthStepper":[4,"show-month-stepper"],"showTodayButton":[4,"show-today-button"],"showYearStepper":[4,"show-year-stepper"],"showKeyboardHint":[4,"show-keyboard-hint"],"showHiddenTitle":[4,"show-hidden-title"],"startDate":[1,"start-date"],"todayButtonContent":[1,"today-button-content"],"value":[1040],"currentDate":[32],"hoveredDate":[32],"weekdays":[32]},null,{"modalIsOpen":[{"watchModalIsOpen":0}],"firstDayOfWeek":[{"watchFirstDayOfWeek":0}],"locale":[{"watchLocale":0}],"range":[{"watchRange":0}],"startDate":[{"watchStartDate":0}],"value":[{"watchValue":0}]}],[257,"tabworthy-dates-modal",{"label":[1],"inline":[4],"placement":[1],"offset":[16],"appendTo":[1,"append-to"],"closing":[32],"showing":[32],"positioned":[32],"open":[64],"close":[64],"getState":[64],"setTriggerElement":[64],"updatePosition":[64]},[[10,"click","handleClick"]],{"showing":[{"watchShowing":0}]}]]],["tabworthy-times.cjs",[[2,"tabworthy-times",{"id":[513],"value":[1025],"range":[4],"label":[1],"placeholder":[1],"locale":[1],"disabled":[4],"minDate":[1,"min-date"],"maxDate":[1,"max-date"],"startDate":[1,"start-date"],"referenceDate":[1,"reference-date"],"useTwelveHourFormat":[4,"use-twelve-hour-format"],"showSeconds":[4,"show-seconds"],"timesLabels":[16],"datesCalendarLabels":[16],"timesPickerLabels":[16],"inline":[4],"hasError":[1028,"has-error"],"showYearStepper":[4,"show-year-stepper"],"showMonthStepper":[4,"show-month-stepper"],"showClearButton":[4,"show-clear-button"],"showCloseButton":[4,"show-close-button"],"showTodayButton":[4,"show-today-button"],"calendarButtonContent":[1,"calendar-button-content"],"disableDate":[16],"elementClassName":[1,"element-class-name"],"firstDayOfWeek":[2,"first-day-of-week"],"format":[1],"inputShouldFormat":[8,"input-should-format"],"disableFreeformInput":[4,"disable-freeform-input"],"inputClass":[1,"input-class"],"appendTo":[1,"append-to"],"internalValue":[32],"selectedDate":[32],"selectedHours":[32],"selectedMinutes":[32],"selectedSeconds":[32],"errorState":[32],"disabledState":[32],"clearValue":[64]},null,{"value":[{"watchValue":0}],"disabled":[{"watchDisabled":0}],"hasError":[{"watchHasError":0}]}]]],["tabworthy-dates.cjs",[[2,"tabworthy-dates",{"id":[513],"value":[1025],"range":[4],"label":[1],"placeholder":[1],"locale":[1],"disabled":[4],"minDate":[1,"min-date"],"maxDate":[1,"max-date"],"startDate":[1,"start-date"],"referenceDate":[1,"reference-date"],"useStrictDateParsing":[4,"use-strict-date-parsing"],"datesLabels":[16],"datesCalendarLabels":[16],"inline":[4],"hasError":[1028,"has-error"],"nextMonthButtonContent":[1,"next-month-button-content"],"nextYearButtonContent":[1,"next-year-button-content"],"showYearStepper":[4,"show-year-stepper"],"showMonthStepper":[4,"show-month-stepper"],"showClearButton":[4,"show-clear-button"],"showCloseButton":[4,"show-close-button"],"showTodayButton":[4,"show-today-button"],"inputShouldFormat":[8,"input-should-format"],"showKeyboardHint":[4,"show-keyboard-hint"],"disableDate":[16],"elementClassName":[1,"element-class-name"],"firstDayOfWeek":[2,"first-day-of-week"],"format":[1],"quickButtons":[16],"todayButtonContent":[1,"today-button-content"],"calendarButtonContent":[1,"calendar-button-content"],"showQuickButtons":[4,"show-quick-buttons"],"disableFreeformInput":[4,"disable-freeform-input"],"inputClass":[1,"input-class"],"appendTo":[1,"append-to"],"internalValue":[32],"errorState":[32],"disabledState":[32],"parseDate":[64]},null,{"disabled":[{"watchDisabled":0}],"value":[{"watchValue":0}]}]]]], options);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
exports.setNonce = index.setNonce;
|
|
@@ -19,7 +19,7 @@ var patchBrowser = () => {
|
|
|
19
19
|
|
|
20
20
|
patchBrowser().then(async (options) => {
|
|
21
21
|
await appGlobals.globalScripts();
|
|
22
|
-
return index.bootstrapLazy([["tabworthy-times-picker.cjs",[[2,"tabworthy-times-picker",{"hours":[1026],"minutes":[1026],"useTwelveHourFormat":[4,"use-twelve-hour-format"],"labels":[16],"labelsSrOnly":[4,"labels-sr-only"],"disabled":[4],"elementClassName":[1,"element-class-name"],"internalHours":[32],"internalMinutes":[32],"period":[32]},null,{"hours":[{"watchHours":0}],"minutes":[{"watchMinutes":0}]}]]],["tabworthy-dates-calendar_2.cjs",[[262,"tabworthy-dates-calendar",{"clearButtonContent":[1,"clear-button-content"],"closeButtonContent":[1,"close-button-content"],"disabled":[4],"modalIsOpen":[4,"modal-is-open"],"disableDate":[16],"elementClassName":[1,"element-class-name"],"firstDayOfWeek":[2,"first-day-of-week"],"range":[4],"labels":[16],"locale":[1],"nextMonthButtonContent":[1,"next-month-button-content"],"nextYearButtonContent":[1,"next-year-button-content"],"previousMonthButtonContent":[1,"previous-month-button-content"],"previousYearButtonContent":[1,"previous-year-button-content"],"minDate":[1,"min-date"],"maxDate":[1,"max-date"],"inline":[4],"showClearButton":[4,"show-clear-button"],"showCloseButton":[4,"show-close-button"],"showMonthStepper":[4,"show-month-stepper"],"showTodayButton":[4,"show-today-button"],"showYearStepper":[4,"show-year-stepper"],"showKeyboardHint":[4,"show-keyboard-hint"],"showHiddenTitle":[4,"show-hidden-title"],"startDate":[1,"start-date"],"todayButtonContent":[1,"today-button-content"],"value":[1040],"currentDate":[32],"hoveredDate":[32],"weekdays":[32]},null,{"modalIsOpen":[{"watchModalIsOpen":0}],"firstDayOfWeek":[{"watchFirstDayOfWeek":0}],"locale":[{"watchLocale":0}],"range":[{"watchRange":0}],"startDate":[{"watchStartDate":0}],"value":[{"watchValue":0}]}],[257,"tabworthy-dates-modal",{"label":[1],"inline":[4],"placement":[1],"offset":[16],"appendTo":[1,"append-to"],"closing":[32],"showing":[32],"positioned":[32],"open":[64],"close":[64],"getState":[64],"setTriggerElement":[64],"updatePosition":[64]},[[10,"click","handleClick"]],{"showing":[{"watchShowing":0}]}]]],["tabworthy-times.cjs",[[2,"tabworthy-times",{"id":[513],"value":[1025],"range":[4],"label":[1],"placeholder":[1],"locale":[1],"disabled":[4],"minDate":[1,"min-date"],"maxDate":[1,"max-date"],"startDate":[1,"start-date"],"referenceDate":[1,"reference-date"],"useTwelveHourFormat":[4,"use-twelve-hour-format"],"timesLabels":[16],"datesCalendarLabels":[16],"timesPickerLabels":[16],"inline":[4],"hasError":[1028,"has-error"],"showYearStepper":[4,"show-year-stepper"],"showMonthStepper":[4,"show-month-stepper"],"showClearButton":[4,"show-clear-button"],"showCloseButton":[4,"show-close-button"],"showTodayButton":[4,"show-today-button"],"calendarButtonContent":[1,"calendar-button-content"],"disableDate":[16],"elementClassName":[1,"element-class-name"],"firstDayOfWeek":[2,"first-day-of-week"],"format":[1],"inputShouldFormat":[8,"input-should-format"],"disableFreeformInput":[4,"disable-freeform-input"],"inputClass":[1,"input-class"],"appendTo":[1,"append-to"],"internalValue":[32],"selectedDate":[32],"selectedHours":[32],"selectedMinutes":[32],"errorState":[32],"disabledState":[32],"clearValue":[64]},null,{"value":[{"watchValue":0}],"disabled":[{"watchDisabled":0}],"hasError":[{"watchHasError":0}]}]]],["tabworthy-dates.cjs",[[2,"tabworthy-dates",{"id":[513],"value":[1025],"range":[4],"label":[1],"placeholder":[1],"locale":[1],"disabled":[4],"minDate":[1,"min-date"],"maxDate":[1,"max-date"],"startDate":[1,"start-date"],"referenceDate":[1,"reference-date"],"useStrictDateParsing":[4,"use-strict-date-parsing"],"datesLabels":[16],"datesCalendarLabels":[16],"inline":[4],"hasError":[1028,"has-error"],"nextMonthButtonContent":[1,"next-month-button-content"],"nextYearButtonContent":[1,"next-year-button-content"],"showYearStepper":[4,"show-year-stepper"],"showMonthStepper":[4,"show-month-stepper"],"showClearButton":[4,"show-clear-button"],"showCloseButton":[4,"show-close-button"],"showTodayButton":[4,"show-today-button"],"inputShouldFormat":[8,"input-should-format"],"showKeyboardHint":[4,"show-keyboard-hint"],"disableDate":[16],"elementClassName":[1,"element-class-name"],"firstDayOfWeek":[2,"first-day-of-week"],"format":[1],"quickButtons":[16],"todayButtonContent":[1,"today-button-content"],"calendarButtonContent":[1,"calendar-button-content"],"showQuickButtons":[4,"show-quick-buttons"],"disableFreeformInput":[4,"disable-freeform-input"],"inputClass":[1,"input-class"],"appendTo":[1,"append-to"],"internalValue":[32],"errorState":[32],"disabledState":[32],"parseDate":[64]},null,{"disabled":[{"watchDisabled":0}],"value":[{"watchValue":0}]}]]]], options);
|
|
22
|
+
return index.bootstrapLazy([["tabworthy-times-picker.cjs",[[2,"tabworthy-times-picker",{"hours":[1026],"minutes":[1026],"seconds":[1026],"useTwelveHourFormat":[4,"use-twelve-hour-format"],"showSeconds":[4,"show-seconds"],"labels":[16],"labelsSrOnly":[4,"labels-sr-only"],"disabled":[4],"elementClassName":[1,"element-class-name"],"internalHours":[32],"internalMinutes":[32],"internalSeconds":[32],"period":[32]},null,{"hours":[{"watchHours":0}],"minutes":[{"watchMinutes":0}],"seconds":[{"watchSeconds":0}]}]]],["tabworthy-dates-calendar_2.cjs",[[262,"tabworthy-dates-calendar",{"clearButtonContent":[1,"clear-button-content"],"closeButtonContent":[1,"close-button-content"],"disabled":[4],"modalIsOpen":[4,"modal-is-open"],"disableDate":[16],"elementClassName":[1,"element-class-name"],"firstDayOfWeek":[2,"first-day-of-week"],"range":[4],"labels":[16],"locale":[1],"nextMonthButtonContent":[1,"next-month-button-content"],"nextYearButtonContent":[1,"next-year-button-content"],"previousMonthButtonContent":[1,"previous-month-button-content"],"previousYearButtonContent":[1,"previous-year-button-content"],"minDate":[1,"min-date"],"maxDate":[1,"max-date"],"inline":[4],"showClearButton":[4,"show-clear-button"],"showCloseButton":[4,"show-close-button"],"showMonthStepper":[4,"show-month-stepper"],"showTodayButton":[4,"show-today-button"],"showYearStepper":[4,"show-year-stepper"],"showKeyboardHint":[4,"show-keyboard-hint"],"showHiddenTitle":[4,"show-hidden-title"],"startDate":[1,"start-date"],"todayButtonContent":[1,"today-button-content"],"value":[1040],"currentDate":[32],"hoveredDate":[32],"weekdays":[32]},null,{"modalIsOpen":[{"watchModalIsOpen":0}],"firstDayOfWeek":[{"watchFirstDayOfWeek":0}],"locale":[{"watchLocale":0}],"range":[{"watchRange":0}],"startDate":[{"watchStartDate":0}],"value":[{"watchValue":0}]}],[257,"tabworthy-dates-modal",{"label":[1],"inline":[4],"placement":[1],"offset":[16],"appendTo":[1,"append-to"],"closing":[32],"showing":[32],"positioned":[32],"open":[64],"close":[64],"getState":[64],"setTriggerElement":[64],"updatePosition":[64]},[[10,"click","handleClick"]],{"showing":[{"watchShowing":0}]}]]],["tabworthy-times.cjs",[[2,"tabworthy-times",{"id":[513],"value":[1025],"range":[4],"label":[1],"placeholder":[1],"locale":[1],"disabled":[4],"minDate":[1,"min-date"],"maxDate":[1,"max-date"],"startDate":[1,"start-date"],"referenceDate":[1,"reference-date"],"useTwelveHourFormat":[4,"use-twelve-hour-format"],"showSeconds":[4,"show-seconds"],"timesLabels":[16],"datesCalendarLabels":[16],"timesPickerLabels":[16],"inline":[4],"hasError":[1028,"has-error"],"showYearStepper":[4,"show-year-stepper"],"showMonthStepper":[4,"show-month-stepper"],"showClearButton":[4,"show-clear-button"],"showCloseButton":[4,"show-close-button"],"showTodayButton":[4,"show-today-button"],"calendarButtonContent":[1,"calendar-button-content"],"disableDate":[16],"elementClassName":[1,"element-class-name"],"firstDayOfWeek":[2,"first-day-of-week"],"format":[1],"inputShouldFormat":[8,"input-should-format"],"disableFreeformInput":[4,"disable-freeform-input"],"inputClass":[1,"input-class"],"appendTo":[1,"append-to"],"internalValue":[32],"selectedDate":[32],"selectedHours":[32],"selectedMinutes":[32],"selectedSeconds":[32],"errorState":[32],"disabledState":[32],"clearValue":[64]},null,{"value":[{"watchValue":0}],"disabled":[{"watchDisabled":0}],"hasError":[{"watchHasError":0}]}]]],["tabworthy-dates.cjs",[[2,"tabworthy-dates",{"id":[513],"value":[1025],"range":[4],"label":[1],"placeholder":[1],"locale":[1],"disabled":[4],"minDate":[1,"min-date"],"maxDate":[1,"max-date"],"startDate":[1,"start-date"],"referenceDate":[1,"reference-date"],"useStrictDateParsing":[4,"use-strict-date-parsing"],"datesLabels":[16],"datesCalendarLabels":[16],"inline":[4],"hasError":[1028,"has-error"],"nextMonthButtonContent":[1,"next-month-button-content"],"nextYearButtonContent":[1,"next-year-button-content"],"showYearStepper":[4,"show-year-stepper"],"showMonthStepper":[4,"show-month-stepper"],"showClearButton":[4,"show-clear-button"],"showCloseButton":[4,"show-close-button"],"showTodayButton":[4,"show-today-button"],"inputShouldFormat":[8,"input-should-format"],"showKeyboardHint":[4,"show-keyboard-hint"],"disableDate":[16],"elementClassName":[1,"element-class-name"],"firstDayOfWeek":[2,"first-day-of-week"],"format":[1],"quickButtons":[16],"todayButtonContent":[1,"today-button-content"],"calendarButtonContent":[1,"calendar-button-content"],"showQuickButtons":[4,"show-quick-buttons"],"disableFreeformInput":[4,"disable-freeform-input"],"inputClass":[1,"input-class"],"appendTo":[1,"append-to"],"internalValue":[32],"errorState":[32],"disabledState":[32],"parseDate":[64]},null,{"disabled":[{"watchDisabled":0}],"value":[{"watchValue":0}]}]]]], options);
|
|
23
23
|
});
|
|
24
24
|
|
|
25
25
|
exports.setNonce = index.setNonce;
|
|
@@ -2825,7 +2825,7 @@ const InclusiveDatesModal = class {
|
|
|
2825
2825
|
}
|
|
2826
2826
|
}
|
|
2827
2827
|
render() {
|
|
2828
|
-
return (index.h(index.Host, { key: '
|
|
2828
|
+
return (index.h(index.Host, { key: 'bf48e957915fbc2975d7ba2f2ca6844e2c14270e', showing: this.showing, ref: (r) => r && (this.el = r) }, !this.inline && this.showing && (index.h("div", { key: '87fd577d1289e3c6f888b614d127e729003b1fe6', part: "body", ref: (r) => {
|
|
2829
2829
|
if (r) {
|
|
2830
2830
|
this.bodyRef = r;
|
|
2831
2831
|
// Setup portal and create popper when ref is set
|
|
@@ -2842,7 +2842,7 @@ const InclusiveDatesModal = class {
|
|
|
2842
2842
|
});
|
|
2843
2843
|
}
|
|
2844
2844
|
}
|
|
2845
|
-
}, style: { visibility: this.positioned ? "visible" : "hidden" }, onKeyDown: this.onKeyDown, role: "dialog", tabindex: -1, "aria-hidden": !this.showing, "aria-label": this.label, "aria-modal": this.showing }, index.h("focus-trap", { key: '
|
|
2845
|
+
}, style: { visibility: this.positioned ? "visible" : "hidden" }, onKeyDown: this.onKeyDown, role: "dialog", tabindex: -1, "aria-hidden": !this.showing, "aria-label": this.label, "aria-modal": this.showing }, index.h("focus-trap", { key: '5f994a20957137ce8e95d17191cb9436ae4c2315' }, index.h("div", { key: '6ab5e6990d04e9e6b0905971b52b33410608759e', part: "content" }, index.h("slot", { key: '9d99fbd7f47ee014277fe4493f86a90b3929103c' }))))), this.inline && (index.h("div", { key: 'fc1766214d1727cc2865a17da6661f06bd67429f', part: "content" }, index.h("slot", { key: '28d41dba4356ce3bd0aa7db06943296de4372695' })))));
|
|
2846
2846
|
}
|
|
2847
2847
|
get hostElement() { return index.getElement(this); }
|
|
2848
2848
|
static get watchers() { return {
|
|
@@ -5,13 +5,16 @@ var index = require('./index-B1s0tI-Z.js');
|
|
|
5
5
|
const defaultLabels = {
|
|
6
6
|
hours: "Hours",
|
|
7
7
|
minutes: "Minutes",
|
|
8
|
+
seconds: "Seconds",
|
|
8
9
|
am: "AM",
|
|
9
10
|
pm: "PM",
|
|
10
11
|
timePicker: "Time picker",
|
|
11
12
|
incrementHours: "Increment hours",
|
|
12
13
|
decrementHours: "Decrement hours",
|
|
13
14
|
incrementMinutes: "Increment minutes",
|
|
14
|
-
decrementMinutes: "Decrement minutes"
|
|
15
|
+
decrementMinutes: "Decrement minutes",
|
|
16
|
+
incrementSeconds: "Increment seconds",
|
|
17
|
+
decrementSeconds: "Decrement seconds"
|
|
15
18
|
};
|
|
16
19
|
const TabworthyTimesPicker = class {
|
|
17
20
|
constructor(hostRef) {
|
|
@@ -20,7 +23,10 @@ const TabworthyTimesPicker = class {
|
|
|
20
23
|
// Current time value (24-hour format)
|
|
21
24
|
this.hours = 12;
|
|
22
25
|
this.minutes = 0;
|
|
26
|
+
this.seconds = 0;
|
|
23
27
|
this.useTwelveHourFormat = false;
|
|
28
|
+
// Show seconds control
|
|
29
|
+
this.showSeconds = false;
|
|
24
30
|
// Labels for accessibility and i18n
|
|
25
31
|
this.labels = defaultLabels;
|
|
26
32
|
// Hide labels visually but keep them for screen readers
|
|
@@ -29,6 +35,7 @@ const TabworthyTimesPicker = class {
|
|
|
29
35
|
this.elementClassName = "tabworthy-times-picker";
|
|
30
36
|
this.internalHours = this.hours;
|
|
31
37
|
this.internalMinutes = this.minutes;
|
|
38
|
+
this.internalSeconds = this.seconds;
|
|
32
39
|
this.period = this.hours >= 12 ? "PM" : "AM";
|
|
33
40
|
this.handleHourChange = (e) => {
|
|
34
41
|
const value = parseInt(e.target.value, 10);
|
|
@@ -106,6 +113,19 @@ const TabworthyTimesPicker = class {
|
|
|
106
113
|
this.internalMinutes === 0 ? 59 : this.internalMinutes - 1;
|
|
107
114
|
this.emitTimeChange();
|
|
108
115
|
};
|
|
116
|
+
this.handleSecondChange = (e) => {
|
|
117
|
+
this.internalSeconds = parseInt(e.target.value, 10);
|
|
118
|
+
this.emitTimeChange();
|
|
119
|
+
};
|
|
120
|
+
this.handleSecondIncrement = () => {
|
|
121
|
+
this.internalSeconds = (this.internalSeconds + 1) % 60;
|
|
122
|
+
this.emitTimeChange();
|
|
123
|
+
};
|
|
124
|
+
this.handleSecondDecrement = () => {
|
|
125
|
+
this.internalSeconds =
|
|
126
|
+
this.internalSeconds === 0 ? 59 : this.internalSeconds - 1;
|
|
127
|
+
this.emitTimeChange();
|
|
128
|
+
};
|
|
109
129
|
}
|
|
110
130
|
watchHours(newValue) {
|
|
111
131
|
this.internalHours = newValue;
|
|
@@ -114,9 +134,13 @@ const TabworthyTimesPicker = class {
|
|
|
114
134
|
watchMinutes(newValue) {
|
|
115
135
|
this.internalMinutes = newValue;
|
|
116
136
|
}
|
|
137
|
+
watchSeconds(newValue) {
|
|
138
|
+
this.internalSeconds = newValue;
|
|
139
|
+
}
|
|
117
140
|
componentWillLoad() {
|
|
118
141
|
this.internalHours = this.hours;
|
|
119
142
|
this.internalMinutes = this.minutes;
|
|
143
|
+
this.internalSeconds = this.seconds;
|
|
120
144
|
this.period = this.hours >= 12 ? "PM" : "AM";
|
|
121
145
|
}
|
|
122
146
|
getDisplayHours() {
|
|
@@ -145,6 +169,7 @@ const TabworthyTimesPicker = class {
|
|
|
145
169
|
this.timeChanged.emit({
|
|
146
170
|
hours: this.get24HourValue(),
|
|
147
171
|
minutes: this.internalMinutes,
|
|
172
|
+
seconds: this.showSeconds ? this.internalSeconds : undefined,
|
|
148
173
|
period: this.useTwelveHourFormat ? this.period : undefined
|
|
149
174
|
});
|
|
150
175
|
}
|
|
@@ -155,16 +180,22 @@ const TabworthyTimesPicker = class {
|
|
|
155
180
|
const displayHours = this.getDisplayHours();
|
|
156
181
|
const maxHours = this.useTwelveHourFormat ? 12 : 23;
|
|
157
182
|
const minHours = this.useTwelveHourFormat ? 1 : 0;
|
|
158
|
-
return (index.h(index.Host, { key: '
|
|
183
|
+
return (index.h(index.Host, { key: 'be075e309d41904bf237c3a4b31b063ac4d1a7e0', class: this.elementClassName, "aria-label": this.labels.timePicker }, index.h("div", { key: '39d3a55428ad6f567490aa9a55ab94766de39e7f', class: `${this.elementClassName}__container` }, index.h("div", { key: '5efcc6b13a4473d5d889689d205128b328ae9417', class: `${this.elementClassName}__field` }, index.h("label", { key: 'f2e760229dd54d2265539e924dc133eda7f53fb8', htmlFor: `${this.elementClassName}-hours`, class: {
|
|
159
184
|
[`${this.elementClassName}__label`]: true,
|
|
160
185
|
[`${this.elementClassName}__label--sr-only`]: this.labelsSrOnly
|
|
161
|
-
} }, this.labels.hours), index.h("div", { key: '
|
|
186
|
+
} }, this.labels.hours), index.h("div", { key: 'a1f92371d923c50adb423d8fa36d84fe632fcdcb', class: `${this.elementClassName}__control` }, index.h("button", { key: 'ce1a13d5d97f664cd5a7ef9ac144cb2d7a76b0e3', type: "button", class: `${this.elementClassName}__button ${this.elementClassName}__button--increment`, onClick: this.handleHourIncrement, disabled: this.disabled, "aria-label": this.labels.incrementHours }, index.h("svg", { key: '9f4f27bc5e3ecc1da7f9520c5a67bef79b546229', fill: "none", height: "16", "stroke-linecap": "round", "stroke-linejoin": "round", "stroke-width": "2", stroke: "currentColor", viewBox: "0 0 24 24", width: "16" }, index.h("polyline", { key: '2537a3c151f846b52f427bff20145dd581b2db7b', points: "18 15 12 9 6 15" }))), index.h("input", { key: 'dbe3c7e05bf44f2942f38e397fa8abcd5ec9a080', id: `${this.elementClassName}-hours`, type: "number", class: `${this.elementClassName}__input`, value: this.padZero(displayHours), min: minHours, max: maxHours, onInput: this.handleHourChange, disabled: this.disabled, "aria-label": this.labels.hours }), index.h("button", { key: '69e610902e8324369a57f5943699f019533f9b0a', type: "button", class: `${this.elementClassName}__button ${this.elementClassName}__button--decrement`, onClick: this.handleHourDecrement, disabled: this.disabled, "aria-label": this.labels.decrementHours }, index.h("svg", { key: 'fd3a91c8c82abb4ba948c1735a4d6b1ab9879452', fill: "none", height: "16", "stroke-linecap": "round", "stroke-linejoin": "round", "stroke-width": "2", stroke: "currentColor", viewBox: "0 0 24 24", width: "16" }, index.h("polyline", { key: 'f2fb31860bc57fe95b78e0331d4dce611976f1cc', points: "6 9 12 15 18 9" }))))), index.h("div", { key: '5f488705145ebbaaba10f7e0370dd614e5ac9c91', class: `${this.elementClassName}__separator` }, ":"), index.h("div", { key: 'c886bc72ad9098a1015d97cdb64d609d10b4b7c0', class: `${this.elementClassName}__field` }, index.h("label", { key: '3590285320f4ee5403e41cceb964aa2440ee3caa', htmlFor: `${this.elementClassName}-minutes`, class: {
|
|
162
187
|
[`${this.elementClassName}__label`]: true,
|
|
163
188
|
[`${this.elementClassName}__label--sr-only`]: this.labelsSrOnly
|
|
164
|
-
} }, this.labels.minutes), index.h("div", { key: '
|
|
189
|
+
} }, this.labels.minutes), index.h("div", { key: '0e4271bc5e35b9664ef599af056c997a0b09c64f', class: `${this.elementClassName}__control` }, index.h("button", { key: '29d095829fb141f2f2495a5cbc4bb7f28f39b54b', type: "button", class: `${this.elementClassName}__button ${this.elementClassName}__button--increment`, onClick: this.handleMinuteIncrement, disabled: this.disabled, "aria-label": this.labels.incrementMinutes }, index.h("svg", { key: '683cb78389935a9a68e59d875df60dc168ca5a4b', fill: "none", height: "16", "stroke-linecap": "round", "stroke-linejoin": "round", "stroke-width": "2", stroke: "currentColor", viewBox: "0 0 24 24", width: "16" }, index.h("polyline", { key: '21084833e0479ace54ee23b2b9a39276752d6467', points: "18 15 12 9 6 15" }))), index.h("input", { key: '07d608da760816c37ae394fe5798ad25ca0c17db', id: `${this.elementClassName}-minutes`, type: "number", class: `${this.elementClassName}__input`, value: this.padZero(this.internalMinutes), min: 0, max: 59, onInput: this.handleMinuteChange, disabled: this.disabled, "aria-label": this.labels.minutes }), index.h("button", { key: '07aee6f5f9b6cfe23fa50ae9ad2319f627c9efe2', type: "button", class: `${this.elementClassName}__button ${this.elementClassName}__button--decrement`, onClick: this.handleMinuteDecrement, disabled: this.disabled, "aria-label": this.labels.decrementMinutes }, index.h("svg", { key: '3e284e93b451ab57b0c4e0a29b8c3953f5a79033', fill: "none", height: "16", "stroke-linecap": "round", "stroke-linejoin": "round", "stroke-width": "2", stroke: "currentColor", viewBox: "0 0 24 24", width: "16" }, index.h("polyline", { key: '589c1da5150f4b3def68b9dcb14f2ee56b9022e2', points: "6 9 12 15 18 9" }))))), this.showSeconds && [
|
|
190
|
+
index.h("div", { key: '717844859ad07d5912fdd0b386151aeb40ccbf94', class: `${this.elementClassName}__separator` }, ":"),
|
|
191
|
+
index.h("div", { key: 'a27907f31a3d71abb9f7c5bce411569ddd22594d', class: `${this.elementClassName}__field` }, index.h("label", { key: 'c6312aeccdfe835aa0bd02bc7078b4a30aa70921', htmlFor: `${this.elementClassName}-seconds`, class: {
|
|
192
|
+
[`${this.elementClassName}__label`]: true,
|
|
193
|
+
[`${this.elementClassName}__label--sr-only`]: this.labelsSrOnly
|
|
194
|
+
} }, this.labels.seconds), index.h("div", { key: 'c347d3847e999a900cba2410dbc2c5711d01d746', class: `${this.elementClassName}__control` }, index.h("button", { key: 'b0862893f9d99e6ef7da0cfc02f6a6e1f0bc4443', type: "button", class: `${this.elementClassName}__button ${this.elementClassName}__button--increment`, onClick: this.handleSecondIncrement, disabled: this.disabled, "aria-label": this.labels.incrementSeconds }, index.h("svg", { key: 'b4032699911ed9e589c015b4c3b9d31766b53d38', fill: "none", height: "16", "stroke-linecap": "round", "stroke-linejoin": "round", "stroke-width": "2", stroke: "currentColor", viewBox: "0 0 24 24", width: "16" }, index.h("polyline", { key: '5bfbeefa5ea9d4901a7bc08de5bf01578fbf6cec', points: "18 15 12 9 6 15" }))), index.h("input", { key: '3c7e4e5b4f7a162e9ce9efa815d1c180ff5395d2', id: `${this.elementClassName}-seconds`, type: "number", class: `${this.elementClassName}__input`, value: this.padZero(this.internalSeconds), min: 0, max: 59, onInput: this.handleSecondChange, disabled: this.disabled, "aria-label": this.labels.seconds }), index.h("button", { key: '6f5a37921ef128033fe8241b63903739f0ddc245', type: "button", class: `${this.elementClassName}__button ${this.elementClassName}__button--decrement`, onClick: this.handleSecondDecrement, disabled: this.disabled, "aria-label": this.labels.decrementSeconds }, index.h("svg", { key: '5c24cc5df194f53889ec353a5527c239df94a380', fill: "none", height: "16", "stroke-linecap": "round", "stroke-linejoin": "round", "stroke-width": "2", stroke: "currentColor", viewBox: "0 0 24 24", width: "16" }, index.h("polyline", { key: '090946e452acf54e8bc491094573368160f55cbe', points: "6 9 12 15 18 9" })))))
|
|
195
|
+
], this.useTwelveHourFormat && (index.h("div", { key: '4bbd646f21dc099efc94e86b05ce35e22c28ee16', class: `${this.elementClassName}__period` }, index.h("button", { key: '3b41814b8fe32ffe3ef898fe816cc027440c6c2b', type: "button", class: {
|
|
165
196
|
[`${this.elementClassName}__period-button`]: true,
|
|
166
197
|
[`${this.elementClassName}__period-button--active`]: this.period === "AM"
|
|
167
|
-
}, onClick: () => this.handlePeriodChange("AM"), disabled: this.disabled, "aria-label": this.labels.am, "aria-pressed": this.period === "AM" }, this.labels.am), index.h("button", { key: '
|
|
198
|
+
}, onClick: () => this.handlePeriodChange("AM"), disabled: this.disabled, "aria-label": this.labels.am, "aria-pressed": this.period === "AM" }, this.labels.am), index.h("button", { key: 'fd9052000876c0516e13ab701a4e5164a7d72112', type: "button", class: {
|
|
168
199
|
[`${this.elementClassName}__period-button`]: true,
|
|
169
200
|
[`${this.elementClassName}__period-button--active`]: this.period === "PM"
|
|
170
201
|
}, onClick: () => this.handlePeriodChange("PM"), disabled: this.disabled, "aria-label": this.labels.pm, "aria-pressed": this.period === "PM" }, this.labels.pm))))));
|
|
@@ -176,6 +207,9 @@ const TabworthyTimesPicker = class {
|
|
|
176
207
|
}],
|
|
177
208
|
"minutes": [{
|
|
178
209
|
"watchMinutes": 0
|
|
210
|
+
}],
|
|
211
|
+
"seconds": [{
|
|
212
|
+
"watchSeconds": 0
|
|
179
213
|
}]
|
|
180
214
|
}; }
|
|
181
215
|
};
|
|
@@ -39,6 +39,8 @@ const InclusiveTimes = class {
|
|
|
39
39
|
this.referenceDate = utils.getISODateString(new Date());
|
|
40
40
|
// Use 12-hour format with AM/PM
|
|
41
41
|
this.useTwelveHourFormat = true;
|
|
42
|
+
// Show seconds picker control
|
|
43
|
+
this.showSeconds = false;
|
|
42
44
|
// Labels used for internal translations
|
|
43
45
|
this.timesLabels = defaultLabels;
|
|
44
46
|
this.inline = false;
|
|
@@ -66,8 +68,9 @@ const InclusiveTimes = class {
|
|
|
66
68
|
this.inputShouldFormat = true;
|
|
67
69
|
this.disableFreeformInput = false;
|
|
68
70
|
this.inputClass = "";
|
|
69
|
-
this.selectedHours =
|
|
70
|
-
this.selectedMinutes =
|
|
71
|
+
this.selectedHours = new Date().getHours();
|
|
72
|
+
this.selectedMinutes = new Date().getMinutes();
|
|
73
|
+
this.selectedSeconds = new Date().getSeconds();
|
|
71
74
|
this.errorState = this.hasError;
|
|
72
75
|
this.disabledState = this.disabled;
|
|
73
76
|
this.errorMessage = "";
|
|
@@ -94,6 +97,9 @@ const InclusiveTimes = class {
|
|
|
94
97
|
this.handleTimeChange = (event) => {
|
|
95
98
|
this.selectedHours = event.detail.hours;
|
|
96
99
|
this.selectedMinutes = event.detail.minutes;
|
|
100
|
+
if (event.detail.seconds !== undefined) {
|
|
101
|
+
this.selectedSeconds = event.detail.seconds;
|
|
102
|
+
}
|
|
97
103
|
// Update the value if we have a selected date
|
|
98
104
|
if (this.selectedDate) {
|
|
99
105
|
this.updateValue(this.selectedDate);
|
|
@@ -163,6 +169,7 @@ const InclusiveTimes = class {
|
|
|
163
169
|
this.selectedDate = parsed.toDate();
|
|
164
170
|
this.selectedHours = parsed.hours();
|
|
165
171
|
this.selectedMinutes = parsed.minutes();
|
|
172
|
+
this.selectedSeconds = parsed.seconds();
|
|
166
173
|
}
|
|
167
174
|
}
|
|
168
175
|
}
|
|
@@ -177,7 +184,7 @@ const InclusiveTimes = class {
|
|
|
177
184
|
const m = moment.hooks(d);
|
|
178
185
|
m.hours(this.selectedHours);
|
|
179
186
|
m.minutes(this.selectedMinutes);
|
|
180
|
-
m.seconds(
|
|
187
|
+
m.seconds(this.selectedSeconds);
|
|
181
188
|
return m.format(this.format);
|
|
182
189
|
});
|
|
183
190
|
this.internalValue = formattedDates;
|
|
@@ -189,7 +196,7 @@ const InclusiveTimes = class {
|
|
|
189
196
|
const m = moment.hooks(date);
|
|
190
197
|
m.hours(this.selectedHours);
|
|
191
198
|
m.minutes(this.selectedMinutes);
|
|
192
|
-
m.seconds(
|
|
199
|
+
m.seconds(this.selectedSeconds);
|
|
193
200
|
const formatted = m.format(this.format);
|
|
194
201
|
this.internalValue = formatted;
|
|
195
202
|
this.value = formatted;
|
|
@@ -239,10 +246,10 @@ const InclusiveTimes = class {
|
|
|
239
246
|
}
|
|
240
247
|
render() {
|
|
241
248
|
var _a;
|
|
242
|
-
return (index.h(index.Host, { key: '
|
|
249
|
+
return (index.h(index.Host, { key: '347e952540e649e53bf13dadfd156f3c9a31b4d2', class: this.elementClassName, "has-error": this.errorState, disabled: this.disabledState }, index.h("label", { key: '3c516fa313feaaabc837e53264c7b10989199f6c', htmlFor: `${this.id}-input`, class: this.getClassName("label") }, this.label), index.h("div", { key: 'edc0f1a6e627273fdd6cae27810d97a2b6763f76', class: this.getClassName("input-container"), ref: (r) => (this.inputContainerRef = r) }, index.h("input", { key: '14a3ed21097915739c2db94e6ede2dbb09f09945', id: `${this.id}-input`, ref: (r) => (this.inputRef = r), type: "text", class: {
|
|
243
250
|
[this.getClassName("input")]: true,
|
|
244
251
|
[this.inputClass]: !!this.inputClass
|
|
245
|
-
}, placeholder: this.placeholder, disabled: this.disabledState || this.disableFreeformInput, value: (_a = this.internalValue) === null || _a === void 0 ? void 0 : _a.toString(), onBlur: this.handleInputBlur, onChange: this.handleInputChange, "aria-describedby": this.errorState ? `${this.id}-error` : undefined, "aria-invalid": this.errorState }), !this.inline && (index.h("button", { key: '
|
|
252
|
+
}, placeholder: this.placeholder, disabled: this.disabledState || this.disableFreeformInput, value: (_a = this.internalValue) === null || _a === void 0 ? void 0 : _a.toString(), onBlur: this.handleInputBlur, onChange: this.handleInputChange, "aria-describedby": this.errorState ? `${this.id}-error` : undefined, "aria-invalid": this.errorState }), !this.inline && (index.h("button", { key: '0a02d0b3e851476d421408bcf622af4c71a4e9b5', type: "button", onClick: this.handleCalendarButtonClick, class: this.getClassName("calendar-button"), disabled: this.disabledState }, this.calendarButtonContent ? (index.h("span", { innerHTML: this.calendarButtonContent })) : (this.timesLabels.openCalendar)))), index.h("tabworthy-dates-modal", { key: '972b23ebef8d198da1c7b23966f5b343c53dc89b', label: this.timesLabels.calendar, ref: (el) => (this.modalRef = el), onOpened: () => {
|
|
246
253
|
if (this.pickerRef) {
|
|
247
254
|
this.pickerRef.modalIsOpen = true;
|
|
248
255
|
}
|
|
@@ -250,7 +257,7 @@ const InclusiveTimes = class {
|
|
|
250
257
|
if (this.pickerRef) {
|
|
251
258
|
this.pickerRef.modalIsOpen = false;
|
|
252
259
|
}
|
|
253
|
-
}, inline: this.inline, appendTo: this.appendTo }, index.h("div", { key: '
|
|
260
|
+
}, inline: this.inline, appendTo: this.appendTo }, index.h("div", { key: '7bab739450039dfb34b638a5882d2334e18e7ee9', class: this.getClassName("picker-container") }, index.h("tabworthy-dates-calendar", { key: '169dd2b5b134d40613547c5633f1ba7aafa79e5a', range: this.range, locale: this.locale, onSelectDate: (event) => this.handlePickerSelection(event.detail), onChangeMonth: (event) => this.handleChangedMonths(event.detail), onChangeYear: (event) => this.handleYearChange(event.detail), onRequestClose: () => { var _a; return (_a = this.modalRef) === null || _a === void 0 ? void 0 : _a.close(); }, labels: this.datesCalendarLabels, ref: (el) => (this.pickerRef = el), startDate: this.startDate, firstDayOfWeek: this.firstDayOfWeek, showHiddenTitle: true, disabled: this.disabledState, showMonthStepper: this.showMonthStepper, showYearStepper: this.showYearStepper, showClearButton: this.showClearButton, showCloseButton: this.showCloseButton, showTodayButton: this.showTodayButton, disableDate: this.disableDate, minDate: this.minDate, maxDate: this.maxDate, inline: this.inline, value: this.value ? this.toDate(this.value) : undefined }, index.h("div", { key: '20555b87d63d4d9b5ba360345b5a8ce3910bb71a', slot: "after-calendar", class: this.getClassName("time-section") }, index.h("hr", { key: 'ccea06aa5b2b149aa77739e495cb71eda5d9a14e', class: this.getClassName("divider") }), index.h("tabworthy-times-picker", { key: '87a3aca5a0f09413fb7b4fb8dd4242f18d5365d7', hours: this.selectedHours, minutes: this.selectedMinutes, seconds: this.selectedSeconds, showSeconds: this.showSeconds, useTwelveHourFormat: this.useTwelveHourFormat, disabled: this.disabledState, onTimeChanged: this.handleTimeChange, labels: this.timesPickerLabels }))))), this.errorState && (index.h("div", { key: 'd45d1adde84b72bbc8d166f4d087f0fcf732ef99', class: this.getClassName("input-error"), id: this.id ? `${this.id}-error` : undefined, role: "status" }, this.errorMessage))));
|
|
254
261
|
}
|
|
255
262
|
get el() { return index.getElement(this); }
|
|
256
263
|
static get watchers() { return {
|
|
@@ -190,7 +190,7 @@ export class InclusiveDatesModal {
|
|
|
190
190
|
}
|
|
191
191
|
}
|
|
192
192
|
render() {
|
|
193
|
-
return (h(Host, { key: '
|
|
193
|
+
return (h(Host, { key: 'bf48e957915fbc2975d7ba2f2ca6844e2c14270e', showing: this.showing, ref: (r) => r && (this.el = r) }, !this.inline && this.showing && (h("div", { key: '87fd577d1289e3c6f888b614d127e729003b1fe6', part: "body", ref: (r) => {
|
|
194
194
|
if (r) {
|
|
195
195
|
this.bodyRef = r;
|
|
196
196
|
// Setup portal and create popper when ref is set
|
|
@@ -207,7 +207,7 @@ export class InclusiveDatesModal {
|
|
|
207
207
|
});
|
|
208
208
|
}
|
|
209
209
|
}
|
|
210
|
-
}, style: { visibility: this.positioned ? "visible" : "hidden" }, onKeyDown: this.onKeyDown, role: "dialog", tabindex: -1, "aria-hidden": !this.showing, "aria-label": this.label, "aria-modal": this.showing }, h("focus-trap", { key: '
|
|
210
|
+
}, style: { visibility: this.positioned ? "visible" : "hidden" }, onKeyDown: this.onKeyDown, role: "dialog", tabindex: -1, "aria-hidden": !this.showing, "aria-label": this.label, "aria-modal": this.showing }, h("focus-trap", { key: '5f994a20957137ce8e95d17191cb9436ae4c2315' }, h("div", { key: '6ab5e6990d04e9e6b0905971b52b33410608759e', part: "content" }, h("slot", { key: '9d99fbd7f47ee014277fe4493f86a90b3929103c' }))))), this.inline && (h("div", { key: 'fc1766214d1727cc2865a17da6661f06bd67429f', part: "content" }, h("slot", { key: '28d41dba4356ce3bd0aa7db06943296de4372695' })))));
|
|
211
211
|
}
|
|
212
212
|
static get is() { return "tabworthy-dates-modal"; }
|
|
213
213
|
static get encapsulation() { return "shadow"; }
|
|
@@ -32,6 +32,8 @@ export class InclusiveTimes {
|
|
|
32
32
|
this.referenceDate = getISODateString(new Date());
|
|
33
33
|
// Use 12-hour format with AM/PM
|
|
34
34
|
this.useTwelveHourFormat = true;
|
|
35
|
+
// Show seconds picker control
|
|
36
|
+
this.showSeconds = false;
|
|
35
37
|
// Labels used for internal translations
|
|
36
38
|
this.timesLabels = defaultLabels;
|
|
37
39
|
this.inline = false;
|
|
@@ -59,8 +61,9 @@ export class InclusiveTimes {
|
|
|
59
61
|
this.inputShouldFormat = true;
|
|
60
62
|
this.disableFreeformInput = false;
|
|
61
63
|
this.inputClass = "";
|
|
62
|
-
this.selectedHours =
|
|
63
|
-
this.selectedMinutes =
|
|
64
|
+
this.selectedHours = new Date().getHours();
|
|
65
|
+
this.selectedMinutes = new Date().getMinutes();
|
|
66
|
+
this.selectedSeconds = new Date().getSeconds();
|
|
64
67
|
this.errorState = this.hasError;
|
|
65
68
|
this.disabledState = this.disabled;
|
|
66
69
|
this.errorMessage = "";
|
|
@@ -87,6 +90,9 @@ export class InclusiveTimes {
|
|
|
87
90
|
this.handleTimeChange = (event) => {
|
|
88
91
|
this.selectedHours = event.detail.hours;
|
|
89
92
|
this.selectedMinutes = event.detail.minutes;
|
|
93
|
+
if (event.detail.seconds !== undefined) {
|
|
94
|
+
this.selectedSeconds = event.detail.seconds;
|
|
95
|
+
}
|
|
90
96
|
// Update the value if we have a selected date
|
|
91
97
|
if (this.selectedDate) {
|
|
92
98
|
this.updateValue(this.selectedDate);
|
|
@@ -156,6 +162,7 @@ export class InclusiveTimes {
|
|
|
156
162
|
this.selectedDate = parsed.toDate();
|
|
157
163
|
this.selectedHours = parsed.hours();
|
|
158
164
|
this.selectedMinutes = parsed.minutes();
|
|
165
|
+
this.selectedSeconds = parsed.seconds();
|
|
159
166
|
}
|
|
160
167
|
}
|
|
161
168
|
}
|
|
@@ -170,7 +177,7 @@ export class InclusiveTimes {
|
|
|
170
177
|
const m = moment(d);
|
|
171
178
|
m.hours(this.selectedHours);
|
|
172
179
|
m.minutes(this.selectedMinutes);
|
|
173
|
-
m.seconds(
|
|
180
|
+
m.seconds(this.selectedSeconds);
|
|
174
181
|
return m.format(this.format);
|
|
175
182
|
});
|
|
176
183
|
this.internalValue = formattedDates;
|
|
@@ -182,7 +189,7 @@ export class InclusiveTimes {
|
|
|
182
189
|
const m = moment(date);
|
|
183
190
|
m.hours(this.selectedHours);
|
|
184
191
|
m.minutes(this.selectedMinutes);
|
|
185
|
-
m.seconds(
|
|
192
|
+
m.seconds(this.selectedSeconds);
|
|
186
193
|
const formatted = m.format(this.format);
|
|
187
194
|
this.internalValue = formatted;
|
|
188
195
|
this.value = formatted;
|
|
@@ -232,10 +239,10 @@ export class InclusiveTimes {
|
|
|
232
239
|
}
|
|
233
240
|
render() {
|
|
234
241
|
var _a;
|
|
235
|
-
return (h(Host, { key: '
|
|
242
|
+
return (h(Host, { key: '347e952540e649e53bf13dadfd156f3c9a31b4d2', class: this.elementClassName, "has-error": this.errorState, disabled: this.disabledState }, h("label", { key: '3c516fa313feaaabc837e53264c7b10989199f6c', htmlFor: `${this.id}-input`, class: this.getClassName("label") }, this.label), h("div", { key: 'edc0f1a6e627273fdd6cae27810d97a2b6763f76', class: this.getClassName("input-container"), ref: (r) => (this.inputContainerRef = r) }, h("input", { key: '14a3ed21097915739c2db94e6ede2dbb09f09945', id: `${this.id}-input`, ref: (r) => (this.inputRef = r), type: "text", class: {
|
|
236
243
|
[this.getClassName("input")]: true,
|
|
237
244
|
[this.inputClass]: !!this.inputClass
|
|
238
|
-
}, placeholder: this.placeholder, disabled: this.disabledState || this.disableFreeformInput, value: (_a = this.internalValue) === null || _a === void 0 ? void 0 : _a.toString(), onBlur: this.handleInputBlur, onChange: this.handleInputChange, "aria-describedby": this.errorState ? `${this.id}-error` : undefined, "aria-invalid": this.errorState }), !this.inline && (h("button", { key: '
|
|
245
|
+
}, placeholder: this.placeholder, disabled: this.disabledState || this.disableFreeformInput, value: (_a = this.internalValue) === null || _a === void 0 ? void 0 : _a.toString(), onBlur: this.handleInputBlur, onChange: this.handleInputChange, "aria-describedby": this.errorState ? `${this.id}-error` : undefined, "aria-invalid": this.errorState }), !this.inline && (h("button", { key: '0a02d0b3e851476d421408bcf622af4c71a4e9b5', type: "button", onClick: this.handleCalendarButtonClick, class: this.getClassName("calendar-button"), disabled: this.disabledState }, this.calendarButtonContent ? (h("span", { innerHTML: this.calendarButtonContent })) : (this.timesLabels.openCalendar)))), h("tabworthy-dates-modal", { key: '972b23ebef8d198da1c7b23966f5b343c53dc89b', label: this.timesLabels.calendar, ref: (el) => (this.modalRef = el), onOpened: () => {
|
|
239
246
|
if (this.pickerRef) {
|
|
240
247
|
this.pickerRef.modalIsOpen = true;
|
|
241
248
|
}
|
|
@@ -243,7 +250,7 @@ export class InclusiveTimes {
|
|
|
243
250
|
if (this.pickerRef) {
|
|
244
251
|
this.pickerRef.modalIsOpen = false;
|
|
245
252
|
}
|
|
246
|
-
}, inline: this.inline, appendTo: this.appendTo }, h("div", { key: '
|
|
253
|
+
}, inline: this.inline, appendTo: this.appendTo }, h("div", { key: '7bab739450039dfb34b638a5882d2334e18e7ee9', class: this.getClassName("picker-container") }, h("tabworthy-dates-calendar", { key: '169dd2b5b134d40613547c5633f1ba7aafa79e5a', range: this.range, locale: this.locale, onSelectDate: (event) => this.handlePickerSelection(event.detail), onChangeMonth: (event) => this.handleChangedMonths(event.detail), onChangeYear: (event) => this.handleYearChange(event.detail), onRequestClose: () => { var _a; return (_a = this.modalRef) === null || _a === void 0 ? void 0 : _a.close(); }, labels: this.datesCalendarLabels, ref: (el) => (this.pickerRef = el), startDate: this.startDate, firstDayOfWeek: this.firstDayOfWeek, showHiddenTitle: true, disabled: this.disabledState, showMonthStepper: this.showMonthStepper, showYearStepper: this.showYearStepper, showClearButton: this.showClearButton, showCloseButton: this.showCloseButton, showTodayButton: this.showTodayButton, disableDate: this.disableDate, minDate: this.minDate, maxDate: this.maxDate, inline: this.inline, value: this.value ? this.toDate(this.value) : undefined }, h("div", { key: '20555b87d63d4d9b5ba360345b5a8ce3910bb71a', slot: "after-calendar", class: this.getClassName("time-section") }, h("hr", { key: 'ccea06aa5b2b149aa77739e495cb71eda5d9a14e', class: this.getClassName("divider") }), h("tabworthy-times-picker", { key: '87a3aca5a0f09413fb7b4fb8dd4242f18d5365d7', hours: this.selectedHours, minutes: this.selectedMinutes, seconds: this.selectedSeconds, showSeconds: this.showSeconds, useTwelveHourFormat: this.useTwelveHourFormat, disabled: this.disabledState, onTimeChanged: this.handleTimeChange, labels: this.timesPickerLabels }))))), this.errorState && (h("div", { key: 'd45d1adde84b72bbc8d166f4d087f0fcf732ef99', class: this.getClassName("input-error"), id: this.id ? `${this.id}-error` : undefined, role: "status" }, this.errorMessage))));
|
|
247
254
|
}
|
|
248
255
|
static get is() { return "tabworthy-times"; }
|
|
249
256
|
static get encapsulation() { return "scoped"; }
|
|
@@ -485,6 +492,26 @@ export class InclusiveTimes {
|
|
|
485
492
|
"attribute": "use-twelve-hour-format",
|
|
486
493
|
"defaultValue": "true"
|
|
487
494
|
},
|
|
495
|
+
"showSeconds": {
|
|
496
|
+
"type": "boolean",
|
|
497
|
+
"mutable": false,
|
|
498
|
+
"complexType": {
|
|
499
|
+
"original": "boolean",
|
|
500
|
+
"resolved": "boolean",
|
|
501
|
+
"references": {}
|
|
502
|
+
},
|
|
503
|
+
"required": false,
|
|
504
|
+
"optional": false,
|
|
505
|
+
"docs": {
|
|
506
|
+
"tags": [],
|
|
507
|
+
"text": ""
|
|
508
|
+
},
|
|
509
|
+
"getter": false,
|
|
510
|
+
"setter": false,
|
|
511
|
+
"reflect": false,
|
|
512
|
+
"attribute": "show-seconds",
|
|
513
|
+
"defaultValue": "false"
|
|
514
|
+
},
|
|
488
515
|
"timesLabels": {
|
|
489
516
|
"type": "unknown",
|
|
490
517
|
"mutable": false,
|
|
@@ -891,6 +918,7 @@ export class InclusiveTimes {
|
|
|
891
918
|
"selectedDate": {},
|
|
892
919
|
"selectedHours": {},
|
|
893
920
|
"selectedMinutes": {},
|
|
921
|
+
"selectedSeconds": {},
|
|
894
922
|
"errorState": {},
|
|
895
923
|
"disabledState": {}
|
|
896
924
|
};
|