diff --git a/inst/resources/gitbook/js/plugin-fontsettings.js b/inst/resources/gitbook/js/plugin-fontsettings.js index f0017920..5a89cb99 100644 --- a/inst/resources/gitbook/js/plugin-fontsettings.js +++ b/inst/resources/gitbook/js/plugin-fontsettings.js @@ -83,12 +83,7 @@ gitbook.require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) { } var lineHeight = Math.max(fontState.spacing / 10, 1); $book.find('section').css('line-height', lineHeight); - - if (lineHeight <= 1) { - $(".font-settings .font-reduce").prop('disabled', true); - } else { - $(".font-settings .font-reduce").prop('disabled', false); - } + $(".font-settings .spacing-reduce").prop('disabled', lineHeight <= 1); }; function init(config) {