@syncfusion/ej2-lists 30.1.37 → 30.1.42

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 (38) hide show
  1. package/.eslintrc.json +2 -0
  2. package/dist/ej2-lists.min.js +2 -2
  3. package/dist/ej2-lists.umd.min.js +2 -2
  4. package/dist/ej2-lists.umd.min.js.map +1 -1
  5. package/dist/es6/ej2-lists.es2015.js +8 -1
  6. package/dist/es6/ej2-lists.es2015.js.map +1 -1
  7. package/dist/es6/ej2-lists.es5.js +8 -1
  8. package/dist/es6/ej2-lists.es5.js.map +1 -1
  9. package/dist/global/ej2-lists.min.js +2 -2
  10. package/dist/global/ej2-lists.min.js.map +1 -1
  11. package/dist/global/index.d.ts +1 -1
  12. package/package.json +11 -54
  13. package/src/list-view/list-view.d.ts +1 -0
  14. package/src/list-view/list-view.js +8 -1
  15. package/styles/bootstrap5.3-lite.css +4 -0
  16. package/styles/bootstrap5.3.css +4 -0
  17. package/styles/list-view/_theme.scss +1 -1
  18. package/styles/list-view/bootstrap5.3.css +4 -0
  19. package/dist/ts/common/index.d.ts +0 -4
  20. package/dist/ts/common/index.ts +0 -4
  21. package/dist/ts/common/list-base.d.ts +0 -415
  22. package/dist/ts/common/list-base.ts +0 -1362
  23. package/dist/ts/component.d.ts +0 -4
  24. package/dist/ts/component.ts +0 -4
  25. package/dist/ts/index.d.ts +0 -6
  26. package/dist/ts/index.ts +0 -6
  27. package/dist/ts/list-view/index.d.ts +0 -6
  28. package/dist/ts/list-view/index.ts +0 -6
  29. package/dist/ts/list-view/list-view-model.d.ts +0 -324
  30. package/dist/ts/list-view/list-view.d.ts +0 -844
  31. package/dist/ts/list-view/list-view.ts +0 -2732
  32. package/dist/ts/list-view/virtualization.d.ts +0 -97
  33. package/dist/ts/list-view/virtualization.ts +0 -947
  34. package/dist/ts/sortable/index.d.ts +0 -5
  35. package/dist/ts/sortable/index.ts +0 -5
  36. package/dist/ts/sortable/sortable-model.d.ts +0 -80
  37. package/dist/ts/sortable/sortable.d.ts +0 -146
  38. package/dist/ts/sortable/sortable.ts +0 -483
@@ -1,844 +0,0 @@
1
- import { Virtualization } from './virtualization';
2
- import { ModuleDeclaration } from '@syncfusion/ej2-base';
3
- import { Component, BaseEventArgs } from '@syncfusion/ej2-base';
4
- import { INotifyPropertyChanged, ChildProperty } from '@syncfusion/ej2-base';
5
- import { EmitType } from '@syncfusion/ej2-base';
6
- import { DataManager, Query } from '@syncfusion/ej2-data';
7
- import { ListBaseOptions, SortOrder, FieldsMapping } from '../common/list-base';
8
- import { ListViewModel, FieldSettingsModel } from './list-view-model';
9
- export declare const classNames: ClassNames;
10
- /**
11
- * An interface that holds options of fields.
12
- */
13
- export interface Fields {
14
- /**
15
- * Specifies the id field mapped in dataSource.
16
- */
17
- id?: string | number;
18
- /**
19
- * The `text` property is used to map the text value from the data source for each list item.
20
- */
21
- text?: string | number;
22
- /**
23
- * It is used to map the custom field values of list item from the dataSource.
24
- */
25
- [key: string]: Object | string | number | undefined;
26
- }
27
- /**
28
- * Represents the field settings of the ListView.
29
- */
30
- export declare class FieldSettings extends ChildProperty<FieldSettings> {
31
- /**
32
- * Specifies the id field mapped in dataSource.
33
- */
34
- id: string;
35
- /**
36
- * The `text` property is used to map the text value from the data source for each list item.
37
- */
38
- text: string;
39
- /**
40
- * The `isChecked` property is used to check whether the list items are in checked state or not.
41
- */
42
- isChecked: string;
43
- /**
44
- * The `isVisible` property is used to check whether the list items are in visible state or not.
45
- */
46
- isVisible: string;
47
- /**
48
- * Specifies the enabled state of the ListView component.
49
- * And, we can disable the component using this property by setting its value as false.
50
- */
51
- enabled: string;
52
- /**
53
- * The `iconCss` is used to customize the icon to the list items dynamically.
54
- * We can add a specific image to the icons using `iconCss` property.
55
- */
56
- iconCss: string;
57
- /**
58
- * The `child` property is used for nested navigation of listed items.
59
- */
60
- child: string;
61
- /**
62
- * The `tooltip` is used to display the information about the target element while hovering on list items.
63
- */
64
- tooltip: string;
65
- /**
66
- * The `groupBy` property is used to wraps the ListView elements into a group.
67
- */
68
- groupBy: string;
69
- /**
70
- * The `sortBy` property used to enable the sorting of list items to be ascending or descending order.
71
- */
72
- sortBy: string;
73
- /**
74
- * The `htmlAttributes` allows additional attributes such as id, class, etc., and
75
- * accepts n number of attributes in a key-value pair format.
76
- */
77
- htmlAttributes: string;
78
- /**
79
- * Specifies the `tableName` used to fetch data from a specific table in the server.
80
- */
81
- tableName: string;
82
- }
83
- /**
84
- * An interface that holds animation settings.
85
- */
86
- export interface AnimationSettings {
87
- /**
88
- * It is used to specify the effect which is shown in sub list transform.
89
- */
90
- effect?: ListViewEffect;
91
- /**
92
- * It is used to specify the time duration of transform object.
93
- */
94
- duration?: number;
95
- /**
96
- * It is used to specify the easing effect applied while transform
97
- */
98
- easing?: string;
99
- }
100
- /**
101
- * An enum type that denotes the effects of the ListView. Available options are as follows None, SlideLeft, SlideDown, Zoom, Fade;
102
- * ```props
103
- * None :- No animation is applied when items are added or removed from the ListView.
104
- * SlideLeft :- Items slide in from the left when added and slide out to the left when removed.
105
- * SlideDown :- Items slide in from the top when added and slide out to the top when removed.
106
- * Zoom :- Items zoom in or out when added or removed.
107
- * Fade :- Items fade in or out when added or removed.
108
- * ```
109
- */
110
- export declare type ListViewEffect = 'None' | 'SlideLeft' | 'SlideDown' | 'Zoom' | 'Fade';
111
- /**
112
- * An enum type that denotes the position of checkbox of the ListView. Available options are as follows Left and Right;
113
- * ```props
114
- * Left :- The checkbox is positioned on the left side of the ListView item.
115
- * Right :- The checkbox is positioned on the right side of the ListView item.
116
- * ```
117
- */
118
- export declare type checkBoxPosition = 'Left' | 'Right';
119
- /**
120
- * Represents the EJ2 ListView control.
121
- * ```html
122
- * <div id="listview">
123
- * <ul>
124
- * <li>Favorite</li>
125
- * <li>Documents</li>
126
- * <li>Downloads</li>
127
- * </ul>
128
- * </div>
129
- * ```
130
- * ```typescript
131
- * var listviewObject = new ListView({});
132
- * listviewObject.appendTo("#listview");
133
- * ```
134
- */
135
- export declare class ListView extends Component<HTMLElement> implements INotifyPropertyChanged {
136
- private ulElement;
137
- private selectedLI;
138
- private onUIScrolled;
139
- private curUL;
140
- private curDSLevel;
141
- private curViewDS;
142
- private curDSJSON;
143
- localData: DataSource[];
144
- private liCollection;
145
- private headerEle;
146
- private contentContainer;
147
- private touchModule;
148
- private listBaseOption;
149
- virtualizationModule: Virtualization;
150
- private animateOptions;
151
- private rippleFn;
152
- private isNestedList;
153
- private currentLiElements;
154
- private selectedData;
155
- private selectedId;
156
- private isWindow;
157
- private selectedItems;
158
- private aniObj;
159
- private LISTVIEW_TEMPLATE_ID;
160
- private LISTVIEW_GROUPTEMPLATE_ID;
161
- private LISTVIEW_HEADERTEMPLATE_ID;
162
- private liElement;
163
- private virtualCheckBox;
164
- private liElementHeight;
165
- private previousSelectedItems;
166
- private hiddenItems;
167
- private enabledItems;
168
- private disabledItems;
169
- private isOffline;
170
- private previousScrollTop;
171
- /**
172
- * The `cssClass` property is used to add a user-preferred class name in the root element of the ListView,
173
- * using which we can customize the component (both CSS and functionality customization)
174
- *
175
- * {% codeBlock src='listview/cssClass/index.md' %}{% endcodeBlock %}
176
- *
177
- * @default ''
178
- */
179
- cssClass: string;
180
- /**
181
- * If `enableVirtualization` set to true, which will increase the ListView performance, while loading a large amount of data.
182
- *
183
- * {% codeBlock src='listview/enableVirtualization/index.md' %}{% endcodeBlock %}
184
- *
185
- * @default false
186
- */
187
- enableVirtualization: boolean;
188
- /**
189
- * The `htmlAttributes` allows additional attributes such as id, class, etc., and
190
- * accepts n number of attributes in a key-value pair format.
191
- *
192
- * {% codeBlock src='listview/htmlAttributes/index.md' %}{% endcodeBlock %}
193
- *
194
- * @default {}
195
- */
196
- htmlAttributes: {
197
- [key: string]: string;
198
- };
199
- /**
200
- * If `enable` set to true, the list items are enabled.
201
- * And, we can disable the component using this property by setting its value as false.
202
- *
203
- * {% codeBlock src='listview/enable/index.md' %}{% endcodeBlock %}
204
- *
205
- * @default true
206
- */
207
- enable: boolean;
208
- /**
209
- * The `dataSource` provides the data to render the ListView component which is mapped with the fields of ListView.
210
- *
211
- * @isGenericType true
212
- *
213
- * {% codeBlock src='listview/dataSource/index.md' %}{% endcodeBlock %}
214
- *
215
- * @default []
216
- */
217
- dataSource: {
218
- [key: string]: Object;
219
- }[] | string[] | number[] | DataManager;
220
- /**
221
- * The `query` is used to fetch the specific data from dataSource by using where and select keywords.
222
- *
223
- * {% codeBlock src='listview/query/index.md' %}{% endcodeBlock %}
224
- *
225
- * @default null
226
- */
227
- query: Query;
228
- /**
229
- * The `fields` is used to map keys from the dataSource which extracts the appropriate data from the dataSource
230
- * with specified mapped with the column fields to render the ListView.
231
- *
232
- * {% codeBlock src='listview/fields/index.md' %}{% endcodeBlock %}
233
- *
234
- * @default defaultMappedFields
235
- */
236
- fields: FieldSettingsModel;
237
- /**
238
- * The `animation` property provides an option to apply the different
239
- * animations on the ListView component.
240
- *
241
- * {% codeBlock src='listview/animation/index.md' %}{% endcodeBlock %}
242
- *
243
- *
244
- * @default { effect: 'SlideLeft', duration: 400, easing: 'ease' }
245
- */
246
- animation: AnimationSettings;
247
- /**
248
- * The `sortOrder` is used to sort the data source. The available type of sort orders are,
249
- * * `None` - The data source is not sorting.
250
- * * `Ascending` - The data source is sorting with ascending order.
251
- * * `Descending` - The data source is sorting with descending order.
252
- *
253
- * {% codeBlock src='listview/sortOrder/index.md' %}{% endcodeBlock %}
254
- *
255
- * @default 'None'
256
- */
257
- sortOrder: SortOrder;
258
- /**
259
- * If `showIcon` set to true, which will show or hide the icon of the list item.
260
- *
261
- * {% codeBlock src='listview/showIcon/index.md' %}{% endcodeBlock %}
262
- *
263
- * @default false
264
- */
265
- showIcon: boolean;
266
- /**
267
- * If `showCheckBox` set to true, which will show or hide the checkbox.
268
- *
269
- * {% codeBlock src='listview/showCheckBox/index.md' %}{% endcodeBlock %}
270
- *
271
- *
272
- * @default false
273
- */
274
- showCheckBox: boolean;
275
- /**
276
- * The `checkBoxPosition` is used to set the position of check box in a list item.
277
- * By default, the `checkBoxPosition` is Left, which will appear before the text content in a list item.
278
- *
279
- * {% codeBlock src='listview/checkBoxPosition/index.md' %}{% endcodeBlock %}
280
- *
281
- * @default 'Left'
282
- */
283
- checkBoxPosition: checkBoxPosition;
284
- /**
285
- * The `headerTitle` is used to set the title of the ListView component.
286
- *
287
- * {% codeBlock src='listview/headerTitle/index.md' %}{% endcodeBlock %}
288
- *
289
- *
290
- * @default ""
291
- */
292
- headerTitle: string;
293
- /**
294
- * If `showHeader` set to true, which will show or hide the header of the ListView component.
295
- *
296
- * {% codeBlock src='listview/showHeader/index.md' %}{% endcodeBlock %}
297
- *
298
- * @default false
299
- */
300
- showHeader: boolean;
301
- /**
302
- * Specifies whether to display or remove the untrusted HTML values in the ListView component.
303
- * If 'enableHtmlSanitizer' set to true, the component will sanitize any suspected untrusted strings and scripts before rendering them.
304
- *
305
- * {% codeBlock src='listview/enableHtmlSanitizer/index.md' %}{% endcodeBlock %}
306
- *
307
- * @default true
308
- */
309
- enableHtmlSanitizer: boolean;
310
- /**
311
- * Defines the height of the ListView component which accepts both string and number values.
312
- *
313
- * {% codeBlock src='listview/height/index.md' %}{% endcodeBlock %}
314
- *
315
- * @default ''
316
- */
317
- height: number | string;
318
- /**
319
- * Defines the width of the ListView component which accepts both string and number values.
320
- *
321
- * {% codeBlock src='listview/width/index.md' %}{% endcodeBlock %}
322
- *
323
- * @default ''
324
- */
325
- width: number | string;
326
- /**
327
- * The ListView component supports to customize the content of each list items with the help of `template` property.
328
- *
329
- * {% codeBlock src='listview/template/index.md' %}{% endcodeBlock %}
330
- *
331
- * @default null
332
- * @angularType string | object
333
- * @reactType string | function | JSX.Element
334
- * @vueType string | function
335
- * @aspType string
336
- */
337
- template: string | Function;
338
- /**
339
- * The ListView has an option to custom design the ListView header title with the help of `headerTemplate` property.
340
- *
341
- * {% codeBlock src="listview/headerTemplate/index.md" %}{% endcodeBlock %}
342
- *
343
- * @default null
344
- * @angularType string | object
345
- * @reactType string | function | JSX.Element
346
- * @vueType string | function
347
- * @aspType string
348
- */
349
- headerTemplate: string | Function;
350
- /**
351
- * The ListView has an option to custom design the group header title with the help of `groupTemplate` property.
352
- *
353
- * {% codeBlock src="listview/groupTemplate/index.md" %}{% endcodeBlock %}
354
- *
355
- * @default null
356
- * @angularType string | object
357
- * @reactType string | function | JSX.Element
358
- * @vueType string | function
359
- * @aspType string
360
- */
361
- groupTemplate: string | Function;
362
- /**
363
- * Triggers when we select the list item in the component.
364
- *
365
- * @event 'object'
366
- */
367
- select: EmitType<SelectEventArgs>;
368
- /**
369
- * Triggers when every ListView action starts.
370
- *
371
- * @event 'object'
372
- */
373
- actionBegin: EmitType<object>;
374
- /**
375
- * Triggers when every ListView actions completed.
376
- *
377
- * @event 'object'
378
- */
379
- actionComplete: EmitType<MouseEvent>;
380
- /**
381
- * Triggers, when the data fetch request from the remote server, fails.
382
- *
383
- * @event 'object'
384
- *
385
- */
386
- actionFailure: EmitType<MouseEvent>;
387
- /**
388
- * Triggers when scrollbar of the ListView component reaches to the top or bottom.
389
- *
390
- * @event 'object'
391
- */
392
- scroll: EmitType<ScrolledEventArgs>;
393
- /**
394
- * Constructor for creating the widget
395
- *
396
- * @param options
397
- *
398
- * @param element
399
- */
400
- constructor(options?: ListViewModel, element?: string | HTMLElement);
401
- /**
402
- * @param newProp
403
- *
404
- * @param oldProp
405
- *
406
- * @private
407
- */
408
- onPropertyChanged(newProp: ListViewModel, oldProp: ListViewModel): void;
409
- private setHTMLAttribute;
410
- private setCSSClass;
411
- private setSize;
412
- private setEnable;
413
- private setEnableRTL;
414
- private enableElement;
415
- private header;
416
- private switchView;
417
- protected preRender(): void;
418
- private initialization;
419
- private renderCheckbox;
420
- private checkInternally;
421
- /**
422
- * Checks the specific list item by passing the unchecked fields as an argument to this method.
423
- *
424
- * @param {Fields | HTMLElement | Element} item - It accepts Fields or HTML list element as an argument.
425
- */
426
- checkItem(item: Fields | HTMLElement | Element): void;
427
- private toggleCheckBase;
428
- /**
429
- * Uncheck the specific list item by passing the checked fields as an argument to this method.
430
- *
431
- * @param {Fields | HTMLElement | Element} item - It accepts Fields or HTML list element as an argument.
432
- */
433
- uncheckItem(item: Fields | HTMLElement | Element): void;
434
- /**
435
- * Checks all the unchecked items in the ListView.
436
- */
437
- checkAllItems(): void;
438
- /**
439
- * Uncheck all the checked items in ListView.
440
- */
441
- uncheckAllItems(): void;
442
- private toggleAllCheckBase;
443
- private setCheckbox;
444
- /**
445
- * Refresh the height of the list item only on enabling the virtualization property.
446
- */
447
- refreshItemHeight(): void;
448
- private handleCheckboxState;
449
- targetElement: Element;
450
- private clickHandler;
451
- private removeElement;
452
- private hoverHandler;
453
- private leaveHandler;
454
- private homeKeyHandler;
455
- private onArrowKeyDown;
456
- private arrowKeyHandler;
457
- private enterKeyHandler;
458
- private spaceKeyHandler;
459
- private keyActionHandler;
460
- private swipeActionHandler;
461
- private focusout;
462
- private wireEvents;
463
- private unWireEvents;
464
- private removeFocus;
465
- private removeHover;
466
- private removeSelect;
467
- private isValidLI;
468
- private setCheckboxLI;
469
- private selectEventData;
470
- private setSelectedItemData;
471
- private setSelectLI;
472
- private setHoverLI;
473
- private getSubDS;
474
- private getItemData;
475
- private findItemFromDS;
476
- private getQuery;
477
- private setViewDataSource;
478
- private isInAnimation;
479
- private renderRemoteLists;
480
- private triggerActionFailure;
481
- private setLocalData;
482
- private reRender;
483
- private resetCurrentList;
484
- private setAttributes;
485
- private createList;
486
- private renderSubList;
487
- private renderIntoDom;
488
- private renderList;
489
- private getElementUID;
490
- /**
491
- * Initializes the ListView component rendering.
492
- */
493
- render(): void;
494
- /**
495
- * It is used to destroy the ListView component.
496
- */
497
- destroy(): void;
498
- /**
499
- * Switches back from the navigated sub list item.
500
- */
501
- back(): void;
502
- /**
503
- * Selects the list item from the ListView by passing the elements or field object.
504
- *
505
- * @param {Fields | HTMLElement | Element} item - We can pass element Object or Fields as Object with ID and Text fields.
506
- */
507
- selectItem(item: Fields | HTMLElement | Element): void;
508
- /**
509
- * This method allows for deselecting a list item within the ListView. The item to be deselected can be specified by passing the element or field object.
510
- *
511
- * @param {Fields | HTMLElement | Element} item - We can pass an element Object or Fields as an Object with ID and Text fields.
512
- */
513
- unselectItem(item?: Fields | HTMLElement | Element): void;
514
- private getLiFromObjOrElement;
515
- /**
516
- * Selects multiple list items from the ListView.
517
- *
518
- * @param {Fields[] | HTMLElement[] | Element[]} item - We can pass array of
519
- * elements or array of fields Object with ID and Text fields.
520
- */
521
- selectMultipleItems(item: Fields[] | HTMLElement[] | Element[]): void;
522
- private getParentId;
523
- private updateSelectedId;
524
- /**
525
- * Gets the details of the currently selected item from the list items.
526
- *
527
- */
528
- getSelectedItems(): SelectedItem | SelectedCollection | UISelectedItem | NestedListData;
529
- /**
530
- * Finds out an item details from the current list.
531
- *
532
- * @param {Fields | HTMLElement | Element} item - We can pass element Object or Fields as Object with ID and Text fields.
533
- */
534
- findItem(item: Fields | HTMLElement | Element): SelectedItem;
535
- /**
536
- * Enables the disabled list items by passing the Id and text fields.
537
- *
538
- * @param {Fields | HTMLElement | Element} item - We can pass element Object or Fields as Object with ID and Text fields.
539
- */
540
- enableItem(item: Fields | HTMLElement | Element): void;
541
- /**
542
- * Disables the list items by passing the Id and text fields.
543
- *
544
- * @param {Fields | HTMLElement | Element} item - We can pass element Object or Fields as Object with ID and Text fields.
545
- */
546
- disableItem(item: Fields | HTMLElement | Element): void;
547
- private setItemState;
548
- /**
549
- * Shows the hide list item from the ListView.
550
- *
551
- * @param {Fields | HTMLElement | Element} item - We can pass element Object or Fields as Object with ID and Text fields.
552
- */
553
- showItem(item: Fields | HTMLElement | Element): void;
554
- /**
555
- * Hides an list item from the ListView.
556
- *
557
- * @param {Fields | HTMLElement | Element} item - We can pass element Object or Fields as Object with ID and Text fields.
558
- */
559
- hideItem(item: Fields | HTMLElement | Element): void;
560
- private showHideItem;
561
- /**
562
- * Adds the new list item(s) to the current ListView.
563
- * To add a new list item(s) in the ListView, we need to pass the `data` as an array of items that need
564
- * to be added and `fields` as the target item to which we need to add the given item(s) as its children.
565
- * For example fields: { text: 'Name', tooltip: 'Name', id:'id'}
566
- *
567
- * @param {{Object}[]} data - JSON Array Data that need to add.
568
- *
569
- * @param {Fields} fields - Target item to add the given data as its children (can be null).
570
- *
571
- * @param {number} index - Indicates the index where the data to be added.
572
- */
573
- addItem(data: {
574
- [key: string]: Object;
575
- }[], fields?: Fields, index?: number): void;
576
- private addItemInternally;
577
- private addItemAtIndex;
578
- private addItemInNestedList;
579
- private addItemIntoDom;
580
- private addListItem;
581
- /**
582
- * Removes the list item from the data source based on a passed
583
- * element like fields: { text: 'Name', tooltip: 'Name', id:'id'}
584
- *
585
- * @param {Fields | HTMLElement | Element} item - We can pass element Object or Fields as Object with ID and Text fields.
586
- */
587
- removeItem(item: Fields | HTMLElement | Element): void;
588
- private removeItemFromList;
589
- private validateNestedView;
590
- /**
591
- * Removes multiple items from the ListView by passing the array of elements or array of field objects.
592
- *
593
- * @param {Fields[] | HTMLElement[] | Element[]} item - We can pass array of elements or array of field Object with ID and Text fields.
594
- */
595
- removeMultipleItems(item: HTMLElement[] | Element[] | Fields[]): void;
596
- private findParent;
597
- protected getModuleName(): string;
598
- requiredModules(): ModuleDeclaration[];
599
- private onListScroll;
600
- /**
601
- * Get the properties to be maintained in the persisted state.
602
- */
603
- protected getPersistData(): string;
604
- }
605
- /** @hidden */
606
- export interface ClassNames {
607
- root: string;
608
- hover: string;
609
- focused: string;
610
- selected: string;
611
- parentItem: string;
612
- listItem: string;
613
- hasChild: string;
614
- view: string;
615
- header: string;
616
- text: string;
617
- headerText: string;
618
- headerTemplateText: string;
619
- listItemText: string;
620
- listIcon: string;
621
- textContent: string;
622
- groupListItem: string;
623
- disable: string;
624
- container: string;
625
- backIcon: string;
626
- backButton: string;
627
- icon: string;
628
- checkboxWrapper: string;
629
- checkbox: string;
630
- checked: string;
631
- checkboxIcon: string;
632
- checklist: string;
633
- checkboxRight: string;
634
- checkboxLeft: string;
635
- listviewCheckbox: string;
636
- itemCheckList: string;
637
- virtualElementContainer: string;
638
- }
639
- /**
640
- * An interface that holds list selected item.
641
- */
642
- export interface ListSelectedItem {
643
- /**
644
- * Specifies the selected item dataSource collection.
645
- *
646
- * @isGenericType true
647
- */
648
- data?: object[];
649
- /**
650
- * Specifies the selected item text collection.
651
- */
652
- text?: string[];
653
- /**
654
- * Specifies index of the selected element.
655
- * Available only in virtualization.
656
- */
657
- index?: number[];
658
- /**
659
- * Specifies the hierarchical parent id collection of the current view.
660
- * Available only in nested list with checkbox enabled.
661
- */
662
- parentId?: string[];
663
- }
664
- /**
665
- * An enum type that denotes the ListView scroll direction when it reaches the end.
666
- * ```props
667
- * Top:- The scrollbar is moved upwards.
668
- * Bottom:- The scrollbar is moved downwards.
669
- * ```
670
- */
671
- export declare type direction = 'Top' | 'Bottom';
672
- /**
673
- * An interface that holds selected item.
674
- */
675
- export interface SelectedItem {
676
- /**
677
- * It denotes the selected item text.
678
- */
679
- text: string;
680
- /**
681
- * It denotes the selected item list element.
682
- *
683
- */
684
- item: HTMLElement | Element;
685
- /**
686
- * It denotes the selected item dataSource JSON object.
687
- *
688
- * @isGenericType true
689
- */
690
- data: {
691
- [key: string]: Object;
692
- } | string[] | number[];
693
- }
694
- /**
695
- * An interface that holds selected collection.
696
- */
697
- export interface SelectedCollection {
698
- /**
699
- * It denotes the selected item text data or collection.
700
- */
701
- text: string | string[];
702
- /**
703
- * It denotes the selected item list element or element collection.
704
- */
705
- item: HTMLElement | Element[] | NodeList;
706
- /**
707
- * It denotes the selected item dataSource JSON object or object collection.
708
- *
709
- * @isGenericType true
710
- */
711
- data: {
712
- [key: string]: object;
713
- } | {
714
- [key: string]: object;
715
- }[] | string[] | number[];
716
- }
717
- /**
718
- * An interface that holds UI selected item.
719
- */
720
- export interface UISelectedItem {
721
- /**
722
- * It denotes the selected item text data or collection.
723
- */
724
- text: string | number | string[] | number[];
725
- /**
726
- * It denotes the selected item list element or element collection.
727
- */
728
- item?: HTMLElement | Element[] | NodeList;
729
- /**
730
- * It denotes the selected item dataSource JSON object or object collection.
731
- *
732
- * @isGenericType true
733
- */
734
- data: {
735
- [key: string]: object;
736
- } | {
737
- [key: string]: object;
738
- }[] | string | number | string[] | number[];
739
- /**
740
- * It is used to denote the index of the selected element.
741
- */
742
- index?: number | number[];
743
- /**
744
- * It is used to check whether the element is checked or not.
745
- */
746
- isChecked?: boolean;
747
- }
748
- /**
749
- * An interface that holds details of data and parent.
750
- */
751
- export interface DataAndParent {
752
- /**
753
- * It denotes the selected item dataSource JSON object or object collection.
754
- *
755
- * @isGenericType true
756
- */
757
- data: {
758
- [key: string]: object;
759
- } | {
760
- [key: string]: object;
761
- }[] | string[];
762
- /**
763
- * It denotes the selected item's parent id;
764
- */
765
- parentId: string[];
766
- }
767
- /**
768
- * An interface that holds nested list data.
769
- */
770
- export interface NestedListData {
771
- /**
772
- * It denotes the selected item text data or collection.
773
- */
774
- text: string | string[];
775
- /**
776
- * It denotes the selected item list element or element collection.
777
- */
778
- item: HTMLElement | Element[] | NodeList;
779
- /**
780
- * It denotes the selected item dataSource JSON object with it's parent id.
781
- */
782
- data: DataAndParent[];
783
- }
784
- /**
785
- * An interface that holds selected event arguments
786
- */
787
- export interface SelectEventArgs extends BaseEventArgs, SelectedItem {
788
- /**
789
- * Specifies that event has triggered by user interaction.
790
- */
791
- isInteracted: boolean;
792
- /**
793
- * Specifies that event argument when event raised by other event.
794
- */
795
- event: MouseEvent | KeyboardEvent;
796
- /**
797
- * It is used to denote the index of the selected element.
798
- */
799
- index: number;
800
- /**
801
- * It is used to check whether the element is checked or not.
802
- */
803
- isChecked?: boolean;
804
- /**
805
- * Cancels the item selection if the value is true
806
- */
807
- cancel: boolean;
808
- }
809
- /**
810
- * An interface that holds scrolled event arguments
811
- */
812
- export interface ScrolledEventArgs {
813
- /**
814
- * Specifies the direction “Top” or “Bottom” in which the scrolling occurs.
815
- */
816
- scrollDirection: direction;
817
- /**
818
- * Specifies the default scroll event arguments.
819
- */
820
- originalEvent: Event;
821
- /**
822
- * Specifies the distance from the scrollbar to the top and bottom ends.
823
- */
824
- distanceY: number;
825
- }
826
- /**
827
- * An interface that holds item created event arguments
828
- */
829
- export interface ItemCreatedArgs {
830
- curData: {
831
- [key: string]: object;
832
- };
833
- dataSource: {
834
- [key: string]: object;
835
- } | string[];
836
- fields: FieldsMapping;
837
- item: HTMLElement;
838
- options: ListBaseOptions;
839
- text: string;
840
- }
841
- interface DataSource {
842
- [key: string]: object;
843
- }
844
- export {};