Skip to content

Commit

Permalink
Fix toc bug.
Browse files Browse the repository at this point in the history
  • Loading branch information
Kenshin committed Feb 7, 2020
1 parent 87edb57 commit f562468
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/userscript/simpread.js
Original file line number Diff line number Diff line change
Expand Up @@ -1100,7 +1100,9 @@ function toc() {
});
event.preventDefault();
})
simpread.read.toc_hide && $('head').append( `<style>toc-bg{width:50px!important;height:200px!important}.toc-bg-hidden{transition:opacity .2s ease}.toc-bg-hidden:hover toc{width:180px}toc{width:0;transition:width .5s!important}</style>` );
simpread.read.toc_hide ?
$('head').append( `<style>toc-bg{width:50px!important;height:200px!important}.toc-bg-hidden{transition:opacity .2s ease}.toc-bg-hidden:hover toc{width:180px}toc{width:0;transition:width .5s!important}</style>` )
: $( "toc" ).css({ "width" : "initial" });
}

/**
Expand Down

0 comments on commit f562468

Please sign in to comment.