@next-bricks/visual-builder 1.19.0 → 1.20.1

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/types.json CHANGED
@@ -45,63 +45,6 @@
45
45
  ],
46
46
  "methods": []
47
47
  },
48
- "visual-builder.workbench-sidebar": {
49
- "properties": [
50
- {
51
- "name": "titleLabel",
52
- "annotation": {
53
- "type": "keyword",
54
- "value": "string"
55
- }
56
- }
57
- ],
58
- "events": [],
59
- "methods": []
60
- },
61
- "visual-builder.workbench-action": {
62
- "properties": [
63
- {
64
- "name": "icon",
65
- "annotation": {
66
- "type": "reference",
67
- "typeName": {
68
- "type": "identifier",
69
- "name": "GeneralIconProps"
70
- }
71
- }
72
- },
73
- {
74
- "name": "to",
75
- "annotation": {
76
- "type": "keyword",
77
- "value": "string"
78
- }
79
- },
80
- {
81
- "name": "active",
82
- "annotation": {
83
- "type": "keyword",
84
- "value": "boolean"
85
- }
86
- },
87
- {
88
- "name": "href",
89
- "annotation": {
90
- "type": "keyword",
91
- "value": "string"
92
- }
93
- },
94
- {
95
- "name": "target",
96
- "annotation": {
97
- "type": "keyword",
98
- "value": "string"
99
- }
100
- }
101
- ],
102
- "events": [],
103
- "methods": []
104
- },
105
48
  "visual-builder.check-editor-by-name": {
106
49
  "type": "provider",
107
50
  "params": [
@@ -132,6 +75,19 @@
132
75
  }
133
76
  }
134
77
  },
78
+ "visual-builder.workbench-sidebar": {
79
+ "properties": [
80
+ {
81
+ "name": "titleLabel",
82
+ "annotation": {
83
+ "type": "keyword",
84
+ "value": "string"
85
+ }
86
+ }
87
+ ],
88
+ "events": [],
89
+ "methods": []
90
+ },
135
91
  "visual-builder.page-arch-node": {
136
92
  "properties": [
137
93
  {
@@ -409,6 +365,50 @@
409
365
  }
410
366
  ]
411
367
  },
368
+ "visual-builder.workbench-action": {
369
+ "properties": [
370
+ {
371
+ "name": "icon",
372
+ "annotation": {
373
+ "type": "reference",
374
+ "typeName": {
375
+ "type": "identifier",
376
+ "name": "GeneralIconProps"
377
+ }
378
+ }
379
+ },
380
+ {
381
+ "name": "to",
382
+ "annotation": {
383
+ "type": "keyword",
384
+ "value": "string"
385
+ }
386
+ },
387
+ {
388
+ "name": "active",
389
+ "annotation": {
390
+ "type": "keyword",
391
+ "value": "boolean"
392
+ }
393
+ },
394
+ {
395
+ "name": "href",
396
+ "annotation": {
397
+ "type": "keyword",
398
+ "value": "string"
399
+ }
400
+ },
401
+ {
402
+ "name": "target",
403
+ "annotation": {
404
+ "type": "keyword",
405
+ "value": "string"
406
+ }
407
+ }
408
+ ],
409
+ "events": [],
410
+ "methods": []
411
+ },
412
412
  "visual-builder.pre-generated-preview": {
413
413
  "properties": [
414
414
  {
@@ -1244,6 +1244,15 @@
1244
1244
  }
1245
1245
  }
1246
1246
  }
1247
+ },
1248
+ {
1249
+ "name": "values.change",
1250
+ "detail": {
1251
+ "annotation": {
1252
+ "type": "keyword",
1253
+ "value": "any"
1254
+ }
1255
+ }
1247
1256
  }
1248
1257
  ],
1249
1258
  "methods": [
@@ -2605,6 +2614,22 @@
2605
2614
  "optional": true,
2606
2615
  "computed": false
2607
2616
  },
2617
+ {
2618
+ "type": "propertySignature",
2619
+ "key": {
2620
+ "type": "identifier",
2621
+ "name": "formData"
2622
+ },
2623
+ "annotation": {
2624
+ "type": "reference",
2625
+ "typeName": {
2626
+ "type": "identifier",
2627
+ "name": "FormData"
2628
+ }
2629
+ },
2630
+ "optional": true,
2631
+ "computed": false
2632
+ },
2608
2633
  {
2609
2634
  "type": "propertySignature",
2610
2635
  "key": {
@@ -2730,6 +2755,10 @@
2730
2755
  {
2731
2756
  "type": "jsLiteral",
2732
2757
  "value": "snippet"
2758
+ },
2759
+ {
2760
+ "type": "jsLiteral",
2761
+ "value": "form"
2733
2762
  }
2734
2763
  ]
2735
2764
  }
@@ -294,12 +294,13 @@ export interface BrickOutline {
294
294
  alias?: string;
295
295
  hasContentScroll?: boolean;
296
296
  }
297
- export type UpdateStoryboardType = "route" | "template" | "snippet";
297
+ export type UpdateStoryboardType = "route" | "template" | "snippet" | "form";
298
298
  export interface PreviewStartOptions {
299
299
  appId: string;
300
300
  routeId?: string;
301
301
  templateId?: string;
302
302
  formId?: string;
303
+ formData?: FormData;
303
304
  snippetData?: any;
304
305
  routePath?: string;
305
306
  routeExact?: boolean;
@@ -17,7 +17,7 @@ declare const SchemaField: {
17
17
  FormLayout: React.FC<React.PropsWithChildren<import("@formily/antd-v5").IFormLayoutProps>> & {
18
18
  useFormLayout: () => import("@formily/antd-v5").IFormLayoutContext;
19
19
  useFormDeepLayout: () => import("@formily/antd-v5").IFormLayoutContext;
20
- useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext; /** 构件名称 */
20
+ useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext;
21
21
  };
22
22
  Input: import("@formily/react").ReactFC<import("antd").InputProps> & {
23
23
  TextArea: React.ForwardRefExoticComponent<Pick<Partial<import("antd/es/input").TextAreaProps & React.RefAttributes<import("antd/es/input/TextArea").TextAreaRef>>, "key" | keyof import("antd/es/input").TextAreaProps> & React.RefAttributes<unknown>>;
@@ -57,7 +57,7 @@ declare const SchemaField: {
57
57
  FormLayout: React.FC<React.PropsWithChildren<import("@formily/antd-v5").IFormLayoutProps>> & {
58
58
  useFormLayout: () => import("@formily/antd-v5").IFormLayoutContext;
59
59
  useFormDeepLayout: () => import("@formily/antd-v5").IFormLayoutContext;
60
- useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext; /** 构件名称 */
60
+ useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext;
61
61
  };
62
62
  Input: import("@formily/react").ReactFC<import("antd").InputProps> & {
63
63
  TextArea: React.ForwardRefExoticComponent<Pick<Partial<import("antd/es/input").TextAreaProps & React.RefAttributes<import("antd/es/input/TextArea").TextAreaRef>>, "key" | keyof import("antd/es/input").TextAreaProps> & React.RefAttributes<unknown>>;
@@ -97,7 +97,7 @@ declare const SchemaField: {
97
97
  FormLayout: React.FC<React.PropsWithChildren<import("@formily/antd-v5").IFormLayoutProps>> & {
98
98
  useFormLayout: () => import("@formily/antd-v5").IFormLayoutContext;
99
99
  useFormDeepLayout: () => import("@formily/antd-v5").IFormLayoutContext;
100
- useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext; /** 构件名称 */
100
+ useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext;
101
101
  };
102
102
  Input: import("@formily/react").ReactFC<import("antd").InputProps> & {
103
103
  TextArea: React.ForwardRefExoticComponent<Pick<Partial<import("antd/es/input").TextAreaProps & React.RefAttributes<import("antd/es/input/TextArea").TextAreaRef>>, "key" | keyof import("antd/es/input").TextAreaProps> & React.RefAttributes<unknown>>;
@@ -137,7 +137,7 @@ declare const SchemaField: {
137
137
  FormLayout: React.FC<React.PropsWithChildren<import("@formily/antd-v5").IFormLayoutProps>> & {
138
138
  useFormLayout: () => import("@formily/antd-v5").IFormLayoutContext;
139
139
  useFormDeepLayout: () => import("@formily/antd-v5").IFormLayoutContext;
140
- useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext; /** 构件名称 */
140
+ useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext;
141
141
  };
142
142
  Input: import("@formily/react").ReactFC<import("antd").InputProps> & {
143
143
  TextArea: React.ForwardRefExoticComponent<Pick<Partial<import("antd/es/input").TextAreaProps & React.RefAttributes<import("antd/es/input/TextArea").TextAreaRef>>, "key" | keyof import("antd/es/input").TextAreaProps> & React.RefAttributes<unknown>>;
@@ -177,7 +177,7 @@ declare const SchemaField: {
177
177
  FormLayout: React.FC<React.PropsWithChildren<import("@formily/antd-v5").IFormLayoutProps>> & {
178
178
  useFormLayout: () => import("@formily/antd-v5").IFormLayoutContext;
179
179
  useFormDeepLayout: () => import("@formily/antd-v5").IFormLayoutContext;
180
- useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext; /** 构件名称 */
180
+ useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext;
181
181
  };
182
182
  Input: import("@formily/react").ReactFC<import("antd").InputProps> & {
183
183
  TextArea: React.ForwardRefExoticComponent<Pick<Partial<import("antd/es/input").TextAreaProps & React.RefAttributes<import("antd/es/input/TextArea").TextAreaRef>>, "key" | keyof import("antd/es/input").TextAreaProps> & React.RefAttributes<unknown>>;
@@ -217,7 +217,7 @@ declare const SchemaField: {
217
217
  FormLayout: React.FC<React.PropsWithChildren<import("@formily/antd-v5").IFormLayoutProps>> & {
218
218
  useFormLayout: () => import("@formily/antd-v5").IFormLayoutContext;
219
219
  useFormDeepLayout: () => import("@formily/antd-v5").IFormLayoutContext;
220
- useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext; /** 构件名称 */
220
+ useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext;
221
221
  };
222
222
  Input: import("@formily/react").ReactFC<import("antd").InputProps> & {
223
223
  TextArea: React.ForwardRefExoticComponent<Pick<Partial<import("antd/es/input").TextAreaProps & React.RefAttributes<import("antd/es/input/TextArea").TextAreaRef>>, "key" | keyof import("antd/es/input").TextAreaProps> & React.RefAttributes<unknown>>;
@@ -257,7 +257,7 @@ declare const SchemaField: {
257
257
  FormLayout: React.FC<React.PropsWithChildren<import("@formily/antd-v5").IFormLayoutProps>> & {
258
258
  useFormLayout: () => import("@formily/antd-v5").IFormLayoutContext;
259
259
  useFormDeepLayout: () => import("@formily/antd-v5").IFormLayoutContext;
260
- useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext; /** 构件名称 */
260
+ useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext;
261
261
  };
262
262
  Input: import("@formily/react").ReactFC<import("antd").InputProps> & {
263
263
  TextArea: React.ForwardRefExoticComponent<Pick<Partial<import("antd/es/input").TextAreaProps & React.RefAttributes<import("antd/es/input/TextArea").TextAreaRef>>, "key" | keyof import("antd/es/input").TextAreaProps> & React.RefAttributes<unknown>>;
@@ -297,7 +297,7 @@ declare const SchemaField: {
297
297
  FormLayout: React.FC<React.PropsWithChildren<import("@formily/antd-v5").IFormLayoutProps>> & {
298
298
  useFormLayout: () => import("@formily/antd-v5").IFormLayoutContext;
299
299
  useFormDeepLayout: () => import("@formily/antd-v5").IFormLayoutContext;
300
- useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext; /** 构件名称 */
300
+ useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext;
301
301
  };
302
302
  Input: import("@formily/react").ReactFC<import("antd").InputProps> & {
303
303
  TextArea: React.ForwardRefExoticComponent<Pick<Partial<import("antd/es/input").TextAreaProps & React.RefAttributes<import("antd/es/input/TextArea").TextAreaRef>>, "key" | keyof import("antd/es/input").TextAreaProps> & React.RefAttributes<unknown>>;
@@ -337,7 +337,7 @@ declare const SchemaField: {
337
337
  FormLayout: React.FC<React.PropsWithChildren<import("@formily/antd-v5").IFormLayoutProps>> & {
338
338
  useFormLayout: () => import("@formily/antd-v5").IFormLayoutContext;
339
339
  useFormDeepLayout: () => import("@formily/antd-v5").IFormLayoutContext;
340
- useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext; /** 构件名称 */
340
+ useFormShallowLayout: () => import("@formily/antd-v5").IFormLayoutContext;
341
341
  };
342
342
  Input: import("@formily/react").ReactFC<import("antd").InputProps> & {
343
343
  TextArea: React.ForwardRefExoticComponent<Pick<Partial<import("antd/es/input").TextAreaProps & React.RefAttributes<import("antd/es/input/TextArea").TextAreaRef>>, "key" | keyof import("antd/es/input").TextAreaProps> & React.RefAttributes<unknown>>;
@@ -385,6 +385,7 @@ export interface EditorComponentProps {
385
385
  onFormValidateSuccess: typeof onFormValidateSuccess;
386
386
  };
387
387
  scope: {
388
+ advancedMode: boolean;
388
389
  dataList: DataItem[];
389
390
  };
390
391
  }
@@ -421,5 +422,6 @@ export interface PropertyEditorProps {
421
422
  editorName: string;
422
423
  advancedMode?: boolean;
423
424
  dataList: DataItem[];
425
+ handleValuesChange: (value: any) => void;
424
426
  }
425
- export declare function LegacyPropertyEditor({ advancedMode, values, editorName, dataList }: PropertyEditorProps, ref: any): React.JSX.Element;
427
+ export declare function LegacyPropertyEditor({ advancedMode, values, editorName, dataList, handleValuesChange, }: PropertyEditorProps, ref: any): React.JSX.Element;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@next-bricks/visual-builder",
3
- "version": "1.19.0",
3
+ "version": "1.20.1",
4
4
  "homepage": "https://github.com/easyops-cn/next-bricks/tree/master/bricks/visual-builder",
5
5
  "repository": {
6
6
  "type": "git",
@@ -44,5 +44,5 @@
44
44
  "@next-bricks/icons": "*",
45
45
  "@next-bricks/vs": "*"
46
46
  },
47
- "gitHead": "2c6d26349bab4e968689435fc387174e5db6fad8"
47
+ "gitHead": "cb9295ae1aa0f2973e49623abbdd49899fcf7b54"
48
48
  }