mirror of https://github.com/ColorlibHQ/AdminLTE
Now the collapse and expand event are triggered after the event loop, Fixes #2019
parent
f0edf90f88
commit
68834fc648
|
@ -1077,7 +1077,7 @@ throw new Error('AdminLTE requires jQuery')
|
||||||
|
|
||||||
parent.addClass(ClassName.open);
|
parent.addClass(ClassName.open);
|
||||||
tree.slideDown(this.options.animationSpeed, function () {
|
tree.slideDown(this.options.animationSpeed, function () {
|
||||||
$(this.element).trigger(expandedEvent);
|
setTimeout(() => $(this.element).trigger(expandedEvent),0)
|
||||||
}.bind(this));
|
}.bind(this));
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -1088,7 +1088,7 @@ throw new Error('AdminLTE requires jQuery')
|
||||||
parentLi.removeClass(ClassName.open);
|
parentLi.removeClass(ClassName.open);
|
||||||
tree.slideUp(this.options.animationSpeed, function () {
|
tree.slideUp(this.options.animationSpeed, function () {
|
||||||
//tree.find(Selector.open + ' > ' + Selector.treeview).slideUp();
|
//tree.find(Selector.open + ' > ' + Selector.treeview).slideUp();
|
||||||
$(this.element).trigger(collapsedEvent);
|
setTimeout(() => $(this.element).trigger(collapsedEvent), 0);
|
||||||
}.bind(this));
|
}.bind(this));
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue