File "extendify-common-430584ee2cbd6274b3e0.js"

Full Path: /home/mhtocwip/harvesthillnaturals.com/wp-content/plugins/extendify/public/build/extendify-common-430584ee2cbd6274b3e0.js
File size: 43.31 KB
MIME-type: text/plain
Charset: utf-8

"use strict";(globalThis.webpackChunkextendify=globalThis.webpackChunkextendify||[]).push([[223],{202:(e,t,a)=>{a.d(t,{Y:()=>m});var r=a(5259),i=a(7143);const n=window.wpApiSettings.root,o={"contact-form-7":{id:"contact-form-7",name:"contact-form-7/contact-form-selector",title:"Contact Form 7",links:{"wp:plugin":[{href:`${n}wp/v2/plugins/contact-form-7/wp-contact-form-7`}]}},simplybook:{id:"simplybook",name:"simplybook/widget",title:"SimplyBook",links:{"wp:plugin":[{href:`${n}wp/v2/plugins/simplybook/simplybook`}]}}};var s=a(1455),l=a.n(s),c=a(1621),d=a(7134);const g=(0,c.vt)((0,d.Zr)((e=>({installedPlugins:window.extSharedData?.activePlugins?.map((e=>e.split("/")[0])),updateInstalledPlugins:async()=>{const t=(await l()({path:"/wp/v2/plugins",method:"GET"}))?.map((e=>e.plugin.split("/")[0]));e({installedPlugins:t})}})),{name:`extendify-page-creator-page-installed-plugins-cache-${window.extSharedData.siteId}`})),p=["contact-form-7","simplybook"],m=async({patterns:e})=>{const{installBlockType:t}=(0,i.dispatch)(r.store),{installedPlugins:a,updateInstalledPlugins:n}=g.getState(),s=e.flatMap((e=>e.patternReplacementCode)).filter(Boolean),l=p.filter((e=>s.some((t=>t.includes(e)))&&!a.includes(e)));for(const e of l){const a=o[e];a&&await t(a)}await n()}},365:(e,t,a)=>{a.d(t,{$N:()=>n,NM:()=>l,Uq:()=>d,Zz:()=>i,cB:()=>c,yy:()=>s});var r=a(1380);const i=()=>{const e=new URLSearchParams(window.location.search);return["page"].includes(e.get("extendify-launch"))},n=(e,...t)=>t.reduce(((e,t)=>{if(!o(e)||!o(t))return null;const a={...e};for(const e in t)o(t[e])&&e in a?a[e]=n(a[e],t[e]):a[e]=t[e];return a}),e),o=e=>"object"==typeof e&&!Array.isArray(e)&&null!==e,s=e=>new Promise((t=>setTimeout(t,e))),l=(e,t)=>e?.filter((e=>e.includes(t)))?.length,c=async()=>{try{return await(0,r.gE)(),!0}catch(e){}return await new Promise((e=>setTimeout(e,1e3))),c()},d=async(e,{maxAttempts:t=1})=>{for(let a=1;a<=t;a++)try{await c(),await e();break}catch(e){if(a===t)throw e}}},1077:(e,t,a)=>{a.d(t,{e:()=>p});var r=a(1455),i=a.n(r),n=a(6528),o=a(1621),s=a(7134);const l="/extendify/v1/shared/activity",c={getItem:()=>i()({path:l}),setItem:(e,t)=>i()({path:l,method:"POST",data:{state:t}})},d=(0,n.N)(window.extSharedData.activity),g={actions:{}},p=(0,o.vt)((0,s.Zr)((0,s.lt)(((e,t)=>{var a;return{...g,...null!==(a=d?.state)&&void 0!==a?a:{},incrementActivity:a=>{e((e=>({...e,actions:{...e.actions,[a]:Number(t().actions[a]||0)+1}})))}}}),{name:"Extendify Activity"}),{name:"extendify_shared_activity",storage:(0,s.KU)((()=>c)),skipHydration:!0}))},1380:(e,t,a)=>{a.d(t,{Fz:()=>d,nT:()=>m,gE:()=>p,yB:()=>g});var r=a(1455),i=a.n(r),n=a(7723),o=a(8969);const s=["partnerId","devbuild","version","siteId","wpLanguage","wpVersion","siteProfile"],l={...Object.fromEntries(Object.entries(window.extSharedData).filter((([e])=>s.includes(e))))};var c=a(4866);const d=async(e,t)=>{const a=await fetch(`${o.AY}/api/draft/image`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json"},signal:t,body:JSON.stringify({...e,globalState:c.C.getState(),...l})}),r=await a.json(),i={remaining:a.headers.get("x-ratelimit-remaining"),total:a.headers.get("x-ratelimit-limit"),refresh:a.headers.get("x-ratelimit-reset")};if(!a.ok){if(r.status&&"content-policy-violation"===r.status)throw{message:(0,n.__)("Your request was rejected as a result of our safety system. Your prompt may contain text that is not allowed by our safety system.","extendify-local"),imageCredits:i};throw{message:(0,n.__)("Service temporarily unavailable","extendify-local"),imageCredits:i}}return{images:r,imageCredits:i,id:a.headers.get("x-request-id")}},g=async({slug:e,source:t,action:a="install"})=>{try{const a=await fetch(`${o.Dq}/api/v1/plugin-install`,{method:"POST",headers:{"Content-Type":"application/json","X-Extendify":"true"},body:JSON.stringify({...l,slug:e,source:t,siteCreatedAt:window.extSharedData?.siteCreatedAt})});return a.ok?await a.json():(console.error("Bad response from server"),null)}catch(e){return console.error("Error sending plugin installation notification:",e),null}},p=async()=>await i()({path:"/extendify/v1/shared/ping"}),m=async e=>{var t;const a=await i()({path:"/extendify/v1/shared/partner-plugins"});if(!Object.keys(null!==(t=a?.data)&&void 0!==t?t:{}).length)throw new Error("Could not get plugins");return e&&a.data?.[e]?a.data[e]:a.data}},3005:(e,t,a)=>{a.d(t,{X:()=>o});var r=a(1621),i=a(7134);const n=e=>({open:!1,setOpen:t=>e({open:t}),progress:"",setProgress:t=>e({progress:t}),regenerationCount:0,incrementRegenerationCount:()=>e((e=>({regenerationCount:e.regenerationCount+1})))}),o=(0,r.vt)((0,i.lt)(n,{name:"Extendify Page Creator Globals"}),n)},4039:(e,t,a)=>{a.d(t,{b:()=>m});var r=a(1455),i=a.n(r),n=a(6528),o=a(1621),s=a(7134);const l=(0,n.N)(window.extSharedData.userData.userSelectionData)?.state?.siteProfile||{},c={siteProfile:{aiDescription:window.extSharedData?.siteProfile?.aiDescription||l?.aiDescription,aiSiteType:l?.aiSiteType,aiSiteCategory:l?.aiSiteCategory,aiKeywords:l?.aiKeywords}},d=e=>({...c,setSiteProfile(t){const a=Object.assign({aiSiteType:c?.siteProfile?.aiSiteType,aiSiteCategory:c?.siteProfile?.aiSiteCategory,aiDescription:c?.siteProfile?.aiDescription,aiKeywords:c?.siteProfile?.aiKeywords},t||{});e({siteProfile:a})},resetState(){e(c)}}),g="/extendify/v1/shared/site-profile",p={getItem:async()=>await i()({path:g}),setItem:async(e,t)=>{await i()({path:g,method:"POST",data:{value:(0,n.N)(t)?.state?.siteProfile||{}}})}},m=(0,o.vt)((0,s.Zr)((0,s.lt)(d,{name:"Extendify Site Profile"}),{storage:(0,s.KU)((()=>p)),skipHydration:!1}),d)},4866:(e,t,a)=>{a.d(t,{C:()=>m});var r=a(1455),i=a.n(r),n=a(6528),o=a(1621),s=a(7134);const l="/extendify/v1/shared/image-generation",c={getItem:async()=>await i()({path:l}),setItem:async(e,t)=>await i()({path:l,method:"POST",data:{state:t}})},d={aiImageOptions:{prompt:"",size:"1024x1024"},imageCredits:{remaining:10,total:10,refresh:void 0}},g=(0,s.lt)((e=>({...d,...(0,n.N)(window.extSharedData?.globalState)?.state,updateImageCredits({remaining:t,total:a,refresh:r}){e((e=>({imageCredits:{...e.imageCredits,...t&&{remaining:t},...a&&{total:a},...r&&{refresh:r}}})))},subtractOneCredit(){e((e=>({imageCredits:{...e.imageCredits,remaining:e.imageCredits.remaining-1,refresh:new Date(Date.now()+864e5).getTime()}})))},resetImageCredits(){e({imageCredits:d.imageCredits})},setAiImageOption(t,a){e((e=>({aiImageOptions:{...e.aiImageOptions,[t]:a}})))}})),{name:"Extendify Image Generation"}),p=(0,s.Zr)(g,{name:"extendify_image_generation",storage:(0,s.KU)((()=>c)),skipHydration:!0,partialize:e=>({...e,aiImageOptions:{...e.aiImageOptions,prompt:""}})}),m=(0,o.vt)(p)},6528:(e,t,a)=>{a.d(t,{N:()=>r});const r=(e,t={})=>{if("string"!=typeof e)return null!=e?e:t;try{var a;return null!==(a=JSON.parse(e))&&void 0!==a?a:t}catch(e){return t}}},6572:(e,t,a)=>{a.d(t,{d:()=>n});var r=a(9244),i=a(1380);const n=async e=>{const t=(await(0,r.fq)())?.data?.map((e=>e.split("/")[0]))||[],a=e.filter((e=>e.pluginDependency)).map((e=>e.pluginDependency)).filter((e=>!t.includes(e)));for(const e of a)(0,i.yB)({slug:e,source:"page-creator"});for(let t=1;t<=3;t++)try{return await(0,r.A7)(e)}catch(a){if(3===t)return console.error("Failed to process patterns after 3 attempts:",a),e;await new Promise((e=>setTimeout(e,1e3)))}}},6727:(e,t,a)=>{a.d(t,{D:()=>s});var r=a(1455),i=a.n(r),n=a(8537),o=a(9244);const s=async e=>{e&&"theme"===(await i()({path:"/wp/v2/templates/extendable//page-with-title"})).source&&await(0,o.Zd)((0,n.decodeEntities)(e))}},7257:(e,t,a)=>{a.d(t,{k:()=>c});var r=a(1455),i=a.n(r),n=a(6528),o=a(1621),s=a(7134);const l={getItem:async()=>await i()({path:"/wp/v2/users/me"}),setItem:async(e,t)=>await i()({path:"/wp/v2/users/me",method:"PUT",data:{extendify_page_creator_user:t}})},c=(0,o.vt)((0,s.Zr)(((e,t)=>{var a;return{openOnNewPage:!0,allowsInstallingPlugins:!0,updateUserOption:(a,r)=>{Object.keys(t()).includes(a)&&e({[a]:r})},...null!==(a=(0,n.N)(window.extPageCreator?.userInfo)?.state)&&void 0!==a?a:{}}}),{name:"extendify_page_creator_user",storage:(0,s.KU)((()=>l)),partialize:e=>({...e,ready:!1}),skipHydration:!0}))},7431:(e,t,a)=>{a.d(t,{q:()=>r});const r=e=>{const t=window.extSharedData?.requiredPlugins;if(!t||!Array.isArray(t)||0===t.length)return e;const a=t.map((e=>({name:e?.name,wordpressSlug:e?.wordpressSlug})));return[...e,...a.filter((t=>!e.some((e=>e.wordpressSlug===t.wordpressSlug))))]}},7581:(e,t,a)=>{a.d(t,{D:()=>l});var r=a(1455),i=a.n(r),n=a(1621),o=a(7134);const s={setItem:(e,t)=>i()({path:"/extendify/v1/shared/update-user-meta",method:"POST",data:{option:"ai_consent",value:t.state.userGaveConsent}})},l=(0,n.vt)((0,o.Zr)((0,o.lt)(((e,t)=>{var a,r,i;return{showAIConsent:null!==(a=window.extSharedData?.showAIConsent)&&void 0!==a&&a,consentTermsCustom:null!==(r=window.extSharedData?.consentTermsCustom)&&void 0!==r?r:"",userGaveConsent:null!==(i=window.extSharedData?.userGaveConsent)&&void 0!==i&&i,setUserGaveConsent:t=>e({userGaveConsent:t}),shouldShowAIConsent:e=>{var a;const{showAIConsent:r,consentTermsCustom:i,userGaveConsent:n}=t(),o=r&&i,s={launch:o,draft:o&&!n,"help-center":o&&!n};return null!==(a=s?.[e])&&void 0!==a&&a}}}),{name:"Extendify AI Consent"}),{name:"extendify-ai-consent",storage:s,skipHydration:!0}))},7828:(e,t,a)=>{a.d(t,{X:()=>i});var r=a(6087);const i=(e,t)=>{"function"==typeof r.createRoot?(0,r.createRoot)(t).render(e):(0,r.render)(e,t)}},8455:(e,t,a)=>{a.d(t,{f:()=>n});var r=a(1621),i=a(7134);const n=(0,r.vt)((0,i.Zr)((0,i.lt)(((e,t)=>({images:[],expiration:0,isEmpty:()=>0===t().images.length,hasExpired:()=>Date.now()>t().expiration,updateCache:t=>e({images:t,expiration:Date.now()+6048e5})})),{name:"Extendify Unsplash Images"}),{name:`extendify-unsplash-images-${window.extSharedData.siteId}`,storage:(0,i.KU)((()=>localStorage))}))},8512:(e,t,a)=>{a.d(t,{Q:()=>i});var r=a(7723);const i={about:{
// translators: This string represents the title of an "About" page on a website that provides information about the website or organization. Please translate it in a way that fits the standard phrasing for an "About" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("About","extendify-local"),
// translators: This string represents the slug of an "About" page on a website that provides information about the website or organization. Please translate it in a way that fits a slug for an "About" page in the target language, considering the common usage in websites for that language.
slug:(0,r.__)("about","extendify-local"),alias:["about","about-us","recognition","stats"]},blog:{
// translators: This string represents the title of a "Blog" page on a website that shows recent blog posts. Please translate it in a way that fits the standard phrasing for a "Blog" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Blog","extendify-local"),
// translators: This string represents the slug of a "Blog" page on a website that shows recent blog posts. Please translate it in a way that fits a slug for a "Blog" page in the target language, considering the common usage in websites for that language.
slug:(0,r.__)("blog","extendify-local"),alias:["blog","blog-categories","blog-section"]},book:{
// translators: This string represents the title of a "Book" page on a website that is meant for booking something. Please translate it in a way that fits the standard phrasing for a "Book" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Book Now","extendify-local"),
// translators: This string represents the slug of a "Book" page on a website that is meant for booking something. Please translate it in a way that fits a slug for a "Book" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("book-now","extendify-local"),alias:["book","booking"]},careers:{
// translators: This string represents the title of a "Careers" page on a website that is meant for listing available careers. Please translate it in a way that fits the standard phrasing for a "Careers" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Careers","extendify-local"),
// translators: This string represents the slug of a "Careers" page on a website that is meant for listing available careers. Please translate it in a way that fits a slug for a "Careers" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("careers","extendify-local"),alias:["careers","career","career-with-opening"]},contact:{
// translators: This string represents the title of a "Contact" page on a website that gives information for visitors on how to contact the website or organization. Please translate it in a way that fits the standard phrasing for a "Contact" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Contact","extendify-local"),
// translators: This string represents the slug of a "Contact" page on a website that gives information for visitors on how to contact the website or organization. Please translate it in a way that fits a slug for a "Contact" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("contact","extendify-local"),alias:["contact","contact-form","contact-in-person"]},events:{
// translators: This string represents the title of an "Events" page on a website that lists events of any kind. Please translate it in a way that fits the standard phrasing for an "Events" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Events","extendify-local"),
// translators: This string represents the slug of an "Events" page on a website that lists events of any kind. Please translate it in a way that fits a slug for an "Events" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("events","extendify-local"),alias:["events","events-section"]},faq:{
// translators: This string represents the title of a "FAQ" page on a website that gives information related to frequently asked questions. Please translate it in a way that fits the standard phrasing for a "FAQ" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("FAQ","extendify-local"),
// translators: This string represents the slug of a "FAQ" page on a website that gives information related to frequently asked questions. Please translate it in a way that fits a slug for a "FAQ" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("faq","extendify-local"),alias:["faq"]},features:{
// translators: This string represents the title of a "Features" page on a website that lists features of a product or service. Please translate it in a way that fits the standard phrasing for a "Features" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Features","extendify-local"),
// translators: This string represents the slug of a "Features" page on a website that lists features of a product or service. Please translate it in a way that fits a slug for a "Features" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("features","extendify-local"),alias:["features"]},gallery:{
// translators: This string represents the title of a "Gallery" page on a website that shows a collection of images. Please translate it in a way that fits the standard phrasing for a "Gallery" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Gallery","extendify-local"),
// translators: This string represents the slug of a "Gallery" page on a website that shows a collection of images. Please translate it in a way that fits a slug for a "Gallery" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("gallery","extendify-local"),alias:["gallery"]},home:{
// translators: This string represents the title of an "Home" page on a website. Please translate it in a way that fits the standard phrasing for a "Home" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Home","extendify-local"),alias:["home"]},menu:{
// translators: This string represents the title of a "Menu" page on a website that lists food or drink items. Please translate it in a way that fits the standard phrasing for a "Menu" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Menu","extendify-local"),
// translators: This string represents the slug of a "Menu" page on a website that lists food or drink items. Please translate it in a way that fits a slug for a "Menu" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("menu","extendify-local"),alias:["menu"]},portfolio:{
// translators: This string represents the title of a "Portfolio" page on a website that showcases a collection of work. Please translate it in a way that fits the standard phrasing for a "Portfolio" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Portfolio","extendify-local"),
// translators: This string represents the slug of a "Portfolio" page on a website that showcases a collection of work. Please translate it in a way that fits a slug for a "Portfolio" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("portfolio","extendify-local"),alias:["portfolio"]},pricing:{
// translators: This string represents the title of a "Pricing" page on a website that lists the pricing of products or services. Please translate it in a way that fits the standard phrasing for a "Pricing" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Pricing","extendify-local"),
// translators: This string represents the slug of a "Pricing" page on a website that lists the pricing of products or services. Please translate it in a way that fits a slug for a "Pricing" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("pricing","extendify-local"),alias:["pricing"]},products:{
// translators: This string represents the title of a "Products" page on a website that lists products. Please translate it in a way that fits the standard phrasing for a "Products" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Products","extendify-local"),
// translators: This string represents the slug of a "Products" page on a website that lists products. Please translate it in a way that fits a slug for a "Products" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("products","extendify-local"),alias:["products","best-sellers-products","featured-products","new-arrivals-product","on-sale-products","product-section","products-by-category","products-categories","top-rated-products"]},quote:{
// translators: This string represents the title of a "Quote" page on a website that allows visitors to request a quote. Please translate it in a way that fits the standard phrasing for a "Quote" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Quote","extendify-local"),
// translators: This string represents the slug of a "Quote" page on a website that allows visitors to request a quote. Please translate it in a way that fits a slug for a "Quote" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("quote","extendify-local"),alias:["quote"]},reservation:{
// translators: This string represents the title of a "Reservation" page on a website that allows visitors to make a reservation. Please translate it in a way that fits the standard phrasing for a "Reservation" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Reservation","extendify-local"),
// translators: This string represents the slug of a "Reservation" page on a website that allows visitors to make a reservation. Please translate it in a way that fits a slug for a "Reservation" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("reservation","extendify-local"),alias:["reservation"]},resources:{
// translators: This string represents the title of a "Resources" page on a website that provides resources. Please translate it in a way that fits the standard phrasing for a "Resources" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Resources","extendify-local"),
// translators: This string represents the slug of a "Resources" page on a website that provides resources. Please translate it in a way that fits a slug for a "Resources" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("resources","extendify-local"),alias:["resources","resource"]},serviceArea:{
// translators: This string represents the title of a "Service Area" page on a website that shows the service area of a business, including a map. Please translate it in a way that fits the standard phrasing for a "Service Area" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Service Area","extendify-local"),
// translators: This string represents the slug of a "Service Area" page on a website that shows the service area of a business, including a map. Please translate it in a way that fits a slug for a "Service Area" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("service-area","extendify-local"),alias:["service-area"]},services:{
// translators: This string represents the title of a "Services" page on a website that lists services. Please translate it in a way that fits the standard phrasing for a "Services" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Services","extendify-local"),
// translators: This string represents the slug of a "Services" page on a website that lists services. Please translate it in a way that fits a slug for a "Services" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("services","extendify-local"),alias:["services"]},specials:{
// translators: This string represents the title of a "Specials" page on a website that lists special offers. Please translate it in a way that fits the standard phrasing for a "Specials" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Specials","extendify-local"),
// translators: This string represents the slug of a "Specials" page on a website that lists special offers. Please translate it in a way that fits a slug for a "Specials" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("specials","extendify-local"),alias:["specials"]},team:{
// translators: This string represents the title of a "Team" page on a website that introduces the team members. Please translate it in a way that fits the standard phrasing for a "Team" page in the target language, considering the common usage in websites for
title:(0,r.__)("Team","extendify-local"),
// translators: This string represents the slug of a "Team" page on a website that introduces the team members. Please translate it in a way that fits a slug for a "Team" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("team","extendify-local"),alias:["team"]},testimonials:{
// translators: This string represents the title of a "Testimonials" page on a website that showcases testimonials from customers. Please translate it in a way that fits the standard phrasing for a "Testimonials" page in the target language, considering the common usage in websites for that language.
title:(0,r.__)("Testimonials","extendify-local"),
// translators: This string represents the slug of a "Testimonials" page on a website that showcases testimonials from customers. Please translate it in a way that fits a slug for a "Testimonials" page in the target language, considering the common usage in websites for that language. Make sure to keep the slug lowercase and url-friendly.
slug:(0,r.__)("testimonials","extendify-local"),alias:["testimonials","testimonial"]}}},8579:(e,t,a)=>{a.d(t,{f:()=>j});var r=a(6087),i=a(7723),n=a(8969),o=a(9244),s=a(7257),l=a(7431);const{siteTitle:c,siteType:d}=window.extSharedData,g={...Object.fromEntries(Object.entries(window.extSharedData).filter((([e])=>["partnerId","devbuild","version","siteId","wpLanguage","wpVersion","siteProfile"].includes(e))))},p=async({pageProfile:e,siteImages:t,sitePlugins:a})=>{const r=await(0,o.PF)(),i=await(async(e={})=>{var t;const{showLocalizedCopy:a,activePlugins:r,installedPlugins:i}=window.extSharedData,{allowsInstallingPlugins:o}=s.k.getState(),l=e?.sitePlugins||[],c=null!==(t=r?.map((e=>e.split("/")[0])))&&void 0!==t?t:[],p=Object.entries(e).reduce(((e,[t,a])=>({...e,[t]:"object"==typeof a?JSON.stringify(a):a})),{}),m=await fetch(`${n.zL}/api/page-creator`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({...g,siteType:d?.slug,showLocalizedCopy:!!a,allowsInstallingPlugins:o,plugins:JSON.stringify(c),installedPlugins:JSON.stringify(i),allowedPlugins:JSON.stringify(l),...p})});if(!m.ok)throw new Error("Bad response from server");return await m.json()})({siteInformation:{title:c},siteImages:t,siteStyle:r,pageProfile:e,sitePlugins:a});if(!i?.template)throw new Error("Could not get page");return"extendable"!==(window.extSharedData?.themeSlug||"extendable")&&(i.template.patterns=i.template.patterns.filter((e=>!e.patternTypes.includes("page-title")))),i},m=async({page:e,userState:t,pageProfile:a})=>{const r=await fetch(`${n.AY}/api/patterns`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({...g,page:e,userState:t,siteProfile:a})});if(!r.ok)throw new Error("Bad response from server");return await r.json()},u=async({description:e,siteProfile:t})=>{const a=await fetch(`${n.AY}/api/page-profile`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({...g,siteDescription:t?.aiDescription||"",description:e})});if(!a?.ok)throw new Error("Something went wrong while fetching the profile");const r=await a.json();return r?.aiDescription?r:{aiTitle:null,aiPageType:null,aiDescription:null,aiKeywords:[]}},y=async({pageProfile:e})=>{const{aiSiteType:t,aiSiteCategory:a,aiDescription:r,aiKeywords:i}=e,o=new URLSearchParams({aiSiteType:t,aiSiteCategory:a,aiDescription:r,aiKeywords:i,...g,source:"page-creator"});c&&o.append("title",c);const s=await fetch(`${n.a3}/api/search?${o}`,{method:"GET",headers:{"Content-Type":"application/json"}});if(!s?.ok)throw new Error("Something went wrong while fetching the images");const l=await s.json();return l?.siteImages?l:{siteImages:[]}},f=async({pageProfile:e})=>{const t=`${n.AY}/api/site-plugins`,a="POST",r={"Content-Type":"application/json"},i=(0,l.q)([]);if(!e)return i;const{wpLanguage:o,partnerId:s,pluginGroupId:c}=window.extSharedData,d=JSON.stringify({aiSiteType:e?.aiPageType||"",aiDescription:e?.aiDescription||"",aiKeywords:e?.aiKeywords||[],siteQuestions:[],wpLanguage:o,partnerId:s,pluginGroupId:c});let g;try{if(g=await fetch(t,{method:a,headers:r,body:d}),!g?.ok)throw new Error("Bad response from server")}catch(e){try{g=await fetch(t,{method:a,headers:r,body:d})}catch{return i}}if(!g?.ok)return i;try{var p;const e=await g.json(),t=null!==(p=e?.selectedPlugins)&&void 0!==p?p:i;return(0,l.q)(t)}catch(e){return i}};var w=a(9130),h=a(3005),x=a(4039),v=a(4225);const S=()=>{const{description:e}=(0,w.C)(),{setProgress:t,regenerationCount:a}=(0,h.X)(),{siteProfile:n}=(0,x.b)(),{data:o,error:s}=(0,v.A)({key:`page-profile-${a}`,description:e,siteProfile:n},u);return(0,r.useEffect)((()=>{o||t((0,i.__)("Generating AI page profile...","extendify-local"))}),[o,t]),{pageProfile:o,error:s,loading:!o&&!s}};var b=a(2177);const _=JSON.parse('{"twentytwentyfive":{"colorSlugs":{"background":"base","foreground":"contrast","primary":"contrast","secondary":"accent-4","tertiary":"accent-1","foreground-alt":"contrast"},"spacingScale":{"20":"30","30":"40","40":"50","50":"60","60":"70","70":"min(7rem,10vw)","80":"80"},"fontSizeScale":{"small":"small","medium":"medium","large":"x-large","x-large":"xx-large","xx-large":"xx-large"}},"twentytwentyfour":{"colorSlugs":{"background":"base","foreground":"contrast","primary":"contrast-2","secondary":"accent-3","tertiary":"base-2","foreground-alt":"contrast"},"spacingScale":{"20":"1rem","30":"30","40":"70","50":"40","60":"50","70":"min(7rem,10vw)","80":"60"},"fontSizeScale":{"small":"small","medium":"medium","large":"large","x-large":"x-large","xx-large":"xx-large"}},"astra":{"colorSlugs":{"background":"ast-global-color-4","foreground":"ast-global-color-2","primary":"ast-global-color-0","secondary":"ast-global-color-6","tertiary":"ast-global-color-5","foreground-alt":"ast-global-color-3"},"spacingScale":{"20":"1rem","30":"min(2rem, 5vw)","40":"min(3rem, 6vw)","50":"min(4rem, 7vw)","60":"min(6rem, 8vw)","70":"min(7rem, 10vw)","80":"min(8rem, 12vw)"},"fontSizeScale":{"small":"small","medium":"medium","large":"x-large","x-large":"xx-large","xx-large":"xx-large"}},"hello-elementor":{"colorSlugs":{"background":"white","foreground":"black","primary":"vivid-red","secondary":"vivid-purple","tertiary":"cyan-bluish-gray","foreground-alt":"black"},"spacingScale":{"20":"20","30":"60","40":"70","50":"min(4rem,7vw)","60":"min(6rem,8vw)","70":"min(7rem,10vw)","80":"min(8rem,12vw)"},"fontSizeScale":{"small":"small","medium":"medium","large":"large","x-large":"x-large","xx-large":"xx-large"}},"twentytwentytwo":{"colorSlugs":{"background":"background","foreground":"foreground","primary":"primary","secondary":"vivid-purple","tertiary":"tertiary","foreground-alt":"foreground"},"spacingScale":{"20":"20","30":"60","40":"70","50":"min(4rem,7vw)","60":"min(6rem,8vw)","70":"min(7rem,10vw)","80":"min(8rem,12vw)"},"fontSizeScale":{"small":"small","medium":"medium","large":"large","x-large":"x-large","xx-large":"xx-large"}},"generatepress":{"colorSlugs":{"background":"base-3","foreground":"contrast","primary":"accent","secondary":"contrast-2","tertiary":"base","foreground-alt":"contrast"},"spacingScale":{"20":"20","30":"60","40":"70","50":"min(4rem,7vw)","60":"min(6rem,8vw)","70":"min(7rem,10vw)","80":"min(8rem,12vw)"},"fontSizeScale":{"small":"small","medium":"medium","large":"large","x-large":"x-large","xx-large":"xx-large"}},"divi":{"colorSlugs":{"background":"background","foreground":"foreground","primary":"primary","secondary":"vivid-purple","tertiary":"tertiary","foreground-alt":"foreground"},"spacingScale":{"20":"20","30":"60","40":"70","50":"min(4rem,7vw)","60":"min(6rem,8vw)","70":"min(7rem,10vw)","80":"min(8rem,12vw)"},"fontSizeScale":{"small":"small","medium":"medium","large":"large","x-large":"x-large","xx-large":"xx-large"}},"twentytwentythree":{"colorSlugs":{"background":"background","foreground":"foreground","primary":"primary","secondary":"vivid-purple","tertiary":"tertiary","foreground-alt":"foreground"},"spacingScale":{"20":"20","30":"60","40":"70","50":"min(4rem,7vw)","60":"min(6rem,8vw)","70":"min(7rem,10vw)","80":"min(8rem,12vw)"},"fontSizeScale":{"small":"small","medium":"medium","large":"large","x-large":"x-large","xx-large":"xx-large"}},"ultra":{"colorSlugs":{"background":"white","foreground":"black","primary":"vivid-red","secondary":"vivid-purple","tertiary":"cyan-bluish-gray","foreground-alt":"black"},"spacingScale":{"20":"20","30":"60","40":"70","50":"min(4rem,7vw)","60":"min(6rem,8vw)","70":"min(7rem,10vw)","80":"min(8rem,12vw)"},"fontSizeScale":{"small":"small","medium":"medium","large":"large","x-large":"x-large","xx-large":"xx-large"}},"oceanwp":{"colorSlugs":{"background":"white","foreground":"black","primary":"vivid-red","secondary":"vivid-purple","tertiary":"cyan-bluish-gray","foreground-alt":"black"},"spacingScale":{"20":"20","30":"60","40":"70","50":"min(4rem,7vw)","60":"min(6rem,8vw)","70":"min(7rem,10vw)","80":"min(8rem,12vw)"},"fontSizeScale":{"small":"small","medium":"medium","large":"large","x-large":"x-large","xx-large":"xx-large"}},"kadence":{"colorSlugs":{"background":"theme-palette-8","foreground":"theme-palette-3","primary":"theme-palette-1","secondary":"theme-palette-2","tertiary":"theme-palette-9","foreground-alt":"theme-palette-3"},"spacingScale":{"20":"20","30":"60","40":"70","50":"min(4rem,7vw)","60":"min(6rem,8vw)","70":"min(7rem,10vw)","80":"min(8rem,12vw)"},"fontSizeScale":{"small":"small","medium":"medium","large":"large","x-large":"x-large","xx-large":"xx-large"}},"popularfx":{"colorSlugs":{"background":"white","foreground":"black","primary":"vivid-red","secondary":"vivid-purple","tertiary":"cyan-bluish-gray","foreground-alt":"black"},"spacingScale":{"20":"20","30":"60","40":"70","50":"min(4rem,7vw)","60":"min(6rem,8vw)","70":"min(7rem,10vw)","80":"min(8rem,12vw)"},"fontSizeScale":{"small":"normal","medium":"medium","large":"large","x-large":"x-large","xx-large":"xx-large"}},"blocksy":{"colorSlugs":{"background":"palette-color-7","foreground":"palette-color-3","primary":"palette-color-1","secondary":"palette-color-4","tertiary":"palette-color-5","foreground-alt":"palette-color-3"},"spacingScale":{"20":"20","30":"60","40":"70","50":"min(4rem,7vw)","60":"min(6rem,8vw)","70":"min(7rem,10vw)","80":"min(8rem,12vw)"},"fontSizeScale":{"small":"normal","medium":"medium","large":"large","x-large":"x-large","xx-large":"xx-large"}},"neve":{"colorSlugs":{"background":"nv-site-bg","foreground":"neve-text-color","primary":"nv-primary-accent","secondary":"nv-secondary-accent","tertiary":"nv-light-bg","foreground-alt":"neve-text-color"},"spacingScale":{"20":"20","30":"60","40":"70","50":"min(4rem,7vw)","60":"min(6rem,8vw)","70":"min(7rem,10vw)","80":"min(8rem,12vw)"},"fontSizeScale":{"small":"medium","medium":"medium","large":"x-large","x-large":"x-large","xx-large":"xx-large"}}}'),P="extendable",k=e=>e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),C=(e={})=>{const t={};return Object.entries(e).forEach((([e,a])=>{t[`"backgroundColor":"${e}"`]=`"backgroundColor":"${a}"`,t[`"textColor":"${e}"`]=`"textColor":"${a}"`,t[`"linkColor":"${e}"`]=`"linkColor":"${a}"`,t[`has-${e}-background-color`]=`has-${a}-background-color`,t[`has-${e}-color`]=`has-${a}-color`,t[`has-${e}-link-color`]=`has-${a}-link-color`,t[`var:preset|color|${e}`]=`var:preset|color|${a}`,t[`var(--wp--preset--color--${e})`]=`var(--wp--preset--color--${a})`})),t},T=(e={})=>{const t={};return Object.entries(e).forEach((([e,a])=>{const r=a.startsWith("min(")?a:`var:preset|spacing|${a}`,i=a.startsWith("min(")?a:`var(--wp--preset--spacing--${a})`;t[`var:preset|spacing|${e}`]=r,t[`var(--wp--preset--spacing--${e})`]=i})),t},I=(e={})=>{const t={};return Object.entries(e).forEach((([e,a])=>{t[`"fontSize":"${e}"`]=`"fontSize":"${a}"`,t[`has-${e}-font-size`]=`has-${a}-font-size`})),t};function O(e="",t=P){if(!e||t===P)return e;const a=_[t];if(!a)return e;const r={...C(a.colorSlugs),...T(a.spacingScale),...I(a.fontSizeScale)};if(console.log("map",r),"kadence"===t&&Object.keys(r).forEach((e=>{(e.startsWith('"backgroundColor":')||e.startsWith('"textColor":')||e.startsWith('"linkColor":'))&&r[e].includes("theme-palette-")&&(r[e]=r[e].replace(/theme-palette-(\d+)/,"theme-palette$1"))})),!Object.keys(r).length)return e;const i=new RegExp(Object.keys(r).map(k).join("|"),"g");return e.replace(i,(e=>{var t;return null!==(t=r[e])&&void 0!==t?t:e}))}var D=a(6528);const{state:$}=(0,D.N)(window.extSharedData?.userData?.userSelectionData),E=window.extSharedData.siteId,A=window.extSharedData?.themeSlug||"extendable",j=()=>{const{pageProfile:e}=S(),{template:t}=(()=>{var e;const{pageProfile:t}=S(),{siteImages:a}=(()=>{const{loading:e,pageProfile:t}=S(),{setProgress:a,regenerationCount:n}=(0,h.X)(),{data:o,error:s}=(0,v.A)(e?null:{key:`page-images-${n}`,pageProfile:t},y);return(0,r.useEffect)((()=>{o||a((0,i.__)("Finding images...","extendify-local"))}),[o,a]),{siteImages:o,error:s,loading:!o&&!s}})(),{sitePlugins:s}=(({disableFetch:e=!1}={})=>{const{loading:t,pageProfile:a}=S(),r={key:"site-plugins-page-creator",pageProfile:a},{data:i,error:n}=(0,b.Ay)(t||e?null:r,f);return{sitePlugins:i,error:n,loading:!i&&!n}})(),l=!t||!a||!s,{setProgress:c,regenerationCount:d}=(0,h.X)(),m={key:`page-creator-page-layout-${d}`,pageProfile:t,siteImages:a,sitePlugins:s},u=t?.isImprintPage?()=>(async()=>{const e=await(0,o.PF)(),t=`${n.zL}/api/page-imprint`,a=await fetch(t,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({...g,siteStyle:JSON.stringify(e)})});if(!a.ok)throw new Error("Could not get imprint page");const r=await a.json();if(!r?.template)throw new Error("No template found for imprint page");return{...r.template}})():p,{data:w,error:x}=(0,v.A)(l?null:m,u);return(0,r.useEffect)((()=>{w||c((0,i.__)("Creating a custom layout...","extendify-local"))}),[w,c]),{template:null!==(e=w?.template)&&void 0!==e?e:w,error:x,loading:!w&&!x}})(),{setProgress:a,regenerationCount:s}=(0,h.X)(),l=!e||!t,c=e?.isImprintPage,d={key:`page-creator-page-custom-content-${s}`,pageProfile:e,userState:{businessInformation:$?.businessInformation,siteInformation:$?.siteInformation,siteId:E},page:t},{data:u,error:w}=(0,v.A)(l||c?null:d,m),x=(0,r.useMemo)((()=>c&&t?{patterns:t.patterns||[]}:u),[c,t,u]);(0,r.useEffect)((()=>{l||a((0,i.__)("Writing custom content...","extendify-local"))}),[x,a,l]);const _=(0,r.useMemo)((()=>x?.patterns?x.patterns.map((e=>({...e,code:O(e.code,A)}))):[]),[x?.patterns]);return{page:x?{patterns:_,title:e.aiTitle}:x,error:w,loading:!x&&!w}}},8969:(e,t,a)=>{a.d(t,{AY:()=>r,Dq:()=>o,XQ:()=>n,a3:()=>s,zL:()=>i});const{AI_HOST:r="https://ai.extendify.com",PATTERNS_HOST:i="https://patterns.extendify.com",KB_HOST:n="https://kb.extendify.com",INSIGHTS_HOST:o="https://insights.extendify.com",IMAGES_HOST:s="https://images-resource.extendify.com"}={}},9130:(e,t,a)=>{a.d(t,{C:()=>n});var r=a(1621),i=a(7134);const n=(0,r.vt)((0,i.Zr)((e=>({description:null,setDescription:t=>e({description:t}),reset:()=>e({description:null})})),{name:`extendify-page-creator-page-description-cache-${window.extSharedData.siteId}`}))},9244:(e,t,a)=>{a.d(t,{A7:()=>c,D3:()=>l,PF:()=>s,Zd:()=>d,fq:()=>g});var r=a(1455),i=a.n(r),n=a(7723),o=a(3832);const s=async()=>await i()({method:"GET",path:(0,o.addQueryArgs)("/extendify/v1/page-creator/settings/get-option",{name:"extendify_siteStyle"})})||{vibe:"standard"},l=async(e,t)=>await i()({path:"/extendify/v1/page-creator/settings/single",method:"POST",data:{key:e,value:t}}),c=e=>i()({path:"/extendify/v1/shared/process-placeholders",method:"POST",data:{patterns:e}}),d=e=>{const t=`\n\t\t\x3c!-- wp:template-part {"slug":"header","tagName":"header"} /--\x3e\n\t\t\x3c!-- wp:group {"tagName":"main","style":{"spacing":{"margin":{"top":"0px","bottom":"0px"},"blockGap":"0"}}} --\x3e\n\t\t<main class="wp-block-group" style="margin-top:0px;margin-bottom:0px">\n\t\t\t${e}\n\t\t\t\x3c!-- wp:post-content {"layout":{"type":"constrained"}} /--\x3e\n\t\t</main>\n\t\t\x3c!-- /wp:group --\x3e\n\t\t\x3c!-- wp:template-part {"slug":"footer","tagName":"footer"} /--\x3e\n\t\t`;return i()({path:"/wp/v2/templates/extendable/page-with-title",method:"POST",data:{slug:"page-with-title",theme:"extendable",type:"wp_template",status:"publish",description:(0,n.__)("Added by Launch","extendify-local"),content:t}})},g=async()=>await i()({path:"/extendify/v1/launch/active-plugins",method:"GET"})},9246:(e,t,a)=>{a.d(t,{f:()=>r});const r=(e,t)=>e.replace(/(<div\s[^>]*class="[^"]*\bwp-block-group\b[^"]*")/,`$1 id="${t}"`)},9324:(e,t,a)=>{a.d(t,{Bf:()=>c,GV:()=>g,OH:()=>s,xZ:()=>l,yt:()=>d});var r=a(1455),i=a.n(r),n=a(3832),o=a(8969);const s=async()=>{const e=await i()({path:"/wp/v2/plugins"});if(!e)throw new Error("Failed to fetch installed plugins");return e},l=async e=>await i()({path:"/wp/v2/plugins",method:"POST",data:{slug:e}}),c=async e=>{const t=await(async e=>{const t=await i()({path:(0,n.addQueryArgs)("/wp/v2/plugins",{search:e})});let a=t?.[0];if(!a)throw new Error("Plugin not found");return a})(e);return await i()({path:`/wp/v2/plugins/${t.plugin}`,method:"POST",data:{status:"active"}})},d=e=>new Promise(((t,a)=>{e.onload=()=>t(e),e.onerror=e=>a(e)})),g=async(e,t,a,r,n={alt:"",caption:""})=>{let o;r&&await p(e,a,{unsplashId:r});try{o=await(async(e,t={})=>{var a,r;const n=new Image;n.src=e,n.crossOrigin="anonymous",await d(n);const o=document.createElement("canvas");o.width=n.width,o.height=n.height;const s=o.getContext("2d");if(!s)return;s.drawImage(n,0,0);const l=await new Promise((e=>{o.toBlob((t=>{t&&e(t)}),"image/jpeg")})),c=new FormData;return c.append("file",new File([l],t.filename)),c.append("alt_text",null!==(a=t.alt)&&void 0!==a?a:""),c.append("caption",null!==(r=t.caption)&&void 0!==r?r:""),c.append("status","publish"),await i()({path:"wp/v2/media",method:"POST",body:c})})(t,{alt:n.alt,filename:"image.jpg",caption:n.caption})}catch(e){o=await(async(e,t={})=>{var a,r;const n=new FormData;return n.append("source",e),n.append("alt_text",null!==(a=t.alt)&&void 0!==a?a:""),n.append("caption",null!==(r=t.caption)&&void 0!==r?r:""),await i()({path:"/extendify/v1/draft/upload-image",method:"POST",body:n})})(t,{alt:n.alt,filename:"image.jpg",caption:n.caption})}return o},p=(e,t,a={})=>fetch(`${o.AY}/api/draft/image/download`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({id:e,source:t,...a})})},9358:(e,t,a)=>{a.d(t,{E:()=>g,P:()=>d});var r=a(8969),i=a(7581),n=a(8455);const{showAIConsent:o,userGaveConsent:s}=i.D.getState(),l=["siteId","partnerId","wpVersion","wpLanguage","devbuild","isBlockTheme","userId","siteProfile"],c={...Object.fromEntries(Object.entries(window.extSharedData).filter((([e])=>l.includes(e)))),showAIConsent:o,userGaveConsent:s},d=async(e,t=null)=>{const a=new URLSearchParams({...c,query:e,source:t}),i=await fetch(`${r.AY}/api/draft/image/unsplash?${a.toString()}`,{method:"GET",headers:{"Content-Type":"application/json"}});if(!i.ok)throw new Error("Bad response from server");const n=await i.json();if(!Array.isArray(n))throw new Error("Bad response from server");return n.map((e=>({...e,requestMetadata:{id:i.headers.get("X-Request-Id"),total:i.headers.get("X-Total"),perPage:i.headers.get("X-Per-Page")}})))},g=async()=>{var e;const t=n.f.getState();if(!t.isEmpty()&&!t.hasExpired())return t.images;const{aiKeywords:a}=null!==(e=window.extSharedData?.siteProfile)&&void 0!==e?e:{},r=a?.length?a:[],i=(await Promise.all(r.map((e=>d(e,"prefetch"))))).flat(),o=i.reduce(((e,t)=>(e.has(t.id)||e.set(t.id,t),e)),new Map);return t.updateCache(Array.from(o.values())),i}},9666:(e,t,a)=>{a.d(t,{j:()=>r});const r=window.extSharedData?.showAIPageCreation}}]);