efficient-storefront-blocks 0.138.1 → 0.139.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (26) hide show
  1. package/CHANGELOG.md +10 -0
  2. package/dist/chunks/{CustomHtmlCodeWindow-4OS3BLNS.js → CustomHtmlCodeWindow-FSTAOP3D.js} +1 -1
  3. package/dist/chunks/{EditorPreviewCheckout-RF2M6FBA.js → EditorPreviewCheckout-KKWOYQT5.js} +1 -1
  4. package/dist/chunks/SiteEditorProvider-ESDRW5S4.js +1 -0
  5. package/dist/chunks/{chunk-LAUTWUIM.js → chunk-5KEEVCY6.js} +1 -1
  6. package/dist/chunks/{chunk-U54HRBBL.js → chunk-5NY7QUSW.js} +1 -1
  7. package/dist/chunks/{chunk-DXVVHVFA.js → chunk-A453E6SC.js} +1 -1
  8. package/dist/chunks/{chunk-OAHMFUHH.js → chunk-EN6NBFZO.js} +1 -1
  9. package/dist/chunks/chunk-EVIGYNEU.js +337 -0
  10. package/dist/chunks/{chunk-55HCCLM4.js → chunk-KDDW7HM7.js} +1 -1
  11. package/dist/chunks/{chunk-JZT76GOY.js → chunk-KMKBZF5D.js} +1 -1
  12. package/dist/chunks/{chunk-MCIZHB3Z.js → chunk-UA7ENMMT.js} +1 -1
  13. package/dist/chunks/{fitment-data-5CQLYPUS.js → fitment-data-RZDYZEJS.js} +1 -1
  14. package/dist/chunks/{section-css-style-GS3GFILD.js → section-css-style-UBORAPCW.js} +1 -1
  15. package/dist/index.js +3 -3
  16. package/dist/render/built-with.json +1 -1
  17. package/dist/routine-index.json +1 -1
  18. package/dist/value-index.json +1 -1
  19. package/package.json +3 -3
  20. package/dist/chunks/SiteEditorProvider-445QTFDY.js +0 -1
  21. package/dist/chunks/chunk-6VZXQPDK.js +0 -337
  22. /package/dist/chunks/{chunk-EWEX5KJD.js → chunk-3SSNRXHF.js} +0 -0
  23. /package/dist/chunks/{chunk-OAHMFUHH.js.LEGAL.txt → chunk-EN6NBFZO.js.LEGAL.txt} +0 -0
  24. /package/dist/chunks/{chunk-6VZXQPDK.js.LEGAL.txt → chunk-EVIGYNEU.js.LEGAL.txt} +0 -0
  25. /package/dist/chunks/{chunk-4BGF2KJJ.js → chunk-F24QIWKG.js} +0 -0
  26. /package/dist/chunks/{chunk-T3YKEXOD.js → chunk-MMTJNMVZ.js} +0 -0
@@ -1,4 +1,4 @@
1
- import{b as Eu,c as xu,d as Fu,e as Bu,g as Ys,h as Mu,i as Hu}from"./chunk-55HCCLM4.js";import{$ as se,$f as iu,$h as Oo,Aa as Mc,Ac as Rs,Af as Je,Ag as hu,Bc as Eo,Bg as Ks,Bh as Ou,Ca as k,Cc as Gc,Ci as H,Da as So,Db as $c,Dc as zc,De as Qc,E as Rc,Ec as Wc,Ed as Ls,Fb as Kt,Fc as As,Gb as Me,Gc as Kc,Hi as Gu,Ia as Ps,Jd as ue,Jf as ou,Ka as Hc,Kf as $s,Lf as ke,Lg as yt,Lh as Vs,Md as Vc,Mf as au,Mh as Co,Nf as su,Ng as gu,Nh as Pu,Of as Yt,Oh as G,Pb as _o,Pf as de,Pg as bu,Rg as yu,Sc as jc,Sf as Xt,Sh as ku,Tc as Ns,Td as Yc,Tf as qt,Tg as Su,Th as Iu,Uh as Ru,Vh as Au,Wd as Xc,Wf as ru,Xg as _u,Xh as Nu,Yg as Tu,Ze as vo,Zf as Us,Zh as Jt,_h as Lu,aa as Ac,ag as Gs,ah as St,ai as Du,b as K,ba as Nc,bh as js,c as qe,ca as Lc,dg as lu,ea as mt,eg as cu,eh as vu,fe as Ds,ff as Ms,ga as yo,i as vc,ic as Uc,ka as Cn,l as go,lg as uu,m as wc,me as xo,mg as zs,n as Cc,oa as ht,oe as jt,og as du,p as Oc,pc as gt,pe as bt,pf as U,pg as re,q as Pc,qf as M,qg as pu,qh as wu,r as kc,rc as ks,rf as eu,rg as fu,sc as Is,se as qc,sf as Vt,sg as Ie,t as bo,te as Fs,tf as tu,tg as Zt,u as Ic,uc as To,ue as Zc,uf as Hs,va as Dc,vf as Pn,vi as Uu,wa as Fc,wf as nu,wg as mu,wh as Cu,xa as Bc,xe as Jc,xg as Ws,yb as On,ye as Bs,za as Os,zf as Ze,zh as wo}from"./chunk-U54HRBBL.js";import{a as V,b as ye}from"./chunk-EWEX5KJD.js";import{d as $u}from"./chunk-T3YKEXOD.js";var Wu="en",Po=null,Ku=Wu,ju=null;function S0(e,t,n){Po=e??null,Ku=t||Wu,ju=n??null}function I(){return ju}function _0(){return Ku}function T0(){return Po}function zu(e,t){return t?e.replace(/\{([A-Za-z][A-Za-z0-9_]*)\}/g,(n,o)=>ye(t,o)?String(V(t,o)):n):e}function c(e,t){let n=Po?V(Po,e):void 0;if(typeof n=="function"){try{let o=K(n(t??{}));if(o)return o}catch{}return zu(e,t)}return zu(K(n)??e,t)}function kn(e,t,n,o){return c(n===1?e:t,{...o,n})}import{parseHexColor as Zu}from"efficient-shell/format";import{COLOR_SLOTS as Ju,FILL_COLOR_SLOTS as dy,colorRole as py,fillColorRole as Qu}from"efficient-shell/markup";import{parseHexColor as Vu}from"efficient-shell/format";import{FILL_COLOR_SLOTS as iy}from"efficient-shell/markup";var ko=e=>{let t=Su.find(n=>n.role===e);return t?`var(${t.token})`:""},ly=e=>ko(e)?`var(--theme-${e})`:"",cy={main:{ink:ht.accent,page:ht.accent,key:"accent",label:()=>c("Main"),words:e=>c("Theme {n} main color",{n:e})},text:{ink:ht.text,page:ht.text,key:"text",label:()=>c("Text"),words:e=>c("Theme {n} text color",{n:e})},background:{ink:ko("bg"),page:ly("bg"),key:"background",label:()=>c("Background"),words:e=>c("Theme {n} background",{n:e})},muted:{ink:ht.labels,page:ht.labels,key:"muted",label:()=>c("Muted"),words:e=>c("Theme {n} muted color",{n:e})},surface:{ink:ko("surface"),page:ko("surface"),key:"surface",label:()=>c("Surface"),words:e=>c("Theme {n} surface color",{n:e})}};function Qe(e){return V(cy,e)}var Xs="#9ca3af";function Qt(e,t,n){let o=Qe(e);return o?{hex:Vu(t[o.key]??"")??"",words:o.words(n)}:null}function Yu(e,t){return iy.flatMap(n=>{let o=Qt(n,e,t);return o&&Qe(n)?.ink?[{name:n,label:o.words,value:o.hex||Xs}]:[]})}var uy=["main","text","background"];function Xu(e){let t=new Set,n=[];return ke(e).themes.forEach((o,a)=>{for(let s of uy){let r=Qe(s),i=r?o[r.key]:void 0,l=typeof i=="string"&&i?Vu(i):null;!r||!l||t.has(l)||(t.add(l),n.push({value:l,label:r.words(a+1)}))}}),n}function He(e){return Qe(e)?.ink??""}function Re(e){if(typeof e!="string")return null;let t=Qu(e.trim());return t?.kind==="slot"&&He(t.slot)?t.slot:null}var fy={accent:"main",labels:"muted"};function $e(e){return V(fy,e)??e}function Io(e){if(!e)return"";if(e.startsWith("#"))return Zu(e)===e.toLowerCase()?e:"";let t=py($e(e));return t?.kind==="slot"?He(t.slot):""}function ed(e,t=Ju){return t.flatMap(n=>{let o=Qe(n);return o?.ink?[{name:n,label:o.label(),value:e?.[n]||Xs}]:[]})}function td(e){let t=Qu($e(e));return t?.kind==="slot"?He(t.slot):""}function D0(e){let t=e?.trim();return t?dy.find(n=>He(n)===t)??null:null}function F0(e){let t={},n=e.ownerDocument,o=n?.defaultView;if(!n||!o)return t;let a=o.getComputedStyle(e),s=n.createElement("canvas").getContext("2d");for(let r of Ju){let i=He(r);if(!i)continue;let l=i.replace(/^var\((--[\w-]+)\)$/,"$1"),u=a.getPropertyValue(l).trim();if(!u)continue;let d=qu(u);!d&&s&&(s.fillStyle="#000000",s.fillStyle=u,d=qu(String(s.fillStyle))),d&&(t[r]=d)}return t}function qu(e){let t=e.trim().toLowerCase();if(t.startsWith("#"))return Zu(t);let n=t.match(/^rgba?\(\s*(\d+)[\s,]+(\d+)[\s,]+(\d+)/);return n?`#${n.slice(1,4).map(o=>Math.min(255,Number(o)).toString(16).padStart(2,"0")).join("")}`:null}var Ro="sf.gapContainer",Ue={min:-32,max:64,step:2},ld={Grid:{sm:12,md:24,lg:40},Flex:{sm:12,md:24,lg:40},FooterGroup:{sm:8,md:16,lg:32},HeroGroup:null,Events:null,GalleryB:null,ProductGrid:null},en={Grid:24,Flex:24,FooterGroup:16,HeroGroup:0,Events:24,GalleryB:8,ProductGrid:2},my=new Set(["Events","GalleryB"]);function In(e,t,n){if(typeof t=="number"&&Number.isFinite(t)&&t>=Ue.min)return t;if(typeof t=="string"){let o=ld[e]?.[t];if(typeof o=="number")return o}return typeof n=="number"&&Number.isFinite(n)?n:en[e]}var hy="sf-gap-overlap",gy="--sf-gap-overlap",qs="--sf-block-gap",nd="--sf-block-gap-rem",Se={min:0,max:Ue.max,step:Ue.step};function Rn(e){if(typeof e!="number"||!Number.isFinite(e))return null;let t=Math.min(Math.max(Math.round(e),Se.min),Se.max);return t-t%Se.step}function H0(e,t){let n=Pn(e,t,"gap",Se);if(n!==null)return{[qs]:n,[nd]:n};let o=Rn(e);return o===null?{}:{[qs]:`${o}px`,[nd]:`${o/16}rem`}}var od="--sf-block-gap-phone",ad="--sf-block-gap-phone-rem",by="--sf-block-gap-on-phone",yy="max-view-tablet:[--sf-block-gap-on-phone:var(--sf-block-gap-phone)]",Sy="max-view-wide:[&_[data-sf-line~=edge]:not([data-sf-line~=edge]_*)]:[--sf-block-gap-on-phone:var(--sf-block-gap-phone)]";function $0(e,t){let n=Pn(e,t,"gap",Se);if(n!==null)return{[od]:n,[ad]:n};let o=Rn(e);return o===null?{}:{[od]:`${o}px`,[ad]:`${o/16}rem`}}function U0(e){return Rn(e)===null?"":`${yy} ${Sy}`}var sd="sf-gap-zone",rd="--sf-gap-len";function Ao(e,t){return typeof t=="number"&&Number.isFinite(t)&&t>=Ue.min?!0:typeof t=="string"&&typeof ld[e]?.[t]=="number"}var id="--sf-gap-len-phone",_y="--sf-gap-len-tablet",An={min:0,max:Ue.max,step:Ue.step};function et(e){return typeof e=="number"&&Number.isFinite(e)&&e>=An.min}function Zs(e){return e/2}function Js(e,t,n){return et(n)&&!Ao(e,t)}function Qs(e,t,n,o,a){return et(t)?t:Js(e,n,a)?a:Zs(In(e,n,o))}var Ty={block:"sf-gap-overlap-block",inline:"sf-gap-overlap-inline",both:"sf-gap-overlap-both"};function G0(e,t,n,o,a){let s={...et(o)?{[id]:`${o}px`}:null,...et(a)?{[_y]:`${a}px`}:null};if(!Ao(e,t)){let i=`${en[e]}px`,l=my.has(e)?`var(--sf-card-gap, ${i})`:i;return{className:` ${sd}`,style:{[rd]:`var(${qs}, ${l})`,[id]:`var(${by})`,...s}}}let r=In(e,t);return r>=0?{className:` ${sd}`,style:{[rd]:`${r}px`,...s}}:{className:` ${hy} ${Ty[n]}`,style:{gap:"0px",[gy]:`${-r/2}px`}}}import{jsx as tr,Fragment as ky,jsxs as Iy}from"react/jsx-runtime";import{createContext as Ry,useContext as Ay,useMemo as Ny}from"react";var Ey=4,xy={sans:"Arial",condensed:"Arial Narrow",serif:"Times New Roman",mono:"Courier New"},vy={sans:"sans-serif",serif:"serif",mono:"monospace"},wy="latin",Cy=/^\/(?![\/\\])[^\s"'()\\<>:]+$/,Oy=/^U\+[0-9A-Fa-f?]{1,6}(?:-[0-9A-Fa-f]{1,6})?(?:\s*,\s*U\+[0-9A-Fa-f?]{1,6}(?:-[0-9A-Fa-f]{1,6})?)*$/,er=e=>`"${Mu(e)}"`,cd=e=>`${e} Fallback`;function Py(e){return typeof e?.url=="string"&&Cy.test(e.url)&&typeof e.unicodeRange=="string"&&Oy.test(e.unicodeRange.trim())&&Number.isInteger(e.weight)&&e.weight>=1&&e.weight<=1e3&&(e.style==="normal"||e.style==="italic")}var No=e=>`${e}%`,Lo=e=>typeof e=="number"&&Number.isFinite(e);function ud(e,t){let n={css:"",vars:{},preload:[]};if(e.siteFonts.size===0)return n;let o=[],a=[];for(let s of new Set(t)){let r=e.siteFonts.get(s),i=e.byKey.get(s);if(!r||!i)continue;let l=er(r.family);for(let p of r.files??[])Py(p)&&(o.push(`@font-face { font-family: ${l}; src: url("${p.url}") format("woff2"); font-weight: ${p.weight}; font-style: ${p.style}; unicode-range: ${p.unicodeRange.trim()}; font-display: swap; }`),p.subset===wy&&a.push(p));let u=r.fallbackMetrics,d=!!u&&Lo(u.ascent)&&Lo(u.descent)&&Lo(u.lineGap)&&Lo(u.sizeAdjust);if(d){let p=xy[r.condensed?"condensed":i.category];o.push(`@font-face { font-family: ${er(cd(r.family))}; src: local("${p}"); ascent-override: ${No(u.ascent)}; descent-override: ${No(u.descent)}; line-gap-override: ${No(u.lineGap)}; size-adjust: ${No(u.sizeAdjust)}; }`)}n.vars[i.cssVar]=Ys([l,...d?[er(cd(r.family))]:[],vy[i.category]].join(", "))}return n.css=Ys(o.join(`
1
+ import{b as Eu,c as xu,d as Fu,e as Bu,g as Ys,h as Mu,i as Hu}from"./chunk-KDDW7HM7.js";import{$ as se,$f as iu,$h as Oo,Aa as Mc,Ac as Rs,Af as Je,Ag as hu,Bc as Eo,Bg as Ks,Bh as Ou,Ca as k,Cc as Gc,Ci as H,Da as So,Db as $c,Dc as zc,De as Qc,E as Rc,Ec as Wc,Ed as Ls,Fb as Kt,Fc as As,Gb as Me,Gc as Kc,Hi as Gu,Ia as Ps,Jd as ue,Jf as ou,Ka as Hc,Kf as $s,Lf as ke,Lg as yt,Lh as Vs,Md as Vc,Mf as au,Mh as Co,Nf as su,Ng as gu,Nh as Pu,Of as Yt,Oh as G,Pb as _o,Pf as de,Pg as bu,Rg as yu,Sc as jc,Sf as Xt,Sh as ku,Tc as Ns,Td as Yc,Tf as qt,Tg as Su,Th as Iu,Uh as Ru,Vh as Au,Wd as Xc,Wf as ru,Xg as _u,Xh as Nu,Yg as Tu,Ze as vo,Zf as Us,Zh as Jt,_h as Lu,aa as Ac,ag as Gs,ah as St,ai as Du,b as K,ba as Nc,bh as js,c as qe,ca as Lc,dg as lu,ea as mt,eg as cu,eh as vu,fe as Ds,ff as Ms,ga as yo,i as vc,ic as Uc,ka as Cn,l as go,lg as uu,m as wc,me as xo,mg as zs,n as Cc,oa as ht,oe as jt,og as du,p as Oc,pc as gt,pe as bt,pf as U,pg as re,q as Pc,qf as M,qg as pu,qh as wu,r as kc,rc as ks,rf as eu,rg as fu,sc as Is,se as qc,sf as Vt,sg as Ie,t as bo,te as Fs,tf as tu,tg as Zt,u as Ic,uc as To,ue as Zc,uf as Hs,va as Dc,vf as Pn,vi as Uu,wa as Fc,wf as nu,wg as mu,wh as Cu,xa as Bc,xe as Jc,xg as Ws,yb as On,ye as Bs,za as Os,zf as Ze,zh as wo}from"./chunk-5NY7QUSW.js";import{a as V,b as ye}from"./chunk-3SSNRXHF.js";import{d as $u}from"./chunk-MMTJNMVZ.js";var Wu="en",Po=null,Ku=Wu,ju=null;function S0(e,t,n){Po=e??null,Ku=t||Wu,ju=n??null}function I(){return ju}function _0(){return Ku}function T0(){return Po}function zu(e,t){return t?e.replace(/\{([A-Za-z][A-Za-z0-9_]*)\}/g,(n,o)=>ye(t,o)?String(V(t,o)):n):e}function c(e,t){let n=Po?V(Po,e):void 0;if(typeof n=="function"){try{let o=K(n(t??{}));if(o)return o}catch{}return zu(e,t)}return zu(K(n)??e,t)}function kn(e,t,n,o){return c(n===1?e:t,{...o,n})}import{parseHexColor as Zu}from"efficient-shell/format";import{COLOR_SLOTS as Ju,FILL_COLOR_SLOTS as dy,colorRole as py,fillColorRole as Qu}from"efficient-shell/markup";import{parseHexColor as Vu}from"efficient-shell/format";import{FILL_COLOR_SLOTS as iy}from"efficient-shell/markup";var ko=e=>{let t=Su.find(n=>n.role===e);return t?`var(${t.token})`:""},ly=e=>ko(e)?`var(--theme-${e})`:"",cy={main:{ink:ht.accent,page:ht.accent,key:"accent",label:()=>c("Main"),words:e=>c("Theme {n} main color",{n:e})},text:{ink:ht.text,page:ht.text,key:"text",label:()=>c("Text"),words:e=>c("Theme {n} text color",{n:e})},background:{ink:ko("bg"),page:ly("bg"),key:"background",label:()=>c("Background"),words:e=>c("Theme {n} background",{n:e})},muted:{ink:ht.labels,page:ht.labels,key:"muted",label:()=>c("Muted"),words:e=>c("Theme {n} muted color",{n:e})},surface:{ink:ko("surface"),page:ko("surface"),key:"surface",label:()=>c("Surface"),words:e=>c("Theme {n} surface color",{n:e})}};function Qe(e){return V(cy,e)}var Xs="#9ca3af";function Qt(e,t,n){let o=Qe(e);return o?{hex:Vu(t[o.key]??"")??"",words:o.words(n)}:null}function Yu(e,t){return iy.flatMap(n=>{let o=Qt(n,e,t);return o&&Qe(n)?.ink?[{name:n,label:o.words,value:o.hex||Xs}]:[]})}var uy=["main","text","background"];function Xu(e){let t=new Set,n=[];return ke(e).themes.forEach((o,a)=>{for(let s of uy){let r=Qe(s),i=r?o[r.key]:void 0,l=typeof i=="string"&&i?Vu(i):null;!r||!l||t.has(l)||(t.add(l),n.push({value:l,label:r.words(a+1)}))}}),n}function He(e){return Qe(e)?.ink??""}function Re(e){if(typeof e!="string")return null;let t=Qu(e.trim());return t?.kind==="slot"&&He(t.slot)?t.slot:null}var fy={accent:"main",labels:"muted"};function $e(e){return V(fy,e)??e}function Io(e){if(!e)return"";if(e.startsWith("#"))return Zu(e)===e.toLowerCase()?e:"";let t=py($e(e));return t?.kind==="slot"?He(t.slot):""}function ed(e,t=Ju){return t.flatMap(n=>{let o=Qe(n);return o?.ink?[{name:n,label:o.label(),value:e?.[n]||Xs}]:[]})}function td(e){let t=Qu($e(e));return t?.kind==="slot"?He(t.slot):""}function D0(e){let t=e?.trim();return t?dy.find(n=>He(n)===t)??null:null}function F0(e){let t={},n=e.ownerDocument,o=n?.defaultView;if(!n||!o)return t;let a=o.getComputedStyle(e),s=n.createElement("canvas").getContext("2d");for(let r of Ju){let i=He(r);if(!i)continue;let l=i.replace(/^var\((--[\w-]+)\)$/,"$1"),u=a.getPropertyValue(l).trim();if(!u)continue;let d=qu(u);!d&&s&&(s.fillStyle="#000000",s.fillStyle=u,d=qu(String(s.fillStyle))),d&&(t[r]=d)}return t}function qu(e){let t=e.trim().toLowerCase();if(t.startsWith("#"))return Zu(t);let n=t.match(/^rgba?\(\s*(\d+)[\s,]+(\d+)[\s,]+(\d+)/);return n?`#${n.slice(1,4).map(o=>Math.min(255,Number(o)).toString(16).padStart(2,"0")).join("")}`:null}var Ro="sf.gapContainer",Ue={min:-32,max:64,step:2},ld={Grid:{sm:12,md:24,lg:40},Flex:{sm:12,md:24,lg:40},FooterGroup:{sm:8,md:16,lg:32},HeroGroup:null,Events:null,GalleryB:null,ProductGrid:null},en={Grid:24,Flex:24,FooterGroup:16,HeroGroup:0,Events:24,GalleryB:8,ProductGrid:2},my=new Set(["Events","GalleryB"]);function In(e,t,n){if(typeof t=="number"&&Number.isFinite(t)&&t>=Ue.min)return t;if(typeof t=="string"){let o=ld[e]?.[t];if(typeof o=="number")return o}return typeof n=="number"&&Number.isFinite(n)?n:en[e]}var hy="sf-gap-overlap",gy="--sf-gap-overlap",qs="--sf-block-gap",nd="--sf-block-gap-rem",Se={min:0,max:Ue.max,step:Ue.step};function Rn(e){if(typeof e!="number"||!Number.isFinite(e))return null;let t=Math.min(Math.max(Math.round(e),Se.min),Se.max);return t-t%Se.step}function H0(e,t){let n=Pn(e,t,"gap",Se);if(n!==null)return{[qs]:n,[nd]:n};let o=Rn(e);return o===null?{}:{[qs]:`${o}px`,[nd]:`${o/16}rem`}}var od="--sf-block-gap-phone",ad="--sf-block-gap-phone-rem",by="--sf-block-gap-on-phone",yy="max-view-tablet:[--sf-block-gap-on-phone:var(--sf-block-gap-phone)]",Sy="max-view-wide:[&_[data-sf-line~=edge]:not([data-sf-line~=edge]_*)]:[--sf-block-gap-on-phone:var(--sf-block-gap-phone)]";function $0(e,t){let n=Pn(e,t,"gap",Se);if(n!==null)return{[od]:n,[ad]:n};let o=Rn(e);return o===null?{}:{[od]:`${o}px`,[ad]:`${o/16}rem`}}function U0(e){return Rn(e)===null?"":`${yy} ${Sy}`}var sd="sf-gap-zone",rd="--sf-gap-len";function Ao(e,t){return typeof t=="number"&&Number.isFinite(t)&&t>=Ue.min?!0:typeof t=="string"&&typeof ld[e]?.[t]=="number"}var id="--sf-gap-len-phone",_y="--sf-gap-len-tablet",An={min:0,max:Ue.max,step:Ue.step};function et(e){return typeof e=="number"&&Number.isFinite(e)&&e>=An.min}function Zs(e){return e/2}function Js(e,t,n){return et(n)&&!Ao(e,t)}function Qs(e,t,n,o,a){return et(t)?t:Js(e,n,a)?a:Zs(In(e,n,o))}var Ty={block:"sf-gap-overlap-block",inline:"sf-gap-overlap-inline",both:"sf-gap-overlap-both"};function G0(e,t,n,o,a){let s={...et(o)?{[id]:`${o}px`}:null,...et(a)?{[_y]:`${a}px`}:null};if(!Ao(e,t)){let i=`${en[e]}px`,l=my.has(e)?`var(--sf-card-gap, ${i})`:i;return{className:` ${sd}`,style:{[rd]:`var(${qs}, ${l})`,[id]:`var(${by})`,...s}}}let r=In(e,t);return r>=0?{className:` ${sd}`,style:{[rd]:`${r}px`,...s}}:{className:` ${hy} ${Ty[n]}`,style:{gap:"0px",[gy]:`${-r/2}px`}}}import{jsx as tr,Fragment as ky,jsxs as Iy}from"react/jsx-runtime";import{createContext as Ry,useContext as Ay,useMemo as Ny}from"react";var Ey=4,xy={sans:"Arial",condensed:"Arial Narrow",serif:"Times New Roman",mono:"Courier New"},vy={sans:"sans-serif",serif:"serif",mono:"monospace"},wy="latin",Cy=/^\/(?![\/\\])[^\s"'()\\<>:]+$/,Oy=/^U\+[0-9A-Fa-f?]{1,6}(?:-[0-9A-Fa-f]{1,6})?(?:\s*,\s*U\+[0-9A-Fa-f?]{1,6}(?:-[0-9A-Fa-f]{1,6})?)*$/,er=e=>`"${Mu(e)}"`,cd=e=>`${e} Fallback`;function Py(e){return typeof e?.url=="string"&&Cy.test(e.url)&&typeof e.unicodeRange=="string"&&Oy.test(e.unicodeRange.trim())&&Number.isInteger(e.weight)&&e.weight>=1&&e.weight<=1e3&&(e.style==="normal"||e.style==="italic")}var No=e=>`${e}%`,Lo=e=>typeof e=="number"&&Number.isFinite(e);function ud(e,t){let n={css:"",vars:{},preload:[]};if(e.siteFonts.size===0)return n;let o=[],a=[];for(let s of new Set(t)){let r=e.siteFonts.get(s),i=e.byKey.get(s);if(!r||!i)continue;let l=er(r.family);for(let p of r.files??[])Py(p)&&(o.push(`@font-face { font-family: ${l}; src: url("${p.url}") format("woff2"); font-weight: ${p.weight}; font-style: ${p.style}; unicode-range: ${p.unicodeRange.trim()}; font-display: swap; }`),p.subset===wy&&a.push(p));let u=r.fallbackMetrics,d=!!u&&Lo(u.ascent)&&Lo(u.descent)&&Lo(u.lineGap)&&Lo(u.sizeAdjust);if(d){let p=xy[r.condensed?"condensed":i.category];o.push(`@font-face { font-family: ${er(cd(r.family))}; src: local("${p}"); ascent-override: ${No(u.ascent)}; descent-override: ${No(u.descent)}; line-gap-override: ${No(u.lineGap)}; size-adjust: ${No(u.sizeAdjust)}; }`)}n.vars[i.cssVar]=Ys([l,...d?[er(cd(r.family))]:[],vy[i.category]].join(", "))}return n.css=Ys(o.join(`
2
2
  `)),n.preload=[...a.filter(s=>s.style==="normal"),...a.filter(s=>s.style!=="normal")].slice(0,Ey),n}var pd=Ry(se);function Z0({siteFonts:e,children:t}){let n=Ny(()=>Ac(e),[e]);return tr(pd.Provider,{value:n,children:t})}function _t(){return Ay(pd)}var dd="sf-site-fonts";function J0({usedKeys:e,preload:t=!0}){let n=_t(),o=ud(n,e),a=Object.entries(o.vars),s=[o.css,a.length?`:root { ${a.map(([r,i])=>`${r}: ${i}`).join("; ")} }`:""].filter(Boolean).join(`
3
3
  `);return s?Iy(ky,{children:[(t?o.preload:[]).map(r=>tr("link",{rel:"preload",as:"font",type:"font/woff2",href:r.url,crossOrigin:""},r.id)),tr("style",{href:`${dd}-${Hu(s)}`,precedence:dd,dangerouslySetInnerHTML:{__html:s}})]}):null}import{jsx as X,jsxs as Et,Fragment as vS}from"react/jsx-runtime";import{useCallback as Od,useContext as wS,useId as Id,useRef as Pd,useState as kd}from"react";import{ThemeIcon as CS}from"efficient-easel/icons";import{Button as OS,useClickOutside as PS}from"efficient-shell/ui";import{SettingsField as kS}from"efficient-easel/panel";import{ScreenDocumentContext as IS}from"efficient-easel/screen/components/ScreenDocumentContext";import{jsx as R,jsxs as nt,Fragment as oS}from"react/jsx-runtime";import{parseHexColor as aS}from"efficient-shell/format";import{Button as sr,IconButton as sS,Tooltip as rS}from"efficient-shell/ui";import{jsx as tt,jsxs as Xy}from"react/jsx-runtime";import{AccentIcon as qy}from"efficient-easel/icons";import{Button as Zy,Tooltip as Jy}from"efficient-shell/ui";import{jsx as ie,jsxs as or}from"react/jsx-runtime";import{useRef as Ly}from"react";import{ColorPicker as Dy,ColorPickerPanel as Fy,ColorSwatch as By,HexInput as My,Popover as Hy,Tooltip as $y,colorFill as Uy,colorSwatchClasses as Gy,useShellStrings as zy}from"efficient-shell/ui";import{SettingsDefaultReset as Wy,SettingsField as Ky}from"efficient-easel/panel";import{typedHex as nr}from"efficient-easel/pick";var fd="Not set";function md({value:e,onChange:t,label:n,id:o,caption:a,inherited:s,ariaLabel:r,choices:i}){return ie(Vy,{value:e,onChange:t,label:c(r??n),id:o,caption:a,inherited:s,choices:i})}function jy(){let{theme:e}=H();return Xu(e)}function Vy({value:e,onChange:t,label:n,id:o,caption:a,inherited:s,choices:r}){let i=jy(),l=e?null:nr(s??""),u=a!==void 0&&(!e||nr(a)!==nr(e))?a:null,d=p=>{p!==e&&t(p)};return or("div",{className:"sf-colour",children:[r?ie(Yy,{id:o,value:e,onChange:t,label:n,presets:i,follows:l,choices:r}):ie(Dy,{id:o,value:e,onChange:d,label:n,presets:i,fallback:l??void 0,size:"md",align:"start"}),u!==null?ie("span",{className:"sf-colour-caption",children:u}):ie("span",{className:"sf-colour-hexwrap",children:ie(My,{value:e||l||"",onChange:d,label:c("{label} hex code",{label:n}),placeholder:e||l?void 0:c(fd),className:l?"sf-colour-hex is-inherited":"sf-colour-hex",size:"md"})})]})}function Yy({value:e,onChange:t,label:n,id:o,presets:a,follows:s,choices:r}){let i=zy().color,l=e||s||"",u=r.findIndex(f=>f.selected),d=u>=0,p=Ly(u);return d&&(p.current=u),ie(Hy,{id:o,trigger:ie("span",{"aria-hidden":"true",className:"absolute inset-0",style:Uy(l)}),triggerLabel:i.swatch(n,l.toUpperCase()||i.none),triggerClassName:Gy({size:"md"}),"aria-label":i.panel(n),align:"start",children:or("div",{className:"sf-colour-window",children:[ie("div",{role:"group","aria-label":n,className:"sf-colour-choices",children:r.map(f=>ie($y,{content:f.label,children:ie(By,{color:f.color,"aria-label":f.label,selected:f.selected,onClick:()=>{f.selected||f.onPick()}})},f.label))}),ie(Fy,{value:d?"":e,onChange:t,label:n,presets:a,fallback:(d?l:s)??void 0},p.current)]})})}function _e({label:e,icon:t,changed:n,hint:o,onReset:a,resetTo:s,children:r,...i}){return ie(Ky,{label:e,icon:t,htmlFor:i.id,changed:n,hint:o,action:a?ie(Wy,{words:I()?.panel,label:e,changed:!!n,detail:s,onReset:a}):void 0,children:r?or("div",{className:"es-width-stack",children:[md({...i,label:e}),r]}):md({...i,label:e})})}function Nn({label:e,icon:t,value:n,inherited:o,resetTo:a,onChange:s,onReset:r,hint:i,choices:l,children:u}){let d=!!n;return ie(_e,{label:e,icon:t,value:n,inherited:d?void 0:o,onChange:s,changed:d,onReset:r,resetTo:a,hint:i,choices:l,children:u})}function ar(e){return de(e).background}function Qy(e){let t=Ze(e.accent,ar(e));return t===null?null:{ratio:t,grade:qt(t)}}function eS(e){let t=ar(e),n=Ze(e.accent,t);return n===null?[]:ru(e.accent).filter(o=>{let a=Ze(o,t);return a!==null&&a>n&&qt(a)==="good"})}var tS={good:"Easy to read","large-only":Xt["large-only"],hard:Xt.hard};function hd({value:e,onChange:t}){let n=Qy(e),o=n?.grade,a=n&&n.grade!=="good"?eS(e):[];return tt(_e,{label:c("Main color"),icon:tt(qy,{}),hint:n?c(tS[n.grade]):void 0,value:e.accent,onChange:s=>t({...e,accent:s}),children:a.length>0?tt("div",{className:"w-full min-w-0",children:Xy("div",{className:"sf-readability",children:[tt("p",{className:"sf-readability-advice",children:nS(o,!0)}),tt("div",{className:"sf-readability-suggestions",children:a.map(s=>{let r=Ze(s,ar(e));return tt(Jy,{content:c("Use {colour}",{colour:s.toUpperCase()}),children:tt(Zy,{variant:"secondary",className:"sf-readability-suggestion",leftIcon:tt("span",{className:"sf-readability-chip",style:{background:s},"aria-hidden":!0}),onClick:()=>t({...e,accent:s}),children:r?`${r.toFixed(1)}:1`:s.toUpperCase()})},s)})})]})}):null})}function nS(e,t){return e?e==="good"?c("This color reads clearly on your pages."):t?c("This color is hard to read on this theme's page. The buttons below are the same hue, darkened."):c("This color is hard to read on your page background. Pick one further from it \u2014 lighter if your pages are dark, deeper if they are light."):c("Pick a color to see how it reads.")}import{ButtonIcon as iS,ChevronDownIcon as bd,ChevronUpIcon as lS,GroundIcon as cS,LayoutIcon as uS,SquareIcon as dS,TextSmallIcon as pS,TypeIcon as gd}from"efficient-easel/icons";var Ln=e=>c("Theme {n}",{n:e+1});function yd({colors:e}){let t=de(e),n=Us(e)??t.accent;return nt("span",{className:"sf-theme-page",style:{background:t.background,color:t.text},"aria-hidden":!0,children:[R("span",{className:"sf-theme-eyebrow",style:{color:t.muted},children:c("label")}),nt("span",{className:"sf-theme-headline",children:[c("Heading")," ",R("span",{style:{color:t.accent},children:c("main")})]}),R("span",{className:"sf-theme-body",children:c("body text")}),nt("span",{className:"sf-theme-row",children:[R("span",{className:"sf-theme-btn",style:{background:n,color:Gs(e,t.accent)},children:c("button")}),R("span",{className:"sf-theme-mini",style:{background:t.surface,borderColor:t.line},children:c("card")})]})]})}var rr={"Text color":R(gd,{}),"Label color":R(pS,{}),Background:R(cS,{}),"Panels & cards":R(uS,{}),Borders:R(dS,{}),"Button color":R(iS,{}),"Button text color":R(gd,{})};function fS({label:e,colorKey:t,value:n,onChange:o,idPrefix:a="sf-theme-ink"}){let s=`${a}-${t}`;return R(_e,{label:c(e),icon:rr[e],id:s,value:n,onChange:r=>o(t,r)})}function mS({value:e,accent:t,onChange:n,idPrefix:o="sf-theme-ink"}){let a=`${o}-button`,s=e!==void 0&&aS(e)===e.toLowerCase(),r=s?e:t;return R(_e,{label:c("Button color"),icon:rr["Button color"],id:a,value:r,caption:s?r:c("Main"),onChange:n})}function hS({colors:e,accent:t,onChange:n,idPrefix:o="sf-theme-ink"}){let a=`${o}-button-ink`,s=iu(e),r=Gs(e,t),i=Us(e)??t,l=qt(Ze(r,i)??0);return R(_e,{label:c("Button text color"),icon:rr["Button text color"],hint:s&&l!=="good"?c("{grade} on the button",{grade:c(Xt[l])}):void 0,id:a,value:r,caption:s?r:c("Auto"),onChange:n})}var gS=[{colour:!0},{label:"Text color",key:"text"},{label:"Label color",key:"muted"},{button:!0},{buttonInk:!0},{moduleBreak:!0},{label:"Background",key:"background"},{label:"Panels & cards",key:"surface"},{label:"Borders",key:"line"}];function ir({colors:e,onChange:t,idPrefix:n}){let o=de(e);return R(oS,{children:gS.map(a=>"colour"in a?R(hd,{value:e,onChange:t},"colour"):"moduleBreak"in a?R("div",{className:"sf-theme-module-break","aria-hidden":"true"},"module-break"):"button"in a?R(mS,{value:e.button,accent:o.accent,onChange:s=>t({...e,button:s}),idPrefix:n},"button"):"buttonInk"in a?R(hS,{colors:e,accent:o.accent,onChange:s=>t({...e,buttonInk:s}),idPrefix:n},"buttonInk"):R(fS,{label:a.label,colorKey:a.key,value:o[a.key],onChange:(s,r)=>t({...e,[s]:r}),idPrefix:n},a.key))})}function Do({index:e,colors:t,selected:n,role:o="radio",open:a,editable:s=!0,onPick:r,onEdit:i,onChangeColors:l}){let u=de(t),d=Ln(e),p=e<$s.length&&!t.brandInk?$s[e]:null,f=qt(Ze(u.text,u.background)??0),m=p?JSON.stringify(t)!==JSON.stringify(p):!1,b=a!==void 0;return nt("div",{className:`sf-theme-card${n?" is-selected":""}`,children:[R("button",{type:"button",role:o,"aria-checked":o==="radio"?n:void 0,"aria-selected":o==="option"?n:void 0,"aria-label":d,className:"sf-theme-pick",onClick:r,children:R(yd,{colors:t})}),nt("div",{className:"sf-theme-foot",children:[R("span",{className:"sf-theme-name",children:d}),f!=="good"&&R("span",{className:"sf-theme-warn",children:c(Xt[f])}),s&&i&&b&&R("span",{className:"sf-theme-edit",children:R(rS,{content:a?c("Collapse"):c("Edit colors"),children:R(sS,{size:"sm","aria-expanded":a,"aria-controls":`sf-theme-colours-${e}`,"aria-label":a?c("Collapse {name}",{name:d}):c("Edit colors for {name}",{name:d}),onClick:i,children:a?R(lS,{size:14}):R(bd,{size:14})})})}),s&&i&&!b&&R(sr,{variant:"secondary",size:"sm",className:"sf-theme-edit","aria-label":c("Edit {name}",{name:d}),onClick:i,children:c("Edit")})]}),a&&nt("div",{id:`sf-theme-colours-${e}`,className:"sf-theme-colours",children:[R(ir,{colors:t,onChange:y=>l?.(y)}),p&&R(sr,{variant:"link",size:"sm",className:"sf-theme-reset",disabled:!m,onClick:()=>l?.({...p}),children:m?c("Reset {name} to the preset",{name:d}):c("Not changed")})]})]})}function Sd({colors:e,name:t,nameId:n,open:o,menuId:a,labelId:s,buttonRef:r,onClick:i,onKeyDown:l,onEdit:u}){return nt("div",{className:"sf-secttheme-btn",children:[R("button",{ref:r,type:"button",className:"sf-theme-pick","aria-expanded":o,"aria-controls":a,"aria-labelledby":`${s} ${n}`,onClick:i,onKeyDown:l,children:e?R(yd,{colors:e}):R("span",{className:"sf-secttheme-nopreview","aria-hidden":"true"})}),nt("div",{className:"sf-theme-foot",children:[R("span",{id:n,className:"sf-theme-name",children:t}),u&&R(sr,{variant:"secondary",size:"sm",className:"sf-theme-edit","aria-label":c("Edit {name}",{name:t}),onClick:u,children:c("Edit")}),R("button",{type:"button",className:"sf-secttheme-caret","aria-hidden":"true",tabIndex:-1,onClick:i,children:R(bd,{size:12,className:"sf-multi-caret","aria-hidden":"true"})})]})]})}import{useCallback as pr,useEffect as vd,useRef as Bo}from"react";import{currentEaselSession as _S}from"efficient-easel/screen/lib/session";import{backendOf as bS}from"efficient-easel/screen/lib/session";var xe=bS,PN=e=>e.blocks;import{useEaselSession as TS}from"efficient-easel/screen/lib/session-context";import{useSyncExternalStore as yS}from"react";var Td,lr=null,Tt=null,Fo=0,cr=new Set;function ur(e){Td=e;for(let t of cr)t()}function RN(e){lr=e,Fo+=1,Tt&&clearTimeout(Tt),Tt=null,ur(void 0)}function AN(e){Fo+=1,ur(e)}function Ed(e=250){lr&&(Tt&&clearTimeout(Tt),Tt=setTimeout(()=>{Tt=null;let t=lr;if(!t)return;let n=++Fo;t().then(o=>{n===Fo&&ur(o)}).catch(()=>{})},e))}function _d(){return Td}function SS(e){return cr.add(e),()=>{cr.delete(e)}}function NN(){return yS(SS,_d,_d)}var dr=new Set;function xd(e){return dr.add(e),()=>{dr.delete(e)}}async function DN(){let e=(await Promise.allSettled([...dr].map(async t=>t()))).find(t=>t.status==="rejected");if(e)throw e.reason}import{WebsiteBackendError as ES}from"efficient-easel/screen/lib/backend-error";function wd(e=_S()){return(t,n,o)=>{let a=xe(e).theme;return a?a.update(t,o?{siteId:o}:void 0):Promise.reject(new ES("invalid","This backend stores no site theme."))}}function Cd(e){return e.themeFromDocument?{status:"skipped",reason:"template"}:e.token?null:{status:"skipped",reason:"no-token"}}async function xS(e,t=wd()){let{themeFromDocument:n,token:o,siteId:a,patch:s}=e,r=Cd({themeFromDocument:n,token:o});if(r)return r;if(Object.keys(s).length===0)return{status:"skipped",reason:"empty"};try{return await t(s,o,a??void 0),{status:"saved"}}catch(i){return{status:"failed",error:i}}}function Mo({themeFromDocument:e,tokenRef:t,siteId:n,onResult:o}){let a=Bo(null),s=Bo({}),r=TS(),i=Bo(o);i.current=o;let l=Bo(null),u=pr(f=>{if(f.status==="skipped"){let m=`skipped:${f.reason}`;if(l.current===m)return;l.current=m}else l.current=null;i.current?.(f)},[]),d=pr(async()=>{a.current&&(clearTimeout(a.current),a.current=null);let f=s.current;s.current={};let m=await xS({themeFromDocument:e,token:t?.current,siteId:n,patch:f},wd(r));return u(m),m.status==="saved"&&Ed(),m.status==="failed"&&(s.current={...f,...s.current}),m},[e,t,n,u,r]),p=pr((f,m=!1)=>{let b=Cd({themeFromDocument:e,token:t?.current});if(b){u(b);return}s.current={...s.current,...f},a.current&&clearTimeout(a.current),m?d():a.current=setTimeout(()=>{d()},500)},[e,t,d,u]);return vd(()=>()=>{d()},[d]),vd(()=>xd(async()=>{if(!a.current&&Object.keys(s.current).length===0)return;let f=await d();if(f.status==="failed")throw f.error}),[d]),{persist:p,flush:d}}var RS="Follow the page",o1="Follow the slideshow",AS=e=>c("Editing {name} changes it everywhere.",{name:e});function NS({colors:e}){if(!e)return X("span",{className:"sf-secttheme-chip sf-secttheme-chip--none","aria-hidden":"true"});let t=de(e);return Et("span",{className:"sf-secttheme-chip","aria-hidden":"true",children:[X("i",{style:{background:t.background}}),X("i",{className:"sf-secttheme-chip-accent",style:{background:t.accent}})]})}function LS({themes:e,value:t,onPick:n,onEdit:o,menuId:a,followLabel:s}){return Et("div",{className:"sf-multi-menu sf-secttheme-menu",id:a,role:"listbox",children:[s!==void 0&&Et(vS,{children:[Et("button",{type:"button",role:"option","aria-selected":t===null,className:`sf-secttheme-item${t===null?" is-active":""}`,onClick:()=>n(_u),children:[X(NS,{}),X("span",{className:"sf-secttheme-name",children:c(s)})]}),X("div",{className:"sf-secttheme-sep",role:"presentation"})]}),t!==null&&e[t]&&X("p",{className:"sf-secttheme-oncard",role:"presentation",children:c("{name} is on this section",{name:Ln(t)})}),e.map((r,i)=>i===t?null:X(Do,{role:"option",index:i,colors:r,selected:!1,onPick:()=>n(i),onEdit:o?()=>o(i):void 0},i))]})}function DS({index:e,colors:t,onChange:n,onDone:o}){let a=Ln(e),s=Id();return Et("div",{className:"sf-secttheme-sheet",children:[Et("div",{className:"sf-secttheme-sheet-head",children:[X("span",{children:a}),X(OS,{variant:"secondary",className:"sf-secttheme-done",onClick:o,children:c("Done")})]}),X("div",{className:"sf-secttheme-rows",children:X(ir,{colors:t,onChange:n,idPrefix:s})}),X("p",{className:"sf-secttheme-warn",children:AS(a)})]})}function Rd({value:e,onChange:t,followLabel:n,hint:o,canEdit:a=!0}){let{theme:s,setTheme:r}=H(),i=ke(s),l=wS(IS),u=l?.tokenRef,d=l?.siteId??null,p=!l?.capabilities?.hasSiteTheme,{persist:f,flush:m}=Mo({themeFromDocument:p,tokenRef:u,siteId:d}),b=ke(i),y=b.themes,_=St(e),S=_!==null?y[_]:void 0,E=S??(y.length?Yt(b):void 0),[w,C]=kd(!1),[O,v]=kd(null),x=Pd(null),P=Pd(null),N=Id(),B=Od(()=>{C(!1),v(null)},[]),Xe=Od(()=>{!w&&O===null||(m(),B())},[w,O,B,m]);PS(x,Xe);let pt=q=>{t(q),B()},ft=q=>{if(O===null)return;let ay=y.map((sy,ry)=>ry===O?q:sy),Cs={...b,themes:ay};r(Cs),f({selected_preset:Cs.selected,theme_presets:Cs.themes})};return Et("div",{className:"sf-secttheme",ref:x,children:[X(kS,{label:c("Theme"),icon:X(CS,{}),labelId:`${N}-label`,hint:o,children:X(Sd,{colors:E,onEdit:a&&_!==null?()=>{v(_),C(!1)}:void 0,name:S?Ln(_):c(n??RS),nameId:`${N}-value`,labelId:`${N}-label`,open:w,menuId:N,buttonRef:P,onClick:()=>{v(null),C(q=>!q)},onKeyDown:q=>{q.key==="Escape"&&(w||O!==null)&&(q.preventDefault(),B())}})}),w&&O===null&&X("div",{onKeyDown:q=>{q.key==="Escape"&&(q.preventDefault(),B(),P.current?.focus())},children:X(LS,{themes:y,value:_,onPick:pt,onEdit:a?q=>{v(q),C(!1)}:void 0,menuId:N,followLabel:n})}),a&&O!==null&&y[O]&&X(DS,{index:O,colors:y[O],onChange:ft,onDone:()=>{m(),B(),P.current?.focus()}})]})}import{defaultTextStyles as up,textStyleCaseCss as rT}from"efficient-easel/text-styles/model";import{resolveViewValue as dp}from"efficient-easel/draw";import{VIEW_DESKTOP_MIN as Ad,VIEW_TABLET_MIN as Nd}from"efficient-easel/draw";var Ho=.02,Ld=`(min-width: ${On}px) and (max-width: ${Ad-Ho}px)`,Dd=`(max-width: ${On-Ho}px)`,$o=`(min-width: ${Nd}px) and (max-width: ${Ad-Ho}px)`,Uo=`(max-width: ${Nd-Ho}px)`;import{textStyleCaseCss as n_,textStyleCaseOfCss as o_,viewKeyAt as ap}from"efficient-easel/draw";function Go(e,t){return t?`${e}[${t.index}].${t.rowKey}`:e}function FS(e){let t=/^([A-Za-z0-9_$]+)\[(\d+)\]\.([A-Za-z0-9_$]+)$/u.exec(e);return t?{key:t[1],row:{index:Number(t[2]),rowKey:t[3]}}:{key:e,row:null}}import{decodePartId as gr,encodePartId as N1}from"efficient-easel/draw";import{LINK_FIELD_MARKER as jd,SCAFFOLD_FIELD_MARKER as Wd,TEXT_FIELD_MARKER as jo}from"efficient-easel/draw";import{readHidable as Vd}from"efficient-easel/draw";import{SCALAR_TEXT_CONTROLS as XS}from"efficient-easel/draw";var Fd={ProductGrid:{source:{keep:["slug"]}},GalleryItem:{product:{keep:["code","finish"]}},FeaturedCover:{source:{keep:["slug"]}},LongRead:{source:{keep:["slug"]}}},Bd={Events:["posts"],SubscribeBlogs:["posts"]};var BS=["anchor"],MS=/^href$|Href$|^url$|Url$|^link$|^mailto$|^tel$/;function Dn(e){return BS.includes(e)||MS.test(e)}var HS={Gallery:{source:{verb:"snapshot",keep:[]}},ProductHero:{source:{verb:"snapshot",keep:[]}},SpecTable:{source:{verb:"snapshot",keep:[]},wheel:{verb:"reference"},finish:{verb:"reference"},size:{verb:"reference"}},CollectionCard:{collection:{verb:"snapshot",keep:[]}},FooterMenu:{menu:{verb:"snapshot",keep:[]}},MenuBlock:{menu:{verb:"snapshot",keep:[]}},ProductGrid:{design_codes:{verb:"reference"}},ProductRef:{code:{verb:"reference"},finish:{verb:"reference"}},FitmentTable:{wheel:{verb:"reference"}},GalleryItem:{fromProduct:{verb:"reference"}},Footprint:{"offices[].group":{verb:"groupKey"},"offices[].lat":{verb:"pii"},"offices[].lng":{verb:"pii"},"offices[].geocode":{verb:"pii"}}};HS.ContactLocations={"locations[].lat":{verb:"pii"},"locations[].lng":{verb:"pii"},"locations[].mapsUrl":{verb:"pii"},"locations[].geocode":{verb:"pii"}};var f1=Object.fromEntries(Object.entries(Fd).map(([e,t])=>[e,Object.keys(t)])),m1=Object.fromEntries(Object.entries(Bd).map(([e,t])=>[e,[...t]]));var fr="__ownBox";function Md(e){return!!e&&typeof e=="object"&&e[fr]===!0}var mr="sfPanelOnly";function zo(e){return!!e&&typeof e=="object"&&e[mr]===!0}import{TEXT_FIELD_MARKER as KS}from"efficient-easel/draw";import{TEXT_FIELD_MARKER as Hd}from"efficient-easel/draw";import{readHidable as $d}from"efficient-easel/draw";import{SCALAR_TEXT_CONTROLS as $S}from"efficient-easel/draw";var US=$S,GS=["text","textarea"],zS=["textarea","plainTextarea"];function WS(e){return!e||typeof e!="object"?null:e[Hd]?.control??null}function Ud(e){let t=WS(e);return t&&US.includes(t)?t:null}function T1(e){return zS.includes(e)}function E1(e){return!e||typeof e!="object"?void 0:e[Hd]?.placeholder}function Wo(e){return $d(e).text}function hr(e,t,n){return GS.includes(e)?{text:n,hidden:$d(t).hidden}:n}function x1(e,t,n,o){return Wo(e[t])===o?null:{...e,[t]:hr(n,e[t],o)}}function Gd(e){if(!(!e||typeof e!="object"))return e[KS]}function jS(e){if(!e||typeof e!="object")return null;let t=e.arrayFields;return t&&typeof t=="object"?t:null}function zd(e,t){if(!Array.isArray(t))return[];let n=Gd(e),o=[];if(n?.control==="textList"){let s=n.itemKey??"text";return t.forEach((r,i)=>{let l=K(r?.[s]);l&&o.push({row:{index:i,rowKey:s},text:l})}),o}let a=jS(e);return a?(t.forEach((s,r)=>{for(let[i,l]of Object.entries(a)){if(!Ud(l))continue;let u=Wo(s?.[i])||Gd(l)?.placeholder||"";u&&o.push({row:{index:r,rowKey:i},text:u})}}),o):[]}function VS(e,t){if(Array.isArray(e))return e[t.index]?.[t.rowKey]}function YS(e,t,n,o){let a=e[t];return!Array.isArray(a)||n.index<0||n.index>=a.length?null:{...e,[t]:a.map((s,r)=>r===n.index?{...s,[n.rowKey]:o}:s)}}function k1(e,t,n,o,a){let s=VS(e[t],n);return Wo(s)===a?null:YS(e,t,n,hr(o,s,a))}function I1(e,t){return t?`${e} \xB7 row ${t.index+1}`:e}var z1="data-sf-part",W1="data-sf-region-part",K1="data-sf-part-row";function j1(e,t){return`${e}[${t}]`}var V1="data-sf-part-kind",qS="data-sf-part-style-owner",ZS="data-sf-part-style-kind";function Y1(e){for(let t=e;t;t=t.parentElement){let n=t.getAttribute(qS),o=t.getAttribute(ZS);if(n&&o)return{owner:n,kind:o};if(t.getAttribute("data-easel-block"))return null}return null}var Kd=2;function tn(e){return Os(e).replace(/\s+/gu,"")}function Ko(e,t,n){let o=e[jo];if(o){if(o.control==="textList"){let s=o.itemKey??"text";if(!Array.isArray(t))return;for(let r of t){let i=r?.[s];typeof i=="string"&&n.push(i)}return}let{text:a}=Vd(t);a?n.push(a):o.placeholder&&n.push(o.placeholder);return}if(!e[jd]){if(e.type==="text"||e.type==="textarea"){let a=K(t);a&&n.push(a);return}if(e.arrayFields&&Array.isArray(t)){for(let a of t)for(let[s,r]of Object.entries(e.arrayFields))Ko(r,a?.[s],n);return}if(e.objectFields&&t&&typeof t=="object")for(let[a,s]of Object.entries(e.objectFields))Ko(s,t[a],n)}}function JS(e){if(!e||typeof e!="object")return!1;let t=e;return t[jd]?!1:!!t[jo]||t.type==="text"||t.type==="textarea"}function Yd(e,t){let n=e[jo];return n?.label?n.label:typeof e.label=="string"?e.label:t}function QS(e){let t=e.indexOf(" (");return(t>0?e.slice(0,t):e).trim()}function X1(e,t,n){if(!e)return[];let o=[];for(let[a,s]of Object.entries(e)){if(!s||typeof s!="object"||Dn(a))continue;let r=s,i=[];Ko(r,t?.[a],i),!i.length&&r[Wd]!==void 0&&Ko(r,r[Wd],i);let l=Yd(r,a);if(n?.(a)&&JS(r)){i.length&&o.push({key:a,label:l,texts:[],keyed:!0});continue}let u=new Set;for(let{row:f,text:m}of zd(r,t?.[a])){let b=tn(m);b.length<Kd||(u.add(b),o.push({key:a,label:l,texts:[b],row:f}))}let d=new Set(u),p=[];for(let f of i){let m=tn(f);m.length<Kd||d.has(m)||(d.add(m),p.push(m))}p.length&&o.push({key:a,label:l,texts:p})}return o}function e_(e){return!e.offPage&&!e.hidden&&e.panelOnly!==!0}var t_=XS;function Xd(e,t){if(!t||typeof t!="object"||Dn(e)||Md(t))return null;let n=t[jo];return!n||!t_.includes(n.control)?null:n}function q1(e,t){let n=Xd(e,t);return n!==null&&n.identifier!==!0}function Z1(e,t){if(!e)return[];let n=[];for(let[o,a]of Object.entries(e)){let s=Xd(o,a);if(!s)continue;let{text:r,hidden:i}=Vd(t?.[o]);if(e_({offPage:s.offPage===!0,hidden:!!i,panelOnly:zo(a)}))continue;let l=r||s.placeholder||"",u=Os(l).replace(/\s+/gu," ").trim();n.push({key:o,label:QS(Yd(a,o)),preview:u,offPage:s.offPage===!0,identifier:s.identifier===!0,hidden:!!i})}return n}function nn(e){return!e||typeof e!="object"||Array.isArray(e)?null:e}function Vo(e,t){return nn(e?.[t])??{}}function qd(e,t,n){let o=Vo(e,t);return nn(V(o,n))??{}}function Zd(e,t,n,o){let{[n]:a,...s}=Vo(e,t),r=o?{...s,[n]:o}:s,{[t]:i,...l}=e;return Object.keys(r).length?{...l,[t]:r}:l}import{isLengthUnit as Er}from"efficient-easel/screen/lib/content/length-units";var xr="_partStyles",a_="data-sf-part-styled",Yo="data-sf-text-style",s_=/^(heading|body)-[1-7]$/;function Ct(e){return typeof e=="string"&&s_.test(e)}var Xo={heading:"heading-1",heading2:"heading-2",heading3:"heading-3",body:"body-1",label:"body-5"};function r_(e){if(!e)return null;for(let[t,n]of Object.entries(Xo))if(n===e)return t;return null}function pL(e){if(Ct(e.textStyle))return e.textStyle;let t=mt(e.role);return t?Xo[t]:void 0}var i_=[400,500,600,700],Bn=["left","center","right","justify"],br=5,yr=1e3,l_=-5,c_=10,u_=0,d_=64,p_=2,Jd={size:{min:br,max:yr,step:1},sizeTablet:{min:br,max:yr,step:1},sizePhone:{min:br,max:yr,step:1},padding:{min:u_,max:d_,step:p_}},f_=.05,m_=.01,h_=["line","letter"],g_=.5,b_=2.5,y_=-1,S_=1,__=0,T_=400,E_=[...new Set(Object.values(yo))];function fL(e){return[`${e} { transition: translate var(--page-motion-hover-duration) var(--page-ease-media) var(--page-motion-hover-delay) }`,`${e}:hover, ${e}:active { translate: 0 calc(-1 * var(--page-hover-lift)) }`]}function mL(e){return Vo(e,xr)}function x_(e,t){return qd(e,xr,t)}function sp(e,t,n){return Zd(e,xr,t,v_(n).length?n:null)}function v_(e){return Object.entries(e).filter(([,t])=>t!==void 0)}function w_(e){return h_.includes(e)}var Fn=(e,t,n)=>Math.min(n,Math.max(t,e)),C_=["sizeUnit","sizeUnitTablet","sizeUnitPhone"];function Sr(e){let t=ap("sizeUnit",e),n=C_.find(o=>o===t);if(!n)throw new Error(`a part stores no unit key ${t}`);return n}var xt={size:Sr("desktop"),sizeTablet:Sr("tablet"),sizePhone:Sr("mobile"),paragraphSpacing:"paragraphSpacingUnit",padding:"paddingUnit"},rp=Object.values(xt);function Ae(e,t){return M(e[xt[t]])}function O_(e,t,n={}){if(rp.includes(e))return Er(t)&&t!=="px"?t:null;if(ye(xt,e)&&Ae(n,e)!=="px"){let o=wt(Number(t),2);return!Number.isFinite(o)||o<0||o===0&&e!=="padding"?null:o}if(w_(e)){let o=Math.round(Number(t));return!Number.isFinite(o)||o===0?null:Fn(o,l_,c_)}if(e==="lineHeight"){let o=Number(t);return Number.isFinite(o)?wt(Fn(o,g_,b_),3):null}if(e==="letterSpacing"){let o=Number(t);return Number.isFinite(o)?wt(Fn(o,y_,S_),4):null}if(e==="paragraphSpacing"){let o=Math.round(Number(t));return!Number.isFinite(o)||o<=0?null:Fn(o,__,T_)}if(ye(Jd,e)){let{min:o,max:a}=Jd[e],s=Math.round(Number(t));return Number.isFinite(s)?Fn(s,o,a):null}return e==="italic"?typeof t=="boolean"?t:null:e==="role"||e==="fontRole"?mt(t)?t:null:e==="sizeToken"?vr(t)?t:null:e==="textStyle"?Ct(t)?t:null:e==="alignPhone"||e==="alignTablet"?Bn.includes(t)?t:null:t}var P_=["weight","size","sizeTablet","sizePhone","line","letter","lineHeight","letterSpacing","paragraphSpacing","padding"];function on(e){let t=null,n=o=>{t??={...e},delete t[o]};for(let o of P_){let a=e[o];a!==void 0&&!(typeof a=="number"&&Number.isFinite(a))&&n(o)}e.align!==void 0&&!Bn.includes(e.align)&&n("align"),e.alignTablet!==void 0&&!Bn.includes(e.alignTablet)&&n("alignTablet"),e.alignPhone!==void 0&&!Bn.includes(e.alignPhone)&&n("alignPhone"),e.textStyle!==void 0&&!Ct(e.textStyle)&&n("textStyle"),e.sizeToken!==void 0&&!vr(e.sizeToken)&&n("sizeToken"),e.fontRole!==void 0&&!mt(e.fontRole)&&n("fontRole");for(let o of rp)e[o]!==void 0&&!Er(e[o])&&n(o);return t??e}function vr(e){if(!e||typeof e!="object")return!1;let{step:t,px:n,stepPhone:o,pxPhone:a,fluid:s}=e,r=l=>typeof l=="number"&&Number.isFinite(l)&&l>0,i=l=>typeof l=="string"&&E_.includes(l);return i(t)&&r(n)&&(o===void 0||i(o))&&(a===void 0||r(a))&&(s===void 0||k_(s,n))}function k_(e,t){if(!e||typeof e!="object"||Array.isArray(e))return!1;let{minPx:n,vw:o,...a}=e;return Object.keys(a).length===0&&typeof n=="number"&&Number.isFinite(n)&&n>0&&n<t&&typeof o=="number"&&Number.isFinite(o)&&o>0&&o<=100}function wr(e){return e?.pxPhone&&vr(e)?{step:e.stepPhone??e.step,px:e.pxPhone}:null}function ip({step:e,px:t,fluid:n}){let o=n?`clamp(${n.minPx}px, ${n.vw}vw, ${t}px)`:`${t}px`,a=`var(--size-${e}, ${o})`;return e.startsWith("heading")?`min(${a}, var(--sf-heading-max,9999px))`:a}var I_=[["font","role"],["font","fontRole"],["role","textStyle"],["line","lineHeight"],["letter","letterSpacing"]];function R_(e){let t=[];for(let[n,o]of I_)n===e?t.push(o):o===e&&t.push(n);return t}function hL(e,t,n,o){let a={...x_(e,t)},s=o==null?null:O_(n,o,a);if(s===null)delete a[n];else{a[n]=s;for(let r of R_(n))delete a[r]}return sp(e,t,a)}function gL(e,t){return sp(e,t,{})}function A_(e){return o_(e)??"none"}function N_(e){return n_(e)??""}var Qd={heading:"--font-role-heading",heading2:"--font-role-heading2",heading3:"--font-role-heading3",body:"--font-role-body",accent:"--font-role-accent",label:"--font-role-label"};function L_(e,t){return mt(e.role)||(t?.blockDrawsStyle?null:r_(e.textStyle))}var D_="--sf-part-size-cap";function Cr(e,t){return e&&t?.sizeCap?`min(${e}, var(${D_}, ${e}))`:e}function bL(e,t){return e?.[t]===!0}function yL(e,t){return e==="Text"&&t==="text"}var F_={headingLarge:"min(clamp(64px,9vw,144px), var(--sf-heading-max,9999px))",headingMedium:"min(32px, var(--sf-heading-max,9999px))",headingSmall:"min(24px, var(--sf-heading-max,9999px))",accent:"32px",body:"14px",label:"12px"};function B_(e){let t=yo[e],n=V(F_,t);return n?`var(--size-${t}, ${n})`:`var(--size-${t})`}function Or(e){let t={};return typeof e.lineHeight=="number"?t.lineHeight=e.lineHeight:e.line&&(t.lineHeight=wt(M_+e.line*f_,3)),typeof e.letterSpacing=="number"?t.letterSpacingEm=e.letterSpacing:e.letter&&(t.letterSpacingEm=wt(e.letter*m_,4)),t}var M_=1,vt="--sf-part-para";function H_(e,t){e=on(e);let n={};if(typeof e.sizePhone=="number"&&e.sizePhone>0)n.fontSize=U(e.sizePhone,Ae(e,"sizePhone"));else{let a=wr(e.sizeToken);if(a)n.fontSize=ip(a);else{let s=Zo(e);s!==void 0&&(n.fontSize=U(s,Ae(e,"sizeTablet")))}}n.fontSize&&(n.fontSize=Cr(n.fontSize,t));let o=e.alignPhone??qo(e);return o&&(n.textAlign=o),n}function qo(e){return e.alignTablet&&e.alignTablet!==e.align?e.alignTablet:void 0}function Zo(e){let t=e.sizeTablet!==void 0&&Ae(e,"sizeTablet")!==Ae(e,"size")?e.sizeTablet:Me("textSize",e.size,e.sizeTablet,void 0).tablet;return t&&t>0?t:void 0}function $_(e,t){let n=on(e),o={},a=Zo(n);a!==void 0&&(o.fontSize=Cr(U(a,Ae(n,"sizeTablet")),t));let s=qo(n);return s&&(o.textAlign=s),o}function SL(e,t){if(t==="desktop")return;let n=on(e);return(t==="mobile"?qo(n):void 0)??n.align}function U_(e,t){if(t==="desktop")return e;let n=on(e),o=Zo(n),a=qo(n);if(t==="tablet"){let i=e;return o!==void 0&&(i={...i,size:o,sizeUnit:n[xt.sizeTablet]}),a&&(i={...i,align:a}),i}let s=e;if(typeof n.sizePhone=="number"&&n.sizePhone>0)s={...s,size:n.sizePhone,sizeUnit:n[xt.sizePhone]};else{let i=wr(n.sizeToken);i?s={...s,size:void 0,sizeToken:i}:o!==void 0&&(s={...s,size:o,sizeUnit:n[xt.sizeTablet]})}let r=n.alignPhone??a;return r&&(s={...s,align:r}),s}function Pr(e,t,n){return kr(U_(e,t),Jo,n)}function G_(e){return ap("size",e)}function _L(e,t){if(t==="desktop")return null;let n=on(e);if(t==="mobile"){if(wr(n.sizeToken))return null;let o=Zo(n);if(o!==void 0)return{px:o,view:"tablet"}}return typeof n.size=="number"&&n.size>0?{px:n.size,view:"desktop"}:null}function lp(e,t){let n=G_(t);if(!ye(e,n))return e;let o={...e};return delete o[n],o}function TL(e,t,n){let o=Pr(lp(e,t),t,n);return{fontFamily:o.fontFamily,fontSize:o.fontSize}}function kr(e,t,n){e=on(e);let o=L_(e,n),a=Or(e),s=Cr(e.size?U(e.size,Ae(e,"size")):e.sizeToken?ip(e.sizeToken):o?B_(o):"",n);return{fontFamily:e.font?j_(e.font,n?.fonts):e.fontRole?`var(${Qd[e.fontRole]})`:o?`var(${Qd[o]})`:"",fontWeight:e.weight?String(e.weight):"",fontSize:s,minWidth:s?"0":"",overflowWrap:s?"break-word":"",lineHeight:a.lineHeight!==void 0?String(a.lineHeight):"",letterSpacing:a.letterSpacingEm!==void 0?`${a.letterSpacingEm}em`:"",[vt]:e.paragraphSpacing?U(e.paragraphSpacing,Ae(e,"paragraphSpacing")):"",textTransform:N_(e.case),textAlign:e.align??"",paddingTop:ep(e.padding,Ae(e,"padding")),paddingBottom:ep(e.padding,Ae(e,"padding")),color:z_(e.color),fontStyle:e.italic===!0?"italic":e.italic===!1?"normal":""}}var z_=e=>Io(e),ep=(e,t)=>e===void 0?"":U(e,t),wt=(e,t)=>Number(e.toFixed(t));function EL(e,t){let n=Number.parseFloat(e.fontSize)||16,o=Number.parseFloat(e.lineHeight),a=Number.parseFloat(e.letterSpacing),s=Number.parseFloat(e.paddingTop);return{fontKey:t,sizePx:n,weight:W_(Number.parseInt(e.fontWeight,10)),lineRatio:Number.isFinite(o)?wt(o/n,3):1.2,letterEm:Number.isFinite(a)?wt(a/n,4):0,align:K_(e.textAlign),case:A_(e.textTransform),paddingPx:Number.isFinite(s)?Math.round(s):0}}function W_(e){return Number.isFinite(e)?i_.reduce((t,n)=>Math.abs(n-e)<Math.abs(t-e)?n:t):400}function K_(e){for(let t of Bn)if(t===e)return t;return e==="end"?"right":"left"}function xL(e,t,n=se){let o=tp(e);if(!o)return"";for(let a of n.options)if(tp(t(a.cssVar))===o)return a.key;return""}var tp=e=>(e.split(",")[0]??"").replace(/["']/g,"").replace(/\s+/g," ").trim().toLowerCase();function j_(e,t=se){let n=Lc(e,t);return n?`var(${n.cssVar})`:""}function vL(e,t,n,o){return!t||gr(t)?.nodeId!==e?null:n.find(a=>o(a.getAttribute("class")))??n[0]??null}function V_(e,t){return nn(V(e,t))??{}}function wL(e,t,n=()=>Jo,o=u=>u,a=q_,s="desktop",r=()=>!1,i=()=>!1,l=se){let u=0;for(let{element:d,partId:p}of e){let f=gr(p)?.propKey;if(!f)continue;let m=V_(t,o(f)),b=Pr(m,s,{blockDrawsStyle:r(f),sizeCap:i(f),fonts:l});Ct(m.textStyle)?d.setAttribute?.(Yo,m.textStyle):d.removeAttribute?.(Yo);let y=_r.some(S=>d.style[S]),_=!1;for(let[S,E]of Object.entries(b))Q_(d,S,E),E&&(_=!0);if(y||_r.some(S=>b[S]))for(let S of Y_(d,a))for(let E of _r)S.style[E]=b[E]??"";_&&(u+=1)}return u}function Y_(e,t){let n=tn(e.textContent??""),o=[],a=e;for(let s=0;s<X_&&t(a);s+=1){let r=a.parentElement;if(!r||tn(r.textContent??"")!==n)break;o.push(r),a=r}return o}var X_=8;function q_(e){let t=e;return typeof window>"u"||!t?.ownerDocument?!1:window.getComputedStyle(t).display==="inline"}var Jo={fontKey:"",sizePx:16,weight:400,lineRatio:1,letterEm:0,align:"left",case:"none",paddingPx:0};function Z_(e){if(!e||typeof e!="object")return null;let t={};Ct(e.textStyle)&&(t.textStyle=e.textStyle),typeof e.size=="number"&&e.size>0&&(t.size=e.size),typeof e.sizeTablet=="number"&&e.sizeTablet>0&&(t.sizeTablet=e.sizeTablet),typeof e.sizePhone=="number"&&e.sizePhone>0&&(t.sizePhone=e.sizePhone);for(let n of["size","sizeTablet","sizePhone"]){let o=xt[n];t[n]!==void 0&&Er(e[o])&&(t[o]=e[o])}return Object.keys(t).length?t:null}function J_(e,t,n){let o=Z_(e);if(!o)return{};let a=Pr(o,t,{...n?.sizeCap?{sizeCap:!0}:{},...n?.fonts?{fonts:n.fonts}:{}});return{...a.fontFamily?{fontFamily:a.fontFamily}:{},...a.fontSize?{fontSize:a.fontSize}:{}}}function CL(e){return Ct(e?.textStyle)||!!e?.role||typeof e?.size=="number"&&e.size>0}function OL(e,t,n,o){if(!e||typeof e!="object")return{};let a=Xc(e.role,t,yo)??{},s=t.sized?J_(lp(e,n),n,o?{fonts:o}:void 0):{};return{...a,...s}}function PL(e,t,n){n.fontFamily&&e.fontFamily===n.fontFamily&&(e.fontFamily=t.fontFamily),n.fontSize&&e.fontSize===n.fontSize&&(e.fontSize=t.fontSize)}function Q_(e,t,n){if(!t.startsWith("--")){e.style[t]=n;return}let o=e.style;typeof o.setProperty=="function"?n?o.setProperty(t,n):o.removeProperty?.(t):o[t]=n;let a=e;t===vt&&(n?a.setAttribute?.(np,""):a.removeAttribute?.(np))}var np="data-sf-part-para",eT=Object.keys(kr({},Jo)),Tr=new Set(["color","overflowWrap",vt,"fontStyle"]),_r=eT.filter(e=>!Tr.has(e));function kL(e,t,n,o=u=>u,a=()=>!1,s=()=>null,r=[],i=()=>!1,l=se){let u=new Map;for(let m of e){let b=Go(m.key,m.row);for(let y of m.texts){let _=u.get(y);_?(_.keys.add(m.key),_.partKeys.add(b)):u.set(y,{keys:new Set([m.key]),partKeys:new Set([b])})}}let d=new Map;for(let m of new Set([...Object.keys(t),...r])){if(!tT(m))continue;let b=op(n,m,nn(t[m])??{},{blockDrawsStyle:!1,sizeCap:i(m),fonts:l},s(m));b&&d.set(m,b)}let p=m=>{let b=o(m),y=s(b);if(!ye(t,b)&&!y)return null;let _=nn(t[b])??{};return op(n,m,_,{blockDrawsStyle:a(m),sizeCap:i(m),fonts:l},y)},f=new Map;for(let[m,{keys:b,partKeys:y}]of u){let _=y.size===1?[...y][0]:b.size===1?[...b][0]:null;if(!_)continue;let S=p(_);S&&f.set(m,S)}for(let m of e){if(!m.keyed)continue;let b=p(Go(m.key,m.row));b&&d.set(m.key,b)}return f.size||d.size?{rules:f,kindRules:d,drawn:new Set(u.keys())}:null}function op(e,t,n,o,a){let s=kr(n,Jo,o),r=$_(n,o),i=H_(n,o),l=Ct(n.textStyle)?n.textStyle:void 0;return!Object.values(s).some(Boolean)&&!Object.keys(r).length&&!Object.keys(i).length&&!l&&!a?null:{stamp:nT(e,t),declarations:s,...Object.keys(r).length?{tablet:r}:{},...Object.keys(i).length?{phone:i}:{},...l?{textStyle:l}:{},...a?{motion:a}:{}}}function tT(e){return e.startsWith("@")}function IL(e,t){return e?.kindRules.get(t)??null}function nT(e,t){let n=o=>o.replace(/[^A-Za-z0-9_-]+/g,"-");return`${n(e)}~${n(t)}`}function oT(e){return e?{tablet:Ld,phone:Dd}:{tablet:$o,phone:Uo}}function RL(e,{inBox:t=!1}={}){let{tablet:n,phone:o}=oT(t),a=[],s=new Set,r=i=>{let{stamp:l,declarations:u}=i;if(s.has(l))return;s.add(l);let d=Object.entries(u).filter(([,S])=>S!==""),p=S=>S.map(([E,w])=>`${aT(E)}: ${w}`).join("; "),f=`[${a_}="${l}"]`,m=d.filter(([S])=>!Tr.has(S)),b=d.filter(([S])=>Tr.has(S));m.length&&a.push(`${f}, *:has(> ${f}) { ${p(m)} }`),b.length&&a.push(`${f} { ${p(b)} }`),u[vt]&&(a.push(`*:has(> ${f}) { ${vt}: ${u[vt]} }`),a.push(...Qo(f,`*:has(> ${f})`)));let y=Object.entries(i.tablet??{}).filter(([,S])=>S!=="");y.length&&a.push(`@media ${n} { ${f}, *:has(> ${f}) { ${p(y)} } }`);let _=Object.entries(i.phone??{}).filter(([,S])=>S!=="");_.length&&a.push(`@media ${o} { ${f}, *:has(> ${f}) { ${p(_)} } }`)};for(let i of e.rules.values())r(i);for(let i of e.kindRules.values())r(i);return a.join(`
4
4
  `)}function Qo(e,t){let n=`var(${vt})`,o=":is([data-sf-bullet], [data-sf-number])";return[`${e} br:not(br + br) { display: block; content: ""; margin-top: ${n} }`,`${e} ${o}:not(:first-child) { margin-top: ${n} }`,`${e} ${o}:not(:last-child) { margin-bottom: ${n} }`,`:is(${t}) + :is(${t}) { margin-top: ${n} }`]}var aT=e=>e.replace(/[A-Z]/g,t=>`-${t.toLowerCase()}`);function AL(e,t){if(!e)return null;let n=tn(t),o=e.rules.get(n);if(o)return o;if(n.length<sT||e.drawn.has(n))return null;let a=null;for(let[s,r]of e.rules)if(s.includes(n)){if(a&&a.stamp!==r.stamp)return null;a=r}return a}var sT=8;var Ir=e=>e==="sentence"?"none":void 0,pp=["font","color","size","sizeTablet","sizePhone","weight","italic","lineHeight","lineHeightTablet","lineHeightPhone","letterSpacing","letterSpacingTablet","letterSpacingPhone","paragraphSpacing","paragraphSpacingTablet","paragraphSpacingPhone","letterCase","largestSize","largestSizeTablet","largestSizePhone"],an=["desktop","tablet","phone"],Ot=(e,t)=>G(e,t);function Nr(e,t,n,o=Kt()){return dp("textSize",t,e.sizeTablet,e.sizePhone,o)[n]}var iT=[["lineSpacing","lineHeight","line"],["letterSpacing","letterSpacing","letter"]];function Rr(e){for(let[t,n,o]of iT)for(let a of an)if(e===Ot(t,a))return{key:G(n,a),view:a,spacing:o};return{key:e,view:"desktop",spacing:null}}function Ne(e){let t={};for(let n of pp)e[n]!==void 0&&(t[n]=e[n]);return t}function Lr(e,t){let{auto:n,...o}=e,a=new Set(t??[]),s=pp.filter(r=>a.has(r)&&e.values[r]===void 0);return s.length?{...o,auto:s}:o}function fp(e){let t=e.fonts,n=e.sizes,o=e.typography,a=gu(e.compression),s={"heading-1":{font:K(t.heading),size:k(n.headingLarge),weight:k(o.weight),lineHeight:a.lineHeight,letterSpacing:a.letterSpacing,letterCase:Ir(o.case),largestSize:k(o.maxPx)},"heading-2":{font:K(t.heading2),size:k(n.headingMedium),weight:k(o.weight2),lineHeight:a.lineHeight,letterSpacing:a.letterSpacing,letterCase:Ir(o.case2)},"heading-3":{font:K(t.heading3),size:k(n.headingSmall),weight:k(o.weight3),lineHeight:a.lineHeight,letterSpacing:a.letterSpacing,letterCase:Ir(o.case3)},"body-1":{font:K(t.body),size:k(n.body)},"body-5":{font:K(t.label),size:k(n.label)}};return up().map(({id:r,kind:i,name:l})=>({id:r,kind:i,name:l,values:Ne(s[r]??{})}))}function Dr(e){return Array.isArray(e)&&e.every(t=>t&&typeof t=="object"&&typeof t.id=="string"&&(t.kind==="heading"||t.kind==="body")&&typeof t.name=="string")?e.map(t=>Lr({...t,values:Ne(t.values??{})},Array.isArray(t.auto)?t.auto:void 0)):null}function KL(e){return Dr(e)??[]}function mp(e){return Dr(e)??up().map(({id:t,kind:n,name:o})=>({id:t,kind:n,name:o,values:{}}))}function rn(e,t){let n=fp(t),o=Dr(e);return o?o.map(a=>{let s={...Ar(n,a.id)};for(let r of a.auto??[])delete s[r];return{...a,values:Ne({...s,...a.values})}}):n}var Ar=(e,t)=>e.find(n=>n.id===t)?.values??{},cp=["heading-1","heading-2","heading-3"];function hp({saved:e,old:t,cur:n,next:o,sizeOf:a,panelView:s="desktop"}){let r=fp(t),i=mp(e),l=rn(i,t),u=[],d=o.map(f=>{let m=n.find(O=>O.id===f.id),b=i.find(O=>O.id===f.id);if(!m||!b){let O=lT([f],a,s)[0],v=O.values.color;return v===void 0?O:{...O,values:{...O.values,color:$e(v)}}}let y={...b.values},_=new Set(b.auto??[]),S=f.values,E=m.values,w=[...new Set([...Object.keys(S),...Object.keys(E)])].filter(O=>JSON.stringify(S[O])!==JSON.stringify(E[O])),C=O=>Rr(O).spacing==="letter";w.sort((O,v)=>Number(C(O))-Number(C(v)));for(let O of w){let{key:v,view:x,spacing:P}=Rr(O),N=v,B=S[O];if(B===void 0){delete y[N],Ar(r,f.id)[N]!==void 0&&(u.push([f.id,N]),_.add(N));continue}if(_.delete(N),P==="line")y[N]=sn(B/100,3);else if(P==="letter"){let Xe={...l.find(q=>q.id===f.id)?.values??{}};for(let q of w)S[q]===void 0&&delete Xe[Rr(q).key];let pt=Ne({...Xe,...y}),ft=Nr(pt,a({...f,values:pt}),x);y[N]=ft?sn(B/ft,4):0}else y[N]=B}return Lr({id:f.id,kind:f.kind,name:f.name,values:Ne(y)},_)}),p=t.compression;if(u.some(([f,m])=>(m==="lineHeight"||m==="letterSpacing")&&cp.includes(f))&&yt(p)!=="normal"){for(let f of cp){let m=d.find(y=>y.id===f);if(!m)continue;let b={...m.values};for(let y of["lineHeight","letterSpacing"])u.some(([_,S])=>_===f&&S===y)||b[y]===void 0&&!(m.auto??[]).includes(y)&&(b[y]=Ar(r,f)[y]);m.values=Ne(b)}p="normal"}return{saved:d,old:{...t,compression:p}}}function gp(e,t){let n={text_styles:e.saved};return e.old.compression!==t.compression&&(n.heading_compression=yt(e.old.compression)),n}var sn=(e,t)=>Number(e.toFixed(t)),bp=(e,t)=>an.indexOf(e)<an.indexOf(t)?t:e;function yp(e,t,n="desktop"){return e.map(o=>{let a={...o.values},s=t(o);for(let r of an){let i=G("lineHeight",r),l=o.values[i],u=o.values[G("letterSpacing",r)];delete a[i],l!==void 0&&(a[Ot("lineSpacing",r)]=sn(l*100,1));let d=bp(r,n);u!==void 0&&(a[Ot("letterSpacing",r)]=sn(u*Nr(o.values,s,d),d===r?2:4))}return{id:o.id,kind:o.kind,name:o.name,values:a}})}function lT(e,t,n="desktop"){return e.map(o=>{let a=o.values,s={...a};for(let u of an)delete s[Ot("lineSpacing",u)],delete s[Ot("letterSpacing",u)];let r={id:o.id,kind:o.kind,name:o.name,values:Ne(s)},i={...r.values},l=t({...r,values:{...r.values}});for(let u of an){let d=a[Ot("lineSpacing",u)],p=a[Ot("letterSpacing",u)];if(typeof d=="number"&&(i[G("lineHeight",u)]=sn(d/100,3)),typeof p=="number"){let f=Nr(r.values,l,bp(u,n));i[G("letterSpacing",u)]=f?sn(p/f,4):0}}return{...r,values:Ne(i)}})}function jL(e,t=se){let n={fonts:Cn({heading:e.heading_font??void 0,heading2:e.heading_2_font??void 0,heading3:e.heading_3_font??void 0,body:e.body_font??void 0,accent:e.accent_font??void 0,label:e.label_font??void 0},t),sizes:zs({headingLarge:e.heading_size_large_px,headingMedium:e.heading_size_medium_px,headingSmall:e.heading_size_small_px,accent:e.accent_size_px,body:e.body_size_px,label:e.label_size_px}),compression:yt(e.heading_compression),typography:yu(e)},o=e.text_styles??null,a=Array.isArray(o)?Fr(rn(o,n),n):n;return{fonts:Cn(a.fonts,t),sizes:zs(a.sizes),compression:yt(a.compression),typography:a.typography,textStyles:o}}function Fr(e,t){let n=f=>e.find(m=>m.id===f)?.values??{},o=n("heading-1"),a=n("heading-2"),s=n("heading-3"),r=n("body-1"),i=n("body-5"),l=t.fonts,u=t.sizes,d=t.typography,p=f=>f==="none"?"sentence":"authored";return{fonts:{...l,heading:o.font??l.heading,heading2:a.font??o.font??l.heading2,heading3:s.font??o.font??l.heading3,body:r.font??l.body,label:i.font??l.label},sizes:{...u,headingLarge:o.size??null,headingMedium:a.size??null,headingSmall:s.size??null,body:r.size??null,label:i.size??null},compression:t.compression,typography:{...d,case:p(o.letterCase),weight:o.weight??null,maxPx:o.largestSize??null,weight2:a.weight??null,weight3:s.weight??null,case2:p(a.letterCase),case3:p(s.letterCase)}}}function VL(e,t=se){let n=[];for(let o of e){let a=o.values,s=`.${Fu(o)}`,r=`[${Yo}="${o.id}"]`,i=`${s}, ${r}`,l=[],u=a.font!==void 0?t.byKey.get(a.font)?.cssVar:void 0;if(u&&l.push(`font-family: var(${u})`),a.size!==void 0){let m=a.largestSize!==void 0?Math.min(a.size,a.largestSize):a.size;l.push(`font-size: ${m}px`)}let d=Io(a.color);d&&l.push(`color: ${d}`),a.italic===!0&&l.push("font-style: italic"),a.weight!==void 0&&l.push(`font-weight: ${a.weight}`);let p=[];a.lineHeight!==void 0&&p.push(`line-height: ${a.lineHeight}`),a.letterSpacing!==void 0&&p.push(`letter-spacing: ${a.letterSpacing}em`),o.kind==="body"&&l.push(...p);let f=rT(a.letterCase);f&&o.kind==="body"&&l.push(`text-transform: ${f}`),a.paragraphSpacing&&l.push(`--sf-part-para: ${a.paragraphSpacing}px`),l.length&&n.push(`${i} { ${l.join("; ")} }`),o.kind==="heading"&&p.length&&n.push(`${i}, ${s}:is(h1, h2, h3, h4), ${r}:is(h1, h2, h3, h4) { ${p.join("; ")} }`),o.kind==="heading"&&f&&n.push(`${r}, ${s}:is(h1, h2, h3, h4) { text-transform: ${f} }`),a.paragraphSpacing&&(n.push(`*:has(> ${r}) { --sf-part-para: ${a.paragraphSpacing}px }`),n.push(...Qo(`:is(${i})`,`*:has(> ${r})`))),n.push(...cT(o,i,s,r))}return n.join(`
@@ -1,4 +1,4 @@
1
- import{f as fs,g as hs}from"./chunk-55HCCLM4.js";import{a as T,b as Sr}from"./chunk-Y6SLVHK3.js";var Sn=T((ud,Ds)=>{"use strict";function Iu(i,e){this.v=i,this.k=e}function ps(i,e){(e==null||e>i.length)&&(e=i.length);for(var t=0,r=Array(e);t<e;t++)r[t]=i[t];return r}function Lu(i){if(Array.isArray(i))return i}function Du(i,e){var t=i==null?null:typeof Symbol<"u"&&i[Symbol.iterator]||i["@@iterator"];if(t!=null){var r,n,s,o,l=[],a=!0,h=!1;try{if(s=(t=t.call(i)).next,e===0){if(Object(t)!==t)return;a=!1}else for(;!(a=(r=s.call(t)).done)&&(l.push(r.value),l.length!==e);a=!0);}catch(f){h=!0,n=f}finally{try{if(!a&&t.return!=null&&(o=t.return(),Object(o)!==o))return}finally{if(h)throw n}}return l}}function Ru(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
1
+ import{f as fs,g as hs}from"./chunk-KDDW7HM7.js";import{a as T,b as Sr}from"./chunk-Y6SLVHK3.js";var Sn=T((ud,Ds)=>{"use strict";function Iu(i,e){this.v=i,this.k=e}function ps(i,e){(e==null||e>i.length)&&(e=i.length);for(var t=0,r=Array(e);t<e;t++)r[t]=i[t];return r}function Lu(i){if(Array.isArray(i))return i}function Du(i,e){var t=i==null?null:typeof Symbol<"u"&&i[Symbol.iterator]||i["@@iterator"];if(t!=null){var r,n,s,o,l=[],a=!0,h=!1;try{if(s=(t=t.call(i)).next,e===0){if(Object(t)!==t)return;a=!1}else for(;!(a=(r=s.call(t)).done)&&(l.push(r.value),l.length!==e);a=!0);}catch(f){h=!0,n=f}finally{try{if(!a&&t.return!=null&&(o=t.return(),Object(o)!==o))return}finally{if(h)throw n}}return l}}function Ru(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2
2
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Nu(i,e){return Lu(i)||Du(i,e)||ku(i,e)||Ru()}function ku(i,e){if(i){if(typeof i=="string")return ps(i,e);var t={}.toString.call(i).slice(8,-1);return t==="Object"&&i.constructor&&(t=i.constructor.name),t==="Map"||t==="Set"?Array.from(i):t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?ps(i,e):void 0}}function br(i){var e,t;function r(s,o){try{var l=i[s](o),a=l.value,h=a instanceof Iu;Promise.resolve(h?a.v:a).then(function(f){if(h){var _=s==="return"&&a.k?s:"next";if(!a.k||f.done)return r(_,f);f=i[_](f).value}n(!!l.done,f)},function(f){r("throw",f)})}catch(f){n(2,f)}}function n(s,o){s===2?e.reject(o):e.resolve({value:o,done:s}),(e=e.next)?r(e.key,e.arg):t=null}this._invoke=function(s,o){return new Promise(function(l,a){var h={key:s,arg:o,resolve:l,reject:a,next:null};t?t=t.next=h:(e=t=h,r(s,o))})},typeof i.return!="function"&&(this.return=void 0)}br.prototype[typeof Symbol=="function"&&Symbol.asyncIterator||"@@asyncIterator"]=function(){return this},br.prototype.next=function(i){return this._invoke("next",i)},br.prototype.throw=function(i){return this._invoke("throw",i)},br.prototype.return=function(i){return this._invoke("return",i)};var xs=Object.entries,ds=Object.setPrototypeOf,Mu=Object.isFrozen,Fu=Object.getPrototypeOf,qu=Object.getOwnPropertyDescriptor,J=Object.freeze,re=Object.seal,vt=Object.create,Cs=typeof Reflect<"u"&&Reflect,vn=Cs.apply,wn=Cs.construct;J||(J=function(e){return e});re||(re=function(e){return e});vn||(vn=function(e,t){for(var r=arguments.length,n=new Array(r>2?r-2:0),s=2;s<r;s++)n[s-2]=arguments[s];return e.apply(t,n)});wn||(wn=function(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];return new e(...r)});var Ge=X(Array.prototype.forEach);Array.prototype.indexOf;var ju=X(Array.prototype.lastIndexOf),ms=X(Array.prototype.pop),kt=X(Array.prototype.push);Array.prototype.slice;var Uu=X(Array.prototype.splice),wt=Array.isArray,qt=X(String.prototype.toLowerCase),pn=X(String.prototype.toString),gs=X(String.prototype.match),Mt=X(String.prototype.replace),ys=X(String.prototype.indexOf),Bu=X(String.prototype.trim),zu=X(Number.prototype.toString),Wu=X(Boolean.prototype.toString),_s=typeof BigInt>"u"?null:X(BigInt.prototype.toString),vs=typeof Symbol>"u"?null:X(Symbol.prototype.toString),ue=X(Object.prototype.hasOwnProperty),Ft=X(Object.prototype.toString),oe=X(RegExp.prototype.test),ke=Hu(TypeError);function X(i){return function(e){e instanceof RegExp&&(e.lastIndex=0);for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];return vn(i,e,r)}}function Hu(i){return function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return wn(i,t)}}function D(i,e){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:qt;if(ds&&ds(i,null),!wt(e))return i;let r=e.length;for(;r--;){let n=e[r];if(typeof n=="string"){let s=t(n);s!==n&&(Mu(e)||(e[r]=s),n=s)}i[n]=!0}return i}function Gu(i){for(let e=0;e<i.length;e++)ue(i,e)||(i[e]=null);return i}function he(i){let e=vt(null);for(let r of xs(i)){var t=Nu(r,2);let n=t[0],s=t[1];ue(i,n)&&(wt(s)?e[n]=Gu(s):s&&typeof s=="object"&&s.constructor===Object?e[n]=he(s):e[n]=s)}return e}function Yu(i){switch(typeof i){case"string":return i;case"number":return zu(i);case"boolean":return Wu(i);case"bigint":return _s?_s(i):"0";case"symbol":return vs?vs(i):"Symbol()";case"undefined":return Ft(i);case"function":case"object":{if(i===null)return Ft(i);let e=i,t=me(e,"toString");if(typeof t=="function"){let r=t(e);return typeof r=="string"?r:Ft(r)}return Ft(i)}default:return Ft(i)}}function me(i,e){for(;i!==null;){let r=qu(i,e);if(r){if(r.get)return X(r.get);if(typeof r.value=="function")return X(r.value)}i=Fu(i)}function t(){return null}return t}function $u(i){try{return oe(i,""),!0}catch{return!1}}var ws=J(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),dn=J(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),mn=J(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),Vu=J(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),gn=J(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),Qu=J(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Ss=J(["#text"]),bs=J(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","command","commandfor","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns"]),yn=J(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dominant-baseline","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","pointer-events","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-orientation","text-rendering","textlength","type","u1","u2","unicode","values","vector-effect","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Ts=J(["accent","accentunder","align","bevelled","close","columnalign","columnlines","columnspacing","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lquote","lspace","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Tr=J(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Xu=re(/{{[\w\W]*|^[\w\W]*}}/g),Ku=re(/<%[\w\W]*|^[\w\W]*%>/g),Ju=re(/\${[\w\W]*/g),Zu=re(/^data-[\-\w.\u00B7-\uFFFF]+$/),el=re(/^aria-[\-\w]+$/),Es=re(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),tl=re(/^(?:\w+script|data):/i),rl=re(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),nl=re(/^html$/i),il=re(/^[a-z][.\w]*(-[.\w]+)+$/i),Os=re(/<[/\w!]/g),As=re(/<[/\w]/g),sl=re(/<\/no(script|embed|frames)/i),ol=re(/\/>/i),fe={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},Is=["style","script","xmp","iframe","noembed","noframes","plaintext","noscript"],al=J(D({},Is)),ul=(function(){let i={};return Ge(Is,e=>{i[e]=re(new RegExp("</"+e+"(?=[\\t\\n\\f\\r />])","i"))}),J(i)})(),ll=function(){return typeof window>"u"?null:window},cl=function(e,t){if(typeof e!="object"||typeof e.createPolicy!="function")return null;let r=null,n="data-tt-policy-suffix";t&&t.hasAttribute(n)&&(r=t.getAttribute(n));let s="dompurify"+(r?"#"+r:"");try{return e.createPolicy(s,{createHTML(o){return o},createScriptURL(o){return o}})}catch{return console.warn("TrustedTypes policy "+s+" could not be created."),null}},Ps=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},Me=function(e,t,r,n){return ue(e,t)&&wt(e[t])?D(n.base?he(n.base):{},e[t],n.transform):r},_n=function(e,t,r){let n=ue(e,t)?e[t]:void 0;return n&&typeof n=="object"?he(n):r()};function Ls(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ll(),e=y=>Ls(y);if(e.version="3.4.16",e.removed=[],!i||!i.document||i.document.nodeType!==fe.document||!i.Element)return e.isSupported=!1,e;let t=i.document,r=t,n=r.currentScript;i.DocumentFragment;let s=i.HTMLTemplateElement,o=i.Node,l=i.Element,a=i.NodeFilter;i.NamedNodeMap===void 0&&(i.NamedNodeMap||i.MozNamedAttrMap),i.HTMLFormElement;let h=i.DOMParser,f=i.trustedTypes,_=l.prototype,p=me(_,"cloneNode"),d=me(_,"remove"),v=me(_,"removeAttributeNode"),x=me(_,"nextSibling"),E=me(_,"childNodes"),U=me(_,"parentNode"),Y=me(_,"shadowRoot"),K=me(_,"attributes"),k=o&&o.prototype?me(o.prototype,"nodeType"):null,V=o&&o.prototype?me(o.prototype,"nodeName"):null,Q=o&&o.prototype?me(o.prototype,"ownerDocument"):null,ee=function(u){return k?k(u):u.nodeType},Se=function(u){return V?V(u):u.nodeName};if(typeof s=="function"){let y=t.createElement("template");y.content&&y.content.ownerDocument&&(t=y.content.ownerDocument)}let te,pe="",Lt,ar=!1,Be=0,Ni=function(){if(Be>0)throw ke('A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.')},ct=function(u){Ni(),Be++;try{return te.createHTML(u)}finally{Be--}},ru=function(u){Ni(),Be++;try{return te.createScriptURL(u)}finally{Be--}},nu=function(){return ar||(Lt=cl(f,n),ar=!0),Lt},ur=t,Xr=ur.implementation,ki=ur.createNodeIterator,iu=ur.createDocumentFragment,su=ur.getElementsByTagName,ou=r.importNode,B=Ps();e.isSupported=typeof xs=="function"&&typeof U=="function"&&Xr&&Xr.createHTMLDocument!==void 0;let au=Xu,uu=Ku,lu=Ju,cu=Zu,fu=el,hu=tl,Mi=rl,pu=il,Fi=Es,z=null,Kr=D({},[...ws,...dn,...mn,...gn,...Ss]),W=null,Jr=D({},[...bs,...yn,...Ts,...Tr]),be=Object.seal(vt(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Dt=null,qi=null,De=Object.seal(vt(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}})),ji=!0,Zr=!0,Ui=!1,Bi=!0,Re=!1,ze=!0,We=!1,en=!1,lr=null,cr=null,tn=!1,ft=!1,fr=!1,hr=!1,zi=!0,Wi=!1,Hi="user-content-",rn=!0,nn=!1,ht={},pt=null,Gi=D({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","selectedcontent","style","svg","template","thead","title","video","xmp"]),Yi=null,$i=D({},["audio","video","img","source","image","track"]),Vi=null,Qi=D({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),pr="http://www.w3.org/1998/Math/MathML",dr="http://www.w3.org/2000/svg",Te="http://www.w3.org/1999/xhtml",dt=Te,sn=!1,on=null,du=D({},[pr,dr,Te],pn),Xi=J(["mi","mo","mn","ms","mtext"]),an=D({},Xi),Ki=J(["annotation-xml"]),un=D({},Ki),mu=D({},["title","style","font","a","script"]),Rt=null,gu=["application/xhtml+xml","text/html"],yu="text/html",$=null,mt=null,_u=t.createElement("form"),Ji=function(u){return u instanceof RegExp||u instanceof Function},ln=function(){let u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(mt&&mt===u)return;(!u||typeof u!="object")&&(u={}),u=he(u),Rt=gu.indexOf(u.PARSER_MEDIA_TYPE)===-1?yu:u.PARSER_MEDIA_TYPE,$=Rt==="application/xhtml+xml"?pn:qt,z=Me(u,"ALLOWED_TAGS",Kr,{transform:$}),W=Me(u,"ALLOWED_ATTR",Jr,{transform:$}),on=Me(u,"ALLOWED_NAMESPACES",du,{transform:pn}),Vi=Me(u,"ADD_URI_SAFE_ATTR",Qi,{transform:$,base:Qi}),Yi=Me(u,"ADD_DATA_URI_TAGS",$i,{transform:$,base:$i}),pt=Me(u,"FORBID_CONTENTS",Gi,{transform:$}),Dt=Me(u,"FORBID_TAGS",he({}),{transform:$}),qi=Me(u,"FORBID_ATTR",he({}),{transform:$}),ht=ue(u,"USE_PROFILES")?u.USE_PROFILES&&typeof u.USE_PROFILES=="object"?he(u.USE_PROFILES):u.USE_PROFILES:!1,ji=u.ALLOW_ARIA_ATTR!==!1,Zr=u.ALLOW_DATA_ATTR!==!1,Ui=u.ALLOW_UNKNOWN_PROTOCOLS||!1,Bi=u.ALLOW_SELF_CLOSE_IN_ATTR!==!1,Re=u.SAFE_FOR_TEMPLATES||!1,ze=u.SAFE_FOR_XML!==!1,We=u.WHOLE_DOCUMENT||!1,ft=u.RETURN_DOM||!1,fr=u.RETURN_DOM_FRAGMENT||!1,hr=u.RETURN_TRUSTED_TYPE||!1,tn=u.FORCE_BODY||!1,zi=u.SANITIZE_DOM!==!1,Wi=u.SANITIZE_NAMED_PROPS||!1,rn=u.KEEP_CONTENT!==!1,nn=u.IN_PLACE||!1,Fi=$u(u.ALLOWED_URI_REGEXP)?u.ALLOWED_URI_REGEXP:Es,dt=typeof u.NAMESPACE=="string"?u.NAMESPACE:Te,an=_n(u,"MATHML_TEXT_INTEGRATION_POINTS",()=>D({},Xi)),un=_n(u,"HTML_INTEGRATION_POINTS",()=>D({},Ki));let c=_n(u,"CUSTOM_ELEMENT_HANDLING",()=>vt(null));if(be=vt(null),ue(c,"tagNameCheck")&&Ji(c.tagNameCheck)&&(be.tagNameCheck=c.tagNameCheck),ue(c,"attributeNameCheck")&&Ji(c.attributeNameCheck)&&(be.attributeNameCheck=c.attributeNameCheck),ue(c,"allowCustomizedBuiltInElements")&&typeof c.allowCustomizedBuiltInElements=="boolean"&&(be.allowCustomizedBuiltInElements=c.allowCustomizedBuiltInElements),re(be),Re&&(Zr=!1),fr&&(ft=!0),ht&&(z=D({},Ss),W=vt(null),ht.html===!0&&(D(z,ws),D(W,bs)),ht.svg===!0&&(D(z,dn),D(W,yn),D(W,Tr)),ht.svgFilters===!0&&(D(z,mn),D(W,yn),D(W,Tr)),ht.mathMl===!0&&(D(z,gn),D(W,Ts),D(W,Tr))),De.tagCheck=null,De.attributeCheck=null,ue(u,"ADD_TAGS")&&(typeof u.ADD_TAGS=="function"?De.tagCheck=u.ADD_TAGS:wt(u.ADD_TAGS)&&(z===Kr&&(z=he(z)),D(z,u.ADD_TAGS,$))),ue(u,"ADD_ATTR")&&(typeof u.ADD_ATTR=="function"?De.attributeCheck=u.ADD_ATTR:wt(u.ADD_ATTR)&&(W===Jr&&(W=he(W)),D(W,u.ADD_ATTR,$))),ue(u,"ADD_FORBID_CONTENTS")&&wt(u.ADD_FORBID_CONTENTS)&&(pt===Gi&&(pt=he(pt)),D(pt,u.ADD_FORBID_CONTENTS,$)),rn&&(z["#text"]=!0),We&&D(z,["html","head","body"]),z.table&&(D(z,["tbody"]),delete Dt.tbody),u.TRUSTED_TYPES_POLICY){if(typeof u.TRUSTED_TYPES_POLICY.createHTML!="function")throw ke('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof u.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw ke('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');let g=te;te=u.TRUSTED_TYPES_POLICY;try{pe=ct("")}catch(w){throw te=g,w}}else u.TRUSTED_TYPES_POLICY===null?(te=void 0,pe=""):(te===void 0&&(te=nu()),te&&typeof pe=="string"&&(pe=ct("")));J&&J(u),mt=u},Zi=D({},[...dn,...mn,...Vu]),es=D({},[...gn,...Qu]),vu=function(u,c,g){return c.namespaceURI===Te?u==="svg":c.namespaceURI===pr?u==="svg"&&(g==="annotation-xml"||an[g]):!!Zi[u]},wu=function(u,c,g){return c.namespaceURI===Te?u==="math":c.namespaceURI===dr?u==="math"&&un[g]:!!es[u]},Su=function(u,c,g){return c.namespaceURI===dr&&!un[g]||c.namespaceURI===pr&&!an[g]?!1:!es[u]&&(mu[u]||!Zi[u])},bu=function(u){let c=U(u);(!c||!c.tagName)&&(c={namespaceURI:dt,tagName:"template"});let g=qt(u.tagName),w=qt(c.tagName);return on[u.namespaceURI]?u.namespaceURI===dr?vu(g,c,w):u.namespaceURI===pr?wu(g,c,w):u.namespaceURI===Te?Su(g,c,w):!!(Rt==="application/xhtml+xml"&&on[u.namespaceURI]):!1},Ne=function(u){kt(e.removed,{element:u});try{U(u).removeChild(u)}catch{if(d(u),!U(u))throw ke("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place")}},ts=function(u,c,g){try{v(u,c)}catch{try{u.removeAttribute(g)}catch{}}},mr=function(u){gr(u);let c=E(u);if(c){let w=[];Ge(c,A=>{kt(w,A)}),Ge(w,A=>{try{d(A)}catch{}})}let g=K(u);if(g)for(let w=g.length-1;w>=0;--w){let A=g[w],C=A&&A.name;typeof C=="string"&&ts(u,A,C)}},He=function(u,c,g){if(!g)try{g=c.getAttributeNode(u)}catch{g=null}kt(e.removed,{attribute:g||null,from:c});try{g?v(c,g):c.removeAttribute(u)}catch{try{c.removeAttribute(u)}catch{}}if(u==="is")if(ft||fr)try{Ne(c)}catch{}else try{c.setAttribute(u,"")}catch{}},Tu=function(u){let c=K(u);if(c)for(let g=c.length-1;g>=0;--g){let w=c[g],A=w&&w.name;typeof A!="string"||W[$(A)]||ts(u,w,A)}},gr=function(u){let c=[u];for(;c.length>0;){let g=c.pop();ee(g)===fe.element&&Tu(g);let w=E(g);if(w)for(let A=w.length-1;A>=0;--A)c.push(w[A])}},rs=function(u,c){return ze?u==="patchsrc"?!0:u==="for"&&c!=="label"&&c!=="output":!1},Eu=function(u){if(!ze)return;let c=[u];for(;c.length>0;){let g=c.pop(),w=ee(g);if(w===fe.processingInstruction||w===fe.comment&&oe(As,g.data)){try{d(g)}catch{}continue}if(w===fe.element){let C=g,L=$(Se(g));try{C.hasAttribute&&C.hasAttribute("patchsrc")&&C.removeAttribute("patchsrc"),C.hasAttribute&&C.hasAttribute("for")&&rs("for",L)&&C.removeAttribute("for")}catch{}}let A=E(g);if(A)for(let C=A.length-1;C>=0;--C)c.push(A[C])}},ns=function(u){let c=null,g=null;if(tn)u="<remove></remove>"+u;else{let C=gs(u,/^[\r\n\t ]+/);g=C&&C[0]}Rt==="application/xhtml+xml"&&dt===Te&&(u='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+u+"</body></html>");let w=te?ct(u):u;if(dt===Te)try{c=new h().parseFromString(w,Rt)}catch{}if(!c||!c.documentElement){c=Xr.createDocument(dt,"template",null);try{c.documentElement.innerHTML=sn?pe:w}catch{}}let A=c.body||c.documentElement;return u&&g&&A.insertBefore(t.createTextNode(g),A.childNodes[0]||null),dt===Te?su.call(c,We?"html":"body")[0]:We?c.documentElement:A},is=function(u){let c=Q?Q(u):u.ownerDocument;return ki.call(c||u,u,a.SHOW_ELEMENT|a.SHOW_COMMENT|a.SHOW_TEXT|a.SHOW_PROCESSING_INSTRUCTION|a.SHOW_CDATA_SECTION,null)},yr=function(u){return u=Mt(u,au," "),u=Mt(u,uu," "),u=Mt(u,lu," "),u},cn=function(u){var c;u.normalize();let g=Q?Q(u):u.ownerDocument,w=ki.call(g||u,u,a.SHOW_TEXT|a.SHOW_COMMENT|a.SHOW_CDATA_SECTION|a.SHOW_PROCESSING_INSTRUCTION,null),A=w.nextNode();for(;A;)A.data=yr(A.data),A=w.nextNode();let C=(c=u.querySelectorAll)===null||c===void 0?void 0:c.call(u,"template");C&&Ge(C,L=>{gt(L.content)&&cn(L.content)})},_r=function(u){let c=V?V(u):null;return typeof c!="string"||$(c)!=="form"?!1:typeof u.nodeName!="string"||typeof u.textContent!="string"||typeof u.removeChild!="function"||u.attributes!==K(u)||typeof u.removeAttribute!="function"||typeof u.removeAttributeNode!="function"||typeof u.getAttributeNode!="function"||typeof u.setAttribute!="function"||typeof u.namespaceURI!="string"||typeof u.insertBefore!="function"||typeof u.hasChildNodes!="function"||u.nodeType!==k(u)||u.childNodes!==E(u)},gt=function(u){if(!k||typeof u!="object"||u===null)return!1;try{return k(u)===fe.documentFragment}catch{return!1}},Nt=function(u){if(!k||typeof u!="object"||u===null)return!1;try{return typeof k(u)=="number"}catch{return!1}};function Ee(y,u,c){y.length!==0&&Ge(y,g=>{g.call(e,u,c,mt)})}let Ou=function(u,c){return!!(ze&&u.hasChildNodes()&&!Nt(u.firstElementChild)&&oe(Os,u.textContent)&&oe(Os,u.innerHTML)||ze&&u.namespaceURI===Te&&al[c]&&(Nt(u.firstElementChild)||typeof u.textContent=="string"&&oe(ul[c],u.textContent))||u.nodeType===fe.processingInstruction||ze&&u.nodeType===fe.comment&&oe(As,u.data))},vr=function(u,c){if(u instanceof RegExp)return oe(u,c);if(u instanceof Function){for(var g=arguments.length,w=new Array(g>2?g-2:0),A=2;A<g;A++)w[A-2]=arguments[A];return!!u(c,...w)}return!1},Au=function(u,c,g){if(!Dt[c]&&us(c)&&vr(be.tagNameCheck,c))return!1;if(rn&&!pt[c]){let w=U(u),A=E(u);if(A&&w){let C=A.length;for(let L=C-1;L>=0;--L){let G=u===g?p(A[L],!0):A[L];w.insertBefore(G,x(u))}}}return Ne(u),!0},ss=function(u,c,g,w){return u.length===0?c:c===g||c===w?he(c):c},yt=function(u,c){return u===c||U(u)!==null?!1:(nn&&gr(u),!0)},os=function(u,c){if(Ee(B.beforeSanitizeElements,u,null),yt(u,c))return!0;if(_r(u))return Ne(u),!0;let g=$(Se(u));if(z=ss(B.uponSanitizeElement,z,Kr,lr),Ee(B.uponSanitizeElement,u,{tagName:g,allowedTags:z}),yt(u,c))return!0;if(Ou(u,g))return Ne(u),!0;if(Dt[g]||!(De.tagCheck instanceof Function&&De.tagCheck(g))&&!z[g]){let w=Au(u,g,c);return w===!1&&(Ee(B.afterSanitizeElements,u,null),yt(u,c))?!0:w}if(ee(u)===fe.element&&!bu(u)||(g==="noscript"||g==="noembed"||g==="noframes")&&oe(sl,u.innerHTML))return Ne(u),!0;if(Re&&u.nodeType===fe.text){let w=yr(u.textContent);u.textContent!==w&&(kt(e.removed,{element:u.cloneNode()}),u.textContent=w)}return Ee(B.afterSanitizeElements,u,null),yt(u,c)},as=function(u,c,g){if(qi[c]||rs(c,u)||zi&&(c==="id"||c==="name")&&(g in t||g in _u))return!1;let w=W[c]||De.attributeCheck instanceof Function&&De.attributeCheck(c,u);return Zr&&oe(cu,c)||ji&&oe(fu,c)?!0:w?Vi[c]||oe(Fi,Mt(g,Mi,""))||(c==="src"||c==="xlink:href"||c==="href")&&u!=="script"&&ys(g,"data:")===0&&Yi[u]||Ui&&!oe(hu,Mt(g,Mi,""))?!0:!g:us(u)&&vr(be.tagNameCheck,u)&&vr(be.attributeNameCheck,c,u)||c==="is"&&be.allowCustomizedBuiltInElements&&vr(be.tagNameCheck,g)},Pu=D({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),us=function(u){return!Pu[qt(u)]&&oe(pu,u)},xu=function(u,c,g,w){if(te&&typeof f=="object"&&typeof f.getAttributeType=="function"&&!g)switch(f.getAttributeType(u,c)){case"TrustedHTML":return ct(w);case"TrustedScriptURL":return ru(w)}return w},Cu=function(u,c,g,w){try{return g?u.setAttributeNS(g,c,w):u.setAttribute(c,w),_r(u)?(Ne(u),!1):!0}catch{return He(c,u),!1}},ls=function(u,c){if(Ee(B.beforeSanitizeAttributes,u,null),yt(u,c))return;let g=u.attributes;if(!g||_r(u))return;W=ss(B.uponSanitizeAttribute,W,Jr,cr);let w={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:W,forceKeepAttr:void 0},A=g.length,C=$(u.nodeName);for(;A--;){let L=g[A],G=L.name,de=L.namespaceURI,ce=L.value,_t=$(G),hn=ce,ae=G==="value"?hn:Bu(hn),cs=!1;if(w.attrName=_t,w.attrValue=ae,w.keepAttr=!0,w.forceKeepAttr=void 0,Ee(B.uponSanitizeAttribute,u,w),ae=w.attrValue,Wi&&(_t==="id"||_t==="name")&&ys(ae,Hi)!==0&&(He(G,u,L),ae=Hi+ae,cs=!0),ze&&oe(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,ae)){He(G,u,L);continue}if(_t==="attributename"&&gs(ae,"href")){He(G,u,L);continue}if(!w.forceKeepAttr){if(!w.keepAttr){He(G,u,L);continue}if(!Bi&&oe(ol,ae)){He(G,u,L);continue}if(Re&&(ae=yr(ae)),!as(C,_t,ae)){He(G,u,L);continue}ae=xu(C,_t,de,ae),ae!==hn&&Cu(u,G,de,ae)&&cs&&ms(e.removed)}}Ee(B.afterSanitizeAttributes,u,null),yt(u,c)},wr=function(u){let c=null,g=is(u);for(Ee(B.beforeSanitizeShadowDOM,u,null);c=g.nextNode();)if(Ee(B.uponSanitizeShadowNode,c,null),os(c,u),ls(c,u),gt(c.content)&&wr(c.content),ee(c)===fe.element){let w=Y(c);gt(w)&&(fn(w),wr(w))}Ee(B.afterSanitizeShadowDOM,u,null)},fn=function(u){let c=[{node:u,shadow:null}];for(;c.length>0;){let g=c.pop();if(g.shadow){wr(g.shadow);continue}let w=g.node,A=ee(w)===fe.element,C=E(w);if(C)for(let L=C.length-1;L>=0;--L)c.push({node:C[L],shadow:null});if(A){let L=V?V(w):null;if(typeof L=="string"&&$(L)==="template"){let G=w.content;gt(G)&&c.push({node:G,shadow:null})}}if(A){let L=Y(w);gt(L)&&c.push({node:null,shadow:L},{node:L,shadow:null})}}};return e.sanitize=function(y){let u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},c=null,g=null,w=null,A=null;if(sn=!y,sn&&(y="<!-->"),typeof y!="string"&&!Nt(y)&&(y=Yu(y),typeof y!="string"))throw ke("dirty is not a string, aborting");if(!e.isSupported)return y;en?(z=lr,W=cr):ln(u),(B.uponSanitizeElement.length>0||B.uponSanitizeAttribute.length>0)&&(z=he(z)),B.uponSanitizeAttribute.length>0&&(W=he(W)),e.removed=[];let C=nn&&typeof y!="string"&&Nt(y);if(C){Eu(y);let de=Se(y);if(typeof de=="string"){let ce=$(de);if(!z[ce]||Dt[ce])throw mr(y),ke("root node is forbidden and cannot be sanitized in-place")}if(_r(y))throw mr(y),ke("root node is clobbered and cannot be sanitized in-place");try{fn(y)}catch(ce){throw mr(y),ce}}else if(Nt(y))c=ns("<!---->"),g=c.ownerDocument.importNode(y,!0),g.nodeType===fe.element&&g.nodeName==="BODY"||g.nodeName==="HTML"?c=g:c.appendChild(g),fn(c);else{if(!ft&&!Re&&!We&&y.indexOf("<")===-1)return te&&hr?ct(y):y;if(c=ns(y),!c)return ft?null:hr?pe:""}c&&tn&&Ne(c.firstChild);let L=C?y:c;try{let de=is(L);for(;w=de.nextNode();)os(w,L),ls(w,L),gt(w.content)&&wr(w.content)}catch(de){throw C&&(mr(y),Ge(e.removed,ce=>{ce.element&&gr(ce.element)})),de}if(C){let de=!1;if(Ge(e.removed,ce=>{ce.element&&(ce.element===y&&(de=!0),gr(ce.element))}),de)throw ke("a node selected for removal could not be safely returned; refusing to sanitize in place");return Re&&cn(y),y}if(ft){if(Re&&cn(c),fr)for(A=iu.call(c.ownerDocument);c.firstChild;)A.appendChild(c.firstChild);else A=c;return(W.shadowroot||W.shadowrootmode)&&(A=ou.call(r,A,!0)),A}let G=We?c.outerHTML:c.innerHTML;return We&&z["!doctype"]&&c.ownerDocument&&c.ownerDocument.doctype&&c.ownerDocument.doctype.name&&oe(nl,c.ownerDocument.doctype.name)&&(G="<!DOCTYPE "+c.ownerDocument.doctype.name+`>
3
3
  `+G),Re&&(G=yr(G)),te&&hr?ct(G):G},e.setConfig=function(){let y=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};ln(y),en=!0,lr=z,cr=W},e.clearConfig=function(){mt=null,en=!1,lr=null,cr=null,te=Lt,pe=""},e.isValidAttribute=function(y,u,c){mt||ln({});let g=$(y),w=$(u);return as(g,w,c)},e.addHook=function(y,u){typeof u=="function"&&ue(B,y)&&kt(B[y],u)},e.removeHook=function(y,u){if(ue(B,y)){if(u!==void 0){let c=ju(B[y],u);return c===-1?void 0:Uu(B[y],c,1)[0]}return ms(B[y])}},e.removeHooks=function(y){ue(B,y)&&(B[y]=[])},e.removeAllHooks=function(){B=Ps()},e}var fl=Ls();Ds.exports=fl});var Ns=T((ld,bn)=>{"use strict";var P=String,Rs=function(){return{isColorSupported:!1,reset:P,bold:P,dim:P,italic:P,underline:P,inverse:P,hidden:P,strikethrough:P,black:P,red:P,green:P,yellow:P,blue:P,magenta:P,cyan:P,white:P,gray:P,bgBlack:P,bgRed:P,bgGreen:P,bgYellow:P,bgBlue:P,bgMagenta:P,bgCyan:P,bgWhite:P,blackBright:P,redBright:P,greenBright:P,yellowBright:P,blueBright:P,magentaBright:P,cyanBright:P,whiteBright:P,bgBlackBright:P,bgRedBright:P,bgGreenBright:P,bgYellowBright:P,bgBlueBright:P,bgMagentaBright:P,bgCyanBright:P,bgWhiteBright:P}};bn.exports=Rs();bn.exports.createColors=Rs});var Tn=T(()=>{"use strict"});var Er=T((hd,Fs)=>{"use strict";var ks=Ns(),Ms=Tn(),jt=class i extends Error{constructor(e,t,r,n,s,o){super(e),this.name="CssSyntaxError",this.reason=e,s&&(this.file=s),n&&(this.source=n),o&&(this.plugin=o),typeof t<"u"&&typeof r<"u"&&(typeof t=="number"?(this.line=t,this.column=r):(this.line=t.line,this.column=t.column,this.endLine=r.line,this.endColumn=r.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,i)}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason}showSourceCode(e){if(!this.source)return"";let t=this.source;e==null&&(e=ks.isColorSupported);let r=f=>f,n=f=>f,s=f=>f;if(e){let{bold:f,gray:_,red:p}=ks.createColors(!0);n=d=>f(p(d)),r=d=>_(d),Ms&&(s=d=>Ms(d))}let o=t.split(/\r?\n/),l=Math.max(this.line-3,0),a=Math.min(this.line+2,o.length),h=String(a).length;return o.slice(l,a).map((f,_)=>{let p=l+1+_,d=" "+(" "+p).slice(-h)+" | ";if(p===this.line){if(f.length>160){let x=20,E=typeof this.endColumn=="number"?this.endColumn:this.column,U=Math.max(0,this.column-x),Y=Math.max(this.column+x,E+x),K=f.slice(U,Y),k=r(d.replace(/\d/g," "))+f.slice(0,Math.min(this.column-1,x-1)).replace(/[^\t]/g," ");return n(">")+r(d)+s(K)+`
4
4
  `+k+n("^")}let v=r(d.replace(/\d/g," "))+f.slice(0,this.column-1).replace(/[^\t]/g," ");return n(">")+r(d)+s(f)+`