From 80e104e7239a7209eebd11a37e55f7b5f4b119c2 Mon Sep 17 00:00:00 2001 From: Cohee <18619528+Cohee1207@users.noreply.github.com> Date: Mon, 27 May 2024 21:50:42 +0300 Subject: [PATCH] Don't open click to edit in document mode if text selected --- public/scripts/chats.js | 1 + 1 file changed, 1 insertion(+) diff --git a/public/scripts/chats.js b/public/scripts/chats.js index 83352f644..f3019759a 100644 --- a/public/scripts/chats.js +++ b/public/scripts/chats.js @@ -1391,6 +1391,7 @@ jQuery(function () { }); $(document).on('click', 'body.documentstyle .mes .mes_text', function () { + if (window.getSelection().toString()) return; if ($('.edit_textarea').length) return; $(this).closest('.mes').find('.mes_edit').trigger('click'); });