@opentiny/tiny-robot 0.1.0-alpha.0 → 0.2.0-alpha.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.
Files changed (244) hide show
  1. package/dist/{bubble-item → bubble}/components/actions/copy.vue.d.ts +3 -3
  2. package/dist/{bubble-item → bubble}/components/actions/refresh.vue.d.ts +1 -1
  3. package/dist/bubble/index.d.ts +12 -0
  4. package/dist/bubble/index.type.d.ts +53 -0
  5. package/dist/bubble/useScroll.d.ts +4 -0
  6. package/dist/container/index.d.ts +7 -0
  7. package/dist/container/index.type.d.ts +16 -0
  8. package/dist/container/index.vue.d.ts +26 -0
  9. package/dist/index.d.ts +10 -5
  10. package/dist/index.js +31 -20
  11. package/dist/node_modules/.pnpm/@opentiny_utils@1.0.0/node_modules/@opentiny/utils/dist/opentiny-utils.es.js +832 -0
  12. package/dist/node_modules/.pnpm/@opentiny_utils@3.22.0/node_modules/@opentiny/utils/dist/index.es.js +959 -1496
  13. package/dist/node_modules/.pnpm/{@opentiny_vue-button@3.22.0 → @opentiny_vue-button@3.21.0}/node_modules/@opentiny/vue-button/lib/index.js +21 -21
  14. package/dist/node_modules/.pnpm/{@opentiny_vue-button@3.22.0 → @opentiny_vue-button@3.21.0}/node_modules/@opentiny/vue-button/lib/pc.js +3 -3
  15. package/dist/node_modules/.pnpm/@opentiny_vue-common@3.21.0/node_modules/@opentiny/vue-common/lib/index.js +727 -0
  16. package/dist/node_modules/.pnpm/@opentiny_vue-common@3.22.0/node_modules/@opentiny/vue-common/lib/index.js +144 -675
  17. package/dist/node_modules/.pnpm/{@opentiny_vue-dialog-box@3.22.0 → @opentiny_vue-dialog-box@3.21.0}/node_modules/@opentiny/vue-dialog-box/lib/index.js +9 -9
  18. package/dist/node_modules/.pnpm/{@opentiny_vue-dialog-box@3.22.0 → @opentiny_vue-dialog-box@3.21.0}/node_modules/@opentiny/vue-dialog-box/lib/pc.js +5 -5
  19. package/dist/node_modules/.pnpm/@opentiny_vue-icon@3.21.0/node_modules/@opentiny/vue-icon/lib/close.js +29 -0
  20. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/eyeclose.js +1 -1
  21. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/eyeopen.js +1 -1
  22. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/finish.js +1 -1
  23. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/fullscreen.js +1 -1
  24. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/loading-shadow.js +21 -22
  25. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/minscreen.js +1 -1
  26. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-add-column-after.js +1 -1
  27. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-add-column-before.js +1 -1
  28. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-add-row-after.js +1 -1
  29. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-add-row-before.js +1 -1
  30. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-align-center.js +1 -1
  31. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-align-left.js +1 -1
  32. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-align-right.js +1 -1
  33. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-bold.js +1 -1
  34. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-code-block.js +1 -1
  35. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-code-view.js +1 -1
  36. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-color.js +1 -1
  37. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-delete-column.js +1 -1
  38. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-delete-row.js +1 -1
  39. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-delete-table.js +1 -1
  40. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-font-size.js +1 -1
  41. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-format-clear.js +1 -1
  42. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-h1.js +1 -1
  43. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-h2.js +1 -1
  44. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-h3.js +1 -1
  45. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-h4.js +1 -1
  46. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-h5.js +1 -1
  47. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-h6.js +1 -1
  48. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-heading.js +1 -1
  49. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-high-light.js +1 -1
  50. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-image.js +1 -1
  51. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-italic.js +1 -1
  52. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-line-height.js +1 -1
  53. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-link-unlink.js +1 -1
  54. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-link.js +1 -1
  55. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-list-ordered.js +1 -1
  56. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-list-unordered.js +1 -1
  57. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-merge-cells-vertical.js +1 -1
  58. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-merge-cells.js +1 -1
  59. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-node-delete.js +1 -1
  60. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-paragraph.js +1 -1
  61. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-quote-text.js +1 -1
  62. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-redo.js +1 -1
  63. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-split-cells-horizontal.js +1 -1
  64. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-split-cells-vertical.js +1 -1
  65. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-strike-through.js +1 -1
  66. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-subscript.js +1 -1
  67. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-superscript.js +1 -1
  68. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-table.js +1 -1
  69. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-task-list.js +1 -1
  70. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-underline.js +1 -1
  71. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/rich-text-undo.js +1 -1
  72. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/sub-script.js +1 -1
  73. package/dist/node_modules/.pnpm/{@opentiny_vue-icon@3.22.0 → @opentiny_vue-icon@3.21.0}/node_modules/@opentiny/vue-icon/lib/warn.js +1 -1
  74. package/dist/node_modules/.pnpm/{@opentiny_vue-input@3.22.0 → @opentiny_vue-input@3.21.0}/node_modules/@opentiny/vue-input/lib/index.js +3 -3
  75. package/dist/node_modules/.pnpm/{@opentiny_vue-input@3.22.0 → @opentiny_vue-input@3.21.0}/node_modules/@opentiny/vue-input/lib/pc.js +36 -36
  76. package/dist/node_modules/.pnpm/{@opentiny_vue-locale@3.22.0 → @opentiny_vue-locale@3.21.0}/node_modules/@opentiny/vue-locale/lib/index.js +63 -63
  77. package/dist/node_modules/.pnpm/{@opentiny_vue-renderless@3.22.0 → @opentiny_vue-renderless@3.21.2}/node_modules/@opentiny/vue-renderless/button/index.js +1 -1
  78. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/browser.js +36 -0
  79. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/deps/clickoutside.js +47 -0
  80. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/deps/debounce.js +7 -0
  81. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/deps/dom.js +45 -0
  82. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/deps/popper.js +320 -0
  83. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/deps/popup-manager.js +118 -0
  84. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/deps/throttle.js +23 -0
  85. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/deps/useEventListener.js +9 -0
  86. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/deps/useInstanceSlots.js +14 -0
  87. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/deps/useRelation.js +54 -0
  88. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/deps/vue-popper.js +84 -0
  89. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/deps/vue-popup.js +73 -0
  90. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/event.js +13 -0
  91. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/function.js +5 -0
  92. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/index.js +11 -0
  93. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/object.js +84 -0
  94. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/string.js +28 -0
  95. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/common/type.js +28 -0
  96. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/dialog-box/index.js +136 -0
  97. package/dist/node_modules/.pnpm/{@opentiny_vue-renderless@3.22.0 → @opentiny_vue-renderless@3.21.2}/node_modules/@opentiny/vue-renderless/dialog-box/vue.js +33 -34
  98. package/dist/node_modules/.pnpm/{@opentiny_vue-renderless@3.22.0 → @opentiny_vue-renderless@3.21.2}/node_modules/@opentiny/vue-renderless/input/index.js +22 -22
  99. package/dist/node_modules/.pnpm/{@opentiny_vue-renderless@3.22.0 → @opentiny_vue-renderless@3.21.2}/node_modules/@opentiny/vue-renderless/input/vue.js +9 -9
  100. package/dist/node_modules/.pnpm/{@opentiny_vue-renderless@3.22.0 → @opentiny_vue-renderless@3.21.2}/node_modules/@opentiny/vue-renderless/tall-storage/index.js +1 -1
  101. package/dist/node_modules/.pnpm/{@opentiny_vue-renderless@3.22.0 → @opentiny_vue-renderless@3.21.2}/node_modules/@opentiny/vue-renderless/tall-storage/vue.js +5 -5
  102. package/dist/node_modules/.pnpm/{@opentiny_vue-renderless@3.22.0 → @opentiny_vue-renderless@3.21.2}/node_modules/@opentiny/vue-renderless/tooltip/index.js +41 -40
  103. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.21.2/node_modules/@opentiny/vue-renderless/tooltip/vue.js +90 -0
  104. package/dist/node_modules/.pnpm/{@opentiny_vue-tooltip@3.22.0 → @opentiny_vue-tooltip@3.21.0}/node_modules/@opentiny/vue-tooltip/lib/index.js +3 -6
  105. package/dist/node_modules/.pnpm/{@opentiny_vue-tooltip@3.22.0 → @opentiny_vue-tooltip@3.21.0}/node_modules/@opentiny/vue-tooltip/lib/pc.js +2 -2
  106. package/dist/packages/components/src/{bubble-list → bubble}/bubble-list.vue.js +2 -2
  107. package/dist/packages/components/src/bubble/bubble-list.vue2.js +37 -0
  108. package/dist/packages/components/src/bubble/bubble.vue.js +7 -0
  109. package/dist/packages/components/src/bubble/bubble.vue2.js +118 -0
  110. package/dist/packages/components/src/bubble/components/actions/copy.vue.js +7 -0
  111. package/dist/packages/components/src/bubble/components/actions/copy.vue2.js +35 -0
  112. package/dist/packages/components/src/bubble/components/actions/refresh.vue.js +7 -0
  113. package/dist/packages/components/src/bubble/components/actions/refresh.vue2.js +16 -0
  114. package/dist/packages/components/src/bubble/index.js +18 -0
  115. package/dist/packages/components/src/bubble/useScroll.js +13 -0
  116. package/dist/packages/components/src/container/index.js +9 -0
  117. package/dist/packages/components/src/container/index.vue.js +7 -0
  118. package/dist/packages/components/src/container/index.vue2.js +55 -0
  119. package/dist/packages/components/src/conversations/index.js +1 -1
  120. package/dist/packages/components/src/prompts/index.js +18 -0
  121. package/dist/packages/components/src/prompts/prompt.vue.js +7 -0
  122. package/dist/packages/components/src/prompts/prompt.vue2.js +37 -0
  123. package/dist/packages/components/src/prompts/prompts.vue.js +7 -0
  124. package/dist/packages/components/src/prompts/prompts.vue2.js +36 -0
  125. package/dist/packages/components/src/question/components/CommonQuestions.vue.js +89 -0
  126. package/dist/packages/components/src/question/components/CommonQuestions.vue2.js +4 -0
  127. package/dist/packages/components/src/question/components/HotQuestions.vue.js +140 -0
  128. package/dist/packages/components/src/question/components/HotQuestions.vue2.js +4 -0
  129. package/dist/packages/components/src/question/composables/useQuestions.js +48 -0
  130. package/dist/packages/components/src/question/index.js +9 -0
  131. package/dist/packages/components/src/question/index.vue.js +113 -0
  132. package/dist/packages/components/src/question/index.vue2.js +4 -0
  133. package/dist/packages/components/src/sender/components/ActionButtons.vue.js +105 -123
  134. package/dist/packages/components/src/sender/composables/useInputHandler.js +26 -22
  135. package/dist/packages/components/src/sender/composables/useKeyboardHandler.js +11 -11
  136. package/dist/packages/components/src/sender/composables/useSpeechHandler.js +9 -9
  137. package/dist/packages/components/src/sender/index.vue.js +67 -66
  138. package/dist/packages/components/src/welcome/index.vue.js +5 -7
  139. package/dist/packages/components/src/welcome/index.vue2.js +32 -0
  140. package/dist/packages/svgs/dist/tiny-robot-svgs.js +223 -0
  141. package/dist/prompts/index.d.ts +12 -0
  142. package/dist/prompts/index.type.d.ts +55 -0
  143. package/dist/prompts/prompt.vue.d.ts +3 -0
  144. package/dist/prompts/prompts.vue.d.ts +20 -0
  145. package/dist/question/components/CommonQuestions.vue.d.ts +32 -0
  146. package/dist/question/components/HotQuestions.vue.d.ts +89 -0
  147. package/dist/question/composables/useQuestions.d.ts +17 -0
  148. package/dist/question/index.d.ts +7 -0
  149. package/dist/question/index.type.d.ts +74 -0
  150. package/dist/question/index.vue.d.ts +46 -0
  151. package/dist/sender/components/ActionButtons.vue.d.ts +6 -4
  152. package/dist/sender/composables/useSpeechHandler.d.ts +0 -6
  153. package/dist/sender/index.type.d.ts +1 -1
  154. package/dist/sender/index.vue.d.ts +3 -4
  155. package/dist/style.css +1 -1
  156. package/dist/welcome/index.type.d.ts +10 -0
  157. package/dist/welcome/index.vue.d.ts +17 -1
  158. package/package.json +6 -5
  159. package/src/bubble/bubble-list.vue +42 -0
  160. package/src/bubble/bubble.vue +247 -0
  161. package/src/bubble/components/actions/copy.vue +54 -0
  162. package/src/bubble/components/actions/refresh.vue +31 -0
  163. package/src/bubble/index.ts +23 -0
  164. package/src/bubble/index.type.ts +63 -0
  165. package/src/bubble/useScroll.ts +14 -0
  166. package/src/container/index.ts +12 -0
  167. package/src/container/index.type.ts +17 -0
  168. package/src/container/index.vue +135 -0
  169. package/src/conversations/index.ts +1 -1
  170. package/src/index.ts +26 -12
  171. package/src/prompts/index.ts +25 -0
  172. package/src/prompts/index.type.ts +59 -0
  173. package/src/prompts/prompt.vue +115 -0
  174. package/src/prompts/prompts.vue +50 -0
  175. package/src/question/components/CommonQuestions.vue +146 -0
  176. package/src/question/components/HotQuestions.vue +148 -0
  177. package/src/question/composables/useQuestions.ts +106 -0
  178. package/src/question/index.less +448 -0
  179. package/src/question/index.ts +12 -0
  180. package/src/question/index.type.ts +86 -0
  181. package/src/question/index.vue +140 -0
  182. package/src/question/vars.less +135 -0
  183. package/src/sender/components/ActionButtons.vue +42 -39
  184. package/src/sender/composables/useInputHandler.ts +15 -10
  185. package/src/sender/composables/useKeyboardHandler.ts +6 -4
  186. package/src/sender/composables/useSpeechHandler.ts +5 -11
  187. package/src/sender/index.less +3 -5
  188. package/src/sender/index.type.ts +1 -1
  189. package/src/sender/index.vue +3 -2
  190. package/src/welcome/index.type.ts +12 -0
  191. package/src/welcome/index.vue +68 -2
  192. package/.vscode/extensions.json +0 -3
  193. package/dist/bubble-item/components/icons/ai.vue.d.ts +0 -2
  194. package/dist/bubble-item/components/icons/index.d.ts +0 -2
  195. package/dist/bubble-item/components/icons/user.vue.d.ts +0 -2
  196. package/dist/bubble-item/index.d.ts +0 -7
  197. package/dist/bubble-list/index.d.ts +0 -8
  198. package/dist/bubble-list/index.type.d.ts +0 -55
  199. package/dist/node_modules/.pnpm/@opentiny_vue-directive@3.22.0/node_modules/@opentiny/vue-directive/index.js +0 -57
  200. package/dist/node_modules/.pnpm/@opentiny_vue-hooks@3.22.0/node_modules/@opentiny/vue-hooks/dist/src/vue-popper.js +0 -85
  201. package/dist/node_modules/.pnpm/@opentiny_vue-hooks@3.22.0/node_modules/@opentiny/vue-hooks/dist/src/vue-popup.js +0 -69
  202. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.22.0/node_modules/@opentiny/vue-renderless/dialog-box/index.js +0 -135
  203. package/dist/node_modules/.pnpm/@opentiny_vue-renderless@3.22.0/node_modules/@opentiny/vue-renderless/tooltip/vue.js +0 -90
  204. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Symbol.js +0 -5
  205. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseGetTag.js +0 -10
  206. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseTrim.js +0 -8
  207. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_freeGlobal.js +0 -4
  208. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getRawTag.js +0 -15
  209. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_objectToString.js +0 -7
  210. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_root.js +0 -5
  211. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_trimmedEndIndex.js +0 -9
  212. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/debounce.js +0 -54
  213. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/isObject.js +0 -7
  214. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/isObjectLike.js +0 -6
  215. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/isSymbol.js +0 -9
  216. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/now.js +0 -7
  217. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/toNumber.js +0 -22
  218. package/dist/packages/components/src/bubble-item/bubble-item.vue.js +0 -7
  219. package/dist/packages/components/src/bubble-item/bubble-item.vue2.js +0 -111
  220. package/dist/packages/components/src/bubble-item/components/actions/copy.vue.js +0 -46
  221. package/dist/packages/components/src/bubble-item/components/actions/copy.vue2.js +0 -4
  222. package/dist/packages/components/src/bubble-item/components/actions/refresh.vue.js +0 -12
  223. package/dist/packages/components/src/bubble-item/components/icons/ai.vue.js +0 -45
  224. package/dist/packages/components/src/bubble-item/components/icons/user.vue.js +0 -63
  225. package/dist/packages/components/src/bubble-item/index.js +0 -9
  226. package/dist/packages/components/src/bubble-list/bubble-list.vue2.js +0 -52
  227. package/dist/packages/components/src/bubble-list/index.js +0 -9
  228. package/src/bubble-item/bubble-item.vue +0 -264
  229. package/src/bubble-item/components/actions/copy.vue +0 -47
  230. package/src/bubble-item/components/actions/refresh.vue +0 -27
  231. package/src/bubble-item/components/icons/ai.vue +0 -30
  232. package/src/bubble-item/components/icons/index.ts +0 -2
  233. package/src/bubble-item/components/icons/user.vue +0 -78
  234. package/src/bubble-item/index.ts +0 -12
  235. package/src/bubble-list/bubble-list.vue +0 -53
  236. package/src/bubble-list/index.ts +0 -14
  237. package/src/bubble-list/index.type.ts +0 -65
  238. package/src/sender/global.d.ts +0 -44
  239. /package/dist/{bubble-list → bubble}/bubble-list.vue.d.ts +0 -0
  240. /package/dist/{bubble-item → bubble}/components/actions/index.d.ts +0 -0
  241. /package/dist/node_modules/.pnpm/{@opentiny_vue-renderless@3.22.0 → @opentiny_vue-renderless@3.21.2}/node_modules/@opentiny/vue-renderless/button/vue.js +0 -0
  242. /package/dist/node_modules/.pnpm/{@opentiny_vue-renderless@3.22.0 → @opentiny_vue-renderless@3.21.2}/node_modules/@opentiny/vue-renderless/chunk-G2ADBYYC.js +0 -0
  243. /package/dist/node_modules/.pnpm/{@opentiny_vue-renderless@3.22.0 → @opentiny_vue-renderless@3.21.2}/node_modules/@opentiny/vue-renderless/tall-storage/vue-storage-box.js +0 -0
  244. /package/src/{bubble-item → bubble}/components/actions/index.ts +0 -0
@@ -1,18 +1,17 @@
1
- import { defineComponent as T, computed as n, createElementBlock as i, openBlock as t, createBlock as c, createCommentVNode as d, unref as o, withCtx as l, createVNode as r, createElementVNode as g, normalizeClass as R, resolveDynamicComponent as E } from "vue";
2
- import N from "../../assets/icons/accessory.svg.js";
1
+ import { defineComponent as R, computed as m, resolveComponent as E, createElementBlock as d, openBlock as t, createBlock as s, createCommentVNode as r, withCtx as l, createVNode as g, unref as a, createElementVNode as f, normalizeClass as y, resolveDynamicComponent as N } from "vue";
2
+ import T from "../../assets/icons/accessory.svg.js";
3
3
  import V from "../../assets/icons/voice.svg.js";
4
4
  import D from "../../assets/icons/loading-speech.svg.js";
5
5
  import F from "../../assets/icons/send.svg.js";
6
6
  import q from "../../assets/icons/loading.svg.js";
7
- import u from "../../../../../node_modules/.pnpm/@opentiny_vue-button@3.22.0/node_modules/@opentiny/vue-button/lib/index.js";
8
- import p from "../../../../../node_modules/.pnpm/@opentiny_vue-tooltip@3.22.0/node_modules/@opentiny/vue-tooltip/lib/index.js";
9
- import x from "../../../../../node_modules/.pnpm/@opentiny_vue-icon@3.22.0/node_modules/@opentiny/vue-icon/lib/close.js";
10
- const z = { class: "action-buttons" }, A = {
7
+ import u from "../../../../../node_modules/.pnpm/@opentiny_vue-button@3.21.0/node_modules/@opentiny/vue-button/lib/index.js";
8
+ import z from "../../../../../node_modules/.pnpm/@opentiny_vue-icon@3.22.0/node_modules/@opentiny/vue-icon/lib/close.js";
9
+ const A = { class: "action-buttons" }, I = {
11
10
  key: 0,
12
11
  src: V,
13
12
  class: "button-icon",
14
13
  alt: "录音"
15
- }, I = {
14
+ }, $ = {
16
15
  key: 1,
17
16
  src: D,
18
17
  class: "button-icon recording-icon",
@@ -21,12 +20,7 @@ const z = { class: "action-buttons" }, A = {
21
20
  key: 0,
22
21
  src: F,
23
22
  alt: "发送"
24
- }, H = {
25
- key: 1,
26
- src: q,
27
- alt: "加载中",
28
- class: "loading"
29
- }, X = /* @__PURE__ */ T({
23
+ }, W = /* @__PURE__ */ R({
30
24
  __name: "ActionButtons",
31
25
  props: {
32
26
  loading: { type: Boolean, default: !1 },
@@ -42,120 +36,108 @@ const z = { class: "action-buttons" }, A = {
42
36
  submitType: { default: "enter" },
43
37
  showShortcuts: { type: Boolean }
44
38
  },
45
- emits: {
46
- /**
47
- * 清除内容事件
48
- */
49
- clear: () => !0,
50
- /**
51
- * 切换语音识别状态事件
52
- * @param {boolean} state - 新的语音识别状态
53
- */
54
- "toggle-speech": (m) => !!m,
55
- /**
56
- * 提交内容事件
57
- */
58
- submit: () => !0
59
- },
60
- setup(m, { emit: _ }) {
61
- const y = x(), a = m, f = _, v = n(() => a.allowSpeech), C = n(() => a.speechStatus.isRecording ? "停止录音" : "开始语音输入"), h = n(() => a.speechStatus.isRecording), k = n(() => a.loading ? "发送中..." : "发送消息"), s = n(() => a.disabled), B = () => {
62
- s.value || f("clear");
63
- }, S = () => {
64
- if (!s.value) {
65
- const e = !a.speechStatus.isRecording;
66
- f("toggle-speech", e);
39
+ emits: ["clear", "toggle-speech", "submit", "cancel"],
40
+ setup(h, { emit: _ }) {
41
+ const C = z(), i = h, c = _, v = m(() => i.allowSpeech), b = m(() => i.speechStatus.isRecording), o = m(() => i.disabled), k = () => {
42
+ o.value || c("clear");
43
+ }, B = () => {
44
+ if (!o.value) {
45
+ const e = !i.speechStatus.isRecording;
46
+ c("toggle-speech", e);
67
47
  }
48
+ }, S = () => {
49
+ o.value || c("submit");
68
50
  }, w = () => {
69
- s.value || f("submit");
51
+ o.value || c("cancel");
52
+ };
53
+ return (e, n) => {
54
+ const p = E("tiny-tooltip");
55
+ return t(), d("div", A, [
56
+ e.allowFiles && !e.loading ? (t(), s(p, {
57
+ key: 0,
58
+ content: "上传文件",
59
+ placement: "top"
60
+ }, {
61
+ default: l(() => [
62
+ g(a(u), {
63
+ type: "text",
64
+ disabled: o.value
65
+ }, {
66
+ default: l(() => n[1] || (n[1] = [
67
+ f("img", {
68
+ src: T,
69
+ class: "button-icon",
70
+ alt: "上传文件"
71
+ }, null, -1)
72
+ ])),
73
+ _: 1
74
+ }, 8, ["disabled"])
75
+ ]),
76
+ _: 1
77
+ })) : r("", !0),
78
+ v.value && !e.loading ? (t(), s(a(u), {
79
+ key: 1,
80
+ type: "text",
81
+ disabled: o.value,
82
+ onClick: B,
83
+ class: y(["speech-button", { "is-recording": b.value }])
84
+ }, {
85
+ default: l(() => [
86
+ b.value ? (t(), d("img", $)) : (t(), d("img", I))
87
+ ]),
88
+ _: 1
89
+ }, 8, ["disabled", "class"])) : r("", !0),
90
+ e.showClear ? (t(), s(p, {
91
+ key: 2,
92
+ content: "清空内容",
93
+ placement: "top"
94
+ }, {
95
+ default: l(() => [
96
+ g(a(u), {
97
+ type: "text",
98
+ disabled: o.value || !e.hasContent,
99
+ onClick: k,
100
+ style: { "margin-left": "0" }
101
+ }, {
102
+ default: l(() => [
103
+ (t(), s(N(a(C)), { class: "button-icon" }))
104
+ ]),
105
+ _: 1
106
+ }, 8, ["disabled"])
107
+ ]),
108
+ _: 1
109
+ })) : r("", !0),
110
+ e.hasContent || e.loading ? (t(), s(a(u), {
111
+ key: 3,
112
+ type: "text",
113
+ class: y(e.loading ? "cancel-button" : "submit-button"),
114
+ disabled: o.value,
115
+ onClick: n[0] || (n[0] = (H) => e.loading ? w() : S())
116
+ }, {
117
+ default: l(() => [
118
+ f("div", j, [
119
+ e.loading ? (t(), s(p, {
120
+ key: 1,
121
+ content: "停止生成",
122
+ placement: "top"
123
+ }, {
124
+ default: l(() => n[2] || (n[2] = [
125
+ f("img", {
126
+ src: q,
127
+ alt: "加载中",
128
+ class: "loading"
129
+ }, null, -1)
130
+ ])),
131
+ _: 1
132
+ })) : (t(), d("img", G))
133
+ ])
134
+ ]),
135
+ _: 1
136
+ }, 8, ["class", "disabled"])) : r("", !0)
137
+ ]);
70
138
  };
71
- return (e, b) => (t(), i("div", z, [
72
- e.allowFiles && !e.loading ? (t(), c(o(p), {
73
- key: 0,
74
- content: "上传文件",
75
- placement: "top"
76
- }, {
77
- default: l(() => [
78
- r(o(u), {
79
- type: "text",
80
- disabled: s.value
81
- }, {
82
- default: l(() => b[0] || (b[0] = [
83
- g("img", {
84
- src: N,
85
- class: "button-icon",
86
- alt: "上传文件"
87
- }, null, -1)
88
- ])),
89
- _: 1
90
- }, 8, ["disabled"])
91
- ]),
92
- _: 1
93
- })) : d("", !0),
94
- v.value && !e.loading ? (t(), c(o(p), {
95
- key: 1,
96
- content: C.value,
97
- placement: "top"
98
- }, {
99
- default: l(() => [
100
- r(o(u), {
101
- type: "text",
102
- disabled: s.value,
103
- onClick: S,
104
- class: R(["speech-button", { "is-recording": h.value }])
105
- }, {
106
- default: l(() => [
107
- h.value ? (t(), i("img", I)) : (t(), i("img", A))
108
- ]),
109
- _: 1
110
- }, 8, ["disabled", "class"])
111
- ]),
112
- _: 1
113
- }, 8, ["content"])) : d("", !0),
114
- e.showClear ? (t(), c(o(p), {
115
- key: 2,
116
- content: "清空内容",
117
- placement: "top"
118
- }, {
119
- default: l(() => [
120
- r(o(u), {
121
- type: "text",
122
- disabled: s.value || !e.hasContent,
123
- onClick: B,
124
- style: { "margin-left": "0" }
125
- }, {
126
- default: l(() => [
127
- (t(), c(E(o(y)), { class: "button-icon" }))
128
- ]),
129
- _: 1
130
- }, 8, ["disabled"])
131
- ]),
132
- _: 1
133
- })) : d("", !0),
134
- e.hasContent || e.loading ? (t(), c(o(p), {
135
- key: 3,
136
- content: k.value,
137
- placement: "top"
138
- }, {
139
- default: l(() => [
140
- r(o(u), {
141
- type: "text",
142
- onClick: w,
143
- class: "submit-button",
144
- disabled: s.value
145
- }, {
146
- default: l(() => [
147
- g("div", j, [
148
- e.loading ? (t(), i("img", H)) : (t(), i("img", G))
149
- ])
150
- ]),
151
- _: 1
152
- }, 8, ["disabled"])
153
- ]),
154
- _: 1
155
- }, 8, ["content"])) : d("", !0)
156
- ]));
157
139
  }
158
140
  });
159
141
  export {
160
- X as default
142
+ W as default
161
143
  };
@@ -1,28 +1,32 @@
1
- import { ref as n, watch as m } from "vue";
2
- import s from "../../../../../node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/debounce.js";
3
- function h(a, l) {
4
- const u = n(a.defaultValue || ""), o = n(null);
5
- m(
6
- () => a.modelValue,
7
- (e) => {
8
- e !== void 0 && e !== u.value && (u.value = e);
1
+ import { ref as n, watch as o } from "vue";
2
+ function V(u, e) {
3
+ const a = n(u.modelValue || u.defaultValue || ""), c = n(null);
4
+ o(
5
+ () => u.modelValue,
6
+ (l) => {
7
+ l !== void 0 && l !== a.value && (a.value = l);
8
+ }
9
+ ), o(
10
+ () => a.value,
11
+ (l) => {
12
+ e("update:modelValue", l);
9
13
  }
10
14
  );
11
- const d = (e) => {
12
- u.value = e, l("update:modelValue", e);
13
- }, c = s((e) => {
14
- !a.disabled && !a.loading && e.trim() && l("submit", e);
15
- }, a.debounceSubmit), i = (e) => {
16
- e == null || e.preventDefault(), c(u.value);
15
+ const i = (l) => {
16
+ a.value = l, e("update:modelValue", l);
17
+ }, r = (l) => {
18
+ l == null || l.preventDefault();
19
+ const d = a.value;
20
+ !u.disabled && !u.loading && d.trim() && e("submit", d);
17
21
  }, t = () => {
18
- u.value = "", l("update:modelValue", ""), l("clear");
19
- }, r = n(!1);
22
+ a.value = "", e("update:modelValue", ""), e("clear");
23
+ }, s = n(!1);
20
24
  return {
21
- inputValue: u,
22
- inputWrapper: o,
23
- isComposing: r,
24
- handleChange: d,
25
- handleSubmit: i,
25
+ inputValue: a,
26
+ inputWrapper: c,
27
+ isComposing: s,
28
+ handleChange: i,
29
+ handleSubmit: r,
26
30
  handleClear: t,
27
31
  clearInput: () => {
28
32
  t();
@@ -30,5 +34,5 @@ function h(a, l) {
30
34
  };
31
35
  }
32
36
  export {
33
- h as useInputHandler
37
+ V as useInputHandler
34
38
  };
@@ -1,15 +1,15 @@
1
- function h(r, s, t, c, n, l, f) {
2
- const a = (e) => !r.disabled && !r.loading && e.trim().length > 0, i = () => {
3
- a(t.value) && (alert("提交成功"), s("submit", t.value.trim()));
4
- }, o = (e, u) => {
1
+ function h(r, s, t, c, f, a, n) {
2
+ const i = (e) => !r.disabled && !r.loading && e.trim().length > 0, u = () => {
3
+ i(t.value) && s("submit", t.value.trim());
4
+ }, y = (e, l) => {
5
5
  if (!(e.key === "Enter")) return !1;
6
- switch (u) {
6
+ switch (l) {
7
7
  case "enter":
8
- return console.log("enter"), !e.shiftKey && !e.ctrlKey && !e.metaKey;
8
+ return !e.shiftKey && !e.ctrlKey && !e.metaKey;
9
9
  case "ctrlEnter":
10
- return console.log("ctrlEnter"), (e.ctrlKey || e.metaKey) && !e.shiftKey;
10
+ return (e.ctrlKey || e.metaKey) && !e.shiftKey;
11
11
  case "shiftEnter":
12
- return console.log("shiftEnter"), e.shiftKey && !e.ctrlKey && !e.metaKey;
12
+ return e.shiftKey && !e.ctrlKey && !e.metaKey;
13
13
  default:
14
14
  return !1;
15
15
  }
@@ -18,12 +18,12 @@ function h(r, s, t, c, n, l, f) {
18
18
  handleKeyPress: (e) => {
19
19
  if (c.value) return;
20
20
  if (e.key === "Escape") {
21
- l.value ? (l.value = !1, e.preventDefault()) : n.isRecording && (f(), e.preventDefault()), s("escape-press");
21
+ a.value ? (a.value = !1, e.preventDefault()) : f.isRecording && (n(), e.preventDefault()), s("escape-press");
22
22
  return;
23
23
  }
24
- o(e, r.submitType) && a(t.value) && (e.preventDefault(), i());
24
+ y(e, r.submitType) && i(t.value) && (e.preventDefault(), u());
25
25
  },
26
- triggerSubmit: i
26
+ triggerSubmit: u
27
27
  };
28
28
  }
29
29
  export {
@@ -2,24 +2,24 @@ import { reactive as f } from "vue";
2
2
  function R(r) {
3
3
  const n = f({
4
4
  isRecording: !1,
5
- isSupported: "webkitSpeechRecognition" in window || "SpeechRecognition" in window,
5
+ isSupported: typeof window < "u" && "webkitSpeechRecognition" in window || "SpeechRecognition" in window,
6
6
  error: void 0
7
- }), a = n.isSupported ? new (window.webkitSpeechRecognition || window.SpeechRecognition)() : null;
8
- a && (a.continuous = r.continuous ?? !1, a.interimResults = r.interimResults ?? !0, a.lang = r.lang ?? navigator.language, a.onstart = () => {
7
+ }), a = n.isSupported ? new (window.webkitSpeechRecognition || window.SpeechRecognition)() : void 0;
8
+ a !== void 0 && (a.continuous = r.continuous ?? !1, a.interimResults = r.interimResults ?? !0, a.lang = r.lang ?? navigator.language, a.onstart = () => {
9
9
  var e;
10
10
  n.isRecording = !0, n.error = void 0, (e = r.onStart) == null || e.call(r);
11
11
  }, a.onend = () => {
12
12
  var e;
13
13
  n.isRecording = !1, (e = r.onEnd) == null || e.call(r);
14
14
  }, a.onresult = (e) => {
15
- var i, u;
15
+ var i, d;
16
16
  const c = Array.from(e.results).map((g) => g[0].transcript).join("");
17
- e.results[0].isFinal ? (i = r.onFinal) == null || i.call(r, c) : (u = r.onInterim) == null || u.call(r, c);
17
+ e.results[0].isFinal ? (i = r.onFinal) == null || i.call(r, c) : (d = r.onInterim) == null || d.call(r, c);
18
18
  }, a.onerror = (e) => {
19
19
  var c;
20
20
  n.error = new Error(e.error), n.isRecording = !1, (c = r.onError) == null || c.call(r, n.error);
21
21
  });
22
- const l = () => {
22
+ const u = () => {
23
23
  var e;
24
24
  if (!a) {
25
25
  const c = new Error("浏览器不支持语音识别");
@@ -45,7 +45,7 @@ function R(r) {
45
45
  } catch (c) {
46
46
  t(c);
47
47
  }
48
- }, d = () => {
48
+ }, l = () => {
49
49
  if (a && n.isRecording)
50
50
  try {
51
51
  a.stop();
@@ -58,8 +58,8 @@ function R(r) {
58
58
  };
59
59
  return {
60
60
  speechState: n,
61
- start: l,
62
- stop: d
61
+ start: u,
62
+ stop: l
63
63
  };
64
64
  }
65
65
  export {