# Editor Behavior Focus, gap cursor and trailing node: the editor behaviours that make a document feel finished. ## Installation ```bash npx shadcn@latest add litingyes/blocove/rich-text-editor-behavior ``` > Typography requires [shadcn/typeset](https://ui.shadcn.com/docs/typeset). Copy `typeset.css` next to your main stylesheet, import it after Tailwind and add the `.typeset-docs` preset. ## API Reference ### EditorFocus Registers the focus extension. The focused node receives a class, so the focus ring can be styled from the document stylesheet. | Prop | Type | Default | | --- | --- | --- | | `className` | `string` | `'has-focus'` | | `mode` | `'all' | 'deepest' | 'shallowest'` | `'all'` | ### EditorGapcursor Registers the gap cursor extension. The caret can sit between two blocks, where a regular text cursor cannot go. ### EditorTrailingNode Registers the trailing node extension. An empty block is kept at the end of the document, so there is always somewhere to keep writing. ## Registry dependencies - `litingyes/blocove/rich-text-editor` - `litingyes/blocove/rich-text-editor-extension` Namespace: `npx shadcn@latest add @blocove/rich-text-editor-behavior`