@natec/mef-dev-ui-kit 22.0.303 → 22.0.317

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.
@@ -0,0 +1,370 @@
1
+ @use '../../styles/vars.scss' as *;
2
+ @use 'sass:color' as color;
3
+
4
+ // ═══════════════════════════════════════════════════════════════════════════
5
+ // MD Grid Table Style
6
+ // ═══════════════════════════════════════════════════════════════════════════
7
+ //
8
+ // USAGE:
9
+ // <md-grid class="md-grid-table" ...>
10
+ // <md-grid class="md-grid-table zebra-white" ...>
11
+ // <md-grid class="md-grid-table zebra-grey" ...>
12
+ //
13
+ // ═══════════════════════════════════════════════════════════════════════════
14
+
15
+ .md-grid-table {
16
+ // ═════════════════════════════════════════════════════════════════════════
17
+ // HOST STYLES
18
+ // ═════════════════════════════════════════════════════════════════════════
19
+
20
+ &.md-grid,
21
+ .md-grid {
22
+ font-family: $base-font-family;
23
+ font-size: 13px;
24
+ font-weight: 400;
25
+ line-height: 21px;
26
+ background: transparent;
27
+ border: none;
28
+ border-radius: 0;
29
+ box-shadow: none;
30
+ }
31
+
32
+ // ═════════════════════════════════════════════════════════════════════════
33
+ // HEADER
34
+ // ═════════════════════════════════════════════════════════════════════════
35
+
36
+ .md-grid-header {
37
+ background: $light-gray-2;
38
+ border: none;
39
+ box-shadow: none;
40
+ }
41
+
42
+ .md-grid-header-inner {
43
+ padding: 0;
44
+ width: 100%;
45
+ }
46
+
47
+ .md-grid-header-cell {
48
+ padding: 13px 8px 10px 8px;
49
+ background: transparent;
50
+ font-family: $font-header;
51
+ font-size: 14px;
52
+ font-weight: 300;
53
+ text-transform: uppercase;
54
+ letter-spacing: 0.5px;
55
+ color: $dark-gray-2;
56
+ vertical-align: middle;
57
+
58
+ &:not(:first-child) {
59
+ border-left: 2px solid $white;
60
+ }
61
+
62
+ &.sortable {
63
+ cursor: pointer;
64
+ user-select: none;
65
+
66
+ &:hover {
67
+ background: transparent;
68
+ }
69
+ }
70
+
71
+ &.sort-active {
72
+ color: $dark-gray-2;
73
+ }
74
+ }
75
+
76
+ .md-grid-header-cell-label {
77
+ line-height: 1.2;
78
+ }
79
+
80
+ // ═════════════════════════════════════════════════════════════════════════
81
+ // SORT ICONS
82
+ // ═════════════════════════════════════════════════════════════════════════
83
+
84
+ .md-grid-sort-icon {
85
+ color: $light-gray-1;
86
+
87
+ &.md-grid-sort-asc,
88
+ &.md-grid-sort-desc {
89
+ color: $dark-gray-2;
90
+ }
91
+ }
92
+
93
+ // ═════════════════════════════════════════════════════════════════════════
94
+ // BODY
95
+ // ═════════════════════════════════════════════════════════════════════════
96
+
97
+ .md-grid-body {
98
+ padding: 0;
99
+ background: transparent;
100
+ gap: 0 !important;
101
+
102
+ &::-webkit-scrollbar-corner {
103
+ background: transparent;
104
+ }
105
+ }
106
+
107
+ .md-grid-group-rows {
108
+ gap: 0 !important;
109
+ }
110
+
111
+ // ═════════════════════════════════════════════════════════════════════════
112
+ // CARD (ROW) - Table row style
113
+ // ═════════════════════════════════════════════════════════════════════════
114
+
115
+ .md-grid-card {
116
+ background: $white;
117
+ border: none;
118
+ border-radius: 0;
119
+ box-shadow: none;
120
+
121
+ // Hover effect for dense table rows
122
+ &:hover {
123
+ background: color.mix($light-gray-2, $white, 30%);
124
+ box-shadow: none;
125
+ transform: none;
126
+ }
127
+
128
+ // Active/selected row
129
+ &.md-grid-card-editing {
130
+ background: color.mix($link, $white, 10%) !important;
131
+ border: none;
132
+ box-shadow: none;
133
+ }
134
+ }
135
+
136
+ // ═════════════════════════════════════════════════════════════════════════
137
+ // CELL
138
+ // ═════════════════════════════════════════════════════════════════════════
139
+
140
+ .md-grid-cell {
141
+ padding: 8px;
142
+ font-family: $base-font-family;
143
+ font-size: 13px;
144
+ font-weight: 400;
145
+ line-height: 21px;
146
+ color: $black-color;
147
+ background: transparent;
148
+ max-height: 30px;
149
+ border: none;
150
+ }
151
+
152
+ .md-grid-cell-value {
153
+ display: block;
154
+ width: 100%;
155
+ }
156
+
157
+ // ═════════════════════════════════════════════════════════════════════════
158
+ // ACTIONS CELL
159
+ // ═════════════════════════════════════════════════════════════════════════
160
+
161
+ .md-grid-actions-cell {
162
+ border-left: none;
163
+ background: transparent;
164
+ }
165
+
166
+ // ═════════════════════════════════════════════════════════════════════════
167
+ // FOOTER / PAGINATION
168
+ // ═════════════════════════════════════════════════════════════════════════
169
+
170
+ .md-grid-footer {
171
+ background: $light-gray-2;
172
+ border-top: 1px solid rgba(0, 0, 0, 0.08);
173
+ padding: 8px;
174
+ font-size: 12px;
175
+ color: $dark-gray-2;
176
+ }
177
+
178
+ .md-grid-pager {
179
+ gap: 2px;
180
+ }
181
+
182
+ .md-grid-pager-btn {
183
+ min-width: 24px;
184
+ height: 24px;
185
+ padding: 0 10px;
186
+ border-radius: 4px;
187
+ border: none;
188
+ background: transparent;
189
+ color: $dark-gray-2;
190
+ font-size: 12px;
191
+
192
+ &:hover:not(:disabled) {
193
+ background: transparent;
194
+ color: $red;
195
+ }
196
+
197
+ &:disabled {
198
+ opacity: 0.3;
199
+ cursor: not-allowed;
200
+ }
201
+ }
202
+
203
+ .md-grid-pager-info {
204
+ padding: 0 8px;
205
+ font-weight: 400;
206
+ }
207
+
208
+ // ═════════════════════════════════════════════════════════════════════════
209
+ // GROUP HEADER
210
+ // ═════════════════════════════════════════════════════════════════════════
211
+
212
+ .md-grid-group-header {
213
+ background: color.mix($light-gray-2, $white, 50%);
214
+ border-bottom: 1px solid rgba(0, 0, 0, 0.08);
215
+ padding: 12px 20px;
216
+ margin-bottom: 0;
217
+ border-radius: 0;
218
+ font-weight: 600;
219
+ font-size: 13px;
220
+ color: $dark-gray-1;
221
+ }
222
+
223
+ // ═════════════════════════════════════════════════════════════════════════
224
+ // RESPONSIVE
225
+ // ═════════════════════════════════════════════════════════════════════════
226
+
227
+ @media (max-width: 768px) {
228
+ font-size: 12px;
229
+
230
+ .md-grid-footer {
231
+ flex-direction: column;
232
+ gap: 8px;
233
+ align-items: flex-start;
234
+ padding: 8px 12px;
235
+ }
236
+ }
237
+
238
+ @media (max-width: 540px) {
239
+ .md-grid-body {
240
+ padding: 6px;
241
+ }
242
+
243
+ .horizontal-scroll-container,
244
+ .md-grid-group-rows {
245
+ display: flex;
246
+ flex-direction: column;
247
+ gap: 10px !important;
248
+ }
249
+
250
+ .md-grid-card {
251
+ border-radius: 8px;
252
+ }
253
+
254
+ .md-grid-cell {
255
+ padding: 7px 12px;
256
+ max-height: none;
257
+ }
258
+
259
+ .md-grid-actions-cell,
260
+ .md-grid-column-actions-cell {
261
+ padding: 7px 4px;
262
+ }
263
+
264
+ .md-grid-first-action-cell,
265
+ .md-grid-row-actions-cell {
266
+ margin-left: auto;
267
+ }
268
+
269
+ .md-grid-last-action-cell,
270
+ .md-grid-row-actions-cell {
271
+ padding-right: 16px;
272
+ }
273
+ }
274
+ }
275
+
276
+ // ═════════════════════════════════════════════════════════════════════════
277
+ // Modifier: zebra-white (white header, zebra rows)
278
+ // ═════════════════════════════════════════════════════════════════════════
279
+
280
+ .md-grid-table.zebra-white {
281
+ .md-grid-header {
282
+ background: $white;
283
+ }
284
+
285
+ .md-grid-header-cell {
286
+ &:not(:first-child) {
287
+ border-left: 2px solid $light-gray-3;
288
+ }
289
+ }
290
+
291
+ .md-grid-card {
292
+ &:nth-child(odd) {
293
+ background: transparent;
294
+ }
295
+
296
+ &:nth-child(even) {
297
+ background: $white;
298
+ }
299
+
300
+ &:hover {
301
+ background: color.mix($light-gray-2, $white, 30%) !important;
302
+ }
303
+ }
304
+
305
+ .md-grid-group-rows {
306
+ .md-grid-card {
307
+ &:nth-child(odd) {
308
+ background: transparent;
309
+ }
310
+
311
+ &:nth-child(even) {
312
+ background: $white;
313
+ }
314
+
315
+ &:hover {
316
+ background: color.mix($light-gray-2, $white, 30%) !important;
317
+ }
318
+ }
319
+ }
320
+
321
+ .md-grid-footer {
322
+ background: $white;
323
+ }
324
+ }
325
+
326
+ // ═════════════════════════════════════════════════════════════════════════
327
+ // Modifier: zebra-grey (grey header, zebra with grey)
328
+ // ═════════════════════════════════════════════════════════════════════════
329
+
330
+ .md-grid-table.zebra-grey {
331
+ .md-grid-card {
332
+ // White rows (odd)
333
+ &:nth-child(odd) {
334
+ background: $white;
335
+
336
+ &:hover {
337
+ background: color.mix($light-gray-2, $white, 30%) !important;
338
+ }
339
+ }
340
+
341
+ // Grey rows (even)
342
+ &:nth-child(even) {
343
+ background: $light-gray-2;
344
+
345
+ &:hover {
346
+ background: color.mix($light-gray-2, $white, 30%) !important;
347
+ }
348
+ }
349
+ }
350
+
351
+ .md-grid-group-rows {
352
+ .md-grid-card {
353
+ &:nth-child(odd) {
354
+ background: $white;
355
+
356
+ &:hover {
357
+ background: color.mix($light-gray-2, $white, 30%) !important;
358
+ }
359
+ }
360
+
361
+ &:nth-child(even) {
362
+ background: $light-gray-2;
363
+
364
+ &:hover {
365
+ background: color.mix($light-gray-2, $white, 30%) !important;
366
+ }
367
+ }
368
+ }
369
+ }
370
+ }