@superblocksteam/library 2.0.0-next.103 → 2.0.0-next.105
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/{allPaths-Dm4m7tGA.js → allPaths-CFupmz0n.js} +2 -2
- package/dist/{allPaths-Dm4m7tGA.js.map → allPaths-CFupmz0n.js.map} +1 -1
- package/dist/{allPaths-CnHspLPW.js → allPaths-DXhCHwqA.js} +2 -2
- package/dist/{allPaths-CnHspLPW.js.map → allPaths-DXhCHwqA.js.map} +1 -1
- package/dist/{allPathsLoader-BwGQ2Dws.js → allPathsLoader-BNlRJuEf.js} +3 -3
- package/dist/{allPathsLoader-BwGQ2Dws.js.map → allPathsLoader-BNlRJuEf.js.map} +1 -1
- package/dist/{allPathsLoader-D7A7Pv5K.js → allPathsLoader-DSzl66vm.js} +3 -3
- package/dist/{allPathsLoader-D7A7Pv5K.js.map → allPathsLoader-DSzl66vm.js.map} +1 -1
- package/dist/{index-LLru6csA.js → index--WgLdVs1.js} +55 -154
- package/dist/{index-LLru6csA.js.map → index--WgLdVs1.js.map} +1 -1
- package/dist/index.js +2 -2
- package/dist/{splitPathsBySizeLoader-B8WkZF3L.js → splitPathsBySizeLoader-BEDIEt1Q.js} +2 -2
- package/dist/{splitPathsBySizeLoader-B8WkZF3L.js.map → splitPathsBySizeLoader-BEDIEt1Q.js.map} +1 -1
- package/dist/{splitPathsBySizeLoader-dklJRlhp.js → splitPathsBySizeLoader-D_NFLN6H.js} +2 -2
- package/dist/{splitPathsBySizeLoader-dklJRlhp.js.map → splitPathsBySizeLoader-D_NFLN6H.js.map} +1 -1
- package/dist-types/edit-mode/features/properties-panel-manager.d.ts +0 -1
- package/dist-types/edit-mode/right-click-menu/right-click-menu.d.ts +1 -2
- package/dist-types/lib/internal-details/lib/evaluator/base-entity-manager.d.ts +0 -1
- package/dist-types/lib/internal-details/lib/evaluator/entity-manager.d.ts +0 -1
- package/dist-types/lib/internal-details/lib/evaluator/use-shallow-mobx-observer.d.ts +1 -1
- package/package.json +2 -2
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { I as IconSvgPaths16 } from "./index-BxzKdlqH.js";
|
|
2
2
|
import { I as IconSvgPaths20 } from "./index-DIn-fanT.js";
|
|
3
|
-
import { p as pascalCase, b as IconSize } from "./index
|
|
3
|
+
import { p as pascalCase, b as IconSize } from "./index--WgLdVs1.js";
|
|
4
4
|
function getIconPaths(name, size) {
|
|
5
5
|
var key = pascalCase(name);
|
|
6
6
|
return size === IconSize.STANDARD ? IconSvgPaths16[key] : IconSvgPaths20[key];
|
|
@@ -14,4 +14,4 @@ export {
|
|
|
14
14
|
getIconPaths,
|
|
15
15
|
iconNameToPathsRecordKey
|
|
16
16
|
};
|
|
17
|
-
//# sourceMappingURL=allPaths-
|
|
17
|
+
//# sourceMappingURL=allPaths-CFupmz0n.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"allPaths-
|
|
1
|
+
{"version":3,"file":"allPaths-CFupmz0n.js","sources":["../../../node_modules/.pnpm/@blueprintjs+icons@5.20.0_@types+react@18.3.18_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@blueprintjs/icons/lib/esm/allPaths.js"],"sourcesContent":["/*\n * Copyright 2021 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { pascalCase } from \"change-case\";\nimport * as IconSvgPaths16 from \"./generated/16px/paths\";\nimport * as IconSvgPaths20 from \"./generated/20px/paths\";\nimport { IconSize } from \"./iconTypes\";\nexport { IconSvgPaths16, IconSvgPaths20 };\n/**\n * Get the list of vector paths that define a given icon. These path strings are used to render `<path>`\n * elements inside an `<svg>` icon element. For full implementation details and nuances, see the icon component\n * handlebars template and `generate-icon-components` script in the __@blueprintjs/icons__ package.\n *\n * Note: this function loads all icon definitions __statically__, which means every icon is included in your\n * JS bundle. Only use this API if your app is likely to use all Blueprint icons at runtime. If you are looking for a\n * dynamic icon loader which loads icon definitions on-demand, use `{ Icons } from \"@blueprintjs/icons\"` instead.\n */\nexport function getIconPaths(name, size) {\n var key = pascalCase(name);\n return size === IconSize.STANDARD ? IconSvgPaths16[key] : IconSvgPaths20[key];\n}\n/**\n * Type safe string literal conversion of snake-case icon names to PascalCase icon names.\n * This is useful for indexing into the SVG paths record to extract a single icon's SVG path definition.\n *\n * @deprecated use `getIconPaths` instead\n */\nexport function iconNameToPathsRecordKey(name) {\n return pascalCase(name);\n}\n//# sourceMappingURL=allPaths.js.map"],"names":[],"mappings":";;;AA6BO,SAAS,aAAa,MAAM,MAAM;AACrC,MAAI,MAAM,WAAW,IAAI;AACzB,SAAO,SAAS,SAAS,WAAW,eAAe,GAAG,IAAI,eAAe,GAAG;AAChF;AAOO,SAAS,yBAAyB,MAAM;AAC3C,SAAO,WAAW,IAAI;AAC1B;","x_google_ignoreList":[0]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { I as IconSvgPaths16 } from "./index-DIJYif9G.js";
|
|
2
2
|
import { I as IconSvgPaths20 } from "./index-LHtbj0-V.js";
|
|
3
|
-
import { p as pascalCase, I as IconSize } from "./index
|
|
3
|
+
import { p as pascalCase, I as IconSize } from "./index--WgLdVs1.js";
|
|
4
4
|
function getIconPaths(name, size) {
|
|
5
5
|
var key = pascalCase(name);
|
|
6
6
|
return size === IconSize.STANDARD ? IconSvgPaths16[key] : IconSvgPaths20[key];
|
|
@@ -14,4 +14,4 @@ export {
|
|
|
14
14
|
getIconPaths,
|
|
15
15
|
iconNameToPathsRecordKey
|
|
16
16
|
};
|
|
17
|
-
//# sourceMappingURL=allPaths-
|
|
17
|
+
//# sourceMappingURL=allPaths-DXhCHwqA.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"allPaths-
|
|
1
|
+
{"version":3,"file":"allPaths-DXhCHwqA.js","sources":["../../../node_modules/.pnpm/@blueprintjs+icons@5.18.1_@types+react@18.3.18_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@blueprintjs/icons/lib/esm/allPaths.js"],"sourcesContent":["/*\n * Copyright 2021 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { pascalCase } from \"change-case\";\nimport * as IconSvgPaths16 from \"./generated/16px/paths\";\nimport * as IconSvgPaths20 from \"./generated/20px/paths\";\nimport { IconSize } from \"./iconTypes\";\nexport { IconSvgPaths16, IconSvgPaths20 };\n/**\n * Get the list of vector paths that define a given icon. These path strings are used to render `<path>`\n * elements inside an `<svg>` icon element. For full implementation details and nuances, see the icon component\n * handlebars template and `generate-icon-components` script in the __@blueprintjs/icons__ package.\n *\n * Note: this function loads all icon definitions __statically__, which means every icon is included in your\n * JS bundle. Only use this API if your app is likely to use all Blueprint icons at runtime. If you are looking for a\n * dynamic icon loader which loads icon definitions on-demand, use `{ Icons } from \"@blueprintjs/icons\"` instead.\n */\nexport function getIconPaths(name, size) {\n var key = pascalCase(name);\n return size === IconSize.STANDARD ? IconSvgPaths16[key] : IconSvgPaths20[key];\n}\n/**\n * Type safe string literal conversion of snake-case icon names to PascalCase icon names.\n * This is useful for indexing into the SVG paths record to extract a single icon's SVG path definition.\n *\n * @deprecated use `getIconPaths` instead\n */\nexport function iconNameToPathsRecordKey(name) {\n return pascalCase(name);\n}\n//# sourceMappingURL=allPaths.js.map"],"names":[],"mappings":";;;AA6BO,SAAS,aAAa,MAAM,MAAM;AACrC,MAAI,MAAM,WAAW,IAAI;AACzB,SAAO,SAAS,SAAS,WAAW,eAAe,GAAG,IAAI,eAAe,GAAG;AAChF;AAOO,SAAS,yBAAyB,MAAM;AAC3C,SAAO,WAAW,IAAI;AAC1B;","x_google_ignoreList":[0]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as __awaiter, a as __generator } from "./index
|
|
1
|
+
import { _ as __awaiter, a as __generator } from "./index--WgLdVs1.js";
|
|
2
2
|
var allPathsLoader = function(name, size) {
|
|
3
3
|
return __awaiter(void 0, void 0, void 0, function() {
|
|
4
4
|
var getIconPaths;
|
|
@@ -7,7 +7,7 @@ var allPathsLoader = function(name, size) {
|
|
|
7
7
|
case 0:
|
|
8
8
|
return [4, import(
|
|
9
9
|
/* webpackChunkName: "blueprint-icons-all-paths" */
|
|
10
|
-
"./allPaths-
|
|
10
|
+
"./allPaths-CFupmz0n.js"
|
|
11
11
|
)];
|
|
12
12
|
case 1:
|
|
13
13
|
getIconPaths = _a.sent().getIconPaths;
|
|
@@ -19,4 +19,4 @@ var allPathsLoader = function(name, size) {
|
|
|
19
19
|
export {
|
|
20
20
|
allPathsLoader
|
|
21
21
|
};
|
|
22
|
-
//# sourceMappingURL=allPathsLoader-
|
|
22
|
+
//# sourceMappingURL=allPathsLoader-BNlRJuEf.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"allPathsLoader-
|
|
1
|
+
{"version":3,"file":"allPathsLoader-BNlRJuEf.js","sources":["../../../node_modules/.pnpm/@blueprintjs+icons@5.20.0_@types+react@18.3.18_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@blueprintjs/icons/lib/esm/paths-loaders/allPathsLoader.js"],"sourcesContent":["/*\n * Copyright 2023 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { __awaiter, __generator } from \"tslib\";\n/**\n * A simple module loader which concatenates all icon paths into a single chunk.\n */\nexport var allPathsLoader = function (name, size) { return __awaiter(void 0, void 0, void 0, function () {\n var getIconPaths;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4 /*yield*/, import(\n /* webpackChunkName: \"blueprint-icons-all-paths\" */\n \"../allPaths\")];\n case 1:\n getIconPaths = (_a.sent()).getIconPaths;\n return [2 /*return*/, getIconPaths(name, size)];\n }\n });\n}); };\n//# sourceMappingURL=allPathsLoader.js.map"],"names":[],"mappings":";AAmBU,IAAC,iBAAiB,SAAU,MAAM,MAAM;AAAE,SAAO,UAAU,QAAQ,QAAQ,QAAQ,WAAY;AACrG,QAAI;AACJ,WAAO,YAAY,MAAM,SAAU,IAAI;AACnC,cAAQ,GAAG,OAAK;AAAA,QACZ,KAAK;AAAG,iBAAO,CAAC,GAAa;AAAA;AAAA,YAEzB;AAAA,UAAa,CAAC;AAAA,QAClB,KAAK;AACD,yBAAgB,GAAG,KAAI,EAAI;AAC3B,iBAAO,CAAC,GAAc,aAAa,MAAM,IAAI,CAAC;AAAA,MAC9D;AAAA,IACA,CAAK;AAAA,EACL,CAAC;AAAE;","x_google_ignoreList":[0]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as __awaiter, a as __generator } from "./index
|
|
1
|
+
import { _ as __awaiter, a as __generator } from "./index--WgLdVs1.js";
|
|
2
2
|
var allPathsLoader = function(name, size) {
|
|
3
3
|
return __awaiter(void 0, void 0, void 0, function() {
|
|
4
4
|
var getIconPaths;
|
|
@@ -7,7 +7,7 @@ var allPathsLoader = function(name, size) {
|
|
|
7
7
|
case 0:
|
|
8
8
|
return [4, import(
|
|
9
9
|
/* webpackChunkName: "blueprint-icons-all-paths" */
|
|
10
|
-
"./allPaths-
|
|
10
|
+
"./allPaths-DXhCHwqA.js"
|
|
11
11
|
)];
|
|
12
12
|
case 1:
|
|
13
13
|
getIconPaths = _a.sent().getIconPaths;
|
|
@@ -19,4 +19,4 @@ var allPathsLoader = function(name, size) {
|
|
|
19
19
|
export {
|
|
20
20
|
allPathsLoader
|
|
21
21
|
};
|
|
22
|
-
//# sourceMappingURL=allPathsLoader-
|
|
22
|
+
//# sourceMappingURL=allPathsLoader-DSzl66vm.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"allPathsLoader-
|
|
1
|
+
{"version":3,"file":"allPathsLoader-DSzl66vm.js","sources":["../../../node_modules/.pnpm/@blueprintjs+icons@5.18.1_@types+react@18.3.18_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@blueprintjs/icons/lib/esm/paths-loaders/allPathsLoader.js"],"sourcesContent":["/*\n * Copyright 2023 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { __awaiter, __generator } from \"tslib\";\n/**\n * A simple module loader which concatenates all icon paths into a single chunk.\n */\nexport var allPathsLoader = function (name, size) { return __awaiter(void 0, void 0, void 0, function () {\n var getIconPaths;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4 /*yield*/, import(\n /* webpackChunkName: \"blueprint-icons-all-paths\" */\n \"../allPaths\")];\n case 1:\n getIconPaths = (_a.sent()).getIconPaths;\n return [2 /*return*/, getIconPaths(name, size)];\n }\n });\n}); };\n//# sourceMappingURL=allPathsLoader.js.map"],"names":[],"mappings":";AAmBU,IAAC,iBAAiB,SAAU,MAAM,MAAM;AAAE,SAAO,UAAU,QAAQ,QAAQ,QAAQ,WAAY;AACrG,QAAI;AACJ,WAAO,YAAY,MAAM,SAAU,IAAI;AACnC,cAAQ,GAAG,OAAK;AAAA,QACZ,KAAK;AAAG,iBAAO,CAAC,GAAa;AAAA;AAAA,YAEzB;AAAA,UAAa,CAAC;AAAA,QAClB,KAAK;AACD,yBAAgB,GAAG,KAAI,EAAI;AAC3B,iBAAO,CAAC,GAAc,aAAa,MAAM,IAAI,CAAC;AAAA,MAC9D;AAAA,IACA,CAAK;AAAA,EACL,CAAC;AAAE;","x_google_ignoreList":[0]}
|
|
@@ -2684,14 +2684,14 @@ function getLoaderFn$1(options) {
|
|
|
2684
2684
|
if (!(loader === "all")) return [3, 3];
|
|
2685
2685
|
return [4, import(
|
|
2686
2686
|
/* webpackChunkName: "blueprint-icons-all-paths-loader" */
|
|
2687
|
-
"./allPathsLoader-
|
|
2687
|
+
"./allPathsLoader-DSzl66vm.js"
|
|
2688
2688
|
)];
|
|
2689
2689
|
case 2:
|
|
2690
2690
|
return [2, _b2.sent().allPathsLoader];
|
|
2691
2691
|
case 3:
|
|
2692
2692
|
return [4, import(
|
|
2693
2693
|
/* webpackChunkName: "blueprint-icons-split-paths-by-size-loader" */
|
|
2694
|
-
"./splitPathsBySizeLoader-
|
|
2694
|
+
"./splitPathsBySizeLoader-D_NFLN6H.js"
|
|
2695
2695
|
)];
|
|
2696
2696
|
case 4:
|
|
2697
2697
|
return [2, _b2.sent().splitPathsBySizeLoader];
|
|
@@ -94273,8 +94273,6 @@ class EntityManager {
|
|
|
94273
94273
|
makeObservable(this, {
|
|
94274
94274
|
createScope: action,
|
|
94275
94275
|
deleteScope: action,
|
|
94276
|
-
// this method is intentionally not an action, we want control when reactions run
|
|
94277
|
-
moveScope: false,
|
|
94278
94276
|
setValidationState: action,
|
|
94279
94277
|
getFullState: computed,
|
|
94280
94278
|
getValidationState: computed,
|
|
@@ -94401,46 +94399,6 @@ class EntityManager {
|
|
|
94401
94399
|
throw new Error(`Cannot delete root scope`);
|
|
94402
94400
|
}
|
|
94403
94401
|
}
|
|
94404
|
-
moveScope(oldScopeId, newScopeId, newName) {
|
|
94405
|
-
const scope = this.state;
|
|
94406
|
-
let currentScope = scope;
|
|
94407
|
-
let parentScope = void 0;
|
|
94408
|
-
while (currentScope) {
|
|
94409
|
-
if (currentScope.id === oldScopeId) {
|
|
94410
|
-
break;
|
|
94411
|
-
}
|
|
94412
|
-
parentScope = currentScope;
|
|
94413
|
-
currentScope = Object.values(currentScope.childScopes).find(
|
|
94414
|
-
(childScope) => childScope.id === oldScopeId
|
|
94415
|
-
);
|
|
94416
|
-
}
|
|
94417
|
-
if (!currentScope) {
|
|
94418
|
-
console.warn(
|
|
94419
|
-
`Scope with id ${oldScopeId} not found, could not move scope`
|
|
94420
|
-
);
|
|
94421
|
-
return;
|
|
94422
|
-
}
|
|
94423
|
-
transaction(() => {
|
|
94424
|
-
if (parentScope) {
|
|
94425
|
-
const newScope = buildEntityScope(newScopeId, newName);
|
|
94426
|
-
newScope.entities = currentScope.entities;
|
|
94427
|
-
newScope.entityMeta = currentScope.entityMeta;
|
|
94428
|
-
newScope.idToName = currentScope.idToName;
|
|
94429
|
-
newScope.childScopes = currentScope.childScopes;
|
|
94430
|
-
parentScope.childScopes[newScopeId] = newScope;
|
|
94431
|
-
for (const [name, entity] of Object.entries(newScope.entities)) {
|
|
94432
|
-
this.updateEntity({
|
|
94433
|
-
scopeId: newScopeId,
|
|
94434
|
-
name: getName(name),
|
|
94435
|
-
props: toJS({ ...entity }),
|
|
94436
|
-
// we need a copy to not trigger atom gets
|
|
94437
|
-
instanceId: entity.instanceId
|
|
94438
|
-
});
|
|
94439
|
-
}
|
|
94440
|
-
}
|
|
94441
|
-
});
|
|
94442
|
-
this.deleteScope({ scopeId: oldScopeId });
|
|
94443
|
-
}
|
|
94444
94402
|
createEntity(params) {
|
|
94445
94403
|
const { scopeId, name, props: props2, type: type5, instanceId } = params;
|
|
94446
94404
|
this.createEntityStructure(scopeId, name, props2, type5, instanceId);
|
|
@@ -94470,18 +94428,18 @@ class EntityManager {
|
|
|
94470
94428
|
const functionalProps = toExecutablesOrValues(props2, managedPropsForType);
|
|
94471
94429
|
const addedProperties = /* @__PURE__ */ new Set();
|
|
94472
94430
|
for (const [prop, value] of functionalProps) {
|
|
94473
|
-
this.addProperty(
|
|
94431
|
+
this.addProperty(scopeId, name, prop, value);
|
|
94474
94432
|
addedProperties.add(prop);
|
|
94475
94433
|
}
|
|
94476
94434
|
this.addMissingProps(managedPropsForType, addedProperties, scopeId, name);
|
|
94477
94435
|
}
|
|
94478
|
-
addProperty(
|
|
94436
|
+
addProperty(scopeId, name, prop, eov) {
|
|
94479
94437
|
if (prop.split(".").includes(RECORD_PATH_IDENTIFIER)) {
|
|
94480
94438
|
console.log(`ALERT: Cannot add a property with a record path (${prop})`);
|
|
94481
94439
|
return;
|
|
94482
94440
|
}
|
|
94483
|
-
const entity =
|
|
94484
|
-
const entityMeta =
|
|
94441
|
+
const entity = this.getScope(scopeId).getEntity(name);
|
|
94442
|
+
const entityMeta = this.getScope(scopeId).getEntityMeta(name);
|
|
94485
94443
|
const pathSegments = prop.split(".");
|
|
94486
94444
|
const isNested = pathSegments.length > 1;
|
|
94487
94445
|
const finalSegment = pathSegments.pop() || "";
|
|
@@ -94505,7 +94463,7 @@ class EntityManager {
|
|
|
94505
94463
|
const entityType = entity.type;
|
|
94506
94464
|
if (eov.type === "external-function") {
|
|
94507
94465
|
const finalFunction = async (...args) => this.dirComputeEngine.compute({
|
|
94508
|
-
snapshot: snapshot(
|
|
94466
|
+
snapshot: snapshot(scopeId),
|
|
94509
94467
|
func: eov.value,
|
|
94510
94468
|
path: prop,
|
|
94511
94469
|
args,
|
|
@@ -94519,7 +94477,7 @@ class EntityManager {
|
|
|
94519
94477
|
const finalFunction = async (...args) => {
|
|
94520
94478
|
await runEventHandlers({
|
|
94521
94479
|
flow: eov.value,
|
|
94522
|
-
scopeId
|
|
94480
|
+
scopeId,
|
|
94523
94481
|
additionalContext: args[0],
|
|
94524
94482
|
get name() {
|
|
94525
94483
|
return getName(entity.name);
|
|
@@ -94542,7 +94500,7 @@ class EntityManager {
|
|
|
94542
94500
|
} else {
|
|
94543
94501
|
if (isComputed) {
|
|
94544
94502
|
ret = computeEngine.compute({
|
|
94545
|
-
snapshot: snapshot(
|
|
94503
|
+
snapshot: snapshot(scopeId),
|
|
94546
94504
|
entityName: name,
|
|
94547
94505
|
func: eov.value,
|
|
94548
94506
|
path: prop
|
|
@@ -94553,7 +94511,7 @@ class EntityManager {
|
|
|
94553
94511
|
}
|
|
94554
94512
|
const managedProp = this.componentRegistry.getManagedProps(entityType).find((p) => p.path === prop);
|
|
94555
94513
|
if (managedProp == null ? void 0 : managedProp.validate) {
|
|
94556
|
-
const currentState = snapshot(
|
|
94514
|
+
const currentState = snapshot(scopeId);
|
|
94557
94515
|
const entity2 = currentState[name.value];
|
|
94558
94516
|
const validationResult = managedProp.validate(ret, entity2);
|
|
94559
94517
|
if (entity2[WIDGET_SOURCE_ID_ATTRIBUTE]) {
|
|
@@ -94582,7 +94540,7 @@ class EntityManager {
|
|
|
94582
94540
|
const metaParent = getMetaParent();
|
|
94583
94541
|
metaParent[finalSegment] = value;
|
|
94584
94542
|
};
|
|
94585
|
-
const { atom, isNew } = this.getOrCreateAtom(
|
|
94543
|
+
const { atom, isNew } = this.getOrCreateAtom(scopeId, name, prop);
|
|
94586
94544
|
Object.defineProperty(propParent, finalSegment, {
|
|
94587
94545
|
get: () => {
|
|
94588
94546
|
atom.reportObserved();
|
|
@@ -94732,7 +94690,7 @@ class EntityManager {
|
|
|
94732
94690
|
const functionalProps = toExecutablesOrValues(props2, managedPropsForType);
|
|
94733
94691
|
const addedProperties = /* @__PURE__ */ new Set();
|
|
94734
94692
|
for (const [prop, value] of functionalProps) {
|
|
94735
|
-
this.addProperty(
|
|
94693
|
+
this.addProperty(scopeId, name, prop, value);
|
|
94736
94694
|
addedProperties.add(prop);
|
|
94737
94695
|
}
|
|
94738
94696
|
const missingPropKeys = Object.keys(entity).filter((key2) => {
|
|
@@ -94745,14 +94703,13 @@ class EntityManager {
|
|
|
94745
94703
|
this.addMissingProps(managedPropsForType, addedProperties, scopeId, name);
|
|
94746
94704
|
}
|
|
94747
94705
|
addMissingProps(managedProps, addedProperties, scopeId, name) {
|
|
94748
|
-
const
|
|
94749
|
-
const entity = scope.getEntity(name);
|
|
94706
|
+
const entity = this.getScope(scopeId).getEntity(name);
|
|
94750
94707
|
for (const prop of managedProps) {
|
|
94751
94708
|
if (lodashExports.get(entity, prop.path) == null && !addedProperties.has(prop.path) && // for nested properties, only set if the default is defined
|
|
94752
94709
|
// for top-level properties, we should always add the property
|
|
94753
94710
|
(!isNestedPath(prop.path) || prop.default !== void 0)) {
|
|
94754
94711
|
this.addProperty(
|
|
94755
|
-
|
|
94712
|
+
scopeId,
|
|
94756
94713
|
name,
|
|
94757
94714
|
prop.path,
|
|
94758
94715
|
toExecutableOrValue(
|
|
@@ -95885,7 +95842,7 @@ function startEditorSync(options) {
|
|
|
95885
95842
|
});
|
|
95886
95843
|
}
|
|
95887
95844
|
},
|
|
95888
|
-
|
|
95845
|
+
reactionOptions
|
|
95889
95846
|
);
|
|
95890
95847
|
};
|
|
95891
95848
|
const projectionDisposers = projectionKeys.reduce(
|
|
@@ -95925,7 +95882,7 @@ function startEditorSync(options) {
|
|
|
95925
95882
|
});
|
|
95926
95883
|
});
|
|
95927
95884
|
},
|
|
95928
|
-
|
|
95885
|
+
reactionOptions
|
|
95929
95886
|
);
|
|
95930
95887
|
return () => {
|
|
95931
95888
|
projectionKeysDisposer();
|
|
@@ -95949,7 +95906,7 @@ function startEditorSync(options) {
|
|
|
95949
95906
|
}
|
|
95950
95907
|
});
|
|
95951
95908
|
},
|
|
95952
|
-
|
|
95909
|
+
reactionOptions
|
|
95953
95910
|
)
|
|
95954
95911
|
);
|
|
95955
95912
|
disposers.push(...computedDisposers);
|
|
@@ -96382,7 +96339,6 @@ function createSbScope(getInitialEntities, options) {
|
|
|
96382
96339
|
name,
|
|
96383
96340
|
scopeId: stableScopeId
|
|
96384
96341
|
});
|
|
96385
|
-
const scope = rootStore.entityManager.getScope(scopeId);
|
|
96386
96342
|
const bindingIds = {};
|
|
96387
96343
|
const getBinding = (key2) => {
|
|
96388
96344
|
if (bindingIds[key2]) {
|
|
@@ -96401,20 +96357,13 @@ function createSbScope(getInitialEntities, options) {
|
|
|
96401
96357
|
if (typeof key2 !== "string") {
|
|
96402
96358
|
return void 0;
|
|
96403
96359
|
}
|
|
96404
|
-
return createBindableEntityProxy(
|
|
96405
|
-
|
|
96406
|
-
|
|
96407
|
-
|
|
96408
|
-
|
|
96409
|
-
|
|
96410
|
-
|
|
96411
|
-
}
|
|
96412
|
-
);
|
|
96413
|
-
return entity;
|
|
96414
|
-
} catch {
|
|
96415
|
-
return void 0;
|
|
96416
|
-
}
|
|
96417
|
-
}, getBinding(key2));
|
|
96360
|
+
return createBindableEntityProxy(
|
|
96361
|
+
() => rootStore.entityManager.getEntity(scopeId, {
|
|
96362
|
+
value: key2,
|
|
96363
|
+
isAnonymous: false
|
|
96364
|
+
}),
|
|
96365
|
+
getBinding(key2)
|
|
96366
|
+
);
|
|
96418
96367
|
}
|
|
96419
96368
|
}
|
|
96420
96369
|
);
|
|
@@ -98348,18 +98297,16 @@ async function connectSocket(serverUrl, {
|
|
|
98348
98297
|
);
|
|
98349
98298
|
}
|
|
98350
98299
|
],
|
|
98351
|
-
|
|
98300
|
+
updateApi: [
|
|
98352
98301
|
async (payload) => {
|
|
98353
|
-
payload.
|
|
98354
|
-
|
|
98355
|
-
|
|
98356
|
-
|
|
98357
|
-
|
|
98358
|
-
|
|
98359
|
-
|
|
98360
|
-
|
|
98361
|
-
}
|
|
98362
|
-
});
|
|
98302
|
+
rootStore.apis.updateApi(payload.api, payload.scopeId);
|
|
98303
|
+
if (payload.oldName) {
|
|
98304
|
+
rootStore.apis.renameApi({
|
|
98305
|
+
api: payload.api,
|
|
98306
|
+
oldName: payload.oldName,
|
|
98307
|
+
scopeId: payload.scopeId
|
|
98308
|
+
});
|
|
98309
|
+
}
|
|
98363
98310
|
}
|
|
98364
98311
|
],
|
|
98365
98312
|
deleteApis: [
|
|
@@ -98424,20 +98371,6 @@ async function connectSocket(serverUrl, {
|
|
|
98424
98371
|
}
|
|
98425
98372
|
});
|
|
98426
98373
|
}
|
|
98427
|
-
],
|
|
98428
|
-
moveScope: [
|
|
98429
|
-
async ({ oldScopeId, newScopeId, newName }) => {
|
|
98430
|
-
var _a3;
|
|
98431
|
-
if (!oldScopeId || !newScopeId) {
|
|
98432
|
-
console.warn("Missing full scope ID information", {
|
|
98433
|
-
oldScopeId,
|
|
98434
|
-
newScopeId
|
|
98435
|
-
});
|
|
98436
|
-
return;
|
|
98437
|
-
}
|
|
98438
|
-
(_a3 = rootStore.editStore) == null ? void 0 : _a3.ui.selectWidget(null);
|
|
98439
|
-
rootStore.entityManager.moveScope(oldScopeId, newScopeId, newName);
|
|
98440
|
-
}
|
|
98441
98374
|
]
|
|
98442
98375
|
},
|
|
98443
98376
|
[],
|
|
@@ -98865,11 +98798,6 @@ class PropertiesPanelManager {
|
|
|
98865
98798
|
editorBridge.addPropertiesPanel(sourceId, propertiesPanel);
|
|
98866
98799
|
});
|
|
98867
98800
|
}
|
|
98868
|
-
untrackPropertiesPanel() {
|
|
98869
|
-
var _a2;
|
|
98870
|
-
(_a2 = this.propertiesPanelTrackerDisposer) == null ? void 0 : _a2.call(this);
|
|
98871
|
-
this.propertiesPanelTrackerDisposer = null;
|
|
98872
|
-
}
|
|
98873
98801
|
getPropertiesDefinition(type5) {
|
|
98874
98802
|
return this.propertiesDefinitions.get(type5);
|
|
98875
98803
|
}
|
|
@@ -101172,7 +101100,6 @@ class UIStore {
|
|
|
101172
101100
|
editorBridge.selectWidgets([], false);
|
|
101173
101101
|
this.setSelectedSourceIds([]);
|
|
101174
101102
|
this.setSelectedInstanceIds([]);
|
|
101175
|
-
this.editStore.propertiesPanelManager.untrackPropertiesPanel();
|
|
101176
101103
|
return;
|
|
101177
101104
|
}
|
|
101178
101105
|
this.setSelectedSourceIds(sourceId ? [sourceId] : []);
|
|
@@ -110730,12 +110657,9 @@ const entityActions = {
|
|
|
110730
110657
|
},
|
|
110731
110658
|
update: (entityName, scopeId, run3) => {
|
|
110732
110659
|
runInAction(function updateEntity2() {
|
|
110733
|
-
|
|
110734
|
-
|
|
110735
|
-
|
|
110736
|
-
run3(entity);
|
|
110737
|
-
} catch {
|
|
110738
|
-
}
|
|
110660
|
+
const state = rootStore.entityManager.getState(scopeId);
|
|
110661
|
+
const entity = state[entityName];
|
|
110662
|
+
run3(entity);
|
|
110739
110663
|
});
|
|
110740
110664
|
}
|
|
110741
110665
|
};
|
|
@@ -110743,7 +110667,7 @@ const createEntityActions = (entityName, scopeId) => ({
|
|
|
110743
110667
|
reset: entityActions.reset.bind(null, entityName, scopeId),
|
|
110744
110668
|
update: entityActions.update.bind(null, entityName, scopeId)
|
|
110745
110669
|
});
|
|
110746
|
-
const useShallowMobxObserver = (obj
|
|
110670
|
+
const useShallowMobxObserver = (obj) => {
|
|
110747
110671
|
const isFirstRenderRef = useRef(true);
|
|
110748
110672
|
const [keys2, setKeys] = useState(Object.keys(obj));
|
|
110749
110673
|
const [result, setResult] = useState(() => toJS(obj));
|
|
@@ -110755,9 +110679,6 @@ const useShallowMobxObserver = (obj, attachReactions = true) => {
|
|
|
110755
110679
|
isFirstRenderRef.current = false;
|
|
110756
110680
|
}, [obj]);
|
|
110757
110681
|
useEffect(() => {
|
|
110758
|
-
if (!attachReactions) {
|
|
110759
|
-
return;
|
|
110760
|
-
}
|
|
110761
110682
|
return reaction(
|
|
110762
110683
|
() => Object.keys(obj),
|
|
110763
110684
|
(newKeys) => {
|
|
@@ -110774,11 +110695,8 @@ const useShallowMobxObserver = (obj, attachReactions = true) => {
|
|
|
110774
110695
|
fireImmediately: false
|
|
110775
110696
|
}
|
|
110776
110697
|
);
|
|
110777
|
-
}, [obj
|
|
110698
|
+
}, [obj]);
|
|
110778
110699
|
useEffect(() => {
|
|
110779
|
-
if (!attachReactions) {
|
|
110780
|
-
return;
|
|
110781
|
-
}
|
|
110782
110700
|
const disposers = [];
|
|
110783
110701
|
for (const key2 of keys2) {
|
|
110784
110702
|
disposers.push(
|
|
@@ -110798,7 +110716,7 @@ const useShallowMobxObserver = (obj, attachReactions = true) => {
|
|
|
110798
110716
|
);
|
|
110799
110717
|
}
|
|
110800
110718
|
return () => disposers.forEach((disposer) => disposer());
|
|
110801
|
-
}, [obj, keys2
|
|
110719
|
+
}, [obj, keys2]);
|
|
110802
110720
|
return result;
|
|
110803
110721
|
};
|
|
110804
110722
|
const INVISIBLE_OPACITY = 0.5;
|
|
@@ -110807,8 +110725,6 @@ function removeBindings(props2) {
|
|
|
110807
110725
|
(acc, [key2, value]) => {
|
|
110808
110726
|
if (isBindingString(value)) {
|
|
110809
110727
|
acc[key2] = value.value;
|
|
110810
|
-
} else if (isComputedProperty(value)) {
|
|
110811
|
-
acc[key2] = "";
|
|
110812
110728
|
} else if (typeof value === "object" && value !== null && key2 !== "children" && key2 !== "bind") {
|
|
110813
110729
|
acc[key2] = removeBindings(value);
|
|
110814
110730
|
} else {
|
|
@@ -110883,18 +110799,14 @@ const ReactiveComponent = observer(function Component2({
|
|
|
110883
110799
|
scopeId,
|
|
110884
110800
|
name
|
|
110885
110801
|
);
|
|
110886
|
-
|
|
110887
|
-
|
|
110888
|
-
|
|
110889
|
-
|
|
110890
|
-
isAnonymous: false
|
|
110891
|
-
});
|
|
110892
|
-
} catch {
|
|
110893
|
-
}
|
|
110802
|
+
const entity = rootStore.entityManager.getEntity(scopeId, {
|
|
110803
|
+
value: name,
|
|
110804
|
+
isAnonymous: false
|
|
110805
|
+
});
|
|
110894
110806
|
const safeProps = useMemo$2(() => {
|
|
110895
110807
|
return isNameDuplicated || !entity ? removeBindings(widgetProps) : entity;
|
|
110896
110808
|
}, [isNameDuplicated, widgetProps, entity]);
|
|
110897
|
-
const reactiveProps = useShallowMobxObserver(safeProps
|
|
110809
|
+
const reactiveProps = useShallowMobxObserver(safeProps);
|
|
110898
110810
|
const stylePropWithSize = useStyleWithSize(reactiveProps);
|
|
110899
110811
|
const styleProp = useMemo$2(() => {
|
|
110900
110812
|
if (reactiveProps.isVisible === false) {
|
|
@@ -117448,8 +117360,8 @@ const RightClickMenu = ({
|
|
|
117448
117360
|
);
|
|
117449
117361
|
return /* @__PURE__ */ jsxRuntimeExports.jsx("span", { style: { display: "contents" }, onContextMenu: handleContextMenu, children });
|
|
117450
117362
|
};
|
|
117451
|
-
const RightClickMenuWrapper = ({ disabled,
|
|
117452
|
-
return disabled
|
|
117363
|
+
const RightClickMenuWrapper = ({ disabled, ...props2 }) => {
|
|
117364
|
+
return disabled ? /* @__PURE__ */ jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children: props2.children }) : /* @__PURE__ */ jsxRuntimeExports.jsx(RightClickMenu, { ...props2 });
|
|
117453
117365
|
};
|
|
117454
117366
|
const stableEffectOptions$1 = {
|
|
117455
117367
|
customEqualChecks: [
|
|
@@ -117579,11 +117491,9 @@ const EditWrapper = observer(function EditWrapper2(props2) {
|
|
|
117579
117491
|
children: props2.children
|
|
117580
117492
|
});
|
|
117581
117493
|
const showVisibilityBackground = props2.widgetProps.isVisible === false && !editStore2.ui.getSelectedSourceIds().includes(props2.identifier.sourceId);
|
|
117582
|
-
|
|
117583
|
-
|
|
117584
|
-
|
|
117585
|
-
} catch {
|
|
117586
|
-
}
|
|
117494
|
+
const scopeName = rootStore.entityManager.getScopeName(
|
|
117495
|
+
props2.identifier.scopeId
|
|
117496
|
+
);
|
|
117587
117497
|
const node2 = /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
117588
117498
|
"div",
|
|
117589
117499
|
{
|
|
@@ -117823,12 +117733,7 @@ const stableEffectOptions = {
|
|
|
117823
117733
|
};
|
|
117824
117734
|
const updateEntity = (params) => {
|
|
117825
117735
|
const { scopeId, name, type: type5, props: props2, sourceId, instanceId } = params;
|
|
117826
|
-
|
|
117827
|
-
try {
|
|
117828
|
-
entity = rootStore.entityManager.getEntity(scopeId, name);
|
|
117829
|
-
} catch {
|
|
117830
|
-
return;
|
|
117831
|
-
}
|
|
117736
|
+
const entity = rootStore.entityManager.getEntity(scopeId, name);
|
|
117832
117737
|
if (entity) {
|
|
117833
117738
|
rootStore.entityManager.updateEntity({
|
|
117834
117739
|
scopeId,
|
|
@@ -118980,16 +118885,12 @@ const StackChild = observer(
|
|
|
118980
118885
|
if (!name || !scopeId) {
|
|
118981
118886
|
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { style: { display: "none" }, children: injectedChild });
|
|
118982
118887
|
}
|
|
118983
|
-
|
|
118984
|
-
try {
|
|
118985
|
-
runtimeProps = rootStore.entityManager.getEntity(scopeId, name);
|
|
118986
|
-
} catch {
|
|
118987
|
-
}
|
|
118888
|
+
const runtimeProps = rootStore.entityManager.getEntity(scopeId, name);
|
|
118988
118889
|
if ((runtimeProps == null ? void 0 : runtimeProps.isVisible) === false && !isEditing) {
|
|
118989
118890
|
return null;
|
|
118990
118891
|
}
|
|
118991
118892
|
const style2 = getStackChildStyle({
|
|
118992
|
-
childProps: runtimeProps
|
|
118893
|
+
childProps: runtimeProps,
|
|
118993
118894
|
primary,
|
|
118994
118895
|
childCount,
|
|
118995
118896
|
parentHeight,
|
|
@@ -144655,14 +144556,14 @@ function getLoaderFn(options) {
|
|
|
144655
144556
|
if (!(loader === "all")) return [3, 3];
|
|
144656
144557
|
return [4, import(
|
|
144657
144558
|
/* webpackChunkName: "blueprint-icons-all-paths-loader" */
|
|
144658
|
-
"./allPathsLoader-
|
|
144559
|
+
"./allPathsLoader-BNlRJuEf.js"
|
|
144659
144560
|
)];
|
|
144660
144561
|
case 2:
|
|
144661
144562
|
return [2, _b2.sent().allPathsLoader];
|
|
144662
144563
|
case 3:
|
|
144663
144564
|
return [4, import(
|
|
144664
144565
|
/* webpackChunkName: "blueprint-icons-split-paths-by-size-loader" */
|
|
144665
|
-
"./splitPathsBySizeLoader-
|
|
144566
|
+
"./splitPathsBySizeLoader-BEDIEt1Q.js"
|
|
144666
144567
|
)];
|
|
144667
144568
|
case 4:
|
|
144668
144569
|
return [2, _b2.sent().splitPathsBySizeLoader];
|
|
@@ -196938,4 +196839,4 @@ export {
|
|
|
196938
196839
|
copyToClipboard as y,
|
|
196939
196840
|
navigateTo as z
|
|
196940
196841
|
};
|
|
196941
|
-
//# sourceMappingURL=index
|
|
196842
|
+
//# sourceMappingURL=index--WgLdVs1.js.map
|