From 6711ceb877e1be4d5bdcf55a80f057eb83b65f5d Mon Sep 17 00:00:00 2001 From: Denis Tingaikin Date: Tue, 14 Jan 2025 08:13:49 +0300 Subject: [PATCH] fix edge case for Link extenstions (#7646) Signed-off-by: denis-tingaikin --- packages/text/src/kits/default-kit.ts | 2 +- plugins/text-editor-resources/src/kits/default-kit.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/text/src/kits/default-kit.ts b/packages/text/src/kits/default-kit.ts index 3c698985d1..56aea0a518 100644 --- a/packages/text/src/kits/default-kit.ts +++ b/packages/text/src/kits/default-kit.ts @@ -55,7 +55,7 @@ export const DefaultKit = Extension.create({ multicolor: false }), Typography.configure({}), - Link.configure({ + Link.extend({ inclusive: false }).configure({ openOnClick: true, HTMLAttributes: { class: 'cursor-pointer', rel: 'noopener noreferrer', target: '_blank' } }) diff --git a/plugins/text-editor-resources/src/kits/default-kit.ts b/plugins/text-editor-resources/src/kits/default-kit.ts index 84a700525c..e67de7cf3d 100644 --- a/plugins/text-editor-resources/src/kits/default-kit.ts +++ b/plugins/text-editor-resources/src/kits/default-kit.ts @@ -1,5 +1,5 @@ // -// Copyright © 2023, 2024 Hardcore Engineering Inc. +// Copyright © 2023, 2024, 2025 Hardcore Engineering Inc. // // Licensed under the Eclipse Public License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. You may @@ -61,7 +61,7 @@ export const DefaultKit = Extension.create({ multicolor: false }), Typography.configure({}), - Link.configure({ + Link.extend({ inclusive: false }).configure({ openOnClick: true, HTMLAttributes: { class: 'cursor-pointer', rel: 'noopener noreferrer', target: '_blank' } }),