@cloudbase/weda-ui 3.20.2 → 3.20.3

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.
Files changed (32) hide show
  1. package/dist/configs/components/form-user-tree-select.js +1 -1
  2. package/dist/configs/components/wd-member.d.ts +2 -0
  3. package/dist/configs/components/wd-member.js +5 -1
  4. package/dist/configs/components/wd-rich-text.d.ts +2 -0
  5. package/dist/configs/components/wd-rich-text.js +1 -0
  6. package/dist/configs/components/wd-upload-file.d.ts +2 -0
  7. package/dist/configs/components/wd-upload-file.js +1 -0
  8. package/dist/configs/components/wd-upload-image.d.ts +18 -11
  9. package/dist/configs/components/wd-upload-image.js +8 -6
  10. package/dist/configs/index.d.ts +28 -14
  11. package/dist/configs/type-utils/type-form.d.ts +2 -0
  12. package/dist/configs/type-utils/type-form.js +23 -0
  13. package/dist/style/weda-ui.min.css +1 -1
  14. package/dist/web/components/form/uploader/upload/index.d.ts +1 -0
  15. package/dist/web/components/form/uploader/upload/index.js +7 -5
  16. package/dist/web/components/form/uploader/uploader.h5.d.ts +1 -0
  17. package/dist/web/components/form/uploader/uploader.pc.js +1 -1
  18. package/dist/web/components/form/uploader/util.d.ts +1 -0
  19. package/dist/web/components/form/uploader/util.js +7 -3
  20. package/dist/web/components/form/uploaderFile/uploadFile.h5.d.ts +2 -1
  21. package/dist/web/components/form/uploaderFile/uploadFile.h5.js +11 -8
  22. package/dist/web/components/form/uploaderFile/uploadFile.pc.d.ts +2 -1
  23. package/dist/web/components/form/uploaderFile/uploadFile.pc.js +11 -8
  24. package/dist/web/components/form-user-tree-select/index.js +4 -2
  25. package/dist/web/components/richText/index.d.ts +4 -1
  26. package/dist/web/components/richText/index.js +16 -14
  27. package/dist/web/components/uploaderFileView/index.js +3 -3
  28. package/dist/web/components/wd-member/wd-member.js +4 -2
  29. package/dist/web/components/wd-rich-text/wd-rich-text.js +2 -2
  30. package/dist/web/components/wd-upload-file/wd-upload-file.js +2 -2
  31. package/dist/web/components/wd-upload-image/wd-upload-image.js +2 -2
  32. package/package.json +2 -2
@@ -266,7 +266,7 @@ const data = Type.Object({
266
266
  default: false,
267
267
  'x-index': 120,
268
268
  'x-category': '高级属性',
269
- description: 'beta属性:开启后,可获取成员多选数据,但是暂不支持将多选数据进行提交,请谨慎开启!',
269
+ description: '开启后,可获取成员多选数据',
270
270
  }),
271
271
  });
272
272
  const events = [
@@ -36,6 +36,7 @@ declare const data: import("@sinclair/typebox").TObject<{
36
36
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
37
37
  title: string;
38
38
  default: any;
39
+ description: string;
39
40
  }>;
40
41
  placeholder: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
41
42
  default: string;
@@ -80,6 +81,7 @@ declare const config: {
80
81
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
81
82
  title: string;
82
83
  default: any;
84
+ description: string;
83
85
  }>;
84
86
  placeholder: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
85
87
  default: string;
@@ -23,7 +23,11 @@ const TITLE = getFormItemDataTitle('成员');
23
23
  const data = Type.Partial(Type.Object({
24
24
  // 通用
25
25
  name: FORM_ITEM_DATA.name,
26
- value: Object.assign({}, FORM_ITEM_DATA.value, { title: '选中值', default: null }),
26
+ value: Object.assign({}, FORM_ITEM_DATA.value, {
27
+ title: '选中值',
28
+ default: null,
29
+ description: '单选时选中值为字符串类型,多选时选中值为数组类型',
30
+ }),
27
31
  placeholder: Object.assign({}, FORM_ITEM_DATA.placeholder, {
28
32
  default: '请选择成员',
29
33
  }),
@@ -17,6 +17,7 @@ declare const data: import("@sinclair/typebox").TObject<{
17
17
  name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
18
18
  default: string;
19
19
  }>;
20
+ storageType: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"https" | "cloudID">>;
20
21
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
21
22
  }>;
22
23
  declare const config: {
@@ -38,6 +39,7 @@ declare const config: {
38
39
  name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
39
40
  default: string;
40
41
  }>;
42
+ storageType: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"https" | "cloudID">>;
41
43
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
42
44
  }>;
43
45
  readonly properties: import("@sinclair/typebox").TObject<{
@@ -7,6 +7,7 @@ const TITLE = getFormItemDataTitle('富文本');
7
7
  const data = Type.Partial(Type.Object({
8
8
  // 通用
9
9
  name: Object.assign({}, FORM_ITEM_DATA.name, { default: 'formTextarea' }),
10
+ storageType: FORM_ITEM_DATA.storageType,
10
11
  value: FORM_ITEM_DATA.value,
11
12
  // 标题
12
13
  ...TITLE,
@@ -37,6 +37,7 @@ declare const data: import("@sinclair/typebox").TObject<{
37
37
  name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
38
38
  'x-helper-text': string;
39
39
  }>;
40
+ storageType: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"https" | "cloudID">>;
40
41
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString> & {
41
42
  title: string;
42
43
  }>;
@@ -80,6 +81,7 @@ declare const config: {
80
81
  name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
81
82
  'x-helper-text': string;
82
83
  }>;
84
+ storageType: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"https" | "cloudID">>;
83
85
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString> & {
84
86
  title: string;
85
87
  }>;
@@ -11,6 +11,7 @@ const data = Type.Partial(Type.Object({
11
11
  name: Object.assign({}, FORM_ITEM_DATA.name, {
12
12
  'x-helper-text': '文件上传后,文件 https 链接默认仅可在微搭应用中访问,有效期 2 小时,可在[云存储权限设置](https://cloud.tencent.com/document/product/876/49037)中调整访问权限。',
13
13
  }),
14
+ storageType: FORM_ITEM_DATA.storageType,
14
15
  value: Object.assign({}, FORM_ITEM_DATA._valueInUpload, {
15
16
  title: '文件值',
16
17
  }),
@@ -36,16 +36,16 @@ declare const data: import("@sinclair/typebox").TObject<{
36
36
  layout: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<string>>;
37
37
  labelWidth: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
38
38
  labelTips: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
39
- name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
40
- 'x-helper-text': string;
41
- }>;
42
- value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
43
39
  template: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
40
+ name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
41
+ storageType: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"https" | "cloudID">>;
42
+ value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
44
43
  }>;
45
44
  declare const previewFileItem: import("@sinclair/typebox").TObject<{
46
45
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
47
46
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
48
47
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
48
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
49
49
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
50
50
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
51
51
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -71,6 +71,7 @@ declare const uploadInstance: import("@sinclair/typebox").TObject<{
71
71
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
72
72
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
73
73
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
74
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
74
75
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
75
76
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
76
77
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -79,6 +80,7 @@ declare const uploadInstance: import("@sinclair/typebox").TObject<{
79
80
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
80
81
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
81
82
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
83
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
82
84
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
83
85
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
84
86
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -87,6 +89,7 @@ declare const uploadInstance: import("@sinclair/typebox").TObject<{
87
89
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
88
90
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
89
91
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
92
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
90
93
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
91
94
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
92
95
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -127,16 +130,13 @@ declare const config: {
127
130
  layout: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<string>>;
128
131
  labelWidth: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
129
132
  labelTips: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
130
- name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
131
- 'x-helper-text': string;
132
- }>;
133
- value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
134
133
  template: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
134
+ name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
135
+ storageType: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"https" | "cloudID">>;
136
+ value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
135
137
  }>;
136
138
  properties: import("@sinclair/typebox").TObject<{
137
- name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
138
- 'x-helper-text': string;
139
- }>;
139
+ name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
140
140
  label: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
141
141
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
142
142
  required: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
@@ -164,6 +164,7 @@ declare const config: {
164
164
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
165
165
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
166
166
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
167
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
167
168
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
168
169
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
169
170
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -172,6 +173,7 @@ declare const config: {
172
173
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
173
174
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
174
175
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
176
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
175
177
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
176
178
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
177
179
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -180,6 +182,7 @@ declare const config: {
180
182
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
181
183
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
182
184
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
185
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
183
186
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
184
187
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
185
188
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -190,6 +193,7 @@ declare const config: {
190
193
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
191
194
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
192
195
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
196
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
193
197
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
194
198
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
195
199
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -275,6 +279,7 @@ declare const config: {
275
279
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
276
280
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
277
281
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
282
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
278
283
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
279
284
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
280
285
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -283,6 +288,7 @@ declare const config: {
283
288
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
284
289
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
285
290
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
291
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
286
292
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
287
293
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
288
294
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -291,6 +297,7 @@ declare const config: {
291
297
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
292
298
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
293
299
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
300
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
294
301
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
295
302
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
296
303
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -18,12 +18,9 @@ export const WD_TAG_CAPTURE_TYPE = [
18
18
  const SELECT = pickWithXCategory(FORM_ITEM_DATA, ['extra', 'showShape', 'borderedH5', 'isChooseAvatar'], X_CATEGORY.IMAGE_CONTENT);
19
19
  const TITLE = getFormItemDataTitle('图片上传');
20
20
  // 属性类型定义
21
- const data = Type.Partial(Type.Object({
22
- // 通用
23
- name: Object.assign({}, FORM_ITEM_DATA.name, {
24
- 'x-helper-text': '图片上传后,图片 https 链接默认仅可在微搭应用中访问,有效期 2 小时,可在[云存储权限设置](https://cloud.tencent.com/document/product/876/49037)中调整访问权限。',
25
- }),
26
- value: FORM_ITEM_DATA._valueInUpload,
21
+ const data = Type.Partial(
22
+ // 模版
23
+ Type.Object({
27
24
  template: Type.String({
28
25
  enum: Tuple([
29
26
  {
@@ -44,6 +41,10 @@ const data = Type.Partial(Type.Object({
44
41
  'data-hidebind': true,
45
42
  },
46
43
  }),
44
+ // 通用
45
+ name: FORM_ITEM_DATA.name,
46
+ storageType: FORM_ITEM_DATA.storageType,
47
+ value: FORM_ITEM_DATA._valueInUpload,
47
48
  // 标题
48
49
  ...TITLE,
49
50
  // 内容
@@ -141,6 +142,7 @@ const previewFileItem = Type.Partial(Type.Object({
141
142
  progress: Type.Number({ title: '加载进度条' }),
142
143
  loading: Type.Boolean({ title: '是否loading' }),
143
144
  cloudId: Type.String({ title: '云存储id' }),
145
+ url: Type.String({ title: '图片https地址' }),
144
146
  tempUrl: Type.String({ title: '临时图片地址' }),
145
147
  key: Type.String({ title: 'key' }),
146
148
  file: Type.Any({ title: 'web端图片对象' }),
@@ -15323,6 +15323,7 @@ export declare const components: {
15323
15323
  name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
15324
15324
  'x-helper-text': string;
15325
15325
  }>;
15326
+ storageType: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"https" | "cloudID">>;
15326
15327
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString> & {
15327
15328
  title: string;
15328
15329
  }>;
@@ -15497,16 +15498,13 @@ export declare const components: {
15497
15498
  layout: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<string>>;
15498
15499
  labelWidth: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15499
15500
  labelTips: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15500
- name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
15501
- 'x-helper-text': string;
15502
- }>;
15503
- value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
15504
15501
  template: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15502
+ name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15503
+ storageType: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"https" | "cloudID">>;
15504
+ value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
15505
15505
  }>;
15506
15506
  properties: import("@sinclair/typebox").TObject<{
15507
- name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
15508
- 'x-helper-text': string;
15509
- }>;
15507
+ name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15510
15508
  label: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15511
15509
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
15512
15510
  required: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
@@ -15534,6 +15532,7 @@ export declare const components: {
15534
15532
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
15535
15533
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
15536
15534
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15535
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15537
15536
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15538
15537
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15539
15538
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -15542,6 +15541,7 @@ export declare const components: {
15542
15541
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
15543
15542
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
15544
15543
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15544
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15545
15545
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15546
15546
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15547
15547
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -15550,6 +15550,7 @@ export declare const components: {
15550
15550
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
15551
15551
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
15552
15552
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15553
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15553
15554
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15554
15555
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15555
15556
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -15560,6 +15561,7 @@ export declare const components: {
15560
15561
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
15561
15562
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
15562
15563
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15564
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15563
15565
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15564
15566
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15565
15567
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -15645,6 +15647,7 @@ export declare const components: {
15645
15647
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
15646
15648
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
15647
15649
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15650
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15648
15651
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15649
15652
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15650
15653
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -15653,6 +15656,7 @@ export declare const components: {
15653
15656
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
15654
15657
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
15655
15658
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15659
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15656
15660
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15657
15661
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15658
15662
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -15661,6 +15665,7 @@ export declare const components: {
15661
15665
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
15662
15666
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
15663
15667
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15668
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15664
15669
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15665
15670
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15666
15671
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -16069,6 +16074,7 @@ export declare const components: {
16069
16074
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
16070
16075
  title: string;
16071
16076
  default: any;
16077
+ description: string;
16072
16078
  }>;
16073
16079
  placeholder: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
16074
16080
  default: string;
@@ -18604,6 +18610,7 @@ export declare const components: {
18604
18610
  name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
18605
18611
  default: string;
18606
18612
  }>;
18613
+ storageType: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"https" | "cloudID">>;
18607
18614
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
18608
18615
  }>;
18609
18616
  readonly properties: import("@sinclair/typebox").TObject<{
@@ -34885,6 +34892,7 @@ declare const _default: {
34885
34892
  name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
34886
34893
  'x-helper-text': string;
34887
34894
  }>;
34895
+ storageType: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"https" | "cloudID">>;
34888
34896
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString> & {
34889
34897
  title: string;
34890
34898
  }>;
@@ -35059,16 +35067,13 @@ declare const _default: {
35059
35067
  layout: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<string>>;
35060
35068
  labelWidth: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35061
35069
  labelTips: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35062
- name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
35063
- 'x-helper-text': string;
35064
- }>;
35065
- value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
35066
35070
  template: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35071
+ name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35072
+ storageType: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"https" | "cloudID">>;
35073
+ value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
35067
35074
  }>;
35068
35075
  properties: import("@sinclair/typebox").TObject<{
35069
- name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
35070
- 'x-helper-text': string;
35071
- }>;
35076
+ name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35072
35077
  label: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35073
35078
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
35074
35079
  required: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
@@ -35096,6 +35101,7 @@ declare const _default: {
35096
35101
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
35097
35102
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
35098
35103
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35104
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35099
35105
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35100
35106
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35101
35107
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -35104,6 +35110,7 @@ declare const _default: {
35104
35110
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
35105
35111
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
35106
35112
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35113
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35107
35114
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35108
35115
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35109
35116
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -35112,6 +35119,7 @@ declare const _default: {
35112
35119
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
35113
35120
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
35114
35121
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35122
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35115
35123
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35116
35124
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35117
35125
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -35122,6 +35130,7 @@ declare const _default: {
35122
35130
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
35123
35131
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
35124
35132
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35133
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35125
35134
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35126
35135
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35127
35136
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -35207,6 +35216,7 @@ declare const _default: {
35207
35216
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
35208
35217
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
35209
35218
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35219
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35210
35220
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35211
35221
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35212
35222
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -35215,6 +35225,7 @@ declare const _default: {
35215
35225
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
35216
35226
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
35217
35227
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35228
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35218
35229
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35219
35230
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35220
35231
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -35223,6 +35234,7 @@ declare const _default: {
35223
35234
  progress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
35224
35235
  loading: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
35225
35236
  cloudId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35237
+ url: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35226
35238
  tempUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35227
35239
  key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
35228
35240
  file: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
@@ -35631,6 +35643,7 @@ declare const _default: {
35631
35643
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
35632
35644
  title: string;
35633
35645
  default: any;
35646
+ description: string;
35634
35647
  }>;
35635
35648
  placeholder: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
35636
35649
  default: string;
@@ -38166,6 +38179,7 @@ declare const _default: {
38166
38179
  name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString & {
38167
38180
  default: string;
38168
38181
  }>;
38182
+ storageType: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"https" | "cloudID">>;
38169
38183
  value: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
38170
38184
  }>;
38171
38185
  readonly properties: import("@sinclair/typebox").TObject<{
@@ -32,6 +32,7 @@ export declare const FORM_ITEM_DATA: {
32
32
  /** 通用 */
33
33
  isRoot: import("@sinclair/typebox").TBoolean;
34
34
  name: import("@sinclair/typebox").TString;
35
+ storageType: import("@sinclair/typebox").TUnsafe<"https" | "cloudID">;
35
36
  language: import("@sinclair/typebox").TUnsafe<string>;
36
37
  theme: import("@sinclair/typebox").TUnsafe<string>;
37
38
  _rangeInTagSelect: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
@@ -459,6 +460,7 @@ export declare const FORM_ITEM_META: {
459
460
  export declare const ItemData: import("@sinclair/typebox").TObject<{
460
461
  isRoot: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
461
462
  name: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
463
+ storageType: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"https" | "cloudID">>;
462
464
  language: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<string>>;
463
465
  theme: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<string>>;
464
466
  _rangeInTagSelect: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
@@ -79,6 +79,29 @@ export const FORM_ITEM_DATA = {
79
79
  },
80
80
  ],
81
81
  }),
82
+ storageType: Type.StringEnum({
83
+ enum: Tuple([
84
+ {
85
+ label: 'https协议',
86
+ value: 'https',
87
+ description: '选择https方式,文件将自动转换为https 链接并存储在数据模型中,开启云存储公有读写权限后,文件链接将长期有效。',
88
+ },
89
+ {
90
+ label: 'cloudID协议',
91
+ value: 'cloudID',
92
+ description: '选择cloudID方式,文件将以云存储 fileID 的形式直接存储在数据模型中。',
93
+ },
94
+ ]),
95
+ title: '值存储方式',
96
+ 'x-runtime-default': 'cloudID',
97
+ description: '指定图片存储方式',
98
+ 'x-helper-text': '选择cloudID方式,文件将以云存储 fileID 的形式直接存储在数据模型中;选择https方式,文件将以HTTPS链接形式存储在数据模型中,开启[云存储](https://docs.cloudbase.net/lowcode/faq#q%E5%BA%94%E7%94%A8%E5%8F%91%E5%B8%83%E5%90%8E%E5%9B%BE%E7%89%87%E4%B8%8D%E5%B1%95%E7%A4%BA)公有读写权限后,文件链接将长期有效。',
99
+ 'x-index': 12,
100
+ 'x-category': X_CATEGORY.COMMON,
101
+ 'x-props': {
102
+ 'data-hidebind': true,
103
+ },
104
+ }),
82
105
  language: Type.StringEnum({
83
106
  title: '支持语言',
84
107
  enum: Tuple(WD_CODE_EDITOR_LANGUAGE),
@@ -1,5 +1,5 @@
1
1
  /**
2
- @cloudbase/weda-ui v3.20.2
2
+ @cloudbase/weda-ui v3.20.3
3
3
  */
4
4
  @charset "UTF-8";@media (min-width:1024px){.weda-ui .weui-cells{font-size:1em}.weui .weui-cell_active:active{background-color:unset!important}}@font-face{font-family:lcap-icon;font-weight:400;font-style:normal;src:url(data:application/font-woff2;charset=utf-8;base64,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) format('woff2')}.wd-form--vertical-left .wedatea2td-form .weda-formcells__pc.horizontal,.wd-form--vertical-right .wedatea2td-form .weda-formcells__pc.horizontal,.wedatea2td-form--vertical .wd-form--horizontal-left .wd-form-item-wrap,.wedatea2td-form--vertical .wd-form--horizontal-right .wd-form-item-wrap,.wedatea2td-form--vertical .wd-form-item.wd-form-item--horizontal-left .wd-form-item-wrap,.wedatea2td-form--vertical .wd-form-item.wd-form-item--horizontal-right .wd-form-item-wrap,.wedatea2td-form--vertical .wedatea2td-form .weda-formcells__pc.horizontal{flex-direction:column}.g-swiper-item>div>*{max-width:100%;max-height:100%;object-fit:cover;max-width:100%;object-fit:cover;max-width:100%;max-height:100%;object-fit:cover;width:100%;height:auto;max-width:100%;object-fit:cover}.form-detail-wrap .form-detail-content-wrap .form-detail-group-header-container{display:flex;align-items:center;justify-content:space-between}.weda-graphic-card .weda-graphic-card__col .weda-graphic-card__title{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}.weda-graphic-card .weda-graphic-card__col .weda-graphic-card__desc{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}.weda-menu .wedatea2td-menu--light .wedatea2td-menu__list li.is-selected>.wedatea2td-menu__item:hover,.wedatea2td-drawer .wedatea2td-menu--light .wedatea2td-menu__list li .wedatea2td-menu__item:hover{background-color:var(--weda-navigation-menu-hover-color)}.weda-menu-mobile .weda-menu__wrapper{display:flex;align-items:center;justify-content:space-between;box-shadow:0 2px 2px rgba(0,0,0,.05)}.weda-menu .wedatea2td-menu__text .menu-text,.weda-menu__drawer .wedatea2td-menu__text .menu-text{display:flex;justify-content:center;align-items:center}@media (max-width:1024px){.g-swiper .g-swiper__turn-next,.g-swiper .g-swiper__turn-pre{display:none}.modal-table-delete .wedatea2td-dialog__inner,.model-relation-selector-modal .wedatea2td-dialog__inner,.wedatea2td-dialog__inner{min-width:0;width:90%;margin:10px 0}.wedatea2td-form.model-form{width:100%}}.markdown-body .octicon{fill:currentColor}.markdown-body pre{word-wrap:normal}.wd-form-item.wd-pc-rich-text-root .ExEditor-basic,.wd-form-item.wd-pc-rich-text-root .exeditor-toolbar{background-color:inherit}.wd-add-relation-button-wrap{display:flex;align-items:center;color:var(--wd-color-brand,#0052d9);white-space:pre-wrap}.weda-import-csv-file-modal .file-json-map-wrap{display:flex;flex-direction:column;box-sizing:border-box}.weda-import-csv-file-modal .import-file-result-wrap .error-container{display:flex;flex-direction:column}.weda-import-csv-file-modal .import-file-result-wrap .error-content{flex:1}.wd-table-wrap-filter .wedatea2td-input:focus,.wd-table-wrap-filter .wedatea2td-input:hover,.wd-table-wrap-filter .wedatea2td-textarea-group:focus,.wd-table-wrap-filter .wedatea2td-textarea-group:hover,.wd-table-wrap-filter .wedatea2td-textarea:focus,.wd-table-wrap-filter .wedatea2td-textarea:hover,.wedatea2td-overlay .wedatea2td-checkbox:focus,.wedatea2td-overlay .wedatea2td-checkbox:hover,.wedatea2td-overlay input[type=checkbox]:focus,.wedatea2td-overlay input[type=checkbox]:hover{border-color:var(--wd-color-brand,#0052d9)}.weda-ui_mapChoose_search_input_clear{display:flex;justify-content:center}.form-select-map .wedatea2td-dialog__inner{box-shadow:none;min-width:100vw!important}.weda-ui-custom-calendar-op__end,.weda-ui-custom-calendar-op__start{display:flex;align-items:center}.weui-tag span{word-wrap:break-word;word-break:break-word}.weda-ui-user-select-container-list__start .depart-tree .wedatea2td-tree__node.is-selected>.wedatea2td-tree__node-content,.weda-ui-user-select-container-list__start .depart-tree .wedatea2td-tree__node.is-selected>.wedatea2td-tree__node-content .wedatea2td-tree__label,.weda-ui-user-select-container-list__start .wedatea2td-tree.wedatea2td-tree--checkbox-separate .wedatea2td-tree__node.is-selected>.wedatea2td-tree__node-content .wedatea2td-tree__label .wedatea2td-tree__label-title{background-color:var(--wd-color-brand-light,#d4e3fc)}.weda-select-user-dept-breadcrumb{display:flex;align-items:center}.form-location-con_disabled{opacity:.4}body{font-size:var(--wd-font-base)}@font-face{font-family:wd-lcap-icon;font-weight:400;font-style:normal;src:url(data:application/font-woff2;charset=utf-8;base64,d09GMgABAAAAAAkMAA0AAAAAFZgAAAi1AAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAP0ZGVE0cGh4GYACCXhEICpxYlmoLTgABNgIkA1gEIAWDMweDBRtzEVGUTVKf7GdCpjLGY/HIYGvbDpn6q7Qdj3xvUaZJUNFads3M7geYVSSiCgsZJYFkhEfn2DjU9//jpn8D1QTqVBQqSrtAVZAq1bwkpTOo0Hbz2tnYfkP3ZzAxpv6ZiSFf3OHh8/b+/oqzxIt4QmFX5ImmIe0SWAOEOJL2n9ZSO5PcCwErnTjzLxOYud0Az24IS8AOXSWgBtyL2lbFtkKxMAhSoPNdlrMFakJqTjuamX+3E3teqiTm6/UpPkH213oLGNahKuAtpQ0wbERrXcnzO1bBpK388B4D6I5fCT9kh69EbSy65RKsi/26+7qKtJv2oREq98FIbnbJO3TaMjBjPcwtqFDG9qp0XxcX/7ndSrUHxotP16TcVrHOGHgIM0PwK6JIMvN/BgpiRTDc/CFwhO+x7ZDYI/ONMoO4NDIX3PYHqpDAWg0a1byp4P4j3ft6fX2jqrvbO6bLU5gtI53w8U4ueG4vS7h0Ze7t9hJUld5xMnwpJp2X5O8KxChB4KG0IQ8pBk+JUXq17qFT7cTN1G17zf2SrGdNz1yMi7Agh0PzRINR0otFF515Z3Fzzml7wfmCrEvFl1zV9wiL6o6j8ELh5LgzjkKpbVTilkw1XLvyYxiCxZHZhpkOEZY3gDto5Ci7PcrBzbTTOYWZGNeqCfoBN0loREx3AceICXbDYFPHIUNaFz37kj0Ei2vbd+MI4fpcJncQ7UiqZzDbycj160Ox7c5YRB0pveJQ3YE71D9yKW5lF9orrq/YQX3XWXa1DDNuc8TQbUcr6ezQQEfN/bEOsmgp7+bEmaOZvxxKsTdORFitIiMxPsBbiIQUJqBxjw7Wv8OPnYIEBlpoYHgDFN/AoHKaGqHoEsTMoJkyCk1BVClDG4WIgACMYEihHNcRrEBLtAtpPsHDR2hmg0XUYuVCqJIuijEgI33NhR3cq+UqR216c91Dp/wkZso+5ap/RFhqHzhkJ4Ajj9tr7uMGA+qimQHUTFOtDN2GmBajgI/zBCDkEXwh4w9+mIFgtQSf4BnP447P8fViKWSgKXpaMshoRh0H+cu3QzkPLQgxwaTGgeAMY/ghgFIpHsHHMdj5HbMQztMOgb/zYwQf563lK4EO80vM9IqwvADuubD+SUa9lp2M2E6dlqEoRFMMzTAISVqNV2EVu7Sr56jz2sxHZjtwV+30MZNzR3xwy21IHgdOdsJR++Am9Zt9CjPJTzrrHuLtgGMdFpJ1ODVE+FlngnUbAXDTnowNG8IEpR+LmWy4+WA4AI6ZXASAQ/ns1179PmP6cMbfFYRCYcu/y9mmz/j9VfqqVaNZCkJB1NRw8qntmA5j2+3S7mEU94VLJnN9kTsNd0vtEw8emBAfnpqbmxq+cD5wcGI6F/cmlVry6X2VpHdNr6Xvf1rSvP+bcZL9jQJdTsRoQE+A5wbKsH26JDoJjXFsEpPYo0OJngPHJaIkWtedxCay3JhNEKPrYXTS2JhPmNNNdkiaOoaGbWfJeLYhXiMZGBY3Spo6WEkDjAwMNoh5TaajSdwkGRqI/85r2Mv4W9bZExPemzd86sLG6h4vaayTkWiWcjU1CztzohIpnwYMBwSSrQLtf/8wX5QPVMJFuYT2nZU9wWaYtxy8b9j4ycHg9GvxOXpEXvFWi15LSkvyVb982ls3NjD1eoTi/oXBFnWoKlRTPH+eTr5nHQE5LXdU5x0d91arTmOl7NfU2gWzp2U+OD/YyufPYa0AvG7aeCnBkDem4EbDmiFgcdP5cRt6rdm6r7ybGqu++K73XLQKuNOvuTk7a9TmvjYiDXn5AmMeu/+zvSyv9SP3/7COdc7nr56/vDw0MvTPL6llXDLchuypmJq2bicN9M7+8ji/uK9zHCjU/W+0Fgp6Q+sq76fRAX5q7ly1+lHCpe8vJV4q1n7c3789MWF7/xTJQ0DB8YnLlmWmzaqoj66MqtTrKr2O+vpKRusqSj+6vkE2UjEr7aWim/dsdJEoqa6utbKosKqlrj5RVNSWiflSLVWFRZWtXCaxGbg0zd/fHNFqX76CZaHY9tNPj34UIY9+Mn8s7wClLQ7bIfqQDaUzYN7x9WTMOV1ntYtmtaZz6SDmI1Yj1kgGBsQXUbdLGhpU1/ckK4uVaMRS43e0s5XdMDDAv+fsxfFK5eMn+flK1c8/L15MHlG+YTYTKW4025bWp7UUQH2n1j/y9Tt6J+5mykLynYv6i9HZvqC/QNV2kZ7HXO/X7/bDf9+T1/Rpe/YolYsWYXO1XS/CmOv6KUuBnUoITNTDEhJNqb1rYTOf1sRhF1D0EvKOkYiRSHnElw9UGd7bkVIq17pUYpqZfGAtizVSDozNPORXtY3YTig+HhCnpergJhqZl1ZlhDTKQz8O+lKEtWVWLTXTaNPBSmt1Z6faC6hmaq+/j+gGT66PrtpKxquCKzUqTFI36xjltiipsN34AAhYK30U0Si9PDd4Qrlx5gXZbykCAdhWAj3p+F8DA+WBim/aNhq9g86DAocD+KIj0VJtIEzs137fvNcn+Zf8+xChp637Q/Eo/0gLUBkjiCckExRp4iSCSMhV8TToMmywXB/GhkcF5ziw45OB87l85aUMFg0NLu2/zrqV/BH9vE5gRJkaL8IilGuqC03JjHIZdlQAzgqTSpcqAx7mVejwNSGWWs4aGlmhqdGjnCFPBYAqTFrMVhmw/tErzDrt1E1nqkx9Os0wHbxR48t8+rYA9icsgyFzkc5s8Ne9hwCEXWH8WM82YAhjUzGZLCR46/+MZFkk2djoLT1IzKCbi3WV1hnUrcvSm+MZtRSpiYWanQU+67DN62G7tnPGP8h5DgBGvMgjgCILl0eQyJQoo5wKKqmimhpqqSOQIIIJQUQoYYQTQSRRRBNDLHGIkRBPAonZMHXOzF6Z99D0PpIk80xVIUlCBjmykYNc5CEfBShEJaqggBIqjzpSRkIGObKRg1zkIR8FKEQlqqCAEiqPulNOAgAA) format("woff2")}.t-icon{speak:none;text-transform:none;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.wd-space-align-items--flex-start{align-items:flex-start;align-items:center;align-items:flex-end}.wd-space-justify-content--flex-start{justify-content:flex-start;justify-content:center;justify-content:flex-end}.wd-btn{--wd-btn-sm-padding:0.0625rem calc(var(--wd-space-base) * 2);--wd-btn-md-padding:0.25rem calc(var(--wd-space-base) * 4);--wd-btn-lg-padding:0.4375rem calc(var(--wd-space-base) * 6);--wd-btn-margin-top:0;--wd-btn-margin-top:0;--wd-btn-font-size-sm:var(--wd-font-size-2);--wd-btn-line-height-sm:1.5;--wd-btn-min-height-sm:24px;--wd-btn-font-size-md:var(--wd-font-size-3);--wd-btn-line-height-md:1.5;--wd-btn-min-height-md:32px;--wd-btn-font-size-lg:var(--wd-font-size-4);--wd-btn-line-height-lg:1.5;--wd-btn-min-height-lg:40px;--wd-btn-icon-space-sm:var(--wd-space-base);--wd-btn-icon-space-md:calc(var(--wd-space-base) * 2);--wd-btn-icon-space-lg:calc(var(--wd-space-base) * 3);--wd-btn-icon-size-sm:calc(var(--wd-btn-font-size-sm) + 0.125rem);--wd-btn-icon-size-md:calc(var(--wd-btn-font-size-md) + 0.125rem);--wd-btn-icon-size-lg:calc(var(--wd-btn-font-size-lg) + 0.25rem);--wd-btn-border-radius:var(--wd-border-radius);--wd-btn-color-text:var(--wd-color-text-default);--wd-btn-color-text-inverse:var(--wd-color-text-inverse);--wd-btn-color-text-hover:var(--wd-color-text-default);--wd-btn-color-text-active:var(--wd-color-text-default);--wd-btn-color-text-focus:var(--wd-color-text-default);--wd-btn-color-text-disabled:var(--wd-color-text-disabled);--wd-btn-color-brand:var(--wd-color-brand);--wd-btn-color-brand-hover:var(--wd-color-brand-hover);--wd-btn-color-brand-active:var(--wd-color-brand-active);--wd-btn-color-brand-focus:var(--wd-color-brand-focus);--wd-btn-color-brand-disabled:var(--wd-color-brand-disabled);--wd-btn-color-warning:var(--wd-color-warning);--wd-btn-color-warning-hover:var(--wd-color-warning-hover);--wd-btn-color-warning-active:var(--wd-color-warning-active);--wd-btn-color-warning-focus:var(--wd-color-warning-focus);--wd-btn-color-warning-disabled:var(--wd-color-warning-disabled);--wd-btn-color-error:var(--wd-color-error);--wd-btn-color-error-hover:var(--wd-color-error-hover);--wd-btn-color-error-active:var(--wd-color-error-active);--wd-btn-color-error-focus:var(--wd-color-error-focus);--wd-btn-color-error-disabled:var(--wd-color-error-disabled);--wd-btn-color-gray:var(
5
5
  --wd-color-gray-1
@@ -19,6 +19,7 @@ interface UploadProps extends EventsType {
19
19
  callbacks?: DataType['callbacks'];
20
20
  onChange?: (val?: any) => void;
21
21
  setUploadHandle?: (uploadHandle: any) => void;
22
+ storageType?: DataType['storageType'];
22
23
  children?: any;
23
24
  }
24
25
  export declare const IMAGE_TYPES: string[];
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import React, { forwardRef, useState, useCallback, useEffect, useImperativeHandle } from 'react';
3
3
  import { getUuid } from '../../../../utils/tool';
4
- import { upload as uploadAction, checkBeforeUpload, getPreviewFileMap, getInitTempFile, getBase64 } from '../util';
4
+ import { upload as uploadAction, checkBeforeUpload, getPreviewFileMap, getInitTempFile, getBase64, storageTypeIsHttps, } from '../util';
5
5
  import { errorHandler } from '../../../../utils/error';
6
6
  import { isNil } from '../../../../utils/lodash';
7
7
  import { toBase64Uri } from '../../../../utils/file2base64';
@@ -19,7 +19,8 @@ export const IMAGE_TYPES = [
19
19
  'image/gif',
20
20
  ];
21
21
  export const Upload = forwardRef(function Upload({ children, ...props }, ref) {
22
- const { maxUploadCount, acceptTypes, multiple, maxSize, disabled, readOnly, name, isCompressBeforeUpload, compressQuality, compressedHeight, compressedWidth, events, onChange, callbacks, setUploadHandle, value: _value, sourceType, } = props;
22
+ const { maxUploadCount, acceptTypes, multiple, maxSize, disabled, readOnly, name, isCompressBeforeUpload, compressQuality, compressedHeight, compressedWidth, events, onChange, callbacks, setUploadHandle, value: _value, sourceType, storageType, } = props;
23
+ const _storageTypeIsHttps = storageTypeIsHttps(storageType);
23
24
  const inputRef = React.useRef(null);
24
25
  const [inputId, setInputId] = useState(() => {
25
26
  return getUuid();
@@ -50,6 +51,7 @@ export const Upload = forwardRef(function Upload({ children, ...props }, ref) {
50
51
  compressQuality,
51
52
  compressedHeight,
52
53
  compressedWidth,
54
+ storageType,
53
55
  }, equal);
54
56
  const [initFlag, setInitFlag] = useState(false);
55
57
  React.useEffect(() => {
@@ -72,7 +74,7 @@ export const Upload = forwardRef(function Upload({ children, ...props }, ref) {
72
74
  var _a;
73
75
  updatePreviewFile(allFile);
74
76
  const getTempFile = (allFile = []) => {
75
- let value = allFile.map((i) => i === null || i === void 0 ? void 0 : i.cloudId).filter((j) => !!j);
77
+ let value = allFile.map((i) => (_storageTypeIsHttps ? i.url.split('?')[0] : i === null || i === void 0 ? void 0 : i.cloudId)).filter((j) => !!j);
76
78
  value = !multiple ? value[0] || '' : value;
77
79
  return value;
78
80
  };
@@ -80,7 +82,7 @@ export const Upload = forwardRef(function Upload({ children, ...props }, ref) {
80
82
  onChange === null || onChange === void 0 ? void 0 : onChange(value);
81
83
  (_a = events === null || events === void 0 ? void 0 : events.change) === null || _a === void 0 ? void 0 : _a.call(events, { value, isDelete });
82
84
  setInputId(getUuid());
83
- }, [events, multiple, onChange]);
85
+ }, [events, multiple, onChange, storageType]);
84
86
  const uploadChange = useCallback(async (e) => {
85
87
  const { accepts, maxSize, maxUploadCount } = config;
86
88
  let files = [...e.target.files];
@@ -163,7 +165,7 @@ export const Upload = forwardRef(function Upload({ children, ...props }, ref) {
163
165
  onSuccess(item) {
164
166
  var _a;
165
167
  updatePreviewFile((allTempFile) => allTempFile.map((i) => (i.key === item.key ? { ...i, ...item } : i)));
166
- (_a = events === null || events === void 0 ? void 0 : events.success) === null || _a === void 0 ? void 0 : _a.call(events, { value: item.cloudId, file: item.file });
168
+ (_a = events === null || events === void 0 ? void 0 : events.success) === null || _a === void 0 ? void 0 : _a.call(events, { value: _storageTypeIsHttps ? item.url : item.cloudId, file: item.file });
167
169
  },
168
170
  onFail(err) {
169
171
  events === null || events === void 0 ? void 0 : events.error(err);
@@ -36,5 +36,6 @@ export interface H5UploaderProps extends Except<CommonFormPropsType, 'events'>,
36
36
  tempFile?: any;
37
37
  setTempFile?: any;
38
38
  setUploadHandle?: (arg?: any) => void;
39
+ storageType?: DataType['storageType'];
39
40
  }
40
41
  export {};
@@ -19,7 +19,7 @@ export const IMAGE_TYPES = [
19
19
  'image/gif',
20
20
  ];
21
21
  export function UploaderPCInner(props) {
22
- const { tips = '', btnTitle = '上传图片', maxUploadCount = 9, maxSize = 10, acceptTypes = IMAGE_TYPES, single = false, disabled = false, imgTypeCls, readOnly, sourceType, popupContainer: portalContainer, defaultValue, setUploadHandle: outSetUploadHandle, } = props;
22
+ const { tips = '', btnTitle = '上传图片', maxUploadCount = 9, acceptTypes = IMAGE_TYPES, single = false, disabled = false, imgTypeCls, readOnly, sourceType, popupContainer: portalContainer, defaultValue, setUploadHandle: outSetUploadHandle, } = props;
23
23
  const uploadRef = React.useRef(null);
24
24
  const [uploadHandle, setUploadHandle] = React.useState({});
25
25
  const tempFile = React.useMemo(() => (uploadHandle === null || uploadHandle === void 0 ? void 0 : uploadHandle.previewFile) || [], [uploadHandle === null || uploadHandle === void 0 ? void 0 : uploadHandle.previewFile]);
@@ -1,5 +1,6 @@
1
1
  import { TempFileProps } from './upload/index';
2
2
  export declare const DEFAULT_UPLOAD_PATH = "weda-uploader";
3
+ export declare const storageTypeIsHttps: (storageType: any) => boolean;
3
4
  export declare const getBase64: (files: any) => Promise<any[]>;
4
5
  export declare const uploadTcbMulti: (files: any, props: any) => Promise<any[]>;
5
6
  export declare const filenameRegex: RegExp;
@@ -4,6 +4,7 @@ import { toBase64Uri } from '../../../utils/file2base64';
4
4
  import { randomStr, alertErrorMessage } from '../../../utils/platform';
5
5
  import { errorHandler } from '../../../utils/error';
6
6
  export const DEFAULT_UPLOAD_PATH = 'weda-uploader';
7
+ export const storageTypeIsHttps = (storageType) => storageType === 'https';
7
8
  export const getBase64 = (files) => {
8
9
  return Promise.all(files.map(async (item) => {
9
10
  let tempUrl = '';
@@ -60,7 +61,7 @@ const uploadToTcb = async (item, props) => {
60
61
  _uploadPath = `${_uploadPath}/${sanitizeFilename(customUploadPath, '')}}`;
61
62
  }
62
63
  const cloudPath = `${_uploadPath}/${randomStr()}-${(_a = file === null || file === void 0 ? void 0 : file.name) === null || _a === void 0 ? void 0 : _a.replace(filenameRegex, '-')}`;
63
- const { fileID } = await tcb.uploadFile({
64
+ const res = await tcb.uploadFile({
64
65
  cloudPath,
65
66
  filePath: file,
66
67
  onUploadProgress: (progressEvent) => {
@@ -84,7 +85,8 @@ const uploadToTcb = async (item, props) => {
84
85
  ...item,
85
86
  progress: 100,
86
87
  loading: false,
87
- cloudId: fileID,
88
+ cloudId: res.fileID,
89
+ url: res.download_url,
88
90
  };
89
91
  if (onUploadFinish) {
90
92
  onUploadFinish(fileItem);
@@ -172,6 +174,7 @@ export const getInitTempFile = ({ value }) => {
172
174
  tempUrl: '',
173
175
  progress: 100,
174
176
  loading: false,
177
+ url: '',
175
178
  }));
176
179
  return tempFile;
177
180
  };
@@ -189,8 +192,9 @@ export const IMAGE_TYPES = [
189
192
  ];
190
193
  export const upload = async (fileList, uploadInstance, allTempFile) => {
191
194
  const { config = {}, onComplete, onSuccess, onFail, onUploadProgress } = uploadInstance;
192
- const { isCompressBeforeUpload, compressQuality, compressedHeight, compressedWidth } = config;
195
+ const { isCompressBeforeUpload, compressQuality, compressedHeight, compressedWidth, storageType } = config;
193
196
  const result = await uploadTcbMulti(fileList, {
197
+ storageType,
194
198
  isCompressBeforeUpload,
195
199
  compressedHeight,
196
200
  compressedWidth,
@@ -3,7 +3,7 @@ import type { CommonFormPropsType } from '../types';
3
3
  import type { DataType } from '../../../../configs/components/wd-upload-file';
4
4
  export declare const FILES_TYPES: string[];
5
5
  export declare function UploadFileH5({ layout, id, style, labelVisible, label, requiredFlag, disabled, className, acceptTypes, tips, btnTitle, uploadTipText, maxUploadCount, maxSize, deleteVisible, downloadVisible, value, // 需要兼容 cloud:和https: 协议,需要兼容字符串和字符串数组
6
- events, defaultValue, uploadPath, single, onChange, isEdit, $node, readOnly, callbacks, }: IUploadFileH5): JSX.Element;
6
+ events, defaultValue, uploadPath, single, onChange, isEdit, $node, readOnly, callbacks, storageType, }: IUploadFileH5): JSX.Element;
7
7
  export interface IUploadFileH5 extends CommonFormPropsType {
8
8
  className?: string;
9
9
  label?: string;
@@ -24,4 +24,5 @@ export interface IUploadFileH5 extends CommonFormPropsType {
24
24
  readOnly?: boolean;
25
25
  callbacks?: DataType['callbacks'];
26
26
  uploadTipText?: string;
27
+ storageType?: DataType['storageType'];
27
28
  }
@@ -13,7 +13,7 @@ import { WdButton } from '../../wd-button/wd-button';
13
13
  import { toBase64Uri } from '../../../utils/file2base64';
14
14
  import { isNil } from '../../../utils/lodash';
15
15
  import { errorHandler } from '../../../utils/error';
16
- import { filenameRegex, checkAcceptedFiles } from '../uploader/util';
16
+ import { filenameRegex, checkAcceptedFiles, storageTypeIsHttps } from '../uploader/util';
17
17
  // 默认组件类前缀
18
18
  const CLASS_PREFIX = 'weda-upload-file-mobile';
19
19
  // 默认图片类型
@@ -42,8 +42,9 @@ export function UploadFileH5({
42
42
  layout, id = '', style = defaultStyle, labelVisible = true, label = '上传文件', requiredFlag = false, disabled = false, className = '', acceptTypes = emptyArray,
43
43
  // 组件属性
44
44
  tips = '', btnTitle = '点击上传', uploadTipText = '支持批量上传', maxUploadCount = 9, maxSize = 10, deleteVisible = true, downloadVisible = true, value = emptyArray, // 需要兼容 cloud:和https: 协议,需要兼容字符串和字符串数组
45
- events = emptyObject, defaultValue, uploadPath = 'weda-uploader', single = true, onChange = null, isEdit = true, $node, readOnly, callbacks, }) {
45
+ events = emptyObject, defaultValue, uploadPath = 'weda-uploader', single = true, onChange = null, isEdit = true, $node, readOnly, callbacks, storageType = 'cloudID', }) {
46
46
  var _a;
47
+ const _storageTypeIsHttps = storageTypeIsHttps(storageType);
47
48
  const [fileIDList, setfileIDList] = React.useState(isInIde() ? [] : filterStrList([].concat(defaultValue, value))); // 上传成功文件ID列表,fileID[]
48
49
  const [fileList, setFileList] = React.useState([]); // 上传中的文件列表,file[],file为原始文件 + uuid属性
49
50
  const [fileSizeObj, setFileSizeObj] = React.useState({}); // 管理上传文件大小 {uuid:size}
@@ -94,8 +95,9 @@ events = emptyObject, defaultValue, uploadPath = 'weda-uploader', single = true,
94
95
  return acceptTypes.includes('*') || acceptTypes.length === 0 ? ['*'] : Array.from(new Set(acceptTypes));
95
96
  }, [acceptTypes]);
96
97
  // 上传后文件列表 fileIDList 改变事件,'add'|'delete'
97
- const handleChange = ({ fileID, uuid, type, size, file }) => {
98
+ const handleChange = ({ fileID: _fileID, uuid, type, size, file, url }) => {
98
99
  var _a;
100
+ const fileID = _storageTypeIsHttps ? url : _fileID;
99
101
  if (fileID) {
100
102
  changeTypeRef.current = type;
101
103
  if (type === 'add') {
@@ -257,12 +259,12 @@ const TcbFileUpload = ({ id, file, disabled, formType }) => {
257
259
  }, [file === null || file === void 0 ? void 0 : file._uuid]);
258
260
  // 上传过程
259
261
  const handleUpload = async (file) => {
260
- var _a, _b;
262
+ var _a, _b, _c;
261
263
  const tcb = await getCloudInstance();
262
264
  try {
263
265
  setStatus('UPLOAD_STATUS_PENDING');
264
266
  const _uploadPath = getDefaultUploadPath(uploadPath);
265
- const { fileID } = await tcb.uploadFile({
267
+ const { fileID, download_url } = await tcb.uploadFile({
266
268
  cloudPath: `${_uploadPath}/${randomStr()}-${(_a = file === null || file === void 0 ? void 0 : file.name) === null || _a === void 0 ? void 0 : _a.replace(filenameRegex, '-')}`,
267
269
  filePath: file,
268
270
  onUploadProgress: (progressEvent) => {
@@ -272,7 +274,8 @@ const TcbFileUpload = ({ id, file, disabled, formType }) => {
272
274
  setPercent(percent < 100 ? percent : 100);
273
275
  },
274
276
  });
275
- !cancelRef.current && (onChange === null || onChange === void 0 ? void 0 : onChange({ fileID, type: 'add', uuid, size, file }));
277
+ const url = (_b = download_url === null || download_url === void 0 ? void 0 : download_url.split('?')) === null || _b === void 0 ? void 0 : _b[0];
278
+ !cancelRef.current && (onChange === null || onChange === void 0 ? void 0 : onChange({ fileID, url, type: 'add', uuid, size, file }));
276
279
  setStatus('UPLOAD_STATUS_SUCCESS');
277
280
  }
278
281
  catch (err) {
@@ -282,7 +285,7 @@ const TcbFileUpload = ({ id, file, disabled, formType }) => {
282
285
  id,
283
286
  });
284
287
  setStatus('UPLOAD_STATUS_ERROR');
285
- (_b = events === null || events === void 0 ? void 0 : events.error) === null || _b === void 0 ? void 0 : _b.call(events, err);
288
+ (_c = events === null || events === void 0 ? void 0 : events.error) === null || _c === void 0 ? void 0 : _c.call(events, err);
286
289
  }
287
290
  };
288
291
  return (_jsxs("div", { className: `${CLASS_PREFIX}__item`, role: "TcbFileUpload", children: [_jsx("div", { className: `${CLASS_PREFIX}__item-left`, children: _jsx(UploadFileStatus, { status: status, percent: percent, size: size, title: title, percentSize: (((file === null || file === void 0 ? void 0 : file.size) / 1024) * percent) / 100, formType: formType }) }), _jsx("div", { className: `${CLASS_PREFIX}__btn-group`, children: _jsx(UploadFileAction, { file: file, uuid: file === null || file === void 0 ? void 0 : file._uuid, status: status, onCancel: (uuid) => {
@@ -309,7 +312,7 @@ const UploadFileStatus = ({ status = 'UPLOAD_STATUS_SUCCESS', percent = 0, size,
309
312
  const UploadFileAction = ({ status = 'UPLOAD_STATUS_PENDING', fileID = '', uuid = '', src = '', file = null, onReLoad = null, onCancel = null, disabled, title = 'downfile', }) => {
310
313
  const { onChange, downloadVisible, deleteVisible, isEdit } = React.useContext(FileContext) || {};
311
314
  // 操作列按钮-删除
312
- const renderDelete = () => isEdit && _jsx(Button, { icon: "delete", onClick: () => onChange === null || onChange === void 0 ? void 0 : onChange({ fileID, uuid, type: 'delete' }), disabled: disabled });
315
+ const renderDelete = () => isEdit && (_jsx(Button, { icon: "delete", onClick: () => onChange === null || onChange === void 0 ? void 0 : onChange({ fileID, uuid, type: 'delete', url: src }), disabled: disabled }));
313
316
  // 操作列按钮-取消
314
317
  const renderCancel = () => isEdit && _jsx(Button, { icon: "dismiss", onClick: () => onCancel === null || onCancel === void 0 ? void 0 : onCancel(uuid) });
315
318
  // 操作列按钮-重新上传
@@ -7,7 +7,7 @@ import type { DataType } from '../../../../configs/components/wd-upload-file';
7
7
  */
8
8
  export declare function UploadFilePc({ layout, id, style, labelVisible, label, requiredFlag, disabled, className, events, decorator, tips, btnTitle, uploadTipText, maxUploadCount, maxSize, single, defaultValue, // 组件默认初始化值
9
9
  value, // 用于模型组件中 formily 的值管理
10
- acceptTypes, downloadVisible, deleteVisible, uploadPath, onChange, isEdit, $node, readOnly, callbacks, }: IUploaderFilePc): JSX.Element;
10
+ acceptTypes, downloadVisible, deleteVisible, uploadPath, onChange, isEdit, $node, readOnly, callbacks, storageType, }: IUploaderFilePc): JSX.Element;
11
11
  export interface IUploaderFilePc extends CommonFormPropsType {
12
12
  btnTitle?: string;
13
13
  maxUploadCount?: number;
@@ -25,6 +25,7 @@ export interface IUploaderFilePc extends CommonFormPropsType {
25
25
  readOnly?: boolean;
26
26
  callbacks?: DataType['callbacks'];
27
27
  uploadTipText?: string;
28
+ storageType?: DataType['storageType'];
28
29
  }
29
30
  export interface IUploadFileAction {
30
31
  status?: string;
@@ -14,7 +14,7 @@ import { getParentForm } from '../../../utils/widget-api';
14
14
  import { toBase64Uri } from '../../../utils/file2base64';
15
15
  import { isNil } from '../../../utils/lodash';
16
16
  import { errorHandler } from '../../../utils/error';
17
- import { filenameRegex } from '../uploader/util';
17
+ import { filenameRegex, storageTypeIsHttps } from '../uploader/util';
18
18
  // 默认组件类前缀
19
19
  const CLASS_PREFIX = 'weda-upload-file-pc';
20
20
  // 上传状态字典
@@ -35,8 +35,9 @@ layout, id = '', style, labelVisible = true, label = '上传文件', requiredFla
35
35
  // 组件属性
36
36
  decorator, tips = '', btnTitle = '点击上传', uploadTipText = '支持批量上传', maxUploadCount = 9, maxSize = 1024, single = true, defaultValue = emptyArray, // 组件默认初始化值
37
37
  value = emptyArray, // 用于模型组件中 formily 的值管理
38
- acceptTypes = emptyArray, downloadVisible = true, deleteVisible = true, uploadPath = 'weda-uploader', onChange = null, isEdit = true, $node, readOnly, callbacks, }) {
38
+ acceptTypes = emptyArray, downloadVisible = true, deleteVisible = true, uploadPath = 'weda-uploader', onChange = null, isEdit = true, $node, readOnly, callbacks, storageType = 'cloudID', }) {
39
39
  var _a;
40
+ const _storageTypeIsHttps = storageTypeIsHttps(storageType);
40
41
  const [fileIDList, setfileIDList] = React.useState(() => {
41
42
  let defaultVal = defaultValue;
42
43
  let val = value;
@@ -163,8 +164,9 @@ acceptTypes = emptyArray, downloadVisible = true, deleteVisible = true, uploadPa
163
164
  return Promise.reject(false);
164
165
  };
165
166
  // 上传后文件列表 fileIDList 改变事件,'add'|'delete'
166
- const handleChange = ({ fileID, uuid, type, size, file }) => {
167
+ const handleChange = ({ fileID: _fileID, uuid, type, size, file, url }) => {
167
168
  var _a;
169
+ const fileID = _storageTypeIsHttps ? url : _fileID;
168
170
  if (fileID) {
169
171
  changeTypeRef.current = type;
170
172
  if (type === 'add') {
@@ -220,7 +222,7 @@ const TcbFileEcho = ({ fileID, disabled, formType, readOnly }) => {
220
222
  const { fileSizeObj } = React.useContext(FileContext) || {};
221
223
  const { data: src } = useTempUrl(fileID);
222
224
  const title = React.useMemo(() => {
223
- if (isCloudFileID(fileID)) {
225
+ if (isCloudFileID(fileID) || isHttpFileID(fileID)) {
224
226
  return transFileCloudidToName(fileID);
225
227
  }
226
228
  else {
@@ -249,12 +251,12 @@ const TcbFileUpload = ({ id, file, disabled, formType }) => {
249
251
  }, [file === null || file === void 0 ? void 0 : file._uuid]);
250
252
  // 上传过程
251
253
  const handleUpload = async (file) => {
252
- var _a;
254
+ var _a, _b;
253
255
  const tcb = await getCloudInstance();
254
256
  try {
255
257
  setStatus('0');
256
258
  const _uploadPath = getDefaultUploadPath(uploadPath);
257
- const { fileID } = await tcb.uploadFile({
259
+ const { fileID, download_url } = await tcb.uploadFile({
258
260
  cloudPath: `${_uploadPath}/${randomStr()}-${(_a = file === null || file === void 0 ? void 0 : file.name) === null || _a === void 0 ? void 0 : _a.replace(filenameRegex, '-')}`,
259
261
  filePath: file,
260
262
  onUploadProgress: (progressEvent) => {
@@ -264,7 +266,8 @@ const TcbFileUpload = ({ id, file, disabled, formType }) => {
264
266
  setPercent(percent < 100 ? percent : 100);
265
267
  },
266
268
  });
267
- !cancelRef.current && (onChange === null || onChange === void 0 ? void 0 : onChange({ fileID, type: 'add', uuid, size, file }));
269
+ const url = (_b = download_url === null || download_url === void 0 ? void 0 : download_url.split('?')) === null || _b === void 0 ? void 0 : _b[0];
270
+ !cancelRef.current && (onChange === null || onChange === void 0 ? void 0 : onChange({ fileID, url, type: 'add', uuid, size, file }));
268
271
  setStatus('2');
269
272
  }
270
273
  catch (e) {
@@ -301,7 +304,7 @@ const UploadFileAction = ({ title = 'downfile', status = '0', fileID = '', uuid
301
304
  // 操作列按钮-删除
302
305
  const renderDelete = () => isEdit &&
303
306
  deleteVisible &&
304
- !readOnly && (_jsx(WdButton, { text: "\u5220\u9664", size: "sm", variant: "link", disabled: disabled, events: { tap: () => onChange === null || onChange === void 0 ? void 0 : onChange({ fileID, uuid, type: 'delete' }) } }));
307
+ !readOnly && (_jsx(WdButton, { text: "\u5220\u9664", size: "sm", variant: "link", disabled: disabled, events: { tap: () => onChange === null || onChange === void 0 ? void 0 : onChange({ fileID, uuid, type: 'delete', url: src }) } }));
305
308
  // 操作列按钮-取消
306
309
  const renderCancel = () => isEdit && _jsx(WdButton, { events: { tap: () => onCancel === null || onCancel === void 0 ? void 0 : onCancel(uuid) }, variant: "link", text: "\u53D6\u6D88", size: "sm" });
307
310
  // 操作列按钮-重新上传
@@ -5,16 +5,18 @@ import Tips from '../form/tips';
5
5
  import { useFormInputTrait, useParentForm } from '../form-input-hooks';
6
6
  import { FormItemWrapper } from '../common/form-item-wrapper';
7
7
  import { convertSingleValue } from '../../utils/tool';
8
+ import { parseStrToArr } from '../form/userOrgSelect/common/utils';
8
9
  const FormUserTreeSelect = React.forwardRef(function FormUserTreeSelect(props, inputRef) {
9
10
  const parent = useParentForm(props.$widget);
10
11
  const { className, id, style, events, required, requiredFlag, label, labelVisible, confirmValue, defaultValueType, multiple, size, where, secondDisplay, corpScope, ...restProps } = props;
11
12
  // 强制转换初始值
12
13
  const initRef = useRef(false);
13
14
  const formValue = useMemo(() => {
15
+ const _value = parseStrToArr(props.value);
14
16
  if (initRef.current)
15
- return props.value;
17
+ return _value;
16
18
  initRef.current = true;
17
- return convertSingleValue(props.value, !multiple);
19
+ return convertSingleValue(_value, !multiple);
18
20
  }, [props.value, multiple]);
19
21
  const { value, name, onChange, disabled, layout, readOnly, validateErrorMsg, validateState, visible } = useFormInputTrait({
20
22
  name: restProps.name,
@@ -1,8 +1,9 @@
1
1
  import React from 'react';
2
2
  import './style';
3
+ import type { DataType } from '../../../configs/components/wd-rich-text';
3
4
  declare const _default: React.MemoExoticComponent<typeof RichText>;
4
5
  export default _default;
5
- declare function RichText({ id, style, className, events, label, labelVisible, value, readOnly, layout, disabled, requiredFlag, onChange, decorator, acceptTypes, initialContent, placeholder, iconPack, maxSize, cloudPath, visible, }: {
6
+ declare function RichText({ id, style, className, events, label, labelVisible, value, readOnly, layout, disabled, requiredFlag, onChange, decorator, acceptTypes, initialContent, placeholder, iconPack, maxSize, cloudPath, visible, storageType, }: {
6
7
  id: any;
7
8
  style: any;
8
9
  className?: string;
@@ -23,6 +24,7 @@ declare function RichText({ id, style, className, events, label, labelVisible, v
23
24
  maxSize: any;
24
25
  cloudPath: any;
25
26
  visible: any;
27
+ storageType?: string;
26
28
  }): JSX.Element;
27
29
  declare namespace RichText {
28
30
  var whyDidYouRender: boolean;
@@ -57,4 +59,5 @@ export interface WdRichTextProps {
57
59
  maxSize?: number;
58
60
  name?: string;
59
61
  cloudPath?: string;
62
+ storageType?: DataType['storageType'];
60
63
  }
@@ -48,7 +48,7 @@ id, style, className = '', events,
48
48
  label, labelVisible, value, readOnly, layout, disabled, requiredFlag, onChange, decorator = undefined, acceptTypes,
49
49
  // acceptAudioTypes,
50
50
  // acceptVideoTypes,
51
- initialContent, placeholder, iconPack, maxSize, cloudPath, visible, }) {
51
+ initialContent, placeholder, iconPack, maxSize, cloudPath, visible, storageType = 'cloudID', }) {
52
52
  var _a, _b, _c, _d, _e, _f, _g, _h, _j;
53
53
  const platform = usePlatform();
54
54
  const isH5 = platform === 'h5';
@@ -109,24 +109,24 @@ initialContent, placeholder, iconPack, maxSize, cloudPath, visible, }) {
109
109
  return true;
110
110
  };
111
111
  const upload = async (file) => {
112
- var _a, _b, _c, _d, _e;
112
+ var _a, _b, _c, _d, _e, _f;
113
113
  const tcb = await ((_b = (_a = window === null || window === void 0 ? void 0 : window.app) === null || _a === void 0 ? void 0 : _a.cloud) === null || _b === void 0 ? void 0 : _b.getCloudInstance());
114
114
  try {
115
115
  const fileType = (_e = (_d = (_c = file === null || file === void 0 ? void 0 : file.name) === null || _c === void 0 ? void 0 : _c.split('.')) === null || _d === void 0 ? void 0 : _d.pop()) === null || _e === void 0 ? void 0 : _e.toLowerCase();
116
116
  const _uploadPath = getDefaultUploadPath(cloudPath);
117
117
  const path = `${_uploadPath}/uploader-${uuidv4()}.${fileType}`;
118
- const { fileID } = await tcb.uploadFile({
118
+ const res = await tcb.uploadFile({
119
119
  cloudPath: path,
120
120
  filePath: file,
121
121
  });
122
- setCurrentMap({ ...cloudRef.current.cloudToHttpsMap, [fileID]: '' });
123
- const src = await getTempFileURL(fileID);
124
- src && (cloudRef.current.cloudToHttpsMap[fileID] = src);
122
+ const { fileID, download_url } = res;
123
+ const url = (_f = download_url === null || download_url === void 0 ? void 0 : download_url.split('?')) === null || _f === void 0 ? void 0 : _f[0];
124
+ cloudRef.current.cloudToHttpsMap[fileID] = url;
125
125
  setCurrentMap(cloudRef.current.cloudToHttpsMap);
126
126
  if (!ref.current.editor.hasFocus()) {
127
127
  ref.current.editor.focus();
128
128
  }
129
- return src;
129
+ return url;
130
130
  }
131
131
  catch (e) {
132
132
  errorHandler({
@@ -251,12 +251,14 @@ initialContent, placeholder, iconPack, maxSize, cloudPath, visible, }) {
251
251
  var _a;
252
252
  setCurrentCursor(((_a = editor.selection()) === null || _a === void 0 ? void 0 : _a.from) || 0);
253
253
  let html = editor.getHTML();
254
- const map = cloudRef.current.cloudToHttpsMap || {};
255
- Object.keys(map).forEach((key) => {
256
- if (map[key]) {
257
- html = html.replaceAll(`${map[key]}`.replaceAll('&', '&amp;'), `${key}`);
258
- }
259
- });
254
+ if (storageType !== 'https') {
255
+ const map = cloudRef.current.cloudToHttpsMap || {};
256
+ Object.keys(map).forEach((key) => {
257
+ if (map[key]) {
258
+ html = html.replaceAll(`${map[key]}`.replaceAll('&', '&amp;'), `${key}`);
259
+ }
260
+ });
261
+ }
260
262
  onDataChange(html);
261
263
  if (html.length > 262144) {
262
264
  console.warn('富文本长度过长,可能导致保存失败,当前', html.length);
@@ -273,7 +275,7 @@ initialContent, placeholder, iconPack, maxSize, cloudPath, visible, }) {
273
275
  };
274
276
  }
275
277
  // eslint-disable-next-line react-hooks/exhaustive-deps
276
- }, [window === null || window === void 0 ? void 0 : window.ExEditor3, toolbar]);
278
+ }, [window === null || window === void 0 ? void 0 : window.ExEditor3, toolbar, storageType]);
277
279
  React.useEffect(() => {
278
280
  if (ref.current.editor) {
279
281
  if (readOnly || disabled) {
@@ -2,7 +2,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import * as React from 'react';
3
3
  import { UploadFilePc } from '../form/uploaderFile/uploadFile.pc';
4
4
  import { UploadFileH5 } from '../form/uploaderFile/uploadFile.h5';
5
- import { filterStrList, isCloudFileID, downloadFile, usePlatform, transFileCloudidToName, } from '../../utils/platform';
5
+ import { filterStrList, isCloudFileID, isHttpFileID, downloadFile, usePlatform, transFileCloudidToName, } from '../../utils/platform';
6
6
  import { useTempUrl } from '../../utils/hooks/use-cloud-id-temp-url';
7
7
  import './style';
8
8
  const CLASS_PREFIX = 'weda-uploader-file-view';
@@ -28,7 +28,7 @@ export default function UploaderFileView(props) {
28
28
  value: fileIDList,
29
29
  isEdit: false,
30
30
  };
31
- return showTypeMix === 'pc' ? (_jsx(UploadFilePc, { ...uploadFileProps })) : (_jsx(UploadFileH5, { ...uploadFileProps }));
31
+ return showTypeMix === 'pc' ? _jsx(UploadFilePc, { ...uploadFileProps }) : _jsx(UploadFileH5, { ...uploadFileProps });
32
32
  }
33
33
  }
34
34
  /**
@@ -37,7 +37,7 @@ export default function UploaderFileView(props) {
37
37
  const FileView = ({ fileID }) => {
38
38
  const { data: src } = useTempUrl(fileID);
39
39
  const title = React.useMemo(() => {
40
- if (isCloudFileID(fileID)) {
40
+ if (isCloudFileID(fileID) || isHttpFileID(fileID)) {
41
41
  return transFileCloudidToName(fileID);
42
42
  }
43
43
  else {
@@ -4,6 +4,7 @@ import { useHandleClear } from '../../utils/hooks/useFormLegacy';
4
4
  import { useFormInputTrait } from '../../components/form-input-hooks';
5
5
  import { WdFormItem, WdInputGroup, WdInputWrap } from '../wd-form-item';
6
6
  import UserTreeSelect from '../form/userOrgSelect/component/user-select-h5';
7
+ import { parseStrToArr } from '../form/userOrgSelect/common/utils';
7
8
  import { emptyObject } from '../../utils/constant';
8
9
  import { RecycleProvider } from '../../utils/hooks/useRecycle';
9
10
  import { convertSingleValue } from '../../utils/tool';
@@ -14,10 +15,11 @@ export const WdMember = forwardRef(function WdMember(props, ref) {
14
15
  // 强制转换初始值
15
16
  const initRef = useRef(false);
16
17
  const formValue = useMemo(() => {
18
+ const _value = parseStrToArr(props.value);
17
19
  if (initRef.current)
18
- return props.value;
20
+ return _value;
19
21
  initRef.current = true;
20
- return convertSingleValue(props.value, !multiple);
22
+ return convertSingleValue(_value, !multiple);
21
23
  }, [props.value, multiple]);
22
24
  const traitProps = { ...props, value: formValue, inputRef: ref };
23
25
  const trait = useFormInputTrait(traitProps);
@@ -10,7 +10,7 @@ import './style';
10
10
  * 富文本-标准化
11
11
  */
12
12
  export const WdRichText = forwardRef(function WdRichText(props, ref) {
13
- const { classRoot = 'rich-text', events = emptyObject, acceptTypes = ['image/*'], maxSize = 20 } = props;
13
+ const { classRoot = 'rich-text', events = emptyObject, acceptTypes = ['image/*'], maxSize = 20, storageType = 'cloudID', } = props;
14
14
  const trait = useFormInputTrait({ ...props, inputRef: ref });
15
15
  const { value, disabled, readOnly, visible } = trait;
16
16
  const formItemProps = {
@@ -26,5 +26,5 @@ export const WdRichText = forwardRef(function WdRichText(props, ref) {
26
26
  };
27
27
  if (!visible)
28
28
  return null;
29
- return (_jsx(WdFormItem, { ...formItemProps, children: _jsx(RichText, { placeholder: true, events: events, acceptTypes: acceptTypes, maxSize: maxSize, readOnly: readOnly, disabled: disabled, value: value, decorator: null, onChange: onChange, id: props.id }) }));
29
+ return (_jsx(WdFormItem, { ...formItemProps, children: _jsx(RichText, { placeholder: true, events: events, acceptTypes: acceptTypes, maxSize: maxSize, readOnly: readOnly, disabled: disabled, value: value, decorator: null, onChange: onChange, id: props.id, storageType: storageType }) }));
30
30
  });
@@ -12,7 +12,7 @@ import './style';
12
12
  * 文件上传-标准化
13
13
  */
14
14
  export const WdUploadFile = forwardRef(function WdUploadFile(props, ref) {
15
- const { classRoot = 'upload-file', acceptTypes: _acceptTypes = X_RUNTIME_DEFAULT._acceptTypesInFile, maxSize = X_RUNTIME_DEFAULT.maxSize, single = X_RUNTIME_DEFAULT.single, maxUploadCount = X_RUNTIME_DEFAULT.maxUploadCount, events = emptyObject, deleteVisible = X_RUNTIME_DEFAULT.deleteVisible, downloadVisible = X_RUNTIME_DEFAULT.downloadVisible, callbacks, uploadButtonText = X_RUNTIME_DEFAULT._uploadButtonText, uploadTipText = X_RUNTIME_DEFAULT._uploadTipText, } = props;
15
+ const { classRoot = 'upload-file', acceptTypes: _acceptTypes = X_RUNTIME_DEFAULT._acceptTypesInFile, maxSize = X_RUNTIME_DEFAULT.maxSize, single = X_RUNTIME_DEFAULT.single, maxUploadCount = X_RUNTIME_DEFAULT.maxUploadCount, events = emptyObject, deleteVisible = X_RUNTIME_DEFAULT.deleteVisible, downloadVisible = X_RUNTIME_DEFAULT.downloadVisible, callbacks, uploadButtonText = X_RUNTIME_DEFAULT._uploadButtonText, uploadTipText = X_RUNTIME_DEFAULT._uploadTipText, storageType = 'cloudID', } = props;
16
16
  const acceptTypes = useMemo(() => convertAcceptTypes(_acceptTypes), [_acceptTypes]);
17
17
  // 强制转换初始值
18
18
  const initRef = useRef(false);
@@ -34,5 +34,5 @@ export const WdUploadFile = forwardRef(function WdUploadFile(props, ref) {
34
34
  };
35
35
  if (!visible)
36
36
  return null;
37
- return (_jsx(WdFormItem, { ...formItemProps, children: _jsx(UploaderFile, { btnTitle: uploadButtonText, uploadTipText: uploadTipText, events: events, labelVisible: false, acceptTypes: acceptTypes, defaultValue: value, deleteVisible: deleteVisible, downloadVisible: downloadVisible, maxSize: maxSize, maxUploadCount: maxUploadCount, single: single, readOnly: readOnly, disabled: disabled, decorator: null, onChange: onChange, callbacks: callbacks }) }));
37
+ return (_jsx(WdFormItem, { ...formItemProps, children: _jsx(UploaderFile, { btnTitle: uploadButtonText, uploadTipText: uploadTipText, events: events, labelVisible: false, acceptTypes: acceptTypes, defaultValue: value, deleteVisible: deleteVisible, downloadVisible: downloadVisible, maxSize: maxSize, maxUploadCount: maxUploadCount, single: single, readOnly: readOnly, disabled: disabled, decorator: null, onChange: onChange, callbacks: callbacks, storageType: storageType }) }));
38
38
  });
@@ -15,7 +15,7 @@ import { Upload } from '../form/uploader/upload/index';
15
15
  export const WdUploadImage = forwardRef(function WdUploadImage(props, ref) {
16
16
  const { classRoot = 'upload-image', showShape = X_RUNTIME_DEFAULT.showShape, acceptTypes = X_RUNTIME_DEFAULT.acceptTypes, maxSize = X_RUNTIME_DEFAULT.maxSize, single = X_RUNTIME_DEFAULT.single, maxUploadCount = X_RUNTIME_DEFAULT.maxUploadCount, events = emptyObject, isCompressBeforeUpload = false,
17
17
  // eslint-disable-next-line @typescript-eslint/no-magic-numbers
18
- compressQuality = 70, compressedHeight = 0, compressedWidth = 0, sourceType = 'both', tips, callbacks, template = 'normal', children, } = props;
18
+ compressQuality = 70, compressedHeight = 0, compressedWidth = 0, sourceType = 'both', tips, callbacks, template = 'normal', children, storageType = 'cloudID', } = props;
19
19
  // 强制转换初始值
20
20
  const initRef = useRef(false);
21
21
  const uploadRef = useRef(null);
@@ -44,5 +44,5 @@ export const WdUploadImage = forwardRef(function WdUploadImage(props, ref) {
44
44
  const multiple = !single;
45
45
  if (!visible)
46
46
  return null;
47
- return (_jsx(WdFormItem, { ...formItemProps, children: template === 'custom' ? (_jsx(Upload, { events: events, acceptTypes: acceptTypes, maxSize: maxSize, maxUploadCount: maxUploadCount, readOnly: readOnly, disabled: disabled, isCompressBeforeUpload: isCompressBeforeUpload, compressQuality: compressQuality, compressedHeight: compressedHeight, compressedWidth: compressedWidth, callbacks: callbacks, value: value, multiple: multiple, sourceType: sourceType, onChange: onChange, ref: uploadRef, setUploadHandle: setUploadHandle, children: children })) : (_jsx(Uploader, { events: events, labelVisible: false, acceptTypes: acceptTypes, defaultValue: value, maxSize: maxSize, maxUploadCount: maxUploadCount, single: single, tips: tips, showShape: showShape, readOnly: readOnly, disabled: disabled, decorator: null, onChange: onChange, isCompressBeforeUpload: isCompressBeforeUpload, compressQuality: compressQuality, compressedHeight: compressedHeight, compressedWidth: compressedWidth, sourceType: sourceType, callbacks: callbacks, setUploadHandle: setUploadHandle })) }));
47
+ return (_jsx(WdFormItem, { ...formItemProps, children: template === 'custom' ? (_jsx(Upload, { events: events, acceptTypes: acceptTypes, maxSize: maxSize, maxUploadCount: maxUploadCount, readOnly: readOnly, disabled: disabled, isCompressBeforeUpload: isCompressBeforeUpload, compressQuality: compressQuality, compressedHeight: compressedHeight, compressedWidth: compressedWidth, callbacks: callbacks, value: value, multiple: multiple, sourceType: sourceType, onChange: onChange, ref: uploadRef, setUploadHandle: setUploadHandle, storageType: storageType, children: children })) : (_jsx(Uploader, { events: events, labelVisible: false, acceptTypes: acceptTypes, defaultValue: value, maxSize: maxSize, maxUploadCount: maxUploadCount, single: single, tips: tips, showShape: showShape, readOnly: readOnly, disabled: disabled, decorator: null, onChange: onChange, isCompressBeforeUpload: isCompressBeforeUpload, compressQuality: compressQuality, compressedHeight: compressedHeight, compressedWidth: compressedWidth, sourceType: sourceType, callbacks: callbacks, setUploadHandle: setUploadHandle, storageType: storageType })) }));
48
48
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cloudbase/weda-ui",
3
- "version": "3.20.2",
3
+ "version": "3.20.3",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index",
6
6
  "miniprogram": "mpdist",
@@ -149,7 +149,7 @@
149
149
  "@babel/preset-typescript": "^7.22.15",
150
150
  "@cloudbase/cals": "^1.2.15",
151
151
  "@cloudbase/lowcode-cli": "^0.22.3",
152
- "@cloudbase/weda-cloud-sdk": "^1.0.104",
152
+ "@cloudbase/weda-cloud-sdk": "^1.0.106",
153
153
  "@commitlint/cli": "^16.0.2",
154
154
  "@commitlint/config-conventional": "^17.7.0",
155
155
  "@craco/craco": "^7.1.0",