Rich Editor
Basic Usage
Border
Describe the image for people who cannot see it.
Nothing matches.
Insert table
Or pick a size
Page setup
Keyboard shortcuts
Text
Paragraphs and lists
Insert
Edit and tools
Review
Word count
- Pages
- Words
- Characters
- Characters excluding spaces
- Reading time
Selection / whole document
<neura::editor document-title="Quarterly report" />
<neura::editor
wire:model="content"
page-size="letter"
orientation="portrait"
:zoom="100"
:menubar="true"
:toolbar="true"
:ruler="true"
:statusbar="true"
/>
<neura::editor :paginated="false" />
Chrome Options
Border
Describe the image for people who cannot see it.
Nothing matches.
Insert table
Or pick a size
Page setup
Keyboard shortcuts
Text
Paragraphs and lists
Insert
Edit and tools
Review
Word count
- Pages
- Words
- Characters
- Characters excluding spaces
- Reading time
Selection / whole document
<neura::editor
:menubar="false"
:ruler="false"
:statusbar="false"
placeholder="Toolbar only…"
/>
Tables
Page Setup
<neura::editor page-size="a4" orientation="portrait" :zoom="100" />
<neura::editor page-size="letter" orientation="landscape" />
<neura::editor page-size="legal" />
Ruler, Headers & Footers
data-numbering
on the <ol>
with a list-style-type
other readers understand, numbering
in JSON mode.
Like the paper size, columns and the first page's header are settings of the editor rather than of the value: pass them back as props and listen to
page-setup-change
and header-footer-change
to keep them.
data-nk-field
:
page
,
pages
,
title
,
date
.
<neura::editor
document-title="Quarterly report"
header='<span data-nk-field="title"></span>'
footer='Page <span data-nk-field="page"></span> of <span data-nk-field="pages"></span>'
different-first-page
first-header=""
first-footer=""
:columns="2"
/>
Writing Tools
/
at the start of a line (or after a space) for the insert menu: styles, lists, checklist, table, image, link, rule,
page break, today's date. Keep typing to filter it, arrows and Enter to pick, Escape to keep the slash as text.
Ctrl+F
opens find, Ctrl+H
find and replace: matches are highlighted as you type
(match case, whole words, regular expressions with $1
in the replacement), and Replace all is one undo step.
Format › Text case changes the selection to lowercase, UPPERCASE, Title Case or Sentence case without losing its formatting.
The paint-format brush copies the formatting at the caret onto the next text you select (double-click it to paint several times, Escape to stop).
Tools › Word count (or a click on the word count) gives pages, words, characters and reading time, for the selection too.
Ctrl+Shift+S
)
writes what you say at the caret, in French or English: say the punctuation (“virgule”, “point d'interrogation”, “comma”) and
“à la ligne” / “new line” or “nouveau paragraphe” / “new paragraph”; French spacing and capitals at the start of sentences come on their own.
It uses the browser's speech recognition (Chrome, Edge, Safari). Ctrl+/
lists every shortcut, searchable.
Going from one menu to the next — a click, passing over another title while one is open, or the arrow keys — slides the same panel across.
Ctrl+Enter
), a line break (Shift+Enter
),
or a break to the next odd or even page, for chapters that start on a right-hand page; a blank page is left when needed.
Breaks are saved as <div data-break="page|odd|even" style="break-before: page|right|left">
(pageBreak
with a kind
in JSON mode), print that way,
and survive undo. Backspace at the start of the next line removes one.
Border
Describe the image for people who cannot see it.
Nothing matches.
Insert table
Or pick a size
Page setup
Keyboard shortcuts
Text
Paragraphs and lists
Insert
Edit and tools
Review
Word count
- Pages
- Words
- Characters
- Characters excluding spaces
- Reading time
Selection / whole document
<neura::editor wire:model="brief" />
<!-- A checklist is saved as <ul data-checklist><li data-checked="true">…, or taskList / taskItem in JSON mode -->
Images & Tables
data-original
, data-crop
,
data-rotate
), so it can be cropped again or reset. An image from another site that does not allow
it (no CORS) cannot be edited, and the toolbar says so.
Border
Describe the image for people who cannot see it.
Nothing matches.
Insert table
Or pick a size
Page setup
Keyboard shortcuts
Text
Paragraphs and lists
Insert
Edit and tools
Review
Word count
- Pages
- Words
- Characters
- Characters excluding spaces
- Reading time
Selection / whole document
<neura::editor wire:model="report" />
<!-- Saved as plain HTML: <figure data-wrap="left" style="width: 32%"> with a float, <td rowspan / colspan>,
<colgroup> widths and real cell borders. JSON mode keeps wrap / width, spans, background, widths and border. -->
Smart Chips, Table of Contents & Footnotes
@
to mention someone or set a date as a chip: the people come from
mentions
(and are searched at mentions-url
as you type),
and dates read plain words — "tomorrow", "demain", "24 décembre", "next friday". Click a chip for its card: email the person,
change the date or remove it. Each mention dispatches editor-mention
so you can notify them.
Ctrl+Alt+F
) puts a numbered marker
at the caret and takes you to its note at the foot of the page, which makes room for it; Escape goes back to the text, a click on a marker or a note opens it again.
Border
Describe the image for people who cannot see it.
Nothing matches.
Insert table
Or pick a size
Page setup
Keyboard shortcuts
Text
Paragraphs and lists
Insert
Edit and tools
Review
Word count
- Pages
- Words
- Characters
- Characters excluding spaces
- Reading time
Selection / whole document
<neura::editor
wire:model="plan"
:mentions="$team->map->only(['id', 'name', 'email', 'avatar'])"
mentions-url="/api/people"
x-on:editor-mention="$wire.notify($event.detail.id)"
/>
<!-- mentions-url is searched with GET ?q=… and answers [{ id, name, email, avatar }].
Saved as <span data-chip="person" data-id="1" data-email="…">@Name</span>, <span data-chip="date" data-date="2026-12-04">,
<nav data-toc> with its links, <sup data-footnote> markers and an <ol data-footnotes> of the notes at the end.
JSON mode: mention, tableOfContents and footnote nodes. -->
Comments & Suggestions
Ctrl+Alt+M
(or the button beside the selection, or Insert › Add comment) to comment on it.
Comments open in a panel beside the pages — over them when the editor is narrow — where they can be answered, resolved, reopened or deleted;
the caret in commented text opens its thread. Comments are signed by author
(a name, or the signed-in user)
and dispatch editor-comment
(add
, reply
,
resolve
, reopen
, delete
).
Ctrl+Alt+Shift+Z / X / C
). Each suggestion has a card to accept or reject it, or accept and reject them all at once.
Formatting is suggested too — bold, italic, underline, colour, font and size on selected text (dotted green underline, rejected it goes back to what it was),
a paragraph's style, alignment, spacing or indent (framed in green) — and so are new paragraphs (a green ¶ where Enter split one; rejected, they join again)
and paragraphs joined by Backspace or Delete (a struck ¶; accepted, they become one). Taking back one's own new paragraph joins it at once.
Lists, tables, images and links still apply directly.
@
in a comment or a reply to mention someone from mentions
(or mentions-url
): each person is announced once with editor-mention
,
whose detail carries comment: { thread, text }
so the app can notify them. editor-comment
also reports edit
and remove
(a reply deleted).
Border
Describe the image for people who cannot see it.
Nothing matches.
Insert table
Or pick a size
Page setup
Keyboard shortcuts
Text
Paragraphs and lists
Insert
Edit and tools
Review
Word count
- Pages
- Words
- Characters
- Characters excluding spaces
- Reading time
Selection / whole document
<neura::editor wire:model="plan" :author="auth()->user()->name" x-on:editor-comment="$wire.notifyTeam($event.detail)" />
<!-- Comments: <span data-comment="c-…"> around the text, the threads in a hidden <aside data-comments> at the end
(comments in JSON mode). Suggestions: <ins data-suggest data-author data-time> and <del …>, insertion / deletion marks in JSON. -->
Version History
Ctrl+Alt+Shift+H
, or the “Last version” link in the status bar) shows them by day;
each version is drawn with what it added in green and what it removed struck in red, against the one before. Name a version to keep it
(Name current version, or the pencil beside it) and filter on named versions; Restore makes a version the document again — what was there stays
a version of its own, and Undo takes the restore back. Comments travel with each version.
history-key
— the wire:model
or name
if not given. To keep them with the document instead, point versions-url
(or config('neura-kit.editor.history.url')
) at a small JSON API of your app, and check there that the user may read the document.
:history="false"
turns history off. editor-version
is dispatched on
add
, update
, rename
and restore
.
// <neura::editor wire:model="body" history-key="brief-{{ $brief->id }}" :versions-url="route('briefs.versions', $brief)" />
Route::prefix('briefs/{brief}/versions')->middleware('auth')->group(function () {
// GET ?key=… → [{ id, time, name, authors }], newest first
Route::get('/', fn (Brief $brief) => $brief->versions()->latest('time')->get(['id', 'time', 'name', 'authors']));
// GET {id} → { id, time, name, authors, html }
Route::get('{version}', fn (Brief $brief, BriefVersion $version) => $version);
// POST { time, name, authors, html } → the new version
Route::post('/', fn (Request $request, Brief $brief) => $brief->versions()->create($request->only('time', 'name', 'authors', 'html')));
// PUT { time, authors, html }: the newest version, brought up to date
Route::put('{version}', fn (Request $request, Brief $brief, BriefVersion $version) => $version->update($request->only('time', 'authors', 'html')));
// PATCH { name }: a version named
Route::patch('{version}', fn (Request $request, Brief $brief, BriefVersion $version) => $version->update($request->only('name')));
});
Keyboard Shortcuts
| Shortcut | Action |
|---|---|
| Ctrl+B / I / U | Bold / italic / underline |
| Ctrl+K | Insert / edit link |
| Ctrl+Alt+0…4 | Paragraph / heading 1–4 |
| Ctrl+Shift+7 / 8 | Ordered / unordered list |
| Tab / Shift+Tab | Indent / outdent (or next/prev cell in tables) |
| Ctrl+Shift+9 | Checklist |
| Ctrl+F / Ctrl+H | Find / find and replace |
| @ | Mention a person or set a date, at the start of a line or after a space |
| Ctrl+Alt+Shift+H | Version history |
| Ctrl+Alt+M | Comment on the selection |
| Ctrl+Alt+Shift+Z / X / C | Editing / Suggesting / Viewing |
| Ctrl+Alt+F | Footnote (Escape to go back to the text) |
| Shift+click | Select the cells between the caret's cell and the clicked one |
| Delete | Remove the picked image, or empty the selected cells |
| Ctrl+Shift+C | Word count |
| / | Insert menu, at the start of a line or after a space |
| Ctrl+Enter / Shift+Enter | Page break / line break |
| Ctrl+Shift+S | Voice typing |
| Ctrl+/ | All keyboard shortcuts |
| Double-click an image | Crop it (Enter keeps the crop, Escape leaves it) |
| Ctrl+Z / Y | Undo / redo (also Ctrl+Shift+Z) |
| Ctrl+\ | Clear formatting |
| Ctrl+P | |
| Escape | Close dialogs / exit header-footer |
#
–####
(headings),
-
/ *
/ +
(bullet list),
1.
(numbered list),
>
(blockquote),
[ ]
/ [x]
(checklist, ticked or not).
On Mac, use ⌘ in place of Ctrl.
Livewire Integration
wire:model
(debounced). Both HTML and JSON modes sync in real time.
<neura::editor wire:model="content" />
Form Integration
name
attribute, a hidden input submits like any other field.
Border
Describe the image for people who cannot see it.
Nothing matches.
Insert table
Or pick a size
Page setup
Keyboard shortcuts
Text
Paragraphs and lists
Insert
Edit and tools
Review
Word count
- Pages
- Words
- Characters
- Characters excluding spaces
- Reading time
Selection / whole document
<form method="POST" action="/posts">
<input type="hidden" name="_token" value="rncyY2bqeTe3pxhkwhYdYAhhZ6D2zhGuvbfORKru" autocomplete="off">
<neura::field>
<neura::label>Description</neura::label>
<neura::editor name="description" placeholder="Enter product description…" />
<neura::description>
Provide a detailed description of the product.
</neura::description>
</neura::field>
<neura::button type="submit">Submit</neura::button>
</form>
Output Modes
mode="json"
for a structured document tree.
HTML Mode
Border
Describe the image for people who cannot see it.
Nothing matches.
Insert table
Or pick a size
Page setup
Keyboard shortcuts
Text
Paragraphs and lists
Insert
Edit and tools
Review
Word count
- Pages
- Words
- Characters
- Characters excluding spaces
- Reading time
Selection / whole document
JSON Mode
Border
Describe the image for people who cannot see it.
Nothing matches.
Insert table
Or pick a size
Page setup
Keyboard shortcuts
Text
Paragraphs and lists
Insert
Edit and tools
Review
Word count
- Pages
- Words
- Characters
- Characters excluding spaces
- Reading time
Selection / whole document
<neura::editor mode="html" wire:model="content" />
<neura::editor mode="json" wire:model="content" />
Image Upload
neura-kit.editor.upload-image
)
or your upload-url
.
On failure the image embeds as a data URL and
editor-upload-failed
is dispatched.
<neura::editor
wire:model="content"
upload-url="{{ route('my.custom.upload') }}"
upload-field="image"
/>
config/neura-kit.php or via environment variables:
NEURA_KIT_EDITOR_IMAGE_DISK (s3, local, etc.) and
NEURA_KIT_EDITOR_IMAGE_PATH (storage path).
Export & Import (Paperdoc)
paperdoc-dev/paperdoc-lib
installed,
File gains Open… and Download. Export uses the current page size,
orientation and margins. Import is sanitized through the editor schema before load.
Menu entries hide when the package is missing.
composer require paperdoc-dev/paperdoc-lib
Disabled State
Border
Describe the image for people who cannot see it.
Nothing matches.
Insert table
Or pick a size
Page setup
Keyboard shortcuts
Text
Paragraphs and lists
Insert
Edit and tools
Review
Word count
- Pages
- Words
- Characters
- Characters excluding spaces
- Reading time
Selection / whole document
<neura::editor disabled wire:model="content" />
Events
| Event | Detail |
|---|---|
| input | Serialized value (HTML or JSON, depending on mode) |
| title-change | New document title string |
| header-footer-change | { header, footer, differentFirstPage, firstHeader, firstFooter }
after leaving header/footer edit or ticking “Different first page” |
| page-setup-change | { size, orientation, margins, columns }
after Page setup or Format → Columns |
| editor-upload-failed | { file, reason }
— image falls back to a data URL |
<div
x-on:title-change="console.log($event.detail)"
x-on:header-footer-change="console.log($event.detail)"
x-on:editor-upload-failed="toast($event.detail.reason)"
>
<neura::editor wire:model="content" />
</div>
Configuration
config/neura-kit.php or via environment variables.
// config/neura-kit.php
'editor' => [
'page_size' => env('NEURA_KIT_EDITOR_PAGE_SIZE', 'a4'),
'orientation' => env('NEURA_KIT_EDITOR_ORIENTATION', 'portrait'),
'max_image_size' => env('NEURA_KIT_EDITOR_MAX_IMAGE_SIZE', 10240), // KB
'image_disk' => env('NEURA_KIT_EDITOR_IMAGE_DISK', 'public'),
'image_path' => env('NEURA_KIT_EDITOR_IMAGE_PATH', 'editor/images'),
// Requires paperdoc-dev/paperdoc-lib
'export_formats' => ['pdf', 'docx', 'html', 'md'],
'import_formats' => ['docx', 'html', 'md', 'txt', 'csv', 'pdf'],
'max_export_bytes' => 5_242_880,
'max_import_kilobytes' => 20_480,
],
// .env
NEURA_KIT_EDITOR_PAGE_SIZE=a4
NEURA_KIT_EDITOR_MAX_IMAGE_SIZE=10240
NEURA_KIT_EDITOR_IMAGE_DISK=s3
NEURA_KIT_EDITOR_IMAGE_PATH=editor/images
Props
| Property | Type | Default | Description |
|---|---|---|---|
| name | string | null | Hidden input name for form submit |
| value | string|array | null | Initial HTML (or JSON tree) |
| mode | string | html | html · json
|
| placeholder | string | Start writing… | Empty-document hint |
| disabled | boolean | false | Read-only; hides toolbar |
| debounce | number | 300 | ms before syncing wire:model / state |
| document-title | string | Untitled document | Menubar title (editable) |
| page-size | string | config | a4 · letter · legal
|
| orientation | string | config | portrait · landscape
|
| zoom | number | 100 | Initial zoom % |
| paginated | boolean | true | Sheet flow vs continuous |
| header / footer | string | null | Initial header/footer HTML |
| menubar | boolean | true | Title + File/Edit/View/Insert/Format |
| toolbar | boolean | true | Formatting toolbar |
| ruler | boolean | true | Margin / indent ruler |
| statusbar | boolean | true | Page / words / zoom |
| upload-url | string | auto | Custom image upload endpoint |
| upload-field | string | image | Multipart field name |
Best Practices
Security
javascript:
URLs), but always sanitize again on the server before storing —
submitted HTML can still be tampered with in transit.
Image Storage
Performance
debounce
for very long documents, or set :paginated="false"
when page geometry does not matter.