@vunk/plus 1.8.0 → 1.8.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.
Files changed (130) hide show
  1. package/components/{SendOutlined.mjs → LinkOutlined.mjs} +36 -54
  2. package/components/agent-chat-provider/index.d.ts +8 -0
  3. package/components/agent-chat-provider/src/MessageView.d.ts +29 -0
  4. package/components/agent-chat-provider/src/api.d.ts +3 -0
  5. package/components/agent-chat-provider/src/const-roles.d.ts +8 -0
  6. package/components/agent-chat-provider/src/const.d.ts +1 -0
  7. package/components/agent-chat-provider/src/index.vue.d.ts +22 -0
  8. package/components/agent-chat-provider/src/types.d.ts +56 -0
  9. package/components/agent-chat-provider/src/use.d.ts +6 -0
  10. package/components/avatar/index.d.ts +4 -0
  11. package/components/avatar/src/ctx.d.ts +6 -0
  12. package/components/avatar/src/index.vue.d.ts +261 -0
  13. package/components/avatar/src/types.d.ts +1 -0
  14. package/components/broadcasting-markdown/index.d.ts +7 -0
  15. package/components/broadcasting-markdown/src/const.d.ts +13 -0
  16. package/components/broadcasting-markdown/src/ctx.d.ts +126 -0
  17. package/components/broadcasting-markdown/src/howler-speech.vue.d.ts +58 -0
  18. package/components/broadcasting-markdown/src/index.vue.d.ts +373 -0
  19. package/components/broadcasting-markdown/src/paragraph.vue.d.ts +79 -0
  20. package/components/broadcasting-markdown/src/speech-error.vue.d.ts +60 -0
  21. package/components/broadcasting-markdown/src/types.d.ts +26 -0
  22. package/components/broadcasting-markdown/src/use.d.ts +19 -0
  23. package/components/bubble-list/index.d.ts +5 -0
  24. package/components/bubble-list/src/ctx.d.ts +28 -0
  25. package/components/bubble-list/src/index.vue.d.ts +484 -0
  26. package/components/bubble-list/src/types.d.ts +4 -0
  27. package/components/bubble-templates/index.d.ts +5 -0
  28. package/components/bubble-templates/src/core.d.ts +69 -0
  29. package/components/bubble-templates/src/index.vue.d.ts +242 -0
  30. package/components/bubble-templates/src/legacy.vue.d.ts +153 -0
  31. package/components/bubble-templates/src/types.d.ts +45 -0
  32. package/components/chat-independent/index.d.ts +4 -0
  33. package/components/chat-independent/src/const.d.ts +13 -0
  34. package/components/chat-independent/src/ctx.d.ts +21 -0
  35. package/components/chat-independent/src/index.vue.d.ts +2291 -0
  36. package/components/chat-independent/src/types.d.ts +13 -0
  37. package/components/index.d.ts +0 -0
  38. package/components/lottie-animation/index.d.ts +4 -0
  39. package/components/lottie-animation/src/ctx.d.ts +10 -0
  40. package/components/lottie-animation/src/index.vue.d.ts +21 -0
  41. package/components/lottie-animation/src/types.d.ts +4 -0
  42. package/components/metahuman-broadcasting/index.d.ts +5 -0
  43. package/components/metahuman-broadcasting/src/ctx.d.ts +57 -0
  44. package/components/metahuman-broadcasting/src/index.vue.d.ts +826 -0
  45. package/components/metahuman-broadcasting/src/types.d.ts +1 -0
  46. package/components/monaco-editor/index.d.ts +5 -0
  47. package/components/monaco-editor/src/ctx.d.ts +23 -0
  48. package/components/monaco-editor/src/index.vue.d.ts +40 -0
  49. package/components/monaco-editor/src/types.d.ts +1 -0
  50. package/components/monaco-environment/index.d.ts +4 -0
  51. package/components/monaco-environment/src/ctx.d.ts +8 -0
  52. package/components/monaco-environment/src/index.vue.d.ts +2 -0
  53. package/components/monaco-environment/src/types.d.ts +1 -0
  54. package/components/pixi-frame/index.d.ts +11 -0
  55. package/components/pixi-frame/src/apng.vue.d.ts +161 -0
  56. package/components/pixi-frame/src/bitmap.vue.d.ts +158 -0
  57. package/components/pixi-frame/src/core.vue.d.ts +173 -0
  58. package/components/pixi-frame/src/ctx.d.ts +55 -0
  59. package/components/pixi-frame/src/index.vue.d.ts +591 -0
  60. package/components/pixi-frame/src/provider.vue.d.ts +2 -0
  61. package/components/pixi-frame/src/types.d.ts +17 -0
  62. package/components/pixi-frame/src/use.d.ts +16 -0
  63. package/components/pixi-frame/src/useSprite.d.ts +12 -0
  64. package/components/pixi-frame/src/video.vue.d.ts +159 -0
  65. package/components/pixi-frame/src/view.vue.d.ts +29 -0
  66. package/components/recorder-button/index.d.ts +4 -0
  67. package/components/recorder-button/src/ctx.d.ts +41 -0
  68. package/components/recorder-button/src/index.vue.d.ts +489 -0
  69. package/components/recorder-button/src/speech-to-text.d.ts +1 -0
  70. package/components/recorder-button/src/types.d.ts +7 -0
  71. package/components/routes-menu-content/index.d.ts +4 -0
  72. package/components/routes-menu-content/src/ctx.d.ts +17 -0
  73. package/components/routes-menu-content/src/index.vue.d.ts +573 -0
  74. package/components/routes-menu-content/src/item/core/ctx.d.ts +18 -0
  75. package/components/routes-menu-content/src/item/core/index.vue.d.ts +408 -0
  76. package/components/routes-menu-content/src/item/ctx.d.ts +14 -0
  77. package/components/routes-menu-content/src/item/index.vue.d.ts +539 -0
  78. package/components/routes-menu-content/src/types.d.ts +1 -0
  79. package/components/scrollbar/index.d.ts +4 -0
  80. package/components/scrollbar/src/bar.d.ts +15 -0
  81. package/components/scrollbar/src/bar.vue.d.ts +138 -0
  82. package/components/scrollbar/src/index.vue.d.ts +552 -0
  83. package/components/scrollbar/src/thumb.d.ts +15 -0
  84. package/components/scrollbar/src/thumb.vue.d.ts +97 -0
  85. package/components/scrollbar/src/types.d.ts +1 -0
  86. package/components/scrollbar/src/util.d.ts +3 -0
  87. package/components/sender/index.d.ts +5 -0
  88. package/components/sender/index.mjs +96 -42
  89. package/components/sender/src/SenderHeader.vue.d.ts +256 -0
  90. package/components/sender/src/ctx.d.ts +107 -0
  91. package/components/sender/src/index.vue.d.ts +649 -0
  92. package/components/sender/src/types.d.ts +1 -0
  93. package/components/speech-button/index.d.ts +4 -0
  94. package/components/speech-button/index.mjs +1 -1
  95. package/components/speech-button/src/LoadingIcon.vue.d.ts +2 -0
  96. package/components/speech-button/src/RecordingIcon.vue.d.ts +2 -0
  97. package/components/speech-button/src/ctx.d.ts +10 -0
  98. package/components/speech-button/src/index.vue.d.ts +22 -0
  99. package/components/speech-button/src/types.d.ts +1 -0
  100. package/components/table-columns/index.d.ts +5 -0
  101. package/components/table-columns/src/ctx.d.ts +59 -0
  102. package/components/table-columns/src/el-ctx.d.ts +57 -0
  103. package/components/table-columns/src/index.vue.d.ts +132 -0
  104. package/components/table-columns/src/types.d.ts +21 -0
  105. package/components/tables-v1/index.d.ts +5 -0
  106. package/components/tables-v1/src/ctx.d.ts +337 -0
  107. package/components/tables-v1/src/el-ctx.d.ts +262 -0
  108. package/components/tables-v1/src/index.vue.d.ts +3085 -0
  109. package/components/tables-v1/src/types.d.ts +3 -0
  110. package/components/tables-v1-checkbox/index.d.ts +5 -0
  111. package/components/tables-v1-checkbox/src/ctx.d.ts +370 -0
  112. package/components/tables-v1-checkbox/src/index.vue.d.ts +3972 -0
  113. package/components/tables-v1-checkbox/src/types.d.ts +1 -0
  114. package/components/text/index.d.ts +4 -0
  115. package/components/text/src/ctx.d.ts +356 -0
  116. package/components/text/src/index.vue.d.ts +2335 -0
  117. package/components/text/src/types.d.ts +1 -0
  118. package/components/typing-markdown/index.d.ts +4 -0
  119. package/components/typing-markdown/src/core.d.ts +2 -0
  120. package/components/typing-markdown/src/ctx.d.ts +41 -0
  121. package/components/typing-markdown/src/index.vue.d.ts +75 -0
  122. package/components/typing-markdown/src/types.d.ts +1 -0
  123. package/components/vditor/index.d.ts +5 -0
  124. package/components/vditor/src/ctx.d.ts +38 -0
  125. package/components/vditor/src/handle-fullscreen.vue.d.ts +18 -0
  126. package/components/vditor/src/handle-value.vue.d.ts +18 -0
  127. package/components/vditor/src/index.vue.d.ts +143 -0
  128. package/components/vditor/src/types.d.ts +9 -0
  129. package/components/vditor/src/use.d.ts +4 -0
  130. package/package.json +1 -1
@@ -927,9 +927,9 @@ function updateCSS(css, key) {
927
927
  return newNode;
928
928
  }
929
929
 
930
- function _objectSpread$8(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$8(target, key, source[key]); }); } return target; }
930
+ function _objectSpread$7(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$7(target, key, source[key]); }); } return target; }
931
931
 
932
- function _defineProperty$8(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
932
+ function _defineProperty$7(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
933
933
  function warn(valid, message) {
934
934
  // Support uglify
935
935
  if (process.env.NODE_ENV !== 'production' && !valid && console !== undefined) {
@@ -946,14 +946,14 @@ function isIconDefinition(target) {
946
946
  }
947
947
  function generate(node, key, rootProps) {
948
948
  if (!rootProps) {
949
- return h(node.tag, _objectSpread$8({
949
+ return h(node.tag, _objectSpread$7({
950
950
  key: key
951
951
  }, node.attrs), (node.children || []).map(function (child, index) {
952
952
  return generate(child, "".concat(key, "-").concat(node.tag, "-").concat(index));
953
953
  }));
954
954
  }
955
955
 
956
- return h(node.tag, _objectSpread$8({
956
+ return h(node.tag, _objectSpread$7({
957
957
  key: key
958
958
  }, rootProps, node.attrs), (node.children || []).map(function (child, index) {
959
959
  return generate(child, "".concat(key, "-").concat(node.tag, "-").concat(index));
@@ -1029,9 +1029,9 @@ function _objectWithoutProperties$1(source, excluded) { if (source == null) retu
1029
1029
 
1030
1030
  function _objectWithoutPropertiesLoose$1(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
1031
1031
 
1032
- function _objectSpread$7(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$7(target, key, source[key]); }); } return target; }
1032
+ function _objectSpread$6(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$6(target, key, source[key]); }); } return target; }
1033
1033
 
1034
- function _defineProperty$7(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1034
+ function _defineProperty$6(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1035
1035
  var twoToneColorPalette = reactive({
1036
1036
  primaryColor: '#333',
1037
1037
  secondaryColor: '#E6E6E6',
@@ -1047,11 +1047,11 @@ function setTwoToneColors(_ref) {
1047
1047
  }
1048
1048
 
1049
1049
  function getTwoToneColors() {
1050
- return _objectSpread$7({}, twoToneColorPalette);
1050
+ return _objectSpread$6({}, twoToneColorPalette);
1051
1051
  }
1052
1052
 
1053
1053
  var IconBase = function IconBase(props, context) {
1054
- var _props$context$attrs = _objectSpread$7({}, props, context.attrs),
1054
+ var _props$context$attrs = _objectSpread$6({}, props, context.attrs),
1055
1055
  icon = _props$context$attrs.icon,
1056
1056
  primaryColor = _props$context$attrs.primaryColor,
1057
1057
  secondaryColor = _props$context$attrs.secondaryColor,
@@ -1075,12 +1075,12 @@ var IconBase = function IconBase(props, context) {
1075
1075
  var target = icon;
1076
1076
 
1077
1077
  if (target && typeof target.icon === 'function') {
1078
- target = _objectSpread$7({}, target, {
1078
+ target = _objectSpread$6({}, target, {
1079
1079
  icon: target.icon(colors.primaryColor, colors.secondaryColor)
1080
1080
  });
1081
1081
  }
1082
1082
 
1083
- return generate(target.icon, "svg-".concat(target.name), _objectSpread$7({}, restProps, {
1083
+ return generate(target.icon, "svg-".concat(target.name), _objectSpread$6({}, restProps, {
1084
1084
  'data-icon': target.name,
1085
1085
  width: '1em',
1086
1086
  height: '1em',
@@ -1156,9 +1156,9 @@ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Sy
1156
1156
 
1157
1157
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
1158
1158
 
1159
- function _objectSpread$6(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$6(target, key, source[key]); }); } return target; }
1159
+ function _objectSpread$5(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$5(target, key, source[key]); }); } return target; }
1160
1160
 
1161
- function _defineProperty$6(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1161
+ function _defineProperty$5(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1162
1162
 
1163
1163
  function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
1164
1164
 
@@ -1169,7 +1169,7 @@ setTwoToneColor(blue.primary);
1169
1169
  var Icon = function Icon(props, context) {
1170
1170
  var _classObj;
1171
1171
 
1172
- var _props$context$attrs = _objectSpread$6({}, props, context.attrs),
1172
+ var _props$context$attrs = _objectSpread$5({}, props, context.attrs),
1173
1173
  cls = _props$context$attrs["class"],
1174
1174
  icon = _props$context$attrs.icon,
1175
1175
  spin = _props$context$attrs.spin,
@@ -1183,7 +1183,7 @@ var Icon = function Icon(props, context) {
1183
1183
  prefixCls = _useInjectIconContext.prefixCls,
1184
1184
  rootClassName = _useInjectIconContext.rootClassName;
1185
1185
 
1186
- var classObj = (_classObj = {}, _defineProperty$6(_classObj, rootClassName.value, !!rootClassName.value), _defineProperty$6(_classObj, prefixCls.value, true), _defineProperty$6(_classObj, "".concat(prefixCls.value, "-").concat(icon.name), Boolean(icon.name)), _defineProperty$6(_classObj, "".concat(prefixCls.value, "-spin"), !!spin || icon.name === 'loading'), _classObj);
1186
+ var classObj = (_classObj = {}, _defineProperty$5(_classObj, rootClassName.value, !!rootClassName.value), _defineProperty$5(_classObj, prefixCls.value, true), _defineProperty$5(_classObj, "".concat(prefixCls.value, "-").concat(icon.name), Boolean(icon.name)), _defineProperty$5(_classObj, "".concat(prefixCls.value, "-spin"), !!spin || icon.name === 'loading'), _classObj);
1187
1187
  var iconTabIndex = tabindex;
1188
1188
 
1189
1189
  if (iconTabIndex === undefined && onClick) {
@@ -1200,7 +1200,7 @@ var Icon = function Icon(props, context) {
1200
1200
  primaryColor = _normalizeTwoToneColo2[0],
1201
1201
  secondaryColor = _normalizeTwoToneColo2[1];
1202
1202
 
1203
- return createVNode("span", _objectSpread$6({
1203
+ return createVNode("span", _objectSpread$5({
1204
1204
  "role": "img",
1205
1205
  "aria-label": icon.name
1206
1206
  }, restProps, {
@@ -1229,14 +1229,14 @@ Icon.setTwoToneColor = setTwoToneColor;
1229
1229
  // This icon file is generated automatically.
1230
1230
  var AudioMutedOutlined$2 = { "icon": { "tag": "svg", "attrs": { "viewBox": "64 64 896 896", "focusable": "false" }, "children": [{ "tag": "defs", "attrs": {}, "children": [{ "tag": "style", "attrs": {} }] }, { "tag": "path", "attrs": { "d": "M682 455V311l-76 76v68c-.1 50.7-42 92.1-94 92a95.8 95.8 0 01-52-15l-54 55c29.1 22.4 65.9 36 106 36 93.8 0 170-75.1 170-168z" } }, { "tag": "path", "attrs": { "d": "M833 446h-60c-4.4 0-8 3.6-8 8 0 140.3-113.7 254-254 254-63 0-120.7-23-165-61l-54 54a334.01 334.01 0 00179 81v102H326c-13.9 0-24.9 14.3-25 32v36c.1 4.4 2.9 8 6 8h408c3.2 0 6-3.6 6-8v-36c0-17.7-11-32-25-32H547V782c165.3-17.9 294-157.9 294-328 0-4.4-3.6-8-8-8zm13.1-377.7l-43.5-41.9a8 8 0 00-11.2.1l-129 129C634.3 101.2 577 64 511 64c-93.9 0-170 75.3-170 168v224c0 6.7.4 13.3 1.2 19.8l-68 68A252.33 252.33 0 01258 454c-.2-4.4-3.8-8-8-8h-60c-4.4 0-8 3.6-8 8 0 53 12.5 103 34.6 147.4l-137 137a8.03 8.03 0 000 11.3l42.7 42.7c3.1 3.1 8.2 3.1 11.3 0L846.2 79.8l.1-.1c3.1-3.2 3-8.3-.2-11.4zM417 401V232c0-50.6 41.9-92 94-92 46 0 84.1 32.3 92.3 74.7L417 401z" } }] }, "name": "audio-muted", "theme": "outlined" };
1231
1231
 
1232
- function _objectSpread$5(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$5(target, key, source[key]); }); } return target; }
1232
+ function _objectSpread$4(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$4(target, key, source[key]); }); } return target; }
1233
1233
 
1234
- function _defineProperty$5(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1234
+ function _defineProperty$4(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1235
1235
 
1236
1236
  var AudioMutedOutlined = function AudioMutedOutlined(props, context) {
1237
- var p = _objectSpread$5({}, props, context.attrs);
1237
+ var p = _objectSpread$4({}, props, context.attrs);
1238
1238
 
1239
- return createVNode(Icon, _objectSpread$5({}, p, {
1239
+ return createVNode(Icon, _objectSpread$4({}, p, {
1240
1240
  "icon": AudioMutedOutlined$2
1241
1241
  }), null);
1242
1242
  };
@@ -1248,14 +1248,14 @@ var AudioMutedOutlined$1 = AudioMutedOutlined;
1248
1248
  // This icon file is generated automatically.
1249
1249
  var AudioOutlined$2 = { "icon": { "tag": "svg", "attrs": { "viewBox": "64 64 896 896", "focusable": "false" }, "children": [{ "tag": "path", "attrs": { "d": "M842 454c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8 0 140.3-113.7 254-254 254S258 594.3 258 454c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8 0 168.7 126.6 307.9 290 327.6V884H326.7c-13.7 0-24.7 14.3-24.7 32v36c0 4.4 2.8 8 6.2 8h407.6c3.4 0 6.2-3.6 6.2-8v-36c0-17.7-11-32-24.7-32H548V782.1c165.3-18 294-158 294-328.1zM512 624c93.9 0 170-75.2 170-168V232c0-92.8-76.1-168-170-168s-170 75.2-170 168v224c0 92.8 76.1 168 170 168zm-94-392c0-50.6 41.9-92 94-92s94 41.4 94 92v224c0 50.6-41.9 92-94 92s-94-41.4-94-92V232z" } }] }, "name": "audio", "theme": "outlined" };
1250
1250
 
1251
- function _objectSpread$4(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$4(target, key, source[key]); }); } return target; }
1251
+ function _objectSpread$3(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$3(target, key, source[key]); }); } return target; }
1252
1252
 
1253
- function _defineProperty$4(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1253
+ function _defineProperty$3(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1254
1254
 
1255
1255
  var AudioOutlined = function AudioOutlined(props, context) {
1256
- var p = _objectSpread$4({}, props, context.attrs);
1256
+ var p = _objectSpread$3({}, props, context.attrs);
1257
1257
 
1258
- return createVNode(Icon, _objectSpread$4({}, p, {
1258
+ return createVNode(Icon, _objectSpread$3({}, p, {
1259
1259
  "icon": AudioOutlined$2
1260
1260
  }), null);
1261
1261
  };
@@ -1267,14 +1267,14 @@ var AudioOutlined$1 = AudioOutlined;
1267
1267
  // This icon file is generated automatically.
1268
1268
  var CloseOutlined$1 = { "icon": { "tag": "svg", "attrs": { "fill-rule": "evenodd", "viewBox": "64 64 896 896", "focusable": "false" }, "children": [{ "tag": "path", "attrs": { "d": "M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z" } }] }, "name": "close", "theme": "outlined" };
1269
1269
 
1270
- function _objectSpread$3(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$3(target, key, source[key]); }); } return target; }
1270
+ function _objectSpread$2(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$2(target, key, source[key]); }); } return target; }
1271
1271
 
1272
- function _defineProperty$3(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1272
+ function _defineProperty$2(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1273
1273
 
1274
1274
  var CloseOutlined = function CloseOutlined(props, context) {
1275
- var p = _objectSpread$3({}, props, context.attrs);
1275
+ var p = _objectSpread$2({}, props, context.attrs);
1276
1276
 
1277
- return createVNode(Icon, _objectSpread$3({}, p, {
1277
+ return createVNode(Icon, _objectSpread$2({}, p, {
1278
1278
  "icon": CloseOutlined$1
1279
1279
  }), null);
1280
1280
  };
@@ -1285,14 +1285,14 @@ CloseOutlined.inheritAttrs = false;
1285
1285
  // This icon file is generated automatically.
1286
1286
  var CloudUploadOutlined$1 = { "icon": { "tag": "svg", "attrs": { "viewBox": "64 64 896 896", "focusable": "false" }, "children": [{ "tag": "path", "attrs": { "d": "M518.3 459a8 8 0 00-12.6 0l-112 141.7a7.98 7.98 0 006.3 12.9h73.9V856c0 4.4 3.6 8 8 8h60c4.4 0 8-3.6 8-8V613.7H624c6.7 0 10.4-7.7 6.3-12.9L518.3 459z" } }, { "tag": "path", "attrs": { "d": "M811.4 366.7C765.6 245.9 648.9 160 512.2 160S258.8 245.8 213 366.6C127.3 389.1 64 467.2 64 560c0 110.5 89.5 200 199.9 200H304c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8h-40.1c-33.7 0-65.4-13.4-89-37.7-23.5-24.2-36-56.8-34.9-90.6.9-26.4 9.9-51.2 26.2-72.1 16.7-21.3 40.1-36.8 66.1-43.7l37.9-9.9 13.9-36.6c8.6-22.8 20.6-44.1 35.7-63.4a245.6 245.6 0 0152.4-49.9c41.1-28.9 89.5-44.2 140-44.2s98.9 15.3 140 44.2c19.9 14 37.5 30.8 52.4 49.9 15.1 19.3 27.1 40.7 35.7 63.4l13.8 36.5 37.8 10C846.1 454.5 884 503.8 884 560c0 33.1-12.9 64.3-36.3 87.7a123.07 123.07 0 01-87.6 36.3H720c-4.4 0-8 3.6-8 8v60c0 4.4 3.6 8 8 8h40.1C870.5 760 960 670.5 960 560c0-92.7-63.1-170.7-148.6-193.3z" } }] }, "name": "cloud-upload", "theme": "outlined" };
1287
1287
 
1288
- function _objectSpread$2(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$2(target, key, source[key]); }); } return target; }
1288
+ function _objectSpread$1(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$1(target, key, source[key]); }); } return target; }
1289
1289
 
1290
- function _defineProperty$2(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1290
+ function _defineProperty$1(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1291
1291
 
1292
1292
  var CloudUploadOutlined = function CloudUploadOutlined(props, context) {
1293
- var p = _objectSpread$2({}, props, context.attrs);
1293
+ var p = _objectSpread$1({}, props, context.attrs);
1294
1294
 
1295
- return createVNode(Icon, _objectSpread$2({}, p, {
1295
+ return createVNode(Icon, _objectSpread$1({}, p, {
1296
1296
  "icon": CloudUploadOutlined$1
1297
1297
  }), null);
1298
1298
  };
@@ -1303,37 +1303,19 @@ CloudUploadOutlined.inheritAttrs = false;
1303
1303
  // This icon file is generated automatically.
1304
1304
  var LinkOutlined$1 = { "icon": { "tag": "svg", "attrs": { "viewBox": "64 64 896 896", "focusable": "false" }, "children": [{ "tag": "path", "attrs": { "d": "M574 665.4a8.03 8.03 0 00-11.3 0L446.5 781.6c-53.8 53.8-144.6 59.5-204 0-59.5-59.5-53.8-150.2 0-204l116.2-116.2c3.1-3.1 3.1-8.2 0-11.3l-39.8-39.8a8.03 8.03 0 00-11.3 0L191.4 526.5c-84.6 84.6-84.6 221.5 0 306s221.5 84.6 306 0l116.2-116.2c3.1-3.1 3.1-8.2 0-11.3L574 665.4zm258.6-474c-84.6-84.6-221.5-84.6-306 0L410.3 307.6a8.03 8.03 0 000 11.3l39.7 39.7c3.1 3.1 8.2 3.1 11.3 0l116.2-116.2c53.8-53.8 144.6-59.5 204 0 59.5 59.5 53.8 150.2 0 204L665.3 562.6a8.03 8.03 0 000 11.3l39.8 39.8c3.1 3.1 8.2 3.1 11.3 0l116.2-116.2c84.5-84.6 84.5-221.5 0-306.1zM610.1 372.3a8.03 8.03 0 00-11.3 0L372.3 598.7a8.03 8.03 0 000 11.3l39.6 39.6c3.1 3.1 8.2 3.1 11.3 0l226.4-226.4c3.1-3.1 3.1-8.2 0-11.3l-39.5-39.6z" } }] }, "name": "link", "theme": "outlined" };
1305
1305
 
1306
- function _objectSpread$1(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty$1(target, key, source[key]); }); } return target; }
1307
-
1308
- function _defineProperty$1(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1309
-
1310
- var LinkOutlined = function LinkOutlined(props, context) {
1311
- var p = _objectSpread$1({}, props, context.attrs);
1312
-
1313
- return createVNode(Icon, _objectSpread$1({}, p, {
1314
- "icon": LinkOutlined$1
1315
- }), null);
1316
- };
1317
-
1318
- LinkOutlined.displayName = 'LinkOutlined';
1319
- LinkOutlined.inheritAttrs = false;
1320
-
1321
- // This icon file is generated automatically.
1322
- var SendOutlined$1 = { "icon": { "tag": "svg", "attrs": { "viewBox": "64 64 896 896", "focusable": "false" }, "children": [{ "tag": "defs", "attrs": {}, "children": [{ "tag": "style", "attrs": {} }] }, { "tag": "path", "attrs": { "d": "M931.4 498.9L94.9 79.5c-3.4-1.7-7.3-2.1-11-1.2a15.99 15.99 0 00-11.7 19.3l86.2 352.2c1.3 5.3 5.2 9.6 10.4 11.3l147.7 50.7-147.6 50.7c-5.2 1.8-9.1 6-10.3 11.3L72.2 926.5c-.9 3.7-.5 7.6 1.2 10.9 3.9 7.9 13.5 11.1 21.5 7.2l836.5-417c3.1-1.5 5.6-4.1 7.2-7.1 3.9-8 .7-17.6-7.2-21.6zM170.8 826.3l50.3-205.6 295.2-101.3c2.3-.8 4.2-2.6 5-5 1.4-4.2-.8-8.7-5-10.2L221.1 403 171 198.2l628 314.9-628.2 313.2z" } }] }, "name": "send", "theme": "outlined" };
1323
-
1324
1306
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty(target, key, source[key]); }); } return target; }
1325
1307
 
1326
1308
  function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
1327
1309
 
1328
- var SendOutlined = function SendOutlined(props, context) {
1310
+ var LinkOutlined = function LinkOutlined(props, context) {
1329
1311
  var p = _objectSpread({}, props, context.attrs);
1330
1312
 
1331
1313
  return createVNode(Icon, _objectSpread({}, p, {
1332
- "icon": SendOutlined$1
1314
+ "icon": LinkOutlined$1
1333
1315
  }), null);
1334
1316
  };
1335
1317
 
1336
- SendOutlined.displayName = 'SendOutlined';
1337
- SendOutlined.inheritAttrs = false;
1318
+ LinkOutlined.displayName = 'LinkOutlined';
1319
+ LinkOutlined.inheritAttrs = false;
1338
1320
 
1339
- export { AudioMutedOutlined$1 as A, CloseOutlined as C, LinkOutlined as L, SendOutlined as S, CloudUploadOutlined as a, AudioOutlined$1 as b };
1321
+ export { AudioMutedOutlined$1 as A, CloseOutlined as C, LinkOutlined as L, CloudUploadOutlined as a, AudioOutlined$1 as b };
@@ -0,0 +1,8 @@
1
+ import VkAgentChatProvider from './src/index.vue';
2
+ export * from './src/const';
3
+ export * from './src/const-roles';
4
+ export { type MessageView, MessageViewManager } from './src/MessageView';
5
+ export * as __VkAgentChatProvider from './src/types';
6
+ export { useAgentChat } from './src/use';
7
+ export { VkAgentChatProvider, };
8
+ export default VkAgentChatProvider;
@@ -0,0 +1,29 @@
1
+ export interface MessageView {
2
+ content: string;
3
+ type: string;
4
+ updating: boolean;
5
+ }
6
+ export declare class MessageViewManager {
7
+ private views;
8
+ getViews(): MessageView[];
9
+ createView(view: MessageView): void;
10
+ /**
11
+ * @description 创建或更新最后一个 view
12
+ */
13
+ upsertView(data: MessageView, callbacks?: {
14
+ onCreate?: (view: MessageView) => void;
15
+ onUpdate?: (view: MessageView) => void;
16
+ }): MessageView;
17
+ /**
18
+ * @description 获取当前view 的上一个 view
19
+ */
20
+ getPrevView(view: MessageView): MessageView | undefined;
21
+ /**
22
+ * @description 获取最后一个正在更新的 view
23
+ */
24
+ getLastUpdatingView(type: string): MessageView | undefined;
25
+ /**
26
+ * @description 所有 view 更新结束
27
+ */
28
+ allViewUpdated(): void;
29
+ }
@@ -0,0 +1,3 @@
1
+ import type { NormalObject } from '@vunk/shared';
2
+ import type { RestFetchReaderOnmessage } from '@vunk/shared/fetch';
3
+ export declare function agentRequest(onmessage: RestFetchReaderOnmessage, data: NormalObject): Promise<void>;
@@ -0,0 +1,8 @@
1
+ import type { RoleMedia } from './types';
2
+ export declare enum Role {
3
+ User = "user",
4
+ Assistant = "assistant",
5
+ Broadcasting = "broadcasting"
6
+ }
7
+ export declare const roleOptions: RoleMedia[];
8
+ export declare const roleMap: Record<Role, RoleMedia>;
@@ -0,0 +1 @@
1
+ export declare const ChatAgentInjectKey = "vk_agent_chat_inject_key";
@@ -0,0 +1,22 @@
1
+ import type { AnyFunc } from '@vunk/shared';
2
+ import type { PropType } from 'vue';
3
+ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
4
+ request: {
5
+ type: PropType<AnyFunc>;
6
+ };
7
+ parser: {
8
+ type: PropType<AnyFunc>;
9
+ };
10
+ }>, import("vue").Slot<any> | undefined, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
11
+ load: null;
12
+ }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
13
+ request: {
14
+ type: PropType<AnyFunc>;
15
+ };
16
+ parser: {
17
+ type: PropType<AnyFunc>;
18
+ };
19
+ }>> & Readonly<{
20
+ onLoad?: ((...args: any[]) => any) | undefined;
21
+ }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
22
+ export default _default;
@@ -0,0 +1,56 @@
1
+ import type { __VkBubbleTemplates } from '@vunk/plus/components/bubble-templates';
2
+ import type { MaybeArray, Media, NormalObject } from '@vunk/shared';
3
+ import type { RequestFn, SSEOutput, useXChat, XAgent, XRequestParams } from 'ant-design-x-vue';
4
+ import type { ComputedRef } from 'vue';
5
+ import type { BubbleListItemProps } from 'vue-element-plus-x/types/components/BubbleList/types';
6
+ import type { MessageView } from './MessageView';
7
+ export type RequestParams<Message> = Omit<XRequestParams, 'message'> & {
8
+ message: Message;
9
+ messages?: Message[];
10
+ } & NormalObject;
11
+ export interface AgentChatContext {
12
+ agent: ComputedRef<XAgent<AgentMessage>>;
13
+ chat: ReturnType<typeof useXChat<AgentMessage, BubbleMessage>>;
14
+ simplicity: {
15
+ onRequest: (message: string) => void;
16
+ items: ComputedRef<BubbleItem[]>;
17
+ };
18
+ }
19
+ export type Request = RequestFn<AgentMessage, RequestParams<AgentMessage>, RequestOutput>;
20
+ export type Parser = (message: Partial<AgentMessage>) => MaybeArray<BubbleMessage>;
21
+ export type RequestOutput = AgentMessage & SSEOutput;
22
+ /**
23
+ * @description useXAgent request onSuccess 发送的数据
24
+ */
25
+ export type AgentMessage = Partial<BubbleMessage> & {
26
+ seviceLoading?: boolean;
27
+ seviceEnd?: boolean;
28
+ views?: MessageView[];
29
+ };
30
+ /**
31
+ * @description useXChat parser 解析数据
32
+ */
33
+ export type BubbleMessage = Partial<BubbleListItemProps> & {
34
+ role: string;
35
+ content: string;
36
+ /**
37
+ * @description 服务端请求是否完成
38
+ */
39
+ seviceEnd?: boolean;
40
+ thinkingStatus?: 'start' | 'thinking' | 'end' | 'error';
41
+ thinkingContent?: string;
42
+ meta?: NormalObject;
43
+ abortController?: AbortController;
44
+ templateType?: string;
45
+ [key: string]: any;
46
+ };
47
+ export type BubbleItem = BubbleItemBasic & __VkBubbleTemplates.RenderItem;
48
+ export type RoleMedia = RoleMediaBasic & __VkBubbleTemplates.RenderItem;
49
+ export type BubbleItemModule = 'Thinking';
50
+ export interface BubbleItemBasic extends BubbleMessage {
51
+ key: string;
52
+ modules?: BubbleItemModule[];
53
+ }
54
+ export interface RoleMediaBasic extends Partial<BubbleItemBasic>, Media {
55
+ value: string;
56
+ }
@@ -0,0 +1,6 @@
1
+ import type { SSEOutput } from 'ant-design-x-vue';
2
+ import type { AgentChatContext, AgentMessage, Parser, Request, RequestParams } from './types';
3
+ import { useXAgent } from 'ant-design-x-vue';
4
+ export declare function useAgent(request: Request): ReturnType<typeof useXAgent<AgentMessage, RequestParams<AgentMessage>, AgentMessage & SSEOutput>>;
5
+ export declare function initAgentChat(request: Request, parser: Parser): AgentChatContext;
6
+ export declare function useAgentChat(): AgentChatContext;
@@ -0,0 +1,4 @@
1
+ import VkAvatar from './src/index.vue';
2
+ export * as __VkAvatar from './src/types';
3
+ export { VkAvatar, };
4
+ export default VkAvatar;
@@ -0,0 +1,6 @@
1
+ import type { avatarProps } from 'element-plus';
2
+ export declare const props: typeof avatarProps & {
3
+ background: never;
4
+ color: never;
5
+ };
6
+ export declare const emits: {};