File tree Expand file tree Collapse file tree 3 files changed +6
-2
lines changed Expand file tree Collapse file tree 3 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -114,7 +114,6 @@ export default class Node extends React.Component {
114
114
}
115
115
116
116
Node . defaultProps = {
117
- circleRadius : 10 ,
118
117
textAnchor : 'start' ,
119
118
attributes : undefined ,
120
119
} ;
@@ -130,6 +129,6 @@ Node.propTypes = {
130
129
name : PropTypes . string . isRequired ,
131
130
attributes : PropTypes . object ,
132
131
textAnchor : PropTypes . string ,
133
- circleRadius : PropTypes . number ,
132
+ circleRadius : PropTypes . number . isRequired ,
134
133
styles : PropTypes . object . isRequired ,
135
134
} ;
Original file line number Diff line number Diff line change @@ -22,6 +22,7 @@ describe('<Node />', () => {
22
22
orientation : 'horizontal' ,
23
23
transitionDuration : 500 ,
24
24
onClick : ( ) => { } ,
25
+ circleRadius : 10 ,
25
26
styles : { } ,
26
27
} ;
27
28
Original file line number Diff line number Diff line change @@ -246,6 +246,7 @@ export default class Tree extends React.Component {
246
246
pathFunc,
247
247
transitionDuration,
248
248
zoomable,
249
+ circleRadius,
249
250
styles,
250
251
} = this . props ;
251
252
@@ -267,6 +268,7 @@ export default class Tree extends React.Component {
267
268
name = { nodeData . name }
268
269
attributes = { nodeData . attributes }
269
270
onClick = { this . handleNodeToggle }
271
+ circleRadius = { circleRadius }
270
272
styles = { styles . nodes }
271
273
/>
272
274
) }
@@ -300,6 +302,7 @@ Tree.defaultProps = {
300
302
scaleExtent : { min : 0.1 , max : 1 } ,
301
303
nodeSize : { x : 140 , y : 140 } ,
302
304
separation : { siblings : 1 , nonSiblings : 2 } ,
305
+ circleRadius : 10 ,
303
306
styles : {
304
307
nodes : {
305
308
node : {
@@ -348,6 +351,7 @@ Tree.propTypes = {
348
351
siblings : PropTypes . number ,
349
352
nonSiblings : PropTypes . number ,
350
353
} ) ,
354
+ circleRadius : PropTypes . number ,
351
355
styles : PropTypes . shape ( {
352
356
nodes : PropTypes . object ,
353
357
links : PropTypes . object ,
You can’t perform that action at this time.
0 commit comments