You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Open MindMap provides a comprehensive CSS customization system. You can control the appearance of every element using CSS custom properties, semantic class selectors, and data attributes — all without writing any JavaScript.
Overview
The styling system works in three layers:
CSS Custom Properties — Set on .mindmap-container, these control theme-level values (colors, fonts, sizes). Override them to change the entire look.
CSS Class Selectors — Semantic classes on every SVG element (.mindmap-edge, .mindmap-node-root, etc.) allow targeted styling. SVG presentation attributes have lower specificity than CSS rules, so your styles always win.
Data Attributes — data-branch-index="0" through "9" on nodes and edges enable per-branch customization.
CSS Custom Properties
Override these on .mindmap-container (or any ancestor) to change theme values:
All SVG elements have semantic CSS classes. Since SVG presentation attributes (e.g., fill="red") have lower specificity than CSS rules, your class-based styles always take precedence.
Container & Canvas
Class
Element
.mindmap-container
Outer wrapper div (CSS variables are set here)
.mindmap-svg
Main SVG element
.mindmap-canvas
Inner <g> group (pan/zoom transform)
Nodes
Class
Element
.mindmap-node-g
Any node group (root or child)
.mindmap-node-root
Root node group (depth = 0)
.mindmap-node-child
Child node group (depth > 0)
.mindmap-node-bg
Node background <rect>
.mindmap-node-text
Node text <text> element
.mindmap-node-content
Node content wrapper <g>
.mindmap-node-underline
Child node underline <line>
.mindmap-node-ghost
Applied when a node is being dragged
Edges
Class
Element
.mindmap-edge
Regular connection line <path>
.mindmap-edge-cross-link
Cross-link edge
.mindmap-edge-label
Edge label text
Inline Formatting (inside SVG <text>)
Class
Element
.mindmap-text-bold
Bold <tspan>
.mindmap-text-italic
Italic <tspan>
.mindmap-text-strikethrough
Strikethrough <tspan>
.mindmap-text-code
Inline code <tspan>
.mindmap-text-highlight
Highlight <tspan>
.mindmap-text-link
Link <a> wrapping <tspan>
.mindmap-text-plain
Plain text <tspan>
.mindmap-code-bg
Code background <rect>
.mindmap-highlight-bg
Highlight background <rect>
Tags
Class
Element
.mindmap-tag
Tag group <g>
.mindmap-tag-bg
Tag background <rect>
.mindmap-tag-text
Tag text <text>
UI Controls
Class
Element
.mindmap-add-btn
Add child button group
.mindmap-fold-btn
Fold/unfold toggle button
.mindmap-zoom-controls
Zoom toolbar container
.mindmap-extra-controls
Mode/fullscreen toolbar
.mindmap-context-menu
Right-click context menu
.mindmap-remark-tooltip
Remark hover tooltip
.mindmap-edit-input
Inline edit input
.mindmap-text-editor
Text mode editor <textarea>
Data Attributes
data-branch-index
Every node and edge has a data-branch-index attribute (0–9) indicating which branch of the root it belongs to. Descendants inherit their ancestor's branch index.