Issue#6·P3·C2: shell.scss 重写(sub2api 契约)——顶栏 54→64 glass(blur20/border-strong);sidebar 224→256·折叠 64→72 实底 slate-900/白+sidebar-header 品牌区(logo 36 r12 gradient glow+品牌 18/700+ver-badge 版本徽章位=用户指令);菜单项 14/500 r12 py10·pl17/pr14·gap12·icon 容器 20(尺寸值 C3 组件配合)·激活 primary-50 底无指示条(源码 sidebar-link-active 真值);分组标题 14/600(用户覆盖 12px);page-head 17→24/700·main padding 32(契约 lg:p-8);card 玻璃 veil→实底 r16 shadow-card(gray-100 边)·hover 浮起/glow 描边退役;KPI value 32→20/700 tabular;ch-table td 12.5→14·py9/12→16·px12→20(baseline 全等项);quick-item qic 34→48 icon 容器(契约);badge/delta/sem/trend 字阶 12/13 对齐;aurora 极光段退役;滚动条/移动端抽屉(900/64)/focus-visible/版本 blink 动画保留;类名锚点全存活;build ✓
This commit is contained in:
+168
-183
@@ -1,267 +1,252 @@
|
||||
/* ============================================================
|
||||
* shell.scss — W1:布局壳(demo-c-aurora 原文直译,变量改引 tokens 单一来源)
|
||||
* 职责:极光背景/topbar/sidebar(H1 折叠+H2 滚动条)/page-head/main/
|
||||
* card/metrics/badge/delta/quick-item/lf-* 登录件/语义徽章/基础重置。
|
||||
* 变量:一律 var(--gosms-*)(tokens.scss);EP 控件走 ep-theme.scss 变量映射。
|
||||
* shell.scss — Issue#6 P3 重写(sub2api 契约 v3.2.1)
|
||||
* 职责:topbar(64 glass)/sidebar(256·折叠72,品牌头部)/page-head(24)/
|
||||
* main(32)/card(r16 实底 shadow-card)/metrics/badge/delta/quick-item/
|
||||
* ch-table(td 14·py16/px20)/版本 chip/基础重置/语义徽章/移动端抽屉。
|
||||
* 真值:sub2api style.css(.sidebar/.sidebar-link/.card/.glass)+alignment-report
|
||||
* 源码规格表;aurora 极光退役;类名锚点(.sidebar/.nav-item/...)全保留
|
||||
* 供 verify-layout 与 views 消费。变量一律 var(--gosms-*)。
|
||||
* ============================================================ */
|
||||
|
||||
body { font-family: var(--gosms-font); font-size: var(--gosms-fs-body); color: var(--gosms-text); background: var(--gosms-bg-page); }
|
||||
body {
|
||||
font-family: var(--gosms-font); font-size: var(--gosms-fs-body); line-height: var(--gosms-lh-body);
|
||||
color: var(--gosms-text); background: var(--gosms-bg-page);
|
||||
-webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility;
|
||||
}
|
||||
.num { font-variant-numeric: tabular-nums; }
|
||||
.num-glow { /* 退役兼容(sub2api 无数字 glow) */ }
|
||||
|
||||
/* ---- 极光背景:三层径向光斑(demo 原文) ---- */
|
||||
.aurora { position: fixed; inset: -20%; z-index: 0; pointer-events: none; filter: blur(90px); opacity: 0.55; }
|
||||
html:not(.dark) .aurora { opacity: 0.3; }
|
||||
.aurora::before, .aurora::after { content: ''; position: absolute; border-radius: 50%; }
|
||||
.aurora::before { width: 46vw; height: 46vw; left: -6vw; top: -10vh; background: radial-gradient(circle, rgba(45,212,191,0.5), transparent 65%); animation: drift1 20s ease-in-out infinite alternate; }
|
||||
.aurora::after { width: 40vw; height: 40vw; right: -8vw; top: 30vh; background: radial-gradient(circle, rgba(14,165,233,0.4), transparent 65%); animation: drift2 26s ease-in-out infinite alternate; }
|
||||
@keyframes drift1 { to { transform: translate(14vw, 10vh) scale(1.15); } }
|
||||
@keyframes drift2 { to { transform: translate(-10vw, -8vh) scale(0.9); } }
|
||||
@media (prefers-reduced-motion: reduce) { .aurora::before, .aurora::after { animation: none; } }
|
||||
.num { font-family: var(--gosms-font-num); font-variant-numeric: tabular-nums; }
|
||||
.num-glow { text-shadow: 0 0 22px var(--gosms-primary-soft); }
|
||||
|
||||
/* ---- 入场动画(W2:原 theme 层佚失类补回;登录卡/错误卡消费) ---- */
|
||||
@keyframes slide-up { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
|
||||
.animate-slide-up { animation: slide-up 0.45s ease-out both; }
|
||||
/* ---- 入场动画(sub2api fadeIn/slideUp 同族) ---- */
|
||||
@keyframes slide-up { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
|
||||
.animate-slide-up { animation: slide-up 0.3s ease-out both; }
|
||||
@media (prefers-reduced-motion: reduce) { .animate-slide-up { animation: none; } }
|
||||
|
||||
/* ---- 顶栏(demo 原文) ---- */
|
||||
/* ---- 顶栏(sub2api AppHeader:glass sticky h-64,左页标题右动作) ---- */
|
||||
.topbar {
|
||||
position: sticky; top: 0; z-index: 50; height: 54px; padding: 0 20px;
|
||||
position: sticky; top: 0; z-index: 50; height: 64px; padding: 0 24px;
|
||||
display: flex; align-items: center; gap: 16px;
|
||||
background: rgba(11, 16, 22, 0.72); backdrop-filter: blur(14px);
|
||||
border-bottom: 1px solid var(--gosms-border);
|
||||
background: var(--gosms-glass-header); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
|
||||
border-bottom: 1px solid var(--gosms-border-strong);
|
||||
}
|
||||
html:not(.dark) .topbar { background: rgba(255, 255, 255, 0.72); }
|
||||
.brand { display: flex; align-items: center; gap: 10px; }
|
||||
.brand-mark { width: 30px; height: 30px; border-radius: 9px; background: var(--gosms-gradient); display: grid; place-items: center; font-size: 15px; box-shadow: 0 0 18px var(--gosms-glow); }
|
||||
.brand-name { font-weight: 700; font-size: 15px; color: var(--gosms-text-bright); letter-spacing: 0.02em; }
|
||||
.brand-sub { font-size: 10px; color: var(--gosms-text-muted); letter-spacing: 0.14em; }
|
||||
.top-title { font-size: var(--gosms-fs-lg); font-weight: 600; color: var(--gosms-text-bright); margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
||||
.top-actions { margin-left: auto; display: flex; align-items: center; gap: 12px; }
|
||||
.avatar-chip { display: flex; align-items: center; gap: 8px; padding: 4px 12px 4px 5px; border-radius: 999px; border: 1px solid var(--gosms-border); cursor: pointer; transition: all 0.2s; }
|
||||
.avatar-chip:hover { border-color: var(--gosms-border-glow); box-shadow: 0 0 14px var(--gosms-primary-soft); }
|
||||
.avatar { width: 26px; height: 26px; border-radius: 50%; background: var(--gosms-gradient); color: #fff; font-size: 11px; font-weight: 700; display: grid; place-items: center; }
|
||||
.avatar-name { font-size: 12px; color: var(--gosms-text-bright); }
|
||||
.theme-btn { font-size: 12px; color: var(--gosms-text-muted); background: none; border: 1px solid var(--gosms-border); border-radius: 8px; padding: 5px 12px; cursor: pointer; transition: all 0.2s; }
|
||||
.theme-btn:hover { color: var(--gosms-primary); border-color: var(--gosms-primary); box-shadow: 0 0 12px var(--gosms-primary-soft); }
|
||||
/* 移动端汉堡(项目补充,demo 无;纯原生,不引入 EP) */
|
||||
.menu-btn { display: none; width: 34px; height: 34px; place-items: center; border: 1px solid var(--gosms-border); border-radius: 8px; background: none; color: var(--gosms-text-muted); cursor: pointer; font-size: 15px; }
|
||||
.avatar-chip {
|
||||
display: flex; align-items: center; gap: 8px; padding: 4px 12px 4px 5px; border-radius: var(--gosms-radius-base);
|
||||
border: 1px solid var(--gosms-border); cursor: pointer; transition: all 0.2s; background: none;
|
||||
}
|
||||
.avatar-chip:hover { background: var(--gosms-input-veil); border-color: var(--gosms-border-strong); }
|
||||
.avatar { width: 28px; height: 28px; border-radius: 50%; background: var(--gosms-gradient); color: #fff; font-size: var(--gosms-fs-xs); font-weight: 700; display: grid; place-items: center; }
|
||||
.avatar-name { font-size: var(--gosms-fs-base); color: var(--gosms-text-bright); }
|
||||
.theme-btn {
|
||||
font-size: var(--gosms-fs-xs); color: var(--gosms-text-secondary); background: none;
|
||||
border: 1px solid var(--gosms-border); border-radius: var(--gosms-radius-base); padding: 6px 12px;
|
||||
cursor: pointer; transition: all 0.2s; white-space: nowrap;
|
||||
}
|
||||
.theme-btn:hover { color: var(--gosms-primary); border-color: var(--gosms-primary); background: var(--gosms-primary-soft); }
|
||||
/* 移动端汉堡(项目补充;纯原生,不引入 EP) */
|
||||
.menu-btn { display: none; width: 36px; height: 36px; place-items: center; border: 1px solid var(--gosms-border); border-radius: var(--gosms-radius-base); background: none; color: var(--gosms-text-secondary); cursor: pointer; font-size: 16px; }
|
||||
.menu-btn:hover { color: var(--gosms-primary); border-color: var(--gosms-primary); }
|
||||
|
||||
/* ---- 布局(demo 原文) ---- */
|
||||
/* ---- 布局 ---- */
|
||||
.shell { position: relative; z-index: 1; display: flex; min-height: 100vh; }
|
||||
.sidebar {
|
||||
width: 224px; flex-shrink: 0; position: sticky; top: 54px; height: calc(100vh - 54px);
|
||||
padding: 16px 12px; overflow: hidden;
|
||||
display: flex; flex-direction: column;
|
||||
background: rgba(255, 255, 255, 0.03); backdrop-filter: blur(14px); border-right: 1px solid var(--gosms-border);
|
||||
width: 256px; flex-shrink: 0; position: sticky; top: 64px; height: calc(100vh - 64px);
|
||||
overflow: hidden; display: flex; flex-direction: column;
|
||||
background: var(--gosms-bg-2); border-right: 1px solid var(--gosms-border);
|
||||
transition: width 0.3s ease;
|
||||
}
|
||||
/* W6:菜单滚动区(flex:1 承接)+底脚收起按钮固定最下方 */
|
||||
.nav-scroll { flex: 1; min-height: 0; overflow-y: auto; scrollbar-width: none; }
|
||||
/* 品牌头部(sub2api sidebar-header:h-64 px-24,logo 36 r12 glow+品牌 18/700+版本徽章) */
|
||||
.sidebar-header {
|
||||
flex-shrink: 0; height: 64px; padding: 0 24px; display: flex; align-items: center; gap: 12px;
|
||||
border-bottom: 1px solid var(--gosms-border); text-decoration: none;
|
||||
}
|
||||
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
|
||||
.brand-mark {
|
||||
flex-shrink: 0; width: 36px; height: 36px; border-radius: var(--gosms-radius-base);
|
||||
background: var(--gosms-gradient); display: grid; place-items: center;
|
||||
color: #fff; font-size: 17px; box-shadow: var(--gosms-shadow-glow); transition: opacity 0.2s;
|
||||
}
|
||||
.brand:hover .brand-mark { opacity: 0.85; }
|
||||
.brand-name { font-weight: 700; font-size: var(--gosms-fs-xl); color: var(--gosms-text-bright); letter-spacing: 0.01em; white-space: nowrap; }
|
||||
/* 版本徽章(sub2api VersionBadge:12px bg-gray-100 无边框;go-sms 置品牌下方=用户指令位) */
|
||||
.ver-badge {
|
||||
display: inline-flex; align-items: center; gap: 6px; margin-top: 2px;
|
||||
padding: 2px 8px; border-radius: var(--gosms-radius-sm);
|
||||
background: var(--gosms-input-veil); color: var(--gosms-text-secondary);
|
||||
font-size: var(--gosms-fs-xs); font-family: var(--gosms-font-num); white-space: nowrap;
|
||||
}
|
||||
/* 菜单滚动区(sub2api sidebar-nav:px-12 py-16) */
|
||||
.nav-scroll { flex: 1; min-height: 0; overflow-y: auto; scrollbar-width: none; padding: 16px 12px; }
|
||||
.nav-scroll::-webkit-scrollbar { display: none; }
|
||||
.sidebar-foot { flex-shrink: 0; display: flex; align-items: center; gap: 8px; padding: 10px 0 0; margin-top: 8px; border-top: 1px solid var(--gosms-border); }
|
||||
.sidebar.collapsed .sidebar-foot { justify-content: center; flex-direction: column; gap: 6px; }
|
||||
html:not(.dark) .sidebar { background: rgba(255, 255, 255, 0.55); }
|
||||
.nav-group { font-size: 10px; color: var(--gosms-text-muted); letter-spacing: 0.16em; padding: 16px 12px 6px; }
|
||||
.sidebar-foot { flex-shrink: 0; display: flex; align-items: center; justify-content: center; padding: 12px 0; border-top: 1px solid var(--gosms-border); }
|
||||
/* 分组标题(源码 12/600 uppercase;go-sms 覆盖 14px 对齐菜单=用户显式项) */
|
||||
.nav-group {
|
||||
font-size: var(--gosms-fs-base); font-weight: 600; color: var(--gosms-text-muted);
|
||||
letter-spacing: 0.05em; padding: 16px 12px 8px; white-space: nowrap;
|
||||
}
|
||||
/* 菜单项(sub2api sidebar-link:14/500 r12 py-10 pl-17 pr-14 gap-12;激活=primary-50 底+primary 字,无指示条) */
|
||||
.nav-item {
|
||||
display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 10px;
|
||||
color: var(--gosms-text); cursor: pointer; position: relative; transition: all 0.2s; margin-bottom: 2px;
|
||||
text-decoration: none;
|
||||
display: flex; align-items: center; gap: 12px; padding: 10px 14px 10px 17px;
|
||||
border-radius: var(--gosms-radius-base); margin-bottom: 4px;
|
||||
color: var(--gosms-text-secondary); font-size: var(--gosms-fs-base); font-weight: 500;
|
||||
cursor: pointer; text-decoration: none; white-space: nowrap; overflow: hidden;
|
||||
transition: background-color 0.2s, color 0.2s;
|
||||
}
|
||||
.nav-item .ic { width: 17px; text-align: center; font-size: 14px; opacity: 0.8; }
|
||||
.nav-item:hover { background: var(--gosms-card-hover); color: var(--gosms-text-bright); }
|
||||
.nav-item .ic { flex-shrink: 0; width: 20px; height: 20px; display: grid; place-items: center; }
|
||||
.nav-item:hover { background: var(--gosms-input-veil); color: var(--gosms-text-bright); }
|
||||
.nav-item.active { background: var(--gosms-primary-soft); color: var(--gosms-primary); font-weight: 600; }
|
||||
.nav-item.active::before {
|
||||
content: ''; position: absolute; left: -12px; top: 20%; bottom: 20%; width: 3px;
|
||||
border-radius: 3px; background: var(--gosms-gradient); box-shadow: 0 0 10px var(--gosms-glow);
|
||||
}
|
||||
.main { flex: 1; padding: 22px 26px; min-width: 0; }
|
||||
.page-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 16px; }
|
||||
.page-head h2 { font-size: 17px; font-weight: 700; color: var(--gosms-text-bright); margin: 0; }
|
||||
.page-head .sub { font-size: 11px; color: var(--gosms-text-muted); letter-spacing: 0.08em; }
|
||||
html:not(.dark) .nav-item.active { background: var(--gosms-primary-50); color: var(--gosms-primary-600); }
|
||||
/* 折叠态(w-72:图标居中/文字隐/分组隐;品牌缩 logo) */
|
||||
.sidebar.collapsed { width: 72px; }
|
||||
.sidebar.collapsed .sidebar-header { padding: 0; justify-content: center; }
|
||||
.sidebar.collapsed .brand-name, .sidebar.collapsed .ver-badge, .sidebar.collapsed .nav-item .txt,
|
||||
.sidebar.collapsed .nav-group { display: none; }
|
||||
.sidebar.collapsed .nav-item { justify-content: center; padding: 10px 0; }
|
||||
.main { flex: 1; padding: 32px; min-width: 0; }
|
||||
|
||||
/* ---- 页头(sub2api page-header:mb-24;title 24/700) ---- */
|
||||
.page-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 24px; flex-wrap: wrap; }
|
||||
.page-head h2 { font-size: var(--gosms-fs-stat); font-weight: 700; color: var(--gosms-text-bright); margin: 0; }
|
||||
.page-head .sub { font-size: var(--gosms-fs-base); color: var(--gosms-text-secondary); }
|
||||
.page-head-extra { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; }
|
||||
.live-chip { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; font-size: 11px; color: var(--gosms-primary); background: var(--gosms-primary-soft); padding: 4px 12px; border-radius: 999px; }
|
||||
.live-chip i { width: 6px; height: 6px; border-radius: 50%; background: var(--gosms-primary); box-shadow: 0 0 8px var(--gosms-glow); animation: pulse 2s infinite; }
|
||||
.live-chip { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; font-size: var(--gosms-fs-xs); color: var(--gosms-primary); background: var(--gosms-primary-soft); padding: 4px 12px; border-radius: 999px; }
|
||||
.live-chip i { width: 6px; height: 6px; border-radius: 50%; background: var(--gosms-primary); animation: pulse 2s infinite; }
|
||||
@keyframes pulse { 50% { opacity: 0.4; } }
|
||||
|
||||
/* ---- stagger 入场(demo 原文) ---- */
|
||||
.stagger > * { opacity: 0; animation: rise 0.55s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
|
||||
.stagger > *:nth-child(1) { animation-delay: 0.05s; } .stagger > *:nth-child(2) { animation-delay: 0.13s; }
|
||||
.stagger > *:nth-child(3) { animation-delay: 0.21s; } .stagger > *:nth-child(4) { animation-delay: 0.29s; }
|
||||
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
|
||||
/* ---- stagger 入场 ---- */
|
||||
.stagger > * { opacity: 0; animation: rise 0.4s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
|
||||
.stagger > *:nth-child(1) { animation-delay: 0.05s; } .stagger > *:nth-child(2) { animation-delay: 0.11s; }
|
||||
.stagger > *:nth-child(3) { animation-delay: 0.17s; } .stagger > *:nth-child(4) { animation-delay: 0.23s; }
|
||||
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
|
||||
@media (prefers-reduced-motion: reduce) { .stagger > * { animation: none; opacity: 1; } }
|
||||
|
||||
/* ---- 玻璃卡 + 渐变描边(demo 原文) ---- */
|
||||
/* ---- 卡片(sub2api .card:实底 r16 边 gray-100 shadow-card;p16=契约) ---- */
|
||||
.card {
|
||||
position: relative; border-radius: 16px; padding: 18px 20px;
|
||||
background: var(--gosms-card-veil); backdrop-filter: blur(12px);
|
||||
border: 1px solid var(--gosms-border); transition: all 0.25s;
|
||||
position: relative; border-radius: var(--gosms-radius); padding: 16px;
|
||||
background: var(--gosms-card); border: 1px solid var(--gosms-border);
|
||||
box-shadow: var(--gosms-shadow-card); transition: box-shadow 0.3s, border-color 0.3s;
|
||||
}
|
||||
.card::before {
|
||||
content: ''; position: absolute; inset: -1px; border-radius: 17px; padding: 1px;
|
||||
background: linear-gradient(135deg, rgba(45, 212, 191, 0.45), transparent 40%, transparent 60%, rgba(14, 165, 233, 0.3));
|
||||
-webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
|
||||
-webkit-mask-composite: xor; mask-composite: exclude;
|
||||
opacity: 0; transition: opacity 0.3s; pointer-events: none;
|
||||
}
|
||||
.card:hover { background: var(--gosms-card-hover); transform: translateY(-2px); box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35); }
|
||||
.card:hover::before { opacity: 1; }
|
||||
html:not(.dark) .card:hover { box-shadow: 0 8px 28px rgba(13, 148, 136, 0.12); }
|
||||
.card:hover { box-shadow: var(--gosms-shadow-card-hover); }
|
||||
|
||||
/* ---- 指标卡(demo 原文) ---- */
|
||||
.metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
|
||||
.metric .label { font-size: 11px; color: var(--gosms-text-muted); display: flex; align-items: center; gap: 6px; }
|
||||
.metric .value { font-family: var(--gosms-font-num); font-size: 32px; font-weight: 600; color: var(--gosms-text-bright); margin: 10px 0 8px; line-height: 1; text-shadow: 0 0 22px var(--gosms-primary-soft); }
|
||||
.metric .value .unit { font-size: 14px; color: var(--gosms-text-muted); font-weight: 400; text-shadow: none; }
|
||||
.delta { font-size: 11.5px; display: inline-flex; gap: 5px; align-items: center; padding: 2px 9px; border-radius: 999px; }
|
||||
/* ---- 指标卡(KPI value 20/700 tabular;P4 Dashboard 组件化承载配色) ---- */
|
||||
.metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
|
||||
.metric .label { font-size: var(--gosms-fs-xs); color: var(--gosms-text-secondary); display: flex; align-items: center; gap: 6px; }
|
||||
.metric .value { font-size: var(--gosms-fs-hero); font-weight: 700; color: var(--gosms-text-bright); margin: 10px 0 8px; line-height: 1.2; font-variant-numeric: tabular-nums; }
|
||||
.metric .value .unit { font-size: var(--gosms-fs-base); color: var(--gosms-text-muted); font-weight: 400; }
|
||||
.delta { font-size: var(--gosms-fs-xs); display: inline-flex; gap: 5px; align-items: center; padding: 2px 9px; border-radius: 999px; }
|
||||
.delta.up { color: var(--gosms-primary); background: var(--gosms-primary-soft); }
|
||||
.delta.down { color: var(--gosms-red); background: rgba(248, 113, 113, 0.1); }
|
||||
.delta.warn { color: var(--gosms-amber); background: rgba(251, 191, 36, 0.1); }
|
||||
.delta.down { color: var(--gosms-red); background: rgba(239, 68, 68, 0.1); }
|
||||
.delta.warn { color: var(--gosms-amber); background: rgba(245, 158, 11, 0.1); }
|
||||
|
||||
/* ---- 图表 + 快捷(demo 原文) ---- */
|
||||
.duo { display: grid; grid-template-columns: 2fr 1fr; gap: 14px; margin-top: 14px; }
|
||||
.card-head { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; font-size: 13px; font-weight: 600; color: var(--gosms-text-bright); }
|
||||
.card-head small { margin-left: auto; font-weight: 400; font-size: 10.5px; color: var(--gosms-text-muted); }
|
||||
/* ---- 图表 + 快捷 ---- */
|
||||
.duo { display: grid; grid-template-columns: 2fr 1fr; gap: 16px; margin-top: 16px; }
|
||||
.card-head { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; font-size: var(--gosms-fs-base); font-weight: 600; color: var(--gosms-text-bright); }
|
||||
.card-head small { margin-left: auto; font-weight: 400; font-size: var(--gosms-fs-xs); color: var(--gosms-text-muted); }
|
||||
.trend-svg { width: 100%; height: auto; display: block; }
|
||||
.quick-item {
|
||||
display: flex; align-items: center; gap: 11px; padding: 10px; border-radius: 11px;
|
||||
cursor: pointer; transition: all 0.2s; border: 1px solid transparent;
|
||||
display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: var(--gosms-radius-base);
|
||||
cursor: pointer; transition: background-color 0.2s; border: 1px solid transparent; text-decoration: none;
|
||||
}
|
||||
.quick-item:hover { background: var(--gosms-primary-soft); border-color: var(--gosms-border-glow); }
|
||||
.quick-item .qic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--gosms-primary-soft); font-size: 15px; }
|
||||
.quick-item .qt { font-size: 12.5px; color: var(--gosms-text-bright); }
|
||||
.quick-item .qd { font-size: 10.5px; color: var(--gosms-text-muted); margin-top: 2px; }
|
||||
.quick-item:hover { background: var(--gosms-input-veil); }
|
||||
.quick-item .qic { flex-shrink: 0; width: 48px; height: 48px; border-radius: var(--gosms-radius-base); display: grid; place-items: center; background: var(--gosms-primary-soft); color: var(--gosms-primary); font-size: var(--gosms-fs-xl); }
|
||||
.quick-item .qt { font-size: var(--gosms-fs-base); font-weight: 500; color: var(--gosms-text-bright); }
|
||||
.quick-item .qd { font-size: var(--gosms-fs-xs); color: var(--gosms-text-muted); margin-top: 2px; }
|
||||
.quick-item .arrow { margin-left: auto; color: var(--gosms-text-muted); transition: transform 0.2s; }
|
||||
.quick-item:hover .arrow { transform: translateX(3px); color: var(--gosms-primary); }
|
||||
|
||||
/* ---- 表格语义(demo 原文;页面内 el-table 由 EP-bridge 对齐) ---- */
|
||||
.ch-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
|
||||
.ch-table thead th { font-size: 10.5px; color: var(--gosms-text-muted); letter-spacing: 0.1em; text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--gosms-border); white-space: nowrap; font-weight: 600; }
|
||||
/* ---- 表格语义(契约 td:14/20 gray-700 py16/px20;th 12/500) ---- */
|
||||
.ch-table { width: 100%; border-collapse: collapse; font-size: var(--gosms-fs-base); }
|
||||
.ch-table thead th { font-size: var(--gosms-fs-xs); font-weight: 500; color: var(--gosms-text-secondary); letter-spacing: 0.02em; text-align: left; padding: 12px 20px; border-bottom: 1px solid var(--gosms-border); white-space: nowrap; }
|
||||
.ch-table thead th.r, .ch-table td.r { text-align: right; }
|
||||
.ch-table tbody td { padding: 11px 12px; border-bottom: 1px solid var(--gosms-border); white-space: nowrap; }
|
||||
.ch-table tbody tr { transition: background 0.15s; }
|
||||
.ch-table tbody tr:hover { background: var(--gosms-primary-soft); }
|
||||
.ch-table tbody td { padding: 16px 20px; border-bottom: 1px solid var(--gosms-border); white-space: nowrap; color: var(--gosms-text); }
|
||||
.ch-table tbody tr { transition: background-color 0.15s; }
|
||||
.ch-table tbody tr:hover { background: var(--gosms-input-veil); }
|
||||
.mono { font-family: var(--gosms-font-num); color: var(--gosms-text-bright); }
|
||||
.badge { font-size: 10.5px; padding: 3px 10px; border-radius: 999px; border: 1px solid; font-weight: 500; display: inline-block; }
|
||||
.badge { font-size: var(--gosms-fs-xs); padding: 3px 10px; border-radius: 999px; border: 1px solid; font-weight: 500; display: inline-block; }
|
||||
.badge.ok { color: var(--gosms-primary); border-color: var(--gosms-border-glow); background: var(--gosms-primary-soft); }
|
||||
.badge.warn { color: var(--gosms-amber); border-color: rgba(251, 191, 36, 0.35); background: rgba(251, 191, 36, 0.08); }
|
||||
.badge.err { color: var(--gosms-red); border-color: rgba(248, 113, 113, 0.35); background: rgba(248, 113, 113, 0.08); }
|
||||
.badge.warn { color: var(--gosms-amber); border-color: rgba(245, 158, 11, 0.35); background: rgba(245, 158, 11, 0.08); }
|
||||
.badge.err { color: var(--gosms-red); border-color: rgba(239, 68, 68, 0.35); background: rgba(239, 68, 68, 0.08); }
|
||||
.badge.violet { color: var(--gosms-violet); border-color: rgba(167, 139, 250, 0.35); background: rgba(167, 139, 250, 0.08); }
|
||||
.rate-bar { display: inline-flex; align-items: center; gap: 8px; }
|
||||
.rate-bar .rb { width: 54px; height: 4px; border-radius: 4px; background: var(--gosms-border); overflow: hidden; }
|
||||
.rate-bar .rb i { display: block; height: 100%; background: var(--gosms-gradient); border-radius: 4px; }
|
||||
|
||||
/* ---- 项目全局工具类(demo 语义补充;E 阶段 legacy 收编) ---- */
|
||||
.hint { font-size: 11px; color: var(--gosms-text-muted); }
|
||||
.page-stack { display: flex; flex-direction: column; gap: 14px; }
|
||||
.glass-card { position: relative; border-radius: 16px; padding: 18px 20px; background: var(--gosms-card-veil); backdrop-filter: blur(12px); border: 1px solid var(--gosms-border); }
|
||||
/* ---- 全局工具类 ---- */
|
||||
.hint { font-size: var(--gosms-fs-xs); color: var(--gosms-text-muted); line-height: 1.5; }
|
||||
.page-stack { display: flex; flex-direction: column; gap: 16px; }
|
||||
.glass-card { border-radius: var(--gosms-radius); padding: 16px; background: var(--gosms-card); border: 1px solid var(--gosms-border); box-shadow: var(--gosms-shadow-card); }
|
||||
.btn-gradient {
|
||||
background: var(--gosms-gradient); color: #fff; border: none; border-radius: 11px; padding: 11px 20px;
|
||||
font-size: 13.5px; font-weight: 700; cursor: pointer; letter-spacing: 0.04em;
|
||||
box-shadow: 0 4px 20px var(--gosms-glow); transition: all 0.2s;
|
||||
background: var(--gosms-gradient); color: #fff; border: none; border-radius: var(--gosms-radius-base); padding: 10px 20px;
|
||||
font-size: var(--gosms-fs-base); font-weight: 600; cursor: pointer;
|
||||
box-shadow: 0 2px 12px var(--gosms-glow); transition: all 0.2s;
|
||||
}
|
||||
.btn-gradient:hover { filter: brightness(1.1); box-shadow: 0 6px 28px var(--gosms-glow); transform: translateY(-1px); }
|
||||
.btn-gradient:hover { filter: brightness(1.08); box-shadow: 0 4px 20px var(--gosms-glow); }
|
||||
|
||||
/* ---- H1:侧栏收起/展开(64px 图标态;无 popup/无复制 logo,双菜单免疫) ---- */
|
||||
.collapse-btn { display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid var(--gosms-border); border-radius: 8px; background: none; color: var(--gosms-text-muted); cursor: pointer; font-size: 13px; transition: all 0.2s; }
|
||||
.collapse-btn:hover { color: var(--gosms-primary); border-color: var(--gosms-primary); }
|
||||
/* ---- 折叠钮 + 版本 chip(Issue#4 资产;折叠钮留 foot,版本徽章迁 brand 下) ---- */
|
||||
.collapse-btn { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid var(--gosms-border); border-radius: var(--gosms-radius-base); background: none; color: var(--gosms-text-secondary); cursor: pointer; font-size: 14px; transition: all 0.2s; }
|
||||
.collapse-btn:hover { color: var(--gosms-primary); border-color: var(--gosms-primary); background: var(--gosms-primary-soft); }
|
||||
.collapse-btn .cg { display: inline-block; transition: transform 0.25s; }
|
||||
/* Issue#4:侧栏底脚版本 chip(折叠按钮旁;点击进发布日志,未读新版本红点闪烁) */
|
||||
.ver-chip { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border: 1px solid var(--gosms-border); border-radius: 999px; color: var(--gosms-text-dim, #909399); font-family: ui-monospace, monospace; font-size: 12px; text-decoration: none; white-space: nowrap; transition: all 0.2s; position: relative; }
|
||||
.ver-chip:hover { color: var(--gosms-primary); border-color: var(--gosms-primary); }
|
||||
.ver-chip .ver-dot { flex: none; width: 7px; height: 7px; border-radius: 50%; background: #f56c6c; animation: gosms-ver-blink 1.1s ease-in-out infinite; }
|
||||
ver-chip { text-decoration: none; }
|
||||
.ver-badge { cursor: pointer; transition: color 0.2s; }
|
||||
.ver-badge:hover { color: var(--gosms-primary); }
|
||||
.ver-badge .ver-dot { flex: none; width: 7px; height: 7px; border-radius: 50%; background: #ef4444; animation: gosms-ver-blink 1.1s ease-in-out infinite; }
|
||||
@keyframes gosms-ver-blink { 0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(245, 108, 108, 0.55); } 50% { opacity: 0.45; box-shadow: 0 0 0 5px rgba(245, 108, 108, 0); } }
|
||||
/* 折叠态(64px):chip 缩为无边框短版本(1.5);红点转绝对定位悬浮右上(badge 式,不占宽防溢出) */
|
||||
.sidebar.collapsed .ver-chip { height: auto; padding: 2px 4px; border-color: transparent; font-size: 10px; gap: 0; }
|
||||
.sidebar.collapsed .ver-chip .ver-dot { position: absolute; top: -2px; right: -4px; box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.35); }
|
||||
.sidebar.collapsed { width: 64px; padding: 16px 8px; }
|
||||
.sidebar.collapsed .nav-item { justify-content: center; padding: 8px 0; }
|
||||
.sidebar.collapsed .nav-item .txt { display: none; }
|
||||
.sidebar.collapsed .nav-item.active::before { left: -8px; }
|
||||
.sidebar.collapsed .nav-group { color: transparent; padding: 12px 0 8px; position: relative; }
|
||||
.sidebar.collapsed .nav-group::after { content: ''; position: absolute; left: 24%; right: 24%; top: 50%; height: 1px; background: var(--gosms-border); }
|
||||
|
||||
/* ---- H2:滚动条——侧栏视觉消除(滚动能力保留,职责在 .nav-scroll),全局 demo 化细条 ---- */
|
||||
* { scrollbar-width: thin; scrollbar-color: var(--gosms-border) transparent; }
|
||||
/* ---- 滚动条(细条契约化) ---- */
|
||||
* { scrollbar-width: thin; scrollbar-color: var(--gosms-border-strong) transparent; }
|
||||
::-webkit-scrollbar { width: 6px; height: 6px; }
|
||||
::-webkit-scrollbar-track { background: transparent; }
|
||||
::-webkit-scrollbar-thumb { background: var(--gosms-border); border-radius: 3px; }
|
||||
::-webkit-scrollbar-thumb { background: var(--gosms-border-strong); border-radius: 3px; }
|
||||
::-webkit-scrollbar-thumb:hover { background: var(--gosms-primary-soft); }
|
||||
|
||||
/* ---- 移动端(demo 断点 900 + 项目汉堡抽屉补充) ---- */
|
||||
/* ---- 移动端(≤900 抽屉;顶栏 64) ---- */
|
||||
@media (max-width: 900px) {
|
||||
.sidebar { display: none; }
|
||||
.duo { grid-template-columns: 1fr; }
|
||||
.menu-btn { display: grid; }
|
||||
.sidebar.open {
|
||||
display: flex; flex-direction: column; position: fixed; top: 54px; left: 0; z-index: 60;
|
||||
height: calc(100vh - 54px); background: var(--gosms-bg-2);
|
||||
box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
|
||||
display: flex; flex-direction: column; position: fixed; top: 64px; left: 0; z-index: 60;
|
||||
height: calc(100vh - 64px); background: var(--gosms-bg-2);
|
||||
box-shadow: var(--gosms-shadow-glass);
|
||||
}
|
||||
.nav-scrim { position: fixed; inset: 54px 0 0 0; z-index: 55; background: rgba(0, 0, 0, 0.45); }
|
||||
.main { padding: 16px 14px; }
|
||||
.nav-scrim { position: fixed; inset: 64px 0 0 0; z-index: 55; background: rgba(0, 0, 0, 0.45); }
|
||||
.main { padding: 16px; }
|
||||
.collapse-btn, .sidebar-foot { display: none; }
|
||||
/* 抽屉态强制全宽+文字回归(collapsed 组合免疫) */
|
||||
.sidebar.open { width: 224px; padding: 16px 12px; }
|
||||
.sidebar.open .nav-item { justify-content: flex-start; padding: 8px 12px; }
|
||||
.sidebar.open { width: 256px; }
|
||||
.sidebar.open .nav-item { justify-content: flex-start; padding: 10px 14px 10px 17px; }
|
||||
.sidebar.open .nav-item .txt { display: inline; }
|
||||
.sidebar.open .nav-item.active::before { left: -12px; }
|
||||
.sidebar.open .nav-group { color: var(--gosms-text-muted); padding: 16px 12px 6px; }
|
||||
.sidebar.open .nav-group::after { display: none; }
|
||||
.sidebar.open .nav-group { padding: 16px 12px 8px; }
|
||||
}
|
||||
@media (min-width: 901px) { .nav-scrim { display: none; } }
|
||||
|
||||
/* ---- P3:全局键盘焦点可见性(只加强不重置;与 aurora 主色一致) ---- */
|
||||
:focus-visible {
|
||||
outline: 2px solid var(--gosms-primary);
|
||||
outline-offset: 2px;
|
||||
}
|
||||
/* ---- 键盘焦点可见性 ---- */
|
||||
:focus-visible { outline: 2px solid var(--gosms-primary); outline-offset: 2px; }
|
||||
|
||||
/* ============================================================
|
||||
* 基础重置(原 index.scss 职责并入)
|
||||
* 基础重置
|
||||
* ============================================================ */
|
||||
* { box-sizing: border-box; }
|
||||
html, body, #app { height: 100%; margin: 0; padding: 0; }
|
||||
body { font-variant-numeric: tabular-nums; }
|
||||
table, .el-table { font-variant-numeric: tabular-nums; }
|
||||
::selection { background: var(--gosms-primary-soft); }
|
||||
|
||||
/* ============================================================
|
||||
* 语义徽章/趋势胶囊/说明文字(原 semantics.scss 职责并入)
|
||||
* 语义徽章/趋势胶囊
|
||||
* ============================================================ */
|
||||
.sem-badge {
|
||||
display: inline-flex; align-items: center; gap: 6px;
|
||||
padding: 2px 10px; border-radius: 999px;
|
||||
font-size: 12px; line-height: 18px;
|
||||
font-size: var(--gosms-fs-xs); line-height: 18px;
|
||||
border: 1px solid transparent;
|
||||
}
|
||||
.sem-badge::before {
|
||||
content: ''; width: 6px; height: 6px; border-radius: 50%;
|
||||
background: currentColor;
|
||||
}
|
||||
.sem-badge--ok {
|
||||
color: var(--el-color-success);
|
||||
background: var(--el-color-success-light-9);
|
||||
border-color: var(--el-color-success-light-7);
|
||||
}
|
||||
.sem-badge--fail {
|
||||
color: var(--el-color-danger);
|
||||
background: var(--el-color-danger-light-9);
|
||||
border-color: var(--el-color-danger-light-7);
|
||||
}
|
||||
.sem-badge--pending {
|
||||
color: var(--el-color-warning);
|
||||
background: var(--el-color-warning-light-9);
|
||||
border-color: var(--el-color-warning-light-7);
|
||||
}
|
||||
.sem-badge--off {
|
||||
color: var(--gosms-text-muted);
|
||||
background: var(--el-fill-color-light);
|
||||
border-color: var(--gosms-border);
|
||||
}
|
||||
.hint { font-size: var(--gosms-fs-xs); color: var(--gosms-text-muted); line-height: 1.5; }
|
||||
.sem-badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
|
||||
.sem-badge--ok { color: var(--el-color-success); background: var(--el-color-success-light-9); border-color: var(--el-color-success-light-7); }
|
||||
.sem-badge--fail { color: var(--el-color-danger); background: var(--el-color-danger-light-9); border-color: var(--el-color-danger-light-7); }
|
||||
.sem-badge--pending { color: var(--el-color-warning); background: var(--el-color-warning-light-9); border-color: var(--el-color-warning-light-7); }
|
||||
.sem-badge--off { color: var(--gosms-text-muted); background: var(--el-fill-color-light); border-color: var(--gosms-border); }
|
||||
.trend-up, .trend-down, .trend-flat {
|
||||
display: inline-flex; align-items: center; gap: 3px;
|
||||
padding: 2px 9px; border-radius: 999px; font-size: var(--gosms-fs-sm);
|
||||
padding: 2px 9px; border-radius: 999px; font-size: var(--gosms-fs-xs);
|
||||
font-weight: 500; line-height: 16px; width: fit-content;
|
||||
}
|
||||
.trend-up { color: var(--el-color-success); background: var(--el-color-success-light-9); }
|
||||
|
||||
Reference in New Issue
Block a user