@8wave/ai-elements 0.123.0 → 0.124.0-beta.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 (41) hide show
  1. package/README.md +4 -0
  2. package/dist/ai-elements.es.js +2592 -2474
  3. package/dist/ai-elements.es.js.map +1 -1
  4. package/dist-vue/PkChatbot.js +1 -1
  5. package/dist-vue/PkChatbotMessages.js +1 -1
  6. package/dist-vue/PkChatbotViewChat.js +1 -1
  7. package/dist-vue/PkChatbotViewConversations.js +1 -1
  8. package/dist-vue/PkChatbotViewFiles.js +1 -1
  9. package/dist-vue/PkChatbotViewProfile.js +1 -1
  10. package/dist-vue/_chunks/{PkChatbot-MEYD0XUR.js → PkChatbot-C7--w-xA.js} +20 -11
  11. package/dist-vue/_chunks/PkChatbot-C7--w-xA.js.map +1 -0
  12. package/dist-vue/_chunks/{PkChatbotMessages-BcHNPZUB.js → PkChatbotMessages-pWNZCmM2.js} +322 -282
  13. package/dist-vue/_chunks/PkChatbotMessages-pWNZCmM2.js.map +1 -0
  14. package/dist-vue/_chunks/{PkChatbotViewChat-CfpGWukX.js → PkChatbotViewChat-mWZvsKLA.js} +3 -3
  15. package/dist-vue/_chunks/{PkChatbotViewChat-CfpGWukX.js.map → PkChatbotViewChat-mWZvsKLA.js.map} +1 -1
  16. package/dist-vue/_chunks/{PkChatbotViewConversations-JCrQIoGf.js → PkChatbotViewConversations-CIv5g2xZ.js} +2 -2
  17. package/dist-vue/_chunks/{PkChatbotViewConversations-JCrQIoGf.js.map → PkChatbotViewConversations-CIv5g2xZ.js.map} +1 -1
  18. package/dist-vue/_chunks/{PkChatbotViewFiles-B1mncBOo.js → PkChatbotViewFiles-DjYF-UoB.js} +2 -2
  19. package/dist-vue/_chunks/{PkChatbotViewFiles-B1mncBOo.js.map → PkChatbotViewFiles-DjYF-UoB.js.map} +1 -1
  20. package/dist-vue/_chunks/{PkChatbotViewProfile--TWIrhYk.js → PkChatbotViewProfile-D3d-hG14.js} +2 -2
  21. package/dist-vue/_chunks/{PkChatbotViewProfile--TWIrhYk.js.map → PkChatbotViewProfile-D3d-hG14.js.map} +1 -1
  22. package/dist-vue/_chunks/{useChatbotStore--6ws3cew.js → useChatbotStore--PcS9kGN.js} +2 -1
  23. package/dist-vue/_chunks/useChatbotStore--PcS9kGN.js.map +1 -0
  24. package/dist-vue/apps/web-component/src/components/EmbeddedChatWidget.ce.d.ts +11 -4
  25. package/dist-vue/apps/web-component/src/lib.d.ts +3 -0
  26. package/dist-vue/apps/web-component/src/pageTools/snapshot.d.ts +18 -9
  27. package/dist-vue/composables.js +15 -5
  28. package/dist-vue/composables.js.map +1 -1
  29. package/dist-vue/index.js +6 -6
  30. package/dist-vue/locales.js +12 -2
  31. package/dist-vue/packages/components/src/chat/PkChatbot.d.ts +11 -7
  32. package/dist-vue/packages/components/src/chat/PkChatbotMessages.d.ts +5 -0
  33. package/dist-vue/packages/components/src/chat/PkHostCallConfirmCard.d.ts +12 -3
  34. package/dist-vue/packages/components/src/chat/PkHostCallConfirmDialog.d.ts +5 -0
  35. package/dist-vue/packages/composable/src/chatbot/hostTools.d.ts +11 -1
  36. package/dist-vue/packages/composable/src/chatbot/useChatbotStore.d.ts +3 -0
  37. package/dist-vue/style.css +1 -1
  38. package/package.json +1 -1
  39. package/dist-vue/_chunks/PkChatbot-MEYD0XUR.js.map +0 -1
  40. package/dist-vue/_chunks/PkChatbotMessages-BcHNPZUB.js.map +0 -1
  41. package/dist-vue/_chunks/useChatbotStore--6ws3cew.js.map +0 -1
package/README.md CHANGED
@@ -296,6 +296,7 @@ Same attributes as the floating widget except `floating-button-position`, plus:
296
296
  | `forwarded-slots` | `string` | none | Comma-separated slot names forwarded to the inner chat (for example `"tool-showArtifact,subagent"`). |
297
297
  | `theme` | `'light' \| 'dark'` | none | The color scheme, over the agent's own setting too, where `system-theme` only applies to an agent set to automatic. For a page that switches theme around a `panel`, which shows the page's background through it. Reactive. |
298
298
  | `follow-page-dialogs` | `boolean` | `false` | While your page has a modal `<dialog>` open, the chat moves into it and stays usable. See [Your modal dialogs](#your-modal-dialogs). Reactive. |
299
+ | `closable` | `boolean` | `false` | The chat's menu offers "Close", which dispatches `close-requested`: for a `panel` your page opens and closes. The widget does not hide itself. Reactive. |
299
300
 
300
301
  ## JavaScript API
301
302
 
@@ -345,6 +346,7 @@ Listen on the element or on any ancestor, `document` included.
345
346
  | `external-token-expiring` | `null` | The session's external token expires in a minute (or is halfway through, when it lives two minutes or less), while the session goes on. Answer with `signIn(freshToken)`, a new JWT of the same user: the session keeps going with it. See [External token](#external-token-jwt). |
346
347
  | `opened` | `null` | The floating panel opened, by the user or by the API. |
347
348
  | `closed` | `null` | The floating panel closed, by the user or by the API. |
349
+ | `close-requested` | `null` | The user chose "Close" in the menu of an embedded widget with `closable`. Close the panel that holds it. |
348
350
  | `chat-error` | `{ type: string, title: string, status: number }` | An API error in the chat. Not named `error`, so it never reaches `window.onerror` and the error monitoring of your page. |
349
351
  | `working-started` | `null` | The agent started answering or running a tool. See [Working state](#working-state). |
350
352
  | `working-ended` | `null` | The agent stopped, or is waiting for the user to confirm an action. |
@@ -1428,6 +1430,7 @@ export interface FloatingChatWidgetElement extends ChatWidgetElement {
1428
1430
  export interface EmbeddedChatWidgetElement extends ChatWidgetElement {
1429
1431
  displayMode?: 'widget' | 'fullscreen' | 'panel'
1430
1432
  forwardedSlots?: string
1433
+ closable?: boolean
1431
1434
  }
1432
1435
 
1433
1436
  declare global {
@@ -1439,6 +1442,7 @@ declare global {
1439
1442
  'signed-in': CustomEvent<{ userId: string; isAnonymous: boolean }>
1440
1443
  'external-auth-expired': CustomEvent<null>
1441
1444
  'chat-error': CustomEvent<{ type: string; title: string; status: number }>
1445
+ 'close-requested': CustomEvent<null>
1442
1446
  'working-started': CustomEvent<null>
1443
1447
  'working-ended': CustomEvent<null>
1444
1448
  'page-control-started': CustomEvent<null>