mirror of
https://github.com/lidarr/lidarr.git
synced 2025-08-21 14:03:29 -07:00
animate I say!
This commit is contained in:
parent
27fc51da48
commit
5928ffc693
3 changed files with 25 additions and 0 deletions
20
UI/Mixins/backbone.marionette.region.mixin.js
Normal file
20
UI/Mixins/backbone.marionette.region.mixin.js
Normal file
|
@ -0,0 +1,20 @@
|
|||
"use strict";
|
||||
|
||||
(function () {
|
||||
|
||||
var _originalRegionClose = Marionette.Region.prototype.close;
|
||||
|
||||
Marionette.Region.prototype.open = function (view) {
|
||||
var self = this;
|
||||
|
||||
this.$el.fadeOut(200, function () {
|
||||
_originalRegionClose.apply(this, arguments);
|
||||
self.$el.html(view.el);
|
||||
self.$el.fadeIn(150);
|
||||
});
|
||||
};
|
||||
|
||||
Marionette.Region.prototype.close = function () {
|
||||
//do nothing. we close the region as part of open so we can chain the animation
|
||||
};
|
||||
}());
|
Loading…
Add table
Add a link
Reference in a new issue