@embeddable.com/sdk-core 3.14.7-next.3 → 3.14.7-next.5
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/lib/index.esm.js +14 -7
- package/lib/index.esm.js.map +1 -1
- package/package.json +3 -3
- package/src/dev.test.ts +25 -0
- package/src/dev.ts +15 -7
package/lib/index.esm.js
CHANGED
|
@@ -22356,6 +22356,7 @@ const globalCustomCanvasWatcher = (ctx) => {
|
|
|
22356
22356
|
return fsWatcher;
|
|
22357
22357
|
};
|
|
22358
22358
|
const sendBuildChanges = async (ctx) => {
|
|
22359
|
+
var _a, _b, _c, _d;
|
|
22359
22360
|
const isValid = await validate(ctx);
|
|
22360
22361
|
if (!isValid) {
|
|
22361
22362
|
return sendMessage("dataModelsAndOrSecurityContextUpdateError");
|
|
@@ -22386,13 +22387,19 @@ const sendBuildChanges = async (ctx) => {
|
|
|
22386
22387
|
].map((entry) => [path.basename(entry[1]), entry[1]]);
|
|
22387
22388
|
filesList = [...filesList, ...cubeAndSecurityContextFileList];
|
|
22388
22389
|
}
|
|
22389
|
-
|
|
22390
|
-
|
|
22391
|
-
|
|
22392
|
-
|
|
22393
|
-
|
|
22394
|
-
|
|
22395
|
-
|
|
22390
|
+
try {
|
|
22391
|
+
const token = await getToken();
|
|
22392
|
+
await archive({
|
|
22393
|
+
ctx,
|
|
22394
|
+
filesList,
|
|
22395
|
+
isDev: true,
|
|
22396
|
+
});
|
|
22397
|
+
await sendBuild(ctx, { workspaceId: previewWorkspace, token });
|
|
22398
|
+
}
|
|
22399
|
+
catch (e) {
|
|
22400
|
+
sending.fail(`Data models and/or security context synchronization failed with error: ${(_d = (_c = (_b = (_a = e.response) === null || _a === void 0 ? void 0 : _a.data) === null || _b === void 0 ? void 0 : _b.errorMessage) !== null && _c !== void 0 ? _c : e.message) !== null && _d !== void 0 ? _d : 'Unknown error'}`);
|
|
22401
|
+
return sendMessage("dataModelsAndOrSecurityContextUpdateError");
|
|
22402
|
+
}
|
|
22396
22403
|
sending.succeed(`Data models and/or security context synchronized`);
|
|
22397
22404
|
sendMessage("dataModelsAndOrSecurityContextUpdateSuccess");
|
|
22398
22405
|
};
|