File tree Expand file tree Collapse file tree 2 files changed +31
-12
lines changed Expand file tree Collapse file tree 2 files changed +31
-12
lines changed Original file line number Diff line number Diff line change @@ -39,24 +39,30 @@ const LazyLoadComponent: FC<
39
39
< div ref = { ref } className = "components-overview-item" >
40
40
{ isVisible && (
41
41
< Suspense fallback = { < div className = "skeleton" > </ div > } >
42
- < Link tabIndex = { 0 } to = { `${ path } /components/${ formattedComponentName } ` } />
42
+ < Link
43
+ className = "components-overview-item__link"
44
+ tabIndex = { 0 }
45
+ to = { `${ path } /components/${ formattedComponentName } ` }
46
+ />
43
47
< KolCard
44
48
tabIndex = { - 1 }
45
49
aria-label = { formattedComponentName }
46
50
role = "img"
47
51
_level = { 2 }
48
52
_label = { formattedComponentName }
49
53
>
50
- < SampleComponent lang = { lang } />
51
- { badges && badges ?. length > 0 && (
52
- < div className = "absolute bottom-2 p-1" >
53
- < div className = "flex flex-wrap gap-2" >
54
- { badges ?. map ( ( label ) => (
55
- < KolBadge key = { label } _color = "#dadde1" _label = { label } > </ KolBadge >
56
- ) ) }
54
+ < div className = "components-overview-item__card-content" >
55
+ < SampleComponent lang = { lang } />
56
+ { badges && badges ?. length > 0 && (
57
+ < div className = "mt-4 p-1" >
58
+ < div className = "flex flex-wrap gap-2" >
59
+ { badges ?. map ( ( label ) => (
60
+ < KolBadge key = { label } _color = "#dadde1" _label = { label } > </ KolBadge >
61
+ ) ) }
62
+ </ div >
57
63
</ div >
58
- </ div >
59
- ) }
64
+ ) }
65
+ </ div >
60
66
</ KolCard >
61
67
</ Suspense >
62
68
) }
Original file line number Diff line number Diff line change @@ -158,10 +158,17 @@ kol-link-button {
158
158
159
159
.components-overview-item {
160
160
position : relative;
161
- height : 350 px ;
161
+ height : auto ;
162
162
}
163
163
164
- .components-overview-item a {
164
+ .components-overview-item__card-content {
165
+ display : flex;
166
+ flex-flow : column;
167
+ height : 100% ;
168
+ justify-content : space-between;
169
+ }
170
+
171
+ .components-overview-item__link {
165
172
position : absolute;
166
173
width : 100% ;
167
174
height : 100% ;
@@ -170,3 +177,9 @@ kol-link-button {
170
177
z-index : 1 ;
171
178
cursor : pointer;
172
179
}
180
+
181
+ @media (max-width : 767px ) {
182
+ .components-overview {
183
+ grid-template-columns : 1fr ;
184
+ }
185
+ }
You can’t perform that action at this time.
0 commit comments