ng-select2-component 8.1.0 → 9.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.
Files changed (50) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/README.md +5 -3
  3. package/esm2020/lib/select2-const.mjs +48 -0
  4. package/esm2020/lib/select2-hint.component.mjs +11 -0
  5. package/esm2020/lib/select2-interfaces.mjs +2 -0
  6. package/esm2020/lib/select2-label.component.mjs +11 -0
  7. package/esm2020/lib/select2-utils.mjs +280 -0
  8. package/esm2020/lib/select2.component.mjs +871 -0
  9. package/esm2020/lib/select2.module.mjs +23 -0
  10. package/esm2020/ng-select2-component.mjs +5 -0
  11. package/esm2020/public_api.mjs +12 -0
  12. package/fesm2015/ng-select2-component.mjs +1241 -0
  13. package/fesm2015/ng-select2-component.mjs.map +1 -0
  14. package/fesm2020/ng-select2-component.mjs +1242 -0
  15. package/fesm2020/ng-select2-component.mjs.map +1 -0
  16. package/lib/select2-const.d.ts +1 -0
  17. package/lib/select2-const.d.ts.map +1 -0
  18. package/lib/select2-hint.component.d.ts +4 -0
  19. package/lib/select2-hint.component.d.ts.map +1 -0
  20. package/lib/select2-interfaces.d.ts +1 -0
  21. package/lib/select2-interfaces.d.ts.map +1 -0
  22. package/lib/select2-label.component.d.ts +4 -0
  23. package/lib/select2-label.component.d.ts.map +1 -0
  24. package/lib/select2-utils.d.ts +1 -0
  25. package/lib/select2-utils.d.ts.map +1 -0
  26. package/lib/select2.component.d.ts +4 -0
  27. package/lib/select2.component.d.ts.map +1 -0
  28. package/lib/select2.module.d.ts +12 -0
  29. package/lib/select2.module.d.ts.map +1 -0
  30. package/ng-select2-component.d.ts +2 -0
  31. package/ng-select2-component.d.ts.map +1 -0
  32. package/package.json +25 -13
  33. package/public_api.d.ts +1 -0
  34. package/public_api.d.ts.map +1 -0
  35. package/bundles/ng-select2-component.umd.js +0 -2666
  36. package/bundles/ng-select2-component.umd.js.map +0 -1
  37. package/bundles/ng-select2-component.umd.min.js +0 -2
  38. package/bundles/ng-select2-component.umd.min.js.map +0 -1
  39. package/esm2015/lib/select2-const.js +0 -57
  40. package/esm2015/lib/select2-hint.component.js +0 -12
  41. package/esm2015/lib/select2-interfaces.js +0 -134
  42. package/esm2015/lib/select2-label.component.js +0 -12
  43. package/esm2015/lib/select2-utils.js +0 -415
  44. package/esm2015/lib/select2.component.js +0 -1530
  45. package/esm2015/lib/select2.module.js +0 -23
  46. package/esm2015/ng-select2-component.js +0 -10
  47. package/esm2015/public_api.js +0 -17
  48. package/fesm2015/ng-select2-component.js +0 -2187
  49. package/fesm2015/ng-select2-component.js.map +0 -1
  50. package/ng-select2-component.metadata.json +0 -1
@@ -0,0 +1,1241 @@
1
+ import * as i4 from '@angular/cdk/overlay';
2
+ import { CdkConnectedOverlay, OverlayModule } from '@angular/cdk/overlay';
3
+ import * as i0 from '@angular/core';
4
+ import { EventEmitter, TemplateRef, Component, Optional, Self, Attribute, Input, Output, HostBinding, ViewChild, ViewChildren, Directive, NgModule } from '@angular/core';
5
+ import { Subject } from 'rxjs';
6
+ import * as i1 from '@angular/cdk/scrolling';
7
+ import * as i2 from '@angular/forms';
8
+ import { FormsModule, ReactiveFormsModule } from '@angular/forms';
9
+ import * as i3 from '@angular/common';
10
+ import { CommonModule } from '@angular/common';
11
+ import * as i5 from 'ngx-infinite-scroll';
12
+ import { InfiniteScrollModule } from 'ngx-infinite-scroll';
13
+
14
+ const timeout = 200;
15
+ const unicodePatterns = [
16
+ { l: 'a', s: /[ⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐ]/gi },
17
+ { l: 'aa', s: /ꜳ/gi },
18
+ { l: 'ae', s: /[æǽǣ]/gi },
19
+ { l: 'ao', s: /ꜵ/gi },
20
+ { l: 'au', s: /ꜷ/gi },
21
+ { l: 'av', s: /[ꜹꜻ]/gi },
22
+ { l: 'ay', s: /ꜽ/gi },
23
+ { l: 'b', s: /[ⓑbḃḅḇƀƃɓ]/gi },
24
+ { l: 'c', s: /[ⓒcćĉċčçḉƈȼꜿↄ]/gi },
25
+ { l: 'd', s: /[ⓓdḋďḍḑḓḏđƌɖɗꝺ]/gi },
26
+ { l: 'dz', s: /[dzdž]/gi },
27
+ { l: 'e', s: /[ⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇɛǝ]/gi },
28
+ { l: 'f', s: /[ⓕfḟƒꝼ]/gi },
29
+ { l: 'g', s: /[ⓖgǵĝḡğġǧģǥɠꞡᵹꝿ]/gi },
30
+ { l: 'h', s: /[ⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ]/gi },
31
+ { l: 'hv', s: /ƕ/gi },
32
+ { l: 'i', s: /[ⓘiìíîĩīĭİïḯỉǐȉȋịįḭɨı]/gi },
33
+ { l: 'j', s: /[ⓙjĵǰɉ]/gi },
34
+ { l: 'k', s: /[ⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ]/gi },
35
+ { l: 'l', s: /[ⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇꝆ]/gi },
36
+ { l: 'lj', s: /lj/gi },
37
+ { l: 'm', s: /[ⓜmḿṁṃɱɯ]/gi },
38
+ { l: 'n', s: /[ⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥ]/gi },
39
+ { l: 'nj', s: /nj/gi },
40
+ { l: 'o', s: /[ⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿɔƟꝋꝍɵ]/gi },
41
+ { l: 'oi', s: /ƣ/gi },
42
+ { l: 'oe', s: /œ/gi },
43
+ { l: 'oo', s: /ꝏ/gi },
44
+ { l: 'ou', s: /ȣ/gi },
45
+ { l: 'p', s: /[ⓟpṕṗƥᵽꝑꝓꝕ]/gi },
46
+ { l: 'q', s: /[ⓠqɋꝗꝙ]/gi },
47
+ { l: 'r', s: /[ⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ]/gi },
48
+ { l: 's', s: /[ⓢsßẞśṥŝṡšṧṣṩșşȿꞩꞅẛ]/gi },
49
+ { l: 't', s: /[ⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ]/gi },
50
+ { l: 'tz', s: /ꜩ/gi },
51
+ { l: 'u', s: /[ⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ]/gi },
52
+ { l: 'v', s: /[ⓥvṽṿʋꝟʌ]/gi },
53
+ { l: 'vy', s: /ꝡ/gi },
54
+ { l: 'w', s: /[ⓦwẁẃŵẇẅẘẉⱳ]/gi },
55
+ { l: 'x', s: /[ⓧxẋẍ]/gi },
56
+ { l: 'y', s: /[ⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ]/gi },
57
+ { l: 'z', s: /[ⓩzźẑżžẓẕƶȥɀⱬꝣ]/gi },
58
+ ];
59
+ const defaultMinCountForSearch = 6;
60
+ const protectRegexp = new RegExp('[\\-\\[\\]\\/\\{\\}\\(\\)\\*\\+\\?\\.\\\\\\^\\$\\|]', 'g');
61
+
62
+ class Select2Utils {
63
+ static getOptionByValue(data, value) {
64
+ if (Array.isArray(data)) {
65
+ for (const groupOrOption of data) {
66
+ const options = groupOrOption.options;
67
+ if (options) {
68
+ for (const option of options) {
69
+ if (option.value === value) {
70
+ return option;
71
+ }
72
+ }
73
+ }
74
+ else if (groupOrOption.value === value) {
75
+ return groupOrOption;
76
+ }
77
+ }
78
+ }
79
+ return null;
80
+ }
81
+ static getOptionsByValue(data, value, multiple) {
82
+ if (multiple) {
83
+ const values = Array.isArray(value) ? value : [];
84
+ const result = [];
85
+ for (const v of values) {
86
+ const option = Select2Utils.getOptionByValue(data, v);
87
+ if (option) {
88
+ result.push(option);
89
+ }
90
+ }
91
+ return result;
92
+ }
93
+ return Select2Utils.getOptionByValue(data, value);
94
+ }
95
+ static getFirstAvailableOption(data) {
96
+ if (Array.isArray(data)) {
97
+ for (const groupOrOption of data) {
98
+ const options = groupOrOption.options;
99
+ if (options) {
100
+ for (const option of options) {
101
+ if (!option.disabled) {
102
+ return option.value;
103
+ }
104
+ }
105
+ }
106
+ else {
107
+ const option = groupOrOption;
108
+ if (!option.disabled) {
109
+ return option.value;
110
+ }
111
+ }
112
+ }
113
+ }
114
+ return null;
115
+ }
116
+ static valueIsNotInFilteredData(filteredData, value) {
117
+ if (Select2Utils.isNullOrUndefined(value)) {
118
+ return true;
119
+ }
120
+ for (const groupOrOption of filteredData) {
121
+ const options = groupOrOption.options;
122
+ if (options) {
123
+ for (const option of options) {
124
+ if (option.value === value) {
125
+ return false;
126
+ }
127
+ }
128
+ }
129
+ else if (groupOrOption.value === value) {
130
+ return false;
131
+ }
132
+ }
133
+ return true;
134
+ }
135
+ // eslint-disable-next-line
136
+ static getPreviousOption(filteredData, hoveringValue) {
137
+ let findIt = Select2Utils.isNullOrUndefined(hoveringValue);
138
+ for (let i = filteredData.length - 1; i >= 0; i--) {
139
+ const groupOrOption = filteredData[i];
140
+ const options = groupOrOption.options;
141
+ if (options) {
142
+ for (let j = options.length - 1; j >= 0; j--) {
143
+ const option = options[j];
144
+ if (findIt && !option.disabled && !option.hide) {
145
+ return option;
146
+ }
147
+ if (!findIt) {
148
+ findIt = option.value === hoveringValue;
149
+ }
150
+ }
151
+ }
152
+ else {
153
+ const option = groupOrOption;
154
+ if (findIt && !option.disabled && !option.hide) {
155
+ return option;
156
+ }
157
+ if (!findIt) {
158
+ findIt = option.value === hoveringValue;
159
+ }
160
+ }
161
+ }
162
+ return null;
163
+ }
164
+ // eslint-disable-next-line
165
+ static getNextOption(filteredData, hoveringValue) {
166
+ let findIt = Select2Utils.isNullOrUndefined(hoveringValue);
167
+ for (const groupOrOption of filteredData) {
168
+ const options = groupOrOption.options;
169
+ if (options) {
170
+ for (const option of options) {
171
+ if (findIt) {
172
+ if (!option.disabled && !option.hide) {
173
+ return option;
174
+ }
175
+ }
176
+ else if (!findIt) {
177
+ findIt = option.value === hoveringValue;
178
+ }
179
+ }
180
+ }
181
+ else {
182
+ const option = groupOrOption;
183
+ if (findIt) {
184
+ if (!option.disabled && !option.hide) {
185
+ return option;
186
+ }
187
+ }
188
+ else if (!findIt) {
189
+ findIt = option.value === hoveringValue;
190
+ }
191
+ }
192
+ }
193
+ return null;
194
+ }
195
+ static getReduceData(data, maxResults = 0) {
196
+ if (maxResults > 0) {
197
+ let counter = 0;
198
+ const result = [];
199
+ // debugger;
200
+ for (const groupOrOption of data) {
201
+ const options = groupOrOption.options;
202
+ if (options) {
203
+ const group = Object.assign(Object.assign({}, groupOrOption), { options: [] });
204
+ result.push(group);
205
+ for (const item of options) {
206
+ group.options.push(item);
207
+ counter++;
208
+ if (counter === maxResults) {
209
+ return { result, reduce: true };
210
+ }
211
+ }
212
+ }
213
+ else {
214
+ result.push(groupOrOption);
215
+ counter++;
216
+ }
217
+ if (counter === maxResults) {
218
+ return { result, reduce: true };
219
+ }
220
+ }
221
+ return { result, reduce: false };
222
+ }
223
+ else {
224
+ return { result: data, reduce: false };
225
+ }
226
+ }
227
+ static getFilteredData(data, searchText, editPattern) {
228
+ if (searchText) {
229
+ const result = [];
230
+ for (const groupOrOption of data) {
231
+ const options = groupOrOption.options;
232
+ if (options) {
233
+ if (options.some(group => Select2Utils.containSearchText(group.label, searchText, editPattern))) {
234
+ const filteredOptions = options.filter(group => Select2Utils.containSearchText(group.label, searchText, editPattern));
235
+ result.push(Object.assign(Object.assign({}, groupOrOption), { options: filteredOptions }));
236
+ }
237
+ }
238
+ else if (Select2Utils.containSearchText(groupOrOption.label, searchText, editPattern)) {
239
+ result.push(groupOrOption);
240
+ }
241
+ }
242
+ return result;
243
+ }
244
+ else {
245
+ return data;
246
+ }
247
+ }
248
+ static getFilteredSelectedData(data, selectedOptions) {
249
+ const result = [];
250
+ for (const groupOrOption of data) {
251
+ const options = groupOrOption.options;
252
+ if (options) {
253
+ const filteredOptions = options.filter(group => Select2Utils.isSelected(selectedOptions, group, true) === 'false');
254
+ if (filteredOptions.length) {
255
+ result.push(Object.assign(Object.assign({}, groupOrOption), { options: filteredOptions }));
256
+ }
257
+ }
258
+ else if (Select2Utils.isSelected(selectedOptions, groupOrOption, true) === 'false') {
259
+ result.push(groupOrOption);
260
+ }
261
+ }
262
+ return result;
263
+ }
264
+ static isSearchboxHiddex(data, minCountForSearch) {
265
+ if (minCountForSearch === '' ||
266
+ minCountForSearch === undefined ||
267
+ minCountForSearch === null ||
268
+ isNaN(+minCountForSearch)) {
269
+ minCountForSearch = defaultMinCountForSearch;
270
+ }
271
+ const optionCount = Select2Utils.getOptionsCount(data);
272
+ return optionCount < +minCountForSearch;
273
+ }
274
+ static isSelected(options, option, multiple) {
275
+ return multiple
276
+ ? options && options.some(op => op.value === option.value)
277
+ ? 'true'
278
+ : 'false'
279
+ : options && option.value === options.value
280
+ ? 'true'
281
+ : 'false';
282
+ }
283
+ static removeSelection(options, option) {
284
+ for (let i = 0; i < options.length; i++) {
285
+ if (options[i].value === option.value) {
286
+ options.splice(i, 1);
287
+ return;
288
+ }
289
+ }
290
+ }
291
+ static getOptionsCount(data) {
292
+ let count = 0;
293
+ if (Array.isArray(data)) {
294
+ for (const groupOrOption of data) {
295
+ const options = groupOrOption.options;
296
+ if (options) {
297
+ count += options.length;
298
+ }
299
+ else {
300
+ count++;
301
+ }
302
+ }
303
+ }
304
+ return count;
305
+ }
306
+ static isNullOrUndefined(value) {
307
+ return value === null || value === undefined;
308
+ }
309
+ static containSearchText(label, searchText, editPattern) {
310
+ return searchText
311
+ ? Select2Utils.formatSansUnicode(label).match(new RegExp(Select2Utils.formatPattern(searchText, editPattern), 'i')) !== null
312
+ : true;
313
+ }
314
+ static protectPattern(str) {
315
+ return str.replace(protectRegexp, '\\$&');
316
+ }
317
+ static formatSansUnicode(str) {
318
+ for (const unicodePattern of unicodePatterns) {
319
+ str = str.replace(unicodePattern.s, unicodePattern.l);
320
+ }
321
+ return str;
322
+ }
323
+ static formatPattern(str, editPattern) {
324
+ str = Select2Utils.formatSansUnicode(Select2Utils.protectPattern(str));
325
+ if (editPattern && typeof editPattern === 'function') {
326
+ str = editPattern(str);
327
+ }
328
+ return str;
329
+ }
330
+ }
331
+
332
+ let nextUniqueId = 0;
333
+ const displaySearchStatusList = ['default', 'hidden', 'always'];
334
+ class Select2 {
335
+ constructor(_viewportRuler, _changeDetectorRef, _parentForm, _parentFormGroup, _control, tabIndex) {
336
+ this._viewportRuler = _viewportRuler;
337
+ this._changeDetectorRef = _changeDetectorRef;
338
+ this._parentForm = _parentForm;
339
+ this._parentFormGroup = _parentFormGroup;
340
+ this._control = _control;
341
+ this.minCharForSearch = 0;
342
+ this.limitSelection = 0;
343
+ this.listPosition = 'below';
344
+ /** use the material style */
345
+ this.styleMode = 'default';
346
+ /** maximum results limit (0 = no limit) */
347
+ this.maxResults = 0;
348
+ /** message when maximum results */
349
+ this.maxResultsMessage = 'Too many results…';
350
+ /** infinite scroll distance */
351
+ this.infiniteScrollDistance = 1.5;
352
+ /** infinite scroll distance */
353
+ this.infiniteScrollThrottle = 150;
354
+ /** the max height of the results container when opening the select */
355
+ this.resultMaxHeight = '200px';
356
+ this.update = new EventEmitter();
357
+ this.open = new EventEmitter();
358
+ this.close = new EventEmitter();
359
+ this.focus = new EventEmitter();
360
+ this.blur = new EventEmitter();
361
+ this.search = new EventEmitter();
362
+ this.scroll = new EventEmitter();
363
+ this.removeOption = new EventEmitter();
364
+ this.option = null;
365
+ this.isOpen = false;
366
+ /** Whether the element is focused or not. */
367
+ this.focused = false;
368
+ this.hoveringValue = null;
369
+ this.innerSearchText = '';
370
+ this._stateChanges = new Subject();
371
+ this._disabled = false;
372
+ this._required = false;
373
+ this._readonly = false;
374
+ this._multiple = false;
375
+ this._overlay = false;
376
+ this._resettable = false;
377
+ this._hideSelectedItems = false;
378
+ this._clickDetection = false;
379
+ this._uid = `select2-${nextUniqueId++}`;
380
+ this._infiniteScroll = true;
381
+ /** View -> model callback called when select has been touched */
382
+ this._onTouched = () => {
383
+ // do nothing
384
+ };
385
+ /** View -> model callback called when value changes */
386
+ this._onChange = () => {
387
+ // do nothing
388
+ };
389
+ // eslint-disable-next-line no-self-assign
390
+ this.id = this.id;
391
+ this._tabIndex = parseInt(tabIndex, 10) || 0;
392
+ if (this._control) {
393
+ this._control.valueAccessor = this;
394
+ }
395
+ this._clickDetectionFc = this.clickDetection.bind(this);
396
+ }
397
+ /** data of options & optiongrps */
398
+ set data(data) {
399
+ this._data = data;
400
+ this.updateFilteredData();
401
+ }
402
+ get multiple() {
403
+ return this._multiple;
404
+ }
405
+ set multiple(value) {
406
+ this._multiple = this._coerceBooleanProperty(value);
407
+ this.ngOnInit();
408
+ }
409
+ /** use the material style */
410
+ get overlay() {
411
+ return this._overlay;
412
+ }
413
+ set overlay(value) {
414
+ this._overlay = this._coerceBooleanProperty(value);
415
+ }
416
+ /** infinite scroll activated */
417
+ get infiniteScroll() {
418
+ return this._infiniteScroll;
419
+ }
420
+ set infiniteScroll(value) {
421
+ this._infiniteScroll = this._coerceBooleanProperty(value);
422
+ }
423
+ get select2Options() {
424
+ return this.multiple ? this.option : null;
425
+ }
426
+ get select2Option() {
427
+ return this.multiple ? null : this.option;
428
+ }
429
+ get searchText() {
430
+ return this.innerSearchText;
431
+ }
432
+ set searchText(text) {
433
+ if (this.customSearchEnabled) {
434
+ this.search.emit({
435
+ component: this,
436
+ value: this._value,
437
+ search: text,
438
+ });
439
+ }
440
+ this.innerSearchText = text;
441
+ }
442
+ /** minimal data of show the search field */
443
+ get minCountForSearch() {
444
+ return this._minCountForSearch;
445
+ }
446
+ set minCountForSearch(value) {
447
+ this._minCountForSearch = value;
448
+ this.updateSearchBox();
449
+ }
450
+ /** Unique id of the element. */
451
+ get id() {
452
+ return this._id;
453
+ }
454
+ set id(value) {
455
+ this._id = value || this._uid;
456
+ }
457
+ /** Whether the element is required. */
458
+ get required() {
459
+ return this._required;
460
+ }
461
+ set required(value) {
462
+ this._required = this._coerceBooleanProperty(value);
463
+ }
464
+ /** Whether selected items should be hidden. */
465
+ get disabled() {
466
+ return this._control ? this._control.disabled : this._disabled;
467
+ }
468
+ set disabled(value) {
469
+ this._disabled = this._coerceBooleanProperty(value);
470
+ }
471
+ /** Whether items are hidden when has. */
472
+ get hideSelectedItems() {
473
+ return this._hideSelectedItems;
474
+ }
475
+ set hideSelectedItems(value) {
476
+ this._hideSelectedItems = this._coerceBooleanProperty(value);
477
+ }
478
+ /** Whether the element is readonly. */
479
+ get readonly() {
480
+ return this._readonly;
481
+ }
482
+ set readonly(value) {
483
+ this._readonly = this._coerceBooleanProperty(value);
484
+ }
485
+ /** The input element's value. */
486
+ get value() {
487
+ return this._value;
488
+ }
489
+ set value(value) {
490
+ if (this.testValueChange(this._value, value)) {
491
+ setTimeout(() => {
492
+ this._value = value;
493
+ this.writeValue(value);
494
+ }, 10);
495
+ }
496
+ }
497
+ /** Tab index for the select2 element. */
498
+ get tabIndex() {
499
+ return this.disabled ? -1 : this._tabIndex;
500
+ }
501
+ set tabIndex(value) {
502
+ if (typeof value !== 'undefined') {
503
+ this._tabIndex = value;
504
+ }
505
+ }
506
+ /** reset with no selected value */
507
+ get resettable() {
508
+ return this._resettable;
509
+ }
510
+ set resettable(value) {
511
+ this._resettable = this._coerceBooleanProperty(value);
512
+ }
513
+ get ariaInvalid() {
514
+ return this._isErrorState();
515
+ }
516
+ get classMaterial() {
517
+ return this.styleMode === 'material';
518
+ }
519
+ get classNostyle() {
520
+ return this.styleMode === 'noStyle';
521
+ }
522
+ get select2above() {
523
+ return !this.overlay ? this.listPosition === 'above' : this._isAbobeOverlay();
524
+ }
525
+ get _positions() {
526
+ if (this.listPosition === 'auto') {
527
+ [
528
+ {
529
+ originX: 'start',
530
+ originY: 'bottom',
531
+ overlayX: 'start',
532
+ overlayY: 'bottom',
533
+ },
534
+ {
535
+ originX: 'start',
536
+ originY: 'top',
537
+ overlayX: 'start',
538
+ overlayY: 'top',
539
+ },
540
+ ];
541
+ }
542
+ else {
543
+ return null;
544
+ }
545
+ }
546
+ get resultsElement() {
547
+ var _a;
548
+ return (_a = this.resultContainer) === null || _a === void 0 ? void 0 : _a.nativeElement;
549
+ }
550
+ ngOnInit() {
551
+ this._viewportRuler.change(100).subscribe(() => {
552
+ if (this.isOpen) {
553
+ this.triggerRect();
554
+ }
555
+ });
556
+ const option = Select2Utils.getOptionsByValue(this._data, this._control ? this._control.value : this.value, this.multiple);
557
+ if (option !== null) {
558
+ this.option = option;
559
+ }
560
+ if (!Array.isArray(option)) {
561
+ this.hoveringValue = this.value;
562
+ }
563
+ this.updateSearchBox();
564
+ }
565
+ ngAfterViewInit() {
566
+ this.cdkConnectedOverlay.positionChange.subscribe((posChange) => {
567
+ var _a;
568
+ if (this.listPosition === 'auto' &&
569
+ ((_a = posChange.connectionPair) === null || _a === void 0 ? void 0 : _a.originY) &&
570
+ this._overlayPosition !== posChange.connectionPair.originY) {
571
+ this.triggerRect();
572
+ this._overlayPosition = posChange.connectionPair.originY;
573
+ this._changeDetectorRef.detectChanges();
574
+ }
575
+ });
576
+ this.selectionElement = this.selection.nativeElement;
577
+ this.triggerRect();
578
+ }
579
+ ngDoCheck() {
580
+ var _a;
581
+ this.updateSearchBox();
582
+ this._dirtyCheckNativeValue();
583
+ if (this._triggerRect) {
584
+ if (this.overlayWidth !== this._triggerRect.width) {
585
+ this.overlayWidth = this._triggerRect.width;
586
+ }
587
+ if (((_a = this._dropdownRect) === null || _a === void 0 ? void 0 : _a.height) > 0 && this.overlayHeight !== this._dropdownRect.height) {
588
+ this.overlayHeight = this.listPosition === 'auto' ? this._dropdownRect.height : 0;
589
+ }
590
+ }
591
+ }
592
+ ngOnDestroy() {
593
+ window.document.body.removeEventListener('click', this._clickDetectionFc);
594
+ }
595
+ updateSearchBox() {
596
+ const hidden = this.customSearchEnabled
597
+ ? false
598
+ : Select2Utils.isSearchboxHiddex(this._data, this._minCountForSearch);
599
+ if (this.isSearchboxHidden !== hidden) {
600
+ this.isSearchboxHidden = hidden;
601
+ }
602
+ }
603
+ hideSearch() {
604
+ const displaySearchStatus = displaySearchStatusList.indexOf(this.displaySearchStatus) > -1 ? this.displaySearchStatus : 'default';
605
+ return (displaySearchStatus === 'default' && this.isSearchboxHidden) || displaySearchStatus === 'hidden';
606
+ }
607
+ getOptionStyle(option) {
608
+ return ('select2-results__option ' +
609
+ (option.hide ? 'select2-results__option--hide ' : '') +
610
+ (option.value === this.hoveringValue ? 'select2-results__option--highlighted ' : '') +
611
+ (option.classes || ''));
612
+ }
613
+ mouseenter(option) {
614
+ if (!option.disabled) {
615
+ this.hoveringValue = option.value;
616
+ }
617
+ }
618
+ click(option) {
619
+ if (this.testSelection(option)) {
620
+ this.select(option);
621
+ }
622
+ }
623
+ reset(e) {
624
+ this.select(null);
625
+ e.preventDefault();
626
+ e.stopPropagation();
627
+ }
628
+ prevChange(event) {
629
+ event.stopPropagation();
630
+ }
631
+ toggleOpenAndClose() {
632
+ if (this.disabled) {
633
+ return;
634
+ }
635
+ this._focus(true);
636
+ this.isOpen = !this.isOpen;
637
+ if (this.isOpen) {
638
+ this.innerSearchText = '';
639
+ this.updateFilteredData();
640
+ this._focusSearchboxOrResultsElement();
641
+ setTimeout(() => {
642
+ if (this.option) {
643
+ const option = this.option instanceof Array ? this.option[0] : this.option;
644
+ this.updateScrollFromOption(option);
645
+ }
646
+ else if (this.resultsElement) {
647
+ this.resultsElement.scrollTop = 0;
648
+ }
649
+ setTimeout(() => {
650
+ var _a, _b;
651
+ this.triggerRect();
652
+ (_b = (_a = this.cdkConnectedOverlay) === null || _a === void 0 ? void 0 : _a.overlayRef) === null || _b === void 0 ? void 0 : _b.updatePosition();
653
+ }, 100);
654
+ });
655
+ this.open.emit(this);
656
+ }
657
+ else {
658
+ this.close.emit(this);
659
+ }
660
+ if (this.isOpen && !this._clickDetection) {
661
+ setTimeout(() => {
662
+ window.document.body.addEventListener('click', this._clickDetectionFc, false);
663
+ this._clickDetection = true;
664
+ }, timeout);
665
+ }
666
+ this._changeDetectorRef.markForCheck();
667
+ }
668
+ hasTemplate(option, defaut) {
669
+ var _a, _b;
670
+ return (this.templates instanceof TemplateRef ||
671
+ ((_a = this.templates) === null || _a === void 0 ? void 0 : _a[option.templateId]) instanceof TemplateRef ||
672
+ ((_b = this.templates) === null || _b === void 0 ? void 0 : _b[defaut]) instanceof TemplateRef);
673
+ }
674
+ getTemplate(option, defaut) {
675
+ return this.hasTemplate(option, defaut)
676
+ ? this.templates[option.templateId] || this.templates[defaut] || this.templates
677
+ : undefined;
678
+ }
679
+ triggerRect() {
680
+ var _a;
681
+ this._triggerRect = this.selectionElement.getBoundingClientRect();
682
+ this._dropdownRect = ((_a = this.dropdown) === null || _a === void 0 ? void 0 : _a.nativeElement)
683
+ ? this.dropdown.nativeElement.getBoundingClientRect()
684
+ : undefined;
685
+ }
686
+ testSelection(option) {
687
+ if (option.disabled) {
688
+ return false;
689
+ }
690
+ if (!this.multiple ||
691
+ !this.limitSelection ||
692
+ (Array.isArray(this._value) && this._value.length < this.limitSelection)) {
693
+ return true;
694
+ }
695
+ return false;
696
+ }
697
+ testValueChange(value1, value2) {
698
+ if (((value1 === null || value1 === undefined) && (value2 === null || value2 === undefined)) ||
699
+ value1 === value2) {
700
+ return false;
701
+ }
702
+ if (this.multiple &&
703
+ (value1 === null || value1 === void 0 ? void 0 : value1.length) &&
704
+ (value2 === null || value2 === void 0 ? void 0 : value2.length) &&
705
+ value1.length === value2.length) {
706
+ for (const e1 of value1) {
707
+ const test = value2.indexOf(e1) > -1;
708
+ if (!test) {
709
+ return true;
710
+ }
711
+ }
712
+ return false;
713
+ }
714
+ return true;
715
+ }
716
+ updateFilteredData() {
717
+ setTimeout(() => {
718
+ let result = this._data;
719
+ if (this.multiple && this.hideSelectedItems) {
720
+ result = Select2Utils.getFilteredSelectedData(result, this.option);
721
+ }
722
+ if (!this.customSearchEnabled && this.searchText && this.searchText.length >= +this.minCharForSearch) {
723
+ result = Select2Utils.getFilteredData(result, this.searchText, this.editPattern);
724
+ }
725
+ if (this.maxResults > 0) {
726
+ const data = Select2Utils.getReduceData(result, +this.maxResults);
727
+ result = data.result;
728
+ this.maxResultsExceeded = data.reduce;
729
+ }
730
+ else {
731
+ this.maxResultsExceeded = false;
732
+ }
733
+ if (Select2Utils.valueIsNotInFilteredData(result, this.hoveringValue)) {
734
+ this.hoveringValue = Select2Utils.getFirstAvailableOption(result);
735
+ }
736
+ this.filteredData = result;
737
+ this._changeDetectorRef.markForCheck();
738
+ });
739
+ }
740
+ clickDetection(e) {
741
+ if (!this.ifParentContainsClass(e.target, 'selection')) {
742
+ if (this.isOpen && !this.ifParentContainsClass(e.target, 'select2-dropdown')) {
743
+ this.toggleOpenAndClose();
744
+ }
745
+ if (!this.ifParentContainsId(e.target, this._id)) {
746
+ this.clickExit();
747
+ }
748
+ }
749
+ else if (this.isOpen && !this.ifParentContainsId(e.target, this._id)) {
750
+ this.toggleOpenAndClose();
751
+ this.clickExit();
752
+ }
753
+ }
754
+ clickExit() {
755
+ this._focus(false);
756
+ window.document.body.removeEventListener('click', this._clickDetectionFc);
757
+ this._clickDetection = false;
758
+ }
759
+ ifParentContainsClass(element, cssClass) {
760
+ return this.getParentElementByClass(element, cssClass) !== null;
761
+ }
762
+ ifParentContainsId(element, id) {
763
+ return this.getParentElementById(element, id) !== null;
764
+ }
765
+ getParentElementByClass(element, cssClass) {
766
+ if (this.containClasses(element, cssClass.trim().split(/\s+/))) {
767
+ return element;
768
+ }
769
+ return element.parentElement ? this.getParentElementByClass(element.parentElement, cssClass) : null;
770
+ }
771
+ getParentElementById(element, id) {
772
+ if (element.id === id) {
773
+ return element;
774
+ }
775
+ return element.parentElement ? this.getParentElementById(element.parentElement, id) : null;
776
+ }
777
+ containClasses(element, cssClasses) {
778
+ if (!element.classList) {
779
+ return false;
780
+ }
781
+ for (const cssClass of cssClasses) {
782
+ if (!element.classList.contains(cssClass)) {
783
+ return false;
784
+ }
785
+ }
786
+ return true;
787
+ }
788
+ focusin() {
789
+ if (!this.disabled) {
790
+ this._focus(true);
791
+ }
792
+ }
793
+ focusout() {
794
+ if (this.selectionElement && !this.selectionElement.classList.contains('select2-focused')) {
795
+ this._focus(false);
796
+ this._onTouched();
797
+ }
798
+ }
799
+ select(option) {
800
+ let value;
801
+ if (option !== null) {
802
+ if (this.multiple) {
803
+ const options = this.option;
804
+ const index = options.findIndex(op => op.value === option.value);
805
+ if (index === -1) {
806
+ options.push(option);
807
+ }
808
+ else {
809
+ options.splice(index, 1);
810
+ }
811
+ value = this.option.map(op => op.value);
812
+ }
813
+ else {
814
+ this.option = option;
815
+ if (this.isOpen) {
816
+ this.isOpen = false;
817
+ this.close.emit(this);
818
+ if (this.selectionElement) {
819
+ this.selectionElement.focus();
820
+ }
821
+ }
822
+ value = this.option.value;
823
+ }
824
+ }
825
+ else {
826
+ this.option = null;
827
+ }
828
+ if (this.multiple && this.hideSelectedItems) {
829
+ this.updateFilteredData();
830
+ }
831
+ if (this._control) {
832
+ this._onChange(value);
833
+ }
834
+ else {
835
+ this._value = value;
836
+ }
837
+ this.update.emit({
838
+ component: this,
839
+ value: value,
840
+ options: Array.isArray(this.option) ? this.option : this.option ? [this.option] : null,
841
+ });
842
+ }
843
+ keyDown(e) {
844
+ if (this._testKey(e, ['ArrowDown', 40])) {
845
+ this.moveDown();
846
+ e.preventDefault();
847
+ }
848
+ else if (this._testKey(e, ['ArrowUp', 38])) {
849
+ this.moveUp();
850
+ e.preventDefault();
851
+ }
852
+ else if (this._testKey(e, ['Enter', 13])) {
853
+ this.selectByEnter();
854
+ e.preventDefault();
855
+ }
856
+ else if (this._testKey(e, ['Escape', 'Tab', 9, 27]) && this.isOpen) {
857
+ this.toggleOpenAndClose();
858
+ this._focus(false);
859
+ }
860
+ }
861
+ openKey(e) {
862
+ if (this._testKey(e, ['ArrowDown', 'ArrowUp', 'Enter', 40, 38, 13])) {
863
+ this.toggleOpenAndClose();
864
+ e.preventDefault();
865
+ }
866
+ else if (this._testKey(e, ['Escape', 'Tab', 9, 27])) {
867
+ this._focus(false);
868
+ this._onTouched();
869
+ }
870
+ }
871
+ trackBy(_index, item) {
872
+ return item.value;
873
+ }
874
+ searchUpdate(e) {
875
+ this.searchText = e.target.value;
876
+ this.updateFilteredData();
877
+ }
878
+ isSelected(option) {
879
+ return Select2Utils.isSelected(this.option, option, this.multiple);
880
+ }
881
+ isDisabled(option) {
882
+ return option.disabled ? 'true' : 'false';
883
+ }
884
+ removeSelection(e, option) {
885
+ Select2Utils.removeSelection(this.option, option);
886
+ if (this.multiple && this.hideSelectedItems) {
887
+ this.updateFilteredData();
888
+ }
889
+ const value = this.option.map(op => op.value);
890
+ if (this._control) {
891
+ this._onChange(value);
892
+ }
893
+ else {
894
+ this._value = value;
895
+ }
896
+ this.update.emit({
897
+ component: this,
898
+ value: value,
899
+ options: Array.isArray(this.option) ? this.option : this.option ? [this.option] : null,
900
+ });
901
+ this.removeOption.emit({
902
+ component: this,
903
+ value: value,
904
+ removedOption: option,
905
+ });
906
+ e.preventDefault();
907
+ e.stopPropagation();
908
+ if (this.isOpen) {
909
+ this._focusSearchboxOrResultsElement();
910
+ }
911
+ }
912
+ /**
913
+ * Sets the model value. Implemented as part of ControlValueAccessor.
914
+ * @param value
915
+ */
916
+ writeValue(value) {
917
+ this._setSelectionByValue(value);
918
+ }
919
+ /**
920
+ * Saves a callback function to be invoked when the select's value
921
+ * changes from user input. Part of the ControlValueAccessor interface
922
+ * required to integrate with Angular's core forms API.
923
+ *
924
+ * @param fn Callback to be triggered when the value changes.
925
+ */
926
+ registerOnChange(fn) {
927
+ this._onChange = fn;
928
+ }
929
+ /**
930
+ * Saves a callback function to be invoked when the select is blurred
931
+ * by the user. Part of the ControlValueAccessor interface required
932
+ * to integrate with Angular's core forms API.
933
+ *
934
+ * @param fn Callback to be triggered when the component has been touched.
935
+ */
936
+ registerOnTouched(fn) {
937
+ this._onTouched = fn;
938
+ }
939
+ /**
940
+ * Sets whether the component should be disabled.
941
+ * Implemented as part of ControlValueAccessor.
942
+ * @param isDisabled
943
+ */
944
+ setDisabledState(isDisabled) {
945
+ this.disabled = isDisabled;
946
+ }
947
+ onScroll(way) {
948
+ this.scroll.emit({
949
+ component: this,
950
+ way,
951
+ search: this.innerSearchText,
952
+ });
953
+ }
954
+ _isErrorState() {
955
+ const isInvalid = this._control && this._control.invalid;
956
+ const isTouched = this._control && this._control.touched;
957
+ const isSubmitted = (this._parentFormGroup && this._parentFormGroup.submitted) ||
958
+ (this._parentForm && this._parentForm.submitted);
959
+ return !!(isInvalid && (isTouched || isSubmitted));
960
+ }
961
+ moveUp() {
962
+ this.updateScrollFromOption(Select2Utils.getPreviousOption(this.filteredData, this.hoveringValue));
963
+ }
964
+ moveDown() {
965
+ this.updateScrollFromOption(Select2Utils.getNextOption(this.filteredData, this.hoveringValue));
966
+ }
967
+ updateScrollFromOption(option) {
968
+ if (option) {
969
+ this.hoveringValue = option.value;
970
+ const domElement = this.results.find(r => r.nativeElement.innerText.trim() === option.label);
971
+ if (domElement && this.resultsElement) {
972
+ this.resultsElement.scrollTop = 0;
973
+ const listClientRect = this.resultsElement.getBoundingClientRect();
974
+ const optionClientRect = domElement.nativeElement.getBoundingClientRect();
975
+ this.resultsElement.scrollTop = optionClientRect.top - listClientRect.top;
976
+ }
977
+ }
978
+ }
979
+ selectByEnter() {
980
+ if (this.hoveringValue) {
981
+ const option = Select2Utils.getOptionByValue(this._data, this.hoveringValue);
982
+ this.select(option);
983
+ }
984
+ }
985
+ _testKey(event, refs = []) {
986
+ return this._isKey(this._getKey(event), refs);
987
+ }
988
+ _getKey(event) {
989
+ let code;
990
+ if (event.key !== undefined) {
991
+ code = event.key;
992
+ }
993
+ else if (event['keyIdentifier'] !== undefined) {
994
+ code = event['keyIdentifier'];
995
+ }
996
+ else if (event['keyCode'] !== undefined) {
997
+ code = event['keyCode'];
998
+ }
999
+ else {
1000
+ event.preventDefault();
1001
+ }
1002
+ return code;
1003
+ }
1004
+ _isKey(code, refs = []) {
1005
+ return refs && refs.length > 0 ? refs.indexOf(code) !== -1 : false;
1006
+ }
1007
+ /**
1008
+ * Sets the selected option based on a value. If no option can be
1009
+ * found with the designated value, the select trigger is cleared.
1010
+ */
1011
+ _setSelectionByValue(value) {
1012
+ if (this.option || (value !== undefined && value !== null)) {
1013
+ const isArray = Array.isArray(value);
1014
+ if (this.multiple && value && !isArray) {
1015
+ throw new Error('Non array value.');
1016
+ }
1017
+ else if (this._data) {
1018
+ if (this.multiple) {
1019
+ this.option = []; // if value is null, then empty option and return
1020
+ if (isArray) {
1021
+ // value is not null. Preselect value
1022
+ const selectedValues = Select2Utils.getOptionsByValue(this._data, value, this.multiple);
1023
+ selectedValues.map(item => this.select(item));
1024
+ }
1025
+ }
1026
+ else {
1027
+ this.select(Select2Utils.getOptionByValue(this._data, value));
1028
+ }
1029
+ }
1030
+ else if (this._control) {
1031
+ this._control.viewToModelUpdate(value);
1032
+ }
1033
+ this._changeDetectorRef.markForCheck();
1034
+ }
1035
+ }
1036
+ /** Does some manual dirty checking on the native input `value` property. */
1037
+ _dirtyCheckNativeValue() {
1038
+ const newValue = this.value;
1039
+ if (this._previousNativeValue !== newValue) {
1040
+ this._previousNativeValue = newValue;
1041
+ this._stateChanges.next();
1042
+ }
1043
+ }
1044
+ _coerceBooleanProperty(value) {
1045
+ return value != null && `${value}` !== 'false';
1046
+ }
1047
+ _focusSearchboxOrResultsElement() {
1048
+ if (!this.isSearchboxHidden) {
1049
+ setTimeout(() => {
1050
+ if (this.searchInput && this.searchInput.nativeElement) {
1051
+ this.searchInput.nativeElement.focus();
1052
+ }
1053
+ });
1054
+ }
1055
+ else if (this.resultsElement) {
1056
+ this.resultsElement.focus();
1057
+ }
1058
+ }
1059
+ _focus(state) {
1060
+ if (!state && this.focused) {
1061
+ this.focused = state;
1062
+ this.blur.emit(this);
1063
+ }
1064
+ else if (state && !this.focused) {
1065
+ this.focused = state;
1066
+ this.focus.emit(this);
1067
+ }
1068
+ }
1069
+ _isAbobeOverlay() {
1070
+ return this.overlay && this._overlayPosition && this.listPosition === 'auto'
1071
+ ? this._overlayPosition === 'top'
1072
+ : this.listPosition === 'above';
1073
+ }
1074
+ }
1075
+ /** @nocollapse */ /** @nocollapse */ Select2.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: Select2, deps: [{ token: i1.ViewportRuler }, { token: i0.ChangeDetectorRef }, { token: i2.NgForm, optional: true }, { token: i2.FormGroupDirective, optional: true }, { token: i2.NgControl, optional: true, self: true }, { token: 'tabindex', attribute: true }], target: i0.ɵɵFactoryTarget.Component });
1076
+ /** @nocollapse */ /** @nocollapse */ Select2.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.11", type: Select2, selector: "select2", inputs: { data: "data", minCharForSearch: "minCharForSearch", displaySearchStatus: "displaySearchStatus", placeholder: "placeholder", customSearchEnabled: "customSearchEnabled", limitSelection: "limitSelection", listPosition: "listPosition", multiple: "multiple", overlay: "overlay", styleMode: "styleMode", noResultMessage: "noResultMessage", maxResults: "maxResults", maxResultsMessage: "maxResultsMessage", infiniteScrollDistance: "infiniteScrollDistance", infiniteScrollThrottle: "infiniteScrollThrottle", infiniteScroll: "infiniteScroll", editPattern: "editPattern", templates: "templates", resultMaxHeight: "resultMaxHeight", minCountForSearch: "minCountForSearch", id: "id", required: "required", disabled: "disabled", hideSelectedItems: "hideSelectedItems", readonly: "readonly", value: "value", tabIndex: "tabIndex", resettable: "resettable" }, outputs: { update: "update", open: "open", close: "close", focus: "focus", blur: "blur", search: "search", scroll: "scroll", removeOption: "removeOption" }, host: { properties: { "id": "this.id", "attr.aria-invalid": "this.ariaInvalid", "class.material": "this.classMaterial", "class.nostyle": "this.classNostyle", "class.select2-above": "this.select2above" } }, viewQueries: [{ propertyName: "cdkConnectedOverlay", first: true, predicate: CdkConnectedOverlay, descendants: true }, { propertyName: "selection", first: true, predicate: ["selection"], descendants: true, static: true }, { propertyName: "resultContainer", first: true, predicate: ["results"], descendants: true }, { propertyName: "searchInput", first: true, predicate: ["searchInput"], descendants: true }, { propertyName: "dropdown", first: true, predicate: ["dropdown"], descendants: true }, { propertyName: "results", predicate: ["result"], descendants: true }], ngImport: i0, template: "<div class=\"select2-label\" (click)=\"toggleOpenAndClose()\">\n <ng-content select=\"select2-label\"></ng-content>\n <span *ngIf=\"required\" class=\"select2-required\"></span>\n</div>\n<div\n class=\"select2 select2-container select2-container--default select2-container--focus\"\n [class.select2-container--below]=\"!select2above\"\n [class.select2-container--above]=\"select2above\"\n [class.select2-container--open]=\"isOpen\"\n [class.select2-container--disabled]=\"disabled\"\n>\n <div\n class=\"selection\"\n #selection\n #trigger=\"cdkOverlayOrigin\"\n [attr.tabindex]=\"!this.isOpen ? tabIndex : '-1'\"\n (click)=\"toggleOpenAndClose()\"\n (focus)=\"focusin()\"\n (blur)=\"focusout()\"\n (keydown)=\"openKey($event)\"\n cdkOverlayOrigin\n [class.select2-focused]=\"focused\"\n >\n <div\n class=\"select2-selection\"\n [class.select2-selection--multiple]=\"multiple\"\n [class.select2-selection--single]=\"!multiple\"\n role=\"combobox\"\n >\n <span *ngIf=\"!multiple\" class=\"select2-selection__rendered\" [title]=\"select2Option?.label || ''\">\n <span *ngIf=\"!select2Option\">&nbsp;</span>\n <span *ngIf=\"select2Option\" [innerHTML]=\"select2Option.label\"></span>\n <span [class.select2-selection__placeholder__option]=\"option\" class=\"select2-selection__placeholder\">{{\n placeholder\n }}</span>\n </span>\n <span\n (click)=\"reset($event)\"\n *ngIf=\"!multiple && resettable && select2Option && !(disabled || readonly)\"\n class=\"select2-selection__reset\"\n role=\"presentation\"\n >\u00D7</span\n >\n <span *ngIf=\"!multiple\" class=\"select2-selection__arrow\" role=\"presentation\"> </span>\n <ul *ngIf=\"multiple\" class=\"select2-selection__rendered\">\n <span\n [class.select2-selection__placeholder__option]=\"select2Options?.length > 0\"\n class=\"select2-selection__placeholder\"\n >{{ placeholder }}</span\n >\n <li *ngFor=\"let op of option; trackBy: trackBy\" class=\"select2-selection__choice\" [title]=\"op.label\">\n <span\n *ngIf=\"!(disabled || readonly)\"\n (click)=\"removeSelection($event, op)\"\n class=\"select2-selection__choice__remove\"\n role=\"presentation\"\n >\u00D7</span\n >\n <span [innerHTML]=\"op.label\"></span>\n </li>\n </ul>\n </div>\n </div>\n <ng-container *ngIf=\"!overlay\">\n <ng-container *ngTemplateOutlet=\"containerTemplate\"></ng-container>\n </ng-container>\n\n <div class=\"select2-subscript-wrapper\">\n <ng-content select=\"select2-hint\"></ng-content>\n </div>\n</div>\n\n<ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayHasBackdrop\n cdkConnectedOverlayBackdropClass=\"select2-overlay-backdrop\"\n [cdkConnectedOverlayOrigin]=\"trigger\"\n [cdkConnectedOverlayOpen]=\"this.isOpen && overlay\"\n [cdkConnectedOverlayMinWidth]=\"overlayWidth\"\n [cdkConnectedOverlayHeight]=\"overlayHeight\"\n [cdkConnectedOverlayPositions]=\"_positions\"\n (backdropClick)=\"toggleOpenAndClose()\"\n>\n <ng-container *ngTemplateOutlet=\"containerTemplate\"></ng-container>\n</ng-template>\n\n<ng-template #containerTemplate>\n <div\n class=\"select2-container select2-container--default select2-container-dropdown\"\n [class.select2-container--open]=\"isOpen\"\n [class.select2-overlay]=\"overlay\"\n [class.select2-position-auto]=\"listPosition === 'auto'\"\n >\n <div\n #dropdown\n class=\"select2-dropdown\"\n [class.select2-dropdown--below]=\"!select2above\"\n [class.select2-dropdown--above]=\"select2above\"\n >\n <div class=\"select2-search select2-search--dropdown\" [class.select2-search--hide]=\"hideSearch()\">\n <input\n #searchInput\n [id]=\"id + '-search-field'\"\n [value]=\"searchText\"\n (keydown)=\"keyDown($event)\"\n (keyup)=\"searchUpdate($event)\"\n (change)=\"prevChange($event)\"\n class=\"select2-search__field\"\n type=\"search\"\n role=\"textbox\"\n autocomplete=\"off\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n spellcheck=\"false\"\n [attr.tabindex]=\"this.isOpen ? tabIndex : '-1'\"\n />\n </div>\n <div class=\"select2-results\">\n <ul\n #results\n class=\"select2-results__options\"\n [style.max-height]=\"resultMaxHeight\"\n role=\"tree\"\n tabindex=\"-1\"\n infiniteScroll\n [infiniteScrollDisabled]=\"!infiniteScroll && !isOpen\"\n [infiniteScrollDistance]=\"infiniteScrollDistance\"\n [infiniteScrollThrottle]=\"infiniteScrollThrottle\"\n [infiniteScrollContainer]=\"results\"\n (scrolled)=\"onScroll('down')\"\n (scrolledUp)=\"onScroll('up')\"\n (keydown)=\"keyDown($event)\"\n >\n <ng-container *ngFor=\"let groupOrOption of filteredData; index as i; trackBy: trackBy\">\n <li *ngIf=\"groupOrOption.options\" class=\"select2-results__option\" role=\"group\">\n <strong\n *ngIf=\"!hasTemplate(groupOrOption, 'group'); else optGroup\"\n [attr.class]=\"\n 'select2-results__group' +\n (groupOrOption.classes ? ' ' + groupOrOption.classes : '')\n \"\n [innerHTML]=\"groupOrOption.label\"\n ></strong>\n <ng-template #optGroup>\n <ng-container\n *ngTemplateOutlet=\"getTemplate(groupOrOption, 'group'); context: groupOrOption\"\n >\n </ng-container>\n </ng-template>\n\n <ul class=\"select2-results__options select2-results__options--nested\">\n <li\n *ngFor=\"let option of groupOrOption.options; index as j; trackBy: trackBy\"\n #result\n [id]=\"option.id || id + '-option-' + i + '-' + j\"\n [class]=\"getOptionStyle(option)\"\n role=\"treeitem\"\n [attr.aria-selected]=\"isSelected(option)\"\n [attr.aria-disabled]=\"isDisabled(option)\"\n (mouseenter)=\"mouseenter(option)\"\n (click)=\"click(option)\"\n >\n <div\n *ngIf=\"!hasTemplate(option, 'option'); else liGroup\"\n class=\"select2-label-content\"\n [innerHTML]=\"option.label\"\n ></div>\n <ng-template #liGroup>\n <ng-container\n *ngTemplateOutlet=\"getTemplate(option, 'option'); context: option\"\n >\n </ng-container>\n </ng-template>\n </li>\n </ul>\n </li>\n <li\n *ngIf=\"!groupOrOption.options\"\n #result\n [id]=\"groupOrOption.id || id + '-option-' + i\"\n [class]=\"getOptionStyle(groupOrOption)\"\n role=\"treeitem\"\n [attr.aria-selected]=\"isSelected(groupOrOption)\"\n [attr.aria-disabled]=\"isDisabled(groupOrOption)\"\n (mouseenter)=\"mouseenter(groupOrOption)\"\n (click)=\"click(groupOrOption)\"\n >\n <div\n *ngIf=\"!hasTemplate(groupOrOption, 'option'); else li\"\n [innerHTML]=\"groupOrOption.label\"\n class=\"select2-label-content\"\n ></div>\n <ng-template #li>\n <ng-container\n *ngTemplateOutlet=\"getTemplate(groupOrOption, 'option'); context: groupOrOption\"\n >\n </ng-container>\n </ng-template>\n </li>\n </ng-container>\n <li\n class=\"select2-no-result select2-results__option\"\n *ngIf=\"!filteredData?.length && noResultMessage\"\n [innerHTML]=\"noResultMessage\"\n ></li>\n <li\n class=\"select2-too-much-result select2-results__option\"\n *ngIf=\"maxResultsExceeded\"\n [innerHTML]=\"maxResultsMessage\"\n ></li>\n </ul>\n </div>\n </div>\n </div>\n</ng-template>\n", styles: [".select2-label{color:#000;color:var(--select2-label-text-color, #000)}.select2-container{box-sizing:border-box;display:inline-block;margin:0;position:relative;vertical-align:middle;width:100%}.select2-container .select2-container-dropdown{position:absolute;width:0px;opacity:0}.select2-container .select2-selection--single{box-sizing:border-box;cursor:pointer;display:block;height:28px;-webkit-user-select:none;user-select:none}.select2-container .select2-selection--single .select2-selection__rendered{display:block;padding:0 0 0 8px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex:1 1 auto}.select2-container .select2-selection--single .select2-selection__clear{position:relative}.select2-container .select2-selection--multiple{box-sizing:border-box;cursor:pointer;display:block;min-height:32px;-webkit-user-select:none;user-select:none}.select2-container .select2-selection--multiple .select2-selection__rendered{display:inline-block;overflow:hidden;padding-left:8px;text-overflow:ellipsis;white-space:nowrap}.select2-container .select2-search--inline{float:left}.select2-container .select2-search--inline .select2-search__field{box-sizing:border-box;border:none;font-size:100%;margin-top:5px;padding:0}.select2-container .select2-search--inline .select2-search__field::-webkit-search-cancel-button{-webkit-appearance:none}.select2-dropdown{background:white;background:var(--select2-dropdown-background, white);border:1px solid #aaa;border:1px solid var(--select2-dropdown-border-color, #aaa);border-radius:4px;border-radius:var(--select2-selection-border-radius, 4px);box-sizing:border-box;display:block;position:absolute;width:100%;z-index:1051;height:0;overflow:hidden}.select2-dropdown .select2-label-content{display:contents}.select2-results{display:block}.select2-results__options{list-style:none;margin:0;padding:0}.select2-results__option{padding:6px;-webkit-user-select:none;user-select:none;color:#000;color:var(--select2-option-text-color, #000)}.select2-results__option[aria-selected]{cursor:pointer}.select2-container.select2-container-dropdown.select2-container--open{width:100%;opacity:1}.select2-container--open .select2-dropdown{overflow:auto;height:auto}.select2-container--open .select2-dropdown--above{border-bottom:none;border-bottom-left-radius:0;border-bottom-right-radius:0;bottom:27px;display:flex;flex-direction:column-reverse}.select2-container--open .select2-dropdown--below{border-top:none;border-top-left-radius:0;border-top-right-radius:0}.select2-search--dropdown{display:block;padding:4px}.select2-search--dropdown .select2-search__field{padding:4px;width:100%;box-sizing:border-box}.select2-search--dropdown .select2-search__field::-webkit-search-cancel-button{-webkit-appearance:none}.select2-search--dropdown.select2-search--hide{display:none}.select2-close-mask{border:0;margin:0;padding:0;display:block;position:fixed;left:0;top:0;min-height:100%;min-width:100%;height:auto;width:auto;opacity:0;z-index:99;background:#fff;filter:alpha(opacity=0)}.select2-required:before{content:\"*\";color:red;color:var(--select2-required-color, red)}.select2-hidden-accessible{border:0!important;clip:rect(0 0 0 0)!important;height:1px!important;margin:-1px!important;overflow:hidden!important;padding:0!important;position:absolute!important;width:1px!important}.select2-container--default .select2-selection--single{background:#fff;background:var(--select2-selection-background, #fff);border:1px solid #aaa;border:1px solid var(--select2-selection-border-color, #aaa);border-radius:4px;border-radius:var(--select2-selection-border-radius, 4px);display:flex}.select2-container--default .select2-selection--single .select2-selection__rendered{color:#444;color:var(--select2-selection-text-color, #444);line-height:28px}.select2-container--default .select2-selection--single .select2-selection__clear{cursor:pointer;float:right;font-weight:700}.select2-container--default .select2-selection--single .select2-selection__placeholder{color:#999;color:var(--select2-placeholder-color, #999)}.select2-container--default .select2-selection--single .select2-selection__placeholder span{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;text-overflow:var(--select2-placeholder-overflow, ellipsis)}.select2-container--default .select2-selection--single .select2-selection__placeholder__option{display:none}.select2-container--default .select2-selection--single .select2-selection__reset,.select2-container--default .select2-selection--single .select2-selection__arrow{display:flex;width:20px;align-items:center;justify-content:center}.select2-container--default .select2-selection--single .select2-selection__arrow:before{content:\" \";border-color:#888 transparent;border-color:var(--select2-arrow-color, #888) transparent;border-style:solid;border-width:5px 4px 0;height:0;width:0}.select2-container--default .select2-selection--single .select2-selection__reset{color:#999;color:var(--select2-reset-color, #999)}.select2-container--default.select2-container--disabled .select2-selection--single{background:#eee;background:var(--select2-selection-disabled-background, #eee);cursor:default}.select2-container--default.select2-container--disabled .select2-selection--single .select2-selection__clear{display:none}.select2-container--default.select2-container--open .select2-selection--single .select2-selection__arrow:before{border-color:transparent transparent #888;border-color:transparent transparent var(--select2-arrow-color, #888);border-width:0 4px 5px}.select2-container--default .select2-selection--multiple{background:#fff;background:var(--select2-selection-background, #fff);border:1px solid #aaa;border:1px solid var(--select2-selection-border-color, #aaa);border-radius:4px;border-radius:var(--select2-selection-border-radius, 4px);cursor:text}.select2-container--default .select2-selection--multiple .select2-selection__rendered{flex:1 1 auto;box-sizing:border-box;list-style:none;margin:0;padding:0 5px;width:100%}.select2-container--default .select2-selection--multiple .select2-selection__rendered li{list-style:none}.select2-container--default .select2-selection--multiple .select2-selection__placeholder{display:block;width:100%;color:#999;color:var(--select2-placeholder-color, #999);margin-top:5px;float:left;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;text-overflow:var(--select2-placeholder-overflow, ellipsis)}.select2-container--default .select2-selection--multiple .select2-selection__placeholder__option{display:none}.select2-container--default .select2-selection--multiple .select2-selection__clear{cursor:pointer;float:right;font-weight:700;margin-top:5px;margin-right:10px}.select2-container--default .select2-selection--multiple .select2-selection__choice{color:#000;color:var(--select2-selection-choice-text-color, #000);background:#e4e4e4;background:var(--select2-selection-choice-background, #e4e4e4);border:1px solid #aaa;border:1px solid var(--select2-selection-choice-border-color, #aaa);border-radius:4px;border-radius:var(--select2-selection-border-radius, 4px);cursor:default;float:left;margin-right:5px;margin-top:5px;padding:0 5px}.select2-container--default .select2-selection--multiple .select2-selection__choice__remove{color:#999;color:var(--select2-selection-choice-close-color, #999);cursor:pointer;display:inline-block;font-weight:700;margin-right:2px}.select2-container--default .select2-selection--multiple .select2-selection__choice__remove:hover{color:#333;color:var(--select2-selection-choice-hover-close-color, #333)}.select2-container--default.select2-container--focused .select2-selection--multiple{border:solid #000 1px;border:solid var(--select2-selection-focus-border-color, #000) 1px;outline:none}.select2-container--default:not(.select2-container--open) .select2-focused .select2-selection--single,.select2-container--default:not(.select2-container--open) .select2-focused .select2-selection--multiple{border:solid #000 1px;border:solid var(--select2-selection-focus-border-color, #000) 1px;outline:none}.select2-container--default.select2-container--disabled .select2-selection--multiple{background:#eee;background:var(--select2-selection-disabled-background, #eee);cursor:default}.select2-container--default.select2-container--disabled .select2-selection__choice__remove{display:none}.select2-container--default.select2-container--open.select2-container--above .select2-selection--single,.select2-container--default.select2-container--open.select2-container--above .select2-selection--multiple{border-top-left-radius:0;border-top-right-radius:0}.select2-container--default.select2-container--open.select2-container--below .select2-selection--single,.select2-container--default.select2-container--open.select2-container--below .select2-selection--multiple{border-bottom-left-radius:0;border-bottom-right-radius:0}.select2-container--default .select2-search--dropdown .select2-search__field{border:1px solid #aaa;border:1px solid var(--select2-search-border-color, #aaa);background:#fff;background:1px solid var(--select2-search-background, #fff);border-radius:0;border-radius:var(--select2-search-border-radius, 0px)}.select2-container--default .select2-search--inline .select2-search__field{background:transparent;border:none;outline:none;box-shadow:none;-webkit-appearance:textfield}.select2-container--default .select2-results>.select2-results__options{overflow-y:auto}.select2-container--default .select2-results__option[role=group]{padding:0}.select2-container--default .select2-results__option[aria-disabled=true]{color:#999;color:var(--select2-option-disabled-text-color, #999);background:transparent;background:var(--select2-option-disabled-background, transparent)}.select2-container--default .select2-results__option[aria-selected=true]{color:#000;color:var(--select2-option-selected-text-color, #000);background:#ddd;background:var(--select2-option-selected-background, #ddd)}.select2-container--default .select2-results__option .select2-results__option{padding-left:1em}.select2-container--default .select2-results__option .select2-results__option .select2-results__group{padding-left:0}.select2-container--default .select2-results__option .select2-results__option .select2-results__option{margin-left:-1em;padding-left:2em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-2em;padding-left:3em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-3em;padding-left:4em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-4em;padding-left:5em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-5em;padding-left:6em}.select2-container--default .select2-results__option--highlighted[aria-selected]{background:#5897fb;background:var(--select2-option-highlighted-background, #5897fb);color:#fff;color:var(--select2-option-highlighted-text-color, #fff)}.select2-container--default .select2-results__option--hide{display:none}.select2-container--default .select2-results__group{cursor:default;display:block;padding:6px;color:gray;color:var(--select2-option-group-text-color, gray);background:transparent;background:var(--select2-option-group-background, transparent)}.select2-no-result{color:#888;color:var(--select2-no-result-color, #888);font-style:italic;font-style:var(--select2-no-result-font-style, italic)}.select2-too-much-result{color:#888;color:var(--select2-too-much-result-color, #888);font-style:italic;font-style:var(--select2-too-much-font-style, italic)}:host.nostyle .select2-dropdown{border-color:transparent}:host.nostyle .select2-selection--single,:host.nostyle .select2-selection--multiple{background:transparent;border-color:transparent}:host.nostyle .select2-container--default .select2-focused .select2-selection--single,:host.nostyle .select2-container--default .select2-focused .select2-selection--multiple,:host.nostyle .select2-container--default:not(.select2-container--open) .select2-focused .select2-selection--single,:host.nostyle .select2-container--default:not(.select2-container--open) .select2-focused .select2-selection--multiple{background:transparent;border-color:transparent}:host.material{display:inline-block;width:300px}:host.material>.select2-container{padding-bottom:1.29688em;vertical-align:inherit}:host.material>.select2-container .selection{padding:.4375em 0;border-top:.84375em solid transparent;display:inline-flex;align-items:baseline;width:100%;height:auto}:host.material .select2-container--default .select2-selection--single,:host.material .select2-container--default .select2-selection--multiple{width:100%;border:0;border-radius:0;height:24px;box-sizing:border-box}:host.material .select2-container--default .select2-selection--single:before,:host.material .select2-container--default .select2-selection--multiple:before{content:\" \";display:block;position:absolute;bottom:1.65em;background:#ddd;background:var(--select2-material-underline, #ddd);height:1px;width:100%}:host.material .select2-container--default .select2-selection--single:after,:host.material .select2-container--default .select2-selection--multiple:after{content:\" \";display:block;position:absolute;bottom:1.63em;background:#5a419e;background:var(--select2-material-underline-active, #5a419e);height:2px;width:0%;left:50%;transition:none}:host.material .select2-container--default .select2-selection--single .select2-selection__rendered,:host.material .select2-container--default .select2-selection--multiple .select2-selection__rendered{padding-left:1px;line-height:inherit}:host.material .select2-container--default .select2-selection--single .select2-selection__placeholder,:host.material .select2-container--default .select2-selection--multiple .select2-selection__placeholder{display:block;color:#00000061;color:var(--select2-material-placeholder-color, rgba(0, 0, 0, .38));transition:transform .3s;position:absolute;transform-origin:0 21px;left:0;top:20px}:host.material .select2-container--default .select2-container--open{left:0;bottom:1.6em}:host.material .select2-container--default .select2-selection__placeholder__option{transform:translateY(-1.5em) scale(.75) perspective(100px) translateZ(.001px);width:133.33333%}:host.material .select2-container--default .select2-selection__arrow{top:20px}:host.material .select2-container--default.select2-container--open .select2-selection--single:after,:host.material .select2-container--default.select2-container--open .select2-selection--multiple:after,:host.material .select2-container--default .select2-focused .select2-selection--single:after,:host.material .select2-container--default .select2-focused .select2-selection--multiple:after{transition:width .3s cubic-bezier(.12,1,.77,1),left .3s cubic-bezier(.12,1,.77,1);width:100%;left:0%}:host.material .select2-container--default .select2-dropdown{border-radius:0;border:0;box-shadow:0 5px 5px #00000080}:host.material .select2-container--default .select2-results__option[aria-selected=true],:host.material .select2-container--default .select2-results__option--highlighted[aria-selected]{background:rgba(0,0,0,.04);background:var(--select2-material-option-selected-background, rgba(0, 0, 0, .04));color:#000;color:var(--select2-material-option-highlighted-text-color, #000)}:host.material .select2-container--default .select2-results__option[aria-selected=true]{color:#ff5722;color:var(--select2-material-option-selected-text-color, #ff5722)}:host.material .select2-container--default.select2-container--disabled .select2-selection--single,:host.material .select2-container--default.select2-container--disabled .select2-selection--multiple{background:transparent}:host.material .select2-container--default.select2-container--disabled .select2-selection--single:before,:host.material .select2-container--default.select2-container--disabled .select2-selection--multiple:before{background:linear-gradient(to right,rgba(0,0,0,.26) 0,rgba(0,0,0,.26) 33%,transparent 0);background:var(--select2-material-underline-disabled, linear-gradient(to right, rgba(0, 0, 0, .26) 0, rgba(0, 0, 0, .26) 33%, transparent 0));background-size:4px 1px;background-repeat:repeat-x;background-position:0 bottom}:host.material.ng-invalid.ng-touched .select2-container--default .select2-selection--single:before,:host.material.ng-invalid.ng-touched .select2-container--default .select2-selection--single:after,:host.material.ng-invalid.ng-touched .select2-container--default .select2-selection--multiple:before,:host.material.ng-invalid.ng-touched .select2-container--default .select2-selection--multiple:after{background:red;background:var(--select2-material-underline-invalid, red)}:host.material:not(.select2-container--open) .select2-focused .select2-selection--single,:host.material:not(.select2-container--open) .select2-focused .select2-selection--multiple{border:0}:host.material .select2-subscript-wrapper{position:absolute;top:calc(100% - 1.72917em);font-size:75%;color:#888;color:var(--select2-hint-text-color, #888)}::ng-deep .select2-overlay-backdrop{background:rgba(0,0,0,.32);background:var(--select2-overlay-backdrop, transparent)}::ng-deep .cdk-overlay-container .select2-container .select2-dropdown.select2-dropdown--above{bottom:28px}::ng-deep .cdk-overlay-container .select2-container--open.select2-position-auto .select2-dropdown{margin-bottom:28px}::ng-deep .cdk-overlay-container .select2-container--open.select2-position-auto .select2-dropdown.select2-dropdown--above{bottom:0;margin-bottom:0;margin-top:28px}@supports (-moz-appearance: none){select2.material .select2-container--default .select2-selection--single,select2.material .select2-container--default .select2-selection--multiple{height:26px}}@supports (-ms-scroll-limit: 0){select2.material .select2-container--default .select2-selection--single,select2.material .select2-container--default .select2-selection--multiple{height:25px}}\n"], directives: [{ type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4.CdkOverlayOrigin, selector: "[cdk-overlay-origin], [overlay-origin], [cdkOverlayOrigin]", exportAs: ["cdkOverlayOrigin"] }, { type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i3.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i4.CdkConnectedOverlay, selector: "[cdk-connected-overlay], [connected-overlay], [cdkConnectedOverlay]", inputs: ["cdkConnectedOverlayOrigin", "cdkConnectedOverlayPositions", "cdkConnectedOverlayPositionStrategy", "cdkConnectedOverlayOffsetX", "cdkConnectedOverlayOffsetY", "cdkConnectedOverlayWidth", "cdkConnectedOverlayHeight", "cdkConnectedOverlayMinWidth", "cdkConnectedOverlayMinHeight", "cdkConnectedOverlayBackdropClass", "cdkConnectedOverlayPanelClass", "cdkConnectedOverlayViewportMargin", "cdkConnectedOverlayScrollStrategy", "cdkConnectedOverlayOpen", "cdkConnectedOverlayDisableClose", "cdkConnectedOverlayTransformOriginOn", "cdkConnectedOverlayHasBackdrop", "cdkConnectedOverlayLockPosition", "cdkConnectedOverlayFlexibleDimensions", "cdkConnectedOverlayGrowAfterOpen", "cdkConnectedOverlayPush"], outputs: ["backdropClick", "positionChange", "attach", "detach", "overlayKeydown", "overlayOutsideClick"], exportAs: ["cdkConnectedOverlay"] }, { type: i5.InfiniteScrollDirective, selector: "[infiniteScroll], [infinite-scroll], [data-infinite-scroll]", inputs: ["infiniteScrollDistance", "infiniteScrollUpDistance", "infiniteScrollThrottle", "infiniteScrollDisabled", "infiniteScrollContainer", "scrollWindow", "immediateCheck", "horizontal", "alwaysCallback", "fromRoot"], outputs: ["scrolled", "scrolledUp"] }] });
1077
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: Select2, decorators: [{
1078
+ type: Component,
1079
+ args: [{ selector: 'select2', template: "<div class=\"select2-label\" (click)=\"toggleOpenAndClose()\">\n <ng-content select=\"select2-label\"></ng-content>\n <span *ngIf=\"required\" class=\"select2-required\"></span>\n</div>\n<div\n class=\"select2 select2-container select2-container--default select2-container--focus\"\n [class.select2-container--below]=\"!select2above\"\n [class.select2-container--above]=\"select2above\"\n [class.select2-container--open]=\"isOpen\"\n [class.select2-container--disabled]=\"disabled\"\n>\n <div\n class=\"selection\"\n #selection\n #trigger=\"cdkOverlayOrigin\"\n [attr.tabindex]=\"!this.isOpen ? tabIndex : '-1'\"\n (click)=\"toggleOpenAndClose()\"\n (focus)=\"focusin()\"\n (blur)=\"focusout()\"\n (keydown)=\"openKey($event)\"\n cdkOverlayOrigin\n [class.select2-focused]=\"focused\"\n >\n <div\n class=\"select2-selection\"\n [class.select2-selection--multiple]=\"multiple\"\n [class.select2-selection--single]=\"!multiple\"\n role=\"combobox\"\n >\n <span *ngIf=\"!multiple\" class=\"select2-selection__rendered\" [title]=\"select2Option?.label || ''\">\n <span *ngIf=\"!select2Option\">&nbsp;</span>\n <span *ngIf=\"select2Option\" [innerHTML]=\"select2Option.label\"></span>\n <span [class.select2-selection__placeholder__option]=\"option\" class=\"select2-selection__placeholder\">{{\n placeholder\n }}</span>\n </span>\n <span\n (click)=\"reset($event)\"\n *ngIf=\"!multiple && resettable && select2Option && !(disabled || readonly)\"\n class=\"select2-selection__reset\"\n role=\"presentation\"\n >\u00D7</span\n >\n <span *ngIf=\"!multiple\" class=\"select2-selection__arrow\" role=\"presentation\"> </span>\n <ul *ngIf=\"multiple\" class=\"select2-selection__rendered\">\n <span\n [class.select2-selection__placeholder__option]=\"select2Options?.length > 0\"\n class=\"select2-selection__placeholder\"\n >{{ placeholder }}</span\n >\n <li *ngFor=\"let op of option; trackBy: trackBy\" class=\"select2-selection__choice\" [title]=\"op.label\">\n <span\n *ngIf=\"!(disabled || readonly)\"\n (click)=\"removeSelection($event, op)\"\n class=\"select2-selection__choice__remove\"\n role=\"presentation\"\n >\u00D7</span\n >\n <span [innerHTML]=\"op.label\"></span>\n </li>\n </ul>\n </div>\n </div>\n <ng-container *ngIf=\"!overlay\">\n <ng-container *ngTemplateOutlet=\"containerTemplate\"></ng-container>\n </ng-container>\n\n <div class=\"select2-subscript-wrapper\">\n <ng-content select=\"select2-hint\"></ng-content>\n </div>\n</div>\n\n<ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayHasBackdrop\n cdkConnectedOverlayBackdropClass=\"select2-overlay-backdrop\"\n [cdkConnectedOverlayOrigin]=\"trigger\"\n [cdkConnectedOverlayOpen]=\"this.isOpen && overlay\"\n [cdkConnectedOverlayMinWidth]=\"overlayWidth\"\n [cdkConnectedOverlayHeight]=\"overlayHeight\"\n [cdkConnectedOverlayPositions]=\"_positions\"\n (backdropClick)=\"toggleOpenAndClose()\"\n>\n <ng-container *ngTemplateOutlet=\"containerTemplate\"></ng-container>\n</ng-template>\n\n<ng-template #containerTemplate>\n <div\n class=\"select2-container select2-container--default select2-container-dropdown\"\n [class.select2-container--open]=\"isOpen\"\n [class.select2-overlay]=\"overlay\"\n [class.select2-position-auto]=\"listPosition === 'auto'\"\n >\n <div\n #dropdown\n class=\"select2-dropdown\"\n [class.select2-dropdown--below]=\"!select2above\"\n [class.select2-dropdown--above]=\"select2above\"\n >\n <div class=\"select2-search select2-search--dropdown\" [class.select2-search--hide]=\"hideSearch()\">\n <input\n #searchInput\n [id]=\"id + '-search-field'\"\n [value]=\"searchText\"\n (keydown)=\"keyDown($event)\"\n (keyup)=\"searchUpdate($event)\"\n (change)=\"prevChange($event)\"\n class=\"select2-search__field\"\n type=\"search\"\n role=\"textbox\"\n autocomplete=\"off\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n spellcheck=\"false\"\n [attr.tabindex]=\"this.isOpen ? tabIndex : '-1'\"\n />\n </div>\n <div class=\"select2-results\">\n <ul\n #results\n class=\"select2-results__options\"\n [style.max-height]=\"resultMaxHeight\"\n role=\"tree\"\n tabindex=\"-1\"\n infiniteScroll\n [infiniteScrollDisabled]=\"!infiniteScroll && !isOpen\"\n [infiniteScrollDistance]=\"infiniteScrollDistance\"\n [infiniteScrollThrottle]=\"infiniteScrollThrottle\"\n [infiniteScrollContainer]=\"results\"\n (scrolled)=\"onScroll('down')\"\n (scrolledUp)=\"onScroll('up')\"\n (keydown)=\"keyDown($event)\"\n >\n <ng-container *ngFor=\"let groupOrOption of filteredData; index as i; trackBy: trackBy\">\n <li *ngIf=\"groupOrOption.options\" class=\"select2-results__option\" role=\"group\">\n <strong\n *ngIf=\"!hasTemplate(groupOrOption, 'group'); else optGroup\"\n [attr.class]=\"\n 'select2-results__group' +\n (groupOrOption.classes ? ' ' + groupOrOption.classes : '')\n \"\n [innerHTML]=\"groupOrOption.label\"\n ></strong>\n <ng-template #optGroup>\n <ng-container\n *ngTemplateOutlet=\"getTemplate(groupOrOption, 'group'); context: groupOrOption\"\n >\n </ng-container>\n </ng-template>\n\n <ul class=\"select2-results__options select2-results__options--nested\">\n <li\n *ngFor=\"let option of groupOrOption.options; index as j; trackBy: trackBy\"\n #result\n [id]=\"option.id || id + '-option-' + i + '-' + j\"\n [class]=\"getOptionStyle(option)\"\n role=\"treeitem\"\n [attr.aria-selected]=\"isSelected(option)\"\n [attr.aria-disabled]=\"isDisabled(option)\"\n (mouseenter)=\"mouseenter(option)\"\n (click)=\"click(option)\"\n >\n <div\n *ngIf=\"!hasTemplate(option, 'option'); else liGroup\"\n class=\"select2-label-content\"\n [innerHTML]=\"option.label\"\n ></div>\n <ng-template #liGroup>\n <ng-container\n *ngTemplateOutlet=\"getTemplate(option, 'option'); context: option\"\n >\n </ng-container>\n </ng-template>\n </li>\n </ul>\n </li>\n <li\n *ngIf=\"!groupOrOption.options\"\n #result\n [id]=\"groupOrOption.id || id + '-option-' + i\"\n [class]=\"getOptionStyle(groupOrOption)\"\n role=\"treeitem\"\n [attr.aria-selected]=\"isSelected(groupOrOption)\"\n [attr.aria-disabled]=\"isDisabled(groupOrOption)\"\n (mouseenter)=\"mouseenter(groupOrOption)\"\n (click)=\"click(groupOrOption)\"\n >\n <div\n *ngIf=\"!hasTemplate(groupOrOption, 'option'); else li\"\n [innerHTML]=\"groupOrOption.label\"\n class=\"select2-label-content\"\n ></div>\n <ng-template #li>\n <ng-container\n *ngTemplateOutlet=\"getTemplate(groupOrOption, 'option'); context: groupOrOption\"\n >\n </ng-container>\n </ng-template>\n </li>\n </ng-container>\n <li\n class=\"select2-no-result select2-results__option\"\n *ngIf=\"!filteredData?.length && noResultMessage\"\n [innerHTML]=\"noResultMessage\"\n ></li>\n <li\n class=\"select2-too-much-result select2-results__option\"\n *ngIf=\"maxResultsExceeded\"\n [innerHTML]=\"maxResultsMessage\"\n ></li>\n </ul>\n </div>\n </div>\n </div>\n</ng-template>\n", styles: [".select2-label{color:#000;color:var(--select2-label-text-color, #000)}.select2-container{box-sizing:border-box;display:inline-block;margin:0;position:relative;vertical-align:middle;width:100%}.select2-container .select2-container-dropdown{position:absolute;width:0px;opacity:0}.select2-container .select2-selection--single{box-sizing:border-box;cursor:pointer;display:block;height:28px;-webkit-user-select:none;user-select:none}.select2-container .select2-selection--single .select2-selection__rendered{display:block;padding:0 0 0 8px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex:1 1 auto}.select2-container .select2-selection--single .select2-selection__clear{position:relative}.select2-container .select2-selection--multiple{box-sizing:border-box;cursor:pointer;display:block;min-height:32px;-webkit-user-select:none;user-select:none}.select2-container .select2-selection--multiple .select2-selection__rendered{display:inline-block;overflow:hidden;padding-left:8px;text-overflow:ellipsis;white-space:nowrap}.select2-container .select2-search--inline{float:left}.select2-container .select2-search--inline .select2-search__field{box-sizing:border-box;border:none;font-size:100%;margin-top:5px;padding:0}.select2-container .select2-search--inline .select2-search__field::-webkit-search-cancel-button{-webkit-appearance:none}.select2-dropdown{background:white;background:var(--select2-dropdown-background, white);border:1px solid #aaa;border:1px solid var(--select2-dropdown-border-color, #aaa);border-radius:4px;border-radius:var(--select2-selection-border-radius, 4px);box-sizing:border-box;display:block;position:absolute;width:100%;z-index:1051;height:0;overflow:hidden}.select2-dropdown .select2-label-content{display:contents}.select2-results{display:block}.select2-results__options{list-style:none;margin:0;padding:0}.select2-results__option{padding:6px;-webkit-user-select:none;user-select:none;color:#000;color:var(--select2-option-text-color, #000)}.select2-results__option[aria-selected]{cursor:pointer}.select2-container.select2-container-dropdown.select2-container--open{width:100%;opacity:1}.select2-container--open .select2-dropdown{overflow:auto;height:auto}.select2-container--open .select2-dropdown--above{border-bottom:none;border-bottom-left-radius:0;border-bottom-right-radius:0;bottom:27px;display:flex;flex-direction:column-reverse}.select2-container--open .select2-dropdown--below{border-top:none;border-top-left-radius:0;border-top-right-radius:0}.select2-search--dropdown{display:block;padding:4px}.select2-search--dropdown .select2-search__field{padding:4px;width:100%;box-sizing:border-box}.select2-search--dropdown .select2-search__field::-webkit-search-cancel-button{-webkit-appearance:none}.select2-search--dropdown.select2-search--hide{display:none}.select2-close-mask{border:0;margin:0;padding:0;display:block;position:fixed;left:0;top:0;min-height:100%;min-width:100%;height:auto;width:auto;opacity:0;z-index:99;background:#fff;filter:alpha(opacity=0)}.select2-required:before{content:\"*\";color:red;color:var(--select2-required-color, red)}.select2-hidden-accessible{border:0!important;clip:rect(0 0 0 0)!important;height:1px!important;margin:-1px!important;overflow:hidden!important;padding:0!important;position:absolute!important;width:1px!important}.select2-container--default .select2-selection--single{background:#fff;background:var(--select2-selection-background, #fff);border:1px solid #aaa;border:1px solid var(--select2-selection-border-color, #aaa);border-radius:4px;border-radius:var(--select2-selection-border-radius, 4px);display:flex}.select2-container--default .select2-selection--single .select2-selection__rendered{color:#444;color:var(--select2-selection-text-color, #444);line-height:28px}.select2-container--default .select2-selection--single .select2-selection__clear{cursor:pointer;float:right;font-weight:700}.select2-container--default .select2-selection--single .select2-selection__placeholder{color:#999;color:var(--select2-placeholder-color, #999)}.select2-container--default .select2-selection--single .select2-selection__placeholder span{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;text-overflow:var(--select2-placeholder-overflow, ellipsis)}.select2-container--default .select2-selection--single .select2-selection__placeholder__option{display:none}.select2-container--default .select2-selection--single .select2-selection__reset,.select2-container--default .select2-selection--single .select2-selection__arrow{display:flex;width:20px;align-items:center;justify-content:center}.select2-container--default .select2-selection--single .select2-selection__arrow:before{content:\" \";border-color:#888 transparent;border-color:var(--select2-arrow-color, #888) transparent;border-style:solid;border-width:5px 4px 0;height:0;width:0}.select2-container--default .select2-selection--single .select2-selection__reset{color:#999;color:var(--select2-reset-color, #999)}.select2-container--default.select2-container--disabled .select2-selection--single{background:#eee;background:var(--select2-selection-disabled-background, #eee);cursor:default}.select2-container--default.select2-container--disabled .select2-selection--single .select2-selection__clear{display:none}.select2-container--default.select2-container--open .select2-selection--single .select2-selection__arrow:before{border-color:transparent transparent #888;border-color:transparent transparent var(--select2-arrow-color, #888);border-width:0 4px 5px}.select2-container--default .select2-selection--multiple{background:#fff;background:var(--select2-selection-background, #fff);border:1px solid #aaa;border:1px solid var(--select2-selection-border-color, #aaa);border-radius:4px;border-radius:var(--select2-selection-border-radius, 4px);cursor:text}.select2-container--default .select2-selection--multiple .select2-selection__rendered{flex:1 1 auto;box-sizing:border-box;list-style:none;margin:0;padding:0 5px;width:100%}.select2-container--default .select2-selection--multiple .select2-selection__rendered li{list-style:none}.select2-container--default .select2-selection--multiple .select2-selection__placeholder{display:block;width:100%;color:#999;color:var(--select2-placeholder-color, #999);margin-top:5px;float:left;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;text-overflow:var(--select2-placeholder-overflow, ellipsis)}.select2-container--default .select2-selection--multiple .select2-selection__placeholder__option{display:none}.select2-container--default .select2-selection--multiple .select2-selection__clear{cursor:pointer;float:right;font-weight:700;margin-top:5px;margin-right:10px}.select2-container--default .select2-selection--multiple .select2-selection__choice{color:#000;color:var(--select2-selection-choice-text-color, #000);background:#e4e4e4;background:var(--select2-selection-choice-background, #e4e4e4);border:1px solid #aaa;border:1px solid var(--select2-selection-choice-border-color, #aaa);border-radius:4px;border-radius:var(--select2-selection-border-radius, 4px);cursor:default;float:left;margin-right:5px;margin-top:5px;padding:0 5px}.select2-container--default .select2-selection--multiple .select2-selection__choice__remove{color:#999;color:var(--select2-selection-choice-close-color, #999);cursor:pointer;display:inline-block;font-weight:700;margin-right:2px}.select2-container--default .select2-selection--multiple .select2-selection__choice__remove:hover{color:#333;color:var(--select2-selection-choice-hover-close-color, #333)}.select2-container--default.select2-container--focused .select2-selection--multiple{border:solid #000 1px;border:solid var(--select2-selection-focus-border-color, #000) 1px;outline:none}.select2-container--default:not(.select2-container--open) .select2-focused .select2-selection--single,.select2-container--default:not(.select2-container--open) .select2-focused .select2-selection--multiple{border:solid #000 1px;border:solid var(--select2-selection-focus-border-color, #000) 1px;outline:none}.select2-container--default.select2-container--disabled .select2-selection--multiple{background:#eee;background:var(--select2-selection-disabled-background, #eee);cursor:default}.select2-container--default.select2-container--disabled .select2-selection__choice__remove{display:none}.select2-container--default.select2-container--open.select2-container--above .select2-selection--single,.select2-container--default.select2-container--open.select2-container--above .select2-selection--multiple{border-top-left-radius:0;border-top-right-radius:0}.select2-container--default.select2-container--open.select2-container--below .select2-selection--single,.select2-container--default.select2-container--open.select2-container--below .select2-selection--multiple{border-bottom-left-radius:0;border-bottom-right-radius:0}.select2-container--default .select2-search--dropdown .select2-search__field{border:1px solid #aaa;border:1px solid var(--select2-search-border-color, #aaa);background:#fff;background:1px solid var(--select2-search-background, #fff);border-radius:0;border-radius:var(--select2-search-border-radius, 0px)}.select2-container--default .select2-search--inline .select2-search__field{background:transparent;border:none;outline:none;box-shadow:none;-webkit-appearance:textfield}.select2-container--default .select2-results>.select2-results__options{overflow-y:auto}.select2-container--default .select2-results__option[role=group]{padding:0}.select2-container--default .select2-results__option[aria-disabled=true]{color:#999;color:var(--select2-option-disabled-text-color, #999);background:transparent;background:var(--select2-option-disabled-background, transparent)}.select2-container--default .select2-results__option[aria-selected=true]{color:#000;color:var(--select2-option-selected-text-color, #000);background:#ddd;background:var(--select2-option-selected-background, #ddd)}.select2-container--default .select2-results__option .select2-results__option{padding-left:1em}.select2-container--default .select2-results__option .select2-results__option .select2-results__group{padding-left:0}.select2-container--default .select2-results__option .select2-results__option .select2-results__option{margin-left:-1em;padding-left:2em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-2em;padding-left:3em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-3em;padding-left:4em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-4em;padding-left:5em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-5em;padding-left:6em}.select2-container--default .select2-results__option--highlighted[aria-selected]{background:#5897fb;background:var(--select2-option-highlighted-background, #5897fb);color:#fff;color:var(--select2-option-highlighted-text-color, #fff)}.select2-container--default .select2-results__option--hide{display:none}.select2-container--default .select2-results__group{cursor:default;display:block;padding:6px;color:gray;color:var(--select2-option-group-text-color, gray);background:transparent;background:var(--select2-option-group-background, transparent)}.select2-no-result{color:#888;color:var(--select2-no-result-color, #888);font-style:italic;font-style:var(--select2-no-result-font-style, italic)}.select2-too-much-result{color:#888;color:var(--select2-too-much-result-color, #888);font-style:italic;font-style:var(--select2-too-much-font-style, italic)}:host.nostyle .select2-dropdown{border-color:transparent}:host.nostyle .select2-selection--single,:host.nostyle .select2-selection--multiple{background:transparent;border-color:transparent}:host.nostyle .select2-container--default .select2-focused .select2-selection--single,:host.nostyle .select2-container--default .select2-focused .select2-selection--multiple,:host.nostyle .select2-container--default:not(.select2-container--open) .select2-focused .select2-selection--single,:host.nostyle .select2-container--default:not(.select2-container--open) .select2-focused .select2-selection--multiple{background:transparent;border-color:transparent}:host.material{display:inline-block;width:300px}:host.material>.select2-container{padding-bottom:1.29688em;vertical-align:inherit}:host.material>.select2-container .selection{padding:.4375em 0;border-top:.84375em solid transparent;display:inline-flex;align-items:baseline;width:100%;height:auto}:host.material .select2-container--default .select2-selection--single,:host.material .select2-container--default .select2-selection--multiple{width:100%;border:0;border-radius:0;height:24px;box-sizing:border-box}:host.material .select2-container--default .select2-selection--single:before,:host.material .select2-container--default .select2-selection--multiple:before{content:\" \";display:block;position:absolute;bottom:1.65em;background:#ddd;background:var(--select2-material-underline, #ddd);height:1px;width:100%}:host.material .select2-container--default .select2-selection--single:after,:host.material .select2-container--default .select2-selection--multiple:after{content:\" \";display:block;position:absolute;bottom:1.63em;background:#5a419e;background:var(--select2-material-underline-active, #5a419e);height:2px;width:0%;left:50%;transition:none}:host.material .select2-container--default .select2-selection--single .select2-selection__rendered,:host.material .select2-container--default .select2-selection--multiple .select2-selection__rendered{padding-left:1px;line-height:inherit}:host.material .select2-container--default .select2-selection--single .select2-selection__placeholder,:host.material .select2-container--default .select2-selection--multiple .select2-selection__placeholder{display:block;color:#00000061;color:var(--select2-material-placeholder-color, rgba(0, 0, 0, .38));transition:transform .3s;position:absolute;transform-origin:0 21px;left:0;top:20px}:host.material .select2-container--default .select2-container--open{left:0;bottom:1.6em}:host.material .select2-container--default .select2-selection__placeholder__option{transform:translateY(-1.5em) scale(.75) perspective(100px) translateZ(.001px);width:133.33333%}:host.material .select2-container--default .select2-selection__arrow{top:20px}:host.material .select2-container--default.select2-container--open .select2-selection--single:after,:host.material .select2-container--default.select2-container--open .select2-selection--multiple:after,:host.material .select2-container--default .select2-focused .select2-selection--single:after,:host.material .select2-container--default .select2-focused .select2-selection--multiple:after{transition:width .3s cubic-bezier(.12,1,.77,1),left .3s cubic-bezier(.12,1,.77,1);width:100%;left:0%}:host.material .select2-container--default .select2-dropdown{border-radius:0;border:0;box-shadow:0 5px 5px #00000080}:host.material .select2-container--default .select2-results__option[aria-selected=true],:host.material .select2-container--default .select2-results__option--highlighted[aria-selected]{background:rgba(0,0,0,.04);background:var(--select2-material-option-selected-background, rgba(0, 0, 0, .04));color:#000;color:var(--select2-material-option-highlighted-text-color, #000)}:host.material .select2-container--default .select2-results__option[aria-selected=true]{color:#ff5722;color:var(--select2-material-option-selected-text-color, #ff5722)}:host.material .select2-container--default.select2-container--disabled .select2-selection--single,:host.material .select2-container--default.select2-container--disabled .select2-selection--multiple{background:transparent}:host.material .select2-container--default.select2-container--disabled .select2-selection--single:before,:host.material .select2-container--default.select2-container--disabled .select2-selection--multiple:before{background:linear-gradient(to right,rgba(0,0,0,.26) 0,rgba(0,0,0,.26) 33%,transparent 0);background:var(--select2-material-underline-disabled, linear-gradient(to right, rgba(0, 0, 0, .26) 0, rgba(0, 0, 0, .26) 33%, transparent 0));background-size:4px 1px;background-repeat:repeat-x;background-position:0 bottom}:host.material.ng-invalid.ng-touched .select2-container--default .select2-selection--single:before,:host.material.ng-invalid.ng-touched .select2-container--default .select2-selection--single:after,:host.material.ng-invalid.ng-touched .select2-container--default .select2-selection--multiple:before,:host.material.ng-invalid.ng-touched .select2-container--default .select2-selection--multiple:after{background:red;background:var(--select2-material-underline-invalid, red)}:host.material:not(.select2-container--open) .select2-focused .select2-selection--single,:host.material:not(.select2-container--open) .select2-focused .select2-selection--multiple{border:0}:host.material .select2-subscript-wrapper{position:absolute;top:calc(100% - 1.72917em);font-size:75%;color:#888;color:var(--select2-hint-text-color, #888)}::ng-deep .select2-overlay-backdrop{background:rgba(0,0,0,.32);background:var(--select2-overlay-backdrop, transparent)}::ng-deep .cdk-overlay-container .select2-container .select2-dropdown.select2-dropdown--above{bottom:28px}::ng-deep .cdk-overlay-container .select2-container--open.select2-position-auto .select2-dropdown{margin-bottom:28px}::ng-deep .cdk-overlay-container .select2-container--open.select2-position-auto .select2-dropdown.select2-dropdown--above{bottom:0;margin-bottom:0;margin-top:28px}@supports (-moz-appearance: none){select2.material .select2-container--default .select2-selection--single,select2.material .select2-container--default .select2-selection--multiple{height:26px}}@supports (-ms-scroll-limit: 0){select2.material .select2-container--default .select2-selection--single,select2.material .select2-container--default .select2-selection--multiple{height:25px}}\n"] }]
1080
+ }], ctorParameters: function () {
1081
+ return [{ type: i1.ViewportRuler }, { type: i0.ChangeDetectorRef }, { type: i2.NgForm, decorators: [{
1082
+ type: Optional
1083
+ }] }, { type: i2.FormGroupDirective, decorators: [{
1084
+ type: Optional
1085
+ }] }, { type: i2.NgControl, decorators: [{
1086
+ type: Self
1087
+ }, {
1088
+ type: Optional
1089
+ }] }, { type: undefined, decorators: [{
1090
+ type: Attribute,
1091
+ args: ['tabindex']
1092
+ }] }];
1093
+ }, propDecorators: { data: [{
1094
+ type: Input
1095
+ }], minCharForSearch: [{
1096
+ type: Input
1097
+ }], displaySearchStatus: [{
1098
+ type: Input
1099
+ }], placeholder: [{
1100
+ type: Input
1101
+ }], customSearchEnabled: [{
1102
+ type: Input
1103
+ }], limitSelection: [{
1104
+ type: Input
1105
+ }], listPosition: [{
1106
+ type: Input
1107
+ }], multiple: [{
1108
+ type: Input
1109
+ }], overlay: [{
1110
+ type: Input
1111
+ }], styleMode: [{
1112
+ type: Input
1113
+ }], noResultMessage: [{
1114
+ type: Input
1115
+ }], maxResults: [{
1116
+ type: Input
1117
+ }], maxResultsMessage: [{
1118
+ type: Input
1119
+ }], infiniteScrollDistance: [{
1120
+ type: Input
1121
+ }], infiniteScrollThrottle: [{
1122
+ type: Input
1123
+ }], infiniteScroll: [{
1124
+ type: Input
1125
+ }], editPattern: [{
1126
+ type: Input
1127
+ }], templates: [{
1128
+ type: Input
1129
+ }], resultMaxHeight: [{
1130
+ type: Input
1131
+ }], update: [{
1132
+ type: Output
1133
+ }], open: [{
1134
+ type: Output
1135
+ }], close: [{
1136
+ type: Output
1137
+ }], focus: [{
1138
+ type: Output
1139
+ }], blur: [{
1140
+ type: Output
1141
+ }], search: [{
1142
+ type: Output
1143
+ }], scroll: [{
1144
+ type: Output
1145
+ }], removeOption: [{
1146
+ type: Output
1147
+ }], minCountForSearch: [{
1148
+ type: Input
1149
+ }], id: [{
1150
+ type: Input
1151
+ }, {
1152
+ type: HostBinding,
1153
+ args: ['id']
1154
+ }], required: [{
1155
+ type: Input
1156
+ }], disabled: [{
1157
+ type: Input
1158
+ }], hideSelectedItems: [{
1159
+ type: Input
1160
+ }], readonly: [{
1161
+ type: Input
1162
+ }], value: [{
1163
+ type: Input
1164
+ }], tabIndex: [{
1165
+ type: Input
1166
+ }], resettable: [{
1167
+ type: Input
1168
+ }], ariaInvalid: [{
1169
+ type: HostBinding,
1170
+ args: ['attr.aria-invalid']
1171
+ }], classMaterial: [{
1172
+ type: HostBinding,
1173
+ args: ['class.material']
1174
+ }], classNostyle: [{
1175
+ type: HostBinding,
1176
+ args: ['class.nostyle']
1177
+ }], select2above: [{
1178
+ type: HostBinding,
1179
+ args: ['class.select2-above']
1180
+ }], cdkConnectedOverlay: [{
1181
+ type: ViewChild,
1182
+ args: [CdkConnectedOverlay]
1183
+ }], selection: [{
1184
+ type: ViewChild,
1185
+ args: ['selection', { static: true }]
1186
+ }], resultContainer: [{
1187
+ type: ViewChild,
1188
+ args: ['results']
1189
+ }], results: [{
1190
+ type: ViewChildren,
1191
+ args: ['result']
1192
+ }], searchInput: [{
1193
+ type: ViewChild,
1194
+ args: ['searchInput']
1195
+ }], dropdown: [{
1196
+ type: ViewChild,
1197
+ args: ['dropdown']
1198
+ }] } });
1199
+
1200
+ class Select2Hint {
1201
+ }
1202
+ /** @nocollapse */ /** @nocollapse */ Select2Hint.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: Select2Hint, deps: [], target: i0.ɵɵFactoryTarget.Directive });
1203
+ /** @nocollapse */ /** @nocollapse */ Select2Hint.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.11", type: Select2Hint, selector: "select2-hint", ngImport: i0 });
1204
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: Select2Hint, decorators: [{
1205
+ type: Directive,
1206
+ args: [{ selector: 'select2-hint' }]
1207
+ }] });
1208
+
1209
+ class Select2Label {
1210
+ }
1211
+ /** @nocollapse */ /** @nocollapse */ Select2Label.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: Select2Label, deps: [], target: i0.ɵɵFactoryTarget.Directive });
1212
+ /** @nocollapse */ /** @nocollapse */ Select2Label.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.11", type: Select2Label, selector: "select2-label", ngImport: i0 });
1213
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: Select2Label, decorators: [{
1214
+ type: Directive,
1215
+ args: [{ selector: 'select2-label' }]
1216
+ }] });
1217
+
1218
+ class Select2Module {
1219
+ }
1220
+ /** @nocollapse */ /** @nocollapse */ Select2Module.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: Select2Module, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1221
+ /** @nocollapse */ /** @nocollapse */ Select2Module.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: Select2Module, declarations: [Select2Hint, Select2Label, Select2], imports: [CommonModule, FormsModule, OverlayModule, ReactiveFormsModule, InfiniteScrollModule], exports: [FormsModule, ReactiveFormsModule, Select2Hint, Select2Label, Select2] });
1222
+ /** @nocollapse */ /** @nocollapse */ Select2Module.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: Select2Module, imports: [[CommonModule, FormsModule, OverlayModule, ReactiveFormsModule, InfiniteScrollModule], FormsModule, ReactiveFormsModule] });
1223
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: Select2Module, decorators: [{
1224
+ type: NgModule,
1225
+ args: [{
1226
+ imports: [CommonModule, FormsModule, OverlayModule, ReactiveFormsModule, InfiniteScrollModule],
1227
+ declarations: [Select2Hint, Select2Label, Select2],
1228
+ exports: [FormsModule, ReactiveFormsModule, Select2Hint, Select2Label, Select2],
1229
+ }]
1230
+ }] });
1231
+
1232
+ /*
1233
+ * Public API Surface of ng-select2-component
1234
+ */
1235
+
1236
+ /**
1237
+ * Generated bundle index. Do not edit.
1238
+ */
1239
+
1240
+ export { Select2, Select2Hint, Select2Label, Select2Module, Select2Utils, defaultMinCountForSearch, protectRegexp, timeout, unicodePatterns };
1241
+ //# sourceMappingURL=ng-select2-component.mjs.map