mirror of
https://github.com/chanzuckerberg/cellxgene.git
synced 2026-09-21 14:58:11 +08:00
* Undo selection appends diffExp genes to user gene list Fixes https://github.com/chanzuckerberg/cellxgene/issues/1171 Need: When a user performs a differential expression from within a sub-selection (world) of the data and then resets the selection to all cells (universe), the differential expression results are no longer valid. Approach: * When the selection is reset, move the top (maxUserDefinedGenes - len(userDefinedGenes) from the differential expression results to the list of user defined genes * Raise maxUserDefinedGenes to 25 to give users more room and accommodate the extra genes transferred in from differential expression Other commits: * Choose different button icons * Add diff exp genes to user defined genes on subset too * Respond to feedback from @liaprins-czi and @bkmartinjr
55 lines
1.3 KiB
JavaScript
55 lines
1.3 KiB
JavaScript
// jshint esversion: 6
|
|
import React from "react";
|
|
import { AnchorButton, Tooltip } from "@blueprintjs/core";
|
|
import { tooltipHoverOpenDelay } from "../../globals";
|
|
|
|
function InformationMenu(props) {
|
|
const {
|
|
undoDisabled,
|
|
redoDisabled,
|
|
dispatch
|
|
} = props;
|
|
return (
|
|
<div style={{ marginRight: 10 }} className="bp3-button-group">
|
|
<Tooltip
|
|
content="Undo"
|
|
position="bottom"
|
|
hoverOpenDelay={tooltipHoverOpenDelay}
|
|
>
|
|
<AnchorButton
|
|
type="button"
|
|
className="bp3-button bp3-icon-undo"
|
|
disabled={undoDisabled}
|
|
onClick={() => {
|
|
dispatch({ type: "@@undoable/undo" });
|
|
}}
|
|
style={{
|
|
cursor: "pointer"
|
|
}}
|
|
data-testid="undo"
|
|
/>
|
|
</Tooltip>
|
|
<Tooltip
|
|
content="Redo"
|
|
position="bottom"
|
|
hoverOpenDelay={tooltipHoverOpenDelay}
|
|
>
|
|
<AnchorButton
|
|
type="button"
|
|
className="bp3-button bp3-icon-redo"
|
|
disabled={redoDisabled}
|
|
onClick={() => {
|
|
dispatch({ type: "@@undoable/redo" });
|
|
}}
|
|
style={{
|
|
cursor: "pointer"
|
|
}}
|
|
data-testid="redo"
|
|
/>
|
|
</Tooltip>
|
|
</div>
|
|
);
|
|
}
|
|
|
|
export default InformationMenu;
|