Add configuration options

This commit is contained in:
John Furrow
2016-02-11 18:26:00 -08:00
parent 0fd6fd7d11
commit 366cb1b428
8 changed files with 24 additions and 16 deletions
@@ -69,7 +69,7 @@ export default class DirectoryFiles extends React.Component {
return (
<div className="directory-tree__node directory-tree__node--file file"
key={`${index}`} title={file.filename}>
key={`${index}-${file.filename}`} title={file.filename}>
<div className="file__detail file__name">
<File />
{file.filename}
@@ -83,7 +83,8 @@ export default class DirectoryFiles extends React.Component {
</div>
<div className="file__detail file__detail--priority">
<PriorityMeter level={this.state.priorities[file.index]}
fileIndex={file.index} onChange={this.handlePriorityChange} />
fileIndex={file.index} onChange={this.handlePriorityChange}
key={`${file.index}-${file.filename}`} />
</div>
</div>
);
@@ -26,12 +26,12 @@ export default class DirectoryTree extends React.Component {
if (branchName === 'files') {
return (
<DirectoryFileList branch={branch} hash={hash}
key={`${index}${depth}`} />
key={`${index}${depth}${branchName}`} />
);
} else {
return (
<DirectoryTreeNode depth={depth} directoryName={branchName}
hash={hash} subTree={branch} key={`${index}${depth}`} />
hash={hash} subTree={branch} key={`${index}${depth}${branchName}`} />
);
}
});
@@ -25,7 +25,7 @@ export default class DirectoryTreeNode extends React.Component {
return (
<div className="directory-tree__node directory-tree__node--group">
<DirectoryTree tree={this.props.subTree} depth={this.props.depth}
hash={this.props.hash} />
hash={this.props.hash} key={`${this.state.expanded}-${this.props.depth}`} />
</div>
);
} else {