Fixed tile tag deduping order.

This commit is contained in:
2026-03-05 17:23:29 +01:00
parent f79ef53ebd
commit da6ccccab4

View File

@@ -135,7 +135,8 @@ const { user } = pageContext;
const pageStash = pageContext.pageProps.stash;
const currentStash = pageStash || pageContext.assets?.primaryStash;
const sceneTags = Object.values(Object.fromEntries(props.scene.tags.map((tag) => [tag.id, tag])));
const tagsById = Object.fromEntries(props.scene.tags.map((tag) => [tag.id, tag]));
const sceneTags = Array.from(new Set(props.scene.tags.map((tag) => tag.id))).map((tagId) => tagsById[tagId]);
const priorityTags = sceneTags.map((tag) => tag.name).slice(0, 2);
const favorited = ref(props.scene.stashes.some((sceneStash) => sceneStash.id === currentStash?.id));