File tree Expand file tree Collapse file tree
packages/pluggable-widgets-tools/src/typings-generator Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -16,6 +16,10 @@ export const fileInput = `<?xml version="1.0" encoding="utf-8"?>
1616 <caption>File 3</caption>
1717 <description />
1818 </property>
19+ <property key="file4" type="file" allowUpload="true" required="false">
20+ <caption>File 4</caption>
21+ <description />
22+ </property>
1923 </propertyGroup>
2024 <propertyGroup caption="Actions">
2125 <property key="description" type="attribute">
@@ -57,6 +61,10 @@ export const fileInputNative = `<?xml version="1.0" encoding="utf-8"?>
5761 <caption>File 3</caption>
5862 <description />
5963 </property>
64+ <property key="file4" type="file" allowUpload="true" required="false">
65+ <caption>File 4</caption>
66+ <description />
67+ </property>
6068 </propertyGroup>
6169 <propertyGroup caption="Actions">
6270 <property key="description" type="attribute">
Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ export interface MyWidgetContainerProps {
1212 file: DynamicValue<FileValue>;
1313 file2?: DynamicValue<FileValue>;
1414 file3: EditableFileValue;
15+ file4?: EditableFileValue;
1516 description: EditableValue<string>;
1617 action?: ActionValue;
1718}
@@ -23,6 +24,7 @@ export interface MyWidgetPreviewProps {
2324 file: string;
2425 file2: string;
2526 file3: string;
27+ file4: string;
2628 description: string;
2729 action: {} | null;
2830}
@@ -33,6 +35,7 @@ export const fileNativeOutput = `export interface MyWidgetProps<Style> {
3335 file: DynamicValue<FileValue>;
3436 file2?: DynamicValue<FileValue>;
3537 file3: EditableFileValue;
38+ file4?: EditableFileValue;
3639 description: EditableValue<string>;
3740 action?: ActionValue;
3841}` ;
Original file line number Diff line number Diff line change @@ -128,9 +128,9 @@ function toClientPropType(
128128 return "number" ;
129129 case "decimal" :
130130 return "Big" ;
131- case "icon" :
131+ case "icon" :
132132 return isNative ? "DynamicValue<NativeIcon>" : "DynamicValue<WebIcon>" ;
133- case "image" :
133+ case "image" :
134134 return isNative ? "DynamicValue<NativeImage>" : prop . $ . allowUpload === "true" ? "EditableImageValue<WebImage>" : "DynamicValue<WebImage>" ;
135135 case "file" :
136136 return prop . $ . allowUpload ? "EditableFileValue" : "DynamicValue<FileValue>" ;
You can’t perform that action at this time.
0 commit comments