blob: f05dc5ff6ab8afcccebaf697f348df379f49c46e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
Kanboard.Accordion = function(app) {
this.app = app;
};
Kanboard.Accordion.prototype.listen = function() {
$(document).on("click", ".accordion-toggle", function(e) {
var section = $(this).parents(".accordion-section");
e.preventDefault();
if (section.hasClass("accordion-collapsed")) {
section.find(".accordion-content").show();
section.removeClass("accordion-collapsed");
} else {
section.find(".accordion-content").hide();
section.addClass("accordion-collapsed");
}
});
};
|