Skip to content

docs(protocol): widget-contract.mdx 仍在教 PerformanceConfig —— 该 schema 已被 #3896 删除 #4996

Description

@xuyushun441-sys

路过发现,不在 #4876 范围内,按 Prime Directive #10 立案不指派、不顺车修。

现象

content/docs/protocol/objectui/widget-contract.mdx:309(「Performance」小节)逐字写着:

Performance tuning is supplied through the shared PerformanceConfig schema (packages/spec/src/ui/responsive.zod.ts) on the manifest's performance field. Use it for options such as virtualization and lazy rendering for widgets that handle large datasets.

而它指向的那个 schema 已经不存在了packages/spec/src/ui/responsive.zod.ts:110 现在是一条墓碑注释:

REMOVED — `PerformanceConfigSchema` / `PerformanceConfig` (#3896 audit …

packages/spec/src/ui/responsive.test.ts:90 同样记着「PerformanceConfigSchema tests removed with the schema (#3896 close-out)」。#3896 那次 sweep 一并退役了 view.performance / dashboard.performance / dashboard.widgets[].performance

该文件不是生成物(packages/spec/scripts/ 里没有任何生成器写它),所以没有闸门会自动纠正它 —— 这也是它能活下来的原因。

为什么值得修

这段话把一个已删除的 schema 描述成「共享的、可用的」,还给出了它当年所在的确切文件路径。照着读的作者(很可能是 AI,ADR-0033)会去 import 一个 v17 里 TS2305 的名字,或者在 manifest 上写一个没有任何东西会读的 performance 字段 —— 正是 ADR-0049 想消灭的「声明 ≠ 兑现」。

需要决定的地方(所以没有直接改)

「manifest 的 performance 字段」说的是 objectui 的 widget manifest 契约,不一定等同于被 #3896 退役的那三个 spec 键。所以正确处置有两种,取决于 objectui 侧那个 manifest 字段今天是否还活着:

需要 objectui 分片确认一句再动笔,不宜由本仓单方面猜。

复现

grep -n 'PerformanceConfig' content/docs/protocol/objectui/widget-contract.mdx
grep -n 'PerformanceConfigSchema' packages/spec/src/ui/responsive.zod.ts

发现于 #4876(退役 dashboard.widgets[].responsive)的文档面清扫;基线 objectstack@c5adfe15a6


Generated by Claude Code

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions