Improve Lighthouse crawlability score
This commit is contained in:
parent
1cece74e0d
commit
c206471b87
2 changed files with 23 additions and 23 deletions
|
|
@ -8,12 +8,16 @@ export const ImageButtonFactory =
|
|||
{ shouldDownload = false }: { shouldDownload?: boolean } = {}
|
||||
) =>
|
||||
(href?: url) =>
|
||||
`<a ${href ? `href="${href}"` : ''}
|
||||
class="image-button" tabindex="-1" rel="noopener" target="_blank" ${
|
||||
shouldDownload ? 'download' : ''
|
||||
}>
|
||||
<button>
|
||||
`
|
||||
<button class="image-button">
|
||||
${
|
||||
href
|
||||
? `<a href="${href}" tabindex="-1" rel="noopener" target="_blank" ${
|
||||
shouldDownload ? 'download' : ''
|
||||
}>`
|
||||
: ''
|
||||
}
|
||||
<div class="svg-container">${svg}</div>
|
||||
<p>${title}</p>
|
||||
</button>
|
||||
</a>`;
|
||||
${href ? '</a>' : ''}
|
||||
</button>`;
|
||||
|
|
|
|||
|
|
@ -5,23 +5,19 @@
|
|||
padding: var(--small-margin) 8px;
|
||||
text-align: center;
|
||||
|
||||
> button {
|
||||
cursor: pointer;
|
||||
.svg-container {
|
||||
position: relative;
|
||||
margin: auto;
|
||||
@include square(var(--icon-size));
|
||||
|
||||
> .svg-container {
|
||||
position: relative;
|
||||
margin: auto;
|
||||
@include square(var(--icon-size));
|
||||
|
||||
> svg {
|
||||
transition: stroke var(--transition-time), transform var(--transition-time);
|
||||
}
|
||||
}
|
||||
|
||||
> p {
|
||||
font-size: 0.9rem;
|
||||
font-style: italic;
|
||||
text-align: center;
|
||||
> svg {
|
||||
transition: stroke var(--transition-time), transform var(--transition-time);
|
||||
}
|
||||
}
|
||||
|
||||
p {
|
||||
font-size: 0.9rem;
|
||||
font-style: italic;
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue