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:
@ -29,6 +29,7 @@ logo : # path of logo image to display in the masthead, e.g.
|
||||
masthead_title : # overrides the website title displayed in the masthead, use " " for no title
|
||||
# breadcrumbs : false # true, false (default)
|
||||
words_per_minute : 200
|
||||
enable_copy_code_button : # true, false (default)
|
||||
copyright : # "copyright" name, defaults to site.title
|
||||
copyright_url : # "copyright" URL, defaults to site.url
|
||||
comments:
|
||||
|
Reference in New Issue
Block a user