@nuxt/ui 3.1.0 → 3.1.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.
- package/.nuxt/ui/accordion.ts +2 -23
- package/.nuxt/ui/alert.ts +2 -23
- package/.nuxt/ui/avatar-group.ts +2 -23
- package/.nuxt/ui/avatar.ts +2 -23
- package/.nuxt/ui/badge.ts +2 -23
- package/.nuxt/ui/breadcrumb.ts +2 -23
- package/.nuxt/ui/button-group.ts +2 -23
- package/.nuxt/ui/button.ts +2 -23
- package/.nuxt/ui/calendar.ts +3 -24
- package/.nuxt/ui/card.ts +2 -23
- package/.nuxt/ui/carousel.ts +2 -23
- package/.nuxt/ui/checkbox-group.ts +2 -23
- package/.nuxt/ui/checkbox.ts +2 -23
- package/.nuxt/ui/chip.ts +2 -23
- package/.nuxt/ui/collapsible.ts +2 -23
- package/.nuxt/ui/color-picker.ts +2 -23
- package/.nuxt/ui/command-palette.ts +2 -23
- package/.nuxt/ui/container.ts +2 -23
- package/.nuxt/ui/context-menu.ts +2 -23
- package/.nuxt/ui/drawer.ts +2 -23
- package/.nuxt/ui/dropdown-menu.ts +2 -23
- package/.nuxt/ui/form-field.ts +2 -23
- package/.nuxt/ui/form.ts +2 -23
- package/.nuxt/ui/input-menu.ts +2 -23
- package/.nuxt/ui/input-number.ts +2 -23
- package/.nuxt/ui/input.ts +2 -23
- package/.nuxt/ui/kbd.ts +2 -23
- package/.nuxt/ui/link.ts +2 -23
- package/.nuxt/ui/modal.ts +2 -23
- package/.nuxt/ui/navigation-menu.ts +3 -24
- package/.nuxt/ui/pagination.ts +2 -23
- package/.nuxt/ui/pin-input.ts +2 -23
- package/.nuxt/ui/popover.ts +2 -23
- package/.nuxt/ui/progress.ts +2 -23
- package/.nuxt/ui/radio-group.ts +2 -23
- package/.nuxt/ui/select-menu.ts +2 -23
- package/.nuxt/ui/select.ts +2 -23
- package/.nuxt/ui/separator.ts +2 -23
- package/.nuxt/ui/skeleton.ts +2 -23
- package/.nuxt/ui/slideover.ts +2 -23
- package/.nuxt/ui/slider.ts +2 -23
- package/.nuxt/ui/stepper.ts +2 -23
- package/.nuxt/ui/switch.ts +2 -23
- package/.nuxt/ui/table.ts +2 -23
- package/.nuxt/ui/tabs.ts +2 -23
- package/.nuxt/ui/textarea.ts +2 -23
- package/.nuxt/ui/toast.ts +2 -23
- package/.nuxt/ui/toaster.ts +2 -23
- package/.nuxt/ui/tooltip.ts +2 -23
- package/.nuxt/ui/tree.ts +2 -23
- package/.nuxt/ui.css +15 -8
- package/README.md +4 -0
- package/dist/module.json +1 -1
- package/dist/module.mjs +3 -2
- package/dist/runtime/components/Accordion.vue.d.ts +4 -20
- package/dist/runtime/components/Alert.vue.d.ts +7 -22
- package/dist/runtime/components/App.vue.d.ts +2 -2
- package/dist/runtime/components/Avatar.vue.d.ts +4 -25
- package/dist/runtime/components/AvatarGroup.vue.d.ts +2 -11
- package/dist/runtime/components/Badge.vue.d.ts +3 -24
- package/dist/runtime/components/Breadcrumb.vue.d.ts +2 -20
- package/dist/runtime/components/Button.vue.d.ts +3 -28
- package/dist/runtime/components/ButtonGroup.vue.d.ts +3 -24
- package/dist/runtime/components/Calendar.vue.d.ts +6 -2
- package/dist/runtime/components/Card.vue.d.ts +2 -11
- package/dist/runtime/components/Carousel.vue.d.ts +4 -2
- package/dist/runtime/components/Checkbox.vue.d.ts +10 -13
- package/dist/runtime/components/CheckboxGroup.vue.d.ts +5 -2
- package/dist/runtime/components/Chip.vue.d.ts +10 -24
- package/dist/runtime/components/Collapsible.vue.d.ts +7 -22
- package/dist/runtime/components/ColorPicker.vue.d.ts +9 -24
- package/dist/runtime/components/CommandPalette.vue.d.ts +15 -27
- package/dist/runtime/components/Container.vue.d.ts +2 -11
- package/dist/runtime/components/ContextMenu.vue.d.ts +4 -24
- package/dist/runtime/components/ContextMenuContent.vue.d.ts +17 -57
- package/dist/runtime/components/Drawer.vue.d.ts +17 -27
- package/dist/runtime/components/DropdownMenu.vue.d.ts +4 -28
- package/dist/runtime/components/DropdownMenuContent.vue.d.ts +19 -6
- package/dist/runtime/components/Form.vue.d.ts +5 -2
- package/dist/runtime/components/FormField.vue.d.ts +2 -11
- package/dist/runtime/components/Icon.vue.d.ts +1 -10
- package/dist/runtime/components/Input.vue.d.ts +16 -31
- package/dist/runtime/components/InputMenu.vue.d.ts +17 -5
- package/dist/runtime/components/InputNumber.vue.d.ts +12 -23
- package/dist/runtime/components/Kbd.vue.d.ts +3 -24
- package/dist/runtime/components/Link.vue.d.ts +3 -34
- package/dist/runtime/components/LinkBase.vue.d.ts +4 -27
- package/dist/runtime/components/Modal.vue.d.ts +12 -28
- package/dist/runtime/components/NavigationMenu.vue.d.ts +4 -24
- package/dist/runtime/components/Pagination.vue.d.ts +9 -33
- package/dist/runtime/components/PinInput.vue.d.ts +13 -24
- package/dist/runtime/components/Popover.vue.d.ts +9 -26
- package/dist/runtime/components/Progress.vue.d.ts +10 -41
- package/dist/runtime/components/RadioGroup.vue.d.ts +6 -3
- package/dist/runtime/components/Select.vue.d.ts +8 -2
- package/dist/runtime/components/SelectMenu.vue.d.ts +17 -5
- package/dist/runtime/components/Separator.vue.d.ts +3 -24
- package/dist/runtime/components/Skeleton.vue.d.ts +3 -12
- package/dist/runtime/components/Slideover.vue.d.ts +12 -29
- package/dist/runtime/components/Slider.vue.d.ts +12 -31
- package/dist/runtime/components/Stepper.vue.d.ts +8 -14
- package/dist/runtime/components/Switch.vue.d.ts +10 -13
- package/dist/runtime/components/Table.vue.d.ts +17 -17
- package/dist/runtime/components/Tabs.vue.d.ts +4 -20
- package/dist/runtime/components/Textarea.vue.d.ts +16 -33
- package/dist/runtime/components/Toast.vue.d.ts +86 -24
- package/dist/runtime/components/Toaster.vue.d.ts +3 -28
- package/dist/runtime/components/Tooltip.vue.d.ts +7 -22
- package/dist/runtime/components/Tree.vue.d.ts +5 -22
- package/dist/runtime/composables/defineShortcuts.js +6 -0
- package/dist/runtime/composables/useAvatarGroup.d.ts +1 -1
- package/dist/runtime/composables/useButtonGroup.d.ts +1 -1
- package/dist/runtime/composables/useFormField.d.ts +1 -1
- package/dist/runtime/composables/useKbd.d.ts +1 -0
- package/dist/runtime/composables/useKbd.js +4 -3
- package/dist/runtime/composables/useOverlay.d.ts +9 -10
- package/dist/runtime/composables/useOverlay.js +11 -6
- package/dist/runtime/inertia/components/Link.vue.d.ts +3 -32
- package/dist/runtime/types/tv.d.ts +53 -0
- package/dist/runtime/types/tv.js +0 -0
- package/dist/runtime/types/utils.d.ts +2 -52
- package/dist/runtime/types/utils.js +1 -0
- package/dist/runtime/vue/components/Icon.vue.d.ts +1 -10
- package/dist/runtime/vue/components/Link.vue.d.ts +3 -34
- package/dist/shared/{ui.D7lOOabO.mjs → ui.CbtTMMzt.mjs} +17 -11
- package/dist/unplugin.d.mts +2 -2
- package/dist/unplugin.mjs +1 -1
- package/dist/vite.d.mts +1 -1
- package/dist/vite.mjs +2 -2
- package/package.json +14 -13
|
@@ -51,22 +51,19 @@ export interface SwitchSlots {
|
|
|
51
51
|
description?: string;
|
|
52
52
|
}): any;
|
|
53
53
|
}
|
|
54
|
-
declare const _default:
|
|
54
|
+
declare const _default: __VLS_WithSlots<import("vue").DefineComponent<SwitchProps & {
|
|
55
55
|
modelValue?: boolean;
|
|
56
|
-
}
|
|
56
|
+
}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
57
|
+
change: (payload: Event) => any;
|
|
58
|
+
"update:modelValue": (value: boolean) => any;
|
|
59
|
+
}, string, import("vue").PublicProps, Readonly<SwitchProps & {
|
|
57
60
|
modelValue?: boolean;
|
|
58
|
-
} &
|
|
61
|
+
}> & Readonly<{
|
|
62
|
+
onChange?: ((payload: Event) => any) | undefined;
|
|
63
|
+
"onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
|
|
64
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, SwitchSlots>;
|
|
59
65
|
export default _default;
|
|
60
|
-
type
|
|
61
|
-
type __VLS_TypePropsToOption<T> = {
|
|
62
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
63
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
64
|
-
} : {
|
|
65
|
-
type: import('vue').PropType<T[K]>;
|
|
66
|
-
required: true;
|
|
67
|
-
};
|
|
68
|
-
};
|
|
69
|
-
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
66
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
70
67
|
new (): {
|
|
71
68
|
$slots: S;
|
|
72
69
|
};
|
|
@@ -138,7 +138,21 @@ export type TableSlots<T> = {
|
|
|
138
138
|
caption: (props?: {}) => any;
|
|
139
139
|
} & DynamicHeaderSlots<T> & DynamicCellSlots<T>;
|
|
140
140
|
declare const _default: <T extends TableData>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
141
|
-
props: __VLS_PrettifyLocal<
|
|
141
|
+
props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
|
|
142
|
+
readonly "onUpdate:globalFilter"?: ((value: string) => any) | undefined;
|
|
143
|
+
readonly "onUpdate:columnFilters"?: ((value: ColumnFiltersState) => any) | undefined;
|
|
144
|
+
readonly "onUpdate:columnOrder"?: ((value: ColumnOrderState) => any) | undefined;
|
|
145
|
+
readonly "onUpdate:columnVisibility"?: ((value: VisibilityState) => any) | undefined;
|
|
146
|
+
readonly "onUpdate:columnPinning"?: ((value: ColumnPinningState) => any) | undefined;
|
|
147
|
+
readonly "onUpdate:columnSizing"?: ((value: ColumnSizingState) => any) | undefined;
|
|
148
|
+
readonly "onUpdate:columnSizingInfo"?: ((value: ColumnSizingInfoState) => any) | undefined;
|
|
149
|
+
readonly "onUpdate:rowSelection"?: ((value: RowSelectionState) => any) | undefined;
|
|
150
|
+
readonly "onUpdate:rowPinning"?: ((value: RowPinningState) => any) | undefined;
|
|
151
|
+
readonly "onUpdate:sorting"?: ((value: SortingState) => any) | undefined;
|
|
152
|
+
readonly "onUpdate:grouping"?: ((value: GroupingState) => any) | undefined;
|
|
153
|
+
readonly "onUpdate:expanded"?: ((value: ExpandedState) => any) | undefined;
|
|
154
|
+
readonly "onUpdate:pagination"?: ((value: PaginationState) => any) | undefined;
|
|
155
|
+
} & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, never>, "onUpdate:globalFilter" | "onUpdate:columnFilters" | "onUpdate:columnOrder" | "onUpdate:columnVisibility" | "onUpdate:columnPinning" | "onUpdate:columnSizing" | "onUpdate:columnSizingInfo" | "onUpdate:rowSelection" | "onUpdate:rowPinning" | "onUpdate:sorting" | "onUpdate:grouping" | "onUpdate:expanded" | "onUpdate:pagination"> & (TableProps<T> & {
|
|
142
156
|
globalFilter?: string;
|
|
143
157
|
columnFilters?: ColumnFiltersState;
|
|
144
158
|
columnOrder?: ColumnOrderState;
|
|
@@ -152,27 +166,13 @@ declare const _default: <T extends TableData>(__VLS_props: NonNullable<Awaited<t
|
|
|
152
166
|
grouping?: GroupingState;
|
|
153
167
|
expanded?: ExpandedState;
|
|
154
168
|
pagination?: PaginationState;
|
|
155
|
-
}
|
|
169
|
+
}) & Partial<{}>> & import("vue").PublicProps;
|
|
156
170
|
expose(exposed: import("vue").ShallowUnwrapRef<{
|
|
157
171
|
tableRef: Ref<HTMLTableElement | undefined, HTMLTableElement | undefined>;
|
|
158
172
|
tableApi: import("@tanstack/table-core").Table<T>;
|
|
159
173
|
}>): void;
|
|
160
174
|
attrs: any;
|
|
161
|
-
slots:
|
|
162
|
-
expanded: (props: {
|
|
163
|
-
row: Row<T>;
|
|
164
|
-
}) => any;
|
|
165
|
-
empty: (props?: {}) => any;
|
|
166
|
-
loading: (props?: {}) => any;
|
|
167
|
-
caption: (props?: {}) => any;
|
|
168
|
-
} & Record<string, (props: HeaderContext<T, unknown>) => any> & Record<`${keyof T extends infer T_1 ? T_1 extends keyof T ? T_1 extends string ? T_1 : never : never : never}-header`, (props: HeaderContext<T, unknown>) => any> & Record<string, (props: CellContext<T, unknown>) => any> & Record<`${keyof T extends infer T_2 ? T_2 extends keyof T ? T_2 extends string ? T_2 : never : never : never}-cell`, (props: CellContext<T, unknown>) => any>> & {
|
|
169
|
-
expanded: (props: {
|
|
170
|
-
row: Row<T>;
|
|
171
|
-
}) => any;
|
|
172
|
-
empty: (props?: {}) => any;
|
|
173
|
-
loading: (props?: {}) => any;
|
|
174
|
-
caption: (props?: {}) => any;
|
|
175
|
-
} & Record<string, (props: HeaderContext<T, unknown>) => any> & Record<`${keyof T extends infer T_3 ? T_3 extends keyof T ? T_3 extends string ? T_3 : never : never : never}-header`, (props: HeaderContext<T, unknown>) => any> & Record<string, (props: CellContext<T, unknown>) => any> & Record<`${keyof T extends infer T_4 ? T_4 extends keyof T ? T_4 extends string ? T_4 : never : never : never}-cell`, (props: CellContext<T, unknown>) => any>;
|
|
175
|
+
slots: TableSlots<T>;
|
|
176
176
|
emit: ((evt: "update:globalFilter", value: string) => void) & ((evt: "update:columnFilters", value: ColumnFiltersState) => void) & ((evt: "update:columnOrder", value: ColumnOrderState) => void) & ((evt: "update:columnVisibility", value: VisibilityState) => void) & ((evt: "update:columnPinning", value: ColumnPinningState) => void) & ((evt: "update:columnSizing", value: ColumnSizingState) => void) & ((evt: "update:columnSizingInfo", value: ColumnSizingInfoState) => void) & ((evt: "update:rowSelection", value: RowSelectionState) => void) & ((evt: "update:rowPinning", value: RowPinningState) => void) & ((evt: "update:sorting", value: SortingState) => void) & ((evt: "update:grouping", value: GroupingState) => void) & ((evt: "update:expanded", value: ExpandedState) => void) & ((evt: "update:pagination", value: PaginationState) => void);
|
|
177
177
|
}>) => import("vue").VNode & {
|
|
178
178
|
__ctx?: Awaited<typeof __VLS_setup>;
|
|
@@ -72,28 +72,12 @@ export type TabsSlots<T extends TabsItem = TabsItem> = {
|
|
|
72
72
|
index: number;
|
|
73
73
|
}>;
|
|
74
74
|
declare const _default: <T extends TabsItem>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
75
|
-
props: __VLS_PrettifyLocal<
|
|
75
|
+
props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
|
|
76
|
+
readonly "onUpdate:modelValue"?: ((payload: string | number) => any) | undefined;
|
|
77
|
+
} & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, never>, "onUpdate:modelValue"> & TabsProps<T> & Partial<{}>> & import("vue").PublicProps;
|
|
76
78
|
expose(exposed: import("vue").ShallowUnwrapRef<{}>): void;
|
|
77
79
|
attrs: any;
|
|
78
|
-
slots:
|
|
79
|
-
leading: SlotProps<T>;
|
|
80
|
-
default: SlotProps<T>;
|
|
81
|
-
trailing: SlotProps<T>;
|
|
82
|
-
content: SlotProps<T>;
|
|
83
|
-
'list-leading': (props?: {}) => any;
|
|
84
|
-
'list-trailing': (props?: {}) => any;
|
|
85
|
-
} & DynamicSlots<T, undefined, {
|
|
86
|
-
index: number;
|
|
87
|
-
}>> & {
|
|
88
|
-
leading: SlotProps<T>;
|
|
89
|
-
default: SlotProps<T>;
|
|
90
|
-
trailing: SlotProps<T>;
|
|
91
|
-
content: SlotProps<T>;
|
|
92
|
-
'list-leading': (props?: {}) => any;
|
|
93
|
-
'list-trailing': (props?: {}) => any;
|
|
94
|
-
} & DynamicSlots<T, undefined, {
|
|
95
|
-
index: number;
|
|
96
|
-
}>;
|
|
80
|
+
slots: TabsSlots<T>;
|
|
97
81
|
emit: (evt: "update:modelValue", payload: string | number) => void;
|
|
98
82
|
}>) => import("vue").VNode & {
|
|
99
83
|
__ctx?: Awaited<typeof __VLS_setup>;
|
|
@@ -48,48 +48,31 @@ export interface TextareaSlots {
|
|
|
48
48
|
default(props?: {}): any;
|
|
49
49
|
trailing(props?: {}): any;
|
|
50
50
|
}
|
|
51
|
-
declare const _default:
|
|
51
|
+
declare const _default: __VLS_WithSlots<import("vue").DefineComponent<TextareaProps & {
|
|
52
52
|
modelValue?: string | number | null;
|
|
53
|
-
}
|
|
54
|
-
rows: number;
|
|
55
|
-
maxrows: number;
|
|
56
|
-
autofocusDelay: number;
|
|
57
|
-
autoresizeDelay: number;
|
|
58
|
-
}>>, {
|
|
53
|
+
}, {
|
|
59
54
|
textareaRef: import("vue").Ref<HTMLTextAreaElement | null, HTMLTextAreaElement | null>;
|
|
60
|
-
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
55
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
56
|
+
"update:modelValue": (value: string | number | null | undefined) => any;
|
|
57
|
+
} & {
|
|
58
|
+
blur: (event: FocusEvent) => any;
|
|
59
|
+
change: (event: Event) => any;
|
|
60
|
+
"update:modelValue": (payload: string | number) => any;
|
|
61
|
+
}, string, import("vue").PublicProps, Readonly<TextareaProps & {
|
|
61
62
|
modelValue?: string | number | null;
|
|
62
|
-
} &
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
}>>> & Readonly<{}>, {
|
|
63
|
+
}> & Readonly<{
|
|
64
|
+
onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
65
|
+
onChange?: ((event: Event) => any) | undefined;
|
|
66
|
+
"onUpdate:modelValue"?: ((payload: string | number) => any) | undefined;
|
|
67
|
+
}>, {
|
|
68
68
|
autofocusDelay: number;
|
|
69
69
|
autoresizeDelay: number;
|
|
70
70
|
rows: number;
|
|
71
71
|
maxrows: number;
|
|
72
|
-
}, {}, {}, {}, string, import("vue").ComponentProvideOptions,
|
|
72
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, TextareaSlots>;
|
|
73
73
|
export default _default;
|
|
74
|
-
type
|
|
75
|
-
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_PrettifyLocal<P[K] & {
|
|
76
|
-
default: D[K];
|
|
77
|
-
}> : P[K];
|
|
78
|
-
};
|
|
79
|
-
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
80
|
-
type __VLS_TypePropsToOption<T> = {
|
|
81
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
82
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
83
|
-
} : {
|
|
84
|
-
type: import('vue').PropType<T[K]>;
|
|
85
|
-
required: true;
|
|
86
|
-
};
|
|
87
|
-
};
|
|
88
|
-
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
74
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
89
75
|
new (): {
|
|
90
76
|
$slots: S;
|
|
91
77
|
};
|
|
92
78
|
};
|
|
93
|
-
type __VLS_PrettifyLocal<T> = {
|
|
94
|
-
[K in keyof T]: T[K];
|
|
95
|
-
} & {};
|
|
@@ -61,35 +61,97 @@ export interface ToastSlots {
|
|
|
61
61
|
};
|
|
62
62
|
}): any;
|
|
63
63
|
}
|
|
64
|
-
declare const _default:
|
|
65
|
-
close: boolean;
|
|
66
|
-
orientation: string;
|
|
67
|
-
}>>, {
|
|
64
|
+
declare const _default: __VLS_WithSlots<import("vue").DefineComponent<ToastProps, {
|
|
68
65
|
height: import("vue").Ref<number, number>;
|
|
69
|
-
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin,
|
|
66
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
67
|
+
resume: () => any;
|
|
68
|
+
pause: () => any;
|
|
69
|
+
"update:open": (value: boolean) => any;
|
|
70
|
+
escapeKeyDown: (event: KeyboardEvent) => any;
|
|
71
|
+
swipeStart: (event: {
|
|
72
|
+
currentTarget: EventTarget & HTMLElement;
|
|
73
|
+
} & Omit<CustomEvent<{
|
|
74
|
+
originalEvent: PointerEvent;
|
|
75
|
+
delta: {
|
|
76
|
+
x: number;
|
|
77
|
+
y: number;
|
|
78
|
+
};
|
|
79
|
+
}>, "currentTarget">) => any;
|
|
80
|
+
swipeMove: (event: {
|
|
81
|
+
currentTarget: EventTarget & HTMLElement;
|
|
82
|
+
} & Omit<CustomEvent<{
|
|
83
|
+
originalEvent: PointerEvent;
|
|
84
|
+
delta: {
|
|
85
|
+
x: number;
|
|
86
|
+
y: number;
|
|
87
|
+
};
|
|
88
|
+
}>, "currentTarget">) => any;
|
|
89
|
+
swipeCancel: (event: {
|
|
90
|
+
currentTarget: EventTarget & HTMLElement;
|
|
91
|
+
} & Omit<CustomEvent<{
|
|
92
|
+
originalEvent: PointerEvent;
|
|
93
|
+
delta: {
|
|
94
|
+
x: number;
|
|
95
|
+
y: number;
|
|
96
|
+
};
|
|
97
|
+
}>, "currentTarget">) => any;
|
|
98
|
+
swipeEnd: (event: {
|
|
99
|
+
currentTarget: EventTarget & HTMLElement;
|
|
100
|
+
} & Omit<CustomEvent<{
|
|
101
|
+
originalEvent: PointerEvent;
|
|
102
|
+
delta: {
|
|
103
|
+
x: number;
|
|
104
|
+
y: number;
|
|
105
|
+
};
|
|
106
|
+
}>, "currentTarget">) => any;
|
|
107
|
+
}, string, import("vue").PublicProps, Readonly<ToastProps> & Readonly<{
|
|
108
|
+
onResume?: (() => any) | undefined;
|
|
109
|
+
onPause?: (() => any) | undefined;
|
|
110
|
+
"onUpdate:open"?: ((value: boolean) => any) | undefined;
|
|
111
|
+
onEscapeKeyDown?: ((event: KeyboardEvent) => any) | undefined;
|
|
112
|
+
onSwipeStart?: ((event: {
|
|
113
|
+
currentTarget: EventTarget & HTMLElement;
|
|
114
|
+
} & Omit<CustomEvent<{
|
|
115
|
+
originalEvent: PointerEvent;
|
|
116
|
+
delta: {
|
|
117
|
+
x: number;
|
|
118
|
+
y: number;
|
|
119
|
+
};
|
|
120
|
+
}>, "currentTarget">) => any) | undefined;
|
|
121
|
+
onSwipeMove?: ((event: {
|
|
122
|
+
currentTarget: EventTarget & HTMLElement;
|
|
123
|
+
} & Omit<CustomEvent<{
|
|
124
|
+
originalEvent: PointerEvent;
|
|
125
|
+
delta: {
|
|
126
|
+
x: number;
|
|
127
|
+
y: number;
|
|
128
|
+
};
|
|
129
|
+
}>, "currentTarget">) => any) | undefined;
|
|
130
|
+
onSwipeCancel?: ((event: {
|
|
131
|
+
currentTarget: EventTarget & HTMLElement;
|
|
132
|
+
} & Omit<CustomEvent<{
|
|
133
|
+
originalEvent: PointerEvent;
|
|
134
|
+
delta: {
|
|
135
|
+
x: number;
|
|
136
|
+
y: number;
|
|
137
|
+
};
|
|
138
|
+
}>, "currentTarget">) => any) | undefined;
|
|
139
|
+
onSwipeEnd?: ((event: {
|
|
140
|
+
currentTarget: EventTarget & HTMLElement;
|
|
141
|
+
} & Omit<CustomEvent<{
|
|
142
|
+
originalEvent: PointerEvent;
|
|
143
|
+
delta: {
|
|
144
|
+
x: number;
|
|
145
|
+
y: number;
|
|
146
|
+
};
|
|
147
|
+
}>, "currentTarget">) => any) | undefined;
|
|
148
|
+
}>, {
|
|
70
149
|
close: boolean | Partial<ButtonProps>;
|
|
71
150
|
orientation: Toast["variants"]["orientation"];
|
|
72
|
-
}, {}, {}, {}, string, import("vue").ComponentProvideOptions,
|
|
151
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, ToastSlots>;
|
|
73
152
|
export default _default;
|
|
74
|
-
type
|
|
75
|
-
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_PrettifyLocal<P[K] & {
|
|
76
|
-
default: D[K];
|
|
77
|
-
}> : P[K];
|
|
78
|
-
};
|
|
79
|
-
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
80
|
-
type __VLS_TypePropsToOption<T> = {
|
|
81
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
82
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
83
|
-
} : {
|
|
84
|
-
type: import('vue').PropType<T[K]>;
|
|
85
|
-
required: true;
|
|
86
|
-
};
|
|
87
|
-
};
|
|
88
|
-
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
153
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
89
154
|
new (): {
|
|
90
155
|
$slots: S;
|
|
91
156
|
};
|
|
92
157
|
};
|
|
93
|
-
type __VLS_PrettifyLocal<T> = {
|
|
94
|
-
[K in keyof T]: T[K];
|
|
95
|
-
} & {};
|
|
@@ -25,39 +25,14 @@ export interface ToasterProps extends Omit<ToastProviderProps, 'swipeDirection'>
|
|
|
25
25
|
export interface ToasterSlots {
|
|
26
26
|
default(props?: {}): any;
|
|
27
27
|
}
|
|
28
|
-
declare const _default:
|
|
29
|
-
expand: boolean;
|
|
30
|
-
portal: boolean;
|
|
31
|
-
duration: number;
|
|
32
|
-
}>>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToOption<ToasterProps>, {
|
|
33
|
-
expand: boolean;
|
|
34
|
-
portal: boolean;
|
|
35
|
-
duration: number;
|
|
36
|
-
}>>> & Readonly<{}>, {
|
|
28
|
+
declare const _default: __VLS_WithSlots<import("vue").DefineComponent<ToasterProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<ToasterProps> & Readonly<{}>, {
|
|
37
29
|
duration: number;
|
|
38
30
|
expand: boolean;
|
|
39
31
|
portal: boolean | string | HTMLElement;
|
|
40
|
-
}, {}, {}, {}, string, import("vue").ComponentProvideOptions,
|
|
32
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, ToasterSlots>;
|
|
41
33
|
export default _default;
|
|
42
|
-
type
|
|
43
|
-
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_PrettifyLocal<P[K] & {
|
|
44
|
-
default: D[K];
|
|
45
|
-
}> : P[K];
|
|
46
|
-
};
|
|
47
|
-
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
48
|
-
type __VLS_TypePropsToOption<T> = {
|
|
49
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
50
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
51
|
-
} : {
|
|
52
|
-
type: import('vue').PropType<T[K]>;
|
|
53
|
-
required: true;
|
|
54
|
-
};
|
|
55
|
-
};
|
|
56
|
-
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
34
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
57
35
|
new (): {
|
|
58
36
|
$slots: S;
|
|
59
37
|
};
|
|
60
38
|
};
|
|
61
|
-
type __VLS_PrettifyLocal<T> = {
|
|
62
|
-
[K in keyof T]: T[K];
|
|
63
|
-
} & {};
|
|
@@ -35,31 +35,16 @@ export interface TooltipSlots {
|
|
|
35
35
|
}): any;
|
|
36
36
|
content(props?: {}): any;
|
|
37
37
|
}
|
|
38
|
-
declare const _default:
|
|
39
|
-
|
|
40
|
-
}
|
|
38
|
+
declare const _default: __VLS_WithSlots<import("vue").DefineComponent<TooltipProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
39
|
+
"update:open": (value: boolean) => any;
|
|
40
|
+
}, string, import("vue").PublicProps, Readonly<TooltipProps> & Readonly<{
|
|
41
|
+
"onUpdate:open"?: ((value: boolean) => any) | undefined;
|
|
42
|
+
}>, {
|
|
41
43
|
portal: boolean | string | HTMLElement;
|
|
42
|
-
}, {}, {}, {}, string, import("vue").ComponentProvideOptions,
|
|
44
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, TooltipSlots>;
|
|
43
45
|
export default _default;
|
|
44
|
-
type
|
|
45
|
-
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_PrettifyLocal<P[K] & {
|
|
46
|
-
default: D[K];
|
|
47
|
-
}> : P[K];
|
|
48
|
-
};
|
|
49
|
-
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
50
|
-
type __VLS_TypePropsToOption<T> = {
|
|
51
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
52
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
53
|
-
} : {
|
|
54
|
-
type: import('vue').PropType<T[K]>;
|
|
55
|
-
required: true;
|
|
56
|
-
};
|
|
57
|
-
};
|
|
58
|
-
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
46
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
59
47
|
new (): {
|
|
60
48
|
$slots: S;
|
|
61
49
|
};
|
|
62
50
|
};
|
|
63
|
-
type __VLS_PrettifyLocal<T> = {
|
|
64
|
-
[K in keyof T]: T[K];
|
|
65
|
-
} & {};
|
|
@@ -94,30 +94,13 @@ export type TreeSlots<A extends TreeItem[] = TreeItem[], T extends NestedItem<A>
|
|
|
94
94
|
selected: boolean;
|
|
95
95
|
}>;
|
|
96
96
|
declare const _default: <T extends TreeItem[], VK extends GetItemKeys<T> = "value", M extends boolean = false>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
97
|
-
props: __VLS_PrettifyLocal<
|
|
97
|
+
props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
|
|
98
|
+
readonly "onUpdate:modelValue"?: ((payload: GetModelValue<T, VK, M>) => any) | undefined;
|
|
99
|
+
readonly "onUpdate:expanded"?: ((val: string[]) => any) | undefined;
|
|
100
|
+
} & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, never>, "onUpdate:modelValue" | "onUpdate:expanded"> & TreeProps<T, VK, M> & Partial<{}>> & import("vue").PublicProps;
|
|
98
101
|
expose(exposed: import("vue").ShallowUnwrapRef<{}>): void;
|
|
99
102
|
attrs: any;
|
|
100
|
-
slots:
|
|
101
|
-
item: SlotProps<NestedItem<T>>;
|
|
102
|
-
'item-leading': SlotProps<NestedItem<T>>;
|
|
103
|
-
'item-label': SlotProps<NestedItem<T>>;
|
|
104
|
-
'item-trailing': SlotProps<NestedItem<T>>;
|
|
105
|
-
} & DynamicSlots<NestedItem<T>, undefined, {
|
|
106
|
-
index: number;
|
|
107
|
-
level: number;
|
|
108
|
-
expanded: boolean;
|
|
109
|
-
selected: boolean;
|
|
110
|
-
}>> & {
|
|
111
|
-
item: SlotProps<NestedItem<T>>;
|
|
112
|
-
'item-leading': SlotProps<NestedItem<T>>;
|
|
113
|
-
'item-label': SlotProps<NestedItem<T>>;
|
|
114
|
-
'item-trailing': SlotProps<NestedItem<T>>;
|
|
115
|
-
} & DynamicSlots<NestedItem<T>, undefined, {
|
|
116
|
-
index: number;
|
|
117
|
-
level: number;
|
|
118
|
-
expanded: boolean;
|
|
119
|
-
selected: boolean;
|
|
120
|
-
}>;
|
|
103
|
+
slots: TreeSlots<T, NestedItem<T>>;
|
|
121
104
|
emit: ((evt: "update:modelValue", payload: GetModelValue<T, VK, M>) => void) & ((evt: "update:expanded", val: string[]) => void);
|
|
122
105
|
}>) => import("vue").VNode & {
|
|
123
106
|
__ctx?: Awaited<typeof __VLS_setup>;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ref, computed, toValue } from "vue";
|
|
2
2
|
import { useEventListener, useActiveElement, useDebounceFn } from "@vueuse/core";
|
|
3
|
+
import { useKbd } from "./useKbd.js";
|
|
3
4
|
const chainedShortcutRegex = /^[^-]+.*-.*[^-]+$/;
|
|
4
5
|
const combinedShortcutRegex = /^[^_]+.*_.*[^_]+$/;
|
|
5
6
|
export function extractShortcuts(items) {
|
|
@@ -27,6 +28,7 @@ export function defineShortcuts(config, options = {}) {
|
|
|
27
28
|
chainedInputs.value.splice(0, chainedInputs.value.length);
|
|
28
29
|
};
|
|
29
30
|
const debouncedClearChainedInput = useDebounceFn(clearChainedInput, options.chainDelay ?? 800);
|
|
31
|
+
const { macOS } = useKbd();
|
|
30
32
|
const activeElement = useActiveElement();
|
|
31
33
|
const onKeyDown = (e) => {
|
|
32
34
|
if (!e.key) {
|
|
@@ -112,6 +114,10 @@ export function defineShortcuts(config, options = {}) {
|
|
|
112
114
|
};
|
|
113
115
|
}
|
|
114
116
|
shortcut.chained = chained;
|
|
117
|
+
if (!macOS.value && shortcut.metaKey && !shortcut.ctrlKey) {
|
|
118
|
+
shortcut.metaKey = false;
|
|
119
|
+
shortcut.ctrlKey = true;
|
|
120
|
+
}
|
|
115
121
|
if (typeof shortcutConfig === "function") {
|
|
116
122
|
shortcut.handler = shortcutConfig;
|
|
117
123
|
} else if (typeof shortcutConfig === "object") {
|
|
@@ -6,5 +6,5 @@ export declare const avatarGroupInjectionKey: InjectionKey<ComputedRef<{
|
|
|
6
6
|
export declare function useAvatarGroup(props: {
|
|
7
7
|
size: AvatarGroupProps['size'];
|
|
8
8
|
}): {
|
|
9
|
-
size: ComputedRef<"
|
|
9
|
+
size: ComputedRef<"3xs" | "2xs" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | undefined>;
|
|
10
10
|
};
|
|
@@ -10,6 +10,6 @@ type Props<T> = {
|
|
|
10
10
|
};
|
|
11
11
|
export declare function useButtonGroup<T>(props: Props<T>): {
|
|
12
12
|
orientation: ComputedRef<"horizontal" | "vertical" | undefined>;
|
|
13
|
-
size: ComputedRef<"
|
|
13
|
+
size: ComputedRef<"xs" | "sm" | "md" | "lg" | "xl" | NonNullable<GetObjectField<T, "size">> | undefined>;
|
|
14
14
|
};
|
|
15
15
|
export {};
|
|
@@ -26,7 +26,7 @@ export declare function useFormField<T>(props?: Props<T>, opts?: {
|
|
|
26
26
|
}): {
|
|
27
27
|
id: ComputedRef<string | undefined>;
|
|
28
28
|
name: ComputedRef<string | undefined>;
|
|
29
|
-
size: ComputedRef<"
|
|
29
|
+
size: ComputedRef<"xs" | "sm" | "md" | "lg" | "xl" | NonNullable<GetObjectField<T, "size">> | undefined>;
|
|
30
30
|
color: ComputedRef<"error" | GetObjectField<T, "color"> | undefined>;
|
|
31
31
|
highlight: ComputedRef<boolean | undefined>;
|
|
32
32
|
disabled: ComputedRef<boolean | undefined>;
|
|
@@ -7,6 +7,7 @@ export const kbdKeysMap = {
|
|
|
7
7
|
win: "\u229E",
|
|
8
8
|
command: "\u2318",
|
|
9
9
|
shift: "\u21E7",
|
|
10
|
+
control: "\u2303",
|
|
10
11
|
option: "\u2325",
|
|
11
12
|
enter: "\u21B5",
|
|
12
13
|
delete: "\u2326",
|
|
@@ -31,9 +32,9 @@ const _useKbd = () => {
|
|
|
31
32
|
ctrl: " "
|
|
32
33
|
});
|
|
33
34
|
onMounted(() => {
|
|
34
|
-
kbdKeysSpecificMap.meta = macOS.value ? kbdKeysMap.command :
|
|
35
|
-
kbdKeysSpecificMap.
|
|
36
|
-
kbdKeysSpecificMap.
|
|
35
|
+
kbdKeysSpecificMap.meta = macOS.value ? kbdKeysMap.command : "Ctrl";
|
|
36
|
+
kbdKeysSpecificMap.ctrl = macOS.value ? kbdKeysMap.control : "Ctrl";
|
|
37
|
+
kbdKeysSpecificMap.alt = macOS.value ? kbdKeysMap.option : "Alt";
|
|
37
38
|
});
|
|
38
39
|
function getKbdKey(value) {
|
|
39
40
|
if (!value) {
|
|
@@ -14,25 +14,24 @@ interface ManagedOverlayOptionsPrivate<T extends Component> {
|
|
|
14
14
|
resolvePromise?: (value: any) => void;
|
|
15
15
|
}
|
|
16
16
|
export type Overlay = OverlayOptions<Component> & ManagedOverlayOptionsPrivate<Component>;
|
|
17
|
-
|
|
17
|
+
type OverlayInstance<T extends Component> = Omit<ManagedOverlayOptionsPrivate<T>, 'component'> & {
|
|
18
18
|
id: symbol;
|
|
19
|
-
|
|
20
|
-
open: (props?: ComponentProps<T>) => Omit<OverlayInstance<T>, 'open' | 'close' | 'patch' | 'modelValue' | 'resolvePromise'>;
|
|
19
|
+
open: (props?: ComponentProps<T>) => OpenedOverlay<T>;
|
|
21
20
|
close: (value?: any) => void;
|
|
22
21
|
patch: (props: Partial<ComponentProps<T>>) => void;
|
|
23
|
-
}
|
|
22
|
+
};
|
|
23
|
+
type OpenedOverlay<T extends Component> = Omit<OverlayInstance<T>, 'open' | 'close' | 'patch' | 'modelValue' | 'resolvePromise'> & {
|
|
24
|
+
result: Promise<CloseEventArgType<ComponentEmit<T>>>;
|
|
25
|
+
};
|
|
24
26
|
declare function _useOverlay(): {
|
|
25
27
|
overlays: import("vue").ShallowReactive<Overlay[]>;
|
|
26
|
-
open: <T extends Component>(id: symbol, props?: ComponentProps<T>) =>
|
|
27
|
-
id: symbol;
|
|
28
|
-
isMounted: boolean;
|
|
29
|
-
isOpen: boolean;
|
|
30
|
-
result: Promise<any>;
|
|
31
|
-
};
|
|
28
|
+
open: <T extends Component>(id: symbol, props?: ComponentProps<T>) => OpenedOverlay<T>;
|
|
32
29
|
close: (id: symbol, value?: any) => void;
|
|
30
|
+
closeAll: () => void;
|
|
33
31
|
create: <T extends Component>(component: T, _options?: OverlayOptions<ComponentProps<T>>) => OverlayInstance<T>;
|
|
34
32
|
patch: <T extends Component>(id: symbol, props: Partial<ComponentProps<T>>) => void;
|
|
35
33
|
unMount: (id: symbol) => void;
|
|
34
|
+
isOpen: (id: symbol) => boolean;
|
|
36
35
|
};
|
|
37
36
|
export declare const useOverlay: typeof _useOverlay;
|
|
38
37
|
export {};
|
|
@@ -15,8 +15,6 @@ function _useOverlay() {
|
|
|
15
15
|
overlays.push(options);
|
|
16
16
|
return {
|
|
17
17
|
...options,
|
|
18
|
-
result: new Promise(() => {
|
|
19
|
-
}),
|
|
20
18
|
open: (props2) => open(options.id, props2),
|
|
21
19
|
close: (value) => close(options.id, value),
|
|
22
20
|
patch: (props2) => patch(options.id, props2)
|
|
@@ -33,9 +31,7 @@ function _useOverlay() {
|
|
|
33
31
|
id,
|
|
34
32
|
isMounted: overlay.isMounted,
|
|
35
33
|
isOpen: overlay.isOpen,
|
|
36
|
-
result: new Promise((resolve) =>
|
|
37
|
-
overlay.resolvePromise = resolve;
|
|
38
|
-
})
|
|
34
|
+
result: new Promise((resolve) => overlay.resolvePromise = resolve)
|
|
39
35
|
};
|
|
40
36
|
};
|
|
41
37
|
const close = (id, value) => {
|
|
@@ -46,6 +42,9 @@ function _useOverlay() {
|
|
|
46
42
|
overlay.resolvePromise = void 0;
|
|
47
43
|
}
|
|
48
44
|
};
|
|
45
|
+
const closeAll = () => {
|
|
46
|
+
overlays.forEach((overlay) => close(overlay.id));
|
|
47
|
+
};
|
|
49
48
|
const unMount = (id) => {
|
|
50
49
|
const overlay = getOverlay(id);
|
|
51
50
|
overlay.isMounted = false;
|
|
@@ -67,13 +66,19 @@ function _useOverlay() {
|
|
|
67
66
|
}
|
|
68
67
|
return overlay;
|
|
69
68
|
};
|
|
69
|
+
const isOpen = (id) => {
|
|
70
|
+
const overlay = getOverlay(id);
|
|
71
|
+
return overlay.isOpen;
|
|
72
|
+
};
|
|
70
73
|
return {
|
|
71
74
|
overlays,
|
|
72
75
|
open,
|
|
73
76
|
close,
|
|
77
|
+
closeAll,
|
|
74
78
|
create,
|
|
75
79
|
patch,
|
|
76
|
-
unMount
|
|
80
|
+
unMount,
|
|
81
|
+
isOpen
|
|
77
82
|
};
|
|
78
83
|
}
|
|
79
84
|
export const useOverlay = /* @__PURE__ */ createSharedComposable(_useOverlay);
|