From 9eb96dd945308d713f4827b9f823c17a365ea7d8 Mon Sep 17 00:00:00 2001 From: Mo Bitar Date: Tue, 22 Aug 2017 19:45:48 -0500 Subject: [PATCH] Fix save status overlap issue in editor title bar --- app/assets/javascripts/app/frontend/controllers/editor.js | 3 ++- app/assets/stylesheets/app/_editor.scss | 7 ++----- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/app/assets/javascripts/app/frontend/controllers/editor.js b/app/assets/javascripts/app/frontend/controllers/editor.js index 8c86acb1f..af682c160 100644 --- a/app/assets/javascripts/app/frontend/controllers/editor.js +++ b/app/assets/javascripts/app/frontend/controllers/editor.js @@ -289,7 +289,6 @@ angular.module('app.frontend') var note = this.note; note.dummy = false; this.save()(note, function(success){ - this.syncTakingTooLong = false; if(success) { if(statusTimeout) $timeout.cancel(statusTimeout); statusTimeout = $timeout(function(){ @@ -298,12 +297,14 @@ angular.module('app.frontend') status += " (offline)"; } this.saveError = false; + this.syncTakingTooLong = false; this.noteStatus = $sce.trustAsHtml(status); }.bind(this), 200) } else { if(statusTimeout) $timeout.cancel(statusTimeout); statusTimeout = $timeout(function(){ this.saveError = true; + this.syncTakingTooLong = false; this.noteStatus = $sce.trustAsHtml("Error syncing
(changes saved offline)") }.bind(this), 200) } diff --git a/app/assets/stylesheets/app/_editor.scss b/app/assets/stylesheets/app/_editor.scss index ca1c82d6f..edc06299a 100644 --- a/app/assets/stylesheets/app/_editor.scss +++ b/app/assets/stylesheets/app/_editor.scss @@ -31,11 +31,7 @@ $heading-height: 75px; z-index: 100; height: auto; - // height: $heading-height; - // min-height: $heading-height; - padding-right: 10px; - overflow: visible; &.fullscreen { @@ -47,11 +43,12 @@ $heading-height: 75px; font-weight: bold; padding-top: 0px; width: 100%; + padding-right: 120px; /* make room for save status */ > .input { float: left; text-overflow:ellipsis; - width: 90%; + width: 100%; font-weight: bold; border: none; outline: none;