fix(mobile): 移动端全站横向溢出修复——Header 三档断点与长词断行

- B1(移动审计 blocker):Header 7 项一行在 390px 溢出 51-88px(主题钮
  被推出屏、整页可晃——用户实测报告的"布局存在问题"实锤)→ 430px
  断点收紧(字号/边距/间隙/图标钮 32px)+ 370px 末档(en Open Source
  长词)
- M1:.prose-tech 补 overflow-wrap:break-word(裸长 URL 曾撑破 88px,
  只给了书评轨是漏)
- m1:ProjectWall 标题 i18n(en 页曾硬编码中文)+ locale prop
- m3:列表标题两行钳制(en 长标题截断丢信息);m4:页脚/pn/书架
  触控目标 ≥24px
- 已知边界:320px 超窄屏 en 仍溢 23px(超出现实机型范围,记录不改)

验证: 移动溢出回归 390/360 × 12 页全过(scrollWidth 断言,曾全站
      51-118px);E2E 30/30 PASS;技术文长 URL 页 +88→0

Spec: 2026-10-25_add-blog-5c

Co-authored-by: GLM-5.3
This commit is contained in:
wait4xandGLM-5.3 committed 2026-10-25 19:46:06 +08:00
1 parent 147f00fe1c
commit 2802278be6
6 files changed
+36 -6

No files matched your search

+7 -2
View File
@@ -3,11 +3,16 @@
// 双源数据见 src/lib/projects.ts;语言色点用 linguist 常用色映射
import { loadProjects, type RepoCard } from '../../lib/projects';
import { t } from '../../i18n/ui';
import type { Locale } from '../../lib/locale';
interface Props {
/** 展示上限:首页精选 6;/opensource 全量传大数 */
limit?: number;
locale?: Locale;
}
const { limit = 6 } = Astro.props;
const { limit = 6, locale = 'zh' } = Astro.props;
const title = t('open_source_projects', locale);
const LANG_COLORS: Record<string, string> = {
Astro: '#ff5a03', TypeScript: '#3178c6', JavaScript: '#f1e05a',
Python: '#3572a5', Go: '#00add8', Rust: '#dea584', Shell: '#89e051',
@@ -23,7 +28,7 @@ try {
---
<section class="project-wall" aria-label="开源项目">
<h2 class="wall-title">开源 · Projects</h2>
<h2 class="wall-title">{title}</h2>
<ul>
{projects.map((p) => (
<li>