@rescui/card 0.14.5 → 0.14.6
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/lib/card.p.module.css.js +26 -26
- package/lib/index.css +59 -53
- package/llm/cards.md +0 -25
- package/package.json +6 -6
package/lib/card.p.module.css.js
CHANGED
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
var styles = {
|
|
2
|
-
"themeLight": "
|
|
3
|
-
"themeDark": "
|
|
4
|
-
"padding0": "
|
|
5
|
-
"padding16": "
|
|
6
|
-
"padding24": "
|
|
7
|
-
"padding32": "
|
|
8
|
-
"borderRadius0": "
|
|
9
|
-
"borderRadius8": "
|
|
10
|
-
"borderRadius16": "
|
|
11
|
-
"borderRadius24": "
|
|
12
|
-
"modeClassic": "
|
|
13
|
-
"modeRock": "
|
|
14
|
-
"transparentBorderTrue": "
|
|
15
|
-
"transparentBorderFalse": "
|
|
16
|
-
"clickable": "
|
|
17
|
-
"disableBorder": "
|
|
18
|
-
"hasGlowHover": "
|
|
19
|
-
"legacyBorder": "
|
|
20
|
-
"tile": "
|
|
21
|
-
"fixedImageHeight": "
|
|
22
|
-
"fullImageWidth": "
|
|
23
|
-
"cardImage": "
|
|
24
|
-
"cardImageImg": "
|
|
25
|
-
"cardImageDiv": "
|
|
26
|
-
"innerLink": "
|
|
27
|
-
"innerButton": "
|
|
2
|
+
"themeLight": "_themeLight_1h1z6y5_8",
|
|
3
|
+
"themeDark": "_themeDark_1h1z6y5_11",
|
|
4
|
+
"padding0": "_padding0_1h1z6y5_15",
|
|
5
|
+
"padding16": "_padding16_1h1z6y5_18",
|
|
6
|
+
"padding24": "_padding24_1h1z6y5_21",
|
|
7
|
+
"padding32": "_padding32_1h1z6y5_24",
|
|
8
|
+
"borderRadius0": "_borderRadius0_1h1z6y5_28",
|
|
9
|
+
"borderRadius8": "_borderRadius8_1h1z6y5_31",
|
|
10
|
+
"borderRadius16": "_borderRadius16_1h1z6y5_34",
|
|
11
|
+
"borderRadius24": "_borderRadius24_1h1z6y5_37",
|
|
12
|
+
"modeClassic": "_modeClassic_1h1z6y5_41",
|
|
13
|
+
"modeRock": "_modeRock_1h1z6y5_51",
|
|
14
|
+
"transparentBorderTrue": "_transparentBorderTrue_1h1z6y5_60",
|
|
15
|
+
"transparentBorderFalse": "_transparentBorderFalse_1h1z6y5_63",
|
|
16
|
+
"clickable": "_clickable_1h1z6y5_111",
|
|
17
|
+
"disableBorder": "_disableBorder_1h1z6y5_70",
|
|
18
|
+
"hasGlowHover": "_hasGlowHover_1h1z6y5_88",
|
|
19
|
+
"legacyBorder": "_legacyBorder_1h1z6y5_133",
|
|
20
|
+
"tile": "_tile_1h1z6y5_247",
|
|
21
|
+
"fixedImageHeight": "_fixedImageHeight_1h1z6y5_323",
|
|
22
|
+
"fullImageWidth": "_fullImageWidth_1h1z6y5_332",
|
|
23
|
+
"cardImage": "_cardImage_1h1z6y5_336",
|
|
24
|
+
"cardImageImg": "_cardImageImg_1h1z6y5_344",
|
|
25
|
+
"cardImageDiv": "_cardImageDiv_1h1z6y5_369",
|
|
26
|
+
"innerLink": "_innerLink_1h1z6y5_394",
|
|
27
|
+
"innerButton": "_innerButton_1h1z6y5_406"
|
|
28
28
|
};
|
|
29
29
|
export { styles as default };
|
package/lib/index.css
CHANGED
|
@@ -1,44 +1,50 @@
|
|
|
1
|
-
|
|
1
|
+
@property --_rs-theme-dark-coefficient{
|
|
2
|
+
syntax:'<number>';
|
|
3
|
+
inherits:true;
|
|
4
|
+
initial-value:0;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
._themeLight_1h1z6y5_8{
|
|
2
8
|
--rs-theme-dark:0;
|
|
3
9
|
}
|
|
4
10
|
|
|
5
|
-
.
|
|
11
|
+
._themeDark_1h1z6y5_11{
|
|
6
12
|
--rs-theme-dark:1;
|
|
7
13
|
}
|
|
8
14
|
|
|
9
|
-
.
|
|
15
|
+
._padding0_1h1z6y5_15{
|
|
10
16
|
--_rs-card-padding:0px;
|
|
11
17
|
}
|
|
12
18
|
|
|
13
|
-
.
|
|
19
|
+
._padding16_1h1z6y5_18{
|
|
14
20
|
--_rs-card-padding:16px;
|
|
15
21
|
}
|
|
16
22
|
|
|
17
|
-
.
|
|
23
|
+
._padding24_1h1z6y5_21{
|
|
18
24
|
--_rs-card-padding:24px;
|
|
19
25
|
}
|
|
20
26
|
|
|
21
|
-
.
|
|
27
|
+
._padding32_1h1z6y5_24{
|
|
22
28
|
--_rs-card-padding:32px;
|
|
23
29
|
}
|
|
24
30
|
|
|
25
|
-
.
|
|
31
|
+
._borderRadius0_1h1z6y5_28{
|
|
26
32
|
--_rs-card-border-radius:0px;
|
|
27
33
|
}
|
|
28
34
|
|
|
29
|
-
.
|
|
35
|
+
._borderRadius8_1h1z6y5_31{
|
|
30
36
|
--_rs-card-border-radius:8px;
|
|
31
37
|
}
|
|
32
38
|
|
|
33
|
-
.
|
|
39
|
+
._borderRadius16_1h1z6y5_34{
|
|
34
40
|
--_rs-card-border-radius:16px;
|
|
35
41
|
}
|
|
36
42
|
|
|
37
|
-
.
|
|
43
|
+
._borderRadius24_1h1z6y5_37{
|
|
38
44
|
--_rs-card-border-radius:24px;
|
|
39
45
|
}
|
|
40
46
|
|
|
41
|
-
.
|
|
47
|
+
._modeClassic_1h1z6y5_41{
|
|
42
48
|
--_rs-card-states-theme-flip:0;
|
|
43
49
|
|
|
44
50
|
--_rs-card-hover-focus-active-border-color:rgb(
|
|
@@ -49,7 +55,7 @@
|
|
|
49
55
|
--_rs-card-active-background:rgb(calc(255 - var(--_rs-theme-dark-coefficient, 0)*207), calc(255 - var(--_rs-theme-dark-coefficient, 0)*207), calc(255 - var(--_rs-theme-dark-coefficient, 0)*204));
|
|
50
56
|
}
|
|
51
57
|
|
|
52
|
-
.
|
|
58
|
+
._modeRock_1h1z6y5_51{
|
|
53
59
|
--_rs-card-states-theme-flip:1;
|
|
54
60
|
|
|
55
61
|
--_rs-card-hover-focus-active-border-color:transparent;
|
|
@@ -58,15 +64,15 @@
|
|
|
58
64
|
--_rs-card-active-background:rgb(calc(244 - var(--_rs-theme-dark-coefficient, 0)*196), calc(244 - var(--_rs-theme-dark-coefficient, 0)*196), calc(244 - var(--_rs-theme-dark-coefficient, 0)*193));
|
|
59
65
|
}
|
|
60
66
|
|
|
61
|
-
.
|
|
67
|
+
._transparentBorderTrue_1h1z6y5_60{
|
|
62
68
|
--_rs-card-grey-border-color:rgba(calc(25 + var(--_rs-theme-dark-coefficient, 0)*230), calc(25 + var(--_rs-theme-dark-coefficient, 0)*230), calc(28 + var(--_rs-theme-dark-coefficient, 0)*227), 0.2);
|
|
63
69
|
}
|
|
64
70
|
|
|
65
|
-
.
|
|
71
|
+
._transparentBorderFalse_1h1z6y5_63{
|
|
66
72
|
--_rs-card-grey-border-color:rgb(calc(209 - var(--_rs-theme-dark-coefficient, 0)*115), calc(209 - var(--_rs-theme-dark-coefficient, 0)*115), calc(210 - var(--_rs-theme-dark-coefficient, 0)*114));
|
|
67
73
|
}
|
|
68
74
|
|
|
69
|
-
.
|
|
75
|
+
._clickable_1h1z6y5_111{
|
|
70
76
|
--_rs-theme-dark:var(
|
|
71
77
|
--_rs-internal-force-theme-dark-consult-rescui-before-using,
|
|
72
78
|
var(--rs-theme-dark, 0)
|
|
@@ -77,11 +83,11 @@
|
|
|
77
83
|
--_rs-card-native-static-border-color:var(--_rs-card-grey-border-color);
|
|
78
84
|
}
|
|
79
85
|
|
|
80
|
-
.
|
|
86
|
+
._clickable_1h1z6y5_111._disableBorder_1h1z6y5_70{
|
|
81
87
|
--_rs-card-native-static-border-color:transparent;
|
|
82
88
|
}
|
|
83
89
|
|
|
84
|
-
.
|
|
90
|
+
._clickable_1h1z6y5_111 {
|
|
85
91
|
--_rs-card-native-hover-border-color:var(
|
|
86
92
|
--_rs-card-hover-focus-active-border-color
|
|
87
93
|
);
|
|
@@ -91,26 +97,26 @@
|
|
|
91
97
|
);
|
|
92
98
|
}
|
|
93
99
|
|
|
94
|
-
.
|
|
100
|
+
._clickable_1h1z6y5_111:is([data-extra-hover-effect], ._hasGlowHover_1h1z6y5_88){
|
|
95
101
|
--_rs-card-native-hover-border-color:var(--_rs-card-grey-border-color);
|
|
96
102
|
}
|
|
97
103
|
|
|
98
|
-
.
|
|
104
|
+
._clickable_1h1z6y5_111:is([data-extra-hover-effect], ._hasGlowHover_1h1z6y5_88)[data-extra-active-effect]{
|
|
99
105
|
--_rs-card-native-active-border-width:1px;
|
|
100
106
|
--_rs-card-native-active-border-color:var(--_rs-card-grey-border-color);
|
|
101
107
|
}
|
|
102
108
|
|
|
103
|
-
.
|
|
109
|
+
._clickable_1h1z6y5_111:is([data-extra-hover-effect], ._hasGlowHover_1h1z6y5_88)._disableBorder_1h1z6y5_70{
|
|
104
110
|
--_rs-card-native-hover-border-color:transparent;
|
|
105
111
|
|
|
106
112
|
--_rs-card-native-active-border-width:1px;
|
|
107
113
|
}
|
|
108
114
|
|
|
109
|
-
.
|
|
115
|
+
._clickable_1h1z6y5_111:is([data-extra-hover-effect], ._hasGlowHover_1h1z6y5_88)._disableBorder_1h1z6y5_70[data-extra-active-effect]{
|
|
110
116
|
--_rs-card-native-active-border-color:transparent;
|
|
111
117
|
}
|
|
112
118
|
|
|
113
|
-
.
|
|
119
|
+
._clickable_1h1z6y5_111 {
|
|
114
120
|
|
|
115
121
|
--_rs-card-env-background:var(
|
|
116
122
|
--rs-card-static-background,
|
|
@@ -131,12 +137,12 @@
|
|
|
131
137
|
--_rs-card-css-border:none;
|
|
132
138
|
}
|
|
133
139
|
|
|
134
|
-
.
|
|
140
|
+
._clickable_1h1z6y5_111._legacyBorder_1h1z6y5_133{
|
|
135
141
|
--_rs-card-css-padding:calc(var(--_rs-card-padding-final) - var(--_rs-card-env-border-width));
|
|
136
142
|
--_rs-card-css-border:var(--_rs-card-env-border-width) solid var(--_rs-card-env-border-color);
|
|
137
143
|
}
|
|
138
144
|
|
|
139
|
-
.
|
|
145
|
+
._clickable_1h1z6y5_111 {
|
|
140
146
|
--rs-out-card-padding:var(--_rs-card-padding-final);
|
|
141
147
|
--rs-out-card-border-radius:var(--_rs-card-border-radius-final);
|
|
142
148
|
--rs-out-card-border-width:var(--_rs-card-env-border-width);
|
|
@@ -167,7 +173,7 @@
|
|
|
167
173
|
appearance:none;
|
|
168
174
|
}
|
|
169
175
|
|
|
170
|
-
.
|
|
176
|
+
._clickable_1h1z6y5_111:not(._legacyBorder_1h1z6y5_133)::after{
|
|
171
177
|
position:absolute;
|
|
172
178
|
top:0;
|
|
173
179
|
right:0;
|
|
@@ -186,13 +192,13 @@
|
|
|
186
192
|
transition:box-shadow 100ms var(--rs-transition-function, ease);
|
|
187
193
|
}
|
|
188
194
|
|
|
189
|
-
.
|
|
190
|
-
.
|
|
195
|
+
._clickable_1h1z6y5_111,
|
|
196
|
+
._clickable_1h1z6y5_111:hover{
|
|
191
197
|
text-decoration:none;
|
|
192
198
|
}
|
|
193
199
|
|
|
194
200
|
@media (hover: hover){
|
|
195
|
-
.
|
|
201
|
+
._clickable_1h1z6y5_111:hover{
|
|
196
202
|
--rs-theme-flip:var(--_rs-card-states-theme-flip);
|
|
197
203
|
|
|
198
204
|
--_rs-card-env-background:var(
|
|
@@ -207,7 +213,7 @@
|
|
|
207
213
|
}
|
|
208
214
|
}
|
|
209
215
|
|
|
210
|
-
.
|
|
216
|
+
._clickable_1h1z6y5_111:focus-visible{
|
|
211
217
|
--rs-theme-flip:var(--_rs-card-states-theme-flip);
|
|
212
218
|
|
|
213
219
|
--_rs-card-env-background:var(
|
|
@@ -222,7 +228,7 @@
|
|
|
222
228
|
outline:none;
|
|
223
229
|
}
|
|
224
230
|
|
|
225
|
-
.
|
|
231
|
+
._clickable_1h1z6y5_111:active{
|
|
226
232
|
--rs-theme-flip:var(--_rs-card-states-theme-flip);
|
|
227
233
|
|
|
228
234
|
--_rs-card-env-background:var(
|
|
@@ -239,7 +245,7 @@
|
|
|
239
245
|
);
|
|
240
246
|
}
|
|
241
247
|
|
|
242
|
-
.
|
|
248
|
+
._tile_1h1z6y5_247{
|
|
243
249
|
--_rs-theme-dark:var(
|
|
244
250
|
--_rs-internal-force-theme-dark-consult-rescui-before-using,
|
|
245
251
|
var(--rs-theme-dark, 0)
|
|
@@ -250,11 +256,11 @@
|
|
|
250
256
|
--_rs-card-native-static-border-color:var(--_rs-card-grey-border-color);
|
|
251
257
|
}
|
|
252
258
|
|
|
253
|
-
.
|
|
259
|
+
._tile_1h1z6y5_247._disableBorder_1h1z6y5_70{
|
|
254
260
|
--_rs-card-native-static-border-color:transparent;
|
|
255
261
|
}
|
|
256
262
|
|
|
257
|
-
.
|
|
263
|
+
._tile_1h1z6y5_247 {
|
|
258
264
|
|
|
259
265
|
--_rs-card-env-background:var(
|
|
260
266
|
--rs-card-static-background,
|
|
@@ -275,12 +281,12 @@
|
|
|
275
281
|
--_rs-card-css-border:none;
|
|
276
282
|
}
|
|
277
283
|
|
|
278
|
-
.
|
|
284
|
+
._tile_1h1z6y5_247._legacyBorder_1h1z6y5_133{
|
|
279
285
|
--_rs-card-css-padding:calc(var(--_rs-card-padding-final) - var(--_rs-card-env-border-width));
|
|
280
286
|
--_rs-card-css-border:var(--_rs-card-env-border-width) solid var(--_rs-card-env-border-color);
|
|
281
287
|
}
|
|
282
288
|
|
|
283
|
-
.
|
|
289
|
+
._tile_1h1z6y5_247 {
|
|
284
290
|
--rs-out-card-padding:var(--_rs-card-padding-final);
|
|
285
291
|
--rs-out-card-border-radius:var(--_rs-card-border-radius-final);
|
|
286
292
|
--rs-out-card-border-width:var(--_rs-card-env-border-width);
|
|
@@ -312,7 +318,7 @@
|
|
|
312
318
|
appearance:none;
|
|
313
319
|
}
|
|
314
320
|
|
|
315
|
-
.
|
|
321
|
+
._tile_1h1z6y5_247:not(._legacyBorder_1h1z6y5_133)::after{
|
|
316
322
|
position:absolute;
|
|
317
323
|
top:0;
|
|
318
324
|
right:0;
|
|
@@ -329,20 +335,20 @@
|
|
|
329
335
|
box-shadow:inset 0 0 0 var(--_rs-card-env-border-width) var(--_rs-card-env-border-color);
|
|
330
336
|
}
|
|
331
337
|
|
|
332
|
-
.
|
|
338
|
+
._fixedImageHeight_1h1z6y5_323{
|
|
333
339
|
height:calc(188px + var(--_rs-card-padding-final));
|
|
334
340
|
max-height:calc(188px + var(--_rs-card-padding-final));
|
|
335
341
|
}
|
|
336
342
|
|
|
337
|
-
.
|
|
343
|
+
._fixedImageHeight_1h1z6y5_323 img{
|
|
338
344
|
height:100%;
|
|
339
345
|
}
|
|
340
346
|
|
|
341
|
-
.
|
|
347
|
+
._fullImageWidth_1h1z6y5_332 img{
|
|
342
348
|
width:100%;
|
|
343
349
|
}
|
|
344
350
|
|
|
345
|
-
.
|
|
351
|
+
._cardImage_1h1z6y5_336{
|
|
346
352
|
position:relative;
|
|
347
353
|
|
|
348
354
|
overflow:hidden;
|
|
@@ -350,7 +356,7 @@
|
|
|
350
356
|
box-sizing:border-box;
|
|
351
357
|
}
|
|
352
358
|
|
|
353
|
-
.
|
|
359
|
+
._cardImageImg_1h1z6y5_344{
|
|
354
360
|
top:calc(var(--_rs-card-padding-final)*-1);
|
|
355
361
|
left:calc(var(--_rs-card-padding-final)*-1);
|
|
356
362
|
|
|
@@ -361,21 +367,21 @@
|
|
|
361
367
|
width:calc(100% + var(--_rs-card-padding-final)*2);
|
|
362
368
|
}
|
|
363
369
|
|
|
364
|
-
.
|
|
370
|
+
._cardImageImg_1h1z6y5_344 img{
|
|
365
371
|
max-width:100%;
|
|
366
372
|
max-height:100%;
|
|
367
373
|
}
|
|
368
374
|
|
|
369
|
-
.
|
|
375
|
+
._clickable_1h1z6y5_111 ._cardImageImg_1h1z6y5_344 img{
|
|
370
376
|
transition:transform 0.2s var(--rs-transition-function, ease);
|
|
371
377
|
transform:scale(1);
|
|
372
378
|
}
|
|
373
379
|
|
|
374
|
-
.
|
|
380
|
+
._clickable_1h1z6y5_111:hover ._cardImageImg_1h1z6y5_344 img{
|
|
375
381
|
transform:scale(1.1);
|
|
376
382
|
}
|
|
377
383
|
|
|
378
|
-
.
|
|
384
|
+
._cardImageDiv_1h1z6y5_369{
|
|
379
385
|
top:calc(var(--_rs-card-padding-final)*-1);
|
|
380
386
|
left:calc(var(--_rs-card-padding-final)*-1);
|
|
381
387
|
|
|
@@ -392,16 +398,16 @@
|
|
|
392
398
|
background-size:100% 100%;
|
|
393
399
|
}
|
|
394
400
|
|
|
395
|
-
.
|
|
401
|
+
._clickable_1h1z6y5_111 ._cardImageDiv_1h1z6y5_369{
|
|
396
402
|
transition:background-size 0.2s var(--rs-transition-function, ease);
|
|
397
403
|
}
|
|
398
404
|
|
|
399
|
-
.
|
|
405
|
+
._clickable_1h1z6y5_111:hover ._cardImageDiv_1h1z6y5_369{
|
|
400
406
|
background-size:110% 110%;
|
|
401
407
|
}
|
|
402
408
|
|
|
403
409
|
@media (hover: hover){
|
|
404
|
-
.
|
|
410
|
+
._clickable_1h1z6y5_111:hover ._innerLink_1h1z6y5_394{
|
|
405
411
|
--_rs-typography-link-padding-bottom-from-state-hover:calc(1px - var(--_rs-typography-link-hover-underline-width-difference-wf));
|
|
406
412
|
--_rs-typography-link-border-bottom-width-from-state-hover:calc(var(--_rs-typography-link-border-bottom-width-wf) + var(--_rs-typography-link-hover-underline-width-difference-wf));
|
|
407
413
|
--_rs-typography-link-border-bottom-color-from-state-hover:var(
|
|
@@ -423,14 +429,14 @@
|
|
|
423
429
|
}
|
|
424
430
|
}
|
|
425
431
|
|
|
426
|
-
.
|
|
432
|
+
._clickable_1h1z6y5_111:focus-visible ._innerLink_1h1z6y5_394{
|
|
427
433
|
--_rs-typography-link-box-shadow-from-state-focus-visible:var(
|
|
428
434
|
--_rs-color-primary
|
|
429
435
|
) 0 0 0 4px;
|
|
430
436
|
}
|
|
431
437
|
|
|
432
438
|
@media (hover: hover){
|
|
433
|
-
.
|
|
439
|
+
._clickable_1h1z6y5_111:hover ._innerButton_1h1z6y5_406{
|
|
434
440
|
--_rs-button-border-inner-color:rgba(
|
|
435
441
|
calc(25 + var(--_rs-theme-dark-coefficient, 0)*230), calc(25 + var(--_rs-theme-dark-coefficient, 0)*230), calc(28 + var(--_rs-theme-dark-coefficient, 0)*227),
|
|
436
442
|
calc(0.3 + var(--_rs-theme-dark-coefficient, 0)*0.1)
|
|
@@ -439,7 +445,7 @@
|
|
|
439
445
|
}
|
|
440
446
|
}
|
|
441
447
|
|
|
442
|
-
.
|
|
448
|
+
._clickable_1h1z6y5_111:active ._innerButton_1h1z6y5_406{
|
|
443
449
|
--_rs-button-border-inner-width:2px;
|
|
444
450
|
--_rs-button-border-inner-color:rgb(calc(25 + var(--_rs-theme-dark-coefficient, 0)*230), calc(25 + var(--_rs-theme-dark-coefficient, 0)*230), calc(28 + var(--_rs-theme-dark-coefficient, 0)*227));
|
|
445
451
|
--_rs-button-background-from-state-active:var(
|
|
@@ -447,13 +453,13 @@
|
|
|
447
453
|
);
|
|
448
454
|
}
|
|
449
455
|
|
|
450
|
-
.
|
|
456
|
+
._clickable_1h1z6y5_111:focus-visible ._innerButton_1h1z6y5_406{
|
|
451
457
|
--_rs-button-box-shadow-from-state-focus-visible:var(
|
|
452
458
|
--_rs-color-primary-t-dim
|
|
453
459
|
) 0 0 0 4px;
|
|
454
460
|
}
|
|
455
461
|
|
|
456
|
-
.
|
|
462
|
+
._clickable_1h1z6y5_111:active:focus-visible:not(:hover) ._innerButton_1h1z6y5_406{
|
|
457
463
|
--_rs-button-background-from-state-active-focus-visible-no-hover:var(
|
|
458
464
|
--_rs-button-active-focus-visible-no-hover-background
|
|
459
465
|
);
|
package/llm/cards.md
CHANGED
|
@@ -53,7 +53,6 @@ A ClassName Helper for creating cards with simple styles and some customizations
|
|
|
53
53
|
- Base example
|
|
54
54
|
- Using css variables to control the border
|
|
55
55
|
- Set border on the pseudo-element to avoid scaling bug when changing `border-width`
|
|
56
|
-
|
|
57
56
|
- [cardCn implementation](/components/card-cn/#default-clickable-card)
|
|
58
57
|
|
|
59
58
|
```tsx
|
|
@@ -140,7 +139,6 @@ render(<Demo />);
|
|
|
140
139
|
- Dark theme
|
|
141
140
|
- Using css variables to control the border
|
|
142
141
|
- Set border on the pseudo-element to avoid scaling bug when changing `border-width`
|
|
143
|
-
|
|
144
142
|
- [cardCn implementation](/components/card-cn/#theme-dark)
|
|
145
143
|
|
|
146
144
|
```tsx
|
|
@@ -383,15 +381,10 @@ render(<Demo />);
|
|
|
383
381
|
##### Details:
|
|
384
382
|
|
|
385
383
|
- With border via pseudo-element `::before`
|
|
386
|
-
|
|
387
384
|
- Forward states to the `Button` inside
|
|
388
|
-
|
|
389
385
|
- Card should have the `button` HTML tag
|
|
390
|
-
|
|
391
386
|
- Main action, like `onClick`, should be on the card element
|
|
392
|
-
|
|
393
387
|
- Use `notFocusable` property with `Button`
|
|
394
|
-
|
|
395
388
|
- Use only one action element inside
|
|
396
389
|
- [cardCn implementation](/components/card-cn/#with-action-button-inside)
|
|
397
390
|
|
|
@@ -508,15 +501,10 @@ render(<Demo />);
|
|
|
508
501
|
##### Details:
|
|
509
502
|
|
|
510
503
|
- With border via pseudo-element `::before`
|
|
511
|
-
|
|
512
504
|
- Forward states to the `rs-link` inside
|
|
513
|
-
|
|
514
505
|
- Card should have the `a` HTML tag
|
|
515
|
-
|
|
516
506
|
- Main action, like `href`, should be on the card element
|
|
517
|
-
|
|
518
507
|
- `rs-link` should have `span` HTML tag
|
|
519
|
-
|
|
520
508
|
- Use only one action element inside
|
|
521
509
|
- [cardCn implementation](/components/card-cn/#with-action-link-inside)
|
|
522
510
|
|
|
@@ -628,10 +616,8 @@ render(<Demo />);
|
|
|
628
616
|
##### Details:
|
|
629
617
|
|
|
630
618
|
- With static border on the main element (border width is constant)
|
|
631
|
-
|
|
632
619
|
- Decrease inner padding by border width value to compensate for the offset
|
|
633
620
|
- Change `border-color` to transparent on hover/active instead of changing its width
|
|
634
|
-
|
|
635
621
|
- Change background-color to contrast value on hover/active
|
|
636
622
|
- Use `--rs-theme-flip` css-variable to reverse theme for all RescUI components on hover/active
|
|
637
623
|
|
|
@@ -718,7 +704,6 @@ render(<Demo />);
|
|
|
718
704
|
##### Details:
|
|
719
705
|
|
|
720
706
|
- With border via pseudo-element `::before`
|
|
721
|
-
|
|
722
707
|
- Inside grid container
|
|
723
708
|
- Each card takes up two rows and applies subgrid to its children
|
|
724
709
|
- Cards text content lays on the second row, aligning with the content in the sibling cards
|
|
@@ -858,7 +843,6 @@ render(<Demo />);
|
|
|
858
843
|
##### Details:
|
|
859
844
|
|
|
860
845
|
- With border via pseudo-element `::before`
|
|
861
|
-
|
|
862
846
|
- With colored bg and border
|
|
863
847
|
- `border-color` is constant, but the `background-color` changes on hover
|
|
864
848
|
- Text is center aligned
|
|
@@ -1178,7 +1162,6 @@ render(<Demo />);
|
|
|
1178
1162
|
|
|
1179
1163
|
- Base example
|
|
1180
1164
|
- Has no dynamic states - its a static `div` element
|
|
1181
|
-
|
|
1182
1165
|
- [cardCn implementation](/components/card-cn/#default-card)
|
|
1183
1166
|
|
|
1184
1167
|
```tsx
|
|
@@ -1594,9 +1577,7 @@ render(<Demo />);
|
|
|
1594
1577
|
##### Details:
|
|
1595
1578
|
|
|
1596
1579
|
- Tiles are aligned using `grid-template-areas` CSS property
|
|
1597
|
-
|
|
1598
1580
|
- Grid areas are forwarded to CSS using `--tile-id` CSS variable
|
|
1599
|
-
|
|
1600
1581
|
- Flat tiles layout structure allows for easy adaptive changes compared to the two-column flex layout
|
|
1601
1582
|
|
|
1602
1583
|
```tsx
|
|
@@ -1747,10 +1728,8 @@ render(<Demo />);
|
|
|
1747
1728
|
|
|
1748
1729
|
- Big tiles with a lot of content
|
|
1749
1730
|
- One or more tiles may have `StickyTag`
|
|
1750
|
-
|
|
1751
1731
|
- Content inside tiles is aligned with siblings
|
|
1752
1732
|
- `checkbox` aligned using subgrid
|
|
1753
|
-
|
|
1754
1733
|
- Actions in the footer are nailed to the tile bottom
|
|
1755
1734
|
- Tiles may contain `Collapse` inside
|
|
1756
1735
|
|
|
@@ -2644,11 +2623,9 @@ render(<Demo />);
|
|
|
2644
2623
|
|
|
2645
2624
|
- Without border
|
|
2646
2625
|
- With `selected` state
|
|
2647
|
-
|
|
2648
2626
|
- With filling progress bar
|
|
2649
2627
|
- With hover and focus-visible states
|
|
2650
2628
|
- Control autoplay animation duration with `--carousel-vertical-control-autoplay-duration` css variable
|
|
2651
|
-
|
|
2652
2629
|
- With react state management
|
|
2653
2630
|
|
|
2654
2631
|
```tsx
|
|
@@ -2844,11 +2821,9 @@ render(<Demo />);
|
|
|
2844
2821
|
|
|
2845
2822
|
- Without border
|
|
2846
2823
|
- With `selected` state
|
|
2847
|
-
|
|
2848
2824
|
- With filling progress bar
|
|
2849
2825
|
- With hover and focus-visible states
|
|
2850
2826
|
- Control autoplay animation duration with `--carousel-horizontal-control-autoplay-duration` css variable
|
|
2851
|
-
|
|
2852
2827
|
- With react state management
|
|
2853
2828
|
|
|
2854
2829
|
```tsx
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rescui/card",
|
|
3
|
-
"version": "0.14.
|
|
3
|
+
"version": "0.14.6",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "lib/index.js",
|
|
@@ -24,16 +24,16 @@
|
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
26
|
"@jetbrains/logos": "^1.4.16",
|
|
27
|
-
"@rescui/button": "^0.24.
|
|
28
|
-
"@rescui/colors": "^0.3.
|
|
29
|
-
"@rescui/postcss-preset-library": "^0.2.
|
|
27
|
+
"@rescui/button": "^0.24.6",
|
|
28
|
+
"@rescui/colors": "^0.3.3",
|
|
29
|
+
"@rescui/postcss-preset-library": "^0.2.3",
|
|
30
30
|
"@rescui/scripts": "^0.5.2",
|
|
31
|
-
"@rescui/typography": "^0.27.
|
|
31
|
+
"@rescui/typography": "^0.27.4",
|
|
32
32
|
"@rescui/visual-regression": "^0.1.4"
|
|
33
33
|
},
|
|
34
34
|
"scripts": {
|
|
35
35
|
"build": "rescui-scripts build"
|
|
36
36
|
},
|
|
37
37
|
"nx": {},
|
|
38
|
-
"gitHead": "
|
|
38
|
+
"gitHead": "3711cbfc0c797014395421b008aa5331d6d47c6e"
|
|
39
39
|
}
|