torchlight-laravel icon indicating copy to clipboard operation
torchlight-laravel copied to clipboard

Copy-paste snippet on Firefox adds newline between every line

Open RobertBoes opened this issue 3 years ago • 1 comments

When viewed on Firefox, if you copy a code snippet from Torchlight it adds an additional newline for every line. Copying an example on the homepage to the clipboard and then pasting results in the following:

<x-code-torchlight language='php'>

    // Any code here will be highlighted by Torchlight!

</x-code-torchlight>

While on Chrome it copies like it should:

<x-code-torchlight language='php'>
    // Any code here will be highlighted by Torchlight!
</x-code-torchlight>

It looks like Firefox copies the span.line-number as an empty line. I removed these elements from the DOM and then copying is as expected

RobertBoes avatar Jul 28 '22 16:07 RobertBoes

can you show your example, your issue is not 100% clear

timbogdanov avatar Aug 10 '23 16:08 timbogdanov