Implementation:0xranx OpenContext Tiptap TableToolbar
| Knowledge Sources | |
|---|---|
| Domains | Editor, React |
| Last Updated | 2026-10-24 00:00 GMT |
Overview
Tiptap floating toolbar for table manipulation, providing add/remove row and column operations and table deletion via a BubbleMenu.
Description
The TableToolbar.jsx in src/ui/src/editor/tiptap/ uses Tiptap's BubbleMenu with a custom pluginKey to show a floating toolbar when the cursor is inside a table. It provides seven actions: add row before/after, add column before/after, delete row, delete column, and delete table. Each action calls the corresponding Tiptap chain command.
Usage
Import and render this component with a Tiptap editor instance that has the Table extension enabled.
Code Reference
Source Location
- Repository: 0xranx_OpenContext
- File: src/ui/src/editor/tiptap/TableToolbar.jsx
- Lines: 1-108
Signature
function TiptapTableToolbar({ editor })
export default memo(TiptapTableToolbar);
Import
import TiptapTableToolbar from './editor/tiptap/TableToolbar';
I/O Contract
Inputs
| Name | Type | Required | Description |
|---|---|---|---|
| editor | Editor | Yes | Tiptap editor with Table extension |
Usage Examples
Rendering Table Toolbar
import TiptapTableToolbar from './editor/tiptap/TableToolbar';
<TiptapTableToolbar editor={editor} />