@coreui/vue-pro 4.7.0 → 4.8.0-next.1

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 (55) hide show
  1. package/dist/components/calendar/utils.d.ts +23 -0
  2. package/dist/components/index.d.ts +1 -0
  3. package/dist/components/modal/CModal.d.ts +4 -20
  4. package/dist/components/multi-select/CMultiSelect.d.ts +35 -44
  5. package/dist/components/multi-select/CMultiSelectNativeSelect.d.ts +1 -1
  6. package/dist/components/multi-select/CMultiSelectOptions.d.ts +13 -11
  7. package/dist/components/multi-select/CMultiSelectSelection.d.ts +1 -1
  8. package/dist/components/multi-select/types.d.ts +14 -0
  9. package/dist/components/multi-select/utils.d.ts +6 -0
  10. package/dist/components/offcanvas/COffcanvas.d.ts +35 -18
  11. package/dist/components/smart-table/CSmartTable.d.ts +65 -87
  12. package/dist/components/smart-table/CSmartTableBody.d.ts +16 -40
  13. package/dist/components/smart-table/CSmartTableHead.d.ts +17 -58
  14. package/dist/components/smart-table/CSmartTableInterface.d.ts +1 -1
  15. package/dist/components/smart-table/types.d.ts +50 -0
  16. package/dist/components/smart-table/utils.d.ts +17 -0
  17. package/dist/components/table/CTable.d.ts +1 -1
  18. package/dist/components/time-picker/types.d.ts +15 -0
  19. package/dist/components/time-picker/utils.d.ts +23 -0
  20. package/dist/components/virtual-scroller/CVirtualScroller.d.ts +23 -0
  21. package/dist/components/virtual-scroller/index.d.ts +6 -0
  22. package/dist/index.es.js +943 -885
  23. package/dist/index.es.js.map +1 -1
  24. package/dist/index.js +943 -883
  25. package/dist/index.js.map +1 -1
  26. package/dist/utils/index.d.ts +1 -3
  27. package/dist/utils/isObjectInArray.d.ts +2 -0
  28. package/package.json +6 -6
  29. package/src/components/calendar/CCalendar.ts +1 -1
  30. package/src/{utils/calendar.ts → components/calendar/utils.ts} +1 -1
  31. package/src/components/date-range-picker/CDateRangePicker.ts +1 -1
  32. package/src/components/element-cover/CElementCover.ts +14 -14
  33. package/src/components/index.ts +1 -0
  34. package/src/components/modal/CModal.ts +10 -10
  35. package/src/components/multi-select/CMultiSelect.ts +33 -99
  36. package/src/components/multi-select/CMultiSelectNativeSelect.ts +2 -1
  37. package/src/components/multi-select/CMultiSelectOptions.ts +31 -17
  38. package/src/components/multi-select/CMultiSelectSelection.ts +2 -1
  39. package/src/components/multi-select/types.ts +15 -0
  40. package/src/components/multi-select/utils.ts +92 -0
  41. package/src/components/offcanvas/COffcanvas.ts +50 -28
  42. package/src/components/smart-table/CSmartTable.ts +365 -268
  43. package/src/components/smart-table/CSmartTableBody.ts +126 -137
  44. package/src/components/smart-table/CSmartTableHead.ts +53 -138
  45. package/src/components/smart-table/CSmartTableInterface.ts +1 -1
  46. package/src/components/smart-table/types.ts +61 -0
  47. package/src/components/smart-table/utils.ts +212 -0
  48. package/src/components/time-picker/CTimePicker.ts +49 -27
  49. package/src/components/time-picker/types.ts +15 -0
  50. package/src/{utils/time.ts → components/time-picker/utils.ts} +43 -2
  51. package/src/components/virtual-scroller/CVirtualScroller.ts +109 -0
  52. package/src/components/virtual-scroller/index.ts +10 -0
  53. package/src/utils/index.ts +1 -3
  54. package/src/utils/getNextSibling.ts +0 -18
  55. package/src/utils/getPreviousSibling.ts +0 -18
@@ -0,0 +1,23 @@
1
+ export declare const convertToLocalDate: (d: Date, locale: string, options?: {}) => string;
2
+ export declare const convertToLocalTime: (d: Date, locale: string, options?: {}) => string;
3
+ export declare const createGroupsInArray: <T>(arr: T[], numberOfGroups: number) => T[][];
4
+ export declare const getCurrentYear: () => number;
5
+ export declare const getCurrentMonth: () => number;
6
+ export declare const getLocalDateFromString: (string: string, locale: string, time?: boolean) => Date | undefined;
7
+ export declare const getMonthName: (month: number, locale: string) => string;
8
+ export declare const getMonthsNames: (locale: string) => string[];
9
+ export declare const getYears: (year: number) => number[];
10
+ export declare const getMonthDetails: (year: number, month: number, firstDayOfWeek: number) => {
11
+ date: Date;
12
+ month: string;
13
+ }[][];
14
+ export declare const isDisableDateInRange: (startDate?: Date | null, endDate?: Date | null, dates?: Date[] | Date[][] | (Date | Date[])[]) => boolean;
15
+ export declare const isDateDisabled: (date: Date, min?: Date | null, max?: Date | null, dates?: Date[] | Date[][] | (Date | Date[])[]) => boolean | undefined;
16
+ export declare const isDateInRange: (date: Date, start: Date | null, end: Date | null) => boolean | null;
17
+ export declare const isDateSelected: (date: Date, start: Date | null, end: Date | null) => boolean | null;
18
+ export declare const isEndDate: (date: Date, start: Date | null, end: Date | null) => boolean | null;
19
+ export declare const isLastDayOfMonth: (date: Date) => boolean;
20
+ export declare const isSameDateAs: (date: Date | null, date2: Date | null) => boolean;
21
+ export declare const isStartDate: (date: Date, start: Date | null, end: Date | null) => boolean | null;
22
+ export declare const isToday: (date: Date) => boolean;
23
+ export declare const isValidDate: (date: string) => number | false;
@@ -43,4 +43,5 @@ export * from './tabs';
43
43
  export * from './time-picker';
44
44
  export * from './toast';
45
45
  export * from './tooltip';
46
+ export * from './virtual-scroller';
46
47
  export * from './widgets';
@@ -7,18 +7,17 @@ declare const CModal: import("vue").DefineComponent<{
7
7
  */
8
8
  alignment: {
9
9
  default: string;
10
- required: false;
11
10
  validator: (value: string) => boolean;
12
11
  };
13
12
  /**
14
13
  * Apply a backdrop on body while offcanvas is open.
15
14
  *
16
- * @values 'static'
15
+ * @values boolean | 'static'
17
16
  */
18
17
  backdrop: {
19
18
  type: (StringConstructor | BooleanConstructor)[];
20
19
  default: boolean;
21
- require: boolean;
20
+ validator: (value: boolean | string) => boolean;
22
21
  };
23
22
  /**
24
23
  * A string of all className you want applied to the modal content component.
@@ -26,7 +25,6 @@ declare const CModal: import("vue").DefineComponent<{
26
25
  contentClassName: {
27
26
  type: StringConstructor;
28
27
  default: undefined;
29
- required: false;
30
28
  };
31
29
  /**
32
30
  * Set modal to covers the entire user viewport
@@ -36,7 +34,6 @@ declare const CModal: import("vue").DefineComponent<{
36
34
  fullscreen: {
37
35
  type: (StringConstructor | BooleanConstructor)[];
38
36
  default: undefined;
39
- required: false;
40
37
  validator: (value: boolean | string) => boolean;
41
38
  };
42
39
  /**
@@ -45,14 +42,12 @@ declare const CModal: import("vue").DefineComponent<{
45
42
  keyboard: {
46
43
  type: BooleanConstructor;
47
44
  default: boolean;
48
- required: false;
49
45
  };
50
46
  /**
51
47
  * Create a scrollable modal that allows scrolling the modal body.
52
48
  */
53
49
  scrollable: {
54
50
  type: BooleanConstructor;
55
- required: false;
56
51
  };
57
52
  /**
58
53
  * Size the component small, large, or extra large.
@@ -62,7 +57,6 @@ declare const CModal: import("vue").DefineComponent<{
62
57
  size: {
63
58
  type: StringConstructor;
64
59
  default: undefined;
65
- required: false;
66
60
  validator: (value: string) => boolean;
67
61
  };
68
62
  /**
@@ -71,7 +65,6 @@ declare const CModal: import("vue").DefineComponent<{
71
65
  transition: {
72
66
  type: BooleanConstructor;
73
67
  default: boolean;
74
- required: false;
75
68
  };
76
69
  /**
77
70
  * By default the component is unmounted after close animation, if you want to keep the component mounted set this property to false.
@@ -79,7 +72,6 @@ declare const CModal: import("vue").DefineComponent<{
79
72
  unmountOnClose: {
80
73
  type: BooleanConstructor;
81
74
  default: boolean;
82
- required: false;
83
75
  };
84
76
  /**
85
77
  * Toggle the visibility of alert component.
@@ -95,18 +87,17 @@ declare const CModal: import("vue").DefineComponent<{
95
87
  */
96
88
  alignment: {
97
89
  default: string;
98
- required: false;
99
90
  validator: (value: string) => boolean;
100
91
  };
101
92
  /**
102
93
  * Apply a backdrop on body while offcanvas is open.
103
94
  *
104
- * @values 'static'
95
+ * @values boolean | 'static'
105
96
  */
106
97
  backdrop: {
107
98
  type: (StringConstructor | BooleanConstructor)[];
108
99
  default: boolean;
109
- require: boolean;
100
+ validator: (value: boolean | string) => boolean;
110
101
  };
111
102
  /**
112
103
  * A string of all className you want applied to the modal content component.
@@ -114,7 +105,6 @@ declare const CModal: import("vue").DefineComponent<{
114
105
  contentClassName: {
115
106
  type: StringConstructor;
116
107
  default: undefined;
117
- required: false;
118
108
  };
119
109
  /**
120
110
  * Set modal to covers the entire user viewport
@@ -124,7 +114,6 @@ declare const CModal: import("vue").DefineComponent<{
124
114
  fullscreen: {
125
115
  type: (StringConstructor | BooleanConstructor)[];
126
116
  default: undefined;
127
- required: false;
128
117
  validator: (value: boolean | string) => boolean;
129
118
  };
130
119
  /**
@@ -133,14 +122,12 @@ declare const CModal: import("vue").DefineComponent<{
133
122
  keyboard: {
134
123
  type: BooleanConstructor;
135
124
  default: boolean;
136
- required: false;
137
125
  };
138
126
  /**
139
127
  * Create a scrollable modal that allows scrolling the modal body.
140
128
  */
141
129
  scrollable: {
142
130
  type: BooleanConstructor;
143
- required: false;
144
131
  };
145
132
  /**
146
133
  * Size the component small, large, or extra large.
@@ -150,7 +137,6 @@ declare const CModal: import("vue").DefineComponent<{
150
137
  size: {
151
138
  type: StringConstructor;
152
139
  default: undefined;
153
- required: false;
154
140
  validator: (value: string) => boolean;
155
141
  };
156
142
  /**
@@ -159,7 +145,6 @@ declare const CModal: import("vue").DefineComponent<{
159
145
  transition: {
160
146
  type: BooleanConstructor;
161
147
  default: boolean;
162
- required: false;
163
148
  };
164
149
  /**
165
150
  * By default the component is unmounted after close animation, if you want to keep the component mounted set this property to false.
@@ -167,7 +152,6 @@ declare const CModal: import("vue").DefineComponent<{
167
152
  unmountOnClose: {
168
153
  type: BooleanConstructor;
169
154
  default: boolean;
170
- required: false;
171
155
  };
172
156
  /**
173
157
  * Toggle the visibility of alert component.
@@ -1,18 +1,5 @@
1
1
  import { PropType } from 'vue';
2
- export interface Option {
3
- disabled?: boolean;
4
- label?: string;
5
- options?: Option[];
6
- order?: number;
7
- selected?: boolean;
8
- text: string;
9
- value: number | string;
10
- }
11
- export interface SelectedOption {
12
- disabled?: boolean;
13
- text: string;
14
- value: number | string;
15
- }
2
+ import type { Option } from './types';
16
3
  declare const CMultiSelect: import("vue").DefineComponent<{
17
4
  /**
18
5
  * Enables selection cleaner element.
@@ -21,7 +8,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
21
8
  */
22
9
  cleaner: {
23
10
  type: BooleanConstructor;
24
- required: false;
25
11
  default: boolean;
26
12
  };
27
13
  /**
@@ -29,7 +15,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
29
15
  */
30
16
  disabled: {
31
17
  type: BooleanConstructor;
32
- required: false;
33
18
  default: boolean;
34
19
  };
35
20
  /**
@@ -84,7 +69,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
84
69
  multiple: {
85
70
  type: BooleanConstructor;
86
71
  default: boolean;
87
- required: false;
88
72
  };
89
73
  /**
90
74
  * List of option elements.
@@ -92,7 +76,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
92
76
  options: {
93
77
  type: PropType<Option[]>;
94
78
  default: () => never[];
95
- required: false;
96
79
  };
97
80
  /**
98
81
  * Sets maxHeight of options list.
@@ -102,7 +85,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
102
85
  optionsMaxHeight: {
103
86
  type: (NumberConstructor | StringConstructor)[];
104
87
  default: string;
105
- required: false;
106
88
  };
107
89
  /**
108
90
  * Sets option style.
@@ -113,7 +95,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
113
95
  optionsStyle: {
114
96
  type: StringConstructor;
115
97
  default: string;
116
- required: false;
117
98
  validator: (value: string) => boolean;
118
99
  };
119
100
  /**
@@ -124,7 +105,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
124
105
  placeholder: {
125
106
  type: StringConstructor;
126
107
  default: string;
127
- required: false;
128
108
  };
129
109
  /**
130
110
  * Enables search input element.
@@ -132,7 +112,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
132
112
  search: {
133
113
  type: (StringConstructor | BooleanConstructor)[];
134
114
  default: boolean;
135
- required: false;
136
115
  validator: (value: boolean | string) => boolean;
137
116
  };
138
117
  /**
@@ -141,7 +120,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
141
120
  searchNoResultsLabel: {
142
121
  type: StringConstructor;
143
122
  default: string;
144
- required: false;
145
123
  };
146
124
  /**
147
125
  * Enables select all button.
@@ -150,7 +128,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
150
128
  */
151
129
  selectAll: {
152
130
  type: BooleanConstructor;
153
- required: false;
154
131
  default: boolean;
155
132
  };
156
133
  /**
@@ -160,7 +137,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
160
137
  */
161
138
  selectAllLabel: {
162
139
  type: StringConstructor;
163
- required: false;
164
140
  default: string;
165
141
  };
166
142
  /**
@@ -172,7 +148,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
172
148
  selectionType: {
173
149
  type: StringConstructor;
174
150
  default: string;
175
- required: false;
176
151
  validator: (value: string) => boolean;
177
152
  };
178
153
  /**
@@ -183,7 +158,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
183
158
  selectionTypeCounterText: {
184
159
  type: StringConstructor;
185
160
  default: string;
186
- required: false;
187
161
  };
188
162
  /**
189
163
  * Size the component small or large.
@@ -192,7 +166,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
192
166
  */
193
167
  size: {
194
168
  type: StringConstructor;
195
- required: false;
196
169
  validator: (value: string) => boolean;
197
170
  };
198
171
  /**
@@ -215,6 +188,12 @@ declare const CMultiSelect: import("vue").DefineComponent<{
215
188
  * @since 4.6.0
216
189
  */
217
190
  valid: BooleanConstructor;
191
+ /**
192
+ * Enable virtual scroller for the options list.
193
+ *
194
+ * @since 4.8.0
195
+ */
196
+ virtualScroller: BooleanConstructor;
218
197
  /**
219
198
  * Toggle the visibility of multi select dropdown.
220
199
  *
@@ -223,7 +202,16 @@ declare const CMultiSelect: import("vue").DefineComponent<{
223
202
  visible: {
224
203
  type: BooleanConstructor;
225
204
  default: boolean;
226
- required: false;
205
+ };
206
+ /**
207
+ *
208
+ * Amount of visible items when virtualScroller is set to `true`.
209
+ *
210
+ * @since 4.8.0
211
+ */
212
+ visibleItems: {
213
+ type: NumberConstructor;
214
+ default: number;
227
215
  };
228
216
  }, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
229
217
  [key: string]: any;
@@ -235,7 +223,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
235
223
  */
236
224
  cleaner: {
237
225
  type: BooleanConstructor;
238
- required: false;
239
226
  default: boolean;
240
227
  };
241
228
  /**
@@ -243,7 +230,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
243
230
  */
244
231
  disabled: {
245
232
  type: BooleanConstructor;
246
- required: false;
247
233
  default: boolean;
248
234
  };
249
235
  /**
@@ -298,7 +284,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
298
284
  multiple: {
299
285
  type: BooleanConstructor;
300
286
  default: boolean;
301
- required: false;
302
287
  };
303
288
  /**
304
289
  * List of option elements.
@@ -306,7 +291,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
306
291
  options: {
307
292
  type: PropType<Option[]>;
308
293
  default: () => never[];
309
- required: false;
310
294
  };
311
295
  /**
312
296
  * Sets maxHeight of options list.
@@ -316,7 +300,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
316
300
  optionsMaxHeight: {
317
301
  type: (NumberConstructor | StringConstructor)[];
318
302
  default: string;
319
- required: false;
320
303
  };
321
304
  /**
322
305
  * Sets option style.
@@ -327,7 +310,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
327
310
  optionsStyle: {
328
311
  type: StringConstructor;
329
312
  default: string;
330
- required: false;
331
313
  validator: (value: string) => boolean;
332
314
  };
333
315
  /**
@@ -338,7 +320,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
338
320
  placeholder: {
339
321
  type: StringConstructor;
340
322
  default: string;
341
- required: false;
342
323
  };
343
324
  /**
344
325
  * Enables search input element.
@@ -346,7 +327,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
346
327
  search: {
347
328
  type: (StringConstructor | BooleanConstructor)[];
348
329
  default: boolean;
349
- required: false;
350
330
  validator: (value: boolean | string) => boolean;
351
331
  };
352
332
  /**
@@ -355,7 +335,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
355
335
  searchNoResultsLabel: {
356
336
  type: StringConstructor;
357
337
  default: string;
358
- required: false;
359
338
  };
360
339
  /**
361
340
  * Enables select all button.
@@ -364,7 +343,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
364
343
  */
365
344
  selectAll: {
366
345
  type: BooleanConstructor;
367
- required: false;
368
346
  default: boolean;
369
347
  };
370
348
  /**
@@ -374,7 +352,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
374
352
  */
375
353
  selectAllLabel: {
376
354
  type: StringConstructor;
377
- required: false;
378
355
  default: string;
379
356
  };
380
357
  /**
@@ -386,7 +363,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
386
363
  selectionType: {
387
364
  type: StringConstructor;
388
365
  default: string;
389
- required: false;
390
366
  validator: (value: string) => boolean;
391
367
  };
392
368
  /**
@@ -397,7 +373,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
397
373
  selectionTypeCounterText: {
398
374
  type: StringConstructor;
399
375
  default: string;
400
- required: false;
401
376
  };
402
377
  /**
403
378
  * Size the component small or large.
@@ -406,7 +381,6 @@ declare const CMultiSelect: import("vue").DefineComponent<{
406
381
  */
407
382
  size: {
408
383
  type: StringConstructor;
409
- required: false;
410
384
  validator: (value: string) => boolean;
411
385
  };
412
386
  /**
@@ -429,6 +403,12 @@ declare const CMultiSelect: import("vue").DefineComponent<{
429
403
  * @since 4.6.0
430
404
  */
431
405
  valid: BooleanConstructor;
406
+ /**
407
+ * Enable virtual scroller for the options list.
408
+ *
409
+ * @since 4.8.0
410
+ */
411
+ virtualScroller: BooleanConstructor;
432
412
  /**
433
413
  * Toggle the visibility of multi select dropdown.
434
414
  *
@@ -437,7 +417,16 @@ declare const CMultiSelect: import("vue").DefineComponent<{
437
417
  visible: {
438
418
  type: BooleanConstructor;
439
419
  default: boolean;
440
- required: false;
420
+ };
421
+ /**
422
+ *
423
+ * Amount of visible items when virtualScroller is set to `true`.
424
+ *
425
+ * @since 4.8.0
426
+ */
427
+ visibleItems: {
428
+ type: NumberConstructor;
429
+ default: number;
441
430
  };
442
431
  }>> & {
443
432
  onChange?: ((...args: any[]) => any) | undefined;
@@ -453,9 +442,11 @@ declare const CMultiSelect: import("vue").DefineComponent<{
453
442
  options: Option[];
454
443
  cleaner: boolean;
455
444
  placeholder: string;
445
+ visibleItems: number;
456
446
  optionsMaxHeight: string | number;
457
447
  optionsStyle: string;
458
448
  searchNoResultsLabel: string;
449
+ virtualScroller: boolean;
459
450
  selectionType: string;
460
451
  selectionTypeCounterText: string;
461
452
  selectAll: boolean;
@@ -1,5 +1,5 @@
1
1
  import { PropType, VNode } from 'vue';
2
- import { Option } from './CMultiSelect';
2
+ import type { Option } from './types';
3
3
  declare const CMultiSelectNativeSelect: import("vue").DefineComponent<{
4
4
  /**
5
5
  * It specifies that multiple options can be selected at once.
@@ -1,5 +1,5 @@
1
1
  import { PropType, VNode } from 'vue';
2
- import { Option } from './CMultiSelect';
2
+ import type { Option } from './types';
3
3
  declare const CMultiSelectOptions: import("vue").DefineComponent<{
4
4
  /**
5
5
  * List of option elements.
@@ -7,7 +7,6 @@ declare const CMultiSelectOptions: import("vue").DefineComponent<{
7
7
  options: {
8
8
  type: PropType<Option[]>;
9
9
  default: () => never[];
10
- required: false;
11
10
  };
12
11
  /**
13
12
  * Sets maxHeight of options list.
@@ -17,7 +16,6 @@ declare const CMultiSelectOptions: import("vue").DefineComponent<{
17
16
  optionsMaxHeight: {
18
17
  type: (NumberConstructor | StringConstructor)[];
19
18
  default: string;
20
- required: false;
21
19
  };
22
20
  /**
23
21
  * Sets option style.
@@ -28,7 +26,6 @@ declare const CMultiSelectOptions: import("vue").DefineComponent<{
28
26
  optionsStyle: {
29
27
  type: StringConstructor;
30
28
  default: string;
31
- required: false;
32
29
  validator: (value: string) => boolean;
33
30
  };
34
31
  /**
@@ -37,12 +34,15 @@ declare const CMultiSelectOptions: import("vue").DefineComponent<{
37
34
  searchNoResultsLabel: {
38
35
  type: StringConstructor;
39
36
  default: string;
40
- required: false;
41
37
  };
42
38
  selected: {
43
39
  type: PropType<Option[]>;
44
40
  default: () => never[];
45
- required: false;
41
+ };
42
+ virtualScroller: BooleanConstructor;
43
+ visibleItems: {
44
+ type: NumberConstructor;
45
+ default: number;
46
46
  };
47
47
  }, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
48
48
  [key: string]: any;
@@ -53,7 +53,6 @@ declare const CMultiSelectOptions: import("vue").DefineComponent<{
53
53
  options: {
54
54
  type: PropType<Option[]>;
55
55
  default: () => never[];
56
- required: false;
57
56
  };
58
57
  /**
59
58
  * Sets maxHeight of options list.
@@ -63,7 +62,6 @@ declare const CMultiSelectOptions: import("vue").DefineComponent<{
63
62
  optionsMaxHeight: {
64
63
  type: (NumberConstructor | StringConstructor)[];
65
64
  default: string;
66
- required: false;
67
65
  };
68
66
  /**
69
67
  * Sets option style.
@@ -74,7 +72,6 @@ declare const CMultiSelectOptions: import("vue").DefineComponent<{
74
72
  optionsStyle: {
75
73
  type: StringConstructor;
76
74
  default: string;
77
- required: false;
78
75
  validator: (value: string) => boolean;
79
76
  };
80
77
  /**
@@ -83,20 +80,25 @@ declare const CMultiSelectOptions: import("vue").DefineComponent<{
83
80
  searchNoResultsLabel: {
84
81
  type: StringConstructor;
85
82
  default: string;
86
- required: false;
87
83
  };
88
84
  selected: {
89
85
  type: PropType<Option[]>;
90
86
  default: () => never[];
91
- required: false;
87
+ };
88
+ virtualScroller: BooleanConstructor;
89
+ visibleItems: {
90
+ type: NumberConstructor;
91
+ default: number;
92
92
  };
93
93
  }>> & {
94
94
  onOptionClick?: ((...args: any[]) => any) | undefined;
95
95
  }, {
96
96
  options: Option[];
97
97
  selected: Option[];
98
+ visibleItems: number;
98
99
  optionsMaxHeight: string | number;
99
100
  optionsStyle: string;
100
101
  searchNoResultsLabel: string;
102
+ virtualScroller: boolean;
101
103
  }>;
102
104
  export { CMultiSelectOptions };
@@ -1,5 +1,5 @@
1
1
  import { PropType } from 'vue';
2
- import { Option } from './CMultiSelect';
2
+ import type { Option } from './types';
3
3
  declare const CMultiSelectSelection: import("vue").DefineComponent<{
4
4
  /**
5
5
  * It specifies that multiple options can be selected at once.
@@ -0,0 +1,14 @@
1
+ export type Option = {
2
+ disabled?: boolean;
3
+ label?: string;
4
+ options?: Option[];
5
+ order?: number;
6
+ selected?: boolean;
7
+ text: string;
8
+ value: number | string;
9
+ };
10
+ export type SelectedOption = {
11
+ disabled?: boolean;
12
+ text: string;
13
+ value: number | string;
14
+ };
@@ -0,0 +1,6 @@
1
+ import type { Option, SelectedOption } from './types';
2
+ export declare const filterOptionsList: (search: string, _options: Option[]) => Option[];
3
+ export declare const flattenArray: (options: Option[]) => Option[];
4
+ export declare const getNextSibling: (elem: HTMLElement, selector?: string) => Element | null | undefined;
5
+ export declare const getPreviousSibling: (elem: HTMLElement, selector?: string) => Element | null | undefined;
6
+ export declare const selectOptions: (options: Option[], selected: SelectedOption[], deselected?: Option[]) => SelectedOption[];