prototyping

This commit is contained in:
Colin Megill
2020-05-11 13:58:46 -04:00
parent c1bf491a96
commit 284631f9b6
4 changed files with 3269 additions and 2 deletions
+16 -2
View File
@@ -4,8 +4,8 @@
import React from "react";
import _ from "lodash";
import fuzzysort from "fuzzysort";
import { connect } from "react-redux";
import { Suggest } from "@blueprintjs/select";
import {
MenuItem,
Button,
@@ -13,7 +13,6 @@ import {
InputGroup,
ControlGroup,
} from "@blueprintjs/core";
import { Suggest } from "@blueprintjs/select";
import HistogramBrush from "../brushableHistogram";
import * as globals from "../../globals";
import actions from "../../actions";
@@ -21,8 +20,10 @@ import {
postUserErrorToast,
keepAroundErrorToast,
} from "../framework/toasters";
import GeneSet from "./geneSet";
import { memoize } from "../../util/dataframe/util";
import testGeneSets from "./test_data";
const renderGene = (fuzzySortResult, { handleClick, modifiers }) => {
if (!modifiers.matchesPredicate) {
@@ -143,6 +144,18 @@ class GeneExpression extends React.Component {
return undefined;
};
renderTestGeneSets = () => {
const sets = [];
_.forEach(testGeneSets, (setGenes, setName) => {
sets.push(
<GeneSet key={setName} setGenes={setGenes} setName={setName} />
);
});
return sets;
};
placeholderGeneNames() {
/*
return a string containing gene name suggestions for use as a user hint.
@@ -369,6 +382,7 @@ class GeneExpression extends React.Component {
})
: null}
</div>
<div>{this.renderTestGeneSets()}</div>
</div>
);
}