Add Mastodon links to new stories, add title texts, and improve tags

- Added Mastodon links to "Woofer Exploration" and "Rose's Binge"
- Add title texts to stories and games thumbnails on index, stories, games, and tag pages
- Add descriptions and related tags to tag pages
This commit is contained in:
Bad Manners 2024-07-23 17:02:49 -03:00
parent efcfce1e06
commit a713adc1ec
34 changed files with 493 additions and 239 deletions

View file

@ -22,12 +22,9 @@ const copyrightedCharacters = await formatCopyrightedCharacters(props.copyrighte
// const relatedGames = (await getEntries(props.relatedGames)).filter((game) => !game.data.isDraft);
const categorizedTags = Object.fromEntries(
(await getCollection("tag-categories")).flatMap((category) =>
category.data.tags.map((tag) => {
if (typeof tag === "string") {
return [tag, tag];
}
return [t(DEFAULT_LANG, tag as any), t(props.lang, tag as any)];
}),
category.data.tags.map<[string, string]>(({ name }) =>
typeof name === "string" ? [name, name] : [t(DEFAULT_LANG, name as any), t(props.lang, name as any)],
),
),
);
const tags = props.tags.map<[string, string]>((tag) => {

View file

@ -34,12 +34,9 @@ const relatedStories = (await getEntries(props.relatedStories)).filter((story) =
// const relatedGames = (await getEntries(props.relatedGames)).filter((game) => !game.data.isDraft);
const categorizedTags = Object.fromEntries(
(await getCollection("tag-categories")).flatMap((category) =>
category.data.tags.map((tag) => {
if (typeof tag === "string") {
return [tag, tag];
}
return [t(DEFAULT_LANG, tag as any), t(props.lang, tag as any)];
}),
category.data.tags.map<[string, string]>(({ name }) =>
typeof name === "string" ? [name, name] : [t(DEFAULT_LANG, name as any), t(props.lang, name as any)],
),
),
);
const tags = props.tags.map<[string, string]>((tag) => {