@aloudata/aloudata-design 2.0.0-beta.5 → 2.0.0-beta.6
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/Dropdown/style/index.less +1 -0
- package/dist/MemberPicker/index.js +2 -0
- package/dist/MemberPicker/interface.d.ts +1 -0
- package/dist/Pagination/index.d.ts +1 -1
- package/dist/Pagination/index.js +7 -1
- package/dist/Pagination/types.d.ts +1 -0
- package/dist/Select/style/index.less +1 -0
- package/dist/Spin/style/index.less +8 -0
- package/dist/Table/components/Pagination/index.js +3 -1
- package/dist/Table/index.js +1 -1
- package/dist/Tree/Tree.js +1 -1
- package/dist/Tree/style/index.less +12 -2
- package/dist/ald.min.css +1 -1
- package/package.json +1 -1
|
@@ -35,6 +35,7 @@ var Component = function Component(_ref) {
|
|
|
35
35
|
disabled = _ref.disabled,
|
|
36
36
|
_onClear = _ref.onClear,
|
|
37
37
|
size = _ref.size,
|
|
38
|
+
selectType = _ref.selectType,
|
|
38
39
|
_ref$lockedIds = _ref.lockedIds,
|
|
39
40
|
lockedIds = _ref$lockedIds === void 0 ? [] : _ref$lockedIds;
|
|
40
41
|
var _ConfigProvider$useGe = ConfigProvider.useGetUserList(),
|
|
@@ -185,6 +186,7 @@ var Component = function Component(_ref) {
|
|
|
185
186
|
return /*#__PURE__*/React.createElement(Select, {
|
|
186
187
|
prefix: prefix,
|
|
187
188
|
size: size,
|
|
189
|
+
type: selectType,
|
|
188
190
|
className: classNames('ald-member-picker-select', className),
|
|
189
191
|
value: selectedUserList.map(function (item) {
|
|
190
192
|
if (item.type === EUserType.USER_GROUP) {
|
|
@@ -15,6 +15,7 @@ export interface IBaseMemberSelectorProps extends Pick<ISelectProps, 'allowClear
|
|
|
15
15
|
open?: boolean;
|
|
16
16
|
onOpenChange?: (open: boolean) => void;
|
|
17
17
|
type?: EMemberPicker;
|
|
18
|
+
selectType?: ISelectProps['type'];
|
|
18
19
|
lockedIds?: Array<TUserValue | TUserGroupValue>;
|
|
19
20
|
}
|
|
20
21
|
export interface IMultipleMemberSelectorProps extends IBaseMemberSelectorProps {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { IPaginationProps } from './types';
|
|
3
|
-
declare function Pagination(props: IPaginationProps): React.JSX.Element;
|
|
3
|
+
declare function Pagination(props: IPaginationProps): React.JSX.Element | null;
|
|
4
4
|
export default Pagination;
|
|
5
5
|
/**
|
|
6
6
|
* 获取在安全范围内的当前页数
|
package/dist/Pagination/index.js
CHANGED
|
@@ -18,7 +18,8 @@ function Pagination(props) {
|
|
|
18
18
|
currPage = _props$current === void 0 ? 1 : _props$current,
|
|
19
19
|
pageSize = props.pageSize,
|
|
20
20
|
total = props.total,
|
|
21
|
-
onChange = props.onChange
|
|
21
|
+
onChange = props.onChange,
|
|
22
|
+
hideOnSinglePage = props.hideOnSinglePage;
|
|
22
23
|
var totalPage = getTotalPage(total, pageSize);
|
|
23
24
|
var _useState = useState(getSafeCurrent(totalPage, currPage)),
|
|
24
25
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -41,6 +42,11 @@ function Pagination(props) {
|
|
|
41
42
|
};
|
|
42
43
|
}, [onChange, current]);
|
|
43
44
|
var pageRange = getPaginationRange(totalPage, current);
|
|
45
|
+
if (hideOnSinglePage) {
|
|
46
|
+
if (totalPage <= 1) {
|
|
47
|
+
return null;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
44
50
|
return /*#__PURE__*/React.createElement("div", {
|
|
45
51
|
className: prefixCls('container')
|
|
46
52
|
}, /*#__PURE__*/React.createElement(Button, {
|
|
@@ -20,7 +20,9 @@ export default function TablePagination(props) {
|
|
|
20
20
|
}, [scrollToFirstRow, scroll, pagination]);
|
|
21
21
|
return pagination && /*#__PURE__*/React.createElement("div", {
|
|
22
22
|
className: prefixCls('pagination')
|
|
23
|
-
}, /*#__PURE__*/React.createElement(Pagination, _extends({
|
|
23
|
+
}, /*#__PURE__*/React.createElement(Pagination, _extends({
|
|
24
|
+
hideOnSinglePage: true
|
|
25
|
+
}, pagination, {
|
|
24
26
|
onChange: onChangePage
|
|
25
27
|
})));
|
|
26
28
|
}
|
package/dist/Table/index.js
CHANGED
|
@@ -18,7 +18,7 @@ import Pagination from "./components/Pagination";
|
|
|
18
18
|
import { getTableColumns, prefixCls } from "./helper";
|
|
19
19
|
import useScrollX from "./hooks/useScroll";
|
|
20
20
|
// 32 行高 + 1 底线高度
|
|
21
|
-
var HEADER_HEIGHT =
|
|
21
|
+
var HEADER_HEIGHT = 41;
|
|
22
22
|
function Table(props, ref) {
|
|
23
23
|
var _classnames;
|
|
24
24
|
var columns = props.columns,
|
package/dist/Tree/Tree.js
CHANGED
|
@@ -25,7 +25,7 @@ var Tree = /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
|
25
25
|
getPrefixCls = _React$useContext.getPrefixCls,
|
|
26
26
|
direction = _React$useContext.direction,
|
|
27
27
|
virtual = _React$useContext.virtual;
|
|
28
|
-
var size = props.size || '
|
|
28
|
+
var size = props.size || 'large';
|
|
29
29
|
var className = props.className,
|
|
30
30
|
_props$showIcon = props.showIcon,
|
|
31
31
|
showIcon = _props$showIcon === void 0 ? false : _props$showIcon,
|
|
@@ -62,6 +62,7 @@
|
|
|
62
62
|
flex: 1;
|
|
63
63
|
display: flex;
|
|
64
64
|
align-items: center;
|
|
65
|
+
border-radius: 4px;
|
|
65
66
|
// stylelint-disable-next-line
|
|
66
67
|
.ald-tree-iconEle {
|
|
67
68
|
display: inline-flex;
|
|
@@ -77,7 +78,6 @@
|
|
|
77
78
|
display: inline-flex;
|
|
78
79
|
align-items: center;
|
|
79
80
|
justify-content: space-between;
|
|
80
|
-
color: var(--alias-colors-text-default, #1f2937);
|
|
81
81
|
flex: 1;
|
|
82
82
|
|
|
83
83
|
.ald-tree-tab-leader {
|
|
@@ -94,8 +94,11 @@
|
|
|
94
94
|
}
|
|
95
95
|
|
|
96
96
|
&.ald-tree-node-selected {
|
|
97
|
-
border-radius: var(--alias-radius-75, 6px);
|
|
98
97
|
background: var(--alias-colors-bg-selected-default, #e8f2fe);
|
|
98
|
+
color: var(--alias-colors-text-selected, #126fdd);
|
|
99
|
+
font-size: 12px;
|
|
100
|
+
font-weight: 400;
|
|
101
|
+
line-height: 16px;
|
|
99
102
|
}
|
|
100
103
|
}
|
|
101
104
|
|
|
@@ -119,10 +122,17 @@
|
|
|
119
122
|
|
|
120
123
|
.ald-tree-node-content-wrapper {
|
|
121
124
|
padding: @tree-padding-large;
|
|
125
|
+
border-radius: var(--alias-radius-75, 6px);
|
|
122
126
|
|
|
123
127
|
.ald-tree-title {
|
|
124
128
|
line-height: @tree-line-height-large;
|
|
125
129
|
}
|
|
130
|
+
|
|
131
|
+
&.ald-tree-node-selected {
|
|
132
|
+
font-size: 14px;
|
|
133
|
+
font-weight: 500;
|
|
134
|
+
line-height: 20px;
|
|
135
|
+
}
|
|
126
136
|
}
|
|
127
137
|
}
|
|
128
138
|
}
|