@puckeditor/plugin-ai 0.10.0-canary.e48cba8c → 0.10.0-canary.e516c08f
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/index.js +10 -2
- package/dist/index.mjs +10 -2
- package/package.json +7 -7
package/dist/index.js
CHANGED
|
@@ -4596,7 +4596,7 @@ var usePuck2 = (0, import_core5.createUsePuck)();
|
|
|
4596
4596
|
var DEFAULT_API_VERSION = "v2";
|
|
4597
4597
|
var BUILD_OP_DEBOUNCE_MS = 1e3 / 60;
|
|
4598
4598
|
var CLIENT_TOOL_ENDPOINT_UNAVAILABLE_ERROR_MESSAGE = "Unable to verify the page data. Please enable the `/chat/tool` endpoint on the server and try again.";
|
|
4599
|
-
var PLUGIN_AI_VERSION = true ? "0.10.0-canary.
|
|
4599
|
+
var PLUGIN_AI_VERSION = true ? "0.10.0-canary.e516c08f" : "unknown";
|
|
4600
4600
|
var prefixedUlid = (prefix = "") => `${prefix ? `${prefix}_` : ""}${(0, import_ulid.ulid)()}`;
|
|
4601
4601
|
async function prepareRequestOptions(defaults, prepareRequest) {
|
|
4602
4602
|
if (!prepareRequest) return defaults;
|
|
@@ -4926,7 +4926,15 @@ function usePuckAiInternal({
|
|
|
4926
4926
|
if (options.isAbort || options.isDisconnect || options.isError) {
|
|
4927
4927
|
setToolStatus((current) => finishLoadingTools(current, "Interrupted"));
|
|
4928
4928
|
}
|
|
4929
|
-
settle().then(() =>
|
|
4929
|
+
settle().then(() => {
|
|
4930
|
+
onFinish?.(options);
|
|
4931
|
+
const addedAsset = (options.message?.parts ?? []).some(
|
|
4932
|
+
(part) => part.type === "tool-generateImage" && part.state === "output-available"
|
|
4933
|
+
);
|
|
4934
|
+
if (addedAsset) {
|
|
4935
|
+
window.dispatchEvent(new CustomEvent("puckeditor:assets-changed"));
|
|
4936
|
+
}
|
|
4937
|
+
});
|
|
4930
4938
|
}
|
|
4931
4939
|
});
|
|
4932
4940
|
const sendMessage = (0, import_react18.useCallback)(
|
package/dist/index.mjs
CHANGED
|
@@ -4627,7 +4627,7 @@ var usePuck2 = createUsePuck2();
|
|
|
4627
4627
|
var DEFAULT_API_VERSION = "v2";
|
|
4628
4628
|
var BUILD_OP_DEBOUNCE_MS = 1e3 / 60;
|
|
4629
4629
|
var CLIENT_TOOL_ENDPOINT_UNAVAILABLE_ERROR_MESSAGE = "Unable to verify the page data. Please enable the `/chat/tool` endpoint on the server and try again.";
|
|
4630
|
-
var PLUGIN_AI_VERSION = true ? "0.10.0-canary.
|
|
4630
|
+
var PLUGIN_AI_VERSION = true ? "0.10.0-canary.e516c08f" : "unknown";
|
|
4631
4631
|
var prefixedUlid = (prefix = "") => `${prefix ? `${prefix}_` : ""}${ulid()}`;
|
|
4632
4632
|
async function prepareRequestOptions(defaults, prepareRequest) {
|
|
4633
4633
|
if (!prepareRequest) return defaults;
|
|
@@ -4957,7 +4957,15 @@ function usePuckAiInternal({
|
|
|
4957
4957
|
if (options.isAbort || options.isDisconnect || options.isError) {
|
|
4958
4958
|
setToolStatus((current) => finishLoadingTools(current, "Interrupted"));
|
|
4959
4959
|
}
|
|
4960
|
-
settle().then(() =>
|
|
4960
|
+
settle().then(() => {
|
|
4961
|
+
onFinish?.(options);
|
|
4962
|
+
const addedAsset = (options.message?.parts ?? []).some(
|
|
4963
|
+
(part) => part.type === "tool-generateImage" && part.state === "output-available"
|
|
4964
|
+
);
|
|
4965
|
+
if (addedAsset) {
|
|
4966
|
+
window.dispatchEvent(new CustomEvent("puckeditor:assets-changed"));
|
|
4967
|
+
}
|
|
4968
|
+
});
|
|
4961
4969
|
}
|
|
4962
4970
|
});
|
|
4963
4971
|
const sendMessage = useCallback5(
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@puckeditor/plugin-ai",
|
|
3
|
-
"version": "0.10.0-canary.
|
|
3
|
+
"version": "0.10.0-canary.e516c08f",
|
|
4
4
|
"author": "Chris Villa <chris@puckeditor.com>",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -54,12 +54,12 @@
|
|
|
54
54
|
"typescript": "^5.5.4",
|
|
55
55
|
"vite-tsconfig-paths": "^5.1.4",
|
|
56
56
|
"vitest": "^4.1.12",
|
|
57
|
-
"
|
|
58
|
-
"
|
|
59
|
-
"@puckeditor/ai-types": "0.10.0-canary.
|
|
60
|
-
"
|
|
61
|
-
"
|
|
62
|
-
"tsup-config": "0.10.0-canary.
|
|
57
|
+
"@puckeditor/platform-types": "0.10.0-canary.e516c08f",
|
|
58
|
+
"eslint-config-custom": "0.10.0-canary.e516c08f",
|
|
59
|
+
"@puckeditor/ai-types": "0.10.0-canary.e516c08f",
|
|
60
|
+
"tsconfig": "0.10.0-canary.e516c08f",
|
|
61
|
+
"reducer": "0.10.0-canary.e516c08f",
|
|
62
|
+
"tsup-config": "0.10.0-canary.e516c08f"
|
|
63
63
|
},
|
|
64
64
|
"peerDependencies": {
|
|
65
65
|
"@puckeditor/core": "^0",
|