wt-enjoy-link-antd-repack 4.1.50 → 4.1.51
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/esm/component/BiuAButton/index.d.ts +4 -4
- package/dist/esm/component/BiuAForm/index.d.ts +1 -1
- package/dist/esm/component/BiuField/component/orderTypeSelect.d.ts +1 -1
- package/dist/esm/component/BiuTableSelect/index.d.ts +1 -1
- package/dist/esm/component/BiuTableSelect/index.js +13 -5
- package/dist/esm/component/BiuVirtualTable/index.d.ts +11 -3
- package/dist/esm/component/BiuVirtualTable/index.js +6 -1
- package/package.json +1 -1
@@ -3,16 +3,16 @@ export declare const BiuAButton: React.MemoExoticComponent<import("styled-compon
|
|
3
3
|
href: string;
|
4
4
|
target?: string | undefined;
|
5
5
|
onClick?: React.MouseEventHandler<HTMLElement> | undefined;
|
6
|
-
} & import("antd/lib/button/button").BaseButtonProps & Omit<React.AnchorHTMLAttributes<any>, "
|
6
|
+
} & import("antd/lib/button/button").BaseButtonProps & Omit<React.AnchorHTMLAttributes<any>, "type" | "onClick"> & {
|
7
7
|
htmlType?: "button" | "submit" | "reset" | undefined;
|
8
8
|
onClick?: React.MouseEventHandler<HTMLElement> | undefined;
|
9
|
-
} & Omit<React.ButtonHTMLAttributes<any>, "
|
9
|
+
} & Omit<React.ButtonHTMLAttributes<any>, "type" | "onClick">> & React.RefAttributes<HTMLElement>, never>> & Omit<React.ForwardRefExoticComponent<Partial<{
|
10
10
|
href: string;
|
11
11
|
target?: string | undefined;
|
12
12
|
onClick?: React.MouseEventHandler<HTMLElement> | undefined;
|
13
|
-
} & import("antd/lib/button/button").BaseButtonProps & Omit<React.AnchorHTMLAttributes<any>, "
|
13
|
+
} & import("antd/lib/button/button").BaseButtonProps & Omit<React.AnchorHTMLAttributes<any>, "type" | "onClick"> & {
|
14
14
|
htmlType?: "button" | "submit" | "reset" | undefined;
|
15
15
|
onClick?: React.MouseEventHandler<HTMLElement> | undefined;
|
16
|
-
} & Omit<React.ButtonHTMLAttributes<any>, "
|
16
|
+
} & Omit<React.ButtonHTMLAttributes<any>, "type" | "onClick">> & React.RefAttributes<HTMLElement>> & {
|
17
17
|
Group: React.FC<import("antd/lib/button").ButtonGroupProps>;
|
18
18
|
}, keyof React.Component<any, {}, any>>>;
|
@@ -2,6 +2,6 @@ import React from 'react';
|
|
2
2
|
export { Form as BiuAForm } from 'antd';
|
3
3
|
export declare const BiuAFormItem: React.MemoExoticComponent<(<Values = any>(props: import("antd").FormItemProps<Values>) => React.ReactElement<any, string | React.JSXElementConstructor<any>>) & {
|
4
4
|
useStatus: () => {
|
5
|
-
status?: "" | "
|
5
|
+
status?: "" | "warning" | "error" | "success" | "validating" | undefined;
|
6
6
|
};
|
7
7
|
}>;
|
@@ -9,7 +9,7 @@ declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponen
|
|
9
9
|
/**
|
10
10
|
* 0:入库 1:出库 2:移库 3:冻结 4:调整 5:属性变更
|
11
11
|
*/
|
12
|
-
orderType: 0 |
|
12
|
+
orderType: 0 | 3 | 1 | 4 | 2 | 5;
|
13
13
|
isFirstLoad: boolean;
|
14
14
|
} & SelectProps<any, import("antd/lib/select").DefaultOptionType> & React.RefAttributes<unknown>>>;
|
15
15
|
export default _default;
|
@@ -46,4 +46,4 @@ export declare const BiuTableSelect: React.MemoExoticComponent<React.ForwardRefE
|
|
46
46
|
* 转换下绑定到组件上的数据源
|
47
47
|
*/
|
48
48
|
dataOption?: ((value: Record<string, any>) => Record<string, any>[]) | undefined;
|
49
|
-
} & Pick<SelectProps<any, import("antd/lib/select").DefaultOptionType>, "showSearch" | "allowClear"> & Pick<TableProps<any>, "
|
49
|
+
} & Pick<SelectProps<any, import("antd/lib/select").DefaultOptionType>, "showSearch" | "allowClear"> & Pick<TableProps<any>, "dataSource" | "onRow"> & React.RefAttributes<unknown>>>;
|
@@ -21,9 +21,9 @@ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
21
21
|
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; }
|
22
22
|
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; }
|
23
23
|
import { SearchOutlined } from '@ant-design/icons';
|
24
|
-
import { useBoolean, useControllableValue } from 'ahooks';
|
24
|
+
import { useBoolean, useControllableValue, useWhyDidYouUpdate } from 'ahooks';
|
25
25
|
import { Divider, Space, Typography } from 'antd';
|
26
|
-
import React, { forwardRef, useCallback,
|
26
|
+
import React, { forwardRef, useCallback, useLayoutEffect, useMemo, useState } from 'react';
|
27
27
|
import { BiuASelect, BiuASelectOption } from "../BiuASelect";
|
28
28
|
import { request } from "../../package";
|
29
29
|
|
@@ -71,7 +71,9 @@ export var BiuTableSelect = /*#__PURE__*/React.memo( /*#__PURE__*/forwardRef(fun
|
|
71
71
|
setOptionRows = _useState2[1];
|
72
72
|
var isSearchDeatil = useMemo(function () {
|
73
73
|
return (!optionRows || optionRows.length <= 0) && !!state;
|
74
|
-
|
74
|
+
|
75
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
76
|
+
}, [state]);
|
75
77
|
var fetchData = useCallback( /*#__PURE__*/function () {
|
76
78
|
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(reqObj) {
|
77
79
|
var result, formatResult;
|
@@ -105,11 +107,17 @@ export var BiuTableSelect = /*#__PURE__*/React.memo( /*#__PURE__*/forwardRef(fun
|
|
105
107
|
return _ref.apply(this, arguments);
|
106
108
|
};
|
107
109
|
}(), [dataOption, interfaceName, isSearchDeatil, onChangeData, requestConfig, rowKey, setFalse, setTrue, state]);
|
108
|
-
|
110
|
+
useLayoutEffect(function () {
|
109
111
|
if (isOnReady && isOnReady(queryData) && queryData) {
|
110
112
|
fetchData(queryData);
|
111
113
|
}
|
112
|
-
|
114
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
115
|
+
}, [queryData]);
|
116
|
+
useWhyDidYouUpdate('BiuTableSelect', {
|
117
|
+
isOnReady: isOnReady,
|
118
|
+
queryData: queryData,
|
119
|
+
fetchData: fetchData
|
120
|
+
});
|
113
121
|
var columnsConvert = useMemo(function () {
|
114
122
|
return columns.reduce(function (obj, current) {
|
115
123
|
return {
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import type { TableProps } from 'antd';
|
2
2
|
import React from 'react';
|
3
3
|
import type { BiuColumnType } from "..";
|
4
|
-
export
|
4
|
+
export type BiuVirtualTablePropsType = Omit<TableProps<any>, 'columns' | 'scroll'> & {
|
5
5
|
columns: (Omit<BiuColumnType, 'width'> & {
|
6
6
|
width: number;
|
7
7
|
})[];
|
@@ -9,5 +9,13 @@ export interface BiuVirtualTablePropsType {
|
|
9
9
|
x: number;
|
10
10
|
y: number;
|
11
11
|
};
|
12
|
-
}
|
13
|
-
export declare const BiuVirtualTable: React.MemoExoticComponent<React.ForwardRefExoticComponent<
|
12
|
+
};
|
13
|
+
export declare const BiuVirtualTable: React.MemoExoticComponent<React.ForwardRefExoticComponent<Omit<TableProps<any>, "scroll" | "columns"> & {
|
14
|
+
columns: (Omit<BiuColumnType, 'width'> & {
|
15
|
+
width: number;
|
16
|
+
})[];
|
17
|
+
scroll: {
|
18
|
+
x: number;
|
19
|
+
y: number;
|
20
|
+
};
|
21
|
+
} & React.RefAttributes<unknown>>>;
|
@@ -18,8 +18,13 @@ import { Table } from 'antd';
|
|
18
18
|
import classNames from 'classnames';
|
19
19
|
import React, { forwardRef, useCallback, useEffect, useMemo, useRef, useState } from 'react';
|
20
20
|
import { VariableSizeGrid } from 'react-window';
|
21
|
+
import { styled } from 'styled-components';
|
21
22
|
import { jsx as _jsx } from "react/jsx-runtime";
|
22
23
|
var VariableSizeGridJSX = VariableSizeGrid;
|
24
|
+
var StyledTable = styled(Table).withConfig({
|
25
|
+
displayName: "StyledTable",
|
26
|
+
componentId: "wt-enjoy-link-antd-repack__sc-xp2a6l-0"
|
27
|
+
})([".ant-table-container{box-sizing:content-box;border:1px solid #f0f0f0 !important;}.virtual-grid{width:100% !important;overflow:scroll;&::-webkit-scrollbar{width:10px !important;}&::-webkit-scrollbar{width:10px;height:10px;}&::-webkit-scrollbar-button{width:0;height:0;}&::-webkit-scrollbar-thumb{background:#ccc;}&::-webkit-scrollbar-track{background-color:#e6e5e5;}}"]);
|
23
28
|
export var BiuVirtualTable = /*#__PURE__*/React.memo( /*#__PURE__*/forwardRef(function (props, parentRef) {
|
24
29
|
var columns = props.columns,
|
25
30
|
scroll = props.scroll,
|
@@ -145,7 +150,7 @@ export var BiuVirtualTable = /*#__PURE__*/React.memo( /*#__PURE__*/forwardRef(fu
|
|
145
150
|
}, [connectObject, domWidth, mergedColumns, renderVirtualListRow, scroll.y]);
|
146
151
|
return /*#__PURE__*/_jsx("div", {
|
147
152
|
ref: domRef,
|
148
|
-
children: /*#__PURE__*/_jsx(
|
153
|
+
children: /*#__PURE__*/_jsx(StyledTable, _objectSpread(_objectSpread({
|
149
154
|
ref: parentRef
|
150
155
|
}, restProps), {}, {
|
151
156
|
scroll: scroll,
|