Welcome to Codidact Meta!
Codidact Meta is the meta-discussion site for the Codidact community network and the Codidact software. Whether you have bug reports or feature requests, support questions or rule discussions that touch the whole network – this is the site for you.
Quick copy button for code blocks
Code blocks have a maximum height, after which any extra content scrolls vertically. This can make it tricky to copy the code for testing or adjusting when answering a question, or assessing an answer. Sometimes while trying to highlight the code in the code block ready for copying, other text on the page suddenly becomes highlighted too.
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Some example code
Would it be feasible to have a way of copying the full content of the code block, perhaps a button next to the code block?
I'm not sure the best way to do this without getting in the way of reading the code block, but I thought it might be worth discussing options.
1 answer
This is now fixed. A "copy" button appears in the top right corner of a code block on hover (desktop) or on tap (mobile).
0 comment threads