When I go to https://doc.wikimedia.org/codex/main/design-tokens/color.html using Chrome on Ubuntu, and I click the "Copy" button next to e.g. color-base--hover, the string that is copied to my clipboard has a newline at the start (i.e."\ncolor-base--hover").
This doesn't happen in Firefox. It seems like it might be caused by the complex code that tries to make this work in older iOS versions; the code mentions not being able to use textarea.select(); for that reason, but if I use that instead of range.selectNodeContents( textarea ); the bug goes away.