fix(a11y): ink-400 对比度达标,接入 Noto Serif SC webfont,补纸张噪点与入场编排

- ink-400 #9C9587(2.90:1)→ #756F61(paper-50 4.87:1 / paper-100 4.55:1),正文级小字全部达标
- serif 栈插入 Noto Serif SC(fontsource 子集加载),Windows 不再跌进 SimSun
- 首页加 feTurbulence 纸张噪点层(.grain);报头/赛程行/预测版 rise-in 错峰入场(60ms 步进)
- reduce 动效用户:隐藏态与动画同在 no-preference 块,不会白屏
- Switch 提到模块顶层(修 render 重建丢焦点);a→Link(SPA 内链);h3→h2/h4→h3 修标题层级
- 按钮/输入热区抬高(btn 40px / btn-sm 32px / field py-2);index.css 硬编码色值改 :root 令牌
This commit is contained in:
shangfangjian
2026-09-18 11:04:46 +08:00
parent cf0751d1ff
commit 1a37c75907
8 changed files with 116 additions and 52 deletions
+7 -7
View File
@@ -6,7 +6,7 @@
*/
import { useState, useEffect, useCallback } from 'react'
import { NavLink, Outlet, useLocation } from 'react-router-dom'
import { NavLink, Link, Outlet, useLocation } from 'react-router-dom'
import { fetchHealth } from './dal'
const NAV_ITEMS = [
@@ -133,13 +133,13 @@ export default function AdminLayout() {
{/* 底部 */}
<div className="border-t border-ink-200 px-4 py-3">
<a
href="/"
<Link
to="/"
className="flex min-h-[44px] items-center gap-2 text-xs text-ink-500 transition-colors hover:text-press"
>
<span aria-hidden="true"></span>
</a>
</Link>
</div>
</aside>
@@ -170,13 +170,13 @@ export default function AdminLayout() {
/>
{healthOk === null ? '检测中' : healthOk ? '系统正常' : '系统异常'}
</span>
<a
href="/"
<Link
to="/"
className="text-press transition-colors hover:text-press-dark sm:hidden"
aria-label="返回前台"
>
</a>
</Link>
</div>
</header>