From 54c05ed02620259951ed5186472428390f2844a8 Mon Sep 17 00:00:00 2001 From: root Date: Wed, 11 Mar 2026 22:58:42 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=B7=BB=E5=8A=A0=E5=BF=AB=E6=8D=B7?= =?UTF-8?q?=E5=AF=BC=E8=88=AA=E6=8C=89=E9=92=AE=20=F0=9F=94=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 右上角添加思源笔记/Gitea/NocoDB快捷入口 - 悬浮设计,支持暗黑模式 - 移动端自适应布局 --- static/css/style.css | 132 +++++++++++++++++++++++++++++++++++++++++++ templates/index.html | 7 +++ 2 files changed, 139 insertions(+) diff --git a/static/css/style.css b/static/css/style.css index 56b717a..cbd898e 100644 --- a/static/css/style.css +++ b/static/css/style.css @@ -188,6 +188,138 @@ h1 { 50% { opacity: 0.5; } } +/* 快捷导航栏 */ +.quick-nav { + position: fixed; + top: 15px; + right: 80px; + display: flex; + gap: 10px; + z-index: 99; +} + +.nav-btn { + display: flex; + align-items: center; + gap: 6px; + padding: 8px 14px; + background: rgba(255, 255, 255, 0.9); + border: none; + border-radius: 20px; + font-size: 14px; + font-weight: 500; + color: #333; + text-decoration: none; + cursor: pointer; + transition: all 0.3s ease; + box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); + white-space: nowrap; +} + +[data-theme="dark"] .nav-btn { + background: rgba(40, 40, 60, 0.9); + color: #e0e0e0; +} + +.nav-btn:hover { + transform: translateY(-2px); + box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2); +} + +[data-theme="dark"] .nav-btn:hover { + background: rgba(60, 60, 80, 0.95); +} + +/* 移动端导航 */ +@media (max-width: 600px) { + .quick-nav { + position: absolute; + top: auto; + bottom: -60px; + right: 50%; + transform: translateX(50%); + background: rgba(255, 255, 255, 0.95); + padding: 10px 15px; + border-radius: 25px; + box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15); + } + + [data-theme="dark"] .quick-nav { + background: rgba(40, 40, 60, 0.95); + } + + .nav-btn { + padding: 6px 10px; + font-size: 12px; + } +} + +/* 快捷导航栏 */ +.quick-nav { + position: fixed; + top: 15px; + right: 80px; + display: flex; + gap: 10px; + z-index: 99; +} + +.nav-btn { + display: flex; + align-items: center; + gap: 6px; + padding: 8px 14px; + background: rgba(255, 255, 255, 0.9); + border: none; + border-radius: 20px; + font-size: 14px; + font-weight: 500; + color: #333; + text-decoration: none; + cursor: pointer; + transition: all 0.3s ease; + box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); + white-space: nowrap; +} + +[data-theme="dark"] .nav-btn { + background: rgba(40, 40, 60, 0.9); + color: #e0e0e0; +} + +.nav-btn:hover { + transform: translateY(-2px); + box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2); +} + +[data-theme="dark"] .nav-btn:hover { + background: rgba(60, 60, 80, 0.95); +} + +/* 移动端导航 */ +@media (max-width: 600px) { + .quick-nav { + position: absolute; + top: auto; + bottom: -60px; + right: 50%; + transform: translateX(50%); + background: rgba(255, 255, 255, 0.95); + padding: 10px 15px; + border-radius: 25px; + box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15); + } + + [data-theme="dark"] .quick-nav { + background: rgba(40, 40, 60, 0.95); + } + + .nav-btn { + padding: 6px 10px; + font-size: 12px; + } +} + /* 主题切换按钮 */ .theme-toggle { position: absolute; diff --git a/templates/index.html b/templates/index.html index 86da888..e880bfc 100644 --- a/templates/index.html +++ b/templates/index.html @@ -7,6 +7,13 @@ + +
+ 📝 思源 + 📦 Gitea + 📊 NocoDB +
+