Advertisement
Guest User

Untitled

a guest
Jun 25th, 2017
63
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.08 KB | None | 0 0
  1. jQuery( document ).ready( function() {
  2.  
  3. 'use strict';
  4.  
  5. if ( ! _.isUndefined( kirkiIcons.section ) ) {
  6.  
  7. // Parse sections and add icons.
  8. _.each( kirkiIcons.section, function( icon, sectionID ) {
  9.  
  10. // Add icons in list.
  11. jQuery( '#accordion-section-' + sectionID + ' > h3' ).prepend( '<span class="' + icon + '" style="padding-right:.2em;"></span>' );
  12.  
  13. // Add icons on titles when a section is open.
  14. jQuery( '#sub-accordion-section-' + sectionID + ' .customize-section-title > h3' ).append( '<span class="' + icon + '" style="padding-right:.2em; padding-top: 2px; float:left;"></span>' );
  15. } );
  16.  
  17. }
  18.  
  19. if ( ! _.isUndefined( kirkiIcons.panel ) ) {
  20.  
  21. _.each( kirkiIcons.panel, function( icon, panelID ) {
  22.  
  23. // Add icons in lists & headers.
  24. jQuery( '#sub-accordion-panel-' + panelID + ' .panel-title' ).prepend( '<span class="' + icon + '" style="padding-right:.2em; padding-top: 2px;"></span>' );
  25.  
  26. // Add icons on titles when a panel is open.
  27. jQuery( '#accordion-panel-' + panelID + ' > h3' ).prepend( '<span class="' + icon + '" style="padding-right:.2em;"></span>' );
  28. } );
  29.  
  30. }
  31.  
  32. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement