From b5b4499d274a80fe10ccbcdb44126210fd948115 Mon Sep 17 00:00:00 2001 From: Sam Becker Date: Thu, 14 Sep 2023 17:32:56 -0500 Subject: [PATCH] Remove hyphens from tag titles --- src/tag/PhotoTag.tsx | 2 +- src/tag/index.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tag/PhotoTag.tsx b/src/tag/PhotoTag.tsx index 70197185..36fc7b8b 100644 --- a/src/tag/PhotoTag.tsx +++ b/src/tag/PhotoTag.tsx @@ -14,7 +14,7 @@ export default function PhotoTag({ className="flex items-center gap-x-1.5" > - {tag} + {tag.replaceAll('-', ' ')} ); } diff --git a/src/tag/index.ts b/src/tag/index.ts index 5e75071b..f8dc9900 100644 --- a/src/tag/index.ts +++ b/src/tag/index.ts @@ -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'}`;