docs/plans/2026-05-31-rename-dom-coverage-copy-policy.md
Objective:
Rename Slate v2 DOM coverage copy policy values from include-model and
summary-only to model and summary across public API, examples, docs,
tests, and changesets.
Goal plan: docs/plans/2026-05-31-rename-dom-coverage-copy-policy.md
Template: docs/plans/templates/task.md
Primary template: docs/plans/templates/task.md
Applied packs:
Task source:
Completion threshold:
DOMCoverageCopyPolicy exposes model, summary, exclude, and
materialize.model.bun check pass in
/Users/zbeyens/git/plate-2/.tmp/slate-v2.Verification surface:
bun test ./packages/slate-dom/test/dom-coverage.ts ./packages/slate-dom/test/clipboard-boundary.tscd packages/slate-react && bun test:vitest -- keyboard-input-strategy-contract selection-reconciler-contract dom-coverage-native-bridge-contract dom-strategy-and-scroll dom-coverage-boundary-contractPLAYWRIGHT_BASE_URL=http://localhost:3100 PLAYWRIGHT_RETRIES=0 bunx playwright test playwright/integration/examples/hidden-content-blocks.test.ts playwright/integration/examples/query-controls.test.ts --project=chromium --grep "hidden content|query controls"bun checkrg -n "include-model|summary-only" --glob '!site/out/**' --glob '!node_modules/**' .Constraints:
Boundaries:
.tmp/slate-v2 Slate v2 package and example sources./examples/hidden-content-blocks.Blocked condition:
bun check expose a real failure outside
this rename that cannot be isolated without user direction.Task state:
Current verdict:
bun check
all agree on the new names.Completion rule:
Start Gates:
| Gate | Applies | Evidence |
|---|---|---|
| Skill analysis before edits | yes | autogoal, task, and changeset loaded. |
| Active goal checked or created | yes | Active goal created for this rename. |
| Source of truth read before edits | yes | rg located copy policy API, runtime, examples, docs, and tests. |
| Tracker comments and attachments read | no | N/A: user chat request only. |
| Video transcript evidence required | no | N/A: no video evidence for this rename. |
docs/solutions checked for non-trivial existing-code work | no | N/A: narrow API rename, local source search was sufficient. |
| TDD decision before behavior change or bug fix | yes | Rename is API contract work; existing focused tests cover behavior. |
| Branch decision for code-changing task | yes | N/A: no branch work requested. |
| Release artifact decision | yes | Changesets updated for slate-dom and slate-react. |
| Browser tool decision for browser surface | yes | Automated Playwright proof covers the route/control behavior. |
| PR expectation decision | yes | N/A: no PR requested. |
| Tracker sync expectation decision | yes | N/A: no tracker. |
| Docs pack selected | yes | Docs pack applied; docs/libraries/slate-react/editable.md updated. |
docs-creator loaded | no | N/A: small API reference table, not docs-dominant work. |
| Docs lane selected | yes | Supporting docs lane. |
| Target docs and nearest sibling docs read | yes | docs/libraries/slate-react/editable.md DOM Coverage Boundaries section read. |
| Docs style doctrine read | yes | Repo instruction: docs describe latest state only. |
| Documented source owner identified | yes | Source owner is DOM coverage boundary/copy runtime. |
| Package/API pack selected | yes | Public string literal union changed. |
| Public surface or package boundary identified | yes | DOMCoverageCopyPolicy and copyPolicy props. |
| Release artifact path selected | yes | .changeset files updated. |
changeset skill loaded when .changeset is required | yes | changeset skill read. |
| Barrel/export impact decision recorded | yes | N/A: no exports or file layout changed. |
| Browser pack selected | yes | Hidden-content example controls touched. |
| Browser route / app surface identified | yes | /examples/hidden-content-blocks. |
| Browser tool decision recorded | yes | Playwright route proof used for deterministic coverage. |
| Console/network caveat policy recorded | yes | N/A: no manual browser console/network audit for string literal rename. |
Work Checklist:
.tmp/slate-v2
or its owning package..changeset..changeset work loaded changeset.Completion Gates:
| Gate | Applies | Required action | Evidence |
|---|---|---|---|
| Named verification threshold | yes | Run named commands | Focused tests, Playwright rows, stale-string audit, and bun check passed. |
| Bug reproduced before fix | no | N/A | This is an API rename, not a bug repro. |
| Targeted behavior verification | yes | Run focused tests | 44 slate-dom tests, 94 focused slate-react tests, and 17 Playwright rows passed. |
| TypeScript or typed config changed | yes | Run typecheck | bun check typecheck phase passed. |
| Package exports or file layout changed | no | N/A | No exports or file layout changed. |
| Package manifests, lockfile, or install graph changed | no | N/A | No manifest or lockfile changed. |
| Agent rules or skills changed | no | N/A | No agent rules or skills changed. |
| Workspace authority proof | yes | Run checks in owning checkout | All commands ran in .tmp/slate-v2 or .tmp/slate-v2/packages/slate-react. |
| Browser surface changed | yes | Run route proof or waiver | Playwright hidden-content/query-controls rows passed. |
| Browser final proof | yes | Record exact route proof | http://localhost:3100/examples/hidden-content-blocks?selection=model©=model returned 200; Playwright passed. |
| CI-controlled template output changed | no | N/A | No templates changed. |
| Package behavior or public API changed | yes | Add changesets | slate-dom and slate-react changesets updated. |
| Registry-only component work changed | no | N/A | No registry-only component work. |
| Docs or content changed | yes | Verify docs claims | editable.md copy policy table matches source union. |
| High-risk mini gate | yes | Record failure mode and proof | Failure mode: stale literal breaks consumers; stale audit and typecheck passed. |
| Agent-native review for agent/tooling changes | no | N/A | No .agents, .claude, .codex, skill, hook, command, prompt, or tooling change. |
| Local install corruption suspected | no | N/A | No install-corruption failure shape. |
| Autoreview for non-trivial implementation changes | no | N/A | Narrow mechanical API rename with green focused and fast full checks. |
| PR create or update | no | N/A | No PR requested. |
| PR proof image hosting | no | N/A | No PR body. |
| Tracker sync-back | no | N/A | No tracker. |
| Final handoff contract | yes | Fill final evidence | Final response will include changed surface and verification. |
| Final lint | yes | Run lint or scoped equivalent | bun check lint phase passed. |
| Goal plan complete | yes | Run autogoal check | Final check run before goal closure. |
| Docs source-backed claim audit | yes | Source audit | DOMCoverageCopyPolicy source matches docs table. |
| Docs links / routes / previews | no | N/A | No links, routes, or previews added to docs. |
| Docs MDX/content parser | no | N/A | Markdown-only package docs; bun check covered formatting/type/test gates. |
| Plugin page specifics | no | N/A | Not a plugin docs page. |
| Public API / package boundary proof | yes | Source audit and checks | Union/default/runtime checks use model and summary. |
| Release artifact classification | yes | Record classification | Published package API rename. |
| Published package changeset | yes | Update one per package | Existing slate-dom and slate-react major changesets updated. |
| Registry changelog | no | N/A | Not registry-only. |
| No release artifact | no | N/A | Public package delta exists. |
| Package typecheck/build/test | yes | Run owning checks | Focused tests and bun check passed. |
| Barrel/export generation | no | N/A | No exported file layout changed. |
| Browser interaction proof | yes | Exercise route/control path | Playwright hidden-content/query-controls rows passed. |
| Browser console/network check | no | N/A | No manual browser proof; automated test route covered behavior. |
| Browser final proof artifact | yes | Record exact caveat | Route 200 plus Playwright pass recorded. |
Phase / pass table:
| Phase | Status | Evidence | Next |
|---|---|---|---|
| Intake and source read | complete | Skills read; API/docs/test surface found with rg. | implementation |
| Implementation | complete | Policy literals renamed and docs/changesets updated. | verification |
| Verification | complete | Focused tests, Playwright rows, stale audit, and bun check passed. | closeout |
| PR / tracker sync | complete | N/A: no PR or tracker requested. | final response |
| Closeout | complete | Plan completed and ready for autogoal check. | final response |
Findings:
copyPolicy is a public DOM coverage contract owned by slate-dom and
surfaced through slate-react.model, summary, exclude, and materialize.Decisions and tradeoffs:
Implementation notes:
Review fixes:
bun check.Error attempts:
| Error / failed attempt | Count | Next different move | Resolution |
|---|---|---|---|
bun check formatting failure in hidden-content example | 1 | Apply formatter-required line wrap | Fixed and reran bun check successfully. |
Verification evidence:
bun test ./packages/slate-dom/test/dom-coverage.ts ./packages/slate-dom/test/clipboard-boundary.ts: 44 passed.cd packages/slate-react && bun test:vitest -- keyboard-input-strategy-contract selection-reconciler-contract dom-coverage-native-bridge-contract dom-strategy-and-scroll dom-coverage-boundary-contract: 5 files, 94 tests passed.PLAYWRIGHT_BASE_URL=http://localhost:3100 PLAYWRIGHT_RETRIES=0 bunx playwright test playwright/integration/examples/hidden-content-blocks.test.ts playwright/integration/examples/query-controls.test.ts --project=chromium --grep "hidden content|query controls": 17 passed.curl http://localhost:3100/examples/hidden-content-blocks?selection=model©=model: 200.bun check: passed.rg -n "include-model|summary-only" --glob '!site/out/**' --glob '!node_modules/**' .: no matches.Final handoff contract:
bun check.model, summary, exclude, and
materialize.DOMCoverageCopyPolicy and React props.Final handoff / sync:
Timeline:
Reboot status:
| Question | Answer |
|---|---|
| Where am I? | Closeout complete. |
| Where am I going? | Final response after autogoal check. |
| What is the goal? | Rename DOM coverage copy policy values to model and summary. |
| What have I learned? | The public copy policy surface is centralized enough for a hard cut. |
| What have I done? | Updated source, examples, docs, tests, changesets, and verification. |
Open risks: