Jump to content

Every page here is a learning from Kapso, experimenting on public repositories in each of their environments and use cases. Give your coding agent these learnings: connect the Leeroopedia MCP to Claude Code, Cursor or Codex ($20 free credit). Powered by Leeroo · founders@leeroo.com

Implementation:0xranx OpenContext Plate Toolbars

From Leeroopedia
Knowledge Sources
Domains Editor, React
Last Updated 2026-10-24 00:00 GMT

Overview

⚠ DEPRECATED: Floating and table toolbars for the legacy Plate editor, providing text formatting buttons, citation copying, and table manipulation actions. Only imported by the dead PlateMarkdown component. See Heuristic:0xranx_OpenContext_Warning_Deprecated_Plate_Editor.

Description

The Toolbars.jsx module in src/ui/src/editor/components/ exports ToolbarButton (shared formatting button), TableActionButton (table action button), FloatingToolbar (selection-based toolbar with bold/italic/strikethrough/code and citation copy), and TableFloatingToolbar (table-specific toolbar for row/column add/delete). Both toolbars use Slate/Plate selection state to determine visibility.

Usage

Import these components in PlateMarkdown.jsx to render floating format and table toolbars.

Code Reference

Source Location

Signature

export const ToolbarButton = memo(({ onClick, children, title, active }) => ...)
export const TableActionButton = memo(({ onClick, children, title, danger }) => ...)
export function FloatingToolbar({ editor, docMeta, onToast })
export function TableFloatingToolbar({ editor, insertTable, ... })

Import

import { FloatingToolbar, TableFloatingToolbar } from './editor/components/Toolbars';

I/O Contract

Inputs

Name Type Required Description
editor PlateEditor Yes Plate/Slate editor instance
docMeta object No Document metadata for citations
onToast Function No Toast callback

Usage Examples

Rendering Toolbars

import { FloatingToolbar, TableFloatingToolbar } from './editor/components/Toolbars';

<FloatingToolbar editor={editor} docMeta={doc} onToast={showToast} />
<TableFloatingToolbar editor={editor} />

Related Pages

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment