doui-react 1.0.2 → 2.0.0
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/es/api/component/common.d.ts +2 -2
- package/es/api/component/common.js +3 -0
- package/es/api/component/global-style.d.ts +0 -1
- package/es/api/component/global-style.js +2 -3
- package/es/api/component/react-dom.js +9 -21
- package/es/button/component/index.js +8 -9
- package/es/button/type/index.d.ts +3 -7
- package/es/checkbox/type/index.d.ts +1 -1
- package/es/date-picker/component/index.js +13 -17
- package/es/date-picker/type/index.d.ts +5 -14
- package/es/form/component/constant.js +2 -2
- package/es/form/component/form-item-map.d.ts +1 -1
- package/es/form/component/form-item.js +1 -3
- package/es/form/component/form-list.d.ts +2 -2
- package/es/form/component/utils.d.ts +36 -26
- package/es/form/component/utils.js +1 -1
- package/es/form/style/form-item.d.ts +1 -1
- package/es/form/style/form-item.js +4 -11
- package/es/form/style/index.js +2 -2
- package/es/form/type/form-item.d.ts +5 -6
- package/es/form/type/form-list.d.ts +2 -2
- package/es/form/type/index.d.ts +3 -3
- package/es/grid/component/pagination.d.ts +72 -15
- package/es/icon/hook/index.d.ts +195 -190
- package/es/input/component/number.d.ts +1 -1
- package/es/input/component/number.js +8 -30
- package/es/input/component/utils.d.ts +0 -1
- package/es/input/component/utils.js +0 -3
- package/es/input/type/index.d.ts +3 -3
- package/es/modal-prompt/component/utils.js +2 -1
- package/es/modal-prompt/type/index.d.ts +2 -2
- package/es/open-modal/component/footer.d.ts +1 -1
- package/es/open-modal/component/footer.js +2 -4
- package/es/open-modal/component/modal.js +14 -6
- package/es/open-modal/component/utils.js +2 -6
- package/es/open-modal/hook/use-modal.js +1 -1
- package/es/open-modal/style/index.js +1 -2
- package/es/open-modal/style/wrap.js +1 -1
- package/es/open-modal/type/index.d.ts +1 -1
- package/es/radio/component/abstract-box.d.ts +86 -114
- package/es/radio/component/abstract-box.js +1 -5
- package/es/radio/component/use-radio.d.ts +7 -5
- package/es/radio/type/index.d.ts +2 -2
- package/es/select/component/use-select.js +4 -7
- package/es/select/component/utils.d.ts +1 -2
- package/es/select/type/index.d.ts +1 -1
- package/es/stack/style/index.d.ts +2 -1
- package/es/switch/type/index.d.ts +2 -2
- package/es/table/component/action-button.js +0 -1
- package/es/table/component/filter.d.ts +1 -1
- package/es/table/component/filter.js +1 -1
- package/es/table/component/sort.d.ts +1 -1
- package/es/table/component/time.js +2 -2
- package/es/table/component/utils.d.ts +3 -77
- package/es/table/component/utils.js +1 -3
- package/es/table/hook/search.d.ts +1 -1
- package/es/table/hook/search.js +8 -6
- package/es/table/type/action.d.ts +2 -7
- package/es/table/type/column.d.ts +3 -3
- package/es/tabs/component/utils.d.ts +7 -7
- package/es/tabs/type/index.d.ts +1 -1
- package/es/text/component/index.js +15 -16
- package/es/text/component/use-text.d.ts +3 -2
- package/es/text/component/use-text.js +12 -19
- package/es/text/component/utils.d.ts +1 -1
- package/es/text/style/index.js +1 -1
- package/es/text/type/index.d.ts +2 -2
- package/es/tooltip/component/index.d.ts +30 -20
- package/es/tooltip/component/index.js +6 -2
- package/es/tooltip/type/index.d.ts +1 -1
- package/es/tree/component/index.d.ts +1 -1
- package/es/tree/style/index.js +1 -1
- package/es/tree-select/component/use-tree-select.js +4 -4
- package/es/tree-select/style/index.js +1 -1
- package/es/virtual-list/type/index.d.ts +1 -1
- package/lib/api/component/common.d.ts +2 -2
- package/lib/api/component/common.js +3 -0
- package/lib/api/component/global-style.d.ts +0 -1
- package/lib/api/component/global-style.js +3 -4
- package/lib/api/component/react-dom.js +9 -21
- package/lib/button/component/index.js +8 -9
- package/lib/button/type/index.d.ts +3 -7
- package/lib/checkbox/type/index.d.ts +1 -1
- package/lib/date-picker/component/index.js +13 -17
- package/lib/date-picker/type/index.d.ts +5 -14
- package/lib/form/component/constant.js +2 -2
- package/lib/form/component/form-item-map.d.ts +1 -1
- package/lib/form/component/form-item.js +1 -3
- package/lib/form/component/form-list.d.ts +2 -2
- package/lib/form/component/utils.d.ts +36 -26
- package/lib/form/component/utils.js +1 -1
- package/lib/form/style/form-item.d.ts +1 -1
- package/lib/form/style/form-item.js +4 -11
- package/lib/form/style/index.js +1 -1
- package/lib/form/type/form-item.d.ts +5 -6
- package/lib/form/type/form-list.d.ts +2 -2
- package/lib/form/type/index.d.ts +3 -3
- package/lib/grid/component/pagination.d.ts +72 -15
- package/lib/icon/hook/index.d.ts +195 -190
- package/lib/input/component/number.d.ts +1 -1
- package/lib/input/component/number.js +7 -28
- package/lib/input/component/utils.d.ts +0 -1
- package/lib/input/component/utils.js +0 -4
- package/lib/input/type/index.d.ts +3 -3
- package/lib/modal-prompt/component/utils.js +2 -1
- package/lib/modal-prompt/type/index.d.ts +2 -2
- package/lib/open-modal/component/footer.d.ts +1 -1
- package/lib/open-modal/component/footer.js +2 -4
- package/lib/open-modal/component/modal.js +12 -4
- package/lib/open-modal/component/utils.js +2 -6
- package/lib/open-modal/hook/use-modal.js +1 -1
- package/lib/open-modal/style/index.js +1 -2
- package/lib/open-modal/style/wrap.js +1 -1
- package/lib/open-modal/type/index.d.ts +1 -1
- package/lib/radio/component/abstract-box.d.ts +86 -114
- package/lib/radio/component/abstract-box.js +1 -5
- package/lib/radio/component/use-radio.d.ts +7 -5
- package/lib/radio/type/index.d.ts +2 -2
- package/lib/select/component/use-select.js +4 -7
- package/lib/select/component/utils.d.ts +1 -2
- package/lib/select/type/index.d.ts +1 -1
- package/lib/stack/style/index.d.ts +2 -1
- package/lib/switch/type/index.d.ts +2 -2
- package/lib/table/component/action-button.js +0 -1
- package/lib/table/component/filter.d.ts +1 -1
- package/lib/table/component/filter.js +1 -1
- package/lib/table/component/sort.d.ts +1 -1
- package/lib/table/component/time.js +2 -2
- package/lib/table/component/utils.d.ts +3 -77
- package/lib/table/component/utils.js +1 -3
- package/lib/table/hook/search.d.ts +1 -1
- package/lib/table/hook/search.js +8 -6
- package/lib/table/type/action.d.ts +2 -7
- package/lib/table/type/column.d.ts +3 -3
- package/lib/tabs/component/utils.d.ts +7 -7
- package/lib/tabs/type/index.d.ts +1 -1
- package/lib/text/component/index.js +15 -16
- package/lib/text/component/use-text.d.ts +3 -2
- package/lib/text/component/use-text.js +11 -18
- package/lib/text/component/utils.d.ts +1 -1
- package/lib/text/style/index.js +1 -1
- package/lib/text/type/index.d.ts +2 -2
- package/lib/tooltip/component/index.d.ts +30 -20
- package/lib/tooltip/component/index.js +6 -2
- package/lib/tooltip/type/index.d.ts +1 -1
- package/lib/tree/component/index.d.ts +1 -1
- package/lib/tree/style/index.js +1 -1
- package/lib/tree-select/component/use-tree-select.js +4 -4
- package/lib/tree-select/style/index.js +1 -1
- package/lib/virtual-list/type/index.d.ts +1 -1
- package/package.json +10 -13
|
@@ -81,7 +81,7 @@ function getModalAndFormProps(props) {
|
|
|
81
81
|
footer: _lodash.default.isNull(formProps.footer) ? null : undefined,
|
|
82
82
|
// 为 null 时,不显示 footer
|
|
83
83
|
css: _style.default.wrapper({
|
|
84
|
-
bodyBottomMargin: getBodyBottomMargin(bodyBottomMargin
|
|
84
|
+
bodyBottomMargin: getBodyBottomMargin(bodyBottomMargin),
|
|
85
85
|
titleCenter: titleCenter
|
|
86
86
|
}),
|
|
87
87
|
style: modalProps.centered ? {} : {
|
|
@@ -94,14 +94,10 @@ function getModalAndFormProps(props) {
|
|
|
94
94
|
modalProps: mergedModalProps
|
|
95
95
|
};
|
|
96
96
|
}
|
|
97
|
-
function getBodyBottomMargin(bodyBottomMargin
|
|
98
|
-
var _formProps$items;
|
|
97
|
+
function getBodyBottomMargin(bodyBottomMargin) {
|
|
99
98
|
if (!_lodash.default.isNil(bodyBottomMargin)) {
|
|
100
99
|
return (0, _api.transformValueWithStyleUnit)(bodyBottomMargin);
|
|
101
100
|
}
|
|
102
|
-
if ((_formProps$items = formProps.items) !== null && _formProps$items !== void 0 && _formProps$items.length) {
|
|
103
|
-
return '10px';
|
|
104
|
-
}
|
|
105
101
|
}
|
|
106
102
|
function shouldEnableButton(_ref2) {
|
|
107
103
|
var _onValidate;
|
|
@@ -7,7 +7,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.useModal = useModal;
|
|
8
8
|
var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread2"));
|
|
9
9
|
var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
|
|
10
|
-
var _usePatchElement3 = _interopRequireDefault(require("antd/
|
|
10
|
+
var _usePatchElement3 = _interopRequireDefault(require("antd/es/_util/hooks/usePatchElement"));
|
|
11
11
|
var _lodash = _interopRequireDefault(require("lodash"));
|
|
12
12
|
var _component = require("../component");
|
|
13
13
|
var _jsxRuntime = require("@emotion/react/jsx-runtime");
|
|
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports.default = void 0;
|
|
8
8
|
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
|
|
9
|
-
var _api = require("../../api");
|
|
10
9
|
var _react = require("@emotion/react");
|
|
11
10
|
var _templateObject, _templateObject2, _templateObject3;
|
|
12
11
|
function titleStyle(titleCenter) {
|
|
@@ -19,7 +18,7 @@ var style = {
|
|
|
19
18
|
wrapper: function wrapper(_ref) {
|
|
20
19
|
var bodyBottomMargin = _ref.bodyBottomMargin,
|
|
21
20
|
titleCenter = _ref.titleCenter;
|
|
22
|
-
return (0, _react.css)(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n
|
|
21
|
+
return (0, _react.css)(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n .ant-modal-title {\n font-size: 16px;\n ", "\n }\n\n .ant-modal-body {\n padding-bottom: ", ";\n }\n "])), titleStyle(titleCenter), bodyBottomMargin);
|
|
23
22
|
}
|
|
24
23
|
};
|
|
25
24
|
var _default = exports.default = style;
|
|
@@ -9,5 +9,5 @@ var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/hel
|
|
|
9
9
|
var _css = require("@emotion/css");
|
|
10
10
|
var _templateObject;
|
|
11
11
|
function getWrapStyle(wrapStyle) {
|
|
12
|
-
return (0, _css.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n
|
|
12
|
+
return (0, _css.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n ", "\n "])), wrapStyle);
|
|
13
13
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { FunctionReturn } from "../../api";
|
|
2
2
|
import { FormInstance, FormItemProps, FormProps, FormValues } from "../../form";
|
|
3
3
|
import { CSSObject } from '@emotion/react';
|
|
4
|
-
import { ModalProps as AntdModalProps } from 'antd/
|
|
4
|
+
import type { ModalProps as AntdModalProps } from 'antd/es/modal';
|
|
5
5
|
import { ReactNode } from 'react';
|
|
6
6
|
type AntdComponentProps = Omit<AntdModalProps, 'onOk' | 'children'> & Omit<FormProps, 'children' | 'content' | 'title'>;
|
|
7
7
|
/**
|
|
@@ -1,92 +1,60 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { BaseBoxProps } from "..";
|
|
3
3
|
import type { SerializedStyles } from '@emotion/utils';
|
|
4
|
-
import { CheckboxChangeEvent } from 'antd/
|
|
4
|
+
import { CheckboxChangeEvent } from 'antd/es/checkbox/Checkbox';
|
|
5
5
|
export declare function useAbstractBox({ refs, boxTooltip, value, onChange, inGroup, ...props }: BaseBoxProps): {
|
|
6
6
|
highlightTextProps: Partial<BaseBoxProps>;
|
|
7
7
|
tooltipProps: {
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
color?: string | undefined;
|
|
9
|
+
title?: import("react").ReactNode | import("antd/es/_util/getRenderPropValue").RenderFunction;
|
|
10
|
+
overlay?: import("react").ReactNode | import("antd/es/_util/getRenderPropValue").RenderFunction;
|
|
11
|
+
styles?: Partial<Record<"body" | "root", import("react").CSSProperties>> | undefined;
|
|
12
|
+
classNames?: Partial<Record<"body" | "root", string>> | undefined;
|
|
10
13
|
style?: import("react").CSSProperties | undefined;
|
|
11
14
|
className?: string | undefined;
|
|
12
|
-
|
|
13
|
-
placement?: import("antd/
|
|
14
|
-
builtinPlacements?: import("rc-trigger").BuildInPlacements | undefined;
|
|
15
|
+
rootClassName?: string | undefined;
|
|
16
|
+
placement?: import("antd/es/tooltip").TooltipPlacement | undefined;
|
|
17
|
+
builtinPlacements?: import("@rc-component/trigger").BuildInPlacements | undefined;
|
|
15
18
|
openClassName?: string | undefined;
|
|
16
19
|
arrowPointAtCenter?: boolean | undefined;
|
|
17
|
-
|
|
20
|
+
arrow?: boolean | {
|
|
21
|
+
arrowPointAtCenter?: boolean | undefined;
|
|
22
|
+
pointAtCenter?: boolean | undefined;
|
|
23
|
+
} | undefined;
|
|
24
|
+
autoAdjustOverflow?: boolean | import("antd/es/tooltip").AdjustOverflow | undefined;
|
|
18
25
|
getPopupContainer?: ((triggerNode: HTMLElement) => HTMLElement) | undefined;
|
|
19
26
|
children?: import("react").ReactNode;
|
|
20
|
-
|
|
27
|
+
destroyTooltipOnHide?: boolean | {
|
|
28
|
+
keepParent?: boolean | undefined;
|
|
29
|
+
} | undefined;
|
|
30
|
+
destroyOnHidden?: boolean | undefined;
|
|
21
31
|
open?: boolean | undefined;
|
|
22
|
-
defaultVisible?: boolean | undefined;
|
|
23
32
|
defaultOpen?: boolean | undefined;
|
|
24
|
-
onVisibleChange?: ((visible: boolean) => void) | undefined;
|
|
25
33
|
onOpenChange?: ((visible: boolean) => void) | undefined;
|
|
26
|
-
afterVisibleChange?: ((visible: boolean) => void) | undefined;
|
|
27
34
|
afterOpenChange?: ((visible: boolean) => void) | undefined;
|
|
28
|
-
zIndex?: number | undefined;
|
|
29
|
-
animation?: string | undefined;
|
|
30
|
-
motion?: import("rc-motion").CSSMotionProps | undefined;
|
|
31
|
-
id?: string | undefined;
|
|
32
|
-
prefixCls?: string | undefined;
|
|
33
|
-
onPopupAlign?: ((element: HTMLElement, align: import("rc-trigger/lib/interface").AlignType) => void) | undefined;
|
|
34
|
-
trigger?: string | string[] | undefined;
|
|
35
|
-
transitionName?: string | undefined;
|
|
36
|
-
overlayStyle?: import("react").CSSProperties | undefined;
|
|
37
|
-
overlayClassName?: string | undefined;
|
|
38
|
-
mouseEnterDelay?: number | undefined;
|
|
39
|
-
mouseLeaveDelay?: number | undefined;
|
|
40
|
-
getTooltipContainer?: ((node: HTMLElement) => HTMLElement) | undefined;
|
|
41
|
-
destroyTooltipOnHide?: boolean | {
|
|
42
|
-
keepParent?: boolean | undefined;
|
|
43
|
-
} | undefined;
|
|
44
|
-
align: import("rc-trigger/lib/interface").AlignType;
|
|
45
|
-
showArrow?: boolean | undefined;
|
|
46
|
-
arrowContent?: import("react").ReactNode;
|
|
47
|
-
popupVisible?: boolean | undefined;
|
|
48
|
-
overlayInnerStyle?: import("react").CSSProperties | undefined;
|
|
49
|
-
} | {
|
|
50
|
-
title?: import("react").ReactNode | import("antd/lib/tooltip").RenderFunction;
|
|
51
|
-
overlay?: import("react").ReactNode | import("antd/lib/tooltip").RenderFunction;
|
|
52
|
-
style?: import("react").CSSProperties | undefined;
|
|
53
|
-
className?: string | undefined;
|
|
54
|
-
color?: string | undefined;
|
|
55
|
-
placement?: import("antd/lib/tooltip").TooltipPlacement | undefined;
|
|
56
|
-
builtinPlacements?: import("rc-trigger").BuildInPlacements | undefined;
|
|
57
|
-
openClassName?: string | undefined;
|
|
58
|
-
arrowPointAtCenter?: boolean | undefined;
|
|
59
|
-
autoAdjustOverflow?: boolean | import("antd/lib/tooltip").AdjustOverflow | undefined;
|
|
60
|
-
getPopupContainer?: ((triggerNode: HTMLElement) => HTMLElement) | undefined;
|
|
61
|
-
children?: import("react").ReactNode;
|
|
62
35
|
visible?: boolean | undefined;
|
|
63
|
-
open?: boolean | undefined;
|
|
64
36
|
defaultVisible?: boolean | undefined;
|
|
65
|
-
defaultOpen?: boolean | undefined;
|
|
66
37
|
onVisibleChange?: ((visible: boolean) => void) | undefined;
|
|
67
|
-
onOpenChange?: ((visible: boolean) => void) | undefined;
|
|
68
38
|
afterVisibleChange?: ((visible: boolean) => void) | undefined;
|
|
69
|
-
afterOpenChange?: ((visible: boolean) => void) | undefined;
|
|
70
39
|
zIndex?: number | undefined;
|
|
71
40
|
animation?: string | undefined;
|
|
72
41
|
motion?: import("rc-motion").CSSMotionProps | undefined;
|
|
73
42
|
id?: string | undefined;
|
|
74
43
|
prefixCls?: string | undefined;
|
|
75
|
-
onPopupAlign?: ((element: HTMLElement, align: import("rc-trigger/lib/interface").AlignType) => void) | undefined;
|
|
76
|
-
trigger?: string | string[] | undefined;
|
|
77
44
|
transitionName?: string | undefined;
|
|
78
|
-
overlayStyle?: import("react").CSSProperties | undefined;
|
|
79
|
-
overlayClassName?: string | undefined;
|
|
80
45
|
mouseEnterDelay?: number | undefined;
|
|
81
46
|
mouseLeaveDelay?: number | undefined;
|
|
47
|
+
onPopupAlign?: ((element: HTMLElement, align: import("@rc-component/trigger").AlignType) => void) | undefined;
|
|
48
|
+
overlayClassName?: string | undefined;
|
|
49
|
+
align?: import("@rc-component/trigger").AlignType | undefined;
|
|
50
|
+
overlayStyle?: import("react").CSSProperties | undefined;
|
|
51
|
+
trigger?: import("@rc-component/trigger").ActionType | import("@rc-component/trigger").ActionType[] | undefined;
|
|
52
|
+
popupVisible?: boolean | undefined;
|
|
53
|
+
forceRender?: boolean | undefined;
|
|
54
|
+
fresh?: boolean | undefined;
|
|
82
55
|
getTooltipContainer?: ((node: HTMLElement) => HTMLElement) | undefined;
|
|
83
|
-
|
|
84
|
-
keepParent?: boolean | undefined;
|
|
85
|
-
} | undefined;
|
|
86
|
-
align: import("rc-trigger/lib/interface").AlignType;
|
|
87
|
-
showArrow?: boolean | undefined;
|
|
56
|
+
showArrow?: boolean | import("@rc-component/trigger").ArrowType | undefined;
|
|
88
57
|
arrowContent?: import("react").ReactNode;
|
|
89
|
-
popupVisible?: boolean | undefined;
|
|
90
58
|
overlayInnerStyle?: import("react").CSSProperties | undefined;
|
|
91
59
|
};
|
|
92
60
|
boxProps: {
|
|
@@ -98,94 +66,63 @@ export declare function useAbstractBox({ refs, boxTooltip, value, onChange, inGr
|
|
|
98
66
|
boxTooltip?: import("react").ReactNode | import("antd").TooltipProps;
|
|
99
67
|
inGroup?: boolean | undefined;
|
|
100
68
|
style?: import("react").CSSProperties | undefined;
|
|
101
|
-
|
|
69
|
+
title?: string | undefined;
|
|
102
70
|
className?: string | undefined;
|
|
103
|
-
onClick?: import("react").MouseEventHandler<HTMLElement> | undefined;
|
|
104
|
-
defaultChecked?: boolean | undefined;
|
|
105
|
-
autoFocus?: boolean | undefined;
|
|
106
71
|
id?: string | undefined;
|
|
72
|
+
name?: string | undefined;
|
|
73
|
+
type?: string | undefined;
|
|
107
74
|
tabIndex?: number | undefined;
|
|
108
75
|
onKeyDown?: import("react").KeyboardEventHandler<HTMLElement> | undefined;
|
|
109
76
|
onKeyPress?: import("react").KeyboardEventHandler<HTMLElement> | undefined;
|
|
77
|
+
onClick?: import("react").MouseEventHandler<HTMLElement> | undefined;
|
|
110
78
|
onMouseEnter?: import("react").MouseEventHandler<HTMLElement> | undefined;
|
|
111
79
|
onMouseLeave?: import("react").MouseEventHandler<HTMLElement> | undefined;
|
|
112
80
|
disabled?: boolean | undefined;
|
|
113
|
-
name?: string | undefined;
|
|
114
|
-
prefixCls?: string | undefined;
|
|
115
81
|
checked?: boolean | undefined;
|
|
82
|
+
required?: boolean | undefined;
|
|
83
|
+
defaultChecked?: boolean | undefined;
|
|
84
|
+
autoFocus?: boolean | undefined;
|
|
85
|
+
prefixCls?: string | undefined;
|
|
86
|
+
rootClassName?: string | undefined;
|
|
116
87
|
indeterminate?: boolean | undefined;
|
|
117
88
|
skipGroup?: boolean | undefined;
|
|
118
|
-
rows?: number | false | undefined;
|
|
119
|
-
tooltip?: import("react").ReactNode | import("antd").TooltipProps;
|
|
120
|
-
autoShowTooltip?: boolean | undefined;
|
|
121
89
|
slot?: string | undefined;
|
|
122
|
-
title?: string | undefined;
|
|
123
90
|
accessKey?: string | undefined;
|
|
91
|
+
dir?: string | undefined;
|
|
124
92
|
color?: string | undefined;
|
|
125
93
|
content?: string | undefined;
|
|
126
|
-
direction?: import("antd/
|
|
127
|
-
translate?: "
|
|
128
|
-
defaultValue?: string | number | readonly string[] | undefined;
|
|
129
|
-
suppressContentEditableWarning?: boolean | undefined;
|
|
94
|
+
direction?: import("antd/es/config-provider").DirectionType;
|
|
95
|
+
translate?: "no" | "yes" | undefined;
|
|
130
96
|
suppressHydrationWarning?: boolean | undefined;
|
|
131
|
-
autoCapitalize?: "none" | (string & {}) | "off" | "on" | "sentences" | "words" | "characters" | undefined;
|
|
132
|
-
contentEditable?: (boolean | "true" | "false") | "inherit" | undefined;
|
|
133
|
-
contextMenu?: string | undefined;
|
|
134
|
-
dir?: string | undefined;
|
|
135
|
-
draggable?: (boolean | "true" | "false") | undefined;
|
|
136
|
-
enterKeyHint?: "search" | "done" | "enter" | "go" | "next" | "previous" | "send" | undefined;
|
|
137
|
-
hidden?: boolean | undefined;
|
|
138
97
|
lang?: string | undefined;
|
|
139
|
-
nonce?: string | undefined;
|
|
140
|
-
placeholder?: string | undefined;
|
|
141
|
-
spellCheck?: (boolean | "true" | "false") | undefined;
|
|
142
|
-
radioGroup?: string | undefined;
|
|
143
98
|
role?: import("react").AriaRole | undefined;
|
|
144
|
-
about?: string | undefined;
|
|
145
|
-
datatype?: string | undefined;
|
|
146
|
-
inlist?: any;
|
|
147
|
-
prefix?: string | undefined;
|
|
148
|
-
property?: string | undefined;
|
|
149
|
-
rel?: string | undefined;
|
|
150
|
-
resource?: string | undefined;
|
|
151
|
-
rev?: string | undefined;
|
|
152
|
-
typeof?: string | undefined;
|
|
153
|
-
vocab?: string | undefined;
|
|
154
|
-
autoCorrect?: string | undefined;
|
|
155
|
-
autoSave?: string | undefined;
|
|
156
|
-
itemProp?: string | undefined;
|
|
157
|
-
itemScope?: boolean | undefined;
|
|
158
|
-
itemType?: string | undefined;
|
|
159
|
-
itemID?: string | undefined;
|
|
160
|
-
itemRef?: string | undefined;
|
|
161
|
-
results?: number | undefined;
|
|
162
|
-
security?: string | undefined;
|
|
163
|
-
unselectable?: "off" | "on" | undefined;
|
|
164
|
-
inputMode?: "search" | "none" | "text" | "tel" | "url" | "email" | "numeric" | "decimal" | undefined;
|
|
165
|
-
is?: string | undefined;
|
|
166
99
|
"aria-activedescendant"?: string | undefined;
|
|
167
100
|
"aria-atomic"?: (boolean | "true" | "false") | undefined;
|
|
168
101
|
"aria-autocomplete"?: "none" | "list" | "inline" | "both" | undefined;
|
|
102
|
+
"aria-braillelabel"?: string | undefined;
|
|
103
|
+
"aria-brailleroledescription"?: string | undefined;
|
|
169
104
|
"aria-busy"?: (boolean | "true" | "false") | undefined;
|
|
170
105
|
"aria-checked"?: boolean | "true" | "false" | "mixed" | undefined;
|
|
171
106
|
"aria-colcount"?: number | undefined;
|
|
172
107
|
"aria-colindex"?: number | undefined;
|
|
108
|
+
"aria-colindextext"?: string | undefined;
|
|
173
109
|
"aria-colspan"?: number | undefined;
|
|
174
110
|
"aria-controls"?: string | undefined;
|
|
175
111
|
"aria-current"?: boolean | "time" | "page" | "true" | "false" | "step" | "location" | "date" | undefined;
|
|
176
112
|
"aria-describedby"?: string | undefined;
|
|
113
|
+
"aria-description"?: string | undefined;
|
|
177
114
|
"aria-details"?: string | undefined;
|
|
178
115
|
"aria-disabled"?: (boolean | "true" | "false") | undefined;
|
|
179
|
-
"aria-dropeffect"?: "
|
|
116
|
+
"aria-dropeffect"?: "link" | "none" | "copy" | "execute" | "move" | "popup" | undefined;
|
|
180
117
|
"aria-errormessage"?: string | undefined;
|
|
181
118
|
"aria-expanded"?: (boolean | "true" | "false") | undefined;
|
|
182
119
|
"aria-flowto"?: string | undefined;
|
|
183
120
|
"aria-grabbed"?: (boolean | "true" | "false") | undefined;
|
|
184
|
-
"aria-haspopup"?: boolean | "dialog" | "menu" | "grid" | "
|
|
121
|
+
"aria-haspopup"?: boolean | "dialog" | "menu" | "grid" | "listbox" | "tree" | "true" | "false" | undefined;
|
|
185
122
|
"aria-hidden"?: (boolean | "true" | "false") | undefined;
|
|
186
123
|
"aria-invalid"?: boolean | "true" | "false" | "grammar" | "spelling" | undefined;
|
|
187
124
|
"aria-keyshortcuts"?: string | undefined;
|
|
188
|
-
|
|
125
|
+
'aria-label'?: string | undefined;
|
|
189
126
|
"aria-labelledby"?: string | undefined;
|
|
190
127
|
"aria-level"?: number | undefined;
|
|
191
128
|
"aria-live"?: "off" | "assertive" | "polite" | undefined;
|
|
@@ -203,6 +140,7 @@ export declare function useAbstractBox({ refs, boxTooltip, value, onChange, inGr
|
|
|
203
140
|
"aria-roledescription"?: string | undefined;
|
|
204
141
|
"aria-rowcount"?: number | undefined;
|
|
205
142
|
"aria-rowindex"?: number | undefined;
|
|
143
|
+
"aria-rowindextext"?: string | undefined;
|
|
206
144
|
"aria-rowspan"?: number | undefined;
|
|
207
145
|
"aria-selected"?: (boolean | "true" | "false") | undefined;
|
|
208
146
|
"aria-setsize"?: number | undefined;
|
|
@@ -226,12 +164,10 @@ export declare function useAbstractBox({ refs, boxTooltip, value, onChange, inGr
|
|
|
226
164
|
onCompositionStartCapture?: import("react").CompositionEventHandler<HTMLElement> | undefined;
|
|
227
165
|
onCompositionUpdate?: import("react").CompositionEventHandler<HTMLElement> | undefined;
|
|
228
166
|
onCompositionUpdateCapture?: import("react").CompositionEventHandler<HTMLElement> | undefined;
|
|
229
|
-
onFocus?: import("react").FocusEventHandler<HTMLElement> | undefined;
|
|
230
167
|
onFocusCapture?: import("react").FocusEventHandler<HTMLElement> | undefined;
|
|
231
|
-
onBlur?: import("react").FocusEventHandler<HTMLElement> | undefined;
|
|
232
168
|
onBlurCapture?: import("react").FocusEventHandler<HTMLElement> | undefined;
|
|
233
169
|
onChangeCapture?: import("react").FormEventHandler<HTMLElement> | undefined;
|
|
234
|
-
onBeforeInput?: import("react").
|
|
170
|
+
onBeforeInput?: import("react").InputEventHandler<HTMLElement> | undefined;
|
|
235
171
|
onBeforeInputCapture?: import("react").FormEventHandler<HTMLElement> | undefined;
|
|
236
172
|
onInput?: import("react").FormEventHandler<HTMLElement> | undefined;
|
|
237
173
|
onInputCapture?: import("react").FormEventHandler<HTMLElement> | undefined;
|
|
@@ -345,9 +281,7 @@ export declare function useAbstractBox({ refs, boxTooltip, value, onChange, inGr
|
|
|
345
281
|
onPointerCancel?: import("react").PointerEventHandler<HTMLElement> | undefined;
|
|
346
282
|
onPointerCancelCapture?: import("react").PointerEventHandler<HTMLElement> | undefined;
|
|
347
283
|
onPointerEnter?: import("react").PointerEventHandler<HTMLElement> | undefined;
|
|
348
|
-
onPointerEnterCapture?: import("react").PointerEventHandler<HTMLElement> | undefined;
|
|
349
284
|
onPointerLeave?: import("react").PointerEventHandler<HTMLElement> | undefined;
|
|
350
|
-
onPointerLeaveCapture?: import("react").PointerEventHandler<HTMLElement> | undefined;
|
|
351
285
|
onPointerOver?: import("react").PointerEventHandler<HTMLElement> | undefined;
|
|
352
286
|
onPointerOverCapture?: import("react").PointerEventHandler<HTMLElement> | undefined;
|
|
353
287
|
onPointerOut?: import("react").PointerEventHandler<HTMLElement> | undefined;
|
|
@@ -368,6 +302,44 @@ export declare function useAbstractBox({ refs, boxTooltip, value, onChange, inGr
|
|
|
368
302
|
onAnimationIterationCapture?: import("react").AnimationEventHandler<HTMLElement> | undefined;
|
|
369
303
|
onTransitionEnd?: import("react").TransitionEventHandler<HTMLElement> | undefined;
|
|
370
304
|
onTransitionEndCapture?: import("react").TransitionEventHandler<HTMLElement> | undefined;
|
|
305
|
+
tooltip?: import("react").ReactNode | import("antd").TooltipProps;
|
|
306
|
+
hidden?: boolean | undefined;
|
|
307
|
+
contextMenu?: string | undefined;
|
|
308
|
+
defaultValue?: string | number | readonly string[] | undefined;
|
|
309
|
+
prefix?: string | undefined;
|
|
310
|
+
suppressContentEditableWarning?: boolean | undefined;
|
|
311
|
+
autoCapitalize?: (string & {}) | "none" | "off" | "on" | "sentences" | "words" | "characters" | undefined;
|
|
312
|
+
contentEditable?: "inherit" | (boolean | "true" | "false") | "plaintext-only" | undefined;
|
|
313
|
+
draggable?: (boolean | "true" | "false") | undefined;
|
|
314
|
+
enterKeyHint?: "search" | "done" | "enter" | "next" | "go" | "previous" | "send" | undefined;
|
|
315
|
+
nonce?: string | undefined;
|
|
316
|
+
spellCheck?: (boolean | "true" | "false") | undefined;
|
|
317
|
+
radioGroup?: string | undefined;
|
|
318
|
+
about?: string | undefined;
|
|
319
|
+
datatype?: string | undefined;
|
|
320
|
+
inlist?: any;
|
|
321
|
+
property?: string | undefined;
|
|
322
|
+
rel?: string | undefined;
|
|
323
|
+
resource?: string | undefined;
|
|
324
|
+
rev?: string | undefined;
|
|
325
|
+
typeof?: string | undefined;
|
|
326
|
+
vocab?: string | undefined;
|
|
327
|
+
autoCorrect?: string | undefined;
|
|
328
|
+
autoSave?: string | undefined;
|
|
329
|
+
itemProp?: string | undefined;
|
|
330
|
+
itemScope?: boolean | undefined;
|
|
331
|
+
itemType?: string | undefined;
|
|
332
|
+
itemID?: string | undefined;
|
|
333
|
+
itemRef?: string | undefined;
|
|
334
|
+
results?: number | undefined;
|
|
335
|
+
security?: string | undefined;
|
|
336
|
+
unselectable?: "off" | "on" | undefined;
|
|
337
|
+
inputMode?: "search" | "text" | "none" | "email" | "tel" | "url" | "numeric" | "decimal" | undefined;
|
|
338
|
+
is?: string | undefined;
|
|
339
|
+
exportparts?: string | undefined;
|
|
340
|
+
part?: string | undefined;
|
|
341
|
+
rows?: number | false | undefined;
|
|
342
|
+
autoShowTooltip?: boolean | undefined;
|
|
371
343
|
refs?: import("../../api").Refs | undefined;
|
|
372
344
|
ref: import("../../api").Refs | undefined;
|
|
373
345
|
};
|
|
@@ -53,11 +53,7 @@ function useAbstractBox(_ref2) {
|
|
|
53
53
|
var _parseHighlightTextAn = (0, _utils.parseHighlightTextAndRestProps)(props),
|
|
54
54
|
highlightTextProps = _parseHighlightTextAn.highlightTextProps,
|
|
55
55
|
restProps = _parseHighlightTextAn.restProps;
|
|
56
|
-
var tooltipProps = (0, _objectSpread3.default)({
|
|
57
|
-
align: {
|
|
58
|
-
offset: [0, 1]
|
|
59
|
-
}
|
|
60
|
-
}, (0, _text.generateTooltip)(boxTooltip));
|
|
56
|
+
var tooltipProps = (0, _objectSpread3.default)({}, (0, _text.generateTooltip)(boxTooltip));
|
|
61
57
|
var boxProps = (0, _objectSpread3.default)((0, _objectSpread3.default)({
|
|
62
58
|
ref: refs
|
|
63
59
|
}, restProps), {}, (0, _defineProperty2.default)((0, _defineProperty2.default)({}, inGroup ? 'value' : 'checked', value), "onChange", function onChange(e) {
|
|
@@ -1,23 +1,25 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { RadioProps } from "..";
|
|
3
|
-
import { RadioChangeEvent } from 'antd/
|
|
3
|
+
import { RadioChangeEvent } from 'antd/es/radio/interface';
|
|
4
4
|
export declare function useRadio({ onChange, ...props }: RadioProps): {
|
|
5
5
|
options: any[];
|
|
6
6
|
onChange: (e: RadioChangeEvent) => void;
|
|
7
7
|
defaultValue?: any;
|
|
8
8
|
value: any;
|
|
9
|
-
size?: import("antd/
|
|
10
|
-
disabled?:
|
|
9
|
+
size?: import("antd/es/button").ButtonSize;
|
|
10
|
+
disabled?: boolean | undefined;
|
|
11
11
|
onMouseEnter?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
12
12
|
onMouseLeave?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
|
|
13
13
|
name?: string | undefined;
|
|
14
14
|
children?: import("react").ReactNode;
|
|
15
15
|
id?: string | undefined;
|
|
16
|
-
optionType?: import("antd/
|
|
17
|
-
buttonStyle?: import("antd/
|
|
16
|
+
optionType?: import("antd/es/radio/interface").RadioGroupOptionType | undefined;
|
|
17
|
+
buttonStyle?: import("antd/es/radio/interface").RadioGroupButtonStyle | undefined;
|
|
18
18
|
onFocus?: import("react").FocusEventHandler<HTMLDivElement> | undefined;
|
|
19
19
|
onBlur?: import("react").FocusEventHandler<HTMLDivElement> | undefined;
|
|
20
|
+
block?: boolean | undefined;
|
|
20
21
|
prefixCls?: string | undefined;
|
|
21
22
|
className?: string | undefined;
|
|
23
|
+
rootClassName?: string | undefined;
|
|
22
24
|
style?: import("react").CSSProperties | undefined;
|
|
23
25
|
};
|
|
@@ -2,9 +2,9 @@ import { BaseComponentProps, BaseFlexProps } from "../../api";
|
|
|
2
2
|
import { BaseSelectProps } from "../../select";
|
|
3
3
|
import { TextProps } from "../../text";
|
|
4
4
|
import { RadioGroupProps } from 'antd';
|
|
5
|
-
import { CheckboxProps as AntdCheckboxProps } from 'antd/
|
|
5
|
+
import { CheckboxProps as AntdCheckboxProps } from 'antd/es/checkbox/Checkbox';
|
|
6
6
|
import { ReactNode } from 'react';
|
|
7
|
-
export interface BaseBoxProps extends Omit<AntdCheckboxProps, 'onChange'>, TextProps, BaseComponentProps {
|
|
7
|
+
export interface BaseBoxProps extends Omit<AntdCheckboxProps, 'onChange' | 'onBlur' | 'onFocus'>, Omit<TextProps, 'onBlur' | 'onFocus'>, BaseComponentProps {
|
|
8
8
|
children?: ReactNode;
|
|
9
9
|
text?: ReactNode;
|
|
10
10
|
/**
|
|
@@ -64,10 +64,7 @@ function renderMaxTag(omittedValues) {
|
|
|
64
64
|
return (0, _jsxRuntime.jsxs)(_text.Text, {
|
|
65
65
|
autoShowTooltip: false,
|
|
66
66
|
tooltip: {
|
|
67
|
-
title: tooltip
|
|
68
|
-
align: {
|
|
69
|
-
offset: [0, 0]
|
|
70
|
-
}
|
|
67
|
+
title: tooltip
|
|
71
68
|
},
|
|
72
69
|
children: ["+", omittedValues.length, "..."]
|
|
73
70
|
});
|
|
@@ -110,7 +107,7 @@ function useSelect(_ref3) {
|
|
|
110
107
|
})),
|
|
111
108
|
displayOptions = _useSelectOptions.displayOptions,
|
|
112
109
|
restSelectProps = (0, _objectWithoutProperties2.default)(_useSelectOptions, _excluded2);
|
|
113
|
-
function
|
|
110
|
+
function onOpenChange(open) {
|
|
114
111
|
setOpen(open);
|
|
115
112
|
setSearch('');
|
|
116
113
|
}
|
|
@@ -130,7 +127,7 @@ function useSelect(_ref3) {
|
|
|
130
127
|
optionFilterProp: 'originLabel',
|
|
131
128
|
optionLabelProp: 'originLabel',
|
|
132
129
|
getPopupContainer: _api.getPopupContainer,
|
|
133
|
-
|
|
130
|
+
popupRender: customRenderDropdown,
|
|
134
131
|
maxTagPlaceholder: renderMaxTag
|
|
135
132
|
}, (0, _utils.getComponentProps)(restSelectProps)), {}, {
|
|
136
133
|
placeholder: placeholder,
|
|
@@ -138,6 +135,6 @@ function useSelect(_ref3) {
|
|
|
138
135
|
loading: loading,
|
|
139
136
|
options: displayOptions,
|
|
140
137
|
onSearch: showSearch ? setSearch : undefined,
|
|
141
|
-
|
|
138
|
+
onOpenChange: onOpenChange
|
|
142
139
|
});
|
|
143
140
|
}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { FormValues } from "../../form";
|
|
2
2
|
import { BaseSelectProps, SelectOptions } from "..";
|
|
3
|
-
import { DependencyList } from 'react';
|
|
4
3
|
export declare function generateOptions({ options, sort, ...rest }: BaseSelectProps): any[];
|
|
5
4
|
export declare function getOptionsValue(options?: SelectOptions): (string | number)[];
|
|
6
5
|
interface DependenciesProps {
|
|
7
6
|
values?: FormValues;
|
|
8
|
-
deps?:
|
|
7
|
+
deps?: string[];
|
|
9
8
|
search: string;
|
|
10
9
|
isFunctionOptions: boolean;
|
|
11
10
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { BaseComponentProps, FunctionReturn } from "../../api";
|
|
2
2
|
import { UseFetchOptions } from "../../hooks";
|
|
3
3
|
import { TextProps } from "../../text";
|
|
4
|
-
import { SelectProps as AntdSelectProps } from 'antd/
|
|
4
|
+
import { SelectProps as AntdSelectProps } from 'antd/es/select';
|
|
5
5
|
import { BaseOptionType, DefaultOptionType } from 'rc-select/lib/Select';
|
|
6
6
|
import { ReactNode } from 'react';
|
|
7
7
|
/**
|
|
@@ -12,7 +12,8 @@ export declare const alignMap: {
|
|
|
12
12
|
between: string;
|
|
13
13
|
};
|
|
14
14
|
export declare function getAlign(align: HStackProps['align']): string;
|
|
15
|
-
|
|
15
|
+
type WidthFlexStyle = Pick<HStackProps, 'width' | 'style' | 'flex'>;
|
|
16
|
+
export declare function getWidthAndFlex({ width, style, flex }: WidthFlexStyle): import("@emotion/react").SerializedStyles;
|
|
16
17
|
declare const style: {
|
|
17
18
|
hStack: (props: Partial<HStackProps>) => import("@emotion/react").SerializedStyles;
|
|
18
19
|
vStack: (props: Partial<VStackProps>) => import("@emotion/react").SerializedStyles;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { BaseComponentProps, FunctionReturn } from "../../api";
|
|
2
|
-
import { SwitchProps as AntdSwitchProps } from 'antd/
|
|
3
|
-
import { EllipsisConfig } from 'antd/
|
|
2
|
+
import { SwitchProps as AntdSwitchProps } from 'antd/es/switch';
|
|
3
|
+
import { EllipsisConfig } from 'antd/es/typography/Base';
|
|
4
4
|
export interface SwitchProps extends AntdSwitchProps, BaseComponentProps {
|
|
5
5
|
/**
|
|
6
6
|
* @description 提示信息
|
|
@@ -24,7 +24,6 @@ function generateAction(action, params) {
|
|
|
24
24
|
disabled: (0, _api.executeFunction)(action.disabled, params),
|
|
25
25
|
tooltip: (0, _api.executeFunction)(action.tooltip, params),
|
|
26
26
|
confirm: (0, _api.executeFunction)(action.confirm, params),
|
|
27
|
-
confirmMessage: (0, _api.executeFunction)(action.confirmMessage, params),
|
|
28
27
|
onClick: function onClick() {
|
|
29
28
|
var _action$onClick;
|
|
30
29
|
return (_action$onClick = action.onClick) === null || _action$onClick === void 0 ? void 0 : _action$onClick.call(action, params);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Column } from '../type';
|
|
2
2
|
export declare function getSortColumn({ dataIndex, sort }: Column): {
|
|
3
|
-
sorter: import("antd/
|
|
3
|
+
sorter: import("antd/es/table/interface").CompareFn<any>;
|
|
4
4
|
} | {
|
|
5
5
|
sorter: (a: any, b: any) => any;
|
|
6
6
|
};
|
|
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
7
|
exports.Time = Time;
|
|
8
|
-
var
|
|
8
|
+
var _dayjs = _interopRequireDefault(require("dayjs"));
|
|
9
9
|
var _jsxRuntime = require("@emotion/react/jsx-runtime");
|
|
10
10
|
var defaultFormat = 'YYYY-MM-DD hh:mm:ss A';
|
|
11
11
|
function Time(_ref) {
|
|
@@ -14,6 +14,6 @@ function Time(_ref) {
|
|
|
14
14
|
var timeFormat = column.timeFormat;
|
|
15
15
|
var format = timeFormat || defaultFormat;
|
|
16
16
|
return (0, _jsxRuntime.jsx)(_jsxRuntime.Fragment, {
|
|
17
|
-
children: (0,
|
|
17
|
+
children: (0, _dayjs.default)(+children).format(format)
|
|
18
18
|
});
|
|
19
19
|
}
|