@aloudata/aloudata-design 1.10.13 → 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.
Files changed (195) hide show
  1. package/dist/Button/index.d.ts +3 -4
  2. package/dist/Button/index.js +7 -20
  3. package/dist/Button/style/size.less +21 -8
  4. package/dist/Button/style/type.less +61 -33
  5. package/dist/Button/style/variables.less +229 -44
  6. package/dist/Checkbox/style/index.less +111 -114
  7. package/dist/Dropdown/index.d.ts +1 -2
  8. package/dist/Dropdown/style/index.less +70 -107
  9. package/dist/Icon/components/AlertTriangleDuotone.d.ts +1 -1
  10. package/dist/Icon/components/AlertTriangleLine.d.ts +11 -0
  11. package/dist/Icon/components/AlertTriangleLine.js +35 -0
  12. package/dist/Icon/components/ArrowDownFill.d.ts +11 -0
  13. package/dist/Icon/components/ArrowDownFill.js +35 -0
  14. package/dist/Icon/components/AttentionCircleFill.d.ts +11 -0
  15. package/dist/Icon/components/AttentionCircleFill.js +35 -0
  16. package/dist/Icon/components/AttentionTriangleFill.d.ts +11 -0
  17. package/dist/Icon/components/AttentionTriangleFill.js +35 -0
  18. package/dist/Icon/components/AttentionTriangleLightLine.d.ts +11 -0
  19. package/dist/Icon/components/AttentionTriangleLightLine.js +35 -0
  20. package/dist/Icon/components/CancelCircleDuotone.d.ts +1 -1
  21. package/dist/Icon/components/CheckCircleDuotone.d.ts +1 -1
  22. package/dist/Icon/components/CheckCircleFill.d.ts +11 -0
  23. package/dist/Icon/components/CheckCircleFill.js +35 -0
  24. package/dist/Icon/components/CheckCircleLightLine.d.ts +11 -0
  25. package/dist/Icon/components/CheckCircleLightLine.js +38 -0
  26. package/dist/Icon/components/CheckLightLine.d.ts +11 -0
  27. package/dist/Icon/components/CheckLightLine.js +35 -0
  28. package/dist/Icon/components/ChevronDownLine.d.ts +1 -1
  29. package/dist/Icon/components/ChevronLeftLine.d.ts +1 -1
  30. package/dist/Icon/components/ChevronRightLine.d.ts +1 -1
  31. package/dist/Icon/components/CircleLightLine.d.ts +11 -0
  32. package/dist/Icon/components/CircleLightLine.js +38 -0
  33. package/dist/Icon/components/CloseCircleFill.d.ts +11 -0
  34. package/dist/Icon/components/CloseCircleFill.js +35 -0
  35. package/dist/Icon/components/CloseLLine.d.ts +1 -1
  36. package/dist/Icon/components/CloseLightLine.d.ts +11 -0
  37. package/dist/Icon/components/CloseLightLine.js +35 -0
  38. package/dist/Icon/components/CloseMLine.d.ts +1 -1
  39. package/dist/Icon/components/DragLine.d.ts +1 -1
  40. package/dist/Icon/components/Ellipsis.d.ts +11 -0
  41. package/dist/Icon/components/Ellipsis.js +35 -0
  42. package/dist/Icon/components/EyeOffLine.d.ts +1 -1
  43. package/dist/Icon/components/EyeOnLine.d.ts +1 -1
  44. package/dist/Icon/components/FoldDownFill.d.ts +1 -1
  45. package/dist/Icon/components/FoldUpFill.d.ts +1 -1
  46. package/dist/Icon/components/InfoCircleDuotone.d.ts +1 -1
  47. package/dist/Icon/components/InfoCircleLine.d.ts +1 -1
  48. package/dist/Icon/components/InformationCircleFill.d.ts +11 -0
  49. package/dist/Icon/components/InformationCircleFill.js +35 -0
  50. package/dist/Icon/components/InformationCircleLightLine.d.ts +11 -0
  51. package/dist/Icon/components/InformationCircleLightLine.js +38 -0
  52. package/dist/Icon/components/Loading2Line.d.ts +1 -1
  53. package/dist/Icon/components/LoadingDuotone.d.ts +11 -0
  54. package/dist/Icon/components/LoadingDuotone.js +39 -0
  55. package/dist/Icon/components/LoadingLine.d.ts +1 -1
  56. package/dist/Icon/components/MoreVerticalLine.d.ts +1 -1
  57. package/dist/Icon/components/SearchLine.d.ts +1 -1
  58. package/dist/Icon/components/TriangleLightLine.d.ts +11 -0
  59. package/dist/Icon/components/TriangleLightLine.js +35 -0
  60. package/dist/Icon/index.d.ts +16 -3
  61. package/dist/Icon/index.js +16 -2
  62. package/dist/Icon/svg/Loading-duotone.svg +6 -0
  63. package/dist/Icon/svg/alert-triangle-duotone.svg +3 -1
  64. package/dist/Icon/svg/alert-triangle-line.svg +5 -0
  65. package/dist/Icon/svg/arrow-down-fill.svg +5 -0
  66. package/dist/Icon/svg/attention-circle-fill.svg +5 -0
  67. package/dist/Icon/svg/attention-triangle-fill.svg +5 -0
  68. package/dist/Icon/svg/attention-triangle-light-line.svg +5 -0
  69. package/dist/Icon/svg/cancel-circle-duotone.svg +7 -3
  70. package/dist/Icon/svg/check-circle-duotone.svg +6 -2
  71. package/dist/Icon/svg/check-circle-fill.svg +5 -0
  72. package/dist/Icon/svg/check-circle-light-line.svg +8 -0
  73. package/dist/Icon/svg/check-light-line.svg +5 -0
  74. package/dist/Icon/svg/chevron-down-line.svg +6 -4
  75. package/dist/Icon/svg/chevron-left-line.svg +6 -4
  76. package/dist/Icon/svg/chevron-right-line.svg +6 -4
  77. package/dist/Icon/svg/circle-light-line.svg +9 -0
  78. package/dist/Icon/svg/close-L-line.svg +11 -9
  79. package/dist/Icon/svg/close-circle-fill.svg +5 -0
  80. package/dist/Icon/svg/close-light-line.svg +5 -0
  81. package/dist/Icon/svg/close-m-line.svg +6 -4
  82. package/dist/Icon/svg/drag-line.svg +6 -4
  83. package/dist/Icon/svg/ellipsis.svg +5 -0
  84. package/dist/Icon/svg/eye-off-line.svg +6 -4
  85. package/dist/Icon/svg/eye-on-line.svg +14 -8
  86. package/dist/Icon/svg/fold-down-fill.svg +7 -6
  87. package/dist/Icon/svg/fold-up-fill.svg +7 -6
  88. package/dist/Icon/svg/info-circle-duotone.svg +4 -2
  89. package/dist/Icon/svg/info-circle-line.svg +3 -1
  90. package/dist/Icon/svg/information-circle-fill.svg +5 -0
  91. package/dist/Icon/svg/information-circle-light-line.svg +9 -0
  92. package/dist/Icon/svg/loading-2-line.svg +4 -2
  93. package/dist/Icon/svg/loading-line.svg +6 -4
  94. package/dist/Icon/svg/more-vertical-line.svg +6 -4
  95. package/dist/Icon/svg/search-line.svg +6 -4
  96. package/dist/Icon/svg/triangle-light-line.svg +5 -0
  97. package/dist/IconButton/index.d.ts +2 -2
  98. package/dist/IconButton/index.js +8 -19
  99. package/dist/IconButton/style/index.less +49 -25
  100. package/dist/Input/components/Input/index.js +18 -2
  101. package/dist/Input/components/Password/index.d.ts +0 -5
  102. package/dist/Input/components/Password/index.js +10 -10
  103. package/dist/Input/components/TextArea/index.js +15 -2
  104. package/dist/Input/index.d.ts +2 -5
  105. package/dist/Input/index.js +1 -3
  106. package/dist/Input/style/index.less +4 -565
  107. package/dist/Input/style/reset.less +22 -0
  108. package/dist/Input/style/size.less +82 -0
  109. package/dist/Input/style/status.less +105 -0
  110. package/dist/MemberPicker/components/MemberSelection.d.ts +2 -1
  111. package/dist/MemberPicker/components/MemberSelection.js +9 -1
  112. package/dist/MemberPicker/components/MultipleOption.js +1 -1
  113. package/dist/MemberPicker/components/Panel.d.ts +2 -1
  114. package/dist/MemberPicker/components/Panel.js +9 -3
  115. package/dist/MemberPicker/components/PanelWrapper.d.ts +3 -2
  116. package/dist/MemberPicker/components/PanelWrapper.js +5 -2
  117. package/dist/MemberPicker/components/SelectedMemberTags.d.ts +2 -1
  118. package/dist/MemberPicker/components/SelectedMemberTags.js +19 -2
  119. package/dist/MemberPicker/components/UserGroupSelection.d.ts +3 -2
  120. package/dist/MemberPicker/components/UserGroupSelection.js +8 -1
  121. package/dist/MemberPicker/index.js +4 -1
  122. package/dist/MemberPicker/interface.d.ts +1 -0
  123. package/dist/MemberPicker/style/index.less +10 -2
  124. package/dist/Menu/index.js +6 -9
  125. package/dist/Menu/style/index.less +72 -133
  126. package/dist/Modal/index.d.ts +1 -1
  127. package/dist/Modal/index.js +32 -43
  128. package/dist/Modal/style/index.less +3 -191
  129. package/dist/Modal/style/modal.less +132 -0
  130. package/dist/Modal/style/modalConfirm.less +100 -0
  131. package/dist/Pagination/index.js +4 -2
  132. package/dist/Pagination/style/index.less +11 -4
  133. package/dist/Popconfirm/index.js +8 -7
  134. package/dist/Popconfirm/style/index.less +16 -6
  135. package/dist/Popover/style/index.less +29 -29
  136. package/dist/Radio/components/Group/index.js +3 -5
  137. package/dist/Radio/components/Radio/index.js +2 -1
  138. package/dist/Radio/interface/radioGroup.d.ts +1 -1
  139. package/dist/Radio/style/index.less +69 -56
  140. package/dist/Select/components/{MultipleOption.d.ts → Option.d.ts} +2 -2
  141. package/dist/Select/components/{MultipleOption.js → Option.js} +14 -11
  142. package/dist/Select/components/SingleOption.d.ts +2 -2
  143. package/dist/Select/components/SingleOption.js +3 -1
  144. package/dist/Select/index.d.ts +5 -0
  145. package/dist/Select/index.js +26 -41
  146. package/dist/Select/style/index.less +96 -76
  147. package/dist/Select/style/layout.less +41 -0
  148. package/dist/Select/style/option.less +42 -0
  149. package/dist/Select/style/selectDropdown.less +17 -0
  150. package/dist/Select/style/size.less +95 -82
  151. package/dist/Select/style/status.less +69 -21
  152. package/dist/Select/style/variables.less +9 -16
  153. package/dist/Spin/CustomIcon/index.d.ts +3 -0
  154. package/dist/Spin/CustomIcon/index.js +20 -15
  155. package/dist/Spin/CustomIcon/index.less +32 -105
  156. package/dist/Spin/index.d.ts +2 -0
  157. package/dist/Spin/index.js +8 -2
  158. package/dist/Spin/style/index.less +9 -1
  159. package/dist/Switch/index.d.ts +1 -1
  160. package/dist/Switch/style/index.less +130 -56
  161. package/dist/Table/style/index.less +16 -8
  162. package/dist/Tabs/index.d.ts +2 -2
  163. package/dist/Tabs/index.js +4 -4
  164. package/dist/Tabs/style/index.less +20 -16
  165. package/dist/TextLink/index.d.ts +44 -0
  166. package/dist/TextLink/index.js +25 -0
  167. package/dist/TextLink/style/index.d.ts +2 -0
  168. package/dist/TextLink/style/index.js +2 -0
  169. package/dist/TextLink/style/index.less +9 -0
  170. package/dist/TextLink/style/size.less +37 -0
  171. package/dist/TextLink/style/type.less +44 -0
  172. package/dist/Tree/style/var.less +1 -1
  173. package/dist/ald.min.css +1 -1
  174. package/dist/index.d.ts +2 -1
  175. package/dist/index.js +1 -1
  176. package/dist/index.less +1 -0
  177. package/dist/message/index.js +15 -14
  178. package/dist/message/style/color.less +22 -41
  179. package/dist/message/style/index.less +15 -16
  180. package/dist/notification/demo/index.js +1 -0
  181. package/dist/notification/index.js +18 -18
  182. package/dist/notification/style/index.less +12 -6
  183. package/dist/style/index.less +1 -0
  184. package/dist/style/themes/default/default.less +1 -1
  185. package/dist/style/themes/default/index.less +3 -3
  186. package/dist/style/themes/default/scrollBar.less +1 -1
  187. package/dist/style/var/default.css +1334 -0
  188. package/package.json +4 -3
  189. package/dist/Icon/components/Icon.d.ts +0 -32
  190. package/dist/Icon/components/Icon.js +0 -25
  191. package/dist/Input/components/Group/index.d.ts +0 -18
  192. package/dist/Input/components/Group/index.js +0 -19
  193. package/dist/Menu/style/dropdown.less +0 -61
  194. package/dist/Select/style/multiple.less +0 -55
  195. package/dist/Select/style/single.less +0 -44
@@ -1,35 +1,28 @@
1
- /* stylelint-disable property-no-unknown */
2
1
  @import '../../style/index.less';
3
-
2
+ @import './option.less';
4
3
  // large size
5
4
  @select-height-large: 36px;
6
- @select-border-radius-large: 4px;
5
+ @select-border-radius-large: 8px;
7
6
  @select-font-size-large: 16px;
8
7
  @select-line-height-large: 24px;
9
- @select-padding-left-large: 11px;
8
+ @select-padding-horizontal-large: var(--alias-padding-150-minus-1, 12px);
10
9
  @selector-height-large: 34px;
11
10
  @selector-item-margin-left-large: 8px;
12
- // @prefix-margin-right-large: 8px;
13
- // @select-padding-horizontal-large: 11px;
14
11
 
15
12
  // medium size
16
13
  @select-height-middle: 32px;
17
- @select-border-radius-middle: 2px;
18
- @select-font-size-middle: 13px;
14
+ @select-border-radius-middle: 6px;
15
+ @select-font-size-middle: 14px;
19
16
  @select-line-height-middle: 20px;
20
- @select-padding-left-middle: 7px;
17
+ @select-padding-horizontal-middle: var(--alias-padding-150-minus-1, 12px);
21
18
  @selector-height-middle: 30px;
22
- @selector-item-margin-left-middle: 4px;
23
- // @prefix-margin-right-middle: 8px;
24
- // @select-padding-horizontal-middle: 11px;
19
+ @selector-item-margin-left-middle: 6px;
25
20
 
26
21
  // small size
27
22
  @select-height-small: 28px;
28
- @select-border-radius-small: 2px;
23
+ @select-border-radius-small: 4px;
29
24
  @select-font-size-small: 12px;
30
25
  @select-line-height-small: 16px;
31
- @select-padding-left-small: 7px;
26
+ @select-padding-horizontal-small: var(--alias-padding-150-minus-1, 12px);
32
27
  @selector-height-small: 26px;
33
28
  @selector-item-margin-left-small: 4px;
34
- // @prefix-margin-right-small: 4px;
35
- // @select-padding-horizontal-small: 7px;
@@ -1,8 +1,11 @@
1
1
  import React from 'react';
2
+ import { TDirection } from '..';
2
3
  import type { SizeType } from '../../ConfigProvider/SizeContext';
3
4
  import './index.less';
4
5
  interface ICustomIconProps {
5
6
  size?: SizeType;
7
+ tip?: React.ReactNode;
8
+ direction: TDirection;
6
9
  }
7
10
  declare const Icon: (props: ICustomIconProps) => React.JSX.Element;
8
11
  export default Icon;
@@ -1,24 +1,29 @@
1
+ import { LoadingDuotone } from "../../Icon";
2
+ import classNames from 'classnames';
1
3
  import React from 'react';
2
4
  import "./index.less";
3
- import classNames from 'classnames';
4
5
  var Icon = function Icon(props) {
5
- var size = props.size;
6
+ var size = props.size,
7
+ tip = props.tip,
8
+ direction = props.direction;
6
9
  return /*#__PURE__*/React.createElement("div", {
7
10
  className: classNames('spinner', {
8
- 'spinner-small': size === 'small',
9
- 'spinner-large': size === 'large',
10
- 'spinner-middle': size !== 'small' && size !== 'large'
11
+ 'spinner-horizontal': direction === 'horizontal'
11
12
  })
12
13
  }, /*#__PURE__*/React.createElement("div", {
13
- className: "spinner-inner"
14
- }, /*#__PURE__*/React.createElement("span", {
15
- className: "icon-bar"
16
- }), /*#__PURE__*/React.createElement("span", {
17
- className: "icon-bar"
18
- }), /*#__PURE__*/React.createElement("span", {
19
- className: "icon-bar"
20
- }), /*#__PURE__*/React.createElement("span", {
21
- className: "icon-bar"
22
- })));
14
+ className: classNames('spinner-inner', {
15
+ 'spinner-inner-small': size === 'small',
16
+ 'spinner-inner-large': size === 'large',
17
+ 'spinner-inner-middle': size !== 'small' && size !== 'large'
18
+ })
19
+ }, size === 'small' && /*#__PURE__*/React.createElement(LoadingDuotone, {
20
+ size: 20
21
+ }), size === 'large' && /*#__PURE__*/React.createElement(LoadingDuotone, {
22
+ size: 64
23
+ }), size !== 'small' && size !== 'large' && /*#__PURE__*/React.createElement(LoadingDuotone, {
24
+ size: 40
25
+ })), /*#__PURE__*/React.createElement("div", {
26
+ className: "spinner-text"
27
+ }, tip));
23
28
  };
24
29
  export default Icon;
@@ -1,125 +1,52 @@
1
1
  @import '../../style/themes/default/themeColor.module.less';
2
- @spin-icon-gap-large: 10px;
3
- @spin-icon-width-large: 56px;
4
- @spin-icon-height-large: 56px;
5
- @spin-icon-bar-height-large: 32px; //1.75
6
- @spin-icon-bar-width-large: 6px;
7
2
 
8
- @spin-icon-gap-middle: 6px;
9
- @spin-icon-width-middle: 36px;
10
- @spin-icon-height-middle: 36px;
11
- @spin-icon-bar-height-middle: 20px; //1.8
12
- @spin-icon-bar-width-middle: 4px;
3
+ @spinner-size-large: 64px;
4
+ @spinner-size-middle: 40px;
5
+ @spinner-size-small: 20px;
13
6
 
14
- @spin-icon-gap-small: 4px;
15
- @spin-icon-width-small: 24px;
16
- @spin-icon-height-small: 24px;
17
- @spin-icon-bar-height-small: 14px; //1.7143
18
- @spin-icon-bar-width-small: 2.5px;
19
-
20
- .spinner {
21
- display: inline-block;
22
- position: absolute;
23
- top: 50%;
24
- inset-inline-start: 50%;
25
-
26
- &.spinner-large {
27
- margin: 0 - (@spin-icon-width-large / 2);
28
-
29
- .spinner-inner {
30
- gap: @spin-icon-gap-large;
31
- width: @spin-icon-width-large;
32
- height: @spin-icon-width-large;
33
-
34
- .icon-bar {
35
- width: @spin-icon-bar-width-large;
36
- height: @spin-icon-bar-height-large;
37
- }
38
- }
39
- }
40
-
41
- &.spinner-middle {
42
- margin: 0 - (@spin-icon-width-middle / 2);
43
-
44
- .spinner-inner {
45
- gap: @spin-icon-gap-middle;
46
- width: @spin-icon-width-middle;
47
- height: @spin-icon-width-middle;
48
-
49
- .icon-bar {
50
- width: @spin-icon-bar-width-middle;
51
- height: @spin-icon-bar-height-middle;
52
- }
53
- }
54
- }
55
-
56
- &.spinner-small {
57
- margin: 0 - (@spin-icon-width-small / 2);
58
-
59
- .spinner-inner {
60
- gap: @spin-icon-gap-small;
61
- width: @spin-icon-width-small;
62
- height: @spin-icon-width-small;
63
-
64
- .icon-bar {
65
- width: @spin-icon-bar-width-small;
66
- height: @spin-icon-bar-height-small;
67
- }
68
- }
69
- }
70
-
71
- .spinner-inner {
72
- display: flex;
73
- height: 100%;
74
- align-items: center;
75
- justify-content: center;
76
- }
7
+ .spinner-inner-small {
8
+ width: @spinner-size-small;
9
+ height: @spinner-size-small;
77
10
  }
78
11
 
79
- .spinner .icon-bar {
80
- background: @B40;
81
- animation: grow 1s ease-in-out infinite;
12
+ .spinner-inner-middle {
13
+ width: @spinner-size-middle;
14
+ height: @spinner-size-middle;
82
15
  }
83
16
 
84
- .spinner .icon-bar:nth-child(2) {
85
- animation: grow 1s ease-in-out 0.15s infinite;
17
+ .spinner-inner-large {
18
+ width: @spinner-size-large;
19
+ height: @spinner-size-large;
86
20
  }
87
21
 
88
- .spinner .icon-bar:nth-child(3) {
89
- animation: grow 1s ease-in-out 0.3s infinite;
22
+ .spinner-inner {
23
+ animation: rotate 2s linear infinite;
24
+ display: flex;
25
+ align-items: center;
90
26
  }
91
27
 
92
- .spinner .icon-bar:nth-child(4) {
93
- animation: grow 1s ease-in-out 0.475s infinite;
94
- }
95
-
96
- @keyframes grow {
97
- 0%,
98
- 100% {
99
- transform: scaleY(1);
100
- }
28
+ .spinner {
29
+ display: flex;
30
+ flex-direction: column;
31
+ align-items: center;
32
+ gap: 16px;
101
33
 
102
- 50% {
103
- transform: scaleY(1.8);
34
+ &.spinner-horizontal {
35
+ flex-direction: row;
36
+ gap: 6px;
104
37
  }
105
38
  }
106
39
 
107
- .ant-spin-show-text {
108
- .spinner-large {
109
- margin-top: -56px;
110
- }
40
+ .spinner-text {
41
+ color: var(--alias-colors-text-subtle, #4b5563);
42
+ }
111
43
 
112
- .spinner-middle {
113
- margin-top: -36px;
44
+ @keyframes rotate {
45
+ 0% {
46
+ transform: rotate(0deg);
114
47
  }
115
48
 
116
- .spinner-small {
117
- margin-top: -20px;
49
+ 100% {
50
+ transform: rotate(360deg);
118
51
  }
119
52
  }
120
-
121
- .ant-spin-nested-loading .ant-spin-show-text .ant-spin-text {
122
- padding-top: 16px;
123
- font-size: 13px;
124
- line-height: 20px;
125
- }
@@ -1,7 +1,9 @@
1
1
  import { SpinProps as AntdSpinProps } from 'antd';
2
2
  import React from 'react';
3
+ export type TDirection = 'vertical' | 'horizontal';
3
4
  export interface SpinProps extends Omit<AntdSpinProps, 'size'> {
4
5
  size?: 'small' | 'large' | 'middle';
6
+ direction?: TDirection;
5
7
  }
6
8
  declare function CustomSpin(props: SpinProps): React.JSX.Element;
7
9
  export default CustomSpin;
@@ -1,4 +1,4 @@
1
- var _excluded = ["size"];
1
+ var _excluded = ["size", "tip", "direction"];
2
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
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
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; }
@@ -8,6 +8,9 @@ import React from 'react';
8
8
  import CustomIcon from "./CustomIcon";
9
9
  function CustomSpin(props) {
10
10
  var size = props.size,
11
+ tip = props.tip,
12
+ _props$direction = props.direction,
13
+ direction = _props$direction === void 0 ? 'vertical' : _props$direction,
11
14
  restProps = _objectWithoutProperties(props, _excluded);
12
15
  var spinSize = 'default';
13
16
  if (size === 'middle') {
@@ -16,9 +19,12 @@ function CustomSpin(props) {
16
19
  return /*#__PURE__*/React.createElement(Spin, _extends({
17
20
  className: classNames('ald-spin', props.className),
18
21
  indicator: /*#__PURE__*/React.createElement(CustomIcon, {
19
- size: props.size
22
+ size: props.size,
23
+ tip: tip,
24
+ direction: direction
20
25
  })
21
26
  }, restProps, {
27
+ tip: null,
22
28
  size: spinSize
23
29
  }));
24
30
  }
@@ -1,7 +1,15 @@
1
1
  @import '../../style/index.less';
2
2
 
3
3
  .ant-spin.ald-spin {
4
+ display: flex !important;
5
+ align-items: center;
6
+ flex-direction: column;
7
+ justify-content: space-evenly;
8
+ gap: 6px;
9
+
4
10
  .ant-spin-text {
5
- color: @B40;
11
+ position: relative !important;
12
+ top: 0 !important;
13
+ left: 0 !important;
6
14
  }
7
15
  }
@@ -31,7 +31,7 @@ export interface ISwitchProps {
31
31
  * @description 尺寸大小
32
32
  * @default middle
33
33
  */
34
- size?: 'middle' | 'small';
34
+ size?: 'large' | 'middle' | 'small';
35
35
  /**
36
36
  * @description 点击时的回调
37
37
  * @type (checked: boolean, event: React.MouseEvent<HTMLButtonElement>) => void;
@@ -1,47 +1,64 @@
1
1
  @import '../../style/index.less';
2
2
 
3
- @switch-handle-middle: @font-size-middle;
4
- @switch-handle-height-middle: @line-height-middle;
5
- @switch-handle-small: @font-size-small;
6
- @switch-handle-height-small: @line-height-small;
7
- @switch-handle-gap-middle: 3px;
8
- @switch-handle-gap-small: 2px;
9
- @switch-text-margin-left: 8px;
10
- @switch-aspect-ratio: 2; //宽高比
11
- @switch-height-radius-ratio: 2; //高度和边框圆角比
12
- @switch-background-color: #dbdbdb;
13
- @switch-background-color-checked: #3271c9;
3
+ @switch-btn-width-large: 36px;
4
+ @switch-btn-height-large: 20px;
5
+ @switch-btn-width-middle: 28px;
6
+ @switch-btn-height-middle: 16px;
7
+ @switch-btn-width-small: 22px;
8
+ @switch-btn-height-small: 12px;
9
+
10
+ @switch-btn-normal-bgc: var(--alias-colors-icon-subtler);
11
+ @switch-btn-normal-hover-bgc: var(--alias-colors-icon-subtle);
12
+ @switch-btn-normal-pressed-bgc: var(--alias-colors-icon-subtle);
13
+ @switch-btn-active-bgc: var(--alias-colors-icon-brand);
14
+ @switch-btn-active-hover-bgc: var(--alias-colors-icon-selected);
15
+ @switch-btn-active-pressed-bgc: var(--alias-colors-icon-selected);
16
+ @switch-btn-disabled-bgc: var(--alias-colors-icon-disabled);
17
+
18
+ @switch-btn-handle-size-large: 16px;
19
+ @switch-btn-handle-size-middle: 12px;
20
+ @switch-btn-handle-size-small: 8px;
21
+ @switch-btn-handle-margin: 2px;
22
+
23
+ @font-size-large: 16px;
24
+ @font-size-middle: 14px;
25
+ @font-size-small: 12px;
14
26
 
15
27
  .ald-switch.ald-switch {
16
28
  display: inline-block;
17
29
  font-size: 0;
18
30
 
19
31
  .ald-switch-btn {
20
- background: @switch-background-color;
32
+ background: @switch-btn-normal-bgc;
33
+ box-shadow: none;
21
34
 
22
- &:focus {
23
- box-shadow: none;
35
+ &:active {
36
+ background-color: @switch-btn-normal-pressed-bgc;
24
37
  }
25
38
 
26
39
  &:hover {
27
- background: @switch-background-color;
40
+ background: @switch-btn-normal-hover-bgc;
28
41
  }
29
42
  }
30
43
 
31
44
  .ald-switch-text {
32
45
  display: inline-flex;
33
46
  align-items: center;
34
- margin-left: @switch-text-margin-left;
47
+ margin-left: 6px;
35
48
  color: @NL0;
36
49
  vertical-align: middle;
37
50
  }
38
51
 
39
52
  &.ald-switch-checked {
40
53
  .ald-switch-btn {
41
- background-color: @switch-background-color-checked;
54
+ background-color: @switch-btn-active-bgc;
42
55
 
43
56
  &:hover {
44
- background-color: @switch-background-color-checked;
57
+ background-color: @switch-btn-active-pressed-bgc;
58
+ }
59
+
60
+ &:active {
61
+ background-color: @switch-btn-active-hover-bgc;
45
62
  }
46
63
  }
47
64
  }
@@ -51,7 +68,15 @@
51
68
 
52
69
  .ald-switch-btn {
53
70
  cursor: initial;
54
- opacity: 0.5;
71
+ background-color: @switch-btn-disabled-bgc;
72
+
73
+ &:hover {
74
+ background-color: @switch-btn-disabled-bgc;
75
+ }
76
+
77
+ &:active {
78
+ background-color: @switch-btn-disabled-bgc;
79
+ }
55
80
 
56
81
  * {
57
82
  cursor: initial;
@@ -66,83 +91,132 @@
66
91
 
67
92
  &.ald-switch-middle {
68
93
  .ald-switch-btn {
69
- width: @switch-handle-height-middle * @switch-aspect-ratio;
70
- min-width: @switch-handle-height-middle * @switch-aspect-ratio;
71
- height: @switch-handle-height-middle;
72
- line-height: @switch-handle-height-middle;
94
+ width: @switch-btn-width-middle;
95
+ min-width: @switch-btn-width-middle;
96
+ height: @switch-btn-height-middle;
97
+ line-height: @switch-btn-height-middle;
73
98
 
74
99
  .ant-switch-handle {
75
- top: @switch-handle-gap-middle;
76
- left: @switch-handle-gap-middle;
77
- width: @switch-handle-middle;
78
- height: @switch-handle-middle;
100
+ top: @switch-btn-handle-margin;
101
+ left: @switch-btn-handle-margin;
102
+ width: @switch-btn-handle-size-middle;
103
+ height: @switch-btn-handle-size-middle;
79
104
 
80
105
  .ant-switch-loading-icon {
81
- width: @switch-handle-middle - 4px;
82
- height: @switch-handle-middle - 4px;
83
- font-size: @switch-handle-middle - 4px;
106
+ width: @switch-btn-handle-size-middle - 4px;
107
+ height: @switch-btn-handle-size-middle - 4px;
108
+ font-size: @switch-btn-handle-size-middle - 4px;
84
109
 
85
110
  svg {
86
- width: @switch-handle-middle - 4px;
87
- height: @switch-handle-middle - 4px;
111
+ width: @switch-btn-handle-size-middle - 4px;
112
+ height: @switch-btn-handle-size-middle - 4px;
88
113
  }
89
114
  }
90
115
  }
91
116
  }
92
117
 
93
118
  .ald-switch-text {
94
- height: @switch-handle-height-middle;
119
+ height: @switch-btn-height-middle;
95
120
  font-size: @font-size-middle;
96
- line-height: @switch-handle-height-middle;
121
+ line-height: @switch-btn-height-middle;
97
122
  }
98
123
 
99
124
  &.ald-switch-checked {
100
125
  .ant-switch-handle {
101
- top: 3px;
102
- left: calc(100% - @switch-handle-middle - @switch-handle-gap-middle);
103
- width: @switch-handle-middle;
104
- height: @switch-handle-middle;
126
+ top: @switch-btn-handle-margin;
127
+ left: calc(
128
+ 100% - @switch-btn-handle-size-middle - @switch-btn-handle-margin
129
+ );
130
+ width: @switch-btn-handle-size-middle;
131
+ height: @switch-btn-handle-size-middle;
105
132
  }
106
133
  }
107
134
  }
108
135
 
109
136
  &.ald-switch-small {
110
137
  .ald-switch-btn {
111
- width: @switch-handle-height-small * @switch-aspect-ratio;
112
- min-width: @switch-handle-height-small * @switch-aspect-ratio;
113
- height: @switch-handle-height-small;
114
- line-height: @switch-handle-height-small;
138
+ width: @switch-btn-width-small;
139
+ min-width: @switch-btn-width-small;
140
+ height: @switch-btn-height-small;
141
+ line-height: @switch-btn-height-small;
115
142
 
116
143
  .ant-switch-handle {
117
- top: @switch-handle-gap-small;
118
- left: @switch-handle-gap-small;
119
- width: @switch-handle-small;
120
- height: @switch-handle-small;
144
+ top: @switch-btn-handle-margin;
145
+ left: @switch-btn-handle-margin;
146
+ width: @switch-btn-handle-size-small;
147
+ height: @switch-btn-handle-size-small;
121
148
 
122
149
  .ant-switch-loading-icon {
123
- width: @switch-handle-small - 4px;
124
- height: @switch-handle-small - 4px;
125
- font-size: @switch-handle-small - 4px;
150
+ width: @switch-btn-handle-size-small - 4px;
151
+ height: @switch-btn-handle-size-small - 4px;
152
+ font-size: @switch-btn-handle-size-small - 4px;
126
153
 
127
154
  svg {
128
- width: @switch-handle-small - 4px;
129
- height: @switch-handle-small - 4px;
155
+ width: @switch-btn-handle-size-small - 4px;
156
+ height: @switch-btn-handle-size-small - 4px;
130
157
  }
131
158
  }
132
159
  }
133
160
  }
134
161
 
135
162
  .ald-switch-text {
136
- height: @switch-handle-height-small;
163
+ height: @switch-btn-height-small;
137
164
  font-size: @font-size-small;
138
- line-height: @switch-handle-height-small;
165
+ line-height: @switch-btn-height-small;
166
+ }
167
+
168
+ &.ald-switch-checked {
169
+ .ant-switch-handle {
170
+ top: @switch-btn-handle-margin;
171
+ left: calc(
172
+ 100% - @switch-btn-handle-size-small - @switch-btn-handle-margin
173
+ );
174
+ width: @switch-btn-handle-size-small;
175
+ height: @switch-btn-handle-size-small;
176
+ }
177
+ }
178
+ }
179
+
180
+ &.ald-switch-large {
181
+ .ald-switch-btn {
182
+ width: @switch-btn-width-large;
183
+ min-width: @switch-btn-width-large;
184
+ height: @switch-btn-height-large;
185
+ line-height: @switch-btn-height-large;
186
+
187
+ .ant-switch-handle {
188
+ top: @switch-btn-handle-margin;
189
+ left: @switch-btn-handle-margin;
190
+ width: @switch-btn-handle-size-large;
191
+ height: @switch-btn-handle-size-large;
192
+
193
+ .ant-switch-loading-icon {
194
+ width: @switch-btn-handle-size-large - 4px;
195
+ height: @switch-btn-handle-size-large - 4px;
196
+ font-size: @switch-btn-handle-size-large - 4px;
197
+
198
+ svg {
199
+ width: @switch-btn-handle-size-large - 4px;
200
+ height: @switch-btn-handle-size-large - 4px;
201
+ }
202
+ }
203
+ }
204
+ }
205
+
206
+ .ald-switch-text {
207
+ height: @switch-btn-height-large;
208
+ font-size: @font-size-large;
209
+ line-height: @switch-btn-height-large;
139
210
  }
140
211
 
141
212
  &.ald-switch-checked {
142
213
  .ant-switch-handle {
143
- left: calc(100% - @switch-handle-small - @switch-handle-gap-small);
144
- width: @switch-handle-small;
145
- height: @switch-handle-small;
214
+ top: @switch-btn-handle-margin;
215
+ left: calc(
216
+ 100% - @switch-btn-handle-size-large - @switch-btn-handle-margin
217
+ );
218
+ width: @switch-btn-handle-size-large;
219
+ height: @switch-btn-handle-size-large;
146
220
  }
147
221
  }
148
222
  }
@@ -42,7 +42,7 @@
42
42
  top: 50%;
43
43
  right: -1px;
44
44
  transform: translateY(-50%);
45
- background-color: #e8e8e8;
45
+ background-color: var(--alias-colors-border-subtle, #f3f4f6);
46
46
  }
47
47
  }
48
48
 
@@ -57,28 +57,33 @@
57
57
  .ald-table-th,
58
58
  .ald-table-td {
59
59
  position: relative;
60
- border-bottom: 1px solid #e8e8e8;
60
+ border-bottom: 1px solid var(--alias-colors-border-subtle, #f3f4f6);
61
61
  flex: 0 0 auto;
62
62
  }
63
63
 
64
64
  .ald-table-th {
65
- border-bottom: 1px solid #e8e8e8;
65
+ border-bottom: 1px solid var(--alias-colors-border-subtle, #f3f4f6);
66
66
  background-color: #fff;
67
67
  }
68
68
 
69
69
  .ald-table-th-default {
70
70
  font-weight: 500;
71
- padding: 6px 12px;
71
+ padding: 0 var(--alias-spacing-200, 16px);
72
+ font-size: 12px;
72
73
  overflow: hidden;
74
+ height: 40px;
75
+ display: flex;
76
+ align-items: center;
73
77
  }
74
78
 
75
79
  .ald-table-td-default {
76
- padding: 0 12px;
80
+ padding: 0 var(--alias-spacing-200, 16px);
77
81
  display: flex;
78
82
  align-items: center;
79
83
  height: 100%;
80
- font-size: 13px;
81
- min-height: 48px;
84
+ font-size: 14px;
85
+ min-height: 47px;
86
+ font-weight: 400;
82
87
  overflow: hidden;
83
88
  }
84
89
 
@@ -101,7 +106,10 @@
101
106
 
102
107
  .ald-table-tr:hover {
103
108
  .ald-table-td {
104
- background-color: #f4f4f4;
109
+ background-color: var(
110
+ --alias-colors-bg-interaction-hover,
111
+ rgba(0, 0, 0, 0.05)
112
+ );
105
113
  }
106
114
  }
107
115
  }
@@ -1,12 +1,12 @@
1
1
  import React from 'react';
2
2
  import { TabsProps } from 'antd';
3
- export type TabsSize = 'default' | 'large';
3
+ export type TabsSize = 'default' | 'small';
4
4
  export interface ITabsProps extends Omit<TabsProps, 'size'> {
5
5
  /**
6
6
  * @description 大小
7
7
  * @default default
8
8
  */
9
- size?: 'large' | 'default';
9
+ size?: TabsSize;
10
10
  /**
11
11
  * @description 当前激活 tab 面板的 key
12
12
  * @default -