mirror of
https://github.com/trafficlunar/tomodachi-share.git
synced 2026-06-28 06:34:15 +00:00
feat: hide metadata type images offscreen for seo
This commit is contained in:
parent
24b9091c05
commit
817baf7970
2 changed files with 13 additions and 2 deletions
|
|
@ -103,6 +103,7 @@ export default async function MiiList({ searchParams, userId, inLikesPage }: Pro
|
|||
imageCount: true,
|
||||
tags: true,
|
||||
createdAt: true,
|
||||
gender: true,
|
||||
// Mii liked check
|
||||
...(session?.user?.id && {
|
||||
likedBy: {
|
||||
|
|
@ -252,6 +253,17 @@ export default async function MiiList({ searchParams, userId, inLikesPage }: Pro
|
|||
)}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/* Offscreen metadata image for search engines; hidden from users */}
|
||||
{/* eslint-disable-next-line @next/next/no-img-element */}
|
||||
<img
|
||||
src={`/mii/${mii.id}/image?type=metadata`}
|
||||
alt={`${mii.name}, a ${mii.gender ? mii.gender.toLowerCase() : ""} Mii ${mii.tags.length ? ` with tags: ${mii.tags.join(", ")}` : ""}`}
|
||||
loading="lazy"
|
||||
width={1}
|
||||
height={1}
|
||||
className="absolute left-[999999]"
|
||||
/>
|
||||
</div>
|
||||
))}
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue