Refactor tmdbImageUrl to accept semantic category instead of size string

- Change primary argument from TMDB size string (`w500`, `w1280`, etc.)
  to category name (`posters`, `backdrops`, `stills`, `logos`,
  `profiles`); optional size override remains as third argument
- Update all call sites across services, actions, pages, and route
  handlers to use the new category-based API
- Update image.test.ts to match the new signature and replace
  size-mapping test descriptions with category-name descriptions
This commit is contained in:
2026-03-08 12:33:07 -04:00
parent a7b3600d15
commit ad8ec62317
14 changed files with 77 additions and 68 deletions
+1 -1
View File
@@ -23,7 +23,7 @@ const posterPaths = [
];
const posterUrls = posterPaths
.map((p) => tmdbImageUrl(p, "w300"))
.map((p) => tmdbImageUrl(p, "posters", "w300"))
.filter(Boolean) as string[];
export default function Home() {