From: Marcel Werk Date: Tue, 30 Mar 2021 17:54:29 +0000 (+0200) Subject: Remove/replace nbsp when copying code to the clipboard X-Git-Tag: 5.3.6~31 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e8ebe776ba63bb06d9203484b65bf7a46149a758;p=GitHub%2FWoltLab%2FWCF.git Remove/replace nbsp when copying code to the clipboard --- diff --git a/wcfsetup/install/files/js/WoltLabSuite/Core/Clipboard.js b/wcfsetup/install/files/js/WoltLabSuite/Core/Clipboard.js index fc35381cc8..592988e0d3 100644 --- a/wcfsetup/install/files/js/WoltLabSuite/Core/Clipboard.js +++ b/wcfsetup/install/files/js/WoltLabSuite/Core/Clipboard.js @@ -60,7 +60,7 @@ define(['Environment', 'Ui/Screen'], function(Environment, UiScreen) { }, copyElementTextToClipboard: function (element) { - return this.copyTextToClipboard(element.textContent); + return this.copyTextToClipboard(element.textContent.replace(/\u200B/g, '').replace(/\u00A0/g, ' ')); } }; });