Allow to pass a string of FuncString for Minimap node className

This commit is contained in:
Robin Goupil
2020-08-28 20:12:11 +02:00
committed by moklick
parent 2e45e9373b
commit a00b1ad597
2 changed files with 7 additions and 2 deletions
@@ -6,17 +6,18 @@ interface MiniMapNodeProps {
width: number;
height: number;
color: string;
className: string;
borderRadius: number;
style?: CSSProperties;
}
const MiniMapNode = ({ x, y, width, height, style, color, borderRadius }: MiniMapNodeProps) => {
const MiniMapNode = ({ x, y, width, height, style, color, className, borderRadius }: MiniMapNodeProps) => {
const { background, backgroundColor } = style || {};
const fill = (color || background || backgroundColor) as string;
return (
<rect
className="react-flow__minimap-node"
className={`react-flow__minimap-node ${className}`}
x={x}
y={y}
rx={borderRadius}