(()=>{"use strict";var t={1455(t){t.exports=window.wp.apiFetch}},e={};function n(o){var r=e[o];if(void 0!==r)return r.exports;var s=e[o]={exports:{}};return t[o](s,s.exports,n),s.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var o in e)n.o(e,o)&&!n.o(t,o)&&Object.defineProperty(t,o,{enumerable:!0,get:e[o]})},n.o=(t,e)=>({}.hasOwnProperty.call(t,e)),(()=>{var t=n(1455),e=n.n(t);const o="__puffergoApiFetchErrorTelemetryInstalled";"undefined"==typeof window||window[o]||(window[o]=!0,e().use((t,e)=>{const n=e(t);return n&&"function"==typeof n.then?n.catch(e=>{try{!function(t){var e,n,o,r;if("undefined"==typeof window||"undefined"==typeof fetch)return;const s=window.puffergoTelemetry,i=s&&"string"==typeof s.baseUrl?s.baseUrl:"https://api.puffergo.com",a=s&&"object"==typeof s.env&&null!==s.env?s.env:{},l=(i+"").replace(/\/$/,"")+"/api/telemetry/event",c=JSON.stringify({eventType:"error",domain:null!==(e=a.domain)&&void 0!==e?e:null,phpVersion:null!==(n=a.phpVersion)&&void 0!==n?n:null,wpVersion:null!==(o=a.wpVersion)&&void 0!==o?o:null,pufferGoVersion:null!==(r=a.pufferGoVersion)&&void 0!==r?r:null,content:JSON.stringify(t)});try{fetch(l,{method:"POST",headers:{"Content-Type":"application/json"},body:c,credentials:"omit",keepalive:!0,mode:"cors"}).catch(()=>{})}catch{}}(function(t,e){const n="string"==typeof t?.path?t.path:"string"==typeof t?.url?t.url:"",o="string"==typeof t?.method?t.method:"GET";let r=null;e&&"object"==typeof e&&e.data&&"number"==typeof e.data.status?r=e.data.status:e&&"object"==typeof e&&"number"==typeof e.status&&(r=e.status);const s=e&&"object"==typeof e&&"string"==typeof e.code?e.code:null;let i="";return e instanceof Error?i=e.message||"":e&&"object"==typeof e&&"string"==typeof e.message?i=e.message:null!=e&&(i=e+""),{source:"wp_plugin_js",restPath:n,restMethod:o,httpStatus:r,code:s,message:i.slice(0,2048)}}(t,e))}catch{}return Promise.reject(e)}):n}))})(),(()=>{const t=window.wp.i18n,e=window.puffergoFseNotice||{};function n(){const t=new FormData;t.append("action",e.action),t.append("nonce",e.nonce),fetch(e.ajaxUrl,{method:"POST",body:t,credentials:"same-origin"})}function o(t){window.open(t,"_blank","noopener,noreferrer")}e.isEditor?wp.domReady(()=>{wp.data.dispatch("core/notices").createNotice("warning",(0,t.__)("The editor preview does not match your live site — this is a theme compatibility issue. Your website is displaying correctly for visitors.","puffergo"),{id:"puffergo-fse-theme-warning",isDismissible:!0,onDismiss:n,actions:[{label:(0,t.__)("Install GeneratePress (Fix Now)","puffergo"),onClick(){return o(e.installUrl)}},{label:(0,t.__)("Learn why","puffergo"),onClick(){return o(e.docsUrl)}}]})}):wp.domReady(()=>{const r=document.querySelector("#wpbody-content");if(!r)return;const s=document.createElement("div");s.className="notice notice-warning puffergo-fse-notice",s.style.cssText="display:flex;align-items:flex-start;gap:12px;padding:12px 16px;",s.innerHTML=`\n\t\t\t<div style="flex:1;">\n\t\t\t\t<p style="margin:0 0 4px;font-weight:600;">\n\t\t\t\t\t${(0,t.__)("PufferGo: current theme has editor preview compatibility issues","puffergo")}\n\t\t\t\t</p>\n\t\t\t\t<p style="margin:0 0 8px;color:#555;">\n\t\t\t\t\t${(0,t.__)("Your website is displaying correctly for visitors. Install GeneratePress to get a consistent editing experience.","puffergo")}\n\t\t\t\t</p>\n\t\t\t\t<button class="button button-small js-fse-install">\n\t\t\t\t\t${(0,t.__)("Install GeneratePress (Fix Now)","puffergo")}\n\t\t\t\t</button>\n\t\t\t\t<a style="margin-left:8px;font-size:13px;vertical-align:middle;cursor:pointer;" class="js-fse-docs">\n\t\t\t\t\t${(0,t.__)("Learn why","puffergo")}\n\t\t\t\t</a>\n\t\t\t</div>\n\t\t\t<button type="button" class="js-fse-dismiss"\n\t\t\t\tstyle="background:none;border:none;cursor:pointer;font-size:18px;line-height:1;color:#999;padding:0;flex-shrink:0;"\n\t\t\t\taria-label="${(0,t.__)("Dismiss","puffergo")}">&#x2715;</button>\n\t\t`,s.querySelector(".js-fse-install").addEventListener("click",()=>o(e.installUrl)),s.querySelector(".js-fse-docs").addEventListener("click",()=>o(e.docsUrl)),s.querySelector(".js-fse-dismiss").addEventListener("click",()=>{n(),s.remove()}),r.prepend(s)})})()})();