@aloudata/aloudata-design 2.0.0-beta.11 → 2.0.0-beta.13
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/Button/style/index.less +4 -0
- package/dist/Checkbox/style/index.less +1 -4
- package/dist/DataPreviewTable/style/index.less +2 -1
- package/dist/Dropdown/index.js +4 -1
- package/dist/Dropdown/style/index.less +11 -0
- package/dist/Empty/style/index.less +2 -2
- package/dist/Icon/components/ArrowRightLightLine.d.ts +11 -0
- package/dist/Icon/components/ArrowRightLightLine.js +35 -0
- package/dist/Icon/components/TimesLightLine.d.ts +11 -0
- package/dist/Icon/components/TimesLightLine.js +35 -0
- package/dist/Icon/index.d.ts +2 -0
- package/dist/Icon/index.js +2 -0
- package/dist/Icon/svg/Arrow-Right-light-line.svg +5 -0
- package/dist/Icon/svg/Times-light-line.svg +5 -0
- package/dist/IconButton/index.js +4 -1
- package/dist/Input/components/Input/index.js +1 -1
- package/dist/Input/components/TextArea/index.js +6 -4
- package/dist/MemberPicker/index.js +29 -19
- package/dist/MemberPicker/interface.d.ts +1 -1
- package/dist/MemberPicker/style/index.less +8 -1
- package/dist/Modal/index.js +26 -7
- package/dist/Select/index.js +14 -5
- package/dist/Select/style/emptyShowAll.less +10 -0
- package/dist/Select/style/index.less +1 -0
- package/dist/Select/style/layout.less +1 -0
- package/dist/Select/style/status.less +24 -2
- package/dist/Table/style/index.less +2 -2
- package/dist/Tooltip/index.js +5 -3
- package/dist/Tree/Tree.js +16 -8
- package/dist/Tree/demo/basic/index.js +4 -0
- package/dist/Tree/style/checkbox.less +57 -36
- package/dist/Tree/style/index.less +17 -2
- package/dist/Tree/style/var.less +1 -1
- package/dist/ald.min.css +1 -1
- package/package.json +1 -1
|
@@ -47,7 +47,6 @@
|
|
|
47
47
|
|
|
48
48
|
.ald-checkbox.ald-checkbox {
|
|
49
49
|
height: 20px;
|
|
50
|
-
color: @NL0;
|
|
51
50
|
font-size: 13px;
|
|
52
51
|
line-height: 20px;
|
|
53
52
|
|
|
@@ -57,7 +56,6 @@
|
|
|
57
56
|
|
|
58
57
|
&.ant-checkbox-wrapper {
|
|
59
58
|
height: 20px;
|
|
60
|
-
color: @NL0;
|
|
61
59
|
font-weight: 400;
|
|
62
60
|
font-size: 13px;
|
|
63
61
|
line-height: 20px;
|
|
@@ -157,7 +155,6 @@
|
|
|
157
155
|
cursor: default;
|
|
158
156
|
|
|
159
157
|
& + span {
|
|
160
|
-
color: @NL0;
|
|
161
158
|
cursor: default;
|
|
162
159
|
}
|
|
163
160
|
|
|
@@ -200,7 +197,7 @@
|
|
|
200
197
|
.ant-checkbox + span {
|
|
201
198
|
display: flex;
|
|
202
199
|
align-items: center;
|
|
203
|
-
padding-right:
|
|
200
|
+
padding-right: 0;
|
|
204
201
|
padding-left: 6px;
|
|
205
202
|
font-size: 14px;
|
|
206
203
|
}
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
.ald-data-preview-table {
|
|
8
8
|
border: 1px solid var(--alias-colors-border-default, #e5e7eb);
|
|
9
9
|
font-size: 12px;
|
|
10
|
+
font-variant-numeric: lining-nums tabular-nums;
|
|
10
11
|
position: relative;
|
|
11
12
|
|
|
12
13
|
* {
|
|
@@ -34,7 +35,7 @@
|
|
|
34
35
|
font-weight: 500;
|
|
35
36
|
|
|
36
37
|
.ald-data-preview-header-default {
|
|
37
|
-
padding:
|
|
38
|
+
padding: 4px 13px 3px 20px;
|
|
38
39
|
height: 100%;
|
|
39
40
|
width: 100%;
|
|
40
41
|
line-height: 20px;
|
package/dist/Dropdown/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
2
|
-
var _excluded = ["children", "open", "overlayClassName", "menu", "align", "placement"];
|
|
2
|
+
var _excluded = ["children", "open", "overlayClassName", "menu", "align", "placement", "trigger"];
|
|
3
3
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
4
4
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
5
5
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
@@ -21,6 +21,8 @@ export default function Dropdown(props) {
|
|
|
21
21
|
menu = props.menu,
|
|
22
22
|
align = props.align,
|
|
23
23
|
placement = props.placement,
|
|
24
|
+
_props$trigger = props.trigger,
|
|
25
|
+
trigger = _props$trigger === void 0 ? ['click'] : _props$trigger,
|
|
24
26
|
otherProps = _objectWithoutProperties(props, _excluded);
|
|
25
27
|
// antd 根据 open 字段是否存在来判断 open 是否是可控模式
|
|
26
28
|
var antdDropdownProps = otherProps;
|
|
@@ -52,6 +54,7 @@ export default function Dropdown(props) {
|
|
|
52
54
|
overlayClassName: classNames('ald-dropdown-overlay', overlayClassName),
|
|
53
55
|
menu: menus,
|
|
54
56
|
align: defaultAlign,
|
|
57
|
+
trigger: trigger,
|
|
55
58
|
placement: placement
|
|
56
59
|
}, antdDropdownProps), children);
|
|
57
60
|
}
|
|
@@ -17,6 +17,17 @@
|
|
|
17
17
|
background-color: unset;
|
|
18
18
|
}
|
|
19
19
|
|
|
20
|
+
.ant-dropdown-menu-item-danger {
|
|
21
|
+
color: #b91c1c !important;
|
|
22
|
+
|
|
23
|
+
&:hover {
|
|
24
|
+
background: var(
|
|
25
|
+
--alias-colors-bg-interaction-hover,
|
|
26
|
+
rgba(0, 0, 0, 0.05)
|
|
27
|
+
) !important;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
20
31
|
.ant-dropdown-menu-item,
|
|
21
32
|
.ant-dropdown-menu-submenu .ant-dropdown-menu-submenu-title {
|
|
22
33
|
display: flex;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { SVGProps } from 'react';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
interface SVGRProps {
|
|
4
|
+
size?: number | string;
|
|
5
|
+
title?: string;
|
|
6
|
+
titleId?: string;
|
|
7
|
+
desc?: string;
|
|
8
|
+
descId?: string;
|
|
9
|
+
}
|
|
10
|
+
declare const Memo: React.MemoExoticComponent<React.ForwardRefExoticComponent<Omit<SVGProps<SVGSVGElement> & SVGRProps, "ref"> & React.RefAttributes<SVGSVGElement>>>;
|
|
11
|
+
export default Memo;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
var _excluded = ["title", "titleId", "desc", "descId"];
|
|
2
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
3
|
+
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; }
|
|
4
|
+
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; }
|
|
5
|
+
import * as React from 'react';
|
|
6
|
+
import { forwardRef, memo } from 'react';
|
|
7
|
+
var ArrowRightLightLine = function ArrowRightLightLine(_ref, ref) {
|
|
8
|
+
var title = _ref.title,
|
|
9
|
+
titleId = _ref.titleId,
|
|
10
|
+
desc = _ref.desc,
|
|
11
|
+
descId = _ref.descId,
|
|
12
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
13
|
+
return /*#__PURE__*/React.createElement("svg", _extends({
|
|
14
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
15
|
+
width: props.width || props.size || 16,
|
|
16
|
+
height: props.height || props.size || 16,
|
|
17
|
+
fill: "none",
|
|
18
|
+
viewBox: "0 0 24 24",
|
|
19
|
+
ref: ref,
|
|
20
|
+
"aria-labelledby": titleId,
|
|
21
|
+
"aria-describedby": descId
|
|
22
|
+
}, props), desc ? /*#__PURE__*/React.createElement("desc", {
|
|
23
|
+
id: descId
|
|
24
|
+
}, desc) : null, title ? /*#__PURE__*/React.createElement("title", {
|
|
25
|
+
id: titleId
|
|
26
|
+
}, title) : null, /*#__PURE__*/React.createElement("path", {
|
|
27
|
+
fill: props.color || 'currentColor',
|
|
28
|
+
fillRule: "evenodd",
|
|
29
|
+
d: "M9.47 6.47a.75.75 0 0 1 1.06 0l5 5a.75.75 0 0 1 0 1.06l-5 5a.75.75 0 1 1-1.06-1.06L13.94 12 9.47 7.53a.75.75 0 0 1 0-1.06Z",
|
|
30
|
+
clipRule: "evenodd"
|
|
31
|
+
}));
|
|
32
|
+
};
|
|
33
|
+
var ForwardRef = /*#__PURE__*/forwardRef(ArrowRightLightLine);
|
|
34
|
+
var Memo = /*#__PURE__*/memo(ForwardRef);
|
|
35
|
+
export default Memo;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { SVGProps } from 'react';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
interface SVGRProps {
|
|
4
|
+
size?: number | string;
|
|
5
|
+
title?: string;
|
|
6
|
+
titleId?: string;
|
|
7
|
+
desc?: string;
|
|
8
|
+
descId?: string;
|
|
9
|
+
}
|
|
10
|
+
declare const Memo: React.MemoExoticComponent<React.ForwardRefExoticComponent<Omit<SVGProps<SVGSVGElement> & SVGRProps, "ref"> & React.RefAttributes<SVGSVGElement>>>;
|
|
11
|
+
export default Memo;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
var _excluded = ["title", "titleId", "desc", "descId"];
|
|
2
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
3
|
+
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; }
|
|
4
|
+
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; }
|
|
5
|
+
import * as React from 'react';
|
|
6
|
+
import { forwardRef, memo } from 'react';
|
|
7
|
+
var TimesLightLine = function TimesLightLine(_ref, ref) {
|
|
8
|
+
var title = _ref.title,
|
|
9
|
+
titleId = _ref.titleId,
|
|
10
|
+
desc = _ref.desc,
|
|
11
|
+
descId = _ref.descId,
|
|
12
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
13
|
+
return /*#__PURE__*/React.createElement("svg", _extends({
|
|
14
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
15
|
+
width: props.width || props.size || 16,
|
|
16
|
+
height: props.height || props.size || 16,
|
|
17
|
+
fill: "none",
|
|
18
|
+
viewBox: "0 0 24 24",
|
|
19
|
+
ref: ref,
|
|
20
|
+
"aria-labelledby": titleId,
|
|
21
|
+
"aria-describedby": descId
|
|
22
|
+
}, props), desc ? /*#__PURE__*/React.createElement("desc", {
|
|
23
|
+
id: descId
|
|
24
|
+
}, desc) : null, title ? /*#__PURE__*/React.createElement("title", {
|
|
25
|
+
id: titleId
|
|
26
|
+
}, title) : null, /*#__PURE__*/React.createElement("path", {
|
|
27
|
+
fill: props.color || 'currentColor',
|
|
28
|
+
fillRule: "evenodd",
|
|
29
|
+
d: "M17.53 7.53a.75.75 0 1 0-1.06-1.06L12 10.94 7.53 6.47a.75.75 0 0 0-1.06 1.06L10.94 12l-4.47 4.47a.75.75 0 0 0 1.06 1.06L12 13.06l4.47 4.47a.75.75 0 0 0 1.06-1.06L13.06 12l4.47-4.47Z",
|
|
30
|
+
clipRule: "evenodd"
|
|
31
|
+
}));
|
|
32
|
+
};
|
|
33
|
+
var ForwardRef = /*#__PURE__*/forwardRef(TimesLightLine);
|
|
34
|
+
var Memo = /*#__PURE__*/memo(ForwardRef);
|
|
35
|
+
export default Memo;
|
package/dist/Icon/index.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export { default as AlertTriangleDuotone } from './components/AlertTriangleDuotone';
|
|
2
2
|
export { default as AlertTriangleLine } from './components/AlertTriangleLine';
|
|
3
3
|
export { default as ArrowDownFill } from './components/ArrowDownFill';
|
|
4
|
+
export { default as ArrowRightLightLine } from './components/ArrowRightLightLine';
|
|
4
5
|
export { default as AttentionCircleFill } from './components/AttentionCircleFill';
|
|
5
6
|
export { default as AttentionTriangleFill } from './components/AttentionTriangleFill';
|
|
6
7
|
export { default as AttentionTriangleLightLine } from './components/AttentionTriangleLightLine';
|
|
@@ -33,6 +34,7 @@ export { default as LoadingDuotone } from './components/LoadingDuotone';
|
|
|
33
34
|
export { default as LoadingLine } from './components/LoadingLine';
|
|
34
35
|
export { default as MoreVerticalLine } from './components/MoreVerticalLine';
|
|
35
36
|
export { default as SearchLine } from './components/SearchLine';
|
|
37
|
+
export { default as TimesLightLine } from './components/TimesLightLine';
|
|
36
38
|
export { default as TriangleLightLine } from './components/TriangleLightLine';
|
|
37
39
|
export { default as User } from './components/User';
|
|
38
40
|
export { default as UserGroup } from './components/UserGroup';
|
package/dist/Icon/index.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export { default as AlertTriangleDuotone } from "./components/AlertTriangleDuotone";
|
|
2
2
|
export { default as AlertTriangleLine } from "./components/AlertTriangleLine";
|
|
3
3
|
export { default as ArrowDownFill } from "./components/ArrowDownFill";
|
|
4
|
+
export { default as ArrowRightLightLine } from "./components/ArrowRightLightLine";
|
|
4
5
|
export { default as AttentionCircleFill } from "./components/AttentionCircleFill";
|
|
5
6
|
export { default as AttentionTriangleFill } from "./components/AttentionTriangleFill";
|
|
6
7
|
export { default as AttentionTriangleLightLine } from "./components/AttentionTriangleLightLine";
|
|
@@ -33,6 +34,7 @@ export { default as LoadingDuotone } from "./components/LoadingDuotone";
|
|
|
33
34
|
export { default as LoadingLine } from "./components/LoadingLine";
|
|
34
35
|
export { default as MoreVerticalLine } from "./components/MoreVerticalLine";
|
|
35
36
|
export { default as SearchLine } from "./components/SearchLine";
|
|
37
|
+
export { default as TimesLightLine } from "./components/TimesLightLine";
|
|
36
38
|
export { default as TriangleLightLine } from "./components/TriangleLightLine";
|
|
37
39
|
export { default as User } from "./components/User";
|
|
38
40
|
export { default as UserGroup } from "./components/UserGroup";
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<g id=" Icon / Light / Arrow / Arrow-Right-light-line">
|
|
3
|
+
<path id="Icon" fill-rule="evenodd" clip-rule="evenodd" d="M9.46967 6.46967C9.76256 6.17678 10.2374 6.17678 10.5303 6.46967L15.5303 11.4697C15.8232 11.7626 15.8232 12.2374 15.5303 12.5303L10.5303 17.5303C10.2374 17.8232 9.76256 17.8232 9.46967 17.5303C9.17678 17.2374 9.17678 16.7626 9.46967 16.4697L13.9393 12L9.46967 7.53033C9.17678 7.23744 9.17678 6.76256 9.46967 6.46967Z" fill="black"/>
|
|
4
|
+
</g>
|
|
5
|
+
</svg>
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<g id=" Icon / Light / Icon / Math / Times-light-line">
|
|
3
|
+
<path id="Icon" fill-rule="evenodd" clip-rule="evenodd" d="M17.5303 7.53045C17.8232 7.23756 17.8232 6.76269 17.5303 6.46979C17.2374 6.1769 16.7625 6.1769 16.4696 6.46979L12 10.9394L7.53037 6.46979C7.23747 6.1769 6.7626 6.1769 6.46971 6.46979C6.17681 6.76269 6.17681 7.23756 6.46971 7.53045L10.9393 12.0001L6.46964 16.4698C6.17675 16.7627 6.17675 17.2376 6.46964 17.5305C6.76253 17.8233 7.23741 17.8233 7.5303 17.5305L12 13.0607L16.4697 17.5305C16.7626 17.8233 17.2375 17.8233 17.5304 17.5305C17.8233 17.2376 17.8233 16.7627 17.5304 16.4698L13.0607 12.0001L17.5303 7.53045Z" fill="black"/>
|
|
4
|
+
</g>
|
|
5
|
+
</svg>
|
package/dist/IconButton/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var _excluded = ["icon", "onClick", "disabled", "size", "menu", "className", "onOpenChange", "tooltip", "id", "showArrow", "mode"];
|
|
1
|
+
var _excluded = ["icon", "onClick", "disabled", "size", "menu", "className", "onOpenChange", "tooltip", "id", "trigger", "showArrow", "mode"];
|
|
2
2
|
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; }
|
|
3
3
|
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; }
|
|
4
4
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
@@ -57,6 +57,8 @@ var DropdownButton = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
57
57
|
onOpenChange = props.onOpenChange,
|
|
58
58
|
tooltip = props.tooltip,
|
|
59
59
|
id = props.id,
|
|
60
|
+
_props$trigger = props.trigger,
|
|
61
|
+
trigger = _props$trigger === void 0 ? ['click'] : _props$trigger,
|
|
60
62
|
_props$showArrow = props.showArrow,
|
|
61
63
|
showArrow = _props$showArrow === void 0 ? true : _props$showArrow,
|
|
62
64
|
_props$mode2 = props.mode,
|
|
@@ -93,6 +95,7 @@ var DropdownButton = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
93
95
|
title: tooltip === null || tooltip === void 0 ? void 0 : tooltip.title
|
|
94
96
|
}), /*#__PURE__*/React.createElement(Dropdown, _extends({
|
|
95
97
|
menu: menu,
|
|
98
|
+
trigger: trigger,
|
|
96
99
|
onOpenChange: onOpenChange
|
|
97
100
|
}, restDropdownProps), /*#__PURE__*/React.createElement("div", {
|
|
98
101
|
id: id,
|
|
@@ -47,7 +47,7 @@ var Input = /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
|
47
47
|
allowClear: allowClear ? {
|
|
48
48
|
clearIcon: /*#__PURE__*/React.createElement(CloseCircleFill, {
|
|
49
49
|
size: 20,
|
|
50
|
-
color: "#
|
|
50
|
+
color: "#9CA3AF"
|
|
51
51
|
})
|
|
52
52
|
} : undefined,
|
|
53
53
|
spellCheck: false,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
2
|
-
var _excluded = ["bordered", "size", "disabled", "className"];
|
|
2
|
+
var _excluded = ["bordered", "size", "disabled", "className", "allowClear"];
|
|
3
3
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
4
4
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
5
5
|
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
@@ -19,6 +19,8 @@ export default /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
|
19
19
|
disabled = props.disabled,
|
|
20
20
|
_props$className = props.className,
|
|
21
21
|
className = _props$className === void 0 ? '' : _props$className,
|
|
22
|
+
_props$allowClear = props.allowClear,
|
|
23
|
+
allowClear = _props$allowClear === void 0 ? false : _props$allowClear,
|
|
22
24
|
rest = _objectWithoutProperties(props, _excluded);
|
|
23
25
|
var contentSize = useContext(SizeContext);
|
|
24
26
|
var size = customSize || contentSize || 'middle';
|
|
@@ -27,12 +29,12 @@ export default /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
|
27
29
|
disabled: disabled,
|
|
28
30
|
spellCheck: false,
|
|
29
31
|
className: classnames('ald-input', 'ald-input-textarea', "ald-input-textarea-".concat(getSizeType(size)), _defineProperty({}, "ald-input-disabled", disabled), className),
|
|
30
|
-
allowClear: {
|
|
32
|
+
allowClear: allowClear ? {
|
|
31
33
|
clearIcon: /*#__PURE__*/React.createElement(CloseCircleFill, {
|
|
32
34
|
size: 20,
|
|
33
|
-
color: "#
|
|
35
|
+
color: "#9CA3AF"
|
|
34
36
|
})
|
|
35
|
-
},
|
|
37
|
+
} : false,
|
|
36
38
|
ref: ref,
|
|
37
39
|
bordered: bordered
|
|
38
40
|
}));
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
var _excluded = ["value", "type", "onChange", "multiple", "dropdownWidth", "open", "onOpenChange", "placeholder", "className", "allowClear", "disabled", "onClear", "size", "selectType", "prefix", "lockedIds"];
|
|
2
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
1
3
|
function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e2) { throw _e2; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e3) { didErr = true; err = _e3; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
|
|
2
4
|
function _objectDestructuringEmpty(obj) { if (obj == null) throw new TypeError("Cannot destructure " + obj); }
|
|
3
5
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
@@ -6,13 +8,16 @@ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o =
|
|
|
6
8
|
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; }
|
|
7
9
|
function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
8
10
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
11
|
+
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; }
|
|
12
|
+
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; }
|
|
9
13
|
import { useRequest } from 'ahooks';
|
|
10
14
|
import classNames from 'classnames';
|
|
11
15
|
import _ from 'lodash';
|
|
12
16
|
import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react';
|
|
17
|
+
import Avatar from "../Avatar";
|
|
13
18
|
import ConfigProvider from "../ConfigProvider";
|
|
14
19
|
import { EUserType } from "../ConfigProvider/getUserList";
|
|
15
|
-
import {
|
|
20
|
+
import { UserGroup } from "../Icon";
|
|
16
21
|
import Select from "../Select";
|
|
17
22
|
import message from "../message";
|
|
18
23
|
import Panel from "./components/Panel";
|
|
@@ -35,9 +40,12 @@ var Component = function Component(_ref) {
|
|
|
35
40
|
disabled = _ref.disabled,
|
|
36
41
|
_onClear = _ref.onClear,
|
|
37
42
|
size = _ref.size,
|
|
38
|
-
selectType = _ref.selectType,
|
|
43
|
+
_ref$selectType = _ref.selectType,
|
|
44
|
+
selectType = _ref$selectType === void 0 ? 'secondary' : _ref$selectType,
|
|
45
|
+
propPrefix = _ref.prefix,
|
|
39
46
|
_ref$lockedIds = _ref.lockedIds,
|
|
40
|
-
lockedIds = _ref$lockedIds === void 0 ? [] : _ref$lockedIds
|
|
47
|
+
lockedIds = _ref$lockedIds === void 0 ? [] : _ref$lockedIds,
|
|
48
|
+
restProps = _objectWithoutProperties(_ref, _excluded);
|
|
41
49
|
var _ConfigProvider$useGe = ConfigProvider.useGetUserList(),
|
|
42
50
|
getUsersByIds = _ConfigProvider$useGe.getUsersByIds,
|
|
43
51
|
getUsersByKeywords = _ConfigProvider$useGe.getUsersByKeywords;
|
|
@@ -183,18 +191,9 @@ var Component = function Component(_ref) {
|
|
|
183
191
|
setDropdownOpen(open);
|
|
184
192
|
onOpenChange === null || onOpenChange === void 0 ? void 0 : onOpenChange(open);
|
|
185
193
|
}, [onOpenChange]);
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
size: 20
|
|
190
|
-
});
|
|
191
|
-
if (type === EMemberPicker.GROUP) return /*#__PURE__*/React.createElement(User, {
|
|
192
|
-
size: 20
|
|
193
|
-
});
|
|
194
|
-
return null;
|
|
195
|
-
}, [multiple, type]);
|
|
196
|
-
return /*#__PURE__*/React.createElement(Select, {
|
|
197
|
-
prefix: prefix,
|
|
194
|
+
return /*#__PURE__*/React.createElement(Select, _extends({
|
|
195
|
+
prefix: propPrefix
|
|
196
|
+
}, restProps, {
|
|
198
197
|
size: size,
|
|
199
198
|
type: selectType,
|
|
200
199
|
className: classNames('ald-member-picker-select', className),
|
|
@@ -221,14 +220,25 @@ var Component = function Component(_ref) {
|
|
|
221
220
|
options: selectedUserList.map(function (item) {
|
|
222
221
|
if (item.type === EUserType.USER_GROUP) return {
|
|
223
222
|
label: item.name,
|
|
224
|
-
value: item.groupId
|
|
223
|
+
value: item.groupId,
|
|
224
|
+
tag: /*#__PURE__*/React.createElement("div", {
|
|
225
|
+
className: 'ald-member-picker-tag'
|
|
226
|
+
}, /*#__PURE__*/React.createElement(UserGroup, {
|
|
227
|
+
size: 20
|
|
228
|
+
}), item.name)
|
|
225
229
|
};
|
|
226
230
|
return {
|
|
227
231
|
label: item.nickname || item.name,
|
|
228
|
-
value: item.userId
|
|
232
|
+
value: item.userId,
|
|
233
|
+
tag: /*#__PURE__*/React.createElement("div", {
|
|
234
|
+
className: 'ald-member-picker-tag'
|
|
235
|
+
}, /*#__PURE__*/React.createElement(Avatar, {
|
|
236
|
+
size: 20,
|
|
237
|
+
src: item.photo
|
|
238
|
+
}), item.nickname || item.name)
|
|
229
239
|
};
|
|
230
240
|
}),
|
|
231
|
-
optionLabelProp:
|
|
241
|
+
optionLabelProp: multiple ? 'label' : 'tag',
|
|
232
242
|
open: dropdownOpen,
|
|
233
243
|
onDropdownVisibleChange: onDropdownOpenChange,
|
|
234
244
|
dropdownMatchSelectWidth: false,
|
|
@@ -249,7 +259,7 @@ var Component = function Component(_ref) {
|
|
|
249
259
|
onCancel: setDropdownOpen.bind(null, false)
|
|
250
260
|
}));
|
|
251
261
|
}
|
|
252
|
-
});
|
|
262
|
+
}));
|
|
253
263
|
};
|
|
254
264
|
var MemberSelector = Component;
|
|
255
265
|
MemberSelector.MemberPanel = MemberPanel;
|
|
@@ -9,7 +9,7 @@ export declare enum EMemberPicker {
|
|
|
9
9
|
USER = "USER",
|
|
10
10
|
BOTH = "BOTH"
|
|
11
11
|
}
|
|
12
|
-
export interface IBaseMemberSelectorProps extends
|
|
12
|
+
export interface IBaseMemberSelectorProps extends Omit<ISelectProps, 'type'> {
|
|
13
13
|
value?: TMemberPickerValue;
|
|
14
14
|
dropdownWidth?: number;
|
|
15
15
|
open?: boolean;
|
|
@@ -19,7 +19,8 @@
|
|
|
19
19
|
&.ald-member-picker-multiple {
|
|
20
20
|
display: flex;
|
|
21
21
|
flex-wrap: wrap;
|
|
22
|
-
border-radius:
|
|
22
|
+
border-radius: 6px;
|
|
23
|
+
overflow: hidden;
|
|
23
24
|
// .memberSelection {
|
|
24
25
|
// }
|
|
25
26
|
|
|
@@ -323,3 +324,9 @@
|
|
|
323
324
|
box-shadow: 0 20px 24px -4px rgba(16, 24, 40, 0.08),
|
|
324
325
|
0 8px 8px -4px rgba(16, 24, 40, 0.03);
|
|
325
326
|
}
|
|
327
|
+
|
|
328
|
+
.ald-member-picker-tag {
|
|
329
|
+
display: flex;
|
|
330
|
+
align-items: center;
|
|
331
|
+
gap: var(--alias-spacing-75, 6px);
|
|
332
|
+
}
|
package/dist/Modal/index.js
CHANGED
|
@@ -5,7 +5,7 @@ var _excluded = ["className", "type", "loading", "size", "disabled", "shape"],
|
|
|
5
5
|
_excluded4 = ["okButtonProps", "cancelButtonProps", "okType", "width", "title", "subTitle", "okText", "cancelText", "className"],
|
|
6
6
|
_excluded5 = ["okButtonProps", "cancelButtonProps", "okType", "width", "title", "subTitle", "okText", "cancelText", "className"],
|
|
7
7
|
_excluded6 = ["okButtonProps", "cancelButtonProps", "okType", "width", "title", "subTitle", "okText", "cancelText", "className"],
|
|
8
|
-
_excluded7 = ["okButtonProps", "cancelButtonProps", "okType", "width", "title", "subTitle", "className", "okText", "cancelText"];
|
|
8
|
+
_excluded7 = ["okButtonProps", "cancelButtonProps", "okType", "width", "title", "subTitle", "className", "okText", "cancelText", "type"];
|
|
9
9
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
10
10
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
11
11
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
@@ -65,6 +65,27 @@ var ModalTitle = function ModalTitle(_ref, type) {
|
|
|
65
65
|
className: 'ald-modal-text-sub-title'
|
|
66
66
|
}, subTitle)));
|
|
67
67
|
};
|
|
68
|
+
function getIcon(type) {
|
|
69
|
+
if (type === 'success') return /*#__PURE__*/React.createElement(CheckCircleLightLine, {
|
|
70
|
+
fill: "#fff",
|
|
71
|
+
color: "#22C55E",
|
|
72
|
+
size: 24
|
|
73
|
+
});
|
|
74
|
+
if (type === 'error') return /*#__PURE__*/React.createElement(AttentionTriangleLightLine, {
|
|
75
|
+
color: "#EF4444",
|
|
76
|
+
fill: '#fff',
|
|
77
|
+
size: 24
|
|
78
|
+
});
|
|
79
|
+
if (type === 'warning') return /*#__PURE__*/React.createElement(AttentionTriangleLightLine, {
|
|
80
|
+
color: "#EAB308",
|
|
81
|
+
size: 24
|
|
82
|
+
});
|
|
83
|
+
return /*#__PURE__*/React.createElement(InformationCircleLightLine, {
|
|
84
|
+
size: 24,
|
|
85
|
+
color: '#2986F4',
|
|
86
|
+
className: "ald-modal-close"
|
|
87
|
+
});
|
|
88
|
+
}
|
|
68
89
|
var OriginModal = function OriginModal(props) {
|
|
69
90
|
var className = props.className,
|
|
70
91
|
children = props.children,
|
|
@@ -260,6 +281,8 @@ Modal.confirm = function confirmFn(props) {
|
|
|
260
281
|
okText = _props$okText6 === void 0 ? '确定' : _props$okText6,
|
|
261
282
|
_props$cancelText6 = props.cancelText,
|
|
262
283
|
cancelText = _props$cancelText6 === void 0 ? '取消' : _props$cancelText6,
|
|
284
|
+
_props$type = props.type,
|
|
285
|
+
type = _props$type === void 0 ? 'confirm' : _props$type,
|
|
263
286
|
restProps = _objectWithoutProperties(props, _excluded7);
|
|
264
287
|
return AntdModal.confirm(_objectSpread({
|
|
265
288
|
okButtonProps: getButtonProps(okButtonProps, 'primary', okType),
|
|
@@ -267,14 +290,10 @@ Modal.confirm = function confirmFn(props) {
|
|
|
267
290
|
width: width || DEFAULT_WIDTH,
|
|
268
291
|
className: classNames('ald-modal', className),
|
|
269
292
|
title: ModalTitle({
|
|
270
|
-
icon:
|
|
271
|
-
size: 24,
|
|
272
|
-
color: '#2986F4',
|
|
273
|
-
className: "ald-modal-close"
|
|
274
|
-
}),
|
|
293
|
+
icon: getIcon(type),
|
|
275
294
|
title: title,
|
|
276
295
|
subTitle: subTitle
|
|
277
|
-
},
|
|
296
|
+
}, type),
|
|
278
297
|
okText: okText,
|
|
279
298
|
cancelText: cancelText
|
|
280
299
|
}, restProps));
|
package/dist/Select/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
2
|
-
var _excluded = ["mode", "options", "dropdownRender", "onDropdownVisibleChange", "defaultValue", "onChange", "open", "defaultOpen", "prefix", "prefixWidth", "className", "popupClassName", "listHeight", "notFoundContent", "value", "type", "tagRender", "style", "autoFocus", "showSearch", "showAllOption", "size", "status", "disabled", "prefixCls"];
|
|
2
|
+
var _excluded = ["mode", "options", "dropdownRender", "onDropdownVisibleChange", "defaultValue", "onChange", "open", "defaultOpen", "prefix", "prefixWidth", "className", "popupClassName", "listHeight", "notFoundContent", "value", "type", "tagRender", "style", "autoFocus", "showSearch", "showAllOption", "size", "status", "disabled", "prefixCls", "placeholder", "dropdownStyle"];
|
|
3
3
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
4
4
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
5
5
|
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
@@ -29,9 +29,12 @@ import React, { forwardRef, useContext, useEffect, useImperativeHandle, useMemo,
|
|
|
29
29
|
import { ConfigContext } from "../ConfigProvider";
|
|
30
30
|
import SizeContext from "../ConfigProvider/sizeContext";
|
|
31
31
|
import Empty from "../Empty";
|
|
32
|
-
import { ArrowDownFill,
|
|
32
|
+
import { ArrowDownFill, TimesLightLine } from "../Icon";
|
|
33
33
|
import Option from "./components/Option";
|
|
34
34
|
var DEFAULT_ALL_OPTION_VALUE = 'default_all_option_value';
|
|
35
|
+
var defaultDropdownStyle = {
|
|
36
|
+
minWidth: 192
|
|
37
|
+
};
|
|
35
38
|
var DEFAULT_LIST_ITEM_HEIGHT = 36;
|
|
36
39
|
var getSelectedOptionsFromValue = function getSelectedOptionsFromValue(isMultiple, options, value, defaultValue) {
|
|
37
40
|
if (typeof value !== 'undefined') {
|
|
@@ -103,7 +106,10 @@ var Select = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
103
106
|
customStatus = props.status,
|
|
104
107
|
customDisabled = props.disabled,
|
|
105
108
|
customizePrefixCls = props.prefixCls,
|
|
109
|
+
propsPlaceholder = props.placeholder,
|
|
110
|
+
dropdownStyle = props.dropdownStyle,
|
|
106
111
|
restProps = _objectWithoutProperties(props, _excluded);
|
|
112
|
+
var placeholder = type === 'primary' ? '全部' : propsPlaceholder;
|
|
107
113
|
var contentSize = useContext(SizeContext);
|
|
108
114
|
var _React$useContext = React.useContext(ConfigContext),
|
|
109
115
|
getPrefixCls = _React$useContext.getPrefixCls,
|
|
@@ -371,7 +377,7 @@ var Select = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
371
377
|
setIsOpen(!isOpen);
|
|
372
378
|
}
|
|
373
379
|
},
|
|
374
|
-
className: classNames('ald-select', className, (_classNames = {}, _defineProperty(_classNames, "ald-select-".concat(type), type === 'primary' || type === 'secondary'), _defineProperty(_classNames, 'ald-select-multiple', isMultiple), _defineProperty(_classNames, 'ald-select-single', !isMultiple), _defineProperty(_classNames, 'ald-select-large', size === 'large'), _defineProperty(_classNames, 'ald-select-small', size === 'small'), _defineProperty(_classNames, 'ald-select-disabled', mergedDisabled), _defineProperty(_classNames, 'ald-select-middle', size !== 'large' && size !== 'small'), _defineProperty(_classNames, 'ald-select-open', typeof _open === 'boolean' ? _open : isOpen), _defineProperty(_classNames, 'ald-select-focus', isFocus), _defineProperty(_classNames, "ald-select-status-".concat(mergedStatus), mergedStatus), _defineProperty(_classNames, 'ald-select-has-value', !_.isEmpty(value) || !_.isEmpty(currentValue)), _classNames), compactItemClassnames, hashId),
|
|
380
|
+
className: classNames('ald-select', className, (_classNames = {}, _defineProperty(_classNames, "ald-select-".concat(type), type === 'primary' || type === 'secondary'), _defineProperty(_classNames, 'ald-select-multiple', isMultiple), _defineProperty(_classNames, 'ald-select-single', !isMultiple), _defineProperty(_classNames, 'ald-select-large', size === 'large'), _defineProperty(_classNames, 'ald-select-small', size === 'small'), _defineProperty(_classNames, 'ald-select-disabled', mergedDisabled), _defineProperty(_classNames, 'ald-select-middle', size !== 'large' && size !== 'small'), _defineProperty(_classNames, 'ald-select-open', typeof _open === 'boolean' ? _open : isOpen), _defineProperty(_classNames, 'ald-select-focus', isFocus), _defineProperty(_classNames, "ald-select-status-".concat(mergedStatus), mergedStatus), _defineProperty(_classNames, 'ald-select-empty-show-all', type === 'primary'), _defineProperty(_classNames, 'ald-select-has-value', !_.isEmpty(value) || !_.isEmpty(currentValue)), _classNames), compactItemClassnames, hashId),
|
|
375
381
|
spellCheck: false,
|
|
376
382
|
style: Object.assign(styleVar, style)
|
|
377
383
|
}, !!prefix && /*#__PURE__*/React.createElement("span", {
|
|
@@ -380,6 +386,7 @@ var Select = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
380
386
|
}, prefix), /*#__PURE__*/React.createElement(AntdSelect, _extends({}, restProps, {
|
|
381
387
|
// @ts-ignore
|
|
382
388
|
status: mergedStatus,
|
|
389
|
+
placeholder: placeholder,
|
|
383
390
|
showSearch: showSearch,
|
|
384
391
|
options: innerOptions,
|
|
385
392
|
mode: isMultiple ? 'multiple' : undefined,
|
|
@@ -395,8 +402,10 @@ var Select = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
395
402
|
className: classNames({
|
|
396
403
|
'ald-select-prefix-select': !!prefix || prefix === 0
|
|
397
404
|
}),
|
|
398
|
-
|
|
399
|
-
|
|
405
|
+
dropdownStyle: dropdownStyle || defaultDropdownStyle,
|
|
406
|
+
clearIcon: /*#__PURE__*/React.createElement(TimesLightLine, {
|
|
407
|
+
className: "ald-select-clear-icon",
|
|
408
|
+
color: "#9CA3AF"
|
|
400
409
|
}),
|
|
401
410
|
style: {
|
|
402
411
|
width: '100%'
|