diff options
author | Laria Carolin Chabowski <laria@laria.me> | 2020-09-25 22:06:12 +0200 |
---|---|---|
committer | Laria Carolin Chabowski <laria@laria.me> | 2020-09-25 22:06:12 +0200 |
commit | 5db841cbaafe2d4f4bfe9009f5ecca996f21b4d3 (patch) | |
tree | 3c18b4c464e6740cbb6697b395516e346d723303 /ratatoeskr/js | |
parent | ecec65566a4ec77edf2054984663d97df55b877a (diff) | |
download | ratatoeskr-cms-5db841cbaafe2d4f4bfe9009f5ecca996f21b4d3.tar.gz ratatoeskr-cms-5db841cbaafe2d4f4bfe9009f5ecca996f21b4d3.tar.bz2 ratatoeskr-cms-5db841cbaafe2d4f4bfe9009f5ecca996f21b4d3.zip |
Require jQuery using composer
Diffstat (limited to 'ratatoeskr/js')
-rw-r--r-- | ratatoeskr/js/backend.js | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/ratatoeskr/js/backend.js b/ratatoeskr/js/backend.js index 8b60c2d..cb276b1 100644 --- a/ratatoeskr/js/backend.js +++ b/ratatoeskr/js/backend.js @@ -1,16 +1,11 @@ -$(function() -{ - $("div.articleeditor-metabar-element h2").addClass("metabar_element_expanded").click(function() - { - self = $(this); - if(self.hasClass("metabar_element_expanded")) - { +$(function() { + $("div.articleeditor-metabar-element h2").addClass("metabar_element_expanded").on("click", function() { + var self = $(this); + if (self.hasClass("metabar_element_expanded")) { self.removeClass("metabar_element_expanded"); self.addClass("metabar_element_collapsed"); $("div.articleeditor-metabar-element-content", self.parent()).hide("fast"); - } - else - { + } else { self.removeClass("metabar_element_collapsed"); self.addClass("metabar_element_expanded"); $("div.articleeditor-metabar-element-content", self.parent()).show("fast"); |