Ubuntu

­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­ !function(i){var e=function(e){if(!e.data("initialized")){var t=wp.oldEditor?wp.oldEditor:wp.editor;t&&t.hasOwnProperty("autop")&&(wp.editor.autop=t.autop,wp.editor.removep=t.removep,wp.editor.initialize=t.initialize);var n,o=e.find(".siteorigin-widget-tinymce-container"),r=o.data("editorSettings");if(tinyMCEPreInit.mceInit&&tinyMCEPreInit.mceInit.hasOwnProperty("content")){var a=tinyMCEPreInit.mceInit.content;if(a.hasOwnProperty("content_css")&&a.content_css){var c=a.content_css.split(",");if(r.tinymce.hasOwnProperty("content_css")&&r.tinymce.content_css)for(var d=0;d0&&!i.hasClass(r.selectedEditor+"-active")&&setTimeout((function(){window.switchEditors.go(m)}),10)})),t.remove(m),window.tinymce&&window.tinymce.EditorManager.overrideDefaults({base_url:r.baseURL,suffix:r.suffix}),f.is(":visible"))t.initialize(m,r);else var w=setInterval((function(){f.is(":visible")&&(t.initialize(m,r),clearInterval(w))}),500);e.on("click",(function(t){var n=i(t.target);if(n.is(".wp-switch-editor")){var o=n.hasClass("switch-tmce")?"tmce":"html";if("tmce"===o){var a=window.tinymce.get(m);if(null!==a){var c=f.val();-1!==c.search("<")&&-1===c.search(">")&&(c=c.replace(/0?n.is(":visible")?e(t):n.on("slideToggleOpenComplete",(function(){n.is(":visible")&&(e(t),n.off("slideToggleOpenComplete"))})):e(t)})),i(document).on("sortstop",(function(t,n){(n.item.is(".siteorigin-widget-field-repeater-item")?n.item.find("> .siteorigin-widget-field-repeater-item-form"):n.item.find(".siteorigin-widget-form")).find(".siteorigin-widget-field-type-tinymce").each((function(){i(this).data("initialized",null),e(i(this))}))}))}(jQuery);