diff --git a/include/style/codeblock.styl b/include/style/codeblock.styl index 0cae04f..c55d045 100644 --- a/include/style/codeblock.styl +++ b/include/style/codeblock.styl @@ -13,7 +13,7 @@ figure.highlight &.folded .highlight-body height: 0 - + .copy opacity: .7 @@ -90,6 +90,10 @@ figure.highlight min-width: inherit border-radius: inherit +figure.highlight.foldable + div.level-left + cursor: pointer // clicking the codeblock filename can toggle folding + /* --------------------------------- * Fix Gist Snippet * --------------------------------- */ diff --git a/source/js/main.js b/source/js/main.js index 2b31fb7..76891f5 100644 --- a/source/js/main.js +++ b/source/js/main.js @@ -113,7 +113,7 @@ toggleFold(this, fold === 'folded'); }); - $('figure.highlight figcaption .fold').click(function() { + $('figure.highlight figcaption .level-left').click(function() { const $code = $(this).closest('figure.highlight'); toggleFold($code.eq(0), !$code.hasClass('folded')); });