diff --git a/resources/lang/en.json b/resources/lang/en.json index 877f9b5cd..c25865187 100644 --- a/resources/lang/en.json +++ b/resources/lang/en.json @@ -1120,7 +1120,8 @@ "legendary": "Legendary", "adfree": "ad-free for life!", "hard": "Plutonium", - "soft": "Caps" + "soft": "Caps", + "free": "+{numFree} BONUS!" }, "flag_input": { "title": "Select Flag", diff --git a/src/client/components/CosmeticButton.ts b/src/client/components/CosmeticButton.ts index 8799aaef8..33467c0cc 100644 --- a/src/client/components/CosmeticButton.ts +++ b/src/client/components/CosmeticButton.ts @@ -79,7 +79,7 @@ export class CosmeticButton extends LitElement { const colorClass = isHard ? "text-green-400" : "text-amber-700"; const currencyKey = isHard ? "cosmetics.hard" : "cosmetics.soft"; return html`
${icon} ${translateText(currencyKey)} + ${pack.bonusAmount > 0 + ? html`
+ ${translateText("cosmetics.free", { + numFree: pack.bonusAmount.toLocaleString(), + })} +
` + : nothing}
`; } diff --git a/src/client/components/DesktopNavBar.ts b/src/client/components/DesktopNavBar.ts index 7b149df94..5786c8057 100644 --- a/src/client/components/DesktopNavBar.ts +++ b/src/client/components/DesktopNavBar.ts @@ -124,7 +124,7 @@ export class DesktopNavBar extends LitElement { data-i18n="main.leaderboard" > diff --git a/src/client/components/MobileNavBar.ts b/src/client/components/MobileNavBar.ts index deb0a034f..5726043d1 100644 --- a/src/client/components/MobileNavBar.ts +++ b/src/client/components/MobileNavBar.ts @@ -115,7 +115,7 @@ export class MobileNavBar extends LitElement { data-i18n="main.leaderboard" > diff --git a/src/core/CosmeticSchemas.ts b/src/core/CosmeticSchemas.ts index ae6196294..031a1d9ca 100644 --- a/src/core/CosmeticSchemas.ts +++ b/src/core/CosmeticSchemas.ts @@ -83,6 +83,7 @@ export const PackSchema = CosmeticSchema.extend({ displayName: z.string(), currency: z.enum(["hard", "soft"]), amount: z.number().int().positive(), + bonusAmount: z.number().int().nonnegative(), }); // Schema for resources/cosmetics/cosmetics.json