From 60e2cc638284eb300ad21b5d44e6c5d2c2601f88 Mon Sep 17 00:00:00 2001 From: fylorn <249551762+fylorn@users.noreply.github.com> Date: Wed, 30 Sep 2026 18:04:05 +0800 Subject: [PATCH] Lite page: redesign the install section The section was a mostly empty left column beside a long stack of three platforms, with the Homebrew command cut off and every caveat written out. Now: a heading with the docs links, one tab per system (the visitor's own system open; all three panels show without script), the requirement in one sentence, one card per way to install (the recommended one marked, commands shown in full), and the first-launch caveat as one short note. Co-Authored-By: Claude Opus 5.5 --- src/components/pages/LitePage.astro | 395 +++++++++++++++++++--------- src/i18n/pages/lite.ts | 130 +++++---- 2 files changed, 338 insertions(+), 187 deletions(-) diff --git a/src/components/pages/LitePage.astro b/src/components/pages/LitePage.astro index 48ceb07..a8e1526 100644 --- a/src/components/pages/LitePage.astro +++ b/src/components/pages/LitePage.astro @@ -70,7 +70,6 @@ const textLink = const nodes = [c.built.lite, c.built.core, c.built.upstreams]; /** 截图外的一圈:和窗口自带的阴影配合,不再加边框 */ const shotClass = "w-full rounded-[10px]"; -const platformLabel = "m-0 font-mono text-[13px] text-[var(--color-muted)]"; const archLabel = { x64: "x64", arm64: "ARM64" } as const; --- @@ -283,129 +282,131 @@ const archLabel = { x64: "x64", arm64: "ARM64" } as const; -
-
-
-

{c.install.eyebrow}

-

{c.install.title}

-

{c.install.brewNote}

-
+
+
+
+
+

{c.install.eyebrow}

+

{c.install.title}

+

{c.install.intro}

+
+
-
-
-

{c.install.macLabel}

-
- - $ brew install --cask thinkwatchproject/tap/thinkwatch-lite - - -
-
-

{c.install.dmgTitle}

-

{c.install.dmgBody}

- {c.install.dmgDownload} - {liteVersion && dmg.sha && ( -

- {c.install.version} {liteVersion} - {" · "} - sha256 -

- )} - - {c.install.releases} - - + + {/* 一个系统一栏,默认选中访客自己的系统(见页尾脚本);没有脚本时三栏都显示 */} + + +
+
+

{c.install.mac.req}

+
+
+
+

{c.install.mac.brewTitle}

+ {c.install.recommended} +
+

{c.install.mac.brewBody}

+
+ $ brew install --cask thinkwatchproject/tap/thinkwatch-lite + +
+
+
+

{c.install.mac.dmgTitle}

+

{c.install.mac.dmgBody}

+
+ {c.install.mac.dmgDownload} + {liteVersion && ( +

+ {c.install.version} {liteVersion} + {dmg.sha && {" · "}{c.install.sha}} +

+ )} +
+
+

{c.install.mac.note}

-
-

{c.install.winLabel}

-
-

{c.install.winTitle}

-

{c.install.winBody}

-
+ +
+

{c.install.windows.req}

+
+

{c.install.windows.title}

+

{c.install.windows.body}

+
{winArchs.map((arch) => ( - ))} {winArchs.map((arch) => ( - ))}
{liteVersion && ( -

+

{c.install.version} {liteVersion} {winArchs.map((arch) => - win[arch].sha && ( - - {" · "} - - sha256 ({archLabel[arch]}) - - - ), + win[arch].sha && {" · "}{c.install.sha} ({archLabel[arch]}), )}

)} -

- {c.install.winUnsigned} -

+

{c.install.windows.note}

-
-

{c.install.linuxLabel}

-
- - $ curl -fsSL {installScript} | sh - - -
-

{c.install.linuxScript}

-
-

{c.install.linuxTitle}

-

{c.install.linuxBody}

-
- {linuxArchs.map((arch) => ( - - ))} - {linuxArchs.map((arch) => ( -
+

{c.install.linux.req}

+
+
+
+

{c.install.linux.scriptTitle}

+ {c.install.recommended} +
+

{c.install.linux.scriptBody}

+
+ $ curl -fsSL {installScript} | sh + +
+
+
+

{c.install.linux.appimageTitle}

+

{c.install.linux.appimageBody}

+
+ {liteVersion && linuxArchs.some((arch) => linux[arch].sha) && ( +

+ {c.install.version} {liteVersion} + {linuxArchs.map((arch) => + linux[arch].sha && {" · "}{c.install.sha} ({arch}), + )}

- ))} + )}
- {liteVersion && linuxArchs.some((arch) => linux[arch].sha) && ( -

- {c.install.version} {liteVersion} - {linuxArchs.map((arch) => - linux[arch].sha && ( - - {" · "} - - sha256 ({arch}) - - - ), - )} -

- )} -

- {c.install.linuxNotes} -

+

{c.install.linux.note}

@@ -432,9 +433,9 @@ const archLabel = { x64: "x64", arm64: "ARM64" } as const;