@mediusinc/mng-commons 7.3.0 → 7.4.0-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/mediusinc-mng-commons-core.mjs +4 -3
- package/fesm2022/mediusinc-mng-commons-core.mjs.map +1 -1
- package/fesm2022/mediusinc-mng-commons-filter.mjs +10 -0
- package/fesm2022/mediusinc-mng-commons-filter.mjs.map +1 -1
- package/fesm2022/mediusinc-mng-commons-form-api.mjs +21 -0
- package/fesm2022/mediusinc-mng-commons-form-api.mjs.map +1 -1
- package/fesm2022/mediusinc-mng-commons-form.mjs +181 -23
- package/fesm2022/mediusinc-mng-commons-form.mjs.map +1 -1
- package/fesm2022/{mediusinc-mng-commons-table-column-toggle.component-4BDcYyDd.mjs → mediusinc-mng-commons-table-column-toggle.component-D7fm83ug.mjs} +2 -2
- package/fesm2022/{mediusinc-mng-commons-table-column-toggle.component-4BDcYyDd.mjs.map → mediusinc-mng-commons-table-column-toggle.component-D7fm83ug.mjs.map} +1 -1
- package/fesm2022/{mediusinc-mng-commons-table-mediusinc-mng-commons-table-DoXp48ZT.mjs → mediusinc-mng-commons-table-mediusinc-mng-commons-table-Czmm5fLT.mjs} +45 -9
- package/fesm2022/mediusinc-mng-commons-table-mediusinc-mng-commons-table-Czmm5fLT.mjs.map +1 -0
- package/fesm2022/mediusinc-mng-commons-table.mjs +1 -1
- package/fesm2022/mediusinc-mng-commons-tableview-api.mjs +10 -0
- package/fesm2022/mediusinc-mng-commons-tableview-api.mjs.map +1 -1
- package/package.json +1 -1
- package/types/mediusinc-mng-commons-core.d.ts +14 -4
- package/types/mediusinc-mng-commons-filter.d.ts +8 -1
- package/types/mediusinc-mng-commons-form-api.d.ts +14 -1
- package/types/mediusinc-mng-commons-form.d.ts +36 -3
- package/types/mediusinc-mng-commons-table.d.ts +2 -0
- package/types/mediusinc-mng-commons-tableview-api.d.ts +8 -1
- package/version-info.json +6 -6
- package/fesm2022/mediusinc-mng-commons-table-mediusinc-mng-commons-table-DoXp48ZT.mjs.map +0 -1
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { NgTemplateOutlet } from '@angular/common';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import {
|
|
3
|
+
import { InjectionToken, inject, Injectable, forwardRef, Injector, DestroyRef, input, booleanAttribute, output, viewChild, signal, computed, ChangeDetectionStrategy, ViewEncapsulation, Component, numberAttribute, ChangeDetectorRef, effect, ElementRef, Renderer2, afterNextRender, Directive } from '@angular/core';
|
|
4
4
|
import { takeUntilDestroyed, toObservable as toObservable$1 } from '@angular/core/rxjs-interop';
|
|
5
|
-
import * as i1 from '@angular/forms';
|
|
5
|
+
import * as i1$1 from '@angular/forms';
|
|
6
6
|
import { NG_VALUE_ACCESSOR, FormsModule, NG_VALIDATORS, FormBuilder, Validators, ReactiveFormsModule, NgControl } from '@angular/forms';
|
|
7
7
|
import { TranslateService, TranslatePipe } from '@ngx-translate/core';
|
|
8
8
|
import { AutoComplete } from 'primeng/autocomplete';
|
|
9
9
|
import { InputGroup } from 'primeng/inputgroup';
|
|
10
10
|
import { InputGroupAddon } from 'primeng/inputgroupaddon';
|
|
11
|
-
import { ReplaySubject, take, switchMap,
|
|
11
|
+
import { of, tap, ReplaySubject, take, switchMap, merge, Subject, distinctUntilChanged, debounceTime, combineLatest, map as map$1 } from 'rxjs';
|
|
12
12
|
import { map } from 'rxjs/operators';
|
|
13
|
-
import { LoggerService, CommonsInternalError,
|
|
13
|
+
import { FilterMatchMode, toObservable, LoggerService, CommonsInternalError, effectWithDeps, fromSubscribeError, getErrorLogLevel, narrowI18nToTranslation, RerenderDirective, booleanWithDefaultAttribute, TemplateDirective, CommonsFeatureTypeEnum } from '@mediusinc/mng-commons/core';
|
|
14
14
|
import { Divider } from 'primeng/divider';
|
|
15
15
|
import { DatePicker } from 'primeng/datepicker';
|
|
16
|
-
import * as i1
|
|
16
|
+
import * as i1 from 'primeng/inputmask';
|
|
17
17
|
import { InputMask, InputMaskModule } from 'primeng/inputmask';
|
|
18
18
|
import { Listbox } from 'primeng/listbox';
|
|
19
19
|
import { Overlay } from 'primeng/overlay';
|
|
@@ -21,6 +21,121 @@ import { MultiSelect } from 'primeng/multiselect';
|
|
|
21
21
|
import { Select } from 'primeng/select';
|
|
22
22
|
import { InputNumber } from 'primeng/inputnumber';
|
|
23
23
|
|
|
24
|
+
const COMMONS_FORM_FEATURE_CONFIG_IT = new InjectionToken('COMMONS_FORM_FEATURE_CONFIG');
|
|
25
|
+
|
|
26
|
+
var _a;
|
|
27
|
+
class LookupLabelResolutionService {
|
|
28
|
+
static { this.IDLE_CLEANUP_TIMEOUT_MS = 2000; }
|
|
29
|
+
#config = inject(COMMONS_FORM_FEATURE_CONFIG_IT, { optional: true });
|
|
30
|
+
#cleanupInterval = this.#config?.lookupNameResolutionCleanupInterval ?? 5 * 60 * 1000;
|
|
31
|
+
#cache = new Map();
|
|
32
|
+
#providerInstanceKeys = new WeakMap();
|
|
33
|
+
#providerInstanceKeyCounter = 0;
|
|
34
|
+
#lastCleanupTimestamp = 0;
|
|
35
|
+
#cleanupScheduled = false;
|
|
36
|
+
storeEntry(dataProvider, valueProperty, propertyValue, item) {
|
|
37
|
+
if ((dataProvider.cacheEnabled ?? true) && (this.#config?.lookupNameResolutionConfigEnabled ?? true)) {
|
|
38
|
+
const expiresAt = new Date();
|
|
39
|
+
const expiresInSeconds = dataProvider.cacheTtl ?? 120;
|
|
40
|
+
expiresAt.setSeconds(expiresAt.getSeconds() + expiresInSeconds);
|
|
41
|
+
const key = this.#getKey(dataProvider, valueProperty, propertyValue);
|
|
42
|
+
this.#cache.set(key, { item, expiresAt });
|
|
43
|
+
this.#scheduleCacheCleanup();
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
getEntries(dataProvider, dataProviderService, valueProperty, propertyValues) {
|
|
47
|
+
this.#scheduleCacheCleanup();
|
|
48
|
+
if ((dataProvider.cacheEnabled ?? true) && (this.#config?.lookupNameResolutionConfigEnabled ?? true)) {
|
|
49
|
+
const keys = propertyValues.map(value => this.#getKey(dataProvider, valueProperty, value));
|
|
50
|
+
if (keys.every(key => {
|
|
51
|
+
const entry = this.#cache.get(key);
|
|
52
|
+
return !!(entry && entry.expiresAt > new Date());
|
|
53
|
+
})) {
|
|
54
|
+
return of(keys.map(key => this.#cache.get(key)?.item));
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
return this.#lookup(dataProvider, dataProviderService, valueProperty, propertyValues);
|
|
58
|
+
}
|
|
59
|
+
clear(opts) {
|
|
60
|
+
if (opts?.providerKey) {
|
|
61
|
+
for (const [key] of this.#cache) {
|
|
62
|
+
if (key.startsWith(`${opts.providerKey}_`)) {
|
|
63
|
+
this.#cache.delete(key);
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
else {
|
|
68
|
+
this.#cache.clear();
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
#lookup(dataProvider, dataProviderService, valueProperty, propertyValues) {
|
|
72
|
+
const isMultiValue = propertyValues.length > 1;
|
|
73
|
+
const params = {
|
|
74
|
+
filters: {
|
|
75
|
+
[valueProperty]: {
|
|
76
|
+
value: isMultiValue ? propertyValues : propertyValues[0],
|
|
77
|
+
matchMode: isMultiValue ? FilterMatchMode.In : FilterMatchMode.Equals
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
};
|
|
81
|
+
return toObservable(dataProvider.lookup(params, dataProviderService)).pipe(tap(items => items.forEach(item => this.storeEntry(dataProvider, valueProperty, item[valueProperty], item))));
|
|
82
|
+
}
|
|
83
|
+
#getKey(dataProvider, valueProperty, propertyValue) {
|
|
84
|
+
const providerKey = dataProvider.cacheKey ?? this.#getProviderInstanceKey(dataProvider);
|
|
85
|
+
return `${providerKey}_${valueProperty}_${propertyValue}`;
|
|
86
|
+
}
|
|
87
|
+
#getProviderInstanceKey(dataProvider) {
|
|
88
|
+
const key = this.#providerInstanceKeys.get(dataProvider);
|
|
89
|
+
if (key) {
|
|
90
|
+
return key;
|
|
91
|
+
}
|
|
92
|
+
const newKey = `lookup-provider-${++this.#providerInstanceKeyCounter}`;
|
|
93
|
+
this.#providerInstanceKeys.set(dataProvider, newKey);
|
|
94
|
+
return newKey;
|
|
95
|
+
}
|
|
96
|
+
#scheduleCacheCleanup() {
|
|
97
|
+
if (this.#cleanupScheduled) {
|
|
98
|
+
return;
|
|
99
|
+
}
|
|
100
|
+
const now = Date.now();
|
|
101
|
+
if (now - this.#lastCleanupTimestamp < this.#cleanupInterval) {
|
|
102
|
+
return;
|
|
103
|
+
}
|
|
104
|
+
this.#cleanupScheduled = true;
|
|
105
|
+
this.#runWhenIdle(() => {
|
|
106
|
+
this.#cleanupScheduled = false;
|
|
107
|
+
const runTimestamp = Date.now();
|
|
108
|
+
if (runTimestamp - this.#lastCleanupTimestamp < this.#cleanupInterval) {
|
|
109
|
+
return;
|
|
110
|
+
}
|
|
111
|
+
this.#lastCleanupTimestamp = runTimestamp;
|
|
112
|
+
this.#clearExpiredEntries(runTimestamp);
|
|
113
|
+
});
|
|
114
|
+
}
|
|
115
|
+
#clearExpiredEntries(now) {
|
|
116
|
+
for (const [key, entry] of this.#cache) {
|
|
117
|
+
if (entry.expiresAt.getTime() <= now) {
|
|
118
|
+
this.#cache.delete(key);
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
#runWhenIdle(task) {
|
|
123
|
+
const requestIdleCallback = window.requestIdleCallback;
|
|
124
|
+
if (requestIdleCallback) {
|
|
125
|
+
requestIdleCallback(() => task(), { timeout: _a.IDLE_CLEANUP_TIMEOUT_MS });
|
|
126
|
+
return;
|
|
127
|
+
}
|
|
128
|
+
requestAnimationFrame(task);
|
|
129
|
+
}
|
|
130
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: LookupLabelResolutionService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
131
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: LookupLabelResolutionService, providedIn: 'root' }); }
|
|
132
|
+
}
|
|
133
|
+
_a = LookupLabelResolutionService;
|
|
134
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: LookupLabelResolutionService, decorators: [{
|
|
135
|
+
type: Injectable,
|
|
136
|
+
args: [{ providedIn: 'root' }]
|
|
137
|
+
}] });
|
|
138
|
+
|
|
24
139
|
const AUTOCOMPLETE_VALUE_ACCESSOR = {
|
|
25
140
|
provide: NG_VALUE_ACCESSOR,
|
|
26
141
|
useExisting: forwardRef(() => AutocompleteComponent),
|
|
@@ -34,6 +149,7 @@ class AutocompleteComponent {
|
|
|
34
149
|
this.injector = inject(Injector);
|
|
35
150
|
this.destroyRef = inject(DestroyRef);
|
|
36
151
|
this.translate = inject(TranslateService);
|
|
152
|
+
this.labelLookupService = inject(LookupLabelResolutionService);
|
|
37
153
|
this.logger = inject(LoggerService).create('AutocompleteComponent');
|
|
38
154
|
this.dataProvider = input.required(...(ngDevMode ? [{ debugName: "dataProvider" }] : []));
|
|
39
155
|
this.optionsTrackProperty = input(...(ngDevMode ? [undefined, { debugName: "optionsTrackProperty" }] : []));
|
|
@@ -102,9 +218,16 @@ class AutocompleteComponent {
|
|
|
102
218
|
}
|
|
103
219
|
return this.optionsValuePropertyInit();
|
|
104
220
|
}, ...(ngDevMode ? [{ debugName: "optionsValueProperty" }] : []));
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
this.
|
|
221
|
+
effectWithDeps([this.ngModelValue, this.primeAutocomplete, this.multiselect], ([ngModelValue, primeAutocomplete, multiselect]) => {
|
|
222
|
+
// it hurts no one to re-write this
|
|
223
|
+
this._value = this.convertValueWithOptionsValuePropSetting(ngModelValue);
|
|
224
|
+
this._rawValue = ngModelValue;
|
|
225
|
+
// sync to autcomplete only if all is ready
|
|
226
|
+
if (primeAutocomplete != null &&
|
|
227
|
+
multiselect === primeAutocomplete?.multiple &&
|
|
228
|
+
(this._rawValue == null || (multiselect && Array.isArray(this._rawValue)) || (!multiselect && !Array.isArray(this._rawValue)))) {
|
|
229
|
+
primeAutocomplete?.updateModel(this._rawValue);
|
|
230
|
+
}
|
|
108
231
|
});
|
|
109
232
|
}
|
|
110
233
|
ngOnInit() {
|
|
@@ -148,6 +271,11 @@ class AutocompleteComponent {
|
|
|
148
271
|
.subscribe({
|
|
149
272
|
next: items => {
|
|
150
273
|
this.queryResultCacheSubject?.next(items);
|
|
274
|
+
const optionsValueProperty = this.optionsValueProperty();
|
|
275
|
+
const dataProvider = this.dataProvider();
|
|
276
|
+
if (dataProvider && optionsValueProperty) {
|
|
277
|
+
items.forEach(item => this.labelLookupService.storeEntry(dataProvider, optionsValueProperty, item[optionsValueProperty], item));
|
|
278
|
+
}
|
|
151
279
|
this.setSuggestionsFromItems(items, query);
|
|
152
280
|
if (isInit && !this._value) {
|
|
153
281
|
this.selectFirstItem();
|
|
@@ -268,14 +396,8 @@ class AutocompleteComponent {
|
|
|
268
396
|
this.setValueFromWrite(isMultiValue ? matchedItems : matchedItems[0]);
|
|
269
397
|
}
|
|
270
398
|
else {
|
|
271
|
-
this.
|
|
272
|
-
|
|
273
|
-
[optionsValuePropertyInit]: {
|
|
274
|
-
value: isMultiValue ? lookupValue : lookupValue[0],
|
|
275
|
-
matchMode: isMultiValue ? FilterMatchMode.In : FilterMatchMode.Equals
|
|
276
|
-
}
|
|
277
|
-
}
|
|
278
|
-
})
|
|
399
|
+
this.labelLookupService
|
|
400
|
+
.getEntries(this.dataProvider(), this.dataProviderService, optionsValuePropertyInit, lookupValue)
|
|
279
401
|
.pipe(take(1))
|
|
280
402
|
.subscribe({
|
|
281
403
|
next: items => {
|
|
@@ -452,11 +574,11 @@ class AutocompleteComponent {
|
|
|
452
574
|
}
|
|
453
575
|
}
|
|
454
576
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: AutocompleteComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
455
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: AutocompleteComponent, isStandalone: true, selector: "mng-autocomplete", inputs: { dataProvider: { classPropertyName: "dataProvider", publicName: "dataProvider", isSignal: true, isRequired: true, transformFunction: null }, optionsTrackProperty: { classPropertyName: "optionsTrackProperty", publicName: "optionsTrackProperty", isSignal: true, isRequired: false, transformFunction: null }, optionsValuePropertyInit: { classPropertyName: "optionsValuePropertyInit", publicName: "optionsValueProperty", isSignal: true, isRequired: false, transformFunction: null }, optionsLabelPropertyInit: { classPropertyName: "optionsLabelPropertyInit", publicName: "optionsLabelProperty", isSignal: true, isRequired: false, transformFunction: null }, optionsLabelTranslate: { classPropertyName: "optionsLabelTranslate", publicName: "optionsLabelTranslate", isSignal: true, isRequired: false, transformFunction: null }, inlineSearch: { classPropertyName: "inlineSearch", publicName: "inlineSearch", isSignal: true, isRequired: false, transformFunction: null }, openOnFocus: { classPropertyName: "openOnFocus", publicName: "openOnFocus", isSignal: true, isRequired: false, transformFunction: null }, multiselect: { classPropertyName: "multiselect", publicName: "multiselect", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, className: { classPropertyName: "className", publicName: "className", isSignal: true, isRequired: false, transformFunction: null }, dropdownClassName: { classPropertyName: "dropdownClassName", publicName: "dropdownClassName", isSignal: true, isRequired: false, transformFunction: null }, showClear: { classPropertyName: "showClear", publicName: "showClear", isSignal: true, isRequired: false, transformFunction: null }, autoClear: { classPropertyName: "autoClear", publicName: "autoClear", isSignal: true, isRequired: false, transformFunction: null }, selectFirst: { classPropertyName: "selectFirst", publicName: "selectFirst", isSignal: true, isRequired: false, transformFunction: null }, searchTrim: { classPropertyName: "searchTrim", publicName: "searchTrim", isSignal: true, isRequired: false, transformFunction: null }, disabledInput: { classPropertyName: "disabledInput", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, templates: { classPropertyName: "templates", publicName: "templates", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valueChange: "valueChange", blur: "blur" }, providers: [AUTOCOMPLETE_VALUE_ACCESSOR], viewQueries: [{ propertyName: "primeAutocomplete", first: true, predicate: AutoComplete, descendants: true, isSignal: true }], ngImport: i0, template: "<p-inputgroup [class]=\"{'has-prepends': prependTemplates().length > 0}\">\n @for (pt of prependTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"pt.template\"></ng-container>\n </p-inputgroup-addon>\n }\n <p-autoComplete\n
|
|
577
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: AutocompleteComponent, isStandalone: true, selector: "mng-autocomplete", inputs: { dataProvider: { classPropertyName: "dataProvider", publicName: "dataProvider", isSignal: true, isRequired: true, transformFunction: null }, optionsTrackProperty: { classPropertyName: "optionsTrackProperty", publicName: "optionsTrackProperty", isSignal: true, isRequired: false, transformFunction: null }, optionsValuePropertyInit: { classPropertyName: "optionsValuePropertyInit", publicName: "optionsValueProperty", isSignal: true, isRequired: false, transformFunction: null }, optionsLabelPropertyInit: { classPropertyName: "optionsLabelPropertyInit", publicName: "optionsLabelProperty", isSignal: true, isRequired: false, transformFunction: null }, optionsLabelTranslate: { classPropertyName: "optionsLabelTranslate", publicName: "optionsLabelTranslate", isSignal: true, isRequired: false, transformFunction: null }, inlineSearch: { classPropertyName: "inlineSearch", publicName: "inlineSearch", isSignal: true, isRequired: false, transformFunction: null }, openOnFocus: { classPropertyName: "openOnFocus", publicName: "openOnFocus", isSignal: true, isRequired: false, transformFunction: null }, multiselect: { classPropertyName: "multiselect", publicName: "multiselect", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, className: { classPropertyName: "className", publicName: "className", isSignal: true, isRequired: false, transformFunction: null }, dropdownClassName: { classPropertyName: "dropdownClassName", publicName: "dropdownClassName", isSignal: true, isRequired: false, transformFunction: null }, showClear: { classPropertyName: "showClear", publicName: "showClear", isSignal: true, isRequired: false, transformFunction: null }, autoClear: { classPropertyName: "autoClear", publicName: "autoClear", isSignal: true, isRequired: false, transformFunction: null }, selectFirst: { classPropertyName: "selectFirst", publicName: "selectFirst", isSignal: true, isRequired: false, transformFunction: null }, searchTrim: { classPropertyName: "searchTrim", publicName: "searchTrim", isSignal: true, isRequired: false, transformFunction: null }, disabledInput: { classPropertyName: "disabledInput", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, templates: { classPropertyName: "templates", publicName: "templates", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valueChange: "valueChange", blur: "blur" }, providers: [AUTOCOMPLETE_VALUE_ACCESSOR], viewQueries: [{ propertyName: "primeAutocomplete", first: true, predicate: AutoComplete, descendants: true, isSignal: true }], ngImport: i0, template: "<p-inputgroup [class]=\"{'has-prepends': prependTemplates().length > 0}\">\n @for (pt of prependTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"pt.template\"></ng-container>\n </p-inputgroup-addon>\n }\n <p-autoComplete\n *mngRerender=\"multiselect()\"\n [placeholder]=\"placeholder()\"\n [dropdown]=\"true\"\n [dataKey]=\"optionsTrackProperty()\"\n [optionLabel]=\"optionsLabelProperty()\"\n [suggestions]=\"suggestions()\"\n [multiple]=\"multiselect()\"\n [showEmptyMessage]=\"true\"\n [emptyMessage]=\"'mngAutocomplete.noMatches' | translate\"\n [class]=\"className()\"\n [panelStyleClass]=\"dropdownClassName()\"\n [minQueryLength]=\"openOnFocus() ? 0 : 1\"\n [showClear]=\"showClear()\"\n [forceSelection]=\"autoClear()\"\n [disabled]=\"disabled()\"\n [completeOnFocus]=\"openOnFocus()\"\n (completeMethod)=\"onSearch($event)\"\n (onSelect)=\"onSelect($event)\"\n (onUnselect)=\"onUnselect($event)\"\n (onFocus)=\"onFocus($event)\"\n (onBlur)=\"onBlur($event)\"\n (onClear)=\"onClear()\"\n (onShow)=\"onShow()\"\n (onHide)=\"onHide()\"\n appendTo=\"body\"\n dropdownMode=\"current\" />\n @for (at of appendTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"at.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</p-inputgroup>\n", styles: [".has-prepends .p-autocomplete-input-multiple{border-top-left-radius:0!important;border-bottom-left-radius:0!important}p-inputgroup{font-size:1rem}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "component", type: AutoComplete, selector: "p-autoComplete, p-autocomplete, p-auto-complete", inputs: ["minLength", "minQueryLength", "delay", "panelStyle", "styleClass", "panelStyleClass", "inputStyle", "inputId", "inputStyleClass", "placeholder", "readonly", "scrollHeight", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "autoHighlight", "forceSelection", "type", "autoZIndex", "baseZIndex", "ariaLabel", "dropdownAriaLabel", "ariaLabelledBy", "dropdownIcon", "unique", "group", "completeOnFocus", "showClear", "dropdown", "showEmptyMessage", "dropdownMode", "multiple", "addOnTab", "tabindex", "dataKey", "emptyMessage", "showTransitionOptions", "hideTransitionOptions", "autofocus", "autocomplete", "optionGroupChildren", "optionGroupLabel", "overlayOptions", "suggestions", "optionLabel", "optionValue", "id", "searchMessage", "emptySelectionMessage", "selectionMessage", "autoOptionFocus", "selectOnFocus", "searchLocale", "optionDisabled", "focusOnHover", "typeahead", "addOnBlur", "separator", "appendTo", "motionOptions"], outputs: ["completeMethod", "onSelect", "onUnselect", "onAdd", "onFocus", "onBlur", "onDropdownClick", "onClear", "onInputKeydown", "onKeyUp", "onShow", "onHide", "onLazyLoad"] }, { kind: "component", type: InputGroup, selector: "p-inputgroup, p-inputGroup, p-input-group", inputs: ["styleClass"] }, { kind: "component", type: InputGroupAddon, selector: "p-inputgroup-addon, p-inputGroupAddon", inputs: ["style", "styleClass"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: RerenderDirective, selector: "[mngRerender]", inputs: ["mngRerender"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
456
578
|
}
|
|
457
579
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: AutocompleteComponent, decorators: [{
|
|
458
580
|
type: Component,
|
|
459
|
-
args: [{ selector: 'mng-autocomplete', encapsulation: ViewEncapsulation.None, providers: [AUTOCOMPLETE_VALUE_ACCESSOR], imports: [TranslatePipe, FormsModule, AutoComplete, InputGroup, InputGroupAddon, NgTemplateOutlet], changeDetection: ChangeDetectionStrategy.OnPush, template: "<p-inputgroup [class]=\"{'has-prepends': prependTemplates().length > 0}\">\n @for (pt of prependTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"pt.template\"></ng-container>\n </p-inputgroup-addon>\n }\n <p-autoComplete\n
|
|
581
|
+
args: [{ selector: 'mng-autocomplete', encapsulation: ViewEncapsulation.None, providers: [AUTOCOMPLETE_VALUE_ACCESSOR], imports: [TranslatePipe, FormsModule, AutoComplete, InputGroup, InputGroupAddon, NgTemplateOutlet, RerenderDirective], changeDetection: ChangeDetectionStrategy.OnPush, template: "<p-inputgroup [class]=\"{'has-prepends': prependTemplates().length > 0}\">\n @for (pt of prependTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"pt.template\"></ng-container>\n </p-inputgroup-addon>\n }\n <p-autoComplete\n *mngRerender=\"multiselect()\"\n [placeholder]=\"placeholder()\"\n [dropdown]=\"true\"\n [dataKey]=\"optionsTrackProperty()\"\n [optionLabel]=\"optionsLabelProperty()\"\n [suggestions]=\"suggestions()\"\n [multiple]=\"multiselect()\"\n [showEmptyMessage]=\"true\"\n [emptyMessage]=\"'mngAutocomplete.noMatches' | translate\"\n [class]=\"className()\"\n [panelStyleClass]=\"dropdownClassName()\"\n [minQueryLength]=\"openOnFocus() ? 0 : 1\"\n [showClear]=\"showClear()\"\n [forceSelection]=\"autoClear()\"\n [disabled]=\"disabled()\"\n [completeOnFocus]=\"openOnFocus()\"\n (completeMethod)=\"onSearch($event)\"\n (onSelect)=\"onSelect($event)\"\n (onUnselect)=\"onUnselect($event)\"\n (onFocus)=\"onFocus($event)\"\n (onBlur)=\"onBlur($event)\"\n (onClear)=\"onClear()\"\n (onShow)=\"onShow()\"\n (onHide)=\"onHide()\"\n appendTo=\"body\"\n dropdownMode=\"current\" />\n @for (at of appendTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"at.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</p-inputgroup>\n", styles: [".has-prepends .p-autocomplete-input-multiple{border-top-left-radius:0!important;border-bottom-left-radius:0!important}p-inputgroup{font-size:1rem}\n"] }]
|
|
460
582
|
}], ctorParameters: () => [], propDecorators: { dataProvider: [{ type: i0.Input, args: [{ isSignal: true, alias: "dataProvider", required: true }] }], optionsTrackProperty: [{ type: i0.Input, args: [{ isSignal: true, alias: "optionsTrackProperty", required: false }] }], optionsValuePropertyInit: [{ type: i0.Input, args: [{ isSignal: true, alias: "optionsValueProperty", required: false }] }], optionsLabelPropertyInit: [{ type: i0.Input, args: [{ isSignal: true, alias: "optionsLabelProperty", required: false }] }], optionsLabelTranslate: [{ type: i0.Input, args: [{ isSignal: true, alias: "optionsLabelTranslate", required: false }] }], inlineSearch: [{ type: i0.Input, args: [{ isSignal: true, alias: "inlineSearch", required: false }] }], openOnFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "openOnFocus", required: false }] }], multiselect: [{ type: i0.Input, args: [{ isSignal: true, alias: "multiselect", required: false }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], className: [{ type: i0.Input, args: [{ isSignal: true, alias: "className", required: false }] }], dropdownClassName: [{ type: i0.Input, args: [{ isSignal: true, alias: "dropdownClassName", required: false }] }], showClear: [{ type: i0.Input, args: [{ isSignal: true, alias: "showClear", required: false }] }], autoClear: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoClear", required: false }] }], selectFirst: [{ type: i0.Input, args: [{ isSignal: true, alias: "selectFirst", required: false }] }], searchTrim: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchTrim", required: false }] }], disabledInput: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], templates: [{ type: i0.Input, args: [{ isSignal: true, alias: "templates", required: false }] }], valueChange: [{ type: i0.Output, args: ["valueChange"] }], blur: [{ type: i0.Output, args: ["blur"] }], primeAutocomplete: [{ type: i0.ViewChild, args: [i0.forwardRef(() => AutoComplete), { isSignal: true }] }] } });
|
|
461
583
|
|
|
462
584
|
const DATETIME_PICKER_VALUE_ACCESSOR = {
|
|
@@ -755,7 +877,7 @@ class DatetimePickerComponent {
|
|
|
755
877
|
this.overlayVisible.set(false);
|
|
756
878
|
}
|
|
757
879
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: DatetimePickerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
758
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: DatetimePickerComponent, isStandalone: true, selector: "mng-datetime-picker", inputs: { templates: { classPropertyName: "templates", publicName: "templates", isSignal: true, isRequired: false, transformFunction: null }, timeInput: { classPropertyName: "timeInput", publicName: "time", isSignal: true, isRequired: false, transformFunction: null }, timeSelect: { classPropertyName: "timeSelect", publicName: "timeSelect", isSignal: true, isRequired: false, transformFunction: null }, timeSelectInterval: { classPropertyName: "timeSelectInterval", publicName: "timeSelectInterval", isSignal: true, isRequired: false, transformFunction: null }, secondsInput: { classPropertyName: "secondsInput", publicName: "seconds", isSignal: true, isRequired: false, transformFunction: null }, milliseconds: { classPropertyName: "milliseconds", publicName: "milliseconds", isSignal: true, isRequired: false, transformFunction: null }, primeTimePicker: { classPropertyName: "primeTimePicker", publicName: "primeTimePicker", isSignal: true, isRequired: false, transformFunction: null }, dateFormat: { classPropertyName: "dateFormat", publicName: "dateFormat", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, minDate: { classPropertyName: "minDate", publicName: "minDate", isSignal: true, isRequired: false, transformFunction: null }, maxDate: { classPropertyName: "maxDate", publicName: "maxDate", isSignal: true, isRequired: false, transformFunction: null }, disabledInput: { classPropertyName: "disabledInput", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, showIcon: { classPropertyName: "showIcon", publicName: "showIcon", isSignal: true, isRequired: false, transformFunction: null }, showButtonBar: { classPropertyName: "showButtonBar", publicName: "showButtonBar", isSignal: true, isRequired: false, transformFunction: null }, showClear: { classPropertyName: "showClear", publicName: "showClear", isSignal: true, isRequired: false, transformFunction: null }, className: { classPropertyName: "className", publicName: "className", isSignal: true, isRequired: false, transformFunction: null }, panelStyleClass: { classPropertyName: "panelStyleClass", publicName: "panelStyleClass", isSignal: true, isRequired: false, transformFunction: null }, inputStyleClass: { classPropertyName: "inputStyleClass", publicName: "inputStyleClass", isSignal: true, isRequired: false, transformFunction: null }, dateRange: { classPropertyName: "dateRange", publicName: "dateRange", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { blur: "blur" }, host: { classAttribute: "block" }, providers: [DATETIME_PICKER_VALUE_ACCESSOR, DATETIME_PICKER_VALIDATOR], viewQueries: [{ propertyName: "maskInput", first: true, predicate: InputMask, descendants: true, isSignal: true }], ngImport: i0, template: "<p-inputgroup class=\"flex-col gap-2\">\n <ng-container *ngTemplateOutlet=\"prependAddons\"></ng-container>\n <!-- Append to body, to prevent overflow in popups (like editable) -->\n <div class=\"flex gap-1\">\n <p-date-picker\n appendTo=\"body\"\n [class]=\"className() + ' basis-1/2 shrink-0'\"\n [panelStyleClass]=\"panelStyleClass()\"\n [inputStyleClass]=\"inputStyleClass()\"\n [minDate]=\"minDate()\"\n [maxDate]=\"maxDate()\"\n [showClear]=\"showClear()\"\n [placeholder]=\"placeholder()\"\n [dateFormat]=\"dateFormat()\"\n [disabled]=\"disabled()\"\n [showTime]=\"time() && primeTimePicker()\"\n [showIcon]=\"showIcon()\"\n [showSeconds]=\"primeTimePicker() && seconds()\"\n [selectionMode]=\"!time() && dateRange() ? 'range' : 'single'\"\n [showButtonBar]=\"showButtonBar()\"\n [firstDayOfWeek]=\"1\"\n [ngModel]=\"displayDate()\"\n (onBlur)=\"handleDateBlur($event)\"\n (onClear)=\"onClear()\"\n (onTodayClick)=\"onSelectToday()\"\n (onClearClick)=\"onClear()\"\n (ngModelChange)=\"onDateModelChange($event)\"/>\n @if (time() && !primeTimePicker()) {\n <p-inputgroup class=\"basis-1/2 shrink-0\">\n <p-inputmask\n #InputMask\n class=\"w-full flex\"\n [invalid]=\"!timeValid()\"\n [(ngModel)]=\"selectedTime\"\n (ngModelChange)=\"onTimeSelect()\"\n [disabled]=\"disabled()\"\n [mask]=\"inputMaskConfig().mask\"\n [placeholder]=\"inputMaskConfig().placeholder\"\n [slotChar]=\"inputMaskConfig().format\"\n [showClear]=\"showClear()\"\n (onClear)=\"onClear()\"\n (click)=\"openOverlay()\"\n (onFocus)=\"openOverlay()\"\n (onBlur)=\"closeOverlay()\" />\n <button\n class=\"p-datepicker-dropdown cursor-pointer shrink-0\"\n [disabled]=\"disabled()\"\n (click)=\"focusTimeInputMask($event, InputMask)\"\n aria-label=\"Focus time mask input\">\n <i class=\"pi pi-clock\"></i>\n </button>\n </p-inputgroup>\n @if (timeSelect() && !disabled()) {\n <!-- Using display:contents rendering, so that the parents flex gap doesn\u2019t apply to this container -->\n <p-overlay class=\"contents\" [(visible)]=\"overlayVisible\" appendTo=\"body\">\n <!-- Refresh event is unnecessary, because it shares the value with the MaskInput, which then triggers ngModelChange.\n It still exists because defaultPropagation closes the popup in filters/editor on select, and disabling it, doesn't trigger the change event -->\n <p-listbox\n class=\"mr-10\"\n [options]=\"selectOptions()\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"selectedTime\"\n (click)=\"$event.stopPropagation()\"\n (mousedown)=\"$event.preventDefault()\"\n (mouseup)=\"closeOverlay()\"\n (onChange)=\"onTimeSelect()\" />\n </p-overlay>\n }\n }\n </div>\n\n <ng-container *ngTemplateOutlet=\"appendAddons\"></ng-container>\n</p-inputgroup>\n\n<ng-template #prependAddons>\n @for (pt of prependTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"pt.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</ng-template>\n<ng-template #appendAddons>\n @for (at of appendTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"at.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</ng-template>\n", styles: ["mng-datetime-picker .p-inputtext.p-invalid:enabled:focus{border-color:var(--p-inputtext-invalid-border-color)}mng-datetime-picker .p-inputgroup .p-datepicker-dropdown{border-start-end-radius:var(--p-datepicker-dropdown-border-radius);border-end-end-radius:var(--p-datepicker-dropdown-border-radius)}\n"], dependencies: [{ kind: "component", type: DatePicker, selector: "p-datePicker, p-datepicker, p-date-picker", inputs: ["iconDisplay", "styleClass", "inputStyle", "inputId", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "readonlyInput", "shortYearCutoff", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "minDate", "maxDate", "disabledDates", "disabledDays", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "view", "defaultDate", "appendTo", "motionOptions"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "component", type: InputGroup, selector: "p-inputgroup, p-inputGroup, p-input-group", inputs: ["styleClass"] }, { kind: "component", type: InputGroupAddon, selector: "p-inputgroup-addon, p-inputGroupAddon", inputs: ["style", "styleClass"] }, { kind: "ngmodule", type: InputMaskModule }, { kind: "component", type: i1$1.InputMask, selector: "p-inputmask, p-inputMask, p-input-mask", inputs: ["type", "slotChar", "autoClear", "showClear", "style", "inputId", "styleClass", "placeholder", "tabindex", "title", "ariaLabel", "ariaLabelledBy", "ariaRequired", "readonly", "unmask", "characterPattern", "autofocus", "autocomplete", "keepBuffer", "mask"], outputs: ["onComplete", "onFocus", "onBlur", "onInput", "onKeydown", "onClear"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { 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: "component", type: Listbox, selector: "p-listbox, p-listBox, p-list-box", inputs: ["hostName", "id", "searchMessage", "emptySelectionMessage", "selectionMessage", "autoOptionFocus", "ariaLabel", "selectOnFocus", "searchLocale", "focusOnHover", "filterMessage", "filterFields", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "scrollHeight", "tabindex", "multiple", "styleClass", "listStyle", "listStyleClass", "readonly", "checkbox", "filter", "filterBy", "filterMatchMode", "filterLocale", "metaKeySelection", "dataKey", "showToggleAll", "optionLabel", "optionValue", "optionGroupChildren", "optionGroupLabel", "optionDisabled", "ariaFilterLabel", "filterPlaceHolder", "emptyFilterMessage", "emptyMessage", "group", "options", "filterValue", "selectAll", "striped", "highlightOnSelect", "checkmark", "dragdrop", "dropListData", "fluid"], outputs: ["onChange", "onClick", "onDblClick", "onFilter", "onFocus", "onBlur", "onSelectAllChange", "onLazyLoad", "onDrop"] }, { kind: "component", type: Overlay, selector: "p-overlay", inputs: ["hostName", "visible", "mode", "style", "styleClass", "contentStyle", "contentStyleClass", "target", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "listener", "responsive", "options", "appendTo", "inline", "motionOptions", "hostAttrSelector"], outputs: ["visibleChange", "onBeforeShow", "onShow", "onBeforeHide", "onHide", "onAnimationStart", "onAnimationDone", "onBeforeEnter", "onEnter", "onAfterEnter", "onBeforeLeave", "onLeave", "onAfterLeave"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
880
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: DatetimePickerComponent, isStandalone: true, selector: "mng-datetime-picker", inputs: { templates: { classPropertyName: "templates", publicName: "templates", isSignal: true, isRequired: false, transformFunction: null }, timeInput: { classPropertyName: "timeInput", publicName: "time", isSignal: true, isRequired: false, transformFunction: null }, timeSelect: { classPropertyName: "timeSelect", publicName: "timeSelect", isSignal: true, isRequired: false, transformFunction: null }, timeSelectInterval: { classPropertyName: "timeSelectInterval", publicName: "timeSelectInterval", isSignal: true, isRequired: false, transformFunction: null }, secondsInput: { classPropertyName: "secondsInput", publicName: "seconds", isSignal: true, isRequired: false, transformFunction: null }, milliseconds: { classPropertyName: "milliseconds", publicName: "milliseconds", isSignal: true, isRequired: false, transformFunction: null }, primeTimePicker: { classPropertyName: "primeTimePicker", publicName: "primeTimePicker", isSignal: true, isRequired: false, transformFunction: null }, dateFormat: { classPropertyName: "dateFormat", publicName: "dateFormat", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, minDate: { classPropertyName: "minDate", publicName: "minDate", isSignal: true, isRequired: false, transformFunction: null }, maxDate: { classPropertyName: "maxDate", publicName: "maxDate", isSignal: true, isRequired: false, transformFunction: null }, disabledInput: { classPropertyName: "disabledInput", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, showIcon: { classPropertyName: "showIcon", publicName: "showIcon", isSignal: true, isRequired: false, transformFunction: null }, showButtonBar: { classPropertyName: "showButtonBar", publicName: "showButtonBar", isSignal: true, isRequired: false, transformFunction: null }, showClear: { classPropertyName: "showClear", publicName: "showClear", isSignal: true, isRequired: false, transformFunction: null }, className: { classPropertyName: "className", publicName: "className", isSignal: true, isRequired: false, transformFunction: null }, panelStyleClass: { classPropertyName: "panelStyleClass", publicName: "panelStyleClass", isSignal: true, isRequired: false, transformFunction: null }, inputStyleClass: { classPropertyName: "inputStyleClass", publicName: "inputStyleClass", isSignal: true, isRequired: false, transformFunction: null }, dateRange: { classPropertyName: "dateRange", publicName: "dateRange", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { blur: "blur" }, host: { classAttribute: "block" }, providers: [DATETIME_PICKER_VALUE_ACCESSOR, DATETIME_PICKER_VALIDATOR], viewQueries: [{ propertyName: "maskInput", first: true, predicate: InputMask, descendants: true, isSignal: true }], ngImport: i0, template: "<p-inputgroup class=\"flex-col gap-2\">\n <ng-container *ngTemplateOutlet=\"prependAddons\"></ng-container>\n <!-- Append to body, to prevent overflow in popups (like editable) -->\n <div class=\"flex gap-1\">\n <p-date-picker\n appendTo=\"body\"\n [class]=\"className() + ' basis-1/2 shrink-0'\"\n [panelStyleClass]=\"panelStyleClass()\"\n [inputStyleClass]=\"inputStyleClass()\"\n [minDate]=\"minDate()\"\n [maxDate]=\"maxDate()\"\n [showClear]=\"showClear()\"\n [placeholder]=\"placeholder()\"\n [dateFormat]=\"dateFormat()\"\n [disabled]=\"disabled()\"\n [showTime]=\"time() && primeTimePicker()\"\n [showIcon]=\"showIcon()\"\n [showSeconds]=\"primeTimePicker() && seconds()\"\n [selectionMode]=\"!time() && dateRange() ? 'range' : 'single'\"\n [showButtonBar]=\"showButtonBar()\"\n [firstDayOfWeek]=\"1\"\n [ngModel]=\"displayDate()\"\n (onBlur)=\"handleDateBlur($event)\"\n (onClear)=\"onClear()\"\n (onTodayClick)=\"onSelectToday()\"\n (onClearClick)=\"onClear()\"\n (ngModelChange)=\"onDateModelChange($event)\"/>\n @if (time() && !primeTimePicker()) {\n <p-inputgroup class=\"basis-1/2 shrink-0\">\n <p-inputmask\n #InputMask\n class=\"w-full flex\"\n [invalid]=\"!timeValid()\"\n [(ngModel)]=\"selectedTime\"\n (ngModelChange)=\"onTimeSelect()\"\n [disabled]=\"disabled()\"\n [mask]=\"inputMaskConfig().mask\"\n [placeholder]=\"inputMaskConfig().placeholder\"\n [slotChar]=\"inputMaskConfig().format\"\n [showClear]=\"showClear()\"\n (onClear)=\"onClear()\"\n (click)=\"openOverlay()\"\n (onFocus)=\"openOverlay()\"\n (onBlur)=\"closeOverlay()\" />\n <button\n class=\"p-datepicker-dropdown cursor-pointer shrink-0\"\n [disabled]=\"disabled()\"\n (click)=\"focusTimeInputMask($event, InputMask)\"\n aria-label=\"Focus time mask input\">\n <i class=\"pi pi-clock\"></i>\n </button>\n </p-inputgroup>\n @if (timeSelect() && !disabled()) {\n <!-- Using display:contents rendering, so that the parents flex gap doesn\u2019t apply to this container -->\n <p-overlay class=\"contents\" [(visible)]=\"overlayVisible\" appendTo=\"body\">\n <!-- Refresh event is unnecessary, because it shares the value with the MaskInput, which then triggers ngModelChange.\n It still exists because defaultPropagation closes the popup in filters/editor on select, and disabling it, doesn't trigger the change event -->\n <p-listbox\n class=\"mr-10\"\n [options]=\"selectOptions()\"\n optionLabel=\"label\"\n optionValue=\"value\"\n [(ngModel)]=\"selectedTime\"\n (click)=\"$event.stopPropagation()\"\n (mousedown)=\"$event.preventDefault()\"\n (mouseup)=\"closeOverlay()\"\n (onChange)=\"onTimeSelect()\" />\n </p-overlay>\n }\n }\n </div>\n\n <ng-container *ngTemplateOutlet=\"appendAddons\"></ng-container>\n</p-inputgroup>\n\n<ng-template #prependAddons>\n @for (pt of prependTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"pt.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</ng-template>\n<ng-template #appendAddons>\n @for (at of appendTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"at.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</ng-template>\n", styles: ["mng-datetime-picker .p-inputtext.p-invalid:enabled:focus{border-color:var(--p-inputtext-invalid-border-color)}mng-datetime-picker .p-inputgroup .p-datepicker-dropdown{border-start-end-radius:var(--p-datepicker-dropdown-border-radius);border-end-end-radius:var(--p-datepicker-dropdown-border-radius)}\n"], dependencies: [{ kind: "component", type: DatePicker, selector: "p-datePicker, p-datepicker, p-date-picker", inputs: ["iconDisplay", "styleClass", "inputStyle", "inputId", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "readonlyInput", "shortYearCutoff", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "minDate", "maxDate", "disabledDates", "disabledDays", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "view", "defaultDate", "appendTo", "motionOptions"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "component", type: InputGroup, selector: "p-inputgroup, p-inputGroup, p-input-group", inputs: ["styleClass"] }, { kind: "component", type: InputGroupAddon, selector: "p-inputgroup-addon, p-inputGroupAddon", inputs: ["style", "styleClass"] }, { kind: "ngmodule", type: InputMaskModule }, { kind: "component", type: i1.InputMask, selector: "p-inputmask, p-inputMask, p-input-mask", inputs: ["type", "slotChar", "autoClear", "showClear", "style", "inputId", "styleClass", "placeholder", "tabindex", "title", "ariaLabel", "ariaLabelledBy", "ariaRequired", "readonly", "unmask", "characterPattern", "autofocus", "autocomplete", "keepBuffer", "mask"], outputs: ["onComplete", "onFocus", "onBlur", "onInput", "onKeydown", "onClear"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: Listbox, selector: "p-listbox, p-listBox, p-list-box", inputs: ["hostName", "id", "searchMessage", "emptySelectionMessage", "selectionMessage", "autoOptionFocus", "ariaLabel", "selectOnFocus", "searchLocale", "focusOnHover", "filterMessage", "filterFields", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "scrollHeight", "tabindex", "multiple", "styleClass", "listStyle", "listStyleClass", "readonly", "checkbox", "filter", "filterBy", "filterMatchMode", "filterLocale", "metaKeySelection", "dataKey", "showToggleAll", "optionLabel", "optionValue", "optionGroupChildren", "optionGroupLabel", "optionDisabled", "ariaFilterLabel", "filterPlaceHolder", "emptyFilterMessage", "emptyMessage", "group", "options", "filterValue", "selectAll", "striped", "highlightOnSelect", "checkmark", "dragdrop", "dropListData", "fluid"], outputs: ["onChange", "onClick", "onDblClick", "onFilter", "onFocus", "onBlur", "onSelectAllChange", "onLazyLoad", "onDrop"] }, { kind: "component", type: Overlay, selector: "p-overlay", inputs: ["hostName", "visible", "mode", "style", "styleClass", "contentStyle", "contentStyleClass", "target", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "listener", "responsive", "options", "appendTo", "inline", "motionOptions", "hostAttrSelector"], outputs: ["visibleChange", "onBeforeShow", "onShow", "onBeforeHide", "onHide", "onAnimationStart", "onAnimationDone", "onBeforeEnter", "onEnter", "onAfterEnter", "onBeforeLeave", "onLeave", "onAfterLeave"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
759
881
|
}
|
|
760
882
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: DatetimePickerComponent, decorators: [{
|
|
761
883
|
type: Component,
|
|
@@ -901,7 +1023,7 @@ class DateRangeComponent {
|
|
|
901
1023
|
}
|
|
902
1024
|
}
|
|
903
1025
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: DateRangeComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
904
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: DateRangeComponent, isStandalone: true, selector: "mng-date-range", inputs: { placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, showTime: { classPropertyName: "showTime", publicName: "showTime", isSignal: true, isRequired: false, transformFunction: null }, showSeconds: { classPropertyName: "showSeconds", publicName: "showSeconds", isSignal: true, isRequired: false, transformFunction: null }, milliseconds: { classPropertyName: "milliseconds", publicName: "milliseconds", isSignal: true, isRequired: false, transformFunction: null }, primeTimePicker: { classPropertyName: "primeTimePicker", publicName: "primeTimePicker", isSignal: true, isRequired: false, transformFunction: null }, timeSelect: { classPropertyName: "timeSelect", publicName: "timeSelect", isSignal: true, isRequired: false, transformFunction: null }, timeSelectInterval: { classPropertyName: "timeSelectInterval", publicName: "timeSelectInterval", isSignal: true, isRequired: false, transformFunction: null }, dateFormat: { classPropertyName: "dateFormat", publicName: "dateFormat", isSignal: true, isRequired: false, transformFunction: null }, className: { classPropertyName: "className", publicName: "className", isSignal: true, isRequired: false, transformFunction: null }, inputStyleClass: { classPropertyName: "inputStyleClass", publicName: "inputStyleClass", 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 }, vertical: { classPropertyName: "vertical", publicName: "vertical", isSignal: true, isRequired: false, transformFunction: null }, templates: { classPropertyName: "templates", publicName: "templates", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "className()" } }, providers: [DATE_RANGE_VALUE_ACCESSOR, DATE_RANGE_VALIDATOR], ngImport: i0, template: "@if (showTime()) {\n <div class=\"flex gap-1\" [class.flex-col]=\"vertical()\">\n <p-inputgroup>\n <ng-container *ngTemplateOutlet=\"prependAddons\"></ng-container>\n <mng-datetime-picker\n class=\"w-full\"\n [inputStyleClass]=\"inputStyleClass()\"\n [formControl]=\"fromCtrl\"\n [maxDate]=\"toCtrl.value\"\n [placeholder]=\"(placeholder() + ' ' + ('mngTable.filterRangeFrom' | translate)).trim()\"\n [dateFormat]=\"dateFormat()\"\n showIcon=\"true\"\n time=\"true\"\n [seconds]=\"showSeconds()\"\n [milliseconds]=\"milliseconds()\"\n [primeTimePicker]=\"primeTimePicker()\"\n [timeSelect]=\"timeSelect()\"\n [timeSelectInterval]=\"timeSelectInterval()\"\n (blur)=\"onBlur()\" />\n <ng-container *ngTemplateOutlet=\"appendAddons\"></ng-container>\n </p-inputgroup>\n @if (!vertical()) {\n <p-divider layout=\"horizontal\" class=\"!w-3 !p-0\" />\n }\n <p-inputgroup>\n <ng-container *ngTemplateOutlet=\"prependAddons\"></ng-container>\n <mng-datetime-picker\n class=\"w-full\"\n [inputStyleClass]=\"inputStyleClass()\"\n [formControl]=\"toCtrl\"\n [minDate]=\"fromCtrl.value\"\n [placeholder]=\"(placeholder() + ' ' + ('mngTable.filterRangeTo' | translate)).trim()\"\n [dateFormat]=\"dateFormat()\"\n showIcon=\"true\"\n time=\"true\"\n [seconds]=\"showSeconds()\"\n [milliseconds]=\"milliseconds()\"\n [primeTimePicker]=\"primeTimePicker()\"\n [timeSelect]=\"timeSelect()\"\n [timeSelectInterval]=\"timeSelectInterval()\"\n (blur)=\"onBlur()\" />\n <ng-container *ngTemplateOutlet=\"appendAddons\"></ng-container>\n </p-inputgroup>\n </div>\n} @else {\n <p-input-group>\n <ng-container *ngTemplateOutlet=\"prependAddons\"></ng-container>\n <mng-datetime-picker\n class=\"w-full\"\n [inputStyleClass]=\"inputStyleClass()\"\n [formControl]=\"dateRangeCtrl\"\n [placeholder]=\"placeholder()\"\n [dateFormat]=\"dateFormat()\"\n dateRange=\"true\"\n showIcon=\"true\"\n (blur)=\"onBlur()\" />\n <ng-container *ngTemplateOutlet=\"appendAddons\"></ng-container\n ></p-input-group>\n}\n\n<ng-template #prependAddons>\n @for (pt of prependTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"pt.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</ng-template>\n<ng-template #appendAddons>\n @for (at of appendTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"at.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</ng-template>\n", styles: ["mng-date-range.ng-dirty.ng-invalid p-date-picker>.p-datepicker>.p-inputtext{border-color:var(--p-inputtext-invalid-border-color, #f87171)}\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: "component", type: DatetimePickerComponent, selector: "mng-datetime-picker", inputs: ["templates", "time", "timeSelect", "timeSelectInterval", "seconds", "milliseconds", "primeTimePicker", "dateFormat", "placeholder", "minDate", "maxDate", "disabled", "showIcon", "showButtonBar", "showClear", "className", "panelStyleClass", "inputStyleClass", "dateRange"], outputs: ["blur"] }, { kind: "component", type: Divider, selector: "p-divider", inputs: ["styleClass", "layout", "type", "align"] }, { kind: "component", type: InputGroupAddon, selector: "p-inputgroup-addon, p-inputGroupAddon", inputs: ["style", "styleClass"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: InputGroup, selector: "p-inputgroup, p-inputGroup, p-input-group", inputs: ["styleClass"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
1026
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: DateRangeComponent, isStandalone: true, selector: "mng-date-range", inputs: { placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, showTime: { classPropertyName: "showTime", publicName: "showTime", isSignal: true, isRequired: false, transformFunction: null }, showSeconds: { classPropertyName: "showSeconds", publicName: "showSeconds", isSignal: true, isRequired: false, transformFunction: null }, milliseconds: { classPropertyName: "milliseconds", publicName: "milliseconds", isSignal: true, isRequired: false, transformFunction: null }, primeTimePicker: { classPropertyName: "primeTimePicker", publicName: "primeTimePicker", isSignal: true, isRequired: false, transformFunction: null }, timeSelect: { classPropertyName: "timeSelect", publicName: "timeSelect", isSignal: true, isRequired: false, transformFunction: null }, timeSelectInterval: { classPropertyName: "timeSelectInterval", publicName: "timeSelectInterval", isSignal: true, isRequired: false, transformFunction: null }, dateFormat: { classPropertyName: "dateFormat", publicName: "dateFormat", isSignal: true, isRequired: false, transformFunction: null }, className: { classPropertyName: "className", publicName: "className", isSignal: true, isRequired: false, transformFunction: null }, inputStyleClass: { classPropertyName: "inputStyleClass", publicName: "inputStyleClass", 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 }, vertical: { classPropertyName: "vertical", publicName: "vertical", isSignal: true, isRequired: false, transformFunction: null }, templates: { classPropertyName: "templates", publicName: "templates", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "className()" } }, providers: [DATE_RANGE_VALUE_ACCESSOR, DATE_RANGE_VALIDATOR], ngImport: i0, template: "@if (showTime()) {\n <div class=\"flex gap-1\" [class.flex-col]=\"vertical()\">\n <p-inputgroup>\n <ng-container *ngTemplateOutlet=\"prependAddons\"></ng-container>\n <mng-datetime-picker\n class=\"w-full\"\n [inputStyleClass]=\"inputStyleClass()\"\n [formControl]=\"fromCtrl\"\n [maxDate]=\"toCtrl.value\"\n [placeholder]=\"(placeholder() + ' ' + ('mngTable.filterRangeFrom' | translate)).trim()\"\n [dateFormat]=\"dateFormat()\"\n showIcon=\"true\"\n time=\"true\"\n [seconds]=\"showSeconds()\"\n [milliseconds]=\"milliseconds()\"\n [primeTimePicker]=\"primeTimePicker()\"\n [timeSelect]=\"timeSelect()\"\n [timeSelectInterval]=\"timeSelectInterval()\"\n (blur)=\"onBlur()\" />\n <ng-container *ngTemplateOutlet=\"appendAddons\"></ng-container>\n </p-inputgroup>\n @if (!vertical()) {\n <p-divider layout=\"horizontal\" class=\"!w-3 !p-0\" />\n }\n <p-inputgroup>\n <ng-container *ngTemplateOutlet=\"prependAddons\"></ng-container>\n <mng-datetime-picker\n class=\"w-full\"\n [inputStyleClass]=\"inputStyleClass()\"\n [formControl]=\"toCtrl\"\n [minDate]=\"fromCtrl.value\"\n [placeholder]=\"(placeholder() + ' ' + ('mngTable.filterRangeTo' | translate)).trim()\"\n [dateFormat]=\"dateFormat()\"\n showIcon=\"true\"\n time=\"true\"\n [seconds]=\"showSeconds()\"\n [milliseconds]=\"milliseconds()\"\n [primeTimePicker]=\"primeTimePicker()\"\n [timeSelect]=\"timeSelect()\"\n [timeSelectInterval]=\"timeSelectInterval()\"\n (blur)=\"onBlur()\" />\n <ng-container *ngTemplateOutlet=\"appendAddons\"></ng-container>\n </p-inputgroup>\n </div>\n} @else {\n <p-input-group>\n <ng-container *ngTemplateOutlet=\"prependAddons\"></ng-container>\n <mng-datetime-picker\n class=\"w-full\"\n [inputStyleClass]=\"inputStyleClass()\"\n [formControl]=\"dateRangeCtrl\"\n [placeholder]=\"placeholder()\"\n [dateFormat]=\"dateFormat()\"\n dateRange=\"true\"\n showIcon=\"true\"\n (blur)=\"onBlur()\" />\n <ng-container *ngTemplateOutlet=\"appendAddons\"></ng-container\n ></p-input-group>\n}\n\n<ng-template #prependAddons>\n @for (pt of prependTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"pt.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</ng-template>\n<ng-template #appendAddons>\n @for (at of appendTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"at.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</ng-template>\n", styles: ["mng-date-range.ng-dirty.ng-invalid p-date-picker>.p-datepicker>.p-inputtext{border-color:var(--p-inputtext-invalid-border-color, #f87171)}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: DatetimePickerComponent, selector: "mng-datetime-picker", inputs: ["templates", "time", "timeSelect", "timeSelectInterval", "seconds", "milliseconds", "primeTimePicker", "dateFormat", "placeholder", "minDate", "maxDate", "disabled", "showIcon", "showButtonBar", "showClear", "className", "panelStyleClass", "inputStyleClass", "dateRange"], outputs: ["blur"] }, { kind: "component", type: Divider, selector: "p-divider", inputs: ["styleClass", "layout", "type", "align"] }, { kind: "component", type: InputGroupAddon, selector: "p-inputgroup-addon, p-inputGroupAddon", inputs: ["style", "styleClass"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: InputGroup, selector: "p-inputgroup, p-inputGroup, p-input-group", inputs: ["styleClass"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
905
1027
|
}
|
|
906
1028
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: DateRangeComponent, decorators: [{
|
|
907
1029
|
type: Component,
|
|
@@ -924,6 +1046,7 @@ class DropdownComponent {
|
|
|
924
1046
|
this.injector = inject(Injector);
|
|
925
1047
|
this.destroyRef = inject(DestroyRef);
|
|
926
1048
|
this.translate = inject(TranslateService);
|
|
1049
|
+
this.labelLookupService = inject(LookupLabelResolutionService);
|
|
927
1050
|
this.dataProvider = input(...(ngDevMode ? [undefined, { debugName: "dataProvider" }] : []));
|
|
928
1051
|
this.options = input([], ...(ngDevMode ? [{ debugName: "options" }] : []));
|
|
929
1052
|
this.optionsTrackProperty = input(...(ngDevMode ? [undefined, { debugName: "optionsTrackProperty" }] : []));
|
|
@@ -1097,6 +1220,11 @@ class DropdownComponent {
|
|
|
1097
1220
|
.subscribe({
|
|
1098
1221
|
next: res => {
|
|
1099
1222
|
this.fetchedItems = res;
|
|
1223
|
+
const dataProvider = this.dataProvider();
|
|
1224
|
+
const optionsValueProperty = this.optionsValueProperty();
|
|
1225
|
+
if (dataProvider && optionsValueProperty) {
|
|
1226
|
+
res.forEach(item => this.labelLookupService.storeEntry(dataProvider, optionsValueProperty, item[optionsValueProperty], item));
|
|
1227
|
+
}
|
|
1100
1228
|
this.setItems(res, query);
|
|
1101
1229
|
this._loading.set(false);
|
|
1102
1230
|
this.selectFirstItem(); // only selects first item if selectFirstItemInput is set accordingly
|
|
@@ -1266,7 +1394,7 @@ class DropdownComponent {
|
|
|
1266
1394
|
}
|
|
1267
1395
|
}
|
|
1268
1396
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: DropdownComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1269
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: DropdownComponent, isStandalone: true, selector: "mng-dropdown", inputs: { dataProvider: { classPropertyName: "dataProvider", publicName: "dataProvider", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: false, transformFunction: null }, optionsTrackProperty: { classPropertyName: "optionsTrackProperty", publicName: "optionsTrackProperty", isSignal: true, isRequired: false, transformFunction: null }, optionsLabelPropertyInit: { classPropertyName: "optionsLabelPropertyInit", publicName: "optionsLabelProperty", isSignal: true, isRequired: false, transformFunction: null }, optionsLabelTranslate: { classPropertyName: "optionsLabelTranslate", publicName: "optionsLabelTranslate", isSignal: true, isRequired: false, transformFunction: null }, optionsValuePropertyInput: { classPropertyName: "optionsValuePropertyInput", publicName: "optionsValueProperty", isSignal: true, isRequired: false, transformFunction: null }, optionsDisabledProperty: { classPropertyName: "optionsDisabledProperty", publicName: "optionsDisabledProperty", isSignal: true, isRequired: false, transformFunction: null }, multiselect: { classPropertyName: "multiselect", publicName: "multiselect", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, showClear: { classPropertyName: "showClear", publicName: "showClear", isSignal: true, isRequired: false, transformFunction: null }, selectFirstItemInput: { classPropertyName: "selectFirstItemInput", publicName: "selectFirstItem", isSignal: true, isRequired: false, transformFunction: null }, className: { classPropertyName: "className", publicName: "className", isSignal: true, isRequired: false, transformFunction: null }, dropdownClassName: { classPropertyName: "dropdownClassName", publicName: "dropdownClassName", isSignal: true, isRequired: false, transformFunction: null }, changeValueOnBlur: { classPropertyName: "changeValueOnBlur", publicName: "changeValueOnBlur", isSignal: true, isRequired: false, transformFunction: null }, loadingInput: { classPropertyName: "loadingInput", publicName: "loading", isSignal: true, isRequired: false, transformFunction: null }, disabledInput: { classPropertyName: "disabledInput", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, allowInput: { classPropertyName: "allowInput", publicName: "allowInput", isSignal: true, isRequired: false, transformFunction: null }, appendTo: { classPropertyName: "appendTo", publicName: "appendTo", isSignal: true, isRequired: false, transformFunction: null }, templates: { classPropertyName: "templates", publicName: "templates", isSignal: true, isRequired: false, transformFunction: null }, inlineSearch: { classPropertyName: "inlineSearch", publicName: "inlineSearch", isSignal: true, isRequired: false, transformFunction: null }, searchTrim: { classPropertyName: "searchTrim", publicName: "searchTrim", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valueChange: "valueChange", blur: "blur" }, providers: [DROPDOWN_VALUE_ACCESSOR], viewQueries: [{ propertyName: "primeSelect", first: true, predicate: Select, descendants: true, isSignal: true }, { propertyName: "primeMultiselect", first: true, predicate: MultiSelect, descendants: true, isSignal: true }], ngImport: i0, template: "<p-inputgroup>\n @for (pt of prependTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"pt.template\"></ng-container>\n </p-inputgroup-addon>\n }\n @if (!multiselect()) {\n <p-select\n [(ngModel)]=\"ngModelValue\"\n [placeholder]=\"placeholder()\"\n [dataKey]=\"optionsTrackProperty()\"\n [optionLabel]=\"optionsLabelProperty()\"\n [optionValue]=\"optionsValueProperty()\"\n [optionDisabled]=\"optionsDisabledProperty()\"\n [options]=\"items()\"\n [showClear]=\"showClear()\"\n [editable]=\"allowInput()\"\n [styleClass]=\"className()\"\n [panelStyleClass]=\"dropdownClassName()\"\n [disabled]=\"disabled()\"\n [filter]=\"inlineSearch() && !allowInput()\"\n [filterBy]=\"optionsLabelProperty()\"\n (onBlur)=\"onDropdownBlur($event)\"\n (onChange)=\"onDropdownChange($event)\"\n (onShow)=\"onDropdownPanelShow()\"\n (onHide)=\"onDropdownPanelHide()\"\n (onFocus)=\"onFocus()\"\n [dropdownIcon]=\"loading() ? 'pi pi-spinner pi-spin' : 'pi pi-chevron-down'\"\n [appendTo]=\"appendTo()\">\n </p-select>\n } @else {\n <p-multiSelect\n [ngModel]=\"ngModelValue()\"\n [maxSelectedLabels]=\"1\"\n [selectedItemsLabel]=\"'mngDropdown.multiselectOverMaxDisplayLimit' | translate\"\n [placeholder]=\"placeholder()\"\n [dataKey]=\"optionsTrackProperty()\"\n [optionLabel]=\"optionsLabelProperty()\"\n [optionValue]=\"optionsValueProperty()\"\n [optionDisabled]=\"optionsDisabledProperty()\"\n [options]=\"items()\"\n [styleClass]=\"className()\"\n [panelStyleClass]=\"dropdownClassName()\"\n [filter]=\"true\"\n [showToggleAll]=\"false\"\n [disabled]=\"disabled()\"\n (onChange)=\"onMultiselectChange($event)\"\n (onPanelHide)=\"onMultiselectPanelHide()\"\n (onBlur)=\"onMultiselectBlur($event)\"\n (onFocus)=\"onFocus()\"\n appendTo=\"body\">\n </p-multiSelect>\n }\n @for (at of appendTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"at.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</p-inputgroup>\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: "component", type: Select, selector: "p-select", inputs: ["id", "scrollHeight", "filter", "panelStyle", "styleClass", "panelStyleClass", "readonly", "editable", "tabindex", "placeholder", "loadingIcon", "filterPlaceholder", "filterLocale", "inputId", "dataKey", "filterBy", "filterFields", "autofocus", "resetFilterOnHide", "checkmark", "dropdownIcon", "loading", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "group", "showClear", "emptyFilterMessage", "emptyMessage", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "ariaLabel", "ariaLabelledBy", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "focusOnHover", "selectOnFocus", "autoOptionFocus", "autofocusFilter", "filterValue", "options", "appendTo", "motionOptions"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onShow", "onHide", "onClear", "onLazyLoad"] }, { kind: "component", type: MultiSelect, selector: "p-multiSelect, p-multiselect, p-multi-select", inputs: ["id", "ariaLabel", "styleClass", "panelStyle", "panelStyleClass", "inputId", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "dataKey", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "chipIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "placeholder", "options", "filterValue", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus", "highlightOnSelect", "size", "variant", "fluid", "appendTo", "motionOptions"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "component", type: InputGroup, selector: "p-inputgroup, p-inputGroup, p-input-group", inputs: ["styleClass"] }, { kind: "component", type: InputGroupAddon, selector: "p-inputgroup-addon, p-inputGroupAddon", inputs: ["style", "styleClass"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1397
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: DropdownComponent, isStandalone: true, selector: "mng-dropdown", inputs: { dataProvider: { classPropertyName: "dataProvider", publicName: "dataProvider", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: false, transformFunction: null }, optionsTrackProperty: { classPropertyName: "optionsTrackProperty", publicName: "optionsTrackProperty", isSignal: true, isRequired: false, transformFunction: null }, optionsLabelPropertyInit: { classPropertyName: "optionsLabelPropertyInit", publicName: "optionsLabelProperty", isSignal: true, isRequired: false, transformFunction: null }, optionsLabelTranslate: { classPropertyName: "optionsLabelTranslate", publicName: "optionsLabelTranslate", isSignal: true, isRequired: false, transformFunction: null }, optionsValuePropertyInput: { classPropertyName: "optionsValuePropertyInput", publicName: "optionsValueProperty", isSignal: true, isRequired: false, transformFunction: null }, optionsDisabledProperty: { classPropertyName: "optionsDisabledProperty", publicName: "optionsDisabledProperty", isSignal: true, isRequired: false, transformFunction: null }, multiselect: { classPropertyName: "multiselect", publicName: "multiselect", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, showClear: { classPropertyName: "showClear", publicName: "showClear", isSignal: true, isRequired: false, transformFunction: null }, selectFirstItemInput: { classPropertyName: "selectFirstItemInput", publicName: "selectFirstItem", isSignal: true, isRequired: false, transformFunction: null }, className: { classPropertyName: "className", publicName: "className", isSignal: true, isRequired: false, transformFunction: null }, dropdownClassName: { classPropertyName: "dropdownClassName", publicName: "dropdownClassName", isSignal: true, isRequired: false, transformFunction: null }, changeValueOnBlur: { classPropertyName: "changeValueOnBlur", publicName: "changeValueOnBlur", isSignal: true, isRequired: false, transformFunction: null }, loadingInput: { classPropertyName: "loadingInput", publicName: "loading", isSignal: true, isRequired: false, transformFunction: null }, disabledInput: { classPropertyName: "disabledInput", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, allowInput: { classPropertyName: "allowInput", publicName: "allowInput", isSignal: true, isRequired: false, transformFunction: null }, appendTo: { classPropertyName: "appendTo", publicName: "appendTo", isSignal: true, isRequired: false, transformFunction: null }, templates: { classPropertyName: "templates", publicName: "templates", isSignal: true, isRequired: false, transformFunction: null }, inlineSearch: { classPropertyName: "inlineSearch", publicName: "inlineSearch", isSignal: true, isRequired: false, transformFunction: null }, searchTrim: { classPropertyName: "searchTrim", publicName: "searchTrim", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valueChange: "valueChange", blur: "blur" }, providers: [DROPDOWN_VALUE_ACCESSOR], viewQueries: [{ propertyName: "primeSelect", first: true, predicate: Select, descendants: true, isSignal: true }, { propertyName: "primeMultiselect", first: true, predicate: MultiSelect, descendants: true, isSignal: true }], ngImport: i0, template: "<p-inputgroup>\n @for (pt of prependTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"pt.template\"></ng-container>\n </p-inputgroup-addon>\n }\n @if (!multiselect()) {\n <p-select\n [(ngModel)]=\"ngModelValue\"\n [placeholder]=\"placeholder()\"\n [dataKey]=\"optionsTrackProperty()\"\n [optionLabel]=\"optionsLabelProperty()\"\n [optionValue]=\"optionsValueProperty()\"\n [optionDisabled]=\"optionsDisabledProperty()\"\n [options]=\"items()\"\n [showClear]=\"showClear()\"\n [editable]=\"allowInput()\"\n [styleClass]=\"className()\"\n [panelStyleClass]=\"dropdownClassName()\"\n [disabled]=\"disabled()\"\n [filter]=\"inlineSearch() && !allowInput()\"\n [filterBy]=\"optionsLabelProperty()\"\n (onBlur)=\"onDropdownBlur($event)\"\n (onChange)=\"onDropdownChange($event)\"\n (onShow)=\"onDropdownPanelShow()\"\n (onHide)=\"onDropdownPanelHide()\"\n (onFocus)=\"onFocus()\"\n [dropdownIcon]=\"loading() ? 'pi pi-spinner pi-spin' : 'pi pi-chevron-down'\"\n [appendTo]=\"appendTo()\">\n </p-select>\n } @else {\n <p-multiSelect\n [ngModel]=\"ngModelValue()\"\n [maxSelectedLabels]=\"1\"\n [selectedItemsLabel]=\"'mngDropdown.multiselectOverMaxDisplayLimit' | translate\"\n [placeholder]=\"placeholder()\"\n [dataKey]=\"optionsTrackProperty()\"\n [optionLabel]=\"optionsLabelProperty()\"\n [optionValue]=\"optionsValueProperty()\"\n [optionDisabled]=\"optionsDisabledProperty()\"\n [options]=\"items()\"\n [styleClass]=\"className()\"\n [panelStyleClass]=\"dropdownClassName()\"\n [filter]=\"true\"\n [showToggleAll]=\"false\"\n [disabled]=\"disabled()\"\n (onChange)=\"onMultiselectChange($event)\"\n (onPanelHide)=\"onMultiselectPanelHide()\"\n (onBlur)=\"onMultiselectBlur($event)\"\n (onFocus)=\"onFocus()\"\n appendTo=\"body\">\n </p-multiSelect>\n }\n @for (at of appendTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"at.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</p-inputgroup>\n", dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: Select, selector: "p-select", inputs: ["id", "scrollHeight", "filter", "panelStyle", "styleClass", "panelStyleClass", "readonly", "editable", "tabindex", "placeholder", "loadingIcon", "filterPlaceholder", "filterLocale", "inputId", "dataKey", "filterBy", "filterFields", "autofocus", "resetFilterOnHide", "checkmark", "dropdownIcon", "loading", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "group", "showClear", "emptyFilterMessage", "emptyMessage", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "ariaLabel", "ariaLabelledBy", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "focusOnHover", "selectOnFocus", "autoOptionFocus", "autofocusFilter", "filterValue", "options", "appendTo", "motionOptions"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onShow", "onHide", "onClear", "onLazyLoad"] }, { kind: "component", type: MultiSelect, selector: "p-multiSelect, p-multiselect, p-multi-select", inputs: ["id", "ariaLabel", "styleClass", "panelStyle", "panelStyleClass", "inputId", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "dataKey", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "chipIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "placeholder", "options", "filterValue", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus", "highlightOnSelect", "size", "variant", "fluid", "appendTo", "motionOptions"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "component", type: InputGroup, selector: "p-inputgroup, p-inputGroup, p-input-group", inputs: ["styleClass"] }, { kind: "component", type: InputGroupAddon, selector: "p-inputgroup-addon, p-inputGroupAddon", inputs: ["style", "styleClass"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1270
1398
|
}
|
|
1271
1399
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: DropdownComponent, decorators: [{
|
|
1272
1400
|
type: Component,
|
|
@@ -1383,7 +1511,7 @@ class NumberRangeComponent {
|
|
|
1383
1511
|
this.onChangeFn([fromDate, toDate]);
|
|
1384
1512
|
}
|
|
1385
1513
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: NumberRangeComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1386
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: NumberRangeComponent, isStandalone: true, selector: "mng-number-range", inputs: { placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, useGrouping: { classPropertyName: "useGrouping", publicName: "useGrouping", isSignal: true, isRequired: false, transformFunction: null }, minFractionDigits: { classPropertyName: "minFractionDigits", publicName: "minFractionDigits", isSignal: true, isRequired: false, transformFunction: null }, maxFractionDigits: { classPropertyName: "maxFractionDigits", publicName: "maxFractionDigits", 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 }, vertical: { classPropertyName: "vertical", publicName: "vertical", isSignal: true, isRequired: false, transformFunction: null }, templates: { classPropertyName: "templates", publicName: "templates", isSignal: true, isRequired: false, transformFunction: null }, className: { classPropertyName: "className", publicName: "className", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { keyDown: "keyDown" }, providers: [NUMBER_RANGE_VALUE_ACCESSOR, NUMBER_RANGE_VALIDATOR], ngImport: i0, template: "<div class=\"flex gap-1\" [class.flex-col]=\"vertical()\">\n <p-inputgroup>\n <ng-container *ngTemplateOutlet=\"prependAddons\"></ng-container>\n <p-inputNumber\n [formControl]=\"fromCtrl\"\n [placeholder]=\"placeholder() + ' ' + ('mngTable.filterRangeFrom' | translate)\"\n [useGrouping]=\"useGrouping()\"\n [minFractionDigits]=\"minFractionDigits()\"\n [maxFractionDigits]=\"maxFractionDigits()\"\n [max]=\"toCtrl.value\"\n [inputStyleClass]=\"className()\"\n (onKeyDown)=\"onKeyDown($event)\"\n (onBlur)=\"onBlur()\" />\n <ng-container *ngTemplateOutlet=\"appendAddons\"></ng-container>\n </p-inputgroup>\n <p-inputgroup>\n <ng-container *ngTemplateOutlet=\"prependAddons\"></ng-container>\n <p-inputNumber\n [formControl]=\"toCtrl\"\n [placeholder]=\"placeholder() + ' ' + ('mngTable.filterRangeTo' | translate)\"\n [useGrouping]=\"useGrouping()\"\n [minFractionDigits]=\"minFractionDigits()\"\n [maxFractionDigits]=\"maxFractionDigits()\"\n [min]=\"fromCtrl.value\"\n [inputStyleClass]=\"className()\"\n (onKeyDown)=\"onKeyDown($event)\"\n (onBlur)=\"onBlur()\" />\n <ng-container *ngTemplateOutlet=\"appendAddons\"></ng-container>\n </p-inputgroup>\n</div>\n\n<ng-template #prependAddons>\n @for (pt of prependTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"pt.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</ng-template>\n<ng-template #appendAddons>\n @for (at of appendTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"at.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</ng-template>\n", styles: ["mng-number-range.ng-dirty.ng-invalid>div>p-inputnumber .p-inputtext{border-color:var(--p-inputtext-invalid-border-color, #f87171)}\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: "component", type: InputNumber, selector: "p-inputNumber, p-inputnumber, p-input-number", inputs: ["showButtons", "format", "buttonLayout", "inputId", "styleClass", "placeholder", "tabindex", "title", "ariaLabelledBy", "ariaDescribedBy", "ariaLabel", "ariaRequired", "autocomplete", "incrementButtonClass", "decrementButtonClass", "incrementButtonIcon", "decrementButtonIcon", "readonly", "allowEmpty", "locale", "localeMatcher", "mode", "currency", "currencyDisplay", "useGrouping", "minFractionDigits", "maxFractionDigits", "prefix", "suffix", "inputStyle", "inputStyleClass", "showClear", "autofocus"], outputs: ["onInput", "onFocus", "onBlur", "onKeyDown", "onClear"] }, { kind: "component", type: InputGroup, selector: "p-inputgroup, p-inputGroup, p-input-group", inputs: ["styleClass"] }, { kind: "component", type: InputGroupAddon, selector: "p-inputgroup-addon, p-inputGroupAddon", inputs: ["style", "styleClass"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
1514
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: NumberRangeComponent, isStandalone: true, selector: "mng-number-range", inputs: { placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, useGrouping: { classPropertyName: "useGrouping", publicName: "useGrouping", isSignal: true, isRequired: false, transformFunction: null }, minFractionDigits: { classPropertyName: "minFractionDigits", publicName: "minFractionDigits", isSignal: true, isRequired: false, transformFunction: null }, maxFractionDigits: { classPropertyName: "maxFractionDigits", publicName: "maxFractionDigits", 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 }, vertical: { classPropertyName: "vertical", publicName: "vertical", isSignal: true, isRequired: false, transformFunction: null }, templates: { classPropertyName: "templates", publicName: "templates", isSignal: true, isRequired: false, transformFunction: null }, className: { classPropertyName: "className", publicName: "className", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { keyDown: "keyDown" }, providers: [NUMBER_RANGE_VALUE_ACCESSOR, NUMBER_RANGE_VALIDATOR], ngImport: i0, template: "<div class=\"flex gap-1\" [class.flex-col]=\"vertical()\">\n <p-inputgroup>\n <ng-container *ngTemplateOutlet=\"prependAddons\"></ng-container>\n <p-inputNumber\n [formControl]=\"fromCtrl\"\n [placeholder]=\"placeholder() + ' ' + ('mngTable.filterRangeFrom' | translate)\"\n [useGrouping]=\"useGrouping()\"\n [minFractionDigits]=\"minFractionDigits()\"\n [maxFractionDigits]=\"maxFractionDigits()\"\n [max]=\"toCtrl.value\"\n [inputStyleClass]=\"className()\"\n (onKeyDown)=\"onKeyDown($event)\"\n (onBlur)=\"onBlur()\" />\n <ng-container *ngTemplateOutlet=\"appendAddons\"></ng-container>\n </p-inputgroup>\n <p-inputgroup>\n <ng-container *ngTemplateOutlet=\"prependAddons\"></ng-container>\n <p-inputNumber\n [formControl]=\"toCtrl\"\n [placeholder]=\"placeholder() + ' ' + ('mngTable.filterRangeTo' | translate)\"\n [useGrouping]=\"useGrouping()\"\n [minFractionDigits]=\"minFractionDigits()\"\n [maxFractionDigits]=\"maxFractionDigits()\"\n [min]=\"fromCtrl.value\"\n [inputStyleClass]=\"className()\"\n (onKeyDown)=\"onKeyDown($event)\"\n (onBlur)=\"onBlur()\" />\n <ng-container *ngTemplateOutlet=\"appendAddons\"></ng-container>\n </p-inputgroup>\n</div>\n\n<ng-template #prependAddons>\n @for (pt of prependTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"pt.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</ng-template>\n<ng-template #appendAddons>\n @for (at of appendTemplates(); track $index) {\n <p-inputgroup-addon>\n <ng-container *ngTemplateOutlet=\"at.template\"></ng-container>\n </p-inputgroup-addon>\n }\n</ng-template>\n", styles: ["mng-number-range.ng-dirty.ng-invalid>div>p-inputnumber .p-inputtext{border-color:var(--p-inputtext-invalid-border-color, #f87171)}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: InputNumber, selector: "p-inputNumber, p-inputnumber, p-input-number", inputs: ["showButtons", "format", "buttonLayout", "inputId", "styleClass", "placeholder", "tabindex", "title", "ariaLabelledBy", "ariaDescribedBy", "ariaLabel", "ariaRequired", "autocomplete", "incrementButtonClass", "decrementButtonClass", "incrementButtonIcon", "decrementButtonIcon", "readonly", "allowEmpty", "locale", "localeMatcher", "mode", "currency", "currencyDisplay", "useGrouping", "minFractionDigits", "maxFractionDigits", "prefix", "suffix", "inputStyle", "inputStyleClass", "showClear", "autofocus"], outputs: ["onInput", "onFocus", "onBlur", "onKeyDown", "onClear"] }, { kind: "component", type: InputGroup, selector: "p-inputgroup, p-inputGroup, p-input-group", inputs: ["styleClass"] }, { kind: "component", type: InputGroupAddon, selector: "p-inputgroup-addon, p-inputGroupAddon", inputs: ["style", "styleClass"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
1387
1515
|
}
|
|
1388
1516
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: NumberRangeComponent, decorators: [{
|
|
1389
1517
|
type: Component,
|
|
@@ -1625,11 +1753,41 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
1625
1753
|
}]
|
|
1626
1754
|
}], propDecorators: { name: [{ type: i0.Input, args: [{ isSignal: true, alias: "name", required: true }] }] } });
|
|
1627
1755
|
|
|
1756
|
+
/**
|
|
1757
|
+
* Prepares providers for usage of the tableview functionalities.
|
|
1758
|
+
*
|
|
1759
|
+
* @returns {CommonsFeature} The `CommonsFeature` object with the layout configuration.
|
|
1760
|
+
*/
|
|
1761
|
+
function withForm(config) {
|
|
1762
|
+
return {
|
|
1763
|
+
type: CommonsFeatureTypeEnum.Form,
|
|
1764
|
+
providers: [
|
|
1765
|
+
{
|
|
1766
|
+
provide: COMMONS_FORM_FEATURE_CONFIG_IT,
|
|
1767
|
+
useValue: config
|
|
1768
|
+
}
|
|
1769
|
+
]
|
|
1770
|
+
};
|
|
1771
|
+
}
|
|
1772
|
+
/**
|
|
1773
|
+
* Provides a list of providers for configuring a form feature. Useful for lazy-loading form chunk in child (lazy loaded routes).
|
|
1774
|
+
*
|
|
1775
|
+
* @param {FormFeatureConfig} [config] - An optional configuration object for the form feature.
|
|
1776
|
+
*/
|
|
1777
|
+
function provideFormChild(config) {
|
|
1778
|
+
return [
|
|
1779
|
+
{
|
|
1780
|
+
provide: COMMONS_FORM_FEATURE_CONFIG_IT,
|
|
1781
|
+
useValue: config
|
|
1782
|
+
}
|
|
1783
|
+
];
|
|
1784
|
+
}
|
|
1785
|
+
|
|
1628
1786
|
// components
|
|
1629
1787
|
|
|
1630
1788
|
/**
|
|
1631
1789
|
* Generated bundle index. Do not edit.
|
|
1632
1790
|
*/
|
|
1633
1791
|
|
|
1634
|
-
export { AUTOCOMPLETE_VALUE_ACCESSOR, AutocompleteComponent, AutocompleteTemplateDirective, DATETIME_PICKER_VALIDATOR, DATETIME_PICKER_VALUE_ACCESSOR, DATE_RANGE_VALIDATOR, DATE_RANGE_VALUE_ACCESSOR, DROPDOWN_VALUE_ACCESSOR, DateRangeComponent, DateRangeTemplateDirective, DatetimePickerComponent, DatetimePickerTemplateDirective, DropdownComponent, DropdownTemplateDirective, InputEmptyValueDirective, InputTrimDirective, NUMBER_RANGE_VALIDATOR, NUMBER_RANGE_VALUE_ACCESSOR, NumberRangeComponent, NumberRangeTemplateDirective };
|
|
1792
|
+
export { AUTOCOMPLETE_VALUE_ACCESSOR, AutocompleteComponent, AutocompleteTemplateDirective, DATETIME_PICKER_VALIDATOR, DATETIME_PICKER_VALUE_ACCESSOR, DATE_RANGE_VALIDATOR, DATE_RANGE_VALUE_ACCESSOR, DROPDOWN_VALUE_ACCESSOR, DateRangeComponent, DateRangeTemplateDirective, DatetimePickerComponent, DatetimePickerTemplateDirective, DropdownComponent, DropdownTemplateDirective, InputEmptyValueDirective, InputTrimDirective, LookupLabelResolutionService, NUMBER_RANGE_VALIDATOR, NUMBER_RANGE_VALUE_ACCESSOR, NumberRangeComponent, NumberRangeTemplateDirective, provideFormChild, withForm };
|
|
1635
1793
|
//# sourceMappingURL=mediusinc-mng-commons-form.mjs.map
|