Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
72 changes: 28 additions & 44 deletions .artifacts/1843/state-coverage.json
Original file line number Diff line number Diff line change
@@ -1,60 +1,44 @@
{
"task": "1843-tab-proportional-restore",
"task": "1843-tab-fixed-width-ellipsis",
"states": [
{
"state": "01-wide-equal",
"screenshot": "04-wide-equal.png",
"state": "01-long-ellipsis",
"screenshot": ".artifacts/1843/01-long-ellipsis.png",
"assertion": "passed",
"widths": [
269.5,
269.5,
269.5,
269.5
],
"clientWidth": 1238,
"scrollWidth": 1238,
"gap": "32px"
"width": 256,
"tabMax": 256,
"ellipsis": true
},
{
"state": "02-narrow-shrink",
"screenshot": "05-narrow-equal-shrink.png",
"state": "02-short-actual",
"screenshot": ".artifacts/1843/02-short-actual.png",
"assertion": "passed",
"widths": [
144.5,
144.5,
144.5,
144.5
],
"clientWidth": 738,
"scrollWidth": 738,
"gap": "32px"
"shortWidths": [
130,
133
]
},
{
"state": "03-floor-scroll",
"screenshot": "06-floor-scroll.png",
"state": "03-not-fill-tail",
"screenshot": ".artifacts/1843/03-not-fill-tail.png",
"assertion": "passed",
"widths": [
96,
96,
96,
96,
96,
96
],
"clientWidth": 538,
"scrollWidth": 800,
"gap": "32px"
"clientWidth": 1238,
"usedWidth": 519
},
{
"state": "04-single-tab",
"screenshot": "07-single-tab.png",
"state": "04-narrow-shrink",
"screenshot": ".artifacts/1843/04-narrow-shrink.png",
"assertion": "passed",
"widths": [
974
"wide": [
256,
130,
133
],
"clientWidth": 1038,
"scrollWidth": 1038,
"gap": "32px"
"narrow": [
256,
106,
108
]
}
]
}
}
1 change: 0 additions & 1 deletion docs/design/system/decisions.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,6 @@ ledger: append-only
| 图标纪检高频 18px 裁决(批次) | 11 个高频 18px 图标逐个对照 spec §2.1(24 网格 / ≤6 笔画 / 尺寸档)、§2.2(`fill="currentColor"`,描边写 `fill="none"` + `stroke-width 1.7`,禁止内联一次性 SVG)、§2.4(可逆动作成对)后**全部维持现状**:无面/线混用、无第四档尺寸、无单向孤儿;明细见本行下方表 | ui-quality-primitives-v1 / 2.5 / #1711 | 2026-11-28 |
| 信息窗复制图标弱化档 | 新增 `--app-text-4`(spec §6 文本弱化档):信息窗复制路径 / 复制文件两图标默认色由 `--app-text-3` 降为该档,hover 提亮到 `--app-text`;该档仅用于低干扰辅助图标静息态,不用于任何文本;标题与路径保持左对齐 | editor-surface-batch24 / #1856 | 2026-11-30 |
| 画面按钮图标定案 | 取代台账「画面图标(#486):图片框构图(山与太阳)」行:控制条「画面」按钮改用「显示器 + 播放三角」(外框 + 底座 + 三角,单 `s` path,§2.1 安全区 / ≤6 笔画);新增 `visual` 概念键,与 `video` 文件类型图标(外框 + 三角)不同构图、不复用 path;两套图标源 + e2e mock 三处同步 | editor-surface-batch24 / #1857 | 2026-11-30 |
| 页签等比伸缩恢复 | #1843 恢复 #1180 等比伸缩(`flex: 1 1 0` 等分可用宽度 + `--tab-min-width` 96px 保底 + 溢出横向滚动),supersede #1231「不伸展 + 256px 上限」;`calc-size()` 因 WebKit/WKWebView 不支持移除,`--tab-max-width` 退役不再约束页签宽度 | fix/1843-tab-proportional-restore / #1843 | 2026-12-02 |

**图标纪检 18px 高频裁决明细(11 行,spec §2.1 / §2.2 / §2.4)**

Expand Down
12 changes: 6 additions & 6 deletions docs/design/system/spec.md
Original file line number Diff line number Diff line change
Expand Up @@ -261,19 +261,19 @@ token 缺失时组件按 `var(--sf-ctrl-height, 27px)` 回落,不静默失效

旧值 320px 自本条款起作废,不得再使用。

### 7.5 页签等比伸缩与最小宽度保底(`--tab-min-width` / `--tab-max-width`)
### 7.5 页签最小宽度保底与最大宽度上限(`--tab-min-width` / `--tab-max-width`)

多页签在页签条内**等比分配**可用宽度:`flex: 1 1 0`——随页签条变窄/变宽整体同比例伸缩、页签之间等宽(激活页签字重导致的数像素差允许)。收缩下限 `--tab-min-width`(96px)保底;页签条可用宽度低于「全部页签保底之和 + 相邻间距」时,页签不再压缩,由页签条横向滚动接管。标题在分配到的宽度内以省略号收尾、单行不换行。
多页签在页签条内弹性伸缩;页签**不伸展**(`flex: 0 1 auto`),宽度按内容自适应,上限 `--tab-max-width`。收缩下限 `--tab-min-width` 的保底语义为「下限 min(96px, 内容宽)」——短名按实际宽度,不被撑到 96px。页签条可用宽度低于「全部页签保底之和 + 相邻间距」时,页签不再压缩,由页签条横向滚动接管。

| 规范值 | 值 | 用途 |
|---|---|---|
| `--tab-min-width` | 96px | 页签收缩下限保底;等比分配不低于此值,击穿后由横向滚动接管 |
| `--tab-max-width` | `var(--tab-info-width)`(256px) | **退役,不再用于页签宽度上限**(等比模型下无内容宽上限) |
| `--tab-min-width` | 96px | 页签收缩下限(与内容宽取 min);短名按实际宽度,不被撑到 96px |
| `--tab-max-width` | `var(--tab-info-width)`(256px) | 页签最大宽度上限;页签不伸展,超出以省略号收尾 |
| `--tab-strip-tail` | 24px | 页签条尾部保留的空白区;承载空白处拖窗与双击切全屏,不随页签伸缩吃掉 |

取值依据:页签内容最小可读宽度 = 左右内距 20px(`px-2.5`)+ 类型图标 20px(18px 图标 + 2px 右间距)+ 标题两侧间隙 12px(`gap-1.5` × 2)+ 关闭钮约 16px + 标题最短可读约 28px(12px 字号下 2–3 个中文字)≈ 96px。保底被击穿后页签条 `overflow-x-auto` 接管:全部页签保持 96px 不再收缩,横向滚动查看。
取值依据:页签内容最小可读宽度 = 左右内距 20px(`px-2.5`)+ 类型图标 20px(18px 图标 + 2px 右间距)+ 标题两侧间隙 12px(`gap-1.5` × 2)+ 关闭钮约 16px + 标题最短可读约 28px(12px 字号下 2–3 个中文字)≈ 96px。保底被击穿后页签条 `overflow-x-auto` 接管:长标题页签保持 96px 不再收缩,短名页签保持其内容宽度。

本条款取代旧「页签标题最大显示宽度 120px」与 #1231「不伸展 + 256px 上限」口径;页签恢复 #1180 等比伸缩模型(见 [decisions.md](./decisions.md) 最新行)。
本条款取代旧「页签标题最大显示宽度 120px」口径;120px 固定上限仍退役,现以 `--tab-max-width`(引用 `--tab-info-width`,256px)作为**弹性上限**重新存在——页签不伸展,宽度按内容自适应并被该上限钳制(见 [decisions.md](./decisions.md) 最新行)。

### 7.6 属性面板日期选择器密度(`--dpb-cal-*`)

Expand Down
Loading
Loading