@aloudata/aloudata-design 1.10.14 → 2.0.0-beta.1
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/index.d.ts +3 -4
- package/dist/Button/index.js +7 -20
- package/dist/Button/style/size.less +21 -8
- package/dist/Button/style/type.less +61 -33
- package/dist/Button/style/variables.less +229 -44
- package/dist/Checkbox/style/index.less +111 -114
- package/dist/Dropdown/index.d.ts +1 -2
- package/dist/Dropdown/style/index.less +70 -107
- package/dist/Icon/components/AlertTriangleDuotone.d.ts +1 -1
- package/dist/Icon/components/AlertTriangleLine.d.ts +11 -0
- package/dist/Icon/components/AlertTriangleLine.js +35 -0
- package/dist/Icon/components/ArrowDownFill.d.ts +11 -0
- package/dist/Icon/components/ArrowDownFill.js +35 -0
- package/dist/Icon/components/AttentionCircleFill.d.ts +11 -0
- package/dist/Icon/components/AttentionCircleFill.js +35 -0
- package/dist/Icon/components/AttentionTriangleFill.d.ts +11 -0
- package/dist/Icon/components/AttentionTriangleFill.js +35 -0
- package/dist/Icon/components/AttentionTriangleLightLine.d.ts +11 -0
- package/dist/Icon/components/AttentionTriangleLightLine.js +35 -0
- package/dist/Icon/components/CancelCircleDuotone.d.ts +1 -1
- package/dist/Icon/components/CheckCircleDuotone.d.ts +1 -1
- package/dist/Icon/components/CheckCircleFill.d.ts +11 -0
- package/dist/Icon/components/CheckCircleFill.js +35 -0
- package/dist/Icon/components/CheckCircleLightLine.d.ts +11 -0
- package/dist/Icon/components/CheckCircleLightLine.js +38 -0
- package/dist/Icon/components/CheckLightLine.d.ts +11 -0
- package/dist/Icon/components/CheckLightLine.js +35 -0
- package/dist/Icon/components/ChevronDownLine.d.ts +1 -1
- package/dist/Icon/components/ChevronLeftLine.d.ts +1 -1
- package/dist/Icon/components/ChevronRightLine.d.ts +1 -1
- package/dist/Icon/components/CircleLightLine.d.ts +11 -0
- package/dist/Icon/components/CircleLightLine.js +38 -0
- package/dist/Icon/components/CloseCircleFill.d.ts +11 -0
- package/dist/Icon/components/CloseCircleFill.js +35 -0
- package/dist/Icon/components/CloseLLine.d.ts +1 -1
- package/dist/Icon/components/CloseLightLine.d.ts +11 -0
- package/dist/Icon/components/CloseLightLine.js +35 -0
- package/dist/Icon/components/CloseMLine.d.ts +1 -1
- package/dist/Icon/components/DragLine.d.ts +1 -1
- package/dist/Icon/components/Ellipsis.d.ts +11 -0
- package/dist/Icon/components/Ellipsis.js +35 -0
- package/dist/Icon/components/EyeOffLine.d.ts +1 -1
- package/dist/Icon/components/EyeOnLine.d.ts +1 -1
- package/dist/Icon/components/FoldDownFill.d.ts +1 -1
- package/dist/Icon/components/FoldUpFill.d.ts +1 -1
- package/dist/Icon/components/InfoCircleDuotone.d.ts +1 -1
- package/dist/Icon/components/InfoCircleLine.d.ts +1 -1
- package/dist/Icon/components/InformationCircleFill.d.ts +11 -0
- package/dist/Icon/components/InformationCircleFill.js +35 -0
- package/dist/Icon/components/InformationCircleLightLine.d.ts +11 -0
- package/dist/Icon/components/InformationCircleLightLine.js +38 -0
- package/dist/Icon/components/Loading2Line.d.ts +1 -1
- package/dist/Icon/components/LoadingDuotone.d.ts +11 -0
- package/dist/Icon/components/LoadingDuotone.js +39 -0
- package/dist/Icon/components/LoadingLine.d.ts +1 -1
- package/dist/Icon/components/MoreVerticalLine.d.ts +1 -1
- package/dist/Icon/components/SearchLine.d.ts +1 -1
- package/dist/Icon/components/TriangleLightLine.d.ts +11 -0
- package/dist/Icon/components/TriangleLightLine.js +35 -0
- package/dist/Icon/index.d.ts +16 -3
- package/dist/Icon/index.js +16 -2
- package/dist/Icon/svg/Loading-duotone.svg +6 -0
- package/dist/Icon/svg/alert-triangle-duotone.svg +3 -1
- package/dist/Icon/svg/alert-triangle-line.svg +5 -0
- package/dist/Icon/svg/arrow-down-fill.svg +5 -0
- package/dist/Icon/svg/attention-circle-fill.svg +5 -0
- package/dist/Icon/svg/attention-triangle-fill.svg +5 -0
- package/dist/Icon/svg/attention-triangle-light-line.svg +5 -0
- package/dist/Icon/svg/cancel-circle-duotone.svg +7 -3
- package/dist/Icon/svg/check-circle-duotone.svg +6 -2
- package/dist/Icon/svg/check-circle-fill.svg +5 -0
- package/dist/Icon/svg/check-circle-light-line.svg +8 -0
- package/dist/Icon/svg/check-light-line.svg +5 -0
- package/dist/Icon/svg/chevron-down-line.svg +6 -4
- package/dist/Icon/svg/chevron-left-line.svg +6 -4
- package/dist/Icon/svg/chevron-right-line.svg +6 -4
- package/dist/Icon/svg/circle-light-line.svg +9 -0
- package/dist/Icon/svg/close-L-line.svg +11 -9
- package/dist/Icon/svg/close-circle-fill.svg +5 -0
- package/dist/Icon/svg/close-light-line.svg +5 -0
- package/dist/Icon/svg/close-m-line.svg +6 -4
- package/dist/Icon/svg/drag-line.svg +6 -4
- package/dist/Icon/svg/ellipsis.svg +5 -0
- package/dist/Icon/svg/eye-off-line.svg +6 -4
- package/dist/Icon/svg/eye-on-line.svg +14 -8
- package/dist/Icon/svg/fold-down-fill.svg +7 -6
- package/dist/Icon/svg/fold-up-fill.svg +7 -6
- package/dist/Icon/svg/info-circle-duotone.svg +4 -2
- package/dist/Icon/svg/info-circle-line.svg +3 -1
- package/dist/Icon/svg/information-circle-fill.svg +5 -0
- package/dist/Icon/svg/information-circle-light-line.svg +9 -0
- package/dist/Icon/svg/loading-2-line.svg +4 -2
- package/dist/Icon/svg/loading-line.svg +6 -4
- package/dist/Icon/svg/more-vertical-line.svg +6 -4
- package/dist/Icon/svg/search-line.svg +6 -4
- package/dist/Icon/svg/triangle-light-line.svg +5 -0
- package/dist/IconButton/index.d.ts +2 -2
- package/dist/IconButton/index.js +8 -19
- package/dist/IconButton/style/index.less +49 -25
- package/dist/Input/components/Input/index.js +18 -2
- package/dist/Input/components/Password/index.d.ts +0 -5
- package/dist/Input/components/Password/index.js +10 -10
- package/dist/Input/components/TextArea/index.js +15 -2
- package/dist/Input/index.d.ts +2 -5
- package/dist/Input/index.js +1 -3
- package/dist/Input/style/index.less +4 -565
- package/dist/Input/style/reset.less +22 -0
- package/dist/Input/style/size.less +82 -0
- package/dist/Input/style/status.less +105 -0
- package/dist/MemberPicker/style/index.less +2 -2
- package/dist/Menu/index.js +6 -9
- package/dist/Menu/style/index.less +72 -133
- package/dist/Modal/index.d.ts +1 -1
- package/dist/Modal/index.js +32 -43
- package/dist/Modal/style/index.less +3 -191
- package/dist/Modal/style/modal.less +132 -0
- package/dist/Modal/style/modalConfirm.less +100 -0
- package/dist/Pagination/index.js +4 -2
- package/dist/Pagination/style/index.less +11 -4
- package/dist/Popconfirm/index.js +8 -7
- package/dist/Popconfirm/style/index.less +16 -6
- package/dist/Popover/style/index.less +29 -29
- package/dist/Radio/components/Group/index.js +3 -5
- package/dist/Radio/components/Radio/index.js +2 -1
- package/dist/Radio/interface/radioGroup.d.ts +1 -1
- package/dist/Radio/style/index.less +69 -56
- package/dist/Select/components/{MultipleOption.d.ts → Option.d.ts} +2 -2
- package/dist/Select/components/{MultipleOption.js → Option.js} +14 -11
- package/dist/Select/components/SingleOption.d.ts +2 -2
- package/dist/Select/components/SingleOption.js +3 -1
- package/dist/Select/index.d.ts +5 -0
- package/dist/Select/index.js +26 -40
- package/dist/Select/style/index.less +96 -76
- package/dist/Select/style/layout.less +41 -0
- package/dist/Select/style/option.less +42 -3
- package/dist/Select/style/selectDropdown.less +17 -0
- package/dist/Select/style/size.less +95 -82
- package/dist/Select/style/status.less +69 -21
- package/dist/Select/style/variables.less +8 -15
- package/dist/Spin/CustomIcon/index.d.ts +3 -0
- package/dist/Spin/CustomIcon/index.js +20 -15
- package/dist/Spin/CustomIcon/index.less +32 -105
- package/dist/Spin/index.d.ts +2 -0
- package/dist/Spin/index.js +8 -2
- package/dist/Spin/style/index.less +9 -1
- package/dist/Switch/index.d.ts +1 -1
- package/dist/Switch/style/index.less +130 -56
- package/dist/Table/style/index.less +16 -8
- package/dist/Tabs/index.d.ts +2 -2
- package/dist/Tabs/index.js +4 -4
- package/dist/Tabs/style/index.less +20 -16
- package/dist/TextLink/index.d.ts +44 -0
- package/dist/TextLink/index.js +25 -0
- package/dist/TextLink/style/index.d.ts +2 -0
- package/dist/TextLink/style/index.js +2 -0
- package/dist/TextLink/style/index.less +9 -0
- package/dist/TextLink/style/size.less +37 -0
- package/dist/TextLink/style/type.less +44 -0
- package/dist/Tree/style/var.less +1 -1
- package/dist/ald.min.css +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +1 -1
- package/dist/index.less +1 -0
- package/dist/message/index.js +15 -14
- package/dist/message/style/color.less +22 -41
- package/dist/message/style/index.less +15 -16
- package/dist/notification/demo/index.js +1 -0
- package/dist/notification/index.js +18 -18
- package/dist/notification/style/index.less +12 -6
- package/dist/style/index.less +1 -0
- package/dist/style/themes/default/default.less +1 -1
- package/dist/style/themes/default/index.less +3 -3
- package/dist/style/themes/default/scrollBar.less +1 -1
- package/dist/style/var/default.css +1334 -0
- package/package.json +4 -3
- package/dist/Icon/components/Icon.d.ts +0 -32
- package/dist/Icon/components/Icon.js +0 -25
- package/dist/Input/components/Group/index.d.ts +0 -18
- package/dist/Input/components/Group/index.js +0 -19
- package/dist/Menu/style/dropdown.less +0 -61
- package/dist/Select/style/multiple.less +0 -55
- package/dist/Select/style/single.less +0 -44
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
// 光标颜色
|
|
2
|
+
@input-caret-color: var(
|
|
3
|
+
--alias-colors-border-accent-gray-stronger-default,
|
|
4
|
+
#4b5563
|
|
5
|
+
);
|
|
6
|
+
// color enabled
|
|
7
|
+
@input-enabled-border-color: var(
|
|
8
|
+
--alias-colors-border-accent-gray-subtle-default,
|
|
9
|
+
#d1d5db
|
|
10
|
+
);
|
|
11
|
+
@input-enabled-bg-color: var(--alias-colors-bg-skeleton-subtler, #fff);
|
|
12
|
+
@input-enabled-text-color: var(--alias-colors-text-default, #1f2937);
|
|
13
|
+
@input-enabled-placeholder-color: var(--alias-colors-text-subtlest, #9ca3af);
|
|
14
|
+
// color hover
|
|
15
|
+
@input-hover-border-color: var(
|
|
16
|
+
--alias-colors-border-accent-gray-subtle-hover,
|
|
17
|
+
#9ca3af
|
|
18
|
+
);
|
|
19
|
+
@input-hover-bg-color: var(--alias-colors-bg-skeleton-subtler, #fff);
|
|
20
|
+
@input-hover-text-color: var(--alias-colors-text-default, #1f2937);
|
|
21
|
+
@input-hover-placeholder-color: var(--alias-colors-text-subtlest, #9ca3af);
|
|
22
|
+
|
|
23
|
+
//color focus
|
|
24
|
+
@input-focus-border-color: var(--alias-colors-border-selected, #126fdd);
|
|
25
|
+
@input-focus-bg-color: var(--alias-colors-bg-skeleton-subtler, #fff);
|
|
26
|
+
@input-focus-text-color: var(--alias-colors-text-default, #1f2937);
|
|
27
|
+
@input-focus-placeholder-color: var(--alias-colors-text-subtlest, #9ca3af);
|
|
28
|
+
|
|
29
|
+
//color disabled
|
|
30
|
+
@input-disabled-border-color: var(
|
|
31
|
+
--alias-colors-border-disabled,
|
|
32
|
+
rgba(0, 0, 0, 0.1)
|
|
33
|
+
);
|
|
34
|
+
@input-disabled-bg-color: var(--alias-colors-bg-transp, rgba(0, 0, 0, 0));
|
|
35
|
+
@input-disabled-text-color: var(
|
|
36
|
+
--alias-colors-text-disabled,
|
|
37
|
+
rgba(0, 0, 0, 0.25)
|
|
38
|
+
);
|
|
39
|
+
@input-disabled-placeholder-color: var(
|
|
40
|
+
--alias-colors-text-disabled,
|
|
41
|
+
rgba(0, 0, 0, 0.25)
|
|
42
|
+
);
|
|
43
|
+
|
|
44
|
+
.input-color(@border-color,@text-color,@bg-color,@placeholder-color) {
|
|
45
|
+
border-color: @border-color;
|
|
46
|
+
color: @text-color;
|
|
47
|
+
background-color: @bg-color;
|
|
48
|
+
|
|
49
|
+
&::placeholder {
|
|
50
|
+
color: @placeholder-color;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.ald-input.ald-input {
|
|
55
|
+
// 纯input 输入框,比如普通的<Input /> <Input.textarea />
|
|
56
|
+
&:not(.ant-input-affix-wrapper) {
|
|
57
|
+
.input-color(@input-enabled-border-color,@input-enabled-text-color,@input-enabled-bg-color,@input-enabled-placeholder-color);
|
|
58
|
+
|
|
59
|
+
&:hover {
|
|
60
|
+
.input-color(@input-hover-border-color,@input-hover-text-color,@input-hover-bg-color,@input-hover-placeholder-color);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
&:focus {
|
|
64
|
+
.input-color(@input-focus-border-color,@input-focus-text-color,@input-focus-bg-color,@input-focus-placeholder-color);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
&.ald-input-disabled {
|
|
68
|
+
cursor: default;
|
|
69
|
+
.input-color(@input-disabled-border-color,@input-disabled-text-color,@input-disabled-bg-color,@input-disabled-placeholder-color);
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
// 带有其他内容的输入框,比如带 allowClear图标、prefix、suffix、密码图标等。
|
|
73
|
+
&.ant-input-affix-wrapper {
|
|
74
|
+
// 纯input 输入框,比如普通的<Input /> <Input.textarea />
|
|
75
|
+
.input-color(@input-enabled-border-color,@input-enabled-text-color,@input-enabled-bg-color,@input-enabled-placeholder-color);
|
|
76
|
+
|
|
77
|
+
&:hover {
|
|
78
|
+
.input-color(@input-hover-border-color,@input-hover-text-color,@input-hover-bg-color,@input-hover-placeholder-color);
|
|
79
|
+
}
|
|
80
|
+
// 激活状态
|
|
81
|
+
&.ant-input-affix-wrapper-focused,
|
|
82
|
+
&:active {
|
|
83
|
+
.input-color(@input-focus-border-color,@input-focus-text-color,@input-focus-bg-color,@input-focus-placeholder-color);
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
&.ald-input-disabled {
|
|
87
|
+
cursor: default;
|
|
88
|
+
.input-color(@input-disabled-border-color,@input-disabled-text-color,@input-disabled-bg-color,@input-disabled-placeholder-color);
|
|
89
|
+
|
|
90
|
+
.ant-input-disabled {
|
|
91
|
+
cursor: default;
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
// 前缀
|
|
95
|
+
.ant-input-prefix {
|
|
96
|
+
color: var(--alias-colors-text-subtle, #4b5563);
|
|
97
|
+
}
|
|
98
|
+
// 后缀
|
|
99
|
+
.ant-input-suffix {
|
|
100
|
+
.ant-input-clear-icon {
|
|
101
|
+
color: var(--alias-colors-icon-subtle, #6b7280);
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
}
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
.ald-member-picker-wrapper {
|
|
13
13
|
box-sizing: border-box;
|
|
14
14
|
border: 1px solid var(--colors-gray-400, #dbdbdb);
|
|
15
|
-
background: var(--colors-
|
|
15
|
+
background: var(--global-colors-base-white-950a, #fff);
|
|
16
16
|
box-shadow: 0 20px 24px -4px rgb(16 24 40 / 0.08),
|
|
17
17
|
0 8px 8px -4px rgb(16 24 40 / 0.03);
|
|
18
18
|
|
|
@@ -192,7 +192,7 @@
|
|
|
192
192
|
width: auto;
|
|
193
193
|
height: 32px;
|
|
194
194
|
box-sizing: border-box;
|
|
195
|
-
background: var(--colors-
|
|
195
|
+
background: var(--global-colors-base-white-950a, #fff);
|
|
196
196
|
justify-content: space-between;
|
|
197
197
|
min-width: 0;
|
|
198
198
|
|
package/dist/Menu/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var _excluded = ["className", "
|
|
1
|
+
var _excluded = ["className", "items"];
|
|
2
2
|
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); }
|
|
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 _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,7 +12,6 @@ import { Menu as AntdMenu } from 'antd';
|
|
|
12
12
|
import classNames from 'classnames';
|
|
13
13
|
import React from 'react';
|
|
14
14
|
import { ChevronRightLine } from "../Icon";
|
|
15
|
-
import theme from "../style/themes/default/themeColor.module.less";
|
|
16
15
|
import Divider from "./Divider";
|
|
17
16
|
import MenuItem from "./MenuItem";
|
|
18
17
|
import SubMenu from "./SubMenu";
|
|
@@ -30,7 +29,10 @@ export function addPopupOffset(items) {
|
|
|
30
29
|
return _objectSpread(_objectSpread({
|
|
31
30
|
popupOffset: [OFFSET_WIDTH, OFFSET_HEIGHT]
|
|
32
31
|
}, item), {}, {
|
|
33
|
-
children: addPopupOffset(item.children)
|
|
32
|
+
children: addPopupOffset(item.children),
|
|
33
|
+
expandIcon: /*#__PURE__*/React.createElement(ChevronRightLine, {
|
|
34
|
+
size: 16
|
|
35
|
+
})
|
|
34
36
|
});
|
|
35
37
|
}
|
|
36
38
|
return item;
|
|
@@ -38,15 +40,10 @@ export function addPopupOffset(items) {
|
|
|
38
40
|
}
|
|
39
41
|
export default function Menu(props) {
|
|
40
42
|
var className = props.className,
|
|
41
|
-
expandIcon = props.expandIcon,
|
|
42
43
|
items = props.items,
|
|
43
44
|
otherProps = _objectWithoutProperties(props, _excluded);
|
|
44
45
|
return /*#__PURE__*/React.createElement(AntdMenu, _extends({
|
|
45
|
-
className: classNames(className, 'ald-menu')
|
|
46
|
-
expandIcon: expandIcon || /*#__PURE__*/React.createElement(ChevronRightLine, {
|
|
47
|
-
color: theme.NL50,
|
|
48
|
-
size: 16
|
|
49
|
-
})
|
|
46
|
+
className: classNames(className, 'ald-menu')
|
|
50
47
|
}, otherProps, {
|
|
51
48
|
items: addPopupOffset(items),
|
|
52
49
|
theme: "light"
|
|
@@ -1,165 +1,104 @@
|
|
|
1
1
|
@import '../../style/index.less';
|
|
2
|
-
@import '../../Icon/index.less';
|
|
3
|
-
@import './dropdown.less';
|
|
4
2
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
3
|
+
// Menu 和子menu的 ul样式
|
|
4
|
+
.menu-content {
|
|
5
|
+
background: var(--alias-colors-bg-skeleton-subtler, #fff);
|
|
6
|
+
border-radius: 0;
|
|
7
|
+
box-shadow: none;
|
|
8
|
+
padding: 0;
|
|
9
9
|
|
|
10
|
-
.ant-menu-item,
|
|
11
|
-
.ant-menu-submenu
|
|
12
|
-
|
|
10
|
+
.ant-menu-item-divider,
|
|
11
|
+
.ant-menu-submenu-title-divider {
|
|
12
|
+
background-color: var(--alias-colors-border-subtle, #f3f4f6);
|
|
13
13
|
margin: 0;
|
|
14
|
-
height: initial;
|
|
15
|
-
padding: 6px 8px;
|
|
16
|
-
line-height: 20px;
|
|
17
|
-
font-size: 13px;
|
|
18
|
-
width: 100%;
|
|
19
|
-
border-radius: 0;
|
|
20
|
-
border: none;
|
|
21
|
-
background-color: @BG100;
|
|
22
|
-
color: @NL0;
|
|
23
|
-
transition: none;
|
|
24
|
-
cursor: pointer;
|
|
25
|
-
|
|
26
|
-
&:hover {
|
|
27
|
-
background-color: @BG90;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
&:active {
|
|
31
|
-
background-color: none;
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
&:not(.ant-menu-item-selected):active {
|
|
35
|
-
background-color: @BG90;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
&.ant-menu-item-disabled {
|
|
39
|
-
color: @NL50 !important;
|
|
40
|
-
transition: none;
|
|
41
|
-
background-color: @BG100 !important;
|
|
42
|
-
cursor: default;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
.ant-menu-submenu-title {
|
|
46
|
-
line-height: 20px;
|
|
47
|
-
font-size: 13px;
|
|
48
|
-
width: 100%;
|
|
49
|
-
padding: 0;
|
|
50
|
-
height: initial;
|
|
51
|
-
margin: 0;
|
|
52
|
-
|
|
53
|
-
&:hover {
|
|
54
|
-
background: none;
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
.ant-menu-submenu-expand-icon {
|
|
58
|
-
width: initial;
|
|
59
|
-
right: 8px;
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
14
|
}
|
|
63
15
|
|
|
64
|
-
.ant-menu-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
.ant-menu-submenu-title {
|
|
68
|
-
padding: 0 8px;
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
.ant-menu-title-content {
|
|
73
|
-
line-height: 20px;
|
|
74
|
-
font-size: 13px;
|
|
75
|
-
width: 100%;
|
|
76
|
-
padding: 0;
|
|
77
|
-
height: initial;
|
|
78
|
-
margin: 0;
|
|
79
|
-
|
|
80
|
-
&:hover {
|
|
81
|
-
background: none;
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
.ant-menu-submenu.ant-menu-submenu.ant-menu-submenu-popup.ant-menu {
|
|
87
|
-
.ant-menu-vertical {
|
|
88
|
-
border: 1px solid @BG70;
|
|
89
|
-
border-radius: 2px;
|
|
90
|
-
box-shadow: @shadow-L;
|
|
16
|
+
.ant-menu-item-selected {
|
|
17
|
+
background-color: unset;
|
|
91
18
|
}
|
|
92
19
|
|
|
20
|
+
// menu项样式
|
|
93
21
|
.ant-menu-item,
|
|
94
|
-
.ant-menu-submenu
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
padding:
|
|
22
|
+
.ant-menu-submenu .ant-menu-submenu-title {
|
|
23
|
+
display: flex;
|
|
24
|
+
align-items: center;
|
|
25
|
+
justify-content: space-between;
|
|
26
|
+
padding: var(--alias-padding-100, 8px) var(--alias-padding-150, 12px);
|
|
27
|
+
color: var(--alias-colors-text-default, #1f2937);
|
|
28
|
+
font-size: 14px;
|
|
29
|
+
font-style: normal;
|
|
30
|
+
font-weight: 400;
|
|
99
31
|
line-height: 20px;
|
|
100
|
-
|
|
101
|
-
|
|
32
|
+
height: auto;
|
|
33
|
+
margin: 0;
|
|
34
|
+
width: auto;
|
|
35
|
+
gap: var(--alias-spacing-50, 4px);
|
|
102
36
|
border-radius: 0;
|
|
103
|
-
border: none;
|
|
104
|
-
background-color: @BG100;
|
|
105
|
-
color: @NL0;
|
|
106
|
-
transition: none;
|
|
107
37
|
|
|
108
38
|
&:hover {
|
|
109
|
-
background-color:
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
&:active {
|
|
113
|
-
background-color: none;
|
|
39
|
+
background-color: unset;
|
|
114
40
|
}
|
|
115
41
|
|
|
116
|
-
|
|
117
|
-
|
|
42
|
+
.ant-dropdown-menu-item-icon {
|
|
43
|
+
font-size: 20px;
|
|
44
|
+
margin: 0;
|
|
118
45
|
}
|
|
119
46
|
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
47
|
+
.ant-menu-title-content.ant-menu-title-content {
|
|
48
|
+
text-overflow: ellipsis;
|
|
49
|
+
overflow: hidden;
|
|
50
|
+
white-space: nowrap;
|
|
51
|
+
margin-left: 0;
|
|
52
|
+
flex: 1;
|
|
125
53
|
}
|
|
126
54
|
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
font-size: 13px;
|
|
130
|
-
width: 100%;
|
|
131
|
-
padding: 0;
|
|
132
|
-
height: initial;
|
|
133
|
-
margin: 0;
|
|
134
|
-
|
|
135
|
-
&:hover {
|
|
136
|
-
background: none;
|
|
137
|
-
}
|
|
55
|
+
svg {
|
|
56
|
+
flex-shrink: 0;
|
|
138
57
|
}
|
|
139
58
|
}
|
|
140
59
|
|
|
141
60
|
.ant-menu-submenu {
|
|
142
|
-
|
|
61
|
+
border-radius: 0;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.ant-menu-item.ant-menu-item-disabled {
|
|
65
|
+
cursor: default;
|
|
66
|
+
color: var(--alias-colors-text-disabled, rgba(0, 0, 0, 0.25));
|
|
143
67
|
|
|
144
|
-
|
|
145
|
-
|
|
68
|
+
&:hover {
|
|
69
|
+
background-color: var(--alias-colors-bg-transp, rgba(0, 0, 0, 0));
|
|
146
70
|
}
|
|
147
71
|
}
|
|
148
72
|
|
|
149
|
-
.ant-menu
|
|
150
|
-
|
|
73
|
+
.ant-menu-item:hover,
|
|
74
|
+
.ant-menu-submenu:hover,
|
|
75
|
+
.ant-menu-submenu.ant-menu-submenu-active {
|
|
76
|
+
background-color: var(
|
|
77
|
+
--alias-colors-bg-interaction-hover,
|
|
78
|
+
rgba(0, 0, 0, 0.05)
|
|
79
|
+
);
|
|
151
80
|
}
|
|
81
|
+
}
|
|
152
82
|
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
83
|
+
// 容器样式
|
|
84
|
+
.menu-wrap {
|
|
85
|
+
border: 1px solid var(--alias-colors-border-strong, #d1d5db);
|
|
86
|
+
border-radius: var(--alias-radius-75, 6px);
|
|
87
|
+
box-shadow: 0 4px 6px -2px rgba(0, 0, 0, 0.05),
|
|
88
|
+
0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 0 0 1px rgba(0, 0, 0, 0.05);
|
|
89
|
+
overflow: hidden;
|
|
90
|
+
}
|
|
160
91
|
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
92
|
+
// menu菜单
|
|
93
|
+
.ant-menu-root.ant-menu {
|
|
94
|
+
border: none;
|
|
95
|
+
.menu-content();
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.ant-menu-submenu.ant-menu-submenu-popup {
|
|
99
|
+
.menu-wrap();
|
|
100
|
+
// 二级菜单中的ul
|
|
101
|
+
.ant-menu-sub {
|
|
102
|
+
.menu-content();
|
|
164
103
|
}
|
|
165
104
|
}
|
package/dist/Modal/index.d.ts
CHANGED
|
@@ -18,7 +18,7 @@ export interface ModalProps extends Omit<AntdModalProps, 'okButtonProps' | 'canc
|
|
|
18
18
|
okType?: ButtonType;
|
|
19
19
|
paddingLess?: boolean;
|
|
20
20
|
virtualScrollBar?: boolean;
|
|
21
|
-
|
|
21
|
+
hideHeaderBottomBorder?: boolean;
|
|
22
22
|
}
|
|
23
23
|
export interface ModalFuncProps extends Omit<AntdModalFuncProps, 'okButtonProps' | 'cancelButtonProps' | 'okType' | 'icon'> {
|
|
24
24
|
cancelButtonProps?: IButtonProps;
|
package/dist/Modal/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
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
2
|
var _excluded = ["className", "type", "loading", "size", "disabled", "shape"],
|
|
3
|
-
_excluded2 = ["className", "children", "okType", "width", "closeIcon", "subTitle", "okButtonProps", "cancelButtonProps", "okText", "cancelText", "icon", "title", "paddingLess", "
|
|
3
|
+
_excluded2 = ["className", "children", "okType", "width", "closeIcon", "subTitle", "okButtonProps", "cancelButtonProps", "okText", "cancelText", "icon", "title", "paddingLess", "hideHeaderBottomBorder", "virtualScrollBar"],
|
|
4
4
|
_excluded3 = ["okButtonProps", "cancelButtonProps", "okType", "width", "title", "subTitle", "okText", "cancelText", "className"],
|
|
5
5
|
_excluded4 = ["okButtonProps", "cancelButtonProps", "okType", "width", "title", "subTitle", "okText", "cancelText", "className"],
|
|
6
6
|
_excluded5 = ["okButtonProps", "cancelButtonProps", "okType", "width", "title", "subTitle", "okText", "cancelText", "className"],
|
|
@@ -20,7 +20,7 @@ import useModal from 'antd/lib/modal/useModal/index';
|
|
|
20
20
|
import classNames from 'classnames';
|
|
21
21
|
import React from 'react';
|
|
22
22
|
import { btnPrefix, getButtonSizeClass, getButtonType, getDangerStatus, getShape } from "../Button";
|
|
23
|
-
import {
|
|
23
|
+
import { AttentionTriangleLightLine, CheckCircleLightLine, CloseLLine, InformationCircleLightLine } from "../Icon";
|
|
24
24
|
import IconButton from "../IconButton";
|
|
25
25
|
import ScrollArea from "../ScrollArea";
|
|
26
26
|
|
|
@@ -49,18 +49,20 @@ function getButtonProps(buttonProps, defaultBtnType, okType) {
|
|
|
49
49
|
shape: getShape(shape)
|
|
50
50
|
});
|
|
51
51
|
}
|
|
52
|
-
var ModalTitle = function ModalTitle(_ref) {
|
|
52
|
+
var ModalTitle = function ModalTitle(_ref, type) {
|
|
53
53
|
var icon = _ref.icon,
|
|
54
54
|
title = _ref.title,
|
|
55
55
|
subTitle = _ref.subTitle;
|
|
56
56
|
return /*#__PURE__*/React.createElement("div", {
|
|
57
57
|
className: 'ald-modal-title-container'
|
|
58
|
-
},
|
|
58
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
59
|
+
className: classNames('ald-modal-icon-container', _defineProperty({}, "ald-modal-cion-".concat(type, "-container"), type))
|
|
60
|
+
}, icon), /*#__PURE__*/React.createElement("div", {
|
|
59
61
|
className: 'ald-modal-text-container'
|
|
60
62
|
}, title && /*#__PURE__*/React.createElement("div", {
|
|
61
|
-
className: 'title'
|
|
63
|
+
className: 'ald-modal-text-title'
|
|
62
64
|
}, title), subTitle && /*#__PURE__*/React.createElement("div", {
|
|
63
|
-
className: '
|
|
65
|
+
className: 'ald-modal-text-sub-title'
|
|
64
66
|
}, subTitle)));
|
|
65
67
|
};
|
|
66
68
|
var OriginModal = function OriginModal(props) {
|
|
@@ -81,30 +83,19 @@ var OriginModal = function OriginModal(props) {
|
|
|
81
83
|
icon = props.icon,
|
|
82
84
|
title = props.title,
|
|
83
85
|
paddingLess = props.paddingLess,
|
|
86
|
+
hideHeaderBottomBorder = props.hideHeaderBottomBorder,
|
|
84
87
|
virtualScrollBar = props.virtualScrollBar,
|
|
85
|
-
_props$hasHeaderBotto = props.hasHeaderBottomBorder,
|
|
86
|
-
hasHeaderBottomBorder = _props$hasHeaderBotto === void 0 ? false : _props$hasHeaderBotto,
|
|
87
88
|
restProps = _objectWithoutProperties(props, _excluded2);
|
|
88
89
|
return /*#__PURE__*/React.createElement(AntdModal, _extends({}, restProps, {
|
|
89
90
|
title: ModalTitle({
|
|
90
91
|
icon: icon,
|
|
91
92
|
title: title,
|
|
92
93
|
subTitle: subTitle
|
|
93
|
-
})
|
|
94
|
-
// title={
|
|
95
|
-
// <div className={'ald-modal-title-container'}>
|
|
96
|
-
// {icon}
|
|
97
|
-
// <div className={'ald-modal-text-container'}>
|
|
98
|
-
// {title && <div className={'title'}>{title}</div>}
|
|
99
|
-
// {subTitle && <div className={'subTitle'}>{subTitle}</div>}
|
|
100
|
-
// </div>
|
|
101
|
-
// </div>
|
|
102
|
-
// }
|
|
103
|
-
,
|
|
94
|
+
}),
|
|
104
95
|
className: classNames('ald-modal', className, {
|
|
105
96
|
'ald-modal-padding-less': paddingLess,
|
|
106
97
|
'ald-modal-virtual-scroll-bar': virtualScrollBar,
|
|
107
|
-
'ald-modal-header-bottom-border':
|
|
98
|
+
'ald-modal-show-header-bottom-border': hideHeaderBottomBorder
|
|
108
99
|
}),
|
|
109
100
|
okButtonProps: getButtonProps(okButtonProps, 'primary', okType),
|
|
110
101
|
cancelButtonProps: getButtonProps(cancelButtonProps, 'secondary'),
|
|
@@ -113,10 +104,9 @@ var OriginModal = function OriginModal(props) {
|
|
|
113
104
|
width: width || DEFAULT_WIDTH,
|
|
114
105
|
closeIcon: closeIcon || /*#__PURE__*/React.createElement(IconButton, {
|
|
115
106
|
icon: /*#__PURE__*/React.createElement(CloseLLine, {
|
|
116
|
-
color: "#171717",
|
|
117
107
|
size: 20
|
|
118
108
|
}),
|
|
119
|
-
size:
|
|
109
|
+
size: "middle"
|
|
120
110
|
})
|
|
121
111
|
}), virtualScrollBar ? /*#__PURE__*/React.createElement(ScrollArea, {
|
|
122
112
|
className: 'ald-modal-body-wrap',
|
|
@@ -146,14 +136,13 @@ Modal.info = function infoFn(props) {
|
|
|
146
136
|
width: width || DEFAULT_WIDTH,
|
|
147
137
|
className: classNames('ald-modal', className),
|
|
148
138
|
title: ModalTitle({
|
|
149
|
-
icon: /*#__PURE__*/React.createElement(
|
|
150
|
-
size:
|
|
151
|
-
color: '#
|
|
152
|
-
className: "ald-modal-close"
|
|
139
|
+
icon: /*#__PURE__*/React.createElement(InformationCircleLightLine, {
|
|
140
|
+
size: 24,
|
|
141
|
+
color: '#2986F4'
|
|
153
142
|
}),
|
|
154
143
|
title: title,
|
|
155
144
|
subTitle: subTitle
|
|
156
|
-
}),
|
|
145
|
+
}, 'info'),
|
|
157
146
|
okText: okText,
|
|
158
147
|
cancelText: cancelText
|
|
159
148
|
}, restProps));
|
|
@@ -179,14 +168,14 @@ Modal.success = function successFn(props) {
|
|
|
179
168
|
width: width || DEFAULT_WIDTH,
|
|
180
169
|
className: classNames('ald-modal', className),
|
|
181
170
|
title: ModalTitle({
|
|
182
|
-
icon: /*#__PURE__*/React.createElement(
|
|
171
|
+
icon: /*#__PURE__*/React.createElement(CheckCircleLightLine, {
|
|
183
172
|
fill: "#fff",
|
|
184
|
-
color: "#
|
|
185
|
-
size:
|
|
173
|
+
color: "#22C55E",
|
|
174
|
+
size: 24
|
|
186
175
|
}),
|
|
187
176
|
title: title,
|
|
188
177
|
subTitle: subTitle
|
|
189
|
-
}),
|
|
178
|
+
}, 'success'),
|
|
190
179
|
okText: okText,
|
|
191
180
|
cancelText: cancelText
|
|
192
181
|
}, restProps));
|
|
@@ -212,14 +201,14 @@ Modal.error = function errorFn(props) {
|
|
|
212
201
|
width: width || DEFAULT_WIDTH,
|
|
213
202
|
className: classNames('ald-modal', className),
|
|
214
203
|
title: ModalTitle({
|
|
215
|
-
icon: /*#__PURE__*/React.createElement(
|
|
216
|
-
color: "#
|
|
204
|
+
icon: /*#__PURE__*/React.createElement(AttentionTriangleLightLine, {
|
|
205
|
+
color: "#EF4444",
|
|
217
206
|
fill: '#fff',
|
|
218
|
-
size:
|
|
207
|
+
size: 24
|
|
219
208
|
}),
|
|
220
209
|
title: title,
|
|
221
210
|
subTitle: subTitle
|
|
222
|
-
}),
|
|
211
|
+
}, 'error'),
|
|
223
212
|
okText: okText,
|
|
224
213
|
cancelText: cancelText
|
|
225
214
|
}, restProps));
|
|
@@ -246,13 +235,13 @@ Modal.warning = function modalWarn(props) {
|
|
|
246
235
|
// className: classNames('ald-modal-warning', className),
|
|
247
236
|
className: classNames('ald-modal ald-modal-warning', className),
|
|
248
237
|
title: ModalTitle({
|
|
249
|
-
icon: /*#__PURE__*/React.createElement(
|
|
250
|
-
color: "#
|
|
251
|
-
size:
|
|
238
|
+
icon: /*#__PURE__*/React.createElement(AttentionTriangleLightLine, {
|
|
239
|
+
color: "#EAB308",
|
|
240
|
+
size: 24
|
|
252
241
|
}),
|
|
253
242
|
title: title,
|
|
254
243
|
subTitle: subTitle
|
|
255
|
-
}),
|
|
244
|
+
}, 'warning'),
|
|
256
245
|
okText: okText,
|
|
257
246
|
cancelText: cancelText
|
|
258
247
|
}, restProps));
|
|
@@ -278,14 +267,14 @@ Modal.confirm = function confirmFn(props) {
|
|
|
278
267
|
width: width || DEFAULT_WIDTH,
|
|
279
268
|
className: classNames('ald-modal', className),
|
|
280
269
|
title: ModalTitle({
|
|
281
|
-
icon: /*#__PURE__*/React.createElement(
|
|
282
|
-
size:
|
|
283
|
-
color: '#
|
|
270
|
+
icon: /*#__PURE__*/React.createElement(InformationCircleLightLine, {
|
|
271
|
+
size: 24,
|
|
272
|
+
color: '#2986F4',
|
|
284
273
|
className: "ald-modal-close"
|
|
285
274
|
}),
|
|
286
275
|
title: title,
|
|
287
276
|
subTitle: subTitle
|
|
288
|
-
}),
|
|
277
|
+
}, 'confirm'),
|
|
289
278
|
okText: okText,
|
|
290
279
|
cancelText: cancelText
|
|
291
280
|
}, restProps));
|