When using line numbers with table style, the border radius for the
corresponding codeblocks leads to annoying gaps between the line numbers
and the actual code.
This commit removes the border radius when the corresponding element is
displayed inside a table (which is the case when line numbers are used
with table format).
The PaperMod theme uses a border-radius for codeblocks by default. The
div that contains the corresponding code element uses the default
background color, independent of the selected theme (dark vs. light).
This causes an incorrect coloring in the corners of code blocks.
This commits overwrites the background color of the surrounding div with
the current theme color.
Many of the CSS files had no semicolon after the last rule in a block,
which is proper syntax, but it's annoying when adding more rules. Since
omitting the semicolons doesn't really have a benefit, I've decided to
add them.
* add buttons to copy code block contents
Adds a clickable "copy" link in the top-right corner of each code block.
If available, uses the navigator.clipboard API. Falls back to selecting
the text and calling document.execCommand('copy') to copy text.
* hides copy button unless mouse is hovering over code block
* change text of copy button when text is copied
* add translation keys for copy button text `code_copy` and `code_copied`
* To disable use `Params.disableCodeCopy: true` in site config