From 49707ffa740a61aed210d73469cfe68f0a6811fe Mon Sep 17 00:00:00 2001 From: QLHazyCoder <2825305047@qq.com> Date: Sun, 19 Apr 2026 00:51:36 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=B7=BB=E5=8A=A0=E4=BE=A7=E8=BE=B9?= =?UTF-8?q?=E6=A0=8F=E8=B4=A1=E7=8C=AE=E6=8C=89=E9=92=AE=EF=BC=8C=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E6=89=93=E5=BC=80=E4=B8=8A=E4=BC=A0=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E9=80=BB=E8=BE=91=EF=BC=8C=E6=9B=B4=E6=96=B0=E7=9B=B8=E5=85=B3?= =?UTF-8?q?=E6=B5=8B=E8=AF=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sidepanel/sidepanel.css | 40 +++++++ sidepanel/sidepanel.html | 18 +-- sidepanel/sidepanel.js | 55 ++++++++-- tests/sidepanel-contribution-button.test.js | 15 +-- tests/sidepanel-header-links.test.js | 115 ++++++++++++++++++++ 项目完整链路说明.md | 5 +- 项目文件结构说明.md | 4 +- 7 files changed, 216 insertions(+), 36 deletions(-) create mode 100644 tests/sidepanel-header-links.test.js diff --git a/sidepanel/sidepanel.css b/sidepanel/sidepanel.css index e0961aa..d366756 100644 --- a/sidepanel/sidepanel.css +++ b/sidepanel/sidepanel.css @@ -118,6 +118,30 @@ header { .header-left svg { color: var(--blue); } +.header-icon-link { + display: flex; + align-items: center; + justify-content: center; + padding: 0; + border: none; + background: transparent; + color: inherit; + cursor: pointer; + flex-shrink: 0; + appearance: none; +} + +.header-icon-link:hover svg { + color: var(--text-primary); +} + +.header-icon-link:focus-visible, +.header-version-link:focus-visible { + outline: 2px solid color-mix(in srgb, var(--blue) 28%, transparent); + outline-offset: 2px; + border-radius: var(--radius-sm); +} + .header-version-block { min-width: 0; display: flex; @@ -144,6 +168,22 @@ header { text-overflow: ellipsis; } +.header-version-link { + display: block; + padding: 0; + border: none; + background: transparent; + font: inherit; + text-align: left; + cursor: pointer; + appearance: none; +} + +.header-version-link:hover { + text-decoration: underline; + text-underline-offset: 2px; +} + .header-version-title.is-version-label { color: var(--blue); } .header-version-title.is-update-available { color: var(--orange); } .header-version-title.is-check-failed { color: var(--text-primary); } diff --git a/sidepanel/sidepanel.html b/sidepanel/sidepanel.html index 3be2c00..4ea5003 100644 --- a/sidepanel/sidepanel.html +++ b/sidepanel/sidepanel.html @@ -16,13 +16,17 @@
- - - +
-
Pro0.0
+
@@ -30,6 +34,8 @@
+ -