Skip to content

Commit 03d96b0

Browse files
committed
docs(cms): drop TODO section from lexical block-diff README
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Rhs2Em2ipydqqPHpH464J4
1 parent 61d64fd commit 03d96b0

1 file changed

Lines changed: 0 additions & 22 deletions

File tree

cms/src/shared/lexical/plugin/README.md

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -155,25 +155,3 @@ const Converter: BlockDiffConverter<TwoColumn> = async (args) => {
155155
| `lexicalEditorWithBlockDiff.ts` | Wraps `lexicalEditor()`, overrides `DiffComponent`, registers it in the generated import map. |
156156
| `helpers.ts` | HTML rendering (`field`, `coordinates`, `uploadArray`, `richText`, ...) + `defineBlockConverters`. |
157157
| `types.ts` | `BlockDiffConverter`, `BlockDiffConvertersMap`, `LexicalEditorState`, `UploadDoc`, `PopulateFn`. |
158-
159-
## TODO
160-
161-
- [ ] Extract this folder into a standalone package and publish on npm, e.g.
162-
`@jhb.software/payload-lexical-block-diff`.
163-
- [ ] Reuse it across the other websites in `jhb-websites/` (website,
164-
houseofu, silke-liederbach-website, freund-immo, blumengreif,
165-
bewusstseinsakademie, martinasaur, le-chauffeur) — each currently shows
166-
only block names in the version diff view.
167-
- [ ] Before extracting, verify nothing in this folder imports from the host
168-
project (payload-types, config, collections). Only the consumer's glue
169-
files should be project-specific.
170-
- [ ] Investigate whether the plugin could **own the diff component** itself
171-
(exporting a prebuilt component at a path like
172-
`@jhb.software/payload-lexical-block-diff/rsc#LexicalBlocksDiffComponent`)
173-
so consumers no longer have to create a `LexicalBlocksDiffComponent.tsx`
174-
file or pass `diffComponentPath` to the wrapper. The open problem is
175-
getting the project-specific `converters` into that component — Payload's
176-
import map resolves components via static string paths, so converters
177-
can't be passed through. Possible approaches, both with trade-offs: - Global registry populated at module load (order-dependent, hacky). - Turn this into a proper Payload plugin with an `init`/config hook that
178-
injects converters into the component via shared state on
179-
`req.payload.config` or similar.

0 commit comments

Comments
 (0)