mirror of
https://github.com/codex-team/editor.js
synced 2026-03-14 14:45:47 +01:00
fix(link-tool): handle formatted linked text clicks
This commit is contained in:
parent
d4745be848
commit
ae90e03c60
1 changed files with 1 additions and 1 deletions
|
|
@ -771,7 +771,7 @@ export default class UI extends Module<UINodes> {
|
|||
* case when user clicks on anchor element
|
||||
* if it is clicked via ctrl key, then we open new window with url
|
||||
*/
|
||||
const element = event.target as Element;
|
||||
const element = (event.target as Element).closest("a");
|
||||
const ctrlKey = event.metaKey || event.ctrlKey;
|
||||
|
||||
if ($.isAnchor(element) && ctrlKey) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue