fix: 修复导航栏内主题按钮对齐问题
- 添加 .quick-nav .theme-toggle 样式,设置 position: static - 让主题按钮跟随导航栏 flex 布局,与其他按钮对齐 - 删除重复的样式定义 - 更新 CSS 版本号
This commit is contained in:
@@ -255,7 +255,7 @@ h1 {
|
||||
}
|
||||
}
|
||||
|
||||
/* 主题切换按钮 - 独立版本(body直接子元素) */
|
||||
/* 主题切换按钮 - 独立版本 */
|
||||
.theme-toggle {
|
||||
position: fixed;
|
||||
top: 20px;
|
||||
@@ -289,34 +289,12 @@ h1 {
|
||||
transform: scale(0.95);
|
||||
}
|
||||
|
||||
/* 主题切换按钮 - 集成到导航栏 */
|
||||
/* 主题切换按钮 - 在导航栏内 */
|
||||
.quick-nav .theme-toggle {
|
||||
position: static;
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
border-radius: 50%;
|
||||
border: none;
|
||||
background: linear-gradient(135deg, var(--bg-gradient-start) 0%, var(--bg-gradient-end) 100%);
|
||||
color: white;
|
||||
font-size: 20px;
|
||||
cursor: pointer;
|
||||
transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
|
||||
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
touch-action: manipulation;
|
||||
-webkit-tap-highlight-color: transparent;
|
||||
-webkit-touch-callout: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.quick-nav .theme-toggle:hover {
|
||||
transform: rotate(20deg) scale(1.1);
|
||||
box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
|
||||
}
|
||||
|
||||
.quick-nav .theme-toggle:active {
|
||||
transform: scale(0.95);
|
||||
}
|
||||
|
||||
/* 表单样式 */
|
||||
|
||||
Reference in New Issue
Block a user