@exhaustive-ui/core 3.0.0-alpha.1 → 22.0.0-alpha.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/fesm2022/exhaustive-ui-core-api.mjs +4 -4
- package/fesm2022/exhaustive-ui-core-api.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-autocomplete.mjs +432 -376
- package/fesm2022/exhaustive-ui-core-autocomplete.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-carousel.mjs +240 -206
- package/fesm2022/exhaustive-ui-core-carousel.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-confirmdialog.mjs +79 -71
- package/fesm2022/exhaustive-ui-core-confirmdialog.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-confirmpopup.mjs +109 -97
- package/fesm2022/exhaustive-ui-core-confirmpopup.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-contextmenu.mjs +301 -323
- package/fesm2022/exhaustive-ui-core-contextmenu.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-datepicker.mjs +943 -793
- package/fesm2022/exhaustive-ui-core-datepicker.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-dialog.mjs +167 -127
- package/fesm2022/exhaustive-ui-core-dialog.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-fileupload.mjs +485 -401
- package/fesm2022/exhaustive-ui-core-fileupload.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-angledoubledown.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-angledoubledown.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-angledoubleleft.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-angledoubleleft.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-angledoubleright.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-angledoubleright.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-angledoubleup.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-angledoubleup.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-angledown.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-angledown.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-angleleft.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-angleleft.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-angleright.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-angleright.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-angleup.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-angleup.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-arrowdown.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-arrowdown.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-arrowdownleft.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-arrowdownleft.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-arrowdownright.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-arrowdownright.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-arrowleft.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-arrowleft.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-arrowright.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-arrowright.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-arrowup.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-arrowup.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-ban.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-ban.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-bars.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-bars.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-blank.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-blank.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-calendar.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-calendar.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-caretleft.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-caretleft.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-caretright.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-caretright.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-check.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-check.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-chevrondown.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-chevrondown.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-chevronleft.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-chevronleft.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-chevronright.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-chevronright.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-chevronup.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-chevronup.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-exclamationtriangle.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-exclamationtriangle.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-eye.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-eye.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-eyeslash.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-eyeslash.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-filter.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-filter.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-filterfill.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-filterfill.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-filterslash.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-filterslash.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-home.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-home.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-infocircle.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-infocircle.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-minus.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-minus.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-pencil.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-pencil.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-plus.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-plus.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-refresh.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-refresh.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-search.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-search.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-searchminus.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-searchminus.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-searchplus.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-searchplus.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-sortalt.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-sortalt.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-sortamountdown.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-sortamountdown.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-sortamountupalt.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-sortamountupalt.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-spinner.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-spinner.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-star.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-star.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-starfill.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-starfill.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-thlarge.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-thlarge.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-times.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-times.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-timescircle.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-timescircle.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-trash.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-trash.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-undo.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-undo.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-upload.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-upload.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-windowmaximize.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-windowmaximize.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-icons-windowminimize.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-icons-windowminimize.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-inplace.mjs +4 -4
- package/fesm2022/exhaustive-ui-core-inplace.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-listbox.mjs +303 -259
- package/fesm2022/exhaustive-ui-core-listbox.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-megamenu.mjs +6 -6
- package/fesm2022/exhaustive-ui-core-megamenu.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-menubar.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-menubar.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-motion.mjs +2 -2
- package/fesm2022/exhaustive-ui-core-motion.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-multiselect.mjs +421 -333
- package/fesm2022/exhaustive-ui-core-multiselect.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-panelmenu.mjs +4 -4
- package/fesm2022/exhaustive-ui-core-panelmenu.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-picklist.mjs +426 -346
- package/fesm2022/exhaustive-ui-core-picklist.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-select.mjs +391 -337
- package/fesm2022/exhaustive-ui-core-select.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-table.mjs +337 -293
- package/fesm2022/exhaustive-ui-core-table.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-tieredmenu.mjs +315 -325
- package/fesm2022/exhaustive-ui-core-tieredmenu.mjs.map +1 -1
- package/fesm2022/exhaustive-ui-core-treeselect.mjs +11 -7
- package/fesm2022/exhaustive-ui-core-treeselect.mjs.map +1 -1
- package/package.json +11 -11
- package/schematics/migrations.json +5 -5
- package/schematics/utils/versions.json +8 -8
|
@@ -3285,7 +3285,7 @@ class DatePicker extends BaseInput {
|
|
|
3285
3285
|
}
|
|
3286
3286
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.2.1", ngImport: i0, type: DatePicker, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
3287
3287
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.2.1", type: DatePicker, isStandalone: true, selector: "p-datePicker, p-datepicker, p-date-picker", inputs: { iconDisplay: { classPropertyName: "iconDisplay", publicName: "iconDisplay", isSignal: true, isRequired: false, transformFunction: null }, inputStyle: { classPropertyName: "inputStyle", publicName: "inputStyle", isSignal: true, isRequired: false, transformFunction: null }, inputId: { classPropertyName: "inputId", publicName: "inputId", isSignal: true, isRequired: false, transformFunction: null }, inputStyleClass: { classPropertyName: "inputStyleClass", publicName: "inputStyleClass", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelledBy: { classPropertyName: "ariaLabelledBy", publicName: "ariaLabelledBy", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, iconAriaLabel: { classPropertyName: "iconAriaLabel", publicName: "iconAriaLabel", isSignal: true, isRequired: false, transformFunction: null }, dateFormat: { classPropertyName: "dateFormat", publicName: "dateFormat", isSignal: true, isRequired: false, transformFunction: null }, multipleSeparator: { classPropertyName: "multipleSeparator", publicName: "multipleSeparator", isSignal: true, isRequired: false, transformFunction: null }, rangeSeparator: { classPropertyName: "rangeSeparator", publicName: "rangeSeparator", isSignal: true, isRequired: false, transformFunction: null }, inline: { classPropertyName: "inline", publicName: "inline", isSignal: true, isRequired: false, transformFunction: null }, showOtherMonths: { classPropertyName: "showOtherMonths", publicName: "showOtherMonths", isSignal: true, isRequired: false, transformFunction: null }, selectOtherMonths: { classPropertyName: "selectOtherMonths", publicName: "selectOtherMonths", isSignal: true, isRequired: false, transformFunction: null }, showIcon: { classPropertyName: "showIcon", publicName: "showIcon", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, readonlyInput: { classPropertyName: "readonlyInput", publicName: "readonlyInput", isSignal: true, isRequired: false, transformFunction: null }, shortYearCutoff: { classPropertyName: "shortYearCutoff", publicName: "shortYearCutoff", isSignal: true, isRequired: false, transformFunction: null }, hourFormat: { classPropertyName: "hourFormat", publicName: "hourFormat", isSignal: true, isRequired: false, transformFunction: null }, timeOnly: { classPropertyName: "timeOnly", publicName: "timeOnly", isSignal: true, isRequired: false, transformFunction: null }, stepHour: { classPropertyName: "stepHour", publicName: "stepHour", isSignal: true, isRequired: false, transformFunction: null }, stepMinute: { classPropertyName: "stepMinute", publicName: "stepMinute", isSignal: true, isRequired: false, transformFunction: null }, stepSecond: { classPropertyName: "stepSecond", publicName: "stepSecond", isSignal: true, isRequired: false, transformFunction: null }, showSeconds: { classPropertyName: "showSeconds", publicName: "showSeconds", isSignal: true, isRequired: false, transformFunction: null }, showOnFocus: { classPropertyName: "showOnFocus", publicName: "showOnFocus", isSignal: true, isRequired: false, transformFunction: null }, showWeek: { classPropertyName: "showWeek", publicName: "showWeek", isSignal: true, isRequired: false, transformFunction: null }, startWeekFromFirstDayOfYear: { classPropertyName: "startWeekFromFirstDayOfYear", publicName: "startWeekFromFirstDayOfYear", isSignal: true, isRequired: false, transformFunction: null }, showClear: { classPropertyName: "showClear", publicName: "showClear", isSignal: true, isRequired: false, transformFunction: null }, dataType: { classPropertyName: "dataType", publicName: "dataType", isSignal: true, isRequired: false, transformFunction: null }, selectionMode: { classPropertyName: "selectionMode", publicName: "selectionMode", isSignal: true, isRequired: false, transformFunction: null }, maxDateCount: { classPropertyName: "maxDateCount", publicName: "maxDateCount", isSignal: true, isRequired: false, transformFunction: null }, showButtonBar: { classPropertyName: "showButtonBar", publicName: "showButtonBar", isSignal: true, isRequired: false, transformFunction: null }, todayButtonStyleClass: { classPropertyName: "todayButtonStyleClass", publicName: "todayButtonStyleClass", isSignal: true, isRequired: false, transformFunction: null }, clearButtonStyleClass: { classPropertyName: "clearButtonStyleClass", publicName: "clearButtonStyleClass", isSignal: true, isRequired: false, transformFunction: null }, autofocus: { classPropertyName: "autofocus", publicName: "autofocus", isSignal: true, isRequired: false, transformFunction: null }, autoZIndex: { classPropertyName: "autoZIndex", publicName: "autoZIndex", isSignal: true, isRequired: false, transformFunction: null }, baseZIndex: { classPropertyName: "baseZIndex", publicName: "baseZIndex", isSignal: true, isRequired: false, transformFunction: null }, panelStyleClass: { classPropertyName: "panelStyleClass", publicName: "panelStyleClass", isSignal: true, isRequired: false, transformFunction: null }, panelStyle: { classPropertyName: "panelStyle", publicName: "panelStyle", isSignal: true, isRequired: false, transformFunction: null }, keepInvalid: { classPropertyName: "keepInvalid", publicName: "keepInvalid", isSignal: true, isRequired: false, transformFunction: null }, hideOnDateTimeSelect: { classPropertyName: "hideOnDateTimeSelect", publicName: "hideOnDateTimeSelect", isSignal: true, isRequired: false, transformFunction: null }, touchUI: { classPropertyName: "touchUI", publicName: "touchUI", isSignal: true, isRequired: false, transformFunction: null }, timeSeparator: { classPropertyName: "timeSeparator", publicName: "timeSeparator", isSignal: true, isRequired: false, transformFunction: null }, focusTrap: { classPropertyName: "focusTrap", publicName: "focusTrap", isSignal: true, isRequired: false, transformFunction: null }, tabindex: { classPropertyName: "tabindex", publicName: "tabindex", isSignal: true, isRequired: false, transformFunction: null }, minDate: { classPropertyName: "minDate", publicName: "minDate", isSignal: true, isRequired: false, transformFunction: null }, maxDate: { classPropertyName: "maxDate", publicName: "maxDate", isSignal: true, isRequired: false, transformFunction: null }, disabledDates: { classPropertyName: "disabledDates", publicName: "disabledDates", isSignal: true, isRequired: false, transformFunction: null }, disabledDays: { classPropertyName: "disabledDays", publicName: "disabledDays", isSignal: true, isRequired: false, transformFunction: null }, showTime: { classPropertyName: "showTime", publicName: "showTime", isSignal: true, isRequired: false, transformFunction: null }, responsiveOptions: { classPropertyName: "responsiveOptions", publicName: "responsiveOptions", isSignal: true, isRequired: false, transformFunction: null }, numberOfMonths: { classPropertyName: "numberOfMonths", publicName: "numberOfMonths", isSignal: true, isRequired: false, transformFunction: null }, firstDayOfWeek: { classPropertyName: "firstDayOfWeek", publicName: "firstDayOfWeek", isSignal: true, isRequired: false, transformFunction: null }, view: { classPropertyName: "view", publicName: "view", isSignal: true, isRequired: false, transformFunction: null }, defaultDate: { classPropertyName: "defaultDate", publicName: "defaultDate", isSignal: true, isRequired: false, transformFunction: null }, appendTo: { classPropertyName: "appendTo", publicName: "appendTo", isSignal: true, isRequired: false, transformFunction: null }, motionOptions: { classPropertyName: "motionOptions", publicName: "motionOptions", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onFocus: "onFocus", onBlur: "onBlur", onClose: "onClose", onSelect: "onSelect", onClear: "onClear", onInput: "onInput", onTodayClick: "onTodayClick", onClearClick: "onClearClick", onMonthChange: "onMonthChange", onYearChange: "onYearChange", onClickOutside: "onClickOutside", onShow: "onShow" }, host: { properties: { "class": "cx('root')", "style": "sx('root')" } }, providers: [DATEPICKER_VALUE_ACCESSOR, DatePickerStyle, { provide: DATEPICKER_INSTANCE, useExisting: DatePicker }, { provide: PARENT_INSTANCE, useExisting: DatePicker }], queries: [{ propertyName: "dateTemplate", first: true, predicate: ["date"], isSignal: true }, { propertyName: "headerTemplate", first: true, predicate: ["header"], isSignal: true }, { propertyName: "footerTemplate", first: true, predicate: ["footer"], isSignal: true }, { propertyName: "disabledDateTemplate", first: true, predicate: ["disabledDate"], isSignal: true }, { propertyName: "decadeTemplate", first: true, predicate: ["decade"], isSignal: true }, { propertyName: "previousIconTemplate", first: true, predicate: ["previousicon"], isSignal: true }, { propertyName: "nextIconTemplate", first: true, predicate: ["nexticon"], isSignal: true }, { propertyName: "triggerIconTemplate", first: true, predicate: ["triggericon"], isSignal: true }, { propertyName: "clearIconTemplate", first: true, predicate: ["clearicon"], isSignal: true }, { propertyName: "decrementIconTemplate", first: true, predicate: ["decrementicon"], isSignal: true }, { propertyName: "incrementIconTemplate", first: true, predicate: ["incrementicon"], isSignal: true }, { propertyName: "inputIconTemplate", first: true, predicate: ["inputicon"], isSignal: true }, { propertyName: "buttonBarTemplate", first: true, predicate: ["buttonbar"], isSignal: true }, { propertyName: "templates", predicate: PrimeTemplate, isSignal: true }], viewQueries: [{ propertyName: "inputfieldViewChild", first: true, predicate: ["inputfield"], descendants: true, isSignal: true }, { propertyName: "contentViewChild", first: true, predicate: ["contentWrapper"], descendants: true, isSignal: true }], usesInheritance: true, hostDirectives: [{ directive: i1.Bind }], ngImport: i0, template: `
|
|
3288
|
-
|
|
3288
|
+
@if (!inline()) {
|
|
3289
3289
|
<input
|
|
3290
3290
|
#inputfield
|
|
3291
3291
|
pInputText
|
|
@@ -3325,429 +3325,504 @@ class DatePicker extends BaseInput {
|
|
|
3325
3325
|
[pt]="ptm('pcInputText')"
|
|
3326
3326
|
[unstyled]="unstyled()"
|
|
3327
3327
|
/>
|
|
3328
|
-
|
|
3329
|
-
|
|
3330
|
-
|
|
3331
|
-
|
|
3332
|
-
|
|
3333
|
-
|
|
3334
|
-
|
|
3335
|
-
|
|
3336
|
-
|
|
3337
|
-
|
|
3338
|
-
|
|
3339
|
-
|
|
3340
|
-
|
|
3341
|
-
|
|
3342
|
-
|
|
3343
|
-
|
|
3344
|
-
|
|
3345
|
-
|
|
3346
|
-
|
|
3347
|
-
|
|
3348
|
-
|
|
3349
|
-
|
|
3350
|
-
|
|
3351
|
-
|
|
3352
|
-
|
|
3353
|
-
|
|
3328
|
+
@if (showClear() && !$disabled() && inputfieldViewChild()?.nativeElement?.value) {
|
|
3329
|
+
@if (!clearIconTemplate() && !_clearIconTemplate()) {
|
|
3330
|
+
<svg data-p-icon="times" [class]="cx('clearIcon')" [pBind]="ptm('inputIcon')" (click)="clear()" />
|
|
3331
|
+
}
|
|
3332
|
+
@if (clearIconTemplate() || _clearIconTemplate()) {
|
|
3333
|
+
<span [class]="cx('clearIcon')" [pBind]="ptm('inputIcon')" (click)="clear()">
|
|
3334
|
+
<ng-template *ngTemplateOutlet="clearIconTemplate() || _clearIconTemplate()"></ng-template>
|
|
3335
|
+
</span>
|
|
3336
|
+
}
|
|
3337
|
+
}
|
|
3338
|
+
@if (showIcon() && iconDisplay() === 'button') {
|
|
3339
|
+
<button
|
|
3340
|
+
type="button"
|
|
3341
|
+
[attr.aria-label]="iconButtonAriaLabel"
|
|
3342
|
+
aria-haspopup="dialog"
|
|
3343
|
+
[attr.aria-expanded]="overlayVisible() ?? false"
|
|
3344
|
+
[attr.aria-controls]="overlayVisible() ? panelId : null"
|
|
3345
|
+
(click)="onButtonClick($event, inputfield)"
|
|
3346
|
+
[class]="cx('dropdown')"
|
|
3347
|
+
[disabled]="$disabled()"
|
|
3348
|
+
tabindex="0"
|
|
3349
|
+
[pBind]="ptm('dropdown')"
|
|
3350
|
+
>
|
|
3351
|
+
@if (icon()) {
|
|
3352
|
+
<span [ngClass]="icon()" [pBind]="ptm('dropdownIcon')"></span>
|
|
3353
|
+
}
|
|
3354
|
+
@if (!icon()) {
|
|
3355
|
+
@if (!triggerIconTemplate() && !_triggerIconTemplate()) {
|
|
3356
|
+
<svg data-p-icon="calendar" [pBind]="ptm('dropdownIcon')" />
|
|
3357
|
+
}
|
|
3358
|
+
<ng-template *ngTemplateOutlet="triggerIconTemplate() || _triggerIconTemplate()"></ng-template>
|
|
3359
|
+
}
|
|
3360
|
+
</button>
|
|
3361
|
+
}
|
|
3362
|
+
@if (iconDisplay() === 'input' && showIcon()) {
|
|
3354
3363
|
<span [class]="cx('inputIconContainer')" [pBind]="ptm('inputIconContainer')" [attr.data-p]="inputIconDataP">
|
|
3355
|
-
|
|
3364
|
+
@if (!inputIconTemplate() && !_inputIconTemplate()) {
|
|
3365
|
+
<svg data-p-icon="calendar" (click)="onButtonClick($event)" [class]="cx('inputIcon')" [pBind]="ptm('inputIcon')" />
|
|
3366
|
+
}
|
|
3356
3367
|
|
|
3357
3368
|
<ng-container *ngTemplateOutlet="inputIconTemplate() || _inputIconTemplate(); context: { clickCallBack: onButtonClick.bind(this) }"></ng-container>
|
|
3358
3369
|
</span>
|
|
3359
|
-
|
|
3360
|
-
|
|
3361
|
-
|
|
3362
|
-
|
|
3363
|
-
|
|
3364
|
-
|
|
3365
|
-
|
|
3366
|
-
|
|
3367
|
-
|
|
3368
|
-
|
|
3369
|
-
|
|
3370
|
-
|
|
3371
|
-
|
|
3372
|
-
|
|
3373
|
-
|
|
3374
|
-
|
|
3375
|
-
|
|
3376
|
-
|
|
3377
|
-
|
|
3378
|
-
|
|
3379
|
-
|
|
3380
|
-
|
|
3381
|
-
|
|
3382
|
-
|
|
3383
|
-
|
|
3384
|
-
|
|
3385
|
-
|
|
3386
|
-
|
|
3370
|
+
}
|
|
3371
|
+
}
|
|
3372
|
+
@if (inline() || overlayVisible() || overlay()) {
|
|
3373
|
+
<p-motion [visible]="inline() || overlayVisible()" name="p-anchored-overlay" [appear]="!inline()" [options]="computedMotionOptions()" (onBeforeEnter)="onOverlayBeforeEnter($event)" (onAfterLeave)="onOverlayAfterLeave($event)">
|
|
3374
|
+
<div
|
|
3375
|
+
#contentWrapper
|
|
3376
|
+
[attr.id]="panelId"
|
|
3377
|
+
[ngStyle]="panelStyle()"
|
|
3378
|
+
[class]="cn(cx('panel'), panelStyleClass())"
|
|
3379
|
+
[attr.aria-label]="getTranslation('chooseDate')"
|
|
3380
|
+
[attr.role]="inline() ? null : 'dialog'"
|
|
3381
|
+
[attr.aria-modal]="inline() ? null : 'true'"
|
|
3382
|
+
(click)="onOverlayClick($event)"
|
|
3383
|
+
[pBind]="ptm('panel')"
|
|
3384
|
+
>
|
|
3385
|
+
<ng-content select="p-header"></ng-content>
|
|
3386
|
+
<ng-container *ngTemplateOutlet="headerTemplate() || _headerTemplate()"></ng-container>
|
|
3387
|
+
@if (!timeOnly()) {
|
|
3388
|
+
<div [class]="cx('calendarContainer')" [pBind]="ptm('calendarContainer')">
|
|
3389
|
+
@for (month of months(); track $index; let i = $index) {
|
|
3390
|
+
<div [class]="cx('calendar')" [pBind]="ptm('calendar')">
|
|
3391
|
+
<div [class]="cx('header')" [pBind]="ptm('header')">
|
|
3392
|
+
<p-button
|
|
3393
|
+
rounded
|
|
3394
|
+
variant="text"
|
|
3395
|
+
severity="secondary"
|
|
3396
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3397
|
+
[styleClass]="cx('pcPrevButton')"
|
|
3398
|
+
(onClick)="onPrevButtonClick($event)"
|
|
3399
|
+
[ngStyle]="{ visibility: i === 0 ? 'visible' : 'hidden' }"
|
|
3400
|
+
type="button"
|
|
3401
|
+
[ariaLabel]="prevIconAriaLabel"
|
|
3402
|
+
[pt]="ptm('pcPrevButton')"
|
|
3403
|
+
[attr.data-pc-group-section]="'navigator'"
|
|
3404
|
+
>
|
|
3405
|
+
<ng-template #icon>
|
|
3406
|
+
@if (!previousIconTemplate() && !_previousIconTemplate()) {
|
|
3407
|
+
<svg data-p-icon="chevron-left" />
|
|
3408
|
+
}
|
|
3409
|
+
@if (previousIconTemplate() || _previousIconTemplate()) {
|
|
3410
|
+
<span>
|
|
3411
|
+
<ng-template *ngTemplateOutlet="previousIconTemplate() || _previousIconTemplate()"></ng-template>
|
|
3412
|
+
</span>
|
|
3413
|
+
}
|
|
3414
|
+
</ng-template>
|
|
3415
|
+
</p-button>
|
|
3416
|
+
<div [class]="cx('title')" [pBind]="ptm('title')">
|
|
3417
|
+
@if (currentView() === 'date') {
|
|
3418
|
+
<button
|
|
3419
|
+
type="button"
|
|
3420
|
+
(click)="switchToMonthView($event)"
|
|
3421
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3422
|
+
[class]="cx('selectMonth')"
|
|
3423
|
+
[attr.disabled]="switchViewButtonDisabled() ? '' : undefined"
|
|
3424
|
+
[attr.aria-label]="this.getTranslation('chooseMonth')"
|
|
3425
|
+
pRipple
|
|
3426
|
+
[pBind]="ptm('selectMonth')"
|
|
3427
|
+
[attr.data-pc-group-section]="'navigator'"
|
|
3428
|
+
>
|
|
3429
|
+
{{ getMonthName(month.month) }}
|
|
3430
|
+
</button>
|
|
3431
|
+
}
|
|
3432
|
+
@if (currentView() !== 'year') {
|
|
3433
|
+
<button
|
|
3434
|
+
type="button"
|
|
3435
|
+
(click)="switchToYearView($event)"
|
|
3436
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3437
|
+
[class]="cx('selectYear')"
|
|
3438
|
+
[attr.disabled]="switchViewButtonDisabled() ? '' : undefined"
|
|
3439
|
+
[attr.aria-label]="getTranslation('chooseYear')"
|
|
3440
|
+
pRipple
|
|
3441
|
+
[pBind]="ptm('selectYear')"
|
|
3442
|
+
[attr.data-pc-group-section]="'navigator'"
|
|
3443
|
+
>
|
|
3444
|
+
{{ getYear(month) }}
|
|
3445
|
+
</button>
|
|
3446
|
+
}
|
|
3447
|
+
@if (currentView() === 'year') {
|
|
3448
|
+
<span [class]="cx('decade')" [pBind]="ptm('decade')">
|
|
3449
|
+
@if (!decadeTemplate() && !_decadeTemplate()) {
|
|
3450
|
+
{{ yearPickerValues()[0] }} - {{ yearPickerValues()[yearPickerValues().length - 1] }}
|
|
3451
|
+
}
|
|
3452
|
+
<ng-container *ngTemplateOutlet="decadeTemplate() || _decadeTemplate(); context: { $implicit: yearPickerValues }"></ng-container>
|
|
3453
|
+
</span>
|
|
3454
|
+
}
|
|
3455
|
+
</div>
|
|
3456
|
+
<p-button
|
|
3457
|
+
rounded
|
|
3458
|
+
variant="text"
|
|
3459
|
+
severity="secondary"
|
|
3460
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3461
|
+
[styleClass]="cx('pcNextButton')"
|
|
3462
|
+
(onClick)="onNextButtonClick($event)"
|
|
3463
|
+
[ngStyle]="{ visibility: i === months().length - 1 ? 'visible' : 'hidden' }"
|
|
3464
|
+
[ariaLabel]="nextIconAriaLabel"
|
|
3465
|
+
[pt]="ptm('pcNextButton')"
|
|
3466
|
+
[attr.data-pc-group-section]="'navigator'"
|
|
3467
|
+
>
|
|
3468
|
+
<ng-template #icon>
|
|
3469
|
+
@if (!nextIconTemplate() && !_nextIconTemplate()) {
|
|
3470
|
+
<svg data-p-icon="chevron-right" />
|
|
3471
|
+
}
|
|
3472
|
+
@if (nextIconTemplate() || _nextIconTemplate()) {
|
|
3473
|
+
<ng-template *ngTemplateOutlet="nextIconTemplate() || _nextIconTemplate()"></ng-template>
|
|
3474
|
+
}
|
|
3475
|
+
</ng-template>
|
|
3476
|
+
</p-button>
|
|
3477
|
+
</div>
|
|
3478
|
+
@if (currentView() === 'date') {
|
|
3479
|
+
<table [class]="cx('dayView')" role="grid" [pBind]="ptm('table')">
|
|
3480
|
+
<thead [pBind]="ptm('tableHeader')">
|
|
3481
|
+
<tr [pBind]="ptm('tableHeaderRow')">
|
|
3482
|
+
@if (showWeek()) {
|
|
3483
|
+
<th [class]="cx('weekHeader')" [pBind]="ptm('weekHeader')">
|
|
3484
|
+
<span [pBind]="ptm('weekHeaderLabel')">{{ getTranslation('weekHeader') }}</span>
|
|
3485
|
+
</th>
|
|
3486
|
+
}
|
|
3487
|
+
@for (weekDay of weekDays(); track $index; let begin = $first, end = $last) {
|
|
3488
|
+
<th [class]="cx('weekDayCell')" scope="col" [pBind]="ptm('weekDayCell')">
|
|
3489
|
+
<span [class]="cx('weekDay')" [pBind]="ptm('weekDay')">{{ weekDay }}</span>
|
|
3490
|
+
</th>
|
|
3491
|
+
}
|
|
3492
|
+
</tr>
|
|
3493
|
+
</thead>
|
|
3494
|
+
<tbody [pBind]="ptm('tableBody')">
|
|
3495
|
+
@for (week of month.dates; track $index; let j = $index) {
|
|
3496
|
+
<tr [pBind]="ptm('tableBodyRow')">
|
|
3497
|
+
@if (showWeek()) {
|
|
3498
|
+
<td [class]="cx('weekNumber')" [pBind]="ptm('weekNumber')">
|
|
3499
|
+
<span [class]="cx('weekLabelContainer')" [pBind]="ptm('weekLabelContainer')">
|
|
3500
|
+
{{ month.weekNumbers[j] }}
|
|
3501
|
+
</span>
|
|
3502
|
+
</td>
|
|
3503
|
+
}
|
|
3504
|
+
@for (date of week; track $index) {
|
|
3505
|
+
<td [attr.aria-label]="date.day" [class]="cx('dayCell', { date })" [pBind]="ptm('dayCell')">
|
|
3506
|
+
@if (date.otherMonth ? showOtherMonths() : true) {
|
|
3507
|
+
<span
|
|
3508
|
+
[ngClass]="dayClass(date)"
|
|
3509
|
+
(click)="onDateSelect($event, date)"
|
|
3510
|
+
draggable="false"
|
|
3511
|
+
[attr.data-date]="formatDateKey(formatDateMetaToDate(date))"
|
|
3512
|
+
(keydown)="onDateCellKeydown($event, date, i)"
|
|
3513
|
+
pRipple
|
|
3514
|
+
[pBind]="ptm('day')"
|
|
3515
|
+
>
|
|
3516
|
+
@if (!dateTemplate() && !_dateTemplate() && (date.selectable || (!disabledDateTemplate() && !_disabledDateTemplate()))) {
|
|
3517
|
+
{{ date.day }}
|
|
3518
|
+
}
|
|
3519
|
+
@if (date.selectable || (!disabledDateTemplate() && !_disabledDateTemplate())) {
|
|
3520
|
+
<ng-container *ngTemplateOutlet="dateTemplate() || _dateTemplate(); context: { $implicit: date }"></ng-container>
|
|
3521
|
+
}
|
|
3522
|
+
@if (!date.selectable) {
|
|
3523
|
+
<ng-container *ngTemplateOutlet="disabledDateTemplate() || _disabledDateTemplate(); context: { $implicit: date }"></ng-container>
|
|
3524
|
+
}
|
|
3525
|
+
</span>
|
|
3526
|
+
@if (isSelected(date)) {
|
|
3527
|
+
<div class="p-hidden-accessible" aria-live="polite">
|
|
3528
|
+
{{ date.day }}
|
|
3529
|
+
</div>
|
|
3530
|
+
}
|
|
3531
|
+
}
|
|
3532
|
+
</td>
|
|
3533
|
+
}
|
|
3534
|
+
</tr>
|
|
3535
|
+
}
|
|
3536
|
+
</tbody>
|
|
3537
|
+
</table>
|
|
3538
|
+
}
|
|
3539
|
+
</div>
|
|
3540
|
+
}
|
|
3541
|
+
</div>
|
|
3542
|
+
@if (currentView() === 'month') {
|
|
3543
|
+
<div [class]="cx('monthView')" [pBind]="ptm('monthView')">
|
|
3544
|
+
@for (m of monthPickerValues(); track $index; let i = $index) {
|
|
3545
|
+
<span (click)="onMonthSelect($event, i)" (keydown)="onMonthCellKeydown($event, i)" [class]="cx('month', { month: m, index: i })" pRipple [pBind]="ptm('month')">
|
|
3546
|
+
{{ m }}
|
|
3547
|
+
@if (isMonthSelected(i)) {
|
|
3548
|
+
<div class="p-hidden-accessible" aria-live="polite">
|
|
3549
|
+
{{ m }}
|
|
3550
|
+
</div>
|
|
3551
|
+
}
|
|
3552
|
+
</span>
|
|
3553
|
+
}
|
|
3554
|
+
</div>
|
|
3555
|
+
}
|
|
3556
|
+
@if (currentView() === 'year') {
|
|
3557
|
+
<div [class]="cx('yearView')" [pBind]="ptm('yearView')">
|
|
3558
|
+
@for (y of yearPickerValues(); track $index) {
|
|
3559
|
+
<span (click)="onYearSelect($event, y)" (keydown)="onYearCellKeydown($event, y)" [class]="cx('year', { year: y })" pRipple [pBind]="ptm('year')">
|
|
3560
|
+
{{ y }}
|
|
3561
|
+
@if (isYearSelected(y)) {
|
|
3562
|
+
<div class="p-hidden-accessible" aria-live="polite">
|
|
3563
|
+
{{ y }}
|
|
3564
|
+
</div>
|
|
3565
|
+
}
|
|
3566
|
+
</span>
|
|
3567
|
+
}
|
|
3568
|
+
</div>
|
|
3569
|
+
}
|
|
3570
|
+
}
|
|
3571
|
+
@if ((showTime() || timeOnly()) && currentView() === 'date') {
|
|
3572
|
+
<div [class]="cx('timePicker')" [pBind]="ptm('timePicker')">
|
|
3573
|
+
<div [class]="cx('hourPicker')" [pBind]="ptm('hourPicker')">
|
|
3387
3574
|
<p-button
|
|
3388
3575
|
rounded
|
|
3389
3576
|
variant="text"
|
|
3390
3577
|
severity="secondary"
|
|
3578
|
+
[styleClass]="cx('pcIncrementButton')"
|
|
3391
3579
|
(keydown)="onContainerButtonKeydown($event)"
|
|
3392
|
-
|
|
3393
|
-
(
|
|
3394
|
-
|
|
3395
|
-
|
|
3396
|
-
|
|
3397
|
-
|
|
3398
|
-
|
|
3580
|
+
(keydown.enter)="incrementHour($event)"
|
|
3581
|
+
(keydown.space)="incrementHour($event)"
|
|
3582
|
+
(mousedown)="onTimePickerElementMouseDown($event, 0, 1)"
|
|
3583
|
+
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
3584
|
+
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
3585
|
+
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
3586
|
+
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
3587
|
+
[attr.aria-label]="getTranslation('nextHour')"
|
|
3588
|
+
[pt]="ptm('pcIncrementButton')"
|
|
3589
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3399
3590
|
>
|
|
3400
3591
|
<ng-template #icon>
|
|
3401
|
-
|
|
3402
|
-
|
|
3403
|
-
|
|
3404
|
-
|
|
3592
|
+
@if (!incrementIconTemplate() && !_incrementIconTemplate()) {
|
|
3593
|
+
<svg data-p-icon="chevron-up" [pBind]="ptm('pcIncrementButton')['icon']" />
|
|
3594
|
+
}
|
|
3595
|
+
<ng-template *ngTemplateOutlet="incrementIconTemplate() || _incrementIconTemplate()"></ng-template>
|
|
3405
3596
|
</ng-template>
|
|
3406
3597
|
</p-button>
|
|
3407
|
-
<
|
|
3408
|
-
<button
|
|
3409
|
-
*ngIf="currentView() === 'date'"
|
|
3410
|
-
type="button"
|
|
3411
|
-
(click)="switchToMonthView($event)"
|
|
3412
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
3413
|
-
[class]="cx('selectMonth')"
|
|
3414
|
-
[attr.disabled]="switchViewButtonDisabled() ? '' : undefined"
|
|
3415
|
-
[attr.aria-label]="this.getTranslation('chooseMonth')"
|
|
3416
|
-
pRipple
|
|
3417
|
-
[pBind]="ptm('selectMonth')"
|
|
3418
|
-
[attr.data-pc-group-section]="'navigator'"
|
|
3419
|
-
>
|
|
3420
|
-
{{ getMonthName(month.month) }}
|
|
3421
|
-
</button>
|
|
3422
|
-
<button
|
|
3423
|
-
*ngIf="currentView() !== 'year'"
|
|
3424
|
-
type="button"
|
|
3425
|
-
(click)="switchToYearView($event)"
|
|
3426
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
3427
|
-
[class]="cx('selectYear')"
|
|
3428
|
-
[attr.disabled]="switchViewButtonDisabled() ? '' : undefined"
|
|
3429
|
-
[attr.aria-label]="getTranslation('chooseYear')"
|
|
3430
|
-
pRipple
|
|
3431
|
-
[pBind]="ptm('selectYear')"
|
|
3432
|
-
[attr.data-pc-group-section]="'navigator'"
|
|
3433
|
-
>
|
|
3434
|
-
{{ getYear(month) }}
|
|
3435
|
-
</button>
|
|
3436
|
-
<span [class]="cx('decade')" *ngIf="currentView() === 'year'" [pBind]="ptm('decade')">
|
|
3437
|
-
<ng-container *ngIf="!decadeTemplate() && !_decadeTemplate()">{{ yearPickerValues()[0] }} - {{ yearPickerValues()[yearPickerValues().length - 1] }}</ng-container>
|
|
3438
|
-
<ng-container *ngTemplateOutlet="decadeTemplate() || _decadeTemplate(); context: { $implicit: yearPickerValues }"></ng-container>
|
|
3439
|
-
</span>
|
|
3440
|
-
</div>
|
|
3598
|
+
<span [pBind]="ptm('hour')">{{ currentHour() < 10 ? '0' : '' }}{{ currentHour() }}</span>
|
|
3441
3599
|
<p-button
|
|
3442
3600
|
rounded
|
|
3443
3601
|
variant="text"
|
|
3444
3602
|
severity="secondary"
|
|
3603
|
+
[styleClass]="cx('pcDecrementButton')"
|
|
3445
3604
|
(keydown)="onContainerButtonKeydown($event)"
|
|
3446
|
-
|
|
3447
|
-
(
|
|
3448
|
-
|
|
3449
|
-
|
|
3450
|
-
|
|
3451
|
-
|
|
3605
|
+
(keydown.enter)="decrementHour($event)"
|
|
3606
|
+
(keydown.space)="decrementHour($event)"
|
|
3607
|
+
(mousedown)="onTimePickerElementMouseDown($event, 0, -1)"
|
|
3608
|
+
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
3609
|
+
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
3610
|
+
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
3611
|
+
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
3612
|
+
[attr.aria-label]="getTranslation('prevHour')"
|
|
3613
|
+
[pt]="ptm('pcDecrementButton')"
|
|
3614
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3452
3615
|
>
|
|
3453
3616
|
<ng-template #icon>
|
|
3454
|
-
|
|
3455
|
-
|
|
3456
|
-
|
|
3457
|
-
|
|
3617
|
+
@if (!decrementIconTemplate() && !_decrementIconTemplate()) {
|
|
3618
|
+
<svg data-p-icon="chevron-down" [pBind]="ptm('pcDecrementButton')['icon']" />
|
|
3619
|
+
}
|
|
3620
|
+
<ng-template *ngTemplateOutlet="decrementIconTemplate() || _decrementIconTemplate()"></ng-template>
|
|
3458
3621
|
</ng-template>
|
|
3459
3622
|
</p-button>
|
|
3460
3623
|
</div>
|
|
3461
|
-
<
|
|
3462
|
-
<
|
|
3463
|
-
<tr [pBind]="ptm('tableHeaderRow')">
|
|
3464
|
-
<th *ngIf="showWeek()" [class]="cx('weekHeader')" [pBind]="ptm('weekHeader')">
|
|
3465
|
-
<span [pBind]="ptm('weekHeaderLabel')">{{ getTranslation('weekHeader') }}</span>
|
|
3466
|
-
</th>
|
|
3467
|
-
<th [class]="cx('weekDayCell')" scope="col" *ngFor="let weekDay of weekDays(); let begin = first; let end = last" [pBind]="ptm('weekDayCell')">
|
|
3468
|
-
<span [class]="cx('weekDay')" [pBind]="ptm('weekDay')">{{ weekDay }}</span>
|
|
3469
|
-
</th>
|
|
3470
|
-
</tr>
|
|
3471
|
-
</thead>
|
|
3472
|
-
<tbody [pBind]="ptm('tableBody')">
|
|
3473
|
-
<tr *ngFor="let week of month.dates; let j = index" [pBind]="ptm('tableBodyRow')">
|
|
3474
|
-
<td *ngIf="showWeek()" [class]="cx('weekNumber')" [pBind]="ptm('weekNumber')">
|
|
3475
|
-
<span [class]="cx('weekLabelContainer')" [pBind]="ptm('weekLabelContainer')">
|
|
3476
|
-
{{ month.weekNumbers[j] }}
|
|
3477
|
-
</span>
|
|
3478
|
-
</td>
|
|
3479
|
-
<td *ngFor="let date of week" [attr.aria-label]="date.day" [class]="cx('dayCell', { date })" [pBind]="ptm('dayCell')">
|
|
3480
|
-
<ng-container *ngIf="date.otherMonth ? showOtherMonths() : true">
|
|
3481
|
-
<span
|
|
3482
|
-
[ngClass]="dayClass(date)"
|
|
3483
|
-
(click)="onDateSelect($event, date)"
|
|
3484
|
-
draggable="false"
|
|
3485
|
-
[attr.data-date]="formatDateKey(formatDateMetaToDate(date))"
|
|
3486
|
-
(keydown)="onDateCellKeydown($event, date, i)"
|
|
3487
|
-
pRipple
|
|
3488
|
-
[pBind]="ptm('day')"
|
|
3489
|
-
>
|
|
3490
|
-
<ng-container *ngIf="!dateTemplate() && !_dateTemplate() && (date.selectable || (!disabledDateTemplate() && !_disabledDateTemplate()))">{{ date.day }}</ng-container>
|
|
3491
|
-
<ng-container *ngIf="date.selectable || (!disabledDateTemplate() && !_disabledDateTemplate())">
|
|
3492
|
-
<ng-container *ngTemplateOutlet="dateTemplate() || _dateTemplate(); context: { $implicit: date }"></ng-container>
|
|
3493
|
-
</ng-container>
|
|
3494
|
-
<ng-container *ngIf="!date.selectable">
|
|
3495
|
-
<ng-container *ngTemplateOutlet="disabledDateTemplate() || _disabledDateTemplate(); context: { $implicit: date }"></ng-container>
|
|
3496
|
-
</ng-container>
|
|
3497
|
-
</span>
|
|
3498
|
-
<div *ngIf="isSelected(date)" class="p-hidden-accessible" aria-live="polite">
|
|
3499
|
-
{{ date.day }}
|
|
3500
|
-
</div>
|
|
3501
|
-
</ng-container>
|
|
3502
|
-
</td>
|
|
3503
|
-
</tr>
|
|
3504
|
-
</tbody>
|
|
3505
|
-
</table>
|
|
3506
|
-
</div>
|
|
3507
|
-
</div>
|
|
3508
|
-
<div [class]="cx('monthView')" *ngIf="currentView() === 'month'" [pBind]="ptm('monthView')">
|
|
3509
|
-
<span *ngFor="let m of monthPickerValues(); let i = index" (click)="onMonthSelect($event, i)" (keydown)="onMonthCellKeydown($event, i)" [class]="cx('month', { month: m, index: i })" pRipple [pBind]="ptm('month')">
|
|
3510
|
-
{{ m }}
|
|
3511
|
-
<div *ngIf="isMonthSelected(i)" class="p-hidden-accessible" aria-live="polite">
|
|
3512
|
-
{{ m }}
|
|
3624
|
+
<div class="p-datepicker-separator" [pBind]="ptm('separatorContainer')">
|
|
3625
|
+
<span [pBind]="ptm('separator')">{{ timeSeparator() }}</span>
|
|
3513
3626
|
</div>
|
|
3514
|
-
|
|
3515
|
-
|
|
3516
|
-
|
|
3517
|
-
|
|
3518
|
-
|
|
3519
|
-
|
|
3520
|
-
|
|
3627
|
+
<div [class]="cx('minutePicker')" [pBind]="ptm('minutePicker')">
|
|
3628
|
+
<p-button
|
|
3629
|
+
rounded
|
|
3630
|
+
variant="text"
|
|
3631
|
+
severity="secondary"
|
|
3632
|
+
[styleClass]="cx('pcIncrementButton')"
|
|
3633
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3634
|
+
(keydown.enter)="incrementMinute($event)"
|
|
3635
|
+
(keydown.space)="incrementMinute($event)"
|
|
3636
|
+
(mousedown)="onTimePickerElementMouseDown($event, 1, 1)"
|
|
3637
|
+
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
3638
|
+
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
3639
|
+
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
3640
|
+
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
3641
|
+
[attr.aria-label]="getTranslation('nextMinute')"
|
|
3642
|
+
[pt]="ptm('pcIncrementButton')"
|
|
3643
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3644
|
+
>
|
|
3645
|
+
<ng-template #icon>
|
|
3646
|
+
@if (!incrementIconTemplate() && !_incrementIconTemplate()) {
|
|
3647
|
+
<svg data-p-icon="chevron-up" [pBind]="ptm('pcIncrementButton')['icon']" />
|
|
3648
|
+
}
|
|
3649
|
+
<ng-template *ngTemplateOutlet="incrementIconTemplate() || _incrementIconTemplate()"></ng-template>
|
|
3650
|
+
</ng-template>
|
|
3651
|
+
</p-button>
|
|
3652
|
+
<span [pBind]="ptm('minute')">{{ currentMinute() < 10 ? '0' : '' }}{{ currentMinute() }}</span>
|
|
3653
|
+
<p-button
|
|
3654
|
+
rounded
|
|
3655
|
+
variant="text"
|
|
3656
|
+
severity="secondary"
|
|
3657
|
+
[styleClass]="cx('pcDecrementButton')"
|
|
3658
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3659
|
+
(keydown.enter)="decrementMinute($event)"
|
|
3660
|
+
(keydown.space)="decrementMinute($event)"
|
|
3661
|
+
(mousedown)="onTimePickerElementMouseDown($event, 1, -1)"
|
|
3662
|
+
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
3663
|
+
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
3664
|
+
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
3665
|
+
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
3666
|
+
[attr.aria-label]="getTranslation('prevMinute')"
|
|
3667
|
+
[pt]="ptm('pcDecrementButton')"
|
|
3668
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3669
|
+
>
|
|
3670
|
+
<ng-template #icon>
|
|
3671
|
+
@if (!decrementIconTemplate() && !_decrementIconTemplate()) {
|
|
3672
|
+
<svg data-p-icon="chevron-down" [pBind]="ptm('pcDecrementButton')['icon']" />
|
|
3673
|
+
}
|
|
3674
|
+
<ng-template *ngTemplateOutlet="decrementIconTemplate() || _decrementIconTemplate()"></ng-template>
|
|
3675
|
+
</ng-template>
|
|
3676
|
+
</p-button>
|
|
3521
3677
|
</div>
|
|
3522
|
-
|
|
3523
|
-
|
|
3524
|
-
|
|
3525
|
-
|
|
3526
|
-
|
|
3527
|
-
|
|
3528
|
-
|
|
3529
|
-
|
|
3530
|
-
|
|
3531
|
-
|
|
3532
|
-
|
|
3533
|
-
|
|
3534
|
-
|
|
3535
|
-
|
|
3536
|
-
|
|
3537
|
-
|
|
3538
|
-
|
|
3539
|
-
|
|
3540
|
-
|
|
3541
|
-
|
|
3542
|
-
|
|
3543
|
-
|
|
3544
|
-
|
|
3545
|
-
|
|
3546
|
-
|
|
3547
|
-
|
|
3548
|
-
|
|
3549
|
-
|
|
3550
|
-
|
|
3551
|
-
|
|
3552
|
-
|
|
3553
|
-
|
|
3554
|
-
|
|
3555
|
-
|
|
3556
|
-
|
|
3557
|
-
|
|
3558
|
-
|
|
3559
|
-
|
|
3560
|
-
|
|
3561
|
-
|
|
3562
|
-
|
|
3563
|
-
|
|
3564
|
-
|
|
3565
|
-
|
|
3566
|
-
|
|
3567
|
-
|
|
3568
|
-
|
|
3569
|
-
|
|
3570
|
-
|
|
3571
|
-
|
|
3572
|
-
|
|
3573
|
-
|
|
3574
|
-
|
|
3575
|
-
|
|
3576
|
-
|
|
3577
|
-
|
|
3578
|
-
|
|
3579
|
-
|
|
3580
|
-
|
|
3581
|
-
|
|
3582
|
-
|
|
3583
|
-
|
|
3584
|
-
|
|
3585
|
-
(
|
|
3586
|
-
|
|
3587
|
-
|
|
3588
|
-
|
|
3589
|
-
|
|
3590
|
-
|
|
3591
|
-
|
|
3592
|
-
|
|
3593
|
-
|
|
3594
|
-
|
|
3595
|
-
|
|
3596
|
-
|
|
3597
|
-
|
|
3598
|
-
|
|
3599
|
-
|
|
3600
|
-
|
|
3601
|
-
|
|
3602
|
-
|
|
3603
|
-
|
|
3604
|
-
|
|
3605
|
-
|
|
3606
|
-
|
|
3607
|
-
|
|
3608
|
-
|
|
3609
|
-
|
|
3610
|
-
|
|
3611
|
-
|
|
3612
|
-
|
|
3613
|
-
|
|
3614
|
-
|
|
3615
|
-
|
|
3616
|
-
|
|
3617
|
-
|
|
3618
|
-
|
|
3619
|
-
|
|
3620
|
-
|
|
3621
|
-
|
|
3622
|
-
|
|
3623
|
-
|
|
3624
|
-
|
|
3625
|
-
|
|
3626
|
-
|
|
3627
|
-
|
|
3628
|
-
|
|
3629
|
-
variant="text"
|
|
3630
|
-
severity="secondary"
|
|
3631
|
-
[styleClass]="cx('pcIncrementButton')"
|
|
3632
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
3633
|
-
(keydown.enter)="incrementSecond($event)"
|
|
3634
|
-
(keydown.space)="incrementSecond($event)"
|
|
3635
|
-
(mousedown)="onTimePickerElementMouseDown($event, 2, 1)"
|
|
3636
|
-
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
3637
|
-
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
3638
|
-
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
3639
|
-
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
3640
|
-
[attr.aria-label]="getTranslation('nextSecond')"
|
|
3641
|
-
[pt]="ptm('pcIncrementButton')"
|
|
3642
|
-
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3643
|
-
>
|
|
3644
|
-
<ng-template #icon>
|
|
3645
|
-
<svg data-p-icon="chevron-up" *ngIf="!incrementIconTemplate() && !_incrementIconTemplate()" [pBind]="ptm('pcIncrementButton')['icon']" />
|
|
3646
|
-
<ng-template *ngTemplateOutlet="incrementIconTemplate() || _incrementIconTemplate()"></ng-template>
|
|
3647
|
-
</ng-template>
|
|
3648
|
-
</p-button>
|
|
3649
|
-
<span [pBind]="ptm('second')"><ng-container *ngIf="currentSecond() < 10">0</ng-container>{{ currentSecond() }}</span>
|
|
3650
|
-
<p-button
|
|
3651
|
-
rounded
|
|
3652
|
-
variant="text"
|
|
3653
|
-
severity="secondary"
|
|
3654
|
-
[styleClass]="cx('pcDecrementButton')"
|
|
3655
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
3656
|
-
(keydown.enter)="decrementSecond($event)"
|
|
3657
|
-
(keydown.space)="decrementSecond($event)"
|
|
3658
|
-
(mousedown)="onTimePickerElementMouseDown($event, 2, -1)"
|
|
3659
|
-
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
3660
|
-
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
3661
|
-
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
3662
|
-
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
3663
|
-
[attr.aria-label]="getTranslation('prevSecond')"
|
|
3664
|
-
[pt]="ptm('pcDecrementButton')"
|
|
3665
|
-
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3666
|
-
>
|
|
3667
|
-
<ng-template #icon>
|
|
3668
|
-
<svg data-p-icon="chevron-down" *ngIf="!decrementIconTemplate() && !_decrementIconTemplate()" [pBind]="ptm('pcDecrementButton')['icon']" />
|
|
3669
|
-
<ng-template *ngTemplateOutlet="decrementIconTemplate() || _decrementIconTemplate()"></ng-template>
|
|
3670
|
-
</ng-template>
|
|
3671
|
-
</p-button>
|
|
3672
|
-
</div>
|
|
3673
|
-
<div [class]="cx('separator')" *ngIf="hourFormat() == '12'" [pBind]="ptm('separatorContainer')">
|
|
3674
|
-
<span [pBind]="ptm('separator')">{{ timeSeparator() }}</span>
|
|
3675
|
-
</div>
|
|
3676
|
-
<div [class]="cx('ampmPicker')" *ngIf="hourFormat() == '12'" [pBind]="ptm('ampmPicker')">
|
|
3677
|
-
<p-button
|
|
3678
|
-
text
|
|
3679
|
-
rounded
|
|
3680
|
-
severity="secondary"
|
|
3681
|
-
[styleClass]="cx('pcIncrementButton')"
|
|
3682
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
3683
|
-
(onClick)="toggleAMPM($event)"
|
|
3684
|
-
(keydown.enter)="toggleAMPM($event)"
|
|
3685
|
-
[attr.aria-label]="getTranslation('am')"
|
|
3686
|
-
[pt]="ptm('pcIncrementButton')"
|
|
3687
|
-
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3688
|
-
>
|
|
3689
|
-
<ng-template #icon>
|
|
3690
|
-
<svg data-p-icon="chevron-up" *ngIf="!incrementIconTemplate() && !_incrementIconTemplate()" [pBind]="ptm('pcIncrementButton')['icon']" />
|
|
3691
|
-
<ng-template *ngTemplateOutlet="incrementIconTemplate() || _incrementIconTemplate()"></ng-template>
|
|
3692
|
-
</ng-template>
|
|
3693
|
-
</p-button>
|
|
3694
|
-
<span [pBind]="ptm('ampm')">{{ pm() ? 'PM' : 'AM' }}</span>
|
|
3695
|
-
<p-button
|
|
3696
|
-
text
|
|
3697
|
-
rounded
|
|
3698
|
-
severity="secondary"
|
|
3699
|
-
[styleClass]="cx('pcDecrementButton')"
|
|
3700
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
3701
|
-
(click)="toggleAMPM($event)"
|
|
3702
|
-
(keydown.enter)="toggleAMPM($event)"
|
|
3703
|
-
[attr.aria-label]="getTranslation('pm')"
|
|
3704
|
-
[pt]="ptm('pcDecrementButton')"
|
|
3705
|
-
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3706
|
-
>
|
|
3707
|
-
<ng-template #icon>
|
|
3708
|
-
<svg data-p-icon="chevron-down" *ngIf="!decrementIconTemplate() && !_decrementIconTemplate()" [pBind]="ptm('pcDecrementButton')['icon']" />
|
|
3709
|
-
<ng-template *ngTemplateOutlet="decrementIconTemplate() || _decrementIconTemplate()"></ng-template>
|
|
3710
|
-
</ng-template>
|
|
3711
|
-
</p-button>
|
|
3712
|
-
</div>
|
|
3713
|
-
</div>
|
|
3714
|
-
<div [class]="cx('buttonbar')" *ngIf="showButtonBar()" [pBind]="ptm('buttonbar')">
|
|
3715
|
-
@if (buttonBarTemplate() || _buttonBarTemplate()) {
|
|
3716
|
-
<ng-container *ngTemplateOutlet="buttonBarTemplate() || _buttonBarTemplate(); context: { todayCallback: onTodayButtonClick.bind(this), clearCallback: onClearButtonClick.bind(this) }"></ng-container>
|
|
3717
|
-
} @else {
|
|
3718
|
-
<p-button
|
|
3719
|
-
size="small"
|
|
3720
|
-
[styleClass]="cx('pcTodayButton')"
|
|
3721
|
-
[label]="getTranslation('today')"
|
|
3722
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
3723
|
-
(onClick)="onTodayButtonClick($event)"
|
|
3724
|
-
[ngClass]="todayButtonStyleClass()"
|
|
3725
|
-
severity="secondary"
|
|
3726
|
-
variant="text"
|
|
3727
|
-
size="small"
|
|
3728
|
-
[pt]="ptm('pcTodayButton')"
|
|
3729
|
-
[attr.data-pc-group-section]="'button'"
|
|
3730
|
-
/>
|
|
3731
|
-
<p-button
|
|
3732
|
-
size="small"
|
|
3733
|
-
[styleClass]="cx('pcClearButton')"
|
|
3734
|
-
[label]="getTranslation('clear')"
|
|
3735
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
3736
|
-
(onClick)="onClearButtonClick($event)"
|
|
3737
|
-
[ngClass]="clearButtonStyleClass()"
|
|
3738
|
-
severity="secondary"
|
|
3739
|
-
variant="text"
|
|
3740
|
-
size="small"
|
|
3741
|
-
[pt]="ptm('pcClearButton')"
|
|
3742
|
-
[attr.data-pc-group-section]="'button'"
|
|
3743
|
-
/>
|
|
3678
|
+
@if (showSeconds()) {
|
|
3679
|
+
<div [class]="cx('separator')" [pBind]="ptm('separatorContainer')">
|
|
3680
|
+
<span [pBind]="ptm('separator')">{{ timeSeparator() }}</span>
|
|
3681
|
+
</div>
|
|
3682
|
+
}
|
|
3683
|
+
@if (showSeconds()) {
|
|
3684
|
+
<div [class]="cx('secondPicker')" [pBind]="ptm('secondPicker')">
|
|
3685
|
+
<p-button
|
|
3686
|
+
rounded
|
|
3687
|
+
variant="text"
|
|
3688
|
+
severity="secondary"
|
|
3689
|
+
[styleClass]="cx('pcIncrementButton')"
|
|
3690
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3691
|
+
(keydown.enter)="incrementSecond($event)"
|
|
3692
|
+
(keydown.space)="incrementSecond($event)"
|
|
3693
|
+
(mousedown)="onTimePickerElementMouseDown($event, 2, 1)"
|
|
3694
|
+
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
3695
|
+
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
3696
|
+
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
3697
|
+
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
3698
|
+
[attr.aria-label]="getTranslation('nextSecond')"
|
|
3699
|
+
[pt]="ptm('pcIncrementButton')"
|
|
3700
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3701
|
+
>
|
|
3702
|
+
<ng-template #icon>
|
|
3703
|
+
@if (!incrementIconTemplate() && !_incrementIconTemplate()) {
|
|
3704
|
+
<svg data-p-icon="chevron-up" [pBind]="ptm('pcIncrementButton')['icon']" />
|
|
3705
|
+
}
|
|
3706
|
+
<ng-template *ngTemplateOutlet="incrementIconTemplate() || _incrementIconTemplate()"></ng-template>
|
|
3707
|
+
</ng-template>
|
|
3708
|
+
</p-button>
|
|
3709
|
+
<span [pBind]="ptm('second')">{{ currentSecond() < 10 ? '0' : '' }}{{ currentSecond() }}</span>
|
|
3710
|
+
<p-button
|
|
3711
|
+
rounded
|
|
3712
|
+
variant="text"
|
|
3713
|
+
severity="secondary"
|
|
3714
|
+
[styleClass]="cx('pcDecrementButton')"
|
|
3715
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3716
|
+
(keydown.enter)="decrementSecond($event)"
|
|
3717
|
+
(keydown.space)="decrementSecond($event)"
|
|
3718
|
+
(mousedown)="onTimePickerElementMouseDown($event, 2, -1)"
|
|
3719
|
+
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
3720
|
+
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
3721
|
+
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
3722
|
+
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
3723
|
+
[attr.aria-label]="getTranslation('prevSecond')"
|
|
3724
|
+
[pt]="ptm('pcDecrementButton')"
|
|
3725
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3726
|
+
>
|
|
3727
|
+
<ng-template #icon>
|
|
3728
|
+
@if (!decrementIconTemplate() && !_decrementIconTemplate()) {
|
|
3729
|
+
<svg data-p-icon="chevron-down" [pBind]="ptm('pcDecrementButton')['icon']" />
|
|
3730
|
+
}
|
|
3731
|
+
<ng-template *ngTemplateOutlet="decrementIconTemplate() || _decrementIconTemplate()"></ng-template>
|
|
3732
|
+
</ng-template>
|
|
3733
|
+
</p-button>
|
|
3734
|
+
</div>
|
|
3735
|
+
}
|
|
3736
|
+
@if (hourFormat() == '12') {
|
|
3737
|
+
<div [class]="cx('separator')" [pBind]="ptm('separatorContainer')">
|
|
3738
|
+
<span [pBind]="ptm('separator')">{{ timeSeparator() }}</span>
|
|
3739
|
+
</div>
|
|
3740
|
+
}
|
|
3741
|
+
@if (hourFormat() == '12') {
|
|
3742
|
+
<div [class]="cx('ampmPicker')" [pBind]="ptm('ampmPicker')">
|
|
3743
|
+
<p-button
|
|
3744
|
+
text
|
|
3745
|
+
rounded
|
|
3746
|
+
severity="secondary"
|
|
3747
|
+
[styleClass]="cx('pcIncrementButton')"
|
|
3748
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3749
|
+
(onClick)="toggleAMPM($event)"
|
|
3750
|
+
(keydown.enter)="toggleAMPM($event)"
|
|
3751
|
+
[attr.aria-label]="getTranslation('am')"
|
|
3752
|
+
[pt]="ptm('pcIncrementButton')"
|
|
3753
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3754
|
+
>
|
|
3755
|
+
<ng-template #icon>
|
|
3756
|
+
@if (!incrementIconTemplate() && !_incrementIconTemplate()) {
|
|
3757
|
+
<svg data-p-icon="chevron-up" [pBind]="ptm('pcIncrementButton')['icon']" />
|
|
3758
|
+
}
|
|
3759
|
+
<ng-template *ngTemplateOutlet="incrementIconTemplate() || _incrementIconTemplate()"></ng-template>
|
|
3760
|
+
</ng-template>
|
|
3761
|
+
</p-button>
|
|
3762
|
+
<span [pBind]="ptm('ampm')">{{ pm() ? 'PM' : 'AM' }}</span>
|
|
3763
|
+
<p-button
|
|
3764
|
+
text
|
|
3765
|
+
rounded
|
|
3766
|
+
severity="secondary"
|
|
3767
|
+
[styleClass]="cx('pcDecrementButton')"
|
|
3768
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3769
|
+
(click)="toggleAMPM($event)"
|
|
3770
|
+
(keydown.enter)="toggleAMPM($event)"
|
|
3771
|
+
[attr.aria-label]="getTranslation('pm')"
|
|
3772
|
+
[pt]="ptm('pcDecrementButton')"
|
|
3773
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3774
|
+
>
|
|
3775
|
+
<ng-template #icon>
|
|
3776
|
+
@if (!decrementIconTemplate() && !_decrementIconTemplate()) {
|
|
3777
|
+
<svg data-p-icon="chevron-down" [pBind]="ptm('pcDecrementButton')['icon']" />
|
|
3778
|
+
}
|
|
3779
|
+
<ng-template *ngTemplateOutlet="decrementIconTemplate() || _decrementIconTemplate()"></ng-template>
|
|
3780
|
+
</ng-template>
|
|
3781
|
+
</p-button>
|
|
3782
|
+
</div>
|
|
3783
|
+
}
|
|
3784
|
+
</div>
|
|
3744
3785
|
}
|
|
3786
|
+
@if (showButtonBar()) {
|
|
3787
|
+
<div [class]="cx('buttonbar')" [pBind]="ptm('buttonbar')">
|
|
3788
|
+
@if (buttonBarTemplate() || _buttonBarTemplate()) {
|
|
3789
|
+
<ng-container *ngTemplateOutlet="buttonBarTemplate() || _buttonBarTemplate(); context: { todayCallback: onTodayButtonClick.bind(this), clearCallback: onClearButtonClick.bind(this) }"></ng-container>
|
|
3790
|
+
} @else {
|
|
3791
|
+
<p-button
|
|
3792
|
+
size="small"
|
|
3793
|
+
[styleClass]="cx('pcTodayButton')"
|
|
3794
|
+
[label]="getTranslation('today')"
|
|
3795
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3796
|
+
(onClick)="onTodayButtonClick($event)"
|
|
3797
|
+
[ngClass]="todayButtonStyleClass()"
|
|
3798
|
+
severity="secondary"
|
|
3799
|
+
variant="text"
|
|
3800
|
+
size="small"
|
|
3801
|
+
[pt]="ptm('pcTodayButton')"
|
|
3802
|
+
[attr.data-pc-group-section]="'button'"
|
|
3803
|
+
/>
|
|
3804
|
+
<p-button
|
|
3805
|
+
size="small"
|
|
3806
|
+
[styleClass]="cx('pcClearButton')"
|
|
3807
|
+
[label]="getTranslation('clear')"
|
|
3808
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3809
|
+
(onClick)="onClearButtonClick($event)"
|
|
3810
|
+
[ngClass]="clearButtonStyleClass()"
|
|
3811
|
+
severity="secondary"
|
|
3812
|
+
variant="text"
|
|
3813
|
+
size="small"
|
|
3814
|
+
[pt]="ptm('pcClearButton')"
|
|
3815
|
+
[attr.data-pc-group-section]="'button'"
|
|
3816
|
+
/>
|
|
3817
|
+
}
|
|
3818
|
+
</div>
|
|
3819
|
+
}
|
|
3820
|
+
<ng-content select="p-footer"></ng-content>
|
|
3821
|
+
<ng-container *ngTemplateOutlet="footerTemplate() || _footerTemplate()"></ng-container>
|
|
3745
3822
|
</div>
|
|
3746
|
-
|
|
3747
|
-
|
|
3748
|
-
|
|
3749
|
-
</p-motion>
|
|
3750
|
-
`, isInline: true, dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "component", type: Button, selector: "p-button", inputs: ["hostName", "type", "badge", "disabled", "raised", "rounded", "text", "plain", "outlined", "link", "tabindex", "size", "variant", "style", "styleClass", "badgeSeverity", "ariaLabel", "autofocus", "iconPos", "icon", "label", "loading", "loadingIcon", "severity", "buttonProps", "fluid"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "directive", type: Ripple, selector: "[pRipple]" }, { kind: "component", type: ChevronLeftIcon, selector: "[data-p-icon=\"chevron-left\"]" }, { kind: "component", type: ChevronRightIcon, selector: "[data-p-icon=\"chevron-right\"]" }, { kind: "component", type: ChevronUpIcon, selector: "[data-p-icon=\"chevron-up\"]" }, { kind: "component", type: ChevronDownIcon, selector: "[data-p-icon=\"chevron-down\"]" }, { kind: "component", type: TimesIcon, selector: "[data-p-icon=\"times\"]" }, { kind: "component", type: CalendarIcon, selector: "[data-p-icon=\"calendar\"]" }, { kind: "directive", type: AutoFocus, selector: "[pAutoFocus]", inputs: ["pAutoFocus"] }, { kind: "directive", type: InputText, selector: "[pInputText]", inputs: ["hostName", "ptInputText", "pInputTextPT", "pInputTextUnstyled", "pSize", "variant", "fluid", "invalid"] }, { kind: "ngmodule", type: SharedModule }, { kind: "ngmodule", type: BindModule }, { kind: "directive", type: i1.Bind, selector: "[pBind]", inputs: ["pBind"] }, { kind: "ngmodule", type: MotionModule }, { kind: "component", type: i3.Motion, selector: "p-motion", inputs: ["visible", "mountOnEnter", "unmountOnLeave", "name", "type", "safe", "disabled", "appear", "enter", "leave", "duration", "hideStrategy", "enterFromClass", "enterToClass", "enterActiveClass", "leaveFromClass", "leaveToClass", "leaveActiveClass", "options"], outputs: ["onBeforeEnter", "onEnter", "onAfterEnter", "onEnterCancelled", "onBeforeLeave", "onLeave", "onAfterLeave", "onLeaveCancelled"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
3823
|
+
</p-motion>
|
|
3824
|
+
}
|
|
3825
|
+
`, isInline: true, dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "component", type: Button, selector: "p-button", inputs: ["hostName", "type", "badge", "disabled", "raised", "rounded", "text", "plain", "outlined", "link", "tabindex", "size", "variant", "style", "styleClass", "badgeSeverity", "ariaLabel", "autofocus", "iconPos", "icon", "label", "loading", "loadingIcon", "severity", "buttonProps", "fluid"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "directive", type: Ripple, selector: "[pRipple]" }, { kind: "component", type: ChevronLeftIcon, selector: "[data-p-icon=\"chevron-left\"]" }, { kind: "component", type: ChevronRightIcon, selector: "[data-p-icon=\"chevron-right\"]" }, { kind: "component", type: ChevronUpIcon, selector: "[data-p-icon=\"chevron-up\"]" }, { kind: "component", type: ChevronDownIcon, selector: "[data-p-icon=\"chevron-down\"]" }, { kind: "component", type: TimesIcon, selector: "[data-p-icon=\"times\"]" }, { kind: "component", type: CalendarIcon, selector: "[data-p-icon=\"calendar\"]" }, { kind: "directive", type: AutoFocus, selector: "[pAutoFocus]", inputs: ["pAutoFocus"] }, { kind: "directive", type: InputText, selector: "[pInputText]", inputs: ["hostName", "ptInputText", "pInputTextPT", "pInputTextUnstyled", "pSize", "variant", "fluid", "invalid"] }, { kind: "ngmodule", type: SharedModule }, { kind: "ngmodule", type: BindModule }, { kind: "directive", type: i1.Bind, selector: "[pBind]", inputs: ["pBind"] }, { kind: "ngmodule", type: MotionModule }, { kind: "component", type: i3.Motion, selector: "p-motion", inputs: ["visible", "mountOnEnter", "unmountOnLeave", "name", "type", "safe", "disabled", "appear", "enter", "leave", "duration", "hideStrategy", "enterFromClass", "enterToClass", "enterActiveClass", "leaveFromClass", "leaveToClass", "leaveActiveClass", "options"], outputs: ["onBeforeEnter", "onEnter", "onAfterEnter", "onEnterCancelled", "onBeforeLeave", "onLeave", "onAfterLeave", "onLeaveCancelled"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
3751
3826
|
}
|
|
3752
3827
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.1", ngImport: i0, type: DatePicker, decorators: [{
|
|
3753
3828
|
type: Component,
|
|
@@ -3756,7 +3831,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.1", ngImpor
|
|
|
3756
3831
|
imports: [CommonModule, Button, Ripple, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, ChevronDownIcon, TimesIcon, CalendarIcon, AutoFocus, InputText, SharedModule, BindModule, MotionModule],
|
|
3757
3832
|
hostDirectives: [Bind],
|
|
3758
3833
|
template: `
|
|
3759
|
-
|
|
3834
|
+
@if (!inline()) {
|
|
3760
3835
|
<input
|
|
3761
3836
|
#inputfield
|
|
3762
3837
|
pInputText
|
|
@@ -3796,428 +3871,503 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.1", ngImpor
|
|
|
3796
3871
|
[pt]="ptm('pcInputText')"
|
|
3797
3872
|
[unstyled]="unstyled()"
|
|
3798
3873
|
/>
|
|
3799
|
-
|
|
3800
|
-
|
|
3801
|
-
|
|
3802
|
-
|
|
3803
|
-
|
|
3804
|
-
|
|
3805
|
-
|
|
3806
|
-
|
|
3807
|
-
|
|
3808
|
-
|
|
3809
|
-
|
|
3810
|
-
|
|
3811
|
-
|
|
3812
|
-
|
|
3813
|
-
|
|
3814
|
-
|
|
3815
|
-
|
|
3816
|
-
|
|
3817
|
-
|
|
3818
|
-
|
|
3819
|
-
|
|
3820
|
-
|
|
3821
|
-
|
|
3822
|
-
|
|
3823
|
-
|
|
3824
|
-
|
|
3874
|
+
@if (showClear() && !$disabled() && inputfieldViewChild()?.nativeElement?.value) {
|
|
3875
|
+
@if (!clearIconTemplate() && !_clearIconTemplate()) {
|
|
3876
|
+
<svg data-p-icon="times" [class]="cx('clearIcon')" [pBind]="ptm('inputIcon')" (click)="clear()" />
|
|
3877
|
+
}
|
|
3878
|
+
@if (clearIconTemplate() || _clearIconTemplate()) {
|
|
3879
|
+
<span [class]="cx('clearIcon')" [pBind]="ptm('inputIcon')" (click)="clear()">
|
|
3880
|
+
<ng-template *ngTemplateOutlet="clearIconTemplate() || _clearIconTemplate()"></ng-template>
|
|
3881
|
+
</span>
|
|
3882
|
+
}
|
|
3883
|
+
}
|
|
3884
|
+
@if (showIcon() && iconDisplay() === 'button') {
|
|
3885
|
+
<button
|
|
3886
|
+
type="button"
|
|
3887
|
+
[attr.aria-label]="iconButtonAriaLabel"
|
|
3888
|
+
aria-haspopup="dialog"
|
|
3889
|
+
[attr.aria-expanded]="overlayVisible() ?? false"
|
|
3890
|
+
[attr.aria-controls]="overlayVisible() ? panelId : null"
|
|
3891
|
+
(click)="onButtonClick($event, inputfield)"
|
|
3892
|
+
[class]="cx('dropdown')"
|
|
3893
|
+
[disabled]="$disabled()"
|
|
3894
|
+
tabindex="0"
|
|
3895
|
+
[pBind]="ptm('dropdown')"
|
|
3896
|
+
>
|
|
3897
|
+
@if (icon()) {
|
|
3898
|
+
<span [ngClass]="icon()" [pBind]="ptm('dropdownIcon')"></span>
|
|
3899
|
+
}
|
|
3900
|
+
@if (!icon()) {
|
|
3901
|
+
@if (!triggerIconTemplate() && !_triggerIconTemplate()) {
|
|
3902
|
+
<svg data-p-icon="calendar" [pBind]="ptm('dropdownIcon')" />
|
|
3903
|
+
}
|
|
3904
|
+
<ng-template *ngTemplateOutlet="triggerIconTemplate() || _triggerIconTemplate()"></ng-template>
|
|
3905
|
+
}
|
|
3906
|
+
</button>
|
|
3907
|
+
}
|
|
3908
|
+
@if (iconDisplay() === 'input' && showIcon()) {
|
|
3825
3909
|
<span [class]="cx('inputIconContainer')" [pBind]="ptm('inputIconContainer')" [attr.data-p]="inputIconDataP">
|
|
3826
|
-
|
|
3910
|
+
@if (!inputIconTemplate() && !_inputIconTemplate()) {
|
|
3911
|
+
<svg data-p-icon="calendar" (click)="onButtonClick($event)" [class]="cx('inputIcon')" [pBind]="ptm('inputIcon')" />
|
|
3912
|
+
}
|
|
3827
3913
|
|
|
3828
3914
|
<ng-container *ngTemplateOutlet="inputIconTemplate() || _inputIconTemplate(); context: { clickCallBack: onButtonClick.bind(this) }"></ng-container>
|
|
3829
3915
|
</span>
|
|
3830
|
-
|
|
3831
|
-
|
|
3832
|
-
|
|
3833
|
-
|
|
3834
|
-
|
|
3835
|
-
|
|
3836
|
-
|
|
3837
|
-
|
|
3838
|
-
|
|
3839
|
-
|
|
3840
|
-
|
|
3841
|
-
|
|
3842
|
-
|
|
3843
|
-
|
|
3844
|
-
|
|
3845
|
-
|
|
3846
|
-
|
|
3847
|
-
|
|
3848
|
-
|
|
3849
|
-
|
|
3850
|
-
|
|
3851
|
-
|
|
3852
|
-
|
|
3853
|
-
|
|
3854
|
-
|
|
3855
|
-
|
|
3856
|
-
|
|
3857
|
-
|
|
3916
|
+
}
|
|
3917
|
+
}
|
|
3918
|
+
@if (inline() || overlayVisible() || overlay()) {
|
|
3919
|
+
<p-motion [visible]="inline() || overlayVisible()" name="p-anchored-overlay" [appear]="!inline()" [options]="computedMotionOptions()" (onBeforeEnter)="onOverlayBeforeEnter($event)" (onAfterLeave)="onOverlayAfterLeave($event)">
|
|
3920
|
+
<div
|
|
3921
|
+
#contentWrapper
|
|
3922
|
+
[attr.id]="panelId"
|
|
3923
|
+
[ngStyle]="panelStyle()"
|
|
3924
|
+
[class]="cn(cx('panel'), panelStyleClass())"
|
|
3925
|
+
[attr.aria-label]="getTranslation('chooseDate')"
|
|
3926
|
+
[attr.role]="inline() ? null : 'dialog'"
|
|
3927
|
+
[attr.aria-modal]="inline() ? null : 'true'"
|
|
3928
|
+
(click)="onOverlayClick($event)"
|
|
3929
|
+
[pBind]="ptm('panel')"
|
|
3930
|
+
>
|
|
3931
|
+
<ng-content select="p-header"></ng-content>
|
|
3932
|
+
<ng-container *ngTemplateOutlet="headerTemplate() || _headerTemplate()"></ng-container>
|
|
3933
|
+
@if (!timeOnly()) {
|
|
3934
|
+
<div [class]="cx('calendarContainer')" [pBind]="ptm('calendarContainer')">
|
|
3935
|
+
@for (month of months(); track $index; let i = $index) {
|
|
3936
|
+
<div [class]="cx('calendar')" [pBind]="ptm('calendar')">
|
|
3937
|
+
<div [class]="cx('header')" [pBind]="ptm('header')">
|
|
3938
|
+
<p-button
|
|
3939
|
+
rounded
|
|
3940
|
+
variant="text"
|
|
3941
|
+
severity="secondary"
|
|
3942
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3943
|
+
[styleClass]="cx('pcPrevButton')"
|
|
3944
|
+
(onClick)="onPrevButtonClick($event)"
|
|
3945
|
+
[ngStyle]="{ visibility: i === 0 ? 'visible' : 'hidden' }"
|
|
3946
|
+
type="button"
|
|
3947
|
+
[ariaLabel]="prevIconAriaLabel"
|
|
3948
|
+
[pt]="ptm('pcPrevButton')"
|
|
3949
|
+
[attr.data-pc-group-section]="'navigator'"
|
|
3950
|
+
>
|
|
3951
|
+
<ng-template #icon>
|
|
3952
|
+
@if (!previousIconTemplate() && !_previousIconTemplate()) {
|
|
3953
|
+
<svg data-p-icon="chevron-left" />
|
|
3954
|
+
}
|
|
3955
|
+
@if (previousIconTemplate() || _previousIconTemplate()) {
|
|
3956
|
+
<span>
|
|
3957
|
+
<ng-template *ngTemplateOutlet="previousIconTemplate() || _previousIconTemplate()"></ng-template>
|
|
3958
|
+
</span>
|
|
3959
|
+
}
|
|
3960
|
+
</ng-template>
|
|
3961
|
+
</p-button>
|
|
3962
|
+
<div [class]="cx('title')" [pBind]="ptm('title')">
|
|
3963
|
+
@if (currentView() === 'date') {
|
|
3964
|
+
<button
|
|
3965
|
+
type="button"
|
|
3966
|
+
(click)="switchToMonthView($event)"
|
|
3967
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3968
|
+
[class]="cx('selectMonth')"
|
|
3969
|
+
[attr.disabled]="switchViewButtonDisabled() ? '' : undefined"
|
|
3970
|
+
[attr.aria-label]="this.getTranslation('chooseMonth')"
|
|
3971
|
+
pRipple
|
|
3972
|
+
[pBind]="ptm('selectMonth')"
|
|
3973
|
+
[attr.data-pc-group-section]="'navigator'"
|
|
3974
|
+
>
|
|
3975
|
+
{{ getMonthName(month.month) }}
|
|
3976
|
+
</button>
|
|
3977
|
+
}
|
|
3978
|
+
@if (currentView() !== 'year') {
|
|
3979
|
+
<button
|
|
3980
|
+
type="button"
|
|
3981
|
+
(click)="switchToYearView($event)"
|
|
3982
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
3983
|
+
[class]="cx('selectYear')"
|
|
3984
|
+
[attr.disabled]="switchViewButtonDisabled() ? '' : undefined"
|
|
3985
|
+
[attr.aria-label]="getTranslation('chooseYear')"
|
|
3986
|
+
pRipple
|
|
3987
|
+
[pBind]="ptm('selectYear')"
|
|
3988
|
+
[attr.data-pc-group-section]="'navigator'"
|
|
3989
|
+
>
|
|
3990
|
+
{{ getYear(month) }}
|
|
3991
|
+
</button>
|
|
3992
|
+
}
|
|
3993
|
+
@if (currentView() === 'year') {
|
|
3994
|
+
<span [class]="cx('decade')" [pBind]="ptm('decade')">
|
|
3995
|
+
@if (!decadeTemplate() && !_decadeTemplate()) {
|
|
3996
|
+
{{ yearPickerValues()[0] }} - {{ yearPickerValues()[yearPickerValues().length - 1] }}
|
|
3997
|
+
}
|
|
3998
|
+
<ng-container *ngTemplateOutlet="decadeTemplate() || _decadeTemplate(); context: { $implicit: yearPickerValues }"></ng-container>
|
|
3999
|
+
</span>
|
|
4000
|
+
}
|
|
4001
|
+
</div>
|
|
4002
|
+
<p-button
|
|
4003
|
+
rounded
|
|
4004
|
+
variant="text"
|
|
4005
|
+
severity="secondary"
|
|
4006
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
4007
|
+
[styleClass]="cx('pcNextButton')"
|
|
4008
|
+
(onClick)="onNextButtonClick($event)"
|
|
4009
|
+
[ngStyle]="{ visibility: i === months().length - 1 ? 'visible' : 'hidden' }"
|
|
4010
|
+
[ariaLabel]="nextIconAriaLabel"
|
|
4011
|
+
[pt]="ptm('pcNextButton')"
|
|
4012
|
+
[attr.data-pc-group-section]="'navigator'"
|
|
4013
|
+
>
|
|
4014
|
+
<ng-template #icon>
|
|
4015
|
+
@if (!nextIconTemplate() && !_nextIconTemplate()) {
|
|
4016
|
+
<svg data-p-icon="chevron-right" />
|
|
4017
|
+
}
|
|
4018
|
+
@if (nextIconTemplate() || _nextIconTemplate()) {
|
|
4019
|
+
<ng-template *ngTemplateOutlet="nextIconTemplate() || _nextIconTemplate()"></ng-template>
|
|
4020
|
+
}
|
|
4021
|
+
</ng-template>
|
|
4022
|
+
</p-button>
|
|
4023
|
+
</div>
|
|
4024
|
+
@if (currentView() === 'date') {
|
|
4025
|
+
<table [class]="cx('dayView')" role="grid" [pBind]="ptm('table')">
|
|
4026
|
+
<thead [pBind]="ptm('tableHeader')">
|
|
4027
|
+
<tr [pBind]="ptm('tableHeaderRow')">
|
|
4028
|
+
@if (showWeek()) {
|
|
4029
|
+
<th [class]="cx('weekHeader')" [pBind]="ptm('weekHeader')">
|
|
4030
|
+
<span [pBind]="ptm('weekHeaderLabel')">{{ getTranslation('weekHeader') }}</span>
|
|
4031
|
+
</th>
|
|
4032
|
+
}
|
|
4033
|
+
@for (weekDay of weekDays(); track $index; let begin = $first, end = $last) {
|
|
4034
|
+
<th [class]="cx('weekDayCell')" scope="col" [pBind]="ptm('weekDayCell')">
|
|
4035
|
+
<span [class]="cx('weekDay')" [pBind]="ptm('weekDay')">{{ weekDay }}</span>
|
|
4036
|
+
</th>
|
|
4037
|
+
}
|
|
4038
|
+
</tr>
|
|
4039
|
+
</thead>
|
|
4040
|
+
<tbody [pBind]="ptm('tableBody')">
|
|
4041
|
+
@for (week of month.dates; track $index; let j = $index) {
|
|
4042
|
+
<tr [pBind]="ptm('tableBodyRow')">
|
|
4043
|
+
@if (showWeek()) {
|
|
4044
|
+
<td [class]="cx('weekNumber')" [pBind]="ptm('weekNumber')">
|
|
4045
|
+
<span [class]="cx('weekLabelContainer')" [pBind]="ptm('weekLabelContainer')">
|
|
4046
|
+
{{ month.weekNumbers[j] }}
|
|
4047
|
+
</span>
|
|
4048
|
+
</td>
|
|
4049
|
+
}
|
|
4050
|
+
@for (date of week; track $index) {
|
|
4051
|
+
<td [attr.aria-label]="date.day" [class]="cx('dayCell', { date })" [pBind]="ptm('dayCell')">
|
|
4052
|
+
@if (date.otherMonth ? showOtherMonths() : true) {
|
|
4053
|
+
<span
|
|
4054
|
+
[ngClass]="dayClass(date)"
|
|
4055
|
+
(click)="onDateSelect($event, date)"
|
|
4056
|
+
draggable="false"
|
|
4057
|
+
[attr.data-date]="formatDateKey(formatDateMetaToDate(date))"
|
|
4058
|
+
(keydown)="onDateCellKeydown($event, date, i)"
|
|
4059
|
+
pRipple
|
|
4060
|
+
[pBind]="ptm('day')"
|
|
4061
|
+
>
|
|
4062
|
+
@if (!dateTemplate() && !_dateTemplate() && (date.selectable || (!disabledDateTemplate() && !_disabledDateTemplate()))) {
|
|
4063
|
+
{{ date.day }}
|
|
4064
|
+
}
|
|
4065
|
+
@if (date.selectable || (!disabledDateTemplate() && !_disabledDateTemplate())) {
|
|
4066
|
+
<ng-container *ngTemplateOutlet="dateTemplate() || _dateTemplate(); context: { $implicit: date }"></ng-container>
|
|
4067
|
+
}
|
|
4068
|
+
@if (!date.selectable) {
|
|
4069
|
+
<ng-container *ngTemplateOutlet="disabledDateTemplate() || _disabledDateTemplate(); context: { $implicit: date }"></ng-container>
|
|
4070
|
+
}
|
|
4071
|
+
</span>
|
|
4072
|
+
@if (isSelected(date)) {
|
|
4073
|
+
<div class="p-hidden-accessible" aria-live="polite">
|
|
4074
|
+
{{ date.day }}
|
|
4075
|
+
</div>
|
|
4076
|
+
}
|
|
4077
|
+
}
|
|
4078
|
+
</td>
|
|
4079
|
+
}
|
|
4080
|
+
</tr>
|
|
4081
|
+
}
|
|
4082
|
+
</tbody>
|
|
4083
|
+
</table>
|
|
4084
|
+
}
|
|
4085
|
+
</div>
|
|
4086
|
+
}
|
|
4087
|
+
</div>
|
|
4088
|
+
@if (currentView() === 'month') {
|
|
4089
|
+
<div [class]="cx('monthView')" [pBind]="ptm('monthView')">
|
|
4090
|
+
@for (m of monthPickerValues(); track $index; let i = $index) {
|
|
4091
|
+
<span (click)="onMonthSelect($event, i)" (keydown)="onMonthCellKeydown($event, i)" [class]="cx('month', { month: m, index: i })" pRipple [pBind]="ptm('month')">
|
|
4092
|
+
{{ m }}
|
|
4093
|
+
@if (isMonthSelected(i)) {
|
|
4094
|
+
<div class="p-hidden-accessible" aria-live="polite">
|
|
4095
|
+
{{ m }}
|
|
4096
|
+
</div>
|
|
4097
|
+
}
|
|
4098
|
+
</span>
|
|
4099
|
+
}
|
|
4100
|
+
</div>
|
|
4101
|
+
}
|
|
4102
|
+
@if (currentView() === 'year') {
|
|
4103
|
+
<div [class]="cx('yearView')" [pBind]="ptm('yearView')">
|
|
4104
|
+
@for (y of yearPickerValues(); track $index) {
|
|
4105
|
+
<span (click)="onYearSelect($event, y)" (keydown)="onYearCellKeydown($event, y)" [class]="cx('year', { year: y })" pRipple [pBind]="ptm('year')">
|
|
4106
|
+
{{ y }}
|
|
4107
|
+
@if (isYearSelected(y)) {
|
|
4108
|
+
<div class="p-hidden-accessible" aria-live="polite">
|
|
4109
|
+
{{ y }}
|
|
4110
|
+
</div>
|
|
4111
|
+
}
|
|
4112
|
+
</span>
|
|
4113
|
+
}
|
|
4114
|
+
</div>
|
|
4115
|
+
}
|
|
4116
|
+
}
|
|
4117
|
+
@if ((showTime() || timeOnly()) && currentView() === 'date') {
|
|
4118
|
+
<div [class]="cx('timePicker')" [pBind]="ptm('timePicker')">
|
|
4119
|
+
<div [class]="cx('hourPicker')" [pBind]="ptm('hourPicker')">
|
|
3858
4120
|
<p-button
|
|
3859
4121
|
rounded
|
|
3860
4122
|
variant="text"
|
|
3861
4123
|
severity="secondary"
|
|
4124
|
+
[styleClass]="cx('pcIncrementButton')"
|
|
3862
4125
|
(keydown)="onContainerButtonKeydown($event)"
|
|
3863
|
-
|
|
3864
|
-
(
|
|
3865
|
-
|
|
3866
|
-
|
|
3867
|
-
|
|
3868
|
-
|
|
3869
|
-
|
|
4126
|
+
(keydown.enter)="incrementHour($event)"
|
|
4127
|
+
(keydown.space)="incrementHour($event)"
|
|
4128
|
+
(mousedown)="onTimePickerElementMouseDown($event, 0, 1)"
|
|
4129
|
+
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
4130
|
+
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
4131
|
+
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
4132
|
+
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
4133
|
+
[attr.aria-label]="getTranslation('nextHour')"
|
|
4134
|
+
[pt]="ptm('pcIncrementButton')"
|
|
4135
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3870
4136
|
>
|
|
3871
4137
|
<ng-template #icon>
|
|
3872
|
-
|
|
3873
|
-
|
|
3874
|
-
|
|
3875
|
-
|
|
4138
|
+
@if (!incrementIconTemplate() && !_incrementIconTemplate()) {
|
|
4139
|
+
<svg data-p-icon="chevron-up" [pBind]="ptm('pcIncrementButton')['icon']" />
|
|
4140
|
+
}
|
|
4141
|
+
<ng-template *ngTemplateOutlet="incrementIconTemplate() || _incrementIconTemplate()"></ng-template>
|
|
3876
4142
|
</ng-template>
|
|
3877
4143
|
</p-button>
|
|
3878
|
-
<
|
|
3879
|
-
<button
|
|
3880
|
-
*ngIf="currentView() === 'date'"
|
|
3881
|
-
type="button"
|
|
3882
|
-
(click)="switchToMonthView($event)"
|
|
3883
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
3884
|
-
[class]="cx('selectMonth')"
|
|
3885
|
-
[attr.disabled]="switchViewButtonDisabled() ? '' : undefined"
|
|
3886
|
-
[attr.aria-label]="this.getTranslation('chooseMonth')"
|
|
3887
|
-
pRipple
|
|
3888
|
-
[pBind]="ptm('selectMonth')"
|
|
3889
|
-
[attr.data-pc-group-section]="'navigator'"
|
|
3890
|
-
>
|
|
3891
|
-
{{ getMonthName(month.month) }}
|
|
3892
|
-
</button>
|
|
3893
|
-
<button
|
|
3894
|
-
*ngIf="currentView() !== 'year'"
|
|
3895
|
-
type="button"
|
|
3896
|
-
(click)="switchToYearView($event)"
|
|
3897
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
3898
|
-
[class]="cx('selectYear')"
|
|
3899
|
-
[attr.disabled]="switchViewButtonDisabled() ? '' : undefined"
|
|
3900
|
-
[attr.aria-label]="getTranslation('chooseYear')"
|
|
3901
|
-
pRipple
|
|
3902
|
-
[pBind]="ptm('selectYear')"
|
|
3903
|
-
[attr.data-pc-group-section]="'navigator'"
|
|
3904
|
-
>
|
|
3905
|
-
{{ getYear(month) }}
|
|
3906
|
-
</button>
|
|
3907
|
-
<span [class]="cx('decade')" *ngIf="currentView() === 'year'" [pBind]="ptm('decade')">
|
|
3908
|
-
<ng-container *ngIf="!decadeTemplate() && !_decadeTemplate()">{{ yearPickerValues()[0] }} - {{ yearPickerValues()[yearPickerValues().length - 1] }}</ng-container>
|
|
3909
|
-
<ng-container *ngTemplateOutlet="decadeTemplate() || _decadeTemplate(); context: { $implicit: yearPickerValues }"></ng-container>
|
|
3910
|
-
</span>
|
|
3911
|
-
</div>
|
|
4144
|
+
<span [pBind]="ptm('hour')">{{ currentHour() < 10 ? '0' : '' }}{{ currentHour() }}</span>
|
|
3912
4145
|
<p-button
|
|
3913
4146
|
rounded
|
|
3914
4147
|
variant="text"
|
|
3915
4148
|
severity="secondary"
|
|
4149
|
+
[styleClass]="cx('pcDecrementButton')"
|
|
3916
4150
|
(keydown)="onContainerButtonKeydown($event)"
|
|
3917
|
-
|
|
3918
|
-
(
|
|
3919
|
-
|
|
3920
|
-
|
|
3921
|
-
|
|
3922
|
-
|
|
4151
|
+
(keydown.enter)="decrementHour($event)"
|
|
4152
|
+
(keydown.space)="decrementHour($event)"
|
|
4153
|
+
(mousedown)="onTimePickerElementMouseDown($event, 0, -1)"
|
|
4154
|
+
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
4155
|
+
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
4156
|
+
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
4157
|
+
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
4158
|
+
[attr.aria-label]="getTranslation('prevHour')"
|
|
4159
|
+
[pt]="ptm('pcDecrementButton')"
|
|
4160
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
3923
4161
|
>
|
|
3924
4162
|
<ng-template #icon>
|
|
3925
|
-
|
|
3926
|
-
|
|
3927
|
-
|
|
3928
|
-
|
|
4163
|
+
@if (!decrementIconTemplate() && !_decrementIconTemplate()) {
|
|
4164
|
+
<svg data-p-icon="chevron-down" [pBind]="ptm('pcDecrementButton')['icon']" />
|
|
4165
|
+
}
|
|
4166
|
+
<ng-template *ngTemplateOutlet="decrementIconTemplate() || _decrementIconTemplate()"></ng-template>
|
|
3929
4167
|
</ng-template>
|
|
3930
4168
|
</p-button>
|
|
3931
4169
|
</div>
|
|
3932
|
-
<
|
|
3933
|
-
<
|
|
3934
|
-
<tr [pBind]="ptm('tableHeaderRow')">
|
|
3935
|
-
<th *ngIf="showWeek()" [class]="cx('weekHeader')" [pBind]="ptm('weekHeader')">
|
|
3936
|
-
<span [pBind]="ptm('weekHeaderLabel')">{{ getTranslation('weekHeader') }}</span>
|
|
3937
|
-
</th>
|
|
3938
|
-
<th [class]="cx('weekDayCell')" scope="col" *ngFor="let weekDay of weekDays(); let begin = first; let end = last" [pBind]="ptm('weekDayCell')">
|
|
3939
|
-
<span [class]="cx('weekDay')" [pBind]="ptm('weekDay')">{{ weekDay }}</span>
|
|
3940
|
-
</th>
|
|
3941
|
-
</tr>
|
|
3942
|
-
</thead>
|
|
3943
|
-
<tbody [pBind]="ptm('tableBody')">
|
|
3944
|
-
<tr *ngFor="let week of month.dates; let j = index" [pBind]="ptm('tableBodyRow')">
|
|
3945
|
-
<td *ngIf="showWeek()" [class]="cx('weekNumber')" [pBind]="ptm('weekNumber')">
|
|
3946
|
-
<span [class]="cx('weekLabelContainer')" [pBind]="ptm('weekLabelContainer')">
|
|
3947
|
-
{{ month.weekNumbers[j] }}
|
|
3948
|
-
</span>
|
|
3949
|
-
</td>
|
|
3950
|
-
<td *ngFor="let date of week" [attr.aria-label]="date.day" [class]="cx('dayCell', { date })" [pBind]="ptm('dayCell')">
|
|
3951
|
-
<ng-container *ngIf="date.otherMonth ? showOtherMonths() : true">
|
|
3952
|
-
<span
|
|
3953
|
-
[ngClass]="dayClass(date)"
|
|
3954
|
-
(click)="onDateSelect($event, date)"
|
|
3955
|
-
draggable="false"
|
|
3956
|
-
[attr.data-date]="formatDateKey(formatDateMetaToDate(date))"
|
|
3957
|
-
(keydown)="onDateCellKeydown($event, date, i)"
|
|
3958
|
-
pRipple
|
|
3959
|
-
[pBind]="ptm('day')"
|
|
3960
|
-
>
|
|
3961
|
-
<ng-container *ngIf="!dateTemplate() && !_dateTemplate() && (date.selectable || (!disabledDateTemplate() && !_disabledDateTemplate()))">{{ date.day }}</ng-container>
|
|
3962
|
-
<ng-container *ngIf="date.selectable || (!disabledDateTemplate() && !_disabledDateTemplate())">
|
|
3963
|
-
<ng-container *ngTemplateOutlet="dateTemplate() || _dateTemplate(); context: { $implicit: date }"></ng-container>
|
|
3964
|
-
</ng-container>
|
|
3965
|
-
<ng-container *ngIf="!date.selectable">
|
|
3966
|
-
<ng-container *ngTemplateOutlet="disabledDateTemplate() || _disabledDateTemplate(); context: { $implicit: date }"></ng-container>
|
|
3967
|
-
</ng-container>
|
|
3968
|
-
</span>
|
|
3969
|
-
<div *ngIf="isSelected(date)" class="p-hidden-accessible" aria-live="polite">
|
|
3970
|
-
{{ date.day }}
|
|
3971
|
-
</div>
|
|
3972
|
-
</ng-container>
|
|
3973
|
-
</td>
|
|
3974
|
-
</tr>
|
|
3975
|
-
</tbody>
|
|
3976
|
-
</table>
|
|
3977
|
-
</div>
|
|
3978
|
-
</div>
|
|
3979
|
-
<div [class]="cx('monthView')" *ngIf="currentView() === 'month'" [pBind]="ptm('monthView')">
|
|
3980
|
-
<span *ngFor="let m of monthPickerValues(); let i = index" (click)="onMonthSelect($event, i)" (keydown)="onMonthCellKeydown($event, i)" [class]="cx('month', { month: m, index: i })" pRipple [pBind]="ptm('month')">
|
|
3981
|
-
{{ m }}
|
|
3982
|
-
<div *ngIf="isMonthSelected(i)" class="p-hidden-accessible" aria-live="polite">
|
|
3983
|
-
{{ m }}
|
|
4170
|
+
<div class="p-datepicker-separator" [pBind]="ptm('separatorContainer')">
|
|
4171
|
+
<span [pBind]="ptm('separator')">{{ timeSeparator() }}</span>
|
|
3984
4172
|
</div>
|
|
3985
|
-
|
|
3986
|
-
|
|
3987
|
-
|
|
3988
|
-
|
|
3989
|
-
|
|
3990
|
-
|
|
3991
|
-
|
|
4173
|
+
<div [class]="cx('minutePicker')" [pBind]="ptm('minutePicker')">
|
|
4174
|
+
<p-button
|
|
4175
|
+
rounded
|
|
4176
|
+
variant="text"
|
|
4177
|
+
severity="secondary"
|
|
4178
|
+
[styleClass]="cx('pcIncrementButton')"
|
|
4179
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
4180
|
+
(keydown.enter)="incrementMinute($event)"
|
|
4181
|
+
(keydown.space)="incrementMinute($event)"
|
|
4182
|
+
(mousedown)="onTimePickerElementMouseDown($event, 1, 1)"
|
|
4183
|
+
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
4184
|
+
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
4185
|
+
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
4186
|
+
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
4187
|
+
[attr.aria-label]="getTranslation('nextMinute')"
|
|
4188
|
+
[pt]="ptm('pcIncrementButton')"
|
|
4189
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
4190
|
+
>
|
|
4191
|
+
<ng-template #icon>
|
|
4192
|
+
@if (!incrementIconTemplate() && !_incrementIconTemplate()) {
|
|
4193
|
+
<svg data-p-icon="chevron-up" [pBind]="ptm('pcIncrementButton')['icon']" />
|
|
4194
|
+
}
|
|
4195
|
+
<ng-template *ngTemplateOutlet="incrementIconTemplate() || _incrementIconTemplate()"></ng-template>
|
|
4196
|
+
</ng-template>
|
|
4197
|
+
</p-button>
|
|
4198
|
+
<span [pBind]="ptm('minute')">{{ currentMinute() < 10 ? '0' : '' }}{{ currentMinute() }}</span>
|
|
4199
|
+
<p-button
|
|
4200
|
+
rounded
|
|
4201
|
+
variant="text"
|
|
4202
|
+
severity="secondary"
|
|
4203
|
+
[styleClass]="cx('pcDecrementButton')"
|
|
4204
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
4205
|
+
(keydown.enter)="decrementMinute($event)"
|
|
4206
|
+
(keydown.space)="decrementMinute($event)"
|
|
4207
|
+
(mousedown)="onTimePickerElementMouseDown($event, 1, -1)"
|
|
4208
|
+
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
4209
|
+
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
4210
|
+
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
4211
|
+
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
4212
|
+
[attr.aria-label]="getTranslation('prevMinute')"
|
|
4213
|
+
[pt]="ptm('pcDecrementButton')"
|
|
4214
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
4215
|
+
>
|
|
4216
|
+
<ng-template #icon>
|
|
4217
|
+
@if (!decrementIconTemplate() && !_decrementIconTemplate()) {
|
|
4218
|
+
<svg data-p-icon="chevron-down" [pBind]="ptm('pcDecrementButton')['icon']" />
|
|
4219
|
+
}
|
|
4220
|
+
<ng-template *ngTemplateOutlet="decrementIconTemplate() || _decrementIconTemplate()"></ng-template>
|
|
4221
|
+
</ng-template>
|
|
4222
|
+
</p-button>
|
|
3992
4223
|
</div>
|
|
3993
|
-
|
|
3994
|
-
|
|
3995
|
-
|
|
3996
|
-
|
|
3997
|
-
|
|
3998
|
-
|
|
3999
|
-
|
|
4000
|
-
|
|
4001
|
-
|
|
4002
|
-
|
|
4003
|
-
|
|
4004
|
-
|
|
4005
|
-
|
|
4006
|
-
|
|
4007
|
-
|
|
4008
|
-
|
|
4009
|
-
|
|
4010
|
-
|
|
4011
|
-
|
|
4012
|
-
|
|
4013
|
-
|
|
4014
|
-
|
|
4015
|
-
|
|
4016
|
-
|
|
4017
|
-
|
|
4018
|
-
|
|
4019
|
-
|
|
4020
|
-
|
|
4021
|
-
|
|
4022
|
-
|
|
4023
|
-
|
|
4024
|
-
|
|
4025
|
-
|
|
4026
|
-
|
|
4027
|
-
|
|
4028
|
-
|
|
4029
|
-
|
|
4030
|
-
|
|
4031
|
-
|
|
4032
|
-
|
|
4033
|
-
|
|
4034
|
-
|
|
4035
|
-
|
|
4036
|
-
|
|
4037
|
-
|
|
4038
|
-
|
|
4039
|
-
|
|
4040
|
-
|
|
4041
|
-
|
|
4042
|
-
|
|
4043
|
-
|
|
4044
|
-
|
|
4045
|
-
|
|
4046
|
-
|
|
4047
|
-
|
|
4048
|
-
|
|
4049
|
-
|
|
4050
|
-
|
|
4051
|
-
|
|
4052
|
-
|
|
4053
|
-
|
|
4054
|
-
|
|
4055
|
-
|
|
4056
|
-
(
|
|
4057
|
-
|
|
4058
|
-
|
|
4059
|
-
|
|
4060
|
-
|
|
4061
|
-
|
|
4062
|
-
|
|
4063
|
-
|
|
4064
|
-
|
|
4065
|
-
|
|
4066
|
-
|
|
4067
|
-
|
|
4068
|
-
|
|
4069
|
-
|
|
4070
|
-
|
|
4071
|
-
|
|
4072
|
-
|
|
4073
|
-
|
|
4074
|
-
|
|
4075
|
-
|
|
4076
|
-
|
|
4077
|
-
|
|
4078
|
-
|
|
4079
|
-
|
|
4080
|
-
|
|
4081
|
-
|
|
4082
|
-
|
|
4083
|
-
|
|
4084
|
-
|
|
4085
|
-
|
|
4086
|
-
|
|
4087
|
-
|
|
4088
|
-
|
|
4089
|
-
|
|
4090
|
-
|
|
4091
|
-
|
|
4092
|
-
|
|
4093
|
-
|
|
4094
|
-
|
|
4095
|
-
|
|
4096
|
-
|
|
4097
|
-
|
|
4098
|
-
|
|
4099
|
-
|
|
4100
|
-
variant="text"
|
|
4101
|
-
severity="secondary"
|
|
4102
|
-
[styleClass]="cx('pcIncrementButton')"
|
|
4103
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
4104
|
-
(keydown.enter)="incrementSecond($event)"
|
|
4105
|
-
(keydown.space)="incrementSecond($event)"
|
|
4106
|
-
(mousedown)="onTimePickerElementMouseDown($event, 2, 1)"
|
|
4107
|
-
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
4108
|
-
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
4109
|
-
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
4110
|
-
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
4111
|
-
[attr.aria-label]="getTranslation('nextSecond')"
|
|
4112
|
-
[pt]="ptm('pcIncrementButton')"
|
|
4113
|
-
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
4114
|
-
>
|
|
4115
|
-
<ng-template #icon>
|
|
4116
|
-
<svg data-p-icon="chevron-up" *ngIf="!incrementIconTemplate() && !_incrementIconTemplate()" [pBind]="ptm('pcIncrementButton')['icon']" />
|
|
4117
|
-
<ng-template *ngTemplateOutlet="incrementIconTemplate() || _incrementIconTemplate()"></ng-template>
|
|
4118
|
-
</ng-template>
|
|
4119
|
-
</p-button>
|
|
4120
|
-
<span [pBind]="ptm('second')"><ng-container *ngIf="currentSecond() < 10">0</ng-container>{{ currentSecond() }}</span>
|
|
4121
|
-
<p-button
|
|
4122
|
-
rounded
|
|
4123
|
-
variant="text"
|
|
4124
|
-
severity="secondary"
|
|
4125
|
-
[styleClass]="cx('pcDecrementButton')"
|
|
4126
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
4127
|
-
(keydown.enter)="decrementSecond($event)"
|
|
4128
|
-
(keydown.space)="decrementSecond($event)"
|
|
4129
|
-
(mousedown)="onTimePickerElementMouseDown($event, 2, -1)"
|
|
4130
|
-
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
4131
|
-
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
4132
|
-
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
4133
|
-
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
4134
|
-
[attr.aria-label]="getTranslation('prevSecond')"
|
|
4135
|
-
[pt]="ptm('pcDecrementButton')"
|
|
4136
|
-
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
4137
|
-
>
|
|
4138
|
-
<ng-template #icon>
|
|
4139
|
-
<svg data-p-icon="chevron-down" *ngIf="!decrementIconTemplate() && !_decrementIconTemplate()" [pBind]="ptm('pcDecrementButton')['icon']" />
|
|
4140
|
-
<ng-template *ngTemplateOutlet="decrementIconTemplate() || _decrementIconTemplate()"></ng-template>
|
|
4141
|
-
</ng-template>
|
|
4142
|
-
</p-button>
|
|
4143
|
-
</div>
|
|
4144
|
-
<div [class]="cx('separator')" *ngIf="hourFormat() == '12'" [pBind]="ptm('separatorContainer')">
|
|
4145
|
-
<span [pBind]="ptm('separator')">{{ timeSeparator() }}</span>
|
|
4146
|
-
</div>
|
|
4147
|
-
<div [class]="cx('ampmPicker')" *ngIf="hourFormat() == '12'" [pBind]="ptm('ampmPicker')">
|
|
4148
|
-
<p-button
|
|
4149
|
-
text
|
|
4150
|
-
rounded
|
|
4151
|
-
severity="secondary"
|
|
4152
|
-
[styleClass]="cx('pcIncrementButton')"
|
|
4153
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
4154
|
-
(onClick)="toggleAMPM($event)"
|
|
4155
|
-
(keydown.enter)="toggleAMPM($event)"
|
|
4156
|
-
[attr.aria-label]="getTranslation('am')"
|
|
4157
|
-
[pt]="ptm('pcIncrementButton')"
|
|
4158
|
-
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
4159
|
-
>
|
|
4160
|
-
<ng-template #icon>
|
|
4161
|
-
<svg data-p-icon="chevron-up" *ngIf="!incrementIconTemplate() && !_incrementIconTemplate()" [pBind]="ptm('pcIncrementButton')['icon']" />
|
|
4162
|
-
<ng-template *ngTemplateOutlet="incrementIconTemplate() || _incrementIconTemplate()"></ng-template>
|
|
4163
|
-
</ng-template>
|
|
4164
|
-
</p-button>
|
|
4165
|
-
<span [pBind]="ptm('ampm')">{{ pm() ? 'PM' : 'AM' }}</span>
|
|
4166
|
-
<p-button
|
|
4167
|
-
text
|
|
4168
|
-
rounded
|
|
4169
|
-
severity="secondary"
|
|
4170
|
-
[styleClass]="cx('pcDecrementButton')"
|
|
4171
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
4172
|
-
(click)="toggleAMPM($event)"
|
|
4173
|
-
(keydown.enter)="toggleAMPM($event)"
|
|
4174
|
-
[attr.aria-label]="getTranslation('pm')"
|
|
4175
|
-
[pt]="ptm('pcDecrementButton')"
|
|
4176
|
-
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
4177
|
-
>
|
|
4178
|
-
<ng-template #icon>
|
|
4179
|
-
<svg data-p-icon="chevron-down" *ngIf="!decrementIconTemplate() && !_decrementIconTemplate()" [pBind]="ptm('pcDecrementButton')['icon']" />
|
|
4180
|
-
<ng-template *ngTemplateOutlet="decrementIconTemplate() || _decrementIconTemplate()"></ng-template>
|
|
4181
|
-
</ng-template>
|
|
4182
|
-
</p-button>
|
|
4183
|
-
</div>
|
|
4184
|
-
</div>
|
|
4185
|
-
<div [class]="cx('buttonbar')" *ngIf="showButtonBar()" [pBind]="ptm('buttonbar')">
|
|
4186
|
-
@if (buttonBarTemplate() || _buttonBarTemplate()) {
|
|
4187
|
-
<ng-container *ngTemplateOutlet="buttonBarTemplate() || _buttonBarTemplate(); context: { todayCallback: onTodayButtonClick.bind(this), clearCallback: onClearButtonClick.bind(this) }"></ng-container>
|
|
4188
|
-
} @else {
|
|
4189
|
-
<p-button
|
|
4190
|
-
size="small"
|
|
4191
|
-
[styleClass]="cx('pcTodayButton')"
|
|
4192
|
-
[label]="getTranslation('today')"
|
|
4193
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
4194
|
-
(onClick)="onTodayButtonClick($event)"
|
|
4195
|
-
[ngClass]="todayButtonStyleClass()"
|
|
4196
|
-
severity="secondary"
|
|
4197
|
-
variant="text"
|
|
4198
|
-
size="small"
|
|
4199
|
-
[pt]="ptm('pcTodayButton')"
|
|
4200
|
-
[attr.data-pc-group-section]="'button'"
|
|
4201
|
-
/>
|
|
4202
|
-
<p-button
|
|
4203
|
-
size="small"
|
|
4204
|
-
[styleClass]="cx('pcClearButton')"
|
|
4205
|
-
[label]="getTranslation('clear')"
|
|
4206
|
-
(keydown)="onContainerButtonKeydown($event)"
|
|
4207
|
-
(onClick)="onClearButtonClick($event)"
|
|
4208
|
-
[ngClass]="clearButtonStyleClass()"
|
|
4209
|
-
severity="secondary"
|
|
4210
|
-
variant="text"
|
|
4211
|
-
size="small"
|
|
4212
|
-
[pt]="ptm('pcClearButton')"
|
|
4213
|
-
[attr.data-pc-group-section]="'button'"
|
|
4214
|
-
/>
|
|
4224
|
+
@if (showSeconds()) {
|
|
4225
|
+
<div [class]="cx('separator')" [pBind]="ptm('separatorContainer')">
|
|
4226
|
+
<span [pBind]="ptm('separator')">{{ timeSeparator() }}</span>
|
|
4227
|
+
</div>
|
|
4228
|
+
}
|
|
4229
|
+
@if (showSeconds()) {
|
|
4230
|
+
<div [class]="cx('secondPicker')" [pBind]="ptm('secondPicker')">
|
|
4231
|
+
<p-button
|
|
4232
|
+
rounded
|
|
4233
|
+
variant="text"
|
|
4234
|
+
severity="secondary"
|
|
4235
|
+
[styleClass]="cx('pcIncrementButton')"
|
|
4236
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
4237
|
+
(keydown.enter)="incrementSecond($event)"
|
|
4238
|
+
(keydown.space)="incrementSecond($event)"
|
|
4239
|
+
(mousedown)="onTimePickerElementMouseDown($event, 2, 1)"
|
|
4240
|
+
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
4241
|
+
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
4242
|
+
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
4243
|
+
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
4244
|
+
[attr.aria-label]="getTranslation('nextSecond')"
|
|
4245
|
+
[pt]="ptm('pcIncrementButton')"
|
|
4246
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
4247
|
+
>
|
|
4248
|
+
<ng-template #icon>
|
|
4249
|
+
@if (!incrementIconTemplate() && !_incrementIconTemplate()) {
|
|
4250
|
+
<svg data-p-icon="chevron-up" [pBind]="ptm('pcIncrementButton')['icon']" />
|
|
4251
|
+
}
|
|
4252
|
+
<ng-template *ngTemplateOutlet="incrementIconTemplate() || _incrementIconTemplate()"></ng-template>
|
|
4253
|
+
</ng-template>
|
|
4254
|
+
</p-button>
|
|
4255
|
+
<span [pBind]="ptm('second')">{{ currentSecond() < 10 ? '0' : '' }}{{ currentSecond() }}</span>
|
|
4256
|
+
<p-button
|
|
4257
|
+
rounded
|
|
4258
|
+
variant="text"
|
|
4259
|
+
severity="secondary"
|
|
4260
|
+
[styleClass]="cx('pcDecrementButton')"
|
|
4261
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
4262
|
+
(keydown.enter)="decrementSecond($event)"
|
|
4263
|
+
(keydown.space)="decrementSecond($event)"
|
|
4264
|
+
(mousedown)="onTimePickerElementMouseDown($event, 2, -1)"
|
|
4265
|
+
(mouseup)="onTimePickerElementMouseUp($event)"
|
|
4266
|
+
(keyup.enter)="onTimePickerElementMouseUp($event)"
|
|
4267
|
+
(keyup.space)="onTimePickerElementMouseUp($event)"
|
|
4268
|
+
(mouseleave)="onTimePickerElementMouseLeave()"
|
|
4269
|
+
[attr.aria-label]="getTranslation('prevSecond')"
|
|
4270
|
+
[pt]="ptm('pcDecrementButton')"
|
|
4271
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
4272
|
+
>
|
|
4273
|
+
<ng-template #icon>
|
|
4274
|
+
@if (!decrementIconTemplate() && !_decrementIconTemplate()) {
|
|
4275
|
+
<svg data-p-icon="chevron-down" [pBind]="ptm('pcDecrementButton')['icon']" />
|
|
4276
|
+
}
|
|
4277
|
+
<ng-template *ngTemplateOutlet="decrementIconTemplate() || _decrementIconTemplate()"></ng-template>
|
|
4278
|
+
</ng-template>
|
|
4279
|
+
</p-button>
|
|
4280
|
+
</div>
|
|
4281
|
+
}
|
|
4282
|
+
@if (hourFormat() == '12') {
|
|
4283
|
+
<div [class]="cx('separator')" [pBind]="ptm('separatorContainer')">
|
|
4284
|
+
<span [pBind]="ptm('separator')">{{ timeSeparator() }}</span>
|
|
4285
|
+
</div>
|
|
4286
|
+
}
|
|
4287
|
+
@if (hourFormat() == '12') {
|
|
4288
|
+
<div [class]="cx('ampmPicker')" [pBind]="ptm('ampmPicker')">
|
|
4289
|
+
<p-button
|
|
4290
|
+
text
|
|
4291
|
+
rounded
|
|
4292
|
+
severity="secondary"
|
|
4293
|
+
[styleClass]="cx('pcIncrementButton')"
|
|
4294
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
4295
|
+
(onClick)="toggleAMPM($event)"
|
|
4296
|
+
(keydown.enter)="toggleAMPM($event)"
|
|
4297
|
+
[attr.aria-label]="getTranslation('am')"
|
|
4298
|
+
[pt]="ptm('pcIncrementButton')"
|
|
4299
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
4300
|
+
>
|
|
4301
|
+
<ng-template #icon>
|
|
4302
|
+
@if (!incrementIconTemplate() && !_incrementIconTemplate()) {
|
|
4303
|
+
<svg data-p-icon="chevron-up" [pBind]="ptm('pcIncrementButton')['icon']" />
|
|
4304
|
+
}
|
|
4305
|
+
<ng-template *ngTemplateOutlet="incrementIconTemplate() || _incrementIconTemplate()"></ng-template>
|
|
4306
|
+
</ng-template>
|
|
4307
|
+
</p-button>
|
|
4308
|
+
<span [pBind]="ptm('ampm')">{{ pm() ? 'PM' : 'AM' }}</span>
|
|
4309
|
+
<p-button
|
|
4310
|
+
text
|
|
4311
|
+
rounded
|
|
4312
|
+
severity="secondary"
|
|
4313
|
+
[styleClass]="cx('pcDecrementButton')"
|
|
4314
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
4315
|
+
(click)="toggleAMPM($event)"
|
|
4316
|
+
(keydown.enter)="toggleAMPM($event)"
|
|
4317
|
+
[attr.aria-label]="getTranslation('pm')"
|
|
4318
|
+
[pt]="ptm('pcDecrementButton')"
|
|
4319
|
+
[attr.data-pc-group-section]="'timepickerbutton'"
|
|
4320
|
+
>
|
|
4321
|
+
<ng-template #icon>
|
|
4322
|
+
@if (!decrementIconTemplate() && !_decrementIconTemplate()) {
|
|
4323
|
+
<svg data-p-icon="chevron-down" [pBind]="ptm('pcDecrementButton')['icon']" />
|
|
4324
|
+
}
|
|
4325
|
+
<ng-template *ngTemplateOutlet="decrementIconTemplate() || _decrementIconTemplate()"></ng-template>
|
|
4326
|
+
</ng-template>
|
|
4327
|
+
</p-button>
|
|
4328
|
+
</div>
|
|
4329
|
+
}
|
|
4330
|
+
</div>
|
|
4215
4331
|
}
|
|
4332
|
+
@if (showButtonBar()) {
|
|
4333
|
+
<div [class]="cx('buttonbar')" [pBind]="ptm('buttonbar')">
|
|
4334
|
+
@if (buttonBarTemplate() || _buttonBarTemplate()) {
|
|
4335
|
+
<ng-container *ngTemplateOutlet="buttonBarTemplate() || _buttonBarTemplate(); context: { todayCallback: onTodayButtonClick.bind(this), clearCallback: onClearButtonClick.bind(this) }"></ng-container>
|
|
4336
|
+
} @else {
|
|
4337
|
+
<p-button
|
|
4338
|
+
size="small"
|
|
4339
|
+
[styleClass]="cx('pcTodayButton')"
|
|
4340
|
+
[label]="getTranslation('today')"
|
|
4341
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
4342
|
+
(onClick)="onTodayButtonClick($event)"
|
|
4343
|
+
[ngClass]="todayButtonStyleClass()"
|
|
4344
|
+
severity="secondary"
|
|
4345
|
+
variant="text"
|
|
4346
|
+
size="small"
|
|
4347
|
+
[pt]="ptm('pcTodayButton')"
|
|
4348
|
+
[attr.data-pc-group-section]="'button'"
|
|
4349
|
+
/>
|
|
4350
|
+
<p-button
|
|
4351
|
+
size="small"
|
|
4352
|
+
[styleClass]="cx('pcClearButton')"
|
|
4353
|
+
[label]="getTranslation('clear')"
|
|
4354
|
+
(keydown)="onContainerButtonKeydown($event)"
|
|
4355
|
+
(onClick)="onClearButtonClick($event)"
|
|
4356
|
+
[ngClass]="clearButtonStyleClass()"
|
|
4357
|
+
severity="secondary"
|
|
4358
|
+
variant="text"
|
|
4359
|
+
size="small"
|
|
4360
|
+
[pt]="ptm('pcClearButton')"
|
|
4361
|
+
[attr.data-pc-group-section]="'button'"
|
|
4362
|
+
/>
|
|
4363
|
+
}
|
|
4364
|
+
</div>
|
|
4365
|
+
}
|
|
4366
|
+
<ng-content select="p-footer"></ng-content>
|
|
4367
|
+
<ng-container *ngTemplateOutlet="footerTemplate() || _footerTemplate()"></ng-container>
|
|
4216
4368
|
</div>
|
|
4217
|
-
|
|
4218
|
-
|
|
4219
|
-
</div>
|
|
4220
|
-
</p-motion>
|
|
4369
|
+
</p-motion>
|
|
4370
|
+
}
|
|
4221
4371
|
`,
|
|
4222
4372
|
providers: [DATEPICKER_VALUE_ACCESSOR, DatePickerStyle, { provide: DATEPICKER_INSTANCE, useExisting: DatePicker }, { provide: PARENT_INSTANCE, useExisting: DatePicker }],
|
|
4223
4373
|
changeDetection: ChangeDetectionStrategy.OnPush,
|