feat(client/ios): iPad tablet 正式适配——断点≥900 对齐设计源 + tablet golden 回归闸

- form_factor 触屏 tablet 阈值 600→900,对齐 design/ui_kits/tablet(1180×820 横屏
  侧栏):iPad 横屏/12.9″竖屏走侧栏,标准/11″竖屏回落 mobile 底 Tab,避免双栏挤压
- form_factor_test 补全断点边界(900/899)与各 iPad 尺寸用例
- 新增 tablet_pages_golden_test:四视图×明暗×中英 12 张 golden,注入演示数据
  (6 节点/周流量/30 天用量)让 2 列网格与周柱满渲染,作回归闸
- design/CONTRACT.md:tablet 像素契约(取自 tabapp.jsx)+ 逐屏验收清单
- 真机 iPad mini 6 视觉签核通过;141 测试全绿

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
wangjia
2026-06-23 10:00:14 +08:00
parent 11ee3342bf
commit e25649cd27
16 changed files with 254 additions and 5 deletions
+6 -2
View File
@@ -20,11 +20,15 @@ bool get _isDesktopPlatform {
}
extension FormFactorContext on BuildContext {
/// 当前形态。桌面平台(macOS/Win/Linux)且宽≥680 → desktop;触屏/Web 宽≥600 → tablet;否则 mobile。
/// 当前形态。桌面平台(macOS/Win/Linux)且宽≥680 → desktop;触屏/Web 宽≥900 → tablet;否则 mobile。
///
/// tablet 阈值 900 对齐 iPad 设计源(design/ui_kits/tablet1180×820 横屏侧栏布局,
/// README 定「宽 ≥900 才从底部 Tab 切侧栏」)iPad 横屏/大屏(12.9″竖屏)→ 侧栏 tablet
/// 小 iPad 竖屏(≤834)→ 回落 mobile 底 Tab,避免双栏在窄屏挤压。
FormFactor get formFactor {
final w = MediaQuery.sizeOf(this).width;
if (_isDesktopPlatform) return w >= 680 ? FormFactor.desktop : FormFactor.mobile;
if (w >= 600) return FormFactor.tablet;
if (w >= 900) return FormFactor.tablet;
return FormFactor.mobile;
}