It's not really elegant, but I put this "copycode" marker at the end of li tags. Then, when the script does the copy action of the lines, it filters it and replace with "\n". That's why I said it's more a hack but it works. This is only appening on numbered lines code blocks.