@teamias/rex-pro 0.0.7 → 0.0.9
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/components/card-basic-info/index.d.ts +2 -2
- package/dist/components/card-basic-info/index.js +1 -1
- package/dist/components/card-basic-info/{style → v1/style}/index.js +1 -1
- package/dist/components/filter-form/index.d.ts +1 -1
- package/dist/components/filter-form/index.js +1 -1
- package/dist/components/filter-form/{filter-form.js → v1/filter-form.js} +3 -3
- package/dist/components/rex-pro-form/index.d.ts +1 -1
- package/dist/components/rex-pro-form/index.js +1 -1
- package/dist/components/rex-pro-table/index.d.ts +2 -2
- package/dist/components/rex-pro-table/index.js +1 -1
- package/dist/components/rex-pro-table/{components → v1/components}/modal-form/InlineForm.d.ts +1 -1
- package/dist/components/rex-pro-table/{components → v1/components}/modal-form/InlineForm.js +1 -1
- package/dist/components/rex-pro-table/{demo → v1/demo}/BasicRexProTable.js +12 -4
- package/dist/components/rex-pro-table/{rex-pro-table.js → v1/rex-pro-table.js} +7 -2
- package/dist/components/rex-pro-table/{style → v1/style}/index.js +4 -4
- package/dist/components/rex-pro-table/{types.d.ts → v1/types.d.ts} +5 -2
- package/package.json +2 -1
- /package/dist/components/card-basic-info/{card-basic-info.d.ts → v1/card-basic-info.d.ts} +0 -0
- /package/dist/components/card-basic-info/{card-basic-info.js → v1/card-basic-info.js} +0 -0
- /package/dist/components/card-basic-info/{demo → v1/demo}/BasicCardBasicInfo.d.ts +0 -0
- /package/dist/components/card-basic-info/{demo → v1/demo}/BasicCardBasicInfo.js +0 -0
- /package/dist/components/card-basic-info/{demo → v1/demo}/LinkContentType.d.ts +0 -0
- /package/dist/components/card-basic-info/{demo → v1/demo}/LinkContentType.js +0 -0
- /package/dist/components/card-basic-info/{demo → v1/demo}/TableUsage.d.ts +0 -0
- /package/dist/components/card-basic-info/{demo → v1/demo}/TableUsage.js +0 -0
- /package/dist/components/card-basic-info/{demo → v1/demo}/TagContentType.d.ts +0 -0
- /package/dist/components/card-basic-info/{demo → v1/demo}/TagContentType.js +0 -0
- /package/dist/components/card-basic-info/{demo → v1/demo}/TextAndTagContentType.d.ts +0 -0
- /package/dist/components/card-basic-info/{demo → v1/demo}/TextAndTagContentType.js +0 -0
- /package/dist/components/card-basic-info/{demo → v1/demo}/TextContentType.d.ts +0 -0
- /package/dist/components/card-basic-info/{demo → v1/demo}/TextContentType.js +0 -0
- /package/dist/components/card-basic-info/{style → v1/style}/index.d.ts +0 -0
- /package/dist/components/filter-form/{demo → v1/demo}/AverageFilterForm.d.ts +0 -0
- /package/dist/components/filter-form/{demo → v1/demo}/AverageFilterForm.js +0 -0
- /package/dist/components/filter-form/{demo → v1/demo}/BasicFilterForm.d.ts +0 -0
- /package/dist/components/filter-form/{demo → v1/demo}/BasicFilterForm.js +0 -0
- /package/dist/components/filter-form/{filter-form.d.ts → v1/filter-form.d.ts} +0 -0
- /package/dist/components/filter-form/{style → v1/style}/index.d.ts +0 -0
- /package/dist/components/filter-form/{style → v1/style}/index.js +0 -0
- /package/dist/components/rex-pro-form/{demo → v1/demo}/BasicRexProForm.d.ts +0 -0
- /package/dist/components/rex-pro-form/{demo → v1/demo}/BasicRexProForm.js +0 -0
- /package/dist/components/rex-pro-form/{rex-pro-form.d.ts → v1/rex-pro-form.d.ts} +0 -0
- /package/dist/components/rex-pro-form/{rex-pro-form.js → v1/rex-pro-form.js} +0 -0
- /package/dist/components/rex-pro-form/{style → v1/style}/index.d.ts +0 -0
- /package/dist/components/rex-pro-form/{style → v1/style}/index.js +0 -0
- /package/dist/components/rex-pro-table/{components → v1/components}/ActionButtons.d.ts +0 -0
- /package/dist/components/rex-pro-table/{components → v1/components}/ActionButtons.js +0 -0
- /package/dist/components/rex-pro-table/{components → v1/components}/drawer-table/InlineTable.d.ts +0 -0
- /package/dist/components/rex-pro-table/{components → v1/components}/drawer-table/InlineTable.js +0 -0
- /package/dist/components/rex-pro-table/{components → v1/components}/drawer-table/index.d.ts +0 -0
- /package/dist/components/rex-pro-table/{components → v1/components}/drawer-table/index.js +0 -0
- /package/dist/components/rex-pro-table/{components → v1/components}/modal-form/index.d.ts +0 -0
- /package/dist/components/rex-pro-table/{components → v1/components}/modal-form/index.js +0 -0
- /package/dist/components/rex-pro-table/{demo → v1/demo}/BasicRexProListTable.d.ts +0 -0
- /package/dist/components/rex-pro-table/{demo → v1/demo}/BasicRexProListTable.js +0 -0
- /package/dist/components/rex-pro-table/{demo → v1/demo}/BasicRexProTable.d.ts +0 -0
- /package/dist/components/rex-pro-table/{rex-pro-table.d.ts → v1/rex-pro-table.d.ts} +0 -0
- /package/dist/components/rex-pro-table/{style → v1/style}/index.d.ts +0 -0
- /package/dist/components/rex-pro-table/{types.js → v1/types.js} +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { CardBasicInfo } from './card-basic-info';
|
|
2
|
-
export type { CardBasicInfoProps } from './card-basic-info';
|
|
1
|
+
export { CardBasicInfo } from './v1/card-basic-info';
|
|
2
|
+
export type { CardBasicInfoProps } from './v1/card-basic-info';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { CardBasicInfo } from "./card-basic-info";
|
|
1
|
+
export { CardBasicInfo } from "./v1/card-basic-info";
|
|
@@ -15,5 +15,5 @@ export var CustomAntdCard = function CustomAntdCard(props) {
|
|
|
15
15
|
};
|
|
16
16
|
export var Card = styled(CustomAntdCard).withConfig({
|
|
17
17
|
displayName: "Card",
|
|
18
|
-
componentId: "rex-pro-aaf4__sc-
|
|
18
|
+
componentId: "rex-pro-aaf4__sc-8wv5e9-0"
|
|
19
19
|
})(["&.card-basic-info .data-cell-row-item,&.card-basic-info .data-cell-row-text-value{width:initial;}"]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './filter-form';
|
|
1
|
+
export * from './v1/filter-form';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// 导出主要组件
|
|
2
|
-
export * from "./filter-form";
|
|
2
|
+
export * from "./v1/filter-form";
|
|
@@ -21,9 +21,9 @@ import { cloneDeep } from 'lodash';
|
|
|
21
21
|
import { useEffect, useImperativeHandle, useRef } from 'react';
|
|
22
22
|
import { FilterFormAutoWidthStyle, FilterFormStyle } from "./style";
|
|
23
23
|
|
|
24
|
-
/**
|
|
25
|
-
* FilterForm 组件 - 支持多语言的筛选表单
|
|
26
|
-
* @param T 表单数据类型
|
|
24
|
+
/**
|
|
25
|
+
* FilterForm 组件 - 支持多语言的筛选表单
|
|
26
|
+
* @param T 表单数据类型
|
|
27
27
|
*/
|
|
28
28
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
29
29
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './rex-pro-form';
|
|
1
|
+
export * from './v1/rex-pro-form';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from "./rex-pro-form";
|
|
1
|
+
export * from "./v1/rex-pro-form";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { RexProTable } from './rex-pro-table';
|
|
2
|
-
export type * from './types';
|
|
1
|
+
export { RexProTable } from './v1/rex-pro-table';
|
|
2
|
+
export type * from './v1/types';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { RexProTable } from "./rex-pro-table";
|
|
1
|
+
export { RexProTable } from "./v1/rex-pro-table";
|
package/dist/components/rex-pro-table/{components → v1/components}/modal-form/InlineForm.d.ts
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { FC } from 'react';
|
|
2
2
|
import { ModalAction, ProModalFormProps } from '../../types';
|
|
3
|
-
export declare const ContainerInlineForm: FC<Omit<import("
|
|
3
|
+
export declare const ContainerInlineForm: FC<Omit<import("../../../../rex-pro-form").RexProFormProps<Record<string, unknown>>, "actionRef"> & {
|
|
4
4
|
actionRef: ModalAction;
|
|
5
5
|
/** 操作成功回调 */
|
|
6
6
|
onFinish?: ProModalFormProps['onFinish'];
|
|
@@ -19,7 +19,7 @@ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) r
|
|
|
19
19
|
import { requestFieldsContainerHoc, useRequestFieldsConfig, useRexProConfigProvider } from '@teamias/rex-design';
|
|
20
20
|
import { Button } from 'antd';
|
|
21
21
|
import { useState } from 'react';
|
|
22
|
-
import { RexProForm } from "
|
|
22
|
+
import { RexProForm } from "../../../../rex-pro-form";
|
|
23
23
|
import { ModalFormButtonGroup } from "../../style";
|
|
24
24
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
25
25
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
@@ -13,7 +13,7 @@ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o =
|
|
|
13
13
|
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
14
14
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
15
15
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
16
|
-
import enUS from "
|
|
16
|
+
import enUS from "../../../../locales/en-US.json";
|
|
17
17
|
import { RequestFieldsContainer, RexProConfigProvider, designLocales } from '@teamias/rex-design';
|
|
18
18
|
import { crush } from 'radash';
|
|
19
19
|
import { useRef, useState } from 'react';
|
|
@@ -655,7 +655,8 @@ export default (function () {
|
|
|
655
655
|
}, {
|
|
656
656
|
title: '供应商',
|
|
657
657
|
dataIndex: 'factory',
|
|
658
|
-
key: 'factory'
|
|
658
|
+
key: 'factory',
|
|
659
|
+
sorter: 'factory'
|
|
659
660
|
}, {
|
|
660
661
|
title: 'ASIN',
|
|
661
662
|
dataIndex: 'asin',
|
|
@@ -1071,14 +1072,21 @@ export default (function () {
|
|
|
1071
1072
|
}
|
|
1072
1073
|
},
|
|
1073
1074
|
request: /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
|
|
1075
|
+
var _len2,
|
|
1076
|
+
args,
|
|
1077
|
+
_key2,
|
|
1078
|
+
_args2 = arguments;
|
|
1074
1079
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
1075
1080
|
while (1) switch (_context2.prev = _context2.next) {
|
|
1076
1081
|
case 0:
|
|
1077
|
-
|
|
1082
|
+
for (_len2 = _args2.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
|
|
1083
|
+
args[_key2] = _args2[_key2];
|
|
1084
|
+
}
|
|
1085
|
+
console.log('调用次', args);
|
|
1078
1086
|
state.selectKeys = [];
|
|
1079
1087
|
update({});
|
|
1080
1088
|
return _context2.abrupt("return", JSON.parse(JSON.stringify(tableData)));
|
|
1081
|
-
case
|
|
1089
|
+
case 5:
|
|
1082
1090
|
case "end":
|
|
1083
1091
|
return _context2.stop();
|
|
1084
1092
|
}
|
|
@@ -13,12 +13,12 @@ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o =
|
|
|
13
13
|
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
14
14
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
15
15
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
16
|
+
import { FilterForm } from "../../filter-form";
|
|
16
17
|
import { ProForm } from '@ant-design/pro-components';
|
|
17
18
|
import { BaseListTable, BaseTable, useRequestFieldsConfig, useRexProConfigProvider, useStateData } from '@teamias/rex-design';
|
|
18
19
|
import { Card, Pagination, Skeleton, Space } from 'antd';
|
|
19
20
|
import { cloneDeep } from 'lodash';
|
|
20
21
|
import React, { useImperativeHandle, useRef } from 'react';
|
|
21
|
-
import { FilterForm } from "../filter-form";
|
|
22
22
|
import { ActionButtons } from "./components/ActionButtons";
|
|
23
23
|
import { TableActionButtonGroup, ToolbarBox, Wrapper } from "./style";
|
|
24
24
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
@@ -321,7 +321,12 @@ var InlineRexProTable = function InlineRexProTable(_ref) {
|
|
|
321
321
|
customEmptyText: state.customEmptyText,
|
|
322
322
|
loading: state.loading,
|
|
323
323
|
pagination: false,
|
|
324
|
-
extraColumns: extraColumns
|
|
324
|
+
extraColumns: extraColumns,
|
|
325
|
+
onChange: function onChange(pagination, filters, sorter) {
|
|
326
|
+
state.params.sort = JSON.parse(JSON.stringify(sorter || {}));
|
|
327
|
+
state.params.filter = JSON.parse(JSON.stringify(filters || {}));
|
|
328
|
+
action.getList(1);
|
|
329
|
+
}
|
|
325
330
|
})), (_state$dataSource = state.dataSource) !== null && _state$dataSource !== void 0 && _state$dataSource.length && !hidePagination ? /*#__PURE__*/_jsx(Pagination, {
|
|
326
331
|
style: {
|
|
327
332
|
marginTop: 10
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import styled, { createGlobalStyle } from 'styled-components';
|
|
2
2
|
export var Wrapper = styled.div.withConfig({
|
|
3
3
|
displayName: "Wrapper",
|
|
4
|
-
componentId: "rex-pro-aaf4__sc-
|
|
4
|
+
componentId: "rex-pro-aaf4__sc-r7dyvb-0"
|
|
5
5
|
})(["&.pro-rex-table-box{display:flex;flex-direction:column;gap:10px;.pro-rex-table-card{flex:1;}}"]);
|
|
6
6
|
export var ToolbarBox = styled.div.withConfig({
|
|
7
7
|
displayName: "ToolbarBox",
|
|
8
|
-
componentId: "rex-pro-aaf4__sc-
|
|
8
|
+
componentId: "rex-pro-aaf4__sc-r7dyvb-1"
|
|
9
9
|
})(["&.pro-rex-toolbar-box{display:flex;gap:10px;align-items:center;margin-bottom:10px;}"]);
|
|
10
10
|
export var TableActionButtonGroup = styled.div.withConfig({
|
|
11
11
|
displayName: "TableActionButtonGroup",
|
|
12
|
-
componentId: "rex-pro-aaf4__sc-
|
|
12
|
+
componentId: "rex-pro-aaf4__sc-r7dyvb-2"
|
|
13
13
|
})(["&.pro-rex-table-action-button-group{display:flex;gap:6px;justify-content:center;align-items:center;}"]);
|
|
14
14
|
export var ModalSearchStyle = createGlobalStyle([".pro-rex-table-modal-search .ant-drawer-body{padding:12px;}.pro-rex-table-modal-search .pro-rex-table-box{height:100%;}.pro-rex-table-modal-search .ant-drawer-header{padding:10px 12px;}.pro-rex-table-modal-search .ant-drawer-title{font-size:14px;}"]);
|
|
15
15
|
export var ModalFormStyle = createGlobalStyle([".pro-modal-form-body .ant-modal-body{max-height:", ";height:", ";overflow-y:auto}"], function (props) {
|
|
@@ -19,5 +19,5 @@ export var ModalFormStyle = createGlobalStyle([".pro-modal-form-body .ant-modal-
|
|
|
19
19
|
});
|
|
20
20
|
export var ModalFormButtonGroup = styled.div.withConfig({
|
|
21
21
|
displayName: "ModalFormButtonGroup",
|
|
22
|
-
componentId: "rex-pro-aaf4__sc-
|
|
22
|
+
componentId: "rex-pro-aaf4__sc-r7dyvb-3"
|
|
23
23
|
})(["&.pro-modal-form-button-group{display:flex;gap:8px;justify-content:flex-end;position:sticky;bottom:0;background:#fff;}"]);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
+
import { FilterForm, IFilterFormProps } from "../../filter-form";
|
|
1
2
|
import { BaseListTable, BaseTable, RequestFieldsContainer, TButtonFilterItem } from '@teamias/rex-design';
|
|
2
3
|
import { Button, DrawerProps, DropDownProps, FormInstance, GetProps, ModalProps } from 'antd';
|
|
3
4
|
import { SizeType } from 'antd/es/config-provider/SizeContext';
|
|
4
5
|
import { MutableRefObject, ReactNode } from 'react';
|
|
5
|
-
import { FilterForm, IFilterFormProps } from '../filter-form';
|
|
6
6
|
/** 组件props */
|
|
7
7
|
export interface IRexProTableProps<TF extends Record<string, unknown>, TT extends Record<string, unknown>> {
|
|
8
8
|
toolbar?: {
|
|
@@ -156,7 +156,10 @@ export type TRexProTableRequestParams<T> = {
|
|
|
156
156
|
page_size: number;
|
|
157
157
|
current: number;
|
|
158
158
|
};
|
|
159
|
-
sort:
|
|
159
|
+
sort: {
|
|
160
|
+
field?: string;
|
|
161
|
+
order?: 'ascend' | 'descend';
|
|
162
|
+
};
|
|
160
163
|
filter: unknown;
|
|
161
164
|
};
|
|
162
165
|
/** 接口回调 */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@teamias/rex-pro",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.9",
|
|
4
4
|
"description": "A react library developed with dumi",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"module": "dist/index.js",
|
|
@@ -91,6 +91,7 @@
|
|
|
91
91
|
"react-dom": ">=16.9.0",
|
|
92
92
|
"react-intl": ">=3.0.0"
|
|
93
93
|
},
|
|
94
|
+
"packageManager": "pnpm@9.15.9",
|
|
94
95
|
"publishConfig": {
|
|
95
96
|
"access": "public"
|
|
96
97
|
},
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/dist/components/rex-pro-table/{components → v1/components}/drawer-table/InlineTable.d.ts
RENAMED
|
File without changes
|
/package/dist/components/rex-pro-table/{components → v1/components}/drawer-table/InlineTable.js
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|