DocMosaicdocs
Primitives

Editor.FrameToolButton

Toolbar toggle that arms the draw-to-size container-frame tool.

Toolbar toggle that arms the draw-to-size container-frame tool. While armed, dragging on an empty part of the page rubber-bands a new FrameSection; other sections dropped inside it become its children. Mutually exclusive with the shape, image-frame, and drawing tools.

Usage

import { Editor } from '@docmosaic/react';

<Editor.Root>
    <Editor.FrameToolButton />
</Editor.Root>;

API Reference

PropTypeDefaultDescription
iconOnlyboolean | undefined-

Render a compact icon-only square button with an accessible label.

variant"default" | "cream" | "sage" | "orange" | "caramel" | "white" | "destructive" | "outline" | "secondary" | "ghost" | "link" | null | undefined-

Override the idle (tool-off) icon-only variant. Defaults to 'caramel'.

activeVariant"default" | "cream" | "sage" | "orange" | "caramel" | "white" | "destructive" | "outline" | "secondary" | "ghost" | "link" | null | undefined-

Override the active (tool-armed) icon-only variant. Defaults to 'orange'.

classNamestring | undefined-

Extra classes merged onto the icon-only button while idle.

activeClassNamestring | undefined-

Extra classes merged onto the icon-only button while the tool is armed.