Optional calloutDefaults applied to newly-placed callouts. All keys are optional; omitted keys fall back to the current built-in defaults.
text — initial label text (default 'Label').color — callout box background color. Falls back to
defaultBrushColor.textColor — label text color (default '#ffffff').fontSize — label font size in pixels (default 20).maxChars — maximum characters allowed in the label
(default 40).lineBreakAt — character position around which to insert an
automatic line break (default 15).Optional color?: stringOptional fontOptional lineOptional maxOptional text?: stringOptional textOptional colorColor palette for the color picker
Optional cropDefault crop aspect ratios available to user
Optional currentCurrent image position in a multi-image editing flow. 1-based index (for example: 1, 2, 3...).
When used together with totalImages, the editor header shows
a compact current/total indicator (e.g. 2/5).
Optional defaultDefault brush color. Default: '#ff0000'
Optional defaultDefault brush width in pixels. Default: 3
Optional defaultDefault stroke color for shapes (circle/ellipse/square/rectangle/arrow). Default: matches defaultBrushColor
Optional defaultDefault stroke width for shapes. Default: 3
Optional defaultDefault text color. Default: '#ff0000'
Optional defaultDefault text font size. Default: 24
Optional disableWhen true, the editor will NOT install keyboard shortcuts (V/C/B/E/T/S, ⌘Z/⌘⇧Z, +/-/0/1, ⌘⏎/Esc, R/⇧R, H/⇧H). Additive; default false.
Optional disabledFeatures to hide from the toolbar. Accepts individual tool names: 'move','crop','zoomIn','zoomOut','rotateLeft','rotateRight', 'draw','text','eraser','callout','undo','redo','reset','filters','adjust','fullscreen' Or group names: 'zoom' (zoomIn+zoomOut), 'transform' (rotateLeft+rotateRight+reset), 'annotate' (draw+text+callout+eraser) Default: [] (all features visible)
Optional exportWhen true (default), the exported image is rendered at the native (intrinsic) resolution of the loaded image — so the on-screen scaling that the editor applies to fit the canvas does NOT reduce the resolution of the output. Annotations are upscaled to match.
Set to false to revert to the legacy behaviour where the export size matches the on-screen canvas size. Default: true
Optional exportDefault export format
Optional exportExport pixel ratio. 1 = standard, 2 = retina. Default: 1
Optional exportJPEG export quality (0.0 - 1.0). Default: 0.92
Optional filterRename individual filter preset tiles without changing behaviour. Keys not present here fall back to the built-in English label.
Example:
filterPresetLabels: { grayscale: 'Mono', sepia: 'Warm Vintage' }
Optional filterWhitelist and ordering of built-in one-click filter presets shown in the Filters tool's tile grid. When set, only listed presets render, in the given order. When unset (default), all seven built-in presets render in their canonical order.
Note: this only picks from the built-in set (see ImageFilterPreset);
it does not let you define new filter algorithms.
Optional keyboardWhich key presses the shortcuts react to.
'global' (default): any key press on the page that isn't typed
into an input. When several editors are mounted, only the most
recently created or clicked/focused one responds, and a key press
inside one editor never reaches another.'editor': only key presses while focus is inside this editor.
Use for inline editors so page-level keys (c, +, Escape, …)
aren't captured.Additive; default 'global'.
Optional labelsPer-key overrides for the resolved locale pack. Deep-partial: pass
any subset of LocalePack keys and only those strings are replaced.
Precedence (lowest → highest):
language (if any)labels overrides passed heretheme, strings, filterPresetLabels,
and calloutDefaults (highest priority)Use cases:
LanguageCode set — pass a complete labels object with no
language, and the missing keys fall back to English.language: 'de' plus a few tweaks.Example:
openEditorModal({
image: file,
config: {
language: 'en',
labels: {
tool: { callout: 'Annotation' },
props: { title: { callout: 'Annotation' }, deleteSelected: 'Remove' },
},
},
});
Optional languageTwo-letter language code that selects a bundled translation pack for every user-facing string in the editor shell (top bar, rails, empty state, props panel, filter tiles, callout defaults).
Supported: da, de, en, es, fr, it, ko, nl, pl, pt, sv, th, tr, vi, zh.
sp is accepted as an alias for es. Regional variants such as
de-DE or pt_BR are folded to their primary tag.
Any individual label you set explicitly on theme, strings,
filterPresetLabels, or calloutDefaults overrides the
language pack for that key. Unknown or missing codes fall back
to English.
Example:
openEditorModal({
image: file,
config: {
language: 'de', // whole UI in German
theme: { headerTitle: 'Foto Studio' } // this one label stays custom
},
});
Optional localeLocale for button text. Can override individual labels via theme
Optional maxMaximum resolution (longest side). null = no limit (auto-detect per platform)
Optional maxMaximum undo stack depth. Default: 20
Optional onOptional callback wired to the shell's primary Apply button in the
top bar. When provided the button is rendered; when omitted it is
hidden. Used by openEditorModal to bridge the modal's promise.
Additive — inline (non-modal) consumers can ignore this.
Optional onOptional callback wired to the shell's Close button in the top bar. When omitted, the Close button is hidden.
Optional onFired for non-fatal editor errors (e.g. bad file, HEIC decode
failure, resolution exceeded). Additive mirror of the error
event on the editor instance.
Optional onFired once the image has finished loading (after HEIC decode,
EXIF orientation correction, and any downscaling). Additive
mirror of the image:loaded event on the editor instance — use
this from modal consumers who don't have a reference to the
RpImageEditor instance.
Optional onFired whenever the active tool changes. Additive mirror of the
mode:changed event on the editor instance.
Optional showWhether to show the built-in toolbar. Default: true
Optional stringsUser-facing strings rendered by the editor shell. All keys are
optional; omitted keys fall back to the built-in English text.
Pass an empty string ('') to hide the corresponding UI element
entirely (currently supported for emptyStateSubtitle).
Optional emptyDefault: 'Supported: PNG, JPEG, HEIC'. Pass '' to hide the row.
Optional emptyDefault: 'Drop an image or click to upload'
Optional themeTheme customization
Optional totalTotal number of images in a multi-image editing flow.
When used together with currentImageIndex, the editor header
shows a compact current/total indicator.
Configuration for the image editor