@jiaozhiye/qm-design-react 1.8.2 → 1.8.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 (42) hide show
  1. package/lib/_utils/util.d.ts +1 -0
  2. package/lib/drawer/style/index.less +101 -101
  3. package/lib/hooks/useMemo.d.ts +1 -0
  4. package/lib/index.esm.js +1 -1
  5. package/lib/index.full.js +1 -1
  6. package/lib/index.js +1 -1
  7. package/lib/lazy-load/style/index.less +15 -15
  8. package/lib/modal/style/index.less +116 -116
  9. package/lib/style/index.less +40 -40
  10. package/lib/table/src/body/context.d.ts +4 -0
  11. package/lib/table/src/cell/index.d.ts +13 -0
  12. package/lib/table/src/cell/useCellText.d.ts +6 -0
  13. package/lib/table/src/{body → cell}/useValueFormat.d.ts +1 -2
  14. package/lib/table/src/context/index.d.ts +2 -2
  15. package/lib/table/src/edit/index.d.ts +1 -3
  16. package/lib/table/src/hooks/useImperativeMethod.d.ts +1 -2
  17. package/lib/table/src/hooks/useTableRef.d.ts +2 -0
  18. package/lib/table/src/hooks/useTableState.d.ts +3 -0
  19. package/lib/table/src/table/props.d.ts +1 -0
  20. package/lib/table/src/table/types.d.ts +1 -1
  21. package/lib/table/style/alert.less +32 -34
  22. package/lib/table/style/clipboard.less +27 -29
  23. package/lib/table/style/column-filter.less +0 -2
  24. package/lib/table/style/empty.less +17 -19
  25. package/lib/table/style/export.less +24 -26
  26. package/lib/table/style/fast-search.less +108 -110
  27. package/lib/table/style/footer.less +31 -33
  28. package/lib/table/style/full-screen.less +19 -21
  29. package/lib/table/style/group-summary.less +91 -93
  30. package/lib/table/style/header.less +205 -207
  31. package/lib/table/style/import.less +23 -25
  32. package/lib/table/style/pager.less +27 -29
  33. package/lib/table/style/print.less +19 -21
  34. package/lib/table/style/reload.less +19 -21
  35. package/lib/table/style/select-collection.less +19 -21
  36. package/lib/table/style/size.less +86 -88
  37. package/lib/table/style/super-search.less +100 -102
  38. package/lib/table/style/table.less +0 -2
  39. package/lib/table/style/tollbox.less +37 -39
  40. package/lib/table/style/toper.less +29 -31
  41. package/lib/table/style/variable.less +50 -48
  42. package/package.json +139 -139
@@ -1,207 +1,205 @@
1
- /*
2
- * @Author: 焦质晔
3
- * @Date: 2020-02-28 22:11:53
4
- * @Last Modified by: 焦质晔
5
- * @Last Modified time: 2022-11-26 21:07:50
6
- */
7
- @prefix-table: ~'@{qm-prefix}-table';
8
-
9
- .TheadAlignCenter {
10
- .cell--text {
11
- justify-content: center !important;
12
- }
13
- }
14
-
15
- .TheadAlignRight {
16
- .cell--text {
17
- justify-content: flex-end !important;
18
- }
19
- }
20
-
21
- .@{prefix-table}--header-wrapper {
22
- background-color: @v-table-header-background-color;
23
- .@{prefix-table}--header {
24
- tr > th[colspan]:not([colspan='1']) {
25
- .TheadAlignCenter();
26
- }
27
- }
28
- .gutter {
29
- background-color: @v-table-header-background-color;
30
- }
31
- }
32
-
33
- .header--column {
34
- .cell--wrapper {
35
- display: flex;
36
- align-items: center;
37
- .cell--text {
38
- display: flex;
39
- align-items: center;
40
- justify-content: flex-start;
41
- flex: 1;
42
- /* 重要 */
43
- width: 0;
44
- .cell {
45
- padding-right: 2px;
46
- line-height: 24px;
47
- }
48
- .tip {
49
- padding: 2px;
50
- cursor: default;
51
- }
52
- }
53
- }
54
- &.column-has-filter {
55
- .cell--wrapper {
56
- margin-right: 16px;
57
- }
58
- }
59
- &.col--center {
60
- .TheadAlignCenter();
61
- }
62
- &.col--right {
63
- .TheadAlignRight();
64
- }
65
- &:not(.column-has-sorter):not(.column-has-filter) {
66
- .cell--text {
67
- .cell {
68
- padding-right: @v-module-distance;
69
- }
70
- .tip {
71
- margin-left: -8px;
72
- }
73
- }
74
- }
75
- &.column--required {
76
- .cell {
77
- &::before {
78
- content: '*';
79
- color: @v-danger-color;
80
- margin-right: 2px;
81
- }
82
- }
83
- }
84
-
85
- /* 全选 */
86
- .cell--selection {
87
- display: flex;
88
- align-items: center;
89
- .icon {
90
- padding: 2px;
91
- margin-left: 2px;
92
- margin-top: 1px;
93
- font-size: @v-font-size;
94
- color: @v-icon-color;
95
- cursor: pointer;
96
- }
97
- .info {
98
- flex-shrink: 0;
99
- margin-left: 4px;
100
- font-size: @v-font-size - 1px;
101
- color: @v-font-secondary-color;
102
- }
103
- }
104
-
105
- /* 排序 */
106
- .cell--sorter {
107
- font-size: 0.8em;
108
- flex-shrink: 0;
109
- display: flex;
110
- flex-direction: column;
111
- align-items: center;
112
- cursor: pointer;
113
- // transform: scale(0.8, 0.8);
114
- &__asc,
115
- &__desc {
116
- color: @v-icon-color;
117
- &.actived {
118
- color: @v-primary-color;
119
- }
120
- }
121
- &__asc {
122
- transform: translateY(1.5px);
123
- }
124
- &__desc {
125
- transform: translateY(-1.5px);
126
- }
127
- }
128
-
129
- /* 筛选 */
130
- .cell--filter {
131
- width: 16px;
132
- display: flex;
133
- justify-content: center;
134
- align-items: center;
135
- position: absolute;
136
- top: 0;
137
- right: 0;
138
- bottom: 0;
139
- color: @v-icon-color;
140
- transition: all 0.3s ease;
141
- cursor: pointer;
142
- .icon {
143
- transform: scale(0.8, 0.9);
144
- }
145
- &:hover,
146
- &.selected {
147
- color: @v-font-secondary-color;
148
- background-color: @v-table-column-filter-hover-color;
149
- }
150
- &.actived {
151
- color: @v-primary-color;
152
- }
153
- }
154
-
155
- .resizable {
156
- position: absolute;
157
- top: 0;
158
- bottom: 0;
159
- right: -5px;
160
- width: 10px;
161
- z-index: 1;
162
- cursor: col-resize;
163
- &.is--line {
164
- &:before {
165
- content: '';
166
- position: absolute;
167
- left: 50%;
168
- top: 20%;
169
- width: 1px;
170
- height: 60%;
171
- background-color: @v-table-resizable-color;
172
- }
173
- }
174
- }
175
- }
176
-
177
- .head-filter__popper {
178
- padding: @v-module-distance !important;
179
- max-height: 300px;
180
- overflow-y: auto;
181
- }
182
-
183
- .head-filter--wrap {
184
- ul {
185
- margin: 0;
186
- li {
187
- display: flex;
188
- align-items: center;
189
- margin-bottom: 5px;
190
- &:last-of-type {
191
- margin-bottom: 0;
192
- }
193
- & > span {
194
- margin-right: 5px;
195
- }
196
- }
197
- }
198
- }
199
-
200
- .all-selection__popper {
201
- .ant-dropdown-menu {
202
- &-item {
203
- padding-left: 12px;
204
- padding-right: 12px;
205
- }
206
- }
207
- }
1
+ /*
2
+ * @Author: 焦质晔
3
+ * @Date: 2020-02-28 22:11:53
4
+ * @Last Modified by: 焦质晔
5
+ * @Last Modified time: 2022-11-26 21:07:50
6
+ */
7
+ .TheadAlignCenter {
8
+ .cell--text {
9
+ justify-content: center !important;
10
+ }
11
+ }
12
+
13
+ .TheadAlignRight {
14
+ .cell--text {
15
+ justify-content: flex-end !important;
16
+ }
17
+ }
18
+
19
+ .@{prefix-table}--header-wrapper {
20
+ background-color: @v-table-header-background-color;
21
+ .@{prefix-table}--header {
22
+ tr > th[colspan]:not([colspan='1']) {
23
+ .TheadAlignCenter();
24
+ }
25
+ }
26
+ .gutter {
27
+ background-color: @v-table-header-background-color;
28
+ }
29
+ }
30
+
31
+ .header--column {
32
+ .cell--wrapper {
33
+ display: flex;
34
+ align-items: center;
35
+ .cell--text {
36
+ display: flex;
37
+ align-items: center;
38
+ justify-content: flex-start;
39
+ flex: 1;
40
+ /* 重要 */
41
+ width: 0;
42
+ .cell {
43
+ padding-right: 2px;
44
+ line-height: 24px;
45
+ }
46
+ .tip {
47
+ padding: 2px;
48
+ cursor: default;
49
+ }
50
+ }
51
+ }
52
+ &.column-has-filter {
53
+ .cell--wrapper {
54
+ margin-right: 16px;
55
+ }
56
+ }
57
+ &.col--center {
58
+ .TheadAlignCenter();
59
+ }
60
+ &.col--right {
61
+ .TheadAlignRight();
62
+ }
63
+ &:not(.column-has-sorter):not(.column-has-filter) {
64
+ .cell--text {
65
+ .cell {
66
+ padding-right: @v-module-distance;
67
+ }
68
+ .tip {
69
+ margin-left: -8px;
70
+ }
71
+ }
72
+ }
73
+ &.column--required {
74
+ .cell {
75
+ &::before {
76
+ content: '*';
77
+ color: @v-danger-color;
78
+ margin-right: 2px;
79
+ }
80
+ }
81
+ }
82
+
83
+ /* 全选 */
84
+ .cell--selection {
85
+ display: flex;
86
+ align-items: center;
87
+ .icon {
88
+ padding: 2px;
89
+ margin-left: 2px;
90
+ margin-top: 1px;
91
+ font-size: @v-font-size;
92
+ color: @v-icon-color;
93
+ cursor: pointer;
94
+ }
95
+ .info {
96
+ flex-shrink: 0;
97
+ margin-left: 4px;
98
+ font-size: @v-font-size - 1px;
99
+ color: @v-font-secondary-color;
100
+ }
101
+ }
102
+
103
+ /* 排序 */
104
+ .cell--sorter {
105
+ font-size: 0.8em;
106
+ flex-shrink: 0;
107
+ display: flex;
108
+ flex-direction: column;
109
+ align-items: center;
110
+ cursor: pointer;
111
+ // transform: scale(0.8, 0.8);
112
+ &__asc,
113
+ &__desc {
114
+ color: @v-icon-color;
115
+ &.actived {
116
+ color: @v-primary-color;
117
+ }
118
+ }
119
+ &__asc {
120
+ transform: translateY(1.5px);
121
+ }
122
+ &__desc {
123
+ transform: translateY(-1.5px);
124
+ }
125
+ }
126
+
127
+ /* 筛选 */
128
+ .cell--filter {
129
+ width: 16px;
130
+ display: flex;
131
+ justify-content: center;
132
+ align-items: center;
133
+ position: absolute;
134
+ top: 0;
135
+ right: 0;
136
+ bottom: 0;
137
+ color: @v-icon-color;
138
+ transition: all 0.3s ease;
139
+ cursor: pointer;
140
+ .icon {
141
+ transform: scale(0.8, 0.9);
142
+ }
143
+ &:hover,
144
+ &.selected {
145
+ color: @v-font-secondary-color;
146
+ background-color: @v-table-column-filter-hover-color;
147
+ }
148
+ &.actived {
149
+ color: @v-primary-color;
150
+ }
151
+ }
152
+
153
+ .resizable {
154
+ position: absolute;
155
+ top: 0;
156
+ bottom: 0;
157
+ right: -5px;
158
+ width: 10px;
159
+ z-index: 1;
160
+ cursor: col-resize;
161
+ &.is--line {
162
+ &:before {
163
+ content: '';
164
+ position: absolute;
165
+ left: 50%;
166
+ top: 20%;
167
+ width: 1px;
168
+ height: 60%;
169
+ background-color: @v-table-resizable-color;
170
+ }
171
+ }
172
+ }
173
+ }
174
+
175
+ .head-filter__popper {
176
+ padding: @v-module-distance !important;
177
+ max-height: 300px;
178
+ overflow-y: auto;
179
+ }
180
+
181
+ .head-filter--wrap {
182
+ ul {
183
+ margin: 0;
184
+ li {
185
+ display: flex;
186
+ align-items: center;
187
+ margin-bottom: 5px;
188
+ &:last-of-type {
189
+ margin-bottom: 0;
190
+ }
191
+ & > span {
192
+ margin-right: 5px;
193
+ }
194
+ }
195
+ }
196
+ }
197
+
198
+ .all-selection__popper {
199
+ .ant-dropdown-menu {
200
+ &-item {
201
+ padding-left: 12px;
202
+ padding-right: 12px;
203
+ }
204
+ }
205
+ }
@@ -1,25 +1,23 @@
1
- /*
2
- * @Author: 焦质晔
3
- * @Date: 2020-03-26 11:26:46
4
- * @Last Modified by: 焦质晔
5
- * @Last Modified time: 2022-04-28 12:03:38
6
- */
7
- @prefix-table: ~'@{qm-prefix}-table';
8
-
9
- .@{prefix-table}-import {
10
- display: inline-block;
11
- padding: 5px 3px;
12
- line-height: 1;
13
- cursor: pointer;
14
- transition: all 0.3s ease;
15
- .icon {
16
- font-size: 1.05em;
17
- }
18
- &:hover {
19
- color: @v-primary-color;
20
- }
21
- }
22
-
23
- .@{prefix-table}--file-form {
24
- display: none;
25
- }
1
+ /*
2
+ * @Author: 焦质晔
3
+ * @Date: 2020-03-26 11:26:46
4
+ * @Last Modified by: 焦质晔
5
+ * @Last Modified time: 2022-04-28 12:03:38
6
+ */
7
+ .@{prefix-table}-import {
8
+ display: inline-block;
9
+ padding: 5px 3px;
10
+ line-height: 1;
11
+ cursor: pointer;
12
+ transition: all 0.3s ease;
13
+ .icon {
14
+ font-size: 1.05em;
15
+ }
16
+ &:hover {
17
+ color: @v-primary-color;
18
+ }
19
+ }
20
+
21
+ .@{prefix-table}--file-form {
22
+ display: none;
23
+ }
@@ -1,29 +1,27 @@
1
- /*
2
- * @Author: 焦质晔
3
- * @Date: 2020-03-26 11:45:02
4
- * @Last Modified by: 焦质晔
5
- * @Last Modified time: 2021-09-04 10:17:37
6
- */
7
- @prefix-table: ~'@{qm-prefix}-table';
8
-
9
- .@{prefix-table}-pager {
10
- margin-top: @v-module-distance;
11
- display: flex;
12
- justify-content: space-between;
13
- .pager-alert {
14
- .@{prefix-table}__alert {
15
- height: 100%;
16
- }
17
- }
18
- .ant-pagination {
19
- line-height: 1;
20
- &-options-size-changer.ant-select {
21
- width: auto;
22
- &.ant-select-status-error {
23
- .ant-select-selector {
24
- border-color: @--border-color-base !important;
25
- }
26
- }
27
- }
28
- }
29
- }
1
+ /*
2
+ * @Author: 焦质晔
3
+ * @Date: 2020-03-26 11:45:02
4
+ * @Last Modified by: 焦质晔
5
+ * @Last Modified time: 2021-09-04 10:17:37
6
+ */
7
+ .@{prefix-table}-pager {
8
+ margin-top: @v-module-distance;
9
+ display: flex;
10
+ justify-content: space-between;
11
+ .pager-alert {
12
+ .@{prefix-table}__alert {
13
+ height: 100%;
14
+ }
15
+ }
16
+ .ant-pagination {
17
+ line-height: 1;
18
+ &-options-size-changer.ant-select {
19
+ width: auto;
20
+ &.ant-select-status-error {
21
+ .ant-select-selector {
22
+ border-color: @--border-color-base !important;
23
+ }
24
+ }
25
+ }
26
+ }
27
+ }
@@ -1,21 +1,19 @@
1
- /*
2
- * @Author: 焦质晔
3
- * @Date: 2020-03-26 11:45:02
4
- * @Last Modified by: 焦质晔
5
- * @Last Modified time: 2022-01-09 10:06:27
6
- */
7
- @prefix-table: ~'@{qm-prefix}-table';
8
-
9
- .@{prefix-table}-print {
10
- display: inline-block;
11
- padding: 5px 3px;
12
- line-height: 1;
13
- cursor: pointer;
14
- transition: all 0.3s ease;
15
- .icon {
16
- font-size: 1.05em;
17
- }
18
- &:hover {
19
- color: @v-primary-color;
20
- }
21
- }
1
+ /*
2
+ * @Author: 焦质晔
3
+ * @Date: 2020-03-26 11:45:02
4
+ * @Last Modified by: 焦质晔
5
+ * @Last Modified time: 2022-01-09 10:06:27
6
+ */
7
+ .@{prefix-table}-print {
8
+ display: inline-block;
9
+ padding: 5px 3px;
10
+ line-height: 1;
11
+ cursor: pointer;
12
+ transition: all 0.3s ease;
13
+ .icon {
14
+ font-size: 1.05em;
15
+ }
16
+ &:hover {
17
+ color: @v-primary-color;
18
+ }
19
+ }
@@ -1,21 +1,19 @@
1
- /*
2
- * @Author: 焦质晔
3
- * @Date: 2020-03-26 11:45:02
4
- * @Last Modified by: 焦质晔
5
- * @Last Modified time: 2021-12-31 14:12:41
6
- */
7
- @prefix-table: ~'@{qm-prefix}-table';
8
-
9
- .@{prefix-table}-reload {
10
- display: inline-block;
11
- padding: 5px 3px;
12
- line-height: 1;
13
- cursor: pointer;
14
- transition: all 0.3s ease;
15
- .icon {
16
- font-size: 1.05em;
17
- }
18
- &:hover {
19
- color: @v-primary-color;
20
- }
21
- }
1
+ /*
2
+ * @Author: 焦质晔
3
+ * @Date: 2020-03-26 11:45:02
4
+ * @Last Modified by: 焦质晔
5
+ * @Last Modified time: 2021-12-31 14:12:41
6
+ */
7
+ .@{prefix-table}-reload {
8
+ display: inline-block;
9
+ padding: 5px 3px;
10
+ line-height: 1;
11
+ cursor: pointer;
12
+ transition: all 0.3s ease;
13
+ .icon {
14
+ font-size: 1.05em;
15
+ }
16
+ &:hover {
17
+ color: @v-primary-color;
18
+ }
19
+ }
@@ -1,21 +1,19 @@
1
- /*
2
- * @Author: 焦质晔
3
- * @Date: 2020-03-26 11:45:02
4
- * @Last Modified by: 焦质晔
5
- * @Last Modified time: 2022-01-06 10:27:07
6
- */
7
- @prefix-table: ~'@{qm-prefix}-table';
8
-
9
- .@{prefix-table}-select-collection {
10
- display: inline-block;
11
- padding: 5px 3px;
12
- line-height: 1;
13
- cursor: pointer;
14
- transition: all 0.3s ease;
15
- .icon {
16
- font-size: 1.05em;
17
- }
18
- &:hover {
19
- color: @v-primary-color;
20
- }
21
- }
1
+ /*
2
+ * @Author: 焦质晔
3
+ * @Date: 2020-03-26 11:45:02
4
+ * @Last Modified by: 焦质晔
5
+ * @Last Modified time: 2022-01-06 10:27:07
6
+ */
7
+ .@{prefix-table}-select-collection {
8
+ display: inline-block;
9
+ padding: 5px 3px;
10
+ line-height: 1;
11
+ cursor: pointer;
12
+ transition: all 0.3s ease;
13
+ .icon {
14
+ font-size: 1.05em;
15
+ }
16
+ &:hover {
17
+ color: @v-primary-color;
18
+ }
19
+ }