@8wave/ai-elements 0.119.0-beta.59 → 0.119.0-beta.62

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 (108) hide show
  1. package/README.md +3 -0
  2. package/dist/_chunks/{PkChatbotFilePreview-Bdi4_IFu.js → PkChatbotFilePreview-C0uMvUlV.js} +2 -2
  3. package/dist/_chunks/{PkChatbotFilePreview-Bdi4_IFu.js.map → PkChatbotFilePreview-C0uMvUlV.js.map} +1 -1
  4. package/dist/_chunks/{PkHeldImage-eNPFmmdh.js → PkHeldImage-CBvcNMEM.js} +2 -2
  5. package/dist/_chunks/{PkHeldImage-eNPFmmdh.js.map → PkHeldImage-CBvcNMEM.js.map} +1 -1
  6. package/dist/_chunks/{PkLazyImg-DHPPSq3N.js → PkLazyImg-COy3jb6W.js} +2 -2
  7. package/dist/_chunks/{PkLazyImg-DHPPSq3N.js.map → PkLazyImg-COy3jb6W.js.map} +1 -1
  8. package/dist/_chunks/{PkToolEditSpreadsheet-Ct9pdQJ1.js → PkToolEditSpreadsheet-C8PN08y2.js} +2 -2
  9. package/dist/_chunks/{PkToolEditSpreadsheet-Ct9pdQJ1.js.map → PkToolEditSpreadsheet-C8PN08y2.js.map} +1 -1
  10. package/dist/_chunks/{PkToolRequestGeolocation-DzhrY8bg.js → PkToolRequestGeolocation-Cu1TSjHl.js} +2 -2
  11. package/dist/_chunks/{PkToolRequestGeolocation-DzhrY8bg.js.map → PkToolRequestGeolocation-Cu1TSjHl.js.map} +1 -1
  12. package/dist/_chunks/{PkToolRequestOAuthConnection-CzRKRGoG.js → PkToolRequestOAuthConnection-Bc2UX4MZ.js} +3 -3
  13. package/dist/_chunks/{PkToolRequestOAuthConnection-CzRKRGoG.js.map → PkToolRequestOAuthConnection-Bc2UX4MZ.js.map} +1 -1
  14. package/dist/_chunks/{PkToolShowArtifact-D6ZTw5vh.js → PkToolShowArtifact-B1YYNKqc.js} +2 -2
  15. package/dist/_chunks/{PkToolShowArtifact-D6ZTw5vh.js.map → PkToolShowArtifact-B1YYNKqc.js.map} +1 -1
  16. package/dist/_chunks/{PkToolShowCalendarEvent-D8DMh3-P.js → PkToolShowCalendarEvent-r0SuzJDT.js} +3 -3
  17. package/dist/_chunks/{PkToolShowCalendarEvent-D8DMh3-P.js.map → PkToolShowCalendarEvent-r0SuzJDT.js.map} +1 -1
  18. package/dist/_chunks/{PkToolShowComparison-DLC22e1W.js → PkToolShowComparison-Bsh6iiIQ.js} +3 -3
  19. package/dist/_chunks/{PkToolShowComparison-DLC22e1W.js.map → PkToolShowComparison-Bsh6iiIQ.js.map} +1 -1
  20. package/dist/_chunks/{PkToolShowContactForm-CW7gKQ7h.js → PkToolShowContactForm-B2UzmoDw.js} +4 -4
  21. package/dist/_chunks/{PkToolShowContactForm-CW7gKQ7h.js.map → PkToolShowContactForm-B2UzmoDw.js.map} +1 -1
  22. package/dist/_chunks/{PkToolShowDiagram-WregKAJO.js → PkToolShowDiagram-iQRTxxLw.js} +3 -3
  23. package/dist/_chunks/{PkToolShowDiagram-WregKAJO.js.map → PkToolShowDiagram-iQRTxxLw.js.map} +1 -1
  24. package/dist/_chunks/{PkToolShowEmail-C7mUCqGL.js → PkToolShowEmail-1pyuWnuN.js} +3 -3
  25. package/dist/_chunks/{PkToolShowEmail-C7mUCqGL.js.map → PkToolShowEmail-1pyuWnuN.js.map} +1 -1
  26. package/dist/_chunks/{PkToolShowForm-D_2FmDwq.js → PkToolShowForm-BRt9i4aW.js} +5 -5
  27. package/dist/_chunks/{PkToolShowForm-D_2FmDwq.js.map → PkToolShowForm-BRt9i4aW.js.map} +1 -1
  28. package/dist/_chunks/{PkToolShowImageGallery-KmMO4UuQ.js → PkToolShowImageGallery-BZ3uOhQq.js} +3 -3
  29. package/dist/_chunks/{PkToolShowImageGallery-KmMO4UuQ.js.map → PkToolShowImageGallery-BZ3uOhQq.js.map} +1 -1
  30. package/dist/_chunks/{PkToolShowLocation-jRZtqoBO.js → PkToolShowLocation-BIAPTY0s.js} +3 -3
  31. package/dist/_chunks/{PkToolShowLocation-jRZtqoBO.js.map → PkToolShowLocation-BIAPTY0s.js.map} +1 -1
  32. package/dist/_chunks/{PkToolShowMessage-vw4XS4TR.js → PkToolShowMessage-BM3TU9SP.js} +3 -3
  33. package/dist/_chunks/{PkToolShowMessage-vw4XS4TR.js.map → PkToolShowMessage-BM3TU9SP.js.map} +1 -1
  34. package/dist/_chunks/{PkToolShowProductList-cld-FOFb.js → PkToolShowProductList-C4a7R9yQ.js} +4 -4
  35. package/dist/_chunks/{PkToolShowProductList-cld-FOFb.js.map → PkToolShowProductList-C4a7R9yQ.js.map} +1 -1
  36. package/dist/_chunks/{PkToolShowQrCode-BhcAUXSZ.js → PkToolShowQrCode-6zjcD50R.js} +3 -3
  37. package/dist/_chunks/{PkToolShowQrCode-BhcAUXSZ.js.map → PkToolShowQrCode-6zjcD50R.js.map} +1 -1
  38. package/dist/_chunks/{PkToolShowSources-DyzheirE.js → PkToolShowSources-CgZRJ1gU.js} +3 -3
  39. package/dist/_chunks/{PkToolShowSources-DyzheirE.js.map → PkToolShowSources-CgZRJ1gU.js.map} +1 -1
  40. package/dist/_chunks/{PkToolShowSuggestedReply-xUBuqStM.js → PkToolShowSuggestedReply-nHsdJfbX.js} +2 -2
  41. package/dist/_chunks/{PkToolShowSuggestedReply-xUBuqStM.js.map → PkToolShowSuggestedReply-nHsdJfbX.js.map} +1 -1
  42. package/dist/_chunks/{PkToolShowVideo-KDNxItWl.js → PkToolShowVideo-BxHrmc_4.js} +3 -3
  43. package/dist/_chunks/{PkToolShowVideo-KDNxItWl.js.map → PkToolShowVideo-BxHrmc_4.js.map} +1 -1
  44. package/dist/_chunks/{PkToolShowWeather-DTrZ7r1t.js → PkToolShowWeather-CNvVC6nZ.js} +2 -2
  45. package/dist/_chunks/{PkToolShowWeather-DTrZ7r1t.js.map → PkToolShowWeather-CNvVC6nZ.js.map} +1 -1
  46. package/dist/_chunks/{PkToolShowWebPages-D35B7GzS.js → PkToolShowWebPages-CRM3rPp6.js} +4 -4
  47. package/dist/_chunks/{PkToolShowWebPages-D35B7GzS.js.map → PkToolShowWebPages-CRM3rPp6.js.map} +1 -1
  48. package/dist/_chunks/{VvButtonLocalized-DV-zbH9b.js → VvButtonLocalized-PfbIEwav.js} +2 -2
  49. package/dist/_chunks/{VvButtonLocalized-DV-zbH9b.js.map → VvButtonLocalized-PfbIEwav.js.map} +1 -1
  50. package/dist/_chunks/{VvCheckbox.es-VtDFxWJM.js → VvCheckbox.es-CtWUn81l.js} +3 -3
  51. package/dist/_chunks/VvCheckbox.es-CtWUn81l.js.map +1 -0
  52. package/dist/_chunks/{VvCheckboxGroup.es-D7MifHZN.js → VvCheckboxGroup.es-DjcwsgD8.js} +3 -3
  53. package/dist/_chunks/VvCheckboxGroup.es-DjcwsgD8.js.map +1 -0
  54. package/dist/_chunks/{VvCombobox.es-Brn06uOj.js → VvCombobox.es-DKR6Fb2W.js} +339 -304
  55. package/dist/_chunks/VvCombobox.es-DKR6Fb2W.js.map +1 -0
  56. package/dist/_chunks/{VvInputText.es-Co9NrR4l.js → VvInputText.es-6IlsXl00.js} +315 -275
  57. package/dist/_chunks/VvInputText.es-6IlsXl00.js.map +1 -0
  58. package/dist/_chunks/{VvRadio.es-BxHgVeVy.js → VvRadio.es-GQuMOlYC.js} +3 -3
  59. package/dist/_chunks/VvRadio.es-GQuMOlYC.js.map +1 -0
  60. package/dist/_chunks/{VvRadioGroup.es-DZtXJGCi.js → VvRadioGroup.es-ct4eQCRN.js} +3 -3
  61. package/dist/_chunks/VvRadioGroup.es-ct4eQCRN.js.map +1 -0
  62. package/dist/_chunks/{VvSelect.es-BR8f0LUN.js → VvSelect.es-CQ2SG0HY.js} +3 -3
  63. package/dist/_chunks/VvSelect.es-CQ2SG0HY.js.map +1 -0
  64. package/dist/_chunks/{VvTextarea.es-TXhUgEuG.js → VvTextarea.es-BcMLwglK.js} +225 -190
  65. package/dist/_chunks/VvTextarea.es-BcMLwglK.js.map +1 -0
  66. package/dist/_chunks/{index.es-dTcgyeM4.js → index.es-D7jsz1j2.js} +254 -210
  67. package/dist/_chunks/index.es-D7jsz1j2.js.map +1 -0
  68. package/dist/_chunks/{index.es-DkFMpDsf.js → index.es-DmG03ICf.js} +10 -10
  69. package/dist/_chunks/{index.es-DkFMpDsf.js.map → index.es-DmG03ICf.js.map} +1 -1
  70. package/dist/ai-elements.es.js +1698 -1643
  71. package/dist/ai-elements.es.js.map +1 -1
  72. package/dist-vue/PkChatbot.js +1 -1
  73. package/dist-vue/PkChatbotAuth.js +1 -1
  74. package/dist-vue/PkChatbotFeedbackForm.js +1 -1
  75. package/dist-vue/PkChatbotMessages.js +1 -1
  76. package/dist-vue/PkChatbotViewChat.js +1 -1
  77. package/dist-vue/_chunks/{PkChatbot-Bgw5K9w1.js → PkChatbot-BRfoWvHX.js} +2 -2
  78. package/dist-vue/_chunks/{PkChatbot-Bgw5K9w1.js.map → PkChatbot-BRfoWvHX.js.map} +1 -1
  79. package/dist-vue/_chunks/{PkChatbotAuth-CHoEXxmg.js → PkChatbotAuth-BsxfxDgR.js} +2 -2
  80. package/dist-vue/_chunks/{PkChatbotAuth-CHoEXxmg.js.map → PkChatbotAuth-BsxfxDgR.js.map} +1 -1
  81. package/dist-vue/_chunks/{PkChatbotFeedbackForm-B5cYsWBr.js → PkChatbotFeedbackForm-pQc2JrQT.js} +2 -2
  82. package/dist-vue/_chunks/{PkChatbotFeedbackForm-B5cYsWBr.js.map → PkChatbotFeedbackForm-pQc2JrQT.js.map} +1 -1
  83. package/dist-vue/_chunks/{PkChatbotMessages-B2e1MQ_d.js → PkChatbotMessages-B6EEvqZy.js} +3 -3
  84. package/dist-vue/_chunks/{PkChatbotMessages-B2e1MQ_d.js.map → PkChatbotMessages-B6EEvqZy.js.map} +1 -1
  85. package/dist-vue/_chunks/{PkChatbotViewChat-DEpMIiic.js → PkChatbotViewChat-PdHUXyCz.js} +3 -3
  86. package/dist-vue/_chunks/{PkChatbotViewChat-DEpMIiic.js.map → PkChatbotViewChat-PdHUXyCz.js.map} +1 -1
  87. package/dist-vue/_chunks/{PkToolShowContactForm-BjE4mrDv.js → PkToolShowContactForm-CBuw96Vr.js} +2 -2
  88. package/dist-vue/_chunks/{PkToolShowContactForm-BjE4mrDv.js.map → PkToolShowContactForm-CBuw96Vr.js.map} +1 -1
  89. package/dist-vue/_chunks/{index.es-C1u3kP7i.js → index.es-CY6tu8qg.js} +2 -2
  90. package/dist-vue/_chunks/{index.es-C1u3kP7i.js.map → index.es-CY6tu8qg.js.map} +1 -1
  91. package/dist-vue/apps/web-component/src/composables/useChatbotAuth.d.ts +36 -0
  92. package/dist-vue/composables.js +217 -164
  93. package/dist-vue/composables.js.map +1 -1
  94. package/dist-vue/index.js +8 -8
  95. package/dist-vue/index.js.map +1 -1
  96. package/dist-vue/packages/auth/src/external-auth-plugin.d.ts +22 -0
  97. package/dist-vue/packages/auth/src/external-identity.d.ts +64 -0
  98. package/dist-vue/packages/models/src/schema/McpServer.d.ts +19 -3
  99. package/package.json +2 -2
  100. package/dist/_chunks/VvCheckbox.es-VtDFxWJM.js.map +0 -1
  101. package/dist/_chunks/VvCheckboxGroup.es-D7MifHZN.js.map +0 -1
  102. package/dist/_chunks/VvCombobox.es-Brn06uOj.js.map +0 -1
  103. package/dist/_chunks/VvInputText.es-Co9NrR4l.js.map +0 -1
  104. package/dist/_chunks/VvRadio.es-BxHgVeVy.js.map +0 -1
  105. package/dist/_chunks/VvRadioGroup.es-DZtXJGCi.js.map +0 -1
  106. package/dist/_chunks/VvSelect.es-BR8f0LUN.js.map +0 -1
  107. package/dist/_chunks/VvTextarea.es-TXhUgEuG.js.map +0 -1
  108. package/dist/_chunks/index.es-dTcgyeM4.js.map +0 -1
@@ -51,15 +51,44 @@ declare function externalAuthClient(): {
51
51
  error: null;
52
52
  }>;
53
53
  };
54
+ externalToken: {
55
+ /** Hands the current session a fresh token of its own user. */
56
+ refresh: (data: {
57
+ token: string;
58
+ }) => Promise<{
59
+ data: null;
60
+ error: {
61
+ message?: string | undefined;
62
+ status: number;
63
+ statusText: string;
64
+ };
65
+ } | {
66
+ data: {
67
+ expiresAt: string | null;
68
+ };
69
+ error: null;
70
+ }>;
71
+ };
54
72
  };
55
73
  pathMethods: {
56
74
  '/sign-in/external-token': "POST";
75
+ '/external-token/refresh': "POST";
57
76
  };
58
77
  atomListeners: {
59
78
  matcher: (path: string) => path is "/sign-in/external-token";
60
79
  signal: "$sessionSignal";
61
80
  }[];
62
81
  };
82
+ /**
83
+ * When to ask the host for the next token, in ms from `now`, for a token
84
+ * that expires at `expiresAt` (seconds, the `exp` claim). A minute before
85
+ * the expiry, but never before half of the time left, nor within ten
86
+ * seconds: a token that lives a minute or less, or a browser clock running
87
+ * ahead of the provider's, would otherwise have the host asked again as soon
88
+ * as it answers. Nothing for a token already expired here: asking cannot
89
+ * help it.
90
+ */
91
+ export declare function externalTokenExpiringDelay(expiresAt: number, now?: number): number | undefined;
63
92
  type AuthClientOptions = {
64
93
  baseURL?: string;
65
94
  basePath?: string;
@@ -101,6 +130,13 @@ export declare function useChatbotAuth(options?: {
101
130
  * signature or disabled config): the host should provide a fresh token.
102
131
  */
103
132
  onExternalAuthExpired?: () => void;
133
+ /**
134
+ * Called a minute before the external token of the session expires,
135
+ * while the session goes on: the host should provide a fresh token,
136
+ * which the session takes in place. The MCP servers that receive the
137
+ * user's token need a valid one on every turn.
138
+ */
139
+ onExternalTokenExpiring?: () => void;
104
140
  }): {
105
141
  client: VueAuthClient<AuthClientOptions>;
106
142
  session: Readonly<globalThis.Ref<{