Blocks
Every line of a document is a block that you can turn into another one, move or delete.
Furniture care
This guide ships to the customer with every order.
In the first week
Peel the film off the legs
Air the room: the fabric smell fades in a couple of days
Tighten the screws after seven days
Keep oak furniture away from radiators: the wood dries out and cracks.
Cleaning the upholstery
Fabric
Vacuum once a week with a soft brush. Blot a stain with a damp cloth, do not rub.
Leather
Wipe with a dry soft cloth. Apply leather cream twice a year.
If the wood gets scratched
Fill the scratch with a wax crayon that matches the wood and buff it with a dry cloth.
Type / for the menu of blocks. It holds text, headings, lists, quotes, code, callouts, toggles, columns and tables, as well as images, files and links.
Hover a block to see its handle. Click the handle to turn the block into another one, duplicate, move or delete it, or drag the handle to move the block. Ctrl+Shift+↑ and Ctrl+Shift+↓ move the block with the caret.
Some blocks add their own items to the handle menu: a callout picks its tone, and a toggle can stay open by default.
Keep only the blocks you need
Restrict the schema to the blocks and styles the form needs:
Tell us what you liked and what we could do better
The slash menu and the bars offer only what the schema allows. Pasted content is cut down to the same blocks and styles.
Table in a document
Open the menu of a column to sort, filter, rename it or change its type:
Oslo armchair upholstery
| Fabric | Price, $ | Delivery | In stock |
|---|---|---|---|
| Gray linen | 249 | 2026-11-20 | |
| Dark linen | 259 | 2026-11-24 | |
| Blue velvet | 289 | 2026-12-03 | |
| Mustard velvet | 289 | 2026-12-10 |
A column holds text, numbers, dates, checkboxes or a choice from a list. The sort and the filters are saved in the document, and readers see the rows the way the author left them.
A table pasted from a spreadsheet or a word processor becomes the same block.
Custom block
Describe the block in the schema and give it a view with defineBlock:
Living room picks
An armchair and a floor lamp from one collection: light oak and gray linen.
The schema entry says how the block is stored: its attributes, its HTML and how to read it back from HTML. That is all NuiContent needs to show the block without the editor.
defineBlock adds the editor side: the view component, items for the slash and handle menus, and keys. The view receives the node and changes it with editor.setAttrs, as the product picker does.
Pass the built-in editorBlocks along with yours: blocks replaces the whole list and is read once when the editor mounts.
defineBlock: (block: NuiEditorBlock) => NuiEditorBlockinterface NuiEditorBlock { readonly name: string; readonly view?: Component | undefined; readonly at?: NuiEditorBlockPlace | undefined; readonly handle?: NuiEditorHandlePlacement | ((node: ElementNode) => NuiEditorHandlePlacement) | undefined; readonly keymap?: Keymap | ((editor: NuiEditorBlockEditor) => Keymap) | undefined; readonly conceals?: ((editor: NuiEditorBlockEditor) => (parent: ElementNode, index: number) => boolean) | undefined; readonly slash?: ((texts: NuiEditorMessages) => readonly SlashItem[]) | undefined; readonly menu?: ((node: ElementNode, editor: NuiEditorBlockContext, texts: NuiEditorMessages) => NuiMenuEntry[]) | undefined;}interface NuiEditorBlockViewProps { node: ElementNode; element: HTMLElement; selected: boolean; focused: boolean; editable: boolean; editor: NuiEditorBlockContext;}