@teamix/pro 1.1.39 → 1.1.40
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/README.md +14 -10
- package/dist/pro.css +1 -1
- package/dist/pro.js +2214 -4073
- package/dist/pro.min.css +1 -1
- package/dist/pro.min.js +1 -1
- package/es/actions/dialog-form.d.ts +5 -5
- package/es/actions/dialog-form.js +1 -5
- package/es/actions/dialog.d.ts +6 -3
- package/es/actions/dialog.js +12 -5
- package/es/actions/index.d.ts +54 -47
- package/es/actions/index.js +28 -22
- package/es/actions/index.scss +17 -2
- package/es/card/index.d.ts +17 -5
- package/es/card/index.js +16 -11
- package/es/form/Components/ProField/index.d.ts +1 -78
- package/es/form/Components/ProField/index.js +34 -40
- package/es/form/Filter/index.js +2 -2
- package/es/form/ProForm/index.d.ts +2 -2
- package/es/form/ProForm/index.js +1 -6
- package/es/form/ProForm/index.scss +19 -1
- package/es/form/ProForm/useFieldRequest.d.ts +5 -0
- package/es/form/ProForm/useFieldRequest.js +26 -0
- package/es/form/SchemaForm/adapterDecorator.js +2 -2
- package/es/form/SchemaForm/index.d.ts +2 -2
- package/es/form/SchemaForm/index.js +12 -21
- package/es/form/SchemaForm/initializeArrayCards.d.ts +2 -2
- package/es/form/SchemaForm/initializeArrayCollapse.d.ts +2 -2
- package/es/form/SchemaForm/initializeArrayItems.d.ts +2 -2
- package/es/form/SchemaForm/initializeArrayTable.d.ts +2 -2
- package/es/form/SchemaForm/initializeDataSource.d.ts +2 -2
- package/es/form/SchemaForm/initializeDataSource.js +2 -2
- package/es/form/SchemaForm/initializeFormButton.d.ts +2 -2
- package/es/form/SchemaForm/initializeFormCollapse.d.ts +2 -2
- package/es/form/SchemaForm/initializeFormGroup.d.ts +2 -2
- package/es/form/SchemaForm/initializeFormStep.d.ts +3 -3
- package/es/form/SchemaForm/initializeFormTab.d.ts +2 -2
- package/es/form/SchemaForm/initializeRequest.d.ts +2 -2
- package/es/form/SchemaForm/initializeRequest.js +2 -2
- package/es/form/SchemaForm/initializeRules.js +44 -16
- package/es/form/SchemaForm/reactions.d.ts +5 -5
- package/es/form/SchemaForm/reactions.js +20 -18
- package/es/form/fieldTypeMap.d.ts +4 -0
- package/es/form/fieldTypeMap.js +41 -0
- package/es/form/index.d.ts +92 -4
- package/es/form/index.js +18 -5
- package/es/form/schemaNameMap.js +3 -0
- package/es/form/typing.d.ts +44 -21
- package/es/form/utils.d.ts +3 -1
- package/es/form/utils.js +38 -1
- package/es/form/warning.d.ts +2 -2
- package/es/index.d.ts +1 -1
- package/es/index.js +1 -1
- package/es/info/components/InfoGroup/index.js +73 -15
- package/es/info/components/InfoGroup/index.scss +45 -3
- package/es/info/components/InfoValueItem/index.js +6 -4
- package/es/info/components/InfoValueItem/index.scss +5 -1
- package/es/info/components/ProInfoItem/index.js +3 -3
- package/es/info/components/ProInfoItem/index.scss +1 -0
- package/es/info/components/baseInfo/index.d.ts +2 -3
- package/es/info/components/headerInfo/index.d.ts +2 -3
- package/es/info/components/tableInfo/index.d.ts +2 -3
- package/es/info/components/tableInfo/index.js +2 -2
- package/es/info/index.js +52 -49
- package/es/info/typing.d.ts +52 -36
- package/es/info/utils/index.d.ts +2 -2
- package/es/info/utils/utils.d.ts +1 -1
- package/es/nocode/pages/renderer.js +2 -2
- package/es/page-header/index.d.ts +34 -21
- package/es/page-header/index.js +39 -30
- package/es/page-header/index.scss +2 -1
- package/es/table/components/EmptyContent/index.d.ts +2 -0
- package/es/table/components/EmptyContent/index.js +11 -0
- package/es/table/components/Filter/index.d.ts +2 -2
- package/es/table/components/Filter/index.js +16 -8
- package/es/table/components/Layout/index.js +2 -2
- package/es/table/components/QuickAction/index.d.ts +2 -2
- package/es/table/components/QuickAction/index.js +3 -3
- package/es/table/components/ToolBar/Fullscreen.js +1 -0
- package/es/table/index.js +76 -14
- package/es/table/index.scss +4 -0
- package/es/table/typing.d.ts +27 -14
- package/es/table/utils/columnRender.d.ts +3 -3
- package/es/table/utils/columnRender.js +2 -2
- package/es/table/utils/genProColumnToColumn.d.ts +2 -2
- package/es/table/utils/genProColumnToColumn.js +1 -1
- package/es/table/utils/index.js +33 -11
- package/es/templates/List/index.d.ts +2 -2
- package/es/utils/message.d.ts +3 -0
- package/es/utils/message.js +19 -0
- package/lib/actions/dialog-form.d.ts +5 -5
- package/lib/actions/dialog-form.js +1 -5
- package/lib/actions/dialog.d.ts +6 -3
- package/lib/actions/dialog.js +13 -5
- package/lib/actions/index.d.ts +54 -47
- package/lib/actions/index.js +37 -30
- package/lib/actions/index.scss +17 -2
- package/lib/card/index.d.ts +17 -5
- package/lib/card/index.js +18 -12
- package/lib/form/Components/ProField/index.d.ts +1 -78
- package/lib/form/Components/ProField/index.js +32 -38
- package/lib/form/Filter/index.js +2 -2
- package/lib/form/ProForm/index.d.ts +2 -2
- package/lib/form/ProForm/index.js +1 -7
- package/lib/form/ProForm/index.scss +19 -1
- package/lib/form/ProForm/useFieldRequest.d.ts +5 -0
- package/lib/form/ProForm/useFieldRequest.js +37 -0
- package/lib/form/SchemaForm/adapterDecorator.js +4 -2
- package/lib/form/SchemaForm/index.d.ts +2 -2
- package/lib/form/SchemaForm/index.js +11 -22
- package/lib/form/SchemaForm/initializeArrayCards.d.ts +2 -2
- package/lib/form/SchemaForm/initializeArrayCollapse.d.ts +2 -2
- package/lib/form/SchemaForm/initializeArrayItems.d.ts +2 -2
- package/lib/form/SchemaForm/initializeArrayTable.d.ts +2 -2
- package/lib/form/SchemaForm/initializeDataSource.d.ts +2 -2
- package/lib/form/SchemaForm/initializeDataSource.js +2 -2
- package/lib/form/SchemaForm/initializeFormButton.d.ts +2 -2
- package/lib/form/SchemaForm/initializeFormCollapse.d.ts +2 -2
- package/lib/form/SchemaForm/initializeFormGroup.d.ts +2 -2
- package/lib/form/SchemaForm/initializeFormStep.d.ts +3 -3
- package/lib/form/SchemaForm/initializeFormTab.d.ts +2 -2
- package/lib/form/SchemaForm/initializeRequest.d.ts +2 -2
- package/lib/form/SchemaForm/initializeRequest.js +1 -1
- package/lib/form/SchemaForm/initializeRules.js +41 -13
- package/lib/form/SchemaForm/reactions.d.ts +5 -5
- package/lib/form/SchemaForm/reactions.js +22 -20
- package/lib/form/fieldTypeMap.d.ts +4 -0
- package/lib/form/fieldTypeMap.js +48 -0
- package/lib/form/index.d.ts +92 -4
- package/lib/form/index.js +17 -31
- package/lib/form/schemaNameMap.js +3 -0
- package/lib/form/typing.d.ts +44 -21
- package/lib/form/utils.d.ts +3 -1
- package/lib/form/utils.js +43 -1
- package/lib/form/warning.d.ts +2 -2
- package/lib/index.d.ts +1 -1
- package/lib/index.js +1 -1
- package/lib/info/components/InfoGroup/index.js +76 -14
- package/lib/info/components/InfoGroup/index.scss +45 -3
- package/lib/info/components/InfoValueItem/index.js +5 -3
- package/lib/info/components/InfoValueItem/index.scss +5 -1
- package/lib/info/components/ProInfoItem/index.js +2 -2
- package/lib/info/components/ProInfoItem/index.scss +1 -0
- package/lib/info/components/baseInfo/index.d.ts +2 -3
- package/lib/info/components/headerInfo/index.d.ts +2 -3
- package/lib/info/components/tableInfo/index.d.ts +2 -3
- package/lib/info/components/tableInfo/index.js +1 -1
- package/lib/info/index.js +51 -48
- package/lib/info/typing.d.ts +52 -36
- package/lib/info/utils/index.d.ts +2 -2
- package/lib/info/utils/utils.d.ts +1 -1
- package/lib/nocode/pages/renderer.js +1 -1
- package/lib/page-header/index.d.ts +34 -21
- package/lib/page-header/index.js +37 -28
- package/lib/page-header/index.scss +2 -1
- package/lib/table/components/EmptyContent/index.d.ts +2 -0
- package/lib/table/components/EmptyContent/index.js +25 -0
- package/lib/table/components/Filter/index.d.ts +2 -2
- package/lib/table/components/Filter/index.js +16 -8
- package/lib/table/components/Layout/index.js +1 -1
- package/lib/table/components/QuickAction/index.d.ts +2 -2
- package/lib/table/components/QuickAction/index.js +1 -1
- package/lib/table/components/ToolBar/Fullscreen.js +1 -0
- package/lib/table/index.js +77 -14
- package/lib/table/index.scss +4 -0
- package/lib/table/typing.d.ts +27 -14
- package/lib/table/utils/columnRender.d.ts +3 -3
- package/lib/table/utils/columnRender.js +1 -1
- package/lib/table/utils/genProColumnToColumn.d.ts +2 -2
- package/lib/table/utils/genProColumnToColumn.js +2 -2
- package/lib/table/utils/index.js +33 -11
- package/lib/templates/List/index.d.ts +2 -2
- package/lib/utils/message.d.ts +3 -0
- package/lib/utils/message.js +32 -0
- package/package.json +4 -4
- package/es/form/Components/Search/index.d.ts +0 -11
- package/es/form/Components/Search/index.js +0 -89
- package/es/form/SchemaForm/initializeArrayIcon.d.ts +0 -3
- package/es/form/SchemaForm/initializeArrayIcon.js +0 -62
- package/es/form/SchemaForm/initializeProField.d.ts +0 -5
- package/es/form/SchemaForm/initializeProField.js +0 -70
- package/es/info/utils/useInfoRequest.d.ts +0 -14
- package/es/info/utils/useInfoRequest.js +0 -76
- package/lib/form/Components/Search/index.d.ts +0 -11
- package/lib/form/Components/Search/index.js +0 -103
- package/lib/form/SchemaForm/initializeArrayIcon.d.ts +0 -3
- package/lib/form/SchemaForm/initializeArrayIcon.js +0 -73
- package/lib/form/SchemaForm/initializeProField.d.ts +0 -5
- package/lib/form/SchemaForm/initializeProField.js +0 -77
- package/lib/info/utils/useInfoRequest.d.ts +0 -14
- package/lib/info/utils/useInfoRequest.js +0 -85
@@ -1,19 +1,16 @@
|
|
1
1
|
import React from 'react';
|
2
2
|
import { TagProps, CloseableProps } from '@alicloudfe/components/types/tag';
|
3
|
-
import {
|
3
|
+
import { ItemProps } from '@alicloudfe/components/types/breadcrumb';
|
4
|
+
import { ProActionGroupProps } from '../actions';
|
4
5
|
import { ProInfoProps } from '../info';
|
5
6
|
import './index.scss';
|
6
|
-
export interface
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
link?: string;
|
12
|
-
icon?: string;
|
13
|
-
text: string;
|
14
|
-
onClick?: (e?: React.MouseEvent<Element, MouseEvent>) => void;
|
7
|
+
export interface ProPageHeaderBreadcrumbItem extends ItemProps {
|
8
|
+
/**
|
9
|
+
* @deprecated 建议使用 children 代替
|
10
|
+
*/
|
11
|
+
text?: string;
|
15
12
|
}
|
16
|
-
export declare type
|
13
|
+
export declare type ProPageHeaderTagItem = (TagProps | (CloseableProps & {
|
17
14
|
closable: true;
|
18
15
|
})) & {
|
19
16
|
/**
|
@@ -22,12 +19,12 @@ export declare type TagItem = (TagProps | (CloseableProps & {
|
|
22
19
|
text?: string;
|
23
20
|
};
|
24
21
|
declare type Color = 'blue' | 'green' | 'orange' | 'red' | 'yellow' | string;
|
25
|
-
export
|
22
|
+
export declare type ProPageHeaderDataItem = {
|
26
23
|
title: string;
|
27
24
|
num: number;
|
28
25
|
color?: Color;
|
29
|
-
}
|
30
|
-
export declare type
|
26
|
+
} & React.HTMLAttributes<HTMLElement>;
|
27
|
+
export declare type ProPageHeaderProps = {
|
31
28
|
title?: React.ReactNode;
|
32
29
|
description?: React.ReactNode;
|
33
30
|
icon?: string;
|
@@ -37,12 +34,28 @@ export declare type PageHeaderProps = {
|
|
37
34
|
goback?: string | boolean;
|
38
35
|
image?: string;
|
39
36
|
loading?: boolean;
|
40
|
-
breadcrumb?:
|
41
|
-
extra?:
|
42
|
-
operation?:
|
43
|
-
tags?:
|
44
|
-
data?:
|
37
|
+
breadcrumb?: ProPageHeaderBreadcrumbItem[];
|
38
|
+
extra?: ProActionGroupProps | React.ReactNode;
|
39
|
+
operation?: ProActionGroupProps | React.ReactNode;
|
40
|
+
tags?: ProPageHeaderTagItem[];
|
41
|
+
data?: ProPageHeaderDataItem[];
|
45
42
|
info?: ProInfoProps | React.ReactNode;
|
46
43
|
} & Omit<React.HTMLAttributes<HTMLElement>, 'title'>;
|
47
|
-
declare const
|
48
|
-
export default
|
44
|
+
declare const ProPageHeader: React.FC<ProPageHeaderProps>;
|
45
|
+
export default ProPageHeader;
|
46
|
+
/**
|
47
|
+
* @deprecated 建议使用 ProPageHeaderBreadcrumbItem 代替
|
48
|
+
*/
|
49
|
+
export declare type BreadcrumbItem = ProPageHeaderBreadcrumbItem;
|
50
|
+
/**
|
51
|
+
* @deprecated 建议使用 ProPageHeaderTagItem 代替
|
52
|
+
*/
|
53
|
+
export declare type TagItem = ProPageHeaderTagItem;
|
54
|
+
/**
|
55
|
+
* @deprecated 建议使用 ProPageHeaderDataItem 代替
|
56
|
+
*/
|
57
|
+
export declare type DataItem = ProPageHeaderDataItem;
|
58
|
+
/**
|
59
|
+
* @deprecated 建议使用 ProPageHeaderProps 代替
|
60
|
+
*/
|
61
|
+
export declare type PageHeaderProps = ProPageHeaderProps;
|
package/es/page-header/index.js
CHANGED
@@ -1,9 +1,7 @@
|
|
1
|
-
var _excluded = ["text", "children"
|
2
|
-
_excluded2 = ["
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
1
|
+
var _excluded = ["text", "children"],
|
2
|
+
_excluded2 = ["text", "children", "closable"],
|
3
|
+
_excluded3 = ["color", "title", "num", "className"],
|
4
|
+
_excluded4 = ["title", "description", "icon", "iconColor", "iconBackgroundType", "iconBackgroundColor", "goback", "operation", "extra", "image", "loading", "breadcrumb", "tags", "data", "info", "children", "className", "style"];
|
7
5
|
|
8
6
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
9
7
|
|
@@ -11,14 +9,18 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
|
|
11
9
|
|
12
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; }
|
13
11
|
|
12
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
13
|
+
|
14
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
15
|
+
|
14
16
|
import React from 'react';
|
15
17
|
import { useHistory } from 'react-router-dom';
|
16
18
|
import classnames from 'classnames';
|
17
19
|
import TeamixIcon from '@teamix/icon';
|
18
20
|
import { Breadcrumb, Tag } from '@alicloudfe/components';
|
19
21
|
import { baseClass } from '@teamix/utils';
|
20
|
-
import {
|
21
|
-
import {
|
22
|
+
import { ProActionGroup } from '../actions';
|
23
|
+
import { ProSkeletonRaw } from '../skeleton';
|
22
24
|
import ProInfo from '../info';
|
23
25
|
import './index.scss';
|
24
26
|
var cls = baseClass('teamix-pro-page-header');
|
@@ -26,10 +28,13 @@ var cls = baseClass('teamix-pro-page-header');
|
|
26
28
|
var renderNav = function renderNav(breadcrumbs) {
|
27
29
|
if (breadcrumbs && breadcrumbs.length) {
|
28
30
|
return /*#__PURE__*/React.createElement(Breadcrumb, null, breadcrumbs.map(function (b, i) {
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
31
|
+
var text = b.text,
|
32
|
+
children = b.children,
|
33
|
+
others = _objectWithoutProperties(b, _excluded);
|
34
|
+
|
35
|
+
return /*#__PURE__*/React.createElement(Breadcrumb.Item, _objectSpread({
|
36
|
+
key: i
|
37
|
+
}, others), text || children);
|
33
38
|
}));
|
34
39
|
}
|
35
40
|
|
@@ -51,7 +56,7 @@ var renderActionGroup = function renderActionGroup(group, defaultProps) {
|
|
51
56
|
type: buttonType
|
52
57
|
}, item);
|
53
58
|
});
|
54
|
-
return /*#__PURE__*/React.createElement(
|
59
|
+
return /*#__PURE__*/React.createElement(ProActionGroup, _objectSpread(_objectSpread(_objectSpread({}, defaultProps), actionGroup), {}, {
|
55
60
|
actions: actions
|
56
61
|
}));
|
57
62
|
}
|
@@ -71,7 +76,7 @@ var renderTags = function renderTags(tags) {
|
|
71
76
|
var text = tag.text,
|
72
77
|
children = tag.children,
|
73
78
|
closable = tag.closable,
|
74
|
-
others = _objectWithoutProperties(tag,
|
79
|
+
others = _objectWithoutProperties(tag, _excluded2);
|
75
80
|
|
76
81
|
if (closable) {
|
77
82
|
return /*#__PURE__*/React.createElement(Tag.Closeable, _objectSpread({
|
@@ -126,26 +131,30 @@ var renderData = function renderData(data) {
|
|
126
131
|
}
|
127
132
|
|
128
133
|
return /*#__PURE__*/React.createElement(React.Fragment, null, data.map(function (item, i) {
|
129
|
-
var
|
134
|
+
var color = item.color,
|
135
|
+
title = item.title,
|
136
|
+
num = item.num,
|
137
|
+
customClassName = item.className,
|
138
|
+
others = _objectWithoutProperties(item, _excluded3);
|
139
|
+
|
140
|
+
var _getColorAndStyle = getColorAndStyle(color),
|
130
141
|
className = _getColorAndStyle.className,
|
131
142
|
style = _getColorAndStyle.style;
|
132
143
|
|
133
|
-
return /*#__PURE__*/React.createElement("div", {
|
144
|
+
return /*#__PURE__*/React.createElement("div", _objectSpread({
|
134
145
|
key: i,
|
135
|
-
className: cls('data-item')
|
136
|
-
}, /*#__PURE__*/React.createElement("div", {
|
146
|
+
className: classnames(cls('data-item'), customClassName)
|
147
|
+
}, others), /*#__PURE__*/React.createElement("div", {
|
137
148
|
className: cls('data-item-title')
|
138
|
-
},
|
149
|
+
}, title), /*#__PURE__*/React.createElement("div", {
|
139
150
|
className: classnames(cls('data-item-num'), className),
|
140
151
|
style: style
|
141
|
-
},
|
152
|
+
}, num));
|
142
153
|
}));
|
143
154
|
};
|
144
155
|
|
145
156
|
var renderInfo = function renderInfo(info) {
|
146
|
-
// @ts-ignore
|
147
157
|
if (info === null || info === void 0 ? void 0 : info.columns) {
|
148
|
-
// @ts-ignore
|
149
158
|
return /*#__PURE__*/React.createElement(ProInfo, _objectSpread({
|
150
159
|
type: "header"
|
151
160
|
}, info));
|
@@ -154,7 +163,7 @@ var renderInfo = function renderInfo(info) {
|
|
154
163
|
return info;
|
155
164
|
};
|
156
165
|
|
157
|
-
var
|
166
|
+
var ProPageHeader = function ProPageHeader(props) {
|
158
167
|
var title = props.title,
|
159
168
|
description = props.description,
|
160
169
|
icon = props.icon,
|
@@ -174,7 +183,7 @@ var PageHeader = function PageHeader(props) {
|
|
174
183
|
children = props.children,
|
175
184
|
className = props.className,
|
176
185
|
style = props.style,
|
177
|
-
others = _objectWithoutProperties(props,
|
186
|
+
others = _objectWithoutProperties(props, _excluded4);
|
178
187
|
|
179
188
|
var history = useHistory();
|
180
189
|
var backgroundImage = image ? "url('".concat(image, "')") : undefined;
|
@@ -224,7 +233,7 @@ var PageHeader = function PageHeader(props) {
|
|
224
233
|
className: cls('section')
|
225
234
|
}, /*#__PURE__*/React.createElement("nav", {
|
226
235
|
className: cls('nav')
|
227
|
-
}, loading && /*#__PURE__*/React.createElement(
|
236
|
+
}, loading && /*#__PURE__*/React.createElement(ProSkeletonRaw.Header.Nav, null), !loading && renderNav(breadcrumb)), /*#__PURE__*/React.createElement("section", {
|
228
237
|
className: cls('extra')
|
229
238
|
}, !loading && renderActionGroup(extra, {
|
230
239
|
type: 'text',
|
@@ -237,17 +246,17 @@ var PageHeader = function PageHeader(props) {
|
|
237
246
|
className: cls('left')
|
238
247
|
}, /*#__PURE__*/React.createElement("section", {
|
239
248
|
className: cls('title')
|
240
|
-
}, loading && /*#__PURE__*/React.createElement(
|
249
|
+
}, loading && /*#__PURE__*/React.createElement(ProSkeletonRaw.Header.Title, null), !loading && renderTitle()), description !== undefined && /*#__PURE__*/React.createElement("section", {
|
241
250
|
className: cls('description')
|
242
|
-
}, loading && /*#__PURE__*/React.createElement(
|
251
|
+
}, loading && /*#__PURE__*/React.createElement(ProSkeletonRaw.Header.Description, null), !loading && /*#__PURE__*/React.createElement(React.Fragment, null, description))), /*#__PURE__*/React.createElement("section", {
|
243
252
|
className: cls('right')
|
244
253
|
}, data && !loading && /*#__PURE__*/React.createElement("section", {
|
245
254
|
className: cls('data')
|
246
255
|
}, renderData(data)), /*#__PURE__*/React.createElement("section", {
|
247
256
|
className: cls('operation')
|
248
|
-
}, !loading && renderActionGroup(operation)))), info &&
|
257
|
+
}, !loading && renderActionGroup(operation)))), info && /*#__PURE__*/React.createElement("section", {
|
249
258
|
className: classnames(cls('section'), cls('info'))
|
250
|
-
}, renderInfo(info)), children);
|
259
|
+
}, !loading && renderInfo(info), loading && /*#__PURE__*/React.createElement(ProSkeletonRaw.Info.Header, null)), children);
|
251
260
|
};
|
252
261
|
|
253
|
-
export default
|
262
|
+
export default ProPageHeader;
|
@@ -32,6 +32,7 @@ $prefix: 'teamix-pro-page-header';
|
|
32
32
|
.#{$prefix}-info {
|
33
33
|
padding-top: var(--s-2, 8px);
|
34
34
|
margin-bottom: 0;
|
35
|
+
flex-direction: column;
|
35
36
|
}
|
36
37
|
|
37
38
|
.#{$prefix}-title {
|
@@ -62,7 +63,7 @@ $prefix: 'teamix-pro-page-header';
|
|
62
63
|
|
63
64
|
.#{$prefix}-description {
|
64
65
|
margin: var(--s-2, 8px) 0;
|
65
|
-
color: var(--color-text1-
|
66
|
+
color: var(--color-text1-2, #5a5a5a);
|
66
67
|
}
|
67
68
|
|
68
69
|
.#{$prefix}-data {
|
@@ -0,0 +1,11 @@
|
|
1
|
+
/** ProTable 空状态 */
|
2
|
+
import React from 'react';
|
3
|
+
import Result from '@teamix/result';
|
4
|
+
import { getMessage } from '@teamix/utils';
|
5
|
+
export default (function () {
|
6
|
+
return /*#__PURE__*/React.createElement(Result, {
|
7
|
+
theme: "hybridcloud-container",
|
8
|
+
img: "noData",
|
9
|
+
title: getMessage('noData')
|
10
|
+
});
|
11
|
+
});
|
@@ -1,8 +1,8 @@
|
|
1
1
|
import React from 'react';
|
2
2
|
import './index.scss';
|
3
|
-
import {
|
3
|
+
import { ProTableColumnProps, ProTableActionType } from '../../typing';
|
4
4
|
declare type ProTableFilterProps = {
|
5
|
-
column:
|
5
|
+
column: ProTableColumnProps;
|
6
6
|
actionRef: React.MutableRefObject<ProTableActionType | undefined>;
|
7
7
|
};
|
8
8
|
declare const Filter: React.FC<ProTableFilterProps>;
|
@@ -171,7 +171,7 @@ var Filter = function Filter(props) {
|
|
171
171
|
btn: true
|
172
172
|
}),
|
173
173
|
onClick: function onClick() {
|
174
|
-
var _actionRef$current2, _actionRef$current2$f, _actionRef$current$ge5, _actionRef$current3, _actionRef$current3$g, _actionRef$current3$g2, _actionRef$current4, _actionRef$
|
174
|
+
var _actionRef$current2, _actionRef$current2$f, _actionRef$current$ge5, _actionRef$current3, _actionRef$current3$g, _actionRef$current3$g2, _actionRef$current4, _actionRef$current5, _actionRef$current5$s, _actionRef$current6, _actionRef$current6$r, _actionRef$current7, _actionRef$current7$r;
|
175
175
|
|
176
176
|
(_actionRef$current2 = actionRef.current) === null || _actionRef$current2 === void 0 ? void 0 : (_actionRef$current2$f = _actionRef$current2.filterDataSource) === null || _actionRef$current2$f === void 0 ? void 0 : _actionRef$current2$f.call(_actionRef$current2, column.dataIndex); // 先获取此列的param
|
177
177
|
|
@@ -199,14 +199,22 @@ var Filter = function Filter(props) {
|
|
199
199
|
return null;
|
200
200
|
})), [[column.dataIndex, param]]).filter(function (item) {
|
201
201
|
return item && (item === null || item === void 0 ? void 0 : item[1]);
|
202
|
-
}));
|
202
|
+
}));
|
203
|
+
var targetPageKey = 'currentPage';
|
204
|
+
var pageInfo = (_actionRef$current4 = actionRef.current) === null || _actionRef$current4 === void 0 ? void 0 : _actionRef$current4.pageInfo;
|
205
|
+
|
206
|
+
if (pageInfo && (pageInfo === null || pageInfo === void 0 ? void 0 : pageInfo.targetPageKey)) {
|
207
|
+
targetPageKey = pageInfo === null || pageInfo === void 0 ? void 0 : pageInfo.targetPageKey;
|
208
|
+
} // 再设置所有的列筛选状态
|
203
209
|
|
204
|
-
(_actionRef$current4 = actionRef.current) === null || _actionRef$current4 === void 0 ? void 0 : (_actionRef$current4$r = _actionRef$current4.request) === null || _actionRef$current4$r === void 0 ? void 0 : _actionRef$current4$r.call(_actionRef$current4, _objectSpread({}, params)); // 再设置所有的列筛选状态
|
205
210
|
|
206
211
|
(_actionRef$current5 = actionRef.current) === null || _actionRef$current5 === void 0 ? void 0 : (_actionRef$current5$s = _actionRef$current5.setFilterRules) === null || _actionRef$current5$s === void 0 ? void 0 : _actionRef$current5$s.call(_actionRef$current5, _objectSpread(_objectSpread({}, rules), {}, _defineProperty({}, column.dataIndex, {
|
207
212
|
rules: selected,
|
208
213
|
params: param
|
209
|
-
})));
|
214
|
+
}))); // 发送请求
|
215
|
+
|
216
|
+
(_actionRef$current6 = actionRef.current) === null || _actionRef$current6 === void 0 ? void 0 : (_actionRef$current6$r = _actionRef$current6.request) === null || _actionRef$current6$r === void 0 ? void 0 : _actionRef$current6$r.call(_actionRef$current6, _objectSpread(_objectSpread({}, params), {}, _defineProperty({}, targetPageKey, 1)));
|
217
|
+
(_actionRef$current7 = actionRef.current) === null || _actionRef$current7 === void 0 ? void 0 : (_actionRef$current7$r = _actionRef$current7.resetPage) === null || _actionRef$current7$r === void 0 ? void 0 : _actionRef$current7$r.call(_actionRef$current7);
|
210
218
|
setVisible(false);
|
211
219
|
}
|
212
220
|
}, "\u786E\u5B9A"), /*#__PURE__*/React.createElement(Button, {
|
@@ -216,15 +224,15 @@ var Filter = function Filter(props) {
|
|
216
224
|
btn: true
|
217
225
|
}),
|
218
226
|
onClick: function onClick() {
|
219
|
-
var _actionRef$current$ge6, _actionRef$
|
227
|
+
var _actionRef$current$ge6, _actionRef$current8, _actionRef$current8$g, _actionRef$current8$g2, _actionRef$current9, _actionRef$current9$s, _actionRef$current10, _actionRef$current10$;
|
220
228
|
|
221
229
|
setSelected([]);
|
222
|
-
var rules = (_actionRef$current$ge6 = (_actionRef$
|
223
|
-
(_actionRef$
|
230
|
+
var rules = (_actionRef$current$ge6 = (_actionRef$current8 = actionRef.current) === null || _actionRef$current8 === void 0 ? void 0 : (_actionRef$current8$g = _actionRef$current8.getState) === null || _actionRef$current8$g === void 0 ? void 0 : (_actionRef$current8$g2 = _actionRef$current8$g.call(_actionRef$current8)) === null || _actionRef$current8$g2 === void 0 ? void 0 : _actionRef$current8$g2.filterRules) !== null && _actionRef$current$ge6 !== void 0 ? _actionRef$current$ge6 : {};
|
231
|
+
(_actionRef$current9 = actionRef.current) === null || _actionRef$current9 === void 0 ? void 0 : (_actionRef$current9$s = _actionRef$current9.setFilterRules) === null || _actionRef$current9$s === void 0 ? void 0 : _actionRef$current9$s.call(_actionRef$current9, _objectSpread(_objectSpread({}, rules), {}, _defineProperty({}, column.dataIndex, {
|
224
232
|
rules: [],
|
225
233
|
params: ''
|
226
234
|
})));
|
227
|
-
(_actionRef$
|
235
|
+
(_actionRef$current10 = actionRef.current) === null || _actionRef$current10 === void 0 ? void 0 : (_actionRef$current10$ = _actionRef$current10.filterDataSource) === null || _actionRef$current10$ === void 0 ? void 0 : _actionRef$current10$.call(_actionRef$current10, column.dataIndex); // setVisible(!visible);
|
228
236
|
}
|
229
237
|
}, "\u91CD\u7F6E")))));
|
230
238
|
};
|
@@ -28,7 +28,7 @@ import React, { useEffect, useState } from 'react';
|
|
28
28
|
import { Header, baseClass } from '@teamix/utils';
|
29
29
|
import { Button, Badge } from '@alicloudfe/components';
|
30
30
|
import TeamixIcon from '@teamix/icon';
|
31
|
-
import {
|
31
|
+
import { ProActionGroup } from '../../../actions';
|
32
32
|
import { SimpleFilter, AdvancedFilter, formilyReactive } from '../../../form';
|
33
33
|
import { getMessage } from '@teamix/utils';
|
34
34
|
import ToolBar from '../ToolBar';
|
@@ -77,7 +77,7 @@ var Layout = function Layout(props) {
|
|
77
77
|
};
|
78
78
|
return /*#__PURE__*/React.createElement("div", {
|
79
79
|
className: cls('main-action')
|
80
|
-
}, /*#__PURE__*/React.createElement(
|
80
|
+
}, /*#__PURE__*/React.createElement(ProActionGroup, _objectSpread(_objectSpread({}, mainAction), {}, {
|
81
81
|
context: _objectSpread(_objectSpread({}, defaultContext), mainAction.context)
|
82
82
|
})));
|
83
83
|
} else return mainAction;
|
@@ -1,8 +1,8 @@
|
|
1
1
|
import React from 'react';
|
2
|
-
import {
|
2
|
+
import { ProActionButtonProps } from '../../../actions';
|
3
3
|
import { ProTableActionType, innerRowSelectionType, rowSelectionType } from '../../typing';
|
4
4
|
interface QuickActionProps {
|
5
|
-
quickAction?:
|
5
|
+
quickAction?: ProActionButtonProps | React.ReactNode | React.ReactNode[];
|
6
6
|
actionRef: React.MutableRefObject<ProTableActionType | undefined>;
|
7
7
|
rowSelection?: innerRowSelectionType | rowSelectionType;
|
8
8
|
}
|
@@ -8,12 +8,12 @@ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "functi
|
|
8
8
|
|
9
9
|
import React from 'react';
|
10
10
|
import { Box } from '@alicloudfe/components';
|
11
|
-
import
|
11
|
+
import ProActionButton from '../../../actions';
|
12
12
|
|
13
13
|
var QuickAction = function QuickAction(props) {
|
14
14
|
var quickAction = props.quickAction,
|
15
15
|
actionRef = props.actionRef,
|
16
|
-
rowSelection = props.rowSelection; // 如果传对象的话,默认为主要文字类型的
|
16
|
+
rowSelection = props.rowSelection; // 如果传对象的话,默认为主要文字类型的 ProActionButton
|
17
17
|
|
18
18
|
if (_typeof(quickAction) === 'object') {
|
19
19
|
// 默认 context
|
@@ -23,7 +23,7 @@ var QuickAction = function QuickAction(props) {
|
|
23
23
|
};
|
24
24
|
return /*#__PURE__*/React.createElement("div", {
|
25
25
|
className: "teamix-pro-table-layout-quick-action"
|
26
|
-
}, /*#__PURE__*/React.createElement(
|
26
|
+
}, /*#__PURE__*/React.createElement(ProActionButton, _objectSpread(_objectSpread({
|
27
27
|
type: "primary",
|
28
28
|
text: true
|
29
29
|
}, quickAction), {}, {
|
package/es/table/index.js
CHANGED
@@ -36,7 +36,7 @@ import React, { useState, useEffect, useRef, useMemo } from 'react';
|
|
36
36
|
import { Table, Pagination, Message, Checkbox } from '@alicloudfe/components';
|
37
37
|
import genProColumnToColumn from './utils/genProColumnToColumn';
|
38
38
|
import { baseClass, useRequest, request as utilResquest, getDeepValue, getMessage, pickProps } from '@teamix/utils';
|
39
|
-
import {
|
39
|
+
import { ProSkeletonRaw as Skeleton } from '../skeleton';
|
40
40
|
import './index.scss';
|
41
41
|
import Layout from './components/Layout';
|
42
42
|
import { useActionType } from './utils';
|
@@ -44,8 +44,9 @@ import getTableProps from './utils/getTableProps';
|
|
44
44
|
import getTableSortIcons from './utils/getTableSortIcons';
|
45
45
|
import useTableSelection from './utils/useTableSelection';
|
46
46
|
import FullScreen from './components/ToolBar/Fullscreen';
|
47
|
+
import EmptyContent from './components/EmptyContent';
|
47
48
|
import { createForm, formilyReactive } from '../form';
|
48
|
-
import {
|
49
|
+
import { ProActionGroup } from '../actions';
|
49
50
|
import debounce from 'lodash.debounce';
|
50
51
|
import classNames from 'classnames';
|
51
52
|
export * from './typing';
|
@@ -193,7 +194,7 @@ var ProTable = function ProTable(props) {
|
|
193
194
|
setShowLoading = _useState20[1]; // 存储定时器 id
|
194
195
|
|
195
196
|
|
196
|
-
var autoRefreshTimerRef = useRef(); // 获取header
|
197
|
+
var autoRefreshTimerRef = useRef(); // 获取header高度,用作全屏吸底吸底高度计算
|
197
198
|
|
198
199
|
var getHeaderHeight = function getHeaderHeight() {
|
199
200
|
var _tableDom$getElements, _tableDom$getElements2;
|
@@ -223,13 +224,35 @@ var ProTable = function ProTable(props) {
|
|
223
224
|
var _useState23 = useState(false),
|
224
225
|
_useState24 = _slicedToArray(_useState23, 2),
|
225
226
|
fullscreenState = _useState24[0],
|
226
|
-
setFullscreenState = _useState24[1];
|
227
|
+
setFullscreenState = _useState24[1]; // 整个内容区是否超过一屏。用于表格在非全屏模式下的吸底
|
228
|
+
|
229
|
+
|
230
|
+
var _useState25 = useState(false),
|
231
|
+
_useState26 = _slicedToArray(_useState25, 2),
|
232
|
+
footerSuctionState = _useState26[0],
|
233
|
+
setFooterSuctionState = _useState26[1];
|
227
234
|
/** 筛选区域 form */
|
228
235
|
|
229
236
|
|
230
237
|
var dataFilterForm = useMemo(function () {
|
231
238
|
return createForm();
|
232
|
-
}, []); //
|
239
|
+
}, []); // 获取内容区是否超出一屏(仅支持全家桶)
|
240
|
+
|
241
|
+
var getFooterSuctionState = function getFooterSuctionState() {
|
242
|
+
var containerDom = document.querySelector('.teamix-pro-page-container');
|
243
|
+
|
244
|
+
if (containerDom) {
|
245
|
+
var offsetHeight = containerDom.offsetHeight;
|
246
|
+
var scrollHeight = containerDom.scrollHeight;
|
247
|
+
|
248
|
+
if (offsetHeight < scrollHeight) {
|
249
|
+
setFooterSuctionState(true);
|
250
|
+
} else {
|
251
|
+
setFooterSuctionState(false);
|
252
|
+
}
|
253
|
+
}
|
254
|
+
}; // rowSelection 相关
|
255
|
+
|
233
256
|
|
234
257
|
var rowSelectionHook = useTableSelection(_objectSpread(_objectSpread({}, propsRowSelection), {}, {
|
235
258
|
// 当初始出现骨架屏的时候,不可选择
|
@@ -345,12 +368,19 @@ var ProTable = function ProTable(props) {
|
|
345
368
|
return _request(params);
|
346
369
|
},
|
347
370
|
reset: function reset() {
|
348
|
-
|
371
|
+
var _actionRef$current, _actionRef$current$se;
|
372
|
+
|
373
|
+
(propsDataFilter === null || propsDataFilter === void 0 ? void 0 : propsDataFilter.onReset) && (propsDataFilter === null || propsDataFilter === void 0 ? void 0 : propsDataFilter.onReset()); // 清空列过滤参数
|
374
|
+
|
375
|
+
(_actionRef$current = actionRef.current) === null || _actionRef$current === void 0 ? void 0 : (_actionRef$current$se = _actionRef$current.setFilterRules) === null || _actionRef$current$se === void 0 ? void 0 : _actionRef$current$se.call(_actionRef$current, {});
|
349
376
|
dataFilterForm.reset();
|
350
377
|
setCurrentPage(1);
|
351
378
|
|
352
379
|
_request(_defineProperty({}, targetPageKey, 1));
|
353
380
|
},
|
381
|
+
resetPage: function resetPage() {
|
382
|
+
setCurrentPage(1);
|
383
|
+
},
|
354
384
|
clearRowSelection: function clearRowSelection() {
|
355
385
|
rowSelectionHook.setSelectedRowKeys([]);
|
356
386
|
rowSelectionHook.setSelectedRecords([]);
|
@@ -359,8 +389,11 @@ var ProTable = function ProTable(props) {
|
|
359
389
|
pageInfo: {
|
360
390
|
total: total,
|
361
391
|
current: currentPage,
|
392
|
+
targetPageKey: targetPageKey,
|
393
|
+
targetPageSizeKey: targetPageSizeKey,
|
362
394
|
pageSize: pageSize
|
363
395
|
},
|
396
|
+
dataFilterForm: dataFilterForm,
|
364
397
|
resetTableMaxBodyHeight: function resetTableMaxBodyHeight() {
|
365
398
|
getHeaderHeight().then(function (height) {
|
366
399
|
setHeaderHeight(height);
|
@@ -427,6 +460,11 @@ var ProTable = function ProTable(props) {
|
|
427
460
|
});
|
428
461
|
} else {
|
429
462
|
onFormatResult(nextData);
|
463
|
+
} // 重新计算是否需要吸底
|
464
|
+
|
465
|
+
|
466
|
+
if (footerSuction) {
|
467
|
+
getFooterSuctionState();
|
430
468
|
}
|
431
469
|
},
|
432
470
|
onError: function onError(error) {
|
@@ -436,12 +474,17 @@ var ProTable = function ProTable(props) {
|
|
436
474
|
props.onError(error);
|
437
475
|
} else {
|
438
476
|
Message.error(error.toString());
|
477
|
+
} // 重新计算是否需要吸底
|
478
|
+
|
479
|
+
|
480
|
+
if (footerSuction) {
|
481
|
+
getFooterSuctionState();
|
439
482
|
}
|
440
483
|
}
|
441
484
|
}); // 请求函数
|
442
485
|
|
443
486
|
function _request(params, noLoading) {
|
444
|
-
var _actionRef$current, _actionRef$
|
487
|
+
var _actionRef$current$ge, _actionRef$current2, _actionRef$current2$g, _objectSpread2;
|
445
488
|
|
446
489
|
// 如果没有传 url 且没有 customRequest,直接返回
|
447
490
|
if (!url && !customRequest) {
|
@@ -450,13 +493,15 @@ var ProTable = function ProTable(props) {
|
|
450
493
|
|
451
494
|
var nextShowLoading = !noLoading;
|
452
495
|
nextShowLoading !== showLoading && setShowLoading(nextShowLoading); // 请求前需要优先清空列过滤条件
|
496
|
+
// actionRef.current?.setFilterRules?.({});
|
453
497
|
|
454
|
-
(_actionRef$current = actionRef.current) === null || _actionRef$current === void 0 ? void 0 : (_actionRef$current$se = _actionRef$current.setFilterRules) === null || _actionRef$current$se === void 0 ? void 0 : _actionRef$current$se.call(_actionRef$current, {});
|
455
498
|
var sortParams = targetFormatSort(sort); // 筛选区请求参数
|
456
499
|
|
457
|
-
var dataFilterParams = toJS(dataFilterForm.values); //
|
500
|
+
var dataFilterParams = toJS(dataFilterForm.values); // 列过滤请求参数
|
458
501
|
|
459
|
-
var
|
502
|
+
var columnsFilterParams = (_actionRef$current$ge = (_actionRef$current2 = actionRef.current) === null || _actionRef$current2 === void 0 ? void 0 : (_actionRef$current2$g = _actionRef$current2.getFilterRules) === null || _actionRef$current2$g === void 0 ? void 0 : _actionRef$current2$g.call(_actionRef$current2)) !== null && _actionRef$current$ge !== void 0 ? _actionRef$current$ge : {}; // 格式化后的请求参数
|
503
|
+
|
504
|
+
var requestData = formatParams(_objectSpread(_objectSpread({}, !showPagination ? _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, dataFilterParams), propsParams), sortParams), columnsFilterParams) : _objectSpread(_objectSpread(_objectSpread(_objectSpread((_objectSpread2 = {}, _defineProperty(_objectSpread2, targetPageKey, currentPage), _defineProperty(_objectSpread2, targetPageSizeKey, pageSize), _objectSpread2), dataFilterParams), propsParams), sortParams), columnsFilterParams)), params));
|
460
505
|
|
461
506
|
if (requestData) {
|
462
507
|
if (autoRefreshTimerRef.current) {
|
@@ -503,6 +548,15 @@ var ProTable = function ProTable(props) {
|
|
503
548
|
}
|
504
549
|
|
505
550
|
useEffect(function () {
|
551
|
+
// 监听 浏览器变化 更吸底状态
|
552
|
+
if (footerSuction) {
|
553
|
+
getFooterSuctionState();
|
554
|
+
|
555
|
+
window.onresize = function () {
|
556
|
+
getFooterSuctionState();
|
557
|
+
};
|
558
|
+
}
|
559
|
+
|
506
560
|
if (requestWhenMount) {
|
507
561
|
_request();
|
508
562
|
}
|
@@ -511,6 +565,10 @@ var ProTable = function ProTable(props) {
|
|
511
565
|
if (autoRefreshTimerRef.current) {
|
512
566
|
clearTimeout(autoRefreshTimerRef.current);
|
513
567
|
}
|
568
|
+
|
569
|
+
if (window.onresize) {
|
570
|
+
window.onresize = null;
|
571
|
+
}
|
514
572
|
};
|
515
573
|
}, []);
|
516
574
|
|
@@ -526,9 +584,12 @@ var ProTable = function ProTable(props) {
|
|
526
584
|
var dataFilter = _objectSpread(_objectSpread({}, propsDataFilter), {}, {
|
527
585
|
onFilter: debounce(function () {
|
528
586
|
(propsDataFilter === null || propsDataFilter === void 0 ? void 0 : propsDataFilter.onFilter) && (propsDataFilter === null || propsDataFilter === void 0 ? void 0 : propsDataFilter.onFilter(_objectSpread({}, toJS(dataFilterForm.values))));
|
529
|
-
setCurrentPage(1);
|
530
587
|
|
531
|
-
|
588
|
+
if (dataFilterForm.validate()) {
|
589
|
+
setCurrentPage(1);
|
590
|
+
|
591
|
+
_request(_defineProperty({}, targetPageKey, 1));
|
592
|
+
}
|
532
593
|
}, filterDebounce),
|
533
594
|
onReset: function onReset() {
|
534
595
|
(propsDataFilter === null || propsDataFilter === void 0 ? void 0 : propsDataFilter.onReset) && (propsDataFilter === null || propsDataFilter === void 0 ? void 0 : propsDataFilter.onReset());
|
@@ -574,6 +635,7 @@ var ProTable = function ProTable(props) {
|
|
574
635
|
sort: sort,
|
575
636
|
primaryKey: primaryKey,
|
576
637
|
rowSelection: rowSelection,
|
638
|
+
emptyContent: /*#__PURE__*/React.createElement(EmptyContent, null),
|
577
639
|
sortIcons: getTableSortIcons(),
|
578
640
|
fixedHeader: fullscreenState,
|
579
641
|
// 102px 为 底部 50px + 空格10px + 顶部 24px padding
|
@@ -609,7 +671,7 @@ var ProTable = function ProTable(props) {
|
|
609
671
|
|
610
672
|
return /*#__PURE__*/React.createElement("div", {
|
611
673
|
className: cls('footer-action')
|
612
|
-
}, /*#__PURE__*/React.createElement(
|
674
|
+
}, /*#__PURE__*/React.createElement(ProActionGroup, _objectSpread(_objectSpread({}, targetFooterActions), {}, {
|
613
675
|
context: _objectSpread(_objectSpread({}, defaultContext), targetFooterActions === null || targetFooterActions === void 0 ? void 0 : targetFooterActions.context)
|
614
676
|
})));
|
615
677
|
} else return footerAction;
|
@@ -691,7 +753,7 @@ var ProTable = function ProTable(props) {
|
|
691
753
|
className: cls({
|
692
754
|
'': true,
|
693
755
|
fullscreen: fullscreenState,
|
694
|
-
'footer-suction': footerSuction
|
756
|
+
'footer-suction': footerSuctionState && footerSuction
|
695
757
|
}),
|
696
758
|
ref: tableRef
|
697
759
|
}, renderTable(), renderFooter()));
|