Commit eaaf03c
* refactor(spec,lint)!: 退役 dashboard widget 的 action 三键与 aria —— 连同那道「为不存在的按钮做引用完整性」的门 (#5010)
#4956 给 `DashboardWidgetSchema` 的 22 个 widget 级键补上首次逐键裁决,
其中 6 个 dead。本单处置其中 4 个(零 authored、零 renderer):
- `actionUrl` / `actionType` / `actionIcon` —— 描述的是一个「每个 widget 自己的
操作按钮」,而两个仓库里**没有任何渲染器画过它**。DashboardRenderer 里 14 处
`actionUrl` 全部限定在 `schema.header.actions[]`(DashboardHeaderAction,另一个
schema);`actionIcon` 更彻底,除自身声明外零引用。
- `aria` —— 声明的 ARIA 属性从未到达 DOM,与 #3896 删掉的看板级 `aria` 是同一种
「假合规」,只是低一层。
四个键躲过 #3896 sweep 的原因与 `widgets[].responsive` 相同:台账当时对
`dashboard.widgets` 没有 `children`,widget 级键**一个都没被分类过** —— 是仪器有
洞,不是键有豁免。
## 一并处置的二阶成本
`packages/lint` 的 `validate-dashboard-action-refs` 对 `widgets[].actionUrl` 做的是
**ERROR 级**引用完整性校验(目标解析不到就构建失败),docblock 自称
「the per-widget button」并声称镜像 objectui 运行时派发 —— 而那个按钮不存在。
于是作者可能因为一个**永远不会渲染**的控件指向一个不存在的 action 而被卡住构建。
一条为消灭「假affordance」而写的规则,自己维持着一个。widget 分支随键一起删除,
并留下 pin 测试保证它不会回来。
## 退役套件
- 四个 `retiredKey()` 墓碑(与同 schema 内 `responsive` 一致):tsc 报 `never`,
parse 抛出**处方**而非泛化的 unrecognized key;action 三键共用一条处方并互相点名。
- ADR-0087 D2 转换 + D3 链步 `dashboard-widget-action-aria-removed`
(`retiredFromLoadPath`),`os migrate meta --from 16` 自动改写。
- 台账四行**保留**(墓碑令键仍在被遍历的 shape 内 —— rls.priority 先例),
去掉 `authorWarn`/`authorHint`:严格 parse 接管,ledger-driven 的 CLI advisory
改为断言**静默**,并留 `colorVariant` 作阳性对照。
- `authorable-surface.json` 四行转 `[RETIRED]`;四张 ratchet 按构造不动
(无 def 停止 emit、无导出移除)。
`AriaPropsSchema` 本身**未删除** —— 仍活在 `app.aria` / `page.components[].aria`。
## 不在本单内
`widgets[].colorVariant`(第 5 个 dead 键)**刻意未动**:其改写目标
`options.colorVariant` 实测同样是死的 —— `options` 只在 inline 路径经
`componentSchema` 到达渲染器,而本 schema 的 `dataset` 是必填,故所有
spec 可授权 widget 均为 dataset-bound、走 DatasetWidget,而后者完全没有配色能力。
改写只会把 16 处 authored 从一个死槽搬到另一个死槽,并多造一个惰性键。交回裁决。
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Ehu85kbvMcrNTUJjwxvLJ9
* build(spec): 合并 origin/main 后按 os-regen 纪律重生成 authorable-surface
合并驱动把 `authorable-surface.json` 记为 pending(它不做文本合并),
从合并后的树整体重生成,补回 #5237 的 `ui/UserFilters:allowAddTab`。
9 张生成物全部 up to date。
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Ehu85kbvMcrNTUJjwxvLJ9
* docs(spec): 订正 WidgetActionTypeSchema 的一处陈述 —— 派发源是 header action
#5010 退役 widget 级 actionType 后,「a type added to ActionType is
dispatchable from a widget」不再成立;唯一消费者是 DashboardHeaderActionSchema。
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Ehu85kbvMcrNTUJjwxvLJ9
---------
Co-authored-by: Claude <noreply@anthropic.com>
1 parent 108ba8d commit eaaf03c
16 files changed
Lines changed: 534 additions & 94 deletions
File tree
- .changeset
- content/docs
- deployment
- references/ui
- docs
- audits
- packages
- lint/src
- spec
- liveness
- src
- conversions
- migrations
- ui
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | | - | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
68 | 76 | | |
69 | 77 | | |
70 | 78 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
98 | 98 | | |
99 | 99 | | |
100 | 100 | | |
101 | | - | |
102 | | - | |
103 | | - | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
104 | 104 | | |
105 | 105 | | |
106 | 106 | | |
| |||
111 | 111 | | |
112 | 112 | | |
113 | 113 | | |
114 | | - | |
| 114 | + | |
115 | 115 | | |
116 | 116 | | |
117 | 117 | | |
| |||
0 commit comments