You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
725B

  1. /* Prismatic - Admin JavaScript */
  2. jQuery(document).ready(function($) {
  3. $('.wp-admin .wrap form h2').prepend('<span class="fa fa-pad fa-cog"></span> ');
  4. $('.prismatic-reset-options').on('click', function(e) {
  5. e.preventDefault();
  6. $('.prismatic-modal-dialog').dialog('destroy');
  7. var link = this;
  8. var button_names = {}
  9. button_names[prismatic_settings.reset_true] = function() { window.location = link.href; }
  10. button_names[prismatic_settings.reset_false] = function() { $(this).dialog('close'); }
  11. $('<div class="prismatic-modal-dialog">'+ prismatic_settings.reset_message +'</div>').dialog({
  12. title: prismatic_settings.reset_title,
  13. buttons: button_names,
  14. modal: true,
  15. width: 350
  16. });
  17. });
  18. });