@volverjs/ui-vue 0.0.10-beta.42 → 0.0.10-beta.44
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/VvAccordionGroup/VvAccordionGroup.vue.d.ts +12 -12
- package/dist/components/VvAccordionGroup/index.d.ts +4 -4
- package/dist/components/VvAction/VvAction.vue.d.ts +2 -2
- package/dist/components/VvAction/index.d.ts +1 -1
- package/dist/components/VvAlert/VvAlert.vue.d.ts +6 -6
- package/dist/components/VvAlert/index.d.ts +4 -3
- package/dist/components/VvAlertGroup/VvAlertGroup.vue.d.ts +9 -9
- package/dist/components/VvAlertGroup/index.d.ts +4 -4
- package/dist/components/VvAvatarGroup/VvAvatarGroup.vue.d.ts +4 -4
- package/dist/components/VvAvatarGroup/index.d.ts +2 -2
- package/dist/components/VvBreadcrumb/VvBreadcrumb.vue.d.ts +13 -13
- package/dist/components/VvBreadcrumb/index.d.ts +1 -1
- package/dist/components/VvButton/VvButton.vue.d.ts +4 -4
- package/dist/components/VvButton/index.d.ts +2 -2
- package/dist/components/VvButtonGroup/VvButtonGroup.vue.d.ts +4 -4
- package/dist/components/VvButtonGroup/index.d.ts +2 -2
- package/dist/components/VvCheckbox/VvCheckbox.vue.d.ts +1 -1
- package/dist/components/VvCheckboxGroup/VvCheckboxGroup.vue.d.ts +3 -3
- package/dist/components/VvCheckboxGroup/index.d.ts +1 -1
- package/dist/components/VvCombobox/VvCombobox.vue.d.ts +438 -559
- package/dist/components/VvCombobox/index.d.ts +21 -241
- package/dist/components/VvDialog/VvDialog.es.js +41 -165
- package/dist/components/VvDialog/VvDialog.umd.js +1 -1
- package/dist/components/VvDialog/VvDialog.vue.d.ts +9 -0
- package/dist/components/VvDialog/index.d.ts +7 -0
- package/dist/components/VvDropdown/VvDropdown.vue.d.ts +33 -268
- package/dist/components/VvDropdown/VvDropdownAction.vue.d.ts +8 -6
- package/dist/components/VvDropdown/index.d.ts +9 -117
- package/dist/components/VvIcon/VvIcon.vue.d.ts +1 -1
- package/dist/components/VvInputFile/VvInputFile.es.js +11 -6
- package/dist/components/VvInputFile/VvInputFile.umd.js +1 -1
- package/dist/components/VvInputFile/VvInputFile.vue.d.ts +31 -105
- package/dist/components/VvInputFile/index.d.ts +11 -28
- package/dist/components/VvInputText/VvInputClearAction.d.ts +2 -2
- package/dist/components/VvInputText/VvInputPasswordAction.d.ts +4 -4
- package/dist/components/VvInputText/VvInputText.vue.d.ts +4 -4
- package/dist/components/VvInputText/index.d.ts +4 -9
- package/dist/components/VvNav/VvNav.vue.d.ts +9 -9
- package/dist/components/VvRadioGroup/VvRadioGroup.vue.d.ts +3 -3
- package/dist/components/VvRadioGroup/index.d.ts +1 -1
- package/dist/components/VvSelect/VvSelect.vue.d.ts +174 -184
- package/dist/components/VvSelect/index.d.ts +4 -4
- package/dist/components/VvTab/VvTab.vue.d.ts +13 -13
- package/dist/components/VvTab/index.d.ts +2 -2
- package/dist/components/VvTextarea/VvTextarea.vue.d.ts +2 -2
- package/dist/components/VvTextarea/index.d.ts +1 -1
- package/dist/components/VvTooltip/VvTooltip.vue.d.ts +2 -2
- package/dist/components/VvTooltip/index.d.ts +1 -1
- package/dist/components/index.es.js +34 -31
- package/dist/components/index.umd.js +1 -1
- package/dist/composables/alert/useAlert.d.ts +47 -77
- package/dist/composables/index.es.js +1 -2
- package/dist/composables/useBlurhash.d.ts +1 -1
- package/dist/composables/useOptions.d.ts +3 -3
- package/dist/icons.es.js +3 -3
- package/dist/icons.umd.js +1 -1
- package/dist/index.es.js +1 -4
- package/dist/index.umd.js +1 -1
- package/dist/props/index.d.ts +14 -121
- package/dist/stories/AccordionGroup/AccordionGroupSlots.stories.d.ts +283 -347
- package/dist/stories/InputFile/InputFile.stories.d.ts +1 -0
- package/dist/test/expect.d.ts +0 -1
- package/dist/types/input-file.d.ts +2 -9
- package/dist/utils/ObjectUtilities.d.ts +1 -1
- package/package.json +29 -30
- package/src/Volver.ts +6 -6
- package/src/assets/icons/detailed.json +1 -1
- package/src/assets/icons/normal.json +1 -1
- package/src/assets/icons/simple.json +1 -1
- package/src/components/VvButtonGroup/index.ts +1 -1
- package/src/components/VvCombobox/index.ts +6 -6
- package/src/components/VvDialog/VvDialog.vue +3 -5
- package/src/components/VvDialog/index.ts +4 -0
- package/src/components/VvInputFile/VvInputFile.vue +8 -3
- package/src/components/VvInputFile/index.ts +2 -0
- package/src/components/VvInputText/VvInputText.vue +18 -18
- package/src/components/common/HintSlot.ts +2 -2
- package/src/composables/group/useInjectedGroupState.ts +3 -3
- package/src/composables/group/useProvideGroupState.ts +3 -3
- package/src/composables/useDefaults.ts +4 -4
- package/src/props/index.ts +1 -1
- package/src/stories/InputFile/InputFile.stories.ts +8 -0
- package/src/types/group.ts +1 -1
- package/src/types/input-file.ts +10 -18
|
@@ -189,143 +189,35 @@ export declare const VvComboboxProps: {
|
|
|
189
189
|
default: undefined;
|
|
190
190
|
};
|
|
191
191
|
placement: {
|
|
192
|
-
type: PropType
|
|
192
|
+
type: PropType<`${import("../../constants").Side}` | `${import("../../constants").Placement}`>;
|
|
193
193
|
default: import("../../constants").Side;
|
|
194
|
-
validator: (value:
|
|
194
|
+
validator: (value: import("../../constants").Side & import("../../constants").Placement) => boolean;
|
|
195
195
|
};
|
|
196
196
|
strategy: {
|
|
197
|
-
type: PropType
|
|
197
|
+
type: PropType<`${import("../../constants").Strategy}`>;
|
|
198
198
|
default: undefined;
|
|
199
199
|
validator: (value: import("../../constants").Strategy) => boolean;
|
|
200
200
|
};
|
|
201
201
|
offset: {
|
|
202
|
-
type: PropType<
|
|
202
|
+
type: PropType<import("../..").OffsetOptions | number | string>;
|
|
203
203
|
default: number;
|
|
204
204
|
};
|
|
205
205
|
shift: {
|
|
206
|
-
type: PropType<
|
|
207
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
208
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
209
|
-
altBoundary?: boolean | undefined;
|
|
210
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
211
|
-
crossAxis?: boolean | undefined;
|
|
212
|
-
mainAxis?: boolean | undefined;
|
|
213
|
-
limiter?: {
|
|
214
|
-
fn: (state: import("@floating-ui/core").MiddlewareState) => import("@floating-ui/utils").Coords;
|
|
215
|
-
options?: any;
|
|
216
|
-
} | undefined;
|
|
217
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
218
|
-
} | import("@floating-ui/core").Derivable<{
|
|
219
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
220
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
221
|
-
altBoundary?: boolean | undefined;
|
|
222
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
223
|
-
crossAxis?: boolean | undefined;
|
|
224
|
-
mainAxis?: boolean | undefined;
|
|
225
|
-
limiter?: {
|
|
226
|
-
fn: (state: import("@floating-ui/core").MiddlewareState) => import("@floating-ui/utils").Coords;
|
|
227
|
-
options?: any;
|
|
228
|
-
} | undefined;
|
|
229
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
230
|
-
}> | undefined>;
|
|
206
|
+
type: PropType<import("../..").ShiftOptions | boolean>;
|
|
231
207
|
default: boolean;
|
|
232
208
|
};
|
|
233
209
|
flip: {
|
|
234
|
-
type: PropType<
|
|
235
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
236
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
237
|
-
altBoundary?: boolean | undefined;
|
|
238
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
239
|
-
crossAxis?: boolean | undefined;
|
|
240
|
-
mainAxis?: boolean | undefined;
|
|
241
|
-
fallbackPlacements?: import("@floating-ui/utils").Placement[] | undefined;
|
|
242
|
-
fallbackStrategy?: "bestFit" | "initialPlacement" | undefined;
|
|
243
|
-
fallbackAxisSideDirection?: "start" | "end" | "none" | undefined;
|
|
244
|
-
flipAlignment?: boolean | undefined;
|
|
245
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
246
|
-
} | import("@floating-ui/core").Derivable<{
|
|
247
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
248
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
249
|
-
altBoundary?: boolean | undefined;
|
|
250
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
251
|
-
crossAxis?: boolean | undefined;
|
|
252
|
-
mainAxis?: boolean | undefined;
|
|
253
|
-
fallbackPlacements?: import("@floating-ui/utils").Placement[] | undefined;
|
|
254
|
-
fallbackStrategy?: "bestFit" | "initialPlacement" | undefined;
|
|
255
|
-
fallbackAxisSideDirection?: "start" | "end" | "none" | undefined;
|
|
256
|
-
flipAlignment?: boolean | undefined;
|
|
257
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
258
|
-
}> | undefined>;
|
|
210
|
+
type: PropType<import("../..").FlipOptions | boolean>;
|
|
259
211
|
default: boolean;
|
|
260
212
|
};
|
|
261
213
|
size: {
|
|
262
|
-
type: PropType<
|
|
263
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
264
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
265
|
-
altBoundary?: boolean | undefined;
|
|
266
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
267
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
268
|
-
apply?: ((args: {
|
|
269
|
-
x: number;
|
|
270
|
-
y: number;
|
|
271
|
-
initialPlacement: import("@floating-ui/utils").Placement;
|
|
272
|
-
placement: import("@floating-ui/utils").Placement;
|
|
273
|
-
strategy: import("@floating-ui/utils").Strategy;
|
|
274
|
-
middlewareData: import("@floating-ui/core").MiddlewareData;
|
|
275
|
-
rects: import("@floating-ui/utils").ElementRects;
|
|
276
|
-
platform: import("@floating-ui/core").Platform;
|
|
277
|
-
elements: import("@floating-ui/dom").Elements;
|
|
278
|
-
} & {
|
|
279
|
-
availableWidth: number;
|
|
280
|
-
availableHeight: number;
|
|
281
|
-
}) => void | Promise<void>) | undefined;
|
|
282
|
-
} | import("@floating-ui/core").Derivable<{
|
|
283
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
284
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
285
|
-
altBoundary?: boolean | undefined;
|
|
286
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
287
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
288
|
-
apply?: ((args: {
|
|
289
|
-
x: number;
|
|
290
|
-
y: number;
|
|
291
|
-
initialPlacement: import("@floating-ui/utils").Placement;
|
|
292
|
-
placement: import("@floating-ui/utils").Placement;
|
|
293
|
-
strategy: import("@floating-ui/utils").Strategy;
|
|
294
|
-
middlewareData: import("@floating-ui/core").MiddlewareData;
|
|
295
|
-
rects: import("@floating-ui/utils").ElementRects;
|
|
296
|
-
platform: import("@floating-ui/core").Platform;
|
|
297
|
-
elements: import("@floating-ui/dom").Elements;
|
|
298
|
-
} & {
|
|
299
|
-
availableWidth: number;
|
|
300
|
-
availableHeight: number;
|
|
301
|
-
}) => void | Promise<void>) | undefined;
|
|
302
|
-
}> | undefined>;
|
|
214
|
+
type: PropType<import("../..").SizeOptions | boolean>;
|
|
303
215
|
default: () => {
|
|
304
216
|
padding: number;
|
|
305
217
|
};
|
|
306
218
|
};
|
|
307
219
|
autoPlacement: {
|
|
308
|
-
type: PropType<
|
|
309
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
310
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
311
|
-
altBoundary?: boolean | undefined;
|
|
312
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
313
|
-
crossAxis?: boolean | undefined;
|
|
314
|
-
alignment?: import("@floating-ui/utils").Alignment | null | undefined;
|
|
315
|
-
autoAlignment?: boolean | undefined;
|
|
316
|
-
allowedPlacements?: import("@floating-ui/utils").Placement[] | undefined;
|
|
317
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
318
|
-
} | import("@floating-ui/core").Derivable<{
|
|
319
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
320
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
321
|
-
altBoundary?: boolean | undefined;
|
|
322
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
323
|
-
crossAxis?: boolean | undefined;
|
|
324
|
-
alignment?: import("@floating-ui/utils").Alignment | null | undefined;
|
|
325
|
-
autoAlignment?: boolean | undefined;
|
|
326
|
-
allowedPlacements?: import("@floating-ui/utils").Placement[] | undefined;
|
|
327
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
328
|
-
}> | undefined>;
|
|
220
|
+
type: PropType<import("../..").AutoPlacementOptions | boolean>;
|
|
329
221
|
default: boolean;
|
|
330
222
|
};
|
|
331
223
|
arrow: {
|
|
@@ -345,12 +237,12 @@ export declare const VvComboboxProps: {
|
|
|
345
237
|
default: undefined;
|
|
346
238
|
};
|
|
347
239
|
iconPosition: {
|
|
348
|
-
type: PropType
|
|
240
|
+
type: PropType<`${import("../../constants").Position}`>;
|
|
349
241
|
default: import("../../constants").Position;
|
|
350
242
|
validation: (value: import("../../constants").Position) => boolean;
|
|
351
243
|
};
|
|
352
244
|
options: {
|
|
353
|
-
type: PropType<(
|
|
245
|
+
type: PropType<(Option | string)[]>;
|
|
354
246
|
default: () => never[];
|
|
355
247
|
};
|
|
356
248
|
labelKey: {
|
|
@@ -392,9 +284,7 @@ export declare const VvComboboxProps: {
|
|
|
392
284
|
invalid: {
|
|
393
285
|
type: BooleanConstructor;
|
|
394
286
|
default: boolean;
|
|
395
|
-
};
|
|
396
|
-
* Label for no search results
|
|
397
|
-
*/
|
|
287
|
+
};
|
|
398
288
|
invalidLabel: {
|
|
399
289
|
type: (ArrayConstructor | StringConstructor)[];
|
|
400
290
|
default: undefined;
|
|
@@ -596,143 +486,35 @@ export declare function useVvComboboxProps<T extends Option | string>(): {
|
|
|
596
486
|
default: undefined;
|
|
597
487
|
};
|
|
598
488
|
placement: {
|
|
599
|
-
type: PropType
|
|
489
|
+
type: PropType<`${import("../../constants").Side}` | `${import("../../constants").Placement}`>;
|
|
600
490
|
default: import("../../constants").Side;
|
|
601
|
-
validator: (value:
|
|
491
|
+
validator: (value: import("../../constants").Side & import("../../constants").Placement) => boolean;
|
|
602
492
|
};
|
|
603
493
|
strategy: {
|
|
604
|
-
type: PropType
|
|
494
|
+
type: PropType<`${import("../../constants").Strategy}`>;
|
|
605
495
|
default: undefined;
|
|
606
496
|
validator: (value: import("../../constants").Strategy) => boolean;
|
|
607
497
|
};
|
|
608
498
|
offset: {
|
|
609
|
-
type: PropType<
|
|
499
|
+
type: PropType<import("../..").OffsetOptions | number | string>;
|
|
610
500
|
default: number;
|
|
611
501
|
};
|
|
612
502
|
shift: {
|
|
613
|
-
type: PropType<
|
|
614
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
615
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
616
|
-
altBoundary?: boolean | undefined;
|
|
617
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
618
|
-
crossAxis?: boolean | undefined;
|
|
619
|
-
mainAxis?: boolean | undefined;
|
|
620
|
-
limiter?: {
|
|
621
|
-
fn: (state: import("@floating-ui/core").MiddlewareState) => import("@floating-ui/utils").Coords;
|
|
622
|
-
options?: any;
|
|
623
|
-
} | undefined;
|
|
624
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
625
|
-
} | import("@floating-ui/core").Derivable<{
|
|
626
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
627
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
628
|
-
altBoundary?: boolean | undefined;
|
|
629
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
630
|
-
crossAxis?: boolean | undefined;
|
|
631
|
-
mainAxis?: boolean | undefined;
|
|
632
|
-
limiter?: {
|
|
633
|
-
fn: (state: import("@floating-ui/core").MiddlewareState) => import("@floating-ui/utils").Coords;
|
|
634
|
-
options?: any;
|
|
635
|
-
} | undefined;
|
|
636
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
637
|
-
}> | undefined>;
|
|
503
|
+
type: PropType<import("../..").ShiftOptions | boolean>;
|
|
638
504
|
default: boolean;
|
|
639
505
|
};
|
|
640
506
|
flip: {
|
|
641
|
-
type: PropType<
|
|
642
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
643
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
644
|
-
altBoundary?: boolean | undefined;
|
|
645
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
646
|
-
crossAxis?: boolean | undefined;
|
|
647
|
-
mainAxis?: boolean | undefined;
|
|
648
|
-
fallbackPlacements?: import("@floating-ui/utils").Placement[] | undefined;
|
|
649
|
-
fallbackStrategy?: "bestFit" | "initialPlacement" | undefined;
|
|
650
|
-
fallbackAxisSideDirection?: "start" | "end" | "none" | undefined;
|
|
651
|
-
flipAlignment?: boolean | undefined;
|
|
652
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
653
|
-
} | import("@floating-ui/core").Derivable<{
|
|
654
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
655
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
656
|
-
altBoundary?: boolean | undefined;
|
|
657
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
658
|
-
crossAxis?: boolean | undefined;
|
|
659
|
-
mainAxis?: boolean | undefined;
|
|
660
|
-
fallbackPlacements?: import("@floating-ui/utils").Placement[] | undefined;
|
|
661
|
-
fallbackStrategy?: "bestFit" | "initialPlacement" | undefined;
|
|
662
|
-
fallbackAxisSideDirection?: "start" | "end" | "none" | undefined;
|
|
663
|
-
flipAlignment?: boolean | undefined;
|
|
664
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
665
|
-
}> | undefined>;
|
|
507
|
+
type: PropType<import("../..").FlipOptions | boolean>;
|
|
666
508
|
default: boolean;
|
|
667
509
|
};
|
|
668
510
|
size: {
|
|
669
|
-
type: PropType<
|
|
670
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
671
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
672
|
-
altBoundary?: boolean | undefined;
|
|
673
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
674
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
675
|
-
apply?: ((args: {
|
|
676
|
-
x: number;
|
|
677
|
-
y: number;
|
|
678
|
-
initialPlacement: import("@floating-ui/utils").Placement;
|
|
679
|
-
placement: import("@floating-ui/utils").Placement;
|
|
680
|
-
strategy: import("@floating-ui/utils").Strategy;
|
|
681
|
-
middlewareData: import("@floating-ui/core").MiddlewareData;
|
|
682
|
-
rects: import("@floating-ui/utils").ElementRects;
|
|
683
|
-
platform: import("@floating-ui/core").Platform;
|
|
684
|
-
elements: import("@floating-ui/dom").Elements;
|
|
685
|
-
} & {
|
|
686
|
-
availableWidth: number;
|
|
687
|
-
availableHeight: number;
|
|
688
|
-
}) => void | Promise<void>) | undefined;
|
|
689
|
-
} | import("@floating-ui/core").Derivable<{
|
|
690
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
691
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
692
|
-
altBoundary?: boolean | undefined;
|
|
693
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
694
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
695
|
-
apply?: ((args: {
|
|
696
|
-
x: number;
|
|
697
|
-
y: number;
|
|
698
|
-
initialPlacement: import("@floating-ui/utils").Placement;
|
|
699
|
-
placement: import("@floating-ui/utils").Placement;
|
|
700
|
-
strategy: import("@floating-ui/utils").Strategy;
|
|
701
|
-
middlewareData: import("@floating-ui/core").MiddlewareData;
|
|
702
|
-
rects: import("@floating-ui/utils").ElementRects;
|
|
703
|
-
platform: import("@floating-ui/core").Platform;
|
|
704
|
-
elements: import("@floating-ui/dom").Elements;
|
|
705
|
-
} & {
|
|
706
|
-
availableWidth: number;
|
|
707
|
-
availableHeight: number;
|
|
708
|
-
}) => void | Promise<void>) | undefined;
|
|
709
|
-
}> | undefined>;
|
|
511
|
+
type: PropType<import("../..").SizeOptions | boolean>;
|
|
710
512
|
default: () => {
|
|
711
513
|
padding: number;
|
|
712
514
|
};
|
|
713
515
|
};
|
|
714
516
|
autoPlacement: {
|
|
715
|
-
type: PropType<
|
|
716
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
717
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
718
|
-
altBoundary?: boolean | undefined;
|
|
719
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
720
|
-
crossAxis?: boolean | undefined;
|
|
721
|
-
alignment?: import("@floating-ui/utils").Alignment | null | undefined;
|
|
722
|
-
autoAlignment?: boolean | undefined;
|
|
723
|
-
allowedPlacements?: import("@floating-ui/utils").Placement[] | undefined;
|
|
724
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
725
|
-
} | import("@floating-ui/core").Derivable<{
|
|
726
|
-
rootBoundary?: import("@floating-ui/core").RootBoundary | undefined;
|
|
727
|
-
elementContext?: import("@floating-ui/core").ElementContext | undefined;
|
|
728
|
-
altBoundary?: boolean | undefined;
|
|
729
|
-
padding?: import("@floating-ui/utils").Padding | undefined;
|
|
730
|
-
crossAxis?: boolean | undefined;
|
|
731
|
-
alignment?: import("@floating-ui/utils").Alignment | null | undefined;
|
|
732
|
-
autoAlignment?: boolean | undefined;
|
|
733
|
-
allowedPlacements?: import("@floating-ui/utils").Placement[] | undefined;
|
|
734
|
-
boundary?: import("@floating-ui/dom").Boundary | undefined;
|
|
735
|
-
}> | undefined>;
|
|
517
|
+
type: PropType<import("../..").AutoPlacementOptions | boolean>;
|
|
736
518
|
default: boolean;
|
|
737
519
|
};
|
|
738
520
|
arrow: {
|
|
@@ -752,7 +534,7 @@ export declare function useVvComboboxProps<T extends Option | string>(): {
|
|
|
752
534
|
default: undefined;
|
|
753
535
|
};
|
|
754
536
|
iconPosition: {
|
|
755
|
-
type: PropType
|
|
537
|
+
type: PropType<`${import("../../constants").Position}`>;
|
|
756
538
|
default: import("../../constants").Position;
|
|
757
539
|
validation: (value: import("../../constants").Position) => boolean;
|
|
758
540
|
};
|
|
@@ -795,9 +577,7 @@ export declare function useVvComboboxProps<T extends Option | string>(): {
|
|
|
795
577
|
invalid: {
|
|
796
578
|
type: BooleanConstructor;
|
|
797
579
|
default: boolean;
|
|
798
|
-
};
|
|
799
|
-
* Label for no search results
|
|
800
|
-
*/
|
|
580
|
+
};
|
|
801
581
|
invalidLabel: {
|
|
802
582
|
type: (ArrayConstructor | StringConstructor)[];
|
|
803
583
|
default: undefined;
|
|
@@ -1,10 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { iconExists, Icon, addIcon } from "@iconify/vue";
|
|
1
|
+
import { computed, unref, defineComponent, ref, toRefs, openBlock, createBlock, Transition, mergeProps, toHandlers, withCtx, withDirectives, createElementVNode, withModifiers, createElementBlock, renderSlot, createTextVNode, toDisplayString, createCommentVNode, vShow } from "vue";
|
|
3
2
|
import { useVModel, onClickOutside } from "@vueuse/core";
|
|
4
|
-
const VvIconPropsDefaults = {
|
|
5
|
-
prefix: "normal"
|
|
6
|
-
/* normal */
|
|
7
|
-
};
|
|
8
3
|
var StorageType = /* @__PURE__ */ ((StorageType2) => {
|
|
9
4
|
StorageType2["local"] = "local";
|
|
10
5
|
StorageType2["session"] = "session";
|
|
@@ -51,146 +46,6 @@ var ActionTag = /* @__PURE__ */ ((ActionTag2) => {
|
|
|
51
46
|
ActionTag2["button"] = "button";
|
|
52
47
|
return ActionTag2;
|
|
53
48
|
})(ActionTag || {});
|
|
54
|
-
const INJECTION_KEY_VOLVER = Symbol.for("volver");
|
|
55
|
-
function useVolver() {
|
|
56
|
-
return inject(INJECTION_KEY_VOLVER);
|
|
57
|
-
}
|
|
58
|
-
function useModifiers(prefix, modifiers, others) {
|
|
59
|
-
return computed(() => {
|
|
60
|
-
const toReturn = {
|
|
61
|
-
[prefix]: true
|
|
62
|
-
};
|
|
63
|
-
const modifiersArray = typeof (modifiers == null ? void 0 : modifiers.value) === "string" ? modifiers.value.split(" ") : modifiers == null ? void 0 : modifiers.value;
|
|
64
|
-
if (modifiersArray) {
|
|
65
|
-
if (Array.isArray(modifiersArray)) {
|
|
66
|
-
modifiersArray.forEach((modifier) => {
|
|
67
|
-
if (modifier) {
|
|
68
|
-
toReturn[`${prefix}--${modifier}`] = true;
|
|
69
|
-
}
|
|
70
|
-
});
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
if (others) {
|
|
74
|
-
Object.keys(others.value).forEach((key) => {
|
|
75
|
-
toReturn[`${prefix}--${key}`] = unref(others.value[key]);
|
|
76
|
-
});
|
|
77
|
-
}
|
|
78
|
-
return toReturn;
|
|
79
|
-
});
|
|
80
|
-
}
|
|
81
|
-
const __default__$1 = {
|
|
82
|
-
name: "VvIcon"
|
|
83
|
-
};
|
|
84
|
-
const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
85
|
-
...__default__$1,
|
|
86
|
-
props: /* @__PURE__ */ mergeDefaults({
|
|
87
|
-
name: {},
|
|
88
|
-
color: {},
|
|
89
|
-
width: {},
|
|
90
|
-
height: {},
|
|
91
|
-
provider: {},
|
|
92
|
-
prefix: {},
|
|
93
|
-
src: {},
|
|
94
|
-
horizontalFlip: { type: Boolean },
|
|
95
|
-
verticalFlip: { type: Boolean },
|
|
96
|
-
flip: {},
|
|
97
|
-
mode: {},
|
|
98
|
-
inline: { type: Boolean },
|
|
99
|
-
rotate: {},
|
|
100
|
-
onLoad: { type: Function },
|
|
101
|
-
svg: {},
|
|
102
|
-
modifiers: {}
|
|
103
|
-
}, VvIconPropsDefaults),
|
|
104
|
-
setup(__props) {
|
|
105
|
-
const props = __props;
|
|
106
|
-
const hasRotate = computed(() => {
|
|
107
|
-
if (typeof props.rotate === "string") {
|
|
108
|
-
return Number.parseFloat(props.rotate);
|
|
109
|
-
}
|
|
110
|
-
return props.rotate;
|
|
111
|
-
});
|
|
112
|
-
const show = ref(true);
|
|
113
|
-
const volver = useVolver();
|
|
114
|
-
const { modifiers } = toRefs(props);
|
|
115
|
-
const bemCssClasses = useModifiers("vv-icon", modifiers);
|
|
116
|
-
const provider = computed(() => {
|
|
117
|
-
return props.provider || (volver == null ? void 0 : volver.iconsProvider);
|
|
118
|
-
});
|
|
119
|
-
const icon = computed(() => {
|
|
120
|
-
const name = props.name ?? "";
|
|
121
|
-
const iconName = `@${provider.value}:${props.prefix}:${name}`;
|
|
122
|
-
if (iconExists(iconName)) {
|
|
123
|
-
return iconName;
|
|
124
|
-
}
|
|
125
|
-
const iconsCollection = volver == null ? void 0 : volver.iconsCollections.find(
|
|
126
|
-
(iconsCollection2) => {
|
|
127
|
-
const icon2 = `@${provider.value}:${iconsCollection2.prefix}:${name}`;
|
|
128
|
-
return iconExists(icon2);
|
|
129
|
-
}
|
|
130
|
-
);
|
|
131
|
-
if (iconsCollection) {
|
|
132
|
-
return `@${provider.value}:${iconsCollection.prefix}:${name}`;
|
|
133
|
-
}
|
|
134
|
-
return name;
|
|
135
|
-
});
|
|
136
|
-
function getSvgContent(svg) {
|
|
137
|
-
let dom;
|
|
138
|
-
if (typeof window === "undefined") {
|
|
139
|
-
const { JSDOM } = require("jsdom");
|
|
140
|
-
dom = new JSDOM().window;
|
|
141
|
-
}
|
|
142
|
-
const domParser = dom ? new dom.DOMParser() : new window.DOMParser();
|
|
143
|
-
const svgDomString = domParser.parseFromString(svg, "text/html");
|
|
144
|
-
const svgEl = svgDomString.querySelector("svg");
|
|
145
|
-
return svgEl;
|
|
146
|
-
}
|
|
147
|
-
function addIconFromSvg(svg) {
|
|
148
|
-
const svgContentEl = getSvgContent(svg);
|
|
149
|
-
const svgContent = (svgContentEl == null ? void 0 : svgContentEl.innerHTML.trim()) || "";
|
|
150
|
-
if (svgContentEl && svgContent) {
|
|
151
|
-
addIcon(`@${provider.value}:${props.prefix}:${props.name}`, {
|
|
152
|
-
body: svgContent,
|
|
153
|
-
// Set height and width from svg content
|
|
154
|
-
height: svgContentEl.viewBox.baseVal.height,
|
|
155
|
-
width: svgContentEl.viewBox.baseVal.width
|
|
156
|
-
});
|
|
157
|
-
}
|
|
158
|
-
}
|
|
159
|
-
if (volver) {
|
|
160
|
-
if (props.src && !iconExists(`@${provider.value}:${props.prefix}:${props.name}`)) {
|
|
161
|
-
show.value = false;
|
|
162
|
-
volver.fetchIcon(props.src).then((svg) => {
|
|
163
|
-
if (svg) {
|
|
164
|
-
addIconFromSvg(svg);
|
|
165
|
-
show.value = true;
|
|
166
|
-
}
|
|
167
|
-
}).catch((e) => {
|
|
168
|
-
throw new Error(`Error during fetch icon: ${e == null ? void 0 : e.message}`);
|
|
169
|
-
});
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
if (props.svg) {
|
|
173
|
-
addIconFromSvg(props.svg);
|
|
174
|
-
}
|
|
175
|
-
return (_ctx, _cache) => {
|
|
176
|
-
return unref(show) ? (openBlock(), createBlock(unref(Icon), mergeProps({
|
|
177
|
-
key: 0,
|
|
178
|
-
class: unref(bemCssClasses)
|
|
179
|
-
}, {
|
|
180
|
-
inline: _ctx.inline,
|
|
181
|
-
width: _ctx.width,
|
|
182
|
-
height: _ctx.height,
|
|
183
|
-
horizontalFlip: _ctx.horizontalFlip,
|
|
184
|
-
verticalFlip: _ctx.verticalFlip,
|
|
185
|
-
flip: _ctx.flip,
|
|
186
|
-
rotate: unref(hasRotate),
|
|
187
|
-
color: _ctx.color,
|
|
188
|
-
onLoad: _ctx.onLoad,
|
|
189
|
-
icon: unref(icon)
|
|
190
|
-
}), null, 16, ["class"])) : createCommentVNode("v-if", true);
|
|
191
|
-
};
|
|
192
|
-
}
|
|
193
|
-
});
|
|
194
49
|
const LinkProps = {
|
|
195
50
|
/**
|
|
196
51
|
* The router-link/nuxt-link property, if it is defined the button is rendered as a ruouter-link or nuxt-link.
|
|
@@ -465,14 +320,42 @@ const VvDialogProps = {
|
|
|
465
320
|
/**
|
|
466
321
|
* Keep open dialog on click outside
|
|
467
322
|
*/
|
|
468
|
-
keepOpen: { type: Boolean, default: false }
|
|
323
|
+
keepOpen: { type: Boolean, default: false },
|
|
324
|
+
/**
|
|
325
|
+
* Close button label
|
|
326
|
+
*/
|
|
327
|
+
labelClose: { type: String, default: "Close" }
|
|
469
328
|
};
|
|
329
|
+
function useModifiers(prefix, modifiers, others) {
|
|
330
|
+
return computed(() => {
|
|
331
|
+
const toReturn = {
|
|
332
|
+
[prefix]: true
|
|
333
|
+
};
|
|
334
|
+
const modifiersArray = typeof (modifiers == null ? void 0 : modifiers.value) === "string" ? modifiers.value.split(" ") : modifiers == null ? void 0 : modifiers.value;
|
|
335
|
+
if (modifiersArray) {
|
|
336
|
+
if (Array.isArray(modifiersArray)) {
|
|
337
|
+
modifiersArray.forEach((modifier) => {
|
|
338
|
+
if (modifier) {
|
|
339
|
+
toReturn[`${prefix}--${modifier}`] = true;
|
|
340
|
+
}
|
|
341
|
+
});
|
|
342
|
+
}
|
|
343
|
+
}
|
|
344
|
+
if (others) {
|
|
345
|
+
Object.keys(others.value).forEach((key) => {
|
|
346
|
+
toReturn[`${prefix}--${key}`] = unref(others.value[key]);
|
|
347
|
+
});
|
|
348
|
+
}
|
|
349
|
+
return toReturn;
|
|
350
|
+
});
|
|
351
|
+
}
|
|
470
352
|
const _hoisted_1 = {
|
|
471
353
|
key: 0,
|
|
472
354
|
class: "vv-dialog__header"
|
|
473
355
|
};
|
|
474
|
-
const _hoisted_2 =
|
|
475
|
-
const _hoisted_3 = {
|
|
356
|
+
const _hoisted_2 = ["aria-label", "title"];
|
|
357
|
+
const _hoisted_3 = { class: "vv-dialog__content" };
|
|
358
|
+
const _hoisted_4 = {
|
|
476
359
|
key: 1,
|
|
477
360
|
class: "vv-dialog__footer"
|
|
478
361
|
};
|
|
@@ -599,26 +482,19 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
599
482
|
1
|
|
600
483
|
/* TEXT */
|
|
601
484
|
),
|
|
602
|
-
createElementVNode(
|
|
603
|
-
"button",
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
},
|
|
610
|
-
[
|
|
611
|
-
createVNode(_sfc_main$1, { name: "close" })
|
|
612
|
-
],
|
|
613
|
-
32
|
|
614
|
-
/* NEED_HYDRATION */
|
|
615
|
-
)
|
|
485
|
+
createElementVNode("button", {
|
|
486
|
+
type: "button",
|
|
487
|
+
"aria-label": _ctx.labelClose,
|
|
488
|
+
title: _ctx.labelClose,
|
|
489
|
+
class: "vv-dialog__close",
|
|
490
|
+
onClickPassive: close
|
|
491
|
+
}, null, 40, _hoisted_2)
|
|
616
492
|
])
|
|
617
493
|
])) : createCommentVNode("v-if", true),
|
|
618
|
-
createElementVNode("div",
|
|
494
|
+
createElementVNode("div", _hoisted_3, [
|
|
619
495
|
renderSlot(_ctx.$slots, "default")
|
|
620
496
|
]),
|
|
621
|
-
_ctx.$slots.footer ? (openBlock(), createElementBlock("footer",
|
|
497
|
+
_ctx.$slots.footer ? (openBlock(), createElementBlock("footer", _hoisted_4, [
|
|
622
498
|
renderSlot(_ctx.$slots, "footer")
|
|
623
499
|
])) : createCommentVNode("v-if", true)
|
|
624
500
|
],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?module.exports=o(require("vue"),require("@
|
|
1
|
+
!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?module.exports=o(require("vue"),require("@vueuse/core")):"function"==typeof define&&define.amd?define(["vue","@vueuse/core"],o):(e="undefined"!=typeof globalThis?globalThis:e||self).VvDialog=o(e.vue,e.core)}(this,(function(e,o){"use strict";var t=(e=>(e.local="local",e.session="session",e))(t||{}),l=(e=>(e.left="left",e.right="right",e.top="top",e.bottom="bottom",e))(l||{}),n=(e=>(e.before="before",e.after="after",e))(n||{}),a=(e=>(e.button="button",e.submit="submit",e.reset="reset",e))(a||{}),r=(e=>(e.nuxtLink="nuxt-link",e.routerLink="router-link",e.a="a",e.button="button",e))(r||{});Boolean,Boolean,Boolean,Boolean;const i={modifiers:{type:[String,Array],default:void 0}};n.before;const s={id:[String,Number]};l.bottom,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,a.button,r.button,t.local;const u={...i,...s,title:String,modelValue:{type:Boolean,default:void 0},transition:{type:String,default:"fade-block"},size:String,keepOpen:{type:Boolean,default:!1},labelClose:{type:String,default:"Close"}};const d={key:0,class:"vv-dialog__header"},c=["aria-label","title"],f={class:"vv-dialog__content"},v={key:1,class:"vv-dialog__footer"};return e.defineComponent({name:"VvDialog",props:u,emits:["open","close","update:modelValue","beforeEnter","afterLeave","enter","afterEnter","enterCancelled","beforeLeave","leave","leaveCancelled"],setup(t,{expose:l,emit:n}){const a=t,r=n,i=e.ref(),s=o.useVModel(a,"modelValue",r),u=e.ref(!1),p=e.computed({get:()=>s.value??u.value,set:e=>{void 0!==s.value?s.value=e:u.value=e}}),m=e.ref(null),{modifiers:b}=e.toRefs(a),g=function(o,t,l){return e.computed((()=>{const n={[o]:!0},a="string"==typeof(null==t?void 0:t.value)?t.value.split(" "):null==t?void 0:t.value;return a&&Array.isArray(a)&&a.forEach((e=>{e&&(n[`${o}--${e}`]=!0)})),l&&Object.keys(l.value).forEach((t=>{n[`${o}--${t}`]=e.unref(l.value[t])})),n}))}("vv-dialog",b,e.computed((()=>a.size?{[a.size]:!!a.size}:{}))),k=e.computed((()=>{const{id:e}=a;return{id:e}})),y=e.computed((()=>`vv-dialog--${a.transition}`)),B={"before-enter":()=>{var e,o;(null==(e=i.value)?void 0:e.open)||null==(o=i.value)||o.showModal(),r("open"),r("beforeEnter")},"after-leave":()=>{var e,o;(null==(e=i.value)?void 0:e.open)&&(null==(o=i.value)||o.close()),r("close"),r("afterLeave")},enter:()=>{r("enter")},"after-enter":()=>{r("afterEnter")},"enter-cancelled":()=>{r("enterCancelled")},"before-leave":()=>{r("beforeLeave")},leave:()=>{r("leave")},"leave-cancelled":()=>{r("leaveCancelled")}};function h(){p.value=!1}function C(){a.keepOpen||h()}return o.onClickOutside(m,(()=>{a.keepOpen||h()})),l({close:h,open:function(){p.value=!0}}),(o,t)=>(e.openBlock(),e.createBlock(e.Transition,e.mergeProps({name:e.unref(y)},e.toHandlers(B),{persisted:""}),{default:e.withCtx((()=>[e.withDirectives(e.createElementVNode("dialog",e.mergeProps(e.unref(k),{ref_key:"dialogEl",ref:i,class:e.unref(g),onCancel:e.withModifiers(C,["stop","prevent"])}),[e.createElementVNode("article",{ref_key:"modalWrapper",ref:m,class:"vv-dialog__wrapper"},[o.$slots.header||o.title?(e.openBlock(),e.createElementBlock("header",d,[e.renderSlot(o.$slots,"header",{},(()=>[e.createTextVNode(e.toDisplayString(o.title)+" ",1),e.createElementVNode("button",{type:"button","aria-label":o.labelClose,title:o.labelClose,class:"vv-dialog__close",onClickPassive:h},null,40,c)]))])):e.createCommentVNode("v-if",!0),e.createElementVNode("div",f,[e.renderSlot(o.$slots,"default")]),o.$slots.footer?(e.openBlock(),e.createElementBlock("footer",v,[e.renderSlot(o.$slots,"footer")])):e.createCommentVNode("v-if",!0)],512)],16),[[e.vShow,e.unref(p)]])])),_:3},16,["name"]))}})}));
|
|
@@ -13,6 +13,10 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
13
13
|
type: BooleanConstructor;
|
|
14
14
|
default: boolean;
|
|
15
15
|
};
|
|
16
|
+
labelClose: {
|
|
17
|
+
type: StringConstructor;
|
|
18
|
+
default: string;
|
|
19
|
+
};
|
|
16
20
|
id: (StringConstructor | NumberConstructor)[];
|
|
17
21
|
modifiers: {
|
|
18
22
|
type: globalThis.PropType<string | string[]>;
|
|
@@ -38,6 +42,10 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
38
42
|
type: BooleanConstructor;
|
|
39
43
|
default: boolean;
|
|
40
44
|
};
|
|
45
|
+
labelClose: {
|
|
46
|
+
type: StringConstructor;
|
|
47
|
+
default: string;
|
|
48
|
+
};
|
|
41
49
|
id: (StringConstructor | NumberConstructor)[];
|
|
42
50
|
modifiers: {
|
|
43
51
|
type: globalThis.PropType<string | string[]>;
|
|
@@ -48,6 +56,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
48
56
|
modifiers: string | string[];
|
|
49
57
|
transition: string;
|
|
50
58
|
keepOpen: boolean;
|
|
59
|
+
labelClose: string;
|
|
51
60
|
}, {}>, {
|
|
52
61
|
header?(_: {}): any;
|
|
53
62
|
default?(_: {}): any;
|
|
@@ -30,6 +30,13 @@ export declare const VvDialogProps: {
|
|
|
30
30
|
type: BooleanConstructor;
|
|
31
31
|
default: boolean;
|
|
32
32
|
};
|
|
33
|
+
/**
|
|
34
|
+
* Close button label
|
|
35
|
+
*/
|
|
36
|
+
labelClose: {
|
|
37
|
+
type: StringConstructor;
|
|
38
|
+
default: string;
|
|
39
|
+
};
|
|
33
40
|
id: (StringConstructor | NumberConstructor)[];
|
|
34
41
|
modifiers: {
|
|
35
42
|
type: globalThis.PropType<string | string[]>;
|