Skip to content

Commit

Permalink
- fixed lots of tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Konstantin Zharich committed Dec 14, 2023
1 parent b4ef67e commit 73b4283
Showing 1 changed file with 2 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ import {
selectActivePreset,
selectIsEditMode,
selectPresetFullName,
selectPresets,
setActiveRnaBuilderItem,
setIsEditMode,
} from 'state/rna-builder';
Expand All @@ -46,12 +45,10 @@ export const scrollToSelectedMonomer = (monomerId) => {

export const RnaEditor = ({ duplicatePreset }) => {
const activePreset = useAppSelector(selectActivePreset);
const presets = useAppSelector(selectPresets);
const isEditMode = useAppSelector(selectIsEditMode);
const activePresetFullName = selectPresetFullName(activePreset);

const dispatch = useAppDispatch();
const hasPresets = presets.length !== 0;

const [expanded, setExpanded] = useState(false);

Expand All @@ -61,10 +58,8 @@ export const RnaEditor = ({ duplicatePreset }) => {
return;
}

if (!hasPresets) {
dispatch(createNewPreset());
dispatch(setActiveRnaBuilderItem(RnaBuilderPresetsItem.Presets));
}
dispatch(createNewPreset());
dispatch(setActiveRnaBuilderItem(RnaBuilderPresetsItem.Presets));
}, [activePreset]);

const expandEditor = () => {
Expand Down

0 comments on commit 73b4283

Please sign in to comment.