Image editing

Crop, rotate, flip, draw, add text or shapes — without leaving the editor and without uploading the image anywhere first. This one is a third-party integration: TUI Image Editor is wired in and shipped with the product.

Saved HTML

Loading…

The one thing to get right

The command edits the currently selectedimage. With nothing selected it returns silently, which looks exactly like a broken button — so if you drive it from your own UI, select first.

// The command edits the CURRENTLY SELECTED image. With nothing selected it
// returns silently, so select first (clicking the image does this for a user).
var img = editor.getEditable().querySelector("img");
editor.selectControl(img);
editor.execCommand("imageeditor");

// On save, the edited result comes back as a data URI and replaces the
// original image's src — so the edit lives in the document, not on a server.

Nothing is fetched from a CDN

TUI and its dependencies are served from your own /richtexteditor/plugins/tui.image-editor/ folder, and the plugin switches TUI’s usage-statistics beacon off. That matters to customers who run static scanners: an editor that phones home is a finding, whoever owns the endpoint.

Because the result is written back as a data URI, an edit is part of the document immediately — useful, but watch the size of the saved HTML if your users crop large photographs. Pair it with an upload handler if you would rather store the bytes.

File upload · Drag-and-drop images · Configuration reference