ronds-metadata 1.3.37 → 1.3.39

Sign up to get free protection for your applications and to get access to all the features.
Files changed (30) hide show
  1. package/es/comps/DynamicPorts/comps/NodeElementForm.js +5 -4
  2. package/es/comps/DynamicPorts/comps/NodeElementNormal.js +5 -4
  3. package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Checkbox.js +3 -2
  4. package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Color.js +2 -1
  5. package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Date.js +3 -2
  6. package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Input.js +3 -2
  7. package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/MutiSelect.js +4 -3
  8. package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Number.js +3 -2
  9. package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/NumberRange.js +1 -1
  10. package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Password.js +3 -2
  11. package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Radio.js +3 -2
  12. package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Select.js +4 -3
  13. package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/TextArea.js +4 -3
  14. package/es/comps/FormGenerator/comps/Canvas/core/index.js +3 -2
  15. package/es/comps/FormGenerator/comps/Canvas/index.js +7 -6
  16. package/es/comps/FormGenerator/comps/Settings/index.js +3 -2
  17. package/es/comps/FormGenerator/comps/Sidebar/Elements.js +4 -2
  18. package/es/comps/FormGenerator/comps/Sidebar/index.js +3 -2
  19. package/es/comps/FormGenerator/settings/index.js +33 -32
  20. package/es/comps/FormGenerator/settings/ruleConfig.js +47 -46
  21. package/es/comps/MetadataForm/DataCell/Array.js +3 -3
  22. package/es/comps/MetadataForm/DataCell/Input.js +3 -3
  23. package/es/comps/MetadataForm/DataCell/Number.js +16 -16
  24. package/es/comps/MetadataForm/DataCell/Ref.js +12 -12
  25. package/es/comps/MetadataForm/DataCell/Select.js +19 -19
  26. package/es/comps/MetadataForm/DataCell/Switch.js +12 -12
  27. package/es/comps/MetadataForm/DataCell/layout/TableArray.js +3 -2
  28. package/es/comps/locales/en-US.d.ts +118 -0
  29. package/es/comps/locales/en-US.js +120 -2
  30. package/package.json +3 -1
@@ -8,7 +8,7 @@ import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
8
8
  /*
9
9
  * @Author: wangxian
10
10
  * @Date: 2021-09-18 14:15:04
11
- * @LastEditTime: 2024-02-27 09:45:28
11
+ * @LastEditTime: 2024-04-17 13:42:03
12
12
  */
13
13
  import React from 'react';
14
14
  import { MetadataFormContext, MetadataRefContext } from '../interface';
@@ -37,7 +37,7 @@ function Index(props) {
37
37
  var _ = _rules.map(function (it) {
38
38
  return {
39
39
  pattern: new RegExp(eval(it === null || it === void 0 ? void 0 : it.regExp), 'g'),
40
- message: it.message
40
+ message: tr(it.message)
41
41
  };
42
42
  });
43
43
  setRules(_toConsumableArray(_));
@@ -55,7 +55,7 @@ function Index(props) {
55
55
  style: (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.color) ? {
56
56
  color: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.color
57
57
  } : {}
58
- }, (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id),
58
+ }, tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id),
59
59
  labelCol: labelSpan && (formContext === null || formContext === void 0 ? void 0 : formContext.layout) === 'horizontal' ? {
60
60
  flex: "0 0 ".concat(labelSpan * 100 / 24, "%"),
61
61
  offset: 0
@@ -69,13 +69,13 @@ function Index(props) {
69
69
  } : undefined,
70
70
  rules: [{
71
71
  required: notRequire ? !notRequire : extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.require,
72
- message: "".concat(tr('请输入')).concat((extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
72
+ message: "".concat(tr('请输入'), " ").concat(tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
73
73
  }].concat(_toConsumableArray(rules)),
74
- help: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help,
75
- tooltip: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip
74
+ help: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help),
75
+ tooltip: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip)
76
76
  }), /*#__PURE__*/React.createElement(_InputNumber, {
77
77
  disabled: (_extraInfo$disabled = extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.disabled) !== null && _extraInfo$disabled !== void 0 ? _extraInfo$disabled : disabled,
78
- placeholder: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder
78
+ placeholder: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder)
79
79
  }));
80
80
  }
81
81
  return !field ? /*#__PURE__*/React.createElement(_Form.Item, {
@@ -88,7 +88,7 @@ function Index(props) {
88
88
  style: (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.color) ? {
89
89
  color: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.color
90
90
  } : {}
91
- }, (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id),
91
+ }, tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id),
92
92
  labelCol: labelSpan && (formContext === null || formContext === void 0 ? void 0 : formContext.layout) === 'horizontal' ? {
93
93
  flex: "0 0 ".concat(labelSpan * 100 / 24, "%"),
94
94
  offset: 0
@@ -103,13 +103,13 @@ function Index(props) {
103
103
  name: name,
104
104
  rules: [{
105
105
  required: notRequire ? !notRequire : extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.require,
106
- message: "".concat(tr('请输入')).concat((extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
106
+ message: "".concat(tr('请输入'), " ").concat(tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
107
107
  }].concat(_toConsumableArray(rules)),
108
- help: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help,
109
- tooltip: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip
108
+ help: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help),
109
+ tooltip: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip)
110
110
  }, /*#__PURE__*/React.createElement(_InputNumber, {
111
111
  disabled: (_extraInfo$disabled2 = extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.disabled) !== null && _extraInfo$disabled2 !== void 0 ? _extraInfo$disabled2 : disabled,
112
- placeholder: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder
112
+ placeholder: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder)
113
113
  })) : /*#__PURE__*/React.createElement(_Form.Item, _extends({}, field, {
114
114
  style: {
115
115
  flex: 1,
@@ -118,13 +118,13 @@ function Index(props) {
118
118
  name: [field === null || field === void 0 ? void 0 : field.name],
119
119
  rules: [{
120
120
  required: notRequire ? !notRequire : extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.require,
121
- message: "".concat(tr('请输入')).concat((extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
121
+ message: "".concat(tr('请输入'), " ").concat(tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
122
122
  }].concat(_toConsumableArray(rules)),
123
- help: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help,
124
- tooltip: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip
123
+ help: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help),
124
+ tooltip: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip)
125
125
  }), /*#__PURE__*/React.createElement(_InputNumber, {
126
126
  disabled: (_extraInfo$disabled3 = extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.disabled) !== null && _extraInfo$disabled3 !== void 0 ? _extraInfo$disabled3 : disabled,
127
- placeholder: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder
127
+ placeholder: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder)
128
128
  }));
129
129
  }
130
130
  export default /*#__PURE__*/React.memo(Index);
@@ -194,7 +194,7 @@ function Index(props) {
194
194
  }
195
195
  }, /*#__PURE__*/React.createElement("label", {
196
196
  className: "".concat((extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.require) && 'ant-form-item-required')
197
- }, (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || fieldRule && ((_fieldRule$ = fieldRule[0]) === null || _fieldRule$ === void 0 ? void 0 : (_fieldRule$$value = _fieldRule$.value) === null || _fieldRule$$value === void 0 ? void 0 : _fieldRule$$value.label) || fieldRule && ((_fieldRule$2 = fieldRule[0]) === null || _fieldRule$2 === void 0 ? void 0 : (_fieldRule$2$value = _fieldRule$2.value) === null || _fieldRule$2$value === void 0 ? void 0 : (_fieldRule$2$value$co = _fieldRule$2$value.common) === null || _fieldRule$2$value$co === void 0 ? void 0 : _fieldRule$2$value$co.label) || id)), formContext.isFoldForm && /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(_Button, {
197
+ }, tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || fieldRule && tr((_fieldRule$ = fieldRule[0]) === null || _fieldRule$ === void 0 ? void 0 : (_fieldRule$$value = _fieldRule$.value) === null || _fieldRule$$value === void 0 ? void 0 : _fieldRule$$value.label) || fieldRule && tr((_fieldRule$2 = fieldRule[0]) === null || _fieldRule$2 === void 0 ? void 0 : (_fieldRule$2$value = _fieldRule$2.value) === null || _fieldRule$2$value === void 0 ? void 0 : (_fieldRule$2$value$co = _fieldRule$2$value.common) === null || _fieldRule$2$value$co === void 0 ? void 0 : _fieldRule$2$value$co.label) || id)), formContext.isFoldForm && /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(_Button, {
198
198
  type: "link",
199
199
  onClick: function onClick() {
200
200
  setIsFold(!isFold);
@@ -233,7 +233,7 @@ function Index(props) {
233
233
  }
234
234
  return !field ? /*#__PURE__*/React.createElement(_Form.Item, {
235
235
  key: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.defaultValue,
236
- label: (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id,
236
+ label: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id,
237
237
  labelCol: labelSpan && (formContext === null || formContext === void 0 ? void 0 : formContext.layout) === 'horizontal' ? {
238
238
  flex: "0 0 ".concat(labelSpan * 100 / 24, "%"),
239
239
  offset: 0
@@ -249,16 +249,16 @@ function Index(props) {
249
249
  name: id,
250
250
  rules: [{
251
251
  required: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.require,
252
- message: "".concat(tr('请输入')).concat((extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
252
+ message: "".concat(tr('请输入'), " ").concat(tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
253
253
  }],
254
- help: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help,
255
- tooltip: (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip) || help
254
+ help: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help),
255
+ tooltip: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip) || tr(help)
256
256
  }, /*#__PURE__*/React.createElement(_Select, {
257
257
  showSearch: true,
258
258
  options: options || [],
259
- placeholder: extraInfo.placeholder,
259
+ placeholder: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder),
260
260
  disabled: (_extraInfo$disabled = extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.disabled) !== null && _extraInfo$disabled !== void 0 ? _extraInfo$disabled : disabled,
261
- notFoundContent: '没有批到到该实体数据',
261
+ notFoundContent: tr('没有匹配到该实体数据'),
262
262
  filterOption: function filterOption(input, option) {
263
263
  return (option === null || option === void 0 ? void 0 : option.label.indexOf(input)) >= 0;
264
264
  },
@@ -272,19 +272,19 @@ function Index(props) {
272
272
  name: [field === null || field === void 0 ? void 0 : field.name],
273
273
  rules: [{
274
274
  required: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.require,
275
- message: "".concat(tr('请输入')).concat((extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
275
+ message: "".concat(tr('请输入'), " ").concat(tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
276
276
  }],
277
- help: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help,
278
- tooltip: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip
277
+ help: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help),
278
+ tooltip: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip)
279
279
  }), /*#__PURE__*/React.createElement(_Select, {
280
280
  showSearch: true,
281
281
  style: {
282
282
  width: '100%'
283
283
  },
284
284
  options: options || [],
285
- placeholder: extraInfo.placeholder,
285
+ placeholder: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder),
286
286
  disabled: (_extraInfo$disabled2 = extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.disabled) !== null && _extraInfo$disabled2 !== void 0 ? _extraInfo$disabled2 : disabled,
287
- notFoundContent: '没有批到到该实体数据',
287
+ notFoundContent: tr('没有匹配到该实体数据'),
288
288
  filterOption: function filterOption(input, option) {
289
289
  return (option === null || option === void 0 ? void 0 : option.label.indexOf(input)) >= 0;
290
290
  },
@@ -37,7 +37,7 @@ import _regeneratorRuntime from "@babel/runtime/regenerator";
37
37
  /*
38
38
  * @Author:wangxian
39
39
  * @Date: 2021-09-18 14:15:04
40
- * @LastEditTime: 2024-02-26 10:27:57
40
+ * @LastEditTime: 2024-04-17 09:50:12
41
41
  */
42
42
  import React from 'react';
43
43
  import { MetadataFormContext, MetadataRefContext } from '../interface';
@@ -444,10 +444,10 @@ function Index(props) {
444
444
  labelInValue: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.labelInValue,
445
445
  allowClear: true,
446
446
  disabled: (_extraInfo$disabled2 = extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.disabled) !== null && _extraInfo$disabled2 !== void 0 ? _extraInfo$disabled2 : disabled,
447
- placeholder: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder,
447
+ placeholder: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder),
448
448
  maxTagCount: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.maxTagCount,
449
449
  maxTagTextLength: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.maxTagTextLength,
450
- maxTagPlaceholder: (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.maxTagPlaceholder) || maxTagPlaceholder
450
+ maxTagPlaceholder: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.maxTagPlaceholder) || maxTagPlaceholder
451
451
  });
452
452
  } else if (isPagination) {
453
453
  var _extraInfo$disabled3;
@@ -455,7 +455,7 @@ function Index(props) {
455
455
  mode: (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.isMutiple) ? 'multiple' : extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.mode,
456
456
  onSelect: onSelect,
457
457
  disabled: (_extraInfo$disabled3 = extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.disabled) !== null && _extraInfo$disabled3 !== void 0 ? _extraInfo$disabled3 : disabled,
458
- placeholder: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder,
458
+ placeholder: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder),
459
459
  options: httpOptions && httpOptions.length > 0 ? httpOptions : options,
460
460
  dropdownRender: function dropdownRender(menu) {
461
461
  return /*#__PURE__*/React.createElement(React.Fragment, null, menu, /*#__PURE__*/React.createElement(_Divider, {
@@ -496,7 +496,7 @@ function Index(props) {
496
496
  span: extraInfo === null || extraInfo === void 0 ? void 0 : (_extraInfo$checkbox = extraInfo.checkbox) === null || _extraInfo$checkbox === void 0 ? void 0 : _extraInfo$checkbox.colSpan
497
497
  }, /*#__PURE__*/React.createElement(_Checkbox, {
498
498
  value: it.value
499
- }, it.label));
499
+ }, tr(it.label)));
500
500
  }))) : /*#__PURE__*/React.createElement(_Radio.Group, {
501
501
  style: {
502
502
  width: '100%'
@@ -508,7 +508,7 @@ function Index(props) {
508
508
  span: extraInfo === null || extraInfo === void 0 ? void 0 : (_extraInfo$checkbox2 = extraInfo.checkbox) === null || _extraInfo$checkbox2 === void 0 ? void 0 : _extraInfo$checkbox2.colSpan
509
509
  }, /*#__PURE__*/React.createElement(_Radio, {
510
510
  value: it.value
511
- }, it.label));
511
+ }, tr(it.label)));
512
512
  })));
513
513
  } else {
514
514
  var _extraInfo$disabled4;
@@ -516,7 +516,7 @@ function Index(props) {
516
516
  mode: (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.isMutiple) ? 'multiple' : extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.mode,
517
517
  onSelect: onSelect,
518
518
  disabled: (_extraInfo$disabled4 = extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.disabled) !== null && _extraInfo$disabled4 !== void 0 ? _extraInfo$disabled4 : disabled,
519
- placeholder: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder,
519
+ placeholder: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.placeholder),
520
520
  options: myOptions,
521
521
  showSearch: true,
522
522
  filterOption: function filterOption(input, option) {
@@ -531,7 +531,7 @@ function Index(props) {
531
531
  labelInValue: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.labelInValue,
532
532
  maxTagCount: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.maxTagCount,
533
533
  maxTagTextLength: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.maxTagTextLength,
534
- maxTagPlaceholder: (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.maxTagPlaceholder) || maxTagPlaceholder
534
+ maxTagPlaceholder: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.maxTagPlaceholder) || maxTagPlaceholder
535
535
  });
536
536
  }
537
537
  };
@@ -546,7 +546,7 @@ function Index(props) {
546
546
  style: (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.color) ? {
547
547
  color: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.color
548
548
  } : {}
549
- }, (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id),
549
+ }, tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id),
550
550
  labelCol: labelSpan && (formContext === null || formContext === void 0 ? void 0 : formContext.layout) === 'horizontal' ? {
551
551
  flex: "0 0 ".concat(labelSpan * 100 / 24, "%"),
552
552
  offset: 0
@@ -561,10 +561,10 @@ function Index(props) {
561
561
  name: [field === null || field === void 0 ? void 0 : field.name].concat(_toConsumableArray(name)),
562
562
  rules: [{
563
563
  required: notRequire ? !notRequire : extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.require,
564
- message: "".concat(tr('请输入')).concat((extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
564
+ message: "".concat(tr('请输入'), " ").concat(tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
565
565
  }],
566
- help: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help,
567
- tooltip: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip
566
+ help: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help),
567
+ tooltip: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip)
568
568
  }), processSelectType((_extraInfo$http8 = extraInfo.http) === null || _extraInfo$http8 === void 0 ? void 0 : _extraInfo$http8.isCascader, (_extraInfo$http9 = extraInfo.http) === null || _extraInfo$http9 === void 0 ? void 0 : _extraInfo$http9.isTreeSelect, (_extraInfo$http10 = extraInfo.http) === null || _extraInfo$http10 === void 0 ? void 0 : _extraInfo$http10.isPagination));
569
569
  }
570
570
  return !field ? /*#__PURE__*/React.createElement(_Form.Item, {
@@ -577,7 +577,7 @@ function Index(props) {
577
577
  style: (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.color) ? {
578
578
  color: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.color
579
579
  } : {}
580
- }, (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id),
580
+ }, tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id),
581
581
  labelCol: labelSpan && (formContext === null || formContext === void 0 ? void 0 : formContext.layout) === 'horizontal' ? {
582
582
  flex: "0 0 ".concat(labelSpan * 100 / 24, "%"),
583
583
  offset: 0
@@ -592,10 +592,10 @@ function Index(props) {
592
592
  name: name,
593
593
  rules: [{
594
594
  required: notRequire ? !notRequire : extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.require,
595
- message: "".concat(tr('请输入')).concat((extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
595
+ message: "".concat(tr('请输入'), " ").concat(tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
596
596
  }],
597
- help: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help,
598
- tooltip: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip
597
+ help: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help),
598
+ tooltip: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip)
599
599
  }, processSelectType((_extraInfo$http11 = extraInfo.http) === null || _extraInfo$http11 === void 0 ? void 0 : _extraInfo$http11.isCascader, (_extraInfo$http12 = extraInfo.http) === null || _extraInfo$http12 === void 0 ? void 0 : _extraInfo$http12.isTreeSelect, (_extraInfo$http13 = extraInfo.http) === null || _extraInfo$http13 === void 0 ? void 0 : _extraInfo$http13.isPagination)) : /*#__PURE__*/React.createElement(_Form.Item, _extends({}, field, {
600
600
  style: {
601
601
  flex: 1,
@@ -604,10 +604,10 @@ function Index(props) {
604
604
  name: [field === null || field === void 0 ? void 0 : field.name],
605
605
  rules: [{
606
606
  required: notRequire ? !notRequire : extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.require,
607
- message: "".concat(tr('请输入')).concat((extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
607
+ message: "".concat(tr('请输入'), " ").concat(tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
608
608
  }],
609
- help: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help,
610
- tooltip: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip
609
+ help: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help),
610
+ tooltip: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip)
611
611
  }), processSelectType((_extraInfo$http14 = extraInfo.http) === null || _extraInfo$http14 === void 0 ? void 0 : _extraInfo$http14.isCascader, (_extraInfo$http15 = extraInfo.http) === null || _extraInfo$http15 === void 0 ? void 0 : _extraInfo$http15.isTreeSelect, (_extraInfo$http16 = extraInfo.http) === null || _extraInfo$http16 === void 0 ? void 0 : _extraInfo$http16.isPagination));
612
612
  }
613
613
  export default /*#__PURE__*/React.memo(Index);
@@ -7,7 +7,7 @@ import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray";
7
7
  /*
8
8
  * @Author: wangxian
9
9
  * @Date: 2021-09-18 14:15:04
10
- * @LastEditTime: 2024-02-27 09:47:00
10
+ * @LastEditTime: 2024-04-17 09:52:06
11
11
  */
12
12
  import React from 'react';
13
13
  import { MetadataFormContext, MetadataRefContext } from '../interface';
@@ -37,7 +37,7 @@ function Index(props) {
37
37
  style: (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.color) ? {
38
38
  color: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.color
39
39
  } : {}
40
- }, (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id),
40
+ }, tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id),
41
41
  labelCol: labelSpan && (formContext === null || formContext === void 0 ? void 0 : formContext.layout) === 'horizontal' ? {
42
42
  span: labelSpan,
43
43
  offset: 0
@@ -53,10 +53,10 @@ function Index(props) {
53
53
  valuePropName: "checked",
54
54
  rules: [{
55
55
  required: notRequire ? !notRequire : extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.require,
56
- message: "".concat(tr('请输入')).concat((extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
56
+ message: "".concat(tr('请输入'), " ").concat(tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
57
57
  }],
58
- help: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help,
59
- tooltip: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip
58
+ help: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help),
59
+ tooltip: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip)
60
60
  }), /*#__PURE__*/React.createElement(_Switch, {
61
61
  disabled: (_extraInfo$disabled = extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.disabled) !== null && _extraInfo$disabled !== void 0 ? _extraInfo$disabled : disabled,
62
62
  checkedChildren: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.checkedChildren,
@@ -68,7 +68,7 @@ function Index(props) {
68
68
  style: (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.color) ? {
69
69
  color: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.color
70
70
  } : {}
71
- }, (extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id),
71
+ }, tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id),
72
72
  labelCol: labelSpan && (formContext === null || formContext === void 0 ? void 0 : formContext.layout) === 'horizontal' ? {
73
73
  flex: "0 0 ".concat(labelSpan * 100 / 24, "%"),
74
74
  offset: 0
@@ -89,10 +89,10 @@ function Index(props) {
89
89
  valuePropName: "checked",
90
90
  rules: [{
91
91
  required: notRequire ? !notRequire : extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.require,
92
- message: "".concat(tr('请输入')).concat((extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
92
+ message: "".concat(tr('请输入'), " ").concat(tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
93
93
  }],
94
- help: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help,
95
- tooltip: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip
94
+ help: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help),
95
+ tooltip: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip)
96
96
  }, /*#__PURE__*/React.createElement(_Switch, {
97
97
  disabled: (_extraInfo$disabled2 = extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.disabled) !== null && _extraInfo$disabled2 !== void 0 ? _extraInfo$disabled2 : disabled,
98
98
  checkedChildren: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.checkedChildren,
@@ -106,10 +106,10 @@ function Index(props) {
106
106
  valuePropName: "checked",
107
107
  rules: [{
108
108
  required: notRequire ? !notRequire : extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.require,
109
- message: "".concat(tr('请输入')).concat((extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
109
+ message: "".concat(tr('请输入'), " ").concat(tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.label) || id)
110
110
  }],
111
- help: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help,
112
- tooltip: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip
111
+ help: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.help),
112
+ tooltip: tr(extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.tooltip)
113
113
  }), /*#__PURE__*/React.createElement(_Switch, {
114
114
  disabled: (_extraInfo$disabled3 = extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.disabled) !== null && _extraInfo$disabled3 !== void 0 ? _extraInfo$disabled3 : disabled,
115
115
  checkedChildren: extraInfo === null || extraInfo === void 0 ? void 0 : extraInfo.checkedChildren,
@@ -17,6 +17,7 @@ import { MetadataFormContext } from '../../interface';
17
17
  import { assignReplace, getLabelByProps } from '../../utils';
18
18
  import { deepClone, getConstantValue } from '../../../../utils';
19
19
  import { STREAM_EVENT_TYPE } from '../../constants';
20
+ import { tr } from '../../../../framework/locale';
20
21
  var TableArray = function TableArray(props) {
21
22
  var initValue = props.initValue,
22
23
  readonly = props.readonly,
@@ -239,7 +240,7 @@ var TableArray = function TableArray(props) {
239
240
  }
240
241
  _enum.forEach(function (it) {
241
242
  var obj = {
242
- label: it.value,
243
+ label: tr(it.value),
243
244
  value: (it === null || it === void 0 ? void 0 : it.key) || (it === null || it === void 0 ? void 0 : it.value)
244
245
  };
245
246
  _options.push(obj);
@@ -262,7 +263,7 @@ var TableArray = function TableArray(props) {
262
263
  var it = _properties[i];
263
264
  var extraInfo = refFieldsRef.current.get(it.id);
264
265
  var obj = {
265
- title: getLabelByProps(it),
266
+ title: tr(getLabelByProps(it)),
266
267
  key: it.id,
267
268
  dataIndex: it.id,
268
269
  width: processColumnType(it, extraInfo) === 'buttonCell' ? 25 : 50,
@@ -17,5 +17,123 @@ declare const _default: {
17
17
  实际尺寸: string;
18
18
  适应画布: string;
19
19
  上传: string;
20
+ 请输入: string;
21
+ 没有匹配到该实体数据: string;
22
+ 根据名称检索: string;
23
+ 请填写元数据名称: string;
24
+ 请填写属性名称: string;
25
+ 名称: string;
26
+ 类型: string;
27
+ 数字: string;
28
+ 文本: string;
29
+ 布尔类型: string;
30
+ 枚举类型: string;
31
+ 数组: string;
32
+ 引用类型: string;
33
+ 对象: string;
34
+ 引用: string;
35
+ 表单扩展规则: string;
36
+ 扩展规则: string;
37
+ 规则名称: string;
38
+ 规则类型: string;
39
+ 规则值: string;
40
+ 添加扩展规则: string;
41
+ 属性名称: string;
42
+ 属性类型: string;
43
+ 添加引用类型: string;
44
+ 刷新: string;
45
+ 添加Enum: string;
46
+ 单行文本: string;
47
+ 多行文本: string;
48
+ 日期选择: string;
49
+ 数字输入框: string;
50
+ 开关: string;
51
+ 下拉单选: string;
52
+ 下拉多选: string;
53
+ 颜色选择: string;
54
+ 密码框: string;
55
+ 点击多选: string;
56
+ 点击单选: string;
57
+ 数字区间: string;
58
+ 常规列表: string;
59
+ 表格: string;
60
+ 基础组件: string;
61
+ 高级组件: string;
62
+ 布局组件: string;
63
+ 整体布局: string;
64
+ '\u9ED8\u8BA4\u5E03\u5C40\uFF08\u4E00\u884C\u4E00\u5217\uFF09': string;
65
+ 一行一列: string;
66
+ 一行两列: string;
67
+ 一行三列: string;
68
+ 一行四列: string;
69
+ 标签展示模式: string;
70
+ 同行: string;
71
+ 单独一行: string;
72
+ 标签宽度: string;
73
+ 不填自适应默认宽度: string;
74
+ 表单配置: string;
75
+ '\u5B57\u6BB5\u540D\u79F0\uFF08\u4EC5\u652F\u6301\u82F1\u6587\uFF09': string;
76
+ 标题: string;
77
+ 标题颜色: string;
78
+ 组件布局: string;
79
+ 默认按照整体布局配置排布: string;
80
+ '\u8FD9\u91CC\u586B\u5199\u8868\u5355\u6574\u4F53\u5E03\u5C40\u7684\u500D\u6570\uFF0C\u6700\u5927\u4E00\u884C': string;
81
+ 默认值: string;
82
+ 帮助说明: string;
83
+ 提示说明: string;
84
+ 默认文本: string;
85
+ 是否换行: string;
86
+ 后面字段另起一行: string;
87
+ 是否必填: string;
88
+ 是否禁用: string;
89
+ 是否隐藏: string;
90
+ 隐藏: string;
91
+ 显示: string;
92
+ 非必填: string;
93
+ 只读: string;
94
+ 文本框: string;
95
+ 日期选择框: string;
96
+ 颜色选择框: string;
97
+ 格式化: string;
98
+ 默认高度: string;
99
+ 正则表达式: string;
100
+ 提示信息: string;
101
+ 枚举值: string;
102
+ 动态枚举值: string;
103
+ 通过接口调用获取枚举值: string;
104
+ 请求URL: string;
105
+ 请求方法: string;
106
+ Body参数: string;
107
+ '\u652F\u6301Json\u5B57\u7B26\u4E32\uFF0C\u7CFB\u7EDF\u4F1A\u81EA\u52A8\u5E8F\u5217\u5316': string;
108
+ Key的替换属性: string;
109
+ Vaule的替换属性: string;
110
+ 监听: string;
111
+ '\u76D1\u542C\u591A\u4E2A\u5C5E\u6027\uFF0C\u7528\u82F1\u6587\u9017\u53F7\u9694\u5F00': string;
112
+ 列表联动: string;
113
+ 校验规则: string;
114
+ 高级设置: string;
115
+ 组件: string;
116
+ 组件配置: string;
117
+ 取消预览: string;
118
+ 预览: string;
119
+ 清空: string;
120
+ 已复制到剪切板: string;
121
+ 导出Schema: string;
122
+ 导入: string;
123
+ 提交: string;
124
+ 重置: string;
125
+ 拖拽左侧栏的组件进行添加: string;
126
+ '\u526A\u5207\u677F\u4E3A\u7A7A\uFF0C\u4E0D\u53EF\u7C98\u8D34': string;
127
+ 粘贴成功: string;
128
+ 复制成功: string;
129
+ 批间隔: string;
130
+ 消费策略: string;
131
+ '\u975E\u5FC5\u586B\uFF0C\u9ED8\u8BA4\u5DE5\u4F5C\u6D41id': string;
132
+ 消费者组: string;
133
+ kafka数据源: string;
134
+ 选择数据源: string;
135
+ 选择主题: string;
136
+ 执行活动配置: string;
137
+ 框选: string;
20
138
  };
21
139
  export default _default;
@@ -1,7 +1,7 @@
1
1
  /*
2
2
  * @Author: wangxian
3
3
  * @Date: 2022-05-09 11:53:44
4
- * @LastEditTime: 2024-04-16 16:09:52
4
+ * @LastEditTime: 2024-04-17 15:42:32
5
5
  */
6
6
  export default {
7
7
  操作: 'Operation',
@@ -21,5 +21,123 @@ export default {
21
21
  缩小: 'zoom out',
22
22
  实际尺寸: 'Actual size',
23
23
  适应画布: 'Fit to canvas',
24
- 上传: 'Upload'
24
+ 上传: 'Upload',
25
+ 请输入: 'Please enter',
26
+ 没有匹配到该实体数据: 'No matching entity data',
27
+ 根据名称检索: 'Search by name',
28
+ 请填写元数据名称: 'Please fill in the metadata name',
29
+ 请填写属性名称: 'Please fill in the attribute name',
30
+ 名称: 'Name',
31
+ 类型: 'Type',
32
+ 数字: 'Number',
33
+ 文本: 'Text',
34
+ 布尔类型: 'Boolean type',
35
+ 枚举类型: 'Enum type',
36
+ 数组: 'Array',
37
+ 引用类型: 'Reference type',
38
+ 对象: 'Object',
39
+ 引用: 'Reference',
40
+ 表单扩展规则: 'Form extension rule',
41
+ 扩展规则: 'Extension rule',
42
+ 规则名称: 'Rule name',
43
+ 规则类型: 'Rule type',
44
+ 规则值: 'Rule value',
45
+ 添加扩展规则: 'Add extension rule',
46
+ 属性名称: 'Attribute name',
47
+ 属性类型: 'Attribute type',
48
+ 添加引用类型: 'Add reference type',
49
+ 刷新: 'Refresh',
50
+ 添加Enum: 'Add Enum',
51
+ 单行文本: 'Single line text',
52
+ 多行文本: 'Multiline text',
53
+ 日期选择: 'Date selection',
54
+ 数字输入框: 'Number input box',
55
+ 开关: 'Switch',
56
+ 下拉单选: 'Dropdown single choice',
57
+ 下拉多选: 'Dropdown multiple choice',
58
+ 颜色选择: 'Color selection',
59
+ 密码框: 'Password box',
60
+ 点击多选: 'Click multiple',
61
+ 点击单选: 'Click single',
62
+ 数字区间: 'Number interval',
63
+ 常规列表: 'General list',
64
+ 表格: 'Table',
65
+ 基础组件: 'Basic components',
66
+ 高级组件: 'Advanced components',
67
+ 布局组件: 'Layout components',
68
+ 整体布局: 'Overall layout',
69
+ '默认布局(一行一列)': 'Default layout (one row and one column)',
70
+ 一行一列: 'One row and one column',
71
+ 一行两列: 'One row and two columns',
72
+ 一行三列: 'One row and three columns',
73
+ 一行四列: 'One row and four columns',
74
+ 标签展示模式: 'Label display mode',
75
+ 同行: 'Same row',
76
+ 单独一行: 'Single row',
77
+ 标签宽度: 'Label width',
78
+ 不填自适应默认宽度: 'Not filled to adapt to the default width',
79
+ 表单配置: 'Form configuration',
80
+ '字段名称(仅支持英文)': 'Field name (only English supported)',
81
+ 标题: 'Title',
82
+ 标题颜色: 'Title color',
83
+ 组件布局: 'Component layout',
84
+ 默认按照整体布局配置排布: 'Default arrange according to the overall layout configuration',
85
+ '这里填写表单整体布局的倍数,最大一行': 'Here fill in the multiple of the overall layout of the form, the maximum row:',
86
+ 默认值: 'Default value',
87
+ 帮助说明: 'Help description',
88
+ 提示说明: 'Tip description',
89
+ 默认文本: 'Default text',
90
+ 是否换行: 'Whether to wrap',
91
+ 后面字段另起一行: 'The next field is on a new line',
92
+ 是否必填: 'Whether it is required',
93
+ 是否禁用: 'Whether it is disabled',
94
+ 是否隐藏: 'Whether it is hidden',
95
+ 隐藏: 'Hide',
96
+ 显示: 'Show',
97
+ 非必填: 'Not required',
98
+ 只读: 'Readonly',
99
+ 文本框: 'Text box',
100
+ 日期选择框: 'Date selection box',
101
+ 颜色选择框: 'Color selection box',
102
+ 格式化: 'Format',
103
+ 默认高度: 'Default height',
104
+ 正则表达式: 'Regular expression',
105
+ 提示信息: 'Prompt information',
106
+ 枚举值: 'Enum value',
107
+ 动态枚举值: 'Dynamic enum value',
108
+ 通过接口调用获取枚举值: 'Get enum values through an interface call',
109
+ 请求URL: 'Request URL',
110
+ 请求方法: 'Request method',
111
+ Body参数: 'Body parameter',
112
+ '支持Json字符串,系统会自动序列化': 'Supports Json string, the system automatically serializes',
113
+ Key的替换属性: 'Key replacement property',
114
+ Vaule的替换属性: 'Value replacement property',
115
+ 监听: 'Listen',
116
+ '监听多个属性,用英文逗号隔开': 'Listen multiple properties, separated by commas',
117
+ 列表联动: 'List linkage',
118
+ 校验规则: 'Validation rule',
119
+ 高级设置: 'Advanced settings',
120
+ 组件: 'Component',
121
+ 组件配置: 'Component configuration',
122
+ 取消预览: 'Cancel preview',
123
+ 预览: 'Preview',
124
+ 清空: 'Clear',
125
+ 已复制到剪切板: 'Copied to the clipboard',
126
+ 导出Schema: 'Export Schema',
127
+ 导入: 'Import',
128
+ 提交: 'Submit',
129
+ 重置: 'Reset',
130
+ 拖拽左侧栏的组件进行添加: 'Drag components from the left sidebar to add',
131
+ '剪切板为空,不可粘贴': 'Clipboard is empty, cannot be pasted',
132
+ 粘贴成功: 'Paste successfully',
133
+ 复制成功: 'Copy successfully',
134
+ 批间隔: 'Batch interval',
135
+ 消费策略: 'Consumption strategy',
136
+ '非必填,默认工作流id': 'Non-required, default workflow id',
137
+ 消费者组: 'Consumer group',
138
+ kafka数据源: 'Kafka data source',
139
+ 选择数据源: 'Select data source',
140
+ 选择主题: 'Select topic',
141
+ 执行活动配置: 'Execution activity configuration',
142
+ 框选: 'Select'
25
143
  };