@vunk/plus 1.12.1 → 1.13.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/components/_plugin-vue_export-helper-BHFhmbuH.js +1 -0
- package/components/_plugin-vue_export-helper-CHgC5LLL.mjs +9 -0
- package/components/agent-chat-provider/index.cjs +1 -0
- package/components/agent-chat-provider/index.mjs +113 -187
- package/components/agent-chat-provider/src/index.vue.d.ts +3 -2
- package/components/avatar/index.cjs +1 -0
- package/components/avatar/index.mjs +25 -31
- package/components/avatar/src/index.vue.d.ts +40 -39
- package/components/broadcasting-markdown/__tests__/const.test.d.ts +1 -0
- package/components/broadcasting-markdown/__tests__/utils.test.d.ts +1 -0
- package/components/broadcasting-markdown/index.cjs +5 -0
- package/components/broadcasting-markdown/index.mjs +346 -4376
- package/components/broadcasting-markdown/src/howler-speech.vue.d.ts +18 -24
- package/components/broadcasting-markdown/src/index.vue.d.ts +101 -51
- package/components/broadcasting-markdown/src/paragraph.vue.d.ts +17 -29
- package/components/broadcasting-markdown/src/speech-error.vue.d.ts +2 -59
- package/components/bubble-list/index.cjs +1 -0
- package/components/bubble-list/index.mjs +220 -302
- package/components/bubble-list/src/core/index.vue.d.ts +40 -885
- package/components/bubble-list/src/core/loading.vue.d.ts +3 -0
- package/components/bubble-list/src/index.vue.d.ts +29 -1321
- package/components/bubble-templates/index.cjs +1 -0
- package/components/bubble-templates/index.mjs +34 -49
- package/components/bubble-templates/src/index.vue.d.ts +3 -224
- package/components/chat-independent/index.cjs +1 -0
- package/components/chat-independent/index.mjs +105 -212
- package/components/chat-independent/src/index.vue.d.ts +20 -2712
- package/components/components.css +1 -0
- package/components/drawer/index.cjs +1 -0
- package/components/drawer/index.mjs +53 -94
- package/components/drawer/src/ctx.d.ts +22 -22
- package/components/drawer/src/index.vue.d.ts +84 -557
- package/components/index.cjs +1 -0
- package/components/index.d.ts +1 -0
- package/components/lottie-animation/index.cjs +1 -0
- package/components/lottie-animation/index.mjs +36 -55
- package/components/lottie-animation/src/index.vue.d.ts +3 -2
- package/components/metahuman-broadcasting/index.cjs +1 -0
- package/components/metahuman-broadcasting/index.mjs +89 -140
- package/components/metahuman-broadcasting/src/index.vue.d.ts +16 -718
- package/components/monaco-editor/index.cjs +1 -0
- package/components/monaco-editor/index.mjs +75 -73
- package/components/monaco-editor/src/ctx.d.ts +10 -4
- package/components/monaco-editor/src/index.vue.d.ts +17 -2
- package/components/monaco-environment/index.cjs +1 -0
- package/components/monaco-environment/index.mjs +23 -38
- package/components/monaco-environment/src/index.vue.d.ts +2 -1
- package/components/pixi-frame/index.cjs +1 -0
- package/components/pixi-frame/index.mjs +501 -1978
- package/components/pixi-frame/src/apng.vue.d.ts +17 -73
- package/components/pixi-frame/src/bitmap-generator.vue.d.ts +24 -66
- package/components/pixi-frame/src/bitmap.vue.d.ts +28 -80
- package/components/pixi-frame/src/buffer-image.vue.d.ts +29 -97
- package/components/pixi-frame/src/core.vue.d.ts +20 -75
- package/components/pixi-frame/src/index.vue.d.ts +302 -237
- package/components/pixi-frame/src/provider.vue.d.ts +12 -1
- package/components/pixi-frame/src/video.vue.d.ts +17 -71
- package/components/pixi-frame/src/view.vue.d.ts +4 -16
- package/components/recorder-button/index.cjs +1 -0
- package/components/recorder-button/index.mjs +140 -269
- package/components/recorder-button/src/index.vue.d.ts +67 -66
- package/components/routes-menu-content/index.cjs +1 -0
- package/components/routes-menu-content/index.mjs +150 -229
- package/components/routes-menu-content/src/index.vue.d.ts +27 -26
- package/components/routes-menu-content/src/item/core/index.vue.d.ts +27 -26
- package/components/routes-menu-content/src/item/index.vue.d.ts +27 -26
- package/components/scrollbar/index.cjs +1 -0
- package/components/scrollbar/index.mjs +288 -567
- package/components/scrollbar/src/bar.vue.d.ts +6 -133
- package/components/scrollbar/src/index.vue.d.ts +66 -337
- package/components/scrollbar/src/thumb.vue.d.ts +3 -80
- package/components/sender/index.cjs +1 -0
- package/components/sender/index.mjs +156 -285
- package/components/sender/src/SenderHeader.vue.d.ts +14 -221
- package/components/sender/src/index.vue.d.ts +16 -505
- package/components/speech-button/index.cjs +1 -0
- package/components/speech-button/index.mjs +98 -144
- package/components/speech-button/src/LoadingIcon.vue.d.ts +2 -1
- package/components/speech-button/src/RecordingIcon.vue.d.ts +2 -1
- package/components/speech-button/src/index.vue.d.ts +6 -5
- package/components/table-columns/index.cjs +1 -0
- package/components/table-columns/index.mjs +48 -78
- package/components/table-columns/src/ctx.d.ts +12 -12
- package/components/table-columns/src/el-ctx.d.ts +3 -3
- package/components/table-columns/src/index.vue.d.ts +28 -27
- package/components/tables-v1/index.cjs +1 -0
- package/components/tables-v1/index.mjs +99 -160
- package/components/tables-v1/src/ctx.d.ts +38 -38
- package/components/tables-v1/src/el-ctx.d.ts +7 -7
- package/components/tables-v1/src/index.vue.d.ts +111 -2266
- package/components/tables-v1-checkbox/index.cjs +1 -0
- package/components/tables-v1-checkbox/index.mjs +116 -4043
- package/components/tables-v1-checkbox/src/ctx.d.ts +36 -36
- package/components/tables-v1-checkbox/src/index.vue.d.ts +224 -2378
- package/components/text/index.cjs +1 -0
- package/components/text/index.mjs +70 -108
- package/components/text/src/ctx.d.ts +32 -32
- package/components/text/src/index.vue.d.ts +92 -1819
- package/components/thinking/index.cjs +1 -0
- package/components/thinking/index.mjs +127 -227
- package/components/thinking/src/index.vue.d.ts +23 -2045
- package/components/typing-markdown/index.cjs +1 -0
- package/components/typing-markdown/index.mjs +61 -201
- package/components/typing-markdown/src/index.vue.d.ts +3 -2
- package/components/vditor/index.cjs +1 -0
- package/components/vditor/index.mjs +121 -195
- package/components/vditor/src/ctx.d.ts +2 -2
- package/components/vditor/src/handle-fullscreen.vue.d.ts +3 -2
- package/components/vditor/src/handle-value.vue.d.ts +3 -2
- package/components/vditor/src/index.vue.d.ts +5 -4
- package/components/xgplayer/index.cjs +1 -0
- package/components/xgplayer/index.mjs +49 -90
- package/components/xgplayer/src/core.vue.d.ts +13 -18
- package/components/xgplayer/src/index.vue.d.ts +13 -67
- package/composables/el-breakpoints/index.cjs +1 -0
- package/composables/el-breakpoints/index.d.ts +10 -10
- package/composables/el-breakpoints/index.mjs +10 -12
- package/composables/index.cjs +1 -0
- package/composables/index.d.ts +1 -0
- package/composables/recorder/index.cjs +1 -0
- package/composables/recorder/index.mjs +9172 -14803
- package/element/_plugin-vue_export-helper-BHFhmbuH.js +1 -0
- package/element/bubble/index.cjs +3 -0
- package/element/bubble/index.d.ts +1 -1
- package/element/bubble/index.mjs +1 -1
- package/element/bubble/src/index.vue.d.ts +22 -22
- package/element/index.css +1 -1
- package/element/thinking/index.cjs +1 -0
- package/element/thinking/index.d.ts +1 -1
- package/element/thinking/index.mjs +1 -1
- package/element/thinking/src/index.vue.d.ts +26 -26
- package/element/thinking/src/types.d.ts +10 -0
- package/icons/_plugin-vue_export-helper-BHFhmbuH.js +1 -0
- package/icons/_plugin-vue_export-helper-CHgC5LLL.mjs +9 -0
- package/icons/end/index.cjs +1 -0
- package/icons/end/index.mjs +21 -26
- package/icons/end/src/index.vue.d.ts +3 -0
- package/icons/keyboard/index.cjs +1 -0
- package/icons/keyboard/index.mjs +21 -26
- package/icons/keyboard/src/index.vue.d.ts +3 -0
- package/icons/start/index.cjs +1 -0
- package/icons/start/index.mjs +21 -26
- package/icons/start/src/index.vue.d.ts +3 -0
- package/icons/voice/index.cjs +1 -0
- package/icons/voice/index.mjs +26 -44
- package/icons/voice/src/index.vue.d.ts +2 -3
- package/index.css +2 -558
- package/index.d.ts +1 -0
- package/package.json +78 -87
- package/shared/data/index.cjs +1 -0
- package/shared/data/index.mjs +16 -22
- package/shared/types/index.cjs +1 -0
- package/shared/types/index.d.ts +1 -0
- package/components/LinkOutlined.mjs +0 -1321
- package/components/_commonjsHelpers.mjs +0 -7
- package/components/_plugin-vue_export-helper.mjs +0 -9
- package/components/bubble-list/index.css +0 -70
- package/components/bubble-templates/index.css +0 -4
- package/components/chat-independent/index.css +0 -47
- package/components/drawer/index.css +0 -124
- package/components/index2.mjs +0 -78
- package/components/lottie-animation/index.css +0 -4
- package/components/monaco-editor/index.css +0 -4
- package/components/pixi-frame/index.css +0 -4
- package/components/recorder-button/index.css +0 -69
- package/components/sender/index.css +0 -22
- package/components/speech-button/index.css +0 -10
- package/components/tables-v1/index.css +0 -7
- package/components/tables-v1-checkbox/index.css +0 -8
- package/components/thinking/index.css +0 -125
- package/components/typing-markdown/index.css +0 -31
- package/components/vditor/index.css +0 -12
- package/components/xgplayer/index.css +0 -1
- package/icons/_plugin-vue_export-helper.mjs +0 -9
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),_=require("@element-plus/icons-vue"),b=require("@vunk/plus/components/scrollbar"),c=require("element-plus"),y={modelValue:{type:Boolean,default:!0},content:{type:String,default:""},status:{type:String,default:"start"},disabled:{type:Boolean,default:!1},autoCollapse:{type:Boolean,default:!1},duration:{type:String,default:"0.2s"},buttonWidth:{type:String,default:"160px"},maxWidth:{type:String,default:"100%"},backgroundColor:{type:String,default:"#fcfcfc"},color:{type:String,default:"var(--el-color-info)"},title:{type:String,default:"分析用户需求"},skipText:{type:String,default:"跳过思考"},showSkip:{type:Boolean,default:!1},radius:{type:String,default:"22px"},borderColor:{type:String,default:"#e4e7ed"},maxHeight:{type:String,default:""}},S={change:null,"update:modelValue":null,skip:null},V={class:"vk-thinking__header"},C=["disabled"],x={class:"vk-thinking__title"},w={class:"vk-thinking__body"},T={class:"vk-thinking__content"},a=e.defineComponent({name:"VkThinking",inheritAttrs:!1,__name:"index",props:y,emits:S,setup(l,{emit:k}){const t=l,o=k,h=e.useSlots(),n=e.ref(t.modelValue);e.watch(()=>t.modelValue,i=>{n.value=i}),e.watch(()=>t.status,i=>{i==="end"&&t.autoCollapse&&(n.value=!1,o("update:modelValue",!1))});const s=e.computed(()=>t.status==="error"?"思考过程中出现错误":t.content),r=e.computed(()=>!!h.default||!!s.value),p=e.computed(()=>t.showSkip&&!t.disabled&&t.status==="thinking"),g=e.computed(()=>t.status==="error"?"分析出现问题":t.status==="cancel"?"已跳过思考":t.title),f=e.computed(()=>({"--vk-thinking-animation-duration":t.duration,"--vk-thinking-button-width":t.buttonWidth,"--vk-thinking-max-width":t.maxWidth,"--vk-thinking-background-color":t.backgroundColor,"--vk-thinking-color":t.color,"--vk-thinking-radius":t.radius,"--vk-thinking-border-color":t.borderColor,"--vk-thinking-body-max-height":t.maxHeight||"none","--vk-thinking-font-size-base":"16px","--vk-thinking-font-size-title":"1.125em","--vk-thinking-font-size-skip":"1em","--vk-thinking-font-size-content":"0.9em","--vk-thinking-font-size-caret":"0.8125em"})),u=e.ref();e.watch(()=>[t.content,n.value,t.status],()=>{t.status==="thinking"&&n.value&&e.nextTick(()=>{u.value?.scrollToBottom({behavior:"auto"})})},{flush:"post"});function d(){o("change",{value:n.value,status:t.status}),o("update:modelValue",n.value)}function v(){t.disabled||!r.value||(n.value=!n.value,d())}function m(){t.disabled||(n.value=!1,d(),o("skip",{value:!1,status:t.status}))}return(i,E)=>(e.openBlock(),e.createElementBlock("div",{class:"vk-thinking",style:e.normalizeStyle(f.value)},[e.createElementVNode("section",{class:e.normalizeClass(["vk-thinking__card",[`is-${i.status}`,{"is-disabled":i.disabled,"is-expanded":n.value&&r.value}]])},[e.createElementVNode("header",V,[e.createElementVNode("button",{class:"vk-thinking__toggle",type:"button",disabled:i.disabled,onClick:v},[e.createElementVNode("span",x,e.toDisplayString(g.value)+":",1),e.createVNode(e.unref(c.ElIcon),{class:e.normalizeClass(["vk-thinking__caret",{"is-expanded":n.value}])},{default:e.withCtx(()=>[e.createVNode(e.unref(_.ArrowRightBold))]),_:1},8,["class"])],8,C),p.value?(e.openBlock(),e.createElementBlock("button",{key:0,class:"vk-thinking__skip",type:"button",onClick:e.withModifiers(m,["stop"])},e.toDisplayString(i.skipText),1)):e.createCommentVNode("",!0)]),e.createVNode(e.unref(c.ElCollapseTransition),null,{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",w,[e.createVNode(e.unref(b.VkScrollbar),{ref_key:"scrollbarRef",ref:u,class:"vk-thinking__scrollbar","max-height":i.maxHeight},{default:e.withCtx(()=>[e.renderSlot(i.$slots,"default",{content:s.value,status:i.status},()=>[e.createElementVNode("div",T,e.toDisplayString(s.value),1)])]),_:3},8,["max-height"])],512),[[e.vShow,n.value&&r.value]])]),_:3})],2)],4))}}),B=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"}));a.install=l=>{l.component(a.name||"VkThinking",a)};exports.VkThinking=a;exports.__VkThinking=B;exports.default=a;
|
|
@@ -1,16 +1,14 @@
|
|
|
1
|
-
import { defineComponent, useSlots, ref, watch, computed, nextTick
|
|
2
|
-
import {
|
|
3
|
-
import { VkScrollbar } from
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
const props = {
|
|
1
|
+
import { defineComponent as B, useSlots as z, ref as v, watch as c, computed as a, nextTick as E, createElementBlock as m, openBlock as _, normalizeStyle as W, createElementVNode as i, normalizeClass as b, createVNode as l, createCommentVNode as A, toDisplayString as k, unref as s, withCtx as h, withModifiers as H, withDirectives as N, renderSlot as R, vShow as j } from "vue";
|
|
2
|
+
import { ArrowRightBold as D } from "@element-plus/icons-vue";
|
|
3
|
+
import { VkScrollbar as M } from "@vunk/plus/components/scrollbar";
|
|
4
|
+
import { ElIcon as O, ElCollapseTransition as $ } from "element-plus";
|
|
5
|
+
const I = {
|
|
8
6
|
/**
|
|
9
7
|
* @description 展开/收起状态(v-model)
|
|
10
8
|
*/
|
|
11
9
|
modelValue: {
|
|
12
10
|
type: Boolean,
|
|
13
|
-
default:
|
|
11
|
+
default: !0
|
|
14
12
|
},
|
|
15
13
|
/**
|
|
16
14
|
* @description 思考内容文本
|
|
@@ -31,14 +29,14 @@ const props = {
|
|
|
31
29
|
*/
|
|
32
30
|
disabled: {
|
|
33
31
|
type: Boolean,
|
|
34
|
-
default:
|
|
32
|
+
default: !1
|
|
35
33
|
},
|
|
36
34
|
/**
|
|
37
35
|
* @description status=end 时是否自动收起
|
|
38
36
|
*/
|
|
39
37
|
autoCollapse: {
|
|
40
38
|
type: Boolean,
|
|
41
|
-
default:
|
|
39
|
+
default: !1
|
|
42
40
|
},
|
|
43
41
|
/**
|
|
44
42
|
* @description 动画过渡时长
|
|
@@ -80,21 +78,21 @@ const props = {
|
|
|
80
78
|
*/
|
|
81
79
|
title: {
|
|
82
80
|
type: String,
|
|
83
|
-
default: "
|
|
81
|
+
default: "分析用户需求"
|
|
84
82
|
},
|
|
85
83
|
/**
|
|
86
84
|
* @description 跳过按钮文案
|
|
87
85
|
*/
|
|
88
86
|
skipText: {
|
|
89
87
|
type: String,
|
|
90
|
-
default: "
|
|
88
|
+
default: "跳过思考"
|
|
91
89
|
},
|
|
92
90
|
/**
|
|
93
91
|
* @description 是否显示跳过按钮
|
|
94
92
|
*/
|
|
95
93
|
showSkip: {
|
|
96
94
|
type: Boolean,
|
|
97
|
-
default:
|
|
95
|
+
default: !1
|
|
98
96
|
},
|
|
99
97
|
/**
|
|
100
98
|
* @description 卡片圆角
|
|
@@ -117,241 +115,143 @@ const props = {
|
|
|
117
115
|
type: String,
|
|
118
116
|
default: ""
|
|
119
117
|
}
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
"change": null,
|
|
118
|
+
}, P = {
|
|
119
|
+
change: null,
|
|
123
120
|
"update:modelValue": null,
|
|
124
|
-
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
...{
|
|
129
|
-
name: "VkThinking",
|
|
130
|
-
inheritAttrs: false
|
|
131
|
-
},
|
|
121
|
+
skip: null
|
|
122
|
+
}, q = { class: "vk-thinking__header" }, F = ["disabled"], G = { class: "vk-thinking__title" }, J = { class: "vk-thinking__body" }, K = { class: "vk-thinking__content" }, p = /* @__PURE__ */ B({
|
|
123
|
+
name: "VkThinking",
|
|
124
|
+
inheritAttrs: !1,
|
|
132
125
|
__name: "index",
|
|
133
|
-
props:
|
|
134
|
-
emits,
|
|
135
|
-
setup(
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
watch(
|
|
142
|
-
() => props.modelValue,
|
|
143
|
-
(newVal) => {
|
|
144
|
-
isExpanded.value = newVal;
|
|
126
|
+
props: I,
|
|
127
|
+
emits: P,
|
|
128
|
+
setup(r, { emit: y }) {
|
|
129
|
+
const t = r, o = y, S = z(), e = v(t.modelValue);
|
|
130
|
+
c(
|
|
131
|
+
() => t.modelValue,
|
|
132
|
+
(n) => {
|
|
133
|
+
e.value = n;
|
|
145
134
|
}
|
|
146
|
-
)
|
|
147
|
-
|
|
148
|
-
() =>
|
|
149
|
-
|
|
150
|
-
if (newVal === "end" && props.autoCollapse) {
|
|
151
|
-
isExpanded.value = false;
|
|
152
|
-
emit("update:modelValue", false);
|
|
153
|
-
}
|
|
135
|
+
), c(
|
|
136
|
+
() => t.status,
|
|
137
|
+
(n) => {
|
|
138
|
+
n === "end" && t.autoCollapse && (e.value = !1, o("update:modelValue", !1));
|
|
154
139
|
}
|
|
155
140
|
);
|
|
156
|
-
const
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
const titleText = computed(() => {
|
|
166
|
-
if (props.status === "error")
|
|
167
|
-
return "\u5206\u6790\u51FA\u73B0\u95EE\u9898";
|
|
168
|
-
if (props.status === "cancel")
|
|
169
|
-
return "\u5DF2\u8DF3\u8FC7\u601D\u8003";
|
|
170
|
-
return props.title;
|
|
171
|
-
});
|
|
172
|
-
const cssVars = computed(() => ({
|
|
173
|
-
"--vk-thinking-animation-duration": props.duration,
|
|
174
|
-
"--vk-thinking-button-width": props.buttonWidth,
|
|
175
|
-
"--vk-thinking-max-width": props.maxWidth,
|
|
176
|
-
"--vk-thinking-background-color": props.backgroundColor,
|
|
177
|
-
"--vk-thinking-color": props.color,
|
|
178
|
-
"--vk-thinking-radius": props.radius,
|
|
179
|
-
"--vk-thinking-border-color": props.borderColor,
|
|
180
|
-
"--vk-thinking-body-max-height": props.maxHeight || "none",
|
|
141
|
+
const u = a(() => t.status === "error" ? "思考过程中出现错误" : t.content), d = a(() => !!S.default || !!u.value), x = a(() => t.showSkip && !t.disabled && t.status === "thinking"), C = a(() => t.status === "error" ? "分析出现问题" : t.status === "cancel" ? "已跳过思考" : t.title), V = a(() => ({
|
|
142
|
+
"--vk-thinking-animation-duration": t.duration,
|
|
143
|
+
"--vk-thinking-button-width": t.buttonWidth,
|
|
144
|
+
"--vk-thinking-max-width": t.maxWidth,
|
|
145
|
+
"--vk-thinking-background-color": t.backgroundColor,
|
|
146
|
+
"--vk-thinking-color": t.color,
|
|
147
|
+
"--vk-thinking-radius": t.radius,
|
|
148
|
+
"--vk-thinking-border-color": t.borderColor,
|
|
149
|
+
"--vk-thinking-body-max-height": t.maxHeight || "none",
|
|
181
150
|
"--vk-thinking-font-size-base": "16px",
|
|
182
151
|
"--vk-thinking-font-size-title": "1.125em",
|
|
183
152
|
"--vk-thinking-font-size-skip": "1em",
|
|
184
153
|
"--vk-thinking-font-size-content": "0.9em",
|
|
185
154
|
"--vk-thinking-font-size-caret": "0.8125em"
|
|
186
|
-
}));
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
() => [props.content, isExpanded.value, props.status],
|
|
155
|
+
})), f = v();
|
|
156
|
+
c(
|
|
157
|
+
() => [t.content, e.value, t.status],
|
|
190
158
|
() => {
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
behavior: "auto"
|
|
195
|
-
});
|
|
159
|
+
t.status === "thinking" && e.value && E(() => {
|
|
160
|
+
f.value?.scrollToBottom({
|
|
161
|
+
behavior: "auto"
|
|
196
162
|
});
|
|
197
|
-
}
|
|
163
|
+
});
|
|
198
164
|
},
|
|
199
165
|
{ flush: "post" }
|
|
200
166
|
);
|
|
201
|
-
function
|
|
202
|
-
|
|
203
|
-
value:
|
|
204
|
-
status:
|
|
205
|
-
});
|
|
206
|
-
emit("update:modelValue", isExpanded.value);
|
|
167
|
+
function g() {
|
|
168
|
+
o("change", {
|
|
169
|
+
value: e.value,
|
|
170
|
+
status: t.status
|
|
171
|
+
}), o("update:modelValue", e.value);
|
|
207
172
|
}
|
|
208
|
-
function
|
|
209
|
-
|
|
210
|
-
return;
|
|
211
|
-
isExpanded.value = !isExpanded.value;
|
|
212
|
-
emitChange();
|
|
173
|
+
function T() {
|
|
174
|
+
t.disabled || !d.value || (e.value = !e.value, g());
|
|
213
175
|
}
|
|
214
|
-
function
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
emit("skip", {
|
|
220
|
-
value: false,
|
|
221
|
-
status: props.status
|
|
222
|
-
});
|
|
176
|
+
function w() {
|
|
177
|
+
t.disabled || (e.value = !1, g(), o("skip", {
|
|
178
|
+
value: !1,
|
|
179
|
+
status: t.status
|
|
180
|
+
}));
|
|
223
181
|
}
|
|
224
|
-
|
|
225
|
-
return arrow_right_bold_default;
|
|
226
|
-
}, get VkScrollbar() {
|
|
227
|
-
return VkScrollbar;
|
|
228
|
-
}, get ElCollapseTransition() {
|
|
229
|
-
return ElCollapseTransition;
|
|
230
|
-
}, get ElIcon() {
|
|
231
|
-
return ElIcon;
|
|
232
|
-
} };
|
|
233
|
-
Object.defineProperty(__returned__, "__isScriptSetup", { enumerable: false, value: true });
|
|
234
|
-
return __returned__;
|
|
235
|
-
}
|
|
236
|
-
});
|
|
237
|
-
|
|
238
|
-
const _hoisted_1 = { class: "vk-thinking__header" };
|
|
239
|
-
const _hoisted_2 = ["disabled"];
|
|
240
|
-
const _hoisted_3 = { class: "vk-thinking__title" };
|
|
241
|
-
const _hoisted_4 = { class: "vk-thinking__body" };
|
|
242
|
-
const _hoisted_5 = { class: "vk-thinking__content" };
|
|
243
|
-
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
244
|
-
return openBlock(), createElementBlock(
|
|
245
|
-
"div",
|
|
246
|
-
{
|
|
182
|
+
return (n, L) => (_(), m("div", {
|
|
247
183
|
class: "vk-thinking",
|
|
248
|
-
style:
|
|
249
|
-
},
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
},
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
184
|
+
style: W(V.value)
|
|
185
|
+
}, [
|
|
186
|
+
i("section", {
|
|
187
|
+
class: b(["vk-thinking__card", [
|
|
188
|
+
`is-${n.status}`,
|
|
189
|
+
{
|
|
190
|
+
"is-disabled": n.disabled,
|
|
191
|
+
"is-expanded": e.value && d.value
|
|
192
|
+
}
|
|
193
|
+
]])
|
|
194
|
+
}, [
|
|
195
|
+
i("header", q, [
|
|
196
|
+
i("button", {
|
|
197
|
+
class: "vk-thinking__toggle",
|
|
198
|
+
type: "button",
|
|
199
|
+
disabled: n.disabled,
|
|
200
|
+
onClick: T
|
|
201
|
+
}, [
|
|
202
|
+
i("span", G, k(C.value) + ":", 1),
|
|
203
|
+
l(s(O), {
|
|
204
|
+
class: b(["vk-thinking__caret", { "is-expanded": e.value }])
|
|
205
|
+
}, {
|
|
206
|
+
default: h(() => [
|
|
207
|
+
l(s(D))
|
|
208
|
+
]),
|
|
209
|
+
_: 1
|
|
210
|
+
}, 8, ["class"])
|
|
211
|
+
], 8, F),
|
|
212
|
+
x.value ? (_(), m("button", {
|
|
213
|
+
key: 0,
|
|
214
|
+
class: "vk-thinking__skip",
|
|
215
|
+
type: "button",
|
|
216
|
+
onClick: H(w, ["stop"])
|
|
217
|
+
}, k(n.skipText), 1)) : A("", !0)
|
|
218
|
+
]),
|
|
219
|
+
l(s($), null, {
|
|
220
|
+
default: h(() => [
|
|
221
|
+
N(i("div", J, [
|
|
222
|
+
l(s(M), {
|
|
223
|
+
ref_key: "scrollbarRef",
|
|
224
|
+
ref: f,
|
|
225
|
+
class: "vk-thinking__scrollbar",
|
|
226
|
+
"max-height": n.maxHeight
|
|
279
227
|
}, {
|
|
280
|
-
default:
|
|
281
|
-
|
|
228
|
+
default: h(() => [
|
|
229
|
+
R(n.$slots, "default", {
|
|
230
|
+
content: u.value,
|
|
231
|
+
status: n.status
|
|
232
|
+
}, () => [
|
|
233
|
+
i("div", K, k(u.value), 1)
|
|
234
|
+
])
|
|
282
235
|
]),
|
|
283
|
-
_:
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
"button",
|
|
289
|
-
{
|
|
290
|
-
key: 0,
|
|
291
|
-
class: "vk-thinking__skip",
|
|
292
|
-
type: "button",
|
|
293
|
-
onClick: withModifiers($setup.skipThinking, ["stop"])
|
|
294
|
-
},
|
|
295
|
-
toDisplayString(_ctx.skipText),
|
|
296
|
-
1
|
|
297
|
-
/* TEXT */
|
|
298
|
-
)) : createCommentVNode("v-if", true)
|
|
236
|
+
_: 3
|
|
237
|
+
}, 8, ["max-height"])
|
|
238
|
+
], 512), [
|
|
239
|
+
[j, e.value && d.value]
|
|
240
|
+
])
|
|
299
241
|
]),
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
createVNode($setup["VkScrollbar"], {
|
|
307
|
-
ref: "scrollbarRef",
|
|
308
|
-
class: "vk-thinking__scrollbar",
|
|
309
|
-
"max-height": _ctx.maxHeight
|
|
310
|
-
}, {
|
|
311
|
-
default: withCtx(() => [
|
|
312
|
-
renderSlot(_ctx.$slots, "default", {
|
|
313
|
-
content: $setup.displayedContent,
|
|
314
|
-
status: _ctx.status
|
|
315
|
-
}, () => [
|
|
316
|
-
createElementVNode(
|
|
317
|
-
"div",
|
|
318
|
-
_hoisted_5,
|
|
319
|
-
toDisplayString($setup.displayedContent),
|
|
320
|
-
1
|
|
321
|
-
/* TEXT */
|
|
322
|
-
)
|
|
323
|
-
])
|
|
324
|
-
]),
|
|
325
|
-
_: 3
|
|
326
|
-
/* FORWARDED */
|
|
327
|
-
}, 8, ["max-height"])
|
|
328
|
-
],
|
|
329
|
-
512
|
|
330
|
-
/* NEED_PATCH */
|
|
331
|
-
), [
|
|
332
|
-
[vShow, $setup.isExpanded && $setup.hasContent]
|
|
333
|
-
])
|
|
334
|
-
]),
|
|
335
|
-
_: 3
|
|
336
|
-
/* FORWARDED */
|
|
337
|
-
})
|
|
338
|
-
],
|
|
339
|
-
2
|
|
340
|
-
/* CLASS */
|
|
341
|
-
)
|
|
342
|
-
],
|
|
343
|
-
4
|
|
344
|
-
/* STYLE */
|
|
345
|
-
);
|
|
346
|
-
}
|
|
347
|
-
var VkThinking = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__file", "/home/runner/work/vunk-plus/vunk-plus/packages/components/thinking/src/index.vue"]]);
|
|
348
|
-
|
|
349
|
-
var types = /*#__PURE__*/Object.freeze({
|
|
242
|
+
_: 3
|
|
243
|
+
})
|
|
244
|
+
], 2)
|
|
245
|
+
], 4));
|
|
246
|
+
}
|
|
247
|
+
}), Z = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
350
248
|
__proto__: null
|
|
351
|
-
});
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
249
|
+
}, Symbol.toStringTag, { value: "Module" }));
|
|
250
|
+
p.install = (r) => {
|
|
251
|
+
r.component(p.name || "VkThinking", p);
|
|
252
|
+
};
|
|
253
|
+
export {
|
|
254
|
+
p as VkThinking,
|
|
255
|
+
Z as __VkThinking,
|
|
256
|
+
p as default
|
|
355
257
|
};
|
|
356
|
-
|
|
357
|
-
export { VkThinking, types as __VkThinking, VkThinking as default };
|