mirror of
https://github.com/discourse/discourse.git
synced 2025-01-19 08:42:44 +08:00
FIX: closing an empty fullscreen composer with toggler prevents scrolling
This commit is contained in:
parent
b1d7582abe
commit
5815a33a9a
|
@ -889,10 +889,6 @@ export default Ember.Controller.extend({
|
|||
}
|
||||
]);
|
||||
} else {
|
||||
// in case the composer is
|
||||
// cancelled while in fullscreen
|
||||
$("html").removeClass("fullscreen-composer");
|
||||
|
||||
// it is possible there is some sort of crazy draft with no body ... just give up on it
|
||||
this.destroyDraft();
|
||||
this.get("model").clearState();
|
||||
|
@ -969,6 +965,10 @@ export default Ember.Controller.extend({
|
|||
},
|
||||
|
||||
close() {
|
||||
// the 'fullscreen-composer' class is added to remove scrollbars from the
|
||||
// document while in fullscreen mode. If the composer is closed for any reason
|
||||
// this class should be removed
|
||||
$("html").removeClass("fullscreen-composer");
|
||||
this.setProperties({ model: null, lastValidatedAt: null });
|
||||
},
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user