Remove hyphens from tag titles

This commit is contained in:
Sam Becker 2023-09-14 17:32:56 -05:00
parent 235d4b0b5f
commit b5b4499d27
2 changed files with 2 additions and 2 deletions

View File

@ -14,7 +14,7 @@ export default function PhotoTag({
className="flex items-center gap-x-1.5"
>
<FaTag size={11} />
<span className="uppercase">{tag}</span>
<span className="uppercase">{tag.replaceAll('-', ' ')}</span>
</Link>
);
}

View File

@ -5,7 +5,7 @@ export const pageTitleForTag = (tag: string) =>
`${capitalizeWords(tag.replaceAll('-', ' '))} Photos`;
export const ogTitleForTag = (tag: string) =>
`🏷️ ${tag.toUpperCase()}`;
`🏷️ ${tag.replaceAll('-', ' ').toUpperCase()}`;
export const descriptionForTaggedPhotos = (photos:Photo[]) =>
`${photos.length} ${photos.length === 1 ? 'photo' : 'photos'}`;