Skip to content

cms-admin: Add read-only rendering to the TipTap rich text block - #6119

Merged
VPS-Obi merged 4 commits into
mainfrom
tiptap-rich-text-read-only
Aug 12, 2026
Merged

cms-admin: Add read-only rendering to the TipTap rich text block#6119
VPS-Obi merged 4 commits into
mainfrom
tiptap-rich-text-read-only

Conversation

@VPS-Ricky

@VPS-Ricky VPS-Ricky commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

The first use case will be the table block, which renders a non-editable rich text editor in its admin grid view.

The renderer comes from the block because only the block knows what the saved content means: the content stores names, such as a text block style name or a child block key, and the block holds what those names map to. Draft-js can offer a standalone read-only component because it attaches its link and whitespace renderers to the editor state itself. TipTap keeps all of it in the block's configuration, so a renderer without the block shows unstyled text and child blocks as their raw keys.


Task: https://vivid-planet.atlassian.net/browse/COM-3096

@VPS-Ricky
VPS-Ricky force-pushed the tiptap-rich-text-read-only branch 4 times, most recently from 6435fb9 to f86793f Compare August 5, 2026 10:30
@VPS-Ricky VPS-Ricky changed the title cms-admin: Render the TipTap rich text block read-only cms-admin: Add read-only rendering to the TipTap rich text block Aug 5, 2026
@VPS-Ricky
VPS-Ricky force-pushed the tiptap-rich-text-read-only branch 5 times, most recently from 98f9b9d to fc11ae8 Compare August 5, 2026 11:00
@VPS-Ricky VPS-Ricky self-assigned this Aug 5, 2026
@VPS-Ricky
VPS-Ricky requested a review from VPS-Obi August 5, 2026 11:10
@VPS-Ricky
VPS-Ricky marked this pull request as ready for review August 5, 2026 11:10
@VPS-Obi
VPS-Obi requested a review from nsams August 6, 2026 12:18
Comment thread packages/admin/cms-admin/src/blocks/tipTap/createTipTapRichTextBlock.tsx Outdated
@VPS-Ricky
VPS-Ricky requested a review from VPS-Obi August 10, 2026 10:34
The first use case will be the table block, which renders a
non-editable rich text editor in its admin grid view.

The renderer comes from the block because only the block knows what the
saved content means: the content stores names, such as a text block
style name or a child block key, and the block holds what those names
map to. Draft-js can offer a standalone read-only component because it
attaches its link and whitespace renderers to the editor state itself.
TipTap keeps all of it in the block's configuration, so a renderer
without the block shows unstyled text and child blocks as their raw
keys.
The read-only story used a block with no text block styles
configured, so it could not tell a correctly resolved style apart
from having none to resolve.
@VPS-Ricky
VPS-Ricky force-pushed the tiptap-rich-text-read-only branch from 93cce33 to 20ef3d1 Compare August 10, 2026 23:01
@VPS-Obi
VPS-Obi removed the request for review from nsams August 12, 2026 08:20
@VPS-Obi
VPS-Obi merged commit 71d6a95 into main Aug 12, 2026
15 checks passed
@VPS-Obi
VPS-Obi deleted the tiptap-rich-text-read-only branch August 12, 2026 08:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants