Invisible Characters

Reveals the spaces and paragraph marks around the text.

UIrich-text-editor-invisible-charactersView JSON

Invisible characters are decorations: they are rendered next to the document, never written into it. The extension starts with the characters visible, so the toolbar toggle can reveal and hide them.

Preview

Installation

Add the item with the shadcn CLI, or copy the source manually.

pnpm dlx shadcn@latest add litingyes/blocove/rich-text-editor-invisible-characters

Requires a shadcn/ui project set up with Base UI primitives. Blocove is developed against the b0 preset, but it installs no base config or theme tokens: your own preset, fonts and colors stay in place.

Or install from the namespace after adding the registry: npx shadcn@latest add @blocove/rich-text-editor-invisible-characters

Typography is provided by shadcn/typeset. Copy typeset.css next to your stylesheet, import it after Tailwind and add the .typeset-docs preset. See the Rich text editor setup.

API Reference

Props accepted by the exported components.

EditorInvisibleCharacters

Registers the invisible characters extension. Spaces, paragraph marks and hard breaks are rendered through decorations while the characters are visible.

PropTypeDefault
visiblebooleantrue

EditorInvisibleCharactersToolbar

Toolbar toggle that shows and hides the invisible characters.

PropTypeDefault
classNamestring-