mirror of
https://github.com/chanzuckerberg/cellxgene.git
synced 2026-09-23 22:38:11 +08:00
reducer
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
const Dotplot = (
|
||||
state = {
|
||||
row: null,
|
||||
column: null,
|
||||
},
|
||||
action
|
||||
) => {
|
||||
switch (action.type) {
|
||||
case "set dotplot row":
|
||||
return {
|
||||
...state,
|
||||
row: action.data,
|
||||
};
|
||||
case "set dotplot column":
|
||||
return {
|
||||
...state,
|
||||
column: action.data,
|
||||
};
|
||||
default:
|
||||
return state;
|
||||
}
|
||||
};
|
||||
|
||||
export default Dotplot;
|
||||
Reference in New Issue
Block a user