Repository navigation
Commit 1434bb4
feat(plugin-kanban)!: retire the unwired useColumnWidths hook and its storage key (objectui#8522) (#10549)
Fixes #8522
Clause-②: yes — a published export (`useColumnWidths` and its two types)
is removed.
Executes ruling `5810224713` (remove: reading 2 of the card, superseded
and left behind). Dispatched by the `domain:ui` seat 2 PM; implemented
by its `os-dev` in session
`https://claude.ai/code/session_014mXUNuFomfj24w7s1pZzhN`.
## What changed
- `packages/plugin-kanban/src/useColumnWidths.ts` deleted: the hook,
`UseColumnWidthsOptions`, `UseColumnWidthsReturn`, and its storage key
`objectui:kanban-column-widths`.
- `packages/plugin-kanban/src/index.tsx`: the three entry exports
removed (the `useColumnWidths` value export and the two-type `export
type` line).
- `@object-ui/types` docblocks, comment-only hunks:
- `complex.ts`, the bare-`kanban` retirement docblock: the "NOT retired"
sentence no longer names the hook as a consumer. `KanbanCard` /
`KanbanColumn` / `CardTemplate` keep the renderer and `CardTemplates` as
consumers, and `ColumnWidthConfig` is recorded as having lost its one
`plugin-kanban` reader to this card, which did not rule on the type.
- `objectql.ts`, the `ObjectKanbanSchema` lane "member set is the READ
set" paragraph: the hook is dropped from the list of read sites. The
hook destructured `columns` as `_columns` and read no lane member, so
the counted member set does not move.
- `kanban-plugin-dialect-authoritative-7664.test.ts`: the pin-1 comment
stops naming the hook. No assertion changed.
- New pin
`packages/plugin-kanban/src/__tests__/useColumnWidthsRetired-8522.test.ts`,
following the `plugin-form` `entrySurface-6059` barrel-pin pattern
(`import * as entry` + `Object.keys(entry)`) and the `spec-symbol-4650`
compile-time `import('..').X` + `@ts-expect-error` pattern.
- `.changeset/8522-retire-use-column-widths.md`:
`'@object-ui/plugin-kanban': minor`, with a BREAKING body in migration
terms. There is no `@object-ui/types` entry: `check-changeset-presence`
asks for presence only, and the types hunks are comment-only. Its last
migration bullet names objectui#7742.
- `.changeset/7742-kanban-arm-batch70.md`, a pending changeset that this
change falsifies, is reconciled here in prose only:
- The sentences naming the `useColumnWidths` widths channel, and saying
the prop and the hook consume the types, are scoped to "at this change".
- A dated note (2026-09-25) records that the hook is retired
(objectui#8522), that `ColumnWidthConfig` has no `plugin-kanban` reader,
and that `CardTemplate` is still consumed by the `CardTemplates`
component's `templates` prop.
- The frontmatter is byte-identical: md5 of the frontmatter block is
`b62313df8fb2af929fbe2c21c5ae3873` before and after.
No tests were deleted. No test existed only to test the hook: the
tracked tree had zero test importers of it.
## Premise, measured on `origin/main` `d461b0de8`
- Readers. `git grep` over `packages apps examples content skills` found
`useColumnWidths` 7 hits in 5 files, `UseColumnWidths` 4 hits in 2
files, and `kanban-column-widths` 1 hit in 1 file. Every hit was the
hook's own file, the entry, the two docblocks, or the 7664 comment. On
the same instrument, the control `useCrossSwimlaneMove` fired with 5
hits in 3 files. Zero readers holds.
- Published surface. H3 answers yes. `@object-ui/plugin-kanban@17.6.0`
from the npm registry exports the hook in its `dist/index.js` export
list as `Ue as useColumnWidths`, and `dist/index.d.ts` re-exports it and
both types. The storage-key literal is present in `dist/index.js` and
`dist/index.umd.cjs`. That is why the changeset is written as a
migration.
- A tree-wide grep found one more carrier outside the file surface: the
pending changeset `.changeset/7742-kanban-arm-batch70.md`. It names "a
`useColumnWidths` hook option for widths" and says "the prop and the
hook still consume the types". Both go false when this merges, and both
would publish into the same release, so this PR reconciles it (see
above).
- A re-grep of every pending `.changeset/*.md` for `useColumnWidths`,
`UseColumnWidths` and `kanban-column-widths` hits only 7742 and this
PR's own changeset.
- The control `CardTemplate` hits 3 files on the same instrument.
- The two `7664-*` changesets that name `ColumnWidthConfig` claim only
that it is declared and re-exported, which remains true.
## Verification
The code legs below ran on `e62e390f4`. The only later commit,
`8be30d7fc`, edits changeset prose only; the changeset gates were re-run
on it.
- Build, under the verify lock: `pnpm --workspace-concurrency=2 --filter
'@object-ui/plugin-kanban...' build` printed `VERDICT command-exit 0`.
The rebuilt `plugin-kanban/dist` has `useColumnWidths` 0 and
`kanban-column-widths` 0 in `index.js`, `index.d.ts` and
`index.umd.cjs`, and no `useColumnWidths.d.ts`. The control
`useCrossSwimlaneMove` is 2 / 2 / 1.
- `pnpm --filter @object-ui/plugin-kanban type-check` (`tsc --noEmit &&
tsc -p tsconfig.test.json`) exits 0. `tsc -p tsconfig.test.json
--listFilesOnly` lists the new pin, so the compile-time half is
compiled.
- `pnpm --filter @object-ui/types type-check` (including
`tsconfig.examples.json` and `tsconfig.test.json`) exits 0.
- `pnpm exec vitest run --maxWorkers=2 packages/plugin-kanban/` reports
`Test Files 61 passed (61)` and `Tests 412 passed (412)`. That is 61
tracked test files: 60 on base plus the new pin.
- `pnpm exec vitest run --maxWorkers=2 packages/types/` reports `Test
Files 233 passed (233)` and `Tests 5184 passed (5184)`.
- Red on base. The base `index.tsx` and `useColumnWidths.ts` were
written back onto disk. The landing was checked on disk: the entry had
`useColumnWidths` twice and the hook file was present with its key.
Under a `trap` restore:
- vitest: `Tests 1 failed | 1 passed (2)`, with `AssertionError:
expected [ 'KANBAN_UNCOLUMNED_ID', …(10) ] to not include
'useColumnWidths'`. The failure is the runtime pin; the type-only test
is erased at runtime.
- `tsc -p tsconfig.test.json` exits 2 with `error TS2578: Unused
'@ts-expect-error' directive.` twice, once on each retired type query.
- After restore, the `index.tsx` blob matches HEAD `7e09f2d92`, the hook
file is absent, and `git diff HEAD` and `git status --porcelain` are
both empty.
- Changeset and prose gates, on `8be30d7fc`:
- `node scripts/check-changeset-presence.mjs` printed `✅ 6 source
file(s) of 2 released package(s) changed, and this change declares 1
changeset(s)`.
- `node scripts/check-changeset-overwrite.mjs` exited 0 (report-only).
It printed `1 changeset(s) added, 1 modified, 0 deleted`. For 7742 it
printed `declared at base: @object-ui/types: minor,
@object-ui/plugin-kanban: minor` and `declares now: @object-ui/types:
minor, @object-ui/plugin-kanban: minor`.
- `node scripts/check-changeset-claims.mjs` exited 0 (report-only),
reading `Corpus: 2 changeset(s) this change adds or modifies` with no
self-contradiction. It listed 27 pending changesets that name
`complex.ts` or `objectql.ts`; none of them names the hook.
- `node scripts/check-pending-changeset-literals.mjs` printed `✅ No test
source names a pending changeset`.
- `node scripts/check-changeset-no-major.mjs` printed `✅ No changeset
declares a major bump`.
- `node scripts/check-new-cross-file-line-citations.mjs` printed
`VERDICT new-cross-file-line-citations: 0 new citation(s)`.
- `node scripts/check-control-bytes.mjs` passed.
- Source gates, on `e62e390f4`. These exited 0:
`check:unreferenced-sources`, `check:self-import`,
`check:side-effects-array`, `check:handler-key-reads`,
`check:entry-guard`, `check:phantom-deps`, `check:unused-deps`,
`check:test-path-roots`, `check:vi-mock-specifiers`,
`check:spec-symbols` and `check:esm-specifiers`.
- `check:readme-exports` passed after the build. No README names any of
the three removed exports.
- ESLint on the 5 touched text files (`--no-inline-config --format
json`): 0 errors. The 66 warnings are pre-existing `no-explicit-any` /
`react-refresh` warnings in untouched lines, and there are none in the
new pin.
- NOT MEASURED:
- `check:sdui-registration-pins`: it needs an `apps/console` build and
exits 2 without one. No registration changed here.
- `check:published-dist`: its turbo build of the whole workspace,
`apps/console` included, was killed by my 300s timeout (exit 124). It
was run outside the verify lock by mistake. That is declared to CI.
## Overlap
The one `types/src/objectql.ts` hunk here is the one-line docblock edit
in the `ObjectKanbanSchema` lane paragraph. objectui#10533 and #10522,
which also edited that file while this PR was being written, have since
merged, and this hunk still applies on `main`. At landing, the open PRs
that edit `objectql.ts` are objectui#10550, #10546 and #8941, and all
three are hunk-disjoint from this edit.
## Acceptance notes
- After this change, `ColumnWidthConfig` (in `@object-ui/types`,
re-exported by `plugin-kanban`, and mirrored by
`ColumnWidthConfigSchema`) has no reader in `plugin-kanban`. The ruling
named the hook, its exports and its key, not the type, so the type
stays. Recorded here only: there is no reproducible defect, and nobody
is known to own it next.
- The 7664 pin-1 comment still says `KanbanColumn` / `KanbanCard` are
consumed by `CardTemplates`. The `CardTemplates` component consumes
`CardTemplate`, not those two. That wording predates this change and is
kept, because the dispatch limits this file to removing the hook's name.
---
_Generated by [Claude
Code](https://claude.ai/code/session_014mXUNuFomfj24w7s1pZzhN)_
---------
Co-authored-by: Claude <noreply@anthropic.com>1 parent f94cfa5 commit 1434bb4
8 files changed
Lines changed: 107 additions & 139 deletions
File tree
- .changeset
- packages
- plugin-kanban/src
- __tests__
- types/src
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
35 | 40 | | |
36 | 41 | | |
37 | 42 | | |
| |||
| 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 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
72 | 72 | | |
73 | 73 | | |
74 | 74 | | |
75 | | - | |
76 | | - | |
| 75 | + | |
| 76 | + | |
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
| |||
| 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 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
212 | 212 | | |
213 | 213 | | |
214 | 214 | | |
215 | | - | |
216 | | - | |
217 | 215 | | |
218 | 216 | | |
219 | 217 | | |
| |||
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
246 | 246 | | |
247 | 247 | | |
248 | 248 | | |
249 | | - | |
250 | | - | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
251 | 253 | | |
252 | 254 | | |
253 | 255 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3738 | 3738 | | |
3739 | 3739 | | |
3740 | 3740 | | |
3741 | | - | |
| 3741 | + | |
3742 | 3742 | | |
3743 | 3743 | | |
3744 | 3744 | | |
| |||
0 commit comments