From 415ae30d3b1a8d546e682e665efaf679721fa9fd Mon Sep 17 00:00:00 2001 From: syui Date: Sun, 25 Jan 2026 18:10:12 +0900 Subject: [PATCH] rm old record key --- src/web/components/card-migrate.ts | 2 +- src/web/components/card.ts | 10 ++-------- src/web/components/rse.ts | 13 ++----------- 3 files changed, 5 insertions(+), 20 deletions(-) diff --git a/src/web/components/card-migrate.ts b/src/web/components/card-migrate.ts index fcc0f24..e6042bd 100644 --- a/src/web/components/card-migrate.ts +++ b/src/web/components/card-migrate.ts @@ -192,7 +192,7 @@ export function renderMigrationPage( .sort((a, b) => a.card - b.card) const cardsHtml = sortedGroups.map(({ card, totalCp, rare, isUnique }) => { - const rarityClass = isUnique ? 'unique' : rare >= 4 ? 'shiny' : rare >= 1 ? 'rare' : '' + const rarityClass = isUnique ? 'unique' : rare >= 1 ? 'rare' : '' const effectsHtml = rarityClass ? `
diff --git a/src/web/components/card.ts b/src/web/components/card.ts index 3dfd2cb..41357a8 100644 --- a/src/web/components/card.ts +++ b/src/web/components/card.ts @@ -17,8 +17,7 @@ export interface CardCollection { // Get rarity class name function getRarityClass(card: UserCard): string { if (card.unique) return 'unique' - if (card.rare >= 4) return 'shiny' // first(5), second(4) - if (card.rare >= 1) return 'rare' // third(3), fourth(2), fifth(1) + if (card.rare >= 1) return 'rare' return '' } @@ -89,8 +88,7 @@ export function renderCardPage( // Count by rarity const rarityCount = { normal: cards.filter(c => !c.unique && c.rare === 0).length, - rare: cards.filter(c => !c.unique && c.rare >= 1 && c.rare < 4).length, - shiny: cards.filter(c => !c.unique && c.rare >= 4).length, + rare: cards.filter(c => !c.unique && c.rare >= 1).length, unique: cards.filter(c => c.unique).length, } @@ -139,10 +137,6 @@ export function renderCardPage( ${rarityCount.unique} Unique -
- ${rarityCount.shiny} - Shiny -
${rarityCount.rare} Rare diff --git a/src/web/components/rse.ts b/src/web/components/rse.ts index c9f87e2..7842816 100644 --- a/src/web/components/rse.ts +++ b/src/web/components/rse.ts @@ -4,7 +4,6 @@ export interface RseItem { id: number cp: number mode: number - shiny: boolean unique: boolean } @@ -15,10 +14,9 @@ export interface RseCollection { updatedAt: string } -// Get rarity class from shiny/unique flags +// Get rarity class from unique flag function getRarityClass(item: RseItem): string { if (item.unique) return 'unique' - if (item.shiny) return 'shiny' return '' } @@ -71,18 +69,15 @@ export function renderRsePage( const totalChars = characters.length const totalItems = items.length const uniqueChars = characters.filter(c => c.unique).length - const shinyChars = characters.filter(c => c.shiny).length - // Sort by unique > shiny > id + // Sort by unique > id const sortedChars = [...characters].sort((a, b) => { if (a.unique !== b.unique) return a.unique ? -1 : 1 - if (a.shiny !== b.shiny) return a.shiny ? -1 : 1 return a.id - b.id }) const sortedItems = [...items].sort((a, b) => { if (a.unique !== b.unique) return a.unique ? -1 : 1 - if (a.shiny !== b.shiny) return a.shiny ? -1 : 1 return a.id - b.id }) @@ -105,10 +100,6 @@ export function renderRsePage( ${uniqueChars} Unique
-
- ${shinyChars} - Shiny -