iglooform 3.7.3 → 3.7.5
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.
- package/.dumi/tmp/core/defineApp.ts +1 -1
- package/.dumi/tmp/core/helmet.ts +1 -1
- package/.dumi/tmp/core/history.ts +1 -1
- package/.dumi/tmp/core/historyIntelli.ts +1 -1
- package/.dumi/tmp/core/plugin.ts +2 -2
- package/.dumi/tmp/core/polyfill.ts +197 -197
- package/.dumi/tmp/core/route.tsx +33 -33
- package/.dumi/tmp/dumi/exports.ts +1 -1
- package/.dumi/tmp/dumi/locales/runtime.tsx +2 -2
- package/.dumi/tmp/dumi/meta/index.ts +33 -33
- package/.dumi/tmp/dumi/meta/runtime.ts +1 -1
- package/.dumi/tmp/dumi/theme/ContextWrapper.tsx +2 -2
- package/.dumi/tmp/dumi/theme/builtins/API.ts +1 -1
- package/.dumi/tmp/dumi/theme/builtins/Badge.ts +1 -1
- package/.dumi/tmp/dumi/theme/builtins/Container.ts +1 -1
- package/.dumi/tmp/dumi/theme/builtins/Previewer.ts +1 -1
- package/.dumi/tmp/dumi/theme/builtins/SourceCode.ts +1 -1
- package/.dumi/tmp/dumi/theme/builtins/Table.ts +1 -1
- package/.dumi/tmp/dumi/theme/builtins/Tree.ts +1 -1
- package/.dumi/tmp/dumi/theme/layouts/DocLayout.ts +1 -1
- package/.dumi/tmp/dumi/theme/loading.tsx +1 -1
- package/.dumi/tmp/dumi/theme/slots/ColorSwitch.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/Content.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/ContentFooter.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/ContentTabs.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/Features.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/Footer.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/Header.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/HeaderExtra.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/Hero.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/HeroTitle.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/LangSwitch.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/Logo.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/Navbar.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/NavbarExtra.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/NotFound.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/PreviewerActions.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/PreviewerActionsExtra.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/RtlSwitch.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/SearchBar.ts +2 -2
- package/.dumi/tmp/dumi/theme/slots/SearchResult.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/Sidebar.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/SocialIcon.ts +1 -1
- package/.dumi/tmp/dumi/theme/slots/Toc.ts +1 -1
- package/.dumi/tmp/exports.ts +5 -5
- package/.dumi/tmp/testBrowser.tsx +3 -3
- package/.dumi/tmp/umi.ts +4 -4
- package/es/form/addable-section/index.js +17 -0
- package/es/free-form/addable-section/index.js +34 -0
- package/es/select/select.d.ts +19 -0
- package/lib/form/addable-section/index.js +17 -0
- package/lib/free-form/addable-section/index.js +34 -0
- package/lib/select/select.d.ts +19 -0
- package/package.json +1 -1
|
@@ -191,6 +191,23 @@ var AddableSection = function AddableSection(props) {
|
|
|
191
191
|
return calcAddableSectionAssertField(namePath, path, index, children);
|
|
192
192
|
});
|
|
193
193
|
}
|
|
194
|
+
if (_child.copyValue) {
|
|
195
|
+
_child.copyValue = _objectSpread(_objectSpread({}, _child.copyValue), {}, {
|
|
196
|
+
assert: _objectSpread(_objectSpread({}, _child.copyValue.assert), {}, {
|
|
197
|
+
field: calcAddableSectionAssertField(namePath, _child.copyValue.assert.field, index, children)
|
|
198
|
+
}),
|
|
199
|
+
copyFrom: calcAddableSectionAssertField(namePath, _child.copyValue.copyFrom, index, children)
|
|
200
|
+
});
|
|
201
|
+
}
|
|
202
|
+
if (Array.isArray(_child.selectValue)) {
|
|
203
|
+
_child.selectValue = _child.selectValue.map(function (sv) {
|
|
204
|
+
return _objectSpread(_objectSpread({}, sv), {}, {
|
|
205
|
+
assert: _objectSpread(_objectSpread({}, sv.assert), {}, {
|
|
206
|
+
field: calcAddableSectionAssertField(namePath, sv.assert.field, index, children)
|
|
207
|
+
})
|
|
208
|
+
});
|
|
209
|
+
});
|
|
210
|
+
}
|
|
194
211
|
if (['Igloo_Free_Form_Item', 'Igloo_Free_Form_Section', 'Igloo_Free_Form_AddableSection'].includes(c === null || c === void 0 ? void 0 : (_c$type = c.type) === null || _c$type === void 0 ? void 0 : _c$type.displayName)) {
|
|
195
212
|
return /*#__PURE__*/cloneElement(c, _objectSpread(_objectSpread({
|
|
196
213
|
key: _index
|
|
@@ -236,6 +253,23 @@ var AddableSection = function AddableSection(props) {
|
|
|
236
253
|
return calcAddableSectionAssertField(namePath, path, index, [children]);
|
|
237
254
|
});
|
|
238
255
|
}
|
|
256
|
+
if (_child.copyValue) {
|
|
257
|
+
_child.copyValue = _objectSpread(_objectSpread({}, _child.copyValue), {}, {
|
|
258
|
+
assert: _objectSpread(_objectSpread({}, _child.copyValue.assert), {}, {
|
|
259
|
+
field: calcAddableSectionAssertField(namePath, _child.copyValue.assert.field, index, [children])
|
|
260
|
+
}),
|
|
261
|
+
copyFrom: calcAddableSectionAssertField(namePath, _child.copyValue.copyFrom, index, [children])
|
|
262
|
+
});
|
|
263
|
+
}
|
|
264
|
+
if (Array.isArray(_child.selectValue)) {
|
|
265
|
+
_child.selectValue = _child.selectValue.map(function (sv) {
|
|
266
|
+
return _objectSpread(_objectSpread({}, sv), {}, {
|
|
267
|
+
assert: _objectSpread(_objectSpread({}, sv.assert), {}, {
|
|
268
|
+
field: calcAddableSectionAssertField(namePath, sv.assert.field, index, [children])
|
|
269
|
+
})
|
|
270
|
+
});
|
|
271
|
+
});
|
|
272
|
+
}
|
|
239
273
|
return /*#__PURE__*/cloneElement(children, _objectSpread(_objectSpread({}, _child), {}, {
|
|
240
274
|
// @ts-ignore
|
|
241
275
|
parentName: parentName,
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Select } from 'antd';
|
|
2
|
+
import { SelectProps as AntdSelectProps, SelectValue, DefaultOptionType } from 'antd/es/select';
|
|
3
|
+
import { FC, IglooComponentProps } from '../types';
|
|
4
|
+
import './style';
|
|
5
|
+
type FilterOption = (inputValue: string, option?: DefaultOptionType) => boolean;
|
|
6
|
+
interface SelectProps extends Omit<AntdSelectProps<SelectValue>, 'showSearch'> {
|
|
7
|
+
showSearch?: boolean | {
|
|
8
|
+
filterOption: FilterOption;
|
|
9
|
+
};
|
|
10
|
+
}
|
|
11
|
+
type Props = SelectProps & IglooComponentProps;
|
|
12
|
+
type OptionType = typeof Select.Option;
|
|
13
|
+
type OptGroupType = typeof Select.OptGroup;
|
|
14
|
+
interface IglooSelectType extends FC<Props> {
|
|
15
|
+
Option: OptionType;
|
|
16
|
+
OptGroup: OptGroupType;
|
|
17
|
+
}
|
|
18
|
+
declare const IglooSelect: IglooSelectType;
|
|
19
|
+
export default IglooSelect;
|
|
@@ -190,6 +190,23 @@ var AddableSection = function AddableSection(_ref) {
|
|
|
190
190
|
return (0, _formUtils.calcAddableSectionAssertField)(namePath, path, index, elements);
|
|
191
191
|
});
|
|
192
192
|
}
|
|
193
|
+
if (child.copyValue) {
|
|
194
|
+
_child.copyValue = _objectSpread(_objectSpread({}, child.copyValue), {}, {
|
|
195
|
+
assert: _objectSpread(_objectSpread({}, child.copyValue.assert), {}, {
|
|
196
|
+
field: (0, _formUtils.calcAddableSectionAssertField)(namePath, child.copyValue.assert.field, index, elements)
|
|
197
|
+
}),
|
|
198
|
+
copyFrom: (0, _formUtils.calcAddableSectionAssertField)(namePath, child.copyValue.copyFrom, index, elements)
|
|
199
|
+
});
|
|
200
|
+
}
|
|
201
|
+
if (Array.isArray(child.selectValue)) {
|
|
202
|
+
_child.selectValue = child.selectValue.map(function (sv) {
|
|
203
|
+
return _objectSpread(_objectSpread({}, sv), {}, {
|
|
204
|
+
assert: _objectSpread(_objectSpread({}, sv.assert), {}, {
|
|
205
|
+
field: (0, _formUtils.calcAddableSectionAssertField)(namePath, sv.assert.field, index, elements)
|
|
206
|
+
})
|
|
207
|
+
});
|
|
208
|
+
});
|
|
209
|
+
}
|
|
193
210
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_element.default, {
|
|
194
211
|
parentName: parentName,
|
|
195
212
|
config: _child,
|
|
@@ -198,6 +198,23 @@ var AddableSection = function AddableSection(props) {
|
|
|
198
198
|
return (0, _formUtils.calcAddableSectionAssertField)(namePath, path, index, children);
|
|
199
199
|
});
|
|
200
200
|
}
|
|
201
|
+
if (_child.copyValue) {
|
|
202
|
+
_child.copyValue = _objectSpread(_objectSpread({}, _child.copyValue), {}, {
|
|
203
|
+
assert: _objectSpread(_objectSpread({}, _child.copyValue.assert), {}, {
|
|
204
|
+
field: (0, _formUtils.calcAddableSectionAssertField)(namePath, _child.copyValue.assert.field, index, children)
|
|
205
|
+
}),
|
|
206
|
+
copyFrom: (0, _formUtils.calcAddableSectionAssertField)(namePath, _child.copyValue.copyFrom, index, children)
|
|
207
|
+
});
|
|
208
|
+
}
|
|
209
|
+
if (Array.isArray(_child.selectValue)) {
|
|
210
|
+
_child.selectValue = _child.selectValue.map(function (sv) {
|
|
211
|
+
return _objectSpread(_objectSpread({}, sv), {}, {
|
|
212
|
+
assert: _objectSpread(_objectSpread({}, sv.assert), {}, {
|
|
213
|
+
field: (0, _formUtils.calcAddableSectionAssertField)(namePath, sv.assert.field, index, children)
|
|
214
|
+
})
|
|
215
|
+
});
|
|
216
|
+
});
|
|
217
|
+
}
|
|
201
218
|
if (['Igloo_Free_Form_Item', 'Igloo_Free_Form_Section', 'Igloo_Free_Form_AddableSection'].includes(c === null || c === void 0 ? void 0 : (_c$type = c.type) === null || _c$type === void 0 ? void 0 : _c$type.displayName)) {
|
|
202
219
|
return /*#__PURE__*/(0, _react.cloneElement)(c, _objectSpread(_objectSpread({
|
|
203
220
|
key: _index
|
|
@@ -243,6 +260,23 @@ var AddableSection = function AddableSection(props) {
|
|
|
243
260
|
return (0, _formUtils.calcAddableSectionAssertField)(namePath, path, index, [children]);
|
|
244
261
|
});
|
|
245
262
|
}
|
|
263
|
+
if (_child.copyValue) {
|
|
264
|
+
_child.copyValue = _objectSpread(_objectSpread({}, _child.copyValue), {}, {
|
|
265
|
+
assert: _objectSpread(_objectSpread({}, _child.copyValue.assert), {}, {
|
|
266
|
+
field: (0, _formUtils.calcAddableSectionAssertField)(namePath, _child.copyValue.assert.field, index, [children])
|
|
267
|
+
}),
|
|
268
|
+
copyFrom: (0, _formUtils.calcAddableSectionAssertField)(namePath, _child.copyValue.copyFrom, index, [children])
|
|
269
|
+
});
|
|
270
|
+
}
|
|
271
|
+
if (Array.isArray(_child.selectValue)) {
|
|
272
|
+
_child.selectValue = _child.selectValue.map(function (sv) {
|
|
273
|
+
return _objectSpread(_objectSpread({}, sv), {}, {
|
|
274
|
+
assert: _objectSpread(_objectSpread({}, sv.assert), {}, {
|
|
275
|
+
field: (0, _formUtils.calcAddableSectionAssertField)(namePath, sv.assert.field, index, [children])
|
|
276
|
+
})
|
|
277
|
+
});
|
|
278
|
+
});
|
|
279
|
+
}
|
|
246
280
|
return /*#__PURE__*/(0, _react.cloneElement)(children, _objectSpread(_objectSpread({}, _child), {}, {
|
|
247
281
|
// @ts-ignore
|
|
248
282
|
parentName: parentName,
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Select } from 'antd';
|
|
2
|
+
import { SelectProps as AntdSelectProps, SelectValue, DefaultOptionType } from 'antd/es/select';
|
|
3
|
+
import { FC, IglooComponentProps } from '../types';
|
|
4
|
+
import './style';
|
|
5
|
+
type FilterOption = (inputValue: string, option?: DefaultOptionType) => boolean;
|
|
6
|
+
interface SelectProps extends Omit<AntdSelectProps<SelectValue>, 'showSearch'> {
|
|
7
|
+
showSearch?: boolean | {
|
|
8
|
+
filterOption: FilterOption;
|
|
9
|
+
};
|
|
10
|
+
}
|
|
11
|
+
type Props = SelectProps & IglooComponentProps;
|
|
12
|
+
type OptionType = typeof Select.Option;
|
|
13
|
+
type OptGroupType = typeof Select.OptGroup;
|
|
14
|
+
interface IglooSelectType extends FC<Props> {
|
|
15
|
+
Option: OptionType;
|
|
16
|
+
OptGroup: OptGroupType;
|
|
17
|
+
}
|
|
18
|
+
declare const IglooSelect: IglooSelectType;
|
|
19
|
+
export default IglooSelect;
|