From 0e4412c99b3e7c702d2b0303ce7c1310d8eb924c Mon Sep 17 00:00:00 2001 From: pavel444-byte Date: Thu, 15 Oct 2026 18:32:18 +0500 Subject: [PATCH] Revert profile cosmetics and GeoCoin currency --- app/cosmetics/page.tsx | 43 -- app/dashboard/page.tsx | 8 - app/layout.tsx | 1 - app/players/[id]/page.tsx | 76 ---- app/profile-cosmetics.css | 409 ------------------ app/settings/page.tsx | 1 - components/AccountSettings.tsx | 36 +- components/CosmeticsShop.tsx | 152 ------- components/Leaderboard.tsx | 16 +- components/MultiplayerGame.tsx | 1 - components/MultiplayerRoom.tsx | 2 - components/PixelArt.tsx | 66 ++- lib/account-api.ts | 5 +- lib/api.ts | 3 - lib/catalog.ts | 4 +- lib/cosmetics-api.ts | 52 --- lib/leaderboard.ts | 2 +- lib/multiplayer-appearance.ts | 2 +- lib/profile-cosmetics.ts | 15 - lib/profile.ts | 2 +- lib/public-profile.ts | 41 -- shared/account.ts | 15 +- shared/database.ts | 18 - shared/locales/ru.json | 49 --- shared/profile-appearance.ts | 3 +- shared/profile-cosmetic-ids.ts | 8 - shared/profile-cosmetics.ts | 41 -- ..._revert_profile_cosmetics_and_currency.sql | 15 + 28 files changed, 60 insertions(+), 1026 deletions(-) delete mode 100644 app/cosmetics/page.tsx delete mode 100644 app/players/[id]/page.tsx delete mode 100644 app/profile-cosmetics.css delete mode 100644 components/CosmeticsShop.tsx delete mode 100644 lib/cosmetics-api.ts delete mode 100644 lib/profile-cosmetics.ts delete mode 100644 lib/public-profile.ts delete mode 100644 shared/profile-cosmetic-ids.ts delete mode 100644 shared/profile-cosmetics.ts create mode 100644 supabase/migrations/20261015132835_revert_profile_cosmetics_and_currency.sql diff --git a/app/cosmetics/page.tsx b/app/cosmetics/page.tsx deleted file mode 100644 index 5839856..0000000 --- a/app/cosmetics/page.tsx +++ /dev/null @@ -1,43 +0,0 @@ -import Link from "next/link"; -import { redirect } from "next/navigation"; -import { ArrowLeft } from "lucide-react"; -import { CosmeticsShop } from "@/components/CosmeticsShop"; -import { Footer, Header } from "@/components/Shell"; -import { getI18n } from "@/lib/i18n"; -import { accountProfile } from "@/lib/profile"; -import { profileCosmeticsState } from "@/lib/profile-cosmetics"; -import { user } from "@/lib/supabase"; - -export const dynamic = "force-dynamic"; - -export async function generateMetadata() { - const { t } = await getI18n(); - return { title: t("Profile cosmetics") }; -} - -export default async function CosmeticsPage() { - const account = await user(); - if (!account) redirect("/log-in?next=%2Fcosmetics"); - const [profile, shop] = await Promise.all([ - accountProfile(account), - profileCosmeticsState(account.id), - ]); - const { t } = await getI18n(); - - return ( - <> -
-
- -
-