@radix-ng/primitives 0.50.0 → 0.51.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/collection/README.md +1 -0
- package/fesm2022/radix-ng-primitives-accordion.mjs +41 -40
- package/fesm2022/radix-ng-primitives-accordion.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-alert-dialog.mjs +22 -22
- package/fesm2022/radix-ng-primitives-alert-dialog.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-arrow.mjs +6 -6
- package/fesm2022/radix-ng-primitives-arrow.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-aspect-ratio.mjs +6 -6
- package/fesm2022/radix-ng-primitives-aspect-ratio.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-avatar.mjs +22 -22
- package/fesm2022/radix-ng-primitives-avatar.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-calendar.mjs +104 -103
- package/fesm2022/radix-ng-primitives-calendar.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-checkbox.mjs +51 -41
- package/fesm2022/radix-ng-primitives-checkbox.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-collapsible.mjs +28 -28
- package/fesm2022/radix-ng-primitives-collapsible.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-collection.mjs +89 -0
- package/fesm2022/radix-ng-primitives-collection.mjs.map +1 -0
- package/fesm2022/radix-ng-primitives-config.mjs +5 -5
- package/fesm2022/radix-ng-primitives-config.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-context-menu.mjs +36 -36
- package/fesm2022/radix-ng-primitives-context-menu.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-core.mjs +33 -24
- package/fesm2022/radix-ng-primitives-core.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-cropper.mjs +54 -53
- package/fesm2022/radix-ng-primitives-cropper.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-date-field.mjs +48 -47
- package/fesm2022/radix-ng-primitives-date-field.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-dialog.mjs +34 -34
- package/fesm2022/radix-ng-primitives-dialog.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-dismissable-layer.mjs +31 -33
- package/fesm2022/radix-ng-primitives-dismissable-layer.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-dropdown-menu.mjs +41 -43
- package/fesm2022/radix-ng-primitives-dropdown-menu.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-editable.mjs +20 -20
- package/fesm2022/radix-ng-primitives-editable.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-focus-guards.mjs +3 -3
- package/fesm2022/radix-ng-primitives-focus-guards.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-focus-scope.mjs +7 -7
- package/fesm2022/radix-ng-primitives-focus-scope.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-hover-card.mjs +69 -77
- package/fesm2022/radix-ng-primitives-hover-card.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-label.mjs +7 -7
- package/fesm2022/radix-ng-primitives-label.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-menu.mjs +65 -70
- package/fesm2022/radix-ng-primitives-menu.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-menubar.mjs +31 -31
- package/fesm2022/radix-ng-primitives-menubar.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-navigation-menu.mjs +113 -105
- package/fesm2022/radix-ng-primitives-navigation-menu.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-number-field.mjs +48 -47
- package/fesm2022/radix-ng-primitives-number-field.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-pagination.mjs +51 -51
- package/fesm2022/radix-ng-primitives-pagination.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-popover.mjs +67 -71
- package/fesm2022/radix-ng-primitives-popover.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-popper.mjs +61 -56
- package/fesm2022/radix-ng-primitives-popper.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-portal.mjs +7 -7
- package/fesm2022/radix-ng-primitives-portal.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-presence.mjs +4 -4
- package/fesm2022/radix-ng-primitives-presence.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-progress.mjs +16 -16
- package/fesm2022/radix-ng-primitives-progress.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-radio.mjs +38 -37
- package/fesm2022/radix-ng-primitives-radio.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-roving-focus.mjs +38 -34
- package/fesm2022/radix-ng-primitives-roving-focus.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-select.mjs +41 -43
- package/fesm2022/radix-ng-primitives-select.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-select2.mjs +897 -0
- package/fesm2022/radix-ng-primitives-select2.mjs.map +1 -0
- package/fesm2022/radix-ng-primitives-separator.mjs +11 -17
- package/fesm2022/radix-ng-primitives-separator.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-slider.mjs +88 -84
- package/fesm2022/radix-ng-primitives-slider.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-stepper.mjs +55 -53
- package/fesm2022/radix-ng-primitives-stepper.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-switch.mjs +22 -30
- package/fesm2022/radix-ng-primitives-switch.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-tabs.mjs +38 -38
- package/fesm2022/radix-ng-primitives-tabs.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-time-field.mjs +63 -78
- package/fesm2022/radix-ng-primitives-time-field.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-toggle-group.mjs +24 -24
- package/fesm2022/radix-ng-primitives-toggle-group.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-toggle.mjs +11 -11
- package/fesm2022/radix-ng-primitives-toggle.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-toolbar.mjs +31 -29
- package/fesm2022/radix-ng-primitives-toolbar.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-tooltip.mjs +69 -77
- package/fesm2022/radix-ng-primitives-tooltip.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-tooltip2.mjs +57 -62
- package/fesm2022/radix-ng-primitives-tooltip2.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-visually-hidden.mjs +31 -31
- package/fesm2022/radix-ng-primitives-visually-hidden.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives.mjs.map +1 -1
- package/package.json +63 -54
- package/select2/README.md +3 -0
- package/{accordion/index.d.ts → types/radix-ng-primitives-accordion.d.ts} +61 -60
- package/{calendar/index.d.ts → types/radix-ng-primitives-calendar.d.ts} +1 -1
- package/{checkbox/index.d.ts → types/radix-ng-primitives-checkbox.d.ts} +31 -27
- package/{collapsible/index.d.ts → types/radix-ng-primitives-collapsible.d.ts} +20 -19
- package/types/radix-ng-primitives-collection.d.ts +40 -0
- package/{core/index.d.ts → types/radix-ng-primitives-core.d.ts} +6 -2
- package/{cropper/index.d.ts → types/radix-ng-primitives-cropper.d.ts} +4 -3
- package/{date-field/index.d.ts → types/radix-ng-primitives-date-field.d.ts} +4 -4
- package/{dialog/index.d.ts → types/radix-ng-primitives-dialog.d.ts} +2 -1
- package/{hover-card/index.d.ts → types/radix-ng-primitives-hover-card.d.ts} +3 -4
- package/{menu/index.d.ts → types/radix-ng-primitives-menu.d.ts} +1 -1
- package/{navigation-menu/index.d.ts → types/radix-ng-primitives-navigation-menu.d.ts} +47 -46
- package/{number-field/index.d.ts → types/radix-ng-primitives-number-field.d.ts} +13 -12
- package/{popover/index.d.ts → types/radix-ng-primitives-popover.d.ts} +3 -4
- package/{popper/index.d.ts → types/radix-ng-primitives-popper.d.ts} +1 -0
- package/{progress/index.d.ts → types/radix-ng-primitives-progress.d.ts} +2 -1
- package/{radio/index.d.ts → types/radix-ng-primitives-radio.d.ts} +1 -1
- package/{roving-focus/index.d.ts → types/radix-ng-primitives-roving-focus.d.ts} +8 -6
- package/types/radix-ng-primitives-select2.d.ts +511 -0
- package/{slider/index.d.ts → types/radix-ng-primitives-slider.d.ts} +4 -4
- package/{stepper/index.d.ts → types/radix-ng-primitives-stepper.d.ts} +17 -16
- package/{switch/index.d.ts → types/radix-ng-primitives-switch.d.ts} +3 -2
- package/{tabs/index.d.ts → types/radix-ng-primitives-tabs.d.ts} +7 -6
- package/{time-field/index.d.ts → types/radix-ng-primitives-time-field.d.ts} +4 -4
- package/{toggle-group/index.d.ts → types/radix-ng-primitives-toggle-group.d.ts} +12 -11
- package/{tooltip/index.d.ts → types/radix-ng-primitives-tooltip.d.ts} +3 -4
- package/{tooltip2/index.d.ts → types/radix-ng-primitives-tooltip2.d.ts} +4 -4
- /package/{alert-dialog/index.d.ts → types/radix-ng-primitives-alert-dialog.d.ts} +0 -0
- /package/{arrow/index.d.ts → types/radix-ng-primitives-arrow.d.ts} +0 -0
- /package/{aspect-ratio/index.d.ts → types/radix-ng-primitives-aspect-ratio.d.ts} +0 -0
- /package/{avatar/index.d.ts → types/radix-ng-primitives-avatar.d.ts} +0 -0
- /package/{config/index.d.ts → types/radix-ng-primitives-config.d.ts} +0 -0
- /package/{context-menu/index.d.ts → types/radix-ng-primitives-context-menu.d.ts} +0 -0
- /package/{dismissable-layer/index.d.ts → types/radix-ng-primitives-dismissable-layer.d.ts} +0 -0
- /package/{dropdown-menu/index.d.ts → types/radix-ng-primitives-dropdown-menu.d.ts} +0 -0
- /package/{editable/index.d.ts → types/radix-ng-primitives-editable.d.ts} +0 -0
- /package/{focus-guards/index.d.ts → types/radix-ng-primitives-focus-guards.d.ts} +0 -0
- /package/{focus-scope/index.d.ts → types/radix-ng-primitives-focus-scope.d.ts} +0 -0
- /package/{label/index.d.ts → types/radix-ng-primitives-label.d.ts} +0 -0
- /package/{menubar/index.d.ts → types/radix-ng-primitives-menubar.d.ts} +0 -0
- /package/{pagination/index.d.ts → types/radix-ng-primitives-pagination.d.ts} +0 -0
- /package/{portal/index.d.ts → types/radix-ng-primitives-portal.d.ts} +0 -0
- /package/{presence/index.d.ts → types/radix-ng-primitives-presence.d.ts} +0 -0
- /package/{select/index.d.ts → types/radix-ng-primitives-select.d.ts} +0 -0
- /package/{separator/index.d.ts → types/radix-ng-primitives-separator.d.ts} +0 -0
- /package/{toggle/index.d.ts → types/radix-ng-primitives-toggle.d.ts} +0 -0
- /package/{toolbar/index.d.ts → types/radix-ng-primitives-toolbar.d.ts} +0 -0
- /package/{visually-hidden/index.d.ts → types/radix-ng-primitives-visually-hidden.d.ts} +0 -0
- /package/{index.d.ts → types/radix-ng-primitives.d.ts} +0 -0
|
@@ -16,33 +16,33 @@ class RdxCalendarCellTriggerDirective {
|
|
|
16
16
|
/**
|
|
17
17
|
* The date value provided to the cell trigger
|
|
18
18
|
*/
|
|
19
|
-
this.day = input(...(ngDevMode ? [undefined, { debugName: "day" }] : []));
|
|
19
|
+
this.day = input(...(ngDevMode ? [undefined, { debugName: "day" }] : /* istanbul ignore next */ []));
|
|
20
20
|
/**
|
|
21
21
|
* The month in which the cell is rendered
|
|
22
22
|
*/
|
|
23
|
-
this.month = input(...(ngDevMode ? [undefined, { debugName: "month" }] : []));
|
|
23
|
+
this.month = input(...(ngDevMode ? [undefined, { debugName: "month" }] : /* istanbul ignore next */ []));
|
|
24
24
|
/**
|
|
25
25
|
* Current day
|
|
26
26
|
*/
|
|
27
|
-
this.dayValue = computed(() => this.day()?.day.toLocaleString(), ...(ngDevMode ? [{ debugName: "dayValue" }] : []));
|
|
27
|
+
this.dayValue = computed(() => this.day()?.day.toLocaleString(), ...(ngDevMode ? [{ debugName: "dayValue" }] : /* istanbul ignore next */ []));
|
|
28
28
|
/**
|
|
29
29
|
* Current today state
|
|
30
30
|
*/
|
|
31
31
|
this.isDateToday = computed(() => {
|
|
32
32
|
return isToday(this.day(), getLocalTimeZone());
|
|
33
|
-
}, ...(ngDevMode ? [{ debugName: "isDateToday" }] : []));
|
|
33
|
+
}, ...(ngDevMode ? [{ debugName: "isDateToday" }] : /* istanbul ignore next */ []));
|
|
34
34
|
/**
|
|
35
35
|
* Current selected state
|
|
36
36
|
*/
|
|
37
|
-
this.isSelectedDate = computed(() => this.rootContext.isDateSelected(this.day()), ...(ngDevMode ? [{ debugName: "isSelectedDate" }] : []));
|
|
38
|
-
this.isDisabled = computed(() => this.rootContext.isDateDisabled(this.day()), ...(ngDevMode ? [{ debugName: "isDisabled" }] : []));
|
|
37
|
+
this.isSelectedDate = computed(() => this.rootContext.isDateSelected(this.day()), ...(ngDevMode ? [{ debugName: "isSelectedDate" }] : /* istanbul ignore next */ []));
|
|
38
|
+
this.isDisabled = computed(() => this.rootContext.isDateDisabled(this.day()), ...(ngDevMode ? [{ debugName: "isDisabled" }] : /* istanbul ignore next */ []));
|
|
39
39
|
this.isOutsideView = computed(() => {
|
|
40
40
|
return !isSameMonth(this.day(), this.month());
|
|
41
|
-
}, ...(ngDevMode ? [{ debugName: "isOutsideView" }] : []));
|
|
41
|
+
}, ...(ngDevMode ? [{ debugName: "isOutsideView" }] : /* istanbul ignore next */ []));
|
|
42
42
|
this.isFocusedDate = computed(() => {
|
|
43
43
|
return !this.rootContext.disabled() && isSameDay(this.day(), this.rootContext.placeholder());
|
|
44
|
-
}, ...(ngDevMode ? [{ debugName: "isFocusedDate" }] : []));
|
|
45
|
-
this.isUnavailable = computed(() => this.rootContext.isDateUnavailable?.(this.day()) ?? false, ...(ngDevMode ? [{ debugName: "isUnavailable" }] : []));
|
|
44
|
+
}, ...(ngDevMode ? [{ debugName: "isFocusedDate" }] : /* istanbul ignore next */ []));
|
|
45
|
+
this.isUnavailable = computed(() => this.rootContext.isDateUnavailable?.(this.day()) ?? false, ...(ngDevMode ? [{ debugName: "isUnavailable" }] : /* istanbul ignore next */ []));
|
|
46
46
|
this.labelText = computed(() => {
|
|
47
47
|
return this.rootContext.formatter.custom(toDate(this.day()), {
|
|
48
48
|
weekday: 'long',
|
|
@@ -50,7 +50,7 @@ class RdxCalendarCellTriggerDirective {
|
|
|
50
50
|
day: 'numeric',
|
|
51
51
|
year: 'numeric'
|
|
52
52
|
});
|
|
53
|
-
}, ...(ngDevMode ? [{ debugName: "labelText" }] : []));
|
|
53
|
+
}, ...(ngDevMode ? [{ debugName: "labelText" }] : /* istanbul ignore next */ []));
|
|
54
54
|
/**
|
|
55
55
|
* @ignore
|
|
56
56
|
*/
|
|
@@ -63,7 +63,8 @@ class RdxCalendarCellTriggerDirective {
|
|
|
63
63
|
this.changeDate(this.day());
|
|
64
64
|
}
|
|
65
65
|
onArrowKey(event) {
|
|
66
|
-
const
|
|
66
|
+
const keyEvent = event;
|
|
67
|
+
const code = keyEvent.code;
|
|
67
68
|
if (![kbd.ARROW_RIGHT, kbd.ARROW_LEFT, kbd.ARROW_UP, kbd.ARROW_DOWN, kbd.ENTER, kbd.SPACE_CODE].includes(code)) {
|
|
68
69
|
return;
|
|
69
70
|
}
|
|
@@ -165,10 +166,10 @@ class RdxCalendarCellTriggerDirective {
|
|
|
165
166
|
changeDate(date) {
|
|
166
167
|
this.rootContext.onDateChange(date);
|
|
167
168
|
}
|
|
168
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
169
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
169
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarCellTriggerDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
170
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.9", type: RdxCalendarCellTriggerDirective, isStandalone: true, selector: "[rdxCalendarCellTrigger]", inputs: { day: { classPropertyName: "day", publicName: "day", isSignal: true, isRequired: false, transformFunction: null }, month: { classPropertyName: "month", publicName: "month", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "button" }, listeners: { "click": "onClick()", "keydown": "onArrowKey($event)" }, properties: { "attr.aria-label": "labelText()", "attr.aria-disabled": "isDisabled() || isUnavailable() ? true : undefined", "attr.data-rdx-calendar-cell-trigger": "\"\"", "attr.tabindex": "isFocusedDate() ? 0 : isOutsideView() || isDisabled() ? undefined : -1", "attr.data-value": "day()?.toString()", "attr.data-disabled": "isDisabled() ? \"\" : undefined", "attr.data-today": "isDateToday() ? \"\" : undefined", "attr.data-outside-view": "isOutsideView() ? \"\" : undefined", "attr.data-selected": "isSelectedDate() ? \"\" : undefined", "attr.data-unavailable": "isUnavailable() ? \"\" : undefined", "attr.data-focus": "isFocusedDate() ? \"\" : undefined" } }, exportAs: ["rdxCalendarCellTrigger"], ngImport: i0 }); }
|
|
170
171
|
}
|
|
171
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
172
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarCellTriggerDirective, decorators: [{
|
|
172
173
|
type: Directive,
|
|
173
174
|
args: [{
|
|
174
175
|
selector: '[rdxCalendarCellTrigger]',
|
|
@@ -190,7 +191,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImpor
|
|
|
190
191
|
'(keydown)': 'onArrowKey($event)'
|
|
191
192
|
}
|
|
192
193
|
}]
|
|
193
|
-
}] });
|
|
194
|
+
}], propDecorators: { day: [{ type: i0.Input, args: [{ isSignal: true, alias: "day", required: false }] }], month: [{ type: i0.Input, args: [{ isSignal: true, alias: "month", required: false }] }] } });
|
|
194
195
|
|
|
195
196
|
class RdxCalendarCellDirective {
|
|
196
197
|
constructor() {
|
|
@@ -198,12 +199,12 @@ class RdxCalendarCellDirective {
|
|
|
198
199
|
/**
|
|
199
200
|
* The date of the cell
|
|
200
201
|
*/
|
|
201
|
-
this.date = input(...(ngDevMode ? [undefined, { debugName: "date" }] : []));
|
|
202
|
+
this.date = input(...(ngDevMode ? [undefined, { debugName: "date" }] : /* istanbul ignore next */ []));
|
|
202
203
|
}
|
|
203
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
204
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
204
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarCellDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
205
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.9", type: RdxCalendarCellDirective, isStandalone: true, selector: "td[rdxCalendarCell]", inputs: { date: { classPropertyName: "date", publicName: "date", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "gridcell" }, properties: { "attr.aria-selected": "rootContext.isDateSelected?.(date()!) ? true : undefined", "attr.aria-disabled": "rootContext.isDateSelected?.(date()!) || rootContext.isDateUnavailable?.(date()!)", "attr.data-disabled": "rootContext.isDateSelected?.(date()!) ? \"\" : undefined" } }, ngImport: i0 }); }
|
|
205
206
|
}
|
|
206
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
207
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarCellDirective, decorators: [{
|
|
207
208
|
type: Directive,
|
|
208
209
|
args: [{
|
|
209
210
|
selector: 'td[rdxCalendarCell]',
|
|
@@ -214,13 +215,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImpor
|
|
|
214
215
|
'[attr.data-disabled]': 'rootContext.isDateSelected?.(date()!) ? "" : undefined'
|
|
215
216
|
}
|
|
216
217
|
}]
|
|
217
|
-
}] });
|
|
218
|
+
}], propDecorators: { date: [{ type: i0.Input, args: [{ isSignal: true, alias: "date", required: false }] }] } });
|
|
218
219
|
|
|
219
220
|
class RdxCalendarGridBodyDirective {
|
|
220
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
221
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
221
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarGridBodyDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
222
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.9", type: RdxCalendarGridBodyDirective, isStandalone: true, selector: "tbody[rdxCalendarGridBody]", ngImport: i0 }); }
|
|
222
223
|
}
|
|
223
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
224
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarGridBodyDirective, decorators: [{
|
|
224
225
|
type: Directive,
|
|
225
226
|
args: [{
|
|
226
227
|
selector: 'tbody[rdxCalendarGridBody]'
|
|
@@ -228,10 +229,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImpor
|
|
|
228
229
|
}] });
|
|
229
230
|
|
|
230
231
|
class RdxCalendarGridHeadDirective {
|
|
231
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
232
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
232
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarGridHeadDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
233
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.9", type: RdxCalendarGridHeadDirective, isStandalone: true, selector: "thead[rdxCalendarGridHead]", host: { properties: { "attr.aria-hidden": "true" } }, ngImport: i0 }); }
|
|
233
234
|
}
|
|
234
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
235
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarGridHeadDirective, decorators: [{
|
|
235
236
|
type: Directive,
|
|
236
237
|
args: [{
|
|
237
238
|
selector: 'thead[rdxCalendarGridHead]',
|
|
@@ -242,10 +243,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImpor
|
|
|
242
243
|
}] });
|
|
243
244
|
|
|
244
245
|
class RdxCalendarGridRowDirective {
|
|
245
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
246
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
246
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarGridRowDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
247
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.9", type: RdxCalendarGridRowDirective, isStandalone: true, selector: "tr[rdxCalendarGridRow]", ngImport: i0 }); }
|
|
247
248
|
}
|
|
248
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
249
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarGridRowDirective, decorators: [{
|
|
249
250
|
type: Directive,
|
|
250
251
|
args: [{
|
|
251
252
|
selector: 'tr[rdxCalendarGridRow]'
|
|
@@ -255,13 +256,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImpor
|
|
|
255
256
|
class RdxCalendarGridDirective {
|
|
256
257
|
constructor() {
|
|
257
258
|
this.rootContext = injectCalendarRootContext();
|
|
258
|
-
this.disabled = computed(() => (this.rootContext.disabled() ? true : undefined), ...(ngDevMode ? [{ debugName: "disabled" }] : []));
|
|
259
|
-
this.readonly = computed(() => (this.rootContext.readonly ? true : undefined), ...(ngDevMode ? [{ debugName: "readonly" }] : []));
|
|
259
|
+
this.disabled = computed(() => (this.rootContext.disabled() ? true : undefined), ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
|
|
260
|
+
this.readonly = computed(() => (this.rootContext.readonly ? true : undefined), ...(ngDevMode ? [{ debugName: "readonly" }] : /* istanbul ignore next */ []));
|
|
260
261
|
}
|
|
261
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
262
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
262
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarGridDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
263
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.9", type: RdxCalendarGridDirective, isStandalone: true, selector: "table[rdxCalendarGrid]", host: { attributes: { "tabindex": "-1", "role": "grid" }, properties: { "attr.aria-readonly": "readonly()", "attr.aria-disabled": "disabled()", "attr.data-readonly": "readonly() && \"\"", "attr.data-disabled": "disabled() && \"\"" } }, ngImport: i0 }); }
|
|
263
264
|
}
|
|
264
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
265
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarGridDirective, decorators: [{
|
|
265
266
|
type: Directive,
|
|
266
267
|
args: [{
|
|
267
268
|
selector: 'table[rdxCalendarGrid]',
|
|
@@ -277,10 +278,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImpor
|
|
|
277
278
|
}] });
|
|
278
279
|
|
|
279
280
|
class RdxCalendarHeadCellDirective {
|
|
280
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
281
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
281
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarHeadCellDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
282
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.9", type: RdxCalendarHeadCellDirective, isStandalone: true, selector: "th[rdxCalendarHeadCell]", ngImport: i0 }); }
|
|
282
283
|
}
|
|
283
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
284
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarHeadCellDirective, decorators: [{
|
|
284
285
|
type: Directive,
|
|
285
286
|
args: [{
|
|
286
287
|
selector: 'th[rdxCalendarHeadCell]'
|
|
@@ -288,10 +289,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImpor
|
|
|
288
289
|
}] });
|
|
289
290
|
|
|
290
291
|
class RdxCalendarHeaderDirective {
|
|
291
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
292
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
292
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarHeaderDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
293
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.9", type: RdxCalendarHeaderDirective, isStandalone: true, selector: "div[rdxCalendarHeader]", ngImport: i0 }); }
|
|
293
294
|
}
|
|
294
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
295
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarHeaderDirective, decorators: [{
|
|
295
296
|
type: Directive,
|
|
296
297
|
args: [{
|
|
297
298
|
selector: 'div[rdxCalendarHeader]'
|
|
@@ -301,12 +302,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImpor
|
|
|
301
302
|
class RdxCalendarHeadingDirective {
|
|
302
303
|
constructor() {
|
|
303
304
|
this.rootContext = injectCalendarRootContext();
|
|
304
|
-
this.headingValue = computed(() => this.rootContext.headingValue(), ...(ngDevMode ? [{ debugName: "headingValue" }] : []));
|
|
305
|
+
this.headingValue = computed(() => this.rootContext.headingValue(), ...(ngDevMode ? [{ debugName: "headingValue" }] : /* istanbul ignore next */ []));
|
|
305
306
|
}
|
|
306
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
307
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
307
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarHeadingDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
308
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.9", type: RdxCalendarHeadingDirective, isStandalone: true, selector: "div[rdxCalendarHeading]", host: { properties: { "attr.data-disabled": "rootContext.disabled() ? \"\" : undefined" } }, exportAs: ["rdxCalendarHeading"], ngImport: i0 }); }
|
|
308
309
|
}
|
|
309
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
310
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarHeadingDirective, decorators: [{
|
|
310
311
|
type: Directive,
|
|
311
312
|
args: [{
|
|
312
313
|
selector: 'div[rdxCalendarHeading]',
|
|
@@ -323,32 +324,32 @@ class RdxCalendarNextDirective {
|
|
|
323
324
|
/**
|
|
324
325
|
* The function to be used for the `next page`. Overwrites the nextPage function set on the `CalendarRoot`.
|
|
325
326
|
*/
|
|
326
|
-
this.nextPage = input(...(ngDevMode ? [undefined, { debugName: "nextPage" }] : []));
|
|
327
|
+
this.nextPage = input(...(ngDevMode ? [undefined, { debugName: "nextPage" }] : /* istanbul ignore next */ []));
|
|
327
328
|
/**
|
|
328
329
|
* @ignore
|
|
329
330
|
*/
|
|
330
|
-
this.disabled = computed(() => this.rootContext.disabled() || this.rootContext.isNextButtonDisabled(this.nextPage()), ...(ngDevMode ? [{ debugName: "disabled" }] : []));
|
|
331
|
+
this.disabled = computed(() => this.rootContext.disabled() || this.rootContext.isNextButtonDisabled(this.nextPage()), ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
|
|
331
332
|
}
|
|
332
333
|
onClick() {
|
|
333
334
|
this.rootContext.nextPage(this.nextPage());
|
|
334
335
|
}
|
|
335
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
336
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
336
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarNextDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
337
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.9", type: RdxCalendarNextDirective, isStandalone: true, selector: "button[rdxCalendarNext]", inputs: { nextPage: { classPropertyName: "nextPage", publicName: "nextPage", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "aria-label": "Next page" }, listeners: { "click": "onClick()" }, properties: { "attr.disabled": "disabled() ? \"\" : undefined", "attr.data-disabled": "disabled() ? \"\" : undefined", "attr.aria-disabled": "disabled() ? \"\" : undefined" } }, exportAs: ["rdxCalendarNext"], ngImport: i0 }); }
|
|
337
338
|
}
|
|
338
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
339
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarNextDirective, decorators: [{
|
|
339
340
|
type: Directive,
|
|
340
341
|
args: [{
|
|
341
342
|
selector: 'button[rdxCalendarNext]',
|
|
342
343
|
exportAs: 'rdxCalendarNext',
|
|
343
344
|
host: {
|
|
344
345
|
'(click)': 'onClick()',
|
|
345
|
-
'[disabled]': 'disabled()',
|
|
346
|
+
'[attr.disabled]': 'disabled() ? "" : undefined',
|
|
346
347
|
'[attr.data-disabled]': 'disabled() ? "" : undefined',
|
|
347
348
|
'[attr.aria-disabled]': 'disabled() ? "" : undefined',
|
|
348
349
|
'aria-label': 'Next page'
|
|
349
350
|
}
|
|
350
351
|
}]
|
|
351
|
-
}] });
|
|
352
|
+
}], propDecorators: { nextPage: [{ type: i0.Input, args: [{ isSignal: true, alias: "nextPage", required: false }] }] } });
|
|
352
353
|
|
|
353
354
|
class RdxCalendarPrevDirective {
|
|
354
355
|
constructor() {
|
|
@@ -356,32 +357,32 @@ class RdxCalendarPrevDirective {
|
|
|
356
357
|
/**
|
|
357
358
|
* The function to be used for the `prev page`. Overwrites the prevPage function set on the `CalendarRoot`.
|
|
358
359
|
*/
|
|
359
|
-
this.prevPage = input(...(ngDevMode ? [undefined, { debugName: "prevPage" }] : []));
|
|
360
|
+
this.prevPage = input(...(ngDevMode ? [undefined, { debugName: "prevPage" }] : /* istanbul ignore next */ []));
|
|
360
361
|
/**
|
|
361
362
|
* @ignore
|
|
362
363
|
*/
|
|
363
|
-
this.disabled = computed(() => this.rootContext.disabled() || this.rootContext.isNextButtonDisabled(this.prevPage()), ...(ngDevMode ? [{ debugName: "disabled" }] : []));
|
|
364
|
+
this.disabled = computed(() => this.rootContext.disabled() || this.rootContext.isNextButtonDisabled(this.prevPage()), ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
|
|
364
365
|
}
|
|
365
366
|
onClick() {
|
|
366
367
|
this.rootContext.prevPage(this.prevPage());
|
|
367
368
|
}
|
|
368
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
369
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
369
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarPrevDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
370
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.9", type: RdxCalendarPrevDirective, isStandalone: true, selector: "button[rdxCalendarPrev]", inputs: { prevPage: { classPropertyName: "prevPage", publicName: "prevPage", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "aria-label": "Previous page" }, listeners: { "click": "onClick()" }, properties: { "attr.disabled": "disabled() ? \"\" : undefined", "attr.data-disabled": "disabled() ? \"\" : undefined", "attr.aria-disabled": "disabled() ? \"\" : undefined" } }, exportAs: ["rdxCalendarPrev"], ngImport: i0 }); }
|
|
370
371
|
}
|
|
371
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
372
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarPrevDirective, decorators: [{
|
|
372
373
|
type: Directive,
|
|
373
374
|
args: [{
|
|
374
375
|
selector: 'button[rdxCalendarPrev]',
|
|
375
376
|
exportAs: 'rdxCalendarPrev',
|
|
376
377
|
host: {
|
|
377
378
|
'(click)': 'onClick()',
|
|
378
|
-
'[disabled]': 'disabled()',
|
|
379
|
+
'[attr.disabled]': 'disabled() ? "" : undefined',
|
|
379
380
|
'[attr.data-disabled]': 'disabled() ? "" : undefined',
|
|
380
381
|
'[attr.aria-disabled]': 'disabled() ? "" : undefined',
|
|
381
382
|
'aria-label': 'Previous page'
|
|
382
383
|
}
|
|
383
384
|
}]
|
|
384
|
-
}] });
|
|
385
|
+
}], propDecorators: { prevPage: [{ type: i0.Input, args: [{ isSignal: true, alias: "prevPage", required: false }] }] } });
|
|
385
386
|
|
|
386
387
|
function calendarState(props) {
|
|
387
388
|
function isDateSelected(dateObj) {
|
|
@@ -419,7 +420,7 @@ function calendarState(props) {
|
|
|
419
420
|
return true;
|
|
420
421
|
}
|
|
421
422
|
return false;
|
|
422
|
-
}, ...(ngDevMode ? [{ debugName: "isInvalid" }] : []));
|
|
423
|
+
}, ...(ngDevMode ? [{ debugName: "isInvalid" }] : /* istanbul ignore next */ []));
|
|
423
424
|
return {
|
|
424
425
|
isDateSelected,
|
|
425
426
|
isInvalid
|
|
@@ -461,17 +462,17 @@ function calendar(props) {
|
|
|
461
462
|
options.era = 'short';
|
|
462
463
|
}
|
|
463
464
|
return options;
|
|
464
|
-
}, ...(ngDevMode ? [{ debugName: "headingFormatOptions" }] : []));
|
|
465
|
+
}, ...(ngDevMode ? [{ debugName: "headingFormatOptions" }] : /* istanbul ignore next */ []));
|
|
465
466
|
const month = signal(createMonths({
|
|
466
467
|
dateObj: props.placeholder(),
|
|
467
468
|
weekStartsOn: props.weekStartsOn(),
|
|
468
469
|
locale: props.locale(),
|
|
469
470
|
fixedWeeks: props.fixedWeeks(),
|
|
470
471
|
numberOfMonths: props.numberOfMonths()
|
|
471
|
-
}), ...(ngDevMode ? [{ debugName: "month" }] : []));
|
|
472
|
+
}), ...(ngDevMode ? [{ debugName: "month" }] : /* istanbul ignore next */ []));
|
|
472
473
|
const visibleView = computed(() => {
|
|
473
474
|
return month().map((month) => month.value);
|
|
474
|
-
}, ...(ngDevMode ? [{ debugName: "visibleView" }] : []));
|
|
475
|
+
}, ...(ngDevMode ? [{ debugName: "visibleView" }] : /* istanbul ignore next */ []));
|
|
475
476
|
function isOutsideVisibleView(date) {
|
|
476
477
|
return !visibleView().some((month) => isEqualMonth(date, month));
|
|
477
478
|
}
|
|
@@ -590,7 +591,7 @@ function calendar(props) {
|
|
|
590
591
|
return month()[0].weeks[0].map((date) => {
|
|
591
592
|
return formatter.dayOfWeek(toDate(date), props.weekdayFormat());
|
|
592
593
|
});
|
|
593
|
-
}, ...(ngDevMode ? [{ debugName: "weekdays" }] : []));
|
|
594
|
+
}, ...(ngDevMode ? [{ debugName: "weekdays" }] : /* istanbul ignore next */ []));
|
|
594
595
|
watch([props.placeholder], ([placeholder]) => {
|
|
595
596
|
if (visibleView().some((month) => isEqualMonth(month, placeholder))) {
|
|
596
597
|
return;
|
|
@@ -631,8 +632,8 @@ function calendar(props) {
|
|
|
631
632
|
return startMonthYear === endMonthYear
|
|
632
633
|
? `${startMonthName} - ${endMonthName} ${endMonthYear}`
|
|
633
634
|
: `${startMonthName} ${startMonthYear} - ${endMonthName} ${endMonthYear}`;
|
|
634
|
-
}, ...(ngDevMode ? [{ debugName: "headingValue" }] : []));
|
|
635
|
-
const fullCalendarLabel = computed(() => `${props.calendarLabel() ?? 'Event Date'}, ${headingValue()}`, ...(ngDevMode ? [{ debugName: "fullCalendarLabel" }] : []));
|
|
635
|
+
}, ...(ngDevMode ? [{ debugName: "headingValue" }] : /* istanbul ignore next */ []));
|
|
636
|
+
const fullCalendarLabel = computed(() => `${props.calendarLabel() ?? 'Event Date'}, ${headingValue()}`, ...(ngDevMode ? [{ debugName: "fullCalendarLabel" }] : /* istanbul ignore next */ []));
|
|
636
637
|
return {
|
|
637
638
|
isDateDisabled,
|
|
638
639
|
isDateUnavailable,
|
|
@@ -656,12 +657,12 @@ class RdxCalendarRootDirective {
|
|
|
656
657
|
/**
|
|
657
658
|
* The controlled checked state of the calendar
|
|
658
659
|
*/
|
|
659
|
-
this.value = model(...(ngDevMode ? [undefined, { debugName: "value" }] : []));
|
|
660
|
+
this.value = model(...(ngDevMode ? [undefined, { debugName: "value" }] : /* istanbul ignore next */ []));
|
|
660
661
|
/**
|
|
661
662
|
* The default placeholder date
|
|
662
663
|
*/
|
|
663
|
-
this.defaultPlaceholder = model(...(ngDevMode ? [undefined, { debugName: "defaultPlaceholder" }] : []));
|
|
664
|
-
this.locale = input('en', ...(ngDevMode ? [{ debugName: "locale" }] : []));
|
|
664
|
+
this.defaultPlaceholder = model(...(ngDevMode ? [undefined, { debugName: "defaultPlaceholder" }] : /* istanbul ignore next */ []));
|
|
665
|
+
this.locale = input('en', ...(ngDevMode ? [{ debugName: "locale" }] : /* istanbul ignore next */ []));
|
|
665
666
|
this.defaultDate = getDefaultDate({
|
|
666
667
|
defaultPlaceholder: this.defaultPlaceholder(),
|
|
667
668
|
defaultValue: this.value(),
|
|
@@ -671,75 +672,75 @@ class RdxCalendarRootDirective {
|
|
|
671
672
|
* The placeholder date, which is used to determine what month to display when no date is selected.
|
|
672
673
|
* This updates as the user navigates the calendar and can be used to programmatically control the calendar view
|
|
673
674
|
*/
|
|
674
|
-
this.placeholder = model(this.defaultPlaceholder() ?? this.defaultDate.copy(), ...(ngDevMode ? [{ debugName: "placeholder" }] : []));
|
|
675
|
-
this.multiple = input(false, ...(ngDevMode ?
|
|
675
|
+
this.placeholder = model(this.defaultPlaceholder() ?? this.defaultDate.copy(), ...(ngDevMode ? [{ debugName: "placeholder" }] : /* istanbul ignore next */ []));
|
|
676
|
+
this.multiple = input(false, { ...(ngDevMode ? { debugName: "multiple" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
676
677
|
/**
|
|
677
678
|
* Whether to always display 6 weeks in the calendar
|
|
678
679
|
*/
|
|
679
|
-
this.fixedWeeks = input(false, ...(ngDevMode ?
|
|
680
|
+
this.fixedWeeks = input(false, { ...(ngDevMode ? { debugName: "fixedWeeks" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
680
681
|
/**
|
|
681
682
|
* Whether the calendar is disabled
|
|
682
683
|
*/
|
|
683
|
-
this.disabled = input(false, ...(ngDevMode ?
|
|
684
|
+
this.disabled = input(false, { ...(ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
684
685
|
/**
|
|
685
686
|
* Whether to prevent the user from deselecting a date without selecting another date first
|
|
686
687
|
*/
|
|
687
|
-
this.preventDeselect = input(false, ...(ngDevMode ?
|
|
688
|
+
this.preventDeselect = input(false, { ...(ngDevMode ? { debugName: "preventDeselect" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
688
689
|
/**
|
|
689
690
|
* The day of the week to start the calendar on
|
|
690
691
|
*/
|
|
691
|
-
this.weekStartsOn = input(1, ...(ngDevMode ? [{ debugName: "weekStartsOn" }] : []));
|
|
692
|
+
this.weekStartsOn = input(1, ...(ngDevMode ? [{ debugName: "weekStartsOn" }] : /* istanbul ignore next */ []));
|
|
692
693
|
/**
|
|
693
694
|
* The number of months to display at once
|
|
694
695
|
*/
|
|
695
|
-
this.numberOfMonths = input(1, ...(ngDevMode ? [{ debugName: "numberOfMonths" }] : []));
|
|
696
|
+
this.numberOfMonths = input(1, ...(ngDevMode ? [{ debugName: "numberOfMonths" }] : /* istanbul ignore next */ []));
|
|
696
697
|
/**
|
|
697
698
|
* The reading direction of the calendar when applicable.
|
|
698
699
|
*/
|
|
699
|
-
this.dir = input('ltr', ...(ngDevMode ? [{ debugName: "dir" }] : []));
|
|
700
|
+
this.dir = input('ltr', ...(ngDevMode ? [{ debugName: "dir" }] : /* istanbul ignore next */ []));
|
|
700
701
|
/**
|
|
701
702
|
* The minimum date that can be selected
|
|
702
703
|
*/
|
|
703
|
-
this.minValue = input(...(ngDevMode ? [undefined, { debugName: "minValue" }] : []));
|
|
704
|
+
this.minValue = input(...(ngDevMode ? [undefined, { debugName: "minValue" }] : /* istanbul ignore next */ []));
|
|
704
705
|
/**
|
|
705
706
|
* The maximum date that can be selected
|
|
706
707
|
*/
|
|
707
|
-
this.maxValue = input(...(ngDevMode ? [undefined, { debugName: "maxValue" }] : []));
|
|
708
|
+
this.maxValue = input(...(ngDevMode ? [undefined, { debugName: "maxValue" }] : /* istanbul ignore next */ []));
|
|
708
709
|
/**
|
|
709
710
|
* The format to use for the weekday strings provided via the weekdays slot prop
|
|
710
711
|
*/
|
|
711
|
-
this.weekdayFormat = input('narrow', ...(ngDevMode ? [{ debugName: "weekdayFormat" }] : []));
|
|
712
|
+
this.weekdayFormat = input('narrow', ...(ngDevMode ? [{ debugName: "weekdayFormat" }] : /* istanbul ignore next */ []));
|
|
712
713
|
/**
|
|
713
714
|
* The accessible label for the calendar
|
|
714
715
|
*/
|
|
715
|
-
this.calendarLabel = input(...(ngDevMode ? [undefined, { debugName: "calendarLabel" }] : []));
|
|
716
|
+
this.calendarLabel = input(...(ngDevMode ? [undefined, { debugName: "calendarLabel" }] : /* istanbul ignore next */ []));
|
|
716
717
|
/**
|
|
717
718
|
* Whether the calendar is readonly
|
|
718
719
|
*/
|
|
719
|
-
this.readonly = input(false, ...(ngDevMode ?
|
|
720
|
+
this.readonly = input(false, { ...(ngDevMode ? { debugName: "readonly" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
720
721
|
/**
|
|
721
722
|
* This property causes the previous and next buttons to navigate by the number of months displayed at once, rather than one month
|
|
722
723
|
*/
|
|
723
|
-
this.pagedNavigation = input(false, ...(ngDevMode ?
|
|
724
|
-
this.propsNextPage = input(...(ngDevMode ? [undefined, { debugName: "propsNextPage" }] : []));
|
|
725
|
-
this.propsPrevPage = input(...(ngDevMode ? [undefined, { debugName: "propsPrevPage" }] : []));
|
|
724
|
+
this.pagedNavigation = input(false, { ...(ngDevMode ? { debugName: "pagedNavigation" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
725
|
+
this.propsNextPage = input(...(ngDevMode ? [undefined, { debugName: "propsNextPage" }] : /* istanbul ignore next */ []));
|
|
726
|
+
this.propsPrevPage = input(...(ngDevMode ? [undefined, { debugName: "propsPrevPage" }] : /* istanbul ignore next */ []));
|
|
726
727
|
/**
|
|
727
728
|
* A function that returns whether a date is disabled
|
|
728
729
|
*/
|
|
729
|
-
this.isDateDisabled = input(...(ngDevMode ? [undefined, { debugName: "isDateDisabled" }] : []));
|
|
730
|
+
this.isDateDisabled = input(...(ngDevMode ? [undefined, { debugName: "isDateDisabled" }] : /* istanbul ignore next */ []));
|
|
730
731
|
/**
|
|
731
732
|
* A function that returns whether a date is unavailable
|
|
732
733
|
*/
|
|
733
|
-
this.isDateUnavailable = input(...(ngDevMode ? [undefined, { debugName: "isDateUnavailable" }] : []));
|
|
734
|
-
this.initialFocus = input(false, ...(ngDevMode ?
|
|
735
|
-
this.months = model(...(ngDevMode ? [undefined, { debugName: "months" }] : []));
|
|
734
|
+
this.isDateUnavailable = input(...(ngDevMode ? [undefined, { debugName: "isDateUnavailable" }] : /* istanbul ignore next */ []));
|
|
735
|
+
this.initialFocus = input(false, { ...(ngDevMode ? { debugName: "initialFocus" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
736
|
+
this.months = model(...(ngDevMode ? [undefined, { debugName: "months" }] : /* istanbul ignore next */ []));
|
|
736
737
|
/**
|
|
737
738
|
* The days of the week
|
|
738
739
|
*/
|
|
739
|
-
this.weekDays = model(...(ngDevMode ? [undefined, { debugName: "weekDays" }] : []));
|
|
740
|
-
this._fixedWeeks = linkedSignal(this.fixedWeeks, ...(ngDevMode ? [{ debugName: "_fixedWeeks" }] : []));
|
|
741
|
-
this._disabled = linkedSignal(this.disabled, ...(ngDevMode ? [{ debugName: "_disabled" }] : []));
|
|
742
|
-
this._pagedNavigation = linkedSignal(this.pagedNavigation, ...(ngDevMode ? [{ debugName: "_pagedNavigation" }] : []));
|
|
740
|
+
this.weekDays = model(...(ngDevMode ? [undefined, { debugName: "weekDays" }] : /* istanbul ignore next */ []));
|
|
741
|
+
this._fixedWeeks = linkedSignal(this.fixedWeeks, ...(ngDevMode ? [{ debugName: "_fixedWeeks" }] : /* istanbul ignore next */ []));
|
|
742
|
+
this._disabled = linkedSignal(this.disabled, ...(ngDevMode ? [{ debugName: "_disabled" }] : /* istanbul ignore next */ []));
|
|
743
|
+
this._pagedNavigation = linkedSignal(this.pagedNavigation, ...(ngDevMode ? [{ debugName: "_pagedNavigation" }] : /* istanbul ignore next */ []));
|
|
743
744
|
this.startingWeekNumber = computed(() => {
|
|
744
745
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
745
746
|
// @ts-expect-error
|
|
@@ -754,15 +755,15 @@ class RdxCalendarRootDirective {
|
|
|
754
755
|
const firstDayOfYear = startOfYear(thursday);
|
|
755
756
|
return ((thursday.compare(firstDayOfYear) / 7) | 0) + 1;
|
|
756
757
|
});
|
|
757
|
-
}, ...(ngDevMode ? [{ debugName: "startingWeekNumber" }] : []));
|
|
758
|
+
}, ...(ngDevMode ? [{ debugName: "startingWeekNumber" }] : /* istanbul ignore next */ []));
|
|
758
759
|
/**
|
|
759
760
|
* @ignore
|
|
760
761
|
*/
|
|
761
|
-
this.headingValue = signal('', ...(ngDevMode ? [{ debugName: "headingValue" }] : []));
|
|
762
|
+
this.headingValue = signal('', ...(ngDevMode ? [{ debugName: "headingValue" }] : /* istanbul ignore next */ []));
|
|
762
763
|
/**
|
|
763
764
|
* @ignore
|
|
764
765
|
*/
|
|
765
|
-
this.fullCalendarLabel = signal('', ...(ngDevMode ? [{ debugName: "fullCalendarLabel" }] : []));
|
|
766
|
+
this.fullCalendarLabel = signal('', ...(ngDevMode ? [{ debugName: "fullCalendarLabel" }] : /* istanbul ignore next */ []));
|
|
766
767
|
this.calendar = calendar({
|
|
767
768
|
locale: this.locale,
|
|
768
769
|
placeholder: this.placeholder,
|
|
@@ -859,10 +860,10 @@ class RdxCalendarRootDirective {
|
|
|
859
860
|
}
|
|
860
861
|
}
|
|
861
862
|
}
|
|
862
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
863
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
863
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarRootDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
864
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.9", type: RdxCalendarRootDirective, isStandalone: true, selector: "[rdxCalendarRoot]", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, defaultPlaceholder: { classPropertyName: "defaultPlaceholder", publicName: "defaultPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, locale: { classPropertyName: "locale", publicName: "locale", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, multiple: { classPropertyName: "multiple", publicName: "multiple", isSignal: true, isRequired: false, transformFunction: null }, fixedWeeks: { classPropertyName: "fixedWeeks", publicName: "fixedWeeks", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, preventDeselect: { classPropertyName: "preventDeselect", publicName: "preventDeselect", isSignal: true, isRequired: false, transformFunction: null }, weekStartsOn: { classPropertyName: "weekStartsOn", publicName: "weekStartsOn", isSignal: true, isRequired: false, transformFunction: null }, numberOfMonths: { classPropertyName: "numberOfMonths", publicName: "numberOfMonths", isSignal: true, isRequired: false, transformFunction: null }, dir: { classPropertyName: "dir", publicName: "dir", isSignal: true, isRequired: false, transformFunction: null }, minValue: { classPropertyName: "minValue", publicName: "minValue", isSignal: true, isRequired: false, transformFunction: null }, maxValue: { classPropertyName: "maxValue", publicName: "maxValue", isSignal: true, isRequired: false, transformFunction: null }, weekdayFormat: { classPropertyName: "weekdayFormat", publicName: "weekdayFormat", isSignal: true, isRequired: false, transformFunction: null }, calendarLabel: { classPropertyName: "calendarLabel", publicName: "calendarLabel", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, pagedNavigation: { classPropertyName: "pagedNavigation", publicName: "pagedNavigation", isSignal: true, isRequired: false, transformFunction: null }, propsNextPage: { classPropertyName: "propsNextPage", publicName: "propsNextPage", isSignal: true, isRequired: false, transformFunction: null }, propsPrevPage: { classPropertyName: "propsPrevPage", publicName: "propsPrevPage", isSignal: true, isRequired: false, transformFunction: null }, isDateDisabled: { classPropertyName: "isDateDisabled", publicName: "isDateDisabled", isSignal: true, isRequired: false, transformFunction: null }, isDateUnavailable: { classPropertyName: "isDateUnavailable", publicName: "isDateUnavailable", isSignal: true, isRequired: false, transformFunction: null }, initialFocus: { classPropertyName: "initialFocus", publicName: "initialFocus", isSignal: true, isRequired: false, transformFunction: null }, months: { classPropertyName: "months", publicName: "months", isSignal: true, isRequired: false, transformFunction: null }, weekDays: { classPropertyName: "weekDays", publicName: "weekDays", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange", defaultPlaceholder: "defaultPlaceholderChange", placeholder: "placeholderChange", months: "monthsChange", weekDays: "weekDaysChange" }, host: { attributes: { "role": "application" }, properties: { "attr.aria-label": "fullCalendarLabel()", "attr.data-disabled": "disabled() ? \"\" : undefined", "attr.data-readonly": "readonly() ? \"\" : undefined", "attr.data-invalid": "isInvalid ? \"\" : undefined", "attr.dir": "dir()" } }, providers: [{ provide: CALENDAR_ROOT_CONTEXT, useExisting: forwardRef(() => RdxCalendarRootDirective) }], exportAs: ["rdxCalendarRoot"], ngImport: i0 }); }
|
|
864
865
|
}
|
|
865
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
866
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarRootDirective, decorators: [{
|
|
866
867
|
type: Directive,
|
|
867
868
|
args: [{
|
|
868
869
|
selector: '[rdxCalendarRoot]',
|
|
@@ -877,7 +878,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImpor
|
|
|
877
878
|
'[attr.dir]': 'dir()'
|
|
878
879
|
}
|
|
879
880
|
}]
|
|
880
|
-
}], ctorParameters: () => [] });
|
|
881
|
+
}], ctorParameters: () => [], propDecorators: { value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], defaultPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "defaultPlaceholder", required: false }] }, { type: i0.Output, args: ["defaultPlaceholderChange"] }], locale: [{ type: i0.Input, args: [{ isSignal: true, alias: "locale", required: false }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }, { type: i0.Output, args: ["placeholderChange"] }], multiple: [{ type: i0.Input, args: [{ isSignal: true, alias: "multiple", required: false }] }], fixedWeeks: [{ type: i0.Input, args: [{ isSignal: true, alias: "fixedWeeks", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], preventDeselect: [{ type: i0.Input, args: [{ isSignal: true, alias: "preventDeselect", required: false }] }], weekStartsOn: [{ type: i0.Input, args: [{ isSignal: true, alias: "weekStartsOn", required: false }] }], numberOfMonths: [{ type: i0.Input, args: [{ isSignal: true, alias: "numberOfMonths", required: false }] }], dir: [{ type: i0.Input, args: [{ isSignal: true, alias: "dir", required: false }] }], minValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "minValue", required: false }] }], maxValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxValue", required: false }] }], weekdayFormat: [{ type: i0.Input, args: [{ isSignal: true, alias: "weekdayFormat", required: false }] }], calendarLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "calendarLabel", required: false }] }], readonly: [{ type: i0.Input, args: [{ isSignal: true, alias: "readonly", required: false }] }], pagedNavigation: [{ type: i0.Input, args: [{ isSignal: true, alias: "pagedNavigation", required: false }] }], propsNextPage: [{ type: i0.Input, args: [{ isSignal: true, alias: "propsNextPage", required: false }] }], propsPrevPage: [{ type: i0.Input, args: [{ isSignal: true, alias: "propsPrevPage", required: false }] }], isDateDisabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "isDateDisabled", required: false }] }], isDateUnavailable: [{ type: i0.Input, args: [{ isSignal: true, alias: "isDateUnavailable", required: false }] }], initialFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialFocus", required: false }] }], months: [{ type: i0.Input, args: [{ isSignal: true, alias: "months", required: false }] }, { type: i0.Output, args: ["monthsChange"] }], weekDays: [{ type: i0.Input, args: [{ isSignal: true, alias: "weekDays", required: false }] }, { type: i0.Output, args: ["weekDaysChange"] }] } });
|
|
881
882
|
|
|
882
883
|
const _imports = [
|
|
883
884
|
RdxCalendarCellTriggerDirective,
|
|
@@ -894,8 +895,8 @@ const _imports = [
|
|
|
894
895
|
RdxCalendarNextDirective
|
|
895
896
|
];
|
|
896
897
|
class RdxCalendarModule {
|
|
897
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
898
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
898
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
899
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarModule, imports: [RdxCalendarCellTriggerDirective,
|
|
899
900
|
RdxCalendarCellDirective,
|
|
900
901
|
RdxCalendarGridBodyDirective,
|
|
901
902
|
RdxCalendarGridHeadDirective,
|
|
@@ -918,9 +919,9 @@ class RdxCalendarModule {
|
|
|
918
919
|
RdxCalendarRootDirective,
|
|
919
920
|
RdxCalendarHeadingDirective,
|
|
920
921
|
RdxCalendarNextDirective] }); }
|
|
921
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
922
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarModule }); }
|
|
922
923
|
}
|
|
923
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
924
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxCalendarModule, decorators: [{
|
|
924
925
|
type: NgModule,
|
|
925
926
|
args: [{
|
|
926
927
|
imports: [..._imports],
|