diff --git a/client/src/components/dotplot/index.js b/client/src/components/dotplot/index.js index e23e9315..a24b75eb 100644 --- a/client/src/components/dotplot/index.js +++ b/client/src/components/dotplot/index.js @@ -6,7 +6,7 @@ import Column from "./column"; @connect((state) => ({ layoutChoice: state.layoutChoice, genesets: state.genesets.genesets, - colors: state.colors, + dotplot: state.dotplot, })) class Dotplot extends React.Component { constructor(props) { @@ -39,15 +39,15 @@ class Dotplot extends React.Component { render() { const { viewport } = this.state; - const { genesets } = this.props; + const { genesets, dotplot } = this.props; - const _TESTgeneset = genesets.get("bladder urothelial"); - const _TESTmetadatField = "tissue"; + let _geneset = null; + let _genes = null; - /* TODO(colinmegill) #632 componetize */ - if (!_TESTgeneset) return null; - - const _genes = Array.from(_TESTgeneset.genes.keys()); + if (dotplot.column) { + _geneset = genesets.get(dotplot.column); + _genes = Array.from(_geneset.genes.keys()); + } return (