@nuxt/ui 2.9.0 → 2.10.0
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/module.d.mts +270 -2
- package/dist/module.d.ts +270 -2
- package/dist/module.json +1 -1
- package/dist/module.mjs +21 -2
- package/dist/runtime/components/data/Table.vue +8 -6
- package/dist/runtime/components/data/Table.vue.d.ts +2 -1
- package/dist/runtime/components/elements/Accordion.vue +15 -13
- package/dist/runtime/components/elements/Accordion.vue.d.ts +5 -2
- package/dist/runtime/components/elements/Button.vue.d.ts +2 -2
- package/dist/runtime/components/elements/Dropdown.vue +31 -25
- package/dist/runtime/components/elements/Dropdown.vue.d.ts +2 -0
- package/dist/runtime/components/elements/Meter.vue +166 -0
- package/dist/runtime/components/elements/Meter.vue.d.ts +123 -0
- package/dist/runtime/components/elements/MeterGroup.d.ts +78 -0
- package/dist/runtime/components/elements/MeterGroup.mjs +172 -0
- package/dist/runtime/components/elements/Progress.vue +284 -0
- package/dist/runtime/components/elements/Progress.vue.d.ts +2 -0
- package/dist/runtime/components/forms/Checkbox.vue.d.ts +2 -2
- package/dist/runtime/components/forms/Form.vue +32 -7
- package/dist/runtime/components/forms/Form.vue.d.ts +2 -1
- package/dist/runtime/components/forms/Input.vue +5 -1
- package/dist/runtime/components/forms/Input.vue.d.ts +12 -3
- package/dist/runtime/components/forms/Radio.vue +10 -9
- package/dist/runtime/components/forms/Radio.vue.d.ts +3 -3
- package/dist/runtime/components/forms/RadioGroup.vue +136 -0
- package/dist/runtime/components/forms/RadioGroup.vue.d.ts +118 -0
- package/dist/runtime/components/forms/Range.vue.d.ts +3 -3
- package/dist/runtime/components/forms/Select.vue.d.ts +2 -2
- package/dist/runtime/components/forms/SelectMenu.vue +62 -57
- package/dist/runtime/components/forms/SelectMenu.vue.d.ts +6 -5
- package/dist/runtime/components/forms/Textarea.vue +5 -1
- package/dist/runtime/components/forms/Textarea.vue.d.ts +11 -2
- package/dist/runtime/components/forms/Toggle.vue.d.ts +2 -2
- package/dist/runtime/components/layout/Divider.vue +107 -0
- package/dist/runtime/components/layout/Divider.vue.d.ts +82 -0
- package/dist/runtime/components/navigation/CommandPalette.vue +10 -3
- package/dist/runtime/components/navigation/CommandPalette.vue.d.ts +1 -1
- package/dist/runtime/components/navigation/Pagination.vue +65 -9
- package/dist/runtime/components/navigation/Pagination.vue.d.ts +41 -3
- package/dist/runtime/components/navigation/Tabs.vue +1 -1
- package/dist/runtime/components/overlays/ContextMenu.vue +7 -2
- package/dist/runtime/components/overlays/ContextMenu.vue.d.ts +2 -1
- package/dist/runtime/components/overlays/Modal.vue +1 -1
- package/dist/runtime/components/overlays/Modal.vue.d.ts +1 -1
- package/dist/runtime/components/overlays/Notification.vue +7 -1
- package/dist/runtime/components/overlays/Notifications.vue +1 -1
- package/dist/runtime/components/overlays/Popover.vue +22 -7
- package/dist/runtime/components/overlays/Popover.vue.d.ts +14 -0
- package/dist/runtime/components/overlays/Slideover.vue.d.ts +1 -1
- package/dist/runtime/components/overlays/Tooltip.vue +16 -10
- package/dist/runtime/components/overlays/Tooltip.vue.d.ts +1 -0
- package/dist/runtime/composables/useFormGroup.d.ts +3 -3
- package/dist/runtime/composables/useFormGroup.mjs +17 -6
- package/dist/runtime/composables/usePopper.d.ts +3 -3
- package/dist/runtime/composables/usePopper.mjs +7 -1
- package/dist/runtime/composables/useUI.d.ts +2 -2
- package/dist/runtime/composables/useUI.mjs +2 -2
- package/dist/runtime/types/command-palette.d.ts +1 -0
- package/dist/runtime/types/form.d.ts +13 -6
- package/dist/runtime/types/index.d.ts +2 -0
- package/dist/runtime/types/meter.d.ts +5 -0
- package/dist/runtime/types/popper.d.ts +1 -0
- package/dist/runtime/types/progress.d.ts +4 -0
- package/dist/runtime/types/utils.d.ts +1 -1
- package/dist/runtime/ui.config.d.ts +263 -0
- package/dist/runtime/ui.config.mjs +263 -19
- package/dist/types.d.mts +1 -1
- package/dist/types.d.ts +1 -1
- package/package.json +19 -19
- package/dist/runtime/utils/StateEmitter.d.ts +0 -17
- package/dist/runtime/utils/StateEmitter.mjs +0 -21
|
@@ -1,10 +1,16 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import { Ref } from 'vue'
|
|
2
|
+
|
|
3
|
+
export interface FormError<T extends string = string> {
|
|
4
|
+
path: T
|
|
3
5
|
message: string
|
|
4
6
|
}
|
|
5
7
|
|
|
8
|
+
export interface FormErrorWithId extends FormError {
|
|
9
|
+
id: string
|
|
10
|
+
}
|
|
11
|
+
|
|
6
12
|
export interface Form<T> {
|
|
7
|
-
validate(path?: string, opts
|
|
13
|
+
validate(path?: string, opts?: { silent?: boolean }): Promise<T>
|
|
8
14
|
clear(path?: string): void
|
|
9
15
|
errors: Ref<FormError[]>
|
|
10
16
|
setErrors(errs: FormError[], path?: string): void
|
|
@@ -12,17 +18,18 @@ export interface Form<T> {
|
|
|
12
18
|
}
|
|
13
19
|
|
|
14
20
|
export type FormSubmitEvent<T> = SubmitEvent & { data: T }
|
|
21
|
+
export type FormErrorEvent = SubmitEvent & { errors: FormErrorWithId[] }
|
|
15
22
|
|
|
16
23
|
export type FormEventType = 'blur' | 'input' | 'change' | 'submit'
|
|
17
24
|
|
|
18
25
|
export interface FormEvent {
|
|
19
26
|
type: FormEventType
|
|
20
|
-
path
|
|
27
|
+
path?: string
|
|
21
28
|
}
|
|
22
29
|
|
|
23
30
|
export interface InjectedFormGroupValue {
|
|
24
|
-
inputId: Ref<string>
|
|
31
|
+
inputId: Ref<string | undefined>
|
|
25
32
|
name: Ref<string>
|
|
26
|
-
size: Ref<string>
|
|
33
|
+
size: Ref<string | number | symbol>
|
|
27
34
|
error: Ref<string | boolean>
|
|
28
35
|
}
|
|
@@ -7,8 +7,10 @@ export * from './command-palette'
|
|
|
7
7
|
export * from './dropdown'
|
|
8
8
|
export * from './form'
|
|
9
9
|
export * from './link'
|
|
10
|
+
export * from './meter'
|
|
10
11
|
export * from './notification'
|
|
11
12
|
export * from './popper'
|
|
13
|
+
export * from './progress'
|
|
12
14
|
export * from './tabs'
|
|
13
15
|
export * from './vertical-navigation'
|
|
14
16
|
export * from './utils'
|
|
@@ -281,6 +281,14 @@ export declare const dropdown: {
|
|
|
281
281
|
placement: string;
|
|
282
282
|
strategy: string;
|
|
283
283
|
};
|
|
284
|
+
arrow: {
|
|
285
|
+
ring: string;
|
|
286
|
+
background: string;
|
|
287
|
+
base: string;
|
|
288
|
+
rounded: string;
|
|
289
|
+
shadow: string;
|
|
290
|
+
placement: string;
|
|
291
|
+
};
|
|
284
292
|
};
|
|
285
293
|
export declare const accordion: {
|
|
286
294
|
wrapper: string;
|
|
@@ -355,6 +363,167 @@ export declare const kbd: {
|
|
|
355
363
|
size: string;
|
|
356
364
|
};
|
|
357
365
|
};
|
|
366
|
+
export declare const progress: {
|
|
367
|
+
wrapper: string;
|
|
368
|
+
indicator: {
|
|
369
|
+
container: {
|
|
370
|
+
base: string;
|
|
371
|
+
width: string;
|
|
372
|
+
transition: string;
|
|
373
|
+
};
|
|
374
|
+
align: string;
|
|
375
|
+
width: string;
|
|
376
|
+
color: string;
|
|
377
|
+
size: {
|
|
378
|
+
'2xs': string;
|
|
379
|
+
xs: string;
|
|
380
|
+
sm: string;
|
|
381
|
+
md: string;
|
|
382
|
+
lg: string;
|
|
383
|
+
xl: string;
|
|
384
|
+
'2xl': string;
|
|
385
|
+
};
|
|
386
|
+
};
|
|
387
|
+
progress: {
|
|
388
|
+
base: string;
|
|
389
|
+
width: string;
|
|
390
|
+
size: {
|
|
391
|
+
'2xs': string;
|
|
392
|
+
xs: string;
|
|
393
|
+
sm: string;
|
|
394
|
+
md: string;
|
|
395
|
+
lg: string;
|
|
396
|
+
xl: string;
|
|
397
|
+
'2xl': string;
|
|
398
|
+
};
|
|
399
|
+
rounded: string;
|
|
400
|
+
track: string;
|
|
401
|
+
bar: string;
|
|
402
|
+
color: string;
|
|
403
|
+
background: string;
|
|
404
|
+
indeterminate: {
|
|
405
|
+
base: string;
|
|
406
|
+
rounded: string;
|
|
407
|
+
};
|
|
408
|
+
};
|
|
409
|
+
steps: {
|
|
410
|
+
base: string;
|
|
411
|
+
color: string;
|
|
412
|
+
size: {
|
|
413
|
+
'2xs': string;
|
|
414
|
+
xs: string;
|
|
415
|
+
sm: string;
|
|
416
|
+
md: string;
|
|
417
|
+
lg: string;
|
|
418
|
+
xl: string;
|
|
419
|
+
'2xl': string;
|
|
420
|
+
};
|
|
421
|
+
};
|
|
422
|
+
step: {
|
|
423
|
+
base: string;
|
|
424
|
+
align: string;
|
|
425
|
+
active: string;
|
|
426
|
+
first: string;
|
|
427
|
+
};
|
|
428
|
+
animation: {
|
|
429
|
+
carousel: string;
|
|
430
|
+
'carousel-inverse': string;
|
|
431
|
+
swing: string;
|
|
432
|
+
elastic: string;
|
|
433
|
+
};
|
|
434
|
+
default: {
|
|
435
|
+
color: string;
|
|
436
|
+
size: string;
|
|
437
|
+
animation: string;
|
|
438
|
+
};
|
|
439
|
+
};
|
|
440
|
+
export declare const meter: {
|
|
441
|
+
wrapper: string;
|
|
442
|
+
indicator: {
|
|
443
|
+
container: string;
|
|
444
|
+
text: string;
|
|
445
|
+
size: {
|
|
446
|
+
'2xs': string;
|
|
447
|
+
xs: string;
|
|
448
|
+
sm: string;
|
|
449
|
+
md: string;
|
|
450
|
+
lg: string;
|
|
451
|
+
xl: string;
|
|
452
|
+
'2xl': string;
|
|
453
|
+
};
|
|
454
|
+
};
|
|
455
|
+
meter: {
|
|
456
|
+
base: string;
|
|
457
|
+
background: string;
|
|
458
|
+
color: string;
|
|
459
|
+
ring: string;
|
|
460
|
+
rounded: string;
|
|
461
|
+
shadow: string;
|
|
462
|
+
size: {
|
|
463
|
+
'2xs': string;
|
|
464
|
+
xs: string;
|
|
465
|
+
sm: string;
|
|
466
|
+
md: string;
|
|
467
|
+
lg: string;
|
|
468
|
+
xl: string;
|
|
469
|
+
'2xl': string;
|
|
470
|
+
};
|
|
471
|
+
appearance: {
|
|
472
|
+
inner: string;
|
|
473
|
+
meter: string;
|
|
474
|
+
bar: string;
|
|
475
|
+
value: string;
|
|
476
|
+
};
|
|
477
|
+
bar: {
|
|
478
|
+
transition: string;
|
|
479
|
+
ring: string;
|
|
480
|
+
rounded: string;
|
|
481
|
+
size: {
|
|
482
|
+
'2xs': string;
|
|
483
|
+
xs: string;
|
|
484
|
+
sm: string;
|
|
485
|
+
md: string;
|
|
486
|
+
lg: string;
|
|
487
|
+
xl: string;
|
|
488
|
+
'2xl': string;
|
|
489
|
+
};
|
|
490
|
+
};
|
|
491
|
+
};
|
|
492
|
+
label: {
|
|
493
|
+
base: string;
|
|
494
|
+
text: string;
|
|
495
|
+
color: string;
|
|
496
|
+
size: {
|
|
497
|
+
'2xs': string;
|
|
498
|
+
xs: string;
|
|
499
|
+
sm: string;
|
|
500
|
+
md: string;
|
|
501
|
+
lg: string;
|
|
502
|
+
xl: string;
|
|
503
|
+
'2xl': string;
|
|
504
|
+
};
|
|
505
|
+
};
|
|
506
|
+
color: {
|
|
507
|
+
white: string;
|
|
508
|
+
black: string;
|
|
509
|
+
gray: string;
|
|
510
|
+
};
|
|
511
|
+
default: {
|
|
512
|
+
size: string;
|
|
513
|
+
color: string;
|
|
514
|
+
};
|
|
515
|
+
};
|
|
516
|
+
export declare const meterGroup: {
|
|
517
|
+
wrapper: string;
|
|
518
|
+
base: string;
|
|
519
|
+
background: string;
|
|
520
|
+
transition: string;
|
|
521
|
+
rounded: string;
|
|
522
|
+
shadow: string;
|
|
523
|
+
default: {
|
|
524
|
+
size: string;
|
|
525
|
+
};
|
|
526
|
+
};
|
|
358
527
|
export declare const input: {
|
|
359
528
|
wrapper: string;
|
|
360
529
|
base: string;
|
|
@@ -743,6 +912,21 @@ export declare const selectMenu: {
|
|
|
743
912
|
default: {
|
|
744
913
|
selectedIcon: string;
|
|
745
914
|
};
|
|
915
|
+
arrow: {
|
|
916
|
+
ring: string;
|
|
917
|
+
background: string;
|
|
918
|
+
base: string;
|
|
919
|
+
rounded: string;
|
|
920
|
+
shadow: string;
|
|
921
|
+
placement: string;
|
|
922
|
+
};
|
|
923
|
+
};
|
|
924
|
+
export declare const radioGroup: {
|
|
925
|
+
wrapper: string;
|
|
926
|
+
legend: string;
|
|
927
|
+
default: {
|
|
928
|
+
color: string;
|
|
929
|
+
};
|
|
746
930
|
};
|
|
747
931
|
export declare const radio: {
|
|
748
932
|
wrapper: string;
|
|
@@ -808,9 +992,13 @@ export declare const range: {
|
|
|
808
992
|
rounded: string;
|
|
809
993
|
background: string;
|
|
810
994
|
size: {
|
|
995
|
+
'2xs': string;
|
|
996
|
+
xs: string;
|
|
811
997
|
sm: string;
|
|
812
998
|
md: string;
|
|
813
999
|
lg: string;
|
|
1000
|
+
xl: string;
|
|
1001
|
+
'2xl': string;
|
|
814
1002
|
};
|
|
815
1003
|
};
|
|
816
1004
|
thumb: {
|
|
@@ -819,9 +1007,13 @@ export declare const range: {
|
|
|
819
1007
|
background: string;
|
|
820
1008
|
ring: string;
|
|
821
1009
|
size: {
|
|
1010
|
+
'2xs': string;
|
|
1011
|
+
xs: string;
|
|
822
1012
|
sm: string;
|
|
823
1013
|
md: string;
|
|
824
1014
|
lg: string;
|
|
1015
|
+
xl: string;
|
|
1016
|
+
'2xl': string;
|
|
825
1017
|
};
|
|
826
1018
|
};
|
|
827
1019
|
track: {
|
|
@@ -829,15 +1021,23 @@ export declare const range: {
|
|
|
829
1021
|
background: string;
|
|
830
1022
|
rounded: string;
|
|
831
1023
|
size: {
|
|
1024
|
+
'2xs': string;
|
|
1025
|
+
xs: string;
|
|
832
1026
|
sm: string;
|
|
833
1027
|
md: string;
|
|
834
1028
|
lg: string;
|
|
1029
|
+
xl: string;
|
|
1030
|
+
'2xl': string;
|
|
835
1031
|
};
|
|
836
1032
|
};
|
|
837
1033
|
size: {
|
|
1034
|
+
'2xs': string;
|
|
1035
|
+
xs: string;
|
|
838
1036
|
sm: string;
|
|
839
1037
|
md: string;
|
|
840
1038
|
lg: string;
|
|
1039
|
+
xl: string;
|
|
1040
|
+
'2xl': string;
|
|
841
1041
|
};
|
|
842
1042
|
default: {
|
|
843
1043
|
size: string;
|
|
@@ -877,6 +1077,35 @@ export declare const skeleton: {
|
|
|
877
1077
|
background: string;
|
|
878
1078
|
rounded: string;
|
|
879
1079
|
};
|
|
1080
|
+
export declare const divider: {
|
|
1081
|
+
wrapper: {
|
|
1082
|
+
base: string;
|
|
1083
|
+
horizontal: string;
|
|
1084
|
+
vertical: string;
|
|
1085
|
+
};
|
|
1086
|
+
container: {
|
|
1087
|
+
base: string;
|
|
1088
|
+
horizontal: string;
|
|
1089
|
+
vertical: string;
|
|
1090
|
+
};
|
|
1091
|
+
border: {
|
|
1092
|
+
base: string;
|
|
1093
|
+
horizontal: string;
|
|
1094
|
+
vertical: string;
|
|
1095
|
+
size: {
|
|
1096
|
+
horizontal: string;
|
|
1097
|
+
vertical: string;
|
|
1098
|
+
};
|
|
1099
|
+
};
|
|
1100
|
+
icon: {
|
|
1101
|
+
base: string;
|
|
1102
|
+
};
|
|
1103
|
+
avatar: {
|
|
1104
|
+
base: string;
|
|
1105
|
+
size: string;
|
|
1106
|
+
};
|
|
1107
|
+
label: string;
|
|
1108
|
+
};
|
|
880
1109
|
export declare const verticalNavigation: {
|
|
881
1110
|
wrapper: string;
|
|
882
1111
|
base: string;
|
|
@@ -983,6 +1212,16 @@ export declare const pagination: {
|
|
|
983
1212
|
inactiveButton: {
|
|
984
1213
|
color: string;
|
|
985
1214
|
};
|
|
1215
|
+
firstButton: {
|
|
1216
|
+
color: string;
|
|
1217
|
+
class: string;
|
|
1218
|
+
icon: string;
|
|
1219
|
+
};
|
|
1220
|
+
lastButton: {
|
|
1221
|
+
color: string;
|
|
1222
|
+
class: string;
|
|
1223
|
+
icon: string;
|
|
1224
|
+
};
|
|
986
1225
|
prevButton: {
|
|
987
1226
|
color: string;
|
|
988
1227
|
class: string;
|
|
@@ -1110,6 +1349,14 @@ export declare const tooltip: {
|
|
|
1110
1349
|
popper: {
|
|
1111
1350
|
strategy: string;
|
|
1112
1351
|
};
|
|
1352
|
+
arrow: {
|
|
1353
|
+
base: string;
|
|
1354
|
+
ring: string;
|
|
1355
|
+
rounded: string;
|
|
1356
|
+
background: string;
|
|
1357
|
+
shadow: string;
|
|
1358
|
+
placement: string;
|
|
1359
|
+
};
|
|
1113
1360
|
};
|
|
1114
1361
|
export declare const popover: {
|
|
1115
1362
|
wrapper: string;
|
|
@@ -1131,6 +1378,14 @@ export declare const popover: {
|
|
|
1131
1378
|
popper: {
|
|
1132
1379
|
strategy: string;
|
|
1133
1380
|
};
|
|
1381
|
+
arrow: {
|
|
1382
|
+
base: string;
|
|
1383
|
+
ring: string;
|
|
1384
|
+
rounded: string;
|
|
1385
|
+
background: string;
|
|
1386
|
+
shadow: string;
|
|
1387
|
+
placement: string;
|
|
1388
|
+
};
|
|
1134
1389
|
};
|
|
1135
1390
|
export declare const contextMenu: {
|
|
1136
1391
|
wrapper: string;
|
|
@@ -1153,6 +1408,14 @@ export declare const contextMenu: {
|
|
|
1153
1408
|
placement: string;
|
|
1154
1409
|
scroll: boolean;
|
|
1155
1410
|
};
|
|
1411
|
+
arrow: {
|
|
1412
|
+
base: string;
|
|
1413
|
+
ring: string;
|
|
1414
|
+
rounded: string;
|
|
1415
|
+
background: string;
|
|
1416
|
+
shadow: string;
|
|
1417
|
+
placement: string;
|
|
1418
|
+
};
|
|
1156
1419
|
};
|
|
1157
1420
|
export declare const notification: {
|
|
1158
1421
|
wrapper: string;
|