@acpaas-ui/ngx-forms 6.0.0-beta.0 → 6.0.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/README.md +9 -9
- package/esm2020/lib/auto-complete/auto-complete.module.mjs +4 -5
- package/esm2020/lib/auto-complete/components/auto-complete/auto-complete.component.mjs +41 -64
- package/esm2020/lib/datepicker/components/datepicker/datepicker.component.mjs +3 -4
- package/esm2020/lib/datepicker/datepicker.conf.mjs +1 -2
- package/esm2020/lib/search-filter/components/search-filter/search-filter.component.mjs +18 -11
- package/esm2020/lib/timepicker/components/timepicker/timepicker.component.mjs +2 -2
- package/esm2020/public-api.mjs +1 -2
- package/fesm2015/acpaas-ui-ngx-forms.mjs +63 -130
- package/fesm2015/acpaas-ui-ngx-forms.mjs.map +1 -1
- package/fesm2020/acpaas-ui-ngx-forms.mjs +63 -120
- package/fesm2020/acpaas-ui-ngx-forms.mjs.map +1 -1
- package/lib/auto-complete/auto-complete.module.d.ts +1 -2
- package/lib/auto-complete/components/auto-complete/auto-complete.component.d.ts +1 -2
- package/lib/datepicker/components/datepicker/datepicker.component.d.ts +1 -5
- package/lib/datepicker/datepicker.conf.d.ts +0 -1
- package/lib/search-filter/components/search-filter/search-filter.component.d.ts +2 -2
- package/package.json +8 -11
- package/public-api.d.ts +0 -1
- package/esm2020/lib/mask/directives/mask.directive.mjs +0 -25
- package/esm2020/lib/mask/mask.module.mjs +0 -20
- package/esm2020/lib/mask/public-api.mjs +0 -3
- package/lib/mask/directives/mask.directive.d.ts +0 -11
- package/lib/mask/mask.module.d.ts +0 -8
- package/lib/mask/public-api.d.ts +0 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import {
|
|
2
|
+
import { Injectable, EventEmitter, TemplateRef, forwardRef, Component, Input, Output, ViewChild, ContentChild, NgModule, InjectionToken, ChangeDetectionStrategy, Inject, HostBinding, HostListener } from '@angular/core';
|
|
3
3
|
import * as i1 from '@angular/common';
|
|
4
4
|
import { CommonModule } from '@angular/common';
|
|
5
5
|
import * as i1$1 from '@angular/forms';
|
|
@@ -8,61 +8,17 @@ import * as i4 from '@acpaas-ui/ngx-flyout';
|
|
|
8
8
|
import { FlyoutDirective, FlyoutZoneDirective, FlyoutModule, FlyoutSize } from '@acpaas-ui/ngx-flyout';
|
|
9
9
|
import * as i5 from '@acpaas-ui/ngx-selectable-list';
|
|
10
10
|
import { SelectableListModule } from '@acpaas-ui/ngx-selectable-list';
|
|
11
|
-
import Inputmask from 'inputmask';
|
|
12
11
|
import { get, isEqual, debounce } from 'lodash-es';
|
|
13
12
|
import { Subject, Observable } from 'rxjs';
|
|
14
13
|
import { takeUntil } from 'rxjs/operators';
|
|
15
|
-
import { DateHelper } from '@acpaas-ui/
|
|
14
|
+
import { DateHelper, IntervalBuilder } from '@acpaas-ui/ngx-utils';
|
|
16
15
|
import * as i1$2 from '@acpaas-ui/ngx-calendar';
|
|
17
16
|
import { CALENDAR_DEFAULT_MONTH_LABELS, CALENDAR_DEFAULT_WEEKDAY_LABELS, CALENDAR_MONTH_LABELS, CALENDAR_WEEKDAY_LABELS, CalendarModule } from '@acpaas-ui/ngx-calendar';
|
|
18
|
-
import { IntervalBuilder } from '@acpaas-ui/ngx-utils';
|
|
19
17
|
import * as i4$1 from '@acpaas-ui/ngx-icon';
|
|
20
18
|
import { IconModule } from '@acpaas-ui/ngx-icon';
|
|
21
19
|
import * as i2 from '@acpaas-ui/ngx-progress-bar';
|
|
22
20
|
import { ProgressBarModule } from '@acpaas-ui/ngx-progress-bar';
|
|
23
21
|
|
|
24
|
-
class MaskDirective {
|
|
25
|
-
constructor(ref) {
|
|
26
|
-
this.ref = ref;
|
|
27
|
-
}
|
|
28
|
-
ngOnChanges() {
|
|
29
|
-
this.setMask(this.auiMask);
|
|
30
|
-
}
|
|
31
|
-
setMask(mask) {
|
|
32
|
-
Inputmask(mask).mask(this.ref.nativeElement);
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
/** @nocollapse */ MaskDirective.ɵfac = function MaskDirective_Factory(t) { return new (t || MaskDirective)(i0.ɵɵdirectiveInject(i0.ElementRef)); };
|
|
36
|
-
/** @nocollapse */ MaskDirective.ɵdir = /** @pureOrBreakMyCode */ i0.ɵɵdefineDirective({ type: MaskDirective, selectors: [["", "auiMask", ""]], inputs: { auiMask: "auiMask" }, features: [i0.ɵɵNgOnChangesFeature] });
|
|
37
|
-
(function () {
|
|
38
|
-
(typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(MaskDirective, [{
|
|
39
|
-
type: Directive,
|
|
40
|
-
args: [{
|
|
41
|
-
selector: '[auiMask]',
|
|
42
|
-
}]
|
|
43
|
-
}], function () { return [{ type: i0.ElementRef }]; }, { auiMask: [{
|
|
44
|
-
type: Input
|
|
45
|
-
}] });
|
|
46
|
-
})();
|
|
47
|
-
|
|
48
|
-
class MaskModule {
|
|
49
|
-
}
|
|
50
|
-
/** @nocollapse */ MaskModule.ɵfac = function MaskModule_Factory(t) { return new (t || MaskModule)(); };
|
|
51
|
-
/** @nocollapse */ MaskModule.ɵmod = /** @pureOrBreakMyCode */ i0.ɵɵdefineNgModule({ type: MaskModule });
|
|
52
|
-
/** @nocollapse */ MaskModule.ɵinj = /** @pureOrBreakMyCode */ i0.ɵɵdefineInjector({ imports: [CommonModule] });
|
|
53
|
-
(function () {
|
|
54
|
-
(typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(MaskModule, [{
|
|
55
|
-
type: NgModule,
|
|
56
|
-
args: [{
|
|
57
|
-
imports: [CommonModule],
|
|
58
|
-
declarations: [MaskDirective],
|
|
59
|
-
exports: [MaskDirective],
|
|
60
|
-
providers: [],
|
|
61
|
-
}]
|
|
62
|
-
}], null, null);
|
|
63
|
-
})();
|
|
64
|
-
(function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(MaskModule, { declarations: [MaskDirective], imports: [CommonModule], exports: [MaskDirective] }); })();
|
|
65
|
-
|
|
66
22
|
class SearchService {
|
|
67
23
|
constructor() {
|
|
68
24
|
this.matchItemWithSearchString = (item, searchString) => {
|
|
@@ -95,99 +51,75 @@ class SearchService {
|
|
|
95
51
|
}], null, null);
|
|
96
52
|
})();
|
|
97
53
|
|
|
98
|
-
function
|
|
99
|
-
if (rf & 1) {
|
|
100
|
-
const _r4 = i0.ɵɵgetCurrentView();
|
|
101
|
-
i0.ɵɵelementStart(0, "input", 4);
|
|
102
|
-
i0.ɵɵlistener("focus", function AutoCompleteComponent_input_1_Template_input_focus_0_listener() { i0.ɵɵrestoreView(_r4); const ctx_r3 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r3.onFocus()); })("keyArrowDown", function AutoCompleteComponent_input_1_Template_input_keyArrowDown_0_listener() { i0.ɵɵrestoreView(_r4); const ctx_r5 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r5.onKeyArrowDown()); })("keyArrowUp", function AutoCompleteComponent_input_1_Template_input_keyArrowUp_0_listener() { i0.ɵɵrestoreView(_r4); const ctx_r6 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r6.onKeyArrowUp()); })("keyEnter", function AutoCompleteComponent_input_1_Template_input_keyEnter_0_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r7 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r7.onKeyEnter($event)); })("keyEscape", function AutoCompleteComponent_input_1_Template_input_keyEscape_0_listener() { i0.ɵɵrestoreView(_r4); const ctx_r8 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r8.onKeyEscape()); })("ngModelChange", function AutoCompleteComponent_input_1_Template_input_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r9 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r9.query = $event); })("ngModelChange", function AutoCompleteComponent_input_1_Template_input_ngModelChange_0_listener() { i0.ɵɵrestoreView(_r4); const ctx_r10 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r10.doSearch()); });
|
|
103
|
-
i0.ɵɵelementEnd();
|
|
104
|
-
}
|
|
105
|
-
if (rf & 2) {
|
|
106
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
107
|
-
i0.ɵɵproperty("ngModel", ctx_r0.query)("disabled", ctx_r0.isDisabled ? true : null)("id", ctx_r0.id)("placeholder", ctx_r0.placeholder)("autocomplete", ctx_r0.autoComplete);
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
function AutoCompleteComponent_input_2_Template(rf, ctx) {
|
|
54
|
+
function AutoCompleteComponent_div_2_span_1_Template(rf, ctx) {
|
|
111
55
|
if (rf & 1) {
|
|
112
|
-
|
|
113
|
-
i0.ɵɵ
|
|
114
|
-
i0.ɵɵ
|
|
115
|
-
i0.ɵɵelementEnd();
|
|
116
|
-
}
|
|
117
|
-
if (rf & 2) {
|
|
118
|
-
const ctx_r1 = i0.ɵɵnextContext();
|
|
119
|
-
i0.ɵɵproperty("ngModel", ctx_r1.query)("auiMask", ctx_r1.mask)("disabled", ctx_r1.isDisabled ? true : null)("id", ctx_r1.id)("placeholder", ctx_r1.placeholder)("autocomplete", ctx_r1.autoComplete);
|
|
120
|
-
}
|
|
121
|
-
}
|
|
122
|
-
function AutoCompleteComponent_div_3_span_1_Template(rf, ctx) {
|
|
123
|
-
if (rf & 1) {
|
|
124
|
-
i0.ɵɵelementStart(0, "span", 10);
|
|
125
|
-
i0.ɵɵelement(1, "span", 11);
|
|
126
|
-
i0.ɵɵelementStart(2, "span", 12);
|
|
56
|
+
i0.ɵɵelementStart(0, "span", 7);
|
|
57
|
+
i0.ɵɵelement(1, "span", 8);
|
|
58
|
+
i0.ɵɵelementStart(2, "span", 9);
|
|
127
59
|
i0.ɵɵtext(3);
|
|
128
60
|
i0.ɵɵelementEnd()();
|
|
129
61
|
}
|
|
130
62
|
if (rf & 2) {
|
|
131
|
-
const
|
|
63
|
+
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
132
64
|
i0.ɵɵadvance(3);
|
|
133
|
-
i0.ɵɵtextInterpolate(
|
|
65
|
+
i0.ɵɵtextInterpolate(ctx_r1.loadingText);
|
|
134
66
|
}
|
|
135
67
|
}
|
|
136
|
-
function
|
|
68
|
+
function AutoCompleteComponent_div_2_span_2_Template(rf, ctx) {
|
|
137
69
|
if (rf & 1) {
|
|
138
|
-
i0.ɵɵelementStart(0, "span",
|
|
70
|
+
i0.ɵɵelementStart(0, "span", 10);
|
|
139
71
|
i0.ɵɵtext(1);
|
|
140
72
|
i0.ɵɵelementEnd();
|
|
141
73
|
}
|
|
142
74
|
if (rf & 2) {
|
|
143
|
-
const
|
|
75
|
+
const ctx_r2 = i0.ɵɵnextContext(2);
|
|
144
76
|
i0.ɵɵadvance(1);
|
|
145
|
-
i0.ɵɵtextInterpolate(
|
|
77
|
+
i0.ɵɵtextInterpolate(ctx_r2.searchIncentiveText);
|
|
146
78
|
}
|
|
147
79
|
}
|
|
148
|
-
function
|
|
80
|
+
function AutoCompleteComponent_div_2_span_3_Template(rf, ctx) {
|
|
149
81
|
if (rf & 1) {
|
|
150
|
-
i0.ɵɵelementStart(0, "span",
|
|
82
|
+
i0.ɵɵelementStart(0, "span", 10);
|
|
151
83
|
i0.ɵɵtext(1);
|
|
152
84
|
i0.ɵɵelementEnd();
|
|
153
85
|
}
|
|
154
86
|
if (rf & 2) {
|
|
155
|
-
const
|
|
87
|
+
const ctx_r3 = i0.ɵɵnextContext(2);
|
|
156
88
|
i0.ɵɵadvance(1);
|
|
157
|
-
i0.ɵɵtextInterpolate(
|
|
89
|
+
i0.ɵɵtextInterpolate(ctx_r3.noResultsText);
|
|
158
90
|
}
|
|
159
91
|
}
|
|
160
|
-
function
|
|
92
|
+
function AutoCompleteComponent_div_2_aui_selectable_list_4_Template(rf, ctx) {
|
|
161
93
|
if (rf & 1) {
|
|
162
|
-
const
|
|
163
|
-
i0.ɵɵelementStart(0, "aui-selectable-list",
|
|
164
|
-
i0.ɵɵlistener("selected", function
|
|
94
|
+
const _r6 = i0.ɵɵgetCurrentView();
|
|
95
|
+
i0.ɵɵelementStart(0, "aui-selectable-list", 11);
|
|
96
|
+
i0.ɵɵlistener("selected", function AutoCompleteComponent_div_2_aui_selectable_list_4_Template_aui_selectable_list_selected_0_listener($event) { i0.ɵɵrestoreView(_r6); const ctx_r5 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r5.onSelect($event)); });
|
|
165
97
|
i0.ɵɵelementEnd();
|
|
166
98
|
}
|
|
167
99
|
if (rf & 2) {
|
|
168
|
-
const
|
|
169
|
-
i0.ɵɵproperty("index",
|
|
100
|
+
const ctx_r4 = i0.ɵɵnextContext(2);
|
|
101
|
+
i0.ɵɵproperty("index", ctx_r4.index)("itemTemplate", ctx_r4.template)("items", ctx_r4.results)("label", ctx_r4.label)("search", ctx_r4.query);
|
|
170
102
|
}
|
|
171
103
|
}
|
|
172
|
-
function
|
|
104
|
+
function AutoCompleteComponent_div_2_Template(rf, ctx) {
|
|
173
105
|
if (rf & 1) {
|
|
174
|
-
i0.ɵɵelementStart(0, "div",
|
|
175
|
-
i0.ɵɵtemplate(1,
|
|
176
|
-
i0.ɵɵtemplate(2,
|
|
177
|
-
i0.ɵɵtemplate(3,
|
|
178
|
-
i0.ɵɵtemplate(4,
|
|
106
|
+
i0.ɵɵelementStart(0, "div", 3);
|
|
107
|
+
i0.ɵɵtemplate(1, AutoCompleteComponent_div_2_span_1_Template, 4, 1, "span", 4);
|
|
108
|
+
i0.ɵɵtemplate(2, AutoCompleteComponent_div_2_span_2_Template, 2, 1, "span", 5);
|
|
109
|
+
i0.ɵɵtemplate(3, AutoCompleteComponent_div_2_span_3_Template, 2, 1, "span", 5);
|
|
110
|
+
i0.ɵɵtemplate(4, AutoCompleteComponent_div_2_aui_selectable_list_4_Template, 1, 5, "aui-selectable-list", 6);
|
|
179
111
|
i0.ɵɵelementEnd();
|
|
180
112
|
}
|
|
181
113
|
if (rf & 2) {
|
|
182
|
-
const
|
|
114
|
+
const ctx_r0 = i0.ɵɵnextContext();
|
|
183
115
|
i0.ɵɵadvance(1);
|
|
184
|
-
i0.ɵɵproperty("ngIf",
|
|
116
|
+
i0.ɵɵproperty("ngIf", ctx_r0.focused && ctx_r0.loadingText && ctx_r0.searching);
|
|
185
117
|
i0.ɵɵadvance(1);
|
|
186
|
-
i0.ɵɵproperty("ngIf",
|
|
118
|
+
i0.ɵɵproperty("ngIf", ctx_r0.focused && ctx_r0.searchIncentiveText && !ctx_r0.searching && !ctx_r0.query && !ctx_r0.results.length);
|
|
187
119
|
i0.ɵɵadvance(1);
|
|
188
|
-
i0.ɵɵproperty("ngIf",
|
|
120
|
+
i0.ɵɵproperty("ngIf", ctx_r0.focused && ctx_r0.noResultsText && !ctx_r0.searching && ctx_r0.query && !ctx_r0.results.length);
|
|
189
121
|
i0.ɵɵadvance(1);
|
|
190
|
-
i0.ɵɵproperty("ngIf",
|
|
122
|
+
i0.ɵɵproperty("ngIf", ctx_r0.results.length > 0 && !(ctx_r0.focused && ctx_r0.loadingText && ctx_r0.searching));
|
|
191
123
|
}
|
|
192
124
|
}
|
|
193
125
|
class AutoCompleteComponent {
|
|
@@ -198,7 +130,6 @@ class AutoCompleteComponent {
|
|
|
198
130
|
this.data = []; // The values to search in when remote search is disabled
|
|
199
131
|
this.remote = false; // Disable or enamble remote search
|
|
200
132
|
this.minCharacters = 0;
|
|
201
|
-
this.mask = null;
|
|
202
133
|
this.clearInvalid = false;
|
|
203
134
|
this.showAllByDefault = false;
|
|
204
135
|
this.autoComplete = 'off';
|
|
@@ -401,31 +332,30 @@ class AutoCompleteComponent {
|
|
|
401
332
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.flyout = _t.first);
|
|
402
333
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.flyoutZone = _t.first);
|
|
403
334
|
}
|
|
404
|
-
}, inputs: { id: "id", placeholder: "placeholder", description: "description", inputLabel: "inputLabel", results: "results", data: "data", remote: "remote", minCharacters: "minCharacters",
|
|
335
|
+
}, inputs: { id: "id", placeholder: "placeholder", description: "description", inputLabel: "inputLabel", results: "results", data: "data", remote: "remote", minCharacters: "minCharacters", clearInvalid: "clearInvalid", searchIncentiveText: "searchIncentiveText", loadingText: "loadingText", noResultsText: "noResultsText", showAllByDefault: "showAllByDefault", autoComplete: "autoComplete", label: "label", value: "value" }, outputs: { search: "search", select: "select" }, features: [i0.ɵɵProvidersFeature([
|
|
405
336
|
{
|
|
406
337
|
provide: NG_VALUE_ACCESSOR,
|
|
407
338
|
useExisting: forwardRef((() => AutoCompleteComponent)),
|
|
408
339
|
multi: true,
|
|
409
340
|
},
|
|
410
|
-
]), i0.ɵɵNgOnChangesFeature], decls:
|
|
341
|
+
]), i0.ɵɵNgOnChangesFeature], decls: 3, vars: 7, consts: [["aria-haspopup", "listbox", "auiFlyout", "", 1, "m-flyout", "m-flyout--scrollable", "m-flyout--full", "o-auto-complete", 3, "toggleClick", "closed"], ["aria-autocomplete", "list", "auiFlyoutAction", "", "auiSelectableActions", "", "type", "text", 1, "a-input", 3, "ngModel", "disabled", "id", "placeholder", "autocomplete", "focus", "keyArrowDown", "keyArrowUp", "keyEnter", "keyEscape", "ngModelChange"], ["auiFlyoutZone", "", 4, "ngIf"], ["auiFlyoutZone", ""], ["class", "a-spinner a-spinner--s u-margin-xs", "role", "alert", 4, "ngIf"], ["class", "o-auto-complete__info u-text-light u-margin-xs", 4, "ngIf"], [3, "index", "itemTemplate", "items", "label", "search", "selected", 4, "ngIf"], ["role", "alert", 1, "a-spinner", "a-spinner--s", "u-margin-xs"], [1, "a-spinner__circle"], [1, "a-spinner__text"], [1, "o-auto-complete__info", "u-text-light", "u-margin-xs"], [3, "index", "itemTemplate", "items", "label", "search", "selected"]], template: function AutoCompleteComponent_Template(rf, ctx) {
|
|
411
342
|
if (rf & 1) {
|
|
412
343
|
i0.ɵɵelementStart(0, "div", 0);
|
|
413
344
|
i0.ɵɵlistener("closed", function AutoCompleteComponent_Template_div_closed_0_listener() { return ctx.onFlyoutClosed(); });
|
|
414
|
-
i0.ɵɵ
|
|
415
|
-
i0.ɵɵ
|
|
416
|
-
i0.ɵɵ
|
|
345
|
+
i0.ɵɵelementStart(1, "input", 1);
|
|
346
|
+
i0.ɵɵlistener("focus", function AutoCompleteComponent_Template_input_focus_1_listener() { return ctx.onFocus(); })("keyArrowDown", function AutoCompleteComponent_Template_input_keyArrowDown_1_listener() { return ctx.onKeyArrowDown(); })("keyArrowUp", function AutoCompleteComponent_Template_input_keyArrowUp_1_listener() { return ctx.onKeyArrowUp(); })("keyEnter", function AutoCompleteComponent_Template_input_keyEnter_1_listener($event) { return ctx.onKeyEnter($event); })("keyEscape", function AutoCompleteComponent_Template_input_keyEscape_1_listener() { return ctx.onKeyEscape(); })("ngModelChange", function AutoCompleteComponent_Template_input_ngModelChange_1_listener($event) { return ctx.query = $event; })("ngModelChange", function AutoCompleteComponent_Template_input_ngModelChange_1_listener() { return ctx.doSearch(); });
|
|
347
|
+
i0.ɵɵelementEnd();
|
|
348
|
+
i0.ɵɵtemplate(2, AutoCompleteComponent_div_2_Template, 5, 4, "div", 2);
|
|
417
349
|
i0.ɵɵelementEnd();
|
|
418
350
|
}
|
|
419
351
|
if (rf & 2) {
|
|
420
352
|
i0.ɵɵproperty("toggleClick", false);
|
|
421
353
|
i0.ɵɵadvance(1);
|
|
422
|
-
i0.ɵɵproperty("
|
|
423
|
-
i0.ɵɵadvance(1);
|
|
424
|
-
i0.ɵɵproperty("ngIf", ctx.mask);
|
|
354
|
+
i0.ɵɵproperty("ngModel", ctx.query)("disabled", ctx.isDisabled ? true : null)("id", ctx.id)("placeholder", ctx.placeholder)("autocomplete", ctx.autoComplete);
|
|
425
355
|
i0.ɵɵadvance(1);
|
|
426
356
|
i0.ɵɵproperty("ngIf", !ctx.isDisabled);
|
|
427
357
|
}
|
|
428
|
-
}, dependencies: [i1.NgIf, i1$1.DefaultValueAccessor, i1$1.NgControlStatus, i1$1.NgModel, i4.FlyoutActionDirective, i4.FlyoutZoneDirective, i4.FlyoutDirective, i5.SelectableListComponent, i5.SelectableActionsDirective
|
|
358
|
+
}, dependencies: [i1.NgIf, i1$1.DefaultValueAccessor, i1$1.NgControlStatus, i1$1.NgModel, i4.FlyoutActionDirective, i4.FlyoutZoneDirective, i4.FlyoutDirective, i5.SelectableListComponent, i5.SelectableActionsDirective], styles: [".o-auto-complete[_ngcontent-%COMP%], .o-auto-complete__info[_ngcontent-%COMP%]{display:block}"] });
|
|
429
359
|
(function () {
|
|
430
360
|
(typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(AutoCompleteComponent, [{
|
|
431
361
|
type: Component,
|
|
@@ -435,7 +365,7 @@ class AutoCompleteComponent {
|
|
|
435
365
|
useExisting: forwardRef((() => AutoCompleteComponent)),
|
|
436
366
|
multi: true,
|
|
437
367
|
},
|
|
438
|
-
], template: "<div\n (closed)=\"onFlyoutClosed()\"\n [toggleClick]=\"false\"\n aria-haspopup=\"listbox\"\n auiFlyout\n class=\"m-flyout m-flyout--scrollable m-flyout--full o-auto-complete\"\n>\n <input\n (focus)=\"onFocus()\"\n (keyArrowDown)=\"onKeyArrowDown()\"\n (keyArrowUp)=\"onKeyArrowUp()\"\n (keyEnter)=\"onKeyEnter($event)\"\n (keyEscape)=\"onKeyEscape()\"\n [(ngModel)]=\"query\"\n (ngModelChange)=\"doSearch()\"\n
|
|
368
|
+
], template: "<div\n (closed)=\"onFlyoutClosed()\"\n [toggleClick]=\"false\"\n aria-haspopup=\"listbox\"\n auiFlyout\n class=\"m-flyout m-flyout--scrollable m-flyout--full o-auto-complete\"\n>\n <input\n (focus)=\"onFocus()\"\n (keyArrowDown)=\"onKeyArrowDown()\"\n (keyArrowUp)=\"onKeyArrowUp()\"\n (keyEnter)=\"onKeyEnter($event)\"\n (keyEscape)=\"onKeyEscape()\"\n [(ngModel)]=\"query\"\n (ngModelChange)=\"doSearch()\"\n [disabled]=\"isDisabled ? true : null\"\n [id]=\"id\"\n [placeholder]=\"placeholder\"\n aria-autocomplete=\"list\"\n auiFlyoutAction\n auiSelectableActions\n [autocomplete]=\"autoComplete\"\n type=\"text\"\n class=\"a-input\"\n />\n <div *ngIf=\"!isDisabled\" auiFlyoutZone>\n <span *ngIf=\"focused && loadingText && searching\" class=\"a-spinner a-spinner--s u-margin-xs\" role=\"alert\">\n <span class=\"a-spinner__circle\"></span>\n <span class=\"a-spinner__text\">{{ loadingText }}</span>\n </span>\n <span\n *ngIf=\"focused && searchIncentiveText && !searching && !query && !results.length\"\n class=\"o-auto-complete__info u-text-light u-margin-xs\"\n >{{ searchIncentiveText }}</span\n >\n <span\n *ngIf=\"focused && noResultsText && !searching && query && !results.length\"\n class=\"o-auto-complete__info u-text-light u-margin-xs\"\n >{{ noResultsText }}</span\n >\n <aui-selectable-list\n (selected)=\"onSelect($event)\"\n *ngIf=\"results.length > 0 && !(focused && loadingText && searching)\"\n [index]=\"index\"\n [itemTemplate]=\"template\"\n [items]=\"results\"\n [label]=\"label\"\n [search]=\"query\"\n ></aui-selectable-list>\n </div>\n</div>\n", styles: [".o-auto-complete,.o-auto-complete__info{display:block}\n"] }]
|
|
439
369
|
}], function () { return [{ type: i0.ElementRef }, { type: SearchService }]; }, { id: [{
|
|
440
370
|
type: Input
|
|
441
371
|
}], placeholder: [{
|
|
@@ -452,8 +382,6 @@ class AutoCompleteComponent {
|
|
|
452
382
|
type: Input
|
|
453
383
|
}], minCharacters: [{
|
|
454
384
|
type: Input
|
|
455
|
-
}], mask: [{
|
|
456
|
-
type: Input
|
|
457
385
|
}], clearInvalid: [{
|
|
458
386
|
type: Input
|
|
459
387
|
}], searchIncentiveText: [{
|
|
@@ -490,19 +418,19 @@ class AutoCompleteModule {
|
|
|
490
418
|
}
|
|
491
419
|
/** @nocollapse */ AutoCompleteModule.ɵfac = function AutoCompleteModule_Factory(t) { return new (t || AutoCompleteModule)(); };
|
|
492
420
|
/** @nocollapse */ AutoCompleteModule.ɵmod = /** @pureOrBreakMyCode */ i0.ɵɵdefineNgModule({ type: AutoCompleteModule });
|
|
493
|
-
/** @nocollapse */ AutoCompleteModule.ɵinj = /** @pureOrBreakMyCode */ i0.ɵɵdefineInjector({ providers: [SearchService], imports: [CommonModule, FormsModule, FlyoutModule, SelectableListModule
|
|
421
|
+
/** @nocollapse */ AutoCompleteModule.ɵinj = /** @pureOrBreakMyCode */ i0.ɵɵdefineInjector({ providers: [SearchService], imports: [CommonModule, FormsModule, FlyoutModule, SelectableListModule] });
|
|
494
422
|
(function () {
|
|
495
423
|
(typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(AutoCompleteModule, [{
|
|
496
424
|
type: NgModule,
|
|
497
425
|
args: [{
|
|
498
|
-
imports: [CommonModule, FormsModule, FlyoutModule, SelectableListModule
|
|
426
|
+
imports: [CommonModule, FormsModule, FlyoutModule, SelectableListModule],
|
|
499
427
|
declarations: [AutoCompleteComponent],
|
|
500
428
|
exports: [AutoCompleteComponent],
|
|
501
429
|
providers: [SearchService],
|
|
502
430
|
}]
|
|
503
431
|
}], null, null);
|
|
504
432
|
})();
|
|
505
|
-
(function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(AutoCompleteModule, { declarations: [AutoCompleteComponent], imports: [CommonModule, FormsModule, FlyoutModule, SelectableListModule
|
|
433
|
+
(function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(AutoCompleteModule, { declarations: [AutoCompleteComponent], imports: [CommonModule, FormsModule, FlyoutModule, SelectableListModule], exports: [AutoCompleteComponent] }); })();
|
|
506
434
|
|
|
507
435
|
const DATEPICKER_ERROR_LABELS = new InjectionToken('errorLabels');
|
|
508
436
|
const DATEPICKER_DEFAULT_ERROR_LABELS = {
|
|
@@ -510,7 +438,6 @@ const DATEPICKER_DEFAULT_ERROR_LABELS = {
|
|
|
510
438
|
ERRORS_INVALID_RANGE: 'INVALID_RANGE',
|
|
511
439
|
};
|
|
512
440
|
const DATEPICKER_SEPARATOR_CHAR = '/';
|
|
513
|
-
const DATEPICKER_DATE_MASK = `99${DATEPICKER_SEPARATOR_CHAR}99${DATEPICKER_SEPARATOR_CHAR}9999`;
|
|
514
441
|
|
|
515
442
|
function DatepickerComponent_aui_icon_7_Template(rf, ctx) {
|
|
516
443
|
if (rf & 1) {
|
|
@@ -554,7 +481,6 @@ class DatepickerComponent {
|
|
|
554
481
|
this.placeholder = 'dd/mm/yyyy';
|
|
555
482
|
// eslint-disable-next-line @angular-eslint/no-output-native
|
|
556
483
|
this.blur = new EventEmitter();
|
|
557
|
-
this.dateMask = { mask: DATEPICKER_DATE_MASK, showMaskOnHover: false };
|
|
558
484
|
this.isDisabled = false;
|
|
559
485
|
this.componentDestroyed$ = new Subject();
|
|
560
486
|
this.onChange = () => undefined;
|
|
@@ -1224,7 +1150,7 @@ function SearchFilterComponent_button_8_Template(rf, ctx) {
|
|
|
1224
1150
|
if (rf & 2) {
|
|
1225
1151
|
const ctx_r0 = i0.ɵɵnextContext();
|
|
1226
1152
|
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction2(2, _c0$4, ctx_r0.size === "large", ctx_r0.size === "small"));
|
|
1227
|
-
i0.ɵɵattribute("disabled", ctx_r0.isDisabled ? "" : null);
|
|
1153
|
+
i0.ɵɵattribute("disabled", ctx_r0.isDisabled || ctx_r0.closeDisabled ? "" : null);
|
|
1228
1154
|
}
|
|
1229
1155
|
}
|
|
1230
1156
|
function SearchFilterComponent_aui_icon_9_Template(rf, ctx) {
|
|
@@ -1309,7 +1235,6 @@ class SearchFilterComponent {
|
|
|
1309
1235
|
this.labelResults = 'Resultaten';
|
|
1310
1236
|
this.labelNoResults = 'Geen resultaten gevonden.';
|
|
1311
1237
|
this.choices = [];
|
|
1312
|
-
this.placeholder = 'Zoeken';
|
|
1313
1238
|
this.inputDelay = 150;
|
|
1314
1239
|
this.onSelect = () => { };
|
|
1315
1240
|
this.onClear = () => { };
|
|
@@ -1320,6 +1245,7 @@ class SearchFilterComponent {
|
|
|
1320
1245
|
this.filteredChoices = [];
|
|
1321
1246
|
this.loading = false;
|
|
1322
1247
|
this.isDisabled = false;
|
|
1248
|
+
this.closeDisabled = false;
|
|
1323
1249
|
this.updateModel = () => { };
|
|
1324
1250
|
this.filterDataFromSearch = debounce(this.filterData.bind(this), this.inputDelay);
|
|
1325
1251
|
}
|
|
@@ -1382,11 +1308,18 @@ class SearchFilterComponent {
|
|
|
1382
1308
|
return ((_a = this.filteredChoices) === null || _a === void 0 ? void 0 : _a.length) && ((_b = this.query) === null || _b === void 0 ? void 0 : _b.length) > 1;
|
|
1383
1309
|
}
|
|
1384
1310
|
getSelectedLabels() {
|
|
1385
|
-
|
|
1311
|
+
if (!this.selectedItems.length) {
|
|
1312
|
+
this.closeDisabled = true;
|
|
1313
|
+
return null;
|
|
1314
|
+
}
|
|
1315
|
+
else {
|
|
1316
|
+
this.closeDisabled = false;
|
|
1317
|
+
return this.selectedItems.map((el) => el).join(', ');
|
|
1318
|
+
}
|
|
1386
1319
|
}
|
|
1387
1320
|
}
|
|
1388
1321
|
/** @nocollapse */ SearchFilterComponent.ɵfac = function SearchFilterComponent_Factory(t) { return new (t || SearchFilterComponent)(); };
|
|
1389
|
-
/** @nocollapse */ SearchFilterComponent.ɵcmp = /** @pureOrBreakMyCode */ i0.ɵɵdefineComponent({ type: SearchFilterComponent, selectors: [["aui-search-filter"]], inputs: { id: "id", name: "name", flyoutSize: "flyoutSize", flyoutAlign: "flyoutAlign", label: "label", description: "description", labelDeselect: "labelDeselect", labelResults: "labelResults", labelNoResults: "labelNoResults", choices: "choices", remote: "remote",
|
|
1322
|
+
/** @nocollapse */ SearchFilterComponent.ɵcmp = /** @pureOrBreakMyCode */ i0.ɵɵdefineComponent({ type: SearchFilterComponent, selectors: [["aui-search-filter"]], inputs: { id: "id", name: "name", flyoutSize: "flyoutSize", flyoutAlign: "flyoutAlign", label: "label", description: "description", labelDeselect: "labelDeselect", labelResults: "labelResults", labelNoResults: "labelNoResults", choices: "choices", remote: "remote", inputDelay: "inputDelay", onSelect: "onSelect", onClear: "onClear", size: "size" }, outputs: { search: "search" }, features: [i0.ɵɵProvidersFeature([
|
|
1390
1323
|
{
|
|
1391
1324
|
provide: NG_VALUE_ACCESSOR,
|
|
1392
1325
|
useExisting: forwardRef((() => SearchFilterComponent)),
|
|
@@ -1398,7 +1331,7 @@ class SearchFilterComponent {
|
|
|
1398
1331
|
i0.ɵɵtext(3);
|
|
1399
1332
|
i0.ɵɵelementEnd();
|
|
1400
1333
|
i0.ɵɵelementStart(4, "small", 3);
|
|
1401
|
-
i0.ɵɵtext(5
|
|
1334
|
+
i0.ɵɵtext(5);
|
|
1402
1335
|
i0.ɵɵelementEnd();
|
|
1403
1336
|
i0.ɵɵelementStart(6, "div", 4)(7, "input", 5);
|
|
1404
1337
|
i0.ɵɵlistener("input", function SearchFilterComponent_Template_input_input_7_listener() { return ctx.filterDataFromSearch(); })("ngModelChange", function SearchFilterComponent_Template_input_ngModelChange_7_listener($event) { return ctx.query = $event; });
|
|
@@ -1422,12 +1355,14 @@ class SearchFilterComponent {
|
|
|
1422
1355
|
i0.ɵɵtextInterpolate(ctx.label);
|
|
1423
1356
|
i0.ɵɵadvance(1);
|
|
1424
1357
|
i0.ɵɵpropertyInterpolate("id", ctx.id + "-description");
|
|
1425
|
-
i0.ɵɵadvance(
|
|
1358
|
+
i0.ɵɵadvance(1);
|
|
1359
|
+
i0.ɵɵtextInterpolate(ctx.description);
|
|
1360
|
+
i0.ɵɵadvance(2);
|
|
1426
1361
|
i0.ɵɵpropertyInterpolate("id", ctx.id + "-search");
|
|
1427
1362
|
i0.ɵɵpropertyInterpolate("name", ctx.name + "-search");
|
|
1428
1363
|
i0.ɵɵpropertyInterpolate("value", ctx.getSelectedLabels());
|
|
1429
1364
|
i0.ɵɵproperty("ngModel", ctx.query);
|
|
1430
|
-
i0.ɵɵattribute("aria-labelledby", ctx.id + "-label")("
|
|
1365
|
+
i0.ɵɵattribute("aria-labelledby", ctx.id + "-label")("disabled", ctx.isDisabled ? "" : null);
|
|
1431
1366
|
i0.ɵɵadvance(1);
|
|
1432
1367
|
i0.ɵɵproperty("ngIf", ctx.hasClose);
|
|
1433
1368
|
i0.ɵɵadvance(1);
|
|
@@ -1449,7 +1384,7 @@ class SearchFilterComponent {
|
|
|
1449
1384
|
useExisting: forwardRef((() => SearchFilterComponent)),
|
|
1450
1385
|
multi: true,
|
|
1451
1386
|
},
|
|
1452
|
-
], template: "<div [align]=\"flyoutAlign\" [size]=\"flyoutSize\" aria-haspopup=\"listbox\" auiFlyout class=\"m-search-filter\">\n <div\n class=\"a-input\"\n [ngClass]=\"{\n 'a-input--l': size === 'large',\n 'a-input--s': size === 'small',\n 'has-icon-right': hasClose\n }\"\n >\n <label class=\"a-input__label\" for=\"{{ id + '-search' }}\">{{ label }}</label>\n <small class=\"a-input__description\" id=\"{{ id + '-description' }}\">
|
|
1387
|
+
], template: "<div [align]=\"flyoutAlign\" [size]=\"flyoutSize\" aria-haspopup=\"listbox\" auiFlyout class=\"m-search-filter\">\n <div\n class=\"a-input\"\n [ngClass]=\"{\n 'a-input--l': size === 'large',\n 'a-input--s': size === 'small',\n 'has-icon-right': hasClose\n }\"\n >\n <label class=\"a-input__label\" for=\"{{ id + '-search' }}\">{{ label }}</label>\n <small class=\"a-input__description\" id=\"{{ id + '-description' }}\">{{ description }}</small>\n <div class=\"m-search-filter__input\">\n <input\n (input)=\"filterDataFromSearch()\"\n [(ngModel)]=\"query\"\n [attr.aria-labelledby]=\"id + '-label'\"\n [attr.disabled]=\"isDisabled ? '' : null\"\n aria-autocomplete=\"list\"\n id=\"{{ id + '-search' }}\"\n name=\"{{ name + '-search' }}\"\n value=\"{{ getSelectedLabels() }}\"\n type=\"text\"\n auiFlyoutAction\n />\n <button\n *ngIf=\"hasClose\"\n [ngClass]=\"{\n 'a-button--l': size === 'large',\n 'a-button--s': size === 'small'\n }\"\n class=\"a-button a-button--outlined has-icon m-search-filter__button a-button--danger\"\n aria-label=\"Zoekopdracht wissen\"\n type=\"button\"\n (click)=\"clear()\"\n [attr.disabled]=\"isDisabled || closeDisabled ? '' : null\"\n >\n <aui-icon name=\"ai-close\"></aui-icon>\n </button>\n <aui-icon *ngIf=\"!hasClose\" name=\"ai-close\"></aui-icon>\n </div>\n </div>\n <div auiFlyoutZone class=\"m-search-filter__search m-search-filter__search--scroll\">\n <p *ngIf=\"labelResults\" class=\"h6 m-search-filter__results-title u-margin-bottom-xs\">{{ labelResults }}</p>\n <div *ngIf=\"loading\" class=\"u-text-center u-padding a-spinner\"></div>\n <ul *ngIf=\"!loading\" class=\"a-checkbox-list a-checkbox-list--flushed\">\n <li *ngIf=\"!filteredChoices.length\" class=\"a-checkbox-list__item\">\n <p class=\"u-margin-xs\">{{ labelNoResults }}</p>\n </li>\n <li *ngFor=\"let choice of filteredChoices; index as i\" class=\"a-checkbox-list__item\">\n <div class=\"a-input a-checkbox-list__checkbox\">\n <div class=\"a-input__checkbox\">\n <input\n (change)=\"toggleSelected(choice.label)\"\n [attr.disabled]=\"isDisabled ? true : null\"\n [checked]=\"selectedItems.indexOf(choice.label) >= 0\"\n id=\"{{ 'checkbox--' + i + '--' + id }}\"\n name=\"{{ 'checkbox--' + i + '--' + id }}\"\n type=\"checkbox\"\n />\n <label for=\"{{ 'checkbox--' + i + '--' + id }}\">{{ choice.label }}</label>\n </div>\n </div>\n </li>\n </ul>\n </div>\n</div>\n", styles: [".m-search-filter{display:block}.m-search-filter__input{display:flex;padding:0}.m-search-filter__input input{border-right:none}.m-search-filter__button{display:inline-block;padding:0;position:relative;vertical-align:middle}.m-search-filter__button .ai{position:relative;transform:none!important;top:0}\n"] }]
|
|
1453
1388
|
}], function () { return []; }, { id: [{
|
|
1454
1389
|
type: Input
|
|
1455
1390
|
}], name: [{
|
|
@@ -1472,8 +1407,6 @@ class SearchFilterComponent {
|
|
|
1472
1407
|
type: Input
|
|
1473
1408
|
}], remote: [{
|
|
1474
1409
|
type: Input
|
|
1475
|
-
}], placeholder: [{
|
|
1476
|
-
type: Input
|
|
1477
1410
|
}], inputDelay: [{
|
|
1478
1411
|
type: Input
|
|
1479
1412
|
}], onSelect: [{
|
|
@@ -2587,5 +2520,5 @@ class UploadModule {
|
|
|
2587
2520
|
* Generated bundle index. Do not edit.
|
|
2588
2521
|
*/
|
|
2589
2522
|
|
|
2590
|
-
export { AutoCompleteComponent, AutoCompleteModule, DATEPICKER_DEFAULT_ERROR_LABELS, DATEPICKER_ERROR_LABELS, DATEPICKER_SEPARATOR_CHAR, DatepickerComponent, DatepickerModule,
|
|
2523
|
+
export { AutoCompleteComponent, AutoCompleteModule, DATEPICKER_DEFAULT_ERROR_LABELS, DATEPICKER_ERROR_LABELS, DATEPICKER_SEPARATOR_CHAR, DatepickerComponent, DatepickerModule, RangeSliderComponent, RangeSliderModule, SearchFilterComponent, SearchFilterModule, TimePickerValidators, TimepickerComponent, TimepickerInputSize, TimepickerModule, UPLOAD_OPTIONS_DEFAULT, UPLOAD_VALIDATION_MESSAGES, UploadComponent, UploadInputComponent, UploadModule, UploadQueueComponent, UploadZoneComponent, Uploader, ValidationListComponent, ValidationMessagesService };
|
|
2591
2524
|
//# sourceMappingURL=acpaas-ui-ngx-forms.mjs.map
|