1import{u as j}from"./B9iTPel3.js";import{A as z,ak as Y,P as W,H as Q,al as tt,am as et,c as rt,Z as nt,Y as st,y as k,b as at}from"./D0saQJ5i.js";import"./BmjvwbSK.js";import"./Ctlgopi_.js";const ot={"images.ctfassets.net":"contentful","cdn.builder.io":"builder.io","images.prismic.io":"imgix","www.datocms-assets.com":"imgix","cdn.sanity.io":"imgix","images.unsplash.com":"imgix","cdn.shopify.com":"shopify","s7d1.scene7.com":"scene7","ip.keycdn.com":"keycdn","assets.caisy.io":"bunny","images.contentstack.io":"contentstack","ucarecdn.com":"uploadcare"},it={"imgix.net":"imgix","files.wordpress.com":"wordpress","b-cdn.net":"bunny","storyblok.com":"storyblok","kc-usercontent.com":"kontent.ai","cloudinary.com":"cloudinary","kxcdn.com":"keycdn","imgeng.in":"imageengine","imagekit.io":"imagekit","cloudimg.io":"cloudimage","ucarecdn.com":"uploadcare","supabase.co":"supabase"},ct={"/cdn-cgi/image/":"cloudflare","/cdn-cgi/imagedelivery/":"cloudflare_images","/_next/image":"nextjs","/_next/static":"nextjs","/_vercel/image":"vercel","/is/image":"scene7","/_ipx/":"ipx","/_image":"astro","/.netlify/images":"netlify","/storage/v1/object/public/":"supabase","/storage/v1/render/image/public/":"supabase"},b=e=>{if(!e)return e;const t=Number(e);return isNaN(t)?e:Math.round(t)},c=(e,t,n,s,r)=>{n?(r&&(n=b(n)),e.searchParams.set(t,n.toString())):s&&e.searchParams.delete(t)},h=(e,t,n)=>{e.searchParams.has(t)||e.searchParams.set(t,n.toString())},w=(e,t)=>{const n=Number(e.searchParams.get(t));return isNaN(n)?void 0:n},q=e=>{const{pathname:t,search:n}=e;return`${t}${n}`},v=e=>e.hostname==="n"?q(e):e.toString(),m=(e,t)=>typeof e=="string"?new URL(e,t??"http://n/"):e,I=new Map(Object.entries(ot)),ut=Object.entries(it);function lt(e){return F(e)||ft(e)}function F(e){if(typeof e=="string"&&!e.startsWith("https://"))return!1;const{hostname:t}=m(e);if(I.has(t))return I.get(t);for(const[n,s]of ut)if(t.endsWith(`.${n}`))return s;return!1}function ft(e){const{pathname:t}=m(e);for(const[n,s]of Object.entries(ct))if(t.startsWith(n))return s;return!1}const mt=({url:e,width:t,height:n,format:s})=>{const r=m(e);return t&&t>4e3&&(n&&(n=Math.round(n*4e3/t)),t=4e3),n&&n>4e3&&(t&&(t=Math.round(t*4e3/n)),n=4e3),c(r,"w",t,!0,!0),c(r,"h",n,!0,!0),c(r,"fm",s),h(r,"fit","fill"),r},dt=({url:e,width:t,height:n,format:s})=>{const r=m(e);return c(r,"width",t,!0,!0),c(r,"height",n,!0,!0),c(r,"format",s),t&&n&&(h(r,"fit","cover"),h(r,"sharp","true")),r},pt=({url:e,width:t,height:n,format:s})=>{const r=m(e);if(c(r,"w",t,!0,!0),c(r,"h",n,!0,!0),h(r,"fit","min"),s){r.searchParams.set("fm",s);const a=r.searchParams.get("auto");a==="format"?r.searchParams.delete("auto"):a?.includes("format")&&r.searchParams.set("auto",a.split(",").filter(o=>o!=="format").join(","))}else r.searchParams.delete("fm"),r.searchParams.get("auto")?.includes("format")||r.searchParams.append("auto","format");return r},ht=/(.+?)(?:_(?:(pico|icon|thumb|small|compact|medium|large|grande|original|master)|(\d*)x(\d*)))?(?:_crop_([a-z]+))?(\.[a-zA-Z]+)(\.png|\.jpg|\.webp|\.avif)?$/,gt=e=>{const t=m(e),n=t.pathname.match(ht);if(!n)throw new Error("Invalid Shopify URL");const[,s,r,a,o,i,l,f]=n;t.pathname=`${s}${l}`;const u=a||t.searchParams.get("width"),d=o||t.searchParams.get("height");return t.searchParams.delete("width"),t.searchParams.delete("height"),{base:t.toString(),width:Number(u)||void 0,height:Number(d)||void 0,format:f?f.slice(1):void 0,params:{crop:i,size:r},cdn:"shopify"}},yt=({base:e,width:t,height:n,format:s,params:r})=>{const a=m(e);return c(a,"width",t,!0,!0),c(a,"height",n,!0,!0),c(a,"crop",r?.crop),c(a,"format",s),a},bt=({url:e,width:t,height:n})=>{const s=gt(e);if(!s)return;const r={...s,width:t,height:n};return yt(r)},$t=({url:e,width:t,height:n})=>{const s=m(e);return c(s,"w",t,!0,!0),c(s,"h",n,!0,!0),h(s,"crop","1"),s},wt=({url:e,width:t,height:n})=>{const s=m(e);return c(s,"w",t,!0,!0),c(s,"h",n,!0,!0),c(s,"q",w(s,"q"),!0),s},xt=/https?:\/\/(?<host>[^\/]+)\/(?<cloudName>[^\/]+)\/(?<assetType>image|video|raw)\/(?<deliveryType>upload|fetch|private|authenticated|sprite|facebook|twitter|youtube|vimeo)\/?(?<signature>s\-\-[a-zA-Z0-9]+\-\-)?\/?(?<transformations>(?:[^_\/]+_[^,\/]+,?)*)?\/(?:(?<version>v\d+)\/)?(?<idAndFormat>[^\s]+)$/g,St=e=>e?Object.fromEntries(e.split(",").map(t=>t.split("_"))):{},B=({host:e,cloudName:t,assetType:n,deliveryType:s,signature:r,transformations:a={},version:o,id:i,format:l})=>{l&&(a.f=l);const f=Object.entries(a).map(([d,p])=>`${d}_${p}`).join(",");
1return`https://${[e,t,n,s,r,f,o,i].filter(Boolean).join("/")}`},A=e=>{const n=[...m(e).toString().matchAll(xt)];if(!n.length)throw new Error("Invalid Cloudinary URL");const s=n[0].groups||{},{transformations:r="",idAndFormat:a,...o}=s;delete s.idAndFormat;const i=a.lastIndexOf("."),l=i<0?a:a.slice(0,i),f=i<0?void 0:a.slice(i+1),{w:u,h:d,f:p,...y}=St(r),g=p&&p!=="auto"?p:f;return{base:B({...o,id:l,transformations:y}),width:Number(u)||void 0,height:Number(d)||void 0,format:g,cdn:"cloudinary",params:{...s,id:s.deliveryType==="fetch"?a:l,format:g,transformations:y}}},vt=({base:e,width:t,height:n,format:s,params:r})=>{const a=A(e.toString()),o={transformations:{},...a.params,...r,format:s||"auto"};return t&&(o.transformations.w=b(t).toString()),n&&(o.transformations.h=b(n).toString()),o.transformations.c||="lfill",B(o)},Pt=({url:e,width:t,height:n,format:s="auto"})=>{const r=A(e);if(!r)throw new Error("Invalid Cloudinary URL");if(r.params?.assetType!=="image")throw new Error("Cloudinary transformer only supports images");if(r.params?.signature)throw new Error("Cloudinary transformer does not support signed URLs");const a={...r,width:t,height:n,format:s};return vt(a)},_t=/https?:\/\/(?<host>[^\/]+)\/cdn-cgi\/image\/(?<transformations>[^\/]+)?\/(?<path>.*)$/g,Ut=e=>Object.fromEntries(e.split(",").map(t=>t.split("="))),C=({host:e,transformations:t={},path:n})=>{const s=Object.entries(t).map(([a,o])=>`${a}=${o}`).join(",");return`https://${[e,"cdn-cgi","image",s,n].join("/")}`},T=e=>{const t=m(e),n=[...t.toString().matchAll(_t)];if(!n.length)throw new Error("Invalid Cloudflare URL");const s=n[0].groups||{},{transformations:r,...a}=s,{width:o,height:i,f:l,...f}=Ut(r);return C({...a,transformations:f}),{base:t.toString(),width:Number(o)||void 0,height:Number(i)||void 0,format:l,cdn:"cloudflare",params:{...s,transformations:f}}},jt=({base:e,width:t,height:n,format:s,params:r})=>{const a=T(e.toString()),o={transformations:{},...a.params,...r};return t&&(o.transformations.width=t?.toString()),n&&(o.transformations.height=n?.toString()),s&&(o.transformations.f=s==="jpg"?"jpeg":s),o.transformations.fit||="cover",new URL(C(o))},kt=({url:e,width:t,height:n,format:s="auto"})=>{const r=T(e);if(!r)throw new Error("Invalid Cloudflare URL");const a={...r,width:t,height:n,format:s};return jt(a)},It=({url:e,width:t,height:n})=>{const s=m(e);return c(s,"width",t,!0,!0),t&&n&&h(s,"aspect_ratio",`${t}:${n}`),s},Rt=/(?<id>\/f\/\d+\/\d+x\d+\/\w+\/[^\/]+)\/?(?<modifiers>m\/?(?<crop>\d+x\d+:\d+x\d+)?\/?(?<resize>(?<flipx>\-)?(?<width>\d+)x(?<flipy>\-)?(?<height>\d+))?\/?(filters\:(?<filters>[^\/]+))?)?$/g,Ot=/^(?<modifiers>\/(?<crop>\d+x\d+:\d+x\d+)?\/?(?<resize>(?<flipx>\-)?(?<width>\d+)x(?<flipy>\-)?(?<height>\d+))?\/?(filters\:(?<filters>[^\/]+))?\/?)?(?<id>\/f\/.+)$/g,Et=e=>e?Object.fromEntries(e.split(":").map(t=>{if(!t)return[];const[n,s]=t.split("(");return[n,s.replace(")","")]})):{},Nt=e=>{if(!e)return;const t=Object.entries(e).map(([n,s])=>`${n}(${s??""})`);if(t.length!==0)return`filters:${t.join(":")}`},Lt=e=>{const t=m(e),n=t.hostname==="img2.storyblok.com"?Ot:Rt,[s]=t.pathname.matchAll(n);if(!s||!s.groups)throw new Error("Invalid Storyblok URL");const{id:r,crop:a,width:o,height:i,filters:l,flipx:f,flipy:u}=s.groups,{format:d,...p}=Et(l);return t.hostname==="img2.storyblok.com"&&(t.hostname="a.storyblok.com"),{base:t.origin+r,width:Number(o)||void 0,height:Number(i)||void 0,format:d,params:{crop:a,filters:p,flipx:f,flipy:u},cdn:"storyblok"}},zt=({base:e,width:t=0,height:n=0,format:s,params:r={}})=>{const{crop:a,filters:o,flipx:i="",flipy:l=""}=r,f=`${i}${t}x${l}${n}`;return new URL([e,"m",a,f,Nt(o),s].filter(Boolean).join("/"))},Wt=({url:e,width:t,height:n,format:s})=>{const r=Lt(e);if(r)return s&&(r.params||(r.params={filters:{}}),r.params.filters||(r.params.filters={}),r.params.filters.format=s),zt({...r,width:t,height:n})},qt=({url:e,width:t,height:n,format:s})=>{const r=m(e);return c(r,"w",t,!0,!0),c(r,"h",n,!0,!0),c(r,"fm",s,!0),t&&n&&h(r,"fit","crop"),r},R=e=>{const n=m(e).searchParams.get("url");if(!n||!n.startsWith("http"))return!1;const s=F(n);return s?{cdn:s,url:n}:!1},Ft=({base:e,width:t,params:{quality:n=75,root:s="_vercel"}={}})=>
1{const r=new URL("http://n");return r.pathname=`/${s}/image`,r.searchParams.set("url",e.toString()),c(r,"w",t,!1,!0),h(r,"q",n),q(r)},D=({url:e,width:t,cdn:n})=>{const s=m(e),r=s.pathname.startsWith("/_next/image")||s.pathname.startsWith("/_vercel/image"),a=r?s.searchParams.get("url"):e.toString();if(a)return c(s,"w",t,!0,!0),r?v(s):Ft({base:a,width:t,params:{root:n==="nextjs"?"_next":"_vercel"}})},Bt=e=>D({...e,cdn:"nextjs"}),At=({url:e,width:t,height:n,format:s})=>{const r=m(e);return c(r,"wid",t,!0,!0),c(r,"hei",n,!0,!0),c(r,"fmt",s,!0),c(r,"qlt",w(r,"qlt"),!0),c(r,"scl",w(r,"scl"),!0),h(r,"fit","crop"),!t&&!n&&h(r,"scl",1),r},Ct=({url:e,width:t,height:n,format:s})=>{const r=m(e);return c(r,"width",t,!0,!0),c(r,"height",n,!0,!0),c(r,"format",s,!0),c(r,"quality",w(r,"quality"),!0),h(r,"enlarge",0),r},Tt=({url:e,width:t,height:n,format:s})=>{const r=m(e);return c(r,"width",t,!0,!0),c(r,"height",n,!0,!0),c(r,"format",s),c(r,"quality",w(r,"quality"),!0),r},S={width:"w",height:"h",autoWidthWithFallback:"w_auto",auto_width_fallback:"w_auto",scaleToScreenWidth:"pc",scale_to_screen_width:"pc",crop:"cr",outputFormat:"f",format:"f",fit:"m",fitMethod:"m",compression:"cmpr",sharpness:"s",rotate:"r",inline:"in",keepMeta:"meta",keep_meta:"meta",noOptimization:"pass",no_optimization:"pass",force_download:"dl",max_device_pixel_ratio:"maxdpr",maxDevicePixelRatio:"maxdpr"};function Dt(e){return Object.keys(S).find(s=>S[s]===e)||""}function Mt(e){let t=e.toString(),n=[];if(t){let s=t.split("imgeng=");s.length>1&&(n=s[1].split("/"))}return n}function Ht(e){let t=e.toString(),n="";if(t){let s=t.split("imgeng=");s.length>1?n=s[0].slice(0,-1):n=t}return n}const Zt=({url:e,width:t,height:n,format:s})=>{const r=m(e),a=Ht(r);let o={};const i=r.toString()===a?[]:Mt(r);i.length&&(o=Gt(i)),t&&(o.width=t),n&&(o.height=n),s&&(o.format=s),o.hasOwnProperty("fit")||(o={...o,fit:"cropbox"});let l=Kt(o),f=Vt(l),u=f===""?"":a.includes("?")?"&":"?";return`${a}${u}${f}`};function Kt(e){return Object.entries(e).reduce((t,[n,s])=>t+Xt(n,s),"")}function Vt(e){return e&&e!==""?`imgeng=${e}`:""}function Xt(e,t){let n=S[e];return n&&(t||t===0)?`/${n}_${t}`:""}function Gt(e){let t={};return e.forEach(n=>{let s=n.split("_");if(s.length>1){let r=s[0],a=s[1],o=Dt(r);o&&(t[o]=a)}}),t}const Jt=({url:e,width:t,height:n,format:s})=>{const r=m(e);return c(r,"width",t,!0,!0),c(r,"height",n,!0,!0),c(r,"format",s),r.searchParams.has("format")||h(r,"auto","webp"),t&&n&&h(r,"fit","crop"),r},Yt=/https?:\/\/(?<host>[^\/]+)\/cdn-cgi\/imagedelivery\/(?<accountHash>[^\/]+)\/(?<imageId>[^\/]+)\/*(?<transformations>[^\/]+)*$/g,Qt=e=>Object.fromEntries(e?.split(",")?.map(t=>t.split("="))??[]),te=({host:e,accountHash:t,transformations:n={},imageId:s})=>{const r=Object.entries(n).map(([o,i])=>`${o}=${i}`).join(",");return`https://${[e,"cdn-cgi","imagedelivery",t,s,r].join("/")}`},M=e=>{const t=m(e),n=[...t.toString().matchAll(Yt)];if(!n.length)throw new Error("Invalid Cloudflare Images URL");const s=n[0].groups||{},{transformations:r,...a}=s,{w:o,h:i,f:l,...f}=Qt(r);return{base:t.toString(),width:Number(o)||void 0,height:Number(i)||void 0,format:l,cdn:"cloudflare_images",params:{...a,transformations:f}}},ee=({base:e,width:t,height:n,format:s,params:r})=>{const a=M(e.toString()),o={transformations:{},...a.params,...r};return t&&(o.transformations.w=t?.toString()),n&&(o.transformations.h=n?.toString()),s&&(o.transformations.f=s),o.transformations.fit||="cover",new URL(te(o))},re=({url:e,width:t,height:n,format:s="auto"})=>{const r=M(e);if(!r)throw new Error("Invalid Cloudflare Images URL");const a={...r,width:t,height:n,format:s};return ee(a)},ne=e=>{const t=m(e),[n,...s]=t.pathname.split("/").slice(1),r=Object.fromEntries(n.split(",").map(a=>{const[o,i]=a.split("_");return[o,i]}));if(r.s){const[a,o]=r.s.split("x");r.w||=a,r.h||=o}return{base:s.join("/"),width:Number(r.w)||void 0,height:Number(r.h)||void 0,quality:Number(r.q)||void 0,format:r.f||"auto",params:r,cdn:"ipx"}},O=({base:e,width:t,height:n,format:s,params:r})=>{const a=r?.modifiers??{};t&&n?a.s=`${t}x${n}`:t?a.w=`${t}`:n&&(a.h=`${n}`),s&&(a.f=s);const o=r?.base.endsWith("/")?r?.base:`${r?.base}/`,i=Object.entries(a).map(([u,d])=>`${u}_${d}`).join(","),l=e.toString(),f=l.startsWith("/")?l.slice(1):l;return`${o}${i}/${f}`},se=e=>{const t=String(e.url),n=m(t),s=n.pathname.startsWith("/_ipx")&&n.hostname!=="n"?`${n.origin}/_ipx`:"/_ipx",r=e.cdnOptions?.ipx?.base??s;if(r&&r!=="/"&&t.startsWith(r)){const o=ne(t.replace(r,""));return O({...o,...e,params:{...e.cdnOptions?.ipx,base:r}})}
1return O({...e,base:t,params:{...e.cdnOptions?.ipx,base:r}})},ae=({url:e,width:t,height:n,format:s})=>{const r=m(e),a=v(new URL(r.pathname,r.origin)),o={searchParams:new URLSearchParams};return c(o,"href",a,!0,!0),c(o,"w",t,!0,!0),c(o,"h",n,!0,!0),c(o,"f",s),`/_image?${o.searchParams.toString()}`},oe=new Set(["w","h","q","fm","url","width","height","quality"]),ie=e=>{const t=m(e),n=Number(t.searchParams.get("w")??t.searchParams.get("width"))??void 0,s=Number(t.searchParams.get("h")??t.searchParams.get("height"))??void 0,r=Number(t.searchParams.get("q")??t.searchParams.get("quality"))||void 0,a=t.searchParams.get("fm")||void 0,o=t.searchParams.get("url")||"",i={quality:r};return t.searchParams.forEach((l,f)=>{oe.has(f)||(i[f]=l)}),t.search="",{base:o,width:n,height:s,format:a,params:i,cdn:"netlify"}},E=({base:e,width:t,height:n,format:s,params:{site:r,quality:a,...o}={}})=>{const i=m("/.netlify/images",r);return Object.entries(o).forEach(([l,f])=>c(i,l,f)),c(i,"q",a,!0,!0),c(i,"w",t,!0,!0),c(i,"h",n,!0,!0),c(i,"fm",s),h(i,"fit","cover"),i.searchParams.set("url",e.toString()),v(i)},ce=e=>{const t=m(e.url);if(t.pathname.startsWith("/.netlify/images")){const{params:n,base:s,format:r}=ie(t);return E({base:s,format:r,...e,params:{...n,site:t.hostname==="n"?void 0:t.origin}})}return E({...e,base:e.url,params:{site:e.cdnOptions?.netlify?.site}})},ue=e=>(e.searchParams.get("tr")||"").split(",").reduce((n,s)=>{const[r,a]=s.split("-");return n[r]=a,n},{}),le=({url:e,width:t,height:n,format:s})=>{const r=m(e),a=ue(r);a.w=t&&Math.round(t),a.h=n&&Math.round(n),a.f||(a.f="auto"),s&&(a.f=s);const o=Object.keys(a).map(i=>{const l=a[i];if(l)return`${i}-${l}`}).filter(i=>i).join(",");return r.searchParams.set("tr",o),r},fe=/^https?:\/\/(?<host>[^\/]+)\/(?<uuid>[^\/]+)/g;function H(e){const t=new URL(e),n=t.pathname+t.search+t.hash,s=n.lastIndexOf("http"),r=n.lastIndexOf("/");let a="";return s>=0?a=n.slice(s):r>=0&&(a=n.slice(r+1)),a}function me(e){return e.startsWith("http")}function de(e){const t=new URL(e);return{pathname:t.origin+t.pathname||"",search:t.search||"",hash:t.hash||""}}function pe(e){const t=new URL(e),n=H(e),s=me(n)?de(n).pathname:n;return t.pathname=t.pathname.replace(s,""),t.search="",t.hash="",t.toString()}const he=e=>{if(typeof e!="string"||!e)return"";let t=e.trim();return t.startsWith("-/")?t=t.slice(2):t.startsWith("/")&&(t=t.slice(1)),t.endsWith("/")&&(t=t.slice(0,t.length-1)),t};function ge(e){const t=pe(e),n=new URL(t),s=n.pathname.indexOf("/-/");return s===-1?[]:n.pathname.substring(s).split("/-/").filter(Boolean).map(a=>he(a))}const ye=e=>e.length?e.reduce((t,n)=>{const[s,r]=n.split("/");return{...t,[s]:r}},{}):{},Z=({host:e,uuid:t,operations:n={},filename:s})=>{const r=Object.entries(n).map(([o,i])=>`${o}/${i}`).join("/-/");return`https://${[e,t,r?`-/${r}`:"",s].join("/")}`},K=e=>{const t=m(e),n=[...t.toString().matchAll(fe)];if(!n.length)throw new Error("Invalid Uploadcare URL");const s=n[0].groups||{},{...r}=s,a=H(t.toString()),{format:o,...i}=ye(ge(t.toString())),l=o&&o!=="auto"?o:"auto";return{base:Z({...r,filename:a||void 0,operations:{...i,format:l}}),cdn:"uploadcare",params:{...s,filename:a||void 0,operations:{...i,format:l}}}},be=({base:e,width:t,height:n,params:s})=>{const r=e.toString(),a=K(r.endsWith("/")?r:`${r}/`),o={operations:{},...a.params,...s};return t&&n?o.operations={...o.operations,resize:`${t}x${n}`}:(t&&(o.operations={...o.operations,resize:`${t}x`}),n&&(o.operations={...o.operations,resize:`x${n}`})),Z(o)},$e=({url:e,width:t,height:n})=>{const s=K(e);if(!s)throw new Error("Invalid Uploadcare URL");const r={...s,width:t,height:n};return be(r)},we=["origin"],V="/storage/v1/object/public/",P="/storage/v1/render/image/public/",xe=e=>e.pathname.startsWith(P),X=e=>{const t=m(e);if(!xe(t))return{cdn:"supabase",base:t.origin+t.pathname};const s=t.pathname.replace(P,""),r=t.searchParams.has("quality")?Number(t.searchParams.get("quality")):void 0,a=t.searchParams.has("width")?Number(t.searchParams.get("width")):void 0,o=t.searchParams.has("height")?Number(t.searchParams.get("height")):void 0,i=t.searchParams.has("format")?t.searchParams.get("format"):void 0,l=t.searchParams.has("resize")?t.searchParams.get("resize"):void 0;return{cdn:"supabase",base:t.origin+V+s,width:a,height:o,format:i,params:{quality:r,resize:l}}},Se=({base:e,width:t,height:n,format:s,params:r})=>{const a=X(e.toString());e=a.base,t=t||a.width,n=n||a.height,s=s||a.format,r={...a.params,...r};const o=new URLSearchParams;return t&&o.set("width",b(t).toString()),n&&o.set("height",b(n).toString()),s&&we.includes(s)&&o.set("format",s),r?.quality&&o.set("qual
1ity",b(r.quality).toString()),r?.resize&&o.set("resize",r.resize),o.toString()===""?e:a.base.replace(V,P)+"?"+o.toString()},ve=({url:e,width:t,height:n,format:s,cdnOptions:r})=>{const a=X(e);return Se({base:a.base,width:t||a.width,height:n||a.height,format:s||a.format,params:r?.supabase||a.params})},N={vercel:R,nextjs:R};function Pe(e,t){if(!(t in N))return!1;const n=N[t];return n?n(e):!1}function G(e,t){const n=lt(e)||t;if(!n)return!1;const s=Pe(e,n);return s||{cdn:n,url:e}}const J=e=>({imgix:pt,contentful:mt,"builder.io":dt,shopify:bt,wordpress:$t,cloudimage:wt,cloudinary:Pt,bunny:It,storyblok:Wt,cloudflare:kt,vercel:D,nextjs:Bt,scene7:At,"kontent.ai":qt,keycdn:Ct,directus:Tt,imageengine:Zt,contentstack:Jt,cloudflare_images:re,ipx:se,astro:ae,netlify:ce,imagekit:le,uploadcare:$e,supabase:ve})[e];var _e=(e,t)=>{if(!(!e||!t))switch(t){case"constrained":return`(min-width: ${e}px) ${e}px, 100vw`;case"fixed":return`${e}px`;case"fullWidth":return"100vw";default:return}},$=e=>e||e===0?`${e}px`:void 0,Ue=({width:e,height:t,aspectRatio:n,layout:s,objectFit:r="cover",background:a})=>{const o=[["object-fit",r]];return a?.startsWith("https:")||a?.startsWith("http:")||a?.startsWith("data:")?(o.push(["background-image",`url(${a})`]),o.push(["background-size","cover"]),o.push(["background-repeat","no-repeat"])):o.push(["background",a]),s==="fixed"&&(o.push(["width",$(e)]),o.push(["height",$(t)])),s==="constrained"&&(o.push(["max-width",$(e)]),o.push(["max-height",$(t)]),o.push(["aspect-ratio",n?`${n}`:void 0]),o.push(["width","100%"])),s==="fullWidth"&&(o.push(["width","100%"]),o.push(["aspect-ratio",n?`${n}`:void 0]),o.push(["height",$(t)])),Object.fromEntries(o.filter(([,i])=>i))},je=[6016,5120,4480,3840,3200,2560,2048,1920,1668,1280,1080,960,828,750,640],L=24,ke=({width:e,layout:t,resolutions:n=je})=>{if(t==="fullWidth")return n;if(!e)return[];const s=e*2;return t==="fixed"?[e,s]:t==="constrained"?[e,s,...n.filter(r=>r<s)]:[]},Ie=({src:e,width:t,layout:n="constrained",height:s,aspectRatio:r,breakpoints:a,cdn:o,transformer:i,format:l})=>{const f=G(e,o);if(f&&!i&&(i=J(f.cdn)),!!i)return a||=ke({width:t,layout:n}),a.sort((u,d)=>u-d).map(u=>{let d;s&&r&&(d=Math.round(u/r));const p=i({url:f?f.url:e,width:u,height:d,format:l});return p?`${p.toString()} ${u}w`:""}).join(`, 2`)};function Re({width:e,height:t,priority:n,layout:s="constrained",aspectRatio:r,...a}){return e=e&&Number(e)||void 0,t=t&&Number(t)||void 0,n?(a.loading||="eager",a.fetchpriority||="high"):(a.loading||="lazy",a.decoding||="async"),a.alt===""&&(a.role||="presentation"),r?e?t||(t=e/r):t&&(e=t*r):e&&t&&(r=e/t),{width:e,height:t,aspectRatio:r,layout:s,...a}}function Oe(e){let{src:t,cdn:n,transformer:s,background:r,layout:a,objectFit:o,breakpoints:i,width:l,height:f,aspectRatio:u,unstyled:d,...p}=Re(e);const y=t?G(t,n):void 0;let g=t;if(y&&(g=y.url,s||=J(y.cdn)),s&&r==="auto"){const x=u?Math.round(L/u):void 0,U=s({url:g,width:L,height:x});U&&(r=U.toString())}const _={width:l,height:f,aspectRatio:u,layout:a,objectFit:o,background:r};if(p.sizes||=_e(l,a),d||(p.style={...Ue(_),...p.style}),s){p.srcset=Ie({src:g,width:l,height:f,aspectRatio:u,layout:a,breakpoints:i,transformer:s,cdn:n});const x=s({url:g,width:l,height:f});x&&(g=x),(a==="fullWidth"||a==="constrained")&&(l=void 0,f=void 0)}return{...p,src:g?.toString(),width:l,height:f}}const Ee=z({__name:"image",props:{src:{},width:{},height:{},layout:{},cdn:{},priority:{type:Boolean},background:{},aspectRatio:{},objectFit:{},unstyled:{type:Boolean},transformer:{type:Function}},setup(e){const t=e,n=Y(),s=rt(()=>Oe({...n,...t}));return(r,a)=>(W(),Q("img",tt(et(s.value)),null,16))}}),qe=z({__name:"CldImage",props:{loading:{},fetchPriority:{},alt:{},width:{},height:{},config:{},layout:{},priority:{type:Boolean},background:{},blur:{},pixelate:{type:Boolean},grayscale:{type:Boolean},tint:{},opacity:{},shear:{},border:{},loaderOptions:{},zoompan:{type:[String,Boolean,Object]},fillBackground:{type:[Boolean,Object]},recolor:{},remove:{},replace:{},restore:{type:Boolean},assetType:{},crop:{},deliveryType:{},effects:{},flags:{},format:{},gravity:{},overlays:{}
2,quality:{},rawTransformations:{},removeBackground:{type:Boolean},sanitize:{type:Boolean},resize:{},seoSuffix:{},src:{},text:{},transformations:{},underlay:{},underlays:{},version:{},widthResize:{},zoom:{}},setup(e){const t=e,{config:n,loaderOptions:s,...r}=t,{url:a}=j({options:r,config:n}),o=()=>{const u={...t};u.width=typeof u.width=="string"?parseInt(u.width):u.width,u.height=typeof u.height=="string"?parseInt(u.height):u.height;let d;typeof s?.width=="number"&&typeof u.width=="number"&&s.width!==u.width?d=s.width:typeof s?.width=="number"&&typeof u?.width!="number"&&(d=s.width,u.width=d),u.width&&d&&d<u.width&&(u.widthResize=s?.width);const{url:p}=j({options:u,config:n});return p},i=at("image-key"),l=async u=>{await f(u)&&(i.value=`${i.value}-${Math.random()}`)},f=async u=>{const{src:d}=u.target;try{await new Promise((p,y)=>{fetch(d).then(g=>{if(!g.ok){y(g);return}p(g)})})}catch(p){return p.status===423?await f(u):!1}return!0};return(u,d)=>(W(),nt(k(Ee),st({key:i.value,src:k(a),layout:e.layout||"constrained",width:e.width,height:e.height},u.$attrs,{priority:e.priority,cdn:"cloudinary",transformer:o,onError:l}),null,16,["src","layout","width","height","priority"]))}});export{qe as default};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.