@aloudata/aloudata-design 0.3.3 → 0.3.4

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 (131) hide show
  1. package/es/Breadcrumb/index.d.ts +1 -0
  2. package/es/Checkbox/index.d.ts +1 -0
  3. package/es/ConfigProvider/defaultRenderEmpty.d.ts +4 -0
  4. package/es/ConfigProvider/defaultRenderEmpty.js +37 -0
  5. package/es/ConfigProvider/sizeContext.d.ts +9 -0
  6. package/es/ConfigProvider/sizeContext.js +12 -0
  7. package/es/Empty/image/Authority.d.ts +1 -0
  8. package/es/Empty/image/Dataspace.d.ts +1 -0
  9. package/es/Empty/image/Search.d.ts +1 -0
  10. package/es/Empty/image/Simple.d.ts +1 -0
  11. package/es/Empty/image/Worksheet.d.ts +1 -0
  12. package/es/Empty/image/empty.d.ts +1 -0
  13. package/es/Input/components/Group/index.d.ts +1 -0
  14. package/es/Input/components/Input/index.d.ts +1 -1
  15. package/es/Input/components/Input/index.js +0 -1
  16. package/es/Input/components/TextArea/index.d.ts +8 -1
  17. package/es/Input/components/TextArea/index.js +8 -1
  18. package/es/Input/style/index.less +78 -0
  19. package/es/InputNumber/index.d.ts +1 -0
  20. package/es/Menu/Divider.d.ts +1 -0
  21. package/es/Modal/style/index.less +3 -0
  22. package/es/Navigator/components/Header/index.d.ts +1 -0
  23. package/es/Navigator/components/Menu/index.d.ts +1 -0
  24. package/es/Popover/index.d.ts +1 -0
  25. package/es/Radio/components/Group/index.d.ts +6 -0
  26. package/es/Radio/components/Group/index.js +72 -0
  27. package/es/Radio/components/Radio/index.d.ts +3 -0
  28. package/es/Radio/components/Radio/index.js +95 -0
  29. package/es/Radio/index.d.ts +9 -2
  30. package/es/Radio/index.js +5 -3
  31. package/es/Radio/interface/radio.d.ts +24 -0
  32. package/es/Radio/interface/radio.js +1 -0
  33. package/es/Radio/interface/radioGroup.d.ts +42 -0
  34. package/es/Radio/interface/radioGroup.js +1 -0
  35. package/es/Radio/style/index.less +348 -0
  36. package/es/Select/index.js +1 -1
  37. package/es/Select/style/index.less +1 -0
  38. package/es/Steps/components/ProcessIcon/index.d.ts +1 -0
  39. package/es/Table/Table.d.ts +2 -1
  40. package/es/Table/Table.js +223 -330
  41. package/es/Table/components/Empty/index.d.ts +3 -0
  42. package/es/Table/components/Empty/index.js +17 -0
  43. package/es/Table/components/Loading/index.d.ts +3 -0
  44. package/es/Table/components/Loading/index.js +19 -0
  45. package/es/Table/components/TableBodyRowList/index.d.ts +13 -0
  46. package/es/Table/components/TableBodyRowList/index.js +89 -0
  47. package/es/Table/components/TableHead/index.d.ts +23 -0
  48. package/es/Table/components/TableHead/index.js +262 -0
  49. package/es/Table/constant.d.ts +1 -0
  50. package/es/Table/constant.js +1 -0
  51. package/es/Table/hooks/useFrame.d.ts +7 -0
  52. package/es/Table/hooks/useFrame.js +90 -0
  53. package/es/Table/hooks/useTableColumn.d.ts +28 -0
  54. package/es/Table/hooks/useTableColumn.js +53 -0
  55. package/es/Table/interface.d.ts +3 -2
  56. package/es/Table/style/index.less +33 -30
  57. package/es/Table/utils.d.ts +15 -0
  58. package/es/Table/utils.js +131 -0
  59. package/es/_utils/hooks/useId.d.ts +4 -0
  60. package/es/_utils/hooks/useId.js +23 -0
  61. package/es/index.d.ts +1 -1
  62. package/es/locale-provider/index.d.ts +5 -1
  63. package/es/style/index.d.ts +0 -1
  64. package/es/style/index.js +0 -1
  65. package/es/style/index.less +2 -2
  66. package/lib/Breadcrumb/index.d.ts +1 -0
  67. package/lib/Checkbox/index.d.ts +1 -0
  68. package/lib/ConfigProvider/defaultRenderEmpty.d.ts +4 -0
  69. package/lib/ConfigProvider/defaultRenderEmpty.js +55 -0
  70. package/lib/ConfigProvider/sizeContext.d.ts +9 -0
  71. package/lib/ConfigProvider/sizeContext.js +30 -0
  72. package/lib/Empty/image/Authority.d.ts +1 -0
  73. package/lib/Empty/image/Dataspace.d.ts +1 -0
  74. package/lib/Empty/image/Search.d.ts +1 -0
  75. package/lib/Empty/image/Simple.d.ts +1 -0
  76. package/lib/Empty/image/Worksheet.d.ts +1 -0
  77. package/lib/Empty/image/empty.d.ts +1 -0
  78. package/lib/Input/components/Group/index.d.ts +1 -0
  79. package/lib/Input/components/Input/index.d.ts +1 -1
  80. package/lib/Input/components/Input/index.js +0 -1
  81. package/lib/Input/components/TextArea/index.d.ts +8 -1
  82. package/lib/Input/components/TextArea/index.js +10 -1
  83. package/lib/Input/style/index.less +78 -0
  84. package/lib/InputNumber/index.d.ts +1 -0
  85. package/lib/Menu/Divider.d.ts +1 -0
  86. package/lib/Modal/style/index.less +3 -0
  87. package/lib/Navigator/components/Header/index.d.ts +1 -0
  88. package/lib/Navigator/components/Menu/index.d.ts +1 -0
  89. package/lib/Popover/index.d.ts +1 -0
  90. package/lib/Radio/components/Group/index.d.ts +6 -0
  91. package/lib/Radio/components/Group/index.js +93 -0
  92. package/lib/Radio/components/Radio/index.d.ts +3 -0
  93. package/lib/Radio/components/Radio/index.js +115 -0
  94. package/lib/Radio/index.d.ts +9 -2
  95. package/lib/Radio/index.js +5 -3
  96. package/lib/Radio/interface/radio.d.ts +24 -0
  97. package/lib/Radio/interface/radio.js +5 -0
  98. package/lib/Radio/interface/radioGroup.d.ts +42 -0
  99. package/lib/Radio/interface/radioGroup.js +5 -0
  100. package/lib/Radio/style/index.less +348 -0
  101. package/lib/Select/index.js +1 -1
  102. package/lib/Select/style/index.less +1 -0
  103. package/lib/Steps/components/ProcessIcon/index.d.ts +1 -0
  104. package/lib/Table/Table.d.ts +2 -1
  105. package/lib/Table/Table.js +228 -332
  106. package/lib/Table/components/Empty/index.d.ts +3 -0
  107. package/lib/Table/components/Empty/index.js +30 -0
  108. package/lib/Table/components/Loading/index.d.ts +3 -0
  109. package/lib/Table/components/Loading/index.js +33 -0
  110. package/lib/Table/components/TableBodyRowList/index.d.ts +13 -0
  111. package/lib/Table/components/TableBodyRowList/index.js +108 -0
  112. package/lib/Table/components/TableHead/index.d.ts +23 -0
  113. package/lib/Table/components/TableHead/index.js +286 -0
  114. package/lib/Table/constant.d.ts +1 -0
  115. package/lib/Table/constant.js +1 -0
  116. package/lib/Table/hooks/useFrame.d.ts +7 -0
  117. package/lib/Table/hooks/useFrame.js +98 -0
  118. package/lib/Table/hooks/useTableColumn.d.ts +28 -0
  119. package/lib/Table/hooks/useTableColumn.js +66 -0
  120. package/lib/Table/interface.d.ts +3 -2
  121. package/lib/Table/style/index.less +33 -30
  122. package/lib/Table/utils.d.ts +15 -0
  123. package/lib/Table/utils.js +147 -0
  124. package/lib/_utils/hooks/useId.d.ts +4 -0
  125. package/lib/_utils/hooks/useId.js +36 -0
  126. package/lib/index.d.ts +1 -1
  127. package/lib/locale-provider/index.d.ts +5 -1
  128. package/lib/style/index.d.ts +0 -1
  129. package/lib/style/index.js +0 -2
  130. package/lib/style/index.less +2 -2
  131. package/package.json +1 -1
@@ -1 +1,349 @@
1
1
  @import '../../style/index.less';
2
+
3
+ @radio-icon-button-padding-large: 10px;
4
+ @radio-icon-button-padding-middle: 9px;
5
+ @radio-icon-button-padding-small: 8px;
6
+ @radio-group-height-large: 36px;
7
+ @radio-group-height-middle: 32px;
8
+ @radio-group-height-small: 28px;
9
+ @radio-button-padding: 12px;
10
+
11
+ // Radio组件基础样式
12
+ .ald-radio-wrapper {
13
+ display: inline-flex;
14
+ gap: 8px;
15
+ align-items: center;
16
+ justify-content: start;
17
+ height: 20px;
18
+ padding: 0;
19
+ cursor: pointer;
20
+ }
21
+
22
+ .ald-radio {
23
+ position: relative;
24
+ display: flex;
25
+ align-items: center;
26
+ justify-content: center;
27
+ width: 20px;
28
+ height: 20px;
29
+ }
30
+
31
+ .ald-radio-input {
32
+ position: absolute;
33
+ z-index: 1;
34
+ width: 1px;
35
+ height: 1px;
36
+ cursor: pointer;
37
+ opacity: 0;
38
+ inset: 0;
39
+ }
40
+
41
+ .ald-radio-inner {
42
+ position: relative;
43
+ display: inline-block;
44
+ width: 17px;
45
+ height: 17px;
46
+ border: 1px solid @NL90;
47
+ border-radius: 50%;
48
+ }
49
+
50
+ .ald-radio-desc {
51
+ z-index: 2;
52
+ display: flex;
53
+ align-items: center;
54
+ justify-content: center;
55
+ color: @NL0;
56
+ font-weight: 400;
57
+ }
58
+ // 绘制选中时的圆圈样式
59
+ .ald-radio-checked > .ald-radio-inner {
60
+ background-color: @B60;
61
+ border: 0;
62
+ transform: background 0.5s ease;
63
+
64
+ &::after {
65
+ position: absolute;
66
+ top: 50%;
67
+ left: 50%;
68
+ width: 6px;
69
+ height: 6px;
70
+ background-color: @ND0;
71
+ border-radius: 50%;
72
+ transform: translate(-50%, -50%);
73
+ content: '';
74
+ }
75
+ }
76
+ // 禁用状态下的样式
77
+ .ald-radio-disabled > .ald-radio-inner {
78
+ background-color: @NL90;
79
+ border: 0;
80
+ }
81
+
82
+ .ald-radio-disabled.ald-radio-checked > .ald-radio-inner::after {
83
+ position: absolute;
84
+ top: 50%;
85
+ left: 50%;
86
+ width: 6px;
87
+ height: 6px;
88
+ background: @NL90;
89
+ border-radius: 50%;
90
+ transform: translate(-50%, -50%);
91
+ content: '';
92
+ }
93
+ // 禁用的样式
94
+ .ald-radio-label.ald-radio-wrapper-disabled {
95
+ cursor: default;
96
+
97
+ .ald-radio-desc {
98
+ color: @NL60;
99
+ }
100
+ }
101
+ // RadioGroup基础样式
102
+ .ald-radio-group {
103
+ position: relative;
104
+
105
+ .ald-radio-label .ald-radio-desc {
106
+ color: @NL30;
107
+ font-weight: 500;
108
+ font-size: @font-size-middle;
109
+ font-style: normal;
110
+ }
111
+
112
+ &.ald-radio-group-radio {
113
+ .ald-radio-desc {
114
+ color: @NL0;
115
+ font-weight: 400;
116
+ }
117
+ }
118
+
119
+ .ald-radio-wrapper:not(:first-child) {
120
+ margin-left: 16px;
121
+ }
122
+ }
123
+
124
+ // filled填充样式下的滑块样式
125
+ .ald-radio-filled-slider {
126
+ position: absolute;
127
+ top: 0;
128
+ left: 0;
129
+ z-index: 1;
130
+ width: 0;
131
+ height: 100%;
132
+ background: @BG100;
133
+ border: 1px solid @NL90;
134
+ border-radius: @border-radius-middle;
135
+ transition: width, left, height 0.3s, 0.3s, 0.3s ease;
136
+ }
137
+
138
+ // button状态下的样式
139
+ .ald-radio-group-button,
140
+ .ald-radio-group-icon-button {
141
+ display: flex;
142
+ align-items: flex-start;
143
+ box-sizing: border-box;
144
+ width: min-content;
145
+ width: auto;
146
+ padding: 0;
147
+ overflow: hidden;
148
+
149
+ .ald-radio-label {
150
+ color: @NL30;
151
+ font-size: @font-size-middle;
152
+ }
153
+ // 按钮样式禁用的文字颜色
154
+ .ald-radio-wrapper-disabled {
155
+ .ald-radio-desc {
156
+ color: @NL80;
157
+ }
158
+ }
159
+ // border的样式
160
+ .ald-radio-button-wrapper-border {
161
+ padding: 0 @radio-button-padding - 1;
162
+ }
163
+
164
+ .ald-radio-button-wrapper-border,
165
+ .ald-radio-icon-button-wrapper-border {
166
+ position: relative;
167
+ display: flex;
168
+ align-items: center;
169
+ justify-content: center;
170
+ height: 100%;
171
+ background: @BG100;
172
+ border: 1px solid @NL90;
173
+ border-right: 1px solid transparent;
174
+ cursor: pointer;
175
+
176
+ &:first-child {
177
+ border-radius: 6px 0 0 6px;
178
+ }
179
+
180
+ &:last-child {
181
+ border-right: 1px solid @NL90;
182
+ border-radius: 0 6px 6px 0;
183
+ }
184
+
185
+ .ald-radio {
186
+ width: 0;
187
+
188
+ .ald-radio-input,
189
+ .ald-radio-inner {
190
+ width: 0;
191
+ border: 0;
192
+ }
193
+ }
194
+
195
+ .ald-radio-checked > .ald-radio-inner::after {
196
+ width: 0;
197
+ }
198
+ }
199
+
200
+ // button选中状态下的样式
201
+ .ald-radio-wrapper-checked.ald-radio-button-wrapper-border,
202
+ .ald-radio-wrapper-checked.ald-radio-icon-button-wrapper-border {
203
+ background: @B98;
204
+ transition: background 0.5s ease;
205
+
206
+ .ald-radio-desc {
207
+ position: relative;
208
+ color: @NL0;
209
+ transition: text-shadow 0.5s ease;
210
+ }
211
+ }
212
+
213
+ // filled样式的button
214
+ .ald-radio-button-wrapper-filled {
215
+ padding: 0 @radio-button-padding;
216
+ }
217
+
218
+ .ald-radio-button-wrapper-filled,
219
+ .ald-radio-icon-button-wrapper-filled {
220
+ position: relative;
221
+ display: flex;
222
+ align-items: center;
223
+ justify-content: center;
224
+ height: 100%;
225
+ background-color: @BG90;
226
+ cursor: pointer;
227
+
228
+ &:first-of-type {
229
+ border-radius: @border-radius-middle 0 0 @border-radius-middle;
230
+ }
231
+
232
+ &:last-of-type {
233
+ border-radius: 0 @border-radius-middle @border-radius-middle 0;
234
+ }
235
+
236
+ .ald-radio {
237
+ width: 0;
238
+
239
+ .ald-radio-input,
240
+ .ald-radio-inner {
241
+ width: 0;
242
+ border: 0;
243
+ }
244
+ }
245
+
246
+ .ald-radio-checked > .ald-radio-inner::after {
247
+ width: 0;
248
+ }
249
+ }
250
+
251
+ .ald-radio-wrapper-checked.ald-radio-button-wrapper-filled,
252
+ .ald-radio-wrapper-checked.ald-radio-icon-button-wrapper-filled {
253
+ position: relative;
254
+
255
+ .ald-radio-desc {
256
+ position: relative;
257
+ z-index: 2;
258
+ color: @NL0;
259
+ }
260
+ }
261
+ // 各种大小
262
+ &.ald-radio-group-middle {
263
+ height: @radio-group-height-middle;
264
+
265
+ .ald-radio-icon-button-wrapper-filled {
266
+ padding: 0 @radio-icon-button-padding-middle;
267
+ }
268
+
269
+ .ald-radio-icon-button-wrapper-border {
270
+ padding: 0 @radio-icon-button-padding-middle - 1;
271
+ }
272
+
273
+ .ald-radio-label {
274
+ .ald-radio-desc {
275
+ font-size: @font-size-middle;
276
+ }
277
+ }
278
+ }
279
+
280
+ &.ald-radio-group-small {
281
+ height: @radio-group-height-small;
282
+
283
+ .ald-radio-icon-button-wrapper-filled {
284
+ padding: 0 @radio-icon-button-padding-small;
285
+ }
286
+
287
+ .ald-radio-icon-button-wrapper-border {
288
+ padding: 0 @radio-icon-button-padding-small - 1;
289
+ }
290
+
291
+ .ald-radio-label {
292
+ .ald-radio-desc {
293
+ font-size: @font-size-small;
294
+ }
295
+ }
296
+
297
+ .ald-radio-button-wrapper-border,
298
+ .ald-radio-icon-button-wrapper-border,
299
+ .ald-radio-button-wrapper-filled,
300
+ .ald-radio-icon-button-wrapper-filled {
301
+ &:first-of-type {
302
+ border-radius: @border-radius-small 0 0 @border-radius-small;
303
+ }
304
+
305
+ &:last-of-type {
306
+ border-radius: 0 @border-radius-small 0 @border-radius-small 0;
307
+ }
308
+ }
309
+
310
+ .ald-radio-filled-slider {
311
+ border-radius: @border-radius-small;
312
+ }
313
+ }
314
+
315
+ &.ald-radio-group.ald-radio-group-large {
316
+ height: @radio-group-height-large;
317
+
318
+ .ald-radio-icon-button-wrapper-filled {
319
+ padding: 0 @radio-icon-button-padding-large;
320
+ }
321
+
322
+ .ald-radio-icon-button-wrapper-border {
323
+ padding: 0 @radio-icon-button-padding-large - 1;
324
+ }
325
+
326
+ .ald-radio-label {
327
+ .ald-radio-desc {
328
+ font-size: @font-size-large;
329
+ }
330
+ }
331
+
332
+ .ald-radio-button-wrapper-border,
333
+ .ald-radio-icon-button-wrapper-border,
334
+ .ald-radio-button-wrapper-filled,
335
+ .ald-radio-icon-button-wrapper-filled {
336
+ &:first-of-type {
337
+ border-radius: @border-radius-large 0 0 @border-radius-large;
338
+ }
339
+
340
+ &:last-of-type {
341
+ border-radius: 0 @border-radius-large @border-radius-large 0;
342
+ }
343
+ }
344
+
345
+ .ald-radio-filled-slider {
346
+ border-radius: @border-radius-large;
347
+ }
348
+ }
349
+ }
@@ -23,7 +23,7 @@ import DisabledContext from 'antd/lib/config-provider/DisabledContext';
23
23
  import { FormItemInputContext } from 'antd/lib/form/context';
24
24
  import { getTransitionDirection, getTransitionName } from 'antd/lib/_util/motion';
25
25
  import { getMergedStatus, getStatusClassNames } from 'antd/lib/_util/statusUtils';
26
- import defaultRenderEmpty from 'antd/lib/config-provider/defaultRenderEmpty';
26
+ import defaultRenderEmpty from '../ConfigProvider/defaultRenderEmpty';
27
27
  import getIcons from './utils/iconUtil';
28
28
  var SECRET_COMBOBOX_MODE_DO_NOT_USE = 'SECRET_COMBOBOX_MODE_DO_NOT_USE';
29
29
 
@@ -1,6 +1,7 @@
1
1
  /* stylelint-disable no-descending-specificity */
2
2
  @import './select.less';
3
3
  @import './variables.less';
4
+ @import '../../Empty/style/index.less';
4
5
 
5
6
  .ald-select {
6
7
  .ant-select-selector:not(.ant-select-customize-input) {
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  interface IProcessIconProps {
2
3
  type: 'process' | 'wait';
3
4
  }
@@ -1,5 +1,6 @@
1
1
  import React, { ReactElement } from 'react';
2
2
  import { ITableProps } from './interface';
3
- declare function Table<RecordType extends object = any>(props: ITableProps<RecordType>, ref?: React.Ref<unknown>): ReactElement;
3
+ import './style/index';
4
+ declare function Table<RecordType extends object = {}>(props: ITableProps<RecordType>, ref?: React.Ref<unknown>): ReactElement;
4
5
  declare const _default: typeof Table;
5
6
  export default _default;