zy-react-library 1.0.165 → 1.0.167
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.
|
@@ -253,7 +253,7 @@ const FormItemsRenderer = ({
|
|
|
253
253
|
<Select placeholder={placeholder} showSearch allowClear optionFilterProp="children" {...componentProps}>
|
|
254
254
|
{(option.items || []).map((item) => {
|
|
255
255
|
const value = item[itemsFieldKey.valueKey];
|
|
256
|
-
const label = item[itemsFieldKey.labelKey];
|
|
256
|
+
const label = item[typeof itemsFieldKey.labelKey === "function" ? itemsFieldKey.labelKey(item) : itemsFieldKey.labelKey];
|
|
257
257
|
return (
|
|
258
258
|
<Select.Option key={value} value={value}>
|
|
259
259
|
{label}
|
|
@@ -268,7 +268,7 @@ const FormItemsRenderer = ({
|
|
|
268
268
|
<Radio.Group {...componentProps}>
|
|
269
269
|
{(option.items || []).map((item) => {
|
|
270
270
|
const value = item[itemsFieldKey.valueKey];
|
|
271
|
-
const label = item[itemsFieldKey.labelKey];
|
|
271
|
+
const label = item[typeof itemsFieldKey.labelKey === "function" ? itemsFieldKey.labelKey(item) : itemsFieldKey.labelKey];
|
|
272
272
|
return (
|
|
273
273
|
<Radio key={value} value={value}>
|
|
274
274
|
{label}
|
|
@@ -283,7 +283,7 @@ const FormItemsRenderer = ({
|
|
|
283
283
|
<Checkbox.Group {...componentProps}>
|
|
284
284
|
{(option.items || []).map((item) => {
|
|
285
285
|
const value = item[itemsFieldKey.valueKey];
|
|
286
|
-
const label = item[itemsFieldKey.labelKey];
|
|
286
|
+
const label = item[typeof itemsFieldKey.labelKey === "function" ? itemsFieldKey.labelKey(item) : itemsFieldKey.labelKey];
|
|
287
287
|
return (
|
|
288
288
|
<Checkbox key={value} value={value}>
|
|
289
289
|
{label}
|
|
@@ -12,11 +12,11 @@ const PreviewImg = (props) => {
|
|
|
12
12
|
return (
|
|
13
13
|
<Image.PreviewGroup>
|
|
14
14
|
{
|
|
15
|
-
files.filter(Boolean).map((item
|
|
15
|
+
files.filter(Boolean).map((item) => (
|
|
16
16
|
<Image
|
|
17
17
|
key={item[fileUrlKey] || item}
|
|
18
18
|
src={item[fileUrlKey] ? fileUrl + item[fileUrlKey] : fileUrl + item}
|
|
19
|
-
wrapperStyle={{
|
|
19
|
+
wrapperStyle={{ marginRight: 10, marginBottom: 10 }}
|
|
20
20
|
width={100}
|
|
21
21
|
height={100}
|
|
22
22
|
alt=""
|