DocMosaicdocs
Primitives

Editor.AddTextButton

Toolbar button that inserts a new text section.

Toolbar button that inserts a new text section.

Usage

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

<Editor.Root>
    <Editor.AddTextButton />
</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 icon-only button variant. Defaults to 'caramel'.

classNamestring | undefined-

Extra classes merged onto the icon-only button.

  • Root - the orchestrator