ant-design-x-vue 0.1.4 → 1.0.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/index.mjs +1171 -1153
- package/dist/index.umd.js +8 -8
- package/dist/typings/attachments/Attachments.vue.d.ts +23 -1
- package/dist/typings/attachments/index.d.ts +11 -1
- package/dist/typings/attachments/interface.d.ts +1 -1
- package/dist/typings/bubble/Bubble.vue.d.ts +31 -1
- package/dist/typings/bubble/index.d.ts +19 -1
- package/dist/typings/prompts/Prompts.vue.d.ts +19 -1
- package/dist/typings/suggestion/Suggestion.vue.d.ts +8 -3
- package/dist/typings/use-x-agent/use-x-agent.d.ts +1 -3
- package/dist/typings/welcome/Welcome.vue.d.ts +25 -1
- package/package.json +14 -11
|
@@ -1,6 +1,28 @@
|
|
|
1
|
+
import { type VNode } from 'vue';
|
|
1
2
|
import type { AttachmentsProps } from './interface';
|
|
2
|
-
declare
|
|
3
|
+
declare function __VLS_template(): {
|
|
4
|
+
attrs: Partial<{}>;
|
|
5
|
+
slots: Readonly<{
|
|
6
|
+
placeholder?(props?: {
|
|
7
|
+
type: "inline" | "drop";
|
|
8
|
+
}): VNode | string;
|
|
9
|
+
}> & {
|
|
10
|
+
placeholder?(props?: {
|
|
11
|
+
type: "inline" | "drop";
|
|
12
|
+
}): VNode | string;
|
|
13
|
+
};
|
|
14
|
+
refs: {};
|
|
15
|
+
rootEl: any;
|
|
16
|
+
};
|
|
17
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
18
|
+
declare const __VLS_component: import("vue").DefineComponent<AttachmentsProps, {
|
|
3
19
|
nativeElement: HTMLDivElement | null;
|
|
4
20
|
upload: (file: File) => void;
|
|
5
21
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<AttachmentsProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
22
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
6
23
|
export default _default;
|
|
24
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
25
|
+
new (): {
|
|
26
|
+
$slots: S;
|
|
27
|
+
};
|
|
28
|
+
};
|
|
@@ -19,7 +19,17 @@ declare const Attachments: {
|
|
|
19
19
|
} & import("vue").ComponentOptionsBase<Readonly<import("./interface").AttachmentsProps> & Readonly<{}>, {
|
|
20
20
|
nativeElement: HTMLDivElement | null;
|
|
21
21
|
upload: (file: File) => void;
|
|
22
|
-
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & {
|
|
22
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
|
|
23
|
+
$slots: Readonly<{
|
|
24
|
+
placeholder?(props?: {
|
|
25
|
+
type: "inline" | "drop";
|
|
26
|
+
}): import("vue").VNode | string;
|
|
27
|
+
}> & {
|
|
28
|
+
placeholder?(props?: {
|
|
29
|
+
type: "inline" | "drop";
|
|
30
|
+
}): import("vue").VNode | string;
|
|
31
|
+
};
|
|
32
|
+
}) & {
|
|
23
33
|
FileCard: import("vue").DefineComponent<import("./interface").FileListCardProps, {
|
|
24
34
|
nativeElement: Readonly<import("vue").ShallowRef<HTMLDivElement>>;
|
|
25
35
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("./interface").FileListCardProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
@@ -19,7 +19,7 @@ export interface PlaceholderConfig {
|
|
|
19
19
|
title?: VNode | string;
|
|
20
20
|
description?: VNode | string;
|
|
21
21
|
}
|
|
22
|
-
export type PlaceholderType = PlaceholderConfig | VNode;
|
|
22
|
+
export type PlaceholderType = PlaceholderConfig | VNode | string;
|
|
23
23
|
export interface PlaceholderProps {
|
|
24
24
|
prefixCls: string;
|
|
25
25
|
placeholder?: PlaceholderType;
|
|
@@ -1,5 +1,35 @@
|
|
|
1
1
|
import type { BubbleProps } from './interface';
|
|
2
|
-
|
|
2
|
+
import type { VNode } from 'vue';
|
|
3
|
+
declare function __VLS_template(): {
|
|
4
|
+
attrs: Partial<{}>;
|
|
5
|
+
slots: Readonly<{
|
|
6
|
+
avatar?(): VNode;
|
|
7
|
+
header?(): VNode | string;
|
|
8
|
+
footer?(): VNode | string;
|
|
9
|
+
loading?(): VNode;
|
|
10
|
+
message?(props?: {
|
|
11
|
+
content: string;
|
|
12
|
+
}): VNode | string;
|
|
13
|
+
}> & {
|
|
14
|
+
avatar?(): VNode;
|
|
15
|
+
header?(): VNode | string;
|
|
16
|
+
footer?(): VNode | string;
|
|
17
|
+
loading?(): VNode;
|
|
18
|
+
message?(props?: {
|
|
19
|
+
content: string;
|
|
20
|
+
}): VNode | string;
|
|
21
|
+
};
|
|
22
|
+
refs: {};
|
|
23
|
+
rootEl: any;
|
|
24
|
+
};
|
|
25
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
26
|
+
declare const __VLS_component: import("vue").DefineComponent<BubbleProps, {
|
|
3
27
|
nativeElement: import("vue").Ref<HTMLDivElement, HTMLDivElement>;
|
|
4
28
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<BubbleProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
29
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
5
30
|
export default _default;
|
|
31
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
32
|
+
new (): {
|
|
33
|
+
$slots: S;
|
|
34
|
+
};
|
|
35
|
+
};
|
|
@@ -18,7 +18,25 @@ declare const Bubble: {
|
|
|
18
18
|
__isSuspense?: never;
|
|
19
19
|
} & import("vue").ComponentOptionsBase<Readonly<import("./interface").BubbleProps> & Readonly<{}>, {
|
|
20
20
|
nativeElement: import("vue").Ref<HTMLDivElement, HTMLDivElement>;
|
|
21
|
-
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & {
|
|
21
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
|
|
22
|
+
$slots: Readonly<{
|
|
23
|
+
avatar?(): import("vue").VNode;
|
|
24
|
+
header?(): import("vue").VNode | string;
|
|
25
|
+
footer?(): import("vue").VNode | string;
|
|
26
|
+
loading?(): import("vue").VNode;
|
|
27
|
+
message?(props?: {
|
|
28
|
+
content: string;
|
|
29
|
+
}): import("vue").VNode | string;
|
|
30
|
+
}> & {
|
|
31
|
+
avatar?(): import("vue").VNode;
|
|
32
|
+
header?(): import("vue").VNode | string;
|
|
33
|
+
footer?(): import("vue").VNode | string;
|
|
34
|
+
loading?(): import("vue").VNode;
|
|
35
|
+
message?(props?: {
|
|
36
|
+
content: string;
|
|
37
|
+
}): import("vue").VNode | string;
|
|
38
|
+
};
|
|
39
|
+
}) & {
|
|
22
40
|
List: import("vue").DefineComponent<import("./interface").BubbleListProps, {
|
|
23
41
|
nativeElement: import("vue").Ref<HTMLDivElement, HTMLDivElement>;
|
|
24
42
|
scrollTo: ({ key, offset, behavior, block }: {
|
|
@@ -1,3 +1,21 @@
|
|
|
1
1
|
import type { PromptsProps } from './interface';
|
|
2
|
-
|
|
2
|
+
import { type VNode } from 'vue';
|
|
3
|
+
declare function __VLS_template(): {
|
|
4
|
+
attrs: Partial<{}>;
|
|
5
|
+
slots: Readonly<{
|
|
6
|
+
title?(): VNode | string;
|
|
7
|
+
}> & {
|
|
8
|
+
title?(): VNode | string;
|
|
9
|
+
};
|
|
10
|
+
refs: {};
|
|
11
|
+
rootEl: any;
|
|
12
|
+
};
|
|
13
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
14
|
+
declare const __VLS_component: import("vue").DefineComponent<PromptsProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<PromptsProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
15
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
3
16
|
export default _default;
|
|
17
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
18
|
+
new (): {
|
|
19
|
+
$slots: S;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
@@ -1,11 +1,16 @@
|
|
|
1
|
-
import type { SuggestionProps } from './interface';
|
|
1
|
+
import type { RenderChildrenProps, SuggestionProps } from './interface';
|
|
2
|
+
import { type VNode } from 'vue';
|
|
2
3
|
declare const _default: <T = any>(__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<{
|
|
3
4
|
props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{} & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, never>, never> & Partial<{}> & SuggestionProps<T>> & import("vue").PublicProps;
|
|
4
5
|
expose(exposed: import("vue").ShallowUnwrapRef<{}>): void;
|
|
5
6
|
attrs: any;
|
|
6
|
-
slots: {
|
|
7
|
+
slots: Readonly<{
|
|
8
|
+
default?(props?: RenderChildrenProps<T>): VNode;
|
|
9
|
+
}> & {
|
|
10
|
+
default?(props?: RenderChildrenProps<T>): VNode;
|
|
11
|
+
};
|
|
7
12
|
emit: {};
|
|
8
|
-
}>) =>
|
|
13
|
+
}>) => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
9
14
|
[key: string]: any;
|
|
10
15
|
}> & {
|
|
11
16
|
__ctx?: Awaited<typeof __VLS_setup>;
|
|
@@ -27,7 +27,5 @@ export declare class XAgent<Message = string> {
|
|
|
27
27
|
request: RequestFn<Message>;
|
|
28
28
|
isRequesting(): boolean;
|
|
29
29
|
}
|
|
30
|
-
export default function useXAgent<Message = string>(config: XAgentConfig<Message>):
|
|
31
|
-
agent: import("vue").ComputedRef<XAgent<Message>>;
|
|
32
|
-
};
|
|
30
|
+
export default function useXAgent<Message = string>(config: XAgentConfig<Message>): import("vue").ComputedRef<XAgent<Message>>[];
|
|
33
31
|
export {};
|
|
@@ -1,3 +1,27 @@
|
|
|
1
1
|
import type { WelcomeProps } from './interface';
|
|
2
|
-
|
|
2
|
+
import { type VNode } from 'vue';
|
|
3
|
+
declare function __VLS_template(): {
|
|
4
|
+
attrs: Partial<{}>;
|
|
5
|
+
slots: Readonly<{
|
|
6
|
+
title?(): VNode | string;
|
|
7
|
+
description?(): VNode | string;
|
|
8
|
+
icon?(): VNode | string;
|
|
9
|
+
extra?(): VNode | string;
|
|
10
|
+
}> & {
|
|
11
|
+
title?(): VNode | string;
|
|
12
|
+
description?(): VNode | string;
|
|
13
|
+
icon?(): VNode | string;
|
|
14
|
+
extra?(): VNode | string;
|
|
15
|
+
};
|
|
16
|
+
refs: {};
|
|
17
|
+
rootEl: any;
|
|
18
|
+
};
|
|
19
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
20
|
+
declare const __VLS_component: import("vue").DefineComponent<WelcomeProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<WelcomeProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
21
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
3
22
|
export default _default;
|
|
23
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
24
|
+
new (): {
|
|
25
|
+
$slots: S;
|
|
26
|
+
};
|
|
27
|
+
};
|
package/package.json
CHANGED
|
@@ -1,24 +1,30 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ant-design-x-vue",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "Craft AI-driven interfaces effortlessly",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"AI",
|
|
7
|
+
"Copilot",
|
|
8
|
+
"ant",
|
|
9
|
+
"antdv",
|
|
10
|
+
"components",
|
|
11
|
+
"framework",
|
|
12
|
+
"chat-ui",
|
|
13
|
+
"vue"
|
|
14
|
+
],
|
|
5
15
|
"scripts": {
|
|
6
16
|
"build": "vite build && vue-tsc --project ./tsconfig.build.json",
|
|
7
17
|
"build:watch": "vite build --watch",
|
|
8
|
-
"dev": "
|
|
18
|
+
"docs:dev": "vitepress dev docs",
|
|
9
19
|
"docs:build": "vitepress build docs",
|
|
10
20
|
"docs:preview": "vitepress preview docs",
|
|
11
21
|
"lint": "npm run lint:es",
|
|
12
|
-
"lint:css": "stylelint \"{src,test}/**/*.{css,less}\"",
|
|
13
22
|
"lint:es": "eslint \"{src,test}/**/*.{js,jsx,ts,tsx,vue}\"",
|
|
14
|
-
"prepare": "husky install && dumi setup",
|
|
15
23
|
"prepublishOnly": "npm run test && npm run build",
|
|
16
24
|
"release": "pnpm test && changelogen --release && npm publish && git push --follow-tags",
|
|
17
|
-
"start": "npm run dev",
|
|
18
25
|
"test": "vitest",
|
|
19
26
|
"test:cov": "vitest --coverage",
|
|
20
|
-
"typecheck": "vue-tsc --noEmit"
|
|
21
|
-
"docs:dev": "vitepress dev docs"
|
|
27
|
+
"typecheck": "vue-tsc --noEmit"
|
|
22
28
|
},
|
|
23
29
|
"author": {
|
|
24
30
|
"name": "wzc520pyfm",
|
|
@@ -76,7 +82,6 @@
|
|
|
76
82
|
"@ant-design/icons-vue": "^7.0.1",
|
|
77
83
|
"@commitlint/cli": "^17.1.2",
|
|
78
84
|
"@commitlint/config-conventional": "^17.1.0",
|
|
79
|
-
"@dumijs/preset-vue": "^2.4.12",
|
|
80
85
|
"@eslint/js": "^9.11.1",
|
|
81
86
|
"@types/markdown-it": "^14.1.2",
|
|
82
87
|
"@types/node": "^22.10.2",
|
|
@@ -85,7 +90,6 @@
|
|
|
85
90
|
"@types/stylis": "^4.2.7",
|
|
86
91
|
"@typescript-eslint/eslint-plugin": "^8.7.0",
|
|
87
92
|
"@typescript-eslint/parser": "^8.7.0",
|
|
88
|
-
"@umijs/lint": "^4.3.24",
|
|
89
93
|
"@vitejs/plugin-vue": "^5.1.4",
|
|
90
94
|
"@vitejs/plugin-vue-jsx": "^4.0.1",
|
|
91
95
|
"@vitest/coverage-v8": "^2.1.1",
|
|
@@ -93,7 +97,6 @@
|
|
|
93
97
|
"@vue/test-utils": "^2.4.6",
|
|
94
98
|
"@vueuse/core": "^12.2.0",
|
|
95
99
|
"changelogen": "^0.5.7",
|
|
96
|
-
"dumi": "^2.4.13",
|
|
97
100
|
"eslint": "^8.57.1",
|
|
98
101
|
"eslint-plugin-vue": "^9.17.0",
|
|
99
102
|
"fast-glob": "^3.3.2",
|