@progress/kendo-angular-dropdowns 12.0.0-develop.6 → 12.0.0-develop.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/autocomplete/autocomplete.component.d.ts +82 -20
- package/comboboxes/combobox.component.d.ts +76 -8
- package/comboboxes/multicolumncombobox.component.d.ts +4 -0
- package/common/action-sheet.component.d.ts +43 -0
- package/common/list.component.d.ts +2 -1
- package/common/localization/messages.d.ts +9 -1
- package/common/selection/selectable.directive.d.ts +2 -1
- package/common/shared.module.d.ts +11 -7
- package/common/util.d.ts +39 -2
- package/dropdownlist/dropdownlist.component.d.ts +78 -9
- package/dropdowntrees/dropdowntree.component.d.ts +80 -8
- package/dropdowntrees/multiselecttree.component.d.ts +90 -6
- package/esm2020/autocomplete/autocomplete.component.mjs +294 -116
- package/esm2020/comboboxes/combobox.component.mjs +251 -60
- package/esm2020/comboboxes/multicolumncombobox.component.mjs +110 -119
- package/esm2020/common/action-sheet.component.mjs +243 -0
- package/esm2020/common/list.component.mjs +11 -2
- package/esm2020/common/localization/messages.mjs +5 -1
- package/esm2020/common/selection/selectable.directive.mjs +3 -3
- package/esm2020/common/shared.module.mjs +13 -6
- package/esm2020/common/util.mjs +68 -2
- package/esm2020/dropdownlist/dropdownlist.component.mjs +245 -64
- package/esm2020/dropdowntrees/dropdowntree.component.mjs +254 -56
- package/esm2020/dropdowntrees/multiselecttree.component.mjs +291 -55
- package/esm2020/index.mjs +1 -0
- package/esm2020/multiselect/multiselect.component.mjs +320 -88
- package/esm2020/package-metadata.mjs +2 -2
- package/fesm2015/progress-kendo-angular-dropdowns.mjs +2085 -552
- package/fesm2020/progress-kendo-angular-dropdowns.mjs +2054 -545
- package/index.d.ts +2 -0
- package/multiselect/multiselect.component.d.ts +87 -10
- package/package.json +9 -8
- package/schematics/ngAdd/index.js +2 -2
|
@@ -16,8 +16,8 @@ import { FixedGroupTemplateDirective } from '../common/templates/fixed-group-tem
|
|
|
16
16
|
import { SelectionService } from '../common/selection/selection.service';
|
|
17
17
|
import { NavigationService } from '../common/navigation/navigation.service';
|
|
18
18
|
import { DisabledItemsService } from '../common/disabled-items/disabled-items.service';
|
|
19
|
-
import { Subject, merge } from 'rxjs';
|
|
20
|
-
import { isPresent, guid, getter, isUntouched, noop, inDropDown, getSizeClass, getRoundedClass, getFillModeClass } from '../common/util';
|
|
19
|
+
import { Subject, Subscription, merge } from 'rxjs';
|
|
20
|
+
import { isPresent, guid, getter, isUntouched, noop, inDropDown, getSizeClass, getRoundedClass, getFillModeClass, windowSize, isTruthy, setListBoxAriaLabelLebBy, setActionSheetTitle, updateActionSheetAdaptiveAppearance, animationDuration } from '../common/util';
|
|
21
21
|
import { NavigationAction } from '../common/navigation/navigation-action';
|
|
22
22
|
import { NoDataTemplateDirective } from '../common/templates/no-data-template.directive';
|
|
23
23
|
import { PreventableEvent } from '../common/models/preventable-event';
|
|
@@ -29,6 +29,7 @@ import { ListComponent } from '../common/list.component';
|
|
|
29
29
|
import { normalizeVirtualizationSettings } from '../common/models/virtualization-settings';
|
|
30
30
|
import { TOUCH_ENABLED } from '../common/constants/touch-enabled';
|
|
31
31
|
import { xIcon } from '@progress/kendo-svg-icons';
|
|
32
|
+
import { ResponsiveRendererComponent } from '../common/action-sheet.component';
|
|
32
33
|
import * as i0 from "@angular/core";
|
|
33
34
|
import * as i1 from "@progress/kendo-angular-l10n";
|
|
34
35
|
import * as i2 from "../common/data.service";
|
|
@@ -38,11 +39,12 @@ import * as i5 from "../common/navigation/navigation.service";
|
|
|
38
39
|
import * as i6 from "../common/disabled-items/disabled-items.service";
|
|
39
40
|
import * as i7 from "../common/searchbar.component";
|
|
40
41
|
import * as i8 from "@progress/kendo-angular-icons";
|
|
41
|
-
import * as i9 from "
|
|
42
|
-
import * as i10 from "
|
|
43
|
-
import * as i11 from "../common/
|
|
44
|
-
import * as i12 from "
|
|
45
|
-
import * as i13 from "
|
|
42
|
+
import * as i9 from "@progress/kendo-angular-common";
|
|
43
|
+
import * as i10 from "../common/action-sheet.component";
|
|
44
|
+
import * as i11 from "../common/list.component";
|
|
45
|
+
import * as i12 from "../common/localization/localized-messages.directive";
|
|
46
|
+
import * as i13 from "@angular/common";
|
|
47
|
+
import * as i14 from "../common/templates/template-context.directive";
|
|
46
48
|
const NO_VALUE = "";
|
|
47
49
|
const DEFAULT_SIZE = 'medium';
|
|
48
50
|
const DEFAULT_ROUNDED = 'medium';
|
|
@@ -88,6 +90,10 @@ export class AutoCompleteComponent {
|
|
|
88
90
|
this.renderer = renderer;
|
|
89
91
|
this.hostElement = hostElement;
|
|
90
92
|
this.touchEnabled = touchEnabled;
|
|
93
|
+
/**
|
|
94
|
+
* @hidden
|
|
95
|
+
*/
|
|
96
|
+
this.animationDuration = animationDuration;
|
|
91
97
|
/**
|
|
92
98
|
* @hidden
|
|
93
99
|
*/
|
|
@@ -106,12 +112,15 @@ export class AutoCompleteComponent {
|
|
|
106
112
|
*/
|
|
107
113
|
this.placeholder = "";
|
|
108
114
|
/**
|
|
109
|
-
*
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
115
|
+
* Enables or disables the adaptive mode. By default the adaptive rendering is disabled.
|
|
116
|
+
*/
|
|
117
|
+
this.adaptiveMode = 'none';
|
|
118
|
+
/**
|
|
119
|
+
* Sets the title of the ActionSheet that is rendered instead of the Popup when using small screen devices.
|
|
120
|
+
* By default the ActionSheet title uses the text provided for the label of the AutoComplete.
|
|
113
121
|
*/
|
|
114
|
-
this.
|
|
122
|
+
this.title = '';
|
|
123
|
+
this._listHeight = 200;
|
|
115
124
|
/**
|
|
116
125
|
* @hidden
|
|
117
126
|
*
|
|
@@ -180,12 +189,17 @@ export class AutoCompleteComponent {
|
|
|
180
189
|
this.widgetClasses = true;
|
|
181
190
|
this.listBoxId = `k-${guid()}`;
|
|
182
191
|
this.optionPrefix = `k-${guid()}`;
|
|
192
|
+
/**
|
|
193
|
+
* @hidden
|
|
194
|
+
*/
|
|
195
|
+
this.windowSize = 'large';
|
|
183
196
|
this.onChangeCallback = noop;
|
|
184
197
|
this.onTouchedCallback = noop;
|
|
185
198
|
this.popupMouseDownHandler = (event) => event.preventDefault();
|
|
186
199
|
this._popupSettings = { animate: true };
|
|
187
200
|
this._open = false;
|
|
188
201
|
this._value = "";
|
|
202
|
+
this.subs = new Subscription();
|
|
189
203
|
this.valueChangeSubject = new Subject();
|
|
190
204
|
this._isFocused = false;
|
|
191
205
|
this._size = 'medium';
|
|
@@ -199,6 +213,18 @@ export class AutoCompleteComponent {
|
|
|
199
213
|
this.subscribeTouchEvents();
|
|
200
214
|
this.selectionService.resetSelection([-1]);
|
|
201
215
|
}
|
|
216
|
+
/**
|
|
217
|
+
* @hidden
|
|
218
|
+
*/
|
|
219
|
+
get actionSheet() {
|
|
220
|
+
return this.responsiveRendererComponent?.actionSheet;
|
|
221
|
+
}
|
|
222
|
+
/**
|
|
223
|
+
* @hidden
|
|
224
|
+
*/
|
|
225
|
+
get actionSheetSearchBar() {
|
|
226
|
+
return this.responsiveRendererComponent?.actionSheetSearchBar;
|
|
227
|
+
}
|
|
202
228
|
get width() {
|
|
203
229
|
let wrapperOffsetWidth = 0;
|
|
204
230
|
if (isDocumentAvailable()) {
|
|
@@ -247,8 +273,8 @@ export class AutoCompleteComponent {
|
|
|
247
273
|
return this.isOpen ? this.listBoxId : undefined;
|
|
248
274
|
}
|
|
249
275
|
/**
|
|
250
|
-
* Toggles the visibility of the popup.
|
|
251
|
-
* If you use the `toggle` method to open or close the popup, the `open` and `close` events will not be fired.
|
|
276
|
+
* Toggles the visibility of the popup or actionSheet.
|
|
277
|
+
* If you use the `toggle` method to open or close the popup or actionSheet, the `open` and `close` events will not be fired.
|
|
252
278
|
*
|
|
253
279
|
* @param open - The state of the popup.
|
|
254
280
|
*/
|
|
@@ -259,10 +285,19 @@ export class AutoCompleteComponent {
|
|
|
259
285
|
});
|
|
260
286
|
}
|
|
261
287
|
/**
|
|
262
|
-
* Returns the current open state
|
|
288
|
+
* Returns the current open state. Returns `true` if the popup or actionSheet is open.
|
|
263
289
|
*/
|
|
264
290
|
get isOpen() {
|
|
265
|
-
return this._open;
|
|
291
|
+
return isTruthy(this._open || this.isActionSheetExpanded);
|
|
292
|
+
}
|
|
293
|
+
/**
|
|
294
|
+
* @hidden
|
|
295
|
+
*/
|
|
296
|
+
handleClick() {
|
|
297
|
+
this.windowSize = windowSize();
|
|
298
|
+
if (this.isAdaptive) {
|
|
299
|
+
this.togglePopup(true);
|
|
300
|
+
}
|
|
266
301
|
}
|
|
267
302
|
/**
|
|
268
303
|
* @hidden
|
|
@@ -325,6 +360,22 @@ export class AutoCompleteComponent {
|
|
|
325
360
|
get value() {
|
|
326
361
|
return this._value || NO_VALUE;
|
|
327
362
|
}
|
|
363
|
+
/**
|
|
364
|
+
* Sets the subtitle of the ActionSheet that is rendered instead of the Popup when using small screen devices.
|
|
365
|
+
* By default the ActionSheet subtitle uses the text provided for the `placeholder` of the AutoComplete.
|
|
366
|
+
*/
|
|
367
|
+
set subtitle(_subtitle) {
|
|
368
|
+
this._subtitle = _subtitle;
|
|
369
|
+
}
|
|
370
|
+
get subtitle() {
|
|
371
|
+
return this._subtitle || this.placeholder;
|
|
372
|
+
}
|
|
373
|
+
/**
|
|
374
|
+
* @hidden
|
|
375
|
+
*/
|
|
376
|
+
get isAdaptiveModeEnabled() {
|
|
377
|
+
return this.adaptiveMode === 'auto';
|
|
378
|
+
}
|
|
328
379
|
/**
|
|
329
380
|
* Configures the popup of the AutoComplete.
|
|
330
381
|
*
|
|
@@ -341,6 +392,24 @@ export class AutoCompleteComponent {
|
|
|
341
392
|
get popupSettings() {
|
|
342
393
|
return this._popupSettings;
|
|
343
394
|
}
|
|
395
|
+
/**
|
|
396
|
+
* Sets the height of the options list in the popup. By default, `listHeight` is 200px.
|
|
397
|
+
*
|
|
398
|
+
* > The `listHeight` property affects only the list of options and not the whole popup container.
|
|
399
|
+
* > To set the height of the popup container, use `popupSettings.height`.
|
|
400
|
+
*
|
|
401
|
+
* > When using `adaptiveMode` and the screen size is `small` or `medium` the `listHeight` property is set to null.
|
|
402
|
+
*/
|
|
403
|
+
set listHeight(_listHeight) {
|
|
404
|
+
this._listHeight = _listHeight;
|
|
405
|
+
}
|
|
406
|
+
;
|
|
407
|
+
get listHeight() {
|
|
408
|
+
if (this.isAdaptive) {
|
|
409
|
+
return;
|
|
410
|
+
}
|
|
411
|
+
return this._listHeight;
|
|
412
|
+
}
|
|
344
413
|
/**
|
|
345
414
|
* Defines a Boolean function that is executed for each data item in the component
|
|
346
415
|
* ([see examples]({% slug disableditems_autocomplete %})).
|
|
@@ -450,21 +519,39 @@ export class AutoCompleteComponent {
|
|
|
450
519
|
get dir() {
|
|
451
520
|
return this.direction;
|
|
452
521
|
}
|
|
522
|
+
/**
|
|
523
|
+
* @hidden
|
|
524
|
+
*/
|
|
525
|
+
get isActionSheetExpanded() {
|
|
526
|
+
return this.actionSheet?.expanded;
|
|
527
|
+
}
|
|
528
|
+
;
|
|
529
|
+
/**
|
|
530
|
+
* @hidden
|
|
531
|
+
*/
|
|
532
|
+
get isAdaptive() {
|
|
533
|
+
return this.isAdaptiveModeEnabled && this.windowSize !== 'large';
|
|
534
|
+
}
|
|
453
535
|
ngOnInit() {
|
|
454
536
|
this.renderer.removeAttribute(this.wrapper, "tabindex");
|
|
455
|
-
this.
|
|
537
|
+
this.subs.add(this.localization
|
|
456
538
|
.changes
|
|
457
539
|
.subscribe(({ rtl }) => {
|
|
458
540
|
this.direction = rtl ? 'rtl' : 'ltr';
|
|
459
541
|
this.cdr.detectChanges();
|
|
460
|
-
});
|
|
542
|
+
}));
|
|
461
543
|
this.setComponentClasses();
|
|
462
544
|
}
|
|
545
|
+
ngAfterViewInit() {
|
|
546
|
+
this.windowSize = windowSize();
|
|
547
|
+
this.cdr.detectChanges();
|
|
548
|
+
this.renderer.setAttribute(this.actionSheet?.element.nativeElement, 'style', '--kendo-actionsheet-height: 60vh; --kendo-actionsheet-max-height: none');
|
|
549
|
+
}
|
|
463
550
|
ngOnDestroy() {
|
|
464
551
|
this.destroyPopup();
|
|
465
|
-
this.
|
|
466
|
-
if (this.
|
|
467
|
-
this.
|
|
552
|
+
this.subs.unsubscribe();
|
|
553
|
+
if (this.touchstartDisposeHandler) {
|
|
554
|
+
this.touchstartDisposeHandler();
|
|
468
555
|
}
|
|
469
556
|
}
|
|
470
557
|
ngOnChanges(changes) {
|
|
@@ -488,6 +575,12 @@ export class AutoCompleteComponent {
|
|
|
488
575
|
messageFor(key) {
|
|
489
576
|
return this.localization.get(key);
|
|
490
577
|
}
|
|
578
|
+
/**
|
|
579
|
+
* @hidden
|
|
580
|
+
*/
|
|
581
|
+
onAdaptiveTextBoxChange(text) {
|
|
582
|
+
this.search(text);
|
|
583
|
+
}
|
|
491
584
|
/**
|
|
492
585
|
* @hidden
|
|
493
586
|
*/
|
|
@@ -557,7 +650,14 @@ export class AutoCompleteComponent {
|
|
|
557
650
|
* @hidden
|
|
558
651
|
*/
|
|
559
652
|
onResize() {
|
|
560
|
-
if (this.
|
|
653
|
+
if (this.isAdaptiveModeEnabled && this.windowSize !== windowSize()) {
|
|
654
|
+
if (this.isOpen) {
|
|
655
|
+
this.togglePopup(false);
|
|
656
|
+
}
|
|
657
|
+
this.windowSize = windowSize();
|
|
658
|
+
this.cdr.detectChanges();
|
|
659
|
+
}
|
|
660
|
+
if (this._open && !this.isActionSheetExpanded) {
|
|
561
661
|
const popupWrapper = this.popupRef.popupElement;
|
|
562
662
|
const { min, max } = this.width;
|
|
563
663
|
popupWrapper.style.minWidth = min;
|
|
@@ -577,13 +677,7 @@ export class AutoCompleteComponent {
|
|
|
577
677
|
}
|
|
578
678
|
}
|
|
579
679
|
search(text, startFrom = 0) {
|
|
580
|
-
|
|
581
|
-
if (text.length && this.dataService.itemsCount) {
|
|
582
|
-
index = this.dataService.findIndex(this.findIndexPredicate(text), startFrom);
|
|
583
|
-
}
|
|
584
|
-
else {
|
|
585
|
-
index = -1;
|
|
586
|
-
}
|
|
680
|
+
const index = this.findIndex(text, startFrom);
|
|
587
681
|
if (this.disabledItemsService.isIndexDisabled(index)) {
|
|
588
682
|
if (index + 1 < this.dataService.itemsCount) {
|
|
589
683
|
this.search(text, index + 1);
|
|
@@ -631,6 +725,10 @@ export class AutoCompleteComponent {
|
|
|
631
725
|
((action === NavigationAction.Enter && this.isOpen) || action !== NavigationAction.Enter)) {
|
|
632
726
|
event.preventDefault();
|
|
633
727
|
}
|
|
728
|
+
if (action === NavigationAction.Tab && this.isActionSheetExpanded) {
|
|
729
|
+
event.stopImmediatePropagation();
|
|
730
|
+
this.togglePopup(false);
|
|
731
|
+
}
|
|
634
732
|
}
|
|
635
733
|
handleEnter(event) {
|
|
636
734
|
const focused = this.selectionService.focused;
|
|
@@ -651,6 +749,9 @@ export class AutoCompleteComponent {
|
|
|
651
749
|
value = this.searchbar.value;
|
|
652
750
|
}
|
|
653
751
|
}
|
|
752
|
+
if (this.isActionSheetExpanded && focused >= 0) {
|
|
753
|
+
this.togglePopup(false);
|
|
754
|
+
}
|
|
654
755
|
this.change(value);
|
|
655
756
|
}
|
|
656
757
|
handleEscape() {
|
|
@@ -681,6 +782,17 @@ export class AutoCompleteComponent {
|
|
|
681
782
|
this.search(text);
|
|
682
783
|
}
|
|
683
784
|
}
|
|
785
|
+
/**
|
|
786
|
+
* @hidden
|
|
787
|
+
*/
|
|
788
|
+
onFilterChange(text) {
|
|
789
|
+
if (this.filterable) {
|
|
790
|
+
this.filterChange.emit(text);
|
|
791
|
+
}
|
|
792
|
+
else if (this.highlightFirst) {
|
|
793
|
+
this.search(text);
|
|
794
|
+
}
|
|
795
|
+
}
|
|
684
796
|
/**
|
|
685
797
|
* @hidden
|
|
686
798
|
*/
|
|
@@ -696,37 +808,39 @@ export class AutoCompleteComponent {
|
|
|
696
808
|
* @hidden
|
|
697
809
|
*/
|
|
698
810
|
handleBlur() {
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
811
|
+
if (!this.isActionSheetExpanded) {
|
|
812
|
+
const focused = this.filterable ? this.selectionService.focused : -1;
|
|
813
|
+
this.searchbar.input.nativeElement.scrollLeft = 0; // Firefox doesn't auto-scroll to the left on blur like other browsers
|
|
814
|
+
let dataItem;
|
|
815
|
+
let text;
|
|
816
|
+
if (focused !== -1) {
|
|
817
|
+
dataItem = this.dataService.itemAt(focused);
|
|
818
|
+
text = getter(dataItem, this.valueField) || "";
|
|
819
|
+
}
|
|
820
|
+
else {
|
|
821
|
+
text = this.searchbar.value;
|
|
822
|
+
}
|
|
823
|
+
const exactMatch = text === this.searchbar.value;
|
|
824
|
+
const insensitiveMatch = text.toLowerCase() === this.searchbar.value.toLowerCase();
|
|
825
|
+
if (!exactMatch && insensitiveMatch) {
|
|
826
|
+
this.selectionService.resetSelection([]);
|
|
827
|
+
}
|
|
828
|
+
this.isFocused = false;
|
|
829
|
+
const valueHasChanged = this.value !== this.text;
|
|
830
|
+
const runInZone = hasObservers(this.onBlur) || hasObservers(this.close) || isUntouched(this.wrapper) || valueHasChanged;
|
|
831
|
+
if (runInZone) {
|
|
832
|
+
this._zone.run(() => {
|
|
833
|
+
if (valueHasChanged) {
|
|
834
|
+
this.change(this.searchbar.value);
|
|
835
|
+
}
|
|
836
|
+
this.onBlur.emit();
|
|
837
|
+
this.onTouchedCallback();
|
|
838
|
+
this.togglePopup(false);
|
|
839
|
+
});
|
|
840
|
+
}
|
|
841
|
+
else {
|
|
725
842
|
this.togglePopup(false);
|
|
726
|
-
}
|
|
727
|
-
}
|
|
728
|
-
else {
|
|
729
|
-
this.togglePopup(false);
|
|
843
|
+
}
|
|
730
844
|
}
|
|
731
845
|
}
|
|
732
846
|
/**
|
|
@@ -744,29 +858,42 @@ export class AutoCompleteComponent {
|
|
|
744
858
|
if (!isDocumentAvailable()) {
|
|
745
859
|
return;
|
|
746
860
|
}
|
|
747
|
-
this.
|
|
861
|
+
this.subs.add(this.valueChangeSubject
|
|
748
862
|
.subscribe(value => {
|
|
749
863
|
const hasChange = this.value !== value;
|
|
864
|
+
const index = this.findIndex(value);
|
|
865
|
+
this.selectionService.focused = index;
|
|
750
866
|
this.value = value;
|
|
751
867
|
this.text = value;
|
|
752
868
|
// emit change after assigning `this.value` => allows the user to modify the component value on `valueChange`
|
|
753
869
|
if (hasChange) {
|
|
754
870
|
this.emitChange(value);
|
|
755
871
|
}
|
|
756
|
-
});
|
|
757
|
-
this.
|
|
758
|
-
this.
|
|
759
|
-
this.
|
|
760
|
-
this.
|
|
761
|
-
this.
|
|
762
|
-
this.
|
|
763
|
-
this.
|
|
764
|
-
this.
|
|
872
|
+
}));
|
|
873
|
+
this.subs.add(this.selectionService.onChange.subscribe(this.handleItemChange.bind(this)));
|
|
874
|
+
this.subs.add(this.selectionService.onFocus.subscribe(this.handleItemFocus.bind(this)));
|
|
875
|
+
this.subs.add(merge(this.navigationService.up, this.navigationService.down).subscribe((event) => this.navigate(event.index)));
|
|
876
|
+
this.subs.add(this.navigationService.close.subscribe(() => this.togglePopup(false)));
|
|
877
|
+
this.subs.add(this.navigationService.open.subscribe(() => this.togglePopup(true)));
|
|
878
|
+
this.subs.add(this.navigationService.enter.subscribe(this.handleEnter.bind(this)));
|
|
879
|
+
this.subs.add(this.navigationService.esc.subscribe(this.handleEscape.bind(this)));
|
|
880
|
+
this.subs.add(merge(this.navigationService.pagedown, this.navigationService.pageup).subscribe((event) => {
|
|
765
881
|
if (this.isOpen) {
|
|
766
882
|
event.originalEvent.preventDefault();
|
|
767
883
|
this.optionsList.scrollWithOnePage(NavigationAction[event.originalEvent.code]);
|
|
768
884
|
}
|
|
769
|
-
});
|
|
885
|
+
}));
|
|
886
|
+
}
|
|
887
|
+
findIndex(value, startFrom = 0) {
|
|
888
|
+
let index;
|
|
889
|
+
if (value && value.length && this.dataService.itemsCount) {
|
|
890
|
+
index = this.dataService.findIndex(this.findIndexPredicate(value), startFrom);
|
|
891
|
+
}
|
|
892
|
+
else {
|
|
893
|
+
index = -1;
|
|
894
|
+
}
|
|
895
|
+
;
|
|
896
|
+
return index;
|
|
770
897
|
}
|
|
771
898
|
subscribeTouchEvents() {
|
|
772
899
|
if (!isDocumentAvailable() || !this.touchEnabled) {
|
|
@@ -781,23 +908,6 @@ export class AutoCompleteComponent {
|
|
|
781
908
|
}
|
|
782
909
|
}));
|
|
783
910
|
}
|
|
784
|
-
unsubscribeEvents() {
|
|
785
|
-
if (!isDocumentAvailable()) {
|
|
786
|
-
return;
|
|
787
|
-
}
|
|
788
|
-
this.changeSubscription.unsubscribe();
|
|
789
|
-
this.navigationSubscription.unsubscribe();
|
|
790
|
-
this.closeSubscription.unsubscribe();
|
|
791
|
-
this.openSubscription.unsubscribe();
|
|
792
|
-
this.enterSubscription.unsubscribe();
|
|
793
|
-
this.escSubscription.unsubscribe();
|
|
794
|
-
this.scrollSubscription.unsubscribe();
|
|
795
|
-
this.valueChangeSubscription.unsubscribe();
|
|
796
|
-
this.focusSubscription.unsubscribe();
|
|
797
|
-
if (this.touchstartDisposeHandler) {
|
|
798
|
-
this.touchstartDisposeHandler();
|
|
799
|
-
}
|
|
800
|
-
}
|
|
801
911
|
handleItemChange(event) {
|
|
802
912
|
const index = event.indices.length ? event.indices[0] : undefined;
|
|
803
913
|
this.selectionService.resetSelection([-1]);
|
|
@@ -806,6 +916,9 @@ export class AutoCompleteComponent {
|
|
|
806
916
|
}
|
|
807
917
|
const text = getter(this.dataService.itemAt(index), this.valueField);
|
|
808
918
|
this.change(text);
|
|
919
|
+
if (this.isActionSheetExpanded) {
|
|
920
|
+
this.togglePopup(false);
|
|
921
|
+
}
|
|
809
922
|
}
|
|
810
923
|
handleItemFocus(_event) {
|
|
811
924
|
const focused = this.selectionService.focused;
|
|
@@ -818,9 +931,14 @@ export class AutoCompleteComponent {
|
|
|
818
931
|
if (this.virtual) {
|
|
819
932
|
this.virtual.skip = 0;
|
|
820
933
|
}
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
934
|
+
this.windowSize = windowSize();
|
|
935
|
+
if (this.isAdaptive) {
|
|
936
|
+
this.openActionSheet();
|
|
937
|
+
return;
|
|
938
|
+
}
|
|
939
|
+
const horizontalAlign = this.direction === "rtl" ? "right" : "left";
|
|
940
|
+
const anchorPosition = { horizontal: horizontalAlign, vertical: "bottom" };
|
|
941
|
+
const popupPosition = { horizontal: horizontalAlign, vertical: "top" };
|
|
824
942
|
this.popupRef = this.popupService.open({
|
|
825
943
|
anchor: this.wrapper,
|
|
826
944
|
animate: this.popupSettings.animate,
|
|
@@ -842,20 +960,17 @@ export class AutoCompleteComponent {
|
|
|
842
960
|
this.renderer.setAttribute(popupWrapper, 'role', 'region');
|
|
843
961
|
this.renderer.setAttribute(popupWrapper, 'aria-label', this.messageFor('popupLabel'));
|
|
844
962
|
}
|
|
845
|
-
|
|
846
|
-
const ariaLabel = this.searchbar.input.nativeElement.getAttribute('aria-labelledby');
|
|
847
|
-
if (ariaLabel) {
|
|
848
|
-
listBox.setAttribute('aria-labelledby', ariaLabel);
|
|
849
|
-
}
|
|
850
|
-
this.popupRef.popupOpen.subscribe(() => {
|
|
963
|
+
this.subs.add(this.popupRef.popupOpen.subscribe(() => {
|
|
851
964
|
this.cdr.detectChanges();
|
|
965
|
+
setListBoxAriaLabelLebBy(this.optionsList, this.searchbar.input, this.renderer);
|
|
852
966
|
this.optionsList.scrollToItem(this.selectionService.focused);
|
|
967
|
+
this.selectionService.focus(this.selectionService.focused);
|
|
853
968
|
this.opened.emit();
|
|
854
|
-
});
|
|
855
|
-
this.popupRef.popupClose.subscribe(() => {
|
|
969
|
+
}));
|
|
970
|
+
this.subs.add(this.popupRef.popupClose.subscribe(() => {
|
|
856
971
|
this.closed.emit();
|
|
857
|
-
});
|
|
858
|
-
this.popupRef.popupAnchorViewportLeave.subscribe(() => this.togglePopup(false));
|
|
972
|
+
}));
|
|
973
|
+
this.subs.add(this.popupRef.popupAnchorViewportLeave.subscribe(() => this.togglePopup(false)));
|
|
859
974
|
}
|
|
860
975
|
destroyPopup() {
|
|
861
976
|
if (this.popupRef) {
|
|
@@ -868,6 +983,9 @@ export class AutoCompleteComponent {
|
|
|
868
983
|
_toggle(open) {
|
|
869
984
|
this._open = open;
|
|
870
985
|
this.destroyPopup();
|
|
986
|
+
if (this.isActionSheetExpanded) {
|
|
987
|
+
this.closeActionSheet();
|
|
988
|
+
}
|
|
871
989
|
if (this._open) {
|
|
872
990
|
this.createPopup();
|
|
873
991
|
}
|
|
@@ -918,9 +1036,28 @@ export class AutoCompleteComponent {
|
|
|
918
1036
|
this.renderer.addClass(this.wrapper, getFillModeClass('input', this.fillMode));
|
|
919
1037
|
}
|
|
920
1038
|
}
|
|
1039
|
+
closeActionSheet() {
|
|
1040
|
+
this.actionSheet.toggle(false);
|
|
1041
|
+
this.actionSheetSearchBar.value = '';
|
|
1042
|
+
this.filterable && this.filterChange.emit('');
|
|
1043
|
+
this.searchbar.input.nativeElement.focus();
|
|
1044
|
+
this.closed.emit();
|
|
1045
|
+
}
|
|
1046
|
+
openActionSheet() {
|
|
1047
|
+
this.actionSheet.toggle(true);
|
|
1048
|
+
this.cdr.detectChanges();
|
|
1049
|
+
setListBoxAriaLabelLebBy(this.optionsList, this.searchbar.input, this.renderer);
|
|
1050
|
+
this.title = setActionSheetTitle(this.searchbar.input, this.title);
|
|
1051
|
+
updateActionSheetAdaptiveAppearance(this.actionSheet, this.windowSize, this.renderer);
|
|
1052
|
+
this.cdr.detectChanges();
|
|
1053
|
+
this.opened.emit();
|
|
1054
|
+
this.optionsList.scrollToItem(this.selectionService.focused);
|
|
1055
|
+
this.selectionService.focus(this.selectionService.focused);
|
|
1056
|
+
this.actionSheetSearchBar.focus();
|
|
1057
|
+
}
|
|
921
1058
|
}
|
|
922
1059
|
AutoCompleteComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: AutoCompleteComponent, deps: [{ token: i1.LocalizationService }, { token: i2.DataService }, { token: i3.PopupService }, { token: i4.SelectionService }, { token: i5.NavigationService }, { token: i6.DisabledItemsService }, { token: i0.NgZone }, { token: i0.ChangeDetectorRef }, { token: i0.Renderer2 }, { token: i0.ElementRef }, { token: TOUCH_ENABLED, optional: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
923
|
-
AutoCompleteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: AutoCompleteComponent, selector: "kendo-autocomplete", inputs: { highlightFirst: "highlightFirst", focusableId: "focusableId", data: "data", value: "value", valueField: "valueField", placeholder: "placeholder", popupSettings: "popupSettings", listHeight: "listHeight", loading: "loading", clearButton: "clearButton", suggest: "suggest", disabled: "disabled", itemDisabled: "itemDisabled", readonly: "readonly", tabindex: "tabindex", tabIndex: "tabIndex", filterable: "filterable", virtual: "virtual", size: "size", rounded: "rounded", fillMode: "fillMode" }, outputs: { valueChange: "valueChange", filterChange: "filterChange", open: "open", opened: "opened", close: "close", closed: "closed", onFocus: "focus", onBlur: "blur" }, host: { properties: { "class.k-autocomplete": "this.widgetClasses", "class.k-input": "this.widgetClasses", "class.k-disabled": "this.isDisabled", "class.k-loading": "this.isLoading", "attr.dir": "this.dir" } }, providers: [
|
|
1060
|
+
AutoCompleteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: AutoCompleteComponent, selector: "kendo-autocomplete", inputs: { highlightFirst: "highlightFirst", focusableId: "focusableId", data: "data", value: "value", valueField: "valueField", placeholder: "placeholder", adaptiveMode: "adaptiveMode", title: "title", subtitle: "subtitle", popupSettings: "popupSettings", listHeight: "listHeight", loading: "loading", clearButton: "clearButton", suggest: "suggest", disabled: "disabled", itemDisabled: "itemDisabled", readonly: "readonly", tabindex: "tabindex", tabIndex: "tabIndex", filterable: "filterable", virtual: "virtual", size: "size", rounded: "rounded", fillMode: "fillMode" }, outputs: { valueChange: "valueChange", filterChange: "filterChange", open: "open", opened: "opened", close: "close", closed: "closed", onFocus: "focus", onBlur: "blur" }, host: { properties: { "class.k-autocomplete": "this.widgetClasses", "class.k-input": "this.widgetClasses", "class.k-disabled": "this.isDisabled", "class.k-loading": "this.isLoading", "attr.dir": "this.dir" } }, providers: [
|
|
924
1061
|
AUTOCOMPLETE_VALUE_ACCESSOR,
|
|
925
1062
|
DataService,
|
|
926
1063
|
SelectionService,
|
|
@@ -939,7 +1076,7 @@ AutoCompleteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
|
|
|
939
1076
|
provide: KendoInput,
|
|
940
1077
|
useExisting: forwardRef(() => AutoCompleteComponent)
|
|
941
1078
|
}
|
|
942
|
-
], queries: [{ propertyName: "template", first: true, predicate: ItemTemplateDirective, descendants: true }, { propertyName: "headerTemplate", first: true, predicate: HeaderTemplateDirective, descendants: true }, { propertyName: "footerTemplate", first: true, predicate: FooterTemplateDirective, descendants: true }, { propertyName: "noDataTemplate", first: true, predicate: NoDataTemplateDirective, descendants: true }, { propertyName: "groupTemplate", first: true, predicate: GroupTemplateDirective, descendants: true }, { propertyName: "fixedGroupTemplate", first: true, predicate: FixedGroupTemplateDirective, descendants: true }], viewQueries: [{ propertyName: "container", first: true, predicate: ["container"], descendants: true, read: ViewContainerRef, static: true }, { propertyName: "popupTemplate", first: true, predicate: ["popupTemplate"], descendants: true, static: true }, { propertyName: "searchbar", first: true, predicate: SearchBarComponent, descendants: true, static: true }, { propertyName: "optionsList", first: true, predicate: ["optionsList"], descendants: true }], exportAs: ["kendoAutoComplete"], usesOnChanges: true, ngImport: i0, template: `
|
|
1079
|
+
], queries: [{ propertyName: "template", first: true, predicate: ItemTemplateDirective, descendants: true }, { propertyName: "headerTemplate", first: true, predicate: HeaderTemplateDirective, descendants: true }, { propertyName: "footerTemplate", first: true, predicate: FooterTemplateDirective, descendants: true }, { propertyName: "noDataTemplate", first: true, predicate: NoDataTemplateDirective, descendants: true }, { propertyName: "groupTemplate", first: true, predicate: GroupTemplateDirective, descendants: true }, { propertyName: "fixedGroupTemplate", first: true, predicate: FixedGroupTemplateDirective, descendants: true }], viewQueries: [{ propertyName: "responsiveRendererComponent", first: true, predicate: ResponsiveRendererComponent, descendants: true }, { propertyName: "container", first: true, predicate: ["container"], descendants: true, read: ViewContainerRef, static: true }, { propertyName: "popupTemplate", first: true, predicate: ["popupTemplate"], descendants: true, static: true }, { propertyName: "searchbar", first: true, predicate: SearchBarComponent, descendants: true, static: true }, { propertyName: "optionsList", first: true, predicate: ["optionsList"], descendants: true }], exportAs: ["kendoAutoComplete"], usesOnChanges: true, ngImport: i0, template: `
|
|
943
1080
|
<ng-container kendoAutoCompleteLocalizedMessages
|
|
944
1081
|
i18n-noDataText="kendo.autocomplete.noDataText|The text displayed in the popup when there are no items"
|
|
945
1082
|
noDataText="NO DATA FOUND"
|
|
@@ -954,7 +1091,6 @@ AutoCompleteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
|
|
|
954
1091
|
<kendo-searchbar #searchbar
|
|
955
1092
|
[role]="'combobox'"
|
|
956
1093
|
[ariaExpanded]="isOpen"
|
|
957
|
-
[ariaControls]="ariaControls"
|
|
958
1094
|
[isSuggestable]="suggest"
|
|
959
1095
|
[isFilterable]="filterable"
|
|
960
1096
|
[isLoading]="isLoading"
|
|
@@ -964,13 +1100,14 @@ AutoCompleteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
|
|
|
964
1100
|
[userInput]="text"
|
|
965
1101
|
[suggestedText]="suggestion"
|
|
966
1102
|
[disabled]="disabled"
|
|
967
|
-
[readonly]="readonly"
|
|
1103
|
+
[readonly]="readonly || this.isAdaptive"
|
|
968
1104
|
[tabIndex]="tabIndex"
|
|
969
1105
|
[placeholder]="placeholder"
|
|
970
1106
|
(onNavigate)="handleNavigate($event)"
|
|
971
1107
|
(valueChange)="searchBarChange($event)"
|
|
972
1108
|
(onBlur)="handleBlur()"
|
|
973
1109
|
(onFocus)="handleFocus()"
|
|
1110
|
+
(click)="handleClick()"
|
|
974
1111
|
></kendo-searchbar>
|
|
975
1112
|
<span
|
|
976
1113
|
*ngIf="!loading && !readonly && (clearButton && text?.length)"
|
|
@@ -990,6 +1127,26 @@ AutoCompleteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
|
|
|
990
1127
|
</span>
|
|
991
1128
|
<span *ngIf="loading" class="k-icon k-i-loading k-input-loading-icon"></span>
|
|
992
1129
|
<ng-template #popupTemplate>
|
|
1130
|
+
<ng-container *ngTemplateOutlet="sharedPopupActionSheetTemplate"></ng-container>
|
|
1131
|
+
</ng-template>
|
|
1132
|
+
<ng-container #container></ng-container>
|
|
1133
|
+
<kendo-resize-sensor *ngIf="isOpen || isAdaptiveModeEnabled" (resize)="onResize()"></kendo-resize-sensor>
|
|
1134
|
+
|
|
1135
|
+
<!--adaptive rendering-->
|
|
1136
|
+
<responsive-renderer
|
|
1137
|
+
[sharedPopupActionSheetTemplate]="sharedPopupActionSheetTemplate"
|
|
1138
|
+
[isActionSheetExpanded]="isActionSheetExpanded"
|
|
1139
|
+
[title]="title"
|
|
1140
|
+
[showTextInput]="true"
|
|
1141
|
+
[subtitle]="subtitle"
|
|
1142
|
+
(closePopup)="togglePopup(false)"
|
|
1143
|
+
(textInputChange)="onFilterChange($event)"
|
|
1144
|
+
(navigate)="handleNavigate($event)"
|
|
1145
|
+
[placeholder]="placeholder"
|
|
1146
|
+
>
|
|
1147
|
+
</responsive-renderer>
|
|
1148
|
+
|
|
1149
|
+
<ng-template #sharedPopupActionSheetTemplate>
|
|
993
1150
|
<!--header template-->
|
|
994
1151
|
<ng-template *ngIf="headerTemplate"
|
|
995
1152
|
[templateContext]="{
|
|
@@ -1033,11 +1190,7 @@ AutoCompleteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
|
|
|
1033
1190
|
}">
|
|
1034
1191
|
</ng-template>
|
|
1035
1192
|
</ng-template>
|
|
1036
|
-
|
|
1037
|
-
<kendo-resize-sensor (resize)="onResize()"></kendo-resize-sensor>
|
|
1038
|
-
</ng-template>
|
|
1039
|
-
<ng-container #container></ng-container>
|
|
1040
|
-
`, isInline: true, components: [{ type: i7.SearchBarComponent, selector: "kendo-searchbar", inputs: ["id", "tagListId", "activeDescendant", "disabled", "readonly", "tabIndex", "role", "isLoading", "ariaControls", "ariaExpanded", "isSuggestable", "isFilterable", "userInput", "suggestedText", "placeholder"], outputs: ["valueChange", "onBlur", "onFocus", "onClick", "onNavigate"] }, { type: i8.IconWrapperComponent, selector: "kendo-icon-wrapper", inputs: ["name", "svgIcon", "innerCssClass", "customFontClass"], exportAs: ["kendoIconWrapper"] }, { type: i9.ListComponent, selector: "kendo-list", inputs: ["selected", "focused", "textField", "valueField", "height", "template", "groupTemplate", "fixedGroupTemplate", "show", "id", "optionPrefix", "multipleSelection", "virtual", "type", "checkboxes", "ariaLive", "isMultiselect", "data", "size", "rounded"], outputs: ["onClick", "pageChange", "listResize"] }, { type: i10.ResizeSensorComponent, selector: "kendo-resize-sensor", inputs: ["rateLimit"], outputs: ["resize"] }], directives: [{ type: i11.LocalizedMessagesDirective, selector: "\n [kendoDropDownListLocalizedMessages],\n [kendoDropDownTreeLocalizedMessages],\n [kendoComboBoxLocalizedMessages],\n [kendoMultiColumnComboBoxLocalizedMessages],\n [kendoAutoCompleteLocalizedMessages],\n [kendoMultiSelectLocalizedMessages],\n [kendoMultiSelectTreeLocalizedMessages]\n " }, { type: i12.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i13.TemplateContextDirective, selector: "[templateContext]", inputs: ["templateContext"] }] });
|
|
1193
|
+
`, isInline: true, components: [{ type: i7.SearchBarComponent, selector: "kendo-searchbar", inputs: ["id", "tagListId", "activeDescendant", "disabled", "readonly", "tabIndex", "role", "isLoading", "ariaControls", "ariaExpanded", "isSuggestable", "isFilterable", "userInput", "suggestedText", "placeholder"], outputs: ["valueChange", "onBlur", "onFocus", "onClick", "onNavigate"] }, { type: i8.IconWrapperComponent, selector: "kendo-icon-wrapper", inputs: ["name", "svgIcon", "innerCssClass", "customFontClass"], exportAs: ["kendoIconWrapper"] }, { type: i9.ResizeSensorComponent, selector: "kendo-resize-sensor", inputs: ["rateLimit"], outputs: ["resize"] }, { type: i10.ResponsiveRendererComponent, selector: "responsive-renderer", inputs: ["title", "showActionButtons", "subtitle", "size", "showTextInput", "sharedPopupActionSheetTemplate", "isActionSheetExpanded", "text", "placeholder"], outputs: ["closePopup", "textInputChange", "navigate", "onExpand", "onCollapse", "onApply", "onCancel"] }, { type: i11.ListComponent, selector: "kendo-list", inputs: ["selected", "focused", "textField", "valueField", "height", "template", "groupTemplate", "fixedGroupTemplate", "show", "id", "optionPrefix", "multipleSelection", "virtual", "type", "checkboxes", "ariaLive", "isMultiselect", "isActionSheetExpanded", "data", "size", "rounded"], outputs: ["onClick", "pageChange", "listResize"] }], directives: [{ type: i12.LocalizedMessagesDirective, selector: "\n [kendoDropDownListLocalizedMessages],\n [kendoDropDownTreeLocalizedMessages],\n [kendoComboBoxLocalizedMessages],\n [kendoMultiColumnComboBoxLocalizedMessages],\n [kendoAutoCompleteLocalizedMessages],\n [kendoMultiSelectLocalizedMessages],\n [kendoMultiSelectTreeLocalizedMessages]\n " }, { type: i13.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i13.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i14.TemplateContextDirective, selector: "[templateContext]", inputs: ["templateContext"] }] });
|
|
1041
1194
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: AutoCompleteComponent, decorators: [{
|
|
1042
1195
|
type: Component,
|
|
1043
1196
|
args: [{
|
|
@@ -1078,7 +1231,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1078
1231
|
<kendo-searchbar #searchbar
|
|
1079
1232
|
[role]="'combobox'"
|
|
1080
1233
|
[ariaExpanded]="isOpen"
|
|
1081
|
-
[ariaControls]="ariaControls"
|
|
1082
1234
|
[isSuggestable]="suggest"
|
|
1083
1235
|
[isFilterable]="filterable"
|
|
1084
1236
|
[isLoading]="isLoading"
|
|
@@ -1088,13 +1240,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1088
1240
|
[userInput]="text"
|
|
1089
1241
|
[suggestedText]="suggestion"
|
|
1090
1242
|
[disabled]="disabled"
|
|
1091
|
-
[readonly]="readonly"
|
|
1243
|
+
[readonly]="readonly || this.isAdaptive"
|
|
1092
1244
|
[tabIndex]="tabIndex"
|
|
1093
1245
|
[placeholder]="placeholder"
|
|
1094
1246
|
(onNavigate)="handleNavigate($event)"
|
|
1095
1247
|
(valueChange)="searchBarChange($event)"
|
|
1096
1248
|
(onBlur)="handleBlur()"
|
|
1097
1249
|
(onFocus)="handleFocus()"
|
|
1250
|
+
(click)="handleClick()"
|
|
1098
1251
|
></kendo-searchbar>
|
|
1099
1252
|
<span
|
|
1100
1253
|
*ngIf="!loading && !readonly && (clearButton && text?.length)"
|
|
@@ -1114,6 +1267,26 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1114
1267
|
</span>
|
|
1115
1268
|
<span *ngIf="loading" class="k-icon k-i-loading k-input-loading-icon"></span>
|
|
1116
1269
|
<ng-template #popupTemplate>
|
|
1270
|
+
<ng-container *ngTemplateOutlet="sharedPopupActionSheetTemplate"></ng-container>
|
|
1271
|
+
</ng-template>
|
|
1272
|
+
<ng-container #container></ng-container>
|
|
1273
|
+
<kendo-resize-sensor *ngIf="isOpen || isAdaptiveModeEnabled" (resize)="onResize()"></kendo-resize-sensor>
|
|
1274
|
+
|
|
1275
|
+
<!--adaptive rendering-->
|
|
1276
|
+
<responsive-renderer
|
|
1277
|
+
[sharedPopupActionSheetTemplate]="sharedPopupActionSheetTemplate"
|
|
1278
|
+
[isActionSheetExpanded]="isActionSheetExpanded"
|
|
1279
|
+
[title]="title"
|
|
1280
|
+
[showTextInput]="true"
|
|
1281
|
+
[subtitle]="subtitle"
|
|
1282
|
+
(closePopup)="togglePopup(false)"
|
|
1283
|
+
(textInputChange)="onFilterChange($event)"
|
|
1284
|
+
(navigate)="handleNavigate($event)"
|
|
1285
|
+
[placeholder]="placeholder"
|
|
1286
|
+
>
|
|
1287
|
+
</responsive-renderer>
|
|
1288
|
+
|
|
1289
|
+
<ng-template #sharedPopupActionSheetTemplate>
|
|
1117
1290
|
<!--header template-->
|
|
1118
1291
|
<ng-template *ngIf="headerTemplate"
|
|
1119
1292
|
[templateContext]="{
|
|
@@ -1157,10 +1330,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1157
1330
|
}">
|
|
1158
1331
|
</ng-template>
|
|
1159
1332
|
</ng-template>
|
|
1160
|
-
<ng-template [ngIf]="isOpen">
|
|
1161
|
-
<kendo-resize-sensor (resize)="onResize()"></kendo-resize-sensor>
|
|
1162
|
-
</ng-template>
|
|
1163
|
-
<ng-container #container></ng-container>
|
|
1164
1333
|
`
|
|
1165
1334
|
}]
|
|
1166
1335
|
}], ctorParameters: function () { return [{ type: i1.LocalizationService }, { type: i2.DataService }, { type: i3.PopupService }, { type: i4.SelectionService }, { type: i5.NavigationService }, { type: i6.DisabledItemsService }, { type: i0.NgZone }, { type: i0.ChangeDetectorRef }, { type: i0.Renderer2 }, { type: i0.ElementRef }, { type: undefined, decorators: [{
|
|
@@ -1168,7 +1337,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1168
1337
|
}, {
|
|
1169
1338
|
type: Inject,
|
|
1170
1339
|
args: [TOUCH_ENABLED]
|
|
1171
|
-
}] }]; }, propDecorators: {
|
|
1340
|
+
}] }]; }, propDecorators: { responsiveRendererComponent: [{
|
|
1341
|
+
type: ViewChild,
|
|
1342
|
+
args: [ResponsiveRendererComponent]
|
|
1343
|
+
}], highlightFirst: [{
|
|
1172
1344
|
type: Input
|
|
1173
1345
|
}], focusableId: [{
|
|
1174
1346
|
type: Input
|
|
@@ -1180,6 +1352,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
1180
1352
|
type: Input
|
|
1181
1353
|
}], placeholder: [{
|
|
1182
1354
|
type: Input
|
|
1355
|
+
}], adaptiveMode: [{
|
|
1356
|
+
type: Input
|
|
1357
|
+
}], title: [{
|
|
1358
|
+
type: Input
|
|
1359
|
+
}], subtitle: [{
|
|
1360
|
+
type: Input
|
|
1183
1361
|
}], popupSettings: [{
|
|
1184
1362
|
type: Input
|
|
1185
1363
|
}], listHeight: [{
|