@vunk/plus 1.3.0 → 1.3.2
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/components/SendOutlined.mjs +1 -1
- package/components/agent-chat-provider/index.d.ts +7 -0
- package/components/agent-chat-provider/src/api.d.ts +3 -0
- package/components/agent-chat-provider/src/const-roles.d.ts +8 -0
- package/components/agent-chat-provider/src/const.d.ts +1 -0
- package/components/agent-chat-provider/src/index.vue.d.ts +47 -0
- package/components/agent-chat-provider/src/types.d.ts +37 -0
- package/components/agent-chat-provider/src/use.d.ts +29 -0
- package/components/avatar/index.d.ts +4 -0
- package/components/avatar/src/ctx.d.ts +18 -0
- package/components/avatar/src/index.vue.d.ts +121 -0
- package/components/avatar/src/types.d.ts +1 -0
- package/components/broadcasting-markdown/index.d.ts +5 -0
- package/components/broadcasting-markdown/index.mjs +32 -16
- package/components/broadcasting-markdown/src/const.d.ts +18 -0
- package/components/broadcasting-markdown/src/ctx.d.ts +101 -0
- package/components/broadcasting-markdown/src/custom-speech.vue.d.ts +117 -0
- package/components/broadcasting-markdown/src/index.vue.d.ts +502 -0
- package/components/broadcasting-markdown/src/paragraph.vue.d.ts +78 -0
- package/components/broadcasting-markdown/src/speech-error.vue.d.ts +60 -0
- package/components/broadcasting-markdown/src/types.d.ts +17 -0
- package/components/broadcasting-markdown/src/use.d.ts +3 -0
- package/components/broadcasting-markdown/src/web-speech.vue.d.ts +110 -0
- package/components/bubble-list/index.d.ts +5 -0
- package/components/bubble-list/index.mjs +2 -316
- package/components/bubble-list/src/ctx.d.ts +30 -0
- package/components/bubble-list/src/index.vue.d.ts +952 -0
- package/components/bubble-list/src/types.d.ts +4 -0
- package/components/bubble-templates/index.d.ts +4 -0
- package/components/bubble-templates/index.mjs +2 -161
- package/components/bubble-templates/src/index.vue.d.ts +656 -0
- package/components/bubble-templates/src/types.d.ts +30 -0
- package/components/chat-independent/index.d.ts +4 -0
- package/components/chat-independent/index.mjs +42 -34
- package/components/chat-independent/src/const.d.ts +13 -0
- package/components/chat-independent/src/ctx.d.ts +20 -0
- package/components/chat-independent/src/index.vue.d.ts +2413 -0
- package/components/chat-independent/src/types.d.ts +13 -0
- package/components/index.d.ts +0 -0
- package/components/index.mjs +0 -35979
- package/components/lottie-animation/index.d.ts +4 -0
- package/components/lottie-animation/src/ctx.d.ts +10 -0
- package/components/lottie-animation/src/index.vue.d.ts +21 -0
- package/components/lottie-animation/src/types.d.ts +4 -0
- package/components/monaco-editor/index.d.ts +5 -0
- package/components/monaco-editor/src/ctx.d.ts +23 -0
- package/components/monaco-editor/src/index.vue.d.ts +40 -0
- package/components/monaco-editor/src/types.d.ts +1 -0
- package/components/monaco-environment/index.d.ts +4 -0
- package/components/monaco-environment/src/ctx.d.ts +8 -0
- package/components/monaco-environment/src/index.vue.d.ts +2 -0
- package/components/monaco-environment/src/types.d.ts +1 -0
- package/components/recorder-button/index.d.ts +4 -0
- package/components/recorder-button/src/ctx.d.ts +40 -0
- package/components/recorder-button/src/index.vue.d.ts +303 -0
- package/components/recorder-button/src/speech-to-text.d.ts +1 -0
- package/components/recorder-button/src/types.d.ts +7 -0
- package/components/routes-menu-content/index.d.ts +4 -0
- package/components/routes-menu-content/src/ctx.d.ts +17 -0
- package/components/routes-menu-content/src/index.vue.d.ts +472 -0
- package/components/routes-menu-content/src/item/core/ctx.d.ts +18 -0
- package/components/routes-menu-content/src/item/core/index.vue.d.ts +307 -0
- package/components/routes-menu-content/src/item/ctx.d.ts +14 -0
- package/components/routes-menu-content/src/item/index.vue.d.ts +438 -0
- package/components/routes-menu-content/src/types.d.ts +1 -0
- package/components/sender/index.d.ts +4 -0
- package/components/sender/index.mjs +1 -1
- package/components/sender/src/SenderHeader.vue.d.ts +256 -0
- package/components/sender/src/ctx.d.ts +58 -0
- package/components/sender/src/index.vue.d.ts +778 -0
- package/components/sender/src/types.d.ts +1 -0
- package/components/speech-button/index.d.ts +4 -0
- package/components/speech-button/index.mjs +1 -1
- package/components/speech-button/src/LoadingIcon.vue.d.ts +2 -0
- package/components/speech-button/src/RecordingIcon.vue.d.ts +2 -0
- package/components/speech-button/src/ctx.d.ts +10 -0
- package/components/speech-button/src/index.vue.d.ts +22 -0
- package/components/speech-button/src/types.d.ts +1 -0
- package/components/table-columns/index.d.ts +5 -0
- package/components/table-columns/src/ctx.d.ts +66 -0
- package/components/table-columns/src/el-ctx.d.ts +63 -0
- package/components/table-columns/src/index.vue.d.ts +282 -0
- package/components/table-columns/src/types.d.ts +21 -0
- package/components/tables-v1/index.d.ts +5 -0
- package/components/tables-v1/src/ctx.d.ts +281 -0
- package/components/tables-v1/src/el-ctx.d.ts +269 -0
- package/components/tables-v1/src/index.vue.d.ts +3014 -0
- package/components/tables-v1/src/types.d.ts +4 -0
- package/components/tables-v1-checkbox/index.d.ts +5 -0
- package/components/tables-v1-checkbox/src/ctx.d.ts +321 -0
- package/components/tables-v1-checkbox/src/index.vue.d.ts +3796 -0
- package/components/tables-v1-checkbox/src/types.d.ts +1 -0
- package/components/typing-markdown/index.d.ts +4 -0
- package/components/typing-markdown/index.mjs +2 -2
- package/components/typing-markdown/src/core.d.ts +2 -0
- package/components/typing-markdown/src/ctx.d.ts +33 -0
- package/components/typing-markdown/src/index.vue.d.ts +57 -0
- package/components/typing-markdown/src/types.d.ts +1 -0
- package/components/vditor/index.d.ts +5 -0
- package/components/vditor/src/ctx.d.ts +37 -0
- package/components/vditor/src/handle-fullscreen.vue.d.ts +18 -0
- package/components/vditor/src/handle-value.vue.d.ts +18 -0
- package/components/vditor/src/index.vue.d.ts +144 -0
- package/components/vditor/src/types.d.ts +9 -0
- package/components/vditor/src/use.d.ts +4 -0
- package/index.css +0 -38
- package/package.json +1 -7
- package/components/bubble-list/index.css +0 -18
- package/components/bubble-templates/index.css +0 -18
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import type { VkBroadcastingMarkdown } from '@vunk/plus/components/broadcasting-markdown';
|
|
2
|
+
import type { __VkRenderer } from '@vunk/core/components/renderer';
|
|
3
|
+
import type { VueComponentPropsType } from '@vunk/shared';
|
|
4
|
+
import type { TypewriterProps } from 'vue-element-plus-x/types/components/Typewriter/types';
|
|
5
|
+
export interface TypewriterSource extends __VkRenderer.SourceItem, TypewriterProps {
|
|
6
|
+
templateType: 'Typewriter';
|
|
7
|
+
}
|
|
8
|
+
export interface BroadcastingMarkdownSource extends __VkRenderer.SourceItem, VueComponentPropsType<typeof VkBroadcastingMarkdown> {
|
|
9
|
+
templateType: 'VkBroadcastingMarkdown';
|
|
10
|
+
}
|
|
11
|
+
export type RenderItem = TypewriterSource | BroadcastingMarkdownSource;
|
|
12
|
+
export type RenderData = Record<string, RenderDataRecord>;
|
|
13
|
+
export interface RenderDataRecord {
|
|
14
|
+
/**
|
|
15
|
+
* @description 渲染的组件
|
|
16
|
+
*/
|
|
17
|
+
templateType?: RenderItem['templateType'];
|
|
18
|
+
/**
|
|
19
|
+
* @description 组件暴露的元数据
|
|
20
|
+
*/
|
|
21
|
+
meta?: any;
|
|
22
|
+
/**
|
|
23
|
+
* @description 已经完成的
|
|
24
|
+
*/
|
|
25
|
+
completed?: boolean;
|
|
26
|
+
/**
|
|
27
|
+
* @description 发生错误的
|
|
28
|
+
*/
|
|
29
|
+
error?: boolean;
|
|
30
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent, ref, computed, createElementBlock, openBlock, createElementVNode, createVNode, unref, withCtx, withDirectives, vShow, renderSlot, nextTick } from 'vue';
|
|
1
|
+
import { defineComponent, ref, computed, createElementBlock, openBlock, createElementVNode, createVNode, unref, withCtx, createCommentVNode, withDirectives, Fragment, vShow, renderSlot, nextTick } from 'vue';
|
|
2
2
|
import { useAgentChat } from '@vunk/plus/components/agent-chat-provider';
|
|
3
3
|
import { VkBubbleList } from '@vunk/plus/components/bubble-list';
|
|
4
4
|
import { VkRecorderButton } from '@vunk/plus/components/recorder-button';
|
|
@@ -113,39 +113,47 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
113
113
|
]),
|
|
114
114
|
two: withCtx(() => [
|
|
115
115
|
createElementVNode("div", _hoisted_3, [
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
{
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
116
|
+
_ctx.speechToText ? (openBlock(), createElementBlock(
|
|
117
|
+
Fragment,
|
|
118
|
+
{ key: 0 },
|
|
119
|
+
[
|
|
120
|
+
withDirectives(createVNode(
|
|
121
|
+
unref(VkKeyboardAvatar),
|
|
122
|
+
{
|
|
123
|
+
size: 40,
|
|
124
|
+
onClick: _cache[0] || (_cache[0] = ($event) => inputType.value = unref(InputType).Text)
|
|
125
|
+
},
|
|
126
|
+
null,
|
|
127
|
+
512
|
|
128
|
+
/* NEED_PATCH */
|
|
129
|
+
), [
|
|
130
|
+
[vShow, inputType.value === unref(InputType).Voice]
|
|
131
|
+
]),
|
|
132
|
+
withDirectives(createVNode(unref(VkRecorderButton), {
|
|
133
|
+
"append-to": mainRef.value,
|
|
134
|
+
disabled: senderDisabled.value,
|
|
135
|
+
"speech-to-text": _ctx.speechToText,
|
|
136
|
+
"submit-to-text": true,
|
|
137
|
+
onSubmitText: onSubmit
|
|
138
|
+
}, null, 8, ["append-to", "disabled", "speech-to-text"]), [
|
|
139
|
+
[vShow, inputType.value === unref(InputType).Voice]
|
|
140
|
+
]),
|
|
141
|
+
withDirectives(createVNode(
|
|
142
|
+
unref(VkVoiceAvatar),
|
|
143
|
+
{
|
|
144
|
+
size: 40,
|
|
145
|
+
onClick: _cache[1] || (_cache[1] = ($event) => inputType.value = unref(InputType).Voice)
|
|
146
|
+
},
|
|
147
|
+
null,
|
|
148
|
+
512
|
|
149
|
+
/* NEED_PATCH */
|
|
150
|
+
), [
|
|
151
|
+
[vShow, inputType.value === unref(InputType).Text]
|
|
152
|
+
])
|
|
153
|
+
],
|
|
154
|
+
64
|
|
155
|
+
/* STABLE_FRAGMENT */
|
|
156
|
+
)) : createCommentVNode("v-if", true),
|
|
149
157
|
withDirectives(createVNode(unref(VkSender), {
|
|
150
158
|
modelValue: content.value,
|
|
151
159
|
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => content.value = $event),
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { __VkBubbleList } from '@vunk/plus/components/bubble-list';
|
|
2
|
+
import type { SetDataEvent } from '@vunk/core';
|
|
3
|
+
import type { PropType } from 'vue';
|
|
4
|
+
export declare const props: {
|
|
5
|
+
/**
|
|
6
|
+
* @description BubbleList渲染时数据, 受控于setData
|
|
7
|
+
*/
|
|
8
|
+
data: {
|
|
9
|
+
type: PropType<import("../../bubble-templates/src/types").RenderData>;
|
|
10
|
+
};
|
|
11
|
+
speechToText: {
|
|
12
|
+
type: PropType<import("./types").SpeechToText>;
|
|
13
|
+
};
|
|
14
|
+
textToSpeech: {
|
|
15
|
+
type: PropType<import("./types").TextToSpeech>;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
export declare const emits: {
|
|
19
|
+
setData: (e: SetDataEvent) => SetDataEvent;
|
|
20
|
+
};
|