From: Alexander Ebert Date: Mon, 20 Jan 2020 18:36:19 +0000 (+0100) Subject: Misaligned caret in Safari 13+ using the invisible space X-Git-Tag: 5.2.2~43 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=ac07f290efa0a23744243a1df9481c9547d96d47;p=GitHub%2FWoltLab%2FWCF.git Misaligned caret in Safari 13+ using the invisible space --- diff --git a/com.woltlab.wcf/templates/wysiwyg.tpl b/com.woltlab.wcf/templates/wysiwyg.tpl index 394a223ce3..8554634890 100644 --- a/com.woltlab.wcf/templates/wysiwyg.tpl +++ b/com.woltlab.wcf/templates/wysiwyg.tpl @@ -256,6 +256,11 @@ } }; + // The caret is misaligned in Safari 13+ when using \u200b. + if (Environment.browser() === 'safari') { + config.emptyHtml = '


'; + } + // user mentions if (elDataBool(element, 'support-mention')) { config.plugins.push('WoltLabMention'); @@ -290,7 +295,7 @@ config.callbacks.init = function() { // slight delay to allow Redactor to initialize itself window.setTimeout(function() { - if (content === '' && Environment.platform() === 'ios') { + if (content === '' && (Environment.platform() === 'ios' || Environment.browser() === 'safari')) { content = '


'; }