@blocklet/pages-kit-block-studio 0.4.90 → 0.4.92

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.
@@ -1,3 +1,4 @@
1
+ import { z } from 'zod';
1
2
  import { LLMConfigProperty } from './zod-utils';
2
3
  export declare function generateWrapperCode({ project, state, version }: any): Promise<{
3
4
  fileName: string;
@@ -26,4 +27,15 @@ export declare function generatePageDataTypesWithZod(state: any): string;
26
27
  * 与现有generatePropertiesTypes函数保持相同签名
27
28
  */
28
29
  export declare function generatePropertiesTypesWithZod(properties: Record<string, any>): string;
30
+ /**
31
+ * 将 Zod schema 序列化为 JSON 描述结构
32
+ */
33
+ export declare function serializeZodSchema(schema: z.ZodTypeAny): any;
34
+ /**
35
+ * 生成特定页面所有 section 数据的 Zod 类型定义
36
+ * @param state 应用状态
37
+ * @param pageId 目标页面ID
38
+ * @returns 包含所有 section 数据类型的 Zod schema 的序列化描述
39
+ */
40
+ export declare function generatePageSectionsDataZod(state: any, pageId: string): any;
29
41
  export default generateWrapperCode;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blocklet/pages-kit-block-studio",
3
- "version": "0.4.90",
3
+ "version": "0.4.92",
4
4
  "description": "Pages Kit block studio for blocklet(s)",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -47,6 +47,10 @@
47
47
  "./frontend": {
48
48
  "import": "./lib/esm/plugins/_theme.js",
49
49
  "require": "./lib/cjs/plugins/_theme.js"
50
+ },
51
+ "./zod-utils": {
52
+ "import": "./lib/esm/utils/zod-utils.js",
53
+ "require": "./lib/cjs/utils/zod-utils.js"
50
54
  }
51
55
  },
52
56
  "typesVersions": {
@@ -84,6 +88,10 @@
84
88
  "frontend": [
85
89
  "./lib/types/plugins/_theme.d.ts",
86
90
  "./lib/types/plugins/_theme.d.ts"
91
+ ],
92
+ "zod-utils": [
93
+ "./lib/types/utils/zod-utils.d.ts",
94
+ "./lib/types/utils/zod-utils.d.ts"
87
95
  ]
88
96
  }
89
97
  },
@@ -132,7 +140,7 @@
132
140
  "zod": "^3.24.2",
133
141
  "zod-to-json-schema": "^3.24.4",
134
142
  "zod-to-ts": "^1.2.0",
135
- "@blocklet/pages-kit": "0.4.90"
143
+ "@blocklet/pages-kit": "0.4.92"
136
144
  },
137
145
  "devDependencies": {
138
146
  "@rollup/plugin-typescript": "^11.1.6",
@@ -157,7 +165,7 @@
157
165
  "zod": "^3.24.2",
158
166
  "zod-to-json-schema": "^3.24.4",
159
167
  "zod-to-ts": "^1.2.0",
160
- "@blocklet/pages-kit": "0.4.90"
168
+ "@blocklet/pages-kit": "0.4.92"
161
169
  },
162
170
  "scripts": {
163
171
  "lint": "eslint src --ext .mjs,.js,.jsx,.ts,.tsx",