From 40eb317cd94701cd82c7bbfb314e420ad5d3f173 Mon Sep 17 00:00:00 2001 From: suguowen <413162826@qq.com> Date: Fri, 31 Jul 2026 18:09:33 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E4=BB=8A=E6=97=A5=E4=B8=8A?= =?UTF-8?q?=E6=96=B0=E6=A0=87=E8=AE=B0=E5=92=8C=E4=B8=BB=E9=A2=98=E6=A8=A1?= =?UTF-8?q?=E6=8B=9F=E9=A2=84=E8=A7=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- web/app/codex-preview.tsx | 20 +++-- web/app/featured-theme-switcher.tsx | 6 +- web/app/globals.css | 70 ++++++++++++++++- web/app/theme-gallery.tsx | 56 ++++++++++--- web/app/theme-preview-dialog.tsx | 117 ++++++++++++++++++++++++++++ web/lib/theme-catalog.ts | 1 + web/lib/theme-recency.ts | 11 +++ web/lib/uploaded-themes.ts | 11 ++- web/tests/rendered-html.test.mjs | 25 +++++- web/tests/theme-recency.test.mjs | 23 ++++++ 10 files changed, 316 insertions(+), 24 deletions(-) create mode 100644 web/app/theme-preview-dialog.tsx create mode 100644 web/lib/theme-recency.ts create mode 100644 web/tests/theme-recency.test.mjs diff --git a/web/app/codex-preview.tsx b/web/app/codex-preview.tsx index 344d1fe..5710093 100644 --- a/web/app/codex-preview.tsx +++ b/web/app/codex-preview.tsx @@ -5,10 +5,18 @@ export type PreviewTheme = { previewImage?: string; }; -export function StandardCodexPreview({ theme }: { theme: PreviewTheme }) { +export function StandardCodexPreview({ + theme, + className = "", + productLabel = "主题", +}: { + theme: PreviewTheme; + className?: string; + productLabel?: string; +}) { return ( -