Skip to content

Commit

Permalink
Don't enable CodeCopyButtons by default
Browse files Browse the repository at this point in the history
Change in var name
disableCodeCopy -> ShowCodeCopyButtons
  • Loading branch information
adityatelange committed Apr 25, 2021
1 parent 14e5389 commit 8005202
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion layouts/partials/footer.html
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@
</script>
{{- end }}

{{- if (and (eq .Kind "page") (ne .Layout "archives") (ne .Layout "search") (not .Site.Params.disableCodeCopy)) }}
{{- if (and (eq .Kind "page") (ne .Layout "archives") (ne .Layout "search") (.Site.Params.ShowCodeCopyButtons)) }}
<script>
document.querySelectorAll('pre > code').forEach((codeblock) => {
const container = codeblock.parentNode.parentNode;
Expand Down

0 comments on commit 8005202

Please sign in to comment.