feat(minimap): node color func

This commit is contained in:
moklick
2019-08-05 18:04:37 +02:00
parent 34a0df46f9
commit 24a296fef9
8 changed files with 48 additions and 9 deletions

View File

@@ -165,6 +165,11 @@ class App extends PureComponent {
>
<MiniMap
style={{ position: 'absolute', right: 10, bottom: 10 }}
nodeColor={n => {
if (n.type === 'input') return 'blue'
if (n.type === 'output') return 'green'
return 'red';
}}
/>
<button
type="button"