Add "copy to clipboard" button for code blocks (#2812)
* Add copy-to-clipboard button and JS * Ignore line numbers if present * Rewrite heading permalink code to use vanilla JS * README: Add credits to zenorocha/clipboard.js (MIT License) @iBug really wants a place here in the Credits section :P * Add .no-copy for hiding the button, update docs * Add td.rouge-code to selectors * Fix navigator.clipboard branch * Add screenreader text for copy button * Restore focus to the button after copying * Add site-wide enable switch
This commit is contained in:
2
assets/js/main.min.js
vendored
2
assets/js/main.min.js
vendored
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user