igniteui-angular 13.0.0-alpha.6 → 13.0.0-alpha.7

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 (72) hide show
  1. package/README.md +31 -30
  2. package/esm2020/lib/action-strip/grid-actions/grid-editing-actions.component.mjs +2 -2
  3. package/esm2020/lib/banner/banner.component.mjs +1 -1
  4. package/esm2020/lib/combo/combo-dropdown.component.mjs +12 -6
  5. package/esm2020/lib/combo/combo-item.component.mjs +5 -3
  6. package/esm2020/lib/combo/combo.api.mjs +3 -3
  7. package/esm2020/lib/combo/combo.common.mjs +1100 -2
  8. package/esm2020/lib/combo/combo.component.mjs +107 -1231
  9. package/esm2020/lib/combo/combo.directives.mjs +9 -25
  10. package/esm2020/lib/combo/combo.pipes.mjs +4 -6
  11. package/esm2020/lib/combo/public_api.mjs +5 -1
  12. package/esm2020/lib/core/utils.mjs +11 -1
  13. package/esm2020/lib/dialog/dialog.component.mjs +22 -10
  14. package/esm2020/lib/directives/focus-trap/focus-trap.directive.mjs +112 -0
  15. package/esm2020/lib/directives/for-of/for_of.directive.mjs +2 -2
  16. package/esm2020/lib/directives/radio/radio-group.directive.mjs +5 -13
  17. package/esm2020/lib/drop-down/drop-down-item.base.mjs +1 -5
  18. package/esm2020/lib/grids/column-actions/column-actions.component.mjs +4 -4
  19. package/esm2020/lib/grids/columns/column-layout.component.mjs +3 -3
  20. package/esm2020/lib/grids/columns/column.component.mjs +5 -5
  21. package/esm2020/lib/grids/common/crud.service.mjs +2 -2
  22. package/esm2020/lib/grids/filtering/advanced-filtering/advanced-filtering-dialog.component.mjs +2 -2
  23. package/esm2020/lib/grids/filtering/grid-filtering.service.mjs +9 -9
  24. package/esm2020/lib/grids/grid/grid.component.mjs +4 -8
  25. package/esm2020/lib/grids/grid-base.directive.mjs +82 -69
  26. package/esm2020/lib/grids/grid-public-row.mjs +3 -12
  27. package/esm2020/lib/grids/grouping/group-by-area.directive.mjs +2 -2
  28. package/esm2020/lib/grids/headers/grid-header-row.component.mjs +3 -3
  29. package/esm2020/lib/grids/hierarchical-grid/hierarchical-grid.component.mjs +4 -8
  30. package/esm2020/lib/grids/state.directive.mjs +2 -2
  31. package/esm2020/lib/grids/tree-grid/tree-grid.component.mjs +4 -8
  32. package/esm2020/lib/services/overlay/utilities.mjs +1 -1
  33. package/esm2020/lib/simple-combo/public_api.mjs +2 -0
  34. package/esm2020/lib/simple-combo/simple-combo.component.mjs +375 -0
  35. package/esm2020/lib/toast/toast.component.mjs +3 -6
  36. package/esm2020/public_api.mjs +3 -1
  37. package/fesm2015/igniteui-angular.mjs +1723 -1405
  38. package/fesm2015/igniteui-angular.mjs.map +1 -1
  39. package/fesm2020/igniteui-angular.mjs +1714 -1402
  40. package/fesm2020/igniteui-angular.mjs.map +1 -1
  41. package/lib/banner/banner.component.d.ts +1 -2
  42. package/lib/combo/combo-dropdown.component.d.ts +3 -1
  43. package/lib/combo/combo-item.component.d.ts +3 -1
  44. package/lib/combo/combo.common.d.ts +733 -4
  45. package/lib/combo/combo.component.d.ts +41 -799
  46. package/lib/combo/combo.pipes.d.ts +1 -1
  47. package/lib/combo/public_api.d.ts +4 -0
  48. package/lib/core/utils.d.ts +4 -0
  49. package/lib/dialog/dialog.component.d.ts +11 -2
  50. package/lib/directives/focus-trap/focus-trap.directive.d.ts +41 -0
  51. package/lib/directives/radio/radio-group.directive.d.ts +4 -4
  52. package/lib/grids/columns/column.component.d.ts +1 -1
  53. package/lib/grids/grid/grid.component.d.ts +2 -1
  54. package/lib/grids/grid-base.directive.d.ts +64 -8
  55. package/lib/grids/grid-public-row.d.ts +2 -3
  56. package/lib/grids/hierarchical-grid/hierarchical-grid.component.d.ts +2 -1
  57. package/lib/grids/tree-grid/tree-grid.component.d.ts +2 -1
  58. package/lib/services/overlay/utilities.d.ts +2 -1
  59. package/lib/simple-combo/public_api.d.ts +1 -0
  60. package/lib/simple-combo/simple-combo.component.d.ts +134 -0
  61. package/lib/toast/toast.component.d.ts +2 -0
  62. package/migrations/common/filterSourceDirs.d.ts +2 -2
  63. package/migrations/common/filterSourceDirs.js +2 -2
  64. package/migrations/update-13_0_0/changes/members.json +26 -0
  65. package/migrations/update-13_0_0/index.js +0 -31
  66. package/package.json +51 -43
  67. package/public_api.d.ts +2 -0
  68. package/src/lib/combo/README.md +14 -14
  69. package/src/lib/directives/focus-trap/README.md +17 -0
  70. package/src/lib/simple-combo/README.md +317 -0
  71. package/esm2020/lib/core/deprecateDecorators.mjs +0 -99
  72. package/lib/core/deprecateDecorators.d.ts +0 -20
@@ -1,21 +1,16 @@
1
- import { AfterViewInit, ChangeDetectorRef, ElementRef, EventEmitter, OnInit, OnDestroy, TemplateRef, Injector } from '@angular/core';
1
+ import { AfterViewInit, ChangeDetectorRef, ElementRef, OnInit, OnDestroy, Injector } from '@angular/core';
2
2
  import { ControlValueAccessor } from '@angular/forms';
3
3
  import { IgxSelectionAPIService } from '../core/selection';
4
- import { IBaseEventArgs, IBaseCancelableBrowserEventArgs, IBaseCancelableEventArgs, CancelableEventArgs } from '../core/utils';
4
+ import { IBaseEventArgs, IBaseCancelableEventArgs, CancelableEventArgs } from '../core/utils';
5
5
  import { IgxStringFilteringOperand, IgxBooleanFilteringOperand } from '../data-operations/filtering-condition';
6
6
  import { FilteringLogic } from '../data-operations/filtering-expression.interface';
7
- import { IForOfState, IgxForOfDirective } from '../directives/for-of/for_of.directive';
8
7
  import { IgxIconService } from '../icon/public_api';
9
- import { IgxInputGroupComponent } from '../input-group/input-group.component';
10
8
  import { IgxComboDropDownComponent } from './combo-dropdown.component';
11
- import { OverlaySettings } from '../services/public_api';
12
- import { DisplayDensityBase, IDisplayDensityOptions } from '../core/density';
13
- import { IgxComboBase } from './combo.common';
9
+ import { IDisplayDensityOptions } from '../core/density';
10
+ import { IgxComboBaseDirective } from './combo.common';
14
11
  import { IgxComboAPIService } from './combo.api';
15
12
  import { EditorProvider } from '../core/edit-provider';
16
- import { IgxInputDirective } from '../directives/input/input.directive';
17
13
  import { IgxInputGroupType } from '../input-group/public_api';
18
- import { SortingDirection } from '../data-operations/sorting-strategy';
19
14
  import * as i0 from "@angular/core";
20
15
  import * as i1 from "./combo-add-item.component";
21
16
  import * as i2 from "./combo.directives";
@@ -32,20 +27,6 @@ import * as i12 from "../icon/public_api";
32
27
  import * as i13 from "../input-group/input-group.component";
33
28
  import * as i14 from "../directives/ripple/ripple.directive";
34
29
  import * as i15 from "../directives/toggle/toggle.directive";
35
- export declare enum IgxComboState {
36
- /**
37
- * Combo with initial state.
38
- */
39
- INITIAL = 0,
40
- /**
41
- * Combo with valid state.
42
- */
43
- VALID = 1,
44
- /**
45
- * Combo with invalid state.
46
- */
47
- INVALID = 2
48
- }
49
30
  /** The filtering criteria to be applied on data search */
50
31
  export interface IComboFilteringOptions {
51
32
  /** Defines filtering case-sensitivity */
@@ -85,7 +66,7 @@ export interface IComboItemAdditionEvent extends IBaseEventArgs, CancelableEvent
85
66
  * @igxGroup Grids & Lists
86
67
  *
87
68
  * @remarks
88
- * It provides the ability to filter items as well as perform single or multiple seleciton with the provided data.
69
+ * It provides the ability to filter items as well as perform selection with the provided data.
89
70
  * Additionally, it exposes keyboard navigation and custom styling capabilities.
90
71
  * @example
91
72
  * ```html
@@ -95,417 +76,15 @@ export interface IComboItemAdditionEvent extends IBaseEventArgs, CancelableEvent
95
76
  * </igx-combo>
96
77
  * ```
97
78
  */
98
- export declare class IgxComboComponent extends DisplayDensityBase implements IgxComboBase, AfterViewInit, ControlValueAccessor, OnInit, OnDestroy, EditorProvider {
79
+ export declare class IgxComboComponent extends IgxComboBaseDirective implements AfterViewInit, ControlValueAccessor, OnInit, OnDestroy, EditorProvider {
99
80
  protected elementRef: ElementRef;
100
81
  protected cdr: ChangeDetectorRef;
101
- protected selection: IgxSelectionAPIService;
82
+ protected selectionService: IgxSelectionAPIService;
102
83
  protected comboAPI: IgxComboAPIService;
103
- private _iconService;
84
+ protected _iconService: IgxIconService;
104
85
  protected _displayDensityOptions: IDisplayDensityOptions;
105
- private _inputGroupType;
106
- private _injector;
107
- /**
108
- * Set custom overlay settings that control how the combo's list of items is displayed.
109
- * Set:
110
- * ```html
111
- * <igx-combo [overlaySettings] = "customOverlaySettings"></igx-combo>
112
- * ```
113
- *
114
- * ```typescript
115
- * const customSettings = { positionStrategy: { settings: { target: myTarget } } };
116
- * combo.overlaySettings = customSettings;
117
- * ```
118
- * Get any custom overlay settings used by the combo:
119
- * ```typescript
120
- * const comboOverlaySettings: OverlaySettings = myCombo.overlaySettings;
121
- * ```
122
- */
123
- overlaySettings: OverlaySettings;
124
- /** @hidden @internal */
125
- inputGroup: IgxInputGroupComponent;
126
- /** @hidden @internal */
127
- comboInput: IgxInputDirective;
128
- /**
129
- * @hidden @internal
130
- */
131
- dropdown: IgxComboDropDownComponent;
132
- /**
133
- * @hidden @internal
134
- */
135
- searchInput: ElementRef<HTMLInputElement>;
136
- /**
137
- * @hidden @internal
138
- */
139
- get displaySearchInput(): boolean;
140
- /**
141
- * The custom template, if any, that should be used when rendering ITEMS in the combo list
142
- *
143
- * ```typescript
144
- * // Set in typescript
145
- * const myCustomTemplate: TemplateRef<any> = myComponent.customTemplate;
146
- * myComponent.combo.itemTemplate = myCustomTemplate;
147
- * ```
148
- * ```html
149
- * <!-- Set in markup -->
150
- * <igx-combo #combo>
151
- * ...
152
- * <ng-template igxComboItem>
153
- * <div class="custom-item" let-item let-key="valueKey">
154
- * <div class="custom-item__name">{{ item[key] }}</div>
155
- * <div class="custom-item__cost">{{ item.cost }}</div>
156
- * </div>
157
- * </ng-template>
158
- * </igx-combo>
159
- * ```
160
- */
161
- itemTemplate: TemplateRef<any>;
162
- /**
163
- * The custom template, if any, that should be used when rendering the HEADER for the combo items list
164
- *
165
- * ```typescript
166
- * // Set in typescript
167
- * const myCustomTemplate: TemplateRef<any> = myComponent.customTemplate;
168
- * myComponent.combo.headerTemplate = myCustomTemplate;
169
- * ```
170
- * ```html
171
- * <!-- Set in markup -->
172
- * <igx-combo #combo>
173
- * ...
174
- * <ng-template igxComboHeader>
175
- * <div class="combo__header">
176
- * This is a custom header
177
- * </div>
178
- * </ng-template>
179
- * </igx-combo>
180
- * ```
181
- */
182
- headerTemplate: TemplateRef<any>;
183
- /**
184
- * The custom template, if any, that should be used when rendering the FOOTER for the combo items list
185
- *
186
- * ```typescript
187
- * // Set in typescript
188
- * const myCustomTemplate: TemplateRef<any> = myComponent.customTemplate;
189
- * myComponent.combo.footerTemplate = myCustomTemplate;
190
- * ```
191
- * ```html
192
- * <!-- Set in markup -->
193
- * <igx-combo #combo>
194
- * ...
195
- * <ng-template igxComboFooter>
196
- * <div class="combo__footer">
197
- * This is a custom footer
198
- * </div>
199
- * </ng-template>
200
- * </igx-combo>
201
- * ```
202
- */
203
- footerTemplate: TemplateRef<any>;
204
- /**
205
- * The custom template, if any, that should be used when rendering HEADER ITEMS for groups in the combo list
206
- *
207
- * ```typescript
208
- * // Set in typescript
209
- * const myCustomTemplate: TemplateRef<any> = myComponent.customTemplate;
210
- * myComponent.combo.headerItemTemplate = myCustomTemplate;
211
- * ```
212
- * ```html
213
- * <!-- Set in markup -->
214
- * <igx-combo #combo>
215
- * ...
216
- * <ng-template igxComboHeaderItem let-item let-key="groupKey">
217
- * <div class="custom-item--group">Group header for {{ item[key] }}</div>
218
- * </ng-template>
219
- * </igx-combo>
220
- * ```
221
- */
222
- headerItemTemplate: TemplateRef<any>;
223
- /**
224
- * The custom template, if any, that should be used when rendering the ADD BUTTON in the combo drop down
225
- *
226
- * ```typescript
227
- * // Set in typescript
228
- * const myCustomTemplate: TemplateRef<any> = myComponent.customTemplate;
229
- * myComponent.combo.addItemTemplate = myCustomTemplate;
230
- * ```
231
- * ```html
232
- * <!-- Set in markup -->
233
- * <igx-combo #combo>
234
- * ...
235
- * <ng-template igxComboAddItem>
236
- * <button class="combo__add-button">
237
- * Click to add item
238
- * </button>
239
- * </ng-template>
240
- * </igx-combo>
241
- * ```
242
- */
243
- addItemTemplate: TemplateRef<any>;
244
- /**
245
- * The custom template, if any, that should be used when rendering the ADD BUTTON in the combo drop down
246
- *
247
- * ```typescript
248
- * // Set in typescript
249
- * const myCustomTemplate: TemplateRef<any> = myComponent.customTemplate;
250
- * myComponent.combo.emptyTemplate = myCustomTemplate;
251
- * ```
252
- * ```html
253
- * <!-- Set in markup -->
254
- * <igx-combo #combo>
255
- * ...
256
- * <ng-template igxComboEmpty>
257
- * <div class="combo--empty">
258
- * There are no items to display
259
- * </div>
260
- * </ng-template>
261
- * </igx-combo>
262
- * ```
263
- */
264
- emptyTemplate: TemplateRef<any>;
265
- /**
266
- * The custom template, if any, that should be used when rendering the combo TOGGLE(open/close) button
267
- *
268
- * ```typescript
269
- * // Set in typescript
270
- * const myCustomTemplate: TemplateRef<any> = myComponent.customTemplate;
271
- * myComponent.combo.toggleIconTemplate = myCustomTemplate;
272
- * ```
273
- * ```html
274
- * <!-- Set in markup -->
275
- * <igx-combo #combo>
276
- * ...
277
- * <ng-template igxComboToggleIcon let-collapsed>
278
- * <igx-icon>{{ collapsed ? 'remove_circle' : 'remove_circle_outline'}}</igx-icon>
279
- * </ng-template>
280
- * </igx-combo>
281
- * ```
282
- */
283
- toggleIconTemplate: TemplateRef<any>;
284
- /**
285
- * The custom template, if any, that should be used when rendering the combo CLEAR button
286
- *
287
- * ```typescript
288
- * // Set in typescript
289
- * const myCustomTemplate: TemplateRef<any> = myComponent.customTemplate;
290
- * myComponent.combo.clearIconTemplate = myCustomTemplate;
291
- * ```
292
- * ```html
293
- * <!-- Set in markup -->
294
- * <igx-combo #combo>
295
- * ...
296
- * <ng-template igxComboClearIcon>
297
- * <igx-icon>clear</igx-icon>
298
- * </ng-template>
299
- * </igx-combo>
300
- * ```
301
- */
302
- clearIconTemplate: TemplateRef<any>;
303
- /**
304
- * @hidden @internal
305
- */
306
- virtualScrollContainer: IgxForOfDirective<any>;
307
- /**
308
- * Emitted when item selection is changing, before the selection completes
309
- *
310
- * ```html
311
- * <igx-combo (selectionChanging)='handleSelection()'></igx-combo>
312
- * ```
313
- */
314
- selectionChanging: EventEmitter<IComboSelectionChangingEventArgs>;
315
- /**
316
- * Emitted before the dropdown is opened
317
- *
318
- * ```html
319
- * <igx-combo opening='handleOpening($event)'></igx-combo>
320
- * ```
321
- */
322
- opening: EventEmitter<IBaseCancelableBrowserEventArgs>;
323
- /**
324
- * Emitted after the dropdown is opened
325
- *
326
- * ```html
327
- * <igx-combo (opened)='handleOpened($event)'></igx-combo>
328
- * ```
329
- */
330
- opened: EventEmitter<IBaseEventArgs>;
331
- /**
332
- * Emitted before the dropdown is closed
333
- *
334
- * ```html
335
- * <igx-combo (closing)='handleClosing($event)'></igx-combo>
336
- * ```
337
- */
338
- closing: EventEmitter<IBaseCancelableBrowserEventArgs>;
339
- /**
340
- * Emitted after the dropdown is closed
341
- *
342
- * ```html
343
- * <igx-combo (closed)='handleClosed($event)'></igx-combo>
344
- * ```
345
- */
346
- closed: EventEmitter<IBaseEventArgs>;
347
- /**
348
- * Emitted when an item is being added to the data collection
349
- *
350
- * ```html
351
- * <igx-combo (addition)='handleAdditionEvent($event)'></igx-combo>
352
- * ```
353
- */
354
- addition: EventEmitter<IComboItemAdditionEvent>;
355
- /**
356
- * Emitted when the value of the search input changes (e.g. typing, pasting, clear, etc.)
357
- *
358
- * ```html
359
- * <igx-combo (searchInputUpdate)='handleSearchInputEvent($event)'></igx-combo>
360
- * ```
361
- */
362
- searchInputUpdate: EventEmitter<IComboSearchInputEventArgs>;
363
- /**
364
- * Emitted when new chunk of data is loaded from the virtualization
365
- *
366
- * ```html
367
- * <igx-combo (dataPreLoad)='handleDataPreloadEvent($event)'></igx-combo>
368
- * ```
369
- */
370
- dataPreLoad: EventEmitter<IForOfState>;
371
- /**
372
- * Gets/gets combo id.
373
- *
374
- * ```typescript
375
- * // get
376
- * let id = this.combo.id;
377
- * ```
378
- *
379
- * ```html
380
- * <!--set-->
381
- * <igx-combo [id]='combo1'></igx-combo>
382
- * ```
383
- */
384
- id: string;
385
- /**
386
- * Sets the style width of the element
387
- *
388
- * ```typescript
389
- * // get
390
- * let myComboWidth = this.combo.width;
391
- * ```
392
- *
393
- * ```html
394
- * <!--set-->
395
- * <igx-combo [width]='250px'></igx-combo>
396
- * ```
397
- */
398
- width: string;
399
- /**
400
- * @hidden @internal
401
- */
402
- cssClass: string;
403
- /**
404
- * @hidden @internal
405
- */
406
- role: string;
407
- /**
408
- * @hidden @internal
409
- */
410
- get ariaExpanded(): boolean;
411
- /**
412
- * @hidden @internal
413
- */
414
- get hasPopUp(): string;
415
- /**
416
- * @hidden @internal
417
- */
418
- get ariaOwns(): string;
419
- /**
420
- * Controls whether custom values can be added to the collection
421
- *
422
- * ```typescript
423
- * // get
424
- * let comboAllowsCustomValues = this.combo.allowCustomValues;
425
- * ```
426
- *
427
- * ```html
428
- * <!--set-->
429
- * <igx-combo [allowCustomValues]='true'></igx-combo>
430
- * ```
431
- */
432
- allowCustomValues: boolean;
433
- /**
434
- * Configures the drop down list height
435
- *
436
- * ```typescript
437
- * // get
438
- * let myComboItemsMaxHeight = this.combo.itemsMaxHeight;
439
- * ```
440
- *
441
- * ```html
442
- * <!--set-->
443
- * <igx-combo [itemsMaxHeight]='320'></igx-combo>
444
- * ```
445
- */
446
- get itemsMaxHeight(): number;
447
- set itemsMaxHeight(val: number);
448
- /**
449
- * Configures the drop down list width
450
- *
451
- * ```typescript
452
- * // get
453
- * let myComboItemsWidth = this.combo.itemsWidth;
454
- * ```
455
- *
456
- * ```html
457
- * <!--set-->
458
- * <igx-combo [itemsWidth] = '"180px"'></igx-combo>
459
- * ```
460
- */
461
- itemsWidth: string;
462
- /**
463
- * Configures the drop down list item height
464
- *
465
- * ```typescript
466
- * // get
467
- * let myComboItemHeight = this.combo.itemHeight;
468
- * ```
469
- *
470
- * ```html
471
- * <!--set-->
472
- * <igx-combo [itemHeight]='32'></igx-combo>
473
- * ```
474
- */
475
- get itemHeight(): number;
476
- set itemHeight(val: number);
477
- /**
478
- * Defines the placeholder value for the combo value field
479
- *
480
- * ```typescript
481
- * // get
482
- * let myComboPlaceholder = this.combo.placeholder;
483
- * ```
484
- *
485
- * ```html
486
- * <!--set-->
487
- * <igx-combo [placeholder]='newPlaceHolder'></igx-combo>
488
- * ```
489
- */
490
- placeholder: any;
491
- /**
492
- * @hidden @internal
493
- */
494
- get inputEmpty(): boolean;
495
- /**
496
- * Defines the placeholder value for the combo dropdown search field
497
- *
498
- * ```typescript
499
- * // get
500
- * let myComboSearchPlaceholder = this.combo.searchPlaceholder;
501
- * ```
502
- *
503
- * ```html
504
- * <!--set-->
505
- * <igx-combo [searchPlaceholder]='newPlaceHolder'></igx-combo>
506
- * ```
507
- */
508
- searchPlaceholder: string;
86
+ protected _inputGroupType: IgxInputGroupType;
87
+ protected _injector: Injector;
509
88
  /**
510
89
  * Defines whether the caseSensitive icon should be shown in the search input
511
90
  *
@@ -521,66 +100,11 @@ export declare class IgxComboComponent extends DisplayDensityBase implements Igx
521
100
  */
522
101
  showSearchCaseIcon: boolean;
523
102
  /**
524
- * Combo data source.
525
- *
526
- * ```html
527
- * <!--set-->
528
- * <igx-combo [data]='items'></igx-combo>
529
- * ```
530
- */
531
- get data(): any[] | null;
532
- set data(val: any[] | null);
533
- /**
534
- * Combo value data source property.
535
- *
536
- * ```typescript
537
- * // get
538
- * let myComboValueKey = this.combo.valueKey;
539
- * ```
540
- *
541
- * ```html
542
- * <!--set-->
543
- * <igx-combo [valueKey]='myKey'></igx-combo>
544
- * ```
545
- */
546
- valueKey: string;
547
- set displayKey(val: string);
548
- /**
549
- * Combo text data source property.
550
- *
551
- * ```typescript
552
- * // get
553
- * let myComboDisplayKey = this.combo.displayKey;
554
- *
555
- * // set
556
- * this.combo.displayKey = 'val';
557
- *
558
- * ```
559
- *
560
- * ```html
561
- * <!--set-->
562
- * <igx-combo [displayKey]='myDisplayKey'></igx-combo>
563
- * ```
564
- */
565
- get displayKey(): string;
566
- /**
567
- * The item property by which items should be grouped inside the items list. Not usable if data is not of type Object[].
568
- *
569
- * ```html
570
- * <!--set-->
571
- * <igx-combo [groupKey]='newGroupKey'></igx-combo>
572
- * ```
573
- */
574
- set groupKey(val: string);
575
- /**
576
- * The item property by which items should be grouped inside the items list. Not usable if data is not of type Object[].
577
- *
578
- * ```typescript
579
- * // get
580
- * let currentGroupKey = this.combo.groupKey;
581
- * ```
103
+ * An @Input property that controls whether the combo's search box
104
+ * should be focused after the `opened` event is called
105
+ * When `false`, the combo's list item container will be focused instead
582
106
  */
583
- get groupKey(): string;
107
+ autoFocusSearch: boolean;
584
108
  /**
585
109
  * An @Input property that enabled/disables filtering in the list. The default is `true`.
586
110
  * ```html
@@ -589,262 +113,55 @@ export declare class IgxComboComponent extends DisplayDensityBase implements Igx
589
113
  */
590
114
  filterable: boolean;
591
115
  /**
592
- * An @Input property that sets groups sorting order.
593
- *
594
- * @example
595
- * ```html
596
- * <igx-combo [groupSortingDirection]="groupSortingDirection"></igx-combo>
597
- * ```
598
- * ```typescript
599
- * public groupSortingDirection = SortingDirection.Asc;
600
- * ```
601
- */
602
- get groupSortingDirection(): SortingDirection;
603
- set groupSortingDirection(val: SortingDirection);
604
- /**
605
- * An @Input property that set aria-labelledby attribute
606
- * ```html
607
- * <igx-combo [ariaLabelledBy]="'label1'">
608
- * ```
609
- */
610
- ariaLabelledBy: string;
611
- /**
612
- * An @Input property that enabled/disables combo. The default is `false`.
613
- * ```html
614
- * <igx-combo [disabled]="'true'">
615
- * ```
616
- */
617
- disabled: boolean;
618
- /**
619
- * An @Input property that sets how the combo will be styled.
620
- * The allowed values are `line`, `box`, `border` and `search`. The default is `box`.
621
- * ```html
622
- * <igx-combo [type]="'line'">
623
- * ```
624
- */
625
- get type(): IgxInputGroupType;
626
- set type(val: IgxInputGroupType);
627
- /**
628
- * An @Input property that controls whether the combo's search box
629
- * should be focused after the `opened` event is called
630
- * When `false`, the combo's list item container will be focused instead
631
- */
632
- autoFocusSearch: boolean;
633
- protected dropdownContainer: ElementRef;
634
- protected primitiveTemplate: TemplateRef<any>;
635
- protected complexTemplate: TemplateRef<any>;
636
- protected virtDir: IgxForOfDirective<any>;
637
- /**
638
- * Gets if control is valid, when used in a form
116
+ * Defines the placeholder value for the combo dropdown search field
639
117
  *
640
118
  * ```typescript
641
119
  * // get
642
- * let valid = this.combo.valid;
120
+ * let myComboSearchPlaceholder = this.combo.searchPlaceholder;
643
121
  * ```
644
- */
645
- get valid(): IgxComboState;
646
- /**
647
- * Sets if control is valid, when used in a form
648
122
  *
649
- * ```typescript
650
- * // set
651
- * this.combo.valid = IgxComboState.INVALID;
123
+ * ```html
124
+ * <!--set-->
125
+ * <igx-combo [searchPlaceholder]='newPlaceHolder'></igx-combo>
652
126
  * ```
653
127
  */
654
- set valid(valid: IgxComboState);
655
- /**
656
- * @hidden @internal
657
- */
658
- get searchValue(): string;
659
- set searchValue(val: string);
660
- /**
661
- * @hidden @internal
662
- */
663
- customValueFlag: boolean;
664
- /**
665
- * @hidden @internal
666
- */
667
- defaultFallbackGroup: string;
128
+ searchPlaceholder: string;
129
+ /** @hidden @internal */
130
+ dropdown: IgxComboDropDownComponent;
668
131
  /**
669
132
  * @hidden @internal
670
133
  */
671
- filteringOptions: IComboFilteringOptions;
134
+ get inputEmpty(): boolean;
135
+ /** @hidden @internal */
136
+ get filteredData(): any[] | null;
137
+ /** @hidden @internal */
138
+ set filteredData(val: any[] | null);
672
139
  /**
673
140
  * @hidden @internal
674
141
  */
675
142
  filteringLogic: FilteringLogic;
676
- /** @hidden @internal */
677
- filterValue: string;
678
143
  protected stringFilters: typeof IgxStringFilteringOperand;
679
144
  protected booleanFilters: typeof IgxBooleanFilteringOperand;
680
- protected _groupKey: string;
681
- protected _displayKey: string;
682
145
  protected _prevInputValue: string;
683
- private _dataType;
684
- private _searchValue;
685
- private _type;
686
- private ngControl;
687
- private destroy$;
688
- private _data;
689
- private _filteredData;
690
- private _itemHeight;
691
- private _itemsMaxHeight;
692
- private _remoteSelection;
693
- private _onChangeCallback;
694
- private _onTouchedCallback;
695
- private _overlaySettings;
696
- private _value;
697
- private _valid;
698
- private _groupSortingDirection;
699
- constructor(elementRef: ElementRef, cdr: ChangeDetectorRef, selection: IgxSelectionAPIService, comboAPI: IgxComboAPIService, _iconService: IgxIconService, _displayDensityOptions: IDisplayDensityOptions, _inputGroupType: IgxInputGroupType, _injector: Injector);
700
- /**
701
- * @hidden @internal
702
- */
703
- onArrowDown(event: Event): void;
704
- /**
705
- * @hidden @internal
706
- */
707
- onInputClick(event: Event): void;
708
- /**
709
- * Defines the current state of the virtualized data. It contains `startIndex` and `chunkSize`
710
- *
711
- * ```typescript
712
- * // get
713
- * let state = this.combo.virtualizationState;
714
- * ```
715
- */
716
- get virtualizationState(): IForOfState;
717
- /**
718
- * Sets the current state of the virtualized data.
719
- *
720
- * ```typescript
721
- * // set
722
- * this.combo.virtualizationState(state);
723
- * ```
724
- */
725
- set virtualizationState(state: IForOfState);
726
- /**
727
- * Gets total count of the virtual data items, when using remote service.
728
- *
729
- * ```typescript
730
- * // get
731
- * let count = this.combo.totalItemCount;
732
- * ```
733
- */
734
- get totalItemCount(): number;
735
- /**
736
- * Sets total count of the virtual data items, when using remote service.
737
- *
738
- * ```typescript
739
- * // set
740
- * this.combo.totalItemCount(remoteService.count);
741
- * ```
742
- */
743
- set totalItemCount(count: number);
744
- /**
745
- * The text displayed in the combo input
746
- *
747
- * ```typescript
748
- * // get
749
- * let comboValue = this.combo.value;
750
- * ```
751
- */
752
- get value(): string;
753
- /**
754
- * @hidden @internal
755
- */
756
- get filteredData(): any[] | null;
757
- /**
758
- * @hidden @internal
759
- */
760
- set filteredData(val: any[] | null);
146
+ constructor(elementRef: ElementRef, cdr: ChangeDetectorRef, selectionService: IgxSelectionAPIService, comboAPI: IgxComboAPIService, _iconService: IgxIconService, _displayDensityOptions: IDisplayDensityOptions, _inputGroupType: IgxInputGroupType, _injector: Injector);
147
+ /** @hidden @internal */
148
+ get displaySearchInput(): boolean;
761
149
  /**
762
150
  * @hidden @internal
763
151
  */
764
152
  handleKeyUp(event: KeyboardEvent): void;
765
- /**
766
- * @hidden @internal
767
- */
768
- handleKeyDown(event: KeyboardEvent): void;
769
- /**
770
- * @hidden @internal
771
- */
772
- handleInputChange(event?: string): void;
773
- /**
774
- * @hidden @internal
775
- */
776
- get dataType(): string;
777
- /**
778
- * @hidden @internal
779
- */
780
- get isRemote(): boolean;
781
- /**
782
- * Returns if the specified itemID is selected
783
- *
784
- * @hidden
785
- * @internal
786
- */
787
- isItemSelected(item: any): boolean;
788
- /**
789
- * Triggers change detection on the combo view
790
- */
791
- triggerCheck(): void;
792
- /**
793
- * @hidden @internal
794
- */
795
- isAddButtonVisible(): boolean;
796
153
  /**
797
154
  * @hidden @internal
798
155
  */
799
156
  handleSelectAll(evt: any): void;
800
- /**
801
- * @hidden @internal
802
- */
803
- addItemToCollection(): void;
804
- /**
805
- * @hidden @internal
806
- */
807
- focusSearchInput(opening?: boolean): void;
808
- /**
809
- * @hidden @internal
810
- */
811
- onBlur(): void;
812
- /**
813
- * @hidden @internal
814
- */
815
- ngOnInit(): void;
816
- /**
817
- * @hidden @internal
818
- */
819
- ngAfterViewInit(): void;
820
- /**
821
- * @hidden @internal
822
- */
823
- ngOnDestroy(): void;
824
157
  /**
825
158
  * @hidden @internal
826
159
  */
827
160
  writeValue(value: any[]): void;
828
- /**
829
- * @hidden @internal
830
- */
831
- registerOnChange(fn: any): void;
832
- /**
833
- * @hidden @internal
834
- */
835
- registerOnTouched(fn: any): void;
836
- /**
837
- * @hidden @internal
838
- */
839
- setDisabledState(isDisabled: boolean): void;
840
161
  /**
841
162
  * @hidden
842
163
  */
843
164
  getEditElement(): HTMLElement;
844
- /**
845
- * @hidden @internal
846
- */
847
- get template(): TemplateRef<any>;
848
165
  /**
849
166
  * @hidden @internal
850
167
  */
@@ -853,69 +170,25 @@ export declare class IgxComboComponent extends DisplayDensityBase implements Igx
853
170
  * @hidden @internal
854
171
  */
855
172
  handleClearItems(event: Event): void;
856
- /**
857
- * A method that opens/closes the combo.
858
- *
859
- * ```html
860
- * <button (click)="combo.toggle()">Toggle Combo</button>
861
- * <igx-combo #combo></igx-combo>
862
- * ```
863
- */
864
- toggle(): void;
865
- /**
866
- * A method that opens the combo.
867
- *
868
- * ```html
869
- * <button (click)="combo.open()">Open Combo</button>
870
- * <igx-combo #combo></igx-combo>
871
- * ```
872
- */
873
- open(): void;
874
- /**
875
- * A method that closes the combo.
876
- *
877
- * ```html
878
- * <button (click)="combo.close()">Close Combo</button>
879
- * <igx-combo #combo></igx-combo>
880
- * ```
881
- */
882
- close(): void;
883
- /**
884
- * Gets drop down state.
885
- *
886
- * ```typescript
887
- * let state = this.combo.collapsed;
888
- * ```
889
- */
890
- get collapsed(): boolean;
891
- /**
892
- * Get current selection state
893
- *
894
- * @returns Array of selected items
895
- * ```typescript
896
- * let selectedItems = this.combo.selectedItems();
897
- * ```
898
- */
899
- selectedItems(): any[];
900
173
  /**
901
174
  * Select defined items
902
175
  *
903
176
  * @param newItems new items to be selected
904
177
  * @param clearCurrentSelection if true clear previous selected items
905
178
  * ```typescript
906
- * this.combo.selectItems(["New York", "New Jersey"]);
179
+ * this.combo.select(["New York", "New Jersey"]);
907
180
  * ```
908
181
  */
909
- selectItems(newItems: Array<any>, clearCurrentSelection?: boolean, event?: Event): void;
182
+ select(newItems: Array<any>, clearCurrentSelection?: boolean, event?: Event): void;
910
183
  /**
911
184
  * Deselect defined items
912
185
  *
913
186
  * @param items items to deselected
914
187
  * ```typescript
915
- * this.combo.deselectItems(["New York", "New Jersey"]);
188
+ * this.combo.deselect(["New York", "New Jersey"]);
916
189
  * ```
917
190
  */
918
- deselectItems(items: Array<any>, event?: Event): void;
191
+ deselect(items: Array<any>, event?: Event): void;
919
192
  /**
920
193
  * Select all (filtered) items
921
194
  *
@@ -954,57 +227,26 @@ export declare class IgxComboComponent extends DisplayDensityBase implements Igx
954
227
  * ```
955
228
  */
956
229
  setSelectedItem(itemID: any, select?: boolean, event?: Event): void;
957
- /**
958
- * Event handlers
959
- *
960
- * @hidden
961
- * @internal
962
- */
963
- handleOpening(e: IBaseCancelableBrowserEventArgs): void;
964
- /**
965
- * @hidden @internal
966
- */
967
- handleOpened(): void;
968
- /**
969
- * @hidden @internal
970
- */
971
- handleClosing(e: IBaseCancelableBrowserEventArgs): void;
972
- /**
973
- * @hidden @internal
974
- */
975
- handleClosed(): void;
976
230
  /**
977
231
  * @hidden @internal
978
232
  */
979
233
  toggleCaseSensitive(): void;
234
+ /** @hidden @internal */
235
+ handleOpened(): void;
236
+ /** @hidden @internal */
237
+ focusSearchInput(opening?: boolean): void;
980
238
  protected setSelection(newSelection: Set<any>, event?: Event): void;
981
- protected onStatusChanged: () => void;
982
- protected manageRequiredAsterisk(): void;
983
- /** Contains key-value pairs of the selected valueKeys and their resp. displayKeys */
984
- private registerRemoteEntries;
985
- /**
986
- * For `id: any[]` returns a mapped `{ [combo.valueKey]: any, [combo.displayKey]: any }[]`
987
- */
988
- private getValueDisplayPairs;
989
- private checkMatch;
239
+ protected createDisplayText(newSelection: any[], oldSelection: any[]): string;
990
240
  /** Returns a string that should be populated in the combo's text box */
991
241
  private concatDisplayText;
992
- /**
993
- * Constructs the combo display value
994
- * If remote, caches the key displayText
995
- * If not, just combine the object.displayKeys
996
- */
997
- private createDisplayText;
998
- /** if there is a valueKey - map the keys to data items, else - just return the keys */
999
- private convertKeysToItems;
1000
242
  static ɵfac: i0.ɵɵFactoryDeclaration<IgxComboComponent, [null, null, null, null, null, { optional: true; }, { optional: true; }, { optional: true; }]>;
1001
- static ɵcmp: i0.ɵɵComponentDeclaration<IgxComboComponent, "igx-combo", never, { "overlaySettings": "overlaySettings"; "id": "id"; "width": "width"; "allowCustomValues": "allowCustomValues"; "itemsMaxHeight": "itemsMaxHeight"; "itemsWidth": "itemsWidth"; "itemHeight": "itemHeight"; "placeholder": "placeholder"; "searchPlaceholder": "searchPlaceholder"; "showSearchCaseIcon": "showSearchCaseIcon"; "data": "data"; "valueKey": "valueKey"; "displayKey": "displayKey"; "groupKey": "groupKey"; "filterable": "filterable"; "groupSortingDirection": "groupSortingDirection"; "ariaLabelledBy": "ariaLabelledBy"; "disabled": "disabled"; "type": "type"; "autoFocusSearch": "autoFocusSearch"; }, { "selectionChanging": "selectionChanging"; "opening": "opening"; "opened": "opened"; "closing": "closing"; "closed": "closed"; "addition": "addition"; "searchInputUpdate": "searchInputUpdate"; "dataPreLoad": "dataPreLoad"; }, ["itemTemplate", "headerTemplate", "footerTemplate", "headerItemTemplate", "addItemTemplate", "emptyTemplate", "toggleIconTemplate", "clearIconTemplate"], ["[igxLabel]", "igx-prefix", "igx-hint, [igxHint]", "igx-suffix"]>;
243
+ static ɵcmp: i0.ɵɵComponentDeclaration<IgxComboComponent, "igx-combo", never, { "showSearchCaseIcon": "showSearchCaseIcon"; "autoFocusSearch": "autoFocusSearch"; "filterable": "filterable"; "searchPlaceholder": "searchPlaceholder"; }, {}, never, ["[igxLabel]", "igx-prefix", "igx-hint, [igxHint]", "igx-suffix"]>;
1002
244
  }
1003
245
  /**
1004
246
  * @hidden
1005
247
  */
1006
248
  export declare class IgxComboModule {
1007
249
  static ɵfac: i0.ɵɵFactoryDeclaration<IgxComboModule, never>;
1008
- static ɵmod: i0.ɵɵNgModuleDeclaration<IgxComboModule, [typeof i1.IgxComboAddItemComponent, typeof i2.IgxComboAddItemDirective, typeof i2.IgxComboClearIconDirective, typeof IgxComboComponent, typeof i3.IgxComboDropDownComponent, typeof i2.IgxComboEmptyDirective, typeof i4.IgxComboFilteringPipe, typeof i2.IgxComboFooterDirective, typeof i4.IgxComboGroupingPipe, typeof i2.IgxComboHeaderDirective, typeof i2.IgxComboHeaderItemDirective, typeof i5.IgxComboItemComponent, typeof i2.IgxComboItemDirective, typeof i2.IgxComboToggleIconDirective], [typeof i6.CommonModule, typeof i7.FormsModule, typeof i8.IgxButtonModule, typeof i9.IgxCheckboxModule, typeof i10.IgxDropDownModule, typeof i11.IgxForOfModule, typeof i12.IgxIconModule, typeof i13.IgxInputGroupModule, typeof i14.IgxRippleModule, typeof i15.IgxToggleModule, typeof i7.ReactiveFormsModule], [typeof i2.IgxComboAddItemDirective, typeof i2.IgxComboClearIconDirective, typeof IgxComboComponent, typeof i2.IgxComboEmptyDirective, typeof i2.IgxComboFooterDirective, typeof i2.IgxComboHeaderDirective, typeof i2.IgxComboHeaderItemDirective, typeof i2.IgxComboItemDirective, typeof i2.IgxComboToggleIconDirective, typeof i13.IgxInputGroupModule]>;
250
+ static ɵmod: i0.ɵɵNgModuleDeclaration<IgxComboModule, [typeof i1.IgxComboAddItemComponent, typeof i2.IgxComboAddItemDirective, typeof i2.IgxComboClearIconDirective, typeof IgxComboComponent, typeof i3.IgxComboDropDownComponent, typeof i2.IgxComboEmptyDirective, typeof i4.IgxComboFilteringPipe, typeof i2.IgxComboFooterDirective, typeof i4.IgxComboGroupingPipe, typeof i2.IgxComboHeaderDirective, typeof i2.IgxComboHeaderItemDirective, typeof i5.IgxComboItemComponent, typeof i2.IgxComboItemDirective, typeof i2.IgxComboToggleIconDirective], [typeof i6.CommonModule, typeof i7.FormsModule, typeof i8.IgxButtonModule, typeof i9.IgxCheckboxModule, typeof i10.IgxDropDownModule, typeof i11.IgxForOfModule, typeof i12.IgxIconModule, typeof i13.IgxInputGroupModule, typeof i14.IgxRippleModule, typeof i15.IgxToggleModule, typeof i7.ReactiveFormsModule], [typeof i1.IgxComboAddItemComponent, typeof i2.IgxComboAddItemDirective, typeof i2.IgxComboClearIconDirective, typeof IgxComboComponent, typeof i3.IgxComboDropDownComponent, typeof i2.IgxComboEmptyDirective, typeof i4.IgxComboFilteringPipe, typeof i2.IgxComboFooterDirective, typeof i4.IgxComboGroupingPipe, typeof i2.IgxComboHeaderDirective, typeof i2.IgxComboHeaderItemDirective, typeof i5.IgxComboItemComponent, typeof i2.IgxComboItemDirective, typeof i2.IgxComboToggleIconDirective, typeof i13.IgxInputGroupModule]>;
1009
251
  static ɵinj: i0.ɵɵInjectorDeclaration<IgxComboModule>;
1010
252
  }