mirror of
https://github.com/chanzuckerberg/cellxgene.git
synced 2026-09-30 03:08:12 +08:00
Add obs index to label file (#928)
* remove debug logging * load and save obs/row index in label file * lint * update tests
This commit is contained in:
@@ -13,7 +13,6 @@ const Annotations = (
|
||||
switch (action.type) {
|
||||
/* CATEGORY */
|
||||
case "annotation: activate add new label mode":
|
||||
console.log(action.type, action);
|
||||
return {
|
||||
...state,
|
||||
isAddingNewLabel: true,
|
||||
@@ -26,28 +25,24 @@ const Annotations = (
|
||||
categoryAddingNewLabel: null
|
||||
};
|
||||
case "annotation: add new label to category":
|
||||
console.log(action.type, action);
|
||||
return {
|
||||
...state,
|
||||
isAddingNewLabel: false,
|
||||
categoryAddingNewLabel: null
|
||||
};
|
||||
case "annotation: activate category edit mode":
|
||||
console.log(action.type, action);
|
||||
return {
|
||||
...state,
|
||||
isEditingCategoryName: true,
|
||||
categoryEditable: action.data
|
||||
};
|
||||
case "annotation: disable category edit mode":
|
||||
console.log(action.type, action);
|
||||
return {
|
||||
...state,
|
||||
isEditingCategoryName: false,
|
||||
categoryEditable: null
|
||||
};
|
||||
case "annotation: category edited":
|
||||
console.log(action.type, action);
|
||||
return {
|
||||
...state,
|
||||
isEditingCategoryName: true,
|
||||
@@ -56,7 +51,6 @@ const Annotations = (
|
||||
|
||||
/* LABEL */
|
||||
case "annotation: activate edit label mode":
|
||||
console.log(action.type, action);
|
||||
return {
|
||||
...state,
|
||||
isEditingLabelName: true,
|
||||
@@ -66,19 +60,16 @@ const Annotations = (
|
||||
}
|
||||
};
|
||||
case "annotation: cancel edit label mode":
|
||||
console.log(action.type, action);
|
||||
return {
|
||||
...state,
|
||||
isEditingLabelName: false,
|
||||
labelEditable: { category: null, label: null }
|
||||
};
|
||||
case "annotation: label edited":
|
||||
console.log(action.type, action);
|
||||
return {
|
||||
...state,
|
||||
isEditingLabelName: false,
|
||||
labelEditable: { category: null, label: null }
|
||||
/* Bruce to persist new label name */
|
||||
};
|
||||
default:
|
||||
return state;
|
||||
|
||||
Reference in New Issue
Block a user