Widget: page-level / unanchored comments (start a thread without a pin) - #70
Widget: page-level / unanchored comments (start a thread without a pin)#70MateuszPaulski wants to merge 3 commits into
Conversation
Add a "Comment on this page" affordance so reviewers can leave general feedback about a page without first anchoring to an element. `anchor` is now optional on CreateThreadBody and the persisted thread; a pinless thread is born with the distinct anchorState "unanchored" and opts out of the anchoring machinery entirely (never matched, re-matched, or orphan-reported). Both create paths (pin and page) now flow through one shared useCreateThread hook. ADR-0048. Closes #53. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
🤖 airside-agent review —
Spec-faithful implementation across core/server/adapters/client — TDD-first, no weakened tests, no crash on the pinless path, no critical/high/medium findings. Promote-ready pending CI. |
Review — verified findingsClean implementation — mergeable as-is. One note on the explicitly deferred server-side guard: The adapters diverge on the deferred Minor nit: Changeset correctly covers all six touched publishable packages. ✅ |
Renumber this PR's ADR to ADR-0049 (0044-0047 taken on main, 0048 claimed by PR #70) and update in-repo references. Cap GitHub issue body under the 65,536-char limit with a truncation marker so very large threads still create an issue instead of failing with a 422. Airside-Agent-Fix: true Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Airside-Agent-Fix: true Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
🤖 airside-agent: addressed "Review — verified findings" in 6227ee4 — swapped the |
|
resolve conflicts |
Resolves the conflicts between the page-level comments feature and main's
controller event bus, PanelListView branding/icon refactor, and ADR-0049:
useCreateThread now emits via controller.emit({type:'created'}), PanelDrawer/
PanelListView carry both provenance and branding props, and ADR-0048 and
ADR-0049 both land in docs/adr.md.
Airside-Agent-Fix: true
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
🤖 airside-agent: addressed "resolve conflicts" in 2f2d563 — merged main into agent/issue-53, resolved 5 conflicts (incl. adapting useCreateThread to the new controller event bus); build/lint/tests green, PR now mergeable. |
Resolves the docs/adr.md conflict: main landed ADR-0049 (which reserves 0048 for PR #70), so this PR's entry takes the next free slot, ADR-0050, keeping newest-last order. Updates the SKILL.md cross-references to match. Also fixes the import-order lint error inherited from main's PanelListView.tsx (biome organizeImports autofix) so the branch lints green. Airside-Agent-Fix: true Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Page-level / unanchored comments (start a thread without a pin)
Implements the approved spec for #53: reviewers can leave general feedback about a page without first anchoring to an element.
What changed
CreateThreadBody.anchorand the persisted thread'sanchorare now optional. A thread born without a pin gets the distinctanchorState: "unanchored"(deliberately not"orphaned", which means lost its anchor and drives self-heal / the "anchor lost" warning). The server derives the state from the request;"orphaned"is still only reached later viaupdateAnchor.undefined, mongo/postgres omit the key) — verified by one contract round-trip that auto-covers all three.unanchoreditems at list ingestion, so they are never matched, re-matched, or orphan-reported (norematch(undefined)crash, no spuriousrefreshAnchor).useCreateThreadhook — both the pin flow (DraftPopover/MarkerLayer) and the new page flow now share one create path; MarkerLayer's existing tests pass unchanged.anchorStateupdate. Changeset added (patch, fixed group).Scope (per spec)
Page-scoped only (
scopestaysz.literal('page'),pageKeystill set). Global / cross-page threads, an on-page indicator for page comments, and a server guard onrefresh-anchorare deferred.Verification
TDD-first for backend. Green locally: core (120), server (141), adapter-memory (45), adapter-mongo (48), adapter-postgres (47), client (386).
pnpm lint(biome ci) clean; fullpnpm buildsucceeds.Closes #53.
🤖 Draft opened by airside-agent — automated build of #53.