mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2025-12-10 18:03:01 +00:00
feat(hotkey): when text is selected, allow the default copy and paste behavior
This commit is contained in:
parent
4507e83d7d
commit
4e0b2fae5d
@ -277,6 +277,10 @@ export const builtinHotkey = (ctx: IPublicModelPluginContext) => {
|
||||
if (isFormEvent(e) || !doc) {
|
||||
return;
|
||||
}
|
||||
const anchorValue = document.getSelection()?.anchorNode?.nodeValue;
|
||||
if (anchorValue && typeof anchorValue === 'string') {
|
||||
return;
|
||||
}
|
||||
e.preventDefault();
|
||||
|
||||
let selected = doc.selection.getTopNodes(true);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user