@sd-angular/core 19.0.0-beta.32 → 19.0.0-beta.34

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.
Files changed (34) hide show
  1. package/components/view/src/view.component.d.ts +11 -11
  2. package/fesm2022/sd-angular-core-components-table.mjs +4 -4
  3. package/fesm2022/sd-angular-core-components-table.mjs.map +1 -1
  4. package/fesm2022/sd-angular-core-components-view.mjs +28 -40
  5. package/fesm2022/sd-angular-core-components-view.mjs.map +1 -1
  6. package/fesm2022/sd-angular-core-components-workflow.mjs +22 -22
  7. package/fesm2022/sd-angular-core-components-workflow.mjs.map +1 -1
  8. package/fesm2022/sd-angular-core-forms-autocomplete.mjs +165 -327
  9. package/fesm2022/sd-angular-core-forms-autocomplete.mjs.map +1 -1
  10. package/fesm2022/sd-angular-core-forms-date.mjs +134 -279
  11. package/fesm2022/sd-angular-core-forms-date.mjs.map +1 -1
  12. package/fesm2022/sd-angular-core-forms-datetime.mjs +132 -289
  13. package/fesm2022/sd-angular-core-forms-datetime.mjs.map +1 -1
  14. package/fesm2022/sd-angular-core-forms-input-number.mjs +161 -337
  15. package/fesm2022/sd-angular-core-forms-input-number.mjs.map +1 -1
  16. package/fesm2022/sd-angular-core-forms-input.mjs +126 -286
  17. package/fesm2022/sd-angular-core-forms-input.mjs.map +1 -1
  18. package/fesm2022/sd-angular-core-forms-select.mjs +205 -400
  19. package/fesm2022/sd-angular-core-forms-select.mjs.map +1 -1
  20. package/fesm2022/sd-angular-core-forms-textarea.mjs +120 -226
  21. package/fesm2022/sd-angular-core-forms-textarea.mjs.map +1 -1
  22. package/fesm2022/sd-angular-core-modules-layout.mjs +1 -1
  23. package/fesm2022/sd-angular-core-modules-layout.mjs.map +1 -1
  24. package/fesm2022/sd-angular-core-services-confirm.mjs +1 -1
  25. package/forms/autocomplete/src/autocomplete.component.d.ts +44 -51
  26. package/forms/date/src/date.component.d.ts +40 -46
  27. package/forms/datetime/src/datetime.component.d.ts +39 -47
  28. package/forms/input/src/input.component.d.ts +44 -55
  29. package/forms/input-number/src/input-number.component.d.ts +45 -53
  30. package/forms/select/src/select.component.d.ts +47 -56
  31. package/forms/textarea/src/textarea.component.d.ts +33 -40
  32. package/package.json +39 -39
  33. package/sd-angular-core-19.0.0-beta.34.tgz +0 -0
  34. package/sd-angular-core-19.0.0-beta.32.tgz +0 -0
@@ -1,10 +1,9 @@
1
1
  import * as i1 from '@angular/common';
2
2
  import { CommonModule } from '@angular/common';
3
3
  import * as i0 from '@angular/core';
4
- import { EventEmitter, ViewChild, ContentChild, Output, Input, Inject, Optional, ChangeDetectionStrategy, Component } from '@angular/core';
4
+ import { viewChild, contentChild, inject, ChangeDetectorRef, input, computed, booleanAttribute, model, output, effect, untracked, ChangeDetectionStrategy, Component } from '@angular/core';
5
5
  import * as i2 from '@angular/forms';
6
- import { NgForm, Validators, FormsModule, ReactiveFormsModule } from '@angular/forms';
7
- import { MatDatepicker } from '@angular/material/datepicker';
6
+ import { Validators, NgForm, FormsModule, ReactiveFormsModule } from '@angular/forms';
8
7
  import { MatFormFieldModule } from '@angular/material/form-field';
9
8
  import * as i4 from '@angular/material/icon';
10
9
  import { MatIconModule } from '@angular/material/icon';
@@ -14,189 +13,136 @@ import * as i5 from '@angular/material/tooltip';
14
13
  import { MatTooltipModule } from '@angular/material/tooltip';
15
14
  import { provideMomentDatetimeAdapter } from '@ng-matero/extensions-moment-adapter';
16
15
  import * as i6 from '@ng-matero/extensions/datetimepicker';
17
- import { MtxDatetimepickerModule, MtxDatetimepicker } from '@ng-matero/extensions/datetimepicker';
16
+ import { MtxDatetimepicker, MtxDatetimepickerModule } from '@ng-matero/extensions/datetimepicker';
18
17
  import { SdView } from '@sd-angular/core/components/view';
19
18
  import { SdViewDefDirective } from '@sd-angular/core/forms/directives';
20
19
  import { SdLabel } from '@sd-angular/core/forms/label';
21
- import { SdFormControl, SD_FORM_CONFIGURATION } from '@sd-angular/core/forms/models';
22
- import { DateUtilities, SdUtilities } from '@sd-angular/core/utilities/extensions';
20
+ import { SD_FORM_CONFIGURATION, SdFormControl } from '@sd-angular/core/forms/models';
21
+ import { SdUtilities, DateUtilities } from '@sd-angular/core/utilities/extensions';
23
22
  import moment from 'moment';
24
23
  import { Subscription } from 'rxjs';
25
24
  import * as uuid from 'uuid';
26
25
 
27
26
  /* eslint-disable @typescript-eslint/no-explicit-any */
28
27
  /* eslint-disable @angular-eslint/no-input-rename */
29
- // eslint-disable-next-line @angular-eslint/component-class-suffix
30
28
  class SdDatetime {
31
- ref;
32
- formConfig;
33
- sdLabelTemplate;
34
- sdValueTemplate;
35
- datetimePicker;
36
29
  id = `I${uuid.v4()}`;
37
- autoId;
38
- set _autoId(val) {
39
- if (!val) {
40
- return;
41
- }
42
- this.autoId = `forms-datetime-${val}`;
43
- }
44
- isMobileOrTablet = false;
45
- #date;
46
- #name = uuid.v4();
47
- set name(val) {
48
- if (val) {
49
- this.#name = val;
50
- }
51
- }
52
- appearance = 'outline';
53
- hideInlineError = false;
54
- set _hideInlineError(val) {
55
- this.hideInlineError = val === '' || val;
56
- val = val === '' || val;
57
- }
30
+ // ==========================================
31
+ // 1. SIGNAL QUERIES
32
+ // ==========================================
33
+ inputRef = viewChild('input');
34
+ datetimePicker = viewChild(MtxDatetimepicker);
35
+ sdLabelTemplate = contentChild('sdLabel');
36
+ sdValueTemplate = contentChild('sdValue');
37
+ sdViewDef = contentChild(SdViewDefDirective);
38
+ // ==========================================
39
+ // 2. INJECTS
40
+ // ==========================================
41
+ ref = inject(ChangeDetectorRef);
42
+ formConfig = inject(SD_FORM_CONFIGURATION, { optional: true });
43
+ // ==========================================
44
+ // 3. SIGNAL INPUTS & MODEL
45
+ // ==========================================
46
+ autoIdInput = input(undefined, { alias: 'autoId' });
47
+ autoId = computed(() => this.autoIdInput() ? `forms-datetime-${this.autoIdInput()}` : undefined);
48
+ name = input(uuid.v4());
49
+ size = input('md');
50
+ form = input();
51
+ label = input();
52
+ helperText = input();
53
+ placeholder = input();
54
+ hideInlineError = input(false, { transform: booleanAttribute });
55
+ required = input(false, { transform: booleanAttribute });
56
+ disabled = input(false, { transform: booleanAttribute });
57
+ viewed = input(false, { transform: booleanAttribute });
58
+ inlineError = input();
59
+ hyperlink = input();
60
+ appearanceInput = input(undefined, { alias: 'appearance' });
61
+ appearance = computed(() => this.appearanceInput() ?? this.formConfig?.appearance ?? 'outline');
62
+ // Xử lý thông minh Gom min/minDate và max/maxDate
63
+ minInput = input(undefined, { alias: 'min' });
64
+ minDateInput = input(undefined, { alias: 'minDate' });
65
+ resolvedMin = computed(() => this.#parseDateBoundary(this.minInput() ?? this.minDateInput()));
66
+ maxInput = input(undefined, { alias: 'max' });
67
+ maxDateInput = input(undefined, { alias: 'maxDate' });
68
+ resolvedMax = computed(() => this.#parseDateBoundary(this.maxInput() ?? this.maxDateInput()));
69
+ valueModel = model(undefined, { alias: 'model' });
70
+ // ==========================================
71
+ // 4. SIGNAL OUTPUTS
72
+ // ==========================================
73
+ sdChange = output();
74
+ sdFocus = output();
75
+ // ==========================================
76
+ // 5. INTERNAL STATE & STREAMS
77
+ // ==========================================
78
+ isMobileOrTablet = SdUtilities.isMobile();
58
79
  formControl = new SdFormControl();
59
- min;
60
- set _min(val) {
61
- if (val === 'TODAY') {
62
- this.min = new Date();
63
- }
64
- else if (val && DateUtilities.isDate(val)) {
65
- this.min = new Date(val);
66
- }
67
- else {
68
- this.min = null;
69
- }
70
- }
71
- max;
72
- set _max(val) {
73
- if (val === 'TODAY') {
74
- this.max = new Date();
75
- }
76
- else if (val && DateUtilities.isDate(val)) {
77
- this.max = new Date(val);
78
- }
79
- else {
80
- this.max = null;
81
- }
82
- }
83
- size = 'md';
84
- #form;
85
- set form(val) {
86
- if (val) {
87
- if (val instanceof NgForm) {
88
- this.#form = val.form;
89
- }
90
- else {
91
- this.#form = val;
92
- }
93
- }
94
- }
95
- set disabled(val) {
96
- val = val === '' || val;
97
- if (val) {
98
- this.formControl.disable();
99
- }
100
- else {
101
- this.formControl.enable();
102
- }
103
- }
104
- viewed = false;
105
- set _viewed(val) {
106
- this.viewed = val === '' || !!val;
107
- }
108
- hyperlink;
109
- required = false;
110
- set _required(val) {
111
- this.required = val === '' || !!val;
112
- if (this.required) {
113
- this.formControl.setValidators([Validators.required]);
114
- }
115
- else {
116
- this.formControl.clearValidators();
117
- }
118
- }
119
- inlineError;
120
- set _inlineError(val) {
121
- this.inlineError = val;
122
- // this.#updateValidator();
123
- if (this.inlineError) {
124
- this.formControl.setValidators([this.customInlineErrorValidator()]);
125
- this.formControl.updateValueAndValidity();
126
- }
127
- else {
128
- this.formControl.clearValidators();
129
- this.formControl.updateValueAndValidity();
130
- }
131
- }
132
- label;
133
- set _label(val) {
134
- this.label = val;
135
- }
136
- helperText;
137
- set _helperText(val) {
138
- this.helperText = val;
139
- }
140
- placeholder;
141
- set minDate(val) {
142
- if (DateUtilities.isDate(val)) {
143
- this.min = new Date(val);
144
- }
145
- else {
146
- this.min = null;
147
- }
148
- }
149
- set maxDate(val) {
150
- if (DateUtilities.isDate(val)) {
151
- this.max = new Date(val);
152
- }
153
- else {
154
- this.max = null;
155
- }
156
- }
157
- sdChange = new EventEmitter();
158
- sdFocus = new EventEmitter();
159
- set model(val) {
160
- if (!DateUtilities.isDate(val)) {
161
- val = null;
162
- }
163
- val = DateUtilities.toFormat(val, 'yyyy/MM/dd HH:mm');
164
- if (this.#date !== val) {
165
- this.#date = val;
166
- const date = DateUtilities.isDate(this.#date)
167
- ? moment(DateUtilities.toFormat(this.#date, 'yyyy/MM/dd HH:mm'), 'YYYY/MM/DD HH:mm')
168
- : null;
169
- this.formControl.setValue(date);
170
- }
171
- }
172
- modelChange = new EventEmitter();
173
- #subscription = new Subscription();
174
- sdViewDef;
175
- input;
176
- datePicker;
177
80
  isFocused = false;
178
- constructor(ref, formConfig) {
179
- this.ref = ref;
180
- this.formConfig = formConfig;
181
- this.isMobileOrTablet = SdUtilities.isMobile();
182
- }
183
- ngOnDestroy() {
184
- this.#form?.removeControl(this.#name);
185
- this.#subscription.unsubscribe();
81
+ isValid;
82
+ #date;
83
+ #subscription = new Subscription();
84
+ constructor() {
85
+ // EFFECT 1: Sync model thay đổi từ bên ngoài (String/Date -> Moment)
86
+ effect(() => {
87
+ let val = this.valueModel();
88
+ untracked(() => {
89
+ if (!DateUtilities.isDate(val)) {
90
+ val = null;
91
+ }
92
+ val = DateUtilities.toFormat(val, 'yyyy/MM/dd HH:mm');
93
+ if (this.#date !== val) {
94
+ this.#date = val;
95
+ const dateObj = DateUtilities.isDate(this.#date)
96
+ ? moment(DateUtilities.toFormat(this.#date, 'yyyy/MM/dd HH:mm'), 'YYYY/MM/DD HH:mm')
97
+ : null;
98
+ this.formControl.setValue(dateObj, { emitEvent: false });
99
+ }
100
+ });
101
+ });
102
+ // EFFECT 2: Sync Disable
103
+ effect(() => {
104
+ if (this.disabled())
105
+ this.formControl.disable({ emitEvent: false });
106
+ else
107
+ this.formControl.enable({ emitEvent: false });
108
+ });
109
+ // EFFECT 3: Update Validators
110
+ effect(() => {
111
+ const req = this.required();
112
+ const inl = this.inlineError();
113
+ untracked(() => {
114
+ const validators = [];
115
+ if (req)
116
+ validators.push(Validators.required);
117
+ if (inl)
118
+ validators.push(this.customInlineErrorValidator());
119
+ this.formControl.setValidators(validators.length ? validators : null);
120
+ this.formControl.updateValueAndValidity({ emitEvent: false });
121
+ });
122
+ });
186
123
  }
187
124
  ngOnInit() {
188
- this.appearance = this.appearance || this.formConfig?.appearance;
189
125
  this.#subscription.add(this.formControl.sdChanges.subscribe(() => {
190
- // this.formControl.updateValueAndValidity();
191
126
  this.ref.markForCheck();
192
127
  }));
193
- this.#form?.addControl(this.#name, this.formControl);
128
+ const formGroup = this.form() instanceof NgForm ? this.form().form : this.form();
129
+ formGroup?.addControl(this.name(), this.formControl);
130
+ }
131
+ ngOnDestroy() {
132
+ const formGroup = this.form() instanceof NgForm ? this.form().form : this.form();
133
+ formGroup?.removeControl(this.name());
134
+ this.#subscription.unsubscribe();
135
+ }
136
+ // Hàm private tái sử dụng cho parse Min/Max Datetime
137
+ #parseDateBoundary(val) {
138
+ if (val === 'TODAY')
139
+ return new Date();
140
+ if (val && DateUtilities.isDate(val))
141
+ return new Date(val);
142
+ return null;
194
143
  }
195
- // Hàm tạo Validators tùy chỉnh cho inlineError
196
144
  customInlineErrorValidator() {
197
- return () => {
198
- return { inlineError: true };
199
- };
145
+ return () => ({ inlineError: true });
200
146
  }
201
147
  onFocus = () => {
202
148
  this.isFocused = true;
@@ -206,38 +152,30 @@ class SdDatetime {
206
152
  this.isFocused = false;
207
153
  };
208
154
  onClick = () => {
209
- if (this.sdViewDef?.templateRef) {
155
+ if (this.sdViewDef()?.templateRef) {
210
156
  if (!this.formControl.disabled && !this.isFocused) {
211
157
  this.focus();
212
158
  }
213
159
  }
214
160
  };
215
161
  blur = () => {
216
- this.input?.nativeElement?.blur();
162
+ this.inputRef()?.nativeElement?.blur();
217
163
  };
218
164
  focus = () => {
219
165
  this.isFocused = true;
220
166
  setTimeout(() => {
221
- this.input?.nativeElement?.focus();
222
- this.datePicker?.open();
223
- //
167
+ this.inputRef()?.nativeElement?.focus();
168
+ this.datetimePicker()?.open();
224
169
  }, 100);
225
170
  };
226
171
  focusInputElement() {
227
- this.input?.nativeElement?.focus();
172
+ this.inputRef()?.nativeElement?.focus();
228
173
  }
229
- isValid;
230
174
  onKeyDown = (event) => {
231
175
  const key = event.keyCode || event.charCode;
232
- let isShift = false;
233
- if (key === 16) {
234
- isShift = true;
235
- }
236
- // cho phép copy parse
237
- if (event.ctrlKey && (key === 67 || key === 86)) {
176
+ const isShift = key === 16;
177
+ if (event.ctrlKey && (key === 67 || key === 86))
238
178
  return true;
239
- }
240
- // Allow only Numeric Keys.
241
179
  if (((key >= 48 && key <= 57) ||
242
180
  key === 8 ||
243
181
  key <= 37 ||
@@ -246,18 +184,16 @@ class SdDatetime {
246
184
  key === 191 ||
247
185
  key === 186 ||
248
186
  key === 59) &&
249
- isShift === false) {
187
+ !isShift) {
250
188
  return true;
251
189
  }
252
- else {
253
- return false;
254
- }
190
+ return false;
255
191
  };
256
192
  onConfirmInput = (event) => {
257
193
  const currentVal = event.target.value;
258
194
  const formControl = this.formControl;
259
- let regexToMinutes = /^([1-9]|([012][0-9])|(3[01]))\/([0]{0,1}[1-9]|1[012])\/\d\d\d\d [012]{0,1}[0-9]:[0-6][0-9]$/g; // dd/MM/yyyy HH:mm
260
- let regexToSecond = /^([1-9]|([012][0-9])|(3[01]))\/([0]{0,1}[1-9]|1[012])\/\d\d\d\d [012]{0,1}[0-9]:[0-6][0-9]:[0-6][0-9]$/g; // dd/MM/yyyy HH:mm:ss
195
+ const regexToMinutes = /^([1-9]|([012][0-9])|(3[01]))\/([0]{0,1}[1-9]|1[012])\/\d\d\d\d [012]{0,1}[0-9]:[0-6][0-9]$/g;
196
+ const regexToSecond = /^([1-9]|([012][0-9])|(3[01]))\/([0]{0,1}[1-9]|1[012])\/\d\d\d\d [012]{0,1}[0-9]:[0-6][0-9]:[0-6][0-9]$/g;
261
197
  if (currentVal && !(regexToMinutes.test(currentVal) || regexToSecond.test(currentVal))) {
262
198
  setTimeout(() => {
263
199
  formControl.markAsDirty();
@@ -272,30 +208,13 @@ class SdDatetime {
272
208
  }, 0);
273
209
  }
274
210
  };
275
- // onChangeBackup = (_: any) => {
276
- // // Ép kiểu
277
- // const event: MtxDatetimepickerInputEvent<Moment> = _;
278
- // const value = DateUtilities.toFormat(event.value?.toDate(), 'yyyy/MM/dd HH:mm:ss');
279
- // this.input?.nativeElement?.focus();
280
- // if (!this.isValid) {
281
- // if (this.#date !== value) {
282
- // this.modelChange.emit(value);
283
- // this.sdChange.emit(value);
284
- // }
285
- // } else {
286
- // this.isValid = false;
287
- // this.formControl.setValue(null);
288
- // this.modelChange.emit(null);
289
- // this.sdChange.emit(null);
290
- // }
291
- // };
292
211
  onChange = (_) => {
293
- // Ép kiểu
294
212
  const event = _;
213
+ // Giữ nguyên logic format cũ theo yêu cầu hệ thống
295
214
  const value = DateUtilities.toFormat(event.value?.toDate(), 'yyyy/MM/dd HH:mm:ss');
296
- this.input?.nativeElement?.focus();
215
+ this.inputRef()?.nativeElement?.focus();
297
216
  if (this.#date !== value) {
298
- this.modelChange.emit(value);
217
+ this.valueModel.set(value);
299
218
  this.sdChange.emit(value);
300
219
  }
301
220
  };
@@ -303,12 +222,12 @@ class SdDatetime {
303
222
  $event?.stopPropagation();
304
223
  if (this.formControl.value) {
305
224
  this.formControl.setValue(null);
306
- this.modelChange.emit(null);
225
+ this.valueModel.set(null);
307
226
  this.sdChange.emit(null);
308
227
  }
309
228
  };
310
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: SdDatetime, deps: [{ token: i0.ChangeDetectorRef }, { token: SD_FORM_CONFIGURATION, optional: true }], target: i0.ɵɵFactoryTarget.Component });
311
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: SdDatetime, isStandalone: true, selector: "sd-datetime", inputs: { _autoId: ["autoId", "_autoId"], name: "name", appearance: "appearance", _hideInlineError: ["hideInlineError", "_hideInlineError"], _min: ["min", "_min"], _max: ["max", "_max"], size: "size", form: "form", disabled: "disabled", _viewed: ["viewed", "_viewed"], hyperlink: "hyperlink", _required: ["required", "_required"], _inlineError: ["inlineError", "_inlineError"], _label: ["label", "_label"], _helperText: ["helperText", "_helperText"], placeholder: "placeholder", minDate: "minDate", maxDate: "maxDate", model: "model" }, outputs: { sdChange: "sdChange", sdFocus: "sdFocus", modelChange: "modelChange" }, providers: [
229
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: SdDatetime, deps: [], target: i0.ɵɵFactoryTarget.Component });
230
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: SdDatetime, isStandalone: true, selector: "sd-datetime", inputs: { autoIdInput: { classPropertyName: "autoIdInput", publicName: "autoId", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, form: { classPropertyName: "form", publicName: "form", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, helperText: { classPropertyName: "helperText", publicName: "helperText", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, hideInlineError: { classPropertyName: "hideInlineError", publicName: "hideInlineError", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, viewed: { classPropertyName: "viewed", publicName: "viewed", isSignal: true, isRequired: false, transformFunction: null }, inlineError: { classPropertyName: "inlineError", publicName: "inlineError", isSignal: true, isRequired: false, transformFunction: null }, hyperlink: { classPropertyName: "hyperlink", publicName: "hyperlink", isSignal: true, isRequired: false, transformFunction: null }, appearanceInput: { classPropertyName: "appearanceInput", publicName: "appearance", isSignal: true, isRequired: false, transformFunction: null }, minInput: { classPropertyName: "minInput", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, minDateInput: { classPropertyName: "minDateInput", publicName: "minDate", isSignal: true, isRequired: false, transformFunction: null }, maxInput: { classPropertyName: "maxInput", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, maxDateInput: { classPropertyName: "maxDateInput", publicName: "maxDate", isSignal: true, isRequired: false, transformFunction: null }, valueModel: { classPropertyName: "valueModel", publicName: "model", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valueModel: "modelChange", sdChange: "sdChange", sdFocus: "sdFocus" }, providers: [
312
231
  provideMomentDatetimeAdapter({
313
232
  parse: {
314
233
  dateInput: 'DD/MM/YYYY',
@@ -326,7 +245,7 @@ class SdDatetime {
326
245
  popupHeaderDateLabel: 'MMM DD, ddd',
327
246
  },
328
247
  }),
329
- ], queries: [{ propertyName: "sdLabelTemplate", first: true, predicate: ["sdLabel"], descendants: true }, { propertyName: "sdValueTemplate", first: true, predicate: ["sdValue"], descendants: true }, { propertyName: "sdViewDef", first: true, predicate: SdViewDefDirective, descendants: true }], viewQueries: [{ propertyName: "datetimePicker", first: true, predicate: MtxDatetimepicker, descendants: true }, { propertyName: "input", first: true, predicate: ["input"], descendants: true }, { propertyName: "datePicker", first: true, predicate: MatDatepicker, descendants: true }], ngImport: i0, template: "@if (viewed) {\r\n <sd-view\r\n [label]=\"label\"\r\n [labelTemplate]=\"sdLabelTemplate\"\r\n [value]=\"formControl.value\"\r\n [display]=\"formControl.value | date: 'dd/MM/yyyy HH:mm'\"\r\n [hyperlink]=\"hyperlink\"\r\n [valueTemplate]=\"sdValueTemplate\">\r\n </sd-view>\r\n} @else {\r\n @if (!appearance) {\r\n <ng-content select=\"[sdLabel]\">\r\n @if (label) {\r\n <sd-label [label]=\"label\" [required]=\"required\"></sd-label>\r\n }\r\n </ng-content>\r\n }\r\n <!-- Th\u00EAm area-hidden=true \u0111\u1EC3 kh\u00F4ng b\u1ECB c\u1EA3nh b\u00E1o g\u1EAFn s\u1EF1 ki\u1EC7n click th\u1EBB div -->\r\n <div\r\n class=\"d-flex align-items-center\"\r\n [class.sd-view]=\"sdViewDef?.templateRef\"\r\n [class.c-focused]=\"isFocused\"\r\n [class.c-disabled]=\"formControl.disabled\"\r\n (click)=\"onClick()\"\r\n aria-hidden=\"true\">\r\n @if (sdViewDef?.templateRef && !isFocused && !datetimePicker?.opened) {\r\n <ng-container\r\n *ngTemplateOutlet=\"\r\n sdViewDef!.templateRef;\r\n context: {\r\n value: formControl.value\r\n }\r\n \">\r\n </ng-container>\r\n } @else {\r\n <mat-form-field\r\n class=\"c-form-field-datetime-input\"\r\n [class.sd-md]=\"size === 'md'\"\r\n [class.sd-sm]=\"size === 'sm'\"\r\n [class.hide-inline-error]=\"hideInlineError\"\r\n [appearance]=\"appearance || 'outline'\">\r\n @if (appearance && label) {\r\n <mat-label style=\"display: inline-block\">\r\n <div style=\"display: flex; align-items: center; gap: 4px\">\r\n <span>{{ label }}</span>\r\n @if (helperText) {\r\n <mat-icon [matTooltip]=\"helperText\" matTooltipPosition=\"below\">info_outline</mat-icon>\r\n }\r\n </div>\r\n </mat-label>\r\n }\r\n <mtx-datetimepicker #datetimePicker [type]=\"'datetime'\" [mode]=\"'auto'\">\r\n <!-- @if (actionButtons) {\r\n <mtx-datetimepicker-actions>\r\n <button mat-button mtxDatetimepickerClear>Clear</button>\r\n <button mat-button mtxDatetimepickerCancel>Cancel</button>\r\n <button mat-raised-button mtxDatetimepickerApply>Apply</button>\r\n </mtx-datetimepicker-actions>\r\n } -->\r\n </mtx-datetimepicker>\r\n <input\r\n aria-hidden=\"true\"\r\n [attr.data-autoId]=\"autoId\"\r\n [mtxDatetimepicker]=\"datetimePicker\"\r\n [id]=\"id\"\r\n (blur)=\"onConfirmInput($event)\"\r\n (keyup.enter)=\"onConfirmInput($event)\"\r\n (keydown)=\"onKeyDown($event)\"\r\n (dateChange)=\"onChange($event)\"\r\n [autocomplete]=\"id\"\r\n autocorrect=\"off\"\r\n [formControl]=\"formControl\"\r\n [required]=\"required\"\r\n [placeholder]=\"placeholder || label || ''\"\r\n [min]=\"min\"\r\n [max]=\"max\"\r\n (focus)=\"onFocus()\"\r\n (blur)=\"onBlur()\"\r\n [attr.data-autoId]=\"autoId\"\r\n #input\r\n matInput />\r\n <mtx-datetimepicker-toggle [for]=\"datetimePicker\" matSuffix></mtx-datetimepicker-toggle>\r\n @if (formControl.errors?.['required'] && formControl.touched) {\r\n <mat-error>\r\n @if (!hideInlineError) {\r\n {{ 'Vui l\u00F2ng nh\u1EADp th\u00F4ng tin' }}\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['matDatepickerMin'] && formControl.touched && !isFocused) {\r\n <mat-error>\r\n @if (!hideInlineError) {\r\n {{ 'Ng\u00E0y nh\u1ECF nh\u1EA5t' }}: <strong>{{ min | date: 'dd/MM/yyyy HH:mm' }}</strong>\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['matDatepickerMax'] && formControl.touched && !isFocused) {\r\n <mat-error>\r\n @if (!hideInlineError) {\r\n {{ 'Ng\u00E0y l\u1EDBn nh\u1EA5t' }}: <strong>{{ max | date: 'dd/MM/yyyy HH:mm' }}</strong>\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['matDatetimePickerParse'] && formControl.touched && !isFocused) {\r\n <mat-error>\r\n @if (!hideInlineError) {\r\n {{ 'Parse error' }}: <strong>{{ formControl.errors?.['matDatetimePickerParse']?.text }}</strong>\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['customValidator'] && formControl.touched && !hideInlineError) {\r\n <mat-error>\r\n {{ formControl.errors?.['customValidator'] }}\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['date'] && formControl.touched && !hideInlineError) {\r\n <mat-error>\r\n {{ formControl.errors?.['date'] }}\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['inlineError'] && formControl.touched && !hideInlineError) {\r\n <mat-error>\r\n {{ inlineError }}\r\n </mat-error>\r\n }\r\n </mat-form-field>\r\n }\r\n </div>\r\n}\r\n", styles: [".text-primary{color:var(--sd-primary)!important}.bg-primary{background:var(--sd-primary)!important}.border-primary{border-color:var(--sd-primary)!important}.text-primary-light{color:var(--sd-primary-light)!important}.bg-primary-light{background:var(--sd-primary-light)!important}.border-primary-light{border-color:var(--sd-primary-light)!important}.text-primary-dark{color:var(--sd-primary-dark)!important}.bg-primary-dark{background:var(--sd-primary-dark)!important}.border-primary-dark{border-color:var(--sd-primary-dark)!important}.text-info{color:var(--sd-info)!important}.bg-info{background:var(--sd-info)!important}.border-info{border-color:var(--sd-info)!important}.text-info-light{color:var(--sd-info-light)!important}.bg-info-light{background:var(--sd-info-light)!important}.border-info-light{border-color:var(--sd-info-light)!important}.text-info-dark{color:var(--sd-info-dark)!important}.bg-info-dark{background:var(--sd-info-dark)!important}.border-info-dark{border-color:var(--sd-info-dark)!important}.text-success{color:var(--sd-success)!important}.bg-success{background:var(--sd-success)!important}.border-success{border-color:var(--sd-success)!important}.text-success-light{color:var(--sd-success-light)!important}.bg-success-light{background:var(--sd-success-light)!important}.border-success-light{border-color:var(--sd-success-light)!important}.text-success-dark{color:var(--sd-success-dark)!important}.bg-success-dark{background:var(--sd-success-dark)!important}.border-success-dark{border-color:var(--sd-success-dark)!important}.text-warning{color:var(--sd-warning)!important}.bg-warning{background:var(--sd-warning)!important}.border-warning{border-color:var(--sd-warning)!important}.text-warning-light{color:var(--sd-warning-light)!important}.bg-warning-light{background:var(--sd-warning-light)!important}.border-warning-light{border-color:var(--sd-warning-light)!important}.text-warning-dark{color:var(--sd-warning-dark)!important}.bg-warning-dark{background:var(--sd-warning-dark)!important}.border-warning-dark{border-color:var(--sd-warning-dark)!important}.text-error{color:var(--sd-error)!important}.bg-error{background:var(--sd-error)!important}.border-error{border-color:var(--sd-error)!important}.text-error-light{color:var(--sd-error-light)!important}.bg-error-light{background:var(--sd-error-light)!important}.border-error-light{border-color:var(--sd-error-light)!important}.text-error-dark{color:var(--sd-error-dark)!important}.bg-error-dark{background:var(--sd-error-dark)!important}.border-error-dark{border-color:var(--sd-error-dark)!important}.text-secondary{color:var(--sd-secondary)!important}.bg-secondary{background:var(--sd-secondary)!important}.border-secondary{border-color:var(--sd-secondary)!important}.text-secondary-light{color:var(--sd-secondary-light)!important}.bg-secondary-light{background:var(--sd-secondary-light)!important}.border-secondary-light{border-color:var(--sd-secondary-light)!important}.text-secondary-dark{color:var(--sd-secondary-dark)!important}.bg-secondary-dark{background:var(--sd-secondary-dark)!important}.border-secondary-dark{border-color:var(--sd-secondary-dark)!important}.text-light{color:var(--sd-light)!important}.bg-light{background:var(--sd-light)!important}.border-light{border-color:var(--sd-light)!important}.text-dark{color:var(--sd-dark)!important}.bg-dark{background:var(--sd-dark)!important}.border-dark{border-color:var(--sd-dark)!important}.text-black500{color:var(--sd-black500)!important}.bg-black500{background:var(--sd-black500)!important}.border-black500{border-color:var(--sd-black500)!important}.text-black400{color:var(--sd-black400)!important}.bg-black400{background:var(--sd-black400)!important}.border-black400{border-color:var(--sd-black400)!important}.text-black300{color:var(--sd-black300)!important}.bg-black300{background:var(--sd-black300)!important}.border-black300{border-color:var(--sd-black300)!important}.text-black200{color:var(--sd-black200)!important}.bg-black200{background:var(--sd-black200)!important}.border-black200{border-color:var(--sd-black200)!important}.text-black100{color:var(--sd-black100)!important}.bg-black100{background:var(--sd-black100)!important}.border-black100{border-color:var(--sd-black100)!important}.text-white{color:#fff!important}.bg-white{background:#fff!important}.border-white{border-color:#fff!important}.text-black{color:#000!important}.bg-black{background:#000!important}.border-black{border-color:#000!important}:host{padding-top:5px;display:block}:host ::ng-deep .mat-mdc-form-field.mat-form-field-appearance-outline.mat-form-field-disabled .mat-mdc-text-field-wrapper{background:var(--sd-black100)}:host ::ng-deep .mat-mdc-form-field input.mat-mdc-input-element:disabled{color:var(--sd-black400)!important}:host ::ng-deep .mat-mdc-form-field .mat-mdc-placeholder-required{color:var(--sd-error)}.sd-view:not(.c-focused):not(.c-disabled):hover{background-color:#ebecf0}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: i1.DatePipe, name: "date" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "component", type: i3.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i3.MatLabel, selector: "mat-label" }, { kind: "directive", type: i3.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: i3.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i5.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "ngmodule", type: MtxDatetimepickerModule }, { kind: "component", type: i6.MtxDatetimepicker, selector: "mtx-datetimepicker", inputs: ["multiYearSelector", "twelvehour", "showWeekNumbers", "startView", "mode", "timeInterval", "preventSameDateTimeSelection", "calendarHeaderComponent", "panelClass", "opened", "color", "startAt", "type", "touchUi", "timeInput", "timeInputAutoFocus", "disabled", "xPosition", "yPosition", "restoreFocus"], outputs: ["selectedChanged", "opened", "closed", "viewChanged"], exportAs: ["mtxDatetimepicker"] }, { kind: "component", type: i6.MtxDatetimepickerToggle, selector: "mtx-datetimepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["mtxDatetimepickerToggle"] }, { kind: "directive", type: i6.MtxDatetimepickerInput, selector: "input[mtxDatetimepicker]", inputs: ["mtxDatetimepicker", "mtxDatetimepickerFilter", "value", "min", "max", "disabled"], outputs: ["dateChange", "dateInput"], exportAs: ["mtxDatetimepickerInput"] }, { kind: "component", type: SdLabel, selector: "sd-label", inputs: ["label", "description", "required", "helperText"] }, { kind: "component", type: SdView, selector: "sd-view", inputs: ["label", "value", "display", "hyperlink", "labelTemplate", "valueTemplate"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
248
+ ], queries: [{ propertyName: "sdLabelTemplate", first: true, predicate: ["sdLabel"], descendants: true, isSignal: true }, { propertyName: "sdValueTemplate", first: true, predicate: ["sdValue"], descendants: true, isSignal: true }, { propertyName: "sdViewDef", first: true, predicate: SdViewDefDirective, descendants: true, isSignal: true }], viewQueries: [{ propertyName: "inputRef", first: true, predicate: ["input"], descendants: true, isSignal: true }, { propertyName: "datetimePicker", first: true, predicate: MtxDatetimepicker, descendants: true, isSignal: true }], ngImport: i0, template: "@let lbl = label();\r\n@let app = appearance();\r\n@let hideErr = hideInlineError();\r\n@let viewDef = sdViewDef();\r\n@let hText = helperText();\r\n@let req = required();\r\n@let inlErr = inlineError();\r\n\r\n@let minD = resolvedMin();\r\n@let maxD = resolvedMax();\r\n\r\n@if (viewed()) {\r\n <sd-view\r\n [label]=\"lbl\"\r\n [labelTemplate]=\"sdLabelTemplate()\"\r\n [value]=\"formControl.value\"\r\n [display]=\"formControl.value | date: 'dd/MM/yyyy HH:mm'\"\r\n [hyperlink]=\"hyperlink()\"\r\n [valueTemplate]=\"sdValueTemplate()\">\r\n </sd-view>\r\n} @else {\r\n @if (!app) {\r\n <ng-content select=\"[sdLabel]\">\r\n @if (lbl) {\r\n <sd-label [label]=\"lbl\" [required]=\"req\"></sd-label>\r\n }\r\n </ng-content>\r\n }\r\n \r\n <div\r\n class=\"d-flex align-items-center\"\r\n [class.sd-view]=\"viewDef?.templateRef\"\r\n [class.c-focused]=\"isFocused\"\r\n [class.c-disabled]=\"formControl.disabled\"\r\n (click)=\"onClick()\"\r\n aria-hidden=\"true\">\r\n \r\n @if (viewDef?.templateRef && !isFocused && !datetimePicker()?.opened) {\r\n <ng-container\r\n *ngTemplateOutlet=\"\r\n viewDef!.templateRef;\r\n context: { value: formControl.value }\r\n \">\r\n </ng-container>\r\n } @else {\r\n <mat-form-field\r\n class=\"c-form-field-datetime-input\"\r\n [class.sd-md]=\"size() === 'md'\"\r\n [class.sd-sm]=\"size() === 'sm'\"\r\n [class.hide-inline-error]=\"hideErr\"\r\n [appearance]=\"app || 'outline'\">\r\n \r\n @if (app && lbl) {\r\n <mat-label style=\"display: inline-block\">\r\n <div style=\"display: flex; align-items: center; gap: 4px\">\r\n <span>{{ lbl }}</span>\r\n @if (hText) {\r\n <mat-icon [matTooltip]=\"hText\" matTooltipPosition=\"below\">info_outline</mat-icon>\r\n }\r\n </div>\r\n </mat-label>\r\n }\r\n \r\n <mtx-datetimepicker #datetimePicker [type]=\"'datetime'\" [mode]=\"'auto'\"></mtx-datetimepicker>\r\n \r\n <input\r\n aria-hidden=\"true\"\r\n [attr.data-autoId]=\"autoId()\"\r\n [mtxDatetimepicker]=\"datetimePicker\"\r\n [id]=\"id\"\r\n (blur)=\"onConfirmInput($event)\"\r\n (keyup.enter)=\"onConfirmInput($event)\"\r\n (keydown)=\"onKeyDown($event)\"\r\n (dateChange)=\"onChange($event)\"\r\n [autocomplete]=\"id\"\r\n autocorrect=\"off\"\r\n [formControl]=\"formControl\"\r\n [required]=\"req\"\r\n [placeholder]=\"placeholder() || lbl || ''\"\r\n [min]=\"minD\"\r\n [max]=\"maxD\"\r\n (focus)=\"onFocus()\"\r\n (blur)=\"onBlur()\"\r\n #input\r\n matInput />\r\n \r\n <mtx-datetimepicker-toggle [for]=\"datetimePicker\" matSuffix></mtx-datetimepicker-toggle>\r\n \r\n @if (formControl.errors?.['required'] && formControl.touched) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ 'Vui l\u00F2ng nh\u1EADp th\u00F4ng tin' }}\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['matDatepickerMin'] && formControl.touched && !isFocused) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ 'Ng\u00E0y nh\u1ECF nh\u1EA5t' }}: <strong>{{ minD | date: 'dd/MM/yyyy HH:mm' }}</strong>\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['matDatepickerMax'] && formControl.touched && !isFocused) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ 'Ng\u00E0y l\u1EDBn nh\u1EA5t' }}: <strong>{{ maxD | date: 'dd/MM/yyyy HH:mm' }}</strong>\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['matDatetimePickerParse'] && formControl.touched && !isFocused) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ 'Parse error' }}: <strong>{{ formControl.errors?.['matDatetimePickerParse']?.text }}</strong>\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['customValidator'] && formControl.touched) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ formControl.errors?.['customValidator'] }}\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['date'] && formControl.touched) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ formControl.errors?.['date'] }}\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['inlineError'] && formControl.touched) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ inlErr }}\r\n }\r\n </mat-error>\r\n }\r\n </mat-form-field>\r\n }\r\n </div>\r\n}", styles: [".text-primary{color:var(--sd-primary)!important}.bg-primary{background:var(--sd-primary)!important}.border-primary{border-color:var(--sd-primary)!important}.text-primary-light{color:var(--sd-primary-light)!important}.bg-primary-light{background:var(--sd-primary-light)!important}.border-primary-light{border-color:var(--sd-primary-light)!important}.text-primary-dark{color:var(--sd-primary-dark)!important}.bg-primary-dark{background:var(--sd-primary-dark)!important}.border-primary-dark{border-color:var(--sd-primary-dark)!important}.text-info{color:var(--sd-info)!important}.bg-info{background:var(--sd-info)!important}.border-info{border-color:var(--sd-info)!important}.text-info-light{color:var(--sd-info-light)!important}.bg-info-light{background:var(--sd-info-light)!important}.border-info-light{border-color:var(--sd-info-light)!important}.text-info-dark{color:var(--sd-info-dark)!important}.bg-info-dark{background:var(--sd-info-dark)!important}.border-info-dark{border-color:var(--sd-info-dark)!important}.text-success{color:var(--sd-success)!important}.bg-success{background:var(--sd-success)!important}.border-success{border-color:var(--sd-success)!important}.text-success-light{color:var(--sd-success-light)!important}.bg-success-light{background:var(--sd-success-light)!important}.border-success-light{border-color:var(--sd-success-light)!important}.text-success-dark{color:var(--sd-success-dark)!important}.bg-success-dark{background:var(--sd-success-dark)!important}.border-success-dark{border-color:var(--sd-success-dark)!important}.text-warning{color:var(--sd-warning)!important}.bg-warning{background:var(--sd-warning)!important}.border-warning{border-color:var(--sd-warning)!important}.text-warning-light{color:var(--sd-warning-light)!important}.bg-warning-light{background:var(--sd-warning-light)!important}.border-warning-light{border-color:var(--sd-warning-light)!important}.text-warning-dark{color:var(--sd-warning-dark)!important}.bg-warning-dark{background:var(--sd-warning-dark)!important}.border-warning-dark{border-color:var(--sd-warning-dark)!important}.text-error{color:var(--sd-error)!important}.bg-error{background:var(--sd-error)!important}.border-error{border-color:var(--sd-error)!important}.text-error-light{color:var(--sd-error-light)!important}.bg-error-light{background:var(--sd-error-light)!important}.border-error-light{border-color:var(--sd-error-light)!important}.text-error-dark{color:var(--sd-error-dark)!important}.bg-error-dark{background:var(--sd-error-dark)!important}.border-error-dark{border-color:var(--sd-error-dark)!important}.text-secondary{color:var(--sd-secondary)!important}.bg-secondary{background:var(--sd-secondary)!important}.border-secondary{border-color:var(--sd-secondary)!important}.text-secondary-light{color:var(--sd-secondary-light)!important}.bg-secondary-light{background:var(--sd-secondary-light)!important}.border-secondary-light{border-color:var(--sd-secondary-light)!important}.text-secondary-dark{color:var(--sd-secondary-dark)!important}.bg-secondary-dark{background:var(--sd-secondary-dark)!important}.border-secondary-dark{border-color:var(--sd-secondary-dark)!important}.text-light{color:var(--sd-light)!important}.bg-light{background:var(--sd-light)!important}.border-light{border-color:var(--sd-light)!important}.text-dark{color:var(--sd-dark)!important}.bg-dark{background:var(--sd-dark)!important}.border-dark{border-color:var(--sd-dark)!important}.text-black500{color:var(--sd-black500)!important}.bg-black500{background:var(--sd-black500)!important}.border-black500{border-color:var(--sd-black500)!important}.text-black400{color:var(--sd-black400)!important}.bg-black400{background:var(--sd-black400)!important}.border-black400{border-color:var(--sd-black400)!important}.text-black300{color:var(--sd-black300)!important}.bg-black300{background:var(--sd-black300)!important}.border-black300{border-color:var(--sd-black300)!important}.text-black200{color:var(--sd-black200)!important}.bg-black200{background:var(--sd-black200)!important}.border-black200{border-color:var(--sd-black200)!important}.text-black100{color:var(--sd-black100)!important}.bg-black100{background:var(--sd-black100)!important}.border-black100{border-color:var(--sd-black100)!important}.text-white{color:#fff!important}.bg-white{background:#fff!important}.border-white{border-color:#fff!important}.text-black{color:#000!important}.bg-black{background:#000!important}.border-black{border-color:#000!important}:host{padding-top:5px;display:block}:host ::ng-deep .mat-mdc-form-field.mat-form-field-appearance-outline.mat-form-field-disabled .mat-mdc-text-field-wrapper{background:var(--sd-black100)}:host ::ng-deep .mat-mdc-form-field input.mat-mdc-input-element:disabled{color:var(--sd-black400)!important}:host ::ng-deep .mat-mdc-form-field .mat-mdc-placeholder-required{color:var(--sd-error)}.sd-view:not(.c-focused):not(.c-disabled):hover{background-color:#ebecf0}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: i1.DatePipe, name: "date" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "component", type: i3.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i3.MatLabel, selector: "mat-label" }, { kind: "directive", type: i3.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: i3.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i5.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "ngmodule", type: MtxDatetimepickerModule }, { kind: "component", type: i6.MtxDatetimepicker, selector: "mtx-datetimepicker", inputs: ["multiYearSelector", "twelvehour", "showWeekNumbers", "startView", "mode", "timeInterval", "preventSameDateTimeSelection", "calendarHeaderComponent", "panelClass", "opened", "color", "startAt", "type", "touchUi", "timeInput", "timeInputAutoFocus", "disabled", "xPosition", "yPosition", "restoreFocus"], outputs: ["selectedChanged", "opened", "closed", "viewChanged"], exportAs: ["mtxDatetimepicker"] }, { kind: "component", type: i6.MtxDatetimepickerToggle, selector: "mtx-datetimepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["mtxDatetimepickerToggle"] }, { kind: "directive", type: i6.MtxDatetimepickerInput, selector: "input[mtxDatetimepicker]", inputs: ["mtxDatetimepicker", "mtxDatetimepickerFilter", "value", "min", "max", "disabled"], outputs: ["dateChange", "dateInput"], exportAs: ["mtxDatetimepickerInput"] }, { kind: "component", type: SdLabel, selector: "sd-label", inputs: ["label", "description", "required", "helperText"] }, { kind: "component", type: SdView, selector: "sd-view", inputs: ["label", "value", "display", "hyperlink", "labelTemplate", "valueTemplate"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
330
249
  }
331
250
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: SdDatetime, decorators: [{
332
251
  type: Component,
@@ -359,84 +278,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImpo
359
278
  MtxDatetimepickerModule,
360
279
  SdLabel,
361
280
  SdView
362
- ], template: "@if (viewed) {\r\n <sd-view\r\n [label]=\"label\"\r\n [labelTemplate]=\"sdLabelTemplate\"\r\n [value]=\"formControl.value\"\r\n [display]=\"formControl.value | date: 'dd/MM/yyyy HH:mm'\"\r\n [hyperlink]=\"hyperlink\"\r\n [valueTemplate]=\"sdValueTemplate\">\r\n </sd-view>\r\n} @else {\r\n @if (!appearance) {\r\n <ng-content select=\"[sdLabel]\">\r\n @if (label) {\r\n <sd-label [label]=\"label\" [required]=\"required\"></sd-label>\r\n }\r\n </ng-content>\r\n }\r\n <!-- Th\u00EAm area-hidden=true \u0111\u1EC3 kh\u00F4ng b\u1ECB c\u1EA3nh b\u00E1o g\u1EAFn s\u1EF1 ki\u1EC7n click th\u1EBB div -->\r\n <div\r\n class=\"d-flex align-items-center\"\r\n [class.sd-view]=\"sdViewDef?.templateRef\"\r\n [class.c-focused]=\"isFocused\"\r\n [class.c-disabled]=\"formControl.disabled\"\r\n (click)=\"onClick()\"\r\n aria-hidden=\"true\">\r\n @if (sdViewDef?.templateRef && !isFocused && !datetimePicker?.opened) {\r\n <ng-container\r\n *ngTemplateOutlet=\"\r\n sdViewDef!.templateRef;\r\n context: {\r\n value: formControl.value\r\n }\r\n \">\r\n </ng-container>\r\n } @else {\r\n <mat-form-field\r\n class=\"c-form-field-datetime-input\"\r\n [class.sd-md]=\"size === 'md'\"\r\n [class.sd-sm]=\"size === 'sm'\"\r\n [class.hide-inline-error]=\"hideInlineError\"\r\n [appearance]=\"appearance || 'outline'\">\r\n @if (appearance && label) {\r\n <mat-label style=\"display: inline-block\">\r\n <div style=\"display: flex; align-items: center; gap: 4px\">\r\n <span>{{ label }}</span>\r\n @if (helperText) {\r\n <mat-icon [matTooltip]=\"helperText\" matTooltipPosition=\"below\">info_outline</mat-icon>\r\n }\r\n </div>\r\n </mat-label>\r\n }\r\n <mtx-datetimepicker #datetimePicker [type]=\"'datetime'\" [mode]=\"'auto'\">\r\n <!-- @if (actionButtons) {\r\n <mtx-datetimepicker-actions>\r\n <button mat-button mtxDatetimepickerClear>Clear</button>\r\n <button mat-button mtxDatetimepickerCancel>Cancel</button>\r\n <button mat-raised-button mtxDatetimepickerApply>Apply</button>\r\n </mtx-datetimepicker-actions>\r\n } -->\r\n </mtx-datetimepicker>\r\n <input\r\n aria-hidden=\"true\"\r\n [attr.data-autoId]=\"autoId\"\r\n [mtxDatetimepicker]=\"datetimePicker\"\r\n [id]=\"id\"\r\n (blur)=\"onConfirmInput($event)\"\r\n (keyup.enter)=\"onConfirmInput($event)\"\r\n (keydown)=\"onKeyDown($event)\"\r\n (dateChange)=\"onChange($event)\"\r\n [autocomplete]=\"id\"\r\n autocorrect=\"off\"\r\n [formControl]=\"formControl\"\r\n [required]=\"required\"\r\n [placeholder]=\"placeholder || label || ''\"\r\n [min]=\"min\"\r\n [max]=\"max\"\r\n (focus)=\"onFocus()\"\r\n (blur)=\"onBlur()\"\r\n [attr.data-autoId]=\"autoId\"\r\n #input\r\n matInput />\r\n <mtx-datetimepicker-toggle [for]=\"datetimePicker\" matSuffix></mtx-datetimepicker-toggle>\r\n @if (formControl.errors?.['required'] && formControl.touched) {\r\n <mat-error>\r\n @if (!hideInlineError) {\r\n {{ 'Vui l\u00F2ng nh\u1EADp th\u00F4ng tin' }}\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['matDatepickerMin'] && formControl.touched && !isFocused) {\r\n <mat-error>\r\n @if (!hideInlineError) {\r\n {{ 'Ng\u00E0y nh\u1ECF nh\u1EA5t' }}: <strong>{{ min | date: 'dd/MM/yyyy HH:mm' }}</strong>\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['matDatepickerMax'] && formControl.touched && !isFocused) {\r\n <mat-error>\r\n @if (!hideInlineError) {\r\n {{ 'Ng\u00E0y l\u1EDBn nh\u1EA5t' }}: <strong>{{ max | date: 'dd/MM/yyyy HH:mm' }}</strong>\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['matDatetimePickerParse'] && formControl.touched && !isFocused) {\r\n <mat-error>\r\n @if (!hideInlineError) {\r\n {{ 'Parse error' }}: <strong>{{ formControl.errors?.['matDatetimePickerParse']?.text }}</strong>\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['customValidator'] && formControl.touched && !hideInlineError) {\r\n <mat-error>\r\n {{ formControl.errors?.['customValidator'] }}\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['date'] && formControl.touched && !hideInlineError) {\r\n <mat-error>\r\n {{ formControl.errors?.['date'] }}\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['inlineError'] && formControl.touched && !hideInlineError) {\r\n <mat-error>\r\n {{ inlineError }}\r\n </mat-error>\r\n }\r\n </mat-form-field>\r\n }\r\n </div>\r\n}\r\n", styles: [".text-primary{color:var(--sd-primary)!important}.bg-primary{background:var(--sd-primary)!important}.border-primary{border-color:var(--sd-primary)!important}.text-primary-light{color:var(--sd-primary-light)!important}.bg-primary-light{background:var(--sd-primary-light)!important}.border-primary-light{border-color:var(--sd-primary-light)!important}.text-primary-dark{color:var(--sd-primary-dark)!important}.bg-primary-dark{background:var(--sd-primary-dark)!important}.border-primary-dark{border-color:var(--sd-primary-dark)!important}.text-info{color:var(--sd-info)!important}.bg-info{background:var(--sd-info)!important}.border-info{border-color:var(--sd-info)!important}.text-info-light{color:var(--sd-info-light)!important}.bg-info-light{background:var(--sd-info-light)!important}.border-info-light{border-color:var(--sd-info-light)!important}.text-info-dark{color:var(--sd-info-dark)!important}.bg-info-dark{background:var(--sd-info-dark)!important}.border-info-dark{border-color:var(--sd-info-dark)!important}.text-success{color:var(--sd-success)!important}.bg-success{background:var(--sd-success)!important}.border-success{border-color:var(--sd-success)!important}.text-success-light{color:var(--sd-success-light)!important}.bg-success-light{background:var(--sd-success-light)!important}.border-success-light{border-color:var(--sd-success-light)!important}.text-success-dark{color:var(--sd-success-dark)!important}.bg-success-dark{background:var(--sd-success-dark)!important}.border-success-dark{border-color:var(--sd-success-dark)!important}.text-warning{color:var(--sd-warning)!important}.bg-warning{background:var(--sd-warning)!important}.border-warning{border-color:var(--sd-warning)!important}.text-warning-light{color:var(--sd-warning-light)!important}.bg-warning-light{background:var(--sd-warning-light)!important}.border-warning-light{border-color:var(--sd-warning-light)!important}.text-warning-dark{color:var(--sd-warning-dark)!important}.bg-warning-dark{background:var(--sd-warning-dark)!important}.border-warning-dark{border-color:var(--sd-warning-dark)!important}.text-error{color:var(--sd-error)!important}.bg-error{background:var(--sd-error)!important}.border-error{border-color:var(--sd-error)!important}.text-error-light{color:var(--sd-error-light)!important}.bg-error-light{background:var(--sd-error-light)!important}.border-error-light{border-color:var(--sd-error-light)!important}.text-error-dark{color:var(--sd-error-dark)!important}.bg-error-dark{background:var(--sd-error-dark)!important}.border-error-dark{border-color:var(--sd-error-dark)!important}.text-secondary{color:var(--sd-secondary)!important}.bg-secondary{background:var(--sd-secondary)!important}.border-secondary{border-color:var(--sd-secondary)!important}.text-secondary-light{color:var(--sd-secondary-light)!important}.bg-secondary-light{background:var(--sd-secondary-light)!important}.border-secondary-light{border-color:var(--sd-secondary-light)!important}.text-secondary-dark{color:var(--sd-secondary-dark)!important}.bg-secondary-dark{background:var(--sd-secondary-dark)!important}.border-secondary-dark{border-color:var(--sd-secondary-dark)!important}.text-light{color:var(--sd-light)!important}.bg-light{background:var(--sd-light)!important}.border-light{border-color:var(--sd-light)!important}.text-dark{color:var(--sd-dark)!important}.bg-dark{background:var(--sd-dark)!important}.border-dark{border-color:var(--sd-dark)!important}.text-black500{color:var(--sd-black500)!important}.bg-black500{background:var(--sd-black500)!important}.border-black500{border-color:var(--sd-black500)!important}.text-black400{color:var(--sd-black400)!important}.bg-black400{background:var(--sd-black400)!important}.border-black400{border-color:var(--sd-black400)!important}.text-black300{color:var(--sd-black300)!important}.bg-black300{background:var(--sd-black300)!important}.border-black300{border-color:var(--sd-black300)!important}.text-black200{color:var(--sd-black200)!important}.bg-black200{background:var(--sd-black200)!important}.border-black200{border-color:var(--sd-black200)!important}.text-black100{color:var(--sd-black100)!important}.bg-black100{background:var(--sd-black100)!important}.border-black100{border-color:var(--sd-black100)!important}.text-white{color:#fff!important}.bg-white{background:#fff!important}.border-white{border-color:#fff!important}.text-black{color:#000!important}.bg-black{background:#000!important}.border-black{border-color:#000!important}:host{padding-top:5px;display:block}:host ::ng-deep .mat-mdc-form-field.mat-form-field-appearance-outline.mat-form-field-disabled .mat-mdc-text-field-wrapper{background:var(--sd-black100)}:host ::ng-deep .mat-mdc-form-field input.mat-mdc-input-element:disabled{color:var(--sd-black400)!important}:host ::ng-deep .mat-mdc-form-field .mat-mdc-placeholder-required{color:var(--sd-error)}.sd-view:not(.c-focused):not(.c-disabled):hover{background-color:#ebecf0}\n"] }]
363
- }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: undefined, decorators: [{
364
- type: Inject,
365
- args: [SD_FORM_CONFIGURATION]
366
- }, {
367
- type: Optional
368
- }] }], propDecorators: { sdLabelTemplate: [{
369
- type: ContentChild,
370
- args: ['sdLabel']
371
- }], sdValueTemplate: [{
372
- type: ContentChild,
373
- args: ['sdValue']
374
- }], datetimePicker: [{
375
- type: ViewChild,
376
- args: [MtxDatetimepicker]
377
- }], _autoId: [{
378
- type: Input,
379
- args: ['autoId']
380
- }], name: [{
381
- type: Input
382
- }], appearance: [{
383
- type: Input
384
- }], _hideInlineError: [{
385
- type: Input,
386
- args: ['hideInlineError']
387
- }], _min: [{
388
- type: Input,
389
- args: ['min']
390
- }], _max: [{
391
- type: Input,
392
- args: ['max']
393
- }], size: [{
394
- type: Input
395
- }], form: [{
396
- type: Input
397
- }], disabled: [{
398
- type: Input
399
- }], _viewed: [{
400
- type: Input,
401
- args: ['viewed']
402
- }], hyperlink: [{
403
- type: Input
404
- }], _required: [{
405
- type: Input,
406
- args: ['required']
407
- }], _inlineError: [{
408
- type: Input,
409
- args: ['inlineError']
410
- }], _label: [{
411
- type: Input,
412
- args: ['label']
413
- }], _helperText: [{
414
- type: Input,
415
- args: ['helperText']
416
- }], placeholder: [{
417
- type: Input
418
- }], minDate: [{
419
- type: Input
420
- }], maxDate: [{
421
- type: Input
422
- }], sdChange: [{
423
- type: Output
424
- }], sdFocus: [{
425
- type: Output
426
- }], model: [{
427
- type: Input
428
- }], modelChange: [{
429
- type: Output
430
- }], sdViewDef: [{
431
- type: ContentChild,
432
- args: [SdViewDefDirective]
433
- }], input: [{
434
- type: ViewChild,
435
- args: ['input']
436
- }], datePicker: [{
437
- type: ViewChild,
438
- args: [MatDatepicker]
439
- }] } });
281
+ ], template: "@let lbl = label();\r\n@let app = appearance();\r\n@let hideErr = hideInlineError();\r\n@let viewDef = sdViewDef();\r\n@let hText = helperText();\r\n@let req = required();\r\n@let inlErr = inlineError();\r\n\r\n@let minD = resolvedMin();\r\n@let maxD = resolvedMax();\r\n\r\n@if (viewed()) {\r\n <sd-view\r\n [label]=\"lbl\"\r\n [labelTemplate]=\"sdLabelTemplate()\"\r\n [value]=\"formControl.value\"\r\n [display]=\"formControl.value | date: 'dd/MM/yyyy HH:mm'\"\r\n [hyperlink]=\"hyperlink()\"\r\n [valueTemplate]=\"sdValueTemplate()\">\r\n </sd-view>\r\n} @else {\r\n @if (!app) {\r\n <ng-content select=\"[sdLabel]\">\r\n @if (lbl) {\r\n <sd-label [label]=\"lbl\" [required]=\"req\"></sd-label>\r\n }\r\n </ng-content>\r\n }\r\n \r\n <div\r\n class=\"d-flex align-items-center\"\r\n [class.sd-view]=\"viewDef?.templateRef\"\r\n [class.c-focused]=\"isFocused\"\r\n [class.c-disabled]=\"formControl.disabled\"\r\n (click)=\"onClick()\"\r\n aria-hidden=\"true\">\r\n \r\n @if (viewDef?.templateRef && !isFocused && !datetimePicker()?.opened) {\r\n <ng-container\r\n *ngTemplateOutlet=\"\r\n viewDef!.templateRef;\r\n context: { value: formControl.value }\r\n \">\r\n </ng-container>\r\n } @else {\r\n <mat-form-field\r\n class=\"c-form-field-datetime-input\"\r\n [class.sd-md]=\"size() === 'md'\"\r\n [class.sd-sm]=\"size() === 'sm'\"\r\n [class.hide-inline-error]=\"hideErr\"\r\n [appearance]=\"app || 'outline'\">\r\n \r\n @if (app && lbl) {\r\n <mat-label style=\"display: inline-block\">\r\n <div style=\"display: flex; align-items: center; gap: 4px\">\r\n <span>{{ lbl }}</span>\r\n @if (hText) {\r\n <mat-icon [matTooltip]=\"hText\" matTooltipPosition=\"below\">info_outline</mat-icon>\r\n }\r\n </div>\r\n </mat-label>\r\n }\r\n \r\n <mtx-datetimepicker #datetimePicker [type]=\"'datetime'\" [mode]=\"'auto'\"></mtx-datetimepicker>\r\n \r\n <input\r\n aria-hidden=\"true\"\r\n [attr.data-autoId]=\"autoId()\"\r\n [mtxDatetimepicker]=\"datetimePicker\"\r\n [id]=\"id\"\r\n (blur)=\"onConfirmInput($event)\"\r\n (keyup.enter)=\"onConfirmInput($event)\"\r\n (keydown)=\"onKeyDown($event)\"\r\n (dateChange)=\"onChange($event)\"\r\n [autocomplete]=\"id\"\r\n autocorrect=\"off\"\r\n [formControl]=\"formControl\"\r\n [required]=\"req\"\r\n [placeholder]=\"placeholder() || lbl || ''\"\r\n [min]=\"minD\"\r\n [max]=\"maxD\"\r\n (focus)=\"onFocus()\"\r\n (blur)=\"onBlur()\"\r\n #input\r\n matInput />\r\n \r\n <mtx-datetimepicker-toggle [for]=\"datetimePicker\" matSuffix></mtx-datetimepicker-toggle>\r\n \r\n @if (formControl.errors?.['required'] && formControl.touched) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ 'Vui l\u00F2ng nh\u1EADp th\u00F4ng tin' }}\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['matDatepickerMin'] && formControl.touched && !isFocused) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ 'Ng\u00E0y nh\u1ECF nh\u1EA5t' }}: <strong>{{ minD | date: 'dd/MM/yyyy HH:mm' }}</strong>\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['matDatepickerMax'] && formControl.touched && !isFocused) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ 'Ng\u00E0y l\u1EDBn nh\u1EA5t' }}: <strong>{{ maxD | date: 'dd/MM/yyyy HH:mm' }}</strong>\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['matDatetimePickerParse'] && formControl.touched && !isFocused) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ 'Parse error' }}: <strong>{{ formControl.errors?.['matDatetimePickerParse']?.text }}</strong>\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['customValidator'] && formControl.touched) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ formControl.errors?.['customValidator'] }}\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['date'] && formControl.touched) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ formControl.errors?.['date'] }}\r\n }\r\n </mat-error>\r\n }\r\n\r\n @if (formControl.errors?.['inlineError'] && formControl.touched) {\r\n <mat-error>\r\n @if (!hideErr) {\r\n {{ inlErr }}\r\n }\r\n </mat-error>\r\n }\r\n </mat-form-field>\r\n }\r\n </div>\r\n}", styles: [".text-primary{color:var(--sd-primary)!important}.bg-primary{background:var(--sd-primary)!important}.border-primary{border-color:var(--sd-primary)!important}.text-primary-light{color:var(--sd-primary-light)!important}.bg-primary-light{background:var(--sd-primary-light)!important}.border-primary-light{border-color:var(--sd-primary-light)!important}.text-primary-dark{color:var(--sd-primary-dark)!important}.bg-primary-dark{background:var(--sd-primary-dark)!important}.border-primary-dark{border-color:var(--sd-primary-dark)!important}.text-info{color:var(--sd-info)!important}.bg-info{background:var(--sd-info)!important}.border-info{border-color:var(--sd-info)!important}.text-info-light{color:var(--sd-info-light)!important}.bg-info-light{background:var(--sd-info-light)!important}.border-info-light{border-color:var(--sd-info-light)!important}.text-info-dark{color:var(--sd-info-dark)!important}.bg-info-dark{background:var(--sd-info-dark)!important}.border-info-dark{border-color:var(--sd-info-dark)!important}.text-success{color:var(--sd-success)!important}.bg-success{background:var(--sd-success)!important}.border-success{border-color:var(--sd-success)!important}.text-success-light{color:var(--sd-success-light)!important}.bg-success-light{background:var(--sd-success-light)!important}.border-success-light{border-color:var(--sd-success-light)!important}.text-success-dark{color:var(--sd-success-dark)!important}.bg-success-dark{background:var(--sd-success-dark)!important}.border-success-dark{border-color:var(--sd-success-dark)!important}.text-warning{color:var(--sd-warning)!important}.bg-warning{background:var(--sd-warning)!important}.border-warning{border-color:var(--sd-warning)!important}.text-warning-light{color:var(--sd-warning-light)!important}.bg-warning-light{background:var(--sd-warning-light)!important}.border-warning-light{border-color:var(--sd-warning-light)!important}.text-warning-dark{color:var(--sd-warning-dark)!important}.bg-warning-dark{background:var(--sd-warning-dark)!important}.border-warning-dark{border-color:var(--sd-warning-dark)!important}.text-error{color:var(--sd-error)!important}.bg-error{background:var(--sd-error)!important}.border-error{border-color:var(--sd-error)!important}.text-error-light{color:var(--sd-error-light)!important}.bg-error-light{background:var(--sd-error-light)!important}.border-error-light{border-color:var(--sd-error-light)!important}.text-error-dark{color:var(--sd-error-dark)!important}.bg-error-dark{background:var(--sd-error-dark)!important}.border-error-dark{border-color:var(--sd-error-dark)!important}.text-secondary{color:var(--sd-secondary)!important}.bg-secondary{background:var(--sd-secondary)!important}.border-secondary{border-color:var(--sd-secondary)!important}.text-secondary-light{color:var(--sd-secondary-light)!important}.bg-secondary-light{background:var(--sd-secondary-light)!important}.border-secondary-light{border-color:var(--sd-secondary-light)!important}.text-secondary-dark{color:var(--sd-secondary-dark)!important}.bg-secondary-dark{background:var(--sd-secondary-dark)!important}.border-secondary-dark{border-color:var(--sd-secondary-dark)!important}.text-light{color:var(--sd-light)!important}.bg-light{background:var(--sd-light)!important}.border-light{border-color:var(--sd-light)!important}.text-dark{color:var(--sd-dark)!important}.bg-dark{background:var(--sd-dark)!important}.border-dark{border-color:var(--sd-dark)!important}.text-black500{color:var(--sd-black500)!important}.bg-black500{background:var(--sd-black500)!important}.border-black500{border-color:var(--sd-black500)!important}.text-black400{color:var(--sd-black400)!important}.bg-black400{background:var(--sd-black400)!important}.border-black400{border-color:var(--sd-black400)!important}.text-black300{color:var(--sd-black300)!important}.bg-black300{background:var(--sd-black300)!important}.border-black300{border-color:var(--sd-black300)!important}.text-black200{color:var(--sd-black200)!important}.bg-black200{background:var(--sd-black200)!important}.border-black200{border-color:var(--sd-black200)!important}.text-black100{color:var(--sd-black100)!important}.bg-black100{background:var(--sd-black100)!important}.border-black100{border-color:var(--sd-black100)!important}.text-white{color:#fff!important}.bg-white{background:#fff!important}.border-white{border-color:#fff!important}.text-black{color:#000!important}.bg-black{background:#000!important}.border-black{border-color:#000!important}:host{padding-top:5px;display:block}:host ::ng-deep .mat-mdc-form-field.mat-form-field-appearance-outline.mat-form-field-disabled .mat-mdc-text-field-wrapper{background:var(--sd-black100)}:host ::ng-deep .mat-mdc-form-field input.mat-mdc-input-element:disabled{color:var(--sd-black400)!important}:host ::ng-deep .mat-mdc-form-field .mat-mdc-placeholder-required{color:var(--sd-error)}.sd-view:not(.c-focused):not(.c-disabled):hover{background-color:#ebecf0}\n"] }]
282
+ }], ctorParameters: () => [] });
440
283
 
441
284
  /**
442
285
  * Generated bundle index. Do not edit.