Skip to content

Commit

Permalink
#1826: do not select a hotkey tool if we are hovering over an atom / …
Browse files Browse the repository at this point in the history
…eslint
  • Loading branch information
KonstantinEpam committed Nov 29, 2022
1 parent 0111473 commit eb97c36
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions packages/ketcher-react/src/script/ui/state/hotkeys.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,12 @@ function keyHandle(dispatch, state, hotKeys, event) {
// in this case we do not want to activate the corresponding tool
// and just insert the atom directly
const atomProps = { ...newAction.opts }
const updatedAtoms = fromAtomsAttrs(render.ctab, hoverItemId, atomProps, true)
const updatedAtoms = fromAtomsAttrs(
render.ctab,
hoverItemId,
atomProps,
true
)
editor.update(updatedAtoms)
} else {
dispatch(onAction(newAction))
Expand Down Expand Up @@ -193,7 +198,7 @@ function clipData(editor) {
if (simpleObjectOrText && window.clipboardData) {
errorHandler(
'The structure you are trying to copy contains Simple object or/and Text object.' +
'To copy Simple object or Text object in Internet Explorer try "Copy as KET" button'
'To copy Simple object or Text object in Internet Explorer try "Copy as KET" button'
)
return null
}
Expand Down

0 comments on commit eb97c36

Please sign in to comment.