iglooform 2.4.26 → 2.4.29

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.
@@ -5,6 +5,7 @@ declare const CratetCheckBoxFilter: (props: {
5
5
  allSelected: any[];
6
6
  valueConfirm: any;
7
7
  chooseed?: string[];
8
+ onChange?: any;
8
9
  disabled?: any[];
9
10
  }) => JSX.Element;
10
11
  export default CratetCheckBoxFilter;
@@ -50,6 +50,7 @@ var CratetCheckBoxFilter = function CratetCheckBoxFilter(props) {
50
50
  _props$chooseed = props.chooseed,
51
51
  chooseed = _props$chooseed === void 0 ? [] : _props$chooseed,
52
52
  disabled = props.disabled,
53
+ _onChange = props.onChange,
53
54
  _props$valueConfirm = props.valueConfirm,
54
55
  valueConfirm = _props$valueConfirm === void 0 ? function () {} : _props$valueConfirm;
55
56
  var timeKey = new Date();
@@ -83,6 +84,7 @@ var CratetCheckBoxFilter = function CratetCheckBoxFilter(props) {
83
84
  }), allChoose ? _jsx("span", {
84
85
  className: "igloo-form-filter-drop-down-container-content-group-title-action",
85
86
  onClick: function onClick() {
87
+ typeof _onChange === 'function' && _onChange([]);
86
88
  valueConfirm({
87
89
  type: optionKey,
88
90
  value: []
@@ -98,6 +100,7 @@ var CratetCheckBoxFilter = function CratetCheckBoxFilter(props) {
98
100
  }) : _jsx("span", {
99
101
  className: "igloo-form-filter-drop-down-container-content-group-title-action",
100
102
  onClick: function onClick() {
103
+ typeof _onChange === 'function' && _onChange(allCanChoose);
101
104
  valueConfirm({
102
105
  type: optionKey,
103
106
  value: allCanChoose
@@ -117,7 +120,8 @@ var CratetCheckBoxFilter = function CratetCheckBoxFilter(props) {
117
120
  width: '100%'
118
121
  },
119
122
  onChange: function onChange(e) {
120
- return valueConfirm({
123
+ typeof _onChange === 'function' && _onChange(e);
124
+ valueConfirm({
121
125
  type: optionKey,
122
126
  value: e
123
127
  });
@@ -23,6 +23,7 @@ export interface IFrameConfig {
23
23
  canNotDelete?: boolean;
24
24
  tagTitle?: (value?: any) => string;
25
25
  render?: (value: any, onChange: any) => ReactNode;
26
+ onChange?: any;
26
27
  }
27
28
  export interface IFilterProps {
28
29
  initValue?: {
@@ -635,7 +635,8 @@ var FilterComponent = function FilterComponent(props) {
635
635
  format = _item$format2 === void 0 ? defaultFormat : _item$format2,
636
636
  dateRangeConfig = item.dateRangeConfig,
637
637
  render = item.render,
638
- tagTitle = item.tagTitle;
638
+ tagTitle = item.tagTitle,
639
+ onChangeProps = item.onChange;
639
640
 
640
641
  switch (type) {
641
642
  case 'customize':
@@ -671,7 +672,8 @@ var FilterComponent = function FilterComponent(props) {
671
672
  onFocus: invisibleRef.current,
672
673
  dateRangeConfig: dateRangeConfig,
673
674
  pickerOpenStatus: dataPickerOpenStatus[key],
674
- setPickerOpenStatus: setPickerOpenStatus
675
+ setPickerOpenStatus: setPickerOpenStatus,
676
+ onChange: onChangeProps
675
677
  }, key);
676
678
 
677
679
  case 'mult':
@@ -683,7 +685,8 @@ var FilterComponent = function FilterComponent(props) {
683
685
  allSelected: optionsAllSelected[key],
684
686
  chooseed: optionsChanged[key],
685
687
  disabled: disabled,
686
- valueConfirm: dispatchOptionsChange
688
+ valueConfirm: dispatchOptionsChange,
689
+ onChange: onChangeProps
687
690
  }, key);
688
691
 
689
692
  case 'single':
@@ -694,7 +697,8 @@ var FilterComponent = function FilterComponent(props) {
694
697
  optionKey: key,
695
698
  chooseed: optionsChanged[key],
696
699
  disabled: disabled,
697
- valueConfirm: dispatchOptionsChange
700
+ valueConfirm: dispatchOptionsChange,
701
+ onChange: onChangeProps
698
702
  }, key);
699
703
  }
700
704
  })]
@@ -5,6 +5,7 @@ declare type IRadioBoxProps = {
5
5
  valueConfirm: any;
6
6
  chooseed?: string[];
7
7
  disabled?: any[];
8
+ onChange?: any;
8
9
  };
9
10
  declare const CreateRadioBoxFilter: (props: IRadioBoxProps) => JSX.Element;
10
11
  export default CreateRadioBoxFilter;
@@ -15,7 +15,8 @@ var CreateRadioBoxFilter = function CreateRadioBoxFilter(props) {
15
15
  configList = props.configList,
16
16
  disabled = props.disabled,
17
17
  valueConfirm = props.valueConfirm,
18
- chooseed = props.chooseed;
18
+ chooseed = props.chooseed,
19
+ _onChange = props.onChange;
19
20
  return _jsxs("div", {
20
21
  className: "igloo-form-filter-drop-down-container-content-group",
21
22
  children: [_jsx("div", {
@@ -27,7 +28,8 @@ var CreateRadioBoxFilter = function CreateRadioBoxFilter(props) {
27
28
  }), _jsx(_Radio.Group, {
28
29
  value: chooseed,
29
30
  onChange: function onChange(e) {
30
- return valueConfirm({
31
+ typeof _onChange === 'function' && _onChange(e.target.value);
32
+ valueConfirm({
31
33
  type: optionKey,
32
34
  value: e.target.value
33
35
  });
@@ -12,6 +12,7 @@ declare const CreateRangePickerFilter: (props: {
12
12
  disabledDate?: any;
13
13
  setRangeType?: any;
14
14
  format?: string;
15
+ onChange?: any;
15
16
  tiemRange?: number;
16
17
  }) => JSX.Element;
17
18
  export default CreateRangePickerFilter;
@@ -44,6 +44,7 @@ var CreateRangePickerFilter = function CreateRangePickerFilter(props) {
44
44
  dateRangeConfig = _props$dateRangeConfi === void 0 ? {} : _props$dateRangeConfi,
45
45
  _props$pickerOpenStat = props.pickerOpenStatus,
46
46
  pickerOpenStatus = _props$pickerOpenStat === void 0 ? false : _props$pickerOpenStat,
47
+ onChange = props.onChange,
47
48
  setPickerOpenStatus = props.setPickerOpenStatus;
48
49
  var RangePicker = _DatePicker.RangePicker;
49
50
 
@@ -83,6 +84,7 @@ var CreateRangePickerFilter = function CreateRangePickerFilter(props) {
83
84
  type: optionKey,
84
85
  value: [timeValueRef.current.startTime, timeValueRef.current.endTime]
85
86
  });
87
+ typeof onChange === 'function' && onChange([timeValueRef.current.startTime, timeValueRef.current.endTime]);
86
88
  setPickerOpenStatus({
87
89
  type: optionKey,
88
90
  value: false
@@ -153,7 +153,7 @@ var AddableSection = function AddableSection(_ref) {
153
153
  className: 'igloo-form-addable-section',
154
154
  children: [index > 0 && _jsx(_Divider, {
155
155
  style: {
156
- margin: !md ? preview ? '16px 0 24px 0' : '24px 0' : '32px 0 24px 0'
156
+ margin: !md ? preview ? '16px 0 24px 0' : '24px 0' : preview ? '16px 0 24px' : '32px 0 24px 0'
157
157
  }
158
158
  }), (groupKeys.length > min && !preview || label) && _jsxs(_Row, {
159
159
  justify: "space-between",
@@ -179,7 +179,7 @@ var AddableSection = function AddableSection(_ref) {
179
179
  className: 'igloo-form-addable-section-content'
180
180
  }, contentProps), {}, {
181
181
  style: {
182
- marginTop: !md ? 16 : 24
182
+ marginTop: !md ? 16 : preview ? 16 : 24
183
183
  },
184
184
  children: _jsx(_Row, {
185
185
  gutter: [32, preview ? 16 : 24],
@@ -63,7 +63,7 @@ var useComponent = function useComponent(config) {
63
63
  return {
64
64
  Component: Component,
65
65
  formItemProps: formItemProps,
66
- withoutForm: type === 'Divider' || Boolean(config.withoutForm)
66
+ withoutForm: type === 'Divider' || Boolean(config.withoutForm) || !config.name
67
67
  };
68
68
  }, [config.type]);
69
69
  };
@@ -235,7 +235,7 @@ var AddableSection = function AddableSection(props) {
235
235
  className: 'igloo-addable-section',
236
236
  children: [index > 0 && _jsx(_Divider, {
237
237
  style: {
238
- margin: !md ? preview ? '16px 0 24px 0' : '24px 0' : '32px 0 24px 0'
238
+ margin: !md ? preview ? '16px 0 24px 0' : '24px 0' : preview ? '16px 0 24px' : '32px 0 24px 0'
239
239
  }
240
240
  }), (groupKeys.length > min && !preview || label) && _jsxs(_Row, {
241
241
  justify: "space-between",
@@ -261,7 +261,7 @@ var AddableSection = function AddableSection(props) {
261
261
  className: 'igloo-addable-section-content'
262
262
  }, contentProps), {}, {
263
263
  style: {
264
- marginTop: !md ? 16 : 24
264
+ marginTop: !md ? 16 : preview ? 16 : 24
265
265
  },
266
266
  children: _jsx(_Row, {
267
267
  gutter: [32, preview ? 16 : 24],
@@ -4,7 +4,7 @@
4
4
  "1 file in progress...": "1 data dalam proses",
5
5
  "Accept": "Menerima",
6
6
  "Action": "Beroperasi",
7
- "Add": "",
7
+ "Add": "Menambahkan",
8
8
  "Apply": "Terapkan",
9
9
  "Apply Columns": "Terapkan Kolom",
10
10
  "Cancel": "Batal",
@@ -38,7 +38,7 @@
38
38
  "OK": "oke",
39
39
  "Once you’re happy with the above, and you’ve checked the declaration, please go ahead and submit your claim.": "Jika Anda puas dengan apa yang telah disampaikan, dan Anda telah memeriksa deklarasi tersebut, silakan lanjutkan dan ajukan klaim Anda.",
40
40
  "Optional": "Pilihan",
41
- "Other Reason": "",
41
+ "Other Reason": "Alasan lain",
42
42
  "Please enter a valid date.": "Silakan tulis tanggal valid",
43
43
  "Please enter a valid time.": "Harap masukkan waktu yang valid",
44
44
  "Please select": "Silahkan pilih",
@@ -49,7 +49,7 @@
49
49
  "Processing progress cannot be updated at the moment. Don’t worry! All your file data are still in progress.": "Perkembangan terkait proses belum dapat diperbarui saat ini. Jangan khawatir! Semua data Anda masih dalam proses .",
50
50
  "Quantity of files should be less than {limit}": "Jumlah dokumen tidak bisa lebih dari {limit}",
51
51
  "Reject": "Menolak",
52
- "Remove": "",
52
+ "Remove": "Menghapus",
53
53
  "Resend OTP": "Kirim ulang OTP",
54
54
  "Resend in": "Kirim ulang",
55
55
  "Reset All Filters": "Setel ulang filter",
@@ -4,7 +4,7 @@
4
4
  "1 file in progress...": "กำลังดำเนินการ 1 ไฟล์...",
5
5
  "Accept": "ยอมรับ",
6
6
  "Action": "ดำเนินงาน",
7
- "Add": "",
7
+ "Add": "เพิ่ม",
8
8
  "Apply": "ใช้",
9
9
  "Apply Columns": "ใช้คอลัมน์",
10
10
  "Cancel": "ยกเลิก",
@@ -38,7 +38,7 @@
38
38
  "OK": "ตกลง",
39
39
  "Once you’re happy with the above, and you’ve checked the declaration, please go ahead and submit your claim.": "หากตรวจสอบแล้วและต้องการยืนยันข้อมูลข้างต้น กรุณากดดำเนินการต่อและยืนยันการเคลมของคุณ",
40
40
  "Optional": "ไม่จำเป็น",
41
- "Other Reason": "",
41
+ "Other Reason": "เหตุผลอื่น",
42
42
  "Please enter a valid date.": "กรุณากรอกวันที่ถูกต้อง",
43
43
  "Please enter a valid time.": "กรุณากรอกเวลาที่ถูกต้อง",
44
44
  "Please select": "โปรดเลือก",
@@ -49,7 +49,7 @@
49
49
  "Processing progress cannot be updated at the moment. Don’t worry! All your file data are still in progress.": "ไม่สามารถอัปเดตการประมวลผลได้ในขณะนี้ ไม่ต้องกังวล! ไฟล์ของคุณทั้งหมดกำลังอยู่ระหว่างดำเนินการ",
50
50
  "Quantity of files should be less than {limit}": "จำนวนไฟล์ควรน้อยกว่า {limit}",
51
51
  "Reject": "ปฏิเสธ",
52
- "Remove": "",
52
+ "Remove": "ลบ",
53
53
  "Resend OTP": "ขอ OTP อีกครั้ง",
54
54
  "Resend in": "ส่งอีกครั้งใน",
55
55
  "Reset All Filters": "รีเซทตัวกรอง",
@@ -4,7 +4,7 @@
4
4
  "1 file in progress...": "1 tệp đang được xử lý",
5
5
  "Accept": "Chấp nhận",
6
6
  "Action": "Chạy",
7
- "Add": "",
7
+ "Add": "Thêm vào",
8
8
  "Apply": "Áp dụng",
9
9
  "Apply Columns": "Áp dụng Cột",
10
10
  "Cancel": "Hủy",
@@ -38,7 +38,7 @@
38
38
  "OK": "Vâng",
39
39
  "Once you’re happy with the above, and you’ve checked the declaration, please go ahead and submit your claim.": "Vui lòng xác nhận và gửi yêu cầu bồi thường.",
40
40
  "Optional": "Không bắt buộc",
41
- "Other Reason": "",
41
+ "Other Reason": "Lý do khác",
42
42
  "Please enter a valid date.": "Vui lòng nhập đúng ngày:",
43
43
  "Please enter a valid time.": "Vui lòng nhập thời gian hợp lệ.",
44
44
  "Please select": "Xin hãy lựa chọn",
@@ -49,7 +49,7 @@
49
49
  "Processing progress cannot be updated at the moment. Don’t worry! All your file data are still in progress.": "Dữ liệu chưa được cập nhật và đang trong quá trình xử lý.",
50
50
  "Quantity of files should be less than {limit}": "Số lượng tệp tin không vượt quá {limit}",
51
51
  "Reject": "Từ chối",
52
- "Remove": "",
52
+ "Remove": "tẩy",
53
53
  "Resend OTP": "Gửi lại OTP",
54
54
  "Resend in": "Gửi lại trong",
55
55
  "Reset All Filters": "Xóa lọc",
@@ -4,7 +4,7 @@
4
4
  "1 file in progress...": "1个文件正在处理...",
5
5
  "Accept": "接受",
6
6
  "Action": "操作",
7
- "Add": "",
7
+ "Add": "增加",
8
8
  "Apply": "应用",
9
9
  "Apply Columns": "应用",
10
10
  "Cancel": "取消",
@@ -38,7 +38,7 @@
38
38
  "OK": "确定",
39
39
  "Once you’re happy with the above, and you’ve checked the declaration, please go ahead and submit your claim.": "如您对上述填写内容满意,在勾选以下申明后,请继续提交您的理赔申请。",
40
40
  "Optional": "可选",
41
- "Other Reason": "",
41
+ "Other Reason": "其他原因",
42
42
  "Please enter a valid date.": "请输入一个有效的日期。",
43
43
  "Please enter a valid time.": "请输入一个有效的时间。",
44
44
  "Please select": "请选择",
@@ -49,7 +49,7 @@
49
49
  "Processing progress cannot be updated at the moment. Don’t worry! All your file data are still in progress.": "文件解析中,请耐心等待。",
50
50
  "Quantity of files should be less than {limit}": "文件数量不能超过{limit}",
51
51
  "Reject": "拒绝",
52
- "Remove": "",
52
+ "Remove": "移除",
53
53
  "Resend OTP": "重新发送OTP",
54
54
  "Resend in": "重新发送",
55
55
  "Reset All Filters": "重置所有过滤条件",
@@ -235,14 +235,10 @@ var UploadPhoto = function UploadPhoto(props) {
235
235
  };
236
236
 
237
237
  useEffect(function () {
238
- if (Array.isArray(value) && value.some(function (url) {
239
- return typeof url === 'string' && !files.find(function (file) {
240
- return file.url === url;
241
- });
242
- })) {
238
+ if (Array.isArray(value) && files.length === 0) {
243
239
  mapFilesFromValue(value);
244
240
  }
245
- }, [value, files]);
241
+ }, [value]);
246
242
  var uploadId = useMemo(function () {
247
243
  return "igloo-upload-photo-input-".concat(Math.random());
248
244
  }, []);
@@ -5,6 +5,7 @@ declare const CratetCheckBoxFilter: (props: {
5
5
  allSelected: any[];
6
6
  valueConfirm: any;
7
7
  chooseed?: string[];
8
+ onChange?: any;
8
9
  disabled?: any[];
9
10
  }) => JSX.Element;
10
11
  export default CratetCheckBoxFilter;
@@ -69,6 +69,7 @@ var CratetCheckBoxFilter = function CratetCheckBoxFilter(props) {
69
69
  _props$chooseed = props.chooseed,
70
70
  chooseed = _props$chooseed === void 0 ? [] : _props$chooseed,
71
71
  disabled = props.disabled,
72
+ _onChange = props.onChange,
72
73
  _props$valueConfirm = props.valueConfirm,
73
74
  valueConfirm = _props$valueConfirm === void 0 ? function () {} : _props$valueConfirm;
74
75
  var timeKey = new Date();
@@ -102,6 +103,7 @@ var CratetCheckBoxFilter = function CratetCheckBoxFilter(props) {
102
103
  }), allChoose ? (0, _jsxRuntime.jsx)("span", {
103
104
  className: "igloo-form-filter-drop-down-container-content-group-title-action",
104
105
  onClick: function onClick() {
106
+ typeof _onChange === 'function' && _onChange([]);
105
107
  valueConfirm({
106
108
  type: optionKey,
107
109
  value: []
@@ -117,6 +119,7 @@ var CratetCheckBoxFilter = function CratetCheckBoxFilter(props) {
117
119
  }) : (0, _jsxRuntime.jsx)("span", {
118
120
  className: "igloo-form-filter-drop-down-container-content-group-title-action",
119
121
  onClick: function onClick() {
122
+ typeof _onChange === 'function' && _onChange(allCanChoose);
120
123
  valueConfirm({
121
124
  type: optionKey,
122
125
  value: allCanChoose
@@ -136,7 +139,8 @@ var CratetCheckBoxFilter = function CratetCheckBoxFilter(props) {
136
139
  width: '100%'
137
140
  },
138
141
  onChange: function onChange(e) {
139
- return valueConfirm({
142
+ typeof _onChange === 'function' && _onChange(e);
143
+ valueConfirm({
140
144
  type: optionKey,
141
145
  value: e
142
146
  });
@@ -23,6 +23,7 @@ export interface IFrameConfig {
23
23
  canNotDelete?: boolean;
24
24
  tagTitle?: (value?: any) => string;
25
25
  render?: (value: any, onChange: any) => ReactNode;
26
+ onChange?: any;
26
27
  }
27
28
  export interface IFilterProps {
28
29
  initValue?: {
@@ -668,7 +668,8 @@ var FilterComponent = function FilterComponent(props) {
668
668
  format = _item$format2 === void 0 ? defaultFormat : _item$format2,
669
669
  dateRangeConfig = item.dateRangeConfig,
670
670
  render = item.render,
671
- tagTitle = item.tagTitle;
671
+ tagTitle = item.tagTitle,
672
+ onChangeProps = item.onChange;
672
673
 
673
674
  switch (type) {
674
675
  case 'customize':
@@ -704,7 +705,8 @@ var FilterComponent = function FilterComponent(props) {
704
705
  onFocus: invisibleRef.current,
705
706
  dateRangeConfig: dateRangeConfig,
706
707
  pickerOpenStatus: dataPickerOpenStatus[key],
707
- setPickerOpenStatus: setPickerOpenStatus
708
+ setPickerOpenStatus: setPickerOpenStatus,
709
+ onChange: onChangeProps
708
710
  }, key);
709
711
 
710
712
  case 'mult':
@@ -716,7 +718,8 @@ var FilterComponent = function FilterComponent(props) {
716
718
  allSelected: optionsAllSelected[key],
717
719
  chooseed: optionsChanged[key],
718
720
  disabled: disabled,
719
- valueConfirm: dispatchOptionsChange
721
+ valueConfirm: dispatchOptionsChange,
722
+ onChange: onChangeProps
720
723
  }, key);
721
724
 
722
725
  case 'single':
@@ -727,7 +730,8 @@ var FilterComponent = function FilterComponent(props) {
727
730
  optionKey: key,
728
731
  chooseed: optionsChanged[key],
729
732
  disabled: disabled,
730
- valueConfirm: dispatchOptionsChange
733
+ valueConfirm: dispatchOptionsChange,
734
+ onChange: onChangeProps
731
735
  }, key);
732
736
  }
733
737
  })]
@@ -5,6 +5,7 @@ declare type IRadioBoxProps = {
5
5
  valueConfirm: any;
6
6
  chooseed?: string[];
7
7
  disabled?: any[];
8
+ onChange?: any;
8
9
  };
9
10
  declare const CreateRadioBoxFilter: (props: IRadioBoxProps) => JSX.Element;
10
11
  export default CreateRadioBoxFilter;
@@ -33,7 +33,8 @@ var CreateRadioBoxFilter = function CreateRadioBoxFilter(props) {
33
33
  configList = props.configList,
34
34
  disabled = props.disabled,
35
35
  valueConfirm = props.valueConfirm,
36
- chooseed = props.chooseed;
36
+ chooseed = props.chooseed,
37
+ _onChange = props.onChange;
37
38
  return (0, _jsxRuntime.jsxs)("div", {
38
39
  className: "igloo-form-filter-drop-down-container-content-group",
39
40
  children: [(0, _jsxRuntime.jsx)("div", {
@@ -45,7 +46,8 @@ var CreateRadioBoxFilter = function CreateRadioBoxFilter(props) {
45
46
  }), (0, _jsxRuntime.jsx)(_radio.default.Group, {
46
47
  value: chooseed,
47
48
  onChange: function onChange(e) {
48
- return valueConfirm({
49
+ typeof _onChange === 'function' && _onChange(e.target.value);
50
+ valueConfirm({
49
51
  type: optionKey,
50
52
  value: e.target.value
51
53
  });
@@ -12,6 +12,7 @@ declare const CreateRangePickerFilter: (props: {
12
12
  disabledDate?: any;
13
13
  setRangeType?: any;
14
14
  format?: string;
15
+ onChange?: any;
15
16
  tiemRange?: number;
16
17
  }) => JSX.Element;
17
18
  export default CreateRangePickerFilter;
@@ -65,6 +65,7 @@ var CreateRangePickerFilter = function CreateRangePickerFilter(props) {
65
65
  dateRangeConfig = _props$dateRangeConfi === void 0 ? {} : _props$dateRangeConfi,
66
66
  _props$pickerOpenStat = props.pickerOpenStatus,
67
67
  pickerOpenStatus = _props$pickerOpenStat === void 0 ? false : _props$pickerOpenStat,
68
+ onChange = props.onChange,
68
69
  setPickerOpenStatus = props.setPickerOpenStatus;
69
70
  var RangePicker = _datePicker.default.RangePicker;
70
71
 
@@ -104,6 +105,7 @@ var CreateRangePickerFilter = function CreateRangePickerFilter(props) {
104
105
  type: optionKey,
105
106
  value: [timeValueRef.current.startTime, timeValueRef.current.endTime]
106
107
  });
108
+ typeof onChange === 'function' && onChange([timeValueRef.current.startTime, timeValueRef.current.endTime]);
107
109
  setPickerOpenStatus({
108
110
  type: optionKey,
109
111
  value: false
@@ -178,7 +178,7 @@ var AddableSection = function AddableSection(_ref) {
178
178
  className: 'igloo-form-addable-section',
179
179
  children: [index > 0 && (0, _jsxRuntime.jsx)(_divider.default, {
180
180
  style: {
181
- margin: !md ? preview ? '16px 0 24px 0' : '24px 0' : '32px 0 24px 0'
181
+ margin: !md ? preview ? '16px 0 24px 0' : '24px 0' : preview ? '16px 0 24px' : '32px 0 24px 0'
182
182
  }
183
183
  }), (groupKeys.length > min && !preview || label) && (0, _jsxRuntime.jsxs)(_row.default, {
184
184
  justify: "space-between",
@@ -204,7 +204,7 @@ var AddableSection = function AddableSection(_ref) {
204
204
  className: 'igloo-form-addable-section-content'
205
205
  }, contentProps), {}, {
206
206
  style: {
207
- marginTop: !md ? 16 : 24
207
+ marginTop: !md ? 16 : preview ? 16 : 24
208
208
  },
209
209
  children: (0, _jsxRuntime.jsx)(_row.default, {
210
210
  gutter: [32, preview ? 16 : 24],
@@ -92,7 +92,7 @@ var useComponent = function useComponent(config) {
92
92
  return {
93
93
  Component: Component,
94
94
  formItemProps: formItemProps,
95
- withoutForm: type === 'Divider' || Boolean(config.withoutForm)
95
+ withoutForm: type === 'Divider' || Boolean(config.withoutForm) || !config.name
96
96
  };
97
97
  }, [config.type]);
98
98
  };
@@ -259,7 +259,7 @@ var AddableSection = function AddableSection(props) {
259
259
  className: 'igloo-addable-section',
260
260
  children: [index > 0 && (0, _jsxRuntime.jsx)(_divider.default, {
261
261
  style: {
262
- margin: !md ? preview ? '16px 0 24px 0' : '24px 0' : '32px 0 24px 0'
262
+ margin: !md ? preview ? '16px 0 24px 0' : '24px 0' : preview ? '16px 0 24px' : '32px 0 24px 0'
263
263
  }
264
264
  }), (groupKeys.length > min && !preview || label) && (0, _jsxRuntime.jsxs)(_row.default, {
265
265
  justify: "space-between",
@@ -285,7 +285,7 @@ var AddableSection = function AddableSection(props) {
285
285
  className: 'igloo-addable-section-content'
286
286
  }, contentProps), {}, {
287
287
  style: {
288
- marginTop: !md ? 16 : 24
288
+ marginTop: !md ? 16 : preview ? 16 : 24
289
289
  },
290
290
  children: (0, _jsxRuntime.jsx)(_row.default, {
291
291
  gutter: [32, preview ? 16 : 24],
@@ -4,7 +4,7 @@
4
4
  "1 file in progress...": "1 data dalam proses",
5
5
  "Accept": "Menerima",
6
6
  "Action": "Beroperasi",
7
- "Add": "",
7
+ "Add": "Menambahkan",
8
8
  "Apply": "Terapkan",
9
9
  "Apply Columns": "Terapkan Kolom",
10
10
  "Cancel": "Batal",
@@ -38,7 +38,7 @@
38
38
  "OK": "oke",
39
39
  "Once you’re happy with the above, and you’ve checked the declaration, please go ahead and submit your claim.": "Jika Anda puas dengan apa yang telah disampaikan, dan Anda telah memeriksa deklarasi tersebut, silakan lanjutkan dan ajukan klaim Anda.",
40
40
  "Optional": "Pilihan",
41
- "Other Reason": "",
41
+ "Other Reason": "Alasan lain",
42
42
  "Please enter a valid date.": "Silakan tulis tanggal valid",
43
43
  "Please enter a valid time.": "Harap masukkan waktu yang valid",
44
44
  "Please select": "Silahkan pilih",
@@ -49,7 +49,7 @@
49
49
  "Processing progress cannot be updated at the moment. Don’t worry! All your file data are still in progress.": "Perkembangan terkait proses belum dapat diperbarui saat ini. Jangan khawatir! Semua data Anda masih dalam proses .",
50
50
  "Quantity of files should be less than {limit}": "Jumlah dokumen tidak bisa lebih dari {limit}",
51
51
  "Reject": "Menolak",
52
- "Remove": "",
52
+ "Remove": "Menghapus",
53
53
  "Resend OTP": "Kirim ulang OTP",
54
54
  "Resend in": "Kirim ulang",
55
55
  "Reset All Filters": "Setel ulang filter",
@@ -4,7 +4,7 @@
4
4
  "1 file in progress...": "กำลังดำเนินการ 1 ไฟล์...",
5
5
  "Accept": "ยอมรับ",
6
6
  "Action": "ดำเนินงาน",
7
- "Add": "",
7
+ "Add": "เพิ่ม",
8
8
  "Apply": "ใช้",
9
9
  "Apply Columns": "ใช้คอลัมน์",
10
10
  "Cancel": "ยกเลิก",
@@ -38,7 +38,7 @@
38
38
  "OK": "ตกลง",
39
39
  "Once you’re happy with the above, and you’ve checked the declaration, please go ahead and submit your claim.": "หากตรวจสอบแล้วและต้องการยืนยันข้อมูลข้างต้น กรุณากดดำเนินการต่อและยืนยันการเคลมของคุณ",
40
40
  "Optional": "ไม่จำเป็น",
41
- "Other Reason": "",
41
+ "Other Reason": "เหตุผลอื่น",
42
42
  "Please enter a valid date.": "กรุณากรอกวันที่ถูกต้อง",
43
43
  "Please enter a valid time.": "กรุณากรอกเวลาที่ถูกต้อง",
44
44
  "Please select": "โปรดเลือก",
@@ -49,7 +49,7 @@
49
49
  "Processing progress cannot be updated at the moment. Don’t worry! All your file data are still in progress.": "ไม่สามารถอัปเดตการประมวลผลได้ในขณะนี้ ไม่ต้องกังวล! ไฟล์ของคุณทั้งหมดกำลังอยู่ระหว่างดำเนินการ",
50
50
  "Quantity of files should be less than {limit}": "จำนวนไฟล์ควรน้อยกว่า {limit}",
51
51
  "Reject": "ปฏิเสธ",
52
- "Remove": "",
52
+ "Remove": "ลบ",
53
53
  "Resend OTP": "ขอ OTP อีกครั้ง",
54
54
  "Resend in": "ส่งอีกครั้งใน",
55
55
  "Reset All Filters": "รีเซทตัวกรอง",
@@ -4,7 +4,7 @@
4
4
  "1 file in progress...": "1 tệp đang được xử lý",
5
5
  "Accept": "Chấp nhận",
6
6
  "Action": "Chạy",
7
- "Add": "",
7
+ "Add": "Thêm vào",
8
8
  "Apply": "Áp dụng",
9
9
  "Apply Columns": "Áp dụng Cột",
10
10
  "Cancel": "Hủy",
@@ -38,7 +38,7 @@
38
38
  "OK": "Vâng",
39
39
  "Once you’re happy with the above, and you’ve checked the declaration, please go ahead and submit your claim.": "Vui lòng xác nhận và gửi yêu cầu bồi thường.",
40
40
  "Optional": "Không bắt buộc",
41
- "Other Reason": "",
41
+ "Other Reason": "Lý do khác",
42
42
  "Please enter a valid date.": "Vui lòng nhập đúng ngày:",
43
43
  "Please enter a valid time.": "Vui lòng nhập thời gian hợp lệ.",
44
44
  "Please select": "Xin hãy lựa chọn",
@@ -49,7 +49,7 @@
49
49
  "Processing progress cannot be updated at the moment. Don’t worry! All your file data are still in progress.": "Dữ liệu chưa được cập nhật và đang trong quá trình xử lý.",
50
50
  "Quantity of files should be less than {limit}": "Số lượng tệp tin không vượt quá {limit}",
51
51
  "Reject": "Từ chối",
52
- "Remove": "",
52
+ "Remove": "tẩy",
53
53
  "Resend OTP": "Gửi lại OTP",
54
54
  "Resend in": "Gửi lại trong",
55
55
  "Reset All Filters": "Xóa lọc",
@@ -4,7 +4,7 @@
4
4
  "1 file in progress...": "1个文件正在处理...",
5
5
  "Accept": "接受",
6
6
  "Action": "操作",
7
- "Add": "",
7
+ "Add": "增加",
8
8
  "Apply": "应用",
9
9
  "Apply Columns": "应用",
10
10
  "Cancel": "取消",
@@ -38,7 +38,7 @@
38
38
  "OK": "确定",
39
39
  "Once you’re happy with the above, and you’ve checked the declaration, please go ahead and submit your claim.": "如您对上述填写内容满意,在勾选以下申明后,请继续提交您的理赔申请。",
40
40
  "Optional": "可选",
41
- "Other Reason": "",
41
+ "Other Reason": "其他原因",
42
42
  "Please enter a valid date.": "请输入一个有效的日期。",
43
43
  "Please enter a valid time.": "请输入一个有效的时间。",
44
44
  "Please select": "请选择",
@@ -49,7 +49,7 @@
49
49
  "Processing progress cannot be updated at the moment. Don’t worry! All your file data are still in progress.": "文件解析中,请耐心等待。",
50
50
  "Quantity of files should be less than {limit}": "文件数量不能超过{limit}",
51
51
  "Reject": "拒绝",
52
- "Remove": "",
52
+ "Remove": "移除",
53
53
  "Resend OTP": "重新发送OTP",
54
54
  "Resend in": "重新发送",
55
55
  "Reset All Filters": "重置所有过滤条件",
@@ -268,14 +268,10 @@ var UploadPhoto = function UploadPhoto(props) {
268
268
  };
269
269
 
270
270
  (0, _react.useEffect)(function () {
271
- if (Array.isArray(value) && value.some(function (url) {
272
- return typeof url === 'string' && !files.find(function (file) {
273
- return file.url === url;
274
- });
275
- })) {
271
+ if (Array.isArray(value) && files.length === 0) {
276
272
  mapFilesFromValue(value);
277
273
  }
278
- }, [value, files]);
274
+ }, [value]);
279
275
  var uploadId = (0, _react.useMemo)(function () {
280
276
  return "igloo-upload-photo-input-".concat(Math.random());
281
277
  }, []);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "iglooform",
3
- "version": "2.4.26",
3
+ "version": "2.4.29",
4
4
  "scripts": {
5
5
  "start": "dumi dev",
6
6
  "build-dev": "dumi build",