@teamix/pro 1.2.23 → 1.2.28
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/dist/212.js +129 -129
- package/dist/pro.css +1 -1
- package/dist/pro.js +18109 -15665
- package/dist/pro.min.css +1 -1
- package/dist/pro.min.js +1 -1
- package/dist/pro.min.js.LICENSE.txt +2 -0
- package/es/actions/dialog.js +4 -3
- package/es/actions/index.d.ts +12 -9
- package/es/actions/index.js +56 -15
- package/es/actions/index.scss +12 -1
- package/es/form/Filter/AdvancedFilter.js +1 -1
- package/es/form/Filter/Layout.d.ts +5 -0
- package/es/form/Filter/Layout.js +82 -0
- package/es/form/Filter/SimpleFilter.js +30 -6
- package/es/form/Filter/index2.d.ts +2 -1
- package/es/form/Filter/index2.js +97 -116
- package/es/form/Filter/index2.scss +16 -45
- package/es/form/Filter/layout.scss +36 -0
- package/es/form/Filter/useSpecialProps.d.ts +6 -0
- package/es/form/Filter/useSpecialProps.js +37 -0
- package/es/form/ProForm/customComponent.d.ts +3 -0
- package/es/form/ProForm/customComponent.js +20 -0
- package/es/form/ProForm/index.scss +5 -6
- package/es/form/ProForm/useFormDisplayValues.js +14 -24
- package/es/form/SchemaForm/adapterType.js +1 -0
- package/es/form/SchemaForm/index.js +8 -6
- package/es/form/SchemaForm/initializeDataSource.d.ts +1 -1
- package/es/form/SchemaForm/initializeDataSource.js +2 -2
- package/es/form/SchemaForm/initializeRequest.d.ts +1 -1
- package/es/form/SchemaForm/initializeRequest.js +2 -2
- package/es/form/SchemaForm/initializeRules.d.ts +1 -1
- package/es/form/SchemaForm/initializeRules.js +3 -3
- package/es/form/fieldTypeMap.js +2 -1
- package/es/form/index.d.ts +4 -2
- package/es/form/index.js +4 -2
- package/es/form/typing.d.ts +25 -1
- package/es/form/utils.d.ts +2 -2
- package/es/form/utils.js +2 -2
- package/es/index.d.ts +5 -2
- package/es/index.js +6 -3
- package/es/info/index.scss +1 -1
- package/es/nocode/pages/renderer.js +1 -1
- package/es/step/ProStepItem/components/HozStepItem/index.d.ts +5 -0
- package/es/step/ProStepItem/components/HozStepItem/index.js +235 -0
- package/es/step/ProStepItem/components/HozStepItem/index.scss +279 -0
- package/es/step/ProStepItem/components/VerStepItem/index.d.ts +5 -0
- package/es/step/ProStepItem/components/VerStepItem/index.js +295 -0
- package/es/step/ProStepItem/components/VerStepItem/index.scss +287 -0
- package/es/step/ProStepItem/index.d.ts +4 -0
- package/es/step/ProStepItem/index.js +57 -0
- package/es/step/index.d.ts +9 -0
- package/es/step/index.js +101 -0
- package/es/step/typing.d.ts +96 -0
- package/es/step/typing.js +1 -0
- package/es/table/components/Filter/index.js +2 -17
- package/es/table/components/Layout/index.js +63 -167
- package/es/table/components/Layout/index.scss +4 -3
- package/es/table/components/Pagination/index.js +2 -2
- package/es/table/components/Pagination/index.scss +5 -0
- package/es/table/components/ToolBar/FullScreenIcon.js +4 -9
- package/es/table/components/ToolBar/Fullscreen.js +21 -11
- package/es/table/index.js +82 -104
- package/es/table/index.scss +5 -5
- package/es/table/typing.d.ts +16 -10
- package/es/table/utils/columnRender.js +21 -3
- package/es/table/utils/index.d.ts +7 -0
- package/es/table/utils/index.js +36 -0
- package/es/utils/index.d.ts +1 -0
- package/es/utils/index.js +1 -0
- package/lib/actions/dialog.js +4 -3
- package/lib/actions/index.d.ts +12 -9
- package/lib/actions/index.js +56 -15
- package/lib/actions/index.scss +12 -1
- package/lib/form/Filter/AdvancedFilter.js +1 -1
- package/lib/form/Filter/Layout.d.ts +5 -0
- package/lib/form/Filter/Layout.js +102 -0
- package/lib/form/Filter/SimpleFilter.js +29 -4
- package/lib/form/Filter/index2.d.ts +2 -1
- package/lib/form/Filter/index2.js +101 -114
- package/lib/form/Filter/index2.scss +16 -45
- package/lib/form/Filter/layout.scss +36 -0
- package/lib/form/Filter/useSpecialProps.d.ts +6 -0
- package/lib/form/Filter/useSpecialProps.js +46 -0
- package/lib/form/ProForm/customComponent.d.ts +3 -0
- package/lib/form/ProForm/customComponent.js +28 -0
- package/lib/form/ProForm/index.scss +5 -6
- package/lib/form/ProForm/useFormDisplayValues.js +17 -24
- package/lib/form/SchemaForm/adapterType.js +1 -0
- package/lib/form/SchemaForm/index.js +8 -6
- package/lib/form/SchemaForm/initializeDataSource.d.ts +1 -1
- package/lib/form/SchemaForm/initializeDataSource.js +2 -2
- package/lib/form/SchemaForm/initializeRequest.d.ts +1 -1
- package/lib/form/SchemaForm/initializeRequest.js +2 -2
- package/lib/form/SchemaForm/initializeRules.d.ts +1 -1
- package/lib/form/SchemaForm/initializeRules.js +3 -3
- package/lib/form/fieldTypeMap.js +2 -1
- package/lib/form/index.d.ts +4 -2
- package/lib/form/index.js +19 -1
- package/lib/form/typing.d.ts +25 -1
- package/lib/form/utils.d.ts +2 -2
- package/lib/form/utils.js +2 -2
- package/lib/index.d.ts +5 -2
- package/lib/index.js +35 -3
- package/lib/info/index.scss +1 -1
- package/lib/nocode/pages/renderer.js +1 -1
- package/lib/step/ProStepItem/components/HozStepItem/index.d.ts +5 -0
- package/lib/step/ProStepItem/components/HozStepItem/index.js +258 -0
- package/lib/step/ProStepItem/components/HozStepItem/index.scss +279 -0
- package/lib/step/ProStepItem/components/VerStepItem/index.d.ts +5 -0
- package/lib/step/ProStepItem/components/VerStepItem/index.js +315 -0
- package/lib/step/ProStepItem/components/VerStepItem/index.scss +287 -0
- package/lib/step/ProStepItem/index.d.ts +4 -0
- package/lib/step/ProStepItem/index.js +69 -0
- package/lib/step/index.d.ts +9 -0
- package/lib/step/index.js +124 -0
- package/lib/step/typing.d.ts +96 -0
- package/lib/step/typing.js +5 -0
- package/lib/table/components/Filter/index.js +2 -17
- package/lib/table/components/Layout/index.js +61 -167
- package/lib/table/components/Layout/index.scss +4 -3
- package/lib/table/components/Pagination/index.js +2 -2
- package/lib/table/components/Pagination/index.scss +5 -0
- package/lib/table/components/ToolBar/FullScreenIcon.js +4 -9
- package/lib/table/components/ToolBar/Fullscreen.js +22 -11
- package/lib/table/index.js +78 -101
- package/lib/table/index.scss +5 -5
- package/lib/table/typing.d.ts +16 -10
- package/lib/table/utils/columnRender.js +21 -3
- package/lib/table/utils/index.d.ts +7 -0
- package/lib/table/utils/index.js +38 -0
- package/lib/utils/index.d.ts +1 -0
- package/lib/utils/index.js +13 -0
- package/package.json +4 -4
@@ -150,8 +150,10 @@ var _default = /*#__PURE__*/(0, _react.memo)(function (_ref) {
|
|
150
150
|
}, [scope]); // 格式化 schema
|
151
151
|
|
152
152
|
var formatSchema = (0, _react.useCallback)(function (schema) {
|
153
|
+
var suffix = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
|
153
154
|
var schemaProperties = {};
|
154
155
|
schema === null || schema === void 0 ? void 0 : schema.forEach(function (item, index) {
|
156
|
+
suffix = "".concat(suffix).concat(index);
|
155
157
|
var newItem = (0, _warning.default)(item);
|
156
158
|
var _newItem = newItem,
|
157
159
|
originalComponent = _newItem.component; // 根据component的不同,初始化为内置的item
|
@@ -215,7 +217,7 @@ var _default = /*#__PURE__*/(0, _react.memo)(function (_ref) {
|
|
215
217
|
component = _newItem2.component,
|
216
218
|
type = _newItem2.type,
|
217
219
|
_newItem2$name = _newItem2.name,
|
218
|
-
name = _newItem2$name === void 0 ? (0, _utils.getFieldName)(component === null || component === void 0 ? void 0 : component.replace(/\./g, ''),
|
220
|
+
name = _newItem2$name === void 0 ? (0, _utils.getFieldName)(component === null || component === void 0 ? void 0 : component.replace(/\./g, ''), suffix) : _newItem2$name,
|
219
221
|
decorator = _newItem2.decorator,
|
220
222
|
decoratorProps = _newItem2.decoratorProps,
|
221
223
|
dataSource = _newItem2.dataSource,
|
@@ -240,18 +242,18 @@ var _default = /*#__PURE__*/(0, _react.memo)(function (_ref) {
|
|
240
242
|
var defaultDecoratorProps = _objectSpread(_objectSpread({}, tooltipProps), decoratorProps); // 初始化request
|
241
243
|
|
242
244
|
|
243
|
-
var _initializeRequest = (0, _initializeRequest2.default)(request,
|
245
|
+
var _initializeRequest = (0, _initializeRequest2.default)(request, suffix),
|
244
246
|
requestReactions = _initializeRequest.reactions,
|
245
247
|
requestScope = _initializeRequest.scope; // 初始化dataSource
|
246
248
|
|
247
249
|
|
248
|
-
var _initializeDataSource = (0, _initializeDataSource2.default)(dataSource,
|
250
|
+
var _initializeDataSource = (0, _initializeDataSource2.default)(dataSource, suffix),
|
249
251
|
defaultDataSource = _initializeDataSource.dataSource,
|
250
252
|
dataSourceReactions = _initializeDataSource.reactions,
|
251
253
|
dataSourceScope = _initializeDataSource.scope; // 初始化rules
|
252
254
|
|
253
255
|
|
254
|
-
var _initializeRules = (0, _initializeRules2.default)(rules,
|
256
|
+
var _initializeRules = (0, _initializeRules2.default)(rules, suffix),
|
255
257
|
defaultRules = _initializeRules.rules,
|
256
258
|
rulesScope = _initializeRules.scope; // 合并reactions,初始化reactions
|
257
259
|
|
@@ -279,11 +281,11 @@ var _default = /*#__PURE__*/(0, _react.memo)(function (_ref) {
|
|
279
281
|
})); // 递归子组件
|
280
282
|
|
281
283
|
var recursiveProperties = (children === null || children === void 0 ? void 0 : children.length) ? {
|
282
|
-
properties: formatSchema(children)
|
284
|
+
properties: formatSchema(children, suffix)
|
283
285
|
} : {}; // 递归items(类似子组件,会先由各initialize方法格式化为固定形式,type不同不统一处理)
|
284
286
|
// 例如:[{ name: 'items', type: 'object', children: items }]
|
285
287
|
|
286
|
-
var recursiveItems = items ? formatSchema([items]) : {}; // 配置组件属性
|
288
|
+
var recursiveItems = items ? formatSchema([items], suffix) : {}; // 配置组件属性
|
287
289
|
|
288
290
|
schemaProperties[name] = _objectSpread(_objectSpread(_objectSpread({}, formatParam), recursiveProperties), recursiveItems);
|
289
291
|
});
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import type { ProFormRequestConfig } from '../typing';
|
2
2
|
interface IInitializeDataSource {
|
3
|
-
(requestConfig?: ProFormRequestConfig | any,
|
3
|
+
(requestConfig?: ProFormRequestConfig | any, suffix?: string): {
|
4
4
|
dataSource?: any[];
|
5
5
|
reactions: any[];
|
6
6
|
scope: {
|
@@ -9,10 +9,10 @@ var _utils = require("@teamix/utils");
|
|
9
9
|
|
10
10
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
11
11
|
|
12
|
-
var initializeDataSource = function initializeDataSource(dataSource,
|
12
|
+
var initializeDataSource = function initializeDataSource(dataSource, suffix) {
|
13
13
|
if ((0, _utils.isPlainObj)(dataSource)) {
|
14
14
|
var requestConfig = dataSource;
|
15
|
-
var requestConfigName = "$requestConfig_".concat(
|
15
|
+
var requestConfigName = "$requestConfig_".concat(suffix);
|
16
16
|
return {
|
17
17
|
reactions: ["{{$dataSource($request,".concat(requestConfigName, ",context)}}")],
|
18
18
|
scope: _defineProperty({}, requestConfigName, requestConfig)
|
@@ -7,9 +7,9 @@ exports.default = void 0;
|
|
7
7
|
|
8
8
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
9
9
|
|
10
|
-
var initializeRequest = function initializeRequest(requestConfig,
|
10
|
+
var initializeRequest = function initializeRequest(requestConfig, suffix) {
|
11
11
|
if (requestConfig) {
|
12
|
-
var requestConfigName = "$requestConfig_".concat(
|
12
|
+
var requestConfigName = "$requestConfig_".concat(suffix);
|
13
13
|
return {
|
14
14
|
reactions: ["{{$common($request,".concat(requestConfigName, ",context)}}")],
|
15
15
|
scope: _defineProperty({}, requestConfigName, requestConfig)
|
@@ -25,13 +25,13 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
|
|
25
25
|
|
26
26
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
27
27
|
|
28
|
-
var initializeRules = function initializeRules(rules,
|
28
|
+
var initializeRules = function initializeRules(rules, suffix) {
|
29
29
|
var initializeValidator = function initializeValidator(rule) {
|
30
|
-
var
|
30
|
+
var index = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
|
31
31
|
|
32
32
|
if ((0, _utils.isPlainObj)(rule === null || rule === void 0 ? void 0 : rule.validator)) {
|
33
33
|
var requestConfig = rule.validator;
|
34
|
-
var requestConfigName = "$requestConfig_".concat(
|
34
|
+
var requestConfigName = "$requestConfig_".concat(suffix).concat(index);
|
35
35
|
return {
|
36
36
|
rules: _objectSpread(_objectSpread({}, rule), {}, {
|
37
37
|
validator: "{{$validator($request,".concat(requestConfigName, ",context)}}")
|
package/lib/form/fieldTypeMap.js
CHANGED
package/lib/form/index.d.ts
CHANGED
@@ -97,7 +97,8 @@ declare const formilyReact: {
|
|
97
97
|
useFieldSchema: () => originalFormilyReact.Schema<any, any, any, any, any, any, any, any, any>;
|
98
98
|
useFormEffects: (effects?: ((form: import("@formily/core").Form<any>) => void) | undefined) => void;
|
99
99
|
};
|
100
|
-
|
100
|
+
import { customComponent } from './ProForm/customComponent';
|
101
|
+
export { formilyReact, customComponent };
|
101
102
|
/**
|
102
103
|
* 导出常用formily内容
|
103
104
|
*/
|
@@ -110,7 +111,8 @@ export { createForm, FormConsumer, FormDialog, FormDrawer, FormStep, FormTab, Fo
|
|
110
111
|
*/
|
111
112
|
import { AdvancedFilter, SimpleFilter } from './Filter';
|
112
113
|
import { QueryFilter } from './Filter/index2';
|
113
|
-
|
114
|
+
import { QueryFilterLayout } from './Filter/Layout';
|
115
|
+
export { AdvancedFilter, SimpleFilter, QueryFilter, QueryFilterLayout };
|
114
116
|
/**
|
115
117
|
* 导出 ProForm 组件,支持快速搭建表单
|
116
118
|
*/
|
package/lib/form/index.js
CHANGED
@@ -22,9 +22,11 @@ var _exportNames = {
|
|
22
22
|
formilyTeamix: true,
|
23
23
|
FormConsumer: true,
|
24
24
|
useForm: true,
|
25
|
+
customComponent: true,
|
25
26
|
AdvancedFilter: true,
|
26
27
|
SimpleFilter: true,
|
27
|
-
QueryFilter: true
|
28
|
+
QueryFilter: true,
|
29
|
+
QueryFilterLayout: true
|
28
30
|
};
|
29
31
|
Object.defineProperty(exports, "AdvancedFilter", {
|
30
32
|
enumerable: true,
|
@@ -74,6 +76,12 @@ Object.defineProperty(exports, "QueryFilter", {
|
|
74
76
|
return _index.QueryFilter;
|
75
77
|
}
|
76
78
|
});
|
79
|
+
Object.defineProperty(exports, "QueryFilterLayout", {
|
80
|
+
enumerable: true,
|
81
|
+
get: function get() {
|
82
|
+
return _Layout.QueryFilterLayout;
|
83
|
+
}
|
84
|
+
});
|
77
85
|
Object.defineProperty(exports, "SimpleFilter", {
|
78
86
|
enumerable: true,
|
79
87
|
get: function get() {
|
@@ -86,6 +94,12 @@ Object.defineProperty(exports, "createForm", {
|
|
86
94
|
return _formilyCore.createForm;
|
87
95
|
}
|
88
96
|
});
|
97
|
+
Object.defineProperty(exports, "customComponent", {
|
98
|
+
enumerable: true,
|
99
|
+
get: function get() {
|
100
|
+
return _customComponent.customComponent;
|
101
|
+
}
|
102
|
+
});
|
89
103
|
exports.formilyTeamix = exports.formilyReactive = exports.formilyReact = exports.formilyCore = exports.default = void 0;
|
90
104
|
Object.defineProperty(exports, "registerFormats", {
|
91
105
|
enumerable: true,
|
@@ -150,10 +164,14 @@ var _useFormDisplayValues = require("./ProForm/useFormDisplayValues");
|
|
150
164
|
|
151
165
|
var _useFieldRequest = _interopRequireDefault(require("./ProForm/useFieldRequest"));
|
152
166
|
|
167
|
+
var _customComponent = require("./ProForm/customComponent");
|
168
|
+
|
153
169
|
var _Filter = require("./Filter");
|
154
170
|
|
155
171
|
var _index = require("./Filter/index2");
|
156
172
|
|
173
|
+
var _Layout = require("./Filter/Layout");
|
174
|
+
|
157
175
|
var _ProForm = _interopRequireDefault(require("./ProForm"));
|
158
176
|
|
159
177
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
package/lib/form/typing.d.ts
CHANGED
@@ -10,7 +10,7 @@ declare type FieldDisplayTypes = 'none' | 'hidden' | 'visible';
|
|
10
10
|
export interface ProFormInitializeItem {
|
11
11
|
(item: ProFormSchemaItem, props?: any): ProFormSchemaItem;
|
12
12
|
}
|
13
|
-
declare type IBaseComponent = 'Input' | 'Password' | 'TextArea' | 'NumberPicker' | 'Percent' | 'Money' | 'Select' | 'MultipleSelect' | 'TreeSelect' | 'Cascader' | 'MultipleCascader' | 'ArbitraryCascader' | 'Radio' | 'Checkbox' | 'Switch' | 'DatePicker' | 'TimePicker' | 'DateTimePicker' | 'WeekPicker' | 'MonthPicker' | 'YearPicker' | 'QuarterPicker' | 'DateRangePicker' | 'TimeRangePicker' | 'DateTimeRangePicker' | 'WeekRangePicker' | 'MonthRangePicker' | 'YearRangePicker' | 'QuarterRangePicker' | 'Transfer' | 'Upload' | 'ColorPicker' | 'ColorRadio' | 'IconPicker' | 'JsonInput' | 'TagPicker' | 'MultipleTagPicker' | 'Range' | 'Search';
|
13
|
+
declare type IBaseComponent = 'Input' | 'Password' | 'TextArea' | 'NumberPicker' | 'Percent' | 'Money' | 'Select' | 'MultipleSelect' | 'TreeSelect' | 'Cascader' | 'MultipleCascader' | 'ArbitraryCascader' | 'Radio' | 'Checkbox' | 'Switch' | 'DatePicker' | 'TimePicker' | 'DateTimePicker' | 'WeekPicker' | 'MonthPicker' | 'YearPicker' | 'QuarterPicker' | 'DateRangePicker' | 'TimeRangePicker' | 'DateTimeRangePicker' | 'WeekRangePicker' | 'MonthRangePicker' | 'YearRangePicker' | 'QuarterRangePicker' | 'Transfer' | 'Upload' | 'ColorPicker' | 'ColorRadio' | 'IconPicker' | 'JsonInput' | 'TagPicker' | 'MultipleTagPicker' | 'Range' | 'Search' | 'SelectGroup';
|
14
14
|
declare type IButtonComponent = 'Submit' | 'Reset';
|
15
15
|
declare type IComboComponent = 'ArrayCards' | 'ArrayCards.Addition' | 'ArrayCards.Remove' | 'ArrayCards.MoveUp' | 'ArrayCards.MoveDown' | 'ArrayCards.Index' | 'ArrayCollapse' | 'ArrayCollapse.CollapsePanel' | 'ArrayCollapse.Addition' | 'ArrayCollapse.Remove' | 'ArrayCollapse.MoveUp' | 'ArrayCollapse.MoveDown' | 'ArrayCollapse.Index' | 'ArrayTable' | 'ArrayTable.Column' | 'ArrayTable.SortHandle' | 'ArrayTable.Addition' | 'ArrayTable.Remove' | 'ArrayTable.MoveDown' | 'ArrayTable.MoveUp' | 'ArrayTable.Index' | 'ArrayItems' | 'ArrayItems.Item' | 'ArrayItems.SortHandle' | 'ArrayItems.Addition' | 'ArrayItems.Remove' | 'ArrayItems.MoveDown' | 'ArrayItems.MoveUp' | 'ArrayItems.Index' | 'Editable' | 'Editable.Popover' | 'Editable.Dialog' | 'Editable.Drawer';
|
16
16
|
declare type ILayoutComponent = 'FormFlex' | 'FormGrid' | 'FormGroup' | 'FormGroup.GroupPanel' | 'Search' | 'Search.SearchPanel' | 'FormTab' | 'FormTab.TabPane' | 'FormStep' | 'FormStep.StepPane' | 'FormCollapse' | 'FormCollapse.CollapsePanel' | 'FormButtonGroup' | 'FormDialog' | 'FormDrawer' | 'FormDialog.Footer' | 'FormDrawer.Footer';
|
@@ -70,20 +70,44 @@ export interface FilterProps extends ProFormProps {
|
|
70
70
|
onReset?: (payload?: any) => void;
|
71
71
|
onResetClick?: () => void;
|
72
72
|
}
|
73
|
+
export interface QueryFilterLayoutProps {
|
74
|
+
prefixCls?: string;
|
75
|
+
className?: string;
|
76
|
+
addonBefore?: ReactNode;
|
77
|
+
addonAfter?: ReactNode;
|
78
|
+
inlineContent?: ReactNode;
|
79
|
+
panelContent?: ReactNode;
|
80
|
+
count?: number;
|
81
|
+
expand?: boolean;
|
82
|
+
onExpand?: (expand: boolean) => void;
|
83
|
+
}
|
73
84
|
export interface QueryFilterProps extends ProFormProps {
|
74
85
|
/**
|
75
86
|
* @deprecated triggerType已弃用
|
76
87
|
*/
|
77
88
|
triggerType?: 'keydown' | 'change' | 'submit';
|
89
|
+
/** 表单展示形式 */
|
78
90
|
mode?: 'inline' | 'panel';
|
91
|
+
/** 面板是否默认展开,仅在 mode='panel' 时生效 */
|
79
92
|
expand?: boolean;
|
93
|
+
/** 顶部筛选区前缀 */
|
80
94
|
addonBefore?: ReactNode;
|
95
|
+
/** 顶部筛选区后缀 */
|
81
96
|
addonAfter?: ReactNode;
|
97
|
+
/** 顶部筛选区默认筛选项 */
|
82
98
|
defaultFilterValue?: string;
|
99
|
+
/** 透出内部表单实例 */
|
83
100
|
formRef?: React.MutableRefObject<any>;
|
101
|
+
/** onChange事件的防抖时间 */
|
102
|
+
filterDebounce?: number;
|
103
|
+
/** 表单初始化(含异步默认值)后回调函数 */
|
84
104
|
onInit?: (values: any) => boolean;
|
105
|
+
/** 表单筛选回调函数 */
|
85
106
|
onFilter?: (values: any) => void;
|
107
|
+
/** 表单重置回调函数 */
|
86
108
|
onReset?: (payload?: any) => void;
|
109
|
+
/** 高级筛选按钮切换 */
|
110
|
+
onExpand?: (expand: boolean) => void;
|
87
111
|
}
|
88
112
|
/**
|
89
113
|
* 兼容性导出
|
package/lib/form/utils.d.ts
CHANGED
@@ -17,11 +17,11 @@ declare const mapMode: (props: any, field: any) => any;
|
|
17
17
|
/**
|
18
18
|
* 创建字段名称
|
19
19
|
* @param prefix 字段名称前缀,接收字段component名称,默认为FieldName
|
20
|
-
* @param
|
20
|
+
* @param suffix 字段后缀,唯一标识
|
21
21
|
* @returns 字段唯一名称
|
22
22
|
*/
|
23
23
|
interface IGetFieldName {
|
24
|
-
(prefix: string,
|
24
|
+
(prefix: string, suffix?: string): string;
|
25
25
|
}
|
26
26
|
declare const getFieldName: IGetFieldName;
|
27
27
|
/**
|
package/lib/form/utils.js
CHANGED
@@ -135,8 +135,8 @@ exports.mapMode = mapMode;
|
|
135
135
|
|
136
136
|
var getFieldName = function getFieldName() {
|
137
137
|
var prefix = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'FieldName';
|
138
|
-
var
|
139
|
-
return "".concat(prefix, "-").concat(
|
138
|
+
var suffix = arguments.length > 1 ? arguments[1] : undefined;
|
139
|
+
return "".concat(prefix, "-").concat(suffix);
|
140
140
|
};
|
141
141
|
/**
|
142
142
|
* 将ProForm的key映射为formily的key,然后筛除掉无效的key/value
|
package/lib/index.d.ts
CHANGED
@@ -9,6 +9,7 @@ import ProPageHeader from './page-header';
|
|
9
9
|
import ProTable from './table';
|
10
10
|
import ProSkeleton from './skeleton';
|
11
11
|
import utils from './utils';
|
12
|
+
import { ProStep } from './step';
|
12
13
|
import * as nocode from './nocode';
|
13
14
|
import * as templates from './templates';
|
14
15
|
export * from './actions';
|
@@ -21,5 +22,7 @@ export * from './page-container';
|
|
21
22
|
export * from './page-header';
|
22
23
|
export * from './skeleton';
|
23
24
|
export * from './table';
|
24
|
-
|
25
|
-
export
|
25
|
+
export * from './utils';
|
26
|
+
export * from './step';
|
27
|
+
declare const version = "1.2.28";
|
28
|
+
export { version, ProAction, ProCard, ProField, ProForm, ProInfo, ProPageContainer, ProPageHeader, ProSkeleton, ProTable, ProStep, hooks, nocode, templates, utils, };
|
package/lib/index.js
CHANGED
@@ -18,6 +18,7 @@ var _exportNames = {
|
|
18
18
|
ProTable: true,
|
19
19
|
ProSkeleton: true,
|
20
20
|
utils: true,
|
21
|
+
ProStep: true,
|
21
22
|
nocode: true,
|
22
23
|
templates: true
|
23
24
|
};
|
@@ -69,6 +70,12 @@ Object.defineProperty(exports, "ProSkeleton", {
|
|
69
70
|
return _skeleton.default;
|
70
71
|
}
|
71
72
|
});
|
73
|
+
Object.defineProperty(exports, "ProStep", {
|
74
|
+
enumerable: true,
|
75
|
+
get: function get() {
|
76
|
+
return _step.ProStep;
|
77
|
+
}
|
78
|
+
});
|
72
79
|
Object.defineProperty(exports, "ProTable", {
|
73
80
|
enumerable: true,
|
74
81
|
get: function get() {
|
@@ -218,7 +225,33 @@ Object.keys(_skeleton).forEach(function (key) {
|
|
218
225
|
});
|
219
226
|
});
|
220
227
|
|
221
|
-
var _utils =
|
228
|
+
var _utils = _interopRequireWildcard(require("./utils"));
|
229
|
+
|
230
|
+
Object.keys(_utils).forEach(function (key) {
|
231
|
+
if (key === "default" || key === "__esModule") return;
|
232
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
233
|
+
if (key in exports && exports[key] === _utils[key]) return;
|
234
|
+
Object.defineProperty(exports, key, {
|
235
|
+
enumerable: true,
|
236
|
+
get: function get() {
|
237
|
+
return _utils[key];
|
238
|
+
}
|
239
|
+
});
|
240
|
+
});
|
241
|
+
|
242
|
+
var _step = require("./step");
|
243
|
+
|
244
|
+
Object.keys(_step).forEach(function (key) {
|
245
|
+
if (key === "default" || key === "__esModule") return;
|
246
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
247
|
+
if (key in exports && exports[key] === _step[key]) return;
|
248
|
+
Object.defineProperty(exports, key, {
|
249
|
+
enumerable: true,
|
250
|
+
get: function get() {
|
251
|
+
return _step[key];
|
252
|
+
}
|
253
|
+
});
|
254
|
+
});
|
222
255
|
|
223
256
|
var nocode = _interopRequireWildcard(require("./nocode"));
|
224
257
|
|
@@ -252,6 +285,5 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
|
|
252
285
|
// 设置图标源
|
253
286
|
_icon.default.setConfig(_utils.default.getTeamixIconConfig());
|
254
287
|
|
255
|
-
|
256
|
-
var version = '1.2.23';
|
288
|
+
var version = '1.2.28';
|
257
289
|
exports.version = version;
|
package/lib/info/index.scss
CHANGED
@@ -37,7 +37,7 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
37
37
|
|
38
38
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
39
39
|
|
40
|
-
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); }
|
40
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
41
41
|
|
42
42
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
43
43
|
|