@hardimpactdev/craft-ui 0.0.17 → 0.0.22
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/README.md +6 -5
- package/dist/craft-ui.css +1 -1
- package/dist/craft-ui.js +39220 -20421
- package/dist/index.d.ts +2 -0
- package/dist/src/components/ai/index.d.ts +1 -0
- package/dist/src/components/ai/prompt-input/PromptInput.vue.d.ts +69 -0
- package/dist/src/components/ai/prompt-input/PromptInputActionAddAttachments.vue.d.ts +9 -0
- package/dist/src/components/ai/prompt-input/PromptInputActionMenu.vue.d.ts +17 -0
- package/dist/src/components/ai/prompt-input/PromptInputActionMenuContent.vue.d.ts +21 -0
- package/dist/src/components/ai/prompt-input/PromptInputActionMenuItem.vue.d.ts +25 -0
- package/dist/src/components/ai/prompt-input/PromptInputActionMenuTrigger.vue.d.ts +21 -0
- package/dist/src/components/ai/prompt-input/PromptInputAddAttachment.vue.d.ts +30 -0
- package/dist/src/components/ai/prompt-input/PromptInputAttachments.vue.d.ts +6 -0
- package/dist/src/components/ai/prompt-input/PromptInputButton.vue.d.ts +27 -0
- package/dist/src/components/ai/prompt-input/PromptInputFooter.vue.d.ts +21 -0
- package/dist/src/components/ai/prompt-input/PromptInputHeader.vue.d.ts +21 -0
- package/dist/src/components/ai/prompt-input/PromptInputSelect.vue.d.ts +27 -0
- package/dist/src/components/ai/prompt-input/PromptInputSelectContent.vue.d.ts +21 -0
- package/dist/src/components/ai/prompt-input/PromptInputSelectItem.vue.d.ts +22 -0
- package/dist/src/components/ai/prompt-input/PromptInputSelectTrigger.vue.d.ts +21 -0
- package/dist/src/components/ai/prompt-input/PromptInputSubmit.vue.d.ts +33 -0
- package/dist/src/components/ai/prompt-input/PromptInputTextarea.vue.d.ts +10 -0
- package/dist/src/components/ai/prompt-input/PromptInputTools.vue.d.ts +21 -0
- package/dist/src/components/ai/prompt-input/index.d.ts +21 -0
- package/dist/src/components/ai/prompt-input/types.d.ts +27 -0
- package/dist/src/components/ai/prompt-input/usePromptInput.d.ts +5 -0
- package/dist/src/components/editor/Editor.vue.d.ts +20 -0
- package/dist/src/components/editor/EditorBubbleMenu.vue.d.ts +8 -0
- package/dist/src/components/editor/EditorToolbar.vue.d.ts +8 -0
- package/dist/src/components/editor/__tests__/Editor.test.d.ts +1 -0
- package/dist/src/components/editor/index.d.ts +3 -0
- package/dist/src/components/input-group/InputGroupTextarea.vue.d.ts +1 -1
- package/dist/src/components/textarea/Textarea.vue.d.ts +1 -1
- package/package.json +12 -4
package/dist/index.d.ts
CHANGED
|
@@ -55,6 +55,7 @@ export * from './src/components/context-menu';
|
|
|
55
55
|
export * from './src/components/dialog';
|
|
56
56
|
export * from './src/components/drawer';
|
|
57
57
|
export * from './src/components/dropdown-menu';
|
|
58
|
+
export * from './src/components/editor';
|
|
58
59
|
export * from './src/components/empty';
|
|
59
60
|
export * from './src/components/field';
|
|
60
61
|
export * from './src/components/form';
|
|
@@ -94,5 +95,6 @@ export * from './src/components/textarea';
|
|
|
94
95
|
export * from './src/components/toggle';
|
|
95
96
|
export * from './src/components/toggle-group';
|
|
96
97
|
export * from './src/components/tooltip';
|
|
98
|
+
export * from './src/components/ai';
|
|
97
99
|
export * from './src/pages/auth';
|
|
98
100
|
export { i18n, cn, __, can, AuthLayout, AuthSimpleLayout, AuthCardLayout, AuthSplitLayout, AppHeaderLayout, AppSidebarLayout, SettingsLayout, AppShell, AppContent, AppHeader, AppSidebar, AppSidebarHeader, AppLogo, AppLogoIcon, Breadcrumbs, NavMain, NavFooter, NavUser, UserInfo, UserMenuContent, TextLink, InputError, Heading, HeadingSmall, AppearanceTabs, DeleteUser, useAppearance, useAppNavigation, useInitials, useLanguage, };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './prompt-input';
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
import { FileAttachment, PromptInputMessage } from './types';
|
|
3
|
+
type __VLS_Props = {
|
|
4
|
+
class?: HTMLAttributes["class"];
|
|
5
|
+
accept?: string;
|
|
6
|
+
multiple?: boolean;
|
|
7
|
+
maxFiles?: number;
|
|
8
|
+
maxFileSize?: number;
|
|
9
|
+
globalDrop?: boolean;
|
|
10
|
+
};
|
|
11
|
+
declare function __VLS_template(): {
|
|
12
|
+
attrs: Partial<{}>;
|
|
13
|
+
slots: {
|
|
14
|
+
default?(_: {}): any;
|
|
15
|
+
};
|
|
16
|
+
refs: {
|
|
17
|
+
fileInputRef: HTMLInputElement;
|
|
18
|
+
formRef: HTMLFormElement;
|
|
19
|
+
};
|
|
20
|
+
rootEl: HTMLDivElement;
|
|
21
|
+
};
|
|
22
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
23
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {
|
|
24
|
+
inputValue: import('vue').Ref<string, string>;
|
|
25
|
+
attachments: import('vue').Ref<{
|
|
26
|
+
id: string;
|
|
27
|
+
type: "file";
|
|
28
|
+
url: string;
|
|
29
|
+
mediaType: string;
|
|
30
|
+
filename: string;
|
|
31
|
+
size?: number | undefined;
|
|
32
|
+
}[], FileAttachment[] | {
|
|
33
|
+
id: string;
|
|
34
|
+
type: "file";
|
|
35
|
+
url: string;
|
|
36
|
+
mediaType: string;
|
|
37
|
+
filename: string;
|
|
38
|
+
size?: number | undefined;
|
|
39
|
+
}[]>;
|
|
40
|
+
addFiles: (files: File[] | FileList) => void;
|
|
41
|
+
clear: () => void;
|
|
42
|
+
openFileDialog: () => void;
|
|
43
|
+
submit: () => void | undefined;
|
|
44
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
45
|
+
error: (error: {
|
|
46
|
+
code: "max_files" | "max_file_size" | "accept";
|
|
47
|
+
message: string;
|
|
48
|
+
}) => any;
|
|
49
|
+
submit: (message: PromptInputMessage, event: Event) => any;
|
|
50
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
51
|
+
onError?: ((error: {
|
|
52
|
+
code: "max_files" | "max_file_size" | "accept";
|
|
53
|
+
message: string;
|
|
54
|
+
}) => any) | undefined;
|
|
55
|
+
onSubmit?: ((message: PromptInputMessage, event: Event) => any) | undefined;
|
|
56
|
+
}>, {
|
|
57
|
+
multiple: boolean;
|
|
58
|
+
globalDrop: boolean;
|
|
59
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
60
|
+
fileInputRef: HTMLInputElement;
|
|
61
|
+
formRef: HTMLFormElement;
|
|
62
|
+
}, HTMLDivElement>;
|
|
63
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
64
|
+
export default _default;
|
|
65
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
66
|
+
new (): {
|
|
67
|
+
$slots: S;
|
|
68
|
+
};
|
|
69
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
class?: HTMLAttributes["class"];
|
|
4
|
+
label?: string;
|
|
5
|
+
};
|
|
6
|
+
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
7
|
+
label: string;
|
|
8
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
9
|
+
export default _default;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
declare function __VLS_template(): {
|
|
2
|
+
attrs: Partial<{}>;
|
|
3
|
+
slots: {
|
|
4
|
+
default?(_: {}): any;
|
|
5
|
+
};
|
|
6
|
+
refs: {};
|
|
7
|
+
rootEl: any;
|
|
8
|
+
};
|
|
9
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
10
|
+
declare const __VLS_component: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
11
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
12
|
+
export default _default;
|
|
13
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
14
|
+
new (): {
|
|
15
|
+
$slots: S;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
class?: HTMLAttributes["class"];
|
|
4
|
+
};
|
|
5
|
+
declare function __VLS_template(): {
|
|
6
|
+
attrs: Partial<{}>;
|
|
7
|
+
slots: {
|
|
8
|
+
default?(_: {}): any;
|
|
9
|
+
};
|
|
10
|
+
refs: {};
|
|
11
|
+
rootEl: any;
|
|
12
|
+
};
|
|
13
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
14
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
15
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
16
|
+
export default _default;
|
|
17
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
18
|
+
new (): {
|
|
19
|
+
$slots: S;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
class?: HTMLAttributes["class"];
|
|
4
|
+
};
|
|
5
|
+
declare function __VLS_template(): {
|
|
6
|
+
attrs: Partial<{}>;
|
|
7
|
+
slots: {
|
|
8
|
+
default?(_: {}): any;
|
|
9
|
+
};
|
|
10
|
+
refs: {};
|
|
11
|
+
rootEl: any;
|
|
12
|
+
};
|
|
13
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
14
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
15
|
+
select: (event: Event) => any;
|
|
16
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
17
|
+
onSelect?: ((event: Event) => any) | undefined;
|
|
18
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
19
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
20
|
+
export default _default;
|
|
21
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
22
|
+
new (): {
|
|
23
|
+
$slots: S;
|
|
24
|
+
};
|
|
25
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
class?: HTMLAttributes["class"];
|
|
4
|
+
};
|
|
5
|
+
declare function __VLS_template(): {
|
|
6
|
+
attrs: Partial<{}>;
|
|
7
|
+
slots: {
|
|
8
|
+
default?(_: {}): any;
|
|
9
|
+
};
|
|
10
|
+
refs: {};
|
|
11
|
+
rootEl: any;
|
|
12
|
+
};
|
|
13
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
14
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
15
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
16
|
+
export default _default;
|
|
17
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
18
|
+
new (): {
|
|
19
|
+
$slots: S;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
import { InputGroupButtonVariants } from '../../input-group';
|
|
3
|
+
import { ButtonVariants } from '../../button';
|
|
4
|
+
type __VLS_Props = {
|
|
5
|
+
class?: HTMLAttributes["class"];
|
|
6
|
+
variant?: ButtonVariants["variant"];
|
|
7
|
+
size?: InputGroupButtonVariants["size"];
|
|
8
|
+
disabled?: boolean;
|
|
9
|
+
};
|
|
10
|
+
declare function __VLS_template(): {
|
|
11
|
+
attrs: Partial<{}>;
|
|
12
|
+
slots: {
|
|
13
|
+
default?(_: {}): any;
|
|
14
|
+
};
|
|
15
|
+
refs: {};
|
|
16
|
+
rootEl: any;
|
|
17
|
+
};
|
|
18
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
19
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
20
|
+
size: "sm" | "icon-sm" | "xs" | "icon-xs" | null;
|
|
21
|
+
variant: "link" | "default" | "destructive" | "outline" | "secondary" | "ghost" | null;
|
|
22
|
+
disabled: boolean;
|
|
23
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
24
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
25
|
+
export default _default;
|
|
26
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
27
|
+
new (): {
|
|
28
|
+
$slots: S;
|
|
29
|
+
};
|
|
30
|
+
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
class?: HTMLAttributes["class"];
|
|
4
|
+
};
|
|
5
|
+
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
6
|
+
export default _default;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
import { InputGroupButtonVariants } from '../../input-group';
|
|
3
|
+
import { ButtonVariants } from '../../button';
|
|
4
|
+
type __VLS_Props = {
|
|
5
|
+
class?: HTMLAttributes["class"];
|
|
6
|
+
variant?: ButtonVariants["variant"];
|
|
7
|
+
size?: InputGroupButtonVariants["size"];
|
|
8
|
+
};
|
|
9
|
+
declare function __VLS_template(): {
|
|
10
|
+
attrs: Partial<{}>;
|
|
11
|
+
slots: {
|
|
12
|
+
default?(_: {}): any;
|
|
13
|
+
};
|
|
14
|
+
refs: {};
|
|
15
|
+
rootEl: any;
|
|
16
|
+
};
|
|
17
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
18
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
19
|
+
variant: "link" | "default" | "destructive" | "outline" | "secondary" | "ghost" | null;
|
|
20
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
21
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
22
|
+
export default _default;
|
|
23
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
24
|
+
new (): {
|
|
25
|
+
$slots: S;
|
|
26
|
+
};
|
|
27
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
class?: HTMLAttributes["class"];
|
|
4
|
+
};
|
|
5
|
+
declare function __VLS_template(): {
|
|
6
|
+
attrs: Partial<{}>;
|
|
7
|
+
slots: {
|
|
8
|
+
default?(_: {}): any;
|
|
9
|
+
};
|
|
10
|
+
refs: {};
|
|
11
|
+
rootEl: HTMLDivElement;
|
|
12
|
+
};
|
|
13
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
14
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
15
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
16
|
+
export default _default;
|
|
17
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
18
|
+
new (): {
|
|
19
|
+
$slots: S;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
class?: HTMLAttributes["class"];
|
|
4
|
+
};
|
|
5
|
+
declare function __VLS_template(): {
|
|
6
|
+
attrs: Partial<{}>;
|
|
7
|
+
slots: {
|
|
8
|
+
default?(_: {}): any;
|
|
9
|
+
};
|
|
10
|
+
refs: {};
|
|
11
|
+
rootEl: HTMLDivElement;
|
|
12
|
+
};
|
|
13
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
14
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
15
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
16
|
+
export default _default;
|
|
17
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
18
|
+
new (): {
|
|
19
|
+
$slots: S;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
class?: HTMLAttributes["class"];
|
|
4
|
+
modelValue?: string;
|
|
5
|
+
placeholder?: string;
|
|
6
|
+
};
|
|
7
|
+
declare function __VLS_template(): {
|
|
8
|
+
attrs: Partial<{}>;
|
|
9
|
+
slots: {
|
|
10
|
+
default?(_: {}): any;
|
|
11
|
+
};
|
|
12
|
+
refs: {};
|
|
13
|
+
rootEl: any;
|
|
14
|
+
};
|
|
15
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
16
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
17
|
+
"update:modelValue": (value: string) => any;
|
|
18
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
19
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
20
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
21
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
22
|
+
export default _default;
|
|
23
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
24
|
+
new (): {
|
|
25
|
+
$slots: S;
|
|
26
|
+
};
|
|
27
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
class?: HTMLAttributes["class"];
|
|
4
|
+
};
|
|
5
|
+
declare function __VLS_template(): {
|
|
6
|
+
attrs: Partial<{}>;
|
|
7
|
+
slots: {
|
|
8
|
+
default?(_: {}): any;
|
|
9
|
+
};
|
|
10
|
+
refs: {};
|
|
11
|
+
rootEl: any;
|
|
12
|
+
};
|
|
13
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
14
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
15
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
16
|
+
export default _default;
|
|
17
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
18
|
+
new (): {
|
|
19
|
+
$slots: S;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
class?: HTMLAttributes["class"];
|
|
4
|
+
value: string;
|
|
5
|
+
};
|
|
6
|
+
declare function __VLS_template(): {
|
|
7
|
+
attrs: Partial<{}>;
|
|
8
|
+
slots: {
|
|
9
|
+
default?(_: {}): any;
|
|
10
|
+
};
|
|
11
|
+
refs: {};
|
|
12
|
+
rootEl: any;
|
|
13
|
+
};
|
|
14
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
15
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
16
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
17
|
+
export default _default;
|
|
18
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
19
|
+
new (): {
|
|
20
|
+
$slots: S;
|
|
21
|
+
};
|
|
22
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
class?: HTMLAttributes["class"];
|
|
4
|
+
};
|
|
5
|
+
declare function __VLS_template(): {
|
|
6
|
+
attrs: Partial<{}>;
|
|
7
|
+
slots: {
|
|
8
|
+
default?(_: {}): any;
|
|
9
|
+
};
|
|
10
|
+
refs: {};
|
|
11
|
+
rootEl: any;
|
|
12
|
+
};
|
|
13
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
14
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
15
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
16
|
+
export default _default;
|
|
17
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
18
|
+
new (): {
|
|
19
|
+
$slots: S;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
import { ButtonVariants } from '../../button';
|
|
3
|
+
import { ChatStatus } from './types';
|
|
4
|
+
type __VLS_Props = {
|
|
5
|
+
class?: HTMLAttributes["class"];
|
|
6
|
+
variant?: ButtonVariants["variant"];
|
|
7
|
+
status?: ChatStatus;
|
|
8
|
+
disabled?: boolean;
|
|
9
|
+
};
|
|
10
|
+
declare function __VLS_template(): {
|
|
11
|
+
attrs: Partial<{}>;
|
|
12
|
+
slots: {
|
|
13
|
+
default?(_: {}): any;
|
|
14
|
+
};
|
|
15
|
+
refs: {};
|
|
16
|
+
rootEl: any;
|
|
17
|
+
};
|
|
18
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
19
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
20
|
+
stop: () => any;
|
|
21
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
22
|
+
onStop?: (() => any) | undefined;
|
|
23
|
+
}>, {
|
|
24
|
+
variant: "link" | "default" | "destructive" | "outline" | "secondary" | "ghost" | null;
|
|
25
|
+
status: ChatStatus;
|
|
26
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
27
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
28
|
+
export default _default;
|
|
29
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
30
|
+
new (): {
|
|
31
|
+
$slots: S;
|
|
32
|
+
};
|
|
33
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
class?: HTMLAttributes["class"];
|
|
4
|
+
placeholder?: string;
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
};
|
|
7
|
+
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
8
|
+
placeholder: string;
|
|
9
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
10
|
+
export default _default;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
class?: HTMLAttributes["class"];
|
|
4
|
+
};
|
|
5
|
+
declare function __VLS_template(): {
|
|
6
|
+
attrs: Partial<{}>;
|
|
7
|
+
slots: {
|
|
8
|
+
default?(_: {}): any;
|
|
9
|
+
};
|
|
10
|
+
refs: {};
|
|
11
|
+
rootEl: HTMLDivElement;
|
|
12
|
+
};
|
|
13
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
14
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
15
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
16
|
+
export default _default;
|
|
17
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
18
|
+
new (): {
|
|
19
|
+
$slots: S;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export * from './types';
|
|
2
|
+
export { usePromptInput } from './usePromptInput';
|
|
3
|
+
export { default as PromptInput } from './PromptInput.vue';
|
|
4
|
+
export { default as PromptInputTextarea } from './PromptInputTextarea.vue';
|
|
5
|
+
export { default as PromptInputHeader } from './PromptInputHeader.vue';
|
|
6
|
+
export { default as PromptInputFooter } from './PromptInputFooter.vue';
|
|
7
|
+
export { default as PromptInputTools } from './PromptInputTools.vue';
|
|
8
|
+
export { default as PromptInputButton } from './PromptInputButton.vue';
|
|
9
|
+
export { default as PromptInputSubmit } from './PromptInputSubmit.vue';
|
|
10
|
+
export { default as PromptInputAttachments } from './PromptInputAttachments.vue';
|
|
11
|
+
export { default as PromptInputActionMenu } from './PromptInputActionMenu.vue';
|
|
12
|
+
export { default as PromptInputActionMenuTrigger } from './PromptInputActionMenuTrigger.vue';
|
|
13
|
+
export { default as PromptInputActionMenuContent } from './PromptInputActionMenuContent.vue';
|
|
14
|
+
export { default as PromptInputActionMenuItem } from './PromptInputActionMenuItem.vue';
|
|
15
|
+
export { default as PromptInputActionAddAttachments } from './PromptInputActionAddAttachments.vue';
|
|
16
|
+
export { default as PromptInputAddAttachment } from './PromptInputAddAttachment.vue';
|
|
17
|
+
export { default as PromptInputSelect } from './PromptInputSelect.vue';
|
|
18
|
+
export { default as PromptInputSelectTrigger } from './PromptInputSelectTrigger.vue';
|
|
19
|
+
export { default as PromptInputSelectContent } from './PromptInputSelectContent.vue';
|
|
20
|
+
export { default as PromptInputSelectItem } from './PromptInputSelectItem.vue';
|
|
21
|
+
export { SelectValue as PromptInputSelectValue } from '../../select';
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { InjectionKey, Ref, ComputedRef } from 'vue';
|
|
2
|
+
export interface FileAttachment {
|
|
3
|
+
id: string;
|
|
4
|
+
type: "file";
|
|
5
|
+
url: string;
|
|
6
|
+
mediaType: string;
|
|
7
|
+
filename: string;
|
|
8
|
+
size?: number;
|
|
9
|
+
}
|
|
10
|
+
export interface PromptInputMessage {
|
|
11
|
+
text: string;
|
|
12
|
+
files: Omit<FileAttachment, "id">[];
|
|
13
|
+
}
|
|
14
|
+
export type ChatStatus = "ready" | "submitted" | "streaming" | "error";
|
|
15
|
+
export interface PromptInputContext {
|
|
16
|
+
inputValue: Ref<string>;
|
|
17
|
+
setInput: (value: string) => void;
|
|
18
|
+
attachments: Ref<FileAttachment[]>;
|
|
19
|
+
addFiles: (files: File[] | FileList) => void;
|
|
20
|
+
removeFile: (id: string) => void;
|
|
21
|
+
clearAttachments: () => void;
|
|
22
|
+
openFileDialog: () => void;
|
|
23
|
+
fileInputRef: Ref<HTMLInputElement | null>;
|
|
24
|
+
isSubmitting: Ref<boolean>;
|
|
25
|
+
submit: () => void;
|
|
26
|
+
}
|
|
27
|
+
export declare const promptInputKey: InjectionKey<ComputedRef<PromptInputContext>>;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
interface Props {
|
|
3
|
+
modelValue?: string;
|
|
4
|
+
placeholder?: string;
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
class?: HTMLAttributes["class"];
|
|
7
|
+
editorClass?: HTMLAttributes["class"];
|
|
8
|
+
}
|
|
9
|
+
declare const _default: import('vue').DefineComponent<Props, {
|
|
10
|
+
editor: import('vue').ComputedRef<import('@tiptap/vue-3').Editor | undefined>;
|
|
11
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
12
|
+
"update:modelValue": (value: string) => any;
|
|
13
|
+
}, string, import('vue').PublicProps, Readonly<Props> & Readonly<{
|
|
14
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
15
|
+
}>, {
|
|
16
|
+
placeholder: string;
|
|
17
|
+
modelValue: string;
|
|
18
|
+
disabled: boolean;
|
|
19
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
20
|
+
export default _default;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Editor } from '@tiptap/vue-3';
|
|
2
|
+
import { HTMLAttributes } from 'vue';
|
|
3
|
+
interface Props {
|
|
4
|
+
editor: Editor | undefined;
|
|
5
|
+
class?: HTMLAttributes["class"];
|
|
6
|
+
}
|
|
7
|
+
declare const _default: import('vue').DefineComponent<Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
8
|
+
export default _default;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Editor } from '@tiptap/vue-3';
|
|
2
|
+
import { HTMLAttributes } from 'vue';
|
|
3
|
+
interface Props {
|
|
4
|
+
editor: Editor | undefined;
|
|
5
|
+
class?: HTMLAttributes["class"];
|
|
6
|
+
}
|
|
7
|
+
declare const _default: import('vue').DefineComponent<Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
8
|
+
export default _default;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -2,5 +2,5 @@ import { HTMLAttributes } from 'vue';
|
|
|
2
2
|
type __VLS_Props = {
|
|
3
3
|
class?: HTMLAttributes["class"];
|
|
4
4
|
};
|
|
5
|
-
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {},
|
|
5
|
+
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
6
6
|
export default _default;
|
|
@@ -8,5 +8,5 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {
|
|
|
8
8
|
"update:modelValue": (payload: string | number) => any;
|
|
9
9
|
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
10
10
|
"onUpdate:modelValue"?: ((payload: string | number) => any) | undefined;
|
|
11
|
-
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {},
|
|
11
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
12
12
|
export default _default;
|