Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
handleComplementSequence: props => () => {
const { sequenceData, updateSequenceData } = props;
updateSequenceData(getComplementSequenceAndAnnotations(sequenceData));
window.toastr.success("Complemented Sequence Successfully");
},
/* eslint-enable no-unused-vars */
handleComplementSelection: props => () => {
const {
sequenceData,
updateSequenceData,
selectionLayer,
wrappedInsertSequenceDataAtPositionOrRange
} = props;
if (!(selectionLayer.start > -1)) {
return; //return early
}
const comp = getComplementSequenceAndAnnotations(sequenceData, {
range: selectionLayer
});
const [newSeqData] = wrappedInsertSequenceDataAtPositionOrRange(
comp,
sequenceData,
selectionLayer,
{
maintainOriginSplit: true
}
);
updateSequenceData(newSeqData);
},