@@ -137,53 +137,48 @@ export default function TemplateCollection() {
137137 '--template-name-dark' : `center/cover no-repeat url(/static/screenshots/joy-ui/getting-started/templates/${ template . name } -dark.jpg)` ,
138138 } }
139139 />
140- < NextLink
140+ < Link
141141 href = { `/joy-ui/getting-started/templates/${ template . name } /` }
142- passHref
143- legacyBehavior
142+ tabIndex = { - 1 }
143+ component = { NextLink }
144+ overlay
145+ aria-hidden
146+ data-ga-event-category = "joy-template"
147+ data-ga-event-label = { template . name }
148+ data-ga-event-action = "preview-img"
149+ sx = { [
150+ ( theme ) => ( {
151+ display : 'flex' ,
152+ alignItems : 'center' ,
153+ justifyContent : 'center' ,
154+ flexDirection : 'column' ,
155+ gap : 1 ,
156+ transition : '0.15s' ,
157+ position : 'absolute' ,
158+ width : '100%' ,
159+ height : '100%' ,
160+ opacity : 0 ,
161+ top : 0 ,
162+ left : 0 ,
163+ bgcolor : `rgba(${ theme . vars . palette . primary . lightChannel } / 0.3)` ,
164+ backdropFilter : 'blur(4px)' ,
165+ '&:hover, &:focus' : {
166+ opacity : 1 ,
167+ } ,
168+ [ theme . getColorSchemeSelector ( 'dark' ) ] : {
169+ bgcolor : `rgba(${ theme . vars . palette . primary . darkChannel } / 0.3)` ,
170+ } ,
171+ } ) ,
172+ ] }
144173 >
145- { /* eslint-disable-next-line jsx-a11y/anchor-is-valid */ }
146- < Link
147- tabIndex = { - 1 }
148- overlay
149- aria-hidden
150- data-ga-event-category = "joy-template"
151- data-ga-event-label = { template . name }
152- data-ga-event-action = "preview-img"
153- sx = { [
154- ( theme ) => ( {
155- display : 'flex' ,
156- alignItems : 'center' ,
157- justifyContent : 'center' ,
158- flexDirection : 'column' ,
159- gap : 1 ,
160- transition : '0.15s' ,
161- position : 'absolute' ,
162- width : '100%' ,
163- height : '100%' ,
164- opacity : 0 ,
165- top : 0 ,
166- left : 0 ,
167- bgcolor : `rgba(${ theme . vars . palette . primary . lightChannel } / 0.3)` ,
168- backdropFilter : 'blur(4px)' ,
169- '&:hover, &:focus' : {
170- opacity : 1 ,
171- } ,
172- [ theme . getColorSchemeSelector ( 'dark' ) ] : {
173- bgcolor : `rgba(${ theme . vars . palette . primary . darkChannel } / 0.3)` ,
174- } ,
175- } ) ,
176- ] }
174+ < Visibility />
175+ < Typography
176+ textColor = "text.primary"
177+ sx = { { fontWeight : 'bold' , fontFamily : 'IBM Plex Sans' } }
177178 >
178- < Visibility />
179- < Typography
180- textColor = "text.primary"
181- sx = { { fontWeight : 'bold' , fontFamily : 'IBM Plex Sans' } }
182- >
183- View live preview
184- </ Typography >
185- </ Link >
186- </ NextLink >
179+ View live preview
180+ </ Typography >
181+ </ Link >
187182 </ AspectRatio >
188183 </ CardOverflow >
189184 < CardContent sx = { { display : 'flex' , flexDirection : 'column' } } >
@@ -255,26 +250,21 @@ export default function TemplateCollection() {
255250 gap : 1.5 ,
256251 } }
257252 >
258- < NextLink
253+ < Button
259254 href = { `https://github.com/mui/material-ui/tree/master/docs/data/joy/getting-started/templates/${ template . name } ` }
260- passHref
261- legacyBehavior
255+ component = { NextLink }
256+ variant = "outlined"
257+ color = "neutral"
258+ fullWidth
259+ startDecorator = { < CodeRoundedIcon /> }
260+ aria-label = "Source code"
261+ data-ga-event-category = "joy-template"
262+ data-ga-event-label = { template . name }
263+ data-ga-event-action = "preview"
264+ sx = { { fontFamily : 'IBM Plex Sans' } }
262265 >
263- < Button
264- component = "a"
265- variant = "outlined"
266- color = "neutral"
267- fullWidth
268- startDecorator = { < CodeRoundedIcon /> }
269- aria-label = "Source code"
270- data-ga-event-category = "joy-template"
271- data-ga-event-label = { template . name }
272- data-ga-event-action = "preview"
273- sx = { { fontFamily : 'IBM Plex Sans' } }
274- >
275- Source
276- </ Button >
277- </ NextLink >
266+ Source
267+ </ Button >
278268 < Button
279269 variant = "outlined"
280270 color = "neutral"
0 commit comments