@xpert-ai/chatkit-web-component 0.17.0 → 0.18.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.
package/dist/xpert-chatkit.js
CHANGED
|
@@ -381,7 +381,13 @@ function createSecureChannelId() {
|
|
|
381
381
|
return null;
|
|
382
382
|
}
|
|
383
383
|
function safeRandomUUID() {
|
|
384
|
-
|
|
384
|
+
const id = createSecureChannelId();
|
|
385
|
+
if (id === null) {
|
|
386
|
+
throw new Error(
|
|
387
|
+
"ChatKit requires crypto.randomUUID or crypto.getRandomValues to generate secure UUIDs."
|
|
388
|
+
);
|
|
389
|
+
}
|
|
390
|
+
return id;
|
|
385
391
|
}
|
|
386
392
|
function isTrustedChatKitMessageEvent(event, { channelId, expectedOrigin, expectedSource }) {
|
|
387
393
|
const payload = event.data;
|
|
@@ -2861,6 +2867,10 @@ class ChatKitElementBase extends (_c = HTMLElement, _focusComposer_dec = [requir
|
|
|
2861
2867
|
}
|
|
2862
2868
|
return connect(request);
|
|
2863
2869
|
},
|
|
2870
|
+
onWorkbenchNavigationChange: async (navigation) => {
|
|
2871
|
+
var _a2, _b2, _c2;
|
|
2872
|
+
await ((_c2 = (_b2 = (_a2 = __privateGet(this, _opts)) == null ? void 0 : _a2.workbench) == null ? void 0 : _b2.onNavigationChange) == null ? void 0 : _c2.call(_b2, navigation));
|
|
2873
|
+
},
|
|
2864
2874
|
onWorkbenchClientCommand: async ({
|
|
2865
2875
|
commandKey,
|
|
2866
2876
|
payload,
|