From 176cac4fbe5f601280d09edaae72e1a89477a8c9 Mon Sep 17 00:00:00 2001 From: CorreyL Date: Sun, 21 Jan 2024 09:12:05 -0800 Subject: [PATCH] Instantiate Link with inclusive set to false Ensures consistent behavior with other common text editors, wherein after applying a link to text, the following text does not also contain the link --- libs/ui/src/components/rich-input.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/ui/src/components/rich-input.tsx b/libs/ui/src/components/rich-input.tsx index d9c71684..6b6f2f3b 100644 --- a/libs/ui/src/components/rich-input.tsx +++ b/libs/ui/src/components/rich-input.tsx @@ -440,7 +440,7 @@ export const RichInput = forwardRef( Image, Underline, Highlight, - Link.configure({ openOnClick: false }), + Link.extend({ inclusive: false }).configure({ openOnClick: false }), TextAlign.configure({ types: ["heading", "paragraph"] }), ], editorProps: {