@webstudio-is/sdk 0.194.0 → 0.196.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/package.json +4 -6
- package/lib/types/jsx.d.ts +0 -151
- package/lib/types/jsx.test.d.ts +0 -1
- package/lib/types/testing.d.ts +0 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webstudio-is/sdk",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.196.0",
|
|
4
4
|
"description": "Webstudio project data schema",
|
|
5
5
|
"author": "Webstudio <github@webstudio.is>",
|
|
6
6
|
"homepage": "https://webstudio.is",
|
|
@@ -21,9 +21,6 @@
|
|
|
21
21
|
"webstudio": "./src/__generated__/normalize.css.ts",
|
|
22
22
|
"types": "./lib/types/__generated__/normalize.css.d.ts",
|
|
23
23
|
"import": "./lib/__generated__/normalize.css.js"
|
|
24
|
-
},
|
|
25
|
-
"./testing": {
|
|
26
|
-
"webstudio": "./src/testing.ts"
|
|
27
24
|
}
|
|
28
25
|
},
|
|
29
26
|
"files": [
|
|
@@ -37,13 +34,14 @@
|
|
|
37
34
|
"reserved-identifiers": "^1.0.0",
|
|
38
35
|
"type-fest": "^4.28.0",
|
|
39
36
|
"zod": "^3.22.4",
|
|
40
|
-
"@webstudio-is/css-engine": "0.
|
|
41
|
-
"@webstudio-is/fonts": "0.
|
|
37
|
+
"@webstudio-is/css-engine": "0.196.0",
|
|
38
|
+
"@webstudio-is/fonts": "0.196.0"
|
|
42
39
|
},
|
|
43
40
|
"devDependencies": {
|
|
44
41
|
"html-tags": "^4.0.0",
|
|
45
42
|
"strip-indent": "^4.0.0",
|
|
46
43
|
"vitest": "^2.1.8",
|
|
44
|
+
"@webstudio-is/template": "0.196.0",
|
|
47
45
|
"@webstudio-is/css-data": "0.0.0",
|
|
48
46
|
"@webstudio-is/tsconfig": "1.0.7"
|
|
49
47
|
},
|
package/lib/types/jsx.d.ts
DELETED
|
@@ -1,151 +0,0 @@
|
|
|
1
|
-
import type { JSX, ReactNode } from "react";
|
|
2
|
-
export declare class ExpressionValue {
|
|
3
|
-
value: string;
|
|
4
|
-
constructor(expression: string);
|
|
5
|
-
}
|
|
6
|
-
export declare class ParameterValue {
|
|
7
|
-
value: string;
|
|
8
|
-
constructor(dataSourceID: string);
|
|
9
|
-
}
|
|
10
|
-
export declare class ResourceValue {
|
|
11
|
-
value: string;
|
|
12
|
-
constructor(resourceId: string);
|
|
13
|
-
}
|
|
14
|
-
export declare class ActionValue {
|
|
15
|
-
value: {
|
|
16
|
-
type: "execute";
|
|
17
|
-
args: string[];
|
|
18
|
-
code: string;
|
|
19
|
-
};
|
|
20
|
-
constructor(args: string[], code: string);
|
|
21
|
-
}
|
|
22
|
-
export declare class AssetValue {
|
|
23
|
-
value: string;
|
|
24
|
-
constructor(assetId: string);
|
|
25
|
-
}
|
|
26
|
-
export declare class PageValue {
|
|
27
|
-
value: string | {
|
|
28
|
-
pageId: string;
|
|
29
|
-
instanceId: string;
|
|
30
|
-
};
|
|
31
|
-
constructor(pageId: string, instanceId?: string);
|
|
32
|
-
}
|
|
33
|
-
export declare const renderJsx: (root: JSX.Element) => {
|
|
34
|
-
instances: Map<string, {
|
|
35
|
-
type: "instance";
|
|
36
|
-
id: string;
|
|
37
|
-
children: ({
|
|
38
|
-
value: string;
|
|
39
|
-
type: "text";
|
|
40
|
-
placeholder?: boolean | undefined;
|
|
41
|
-
} | {
|
|
42
|
-
value: string;
|
|
43
|
-
type: "id";
|
|
44
|
-
} | {
|
|
45
|
-
value: string;
|
|
46
|
-
type: "expression";
|
|
47
|
-
})[];
|
|
48
|
-
component: string;
|
|
49
|
-
label?: string | undefined;
|
|
50
|
-
}>;
|
|
51
|
-
props: Map<string, {
|
|
52
|
-
value: number;
|
|
53
|
-
type: "number";
|
|
54
|
-
id: string;
|
|
55
|
-
name: string;
|
|
56
|
-
instanceId: string;
|
|
57
|
-
required?: boolean | undefined;
|
|
58
|
-
} | {
|
|
59
|
-
value: string;
|
|
60
|
-
type: "string";
|
|
61
|
-
id: string;
|
|
62
|
-
name: string;
|
|
63
|
-
instanceId: string;
|
|
64
|
-
required?: boolean | undefined;
|
|
65
|
-
} | {
|
|
66
|
-
value: boolean;
|
|
67
|
-
type: "boolean";
|
|
68
|
-
id: string;
|
|
69
|
-
name: string;
|
|
70
|
-
instanceId: string;
|
|
71
|
-
required?: boolean | undefined;
|
|
72
|
-
} | {
|
|
73
|
-
type: "json";
|
|
74
|
-
id: string;
|
|
75
|
-
name: string;
|
|
76
|
-
instanceId: string;
|
|
77
|
-
value?: unknown;
|
|
78
|
-
required?: boolean | undefined;
|
|
79
|
-
} | {
|
|
80
|
-
value: string;
|
|
81
|
-
type: "asset";
|
|
82
|
-
id: string;
|
|
83
|
-
name: string;
|
|
84
|
-
instanceId: string;
|
|
85
|
-
required?: boolean | undefined;
|
|
86
|
-
} | {
|
|
87
|
-
value: (string | {
|
|
88
|
-
instanceId: string;
|
|
89
|
-
pageId: string;
|
|
90
|
-
}) & (string | {
|
|
91
|
-
instanceId: string;
|
|
92
|
-
pageId: string;
|
|
93
|
-
} | undefined);
|
|
94
|
-
type: "page";
|
|
95
|
-
id: string;
|
|
96
|
-
name: string;
|
|
97
|
-
instanceId: string;
|
|
98
|
-
required?: boolean | undefined;
|
|
99
|
-
} | {
|
|
100
|
-
value: string[];
|
|
101
|
-
type: "string[]";
|
|
102
|
-
id: string;
|
|
103
|
-
name: string;
|
|
104
|
-
instanceId: string;
|
|
105
|
-
required?: boolean | undefined;
|
|
106
|
-
} | {
|
|
107
|
-
value: string;
|
|
108
|
-
type: "parameter";
|
|
109
|
-
id: string;
|
|
110
|
-
name: string;
|
|
111
|
-
instanceId: string;
|
|
112
|
-
required?: boolean | undefined;
|
|
113
|
-
} | {
|
|
114
|
-
value: string;
|
|
115
|
-
type: "resource";
|
|
116
|
-
id: string;
|
|
117
|
-
name: string;
|
|
118
|
-
instanceId: string;
|
|
119
|
-
required?: boolean | undefined;
|
|
120
|
-
} | {
|
|
121
|
-
value: string;
|
|
122
|
-
type: "expression";
|
|
123
|
-
id: string;
|
|
124
|
-
name: string;
|
|
125
|
-
instanceId: string;
|
|
126
|
-
required?: boolean | undefined;
|
|
127
|
-
} | {
|
|
128
|
-
value: {
|
|
129
|
-
code: string;
|
|
130
|
-
type: "execute";
|
|
131
|
-
args: string[];
|
|
132
|
-
}[];
|
|
133
|
-
type: "action";
|
|
134
|
-
id: string;
|
|
135
|
-
name: string;
|
|
136
|
-
instanceId: string;
|
|
137
|
-
required?: boolean | undefined;
|
|
138
|
-
}>;
|
|
139
|
-
};
|
|
140
|
-
type ComponentProps = Record<string, unknown> & Record<`${string}:expression`, string> & {
|
|
141
|
-
"ws:id"?: string;
|
|
142
|
-
"ws:label"?: string;
|
|
143
|
-
children?: ReactNode | ExpressionValue;
|
|
144
|
-
};
|
|
145
|
-
type Component = {
|
|
146
|
-
displayName: string;
|
|
147
|
-
} & ((props: ComponentProps) => ReactNode);
|
|
148
|
-
export declare const createProxy: (prefix: string) => Record<string, Component>;
|
|
149
|
-
export declare const $: Record<string, Component>;
|
|
150
|
-
export declare const ws: Record<string, Component>;
|
|
151
|
-
export {};
|
package/lib/types/jsx.test.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
package/lib/types/testing.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./jsx";
|