Skip to content

Commit 915401c

Browse files
Tree lint:fix
1 parent 401255e commit 915401c

File tree

2 files changed

+4
-8
lines changed

2 files changed

+4
-8
lines changed

components/tree/__docs__/storybook-stories.jsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ import IconSettings from '../../icon-settings';
88
import { TREE } from '../../../utilities/constants';
99
import sampleNodes from '../../../utilities/sample-data/tree';
1010

11-
1211
import Tree from '../../tree';
1312
import Search from '../../forms/input/search';
1413

components/tree/index.jsx

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,7 @@ const flattenTree = (root, treeIndex = '') => {
3838
for (let index = 0; index < root.nodes.length; index++) {
3939
const curNode = root.nodes[index];
4040
nodes = nodes.concat(
41-
flattenTree(
42-
curNode,
43-
treeIndex ? `${treeIndex}-${index}` : `${index}`
44-
)
41+
flattenTree(curNode, treeIndex ? `${treeIndex}-${index}` : `${index}`)
4542
);
4643
}
4744
}
@@ -121,19 +118,19 @@ class Tree extends React.Component {
121118
focusedNodeIndex: data.treeIndex,
122119
selectedNodeIndexes,
123120
});
124-
}
121+
};
125122

126123
handleNodeBlur = () => {
127124
// There is no need to render when blurring a node because focus is either:
128125
// - outside of the tree, or
129126
// - focused on another node in the tree, which triggers its own render
130127
this.treeHasFocus = false;
131-
}
128+
};
132129

133130
handleExpand = (event, data) => {
134131
this.treeHasFocus = true;
135132
this.props.onExpandClick(event, data);
136-
}
133+
};
137134

138135
render () {
139136
// One of these is required to pass accessibility tests

0 commit comments

Comments
 (0)