@tekus/design-system 5.20.0 → 5.21.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.
@@ -1,163 +1,188 @@
1
- import { EventEmitter, OnInit, OnDestroy } from '@angular/core';
2
- import { FormControl, ControlValueAccessor } from '@angular/forms';
1
+ import { OnInit, OnDestroy } from '@angular/core';
2
+ import { FormControl, ControlValueAccessor, NgControl } from '@angular/forms';
3
3
  import * as i0 from "@angular/core";
4
4
  export type DateValue = Date | [Date, Date] | null;
5
5
  export declare class DatePickerComponent implements OnInit, OnDestroy, ControlValueAccessor {
6
+ /** Internal references and injections */
7
+ readonly ngControl: NgControl | null;
8
+ constructor();
6
9
  /**
7
- * @property {'single' | 'range'} selectionMode
10
+ * @property {InputSignal<'date' | 'time'>} variant
11
+ * @description
12
+ * Defines the visual and functional mode:
13
+ * - `'date'`: standard date/range picker
14
+ * - `'time'`: time-only picker
15
+ * @default 'date'
16
+ */
17
+ variant: import("@angular/core").InputSignal<"date" | "time">;
18
+ /**
19
+ * @property {InputSignal<'single' | 'range'>} selectionMode
8
20
  * @description
9
21
  * Defines how the datepicker behaves:
10
22
  * - `'single'`: select one date
11
23
  * - `'range'`: select a pair of dates [start, end]
12
24
  * @default 'range'
13
25
  */
14
- selectionMode: 'single' | 'range';
26
+ selectionMode: import("@angular/core").InputSignal<"single" | "range">;
15
27
  /**
16
- * @property {boolean} readonlyInput
28
+ * @property {InputSignal<boolean>} readonlyInput
17
29
  * @description
18
30
  * Disables manual typing in the input and forces the user to select via the calendar.
19
31
  * @default true
20
32
  */
21
- readonlyInput: boolean;
22
- /**
23
- * @property {boolean} disabled
24
- * @description
25
- * Disables component.
26
- * @default false
27
- */
28
- disabled: boolean;
33
+ readonlyInput: import("@angular/core").InputSignal<boolean>;
29
34
  /**
30
- * @property {boolean} showClear
35
+ * @property {InputSignal<boolean>} showClear
31
36
  * @description
32
37
  * Displays a clear button that resets the datepicker value.
33
38
  * @default true
34
39
  */
35
- showClear: boolean;
40
+ showClear: import("@angular/core").InputSignal<boolean>;
36
41
  /**
37
- * @property {boolean} showIcon
42
+ * @property {InputSignal<boolean>} showIcon
38
43
  * @description
39
- * Shows the calendar icon inside the input.
44
+ * Shows the calendar or clock icon inside the input.
40
45
  * @default true
41
46
  */
42
- showIcon: boolean;
47
+ showIcon: import("@angular/core").InputSignal<boolean>;
43
48
  /**
44
- * @property {string} dateFormat
49
+ * @property {InputSignal<string>} dateFormat
45
50
  * @description
46
51
  * Format used by PrimeNG for displaying dates.
47
52
  * @default 'mm/dd/yy'
48
53
  */
49
- dateFormat: string;
54
+ dateFormat: import("@angular/core").InputSignal<string>;
50
55
  /**
51
- * @property {Date | null} maxDate
56
+ * @property {InputSignal<string>} timeFormat
52
57
  * @description
53
- * Maximum selectable date. When set, the calendar will prevent selecting dates after this value.
54
- * Provide a JavaScript Date object. Use `null` to allow any future date.
55
- * @default null
58
+ * Format used by PrimeNG for displaying times.
59
+ * @default 'HH:mm'
56
60
  */
57
- maxDate: Date | null;
61
+ timeFormat: import("@angular/core").InputSignal<string>;
58
62
  /**
59
- * @property {Date | null} minDate
63
+ * @property {InputSignal<number>} stepHour
60
64
  * @description
61
- * Minimum selectable date. When set, the calendar will prevent selecting dates before this value.
62
- * Provide a JavaScript Date object. Use `null` to allow any past date.
63
- * @default null
65
+ * Hours to skip when clicking up/down.
66
+ * @default 1
64
67
  */
65
- minDate: Date | null;
68
+ stepHour: import("@angular/core").InputSignal<number>;
66
69
  /**
67
- * @property {string} labelText
70
+ * @property {InputSignal<number>} stepMinute
68
71
  * @description
69
- * Label shown by the float-label wrapper.
70
- * @default 'Select a date'
72
+ * Minutes to skip when clicking up/down.
73
+ * @default 1
71
74
  */
72
- labelText: string;
75
+ stepMinute: import("@angular/core").InputSignal<number>;
73
76
  /**
74
- * @private
75
- * @property {FormControl<DateValue>} internalControl
77
+ * @property {InputSignal<number>} stepSecond
76
78
  * @description
77
- * The internal FormControl used in the template. It handles value synchronization
78
- * for both CVA and the optional external control input.
79
+ * Seconds to skip when clicking up/down.
80
+ * @default 1
79
81
  */
80
- internalControl: FormControl<DateValue>;
82
+ stepSecond: import("@angular/core").InputSignal<number>;
81
83
  /**
82
- * @private
83
- * @property {Subscription} sub
84
- * @description Subscription to the valueChanges observable.
84
+ * @property {InputSignal<boolean>} showSeconds
85
+ * @description
86
+ * Whether to show seconds in the time picker.
87
+ * @default false
85
88
  */
86
- private sub;
87
- private onChange;
88
- private onTouched;
89
+ showSeconds: import("@angular/core").InputSignal<boolean>;
89
90
  /**
90
- * @property {FormControl<DateValue> | null} control
91
+ * @property {InputSignal<Date | null>} maxDate
91
92
  * @description
92
- * Allows passing an external FormControl (traditional Reactive Forms usage).
93
- * If provided, it overrides the internal control.
93
+ * Maximum selectable date.
94
+ * @default null
94
95
  */
95
- set control(ctrl: FormControl<DateValue> | null);
96
- get control(): FormControl<DateValue>;
96
+ maxDate: import("@angular/core").InputSignal<Date | null>;
97
97
  /**
98
- * @event handleSelect
98
+ * @property {InputSignal<Date | null>} minDate
99
99
  * @description
100
- * Emitted when:
101
- * - single mode → a valid Date is selected
102
- * - range mode → both start and end dates are selected
103
- *
104
- * Payload:
105
- * - Date (single mode)
106
- * - [Date, Date] (completed range)
100
+ * Minimum selectable date.
101
+ * @default null
107
102
  */
108
- handleSelect: EventEmitter<DateValue>;
103
+ minDate: import("@angular/core").InputSignal<Date | null>;
109
104
  /**
110
- * @event handleClear
105
+ * @property {InputSignal<string>} labelText
111
106
  * @description
112
- * Emitted when the control's value becomes `null`.
107
+ * Label shown by the float-label wrapper.
113
108
  */
114
- handleClear: EventEmitter<void>;
109
+ labelText: import("@angular/core").InputSignal<string>;
115
110
  /**
116
- * @property faCalendarDay
111
+ * @property {InputSignal<FormControl>} control
117
112
  * @description
118
- * Icon displayed inside the datepicker input.
113
+ * External FormControl used to read/set the datepicker value.
114
+ * If not provided, an internal FormControl is created.
119
115
  */
120
- faCalendarDay: import("@fortawesome/fontawesome-common-types").IconDefinition;
116
+ control: import("@angular/core").InputSignal<FormControl<any> | undefined>;
121
117
  /**
122
- * @method writeValue
123
- * @description Writes a new value from the form model (ngModel or formControl) into the component.
118
+ * @property {ModelSignal<DateValue>} modelValue
119
+ * @description
120
+ * The value of the datepicker model. Supports two-way binding.
124
121
  */
125
- writeValue(value: DateValue): void;
122
+ modelValue: import("@angular/core").ModelSignal<DateValue>;
123
+ /**
124
+ * @property {OutputRef<DateValue>} handleSelect
125
+ * @description
126
+ * Emitted when a value is selected.
127
+ */
128
+ handleSelect: import("@angular/core").OutputEmitterRef<DateValue>;
126
129
  /**
127
- * @method registerOnChange
128
- * @description Registers a callback function to be called when the control's value changes.
130
+ * @property {OutputRef<void>} handleClear
131
+ * @description
132
+ * Emitted when the value is cleared.
129
133
  */
130
- registerOnChange(fn: (value: DateValue) => void): void;
134
+ handleClear: import("@angular/core").OutputEmitterRef<void>;
135
+ /** Computed properties */
131
136
  /**
132
- * @method registerOnTouched
133
- * @description Registers a callback function to be called when the control receives a blur event (is touched).
137
+ * @property {Signal<'single' | 'range'>} effectiveSelectionMode
138
+ * @description
139
+ * Returns 'single' automatically if variant is 'time', otherwise returns the user-provided selectionMode.
134
140
  */
135
- registerOnTouched(fn: () => void): void;
141
+ effectiveSelectionMode: import("@angular/core").Signal<"single" | "range">;
136
142
  /**
137
- * @method setDisabledState
138
- * @description Called when the control should be disabled or enabled.
143
+ * @property {Signal<string>} effectiveDateFormat
144
+ * @description
145
+ * Returns the user-provided dateFormat or timeFormat based on the variant.
139
146
  */
140
- setDisabledState(isDisabled: boolean): void;
147
+ effectiveDateFormat: import("@angular/core").Signal<string>;
141
148
  /**
142
- * @method ngOnInit
149
+ * @property {Signal<FormControl>} effectiveControl
143
150
  * @description
144
- * Subscribes to the internal control's valueChanges:
145
- * 1. Notifies the external form (CVA) via `this.onChange()`.
146
- * 2. Emits the semantic events `handleSelect` or `handleClear`.
151
+ * Returns the external FormControl from NgControl or a local fallback.
147
152
  */
153
+ internalControl: FormControl<DateValue>;
154
+ get effectiveControl(): FormControl;
155
+ /** Icons */
156
+ faCalendarDay: import("@fortawesome/fontawesome-common-types").IconDefinition;
157
+ faClock: import("@fortawesome/fontawesome-common-types").IconDefinition;
158
+ /** CVA Logic */
159
+ onChange: (value: DateValue) => void;
160
+ onTouched: () => void;
161
+ private readonly sub;
148
162
  ngOnInit(): void;
163
+ ngOnDestroy(): void;
164
+ writeValue(value: DateValue): void;
165
+ registerOnChange(fn: (value: DateValue) => void): void;
166
+ registerOnTouched(fn: () => void): void;
167
+ setDisabledState(isDisabled: boolean): void;
149
168
  /**
150
- * @method ngOnDestroy
151
- * @description Cleans up the internal subscription when the component is destroyed.
169
+ * @method onModelChange
170
+ * @description
171
+ * Called when the PrimeNG DatePicker template updates the value.
152
172
  */
153
- ngOnDestroy(): void;
173
+ onModelChange(value: DateValue): void;
174
+ /**
175
+ * @method onBlur
176
+ * @description
177
+ * Triggered when the component loses focus.
178
+ */
179
+ onBlur(): void;
154
180
  /**
155
181
  * @method clear
156
182
  * @description
157
- * Programmatically clears the control's value,
158
- * which automatically triggers `handleClear`.
183
+ * Programmatically clears the value.
159
184
  */
160
185
  clear(): void;
161
186
  static ɵfac: i0.ɵɵFactoryDeclaration<DatePickerComponent, never>;
162
- static ɵcmp: i0.ɵɵComponentDeclaration<DatePickerComponent, "tk-date-picker", never, { "selectionMode": { "alias": "selectionMode"; "required": false; }; "readonlyInput": { "alias": "readonlyInput"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "showClear": { "alias": "showClear"; "required": false; }; "showIcon": { "alias": "showIcon"; "required": false; }; "dateFormat": { "alias": "dateFormat"; "required": false; }; "maxDate": { "alias": "maxDate"; "required": false; }; "minDate": { "alias": "minDate"; "required": false; }; "labelText": { "alias": "labelText"; "required": false; }; "control": { "alias": "control"; "required": false; }; }, { "handleSelect": "handleSelect"; "handleClear": "handleClear"; }, never, never, true, never>;
187
+ static ɵcmp: i0.ɵɵComponentDeclaration<DatePickerComponent, "tk-date-picker", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "selectionMode": { "alias": "selectionMode"; "required": false; "isSignal": true; }; "readonlyInput": { "alias": "readonlyInput"; "required": false; "isSignal": true; }; "showClear": { "alias": "showClear"; "required": false; "isSignal": true; }; "showIcon": { "alias": "showIcon"; "required": false; "isSignal": true; }; "dateFormat": { "alias": "dateFormat"; "required": false; "isSignal": true; }; "timeFormat": { "alias": "timeFormat"; "required": false; "isSignal": true; }; "stepHour": { "alias": "stepHour"; "required": false; "isSignal": true; }; "stepMinute": { "alias": "stepMinute"; "required": false; "isSignal": true; }; "stepSecond": { "alias": "stepSecond"; "required": false; "isSignal": true; }; "showSeconds": { "alias": "showSeconds"; "required": false; "isSignal": true; }; "maxDate": { "alias": "maxDate"; "required": false; "isSignal": true; }; "minDate": { "alias": "minDate"; "required": false; "isSignal": true; }; "labelText": { "alias": "labelText"; "required": false; "isSignal": true; }; "control": { "alias": "control"; "required": false; "isSignal": true; }; "modelValue": { "alias": "modelValue"; "required": false; "isSignal": true; }; }, { "modelValue": "modelValueChange"; "handleSelect": "handleSelect"; "handleClear": "handleClear"; }, never, never, true, never>;
163
188
  }
@@ -1,236 +1,259 @@
1
1
  import * as i0 from '@angular/core';
2
- import { forwardRef, EventEmitter, Output, Input, Component } from '@angular/core';
2
+ import { inject, input, model, output, computed, Component } from '@angular/core';
3
3
  import * as i1 from '@angular/forms';
4
- import { NG_VALUE_ACCESSOR, FormControl, FormsModule, ReactiveFormsModule } from '@angular/forms';
4
+ import { NgControl, FormControl, FormsModule, ReactiveFormsModule } from '@angular/forms';
5
+ import { Subscription } from 'rxjs';
5
6
  import * as i2 from 'primeng/datepicker';
6
7
  import { DatePickerModule } from 'primeng/datepicker';
7
8
  import * as i3 from 'primeng/floatlabel';
8
9
  import { FloatLabelModule } from 'primeng/floatlabel';
9
10
  import { FaIconComponent } from '@fortawesome/angular-fontawesome';
10
- import { faCalendarDay } from '@fortawesome/pro-regular-svg-icons';
11
+ import { faCalendarDay, faClock } from '@fortawesome/pro-regular-svg-icons';
11
12
 
12
- const TK_DATE_PICKER_VALUE_ACCESSOR = {
13
- provide: NG_VALUE_ACCESSOR,
14
- useExisting: forwardRef(() => DatePickerComponent),
15
- multi: true,
16
- };
17
13
  /**
18
14
  * @component DatePickerComponent
19
15
  * @description
20
- * A wrapper around PrimeNG's DatePicker component with support for single-date
21
- * and range selection modes. It is compatible with both Reactive Forms (formControlName, [control])
22
- * and Template-Driven Forms ([(ngModel)]).
23
- *
24
- * The component emits:
25
- * - `handleSelect` when a valid single date or a completed date range is selected.
26
- * - `handleClear` when the control is cleared (value becomes `null`).
16
+ * A wrapper around PrimeNG's DatePicker component with support for single-date,
17
+ * range selection, and time-only modes. It uses Angular Signals for reactivity
18
+ * and strictly implements the ControlValueAccessor interface via NgControl.
27
19
  */
28
20
  class DatePickerComponent {
29
21
  constructor() {
22
+ /** Internal references and injections */
23
+ this.ngControl = inject(NgControl, { self: true, optional: true });
30
24
  /**
31
- * @property {'single' | 'range'} selectionMode
25
+ * @property {InputSignal<'date' | 'time'>} variant
26
+ * @description
27
+ * Defines the visual and functional mode:
28
+ * - `'date'`: standard date/range picker
29
+ * - `'time'`: time-only picker
30
+ * @default 'date'
31
+ */
32
+ this.variant = input('date');
33
+ /**
34
+ * @property {InputSignal<'single' | 'range'>} selectionMode
32
35
  * @description
33
36
  * Defines how the datepicker behaves:
34
37
  * - `'single'`: select one date
35
38
  * - `'range'`: select a pair of dates [start, end]
36
39
  * @default 'range'
37
40
  */
38
- this.selectionMode = 'range';
41
+ this.selectionMode = input('range');
39
42
  /**
40
- * @property {boolean} readonlyInput
43
+ * @property {InputSignal<boolean>} readonlyInput
41
44
  * @description
42
45
  * Disables manual typing in the input and forces the user to select via the calendar.
43
46
  * @default true
44
47
  */
45
- this.readonlyInput = true;
48
+ this.readonlyInput = input(true);
46
49
  /**
47
- * @property {boolean} disabled
48
- * @description
49
- * Disables component.
50
- * @default false
51
- */
52
- this.disabled = false;
53
- /**
54
- * @property {boolean} showClear
50
+ * @property {InputSignal<boolean>} showClear
55
51
  * @description
56
52
  * Displays a clear button that resets the datepicker value.
57
53
  * @default true
58
54
  */
59
- this.showClear = true;
55
+ this.showClear = input(true);
60
56
  /**
61
- * @property {boolean} showIcon
57
+ * @property {InputSignal<boolean>} showIcon
62
58
  * @description
63
- * Shows the calendar icon inside the input.
59
+ * Shows the calendar or clock icon inside the input.
64
60
  * @default true
65
61
  */
66
- this.showIcon = true;
62
+ this.showIcon = input(true);
67
63
  /**
68
- * @property {string} dateFormat
64
+ * @property {InputSignal<string>} dateFormat
69
65
  * @description
70
66
  * Format used by PrimeNG for displaying dates.
71
67
  * @default 'mm/dd/yy'
72
68
  */
73
- this.dateFormat = 'mm/dd/yy';
69
+ this.dateFormat = input('mm/dd/yy');
74
70
  /**
75
- * @property {Date | null} maxDate
71
+ * @property {InputSignal<string>} timeFormat
76
72
  * @description
77
- * Maximum selectable date. When set, the calendar will prevent selecting dates after this value.
78
- * Provide a JavaScript Date object. Use `null` to allow any future date.
73
+ * Format used by PrimeNG for displaying times.
74
+ * @default 'HH:mm'
75
+ */
76
+ this.timeFormat = input('HH:mm');
77
+ /**
78
+ * @property {InputSignal<number>} stepHour
79
+ * @description
80
+ * Hours to skip when clicking up/down.
81
+ * @default 1
82
+ */
83
+ this.stepHour = input(1);
84
+ /**
85
+ * @property {InputSignal<number>} stepMinute
86
+ * @description
87
+ * Minutes to skip when clicking up/down.
88
+ * @default 1
89
+ */
90
+ this.stepMinute = input(1);
91
+ /**
92
+ * @property {InputSignal<number>} stepSecond
93
+ * @description
94
+ * Seconds to skip when clicking up/down.
95
+ * @default 1
96
+ */
97
+ this.stepSecond = input(1);
98
+ /**
99
+ * @property {InputSignal<boolean>} showSeconds
100
+ * @description
101
+ * Whether to show seconds in the time picker.
102
+ * @default false
103
+ */
104
+ this.showSeconds = input(false);
105
+ /**
106
+ * @property {InputSignal<Date | null>} maxDate
107
+ * @description
108
+ * Maximum selectable date.
79
109
  * @default null
80
110
  */
81
- this.maxDate = null;
111
+ this.maxDate = input(null);
82
112
  /**
83
- * @property {Date | null} minDate
113
+ * @property {InputSignal<Date | null>} minDate
84
114
  * @description
85
- * Minimum selectable date. When set, the calendar will prevent selecting dates before this value.
86
- * Provide a JavaScript Date object. Use `null` to allow any past date.
115
+ * Minimum selectable date.
87
116
  * @default null
88
117
  */
89
- this.minDate = null;
118
+ this.minDate = input(null);
90
119
  /**
91
- * @property {string} labelText
120
+ * @property {InputSignal<string>} labelText
92
121
  * @description
93
122
  * Label shown by the float-label wrapper.
94
- * @default 'Select a date'
95
123
  */
96
- this.labelText = 'Select a date';
124
+ this.labelText = input('Select a date');
97
125
  /**
98
- * @private
99
- * @property {FormControl<DateValue>} internalControl
126
+ * @property {InputSignal<FormControl>} control
100
127
  * @description
101
- * The internal FormControl used in the template. It handles value synchronization
102
- * for both CVA and the optional external control input.
128
+ * External FormControl used to read/set the datepicker value.
129
+ * If not provided, an internal FormControl is created.
103
130
  */
104
- this.internalControl = new FormControl(null);
105
- // Functions registered by ControlValueAccessor to communicate with the outside form
106
- this.onChange = () => { };
107
- this.onTouched = () => { };
131
+ this.control = input(undefined);
132
+ /**
133
+ * @property {ModelSignal<DateValue>} modelValue
134
+ * @description
135
+ * The value of the datepicker model. Supports two-way binding.
136
+ */
137
+ this.modelValue = model(null);
138
+ /**
139
+ * @property {OutputRef<DateValue>} handleSelect
140
+ * @description
141
+ * Emitted when a value is selected.
142
+ */
143
+ this.handleSelect = output();
144
+ /**
145
+ * @property {OutputRef<void>} handleClear
146
+ * @description
147
+ * Emitted when the value is cleared.
148
+ */
149
+ this.handleClear = output();
150
+ /** Computed properties */
108
151
  /**
109
- * @event handleSelect
152
+ * @property {Signal<'single' | 'range'>} effectiveSelectionMode
110
153
  * @description
111
- * Emitted when:
112
- * - single mode → a valid Date is selected
113
- * - range mode → both start and end dates are selected
114
- *
115
- * Payload:
116
- * - Date (single mode)
117
- * - [Date, Date] (completed range)
154
+ * Returns 'single' automatically if variant is 'time', otherwise returns the user-provided selectionMode.
118
155
  */
119
- this.handleSelect = new EventEmitter();
156
+ this.effectiveSelectionMode = computed(() => {
157
+ return this.variant() === 'time' ? 'single' : this.selectionMode();
158
+ });
120
159
  /**
121
- * @event handleClear
160
+ * @property {Signal<string>} effectiveDateFormat
122
161
  * @description
123
- * Emitted when the control's value becomes `null`.
162
+ * Returns the user-provided dateFormat or timeFormat based on the variant.
124
163
  */
125
- this.handleClear = new EventEmitter();
164
+ this.effectiveDateFormat = computed(() => {
165
+ return this.variant() === 'time' ? this.timeFormat() : this.dateFormat();
166
+ });
126
167
  /**
127
- * @property faCalendarDay
168
+ * @property {Signal<FormControl>} effectiveControl
128
169
  * @description
129
- * Icon displayed inside the datepicker input.
170
+ * Returns the external FormControl from NgControl or a local fallback.
130
171
  */
172
+ this.internalControl = new FormControl(null);
173
+ /** Icons */
131
174
  this.faCalendarDay = faCalendarDay;
132
- }
133
- /**
134
- * @property {FormControl<DateValue> | null} control
135
- * @description
136
- * Allows passing an external FormControl (traditional Reactive Forms usage).
137
- * If provided, it overrides the internal control.
138
- */
139
- set control(ctrl) {
140
- // If the user provides a control, we use that control for everything.
141
- if (ctrl) {
142
- this.internalControl = ctrl;
175
+ this.faClock = faClock;
176
+ /** CVA Logic */
177
+ this.onChange = () => { };
178
+ this.onTouched = () => { };
179
+ this.sub = new Subscription();
180
+ if (this.ngControl) {
181
+ this.ngControl.valueAccessor = this;
143
182
  }
144
183
  }
145
- get control() {
146
- return this.internalControl;
184
+ get effectiveControl() {
185
+ return (this.ngControl?.control ||
186
+ this.control() ||
187
+ this.internalControl);
188
+ }
189
+ ngOnInit() {
190
+ const control = this.effectiveControl;
191
+ // Synchronize signal model with control value
192
+ this.modelValue.set(control.value);
193
+ this.sub.add(control.valueChanges.subscribe(value => {
194
+ this.modelValue.set(value);
195
+ }));
196
+ }
197
+ ngOnDestroy() {
198
+ this.sub.unsubscribe();
147
199
  }
148
- /**
149
- * @method writeValue
150
- * @description Writes a new value from the form model (ngModel or formControl) into the component.
151
- */
152
200
  writeValue(value) {
153
- if (value !== undefined) {
154
- // Use { emitEvent: false } to prevent an unnecessary valueChanges loop.
155
- this.internalControl.setValue(value, { emitEvent: false });
156
- }
201
+ this.modelValue.set(value);
157
202
  }
158
- /**
159
- * @method registerOnChange
160
- * @description Registers a callback function to be called when the control's value changes.
161
- */
162
203
  registerOnChange(fn) {
163
204
  this.onChange = fn;
164
205
  }
165
- /**
166
- * @method registerOnTouched
167
- * @description Registers a callback function to be called when the control receives a blur event (is touched).
168
- */
169
206
  registerOnTouched(fn) {
170
207
  this.onTouched = fn;
171
208
  }
172
- /**
173
- * @method setDisabledState
174
- * @description Called when the control should be disabled or enabled.
175
- */
176
209
  setDisabledState(isDisabled) {
177
- const actionMap = {
178
- true: () => this.internalControl.disable(),
179
- false: () => this.internalControl.enable(),
180
- };
181
- actionMap[String(isDisabled)]();
210
+ const action = isDisabled ? 'disable' : 'enable';
211
+ this.effectiveControl[action]({ emitEvent: false });
182
212
  }
183
213
  /**
184
- * @method ngOnInit
214
+ * @method onModelChange
185
215
  * @description
186
- * Subscribes to the internal control's valueChanges:
187
- * 1. Notifies the external form (CVA) via `this.onChange()`.
188
- * 2. Emits the semantic events `handleSelect` or `handleClear`.
216
+ * Called when the PrimeNG DatePicker template updates the value.
189
217
  */
190
- ngOnInit() {
191
- this.sub = this.internalControl.valueChanges.subscribe(value => {
192
- // Notify the CVA / External Form
193
- this.onChange(value);
194
- this.onTouched();
195
- if (value === null) {
196
- this.handleClear.emit();
197
- return;
198
- }
199
- // RANGE MODE
200
- if (this.selectionMode === 'range') {
201
- if (Array.isArray(value)) {
202
- const [start, end] = value;
203
- // Emit ONLY when both dates exist
204
- if (start instanceof Date && end instanceof Date) {
205
- this.handleSelect.emit([start, end]);
206
- }
218
+ onModelChange(value) {
219
+ this.modelValue.set(value);
220
+ this.onChange(value);
221
+ this.effectiveControl.setValue(value, { emitEvent: false });
222
+ this.effectiveControl.markAsDirty();
223
+ if (value === null) {
224
+ this.handleClear.emit();
225
+ }
226
+ else if (this.selectionMode() === 'range') {
227
+ if (Array.isArray(value)) {
228
+ const [start, end] = value;
229
+ if (start instanceof Date && end instanceof Date) {
230
+ this.handleSelect.emit(value);
207
231
  }
208
- return;
209
232
  }
210
- // SINGLE MODE
211
- if (this.selectionMode === 'single' && value instanceof Date) {
212
- this.handleSelect.emit(value);
213
- }
214
- });
233
+ }
234
+ else if (value instanceof Date) {
235
+ this.handleSelect.emit(value);
236
+ }
215
237
  }
216
238
  /**
217
- * @method ngOnDestroy
218
- * @description Cleans up the internal subscription when the component is destroyed.
239
+ * @method onBlur
240
+ * @description
241
+ * Triggered when the component loses focus.
219
242
  */
220
- ngOnDestroy() {
221
- this.sub?.unsubscribe();
243
+ onBlur() {
244
+ this.onTouched();
245
+ this.effectiveControl.markAsTouched();
222
246
  }
223
247
  /**
224
248
  * @method clear
225
249
  * @description
226
- * Programmatically clears the control's value,
227
- * which automatically triggers `handleClear`.
250
+ * Programmatically clears the value.
228
251
  */
229
252
  clear() {
230
- this.internalControl.setValue(null);
253
+ this.onModelChange(null);
231
254
  }
232
255
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: DatePickerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
233
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.18", type: DatePickerComponent, isStandalone: true, selector: "tk-date-picker", inputs: { selectionMode: "selectionMode", readonlyInput: "readonlyInput", disabled: "disabled", showClear: "showClear", showIcon: "showIcon", dateFormat: "dateFormat", maxDate: "maxDate", minDate: "minDate", labelText: "labelText", control: "control" }, outputs: { handleSelect: "handleSelect", handleClear: "handleClear" }, providers: [TK_DATE_PICKER_VALUE_ACCESSOR], ngImport: i0, template: "<div class=\"datepicker-container\">\n <p-floatlabel>\n <p-datepicker\n inputId=\"datepicker\"\n iconDisplay=\"input\"\n [formControl]=\"internalControl\"\n [selectionMode]=\"selectionMode\"\n [readonlyInput]=\"readonlyInput\"\n [showClear]=\"showClear\"\n [showIcon]=\"showIcon\"\n [minDate]=\"minDate\"\n [maxDate]=\"maxDate\"\n [disabled]=\"disabled\"\n [dateFormat]=\"dateFormat\">\n <ng-template #inputicon let-clickCallBack=\"clickCallBack\">\n <fa-icon\n tabindex=\"0\"\n [icon]=\"faCalendarDay\"\n (keydown.enter)=\"clickCallBack($event)\"\n (keydown.space)=\"clickCallBack($event)\"\n (click)=\"clickCallBack($event)\">\n </fa-icon>\n </ng-template>\n </p-datepicker>\n\n <label for=\"datepicker\">{{ labelText }}</label>\n </p-floatlabel>\n</div>\n", styles: [":host ::ng-deep .p-datepicker{width:100%}:host ::ng-deep .p-datepicker-input{border:none;border-bottom:1px solid var(--tk-color-border-default, #cecdcd);border-radius:0;background-color:transparent;padding:var(--tk-spacing-base-75, 12px) var(--tk-spacing-base-75, 12px) var(--tk-spacing-base-75, 12px) var(--tk-spacing-base-25, 4px)!important}:host ::ng-deep .p-datepicker-input:focus{border-color:var(--tk-color-accent-default, #16006f)}:host ::ng-deep .p-datepicker-decade{color:var(--tk-color-text-default, #121214)}:host ::ng-deep .p-datepicker-clear-icon{color:var(--tk-surface-700, #424243);inset-inline-end:2.5rem!important}:host ::ng-deep .p-floatlabel:has(.p-inputwrapper-filled) label,:host ::ng-deep .p-floatlabel:has(input:focus) label{color:var(--tk-primary-500, #16006f)}:host ::ng-deep .p-floatlabel label{color:var(--tk-surface-700, #8a8a8b);font-family:var(--tk-font-family, Poppins, sans-serif);font-size:var(--tk-font-size-2xs, 1rem);font-weight:var(--tk-font-weight-400, 400);left:var(--tk-spacing-base-25, .25rem)}:host ::ng-deep .p-datepicker-day-selected-range{background-color:var(--tk-primary-100, #b7b0d2);color:var(--tk-primary-700, #10004f)}:host ::ng-deep .p-datepicker-panel{min-width:0!important;max-width:300px!important;width:100%!important}.datepicker-container{margin-top:var(--tk-spacing-base-200, 2rem)}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: DatePickerModule }, { kind: "component", type: i2.DatePicker, selector: "p-datePicker, p-datepicker, p-date-picker", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "fluid", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "size", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "ngmodule", type: FloatLabelModule }, { kind: "component", type: i3.FloatLabel, selector: "p-floatlabel, p-floatLabel, p-float-label", inputs: ["variant"] }, { kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }] }); }
256
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.18", type: DatePickerComponent, isStandalone: true, selector: "tk-date-picker", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, selectionMode: { classPropertyName: "selectionMode", publicName: "selectionMode", isSignal: true, isRequired: false, transformFunction: null }, readonlyInput: { classPropertyName: "readonlyInput", publicName: "readonlyInput", isSignal: true, isRequired: false, transformFunction: null }, showClear: { classPropertyName: "showClear", publicName: "showClear", isSignal: true, isRequired: false, transformFunction: null }, showIcon: { classPropertyName: "showIcon", publicName: "showIcon", isSignal: true, isRequired: false, transformFunction: null }, dateFormat: { classPropertyName: "dateFormat", publicName: "dateFormat", isSignal: true, isRequired: false, transformFunction: null }, timeFormat: { classPropertyName: "timeFormat", publicName: "timeFormat", 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 }, maxDate: { classPropertyName: "maxDate", publicName: "maxDate", isSignal: true, isRequired: false, transformFunction: null }, minDate: { classPropertyName: "minDate", publicName: "minDate", isSignal: true, isRequired: false, transformFunction: null }, labelText: { classPropertyName: "labelText", publicName: "labelText", isSignal: true, isRequired: false, transformFunction: null }, control: { classPropertyName: "control", publicName: "control", isSignal: true, isRequired: false, transformFunction: null }, modelValue: { classPropertyName: "modelValue", publicName: "modelValue", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { modelValue: "modelValueChange", handleSelect: "handleSelect", handleClear: "handleClear" }, ngImport: i0, template: "<div class=\"datepicker-container\">\n <p-floatlabel>\n <p-datepicker\n inputId=\"datepicker\"\n iconDisplay=\"input\"\n [ngModel]=\"modelValue()\"\n (ngModelChange)=\"onModelChange($event)\"\n (onBlur)=\"onBlur()\"\n [selectionMode]=\"effectiveSelectionMode()\"\n [readonlyInput]=\"readonlyInput()\"\n [showClear]=\"showClear()\"\n [showIcon]=\"showIcon()\"\n [minDate]=\"minDate()\"\n [maxDate]=\"maxDate()\"\n [disabled]=\"effectiveControl.disabled\"\n [dateFormat]=\"effectiveDateFormat()\"\n [timeOnly]=\"variant() === 'time'\"\n [stepHour]=\"stepHour()\"\n [stepMinute]=\"stepMinute()\"\n [stepSecond]=\"stepSecond()\"\n [showSeconds]=\"showSeconds()\">\n <ng-template #inputicon let-clickCallBack=\"clickCallBack\">\n <fa-icon\n tabindex=\"0\"\n [icon]=\"variant() === 'time' ? faClock : faCalendarDay\"\n (keydown.enter)=\"clickCallBack($event)\"\n (keydown.space)=\"clickCallBack($event)\"\n (click)=\"clickCallBack($event)\">\n </fa-icon>\n </ng-template>\n </p-datepicker>\n\n <label for=\"datepicker\">{{ labelText() }}</label>\n </p-floatlabel>\n</div>\n", styles: [":host ::ng-deep .p-datepicker{width:100%}:host ::ng-deep .p-datepicker-input{border:none;border-bottom:1px solid var(--tk-color-border-default, #cecdcd);border-radius:0;background-color:transparent;padding:var(--tk-spacing-base-75, 12px) var(--tk-spacing-base-75, 12px) var(--tk-spacing-base-75, 12px) var(--tk-spacing-base-25, 4px)!important}:host ::ng-deep .p-datepicker-input:focus{border-color:var(--tk-color-accent-default, #16006f)}:host ::ng-deep .p-datepicker-decade{color:var(--tk-color-text-default, #121214)}:host ::ng-deep .p-datepicker-clear-icon{color:var(--tk-surface-700, #424243);inset-inline-end:2.5rem!important}:host ::ng-deep .p-floatlabel:has(.p-inputwrapper-filled) label,:host ::ng-deep .p-floatlabel:has(input:focus) label{color:var(--tk-primary-500, #16006f)}:host ::ng-deep .p-floatlabel label{color:var(--tk-surface-700, #8a8a8b);font-family:var(--tk-font-family, Poppins, sans-serif);font-size:var(--tk-font-size-2xs, 1rem);font-weight:var(--tk-font-weight-400, 400);left:var(--tk-spacing-base-25, .25rem)}:host ::ng-deep .p-datepicker-day-selected-range{background-color:var(--tk-primary-100, #b7b0d2);color:var(--tk-primary-700, #10004f)}:host ::ng-deep .p-datepicker-panel{min-width:0!important;max-width:300px!important;width:100%!important}.datepicker-container{margin-top:var(--tk-spacing-base-200, 2rem)}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "ngmodule", type: DatePickerModule }, { kind: "component", type: i2.DatePicker, selector: "p-datePicker, p-datepicker, p-date-picker", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "fluid", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "size", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "ngmodule", type: FloatLabelModule }, { kind: "component", type: i3.FloatLabel, selector: "p-floatlabel, p-floatLabel, p-float-label", inputs: ["variant"] }, { kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }] }); }
234
257
  }
235
258
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: DatePickerComponent, decorators: [{
236
259
  type: Component,
@@ -240,32 +263,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
240
263
  DatePickerModule,
241
264
  FloatLabelModule,
242
265
  FaIconComponent,
243
- ], providers: [TK_DATE_PICKER_VALUE_ACCESSOR], template: "<div class=\"datepicker-container\">\n <p-floatlabel>\n <p-datepicker\n inputId=\"datepicker\"\n iconDisplay=\"input\"\n [formControl]=\"internalControl\"\n [selectionMode]=\"selectionMode\"\n [readonlyInput]=\"readonlyInput\"\n [showClear]=\"showClear\"\n [showIcon]=\"showIcon\"\n [minDate]=\"minDate\"\n [maxDate]=\"maxDate\"\n [disabled]=\"disabled\"\n [dateFormat]=\"dateFormat\">\n <ng-template #inputicon let-clickCallBack=\"clickCallBack\">\n <fa-icon\n tabindex=\"0\"\n [icon]=\"faCalendarDay\"\n (keydown.enter)=\"clickCallBack($event)\"\n (keydown.space)=\"clickCallBack($event)\"\n (click)=\"clickCallBack($event)\">\n </fa-icon>\n </ng-template>\n </p-datepicker>\n\n <label for=\"datepicker\">{{ labelText }}</label>\n </p-floatlabel>\n</div>\n", styles: [":host ::ng-deep .p-datepicker{width:100%}:host ::ng-deep .p-datepicker-input{border:none;border-bottom:1px solid var(--tk-color-border-default, #cecdcd);border-radius:0;background-color:transparent;padding:var(--tk-spacing-base-75, 12px) var(--tk-spacing-base-75, 12px) var(--tk-spacing-base-75, 12px) var(--tk-spacing-base-25, 4px)!important}:host ::ng-deep .p-datepicker-input:focus{border-color:var(--tk-color-accent-default, #16006f)}:host ::ng-deep .p-datepicker-decade{color:var(--tk-color-text-default, #121214)}:host ::ng-deep .p-datepicker-clear-icon{color:var(--tk-surface-700, #424243);inset-inline-end:2.5rem!important}:host ::ng-deep .p-floatlabel:has(.p-inputwrapper-filled) label,:host ::ng-deep .p-floatlabel:has(input:focus) label{color:var(--tk-primary-500, #16006f)}:host ::ng-deep .p-floatlabel label{color:var(--tk-surface-700, #8a8a8b);font-family:var(--tk-font-family, Poppins, sans-serif);font-size:var(--tk-font-size-2xs, 1rem);font-weight:var(--tk-font-weight-400, 400);left:var(--tk-spacing-base-25, .25rem)}:host ::ng-deep .p-datepicker-day-selected-range{background-color:var(--tk-primary-100, #b7b0d2);color:var(--tk-primary-700, #10004f)}:host ::ng-deep .p-datepicker-panel{min-width:0!important;max-width:300px!important;width:100%!important}.datepicker-container{margin-top:var(--tk-spacing-base-200, 2rem)}\n"] }]
244
- }], propDecorators: { selectionMode: [{
245
- type: Input
246
- }], readonlyInput: [{
247
- type: Input
248
- }], disabled: [{
249
- type: Input
250
- }], showClear: [{
251
- type: Input
252
- }], showIcon: [{
253
- type: Input
254
- }], dateFormat: [{
255
- type: Input
256
- }], maxDate: [{
257
- type: Input
258
- }], minDate: [{
259
- type: Input
260
- }], labelText: [{
261
- type: Input
262
- }], control: [{
263
- type: Input
264
- }], handleSelect: [{
265
- type: Output
266
- }], handleClear: [{
267
- type: Output
268
- }] } });
266
+ ], template: "<div class=\"datepicker-container\">\n <p-floatlabel>\n <p-datepicker\n inputId=\"datepicker\"\n iconDisplay=\"input\"\n [ngModel]=\"modelValue()\"\n (ngModelChange)=\"onModelChange($event)\"\n (onBlur)=\"onBlur()\"\n [selectionMode]=\"effectiveSelectionMode()\"\n [readonlyInput]=\"readonlyInput()\"\n [showClear]=\"showClear()\"\n [showIcon]=\"showIcon()\"\n [minDate]=\"minDate()\"\n [maxDate]=\"maxDate()\"\n [disabled]=\"effectiveControl.disabled\"\n [dateFormat]=\"effectiveDateFormat()\"\n [timeOnly]=\"variant() === 'time'\"\n [stepHour]=\"stepHour()\"\n [stepMinute]=\"stepMinute()\"\n [stepSecond]=\"stepSecond()\"\n [showSeconds]=\"showSeconds()\">\n <ng-template #inputicon let-clickCallBack=\"clickCallBack\">\n <fa-icon\n tabindex=\"0\"\n [icon]=\"variant() === 'time' ? faClock : faCalendarDay\"\n (keydown.enter)=\"clickCallBack($event)\"\n (keydown.space)=\"clickCallBack($event)\"\n (click)=\"clickCallBack($event)\">\n </fa-icon>\n </ng-template>\n </p-datepicker>\n\n <label for=\"datepicker\">{{ labelText() }}</label>\n </p-floatlabel>\n</div>\n", styles: [":host ::ng-deep .p-datepicker{width:100%}:host ::ng-deep .p-datepicker-input{border:none;border-bottom:1px solid var(--tk-color-border-default, #cecdcd);border-radius:0;background-color:transparent;padding:var(--tk-spacing-base-75, 12px) var(--tk-spacing-base-75, 12px) var(--tk-spacing-base-75, 12px) var(--tk-spacing-base-25, 4px)!important}:host ::ng-deep .p-datepicker-input:focus{border-color:var(--tk-color-accent-default, #16006f)}:host ::ng-deep .p-datepicker-decade{color:var(--tk-color-text-default, #121214)}:host ::ng-deep .p-datepicker-clear-icon{color:var(--tk-surface-700, #424243);inset-inline-end:2.5rem!important}:host ::ng-deep .p-floatlabel:has(.p-inputwrapper-filled) label,:host ::ng-deep .p-floatlabel:has(input:focus) label{color:var(--tk-primary-500, #16006f)}:host ::ng-deep .p-floatlabel label{color:var(--tk-surface-700, #8a8a8b);font-family:var(--tk-font-family, Poppins, sans-serif);font-size:var(--tk-font-size-2xs, 1rem);font-weight:var(--tk-font-weight-400, 400);left:var(--tk-spacing-base-25, .25rem)}:host ::ng-deep .p-datepicker-day-selected-range{background-color:var(--tk-primary-100, #b7b0d2);color:var(--tk-primary-700, #10004f)}:host ::ng-deep .p-datepicker-panel{min-width:0!important;max-width:300px!important;width:100%!important}.datepicker-container{margin-top:var(--tk-spacing-base-200, 2rem)}\n"] }]
267
+ }], ctorParameters: () => [] });
269
268
 
270
269
  /**
271
270
  * Generated bundle index. Do not edit.
@@ -1 +1 @@
1
- {"version":3,"file":"tekus-design-system-components-date-picker.mjs","sources":["../../../projects/design-system/components/date-picker/src/date-picker.component.ts","../../../projects/design-system/components/date-picker/src/date-picker.component.html","../../../projects/design-system/components/date-picker/tekus-design-system-components-date-picker.ts"],"sourcesContent":["import {\n Component,\n Input,\n Output,\n EventEmitter,\n OnInit,\n OnDestroy,\n forwardRef,\n} from '@angular/core';\nimport {\n FormsModule,\n ReactiveFormsModule,\n FormControl,\n ControlValueAccessor,\n NG_VALUE_ACCESSOR,\n} from '@angular/forms';\nimport { Subscription } from 'rxjs';\n\nimport { DatePickerModule } from 'primeng/datepicker';\nimport { FloatLabelModule } from 'primeng/floatlabel';\nimport { FaIconComponent } from '@fortawesome/angular-fontawesome';\nimport { faCalendarDay } from '@fortawesome/pro-regular-svg-icons';\n\nconst TK_DATE_PICKER_VALUE_ACCESSOR = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => DatePickerComponent),\n multi: true,\n};\n\nexport type DateValue = Date | [Date, Date] | null;\n@Component({\n selector: 'tk-date-picker',\n standalone: true,\n imports: [\n FormsModule,\n ReactiveFormsModule,\n DatePickerModule,\n FloatLabelModule,\n FaIconComponent,\n ],\n providers: [TK_DATE_PICKER_VALUE_ACCESSOR],\n templateUrl: './date-picker.component.html',\n styleUrls: ['./date-picker.component.scss'],\n})\n/**\n * @component DatePickerComponent\n * @description\n * A wrapper around PrimeNG's DatePicker component with support for single-date\n * and range selection modes. It is compatible with both Reactive Forms (formControlName, [control])\n * and Template-Driven Forms ([(ngModel)]).\n *\n * The component emits:\n * - `handleSelect` when a valid single date or a completed date range is selected.\n * - `handleClear` when the control is cleared (value becomes `null`).\n */\nexport class DatePickerComponent\n implements OnInit, OnDestroy, ControlValueAccessor\n{\n /**\n * @property {'single' | 'range'} selectionMode\n * @description\n * Defines how the datepicker behaves:\n * - `'single'`: select one date\n * - `'range'`: select a pair of dates [start, end]\n * @default 'range'\n */\n @Input() selectionMode: 'single' | 'range' = 'range';\n\n /**\n * @property {boolean} readonlyInput\n * @description\n * Disables manual typing in the input and forces the user to select via the calendar.\n * @default true\n */\n @Input() readonlyInput = true;\n\n /**\n * @property {boolean} disabled\n * @description\n * Disables component.\n * @default false\n */\n @Input() disabled = false;\n\n /**\n * @property {boolean} showClear\n * @description\n * Displays a clear button that resets the datepicker value.\n * @default true\n */\n @Input() showClear = true;\n\n /**\n * @property {boolean} showIcon\n * @description\n * Shows the calendar icon inside the input.\n * @default true\n */\n @Input() showIcon = true;\n\n /**\n * @property {string} dateFormat\n * @description\n * Format used by PrimeNG for displaying dates.\n * @default 'mm/dd/yy'\n */\n @Input() dateFormat = 'mm/dd/yy';\n\n /**\n * @property {Date | null} maxDate\n * @description\n * Maximum selectable date. When set, the calendar will prevent selecting dates after this value.\n * Provide a JavaScript Date object. Use `null` to allow any future date.\n * @default null\n */\n @Input() maxDate: Date | null = null;\n\n /**\n * @property {Date | null} minDate\n * @description\n * Minimum selectable date. When set, the calendar will prevent selecting dates before this value.\n * Provide a JavaScript Date object. Use `null` to allow any past date.\n * @default null\n */\n @Input() minDate: Date | null = null;\n\n /**\n * @property {string} labelText\n * @description\n * Label shown by the float-label wrapper.\n * @default 'Select a date'\n */\n @Input() labelText = 'Select a date';\n\n /**\n * @private\n * @property {FormControl<DateValue>} internalControl\n * @description\n * The internal FormControl used in the template. It handles value synchronization\n * for both CVA and the optional external control input.\n */\n internalControl = new FormControl<DateValue>(null);\n\n /**\n * @private\n * @property {Subscription} sub\n * @description Subscription to the valueChanges observable.\n */\n private sub!: Subscription;\n\n // Functions registered by ControlValueAccessor to communicate with the outside form\n private onChange: (value: DateValue) => void = () => {};\n private onTouched: () => void = () => {};\n\n /**\n * @property {FormControl<DateValue> | null} control\n * @description\n * Allows passing an external FormControl (traditional Reactive Forms usage).\n * If provided, it overrides the internal control.\n */\n @Input() set control(ctrl: FormControl<DateValue> | null) {\n // If the user provides a control, we use that control for everything.\n if (ctrl) {\n this.internalControl = ctrl;\n }\n }\n get control(): FormControl<DateValue> {\n return this.internalControl;\n }\n\n /**\n * @event handleSelect\n * @description\n * Emitted when:\n * - single mode → a valid Date is selected\n * - range mode → both start and end dates are selected\n *\n * Payload:\n * - Date (single mode)\n * - [Date, Date] (completed range)\n */\n @Output() handleSelect = new EventEmitter<DateValue>();\n\n /**\n * @event handleClear\n * @description\n * Emitted when the control's value becomes `null`.\n */\n @Output() handleClear = new EventEmitter<void>();\n\n /**\n * @property faCalendarDay\n * @description\n * Icon displayed inside the datepicker input.\n */\n faCalendarDay = faCalendarDay;\n\n /**\n * @method writeValue\n * @description Writes a new value from the form model (ngModel or formControl) into the component.\n */\n writeValue(value: DateValue): void {\n if (value !== undefined) {\n // Use { emitEvent: false } to prevent an unnecessary valueChanges loop.\n this.internalControl.setValue(value, { emitEvent: false });\n }\n }\n\n /**\n * @method registerOnChange\n * @description Registers a callback function to be called when the control's value changes.\n */\n registerOnChange(fn: (value: DateValue) => void): void {\n this.onChange = fn;\n }\n\n /**\n * @method registerOnTouched\n * @description Registers a callback function to be called when the control receives a blur event (is touched).\n */\n registerOnTouched(fn: () => void): void {\n this.onTouched = fn;\n }\n\n /**\n * @method setDisabledState\n * @description Called when the control should be disabled or enabled.\n */\n setDisabledState(isDisabled: boolean): void {\n const actionMap: { [key: string]: () => void } = {\n true: () => this.internalControl.disable(),\n false: () => this.internalControl.enable(),\n };\n actionMap[String(isDisabled)]();\n }\n\n /**\n * @method ngOnInit\n * @description\n * Subscribes to the internal control's valueChanges:\n * 1. Notifies the external form (CVA) via `this.onChange()`.\n * 2. Emits the semantic events `handleSelect` or `handleClear`.\n */\n ngOnInit(): void {\n this.sub = this.internalControl.valueChanges.subscribe(value => {\n // Notify the CVA / External Form\n this.onChange(value);\n this.onTouched();\n\n if (value === null) {\n this.handleClear.emit();\n return;\n }\n // RANGE MODE\n if (this.selectionMode === 'range') {\n if (Array.isArray(value)) {\n const [start, end] = value;\n // Emit ONLY when both dates exist\n if (start instanceof Date && end instanceof Date) {\n this.handleSelect.emit([start, end]);\n }\n }\n return;\n }\n // SINGLE MODE\n if (this.selectionMode === 'single' && value instanceof Date) {\n this.handleSelect.emit(value);\n }\n });\n }\n\n /**\n * @method ngOnDestroy\n * @description Cleans up the internal subscription when the component is destroyed.\n */\n ngOnDestroy(): void {\n this.sub?.unsubscribe();\n }\n\n /**\n * @method clear\n * @description\n * Programmatically clears the control's value,\n * which automatically triggers `handleClear`.\n */\n clear() {\n this.internalControl.setValue(null);\n }\n}\n","<div class=\"datepicker-container\">\n <p-floatlabel>\n <p-datepicker\n inputId=\"datepicker\"\n iconDisplay=\"input\"\n [formControl]=\"internalControl\"\n [selectionMode]=\"selectionMode\"\n [readonlyInput]=\"readonlyInput\"\n [showClear]=\"showClear\"\n [showIcon]=\"showIcon\"\n [minDate]=\"minDate\"\n [maxDate]=\"maxDate\"\n [disabled]=\"disabled\"\n [dateFormat]=\"dateFormat\">\n <ng-template #inputicon let-clickCallBack=\"clickCallBack\">\n <fa-icon\n tabindex=\"0\"\n [icon]=\"faCalendarDay\"\n (keydown.enter)=\"clickCallBack($event)\"\n (keydown.space)=\"clickCallBack($event)\"\n (click)=\"clickCallBack($event)\">\n </fa-icon>\n </ng-template>\n </p-datepicker>\n\n <label for=\"datepicker\">{{ labelText }}</label>\n </p-floatlabel>\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;AAuBA,MAAM,6BAA6B,GAAG;AACpC,IAAA,OAAO,EAAE,iBAAiB;AAC1B,IAAA,WAAW,EAAE,UAAU,CAAC,MAAM,mBAAmB,CAAC;AAClD,IAAA,KAAK,EAAE,IAAI;CACZ;AAiBD;;;;;;;;;;AAUG;MACU,mBAAmB,CAAA;AAzBhC,IAAA,WAAA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,CAAA;sBAApB;;;AE5LH;;AAEG;;;;"}
1
+ {"version":3,"file":"tekus-design-system-components-date-picker.mjs","sources":["../../../projects/design-system/components/date-picker/src/date-picker.component.ts","../../../projects/design-system/components/date-picker/src/date-picker.component.html","../../../projects/design-system/components/date-picker/tekus-design-system-components-date-picker.ts"],"sourcesContent":["import {\n Component,\n OnInit,\n OnDestroy,\n inject,\n input,\n model,\n computed,\n output,\n} from '@angular/core';\nimport {\n FormsModule,\n ReactiveFormsModule,\n FormControl,\n ControlValueAccessor,\n NgControl,\n} from '@angular/forms';\nimport { Subscription } from 'rxjs';\n\nimport { DatePickerModule } from 'primeng/datepicker';\nimport { FloatLabelModule } from 'primeng/floatlabel';\nimport { FaIconComponent } from '@fortawesome/angular-fontawesome';\nimport { faCalendarDay, faClock } from '@fortawesome/pro-regular-svg-icons';\n\nexport type DateValue = Date | [Date, Date] | null;\n\n@Component({\n selector: 'tk-date-picker',\n standalone: true,\n imports: [\n FormsModule,\n ReactiveFormsModule,\n DatePickerModule,\n FloatLabelModule,\n FaIconComponent,\n ],\n templateUrl: './date-picker.component.html',\n styleUrls: ['./date-picker.component.scss'],\n})\n/**\n * @component DatePickerComponent\n * @description\n * A wrapper around PrimeNG's DatePicker component with support for single-date,\n * range selection, and time-only modes. It uses Angular Signals for reactivity\n * and strictly implements the ControlValueAccessor interface via NgControl.\n */\nexport class DatePickerComponent\n implements OnInit, OnDestroy, ControlValueAccessor\n{\n /** Internal references and injections */\n readonly ngControl = inject(NgControl, { self: true, optional: true });\n\n constructor() {\n if (this.ngControl) {\n this.ngControl.valueAccessor = this;\n }\n }\n\n /**\n * @property {InputSignal<'date' | 'time'>} variant\n * @description\n * Defines the visual and functional mode:\n * - `'date'`: standard date/range picker\n * - `'time'`: time-only picker\n * @default 'date'\n */\n variant = input<'date' | 'time'>('date');\n\n /**\n * @property {InputSignal<'single' | 'range'>} selectionMode\n * @description\n * Defines how the datepicker behaves:\n * - `'single'`: select one date\n * - `'range'`: select a pair of dates [start, end]\n * @default 'range'\n */\n selectionMode = input<'single' | 'range'>('range');\n\n /**\n * @property {InputSignal<boolean>} readonlyInput\n * @description\n * Disables manual typing in the input and forces the user to select via the calendar.\n * @default true\n */\n readonlyInput = input<boolean>(true);\n\n /**\n * @property {InputSignal<boolean>} showClear\n * @description\n * Displays a clear button that resets the datepicker value.\n * @default true\n */\n showClear = input<boolean>(true);\n\n /**\n * @property {InputSignal<boolean>} showIcon\n * @description\n * Shows the calendar or clock icon inside the input.\n * @default true\n */\n showIcon = input<boolean>(true);\n\n /**\n * @property {InputSignal<string>} dateFormat\n * @description\n * Format used by PrimeNG for displaying dates.\n * @default 'mm/dd/yy'\n */\n dateFormat = input<string>('mm/dd/yy');\n\n /**\n * @property {InputSignal<string>} timeFormat\n * @description\n * Format used by PrimeNG for displaying times.\n * @default 'HH:mm'\n */\n timeFormat = input<string>('HH:mm');\n\n /**\n * @property {InputSignal<number>} stepHour\n * @description\n * Hours to skip when clicking up/down.\n * @default 1\n */\n stepHour = input<number>(1);\n\n /**\n * @property {InputSignal<number>} stepMinute\n * @description\n * Minutes to skip when clicking up/down.\n * @default 1\n */\n stepMinute = input<number>(1);\n\n /**\n * @property {InputSignal<number>} stepSecond\n * @description\n * Seconds to skip when clicking up/down.\n * @default 1\n */\n stepSecond = input<number>(1);\n\n /**\n * @property {InputSignal<boolean>} showSeconds\n * @description\n * Whether to show seconds in the time picker.\n * @default false\n */\n showSeconds = input<boolean>(false);\n\n /**\n * @property {InputSignal<Date | null>} maxDate\n * @description\n * Maximum selectable date.\n * @default null\n */\n maxDate = input<Date | null>(null);\n\n /**\n * @property {InputSignal<Date | null>} minDate\n * @description\n * Minimum selectable date.\n * @default null\n */\n minDate = input<Date | null>(null);\n\n /**\n * @property {InputSignal<string>} labelText\n * @description\n * Label shown by the float-label wrapper.\n */\n labelText = input<string>('Select a date');\n\n /**\n * @property {InputSignal<FormControl>} control\n * @description\n * External FormControl used to read/set the datepicker value.\n * If not provided, an internal FormControl is created.\n */\n control = input<FormControl | undefined>(undefined);\n\n /**\n * @property {ModelSignal<DateValue>} modelValue\n * @description\n * The value of the datepicker model. Supports two-way binding.\n */\n modelValue = model<DateValue>(null);\n\n /**\n * @property {OutputRef<DateValue>} handleSelect\n * @description\n * Emitted when a value is selected.\n */\n handleSelect = output<DateValue>();\n\n /**\n * @property {OutputRef<void>} handleClear\n * @description\n * Emitted when the value is cleared.\n */\n handleClear = output<void>();\n\n /** Computed properties */\n\n /**\n * @property {Signal<'single' | 'range'>} effectiveSelectionMode\n * @description\n * Returns 'single' automatically if variant is 'time', otherwise returns the user-provided selectionMode.\n */\n effectiveSelectionMode = computed(() => {\n return this.variant() === 'time' ? 'single' : this.selectionMode();\n });\n\n /**\n * @property {Signal<string>} effectiveDateFormat\n * @description\n * Returns the user-provided dateFormat or timeFormat based on the variant.\n */\n effectiveDateFormat = computed(() => {\n return this.variant() === 'time' ? this.timeFormat() : this.dateFormat();\n });\n\n /**\n * @property {Signal<FormControl>} effectiveControl\n * @description\n * Returns the external FormControl from NgControl or a local fallback.\n */\n internalControl = new FormControl<DateValue>(null);\n get effectiveControl(): FormControl {\n return (\n (this.ngControl?.control as FormControl) ||\n this.control() ||\n this.internalControl\n );\n }\n\n /** Icons */\n faCalendarDay = faCalendarDay;\n faClock = faClock;\n\n /** CVA Logic */\n onChange: (value: DateValue) => void = () => {};\n onTouched: () => void = () => {};\n private readonly sub = new Subscription();\n\n ngOnInit(): void {\n const control = this.effectiveControl;\n\n // Synchronize signal model with control value\n this.modelValue.set(control.value);\n\n this.sub.add(\n control.valueChanges.subscribe(value => {\n this.modelValue.set(value);\n })\n );\n }\n\n ngOnDestroy(): void {\n this.sub.unsubscribe();\n }\n\n writeValue(value: DateValue): void {\n this.modelValue.set(value);\n }\n\n registerOnChange(fn: (value: DateValue) => void): void {\n this.onChange = fn;\n }\n\n registerOnTouched(fn: () => void): void {\n this.onTouched = fn;\n }\n\n setDisabledState(isDisabled: boolean): void {\n const action = isDisabled ? 'disable' : 'enable';\n this.effectiveControl[action]({ emitEvent: false });\n }\n\n /**\n * @method onModelChange\n * @description\n * Called when the PrimeNG DatePicker template updates the value.\n */\n onModelChange(value: DateValue): void {\n this.modelValue.set(value);\n this.onChange(value);\n this.effectiveControl.setValue(value, { emitEvent: false });\n this.effectiveControl.markAsDirty();\n\n if (value === null) {\n this.handleClear.emit();\n } else if (this.selectionMode() === 'range') {\n if (Array.isArray(value)) {\n const [start, end] = value;\n if (start instanceof Date && end instanceof Date) {\n this.handleSelect.emit(value);\n }\n }\n } else if (value instanceof Date) {\n this.handleSelect.emit(value);\n }\n }\n\n /**\n * @method onBlur\n * @description\n * Triggered when the component loses focus.\n */\n onBlur(): void {\n this.onTouched();\n this.effectiveControl.markAsTouched();\n }\n\n /**\n * @method clear\n * @description\n * Programmatically clears the value.\n */\n clear() {\n this.onModelChange(null);\n }\n}\n","<div class=\"datepicker-container\">\n <p-floatlabel>\n <p-datepicker\n inputId=\"datepicker\"\n iconDisplay=\"input\"\n [ngModel]=\"modelValue()\"\n (ngModelChange)=\"onModelChange($event)\"\n (onBlur)=\"onBlur()\"\n [selectionMode]=\"effectiveSelectionMode()\"\n [readonlyInput]=\"readonlyInput()\"\n [showClear]=\"showClear()\"\n [showIcon]=\"showIcon()\"\n [minDate]=\"minDate()\"\n [maxDate]=\"maxDate()\"\n [disabled]=\"effectiveControl.disabled\"\n [dateFormat]=\"effectiveDateFormat()\"\n [timeOnly]=\"variant() === 'time'\"\n [stepHour]=\"stepHour()\"\n [stepMinute]=\"stepMinute()\"\n [stepSecond]=\"stepSecond()\"\n [showSeconds]=\"showSeconds()\">\n <ng-template #inputicon let-clickCallBack=\"clickCallBack\">\n <fa-icon\n tabindex=\"0\"\n [icon]=\"variant() === 'time' ? faClock : faCalendarDay\"\n (keydown.enter)=\"clickCallBack($event)\"\n (keydown.space)=\"clickCallBack($event)\"\n (click)=\"clickCallBack($event)\">\n </fa-icon>\n </ng-template>\n </p-datepicker>\n\n <label for=\"datepicker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AA,EAAA,mBAAA,EAAA,gBAAA,EAAA,gBAAA,EAAA,QAAA,EAAA,MAAA,EAAA,aAAA,CAAA,EAAA,OAAA,EAAA,CAAA,SAAA,EAAA,QAAA,EAAA,SAAA,EAAA,UAAA,EAAA,SAAA,EAAA,SAAA,EAAA,cAAA,EAAA,cAAA,EAAA,eAAA,EAAA,cAAA,EAAA,gBAAA,EAAA,QAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAChB,gBAAgB,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,EAAA,CAAA,UAAA,EAAA,QAAA,EAAA,2CAAA,EAAA,MAAA,EAAA,CAAA,SAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAChB,eAAe,EAAA,QAAA,EAAA,SAAA,EAAA,MAAA,EAAA,CAAA,MAAA,EAAA,OAAA,EAAA,WAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,QAAA,EAAA,SAAA,EAAA,QAAA,EAAA,QAAA,EAAA,YAAA,EAAA,WAAA,EAAA,UAAA,CAAA,EAAA,CAAA,EAAA,CAAA,CAAA;;4FAYN,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBApB/B,SAAS;+BACE,gBAAgB,EAAA,UAAA,EACd,IAAI,EACP,OAAA,EAAA;wBACP,WAAW;wBACX,mBAAmB;wBACnB,gBAAgB;wBAChB,gBAAgB;wBAChB,eAAe;AAChB,qBAAA,EAAA,QAAA,EAAA,utCAAA,EAAA,MAAA,EAAA,CAAA,g0CAAA,CAAA,EAAA;;;AEnCH;;AAEG;;;;"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tekus/design-system",
3
3
  "description": "Tekus design system library",
4
- "version": "5.20.0",
4
+ "version": "5.21.0",
5
5
  "license": "UNLICENSED",
6
6
  "peerDependencies": {
7
7
  "@angular/core": "^19.2.15",
@@ -39,6 +39,10 @@
39
39
  "types": "./core/index.d.ts",
40
40
  "default": "./fesm2022/tekus-design-system-core.mjs"
41
41
  },
42
+ "./core/types": {
43
+ "types": "./core/types/index.d.ts",
44
+ "default": "./fesm2022/tekus-design-system-core-types.mjs"
45
+ },
42
46
  "./components/autocomplete": {
43
47
  "types": "./components/autocomplete/index.d.ts",
44
48
  "default": "./fesm2022/tekus-design-system-components-autocomplete.mjs"
@@ -59,14 +63,14 @@
59
63
  "types": "./components/date-picker/index.d.ts",
60
64
  "default": "./fesm2022/tekus-design-system-components-date-picker.mjs"
61
65
  },
62
- "./components/drawer": {
63
- "types": "./components/drawer/index.d.ts",
64
- "default": "./fesm2022/tekus-design-system-components-drawer.mjs"
65
- },
66
66
  "./components/fallback-view": {
67
67
  "types": "./components/fallback-view/index.d.ts",
68
68
  "default": "./fesm2022/tekus-design-system-components-fallback-view.mjs"
69
69
  },
70
+ "./components/drawer": {
71
+ "types": "./components/drawer/index.d.ts",
72
+ "default": "./fesm2022/tekus-design-system-components-drawer.mjs"
73
+ },
70
74
  "./components/icon": {
71
75
  "types": "./components/icon/index.d.ts",
72
76
  "default": "./fesm2022/tekus-design-system-components-icon.mjs"
@@ -131,10 +135,6 @@
131
135
  "types": "./components/topbar/index.d.ts",
132
136
  "default": "./fesm2022/tekus-design-system-components-topbar.mjs"
133
137
  },
134
- "./core/types": {
135
- "types": "./core/types/index.d.ts",
136
- "default": "./fesm2022/tekus-design-system-core-types.mjs"
137
- },
138
138
  "./directives/gird-item": {
139
139
  "types": "./directives/gird-item/index.d.ts",
140
140
  "default": "./fesm2022/tekus-design-system-directives-gird-item.mjs"