You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1110 lines
37 KiB
1110 lines
37 KiB
<!DOCTYPE html>
|
|
<html lang="zh-CN">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=375, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
|
|
<title>青核 Youthome - 设置</title>
|
|
<script src="https://cdn.tailwindcss.com"></script>
|
|
<link rel="stylesheet" href="../colors_and_type.css">
|
|
<style>
|
|
* {
|
|
margin: 0;
|
|
padding: 0;
|
|
box-sizing: border-box;
|
|
-webkit-tap-highlight-color: transparent;
|
|
}
|
|
|
|
:root {
|
|
/* Traework 设计令牌 - 圆角/间距/阴影/高度 */
|
|
--radius-xs: 4px;
|
|
--radius-sm: 8px;
|
|
--radius-md: 12px;
|
|
--radius-lg: 16px;
|
|
--radius-xl: 20px;
|
|
--radius-full: 9999px;
|
|
--height-btn: 44px;
|
|
--height-input: 44px;
|
|
--height-nav: 64px;
|
|
--space-1: 4px;
|
|
--space-2: 8px;
|
|
--space-3: 12px;
|
|
--space-4: 16px;
|
|
--space-5: 20px;
|
|
--space-6: 24px;
|
|
--shadow-card: 0 2px 12px rgba(0, 0, 0, 0.04);
|
|
--shadow-card-hover: 0 6px 20px rgba(0, 0, 0, 0.06);
|
|
--shadow-btn: 0 2px 8px rgba(38, 194, 187, 0.25);
|
|
--shadow-btn-hover: 0 4px 16px rgba(38, 194, 187, 0.35);
|
|
--shadow-modal: 0 16px 48px rgba(0, 0, 0, 0.12);
|
|
--shadow-float: 0 4px 24px rgba(0, 0, 0, 0.08);
|
|
--shadow-inset: inset 0 1px 3px rgba(0, 0, 0, 0.03);
|
|
--glass-bg: rgba(255, 255, 255, 0.72);
|
|
--glass-blur: blur(20px);
|
|
--glass-border: rgba(255, 255, 255, 0.3);
|
|
|
|
}
|
|
|
|
html, body {
|
|
font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'SF Pro Display', 'Helvetica Neue', 'Segoe UI', Roboto, sans-serif;
|
|
background: var(--youth-bg-page);
|
|
color: var(--youth-text-primary);
|
|
min-height: 100vh;
|
|
overflow-x: hidden;
|
|
}
|
|
|
|
.app-container {
|
|
width: 375px;
|
|
height: 812px;
|
|
margin: 0 auto;
|
|
background: var(--youth-bg-page);
|
|
position: relative;
|
|
overflow: hidden;
|
|
display: flex;
|
|
flex-direction: column;
|
|
}
|
|
|
|
/* ===== 状态栏 ===== */
|
|
.status-bar {
|
|
height: 36px;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
padding: 0 20px;
|
|
font-size: 14px;
|
|
font-weight: 600;
|
|
color: var(--youth-text-primary);
|
|
position: relative;
|
|
z-index: 10;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.status-bar .right-icons {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 6px;
|
|
}
|
|
|
|
.status-bar svg {
|
|
width: 16px;
|
|
height: 16px;
|
|
}
|
|
|
|
/* ===== 导航栏 ===== */
|
|
.nav-bar {
|
|
height: 64px;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
padding: 0 16px;
|
|
position: relative;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.nav-btn {
|
|
width: 34px;
|
|
height: 34px;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
border-radius: var(--youth-radius-lg);
|
|
background: var(--youth-gradient-matte-card);
|
|
border: 1px solid var(--youth-border-light);
|
|
box-shadow:
|
|
0 2px 8px rgba(0, 0, 0, 0.06),
|
|
inset 0 1px 0 rgba(255, 255, 255, 0.8);
|
|
cursor: pointer;
|
|
transition: all 0.2s ease;
|
|
color: var(--youth-text-primary);
|
|
position: absolute;
|
|
left: 16px;
|
|
top: 50%;
|
|
transform: translateY(-50%);
|
|
}
|
|
|
|
.nav-btn:active {
|
|
transform: translateY(-50%) scale(0.95);
|
|
box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.08);
|
|
}
|
|
|
|
.nav-title {
|
|
font-size: 17px;
|
|
font-weight: 600;
|
|
color: var(--youth-text-primary);
|
|
letter-spacing: -0.01em;
|
|
}
|
|
|
|
/* ===== 内容滚动区 ===== */
|
|
.content-scroll {
|
|
flex: 1;
|
|
overflow-y: auto;
|
|
overflow-x: hidden;
|
|
padding-bottom: 12px;
|
|
}
|
|
|
|
.content-scroll::-webkit-scrollbar {
|
|
width: 0;
|
|
}
|
|
|
|
/* ===== 设置分组标题 ===== */
|
|
.group-title {
|
|
font-size: 12px;
|
|
font-weight: 500;
|
|
color: var(--youth-text-tertiary);
|
|
padding: 14px 20px 6px;
|
|
letter-spacing: 0.02em;
|
|
}
|
|
|
|
/* ===== 设置分组卡片 ===== */
|
|
.settings-group {
|
|
margin: 0 16px;
|
|
background: var(--youth-bg-card);
|
|
border-radius: 16px;
|
|
overflow: hidden;
|
|
box-shadow:
|
|
0 2px 12px rgba(0, 0, 0, 0.04),
|
|
inset 0 1px 0 rgba(255, 255, 255, 0.6);
|
|
border: 1px solid var(--youth-border-light);
|
|
position: relative;
|
|
}
|
|
|
|
.settings-group::before {
|
|
content: '';
|
|
position: absolute;
|
|
top: 0;
|
|
left: 0;
|
|
right: 0;
|
|
height: 1px;
|
|
background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.5) 50%, transparent 100%);
|
|
pointer-events: none;
|
|
}
|
|
|
|
.settings-item {
|
|
display: flex;
|
|
align-items: center;
|
|
padding: 13px 16px;
|
|
cursor: pointer;
|
|
|
|
position: relative;
|
|
}
|
|
|
|
.settings-item:active {
|
|
background-color: var(--youth-bg-hover);
|
|
}
|
|
|
|
.settings-item:not(:last-child)::after {
|
|
content: '';
|
|
position: absolute;
|
|
bottom: 0;
|
|
left: 52px;
|
|
right: 16px;
|
|
height: 1px;
|
|
background: var(--youth-border-light);
|
|
}
|
|
|
|
.settings-icon {
|
|
width: 30px;
|
|
height: 30px;
|
|
border-radius: var(--youth-radius-md);
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
margin-right: 12px;
|
|
flex-shrink: 0;
|
|
box-shadow:
|
|
0 2px 6px rgba(0, 0, 0, 0.08),
|
|
inset 0 1px 0 rgba(255, 255, 255, 0.5);
|
|
}
|
|
|
|
.settings-icon svg {
|
|
width: 16px;
|
|
height: 16px;
|
|
}
|
|
|
|
.settings-label {
|
|
flex: 1;
|
|
font-size: 14px;
|
|
font-weight: 500;
|
|
color: var(--youth-text-primary);
|
|
}
|
|
|
|
.settings-right {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 6px;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.settings-value {
|
|
font-size: 13px;
|
|
color: var(--youth-text-tertiary);
|
|
}
|
|
|
|
.settings-arrow {
|
|
color: var(--youth-text-quaternary);
|
|
}
|
|
|
|
.settings-arrow svg {
|
|
width: 16px;
|
|
height: 16px;
|
|
}
|
|
|
|
/* ===== 状态标签 ===== */
|
|
.status-tag {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
padding: 3px 10px;
|
|
border-radius: var(--youth-radius-full);
|
|
font-size: 11px;
|
|
font-weight: 600;
|
|
position: relative;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.status-tag::before {
|
|
content: '';
|
|
position: absolute;
|
|
top: 0;
|
|
left: 0;
|
|
right: 0;
|
|
height: 50%;
|
|
background: linear-gradient(180deg, rgba(255,255,255,0.25) 0%, transparent 100%);
|
|
pointer-events: none;
|
|
}
|
|
|
|
.status-tag span {
|
|
position: relative;
|
|
z-index: 1;
|
|
}
|
|
|
|
.status-tag.green {
|
|
background: linear-gradient(135deg, #67E188 0%, #34C759 100%);
|
|
color: white;
|
|
box-shadow: 0 2px 6px rgba(52, 199, 89, 0.3);
|
|
}
|
|
|
|
.status-tag.teal {
|
|
background: linear-gradient(135deg, #54CAC5 0%, #26C2BB 100%);
|
|
color: white;
|
|
box-shadow: 0 2px 6px rgba(38, 194, 187, 0.3);
|
|
}
|
|
|
|
.status-tag.gray {
|
|
background: var(--youth-bg-input);
|
|
color: var(--youth-text-secondary);
|
|
border: 1px solid var(--youth-border-light);
|
|
}
|
|
|
|
/* ===== 立体开关 ===== */
|
|
.toggle-switch {
|
|
width: 46px;
|
|
height: 26px;
|
|
border-radius: 13px;
|
|
background: var(--youth-gray-300);
|
|
position: relative;
|
|
cursor: pointer;
|
|
|
|
box-shadow:
|
|
inset 0 2px 4px rgba(0, 0, 0, 0.12),
|
|
inset 0 1px 2px rgba(0, 0, 0, 0.08);
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.toggle-switch.active {
|
|
background: linear-gradient(135deg, #54CAC5 0%, #26C2BB 100%);
|
|
box-shadow:
|
|
inset 0 2px 4px rgba(0, 0, 0, 0.1),
|
|
0 2px 8px rgba(38, 194, 187, 0.35);
|
|
}
|
|
|
|
.toggle-thumb {
|
|
position: absolute;
|
|
top: 2px;
|
|
left: 2px;
|
|
width: 22px;
|
|
height: 22px;
|
|
border-radius: 50%;
|
|
background: linear-gradient(135deg, #FFFFFF 0%, #F0F0F0 100%);
|
|
box-shadow:
|
|
0 2px 6px rgba(0, 0, 0, 0.15),
|
|
0 1px 2px rgba(0, 0, 0, 0.1),
|
|
inset 0 1px 0 rgba(255, 255, 255, 0.9);
|
|
transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
|
}
|
|
|
|
.toggle-switch.active .toggle-thumb {
|
|
transform: translateX(20px);
|
|
background: linear-gradient(135deg, #FFFFFF 0%, #F5F5F5 100%);
|
|
box-shadow:
|
|
0 2px 8px rgba(0, 0, 0, 0.2),
|
|
0 1px 3px rgba(0, 0, 0, 0.12),
|
|
inset 0 1px 0 rgba(255, 255, 255, 1);
|
|
}
|
|
|
|
/* ===== 底部操作区 ===== */
|
|
.bottom-actions {
|
|
padding: 20px 16px 10px;
|
|
background: var(--youth-bg-page);
|
|
}
|
|
|
|
.logout-btn {
|
|
width: 100%;
|
|
height: 44px;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
border-radius: var(--youth-radius-xl);
|
|
font-size: 15px;
|
|
font-weight: 500;
|
|
cursor: pointer;
|
|
transition: all 0.2s ease;
|
|
font-family: inherit;
|
|
color: #E57878;
|
|
background: var(--youth-gradient-matte-card);
|
|
border: 1px solid var(--youth-border-light);
|
|
box-shadow:
|
|
0 2px 8px rgba(0, 0, 0, 0.04),
|
|
inset 0 1px 0 rgba(255, 255, 255, 0.8);
|
|
}
|
|
|
|
.logout-btn:active {
|
|
transform: scale(0.98);
|
|
background: var(--youth-bg-hover);
|
|
}
|
|
|
|
/* ===== 底部安全区域 ===== */
|
|
.safe-area-bottom {
|
|
height: 20px;
|
|
background: var(--youth-bg-page);
|
|
}
|
|
|
|
/* ===== 弹窗 ===== */
|
|
.modal-overlay {
|
|
position: fixed;
|
|
top: 0;
|
|
left: 0;
|
|
right: 0;
|
|
bottom: 0;
|
|
width: 100%;
|
|
height: 100%;
|
|
background: rgba(0, 0, 0, 0.45);
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
z-index: 998;
|
|
opacity: 0;
|
|
visibility: hidden;
|
|
transition: all 0.3s ease;
|
|
}
|
|
|
|
.modal-overlay.show {
|
|
opacity: 1;
|
|
visibility: visible;
|
|
}
|
|
|
|
.modal-dialog {
|
|
width: 280px;
|
|
background: var(--youth-bg-card);
|
|
border-radius: 20px;
|
|
padding: 20px 20px 16px;
|
|
box-shadow: 0 16px 48px rgba(0, 0, 0, 0.12);
|
|
transform: scale(0.9);
|
|
transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
|
z-index: 999;
|
|
position: fixed;
|
|
top: 50%;
|
|
left: 50%;
|
|
transform: translate(-50%, -50%) scale(0.9);
|
|
}
|
|
|
|
.modal-overlay.show .modal-dialog {
|
|
transform: translate(-50%, -50%) scale(1);
|
|
}
|
|
|
|
.modal-title {
|
|
font-size: 17px;
|
|
font-weight: 700;
|
|
color: var(--youth-text-primary);
|
|
text-align: center;
|
|
margin-bottom: 6px;
|
|
}
|
|
|
|
.modal-message {
|
|
font-size: 13px;
|
|
color: var(--youth-text-secondary);
|
|
text-align: center;
|
|
margin-bottom: 18px;
|
|
line-height: 1.5;
|
|
}
|
|
|
|
.modal-actions {
|
|
display: flex;
|
|
gap: 10px;
|
|
}
|
|
|
|
.modal-btn {
|
|
flex: 1;
|
|
height: 42px;
|
|
border-radius: var(--youth-radius-xl);
|
|
font-size: 14px;
|
|
font-weight: 600;
|
|
cursor: pointer;
|
|
font-family: inherit;
|
|
transition: all 0.2s ease;
|
|
position: relative;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.modal-btn:active {
|
|
transform: scale(0.97);
|
|
}
|
|
|
|
.modal-btn.danger {
|
|
background: linear-gradient(135deg, #FF8A8A 0%, #FF6B6B 100%);
|
|
color: white;
|
|
box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
|
|
}
|
|
|
|
.modal-btn.danger::before {
|
|
content: '';
|
|
position: absolute;
|
|
top: 0;
|
|
left: 0;
|
|
right: 0;
|
|
height: 50%;
|
|
background: linear-gradient(180deg, rgba(255,255,255,0.2) 0%, transparent 100%);
|
|
pointer-events: none;
|
|
}
|
|
|
|
.modal-btn.cancel {
|
|
background: var(--youth-bg-input);
|
|
color: var(--youth-text-secondary);
|
|
border: 1px solid var(--youth-border-light);
|
|
}
|
|
|
|
.modal-btn.primary {
|
|
background: linear-gradient(135deg, #54CAC5 0%, #26C2BB 100%);
|
|
color: white;
|
|
box-shadow: 0 4px 12px rgba(38, 194, 187, 0.3);
|
|
}
|
|
|
|
.modal-btn.primary::before {
|
|
content: '';
|
|
position: absolute;
|
|
top: 0;
|
|
left: 0;
|
|
right: 0;
|
|
height: 50%;
|
|
background: linear-gradient(180deg, rgba(255,255,255,0.2) 0%, transparent 100%);
|
|
pointer-events: none;
|
|
}
|
|
|
|
/* ===== Toast ===== */
|
|
.toast {
|
|
position: fixed;
|
|
top: 100px;
|
|
left: 50%;
|
|
transform: translateX(-50%) translateY(-20px);
|
|
padding: 10px 20px;
|
|
background: rgba(26, 26, 26, 0.9);
|
|
color: white;
|
|
border-radius: var(--youth-radius-full);
|
|
font-size: 14px;
|
|
font-weight: 500;
|
|
z-index: 200;
|
|
opacity: 0;
|
|
visibility: hidden;
|
|
transition: all 0.3s ease;
|
|
backdrop-filter: blur(10px);
|
|
}
|
|
|
|
.toast.show {
|
|
opacity: 1;
|
|
visibility: visible;
|
|
transform: translateX(-50%) translateY(0);
|
|
}
|
|
|
|
/* ===== 设置图标背景色 ===== */
|
|
.icon-bg-lock {
|
|
background: linear-gradient(135deg, #E5F7FF 0%, #CCEFF9 100%);
|
|
color: #5A9FD4;
|
|
}
|
|
.icon-bg-id {
|
|
background: linear-gradient(135deg, #E5FFF0 0%, #CCFFDE 100%);
|
|
color: #53B972;
|
|
}
|
|
.icon-bg-grad {
|
|
background: linear-gradient(135deg, #E5F7F6 0%, #CCEFEA 100%);
|
|
color: #26C2BB;
|
|
}
|
|
.icon-bg-key {
|
|
background: linear-gradient(135deg, #FFF5E5 0%, #FFE9CC 100%);
|
|
color: #E5A253;
|
|
}
|
|
.icon-bg-bell {
|
|
background: linear-gradient(135deg, #FFE5F0 0%, #FFCCE0 100%);
|
|
color: #E55395;
|
|
}
|
|
.icon-bg-shield {
|
|
background: linear-gradient(135deg, #F0EEFF 0%, #DED9FF 100%);
|
|
color: #7B61FF;
|
|
}
|
|
.icon-bg-ban {
|
|
background: linear-gradient(135deg, #FFE5E5 0%, #FFCCCC 100%);
|
|
color: #E57878;
|
|
}
|
|
.icon-bg-eye {
|
|
background: linear-gradient(135deg, #E5FFF8 0%, #CCFFF0 100%);
|
|
color: #34C7A0;
|
|
}
|
|
.icon-bg-moon {
|
|
background: linear-gradient(135deg, #E8E5FF 0%, #D4CCFF 100%);
|
|
color: #8B77FF;
|
|
}
|
|
.icon-bg-font {
|
|
background: linear-gradient(135deg, #FFF0E5 0%, #FFE0CC 100%);
|
|
color: #E58A53;
|
|
}
|
|
.icon-bg-lang {
|
|
background: linear-gradient(135deg, #E5F0FF 0%, #CCE0FF 100%);
|
|
color: #5385E5;
|
|
}
|
|
.icon-bg-trash {
|
|
background: linear-gradient(135deg, #FFE8E5 0%, #FFD4CC 100%);
|
|
color: #E58A78;
|
|
}
|
|
.icon-bg-info {
|
|
background: linear-gradient(135deg, #E5F7FF 0%, #CCEFF9 100%);
|
|
color: #53A8E5;
|
|
}
|
|
.icon-bg-help {
|
|
background: linear-gradient(135deg, #FFFBE5 0%, #FFF6CC 100%);
|
|
color: #E5C553;
|
|
}
|
|
.icon-bg-doc {
|
|
background: linear-gradient(135deg, #F0FFE5 0%, #E0FFCC 100%);
|
|
color: #8BC753;
|
|
}
|
|
/* 响应式 */
|
|
@media (max-width: 375px) {
|
|
.app-container { width: 100%; height: 100vh; }
|
|
}
|
|
|
|
/* SVG 图标统一尺寸 */
|
|
.icon-svg {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
width: 1em;
|
|
height: 1em;
|
|
vertical-align: middle;
|
|
line-height: 1;
|
|
}
|
|
.icon-svg svg {
|
|
width: 100%;
|
|
height: 100%;
|
|
stroke: currentColor;
|
|
}
|
|
/* 侧栏图标 */
|
|
.sidebar-icon .icon-svg { width: 22px; height: 22px; font-size: 22px; }
|
|
/* 社团logo图标 */
|
|
.club-logo .icon-svg { width: 28px; height: 28px; font-size: 28px; color: #fff; }
|
|
/* 头图大图标 */
|
|
.hero-icon .icon-svg { width: 56px; height: 56px; font-size: 56px; opacity: 0.3; }
|
|
/* meta 小图标 */
|
|
.club-meta .icon-svg { width: 12px; height: 12px; font-size: 12px; }
|
|
/* 分类选择网格图标 */
|
|
.cat-option .icon-svg { width: 26px; height: 26px; font-size: 26px; }
|
|
/* logo预览图标 */
|
|
.logo-preview .icon-svg { width: 40px; height: 40px; font-size: 40px; color: #fff; }
|
|
/* 提示图标 */
|
|
.notice-icon .icon-svg { width: 18px; height: 18px; font-size: 18px; }
|
|
|
|
|
|
/* Hide scrollbar */
|
|
::-webkit-scrollbar { display: none; width: 0; height: 0; }
|
|
* { -ms-overflow-style: none; scrollbar-width: none; }
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<div class="app-container" style="height: 1195px;">
|
|
|
|
<!-- 状态栏 -->
|
|
<div class="status-bar">
|
|
<span>9:41</span>
|
|
<div class="right-icons">
|
|
<svg viewBox="0 0 24 24" fill="currentColor">
|
|
<path d="M1 9l2 2c4.97-4.97 13.03-4.97 18 0l2-2C16.93 2.93 7.08 2.93 1 9zm8 8l3 3 3-3c-1.65-1.66-4.34-1.66-6 0zm-4-4l2 2c2.76-2.76 7.24-2.76 10 0l2-2C15.14 9.14 8.87 9.14 5 13z"></path>
|
|
</svg>
|
|
<svg viewBox="0 0 24 24" fill="currentColor">
|
|
<path d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4z"></path>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- 导航栏 -->
|
|
<div class="nav-bar">
|
|
<button class="nav-btn" data-dom-id="btn-back" onclick="goBack()">
|
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="15 18 9 12 15 6"></polyline>
|
|
</svg>
|
|
</button>
|
|
<span class="nav-title">设置</span>
|
|
</div>
|
|
|
|
<!-- 内容滚动区 -->
|
|
<div class="content-scroll">
|
|
|
|
<!-- 第一组:账号安全 -->
|
|
<div class="group-title">账号安全</div>
|
|
<div class="settings-group">
|
|
<div class="settings-item" data-dom-id="item-account-security" onclick="navigateTo('item-account-security')">
|
|
<div class="settings-icon icon-bg-lock">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<rect x="3" y="11" width="18" height="11" rx="2" ry="2"></rect>
|
|
<path d="M7 11V7a5 5 0 0 1 10 0v4"></path>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">账号与安全</span>
|
|
<div class="settings-right">
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="settings-item" data-dom-id="item-realname-auth" onclick="navigateTo('item-realname-auth')">
|
|
<div class="settings-icon icon-bg-id">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<path d="M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2"></path>
|
|
<circle cx="12" cy="7" r="4"></circle>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">实名认证</span>
|
|
<div class="settings-right">
|
|
<div class="status-tag green">
|
|
<span>已认证</span>
|
|
</div>
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="settings-item" data-dom-id="item-student-auth" onclick="navigateTo('item-student-auth')">
|
|
<div class="settings-icon icon-bg-grad">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<path d="M22 10v6M2 10l10-5 10 5-10 5z"></path>
|
|
<path d="M6 12v5c3 3 9 3 12 0v-5"></path>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">学生认证</span>
|
|
<div class="settings-right">
|
|
<div class="status-tag teal">
|
|
<span>已通过</span>
|
|
</div>
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="settings-item" data-dom-id="item-change-password" onclick="navigateTo('item-change-password')">
|
|
<div class="settings-icon icon-bg-key">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<path d="M21 2l-2 2m-7.61 7.61a5.5 5.5 0 1 1-7.778 7.778 5.5 5.5 0 0 1 7.777-7.777zm0 0L15.5 7.5m0 0l3 3L22 7l-3-3m-3.5 3.5L19 4"></path>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">修改密码</span>
|
|
<div class="settings-right">
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- 第二组:通知与隐私 -->
|
|
<div class="group-title">通知与隐私</div>
|
|
<div class="settings-group">
|
|
<div class="settings-item" onclick="toggleSwitch('switch-notification')">
|
|
<div class="settings-icon icon-bg-bell">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<path d="M18 8A6 6 0 0 0 6 8c0 7-3 9-3 9h18s-3-2-3-9"></path>
|
|
<path d="M13.73 21a2 2 0 0 1-3.46 0"></path>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">消息通知</span>
|
|
<div class="settings-right">
|
|
<div class="toggle-switch active" data-dom-id="switch-notification" onclick="event.stopPropagation(); toggleSwitch('switch-notification')">
|
|
<div class="toggle-thumb"></div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="settings-item" data-dom-id="item-privacy" onclick="navigateTo('item-privacy')">
|
|
<div class="settings-icon icon-bg-shield">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<path d="M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z"></path>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">隐私设置</span>
|
|
<div class="settings-right">
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="settings-item" data-dom-id="item-blacklist" onclick="navigateTo('item-blacklist')">
|
|
<div class="settings-icon icon-bg-ban">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<circle cx="12" cy="12" r="10"></circle>
|
|
<line x1="4.93" y1="4.93" x2="19.07" y2="19.07"></line>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">黑名单管理</span>
|
|
<div class="settings-right">
|
|
<span class="settings-value">3人</span>
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="settings-item" data-dom-id="item-block-posts" onclick="navigateTo('item-block-posts')">
|
|
<div class="settings-icon icon-bg-eye">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<path d="M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19m-6.72-1.07a3 3 0 1 1-4.24-4.24"></path>
|
|
<line x1="1" y1="1" x2="23" y2="23"></line>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">不看他的动态</span>
|
|
<div class="settings-right">
|
|
<span class="settings-value">5人</span>
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- 第三组:通用设置 -->
|
|
<div class="group-title">通用设置</div>
|
|
<div class="settings-group">
|
|
<div class="settings-item" data-dom-id="item-font-size" onclick="navigateTo('item-font-size')">
|
|
<div class="settings-icon icon-bg-font">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="4 7 4 4 20 4 20 7"></polyline>
|
|
<line x1="9" y1="20" x2="15" y2="20"></line>
|
|
<line x1="12" y1="4" x2="12" y2="20"></line>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">字体大小</span>
|
|
<div class="settings-right">
|
|
<span class="settings-value">标准</span>
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="settings-item" data-dom-id="item-language" onclick="navigateTo('item-language')">
|
|
<div class="settings-icon icon-bg-lang">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<circle cx="12" cy="12" r="10"></circle>
|
|
<line x1="2" y1="12" x2="22" y2="12"></line>
|
|
<path d="M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z"></path>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">语言设置</span>
|
|
<div class="settings-right">
|
|
<span class="settings-value">简体中文</span>
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="settings-item" data-dom-id="item-clear-cache" onclick="openClearCacheModal()">
|
|
<div class="settings-icon icon-bg-trash">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="3 6 5 6 21 6"></polyline>
|
|
<path d="M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6m3 0V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2"></path>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">清理缓存</span>
|
|
<div class="settings-right">
|
|
<span class="settings-value" id="cache-size">23.6MB</span>
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- 第四组:关于与帮助 -->
|
|
<div class="group-title">关于与帮助</div>
|
|
<div class="settings-group">
|
|
<div class="settings-item" data-dom-id="item-about" onclick="navigateTo('item-about')">
|
|
<div class="settings-icon icon-bg-info">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<circle cx="12" cy="12" r="10"></circle>
|
|
<line x1="12" y1="16" x2="12" y2="12"></line>
|
|
<line x1="12" y1="8" x2="12.01" y2="8"></line>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">关于青核</span>
|
|
<div class="settings-right">
|
|
<span class="settings-value">v2.1.0</span>
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="settings-item" data-dom-id="item-help" onclick="navigateTo('item-help')">
|
|
<div class="settings-icon icon-bg-help">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<circle cx="12" cy="12" r="10"></circle>
|
|
<path d="M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3"></path>
|
|
<line x1="12" y1="17" x2="12.01" y2="17"></line>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">帮助与反馈</span>
|
|
<div class="settings-right">
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="settings-item" data-dom-id="item-user-agreement" onclick="navigateTo('item-user-agreement')">
|
|
<div class="settings-icon icon-bg-doc">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"></path>
|
|
<polyline points="14 2 14 8 20 8"></polyline>
|
|
<line x1="16" y1="13" x2="8" y2="13"></line>
|
|
<line x1="16" y1="17" x2="8" y2="17"></line>
|
|
<polyline points="10 9 9 9 8 9"></polyline>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">用户协议</span>
|
|
<div class="settings-right">
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="settings-item" data-dom-id="item-privacy-policy" onclick="navigateTo('item-privacy-policy')">
|
|
<div class="settings-icon icon-bg-shield">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<path d="M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z"></path>
|
|
</svg>
|
|
</div>
|
|
<span class="settings-label">隐私政策</span>
|
|
<div class="settings-right">
|
|
<div class="settings-arrow">
|
|
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
<polyline points="9 18 15 12 9 6"></polyline>
|
|
</svg>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- 底部操作区 -->
|
|
<div class="bottom-actions">
|
|
<button class="logout-btn" data-dom-id="btn-logout" onclick="openLogoutModal()">
|
|
退出登录
|
|
</button>
|
|
</div>
|
|
|
|
<!-- 底部安全区域 -->
|
|
<div class="safe-area-bottom"></div>
|
|
</div>
|
|
|
|
|
|
|
|
<!-- 清理缓存确认弹窗 -->
|
|
<div class="modal-overlay" id="clear-cache-modal" onclick="closeModalOutside(event, 'clear-cache-modal')">
|
|
<div class="modal-dialog">
|
|
<div class="modal-title">清理缓存</div>
|
|
<div class="modal-message">确定要清理 23.6MB 缓存吗?<br>清理后不会影响使用</div>
|
|
<div class="modal-actions">
|
|
<button class="modal-btn cancel" onclick="closeClearCacheModal()">取消</button>
|
|
<button class="modal-btn primary" onclick="confirmClearCache()">确认清理</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- 退出登录确认弹窗 -->
|
|
<div class="modal-overlay" id="logout-modal" onclick="closeModalOutside(event, 'logout-modal')">
|
|
<div class="modal-dialog">
|
|
<div class="modal-title">退出登录</div>
|
|
<div class="modal-message">确定要退出当前账号吗?</div>
|
|
<div class="modal-actions">
|
|
<button class="modal-btn cancel" onclick="closeLogoutModal()">取消</button>
|
|
<button class="modal-btn danger" onclick="confirmLogout()">退出登录</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Toast 提示 -->
|
|
<div class="toast" id="toast"></div>
|
|
|
|
<script>// ===== 返回按钮 =====
|
|
function goBack() {
|
|
window.location.href = 'profile-home.html';
|
|
}
|
|
|
|
// ===== 开关切换 =====
|
|
function toggleSwitch(domId) {
|
|
const toggleEl = document.querySelector(`[data-dom-id="${domId}"]`);
|
|
if (toggleEl) {
|
|
toggleEl.classList.toggle('active');
|
|
}
|
|
}
|
|
|
|
// ===== 导航跳转 =====
|
|
function navigateTo(itemId) {
|
|
switch (itemId) {
|
|
case 'item-realname-auth':
|
|
window.location.href = 'auth-step1.html';
|
|
break;
|
|
case 'item-student-auth':
|
|
window.location.href = 'auth-locked.html';
|
|
break;
|
|
case 'item-privacy':
|
|
window.location.href = 'privacy-settings.html';
|
|
break;
|
|
case 'item-account-security':
|
|
showToast('账号与安全');
|
|
break;
|
|
case 'item-change-password':
|
|
showToast('修改密码');
|
|
break;
|
|
case 'item-blacklist':
|
|
showToast('黑名单管理');
|
|
break;
|
|
case 'item-block-posts':
|
|
showToast('不看他的动态');
|
|
break;
|
|
case 'item-font-size':
|
|
showToast('字体大小设置');
|
|
break;
|
|
case 'item-language':
|
|
showToast('语言设置');
|
|
break;
|
|
case 'item-about':
|
|
showToast('关于青核 v2.1.0');
|
|
break;
|
|
case 'item-help':
|
|
showToast('帮助与反馈');
|
|
break;
|
|
case 'item-user-agreement':
|
|
showToast('用户协议');
|
|
break;
|
|
case 'item-privacy-policy':
|
|
showToast('隐私政策');
|
|
break;
|
|
default:
|
|
showToast('功能开发中');
|
|
}
|
|
}
|
|
|
|
// ===== 清理缓存弹窗 =====
|
|
function openClearCacheModal() {
|
|
const modal = document.getElementById('clear-cache-modal');
|
|
modal.classList.add('show');
|
|
}
|
|
|
|
function closeClearCacheModal() {
|
|
const modal = document.getElementById('clear-cache-modal');
|
|
modal.classList.remove('show');
|
|
}
|
|
|
|
function confirmClearCache() {
|
|
closeClearCacheModal();
|
|
// 模拟清理动画
|
|
const cacheEl = document.getElementById('cache-size');
|
|
let size = 23.6;
|
|
const interval = setInterval(() => {
|
|
size -= 2.0;
|
|
if (size <= 0) {
|
|
size = 0;
|
|
clearInterval(interval);
|
|
showToast('缓存已清理');
|
|
}
|
|
cacheEl.textContent = size.toFixed(1) + 'MB';
|
|
}, 80);
|
|
}
|
|
|
|
// ===== 退出登录弹窗 =====
|
|
function openLogoutModal() {
|
|
const modal = document.getElementById('logout-modal');
|
|
modal.classList.add('show');
|
|
}
|
|
|
|
function closeLogoutModal() {
|
|
const modal = document.getElementById('logout-modal');
|
|
modal.classList.remove('show');
|
|
}
|
|
|
|
function confirmLogout() {
|
|
closeLogoutModal();
|
|
showToast('已退出登录');
|
|
// 实际项目中跳转到登录页
|
|
// setTimeout(() => {
|
|
// window.location.href = 'login.html';
|
|
// }, 1000);
|
|
}
|
|
|
|
// ===== 点击遮罩关闭弹窗 =====
|
|
function closeModalOutside(event, modalId) {
|
|
if (event.target.classList.contains('modal-overlay')) {
|
|
const modal = document.getElementById(modalId);
|
|
modal.classList.remove('show');
|
|
}
|
|
}
|
|
|
|
// ===== Toast =====
|
|
let toastTimer = null;
|
|
function showToast(message) {
|
|
const toast = document.getElementById('toast');
|
|
toast.textContent = message;
|
|
toast.classList.add('show');
|
|
|
|
if (toastTimer) clearTimeout(toastTimer);
|
|
toastTimer = setTimeout(() => {
|
|
toast.classList.remove('show');
|
|
}, 2000);
|
|
}</script>
|
|
</body>
|
|
</html>
|
|
|