Files
PaperClipAI/ui
Devin Foley fd1831ea3c Restore a single Lexical copy so the rich editor renders
Cherry-pick of the master fix onto the v2026.825.0-beta.1 base, so the
beta channel can ship a patched candidate without waiting for a full
rebase onto master.

The rich markdown editor fell back to its raw-source textarea on every
field, for any content including an empty one, with the render-time
error "LexicalBuilder.fromEditor: The given editor was created with
LexicalBuilder 0.48.0 but this version is 0.49.0. A project should have
exactly one copy of LexicalBuilder".

Root pnpm overrides pinned the Lexical family to 0.49.0 while
@mdxeditor/editor declares lexical ^0.48.0 — a caret on a 0.x version
pins the minor, so the override forced the editor past the only line it
supports (0.49 also carried breaking node-config changes). The override
list was incomplete besides: @lexical/extension, @lexical/history, and
@lexical/internal are reached transitively and stayed on 0.48, so the
graph mixed both lines and the LexicalBuilder invariant threw. The
browser bundle carried two @lexical/extension instances as a result.

Drop the Lexical entries from the root overrides (react, react-dom, and
rollup stay) and pin the app's own lexical and @lexical/link to 0.48.0,
so the whole graph resolves through the editor's supported line. The app
subclasses LinkNode for mention-aware links and registers it into the
editor's instance, so node identity depends on this being one copy.

Add a resolution-graph test that fails fast on a mixed graph rather than
waiting for a render crash: it asserts the app and the editor resolve
the same lexical copy, that @lexical/link and the transitively-reached
@lexical/extension sit on that version, and that the version satisfies
the editor's declared range.

The lockfile is regenerated against this base rather than taken from
master — the beta base predates several unrelated dependency bumps, so
master's lockfile does not describe this tree. Only Lexical resolutions
move; every other entry is unchanged. The conflict on ui/package.json
was lucide-react version drift, resolved in favour of this base.

Tested on the beta base: ui typecheck clean; the new resolution test
passes (3); mention-deletion, mention-aware-link-node, and
MarkdownEditor suites pass (42); the lockfile now resolves the whole
Lexical family to a single 0.48.0 line; the built bundle went from two
LexicalBuilder registrations to one. A probe rendering the real editor
(no mock) returns no fallback for empty and plain-prose content, where
both previously fell back. Prose containing bare angle brackets still
falls back on this base — that is a separate editor bug, not present on
master either, and out of scope here.
2026-08-27 09:31:40 -07:00
..

@paperclipai/ui

Published static assets for the Paperclip board UI.

What gets published

The npm package contains the production build under dist/. It does not ship the UI source tree or workspace-only dependencies.

Storybook

Storybook config, stories, and fixtures live under ui/storybook/.

pnpm --filter @paperclipai/ui storybook
pnpm --filter @paperclipai/ui build-storybook

Typical use

Install the package, then serve or copy the built files from node_modules/@paperclipai/ui/dist.