@8wave/ai-elements 0.125.0-beta.16 → 0.125.0-beta.18

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 (145) hide show
  1. package/README.md +24 -0
  2. package/dist/_chunks/{PkChatbotFilePreview-xDlDvl5m.js → PkChatbotFilePreview-CFGqa-tX.js} +2 -2
  3. package/dist/_chunks/{PkChatbotFilePreview-xDlDvl5m.js.map → PkChatbotFilePreview-CFGqa-tX.js.map} +1 -1
  4. package/dist/_chunks/{PkFilePreview-8nVPKv8k.js → PkFilePreview-BIFkMsAC.js} +559 -718
  5. package/dist/_chunks/PkFilePreview-BIFkMsAC.js.map +1 -0
  6. package/dist/_chunks/{PkFilePreviewDialog-BHPcGlnF.js → PkFilePreviewDialog-NLk4gZMd.js} +8 -8
  7. package/dist/_chunks/{PkFilePreviewDialog-BHPcGlnF.js.map → PkFilePreviewDialog-NLk4gZMd.js.map} +1 -1
  8. package/dist/_chunks/PkSelectionActions-CUymhwsG.js +168 -0
  9. package/dist/_chunks/PkSelectionActions-CUymhwsG.js.map +1 -0
  10. package/dist/_chunks/{PkStreamingMarkdown-BFTTLuPc.js → PkStreamingMarkdown-CqLpNWQv.js} +2 -2
  11. package/dist/_chunks/{PkStreamingMarkdown-BFTTLuPc.js.map → PkStreamingMarkdown-CqLpNWQv.js.map} +1 -1
  12. package/dist/_chunks/{PkToolChatFile-Buv7Qkes.js → PkToolChatFile-iE4ZokYD.js} +2 -2
  13. package/dist/_chunks/{PkToolChatFile-Buv7Qkes.js.map → PkToolChatFile-iE4ZokYD.js.map} +1 -1
  14. package/dist/_chunks/{PkToolShareDocument-kB0qoQda.js → PkToolShareDocument-lTHNZodf.js} +2 -2
  15. package/dist/_chunks/{PkToolShareDocument-kB0qoQda.js.map → PkToolShareDocument-lTHNZodf.js.map} +1 -1
  16. package/dist/_chunks/{PkToolShowArtifact-ClYqvIqB.js → PkToolShowArtifact-BNQrM5fY.js} +2 -2
  17. package/dist/_chunks/{PkToolShowArtifact-ClYqvIqB.js.map → PkToolShowArtifact-BNQrM5fY.js.map} +1 -1
  18. package/dist/_chunks/{PkToolShowContactForm-C0ABjvtZ.js → PkToolShowContactForm-CvQoLumn.js} +2 -2
  19. package/dist/_chunks/{PkToolShowContactForm-C0ABjvtZ.js.map → PkToolShowContactForm-CvQoLumn.js.map} +1 -1
  20. package/dist/_chunks/{PkToolShowDiagram-BZbHtEs5.js → PkToolShowDiagram-COt1Z3q9.js} +2 -2
  21. package/dist/_chunks/{PkToolShowDiagram-BZbHtEs5.js.map → PkToolShowDiagram-COt1Z3q9.js.map} +1 -1
  22. package/dist/_chunks/{PkToolShowForm-DUjR-9o1.js → PkToolShowForm-DcPccCEU.js} +2 -2
  23. package/dist/_chunks/{PkToolShowForm-DUjR-9o1.js.map → PkToolShowForm-DcPccCEU.js.map} +1 -1
  24. package/dist/_chunks/{PkToolShowImageGallery-CNU2Zvso.js → PkToolShowImageGallery-DefXra8-.js} +2 -2
  25. package/dist/_chunks/{PkToolShowImageGallery-CNU2Zvso.js.map → PkToolShowImageGallery-DefXra8-.js.map} +1 -1
  26. package/dist/_chunks/{PkToolShowSources-DhDjNIFa.js → PkToolShowSources-BE3Zv_uz.js} +2 -2
  27. package/dist/_chunks/{PkToolShowSources-DhDjNIFa.js.map → PkToolShowSources-BE3Zv_uz.js.map} +1 -1
  28. package/dist/_chunks/{useLightbox-BEEzZ0qT.js → useLightbox-D2Zi-Fpe.js} +72 -13
  29. package/dist/_chunks/useLightbox-D2Zi-Fpe.js.map +1 -0
  30. package/dist/ai-elements.es.js +4692 -4268
  31. package/dist/ai-elements.es.js.map +1 -1
  32. package/dist-vue/PkChatbot.js +1 -1
  33. package/dist-vue/PkChatbotEmptyState.js +1 -1
  34. package/dist-vue/PkChatbotFilePreview.js +1 -1
  35. package/dist-vue/PkChatbotInput.js +1 -1
  36. package/dist-vue/PkChatbotMessages.js +1 -1
  37. package/dist-vue/PkChatbotStepPayload.js +1 -1
  38. package/dist-vue/PkChatbotStepToolDetail.js +1 -1
  39. package/dist-vue/PkChatbotSteps.js +1 -1
  40. package/dist-vue/PkChatbotViewChat.js +1 -1
  41. package/dist-vue/PkChatbotViewConversations.js +1 -1
  42. package/dist-vue/PkChatbotViewFiles.js +1 -1
  43. package/dist-vue/PkChatbotViewProfile.js +1 -1
  44. package/dist-vue/_chunks/{Agent-DmxsItHG.js → Agent-Cm1LrkYm.js} +162 -162
  45. package/dist-vue/_chunks/{Agent-DmxsItHG.js.map → Agent-Cm1LrkYm.js.map} +1 -1
  46. package/dist-vue/_chunks/{Document-CXfJxfu6.js → Document-DHBTrCuO.js} +10 -10
  47. package/dist-vue/_chunks/{Document-CXfJxfu6.js.map → Document-DHBTrCuO.js.map} +1 -1
  48. package/dist-vue/_chunks/{PkChatbot-Bpo22_yE.js → PkChatbot-DCGQnndK.js} +10 -9
  49. package/dist-vue/_chunks/PkChatbot-DCGQnndK.js.map +1 -0
  50. package/dist-vue/_chunks/{PkChatbotEmptyState-CQ_Qdkge.js → PkChatbotEmptyState-COya3H3C.js} +2 -2
  51. package/dist-vue/_chunks/{PkChatbotEmptyState-CQ_Qdkge.js.map → PkChatbotEmptyState-COya3H3C.js.map} +1 -1
  52. package/dist-vue/_chunks/{PkChatbotFilePreview-BpVM850N.js → PkChatbotFilePreview-BsvT6orx.js} +2 -2
  53. package/dist-vue/_chunks/{PkChatbotFilePreview-BpVM850N.js.map → PkChatbotFilePreview-BsvT6orx.js.map} +1 -1
  54. package/dist-vue/_chunks/{PkChatbotInput-BVu1b2Te.js → PkChatbotInput-D0KUEkAs.js} +5 -4
  55. package/dist-vue/_chunks/PkChatbotInput-D0KUEkAs.js.map +1 -0
  56. package/dist-vue/_chunks/{PkChatbotMessages-DftNL5ZQ.js → PkChatbotMessages-l-IzEWsN.js} +21 -21
  57. package/dist-vue/_chunks/{PkChatbotMessages-DftNL5ZQ.js.map → PkChatbotMessages-l-IzEWsN.js.map} +1 -1
  58. package/dist-vue/_chunks/{PkChatbotStepPayload-AiDZPbds.js → PkChatbotStepPayload-cuYclK_2.js} +2 -2
  59. package/dist-vue/_chunks/{PkChatbotStepPayload-AiDZPbds.js.map → PkChatbotStepPayload-cuYclK_2.js.map} +1 -1
  60. package/dist-vue/_chunks/{PkChatbotStepToolDetail-CALZDpfQ.js → PkChatbotStepToolDetail-Yd8cUQJP.js} +3 -3
  61. package/dist-vue/_chunks/{PkChatbotStepToolDetail-CALZDpfQ.js.map → PkChatbotStepToolDetail-Yd8cUQJP.js.map} +1 -1
  62. package/dist-vue/_chunks/{PkChatbotSteps-CY7pN2Gl.js → PkChatbotSteps-_Aqft0em.js} +5 -5
  63. package/dist-vue/_chunks/{PkChatbotSteps-CY7pN2Gl.js.map → PkChatbotSteps-_Aqft0em.js.map} +1 -1
  64. package/dist-vue/_chunks/{PkChatbotViewChat-Drp0At_n.js → PkChatbotViewChat-CHvtUHuO.js} +180 -178
  65. package/dist-vue/_chunks/PkChatbotViewChat-CHvtUHuO.js.map +1 -0
  66. package/dist-vue/_chunks/{PkChatbotViewConversations-C0KqM_Wq.js → PkChatbotViewConversations-7JU_5-F2.js} +3 -3
  67. package/dist-vue/_chunks/{PkChatbotViewConversations-C0KqM_Wq.js.map → PkChatbotViewConversations-7JU_5-F2.js.map} +1 -1
  68. package/dist-vue/_chunks/{PkChatbotViewFiles-B9mYRoNK.js → PkChatbotViewFiles-D53wtRPS.js} +3 -3
  69. package/dist-vue/_chunks/{PkChatbotViewFiles-B9mYRoNK.js.map → PkChatbotViewFiles-D53wtRPS.js.map} +1 -1
  70. package/dist-vue/_chunks/{PkChatbotViewProfile-BfNE3d7F.js → PkChatbotViewProfile-BRlLIofM.js} +2 -2
  71. package/dist-vue/_chunks/{PkChatbotViewProfile-BfNE3d7F.js.map → PkChatbotViewProfile-BRlLIofM.js.map} +1 -1
  72. package/dist-vue/_chunks/{PkFilePreview-z7JcRtjP.js → PkFilePreview-DLo9nI2g.js} +426 -426
  73. package/dist-vue/_chunks/PkFilePreview-DLo9nI2g.js.map +1 -0
  74. package/dist-vue/_chunks/{PkFilePreviewDialog-zVon3aPY.js → PkFilePreviewDialog-CgDJQgIJ.js} +2 -2
  75. package/dist-vue/_chunks/{PkFilePreviewDialog-zVon3aPY.js.map → PkFilePreviewDialog-CgDJQgIJ.js.map} +1 -1
  76. package/dist-vue/_chunks/{PkStreamingMarkdown-bJEDk-kM.js → PkStreamingMarkdown-2FN4WMQD.js} +4 -4
  77. package/dist-vue/_chunks/{PkStreamingMarkdown-bJEDk-kM.js.map → PkStreamingMarkdown-2FN4WMQD.js.map} +1 -1
  78. package/dist-vue/_chunks/{PkSvgViewer-DmkElalq.js → PkSvgViewer-BsdSOBpH.js} +2 -2
  79. package/dist-vue/_chunks/{PkSvgViewer-DmkElalq.js.map → PkSvgViewer-BsdSOBpH.js.map} +1 -1
  80. package/dist-vue/_chunks/{PkToolChatFile-DqLGwJxp.js → PkToolChatFile-DAT1tv52.js} +4 -4
  81. package/dist-vue/_chunks/{PkToolChatFile-DqLGwJxp.js.map → PkToolChatFile-DAT1tv52.js.map} +1 -1
  82. package/dist-vue/_chunks/{PkToolRequestGeolocation-BnV7A6SW.js → PkToolRequestGeolocation-p7Ip17F7.js} +2 -2
  83. package/dist-vue/_chunks/{PkToolRequestGeolocation-BnV7A6SW.js.map → PkToolRequestGeolocation-p7Ip17F7.js.map} +1 -1
  84. package/dist-vue/_chunks/{PkToolRequestOAuthConnection-QCbQ7bnl.js → PkToolRequestOAuthConnection-CtXSzKzM.js} +2 -2
  85. package/dist-vue/_chunks/{PkToolRequestOAuthConnection-QCbQ7bnl.js.map → PkToolRequestOAuthConnection-CtXSzKzM.js.map} +1 -1
  86. package/dist-vue/_chunks/{PkToolShareDocument-BIZkgcJ3.js → PkToolShareDocument-Qb2Lu5vh.js} +2 -2
  87. package/dist-vue/_chunks/{PkToolShareDocument-BIZkgcJ3.js.map → PkToolShareDocument-Qb2Lu5vh.js.map} +1 -1
  88. package/dist-vue/_chunks/{PkToolShowArtifact-DanzULWt.js → PkToolShowArtifact-Bskomw05.js} +2 -2
  89. package/dist-vue/_chunks/{PkToolShowArtifact-DanzULWt.js.map → PkToolShowArtifact-Bskomw05.js.map} +1 -1
  90. package/dist-vue/_chunks/{PkToolShowContactForm-DzttQBG6.js → PkToolShowContactForm-iQrlqv7j.js} +2 -2
  91. package/dist-vue/_chunks/{PkToolShowContactForm-DzttQBG6.js.map → PkToolShowContactForm-iQrlqv7j.js.map} +1 -1
  92. package/dist-vue/_chunks/{PkToolShowDiagram-BNa89wcw.js → PkToolShowDiagram-C-43uUoh.js} +3 -3
  93. package/dist-vue/_chunks/{PkToolShowDiagram-BNa89wcw.js.map → PkToolShowDiagram-C-43uUoh.js.map} +1 -1
  94. package/dist-vue/_chunks/{PkToolShowForm-BXol1WE3.js → PkToolShowForm-CKXpqQxy.js} +4 -4
  95. package/dist-vue/_chunks/{PkToolShowForm-BXol1WE3.js.map → PkToolShowForm-CKXpqQxy.js.map} +1 -1
  96. package/dist-vue/_chunks/{PkToolShowImageGallery-Dmr5zXTj.js → PkToolShowImageGallery-DLTn6JmU.js} +3 -3
  97. package/dist-vue/_chunks/{PkToolShowImageGallery-Dmr5zXTj.js.map → PkToolShowImageGallery-DLTn6JmU.js.map} +1 -1
  98. package/dist-vue/_chunks/{PkToolShowLocation-DCPaDtBI.js → PkToolShowLocation-B8FE_Sqd.js} +2 -2
  99. package/dist-vue/_chunks/{PkToolShowLocation-DCPaDtBI.js.map → PkToolShowLocation-B8FE_Sqd.js.map} +1 -1
  100. package/dist-vue/_chunks/{PkToolShowProductList-C_uIUG_G.js → PkToolShowProductList-hhSBAQVC.js} +2 -2
  101. package/dist-vue/_chunks/{PkToolShowProductList-C_uIUG_G.js.map → PkToolShowProductList-hhSBAQVC.js.map} +1 -1
  102. package/dist-vue/_chunks/{PkToolShowSources-BHRNGn4s.js → PkToolShowSources-BiP9fVV2.js} +3 -3
  103. package/dist-vue/_chunks/{PkToolShowSources-BHRNGn4s.js.map → PkToolShowSources-BiP9fVV2.js.map} +1 -1
  104. package/dist-vue/_chunks/{PkToolShowSuggestedReply-DHCqxA1P.js → PkToolShowSuggestedReply-BRIzGNwx.js} +2 -2
  105. package/dist-vue/_chunks/{PkToolShowSuggestedReply-DHCqxA1P.js.map → PkToolShowSuggestedReply-BRIzGNwx.js.map} +1 -1
  106. package/dist-vue/_chunks/{PkToolShowVideo-P4H5A7ke.js → PkToolShowVideo-DJhsbDuX.js} +2 -2
  107. package/dist-vue/_chunks/{PkToolShowVideo-P4H5A7ke.js.map → PkToolShowVideo-DJhsbDuX.js.map} +1 -1
  108. package/dist-vue/_chunks/{PkToolShowWebPages-BzNZHR7Q.js → PkToolShowWebPages-BAv66f5H.js} +2 -2
  109. package/dist-vue/_chunks/{PkToolShowWebPages-BzNZHR7Q.js.map → PkToolShowWebPages-BAv66f5H.js.map} +1 -1
  110. package/dist-vue/_chunks/{createChatbotApiClient-CQjxHqLr.js → createChatbotApiClient-DO4_I5hT.js} +21 -14
  111. package/dist-vue/_chunks/createChatbotApiClient-DO4_I5hT.js.map +1 -0
  112. package/dist-vue/_chunks/{useChatbotStore-CyZha9pf.js → useChatbotStore-Bj00X4yT.js} +1255 -1242
  113. package/dist-vue/_chunks/useChatbotStore-Bj00X4yT.js.map +1 -0
  114. package/dist-vue/_chunks/{useLightbox-gSzoBgNv.js → useLightbox-FDyQrPWe.js} +72 -13
  115. package/dist-vue/_chunks/useLightbox-FDyQrPWe.js.map +1 -0
  116. package/dist-vue/_chunks/{utils-8lO2Gj-m.js → utils-RwaXl9-x.js} +4 -4
  117. package/dist-vue/_chunks/{utils-8lO2Gj-m.js.map → utils-RwaXl9-x.js.map} +1 -1
  118. package/dist-vue/api.js +1 -1
  119. package/dist-vue/apps/web-component/src/components/EmbeddedChatWidget.ce.d.ts +4 -4
  120. package/dist-vue/apps/web-component/src/composables/usePagePointer.d.ts +14 -9
  121. package/dist-vue/apps/web-component/src/composables/usePendingMessage.d.ts +29 -15
  122. package/dist-vue/apps/web-component/src/composables/useSelectionActions.d.ts +77 -0
  123. package/dist-vue/composables.js +40 -8
  124. package/dist-vue/composables.js.map +1 -1
  125. package/dist-vue/index.js +5401 -5321
  126. package/dist-vue/index.js.map +1 -1
  127. package/dist-vue/locales.js +28 -2
  128. package/dist-vue/packages/components/src/chat/PkAgentSelectionActionsSettings.d.ts +25 -0
  129. package/dist-vue/packages/components/src/chat/PkAgentSettingsPanel.d.ts +23 -3
  130. package/dist-vue/packages/components/src/chat/PkChatbot.d.ts +2 -1
  131. package/dist-vue/packages/components/src/chat/PkChatbotInput.d.ts +2 -0
  132. package/dist-vue/packages/components/src/chat/PkSelectionActions.d.ts +2 -12
  133. package/dist-vue/packages/components/src/chat/PkSelectionAnswerCard.d.ts +41 -0
  134. package/dist-vue/packages/composable/src/chatbot/api/createChatbotApiClient.d.ts +6 -0
  135. package/dist-vue/packages/composable/src/chatbot/useChatbotStore.d.ts +4 -1
  136. package/package.json +1 -1
  137. package/dist/_chunks/PkFilePreview-8nVPKv8k.js.map +0 -1
  138. package/dist/_chunks/useLightbox-BEEzZ0qT.js.map +0 -1
  139. package/dist-vue/_chunks/PkChatbot-Bpo22_yE.js.map +0 -1
  140. package/dist-vue/_chunks/PkChatbotInput-BVu1b2Te.js.map +0 -1
  141. package/dist-vue/_chunks/PkChatbotViewChat-Drp0At_n.js.map +0 -1
  142. package/dist-vue/_chunks/PkFilePreview-z7JcRtjP.js.map +0 -1
  143. package/dist-vue/_chunks/createChatbotApiClient-CQjxHqLr.js.map +0 -1
  144. package/dist-vue/_chunks/useChatbotStore-CyZha9pf.js.map +0 -1
  145. package/dist-vue/_chunks/useLightbox-gSzoBgNv.js.map +0 -1
@@ -462,6 +462,7 @@ var e = {
462
462
  pageAccessConfirmEveryAction: "The user confirms every click and every write, not only submits and page changes.",
463
463
  pageAccessPointer: "A button in the chat input to point at an element of the page, or select its text, and ask about it.",
464
464
  pageAccessNotice: "Empty, the widget uses the level's own text.",
465
+ selectionActionsMax: "At most {count} actions on the bar, built-in and the agent's together.",
465
466
  modelRetired: "No longer available on the platform: move the agents using it to another model.",
466
467
  modelNotCompatible: "Not compatible with the privacy flags of this agent.",
467
468
  modelGuaranteedOnSome: "The guarantees you switched on hold only on some providers of this model: the gateway routes accordingly.",
@@ -882,7 +883,16 @@ var e = {
882
883
  openLatest: "Open the latest",
883
884
  label: "Actions on the selection",
884
885
  askPlaceholder: "What should be done with the selection?",
885
- ask: "Ask…"
886
+ ask: "Ask…",
887
+ card: {
888
+ aiNotice: "Answered by artificial intelligence",
889
+ thinking: "Answer on its way…",
890
+ waitsConfirm: "The agent is waiting for you to confirm an action: continue in chat to answer.",
891
+ waitsReply: "The agent is asking you something: continue in chat to answer.",
892
+ more: "The answer also holds content that shows only in the chat.",
893
+ noAnswer: "No answer: continue in chat to see what happened.",
894
+ continue: "Continue in chat"
895
+ }
886
896
  },
887
897
  confirmTitle: {
888
898
  deleteMyConversations: "Delete all your conversations?",
@@ -936,6 +946,9 @@ var e = {
936
946
  },
937
947
  lightbox: {
938
948
  zoom: "Zoom in or out",
949
+ copy: "Copy image",
950
+ copied: "Image copied",
951
+ copyFailed: "The image could not be copied",
939
952
  openInNewTab: "Open in a new tab"
940
953
  }
941
954
  }, t = {
@@ -1401,6 +1414,7 @@ var e = {
1401
1414
  pageAccessConfirmEveryAction: "L'utente conferma ogni clic e ogni scrittura, non solo gli invii e i cambi di pagina.",
1402
1415
  pageAccessPointer: "Un pulsante nel campo della chat per indicare un elemento della pagina, o selezionarne il testo, e chiedere.",
1403
1416
  pageAccessNotice: "Vuoto, il widget usa il testo del livello.",
1417
+ selectionActionsMax: "Al massimo {count} azioni nella barra, predefinite e dell'agente insieme.",
1404
1418
  modelRetired: "Non più disponibile sulla piattaforma: sposta su un altro modello gli agenti che lo usano.",
1405
1419
  modelNotCompatible: "Non compatibile con i flag di riservatezza di questo agente.",
1406
1420
  modelGuaranteedOnSome: "Le garanzie che hai acceso valgono solo su alcuni provider di questo modello: il gateway instrada di conseguenza.",
@@ -1821,7 +1835,16 @@ var e = {
1821
1835
  openLatest: "Apri l'ultima",
1822
1836
  label: "Azioni sulla selezione",
1823
1837
  askPlaceholder: "Cosa vuoi fare con la selezione?",
1824
- ask: "Chiedi…"
1838
+ ask: "Chiedi…",
1839
+ card: {
1840
+ aiNotice: "Risponde un'intelligenza artificiale",
1841
+ thinking: "Risposta in arrivo…",
1842
+ waitsConfirm: "L'agente aspetta che tu confermi un'azione: continua in chat per rispondere.",
1843
+ waitsReply: "L'agente ti chiede qualcosa: continua in chat per rispondere.",
1844
+ more: "La risposta ha anche contenuti che si vedono solo in chat.",
1845
+ noAnswer: "Nessuna risposta: continua in chat per vedere cosa è successo.",
1846
+ continue: "Continua in chat"
1847
+ }
1825
1848
  },
1826
1849
  confirmTitle: {
1827
1850
  deleteMyConversations: "Eliminare tutte le vostre conversazioni?",
@@ -1875,6 +1898,9 @@ var e = {
1875
1898
  },
1876
1899
  lightbox: {
1877
1900
  zoom: "Ingrandisci o riduci",
1901
+ copy: "Copia immagine",
1902
+ copied: "Immagine copiata",
1903
+ copyFailed: "Non è stato possibile copiare l'immagine",
1878
1904
  openInNewTab: "Apri in una nuova scheda"
1879
1905
  }
1880
1906
  };
@@ -0,0 +1,25 @@
1
+ import { SelectionActionsSettings, SelectionSurface } from '../../../models/src';
2
+ import { DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
3
+ /**
4
+ * One group of the selection bar's settings (spec `selection-actions.md`,
5
+ * "Cosa è comune"): the switch and the built-in actions to tick, within
6
+ * the cap the bar shows. The page group sits in "Site and app" after
7
+ * "Point and ask", the Word and Excel groups in "Tools" beside their
8
+ * tools. Its labels are `label.selectionActions<Surface><Key>`, the names
9
+ * the change list of a save reads them by.
10
+ */
11
+ type Group = SelectionActionsSettings[SelectionSurface];
12
+ type __VLS_Props = {
13
+ surface: SelectionSurface;
14
+ };
15
+ type __VLS_ModelProps = {
16
+ modelValue?: Partial<Group> | undefined;
17
+ };
18
+ type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
19
+ declare const __VLS_export: DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
20
+ "update:modelValue": (value: Partial<Group> | undefined) => any;
21
+ }, string, PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
22
+ "onUpdate:modelValue"?: ((value: Partial<Group> | undefined) => any) | undefined;
23
+ }>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
24
+ declare const _default: typeof __VLS_export;
25
+ export default _default;
@@ -1,4 +1,4 @@
1
- import { AgentFormSettings, AgentReasoning, AgentWebSearch, HostToolsSettings, LocalizedString, PageAccessSettings, Media, ModelCatalogEntry, OrganizationFeature, VoiceOption, AgentBuiltInTool, AgentChannel, AgentToolWorkingSetMode, AgentLoaderStrategy, AgentType, WebSearchProvider, StoragePolicy, PageAccessLevel } from '../../../models/src';
1
+ import { AgentFormSettings, AgentReasoning, AgentWebSearch, HostToolsSettings, LocalizedString, PageAccessSettings, SelectionActionsSettings, Media, ModelCatalogEntry, OrganizationFeature, VoiceOption, AgentBuiltInTool, AgentChannel, AgentToolWorkingSetMode, AgentLoaderStrategy, AgentType, PageAccessLevel, WebSearchProvider, StoragePolicy } from '../../../models/src';
2
2
  import { DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
3
3
  type __VLS_Props = {
4
4
  organizationSlug?: string;
@@ -136,6 +136,8 @@ type __VLS_ModelProps = {
136
136
  'hostTools'?: Partial<HostToolsSettings> | undefined;
137
137
  /** What the agent may do on the page that embeds it (spec `page-tools.md`). */
138
138
  'pageAccess'?: Partial<PageAccessSettings> | undefined;
139
+ /** The bar of actions on a text selected on the page (spec `selection-actions.md`). */
140
+ 'selectionActionsPage'?: Partial<SelectionActionsSettings['page']> | undefined;
139
141
  /** The user may choose automatic confirmations in the chat (spec `auto-confirmations.md`). */
140
142
  'confirmationsAllowAutomatic'?: boolean;
141
143
  'ranking'?: {
@@ -155,9 +157,9 @@ type __VLS_ModelProps = {
155
157
  } | undefined;
156
158
  };
157
159
  type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
158
- declare var __VLS_909: {};
160
+ declare var __VLS_914: {};
159
161
  type __VLS_Slots = {} & {
160
- default?: (props: typeof __VLS_909) => any;
162
+ default?: (props: typeof __VLS_914) => any;
161
163
  };
162
164
  declare const __VLS_base: DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
163
165
  "update:reasoning": (value: {
@@ -415,6 +417,15 @@ declare const __VLS_base: DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, Com
415
417
  acknowledgedAt?: Date | undefined;
416
418
  acknowledgedLevel?: PageAccessLevel | undefined;
417
419
  }> | undefined) => any;
420
+ "update:selectionActionsPage": (value: Partial<{
421
+ enabled: boolean;
422
+ builtIns: ("explain" | "summarize")[];
423
+ actions: {
424
+ id: string;
425
+ label: Record<string, string>;
426
+ prompt: Record<string, string>;
427
+ }[];
428
+ }> | undefined) => any;
418
429
  "update:confirmationsAllowAutomatic": (value: boolean) => any;
419
430
  "update:ranking": (value: {
420
431
  freshness?: {
@@ -688,6 +699,15 @@ declare const __VLS_base: DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, Com
688
699
  acknowledgedAt?: Date | undefined;
689
700
  acknowledgedLevel?: PageAccessLevel | undefined;
690
701
  }> | undefined) => any) | undefined;
702
+ "onUpdate:selectionActionsPage"?: ((value: Partial<{
703
+ enabled: boolean;
704
+ builtIns: ("explain" | "summarize")[];
705
+ actions: {
706
+ id: string;
707
+ label: Record<string, string>;
708
+ prompt: Record<string, string>;
709
+ }[];
710
+ }> | undefined) => any) | undefined;
691
711
  "onUpdate:confirmationsAllowAutomatic"?: ((value: boolean) => any) | undefined;
692
712
  "onUpdate:ranking"?: ((value: {
693
713
  freshness?: {
@@ -1,5 +1,5 @@
1
1
  import { AgentConfirmationsCapability, AgentInterface, AgentModel, AgentFileUpload, AgentGatewayOptions, AgentVoiceCapability, ChatMessageActions, RevisedAnswer, UIChatMessage, AgentTools, HostToolsCapability, PageAccessCapability, SelectionActionsCapability } from '../../../models/src';
2
- import { RegisteredHostTool } from '../../../composable/src';
2
+ import { RegisteredHostTool, SelectionPointer } from '../../../composable/src';
3
3
  import { DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
4
4
  import { ChatRequestOptions } from 'ai';
5
5
  type __VLS_Props = {
@@ -85,6 +85,7 @@ declare const __VLS_base: DefineComponent<__VLS_PublicProps, {
85
85
  } & ChatRequestOptions) => Promise<void>>[0]) => Promise<void>;
86
86
  stopGeneration: () => Promise<void>;
87
87
  sendMessage: (text: string) => void;
88
+ sendSelection: (text: string, pointer: SelectionPointer) => boolean;
88
89
  }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
89
90
  error: (error: {
90
91
  type: string;
@@ -62,6 +62,7 @@ declare const __VLS_base: DefineComponent<__VLS_PublicProps, {
62
62
  "update:pendingAttachments": (value: PendingAttachment[]) => any;
63
63
  "stop-generation": () => any;
64
64
  "file-select": (file: File) => any;
65
+ "remove-attachment": (attachment: PendingAttachment) => any;
65
66
  "dismiss-attachment-notice": () => any;
66
67
  "dismiss-page-notice": () => any;
67
68
  "open-answer-notice": (id: string) => any;
@@ -76,6 +77,7 @@ declare const __VLS_base: DefineComponent<__VLS_PublicProps, {
76
77
  "onUpdate:pendingAttachments"?: ((value: PendingAttachment[]) => any) | undefined;
77
78
  "onStop-generation"?: (() => any) | undefined;
78
79
  "onFile-select"?: ((file: File) => any) | undefined;
80
+ "onRemove-attachment"?: ((attachment: PendingAttachment) => any) | undefined;
79
81
  "onDismiss-attachment-notice"?: (() => any) | undefined;
80
82
  "onDismiss-page-notice"?: (() => any) | undefined;
81
83
  "onOpen-answer-notice"?: ((id: string) => any) | undefined;
@@ -7,7 +7,7 @@ import { DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOp
7
7
  * language). It sits above the start of the selection, below it without
8
8
  * room there (`selectionBarPosition`). Its buttons take no focus on a
9
9
  * click, so the selection stays and Cmd+C still copies it; the keyboard
10
- * reaches them with Tab. The page puts its answer card in `card`.
10
+ * reaches them with Tab.
11
11
  */
12
12
  export type SelectionBarAction = {
13
13
  id: string;
@@ -46,11 +46,7 @@ type __VLS_ModelProps = {
46
46
  'asking'?: boolean;
47
47
  };
48
48
  type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
49
- declare var __VLS_1: {};
50
- type __VLS_Slots = {} & {
51
- card?: (props: typeof __VLS_1) => any;
52
- };
53
- declare const __VLS_base: DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
49
+ declare const __VLS_export: DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
54
50
  close: () => any;
55
51
  "update:asking": (value: boolean) => any;
56
52
  action: (id: string, value?: string | undefined) => any;
@@ -63,11 +59,5 @@ declare const __VLS_base: DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, Com
63
59
  onAsk?: ((text: string) => any) | undefined;
64
60
  onNote?: (() => any) | undefined;
65
61
  }>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
66
- declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
67
62
  declare const _default: typeof __VLS_export;
68
63
  export default _default;
69
- type __VLS_WithSlots<T, S> = T & {
70
- new (): {
71
- $slots: S;
72
- };
73
- };
@@ -0,0 +1,41 @@
1
+ import { UIChatMessage } from '../../../models/src';
2
+ import { DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
3
+ type __VLS_Props = {
4
+ /** The selected text the answer is about. */
5
+ quote: string;
6
+ agentName?: string;
7
+ /** The messages of the answer, after the action's own. */
8
+ messages: UIChatMessage[];
9
+ /** The answer is on its way: the action's message may not even have left. */
10
+ streaming: boolean;
11
+ /** The answer waits on the card of a page action the user must confirm. */
12
+ confirming?: boolean;
13
+ /** Where the selection was when the action left, in the window. */
14
+ anchor: {
15
+ start: {
16
+ top: number;
17
+ left: number;
18
+ };
19
+ bottom: number;
20
+ bounds: {
21
+ top: number;
22
+ left: number;
23
+ width: number;
24
+ height: number;
25
+ };
26
+ };
27
+ isDark?: boolean;
28
+ /** The action came from the keyboard: the focus the bar had moves here. */
29
+ takeFocus?: boolean;
30
+ };
31
+ declare const __VLS_export: DefineComponent<__VLS_Props, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
32
+ continue: () => any;
33
+ stop: () => any;
34
+ close: () => any;
35
+ }, string, PublicProps, Readonly<__VLS_Props> & Readonly<{
36
+ onContinue?: (() => any) | undefined;
37
+ onStop?: (() => any) | undefined;
38
+ onClose?: (() => any) | undefined;
39
+ }>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
40
+ declare const _default: typeof __VLS_export;
41
+ export default _default;
@@ -75,6 +75,12 @@ export interface ChatbotApiClient {
75
75
  getChatFilePreview(agentId: string, chatId: string, storedFileName: string): Promise<ChatFilePreview>;
76
76
  appendAuthToken(url: string): string;
77
77
  uploadMedia(agentId: string, chatId: string, file: File): Promise<MediaSource>;
78
+ /**
79
+ * Deletes an upload that was never sent, still in `temp/`: the receipt
80
+ * the upload returned in the source names its uploader, the only one who
81
+ * can.
82
+ */
83
+ discardMedia(source: MediaSource): Promise<void>;
78
84
  getChatEndpoint(agentId: string, type?: 'chat' | 'reasoning'): string;
79
85
  /** Where a client resumes the stream of the turn running in a chat. */
80
86
  getChatStreamEndpoint(agentId: string, chatId: string): string;
@@ -2178,6 +2178,7 @@ export declare function useChatbotStore(agentId: string): Store<`chatbot-${strin
2178
2178
  reason?: string;
2179
2179
  }) => void;
2180
2180
  handleFileSelect: (file: File) => Promise<void>;
2181
+ discardPendingAttachment: (attachment: PendingAttachment) => Promise<void>;
2181
2182
  clearFileLimitError: () => void;
2182
2183
  clearPendingAttachments: (revokeAll?: boolean) => void;
2183
2184
  onUpvote: (message: UIChatMessage) => Promise<void>;
@@ -4321,6 +4322,7 @@ export declare function useChatbotStore(agentId: string): Store<`chatbot-${strin
4321
4322
  reason?: string;
4322
4323
  }) => void;
4323
4324
  handleFileSelect: (file: File) => Promise<void>;
4325
+ discardPendingAttachment: (attachment: PendingAttachment) => Promise<void>;
4324
4326
  clearFileLimitError: () => void;
4325
4327
  clearPendingAttachments: (revokeAll?: boolean) => void;
4326
4328
  onUpvote: (message: UIChatMessage) => Promise<void>;
@@ -6464,6 +6466,7 @@ export declare function useChatbotStore(agentId: string): Store<`chatbot-${strin
6464
6466
  reason?: string;
6465
6467
  }) => void;
6466
6468
  handleFileSelect: (file: File) => Promise<void>;
6469
+ discardPendingAttachment: (attachment: PendingAttachment) => Promise<void>;
6467
6470
  clearFileLimitError: () => void;
6468
6471
  clearPendingAttachments: (revokeAll?: boolean) => void;
6469
6472
  onUpvote: (message: UIChatMessage) => Promise<void>;
@@ -6475,4 +6478,4 @@ export declare function useChatbotStore(agentId: string): Store<`chatbot-${strin
6475
6478
  focusInput: () => void;
6476
6479
  renameChatTitle: (chatId: string, title: string) => Promise<void>;
6477
6480
  deleteChat: (chatId: string) => Promise<void>;
6478
- }, "regenerate" | "sendMessage" | "addToolOutput" | "addToolApprovalResponse" | "stopHostActions" | "voicePageTools" | "cancelVoicePageCalls" | "closePageNotice" | "respondHostConfirmation" | "setPageAccessOff" | "sendSelection" | "setConfirmationMode" | "openBackgroundAnswer" | "dismissBackgroundAnswer" | "removeQueuedMessage" | "editQueuedMessage" | "buildDeviceContext" | "initialize" | "loadConversations" | "loadMoreConversations" | "searchConversations" | "loadChatFiles" | "refreshMessages" | "appendMessage" | "getChatFileUrl" | "getChatFilePreviewUrl" | "deleteChatFile" | "handleSubmit" | "stopGeneration" | "startNewChat" | "handleFileSelect" | "clearFileLimitError" | "clearPendingAttachments" | "onUpvote" | "onDownvote" | "onFeedback" | "onFeedbackSubmit" | "onLeadSubmit" | "navigate" | "focusInput" | "renameChatTitle" | "deleteChat">>;
6481
+ }, "regenerate" | "sendMessage" | "addToolOutput" | "addToolApprovalResponse" | "stopHostActions" | "voicePageTools" | "cancelVoicePageCalls" | "closePageNotice" | "respondHostConfirmation" | "setPageAccessOff" | "sendSelection" | "setConfirmationMode" | "openBackgroundAnswer" | "dismissBackgroundAnswer" | "removeQueuedMessage" | "editQueuedMessage" | "buildDeviceContext" | "initialize" | "loadConversations" | "loadMoreConversations" | "searchConversations" | "loadChatFiles" | "refreshMessages" | "appendMessage" | "getChatFileUrl" | "getChatFilePreviewUrl" | "deleteChatFile" | "handleSubmit" | "stopGeneration" | "startNewChat" | "handleFileSelect" | "discardPendingAttachment" | "clearFileLimitError" | "clearPendingAttachments" | "onUpvote" | "onDownvote" | "onFeedback" | "onFeedbackSubmit" | "onLeadSubmit" | "navigate" | "focusInput" | "renameChatTitle" | "deleteChat">>;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@8wave/ai-elements",
3
3
  "private": false,
4
- "version": "0.125.0-beta.16",
4
+ "version": "0.125.0-beta.18",
5
5
  "type": "module",
6
6
  "scripts": {
7
7
  "dev": "vite --port 8082 --open --host",