disable shield background in distraction free mode, fixes #226

This commit is contained in:
azivner 2018-11-14 13:42:50 +01:00
parent 6652ddc20a
commit 040bb13800
2 changed files with 4 additions and 1 deletions

View file

@ -60,6 +60,7 @@ function registerEntrypoints() {
// when hiding switch display to block, otherwise grid still tries to display columns which shows
// left empty column
$container.css("display", $container.css("display") === "grid" ? "block" : "grid");
$container.toggleClass("distraction-free-mode");
});
// hide (toggle) everything except for the note content for distraction free writing

View file

@ -99,7 +99,9 @@ body {
overflow: auto;
}
#note-detail-wrapper.protected {
/** we disable shield background when in distraction free mode because I couldn't get it to stay static
(it kept growing with content) */
#container:not(.distraction-free-mode) #note-detail-wrapper.protected {
/* DON'T COLLAPSE THE RULES INTO SINGLE ONE, BACKGROUND WON'T DISPLAY */
background: url('/images/shield.svg') no-repeat;
background-size: contain;