Copying from a code block copies html

Xon

Well-known member
Affected version
2.3.0 Beta 5
If you copy from a code block (inline or otherwise), instead of formatting being vaguely copied as expected it dumps a bunch of HTML goops into the editor.

PHP:
line1;
line2;
line3;
Copying "line2;" will paste something like line2<span>;</span>
 
It's a Froala issue I guess

Sad Tb GIF by Hide The Pain Harold
 
I bet it gets really ugly with syntax highlighted code:

PHP:
public static function getGoodEditors(): array
{
    $editors = ['literally anything else', 'Froala'];
    Array::removeValue($editors, 'Froala');
    return $editors;
}
 
Yeah fun

<span>public</span> <span>static</span> <span>function</span> <span>getGoodEditors</span><span>(</span><span>)</span><span>:</span> <span>array</span><br><span>{</span><br> <span>$editors</span> <span>=</span> <span>[</span><span>'literally anything else'</span><span>,</span> <span>'Froala'</span><span>]</span><span>;</span><br> <span>Array</span><span>:</span><span>:</span><span>removeValue</span><span>(</span><span>$editors</span><span>,</span> <span>'Froala'</span><span>)</span><span>;</span><br> <span>return</span> <span>$editors</span><span>;</span><br><span>}</span>
 
Back
Top Bottom