Merge pull request #11034 from ejegg/docStrings
[civicrm-core.git] / js / crm.wordpress.js
index 6ca4ff504d08ef3addffbd8679c7f40c422d3c13..774b24a35fd0a3b52189bbf0b19b190dfd1516af 100644 (file)
@@ -10,5 +10,12 @@ CRM.$(function($) {
         // Restore admin bar position
         $('#adminmenuwrap').css('z-index', '');
       }
+    })
+    .on('crmWysiwygCreate', function(e, type, editor) {
+      if (type === 'ckeditor') {
+        editor.on('maximize', function(e) {
+          $('#wpadminbar').toggle(e.data === 2);
+        });
+      }
     });
 });