@superblocksteam/library 2.0.3-next.161 → 2.0.3-next.162
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-BApLf4rp.js → allPaths-DM9vqwnS.js} +2 -2
- package/dist/{allPaths-BApLf4rp.js.map → allPaths-DM9vqwnS.js.map} +1 -1
- package/dist/{allPaths-BiuxA7ic.js → allPaths-DxkvppLV.js} +2 -2
- package/dist/{allPaths-BiuxA7ic.js.map → allPaths-DxkvppLV.js.map} +1 -1
- package/dist/{allPathsLoader-DAmfuudp.js → allPathsLoader-CA2g8N1n.js} +3 -3
- package/dist/{allPathsLoader-DgVs_Ja6.js.map → allPathsLoader-CA2g8N1n.js.map} +1 -1
- package/dist/{allPathsLoader-DgVs_Ja6.js → allPathsLoader-CWPx59Ux.js} +3 -3
- package/dist/{allPathsLoader-DAmfuudp.js.map → allPathsLoader-CWPx59Ux.js.map} +1 -1
- package/dist/{index-CNYSm9og.js → index-DSm4sAXe.js} +150 -50
- package/dist/{index-CNYSm9og.js.map → index-DSm4sAXe.js.map} +1 -1
- package/dist/index.js +2 -2
- package/dist/{splitPathsBySizeLoader-lGtuqt6v.js → splitPathsBySizeLoader-CePLwOUn.js} +2 -2
- package/dist/{splitPathsBySizeLoader-lGtuqt6v.js.map → splitPathsBySizeLoader-CePLwOUn.js.map} +1 -1
- package/dist/{splitPathsBySizeLoader-CYAbP99t.js → splitPathsBySizeLoader-DSNr6R-_.js} +2 -2
- package/dist/{splitPathsBySizeLoader-CYAbP99t.js.map → splitPathsBySizeLoader-DSNr6R-_.js.map} +1 -1
- package/dist-types/edit-mode/features/operation-store.d.ts +4 -3
- package/dist-types/edit-mode/source-update-api.d.ts +2 -1
- package/dist-types/edit-mode/superblocks-editor-bridge.d.ts +2 -3
- package/dist-types/lib/internal-details/lib/types.d.ts +3 -13
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { W as clientExports } from "./index-
|
|
2
|
-
import { X, Y, R, L, M, Z, K, $, a0, a1, a2, a3, a4, x, a5, a6, a7, a8, a9, V, aa, P, ab, ac, ad, ae, U, w, S, n, d, e, l, o, k, N, y, s, t, f, m, i, g, x as x2, c, q, j, h, v, u, A, af, ag, ah, ai, aj, T, ak, al, am, an, ao, ap, aq, ar, as, at, au, av, aw, ax, ay, az, aA, aB, aC, aD, aE, aF, aG, aH, aI, z, aJ, aK, aL, aM, aN, aO, aP, aQ, aR, aS, aT, J, aU, aV, aW, aX, aY, aZ, D, a_, a$, b0, b1, b2, F, b3, b4, B, b5, b6, b7, r, H, G, b8, b9, ba, Q, C, E, bb, bc, bd, be, bf, bg, bh, bi, bj, bk, bl, bm, bn, bo, bp, bq, br, bs, bt, bu, bv, bw, bx, by, bz, bA, bB, bC, bD, bE, bF, bG, bH, O, bI } from "./index-
|
|
1
|
+
import { W as clientExports } from "./index-DSm4sAXe.js";
|
|
2
|
+
import { X, Y, R, L, M, Z, K, $, a0, a1, a2, a3, a4, x, a5, a6, a7, a8, a9, V, aa, P, ab, ac, ad, ae, U, w, S, n, d, e, l, o, k, N, y, s, t, f, m, i, g, x as x2, c, q, j, h, v, u, A, af, ag, ah, ai, aj, T, ak, al, am, an, ao, ap, aq, ar, as, at, au, av, aw, ax, ay, az, aA, aB, aC, aD, aE, aF, aG, aH, aI, z, aJ, aK, aL, aM, aN, aO, aP, aQ, aR, aS, aT, J, aU, aV, aW, aX, aY, aZ, D, a_, a$, b0, b1, b2, F, b3, b4, B, b5, b6, b7, r, H, G, b8, b9, ba, Q, C, E, bb, bc, bd, be, bf, bg, bh, bi, bj, bk, bl, bm, bn, bo, bp, bq, br, bs, bt, bu, bv, bw, bx, by, bz, bA, bB, bC, bD, bE, bF, bG, bH, O, bI } from "./index-DSm4sAXe.js";
|
|
3
3
|
const createRoot = clientExports.createRoot;
|
|
4
4
|
export {
|
|
5
5
|
X as Await,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as __awaiter, a as __generator, p as pascalCase, I as IconSize } from "./index-
|
|
1
|
+
import { _ as __awaiter, a as __generator, p as pascalCase, I as IconSize } from "./index-DSm4sAXe.js";
|
|
2
2
|
var splitPathsBySizeLoader = function(name, size) {
|
|
3
3
|
return __awaiter(void 0, void 0, void 0, function() {
|
|
4
4
|
var key, pathsRecord;
|
|
@@ -31,4 +31,4 @@ var splitPathsBySizeLoader = function(name, size) {
|
|
|
31
31
|
export {
|
|
32
32
|
splitPathsBySizeLoader
|
|
33
33
|
};
|
|
34
|
-
//# sourceMappingURL=splitPathsBySizeLoader-
|
|
34
|
+
//# sourceMappingURL=splitPathsBySizeLoader-CePLwOUn.js.map
|
package/dist/{splitPathsBySizeLoader-lGtuqt6v.js.map → splitPathsBySizeLoader-CePLwOUn.js.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"splitPathsBySizeLoader-
|
|
1
|
+
{"version":3,"file":"splitPathsBySizeLoader-CePLwOUn.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/splitPathsBySizeLoader.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\";\nimport { pascalCase } from \"change-case\";\nimport { IconSize } from \"../iconTypes\";\n/**\n * A dynamic loader for icon paths that generates separate chunks for the two size variants.\n */\nexport var splitPathsBySizeLoader = function (name, size) { return __awaiter(void 0, void 0, void 0, function () {\n var key, pathsRecord;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n key = pascalCase(name);\n if (!(size === IconSize.STANDARD)) return [3 /*break*/, 2];\n return [4 /*yield*/, import(\n /* webpackChunkName: \"blueprint-icons-16px-paths\" */\n \"../generated/16px/paths\")];\n case 1:\n pathsRecord = _a.sent();\n return [3 /*break*/, 4];\n case 2: return [4 /*yield*/, import(\n /* webpackChunkName: \"blueprint-icons-20px-paths\" */\n \"../generated/20px/paths\")];\n case 3:\n pathsRecord = _a.sent();\n _a.label = 4;\n case 4: return [2 /*return*/, pathsRecord[key]];\n }\n });\n}); };\n//# sourceMappingURL=splitPathsBySizeLoader.js.map"],"names":[],"mappings":";AAqBU,IAAC,yBAAyB,SAAU,MAAM,MAAM;AAAE,SAAO,UAAU,QAAQ,QAAQ,QAAQ,WAAY;AAC7G,QAAI,KAAK;AACT,WAAO,YAAY,MAAM,SAAU,IAAI;AACnC,cAAQ,GAAG,OAAK;AAAA,QACZ,KAAK;AACD,gBAAM,WAAW,IAAI;AACrB,cAAI,EAAE,SAAS,SAAS,UAAW,QAAO,CAAC,GAAa,CAAC;AACzD,iBAAO,CAAC,GAAa;AAAA;AAAA,YAEjB;AAAA,UAAyB,kBAAC;AAAA,QAClC,KAAK;AACD,wBAAc,GAAG,KAAM;AACvB,iBAAO,CAAC,GAAa,CAAC;AAAA,QAC1B,KAAK;AAAG,iBAAO,CAAC,GAAa;AAAA;AAAA,YAEzB;AAAA,UAAyB,kBAAC;AAAA,QAC9B,KAAK;AACD,wBAAc,GAAG,KAAM;AACvB,aAAG,QAAQ;AAAA,QACf,KAAK;AAAG,iBAAO,CAAC,GAAc,YAAY,GAAG,CAAC;AAAA,MAC1D;AAAA,IACA,CAAK;AAAA,EACL,CAAC;AAAE;","x_google_ignoreList":[0]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as __awaiter, a as __generator, p as pascalCase, b as IconSize } from "./index-
|
|
1
|
+
import { _ as __awaiter, a as __generator, p as pascalCase, b as IconSize } from "./index-DSm4sAXe.js";
|
|
2
2
|
var splitPathsBySizeLoader = function(name, size) {
|
|
3
3
|
return __awaiter(void 0, void 0, void 0, function() {
|
|
4
4
|
var key, pathsRecord;
|
|
@@ -31,4 +31,4 @@ var splitPathsBySizeLoader = function(name, size) {
|
|
|
31
31
|
export {
|
|
32
32
|
splitPathsBySizeLoader
|
|
33
33
|
};
|
|
34
|
-
//# sourceMappingURL=splitPathsBySizeLoader-
|
|
34
|
+
//# sourceMappingURL=splitPathsBySizeLoader-DSNr6R-_.js.map
|
package/dist/{splitPathsBySizeLoader-CYAbP99t.js.map → splitPathsBySizeLoader-DSNr6R-_.js.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"splitPathsBySizeLoader-
|
|
1
|
+
{"version":3,"file":"splitPathsBySizeLoader-DSNr6R-_.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/splitPathsBySizeLoader.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\";\nimport { pascalCase } from \"change-case\";\nimport { IconSize } from \"../iconTypes\";\n/**\n * A dynamic loader for icon paths that generates separate chunks for the two size variants.\n */\nexport var splitPathsBySizeLoader = function (name, size) { return __awaiter(void 0, void 0, void 0, function () {\n var key, pathsRecord;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n key = pascalCase(name);\n if (!(size === IconSize.STANDARD)) return [3 /*break*/, 2];\n return [4 /*yield*/, import(\n /* webpackChunkName: \"blueprint-icons-16px-paths\" */\n \"../generated/16px/paths\")];\n case 1:\n pathsRecord = _a.sent();\n return [3 /*break*/, 4];\n case 2: return [4 /*yield*/, import(\n /* webpackChunkName: \"blueprint-icons-20px-paths\" */\n \"../generated/20px/paths\")];\n case 3:\n pathsRecord = _a.sent();\n _a.label = 4;\n case 4: return [2 /*return*/, pathsRecord[key]];\n }\n });\n}); };\n//# sourceMappingURL=splitPathsBySizeLoader.js.map"],"names":[],"mappings":";AAqBU,IAAC,yBAAyB,SAAU,MAAM,MAAM;AAAE,SAAO,UAAU,QAAQ,QAAQ,QAAQ,WAAY;AAC7G,QAAI,KAAK;AACT,WAAO,YAAY,MAAM,SAAU,IAAI;AACnC,cAAQ,GAAG,OAAK;AAAA,QACZ,KAAK;AACD,gBAAM,WAAW,IAAI;AACrB,cAAI,EAAE,SAAS,SAAS,UAAW,QAAO,CAAC,GAAa,CAAC;AACzD,iBAAO,CAAC,GAAa;AAAA;AAAA,YAEjB;AAAA,UAAyB,kBAAC;AAAA,QAClC,KAAK;AACD,wBAAc,GAAG,KAAM;AACvB,iBAAO,CAAC,GAAa,CAAC;AAAA,QAC1B,KAAK;AAAG,iBAAO,CAAC,GAAa;AAAA;AAAA,YAEzB;AAAA,UAAyB,kBAAC;AAAA,QAC9B,KAAK;AACD,wBAAc,GAAG,KAAM;AACvB,aAAG,QAAQ;AAAA,QACf,KAAK;AAAG,iBAAO,CAAC,GAAc,YAAY,GAAG,CAAC;AAAA,MAC1D;AAAA,IACA,CAAK;AAAA,EACL,CAAC;AAAE;","x_google_ignoreList":[0]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { CreateRequest, DeleteRequest, EditOperations, PropertyInfo, ReparentRequest, SbElement, SetPropertiesRequest, SetPropertyRequest, SourceLocation } from "@superblocksteam/library-shared/types";
|
|
1
|
+
import type { CreateRequest, DeleteRequest, EditOperationPayload, EditOperations, EditOperationType, PropertyInfo, ReparentRequest, SbElement, SetPropertiesRequest, SetPropertyRequest, SourceLocation } from "@superblocksteam/library-shared/types";
|
|
2
2
|
type OptimisticOperation<P> = {
|
|
3
3
|
type: keyof EditOperations;
|
|
4
4
|
payload: P;
|
|
@@ -38,11 +38,12 @@ declare class OperationManager {
|
|
|
38
38
|
};
|
|
39
39
|
propsToChange?: Record<string, PropertyInfo>;
|
|
40
40
|
}): void;
|
|
41
|
-
|
|
41
|
+
deleteComponents(sourceIds: SbElement[]): void;
|
|
42
|
+
acknowledgeEditOperation(operation: EditOperationPayload<EditOperationType>): void;
|
|
42
43
|
writeRuntimeProperties(sourceId: SbElement, transactionId: string, updates: Record<string, PropertyInfo<unknown>>): void;
|
|
43
44
|
setWidgetProperties(sourceId: SbElement, properties: Record<string, PropertyInfo<unknown>>, callback?: () => void): void;
|
|
44
45
|
setWidgetProperty(sourceId: SbElement, property: string, value: PropertyInfo<unknown>, callback?: () => void): void;
|
|
45
46
|
ensureFilesSynced(): Promise<void>;
|
|
46
|
-
generateSourceId():
|
|
47
|
+
generateSourceId(): `SB-${string}`;
|
|
47
48
|
}
|
|
48
49
|
export default OperationManager;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { EditOperationType, EditOperations, ReparentRequest, CreateRequest, SetPropertyRequest, SetPropertiesRequest, BatchUpdateRequest, ApiUpdateRequest, AddEntityRequest, UpdateEntityRequest, UpdateThemeRequest, DeleteEntityRequest, DeleteRequest } from "@superblocksteam/library-shared/types";
|
|
1
|
+
import type { EditOperationType, EditOperations, ReparentRequest, CreateRequest, SetPropertyRequest, SetPropertiesRequest, BatchUpdateRequest, ApiUpdateRequest, AddEntityRequest, UpdateEntityRequest, UpdateThemeRequest, DeleteEntityRequest, DeleteRequest, DeletePropertiesRequest } from "@superblocksteam/library-shared/types";
|
|
2
2
|
type CamelCase<S extends string> = S extends `${infer Head}-${infer Tail}` ? `${Head}${Capitalize<CamelCase<Tail>>}` : S extends `${infer Head}:${infer Tail}` ? `${Head}${Capitalize<CamelCase<Tail>>}` : S;
|
|
3
3
|
type IOperationAPI = {
|
|
4
4
|
[K in EditOperationType as CamelCase<K>]: (payload: Parameters<EditOperations[K]>[0]) => Promise<ReturnType<EditOperations[K]> | undefined>;
|
|
@@ -13,6 +13,7 @@ declare class OperationAPI implements IOperationAPI {
|
|
|
13
13
|
editorDeleteComponents: (payload: DeleteRequest) => Promise<void | undefined>;
|
|
14
14
|
editorSetProperty: (payload: SetPropertyRequest) => Promise<void | undefined>;
|
|
15
15
|
editorSetProperties: (payload: SetPropertiesRequest) => Promise<any>;
|
|
16
|
+
editorDeleteProperties: (payload: DeletePropertiesRequest) => Promise<void | undefined>;
|
|
16
17
|
editorBatchUpdate: (payload: BatchUpdateRequest) => Promise<unknown[] | undefined>;
|
|
17
18
|
apiUpdate: (payload: ApiUpdateRequest) => Promise<import("@superblocksteam/library-shared/types").ApiUpdateResponse | undefined>;
|
|
18
19
|
editorAddEntity: (payload: AddEntityRequest) => Promise<void | undefined>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { FromChildToParentMessageTypesMap } from "../lib/index.js";
|
|
2
2
|
import type { StreamEvent } from "../lib/internal-details/lib/types.js";
|
|
3
3
|
import type { PropertiesPanelDefinition } from "@superblocksteam/library-shared/props";
|
|
4
|
-
import type { GeneratedTheme, SbElement, Theme } from "@superblocksteam/library-shared/types";
|
|
4
|
+
import type { EditOperationPayload, EditOperationType, GeneratedTheme, SbElement, Theme } from "@superblocksteam/library-shared/types";
|
|
5
5
|
export declare class SuperblocksEditorBridge {
|
|
6
6
|
private static instance;
|
|
7
7
|
private messagesToSend;
|
|
@@ -11,8 +11,7 @@ export declare class SuperblocksEditorBridge {
|
|
|
11
11
|
sendReady(): void;
|
|
12
12
|
sendNotification(type: "success" | "error" | "info" | "warning", message: string, description?: string): void;
|
|
13
13
|
selectWidgets(sourceIds: SbElement[], selectingMultiple?: boolean): void;
|
|
14
|
-
|
|
15
|
-
deleteWidgets(sourceIds: SbElement[]): void;
|
|
14
|
+
editOpRequest<T extends EditOperationType>(type: T, payload: EditOperationPayload<T>["payload"]): void;
|
|
16
15
|
undo(): void;
|
|
17
16
|
redo(): void;
|
|
18
17
|
sendStreamedApiEvent(event: StreamEvent, apiName: string): void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { PropertiesPanelDefinition } from "@superblocksteam/library-shared/props";
|
|
2
|
-
import type { AppToEditorMessage, DeleteMeLibraryApi,
|
|
2
|
+
import type { AppToEditorMessage, DeleteMeLibraryApi, EditOperationPayload, EditOperationType, PayloadAction, PropertyInfo, SbElement, SourceLocation, TransactionInfo } from "@superblocksteam/library-shared/types";
|
|
3
3
|
import type { OrchestratorViewMode, PlaceholderInfo } from "@superblocksteam/shared";
|
|
4
4
|
import type { XYCoord } from "react-dnd";
|
|
5
5
|
export type ExecutionError = {
|
|
@@ -104,20 +104,16 @@ export type FromParentToChildMessageTypesMap = {
|
|
|
104
104
|
logContext: Record<string, unknown>;
|
|
105
105
|
};
|
|
106
106
|
"sb-editor-request-bootstrap": void;
|
|
107
|
-
"sb-update-property": {
|
|
108
|
-
sourceId: string;
|
|
109
|
-
updates: Record<string, PropertyInfo<unknown>>;
|
|
110
|
-
};
|
|
111
107
|
"sb-update-property-with-effects": {
|
|
112
108
|
sourceId: string;
|
|
113
109
|
callbackId: string;
|
|
114
110
|
updates: Record<string, PropertyInfo<unknown>>;
|
|
115
111
|
transaction: TransactionInfo;
|
|
116
112
|
};
|
|
113
|
+
"sb-edit-operation-acknowledge": EditOperationPayload<EditOperationType>;
|
|
117
114
|
"sb-retrieve-property-panel-props": {
|
|
118
115
|
sourceId: string;
|
|
119
116
|
};
|
|
120
|
-
"sb-delete-components": DeleteRequest;
|
|
121
117
|
"parent-action-batch": PayloadAction<unknown>[];
|
|
122
118
|
click: void;
|
|
123
119
|
"register-keypress": {
|
|
@@ -173,10 +169,7 @@ export type FromChildToParentMessageTypesMap = {
|
|
|
173
169
|
"reject-promise": unknown;
|
|
174
170
|
"sb-editor-request-bootstrap": void;
|
|
175
171
|
"reload-configs": void;
|
|
176
|
-
"sb-
|
|
177
|
-
sourceId: string;
|
|
178
|
-
updates: Record<string, unknown>;
|
|
179
|
-
};
|
|
172
|
+
"sb-edit-operation-request": EditOperationPayload<EditOperationType>;
|
|
180
173
|
"client:selectWidgets": {
|
|
181
174
|
sourceIds: SbElement[];
|
|
182
175
|
selectingMultiple: boolean;
|
|
@@ -228,9 +221,6 @@ export type FromChildToParentMessageTypesMap = {
|
|
|
228
221
|
};
|
|
229
222
|
undo: void;
|
|
230
223
|
redo: void;
|
|
231
|
-
deleteWidgets: {
|
|
232
|
-
sourceIds: string[];
|
|
233
|
-
};
|
|
234
224
|
} & AppToEditorMessage<PropertiesPanelDefinition>;
|
|
235
225
|
export type FromChildToParentMessageTypes = keyof FromChildToParentMessageTypesMap;
|
|
236
226
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@superblocksteam/library",
|
|
3
|
-
"version": "2.0.3-next.
|
|
3
|
+
"version": "2.0.3-next.162",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"exports": {
|
|
6
6
|
".": {
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"@react-hook/resize-observer": "1.2.6",
|
|
33
33
|
"@superblocksteam/fast-deep-equal": "3.1.4",
|
|
34
34
|
"@superblocksteam/iso-currency": "2.0.0",
|
|
35
|
-
"@superblocksteam/library-shared": "2.0.3-next.
|
|
35
|
+
"@superblocksteam/library-shared": "2.0.3-next.162",
|
|
36
36
|
"@superblocksteam/shared": "0.9120.0",
|
|
37
37
|
"antd": "4.24.15",
|
|
38
38
|
"apca-w3": "^0.1.9",
|