ru-se.com

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

customizer-footer.js (776B)


      1 (function ($) {
      2     window.CP_Customizer.addModule(function (CP_Customizer) {
      3         var control = wp.customize.panel('footer_panel');
      4 
      5         if (!control) {
      6             return;
      7         }
      8 
      9         var $footerLi = control.container.eq(0);
     10         // remove default events
     11         $footerLi.children('h3').addBack().off();
     12 
     13         $footerLi.find('[data-name="change"]').addBack().click(function (event) {
     14             event.preventDefault();
     15             event.stopPropagation();
     16 
     17             var sectionID = 'reiki_webpage_footers';
     18             if (CP_Customizer.isRightSidebarVisible(sectionID)) {
     19                 CP_Customizer.hideRightSidebar();
     20             } else {
     21                 CP_Customizer.openRightSidebar(sectionID);
     22             }
     23         });
     24     });
     25 })(jQuery);