efficient-storefront-blocks 0.30.0 → 0.32.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.
- package/CHANGELOG.md +106 -0
- package/README.md +1 -1
- package/dist/chunks/EditorPreviewCheckout-UGMEXAGV.js +4 -0
- package/dist/chunks/{PreviewFooter-3TIQCTIG.js → PreviewFooter-OIGLH5ZN.js} +1 -1
- package/dist/chunks/SiteEditorProvider-2KRUHZNS.js +1 -0
- package/dist/chunks/chunk-7DTL5AL3.js +234 -0
- package/dist/chunks/{chunk-J7FJ5WNL.js → chunk-ARXXIF4I.js} +33 -33
- package/dist/chunks/chunk-GD6ZFQC7.js +1 -0
- package/dist/chunks/chunk-NEQXU52M.js +1 -0
- package/dist/chunks/chunk-QOXKQV6L.js +16 -0
- package/dist/chunks/{fitment-data-RS3KPFUJ.js → fitment-data-I2D4TVEQ.js} +1 -1
- package/dist/chunks/{render-client-6GUP7QLJ.js → render-client-PQUQUDJN.js} +1 -1
- package/dist/editor.css +1 -1
- package/dist/index.d.ts +28 -4
- package/dist/index.js +94 -36
- package/dist/words.d.ts +8 -1
- package/dist/words.js +4 -4
- package/package.json +3 -3
- package/dist/chunks/EditorPreviewCheckout-FI4OK4QQ.js +0 -4
- package/dist/chunks/SiteEditorProvider-32N5NUFO.js +0 -1
- package/dist/chunks/chunk-BPXASQLG.js +0 -234
- package/dist/chunks/chunk-FUTJ73KM.js +0 -1
- package/dist/chunks/chunk-HKXYT5YG.js +0 -16
- package/dist/chunks/chunk-K6YFJAQ7.js +0 -1
- /package/dist/chunks/{SectionEditorShell-KZ3O54XM.js → SectionEditorShell-V4Y5R3W6.js} +0 -0
- /package/dist/chunks/{chunk-J7FJ5WNL.js.LEGAL.txt → chunk-ARXXIF4I.js.LEGAL.txt} +0 -0
- /package/dist/chunks/{chunk-VPJVU5VD.js → chunk-IKG5YKP7.js} +0 -0
- /package/dist/chunks/{chunk-HKXYT5YG.js.LEGAL.txt → chunk-QOXKQV6L.js.LEGAL.txt} +0 -0
- /package/dist/chunks/{chunk-WHY2JZ46.js → chunk-VBQY6H55.js} +0 -0
|
@@ -0,0 +1,234 @@
|
|
|
1
|
+
import{$a as $r,$e as Fe,$h as eo,Be as _i,Da as bt,De as Oi,Ee as Hi,Fa as jt,Gb as Ii,Gg as ta,Ha as Ge,Hb as Ei,He as Qt,I as yr,Ia as zr,Ja as wt,Jf as Xn,K as Mt,Ka as qt,Kg as na,L as br,Lc as ae,Lf as Wi,Lg as oa,Ma as _r,Mf as ji,Mg as ra,N as te,Nc as le,Ng as ia,O as Oe,Oa as Or,Ob as xt,Oc as Pi,Od as Ze,Og as aa,P as wr,Pc as i,Pg as sa,Ph as ua,Qa as Xe,Qc as Xt,Qg as la,R as Wn,Rc as Ri,Re as Mi,Rh as Zn,Sa as $t,Sc as Ai,Se as Bi,Sg as ca,Sh as Jn,T as $e,Ta as Gt,Tc as Li,Th as Pe,U as xr,Ua as Hr,Ub as vt,Ug as da,Uh as fa,Va as Mr,Vc as Ne,Vf as qi,Wa as Br,Wg as pa,Xa as Wr,Y as vr,Ya as Kt,Yc as Ni,Ye as en,Yh as Qn,Za as jr,Zh as ma,_a as qr,ab as Ee,ad as rt,ai as to,bb as be,bi as no,ci as oo,db as Gr,dc as Yn,dg as $i,di as ga,e as mr,ei as ya,fb as Kr,fe as De,fi as ba,g as Bn,gb as Ur,gi as wa,hb as Vr,j as gt,ja as Sr,jg as Ki,ji as xa,ka as Te,kb as Yr,ki as va,l as yt,li as Sa,ma as kr,mb as Xr,md as Di,me as zi,mg as tn,mi as Ca,na as Cr,nb as Zr,ne as Jt,ni as Ta,o as gr,oa as Tr,ob as Jr,pa as Ir,pb as Qr,pg as St,pi as Ia,qa as Er,qb as Ut,rb as ei,rg as Yi,sa as Ye,sg as kt,ta as nt,tb as qn,ua as Pr,ub as Vt,ug as Xi,ui as Ea,vb as ti,vd as Fi,vh as ha,vi as Pa,wb as ni,wg as Zi,xg as Ji,yg as Qi,za as Fr,zd as Zt,zg as ea,zi as nn}from"./chunk-QOXKQV6L.js";import{$ as ui,A as ri,Aa as Si,B as ii,Ba as ki,C as ai,Ca as Ci,Fa as Ti,La as ie,Ma as Gi,Oa as Ui,Pa as Vi,S as si,T as li,U as ci,V as di,Y as pi,Z as $n,_ as hi,aa as fi,d as Rr,da as mi,e as Ar,ea as Gn,f as Lr,g as Nr,h as Ie,ha as gi,i as Bt,ia as Kn,j as Wt,ka as Un,n as ot,o as jn,oa as yi,p as Dr,ta as Vn,ua as bi,wa as wi,y as Yt,ya as xi,z as oi,za as vi}from"./chunk-IKG5YKP7.js";import{q as ka}from"./chunk-VBQY6H55.js";import{jsx as ro,Fragment as yc,jsxs as bc}from"react/jsx-runtime";import{createContext as wc,useContext as xc}from"react";var vc={mirrorHostStyles:!0,css:null,fontHrefs:[]},Ra=wc(vc);function bm({value:e,children:t}){return ro(Ra.Provider,{value:e,children:t})}function io(){return xc(Ra)}function Aa(){let{css:e,fontHrefs:t}=io();return bc(yc,{children:[t.map(o=>ro("link",{rel:"stylesheet",href:o},o)),e?ro("style",{"data-sf-canvas-css":"",children:e}):null]})}import{jsx as Sc}from"react/jsx-runtime";import{createContext as kc,useContext as Cc}from"react";var La=kc(void 0);function Sm({metadata:e,children:t}){return Sc(La.Provider,{value:e,children:t})}var Na=()=>Cc(La);import{jsx as Q,jsxs as fr}from"react/jsx-runtime";import{useCallback as Hn,useEffect as Ve,useState as Yf}from"react";import{Button as Xf,Tooltip as Zf}from"efficient-shell/ui";import{SettingsSwitch as Jf}from"efficient-easel/panel";import{PagesIcon as Qf,StylesIcon as em}from"efficient-easel/rail";import{TreeRow as tm}from"efficient-easel/tree";import{useEaselStrings as nm}from"efficient-easel/strings";import{jsx as B,Fragment as Bo,jsxs as ht}from"react/jsx-runtime";import{Fragment as gh,useEffect as yh,useId as bh,useMemo as Es,useState as pt}from"react";import{default as on,PanelHideButton as ao,PanelModeExit as Tm,PanelShowStrip as Im}from"efficient-easel/screen/components/SidePanelHead";import{jsx as j,jsxs as ct,Fragment as Rt}from"react/jsx-runtime";import{useEasel as zo}from"efficient-easel/easel";import{useEffect as zp,useRef as vs,useState as Cn}from"react";import{jsx as Ke,jsxs as _a,Fragment as Pc}from"react/jsx-runtime";import{useState as Oa}from"react";import{SettingsDefaultReset as Rc,SettingsField as Ac}from"efficient-easel/panel";import{useEaselStrings as Lc}from"efficient-easel/strings";import{jsx as rn,Fragment as Tc,jsxs as Da}from"react/jsx-runtime";import{Button as Fa,Dialog as Ic}from"efficient-shell/ui";function Ec(e){return Xt("This site has {n} color theme of its own. Clearing takes them away and puts back the four the shop supplies.","This site has {n} color themes of its own. Clearing takes them away and puts back the four the shop supplies.",e)}function za({count:e,onCancel:t,onConfirm:o}){return Da(Ic,{open:!0,onClose:t,role:"alertdialog",size:"sm",title:i("Clear this site\u2019s colors?"),footer:Da(Tc,{children:[rn(Fa,{variant:"secondary",onClick:t,children:i("Cancel")}),rn(Fa,{variant:"danger",onClick:o,children:i("Clear colors")})]}),children:[rn("p",{children:Ec(e)}),rn("p",{className:"mt-2 font-medium",children:i("This cannot be undone.")})]})}var Nc=Oi("the row's whole content is an action; the gutter names a subject and this row has none \u2014 the button's label is the name GG, 2026-09-23");function Dc(){return Ke("svg",{width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",children:Ke("path",{d:"M12 5v14M5 12h14"})})}var Fc="Reset color",zc={selected:0,themes:[]};function _c(e){e(zc)}function Ha({value:e,onChange:t}){let o=e?.themes??[],a=o.length===0,s=Yt(e),[l,d]=Oa(!1),c=Lc(),[h,g]=Oa(null),f=(v,k)=>{t({...s,themes:s.themes.map((u,y)=>y===v?k:u)})},x=ii(s).accent,E=new Set(s.themes.map(v=>v.brandInk).filter(Boolean)),C=oi.filter(v=>!E.has(v)).map(v=>ri(x,v)),A=[...s.themes,...C],P=v=>{if(v<s.themes.length)return t({...s,selected:v});let k=[...s.themes,A[v]];t({...s,themes:k,selected:k.length-1})},b=()=>{let v=[...s.themes,{...ai(s.themes[s.selected])}];t({...s,themes:v,selected:v.length-1}),g(v.length-1)};return _a(Pc,{children:[a?null:Ke(Ac,{label:i(Fc),icon:Hi(Nc),labelId:"sf-theme-reset",action:Ke(Rc,{label:i("all theme colors"),words:c.panel,changed:!0,onReset:()=>d(!0)})}),l&&Ke(za,{count:o.length,onCancel:()=>d(!1),onConfirm:()=>{d(!1),_c(t)}}),Ke("div",{className:"sf-theme-list",role:"radiogroup","aria-label":i("Theme"),children:A.map((v,k)=>Ke(Li,{index:k,colors:v,selected:k===s.selected,open:h===k&&k<s.themes.length,editable:k<s.themes.length,onPick:()=>P(k),onEdit:()=>g(u=>u===k?null:k),onChangeColors:u=>f(k,u)},k))}),_a("button",{type:"button",onClick:b,className:"sf-theme-add",children:[Ke(Dc,{}),i("Add new theme")]})]})}import{jsx as an}from"react/jsx-runtime";import{SettingsDefaultReset as Oc,SettingsField as Hc}from"efficient-easel/panel";import{SquareIcon as Mc}from"efficient-easel/icons";var Bc="Applies to panels, cards, inputs and buttons. Round things \u2014 color swatches, switches, status dots \u2014 stay round.",so="Corners";function Ma({value:e,onChange:t,showHint:o=!0}){let a=e===null;return an(Hc,{label:i(so),icon:an(Mc,{}),value:a?void 0:`${e}px`,changed:!a,action:an(Oc,{words:le()?.panel,label:i(so),changed:!a,detail:i("the built-in corners"),onReset:()=>t(null)}),hint:o?i(Bc):void 0,children:an(Fe,{min:$n,max:hi,step:1,value:e??$n,readout:!1,ariaLabel:i(so),onChange:t})})}import{jsx as Ct}from"react/jsx-runtime";import{SettingsDefaultReset as Wc,SettingsField as jc,SettingsSegmented as qc}from"efficient-easel/panel";import{ShadowIcon as $c}from"efficient-easel/icons";var lo={none:"None",soft:"Soft",lifted:"Lifted"},Gc="Applies to cards \u2014 products, brands, journal entries and filter cells. Round things like swatches and status dots are never shadowed.",Kc={none:"none",soft:"0 1px 1px rgba(20, 20, 22, 0.10), 0 2px 4px -1px rgba(20, 20, 22, 0.14)",lifted:"0 1px 2px rgba(20, 20, 22, 0.10), 0 4px 7px -2px rgba(20, 20, 22, 0.30)"},Uc={labelsPx:90.25,widestLabelPx:34.6};function Ba({value:e,onChange:t,showHint:o=!0}){let a=e===null,s=e??Gn;return Ct(jc,{label:i("Card shadow"),icon:Ct($c,{}),value:i(lo[s]),changed:!a,action:Ct(Wc,{words:le()?.panel,label:i("Card shadow"),changed:!a,detail:i(lo[Gn]),onReset:()=>t(null)}),hint:o?i(Gc):void 0,children:Ct(qc,{options:mi.map(l=>({id:l,label:i(lo[l]),icon:Ct("span",{className:"sf-shadow-chip",style:{boxShadow:Kc[l]}})})),value:s,ariaLabel:i("Card shadow"),fit:Uc,onChange:t})})}import{jsx as co}from"react/jsx-runtime";import{SettingsDefaultReset as Vc,SettingsField as Yc}from"efficient-easel/panel";import{ShadowIcon as Xc}from"efficient-easel/icons";var Zc="Most useful on a dark theme, where a black shadow cannot be seen. Also used by the Lift hover, even with the card shadow off.";function Wa({value:e,onChange:t,showHint:o=!0}){let a=e===null;return co(Yc,{label:i("Shadow color"),icon:co(Xc,{}),changed:!a,action:Ri({value:e??"",inherited:a?Un:void 0,onChange:t,label:"Shadow color",after:co(Vc,{words:le()?.panel,label:i("Shadow color"),changed:!a,detail:Un,onReset:()=>t(null)})}),hint:o?i(Zc):void 0})}import{jsx as sn}from"react/jsx-runtime";import{SettingsDefaultReset as Jc,SettingsField as Qc}from"efficient-easel/panel";import{AlignSeparateIcon as ed}from"efficient-easel/icons";var td="The space between the blocks inside a row, a grid or a box. Default means each one keeps the spacing it already has.",po="Block gap",nd=zi.Grid;function ja({value:e,onChange:t,showHint:o=!0}){let a=e===null;return sn(Qc,{label:i(po),labelId:"sf-block-gap",icon:sn(ed,{}),value:a?void 0:`${e}px`,changed:!a,action:sn(Jc,{words:le()?.panel,label:i(po),changed:!a,detail:i("each block's own spacing"),onReset:()=>t(null)}),hint:o?i(td):void 0,children:sn(Fe,{min:Jt.min,max:Jt.max,step:Jt.step,value:a?nd:e,readout:!1,ariaLabel:i(po),onChange:t})})}import{jsx as ln}from"react/jsx-runtime";import{SettingsDefaultReset as od,SettingsField as rd,SettingsSegmented as id}from"efficient-easel/panel";import{HoverIcon as ad}from"efficient-easel/icons";var ho={none:"None",lift:"Lift",highlight:"Highlight"},sd="What a card does when a shopper points at it \u2014 or taps it, on a phone. Highlight is the effect your cards already use.";function qa({value:e,onChange:t,showHint:o=!0}){let a=e===null,s=e??Kn;return ln(rd,{label:i("Hover effect"),icon:ln(ad,{}),value:i(ho[s]),changed:!a,action:ln(od,{words:le()?.panel,label:i("Hover effect"),changed:!a,detail:i(ho[Kn]),onReset:()=>t(null)}),hint:o?i(sd):void 0,children:ln(id,{options:gi.map(l=>({id:l,label:i(ho[l])})),value:s,ariaLabel:i("Hover effect"),onChange:t})})}import{jsx as cn}from"react/jsx-runtime";import{SettingsDefaultReset as ld,SettingsField as cd,SettingsSegmented as dd}from"efficient-easel/panel";import{ImageIcon as pd}from"efficient-easel/icons";var uo="Hero image",fo=[{followsWidth:!1,label:Yn.full},{followsWidth:!0,label:Yn.page}],hd="Whether the big picture at the top of a page runs edge to edge, or sits inside the page width. The words follow the page width either way.";function $a({value:e,onChange:t,showHint:o=!0}){let a=e===null,s=e??!1;return cn(cd,{label:i(uo),icon:cn(pd,{}),value:i(fo.find(l=>l.followsWidth===s).label),changed:!a,action:cn(ld,{words:le()?.panel,label:i(uo),changed:!a,detail:i(fo.find(l=>!l.followsWidth).label),onReset:()=>t(null)}),hint:o?i(hd):void 0,children:cn(dd,{options:fo.map(l=>({id:l.followsWidth,label:i(l.label)})),value:s,ariaLabel:i(uo),onChange:t})})}import{jsx as dn}from"react/jsx-runtime";import{SettingsDefaultReset as ud,SettingsField as fd,SettingsSegmented as md}from"efficient-easel/panel";import{DropIcon as gd}from"efficient-easel/icons";var mo="Photography",Ga={shot:"As shot",mono:"Black and white"},go=[{grayscale:!1,label:Ga.shot},{grayscale:!0,label:Ga.mono}],yd="Black and white photographs return to color on hover. Wheels and tyres keep their real finish either way.";function Ka({value:e,onChange:t,showHint:o=!0}){let a=e===null,s=e??!1;return dn(fd,{label:i(mo),icon:dn(gd,{}),value:i(go.find(l=>l.grayscale===s).label),changed:!a,action:dn(ud,{words:le()?.panel,label:i(mo),changed:!a,detail:i(go.find(l=>!l.grayscale).label),onReset:()=>t(null)}),hint:o?i(yd):void 0,children:dn(md,{options:go.map(l=>({id:l.grayscale,label:i(l.label)})),value:s,ariaLabel:i(mo),onChange:t})})}import{jsx as pn}from"react/jsx-runtime";import{SettingsDefaultReset as bd,SettingsField as wd}from"efficient-easel/panel";import{PaddingXIcon as xd}from"efficient-easel/icons";var yo="Side space",bo=vt.default,vd="The room left at the left and right edge of every page.";function Ua({value:e,onChange:t,showHint:o=!0}){let a=e===null;return pn(wd,{label:i(yo),labelId:"sf-side-space",icon:pn(xd,{}),value:`${e??bo}px`,changed:!a,action:pn(bd,{words:le()?.panel,label:i(yo),changed:!a,detail:`${bo}px`,onReset:()=>t(null)}),hint:o?i(vd):void 0,children:pn(Fe,{min:vt.min,max:vt.max,step:vt.step,value:e??bo,readout:!1,ariaLabel:i(yo),onChange:t})})}import{jsx as hn}from"react/jsx-runtime";import{SettingsDefaultReset as Sd,SettingsField as kd}from"efficient-easel/panel";import{WidthIcon as Cd}from"efficient-easel/icons";var wo="Content width",xo=xt.default,Td="The standard width every page on this site renders at.";function Va({value:e,onChange:t,showHint:o=!0}){let a=e===null;return hn(kd,{label:i(wo),labelId:"sf-site-width",icon:hn(Cd,{}),value:`${e??xo}px`,changed:!a,action:hn(Sd,{words:le()?.panel,label:i(wo),changed:!a,detail:`${xo}px`,onReset:()=>t(null)}),hint:o?i(Td):void 0,children:hn(Fe,{min:xt.min,max:xt.max,step:xt.step,value:e??xo,readout:!1,ariaLabel:i(wo),onChange:t})})}import{jsx as z,jsxs as vn,Fragment as Lo}from"react/jsx-runtime";import{FieldSelect as hp}from"efficient-easel/fields";import{SettingsField as Sn}from"efficient-easel/panel";import{Tooltip as us}from"efficient-shell/ui";import{AccentIcon as up,CaseIcon as fp,StylesIcon as mp,TextLinesIcon as ms,TextSizeIcon as Pt,TextSmallIcon as gp,TypeIcon as yp,WeightIcon as bp}from"efficient-easel/icons";import{jsx as I,jsxs as ne,Fragment as It}from"react/jsx-runtime";import{useEffect as bn,useId as jd,useRef as Eo,useState as Po}from"react";import{jsx as it,jsxs as Ya}from"react/jsx-runtime";import{Tooltip as Id}from"efficient-shell/ui";function Je({label:e,onClear:t,what:o="override"}){let a=i(e),s=o==="override"?i("Clear override"):o==="change"?i("Clear change"):i("Clear {what}",{what:o}),l=o==="override"?i("Clear override: {label}",{label:a}):o==="change"?i("Clear change: {label}",{label:a}):i("Clear {what}: {label}",{what:o,label:a});return it(Id,{content:s,children:it("button",{type:"button",className:"sf-part-mark","aria-label":l,onClick:t,children:it(Ed,{})})})}function Ed(){return Ya("svg",{width:"12",height:"12",viewBox:"0 0 16 16","aria-hidden":"true",children:[it("circle",{className:"sf-part-mark-dot",cx:"8",cy:"8",r:"3",fill:"currentColor"}),Ya("g",{className:"sf-part-mark-arrow",fill:"none",stroke:"currentColor",strokeWidth:1.8,strokeLinecap:"round",children:[it("path",{d:"M13 8a5 5 0 1 1-1.6-3.7"}),it("path",{d:"M13 2.5V5h-2.6"})]})]})}import{FieldSelect as ss,InspectorField as qd}from"efficient-easel/fields";import{SettingsField as ls,SettingsGroup as $d}from"efficient-easel/panel";import{InspectorUpLevel as wn}from"efficient-easel/chrome";import{StylesIcon as Gd,TextColorIcon as Kd,TypeIcon as cs}from"efficient-easel/icons";import{useEasel as Ud}from"efficient-easel/easel";import{Tooltip as Vd}from"efficient-shell/ui";import{jsx as un,jsxs as vo}from"react/jsx-runtime";import{ColorSwatch as Pd,Tooltip as Rd}from"efficient-shell/ui";function Xa({value:e,label:t,colors:o,onChange:a}){let s=e===null,l=e||void 0,d=o.find(h=>h.key===l),c=d?d.value:l&&/^#[0-9a-f]{6}$/i.test(l)?l:void 0;return vo("div",{className:"sf-part-ink",children:[vo("div",{className:"sf-part-ink-top",children:[un("span",{className:"sf-part-ink-label",children:i(t)}),un("span",{className:"sf-part-ink-read",children:c?c.toUpperCase():s?i("Mixed"):i("Follows the style")})]}),vo("div",{className:"sf-part-ink-swatches",role:"group","aria-label":i(t),children:[o.map(h=>un(Rd,{content:`${i(h.name)} \xB7 ${h.value.toUpperCase()}`,children:un(Pd,{color:h.value,"aria-label":i(h.name),size:"sm",selected:l===h.key,onClick:()=>a(l===h.key?null:h.key)})},h.key)),Ai({value:d?"":(c??"").toLowerCase(),label:"Any color",onChange:a})]})]})}import{jsx as Io,jsxs as _d}from"react/jsx-runtime";import{COPY_CELLS as mn,CopyBox as Od}from"efficient-easel/copy";import{PaddingYIcon as Hd,WidthIcon as Md}from"efficient-easel/icons";import{useSyncExternalStore as Ad}from"react";function at(e,t){let o=Br(e);return o?.control==="textList"?t.rowKey===(o.itemKey??"text")?ji(o,t.index):null:Wr(e)?.[t.rowKey]??null}function fn(e,t,o){let a=e.node.props,{key:s,row:l}=Ge(e.propKey),d=l?qr(a,s,l,e.kind,t):Mr(a,s,e.kind,t);return d?(o(e.zone,e.index,{...e.node,props:d}),!0):!1}var Ld=["bold","italic","underline","strike","link","sup","sub"],Nd=["bullet","number"];function Co(e,t){return e?[...Ld,...t?Nd:[]]:[]}function Za(e,t){let o=zr(e);if(!o?.propKey)return null;let{nodeId:a,propKey:s}=o,l=t.getItemById(a),d=t.getSelectorForId(a);if(!l||!d)return null;let{key:c,row:h}=Ge(s),g=t.components[l.type]?.fields?.[c],f=h?at(g,h):g,x=$t(f);if(!x)return null;let E=l.props??{};if(h&&!(Array.isArray(E[c])&&h.index<E[c].length))return null;let C=h?Kt(E[c],h):E[c];return{node:l,selector:d,propKey:s,kind:x,stored:C,offPage:Qt(f)}}function Ja(e,t){let o=Za(e,t);if(!o||o.offPage)return null;let{text:a,hidden:s}=Xe(o.stored);if(s)return null;let l=Gt(o.kind);return{partId:e,value:a,rules:qt,multiline:l,offered:Co(o.kind!=="plainText",l),write:d=>{let c=Za(e,t);c&&fn({node:c.node,propKey:c.propKey,kind:c.kind,zone:c.selector.zone,index:c.selector.index},d,t.replace)}}}function Qa(e,t,o){return e?.isConnected&&e.getAttribute(Ee)===o?e:t?.querySelector(`[${Ee}="${Dd(o)}"]`)??null}function Dd(e){return e.replace(/["\\]/g,"\\$&")}function es(e){let t=e.activeElement;return t?t.tagName==="IFRAME"||!!t.closest(".es-canvas"):!1}var So=null,ko=new Set;function Fd(){return So}function To(e){if(e!==So){So=e;for(let t of ko)t()}}function zd(e){return ko.add(e),()=>{ko.delete(e)}}function ts(){return Ad(zd,Fd,()=>null)}var Bd=["left","center","right","justify"];function ns({text:e,onTextChange:t,multiline:o,markup:a=!0,styled:s=!0,style:l,base:d,setValue:c,colors:h,placeholder:g,ariaLabel:f,head:x,typedOnCanvas:E=!1}){let C=ni(l),A=l.size??d.sizePx,P=[{...mn.fontSize,value:l.size,styleValue:Math.round(d.sizePx),onChange:v=>c({size:v??null})},{...mn.lineHeight,value:C.lineHeight,styleValue:d.lineRatio,onChange:v=>c(v===void 0?{lineHeight:null,line:null}:{lineHeight:v})},{...mn.letterSpacing,scale:A,value:C.letterSpacingEm,styleValue:d.letterEm,onChange:v=>c(v===void 0?{letterSpacing:null,letter:null}:{letterSpacing:v})},{...mn.paragraphSpacing,value:l.paragraphSpacing,styleValue:0,onChange:v=>c({paragraphSpacing:v??null})},{key:"padding",name:i("Padding"),icon:Io(Hd,{}),unit:"px",step:Jr,shiftStep:10,min:Xr,max:Zr,value:l.padding,styleValue:d.paddingPx,onChange:v=>c({padding:v??null})},{key:"width",name:i("Width"),icon:Io(Md,{}),unit:"px",step:ei,shiftStep:100,min:Qr,max:Ut,value:l.width,styleValue:d.widthPx,onChange:v=>c({width:v??null})}],b=Co(a,o);return _d("div",{className:"sf-part-textbox",children:[x,Io(Od,{value:e,onChange:t,multiline:o,placeholder:g,ariaLabel:f,rules:qt,tools:b,barShows:E?"focus":"always",colors:a?h:[],align:s?{value:l.align??d.align,allow:Bd,onChange:v=>c({align:v})}:void 0,letterCase:s?{value:l.case??"",onChange:v=>c({case:v||null})}:void 0,cells:s?P:void 0})]})}var Wd={CollectionCard:"product",FooterMenu:"menu",Gallery:"product",GalleryItem:"product",ProductGrid:"product",ProductHero:"product",SpecTable:"product",Events:"blog",FeaturedCover:"blog",LongRead:"blog",SubscribeBlogs:"blog"},os={product:"Synced from the product.",blog:"Synced from the blog post.",menu:"Synced from the site menu."},rs="Open",is={product:{type:"storefront-editor:open-product",needsSlug:!0},blog:{type:"storefront-editor:open-post",needsSlug:!0},menu:{type:"storefront-editor:open-menus",needsSlug:!1}};function Tt(e){let t=e?.source?.slug;return typeof t=="string"&&t.length>0?t:void 0}function gn(e){return Wd[e]??null}var Yd={400:"Regular",500:"Medium",600:"Semibold",700:"Bold"},ds=[{key:"font",label:"Font",group:"Style"},{key:"color",label:"Color",group:"Style"}],Xd=[...new Set(ds.map(e=>e.group))],Zd={font:I(cs,{}),color:I(Kd,{})};function Et(e){return e?i(e):null}function Qe(e){return e.kind==="role"?Wt[e.role]:e.kind==="custom"?"Custom":null}var Jd=e=>e.kind==="role"?`role:${e.role}`:e.kind;function Qd(e){let t=e.role;return t&&Bt.includes(t)?{kind:"role",role:t}:null}function ep(e,t){if(!e)return{kind:"unread"};let{faceRole:o,base:a}=e;if(t[o]===a.fontKey)return{kind:"role",role:o};let s=Object.keys(t).filter(l=>t[l]===a.fontKey);return s.length===1?{kind:"role",role:s[0]}:{kind:"custom"}}function Ro(e,t,o,a){return Qd(qn(e,t))??ep(o,a)}function ps(e,t,o,a){return Qe(Ro(e,t,o,a))}function Ao(e,t){if(!e.length)return null;let o=t(e[0]);return e.every(a=>t(a)===o)?o:null}function tp(e){return Object.values(e).filter(t=>t!==void 0).length}function np(e,t){let o=e.style[t];return t==="color"?o??"":o!==void 0?String(o):e.base.fontKey}function op({face:e,base:t,onPick:o}){let[a,s]=Po(!1),l=Eo(null),d=Eo(null),c=jd();bn(()=>{if(!a)return;let f=x=>{l.current&&!l.current.contains(x.target)&&s(!1)};return document.addEventListener("mousedown",f),()=>document.removeEventListener("mousedown",f)},[a]);let h=e.kind==="role"?e.role:null,g=f=>{o(f),s(!1),d.current?.focus()};return ne("div",{className:"sf-part-style-pick",ref:l,children:[ne("button",{ref:d,type:"button",className:"sf-part-style-trigger","aria-expanded":a,"aria-controls":c,"aria-label":Qe(e)?i("Follows {name} \u2014 change",{name:Et(Qe(e))}):i("Follows no style \u2014 change"),onClick:()=>s(f=>!f),onKeyDown:f=>{f.key==="Escape"&&a&&(f.preventDefault(),s(!1))},children:[I("span",{className:"sf-part-style-name",style:{fontFamily:t?.fontKey?`var(${Ie(t.fontKey)?.cssVar})`:void 0,fontWeight:t?.weight},children:Et(Qe(e))}),I("span",{className:"sf-part-style-sign","aria-hidden":"true"})]}),a&&ne("div",{className:"sf-multi-menu sf-part-style-menu",id:c,role:"listbox",onKeyDown:f=>{f.key==="Escape"&&(f.preventDefault(),s(!1),d.current?.focus())},children:[ne("button",{type:"button",role:"option","aria-selected":h===null,className:`sf-part-style-option${h===null?" is-on":""}`,onClick:()=>g(null),children:[I("span",{className:"sf-part-style-option-name",children:i("No style")}),I("span",{className:"sf-note",children:i("Section\u2019s own")})]}),Bt.map(f=>I("button",{type:"button",role:"option","aria-selected":h===f,className:`sf-part-style-option${h===f?" is-on":""}`,onClick:()=>g(f),children:I("span",{className:"sf-part-style-option-name",style:{fontFamily:`var(--font-role-${f})`},children:i(Wt[f])})},f))]})]})}var yn="";function rp({face:e,base:t,onPick:o}){let a=e.kind==="role"?e.role:yn,s=[{label:i("No style"),value:yn},...Bt.map(l=>({label:i(Wt[l]),value:l}))];return I(ss,{ariaLabel:i("Style"),value:a,options:s,inline:!0,onChange:l=>o(l===yn?null:l),renderOption:l=>l.value===yn?ne(It,{children:[I("span",{className:"es-fsel-label sf-part-style-keep",children:l.label}),I("span",{className:"sf-part-style-aside","aria-hidden":"true",children:i("Section\u2019s own")})]}):I("span",{className:"es-fsel-label",style:{fontFamily:`var(--font-role-${l.value})`},children:l.label}),renderValue:()=>I("span",{style:{fontFamily:t?.fontKey?`var(${Ie(t.fontKey)?.cssVar})`:void 0,fontWeight:t?.weight},children:Et(Qe(e))}),valueText:l=>Et(Qe(e))??l?.label??""})}function ip({parts:e,onEditStyle:t,onClearAll:o,onFollowStyle:a,kindLabel:s}){let l=Ao(e,f=>Jd(f.face))?e[0].face:null,d=l?Qe(l):null,c=l&&l.kind!=="unread"?e[0].base:null,h=e.reduce((f,x)=>f+tp(x.style),0),g=c?Ie(c.fontKey)?.label:void 0;return ne("div",{className:`sf-part-style${h?" has-overrides":""}`,children:[I("div",{className:"sf-part-style-caption",children:i("Style")}),e.length>1&&I("div",{className:"sf-part-style-count",children:i("{n} selected",{n:e.length})}),e.length===1&&s&&I("div",{className:"sf-part-style-count",children:i("{kind} \xB7 every row",{kind:i(s)})}),d&&c?ne(It,{children:[a&&l?I(op,{face:l,base:c,onPick:a}):I("div",{className:"sf-part-style-name",style:{fontFamily:g?`var(${Ie(c.fontKey)?.cssVar})`:void 0,fontWeight:c.weight},children:i(d)}),I("div",{className:"sf-part-style-meta",children:[g,`${Math.round(c.sizePx)} px`,i(Yd[c.weight])].filter(Boolean).join(" \xB7 ")})]}):I("div",{className:"sf-part-style-name",children:i("Mixed styles")}),ne("div",{className:"sf-part-style-top",children:[d?h?ne(It,{children:[I("span",{className:"sf-part-chip",children:i("{n} changed",{n:h})}),I("button",{type:"button",className:"sf-part-link",onClick:o,children:i("Clear")})]}):I("span",{className:"sf-part-style-state",children:i("This text follows the site style.")}):I("span",{className:"sf-part-style-state",children:i("Changes apply to all selected.")}),I("span",{className:"sf-part-style-gap"}),d&&t&&I("button",{type:"button",className:"sf-part-link",onClick:t,children:i("Edit")})]})]})}function ap({sectionName:e,onBack:t,textEditor:o,styleRow:a,children:s}){return ne("div",{className:"sf-part-panel",children:[I(wn,{inline:!0,name:i(e),onSelect:t}),o,a,s]})}function xn({source:e,slug:t}){let o=Zt(),a=is[e],s=!a.needsSlug||!!t;return I("div",{className:"sf-note sf-note--source",children:ne("p",{className:"es-field-hint sf-hint-keep",children:[i(os[e]),s?ne(It,{children:[" ",I("button",{type:"button",className:"sf-source-open",onClick:()=>{a.type==="storefront-editor:open-menus"?o.send(a.type):t&&o.send(a.type,{slug:t})},children:i(rs)})]}):null]})})}var as=4,sp=120;function lp({region:e,sizePx:t,face:o,base:a,onFollowStyle:s,source:l,slug:d,onBack:c}){let h=e.follows;return ne("div",{className:"sf-note",children:[I("p",{children:I("strong",{children:i(e.label)})}),I("p",{children:t?i("Its size follows Site styles \u25B8 {follows} \u2014 {px}px right now.",{follows:i(h),px:Math.round(t)}):i("Its size follows Site styles \u25B8 {follows}.",{follows:i(h)})}),s?I(It,{children:I(ls,{label:i("Style"),icon:I(Gd,{}),hint:i("Every {part} in this section follows it. The face and the size change; the letter case is the section\u2019s own and stays as it is.",{part:i(e.label).toLowerCase()}),children:I(rp,{face:o,base:a,onPick:s})})}):I("p",{className:"es-field-hint sf-hint-keep",children:i("Only the size follows a site style. This section sets its own font, weight and letter case.")}),l?I(xn,{source:l,slug:d}):null,I(wn,{inline:!0,name:i("Page"),onSelect:c})]})}function cp({onBack:e}){return ne("div",{className:"sf-note",children:[I("p",{children:I("strong",{children:i("This part is no longer here.")})}),I("p",{children:i("The section it belonged to has been changed or removed.")}),I(wn,{inline:!0,name:i("Page"),onSelect:e})]})}function dp({onBack:e,partId:t,why:o}){return ne("div",{className:"sf-note",children:[I("p",{children:I("strong",{children:i("This part's settings did not open.")})}),I("p",{children:i("The words are still on your page and nothing has been lost. The editor could not work out which control belongs to them, which is a fault on our side. Go back and click the section to open its settings instead.")}),I("p",{className:"sf-note-detail",children:ne("code",{children:[t," \u2014 ",o]})}),I(wn,{inline:!0,name:i("Page"),onSelect:e})]})}function hs({nodeId:e,propKey:t,onBack:o,onEditStyle:a}){let{getItemById:s,getSelectorForId:l,config:d}=Ud(L=>L),c=rt(),h=ts(),{partStyle:g}=jt(),{fonts:f}=ie(),[x,E]=Po({}),C=Eo(null),A=s(e),P=l(e),b=A?d.components[A.type]:void 0,{key:v,row:k}=Ge(t),u=b?.fields?.[v],y=k?at(u,k):u,N=wt(e,t),w=A?.props??{},F=$t(y),_=Qt(y),ge=Kr(y),V=A?gn(A.type):null,M=k?Kt(w[v],k):w[v],X=!!k&&!(Array.isArray(w[v])&&k.index<w[v].length);bn(()=>{es(document)||C.current?.querySelector(".es-copy [contenteditable='true'], .es-copy textarea, .sf-copybox textarea, .sf-copybox input")?.focus()},[N]);let[de,D]=Po(0);bn(()=>D(0),[N]);let ee=!!A&&!X&&(!P||!y);bn(()=>{if(!ee||de>=as)return;let L=setTimeout(()=>D(Z=>Z+1),sp);return()=>clearTimeout(L)},[ee,de]);let Ae=ee&&de<as;if(!A||X)return I(cp,{onBack:o});let we=na(A.type),Be=we?ta(we,t):null;if(we&&Be){let L=g?.partId===N?g:null,Z=we[Be],ve=Z.writable===!0&&!!P,Se=ue=>{P&&c.replaceComponent(P.zone,P.index,{...A,props:Vt(w,t,"role",ue)})};return I(lp,{region:Z,sizePx:L?.base.sizePx??null,face:Ro(w,t,L,f),base:L?.base??null,onFollowStyle:ve?Se:void 0,source:V,slug:Tt(w),onBack:o})}if(!P||!y)return Ae?I("div",{className:"sf-note","aria-busy":"true"}):I(dp,{onBack:o,partId:N,why:P?"no field":"no selector"});let xe=L=>{c.replaceComponent(P.zone,P.index,{...A,props:L})},Ce=L=>{if(Xe(L).hidden!==Xe(M).hidden||!F){let Z=k?jr(w,v,k,L):{...w,[v]:L};Z&&xe(Z);return}fn({node:A,propKey:t,kind:F,zone:P.zone,index:P.index},Xe(L).text,c.replaceComponent)},We=M,ye=Ei(A?.type,t),fe=qn(w,ye),J=g?.partId===N?g:null,G=[{partKey:ye,face:Ro(w,ye,J,f),sizeGroup:J?.sizeGroup??null,base:J?.base??pp,style:fe}],_e=Ao(G,L=>L.sizeGroup),S=Fr(J?.inks),q=(L,Z)=>{let ve=w;for(let Se of G)ve=Vt(ve,Se.partKey,L,Z);xe(ve)},$=L=>q("role",L),pe=()=>{let L=w;for(let Z of G)L=ti(L,Z.partKey);xe(L)},he=L=>{let Z=w;for(let ve of G)for(let[Se,ue]of Object.entries(L))Z=Vt(Z,ve.partKey,Se,ue??null);xe(Z)},je=(L,Z)=>{let ve=G.some(Le=>Le.style[L]!==void 0),Se=Ao(G,Le=>np(Le,L)),ue=Se===null,tt=`sf-part-${e}-${t}-${L}`;return L==="color"?I(Xa,{value:ue?null:String(Se),label:Z,colors:S,onChange:Le=>q("color",Le)},L):I(ls,{label:i(Z),icon:Zd[L],className:"sf-part-field",changed:ve,htmlFor:tt,action:ve?I(Je,{label:Z,onClear:()=>q(L,null)}):void 0,children:L==="font"?I(ss,{id:tt,ariaLabel:i(Z),value:!ue&&Ie(String(Se))?String(Se):void 0,placeholder:ue?i("Mixed"):i("Site style"),options:Rr.map(Le=>({label:Le.label,value:Le.key})),onChange:Le=>q("font",Le||null)}):null},L)},oe=F==="text"||F==="textarea",{text:re,hidden:me}=Xe(M),qe=y?.[Or]?.label??t,Ht=me?i("Show {label} on the slide",{label:i(qe)}):i("Hide {label} on the slide",{label:i(qe)}),gc=ne("div",{className:"sf-field-head",children:[I(cs,{}),I("span",{className:"sf-field-label sf-field-label--inline",children:i(qe)}),oe&&I(Vd,{content:Ht,children:I("button",{type:"button",className:"sf-field-eye","aria-pressed":me,"aria-label":Ht,onClick:()=>Ce({text:re,hidden:!me}),children:me?I(De,{name:"eye-off",size:14}):I(De,{name:"eye",size:14})})})]}),Mn=!_&≥return ne(ap,{sectionName:b?.label??A.type,onBack:o,textEditor:ne("div",{ref:C,className:"sf-part-text",children:[F?I(ns,{text:re,onTextChange:L=>Ce(oe?{text:L,hidden:me}:L),multiline:Gt(F),markup:F!=="plainText",styled:Mn,style:G[0].style,base:G[0].base,setValue:he,colors:S.map(L=>({name:L.key,label:i(L.name),value:L.value})),placeholder:Et(Hr(y))??void 0,ariaLabel:i(qe),head:gc,typedOnCanvas:h===N}):I(qd,{field:y,name:t,value:We,onChange:Ce,id:`sf-part-${e}-${t}`}),Mn&&F&&_e===null&&I("p",{className:"es-field-hint sf-hint-keep",children:i("Fixed size \u2014 the site\u2019s Text setting doesn\u2019t resize this.")})]}),children:[V&&I(xn,{source:V,slug:Tt(w)}),Mn&&Xd.map(L=>{let Z=ds.filter(ue=>ue.group===L),ve=Z.filter(ue=>G.some(tt=>tt.style[ue.key]!==void 0)).length,Se=`sf-part-g-${e}-${t}-${L.replace(/\W+/g,"-")}`;return ne($d,{id:Se,title:i(L),open:x[L]!==!0,onToggle:ue=>E(tt=>({...tt,[L]:!ue})),count:ve,children:[I(ip,{parts:G,onEditStyle:a,onClearAll:pe,onFollowStyle:$,kindLabel:Ii[ye]}),Z.map(ue=>je(ue.key,ue.label))]},L)})]})}var pp={fontKey:"",sizePx:16,weight:400,lineRatio:1.4,letterEm:0,align:"left",case:"none",paddingPx:0,widthPx:Ut};var wp=[{role:"heading",title:"Heading 1",group:"heading",step:"headingLarge",base:17,icon:z(Pt,{})},{role:"heading2",title:"Heading 2",group:"heading",step:"headingMedium",base:15,icon:z(Pt,{})},{role:"heading3",title:"Heading 3",group:"heading",step:"headingSmall",base:13,icon:z(Pt,{})},{role:"accent",title:"Accent",step:"accent",base:15,icon:z(up,{})},{role:"body",title:"Body",group:"body",step:"body",base:14,icon:z(ms,{})},{role:"label",title:"Labels",group:"label",step:"label",base:11,icon:z(gp,{})}];var xp=9,st=500,vp=100,Sp=80,kp=4,Cp=600,Tp=700,Ip=400,Ep="0.18em";function Pp({id:e,value:t,onChange:o}){let a=Lr().flatMap(([l,d])=>d.map(c=>({label:c.label,value:c.key,group:i(Ar[l])}))),s=(l,d)=>z("span",{style:{fontFamily:`var(${Ie(l)?.cssVar??"--font-body"})`},children:d});return z(hp,{id:e,value:t,onChange:o,options:a,renderOption:l=>s(l.value,l.label),renderValue:l=>l?s(l.value,l.label):null})}function Rp({label:e,icon:t,readout:o,min:a,max:s,step:l,value:d,onChange:c,action:h,hint:g}){return z(Sn,{label:i(e),icon:t,value:o,action:h,hint:g,children:z(Fe,{min:a,max:s,step:l,value:d,readout:!1,ariaLabel:i(e),onChange:c})})}function No({label:e,icon:t,value:o,fallback:a,min:s,max:l,step:d,suffix:c="",hint:h,onChange:g}){let f=o===null;return z(Rp,{label:e,icon:t,readout:f?i("Auto"):`${o}${c}`,min:s,max:l,step:d,value:f?a:o,onChange:g,action:f?null:z(Je,{label:e,what:"change",onClear:()=>g(null)}),hint:h})}function fs({label:e,icon:t,options:o,value:a,onChange:s,hint:l,action:d}){return z(Sn,{label:i(e),icon:t,value:Ap(o.find(c=>c.value===a)?.label),hint:l,action:d,children:z("div",{className:"sf-rungs",children:o.map(c=>z("button",{type:"button","aria-pressed":c.value===a,onClick:()=>s(c.value),className:`sf-rung${c.value===a?" is-active":""}`,children:i(c.label)},c.value))})})}var Ap=e=>e===void 0?void 0:i(e),Lp=[{value:"authored",label:"As designed"},{value:"sentence",label:"As typed"}],Np=[{value:"normal",label:"Normal"},{value:"tight",label:"Tight"},{value:"compressed",label:"Compressed"}];function Dp({fontKey:e,weight:t,fallbackWeight:o,onWeight:a}){let s=(t??o)>=Cp,l=Nr(e),d=Ie(e)?.label??i("This face");return z(Sn,{label:i("Style"),icon:z(mp,{}),value:s?i("Bold"):i("Normal"),hint:i("Bold is the weight above \u2014 one value, two ways to set it."),children:vn("div",{className:"sf-rungs",children:[z(us,{content:i("Bold"),className:"sf-rung-tip",children:z("button",{type:"button","aria-pressed":s,"aria-label":i("Bold"),onClick:()=>a(s?Ip:Tp),className:`sf-rung sf-rung--glyph${s?" is-active":""}`,style:{fontWeight:700},children:"B"})}),z(us,{className:"sf-rung-tip",content:l?i("Italic is not saved yet \u2014 the theme row has no column for it (card 66162.b)."):i("{face} is loaded without an italic, so it cannot be set in italic. Slanting it would deform the letters rather than style them.",{face:d}),children:z("span",{className:"sf-tip-disabled",tabIndex:0,children:z("button",{type:"button","aria-pressed":!1,"aria-label":i("Italic"),disabled:!0,className:"sf-rung sf-rung--glyph",style:{fontStyle:"italic"},children:"I"})})})]})})}function gs({fonts:e,compression:t,headingTypography:o,openRole:a,onOpenRole:s,onFontChange:l,sizes:d,onSizeChange:c,onCompressionChange:h,onHeadingTypographyChange:g,livePx:f,savedRole:x=null}){let E=b=>g({...o,...b}),C=b=>b==="accent"?"weightStrong":b==="heading2"?"weight2":b==="heading3"?"weight3":"weight",A=b=>b==="heading2"?"case2":b==="heading3"?"case3":"case",P=wi(t);return z("div",{className:"sf-style-list",children:wp.map(b=>{let v=a===b.role;return z(Fi,{styleKey:b.role,label:b.title,icon:b.icon,value:Ie(e[b.role])?.label??e[b.role],sampleStyle:Fp(b,e,o,P),open:v,onToggle:()=>s(v?null:b.role),saved:x===b.role,children:v&&vn(Lo,{children:[z(Sn,{label:i("Font"),icon:z(yp,{}),htmlFor:`sf-font-${b.role}`,action:e[b.role]===jn[b.role]?null:z(Je,{label:"Font",what:"change",onClear:()=>l(b.role,jn[b.role])}),children:z(Pp,{id:`sf-font-${b.role}`,value:e[b.role],onChange:k=>l(b.role,k)})}),b.step&&c&&z(No,{label:"Size",icon:z(Pt,{}),value:d[b.step],fallback:b.base*2,min:li,max:ci,step:di,suffix:"px",hint:d[b.step]===null?i("Auto = this style states no size, and text following it keeps the size its section drew."):i("The size a text takes when you set it to follow this style. Sections keep their own sizes."),onChange:k=>c(b.step,k)}),(ot(b.role)||b.role==="accent")&&vn(Lo,{children:[z(No,{label:"Weight",icon:z(bp,{}),value:o[C(b.role)],fallback:ot(b.role)?st:o.weight??st,min:xi,max:vi,step:vp,hint:b.role==="accent"?i("Auto = the accent phrase takes the heading's own weight."):void 0,onChange:k=>E({[C(b.role)]:k})}),z(Dp,{fontKey:e[b.role],weight:o[C(b.role)],fallbackWeight:ot(b.role)?st:o.weight??st,onWeight:k=>E({[C(b.role)]:k})})]}),ot(b.role)&&vn(Lo,{children:[z(fs,{label:"Line & text gap",icon:z(ms,{}),options:Np,value:t,onChange:h,hint:P.lineHeight===void 0?i("The built-in spacing."):i("Line gap {line} \xB7 text gap {letter}em.",{line:P.lineHeight,letter:String(P.letterSpacing)}),action:t===Vn?null:z(Je,{label:"Line & text gap",what:"change",onClear:()=>h(Vn)})}),z(fs,{label:"Capitals",icon:z(fp,{}),options:Lp,value:o[A(b.role)],onChange:k=>E({[A(b.role)]:k}),hint:i("The only setting that changes a heading's capitals."),action:o[A(b.role)]==="authored"?null:z(Je,{label:"Capitals",what:"change",onClear:()=>E({[A(b.role)]:"authored"})})}),z(No,{label:"Largest size",icon:z(Pt,{}),value:o.maxPx,fallback:Sp,min:Si,max:ki,step:kp,suffix:"px",hint:i("Caps the biggest heading on the site. Auto = each section's own."),onChange:k=>E({maxPx:k})})]})]})},b.role)})})}function Fp(e,t,o,a){let s=Math.max(xp,e.base),l={fontFamily:`var(${Ie(t[e.role])?.cssVar??"--font-body"})`,fontSize:`${s.toFixed(1)}px`,lineHeight:1.15};return ot(e.role)?(l.fontWeight=o.weight??st,l.textTransform=o.case==="sentence"?"none":"uppercase",a.letterSpacing!==void 0&&(l.letterSpacing=`${a.letterSpacing}em`)):e.role==="accent"?(l.fontWeight=o.weightStrong??o.weight??st,a.letterSpacing!==void 0&&(l.letterSpacing=`${a.letterSpacing}em`)):e.role==="label"&&(l.textTransform="uppercase",l.letterSpacing=Ep),l}import{SettingsTabs as _p}from"efficient-easel/panel";import{Tooltip as Gb,tabButtonId as Op,tabPanelId as Hp}from"efficient-shell/ui";import{ContrastIcon as Mp,NoteIcon as Bp,SettingsIcon as Wp,TypeIcon as jp}from"efficient-easel/icons";function ys(e){switch(e.status){case"saved":return null;case"failed":return{msg:i("Not saved. Try again."),tone:"error"};case"skipped":switch(e.reason){case"empty":return null;case"no-token":return{msg:i("Not saved. Reload the page."),tone:"error"};case"template":return{msg:i("Templates keep their look. Press Done."),tone:"success"}}}}import{gotoPreviewSlide as Ib,pinPreviewToBottom as bs,pinPreviewToSection as kn,previewFrame as ws,scrollPreviewToSection as xs,scrollPreviewToTop as Do}from"efficient-easel/screen/lib/puck/preview-dom";var Fo="sf-site-styles",qp="sf-site-styles-tabpanel",_o=!1,$p="Show hints";function Oo({shown:e,onChange:t}){return j("div",{className:"sf-hints",children:ct("button",{type:"button","aria-pressed":e,onClick:()=>t(!e),className:`sf-rung sf-hints-toggle${e?" is-active":""}`,children:[j(Bp,{size:13}),i($p)]})})}var Ss="text",lt=[{id:"basics",label:"Basics",icon:j(Wp,{})},{id:"theme",label:"Theme",icon:j(Mp,{})},{id:"text",label:"Text",icon:j(jp,{})}];function Gp({themeFromDocument:e,persist:t}){let{appState:o,dispatch:a}=zo(g=>g),{theme:s,setTheme:l}=ie(),d=o.data,c=d.root?.props??{},h=g=>{if(e){let f={...c,theme:g};a({type:"replaceRoot",root:{...d.root,props:f},recordHistory:!0})}else l(g);t({selected_preset:g.selected,theme_presets:g.themes})};return j(Ha,{value:e?c.theme:s,onChange:h})}function Kp(e,t){let[o,a]=Cn(null),s=vs(null),l=JSON.stringify(e),d=vs(t);return d.current=t,zp(()=>{if(s.current===null){s.current=l;return}if(s.current===l)return;s.current=l;let c=window.setTimeout(()=>a(d.current),700),h=window.setTimeout(()=>a(null),2200);return()=>{window.clearTimeout(c),window.clearTimeout(h)}},[l]),o}function Up({themeFromDocument:e,persist:t}){let{appState:o,dispatch:a}=zo(w=>w),[s,l]=Cn(null),{fonts:d,setFonts:c,sizes:h,setSizes:g,headingCompression:f,setHeadingCompression:x,headingTypography:E,setHeadingTypography:C}=ie(),A=o.data,P=A.root?.props??{},b=e?Dr(P.fonts):d,v=e?si:h,k=e?bi(P.headingCompression):f,u=e?Ci(P.headingTypography):E,y=w=>a({type:"replaceRoot",root:{...A.root,props:{...P,...w}},recordHistory:!0}),N=Kp({curFonts:b,curCompression:k,curTypography:u},s);return j(gs,{fonts:b,sizes:v,compression:k,headingTypography:u,openRole:s,onOpenRole:l,onFontChange:(w,F)=>{let _={...b,[w]:F};e?y({fonts:_}):c(_),t({heading_font:_.heading,body_font:_.body,accent_font:_.accent,label_font:_.label})},onSizeChange:e?void 0:(w,F)=>{let _={...v,[w]:F};g(_),t({heading_size_large_px:_.headingLarge,heading_size_medium_px:_.headingMedium,heading_size_small_px:_.headingSmall,accent_size_px:_.accent,body_size_px:_.body,label_size_px:_.label})},onCompressionChange:w=>{e?y({headingCompression:w}):x(w),t({heading_compression:w})},onHeadingTypographyChange:w=>{e?y({headingTypography:w}):C(w),t(Ti(w))},livePx:Yp,savedRole:N})}var Vp={heading:"main h1, main h2",heading2:"main h1, main h2",heading3:"main h1, main h2",accent:"main h1 em, main h2 em",body:"main p",label:"main .mono-eyebrow"};function Yp(e){if(typeof document>"u")return null;let t=(ws()?.contentDocument??document).querySelector(Vp[e]);if(!t)return null;let o=parseFloat(getComputedStyle(t).fontSize);return Number.isFinite(o)?o:null}function Xp({themeFromDocument:e,persist:t,showHint:o}){let{appState:a,dispatch:s}=zo(E=>E),{cornerRadiusPx:l,setCornerRadiusPx:d}=ie(),c=a.data,h=c.root?.props??{},g=h.cornerRadiusPx===void 0?ui[pi(h.cornerStyle)]:fi(h.cornerRadiusPx),f=e?g:l,x=E=>s({type:"replaceRoot",root:{...c.root,props:{...h,...E}},recordHistory:!0});return j(Ma,{value:f,onChange:E=>{e?x({cornerRadiusPx:E}):d(E),t({corner_radius_px:E})},showHint:o})}function Zp(e){return{site_width:e}}function Jp({persist:e,showHint:t}){let{siteWidth:o,setSiteWidth:a}=ie();return j(Va,{value:o,onChange:s=>{a(s),e(Zp(s),s===null)},showHint:t})}function Qp(e){return{block_gap:e}}function eh(e){return{site_gutter:e}}function th({persist:e,showHint:t}){let{siteGutter:o,setSiteGutter:a}=ie();return j(Ua,{value:o,onChange:s=>{a(s),e(eh(s),s===null)},showHint:t})}function nh({persist:e,showHint:t}){let{blockGap:o,setBlockGap:a}=ie();return j(ja,{value:o,onChange:s=>{a(s),e(Qp(s),s===null)},showHint:t})}function oh({persist:e,showHint:t}){let{heroBackgroundFollowsWidth:o,setHeroBackgroundFollowsWidth:a}=ie();return j($a,{value:o,onChange:s=>{a(s),e({hero_background_follows_width:s},!0)},showHint:t})}function rh({persist:e,showHint:t=!0}){return ct(Rt,{children:[j(Jp,{persist:e,showHint:t}),j(th,{persist:e,showHint:t}),j(nh,{persist:e,showHint:t}),j(oh,{persist:e,showHint:t})]})}function ih(e){return{card_shadow:e}}function ah(e){return e===null?{shadow_color:null}:{shadow_color:yi(e)}}function sh(e){return{hover_effect:e}}function lh({persist:e,showHint:t=!0}){let{cardShadow:o,setCardShadow:a,shadowColor:s,setShadowColor:l,hoverEffect:d,setHoverEffect:c}=ie();return ct(Rt,{children:[j(Ba,{value:o,onChange:h=>{a(h),e(ih(h),!0)},showHint:t}),j(Wa,{value:s,onChange:h=>{l(h),e(ah(h),h===null)},showHint:t}),j(qa,{value:d,onChange:h=>{c(h),e(sh(h),!0)},showHint:t})]})}function ch(e){return{photography_grayscale:e}}function dh({persist:e,showHint:t}){let{photographyGrayscale:o,setPhotographyGrayscale:a}=ie();return j(Ka,{value:o,onChange:s=>{a(s),e(ch(s),!0)},showHint:t})}function ph({persist:e,showHint:t=!0}){return j(Rt,{children:j(dh,{persist:e,showHint:t})})}function dt(){let{websiteName:e}=ie();return e?.trim()||Gi}function Tn({themeFromDocument:e=!1,tokenRef:t,siteId:o,onNotify:a,tab:s,onTabChange:l}){let{persist:d}=Ni({themeFromDocument:e,tokenRef:t,siteId:o,onResult:P=>{let b=ys(P);b&&a?.(b.msg,b.tone)}}),[c,h]=Cn(lt[0].id),g=s!==void 0,f=g?s:c,x=g?l??(()=>{}):h,E=lt.find(P=>P.id===f)??lt[0],[C,A]=Cn(_o);return ct(Rt,{children:[j(_p,{items:lt.map(P=>({...P,label:i(P.label)})),activeId:E.id,onSelect:x,ariaLabel:i("Site styles"),idPrefix:Fo}),ct("div",{id:Hp(Fo,E.id),className:qp,role:"tabpanel","aria-labelledby":Op(Fo,E.id),children:[f==="basics"&&ct(Rt,{children:[j(Xp,{themeFromDocument:e,persist:d,showHint:C}),!e&&j(lh,{persist:d,showHint:C}),!e&&j(rh,{persist:d,showHint:C}),!e&&j(ph,{persist:d,showHint:C}),j(Oo,{shown:C,onChange:A})]}),f==="theme"&&j(Gp,{themeFromDocument:e,persist:d}),f==="text"&&j(Up,{themeFromDocument:e,persist:d})]})]})}import{InspectorIconButton as wh}from"efficient-easel/chrome";import{Button as Ps,Dialog as xh,FormField as vh,Input as Rs,toast as As}from"efficient-shell/ui";import{LayersTree as Sh,TreeGroupLabel as kh,TreeRow as Ls,TreeRowAction as Wo}from"efficient-easel/tree";import{AddIcon as Ch}from"efficient-easel/icons";import{PagesIcon as Th}from"efficient-easel/rail";import{useCallback as In,useEffect as hh,useSyncExternalStore as uh}from"react";var ks=new WeakMap;function At(e){let t=ks.get(e);return t||(t={rows:null,loading:null,listeners:new Set},ks.set(e,t)),t}function Ho(e,t){e.rows=t;for(let o of e.listeners)o()}var En=new Set;function Pn(e,t){t?En.add(e):En.delete(e)}function Cs(e){let t=At(e),o=e.listPages().then(a=>Ho(t,En.size?a.filter(s=>!En.has(s.id)):a),()=>Ho(t,[])).finally(()=>{t.loading===o&&(t.loading=null)});return t.loading=o,o}var Ts=()=>null,fh=()=>()=>{};function Mo(){let{adapter:e,ready:t}=ae(),o=In(c=>{let{listeners:h}=At(e);return h.add(c),()=>h.delete(c)},[e]),a=In(()=>At(e).rows,[e]),s=uh(t?o:fh,t?a:Ts,Ts);hh(()=>{if(!t)return;let c=At(e);c.rows===null&&!c.loading&&Cs(e)},[e,t]);let l=In(()=>t?Cs(e):Promise.resolve(),[e,t]),d=In(c=>Ho(At(e),c),[e]);return{rows:s,reload:l,setRows:d,getRows:a}}function mh(e,t){return e?.find(o=>o.slug===t)?.label?.trim()||`/${t}`}function Is(){let{currentSlug:e}=ae(),{rows:t}=Mo();return mh(t,e)}var Ns="sf-editor-pages-collapsed-groups",Ih=e=>e.toLowerCase().trim().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,""),Ds=(e,t)=>{let o=Ih(e)||"page";if(!t.has(o))return o;let a=2;for(;t.has(`${o}-${a}`);)a+=1;return`${o}-${a}`};function Fs({onNavigate:e,onClose:t,activeSurface:o,onPreviewSurface:a}){let s=Ne().chrome?.pageRows,l=Zt(),{adapter:d,capabilities:c,ready:h,currentSlug:g}=ae(),f=dt(),{rows:x,reload:E,setRows:C,getRows:A}=Mo(),[P,b]=pt(""),[v,k]=pt(!1),[u,y]=pt(null),[N,w]=pt(!1),[F,_]=pt(""),ge=bh(),[V,M]=pt(()=>{if(typeof window>"u")return new Set;try{let S=window.localStorage.getItem(Ns);return new Set(S?JSON.parse(S):[])}catch{return new Set}});yh(()=>{try{window.localStorage.setItem(Ns,JSON.stringify([...V]))}catch{}},[V]);let X=S=>M(q=>{let $=new Set(q);return $.has(S)?$.delete(S):$.add(S),$}),de=Es(()=>aa(x??[]),[x]),D=P.trim().toLowerCase(),ee=S=>!D||S.toLowerCase().includes(D),Ae=S=>D?!0:!V.has(S),we=Es(()=>new Set((x??[]).map(S=>S.slug)),[x]),Be=()=>{if(c.pageCreationInAdminForm){l.send("storefront-editor:new-page");return}_(""),y(null),w(!0)},xe=async()=>{let S=F.trim();if(!(!S||!h||v||!d.createPage)){k(!0),y(null);try{let q=await d.createPage({slug:Ds(S,we),title:S,layout:{}});await E(),w(!1),_(""),e(q.slug)}catch{y(i("Couldn\u2019t add the page \u2014 please retry."))}finally{k(!1)}}},Ce=S=>{let q=x??[],$=d.deletePage;if(!h||v||!$||q.length<=1)return;let pe=q.findIndex(re=>re.id===S.id),he=q.filter(re=>re.id!==S.id),je=S.slug===g;Pn(S.id,!0),C(he),y(null),je&&he[0]&&e(he[0].slug);let oe=()=>{Pn(S.id,!1);let re=A()??[];if(re.some(qe=>qe.id===S.id))return;let me=[...re];me.splice(Math.max(0,Math.min(pe,me.length)),0,S),C(me)};As.undoable(i("Deleted \u201C{name}\u201D",{name:S.label}),{actionLabel:i("Undo"),commit:async re=>{await $(S.id,re),Pn(S.id,!1)},undo:()=>{oe(),je&&e(S.slug)},onFail:()=>{oe(),As.error(i("Couldn\u2019t delete the page \u2014 please retry."))}})},We=S=>l.send("storefront-editor:open-page",{slug:S}),ye=S=>{if(!ee(S.label))return null;let q=!o&&S.slug===g,$=c.canDeletePagesInline&&(x??[]).length>1,pe=ia(S),he=S.kind==="lightbox",je=pe||he||S.draft?ht(Bo,{children:[pe&&B("span",{className:"sf-badge-dynamic",children:i("Dynamic")}),he&&B("span",{className:"sf-badge-lightbox",children:i("Lightbox")}),S.draft&&B("span",{className:"sf-page-draft",children:i("draft")})]}):void 0,oe=c.pageCreationInAdminForm||$?ht(Bo,{children:[c.pageCreationInAdminForm&&B(Wo,{kind:"plain",label:i("Edit \u201C{name}\u201D in {place}",{name:S.label,place:i("the admin")}),onClick:()=>We(S.slug),children:B(De,{name:"pencil",size:13,strokeWidth:1.7,rounded:!0})}),$&&B(Wo,{kind:"delete",label:i("Delete \u201C{name}\u201D",{name:S.label}),disabled:v,onClick:()=>Ce(S),children:B(De,{name:"trash",size:13,strokeWidth:1.7,rounded:!0})})]}):void 0;return B(Ls,{icon:B(Eh,{}),name:S.label,selected:q,onSelect:()=>e(S.slug),preview:je,actions:oe,rowProps:{"data-page-slug":S.slug}},S.id)},fe=(S,q,$)=>{let pe=$.filter(Boolean);if(pe.length===0)return null;let he=Ae(S);return ht(gh,{children:[B(kh,{count:pe.length,expanded:he,onToggle:()=>X(S),children:q}),he&&pe]},S)},J=(s?.rows??[]).filter(S=>ee(S.label)).map(S=>{let q=o===S.key;return B(Ls,{icon:S.icon,name:S.label,selected:q,onSelect:()=>a(S.key),preview:B("span",{className:"sf-badge-preview",children:i("Preview")}),actions:B(Wo,{kind:"plain",label:i("Open the {name} in a new tab",{name:S.label}),onClick:()=>window.open(S.href,"_blank","noopener,noreferrer"),children:B(De,{name:"external-link",size:13,strokeWidth:1.7,rounded:!0})}),rowProps:{"data-shop-surface":S.key}},S.key)}),G=c.hasSiteSettings&&!!s,_e=(()=>{if(x===null)return null;let S=[],q=!1;for(let $ of de){G&&!q&&$.key.startsWith("system:")&&(S.push(fe("shop",s.title,J)),q=!0);let pe=$.key===ra||$.label===oa?i($.label):$.label;S.push(fe($.key,pe,$.rows.map(ye)))}return G&&!q&&S.push(fe("shop",s.title,J)),S})();return ht("div",{className:"sf-pages",children:[B(on,{icon:B(Th,{}),title:i("Pages"),context:f,actions:B(wh,{label:i("New page"),onClick:Be,children:B(Ch,{size:15})}),onHide:t}),B("div",{className:"sf-pages-find",children:B(Rs,{type:"search",leftIcon:B(De,{name:"search",size:14,rounded:!0}),placeholder:i("Search all pages\u2026"),value:P,onChange:S=>b(S.target.value),"aria-label":i("Search all pages")})}),u&&!N&&B("div",{className:"sf-note sf-note--error",role:"alert",children:u}),_e===null?B("div",{className:"sf-note",children:i("Loading\u2026")}):_e.some(Boolean)?B(Sh,{ariaLabel:i("Pages"),className:"sf-scroll",children:_e}):B("div",{className:"sf-note",children:P.trim()?i("No pages match your search"):i("No pages yet. Add one with + above.")}),B(xh,{open:N,onClose:()=>w(!1),size:"sm",title:i("Add a page"),description:i("Give the new template page a name. It starts blank \u2014 add sections once it opens."),footer:ht(Bo,{children:[B(Ps,{variant:"secondary",onClick:()=>w(!1),children:i("Cancel")}),B(Ps,{onClick:()=>{xe()},disabled:v||!F.trim(),loading:v,children:i("Add page")})]}),children:B(vh,{label:i("Page name"),htmlFor:ge,hint:F.trim()?i("URL: /{slug}",{slug:Ds(F,we)}):void 0,error:u??void 0,children:B(Rs,{id:ge,value:F,invalid:!!u,onChange:S=>_(S.target.value),onKeyDown:S=>{S.key==="Enter"&&xe()},placeholder:i("e.g. About")})})})]})}function Eh(){return ht("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:1.7,strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[B("path",{d:"M14 3H7a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V8z"}),B("path",{d:"M14 3v5h5"})]})}import{jsx as jo}from"react/jsx-runtime";import{DesktopIcon as Ph,PhoneIcon as Rh,TabletIcon as Ah}from"efficient-easel/icons";var Lh={desktop:jo(Ph,{}),tablet:jo(Ah,{}),mobile:jo(Rh,{})},zs=la.map(e=>({id:e,get label(){return i(sa[e])},icon:Lh[e]}));import{jsx as W,jsxs as Ue,Fragment as er}from"react/jsx-runtime";import{useState as Mu}from"react";import{useEasel as Bu}from"efficient-easel/easel";import{InspectorHead as Wu,InspectorIconButton as al}from"efficient-easel/chrome";import{DuplicateIcon as ju,TrashIcon as qu}from"efficient-easel/icons";import{panelFieldsOf as _s}from"efficient-easel/screen/lib/puck/panel-fields";import{jsx as m,Fragment as O,jsxs as H}from"react/jsx-runtime";import{BlockBannerIcon as Nh,BlockBoxIcon as Dh,BlockButtonIcon as Fh,BlockDividerIcon as Os,BlockFooterIcon as Hs,BlockHeadingIcon as zh,BlockProductIcon as _h,BlockSocialIcon as Oh,BlockTextIcon as Hh,ChatIcon as Mh,GridIcon as Bh,ImageIcon as Wh,PageIcon as jh}from"efficient-easel/icons";var qh={header:H(O,{children:[m("rect",{x:"3",y:"5",width:"18",height:"14",rx:"2"}),m("path",{d:"M3 9.5h18"})]}),website:H(O,{children:[m("circle",{cx:"12",cy:"12",r:"9"}),m("path",{d:"M3 12h18M12 3c2.6 2.7 2.6 15.3 0 18M12 3c-2.6 2.7-2.6 15.3 0 18"})]}),social:H(O,{children:[m("circle",{cx:"6",cy:"12",r:"2.5"}),m("circle",{cx:"18",cy:"6",r:"2.5"}),m("circle",{cx:"18",cy:"18",r:"2.5"}),m("path",{d:"M8.2 10.8l7.6-3.6M8.2 13.2l7.6 3.6"})]}),ticker:H(O,{children:[m("rect",{x:"3",y:"8.5",width:"18",height:"7",rx:"2"}),m("path",{d:"M6 12h3.5M11.5 12h2M15.5 12h2.5"})]}),FooterLogo:H(O,{children:[m("path",{d:"M4 15.5h6M4 18h4"}),m("path",{d:"M14 8.5l3 7 3-7"})]}),FooterMenu:m("path",{d:"M6 7h12M6 11h12M6 15h8M6 19h8"}),FooterGroup:H(O,{children:[m("rect",{x:"4",y:"4",width:"16",height:"16",rx:"2",strokeDasharray:"3 2.5"}),m("path",{d:"M8 9h8M8 13h8M8 16h5"})]}),FooterText:m("path",{d:"M5 7h14M5 12h14M5 17h9"}),FooterEmailSignup:H(O,{children:[m("rect",{x:"3",y:"6",width:"18",height:"12",rx:"2"}),m("path",{d:"M3.5 7l8.5 6 8.5-6"})]}),SearchBlock:H(O,{children:[m("circle",{cx:"11",cy:"11",r:"6"}),m("path",{d:"M20 20l-4.2-4.2"})]}),CartBlock:da,CountrySwitchBlock:H(O,{children:[m("circle",{cx:"12",cy:"12",r:"8.5"}),m("path",{d:"M3.5 12h17M12 3.5c2.6 2.4 3.6 5.2 3.6 8.5s-1 6.1-3.6 8.5M12 3.5c-2.6 2.4-3.6 5.2-3.6 8.5s1 6.1 3.6 8.5"})]}),LegalLineBlock:H(O,{children:[m("path",{d:"M3 9h18"}),m("path",{d:"M3 14h8M14 14h2M18 14h3"})]}),Hero:H(O,{children:[m("rect",{x:"3",y:"4",width:"18",height:"16",rx:"2"}),m("path",{d:"M7 13.5h7M7 16.5h10"})]}),HeroSlide:H(O,{children:[m("rect",{x:"3",y:"5",width:"18",height:"14",rx:"2"}),m("path",{d:"M7 15h6M16 9.5h.01M9.5 12l-2.5 3"})]}),HeroSingle:H(O,{children:[m("rect",{x:"3",y:"4",width:"18",height:"16",rx:"2"}),m("path",{d:"M10.5 8.5l4 2.5-4 2.5z"}),m("path",{d:"M7 17h7"})]}),Collections:H(O,{children:[m("rect",{x:"3",y:"5",width:"4.6",height:"14",rx:"1.3"}),m("rect",{x:"9.7",y:"5",width:"4.6",height:"14",rx:"1.3"}),m("rect",{x:"16.4",y:"5",width:"4.6",height:"14",rx:"1.3"})]}),CollectionCard:H(O,{children:[m("rect",{x:"6",y:"4",width:"12",height:"16",rx:"2"}),m("path",{d:"M9 15h6M9 17.5h4"})]}),AlloyWheelsListing:H(O,{children:[m("path",{d:"M3 5h5M3 9h5M3 13h5M3 17h5"}),m("rect",{x:"11.5",y:"5",width:"4.2",height:"5",rx:"1"}),m("rect",{x:"17.3",y:"5",width:"4.2",height:"5",rx:"1"}),m("rect",{x:"11.5",y:"12",width:"4.2",height:"5",rx:"1"}),m("rect",{x:"17.3",y:"12",width:"4.2",height:"5",rx:"1"})]}),CatalogFilterBar:H(O,{children:[m("path",{d:"M3 7h9M15.5 7H21"}),m("circle",{cx:"13.5",cy:"7",r:"1.7"}),m("path",{d:"M3 12h4M10.5 12H21"}),m("circle",{cx:"8.5",cy:"12",r:"1.7"}),m("path",{d:"M3 17h9M15.5 17H21"}),m("circle",{cx:"13.5",cy:"17",r:"1.7"})]}),ProductGrid:H(O,{children:[m("rect",{x:"3",y:"5",width:"4.8",height:"6",rx:"1"}),m("rect",{x:"9.6",y:"5",width:"4.8",height:"6",rx:"1"}),m("rect",{x:"16.2",y:"5",width:"4.8",height:"6",rx:"1"}),m("rect",{x:"3",y:"13",width:"4.8",height:"6",rx:"1"}),m("rect",{x:"9.6",y:"13",width:"4.8",height:"6",rx:"1"}),m("rect",{x:"16.2",y:"13",width:"4.8",height:"6",rx:"1"})]}),RelatedProducts:H(O,{children:[m("path",{d:"M3 5h10"}),m("rect",{x:"3",y:"9.5",width:"5",height:"9",rx:"1"}),m("rect",{x:"9.5",y:"9.5",width:"5",height:"9",rx:"1"}),m("rect",{x:"16",y:"9.5",width:"5",height:"9",rx:"1"})]}),Gallery:H(O,{children:[m("rect",{x:"3",y:"4",width:"11",height:"16",rx:"2"}),m("rect",{x:"15.5",y:"4",width:"5.5",height:"7.5",rx:"1.5"}),m("rect",{x:"15.5",y:"12.5",width:"5.5",height:"7.5",rx:"1.5"})]}),GalleryB:H(O,{children:[m("rect",{x:"3.5",y:"4",width:"7.5",height:"7.5",rx:"1.5"}),m("rect",{x:"13",y:"4",width:"7.5",height:"7.5",rx:"1.5"}),m("rect",{x:"3.5",y:"12.5",width:"7.5",height:"7.5",rx:"1.5"}),m("rect",{x:"13",y:"12.5",width:"7.5",height:"7.5",rx:"1.5"})]}),GalleryItem:H(O,{children:[m("rect",{x:"4",y:"5",width:"16",height:"14",rx:"2"}),m("circle",{cx:"9",cy:"10",r:"1.6"}),m("path",{d:"M20 15.5l-4.5-4L7 19"})]}),Events:H(O,{children:[m("rect",{x:"4",y:"5",width:"16",height:"15",rx:"2"}),m("path",{d:"M4 9.5h16M8.5 3v4M15.5 3v4M8 14h2M14 14h2"})]}),PostCard:H(O,{children:[m("rect",{x:"4",y:"3.5",width:"16",height:"17",rx:"2"}),m("rect",{x:"6.5",y:"6",width:"11",height:"6",rx:"1"}),m("path",{d:"M6.5 14.5h11M6.5 17.5h7"})]}),Manifesto:H(O,{children:[m("path",{d:"M7 8h3.2v4c0 1.6-1 2.6-3 3.2"}),m("path",{d:"M14 8h3.2v4c0 1.6-1 2.6-3 3.2"})]}),Stats:H(O,{children:[m("path",{d:"M3.5 20h17"}),m("path",{d:"M6 20v-7M11 20V7M16 20v-5M20.5 20v-9"})]}),Logos:H(O,{children:[m("circle",{cx:"6",cy:"12",r:"2.6"}),m("rect",{x:"10",y:"9.4",width:"5.2",height:"5.2",rx:"1.2"}),m("path",{d:"M19 9.2l2.4 5h-4.8z"})]}),Ticker:H(O,{children:[m("rect",{x:"3",y:"8.5",width:"18",height:"7",rx:"2"}),m("path",{d:"M6 12h3.5M11.5 12h2M15.5 12h2.5"})]}),SectionHeader:H(O,{children:[m("rect",{x:"3.5",y:"6",width:"5",height:"5",rx:"1.2"}),m("path",{d:"M11 8.5h9M3.5 15.5h17"})]}),IntroBleed:H(O,{children:[m("rect",{x:"3",y:"4",width:"18",height:"16",rx:"2"}),m("path",{d:"M3 13.5h18M7 16.8h6"})]}),Split:H(O,{children:[m("rect",{x:"3",y:"5",width:"8",height:"14",rx:"1.5"}),m("path",{d:"M14 8.5h6M14 12h6M14 15.5h4"})]}),Eyebrow:H(O,{children:[m("path",{d:"M4 8.5h4.5M11 8.5h9"}),m("path",{d:"M4 14.5h16"})]}),HeroGroup:H(O,{children:[m("rect",{x:"3.5",y:"4.5",width:"17",height:"15",rx:"2"}),m("path",{d:"M7 9h8M7 12.5h10M7 16h6"})]}),Form:H(O,{children:[m("rect",{x:"3",y:"4",width:"18",height:"16",rx:"2"}),m("path",{d:"M6.5 9h11M6.5 12.5h11"}),m("rect",{x:"6.5",y:"15",width:"6.5",height:"2.6",rx:"1.3"})]}),LogoBlock:m(O,{children:m("path",{d:"M12 3.5l7.5 3.2v5.1c0 4.2-3.2 7.1-7.5 8.7-4.3-1.6-7.5-4.5-7.5-8.7V6.7z"})}),Spacer:H(O,{children:[m("path",{d:"M12 4v6M9.5 6.5L12 4l2.5 2.5M12 20v-6M9.5 17.5L12 20l2.5-2.5"}),m("path",{d:"M5 13h14",strokeDasharray:"2 2.5"})]}),ContactRouting:H(O,{children:[m("rect",{x:"3",y:"4",width:"5",height:"5",rx:"1"}),m("rect",{x:"9.5",y:"4",width:"5",height:"5",rx:"1"}),m("rect",{x:"16",y:"4",width:"5",height:"5",rx:"1"}),m("path",{d:"M4 13.5h11M4 17.5h7"}),m("path",{d:"M17 15l3 2-3 2"})]}),CustomHTML:m("path",{d:"M9 8l-4 4 4 4M15 8l4 4-4 4"})},$h=m("rect",{x:"4",y:"4",width:"16",height:"16",rx:"2.5"}),Gh={footer:Hs,Footer:Hs,Divider:Os,FooterDivider:Os,Banner:Nh,Flex:Dh,FooterSocial:Oh,page:jh,chat:Mh,Heading:zh,Text:Hh,ImageBlock:Wh,ButtonBlock:Fh,Grid:Bh,ProductRef:_h},Kh={MenuBlock:"FooterMenu",EmailFormBlock:"FooterEmailSignup",SocialLogosBlock:"FooterSocial",SiteHeader:"header",SiteFooter:"footer"};function ut({type:e,size:t=16,className:o}){let a=Kh[e]??e,s=Gh[a];return s?m(s,{size:t,className:o}):m("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:1.7,strokeLinecap:"round",strokeLinejoin:"round",className:o,"aria-hidden":"true",children:qh[a]??$h})}import{jsx as ke,Fragment as Uh,jsxs as Vh}from"react/jsx-runtime";import{useEffect as Yh,useId as Xh,useState as Zh}from"react";import{SettingsField as Ms,SettingsSwitch as Jh}from"efficient-easel/panel";import{EyeIcon as Qh,TypeIcon as eu}from"efficient-easel/icons";var tu="Chat with us",nu="We usually reply within a few minutes",ou="Hi! Ask us anything \u2014 about a wheel, an order, or fitment. Leave your details and we\u2019ll reply.";function qo({label:e,value:t,placeholder:o,onCommit:a,multiline:s=!1}){let[l,d]=Zh(t);Yh(()=>d(t),[t]);let c=()=>{l!==t&&a(l)};return ke(Ms,{label:e,icon:ke(eu,{}),children:s?ke("textarea",{value:l,placeholder:o,rows:3,onChange:h=>d(h.target.value),onBlur:c,"aria-label":e}):ke("input",{type:"text",value:l,placeholder:o,onChange:h=>d(h.target.value),onBlur:c,onKeyDown:h=>{h.key==="Enter"&&h.currentTarget.blur()},"aria-label":e,autoComplete:"off"})})}function Bs(){let{chat:e,setChat:t}=tn(),o=Xh();return Vh(Uh,{children:[ke(Ms,{label:i("Show the chat bubble"),labelId:o,icon:ke(Qh,{}),action:ke(Jh,{checked:e.enabled,onChange:a=>t({enabled:a}),ariaLabelledBy:o}),hint:e.enabled?i("The floating chat bubble shows in the corner of every page."):i("The chat bubble is hidden across the whole site.")}),ke(en,{label:"Wording"}),ke(qo,{label:i("Title"),value:e.title,placeholder:tu,onCommit:a=>t({title:a})}),ke(qo,{label:i("Subtitle"),value:e.subtitle,placeholder:nu,onCommit:a=>t({subtitle:a})}),ke(qo,{label:i("Greeting message"),value:e.greeting,placeholder:ou,onCommit:a=>t({greeting:a}),multiline:!0}),ke("p",{className:"es-field-hint sf-hint-keep",children:i("Leave a field blank to use the built-in wording.")})]})}import{jsx as et,Fragment as $o,jsxs as qs}from"react/jsx-runtime";import{useEffect as ru,useId as Ws,useState as js}from"react";import{SettingsField as iu}from"efficient-easel/panel";var au={instagram:"instagram.com/yourshop",facebook:"facebook.com/yourshop",tiktok:"tiktok.com/@yourshop",youtube:"youtube.com/@yourshop",x:"x.com/yourshop",linkedin:"linkedin.com/company/yourshop",pinterest:"pinterest.com/yourshop",whatsapp:"wa.me/61400000000",telegram:"t.me/yourshop",line:"line.me/ti/p/~yourshop",wechat:"u.wechat.com/your-qr-code-link"};function su({platform:e}){let{rows:t,saveLink:o}=St(),{value:a,error:s}=t[e],[l,d]=js(a),[c,h]=js(!1),g=Ws(),f=Ws();ru(()=>d(a),[a]);let x=async()=>{if(l.trim()===a){l!==a&&d(a);return}h(!0),await o(e,l),h(!1)},E=Vi[e];return qs($o,{children:[et(iu,{label:i(E),htmlFor:g,icon:et(pa,{platform:e,iconStyle:"outline",size:18}),children:et("input",{id:g,type:"text",inputMode:"url",value:l,placeholder:au[e],onChange:C=>d(C.target.value),onBlur:()=>{x()},onKeyDown:C=>{C.key==="Enter"&&C.currentTarget.blur(),C.key==="Escape"&&(d(a),C.currentTarget.blur())},"aria-invalid":s?!0:void 0,"aria-describedby":s?f:void 0,"aria-busy":c||void 0,autoComplete:"off",spellCheck:!1})}),s&&et("p",{id:f,className:"sf-note sf-note--error",role:"alert",children:s})]})}function $s({unavailable:e}){let{canSave:t}=St();return!t&&e?et($o,{children:e}):qs($o,{children:[et("p",{className:"es-field-hint sf-hint-keep",children:i("Paste a link to each profile. A platform left empty shows nothing on the site.")}),Ui.map(o=>et(su,{platform:o},o))]})}import{jsx as ft,jsxs as lu}from"react/jsx-runtime";import{useId as cu,useMemo as du}from"react";import{useEasel as pu}from"efficient-easel/easel";import{SettingsField as hu,SettingsSwitch as uu}from"efficient-easel/panel";import{EyeIcon as fu}from"efficient-easel/icons";var mu="root:default-zone";function Gs({heroId:e}){let{appState:t,dispatch:o}=pu(f=>f),a=t.data.content??[],s=a.findIndex(f=>f.props.id===e),l=s>=0?a[s]:null,d=l?l.props.showTicker??!0:!0,c=du(()=>{let f=l?.props.tickerItems;return Array.isArray(f)?f:ua.map(x=>({text:x}))},[l]),h=cu();if(!l)return ft("p",{className:"sf-note",children:i("This ticker\u2019s hero is no longer on the page.")});let g=f=>o({type:"replace",destinationZone:mu,destinationIndex:s,data:{...l,props:{...l.props,...f}}});return lu("div",{children:[ft(en,{label:"Ticker"}),ft(hu,{label:i("Show ticker"),labelId:h,icon:ft(fu,{}),action:ft(uu,{checked:d,onChange:f=>g({showTicker:f}),ariaLabelledBy:h})}),ft(Wi,{label:Xn.label,icon:Xn.icon,items:c,placeholder:"item",onChange:f=>g({tickerItems:f}),markup:!0})]})}import{jsx as Re,jsxs as Go,Fragment as gu}from"react/jsx-runtime";import{useCallback as yu,useRef as bu,useState as Lt}from"react";import{InspectorIconButton as wu}from"efficient-easel/chrome";import{PopupMenu as xu,PopupMenuItem as vu,PopupMenuLabel as Rn}from"efficient-shell/ui";import{CopyToPageIcon as Su}from"efficient-easel/icons";import{cloneNodeWithFreshIds as Ks,docToNode as rx,nodeToDoc as ix}from"efficient-easel/screen/lib/puck/section-doc";function Us({node:e,currentSlug:t,siteId:o,tokenRef:a,runAuthed:s,onNotify:l}){let[d,c]=Lt(!1),[h,g]=Lt(null),f=Ne(),[x,E]=Lt(!1),[C,A]=Lt(null),P=bu(null),[b,v]=Lt(null),k=yu(async()=>{if(f.usesBridgedToken&&!a.current){E(!0);return}try{g(await gt(f).pages.list(o?{siteId:o}:void 0))}catch{E(!0)}},[a,o,f]),u=()=>{if(d){c(!1);return}let w=P.current?.getBoundingClientRect();w&&v({top:w.bottom+6,right:Math.max(8,window.innerWidth-w.right)}),g(null),E(!1),k(),c(!0)},y=(h??[]).filter(w=>w.slug!==t),N=async w=>{if(C)return;A(w.slug);let F=Ks(e),_=f.documentHooks?.storedNode?.(F)??F,ge=gt(f).pages,V=await s(async()=>{let M=await ge.load({id:w.id});if(!M)throw new Error(`Page "${w.slug}" no longer exists.`);let X=M.layout??{},de=Array.isArray(X.content)?[...X.content]:[],D=de.findIndex(ee=>ee?.type===te);de.splice(D===-1?de.length:D,0,_),await ge.save(w.id,{layout:{root:{},zones:{},...X,content:de}},{version:M.version,clientId:""})});A(null),c(!1),l?.(V?i("Duplicated to \u201C{name}\u201D",{name:w.label}):i("Couldn\u2019t duplicate the section \u2014 please retry"),V?"success":"error")};return Go(gu,{children:[Re("span",{"data-menu-toggle":!0,style:{display:"contents"},children:Re(wu,{buttonRef:P,label:i("Duplicate to another page"),hasPopup:"menu",expanded:d,onClick:u,children:Re(Su,{size:15})})}),d&&b&&Re(xu,{portal:!0,style:{top:b.top,right:b.right},onClose:()=>c(!1),children:Go("div",{role:"menu","aria-label":i("Duplicate to page"),children:[Re(Rn,{children:i("Duplicate to page")}),x?Re(Rn,{children:i("Couldn\u2019t load pages")}):h===null?Re(Rn,{children:i("Loading\u2026")}):y.length===0?Re(Rn,{children:i("No other pages")}):y.map(w=>Go(vu,{role:"menuitem",disabled:C!==null,onClick:()=>{N(w)},children:[Re("span",{className:"min-w-0 flex-1 truncate",children:w.label}),C===w.slug?Re("span",{className:"shrink-0 text-xs",children:i("Copying\u2026")}):w.draft&&Re("span",{className:"shrink-0 text-xs",children:i("draft")})]},w.id))]})})]})}import{ScreenPartsProvider as wx,sameInspectorMode as xx,SELECTION_MODE as Vs,useScreenParts as vx,useScreenBlockLook as Sx,useScreenBlockRules as kx,useScreenBridges as Cx,useScreenCanvasFrame as Tx,useScreenDevices as Ix,useScreenDocumentPass as Ex,useScreenInspectorPanel as Px,useScreenLeftView as Rx,useScreenOwnerName as Ax,useScreenPinned as Lx,useStandaloneScreenBridges as Nx}from"efficient-easel/screen/lib/screen-parts";import{jsx as Nt,jsxs as ku}from"react/jsx-runtime";import{SettingsDrill as Cu}from"efficient-easel/panel";var Tu="Not shown on the page";function Iu({part:e,onOpen:t}){return Nt(Cu,{name:i(e.label),preview:e.offPage?i(Tu):e.preview||i("Empty"),offPage:e.offPage,status:e.hidden?Nt("span",{className:"sf-entry-eye",role:"img","aria-label":i("Hidden on the page"),children:Nt(De,{name:"eye-off",size:14})}):void 0,onOpen:()=>t(e.key)})}function Ko(e){return e.filter(t=>!t.identifier)}function Ys({parts:e,onOpen:t,heading:o=!0}){let a=Ko(e);return a.length?ku("div",{className:"sf-entries",children:[o?Nt("h3",{className:"sf-entries-head",children:i("Text")}):null,a.map(s=>Nt(Iu,{part:s,onOpen:t},s.key))]}):null}import{jsx as Nn,jsxs as Js}from"react/jsx-runtime";import{useState as Ru}from"react";import{createNode as Au,newId as Lu}from"efficient-easel/data";import{useEasel as Nu}from"efficient-easel/easel";import{Button as Uo}from"efficient-shell/ui";var An="Flex",Eu={FooterMenu:"MenuBlock",FooterEmailSignup:"EmailFormBlock",FooterSocial:"SocialLogosBlock"},Pu=e=>{let{id:t,...o}=e;return o},Xs=e=>typeof e=="string"?e:"";function Zs(e,t){let o=e.props??{},a=Eu[e.type];if(a)return[t(a,Pu(o))];switch(e.type){case"FooterLogo":{let s=t("LogoBlock",o.reverse?{reverse:o.reverse}:{}),l=Xs(o.tagline).trim();return l?[s,t("Text",{text:l,tone:"dim",align:o.align==="center"?"center":"left"})]:[s]}case"FooterText":return[t("Text",{text:Xs(o.text),tone:typeof o.tone=="string"?o.tone:"default"})];case"FooterDivider":return[t("Divider")];case"FooterGroup":{let s=Array.isArray(o.blocks)?o.blocks:[];return[t(An,{direction:o.direction==="horizontal"?"row":"column",content:s.flatMap(l=>Zs(l,t))})]}default:return[]}}function Ln(e,t,o){let a=(e&&Array.isArray(e.props?.blocks)?e.props.blocks:[]).flatMap(d=>{let c=Zs(d,t);return c.length<=1?c:[t(An,{direction:"column",content:c})]}),s=t(An,{direction:"row",wrap:!0,share:"equal",content:a}),l=t(An,{direction:"column",content:[t("LegalLineBlock")]});return Tr(Te,o,[s,l])}function Qs(){let{appState:e,dispatch:t,config:o}=Nu(f=>f),{readOnly:a}=ae(),[s,l]=Ru(!1),d=e.data.content;if(a||d.some(f=>f.type===Te))return null;let c=d.find(f=>f.type===te)??null,h=(f,x)=>Au(o,f,x),g=()=>{let f=Ln(c,h,Lu(Te));t({type:"setData",data:x=>({...x,content:[...Er(x.content,f)]}),recordHistory:!0}),l(!1)};return Js("div",{className:"sf-box-footer-switch",children:[Nn("p",{className:"sf-box-footer-switch-text",children:i("Build this footer out of Boxes and blocks, like a page: the same menus, signup, social links and logo, with the copyright as a Legal Line. Your current footer is kept.")}),s?Js("div",{className:"sf-box-footer-switch-row",children:[Nn(Uo,{variant:"primary",size:"sm",onClick:g,children:i("Switch now")}),Nn(Uo,{variant:"secondary",size:"sm",onClick:()=>l(!1),children:i("Cancel")})]}):Nn(Uo,{variant:"secondary",size:"sm",onClick:()=>l(!0),children:i("Switch to Box footer")})]})}import{jsx as Jo}from"react/jsx-runtime";import{useLayoutEffect as Du,useMemo as rl,useRef as Fu,useState as Xo}from"react";import{useSelectedFields as zu}from"efficient-easel/easel";import{Inspector as _u,planFields as il}from"efficient-easel/fields";var Vo=" text",el="Text";function Yo(e){let t=e.rows.filter(o=>o.shown);return t.length===0||t.length===1&&t[0].labelled}function tl(e){return e.filter(Yo).map(t=>t.key)}function nl(e,t){let o=null;for(let a of t){let s=e[a];!s||s.marker!==!0||typeof s.fold!="string"||(o??={...e},o[a]={...s,fold:!1})}return o??e}function ol(e,t){if(e.size!==t.size)return!1;for(let o of e)if(!t.has(o))return!1;return!0}var Zo=new Map,Dn=new Set;function Ou(e,t){let o=new Map;for(let s of e.querySelectorAll(".es-insp-row[data-field]"))o.set(s.getAttribute("data-field")??"",s);let a=[];for(let[s,l]of t)a.push({key:s,rows:l.map(d=>{let c=o.get(d),h=!!c&&[...c.children].some(f=>!f.hidden),g=c?.querySelector(".es-field-label, .es-list-label")?.textContent?.trim();return{shown:h,labelled:h&&!!g}})});return a}var Hu=Object.fromEntries(qi.map(e=>{let t=Mi[e];return[e,Jo(t,{},e)]}));function Qo({entries:e,entryCount:t=0}){let{id:o,fields:a,values:s,readOnly:l,onChange:d}=zu(),[c,h]=Xo(()=>new Set(Dn)),[g,f]=Xo(()=>new Set),x=Fu(null),E=rl(()=>{let w=new Map;for(let F of il(a).rows){if(!F.fold)continue;let _=w.get(F.fold.key)??[];_.push(F.name),w.set(F.fold.key,_)}return w},[a]);Du(()=>{let w=x.current?.parentElement;if(!w)return;let F=new Set(tl(Ou(w,E)));f(_=>ol(_,F)?_:F)});let C=rl(()=>nl(a,g),[a,g]),A={key:Vo,rows:Array.from({length:t},()=>({shown:!0,labelled:!0}))},P=Yo(A)?void 0:{key:Vo,title:el},[b,v]=Xo(()=>Zo.get(o)),k=Zo.get(o),u=il(a).buckets,y=k&&u.includes(k)?k:b&&u.includes(b)?b:u[0],N=y===void 0||Bi(u,y)!==!0;return Jo(_u,{fields:C,values:s,onChange:d,readOnly:l,tab:y,onTab:w=>{Zo.set(o,w),v(w)},tabIcons:Hu,idPrefix:o,ariaLabel:i("Section settings"),lead:N?e:null,leadFold:P,closedFolds:c,onFold:(w,F)=>{F?Dn.delete(w):Dn.add(w),h(new Set(Dn))},children:Jo("span",{ref:x,hidden:!0})})}import{SettingsSwitch as $u}from"efficient-easel/panel";var sl=Vs,tr={kind:"header"},nr={kind:"website"},ll={kind:"chat"},cl={kind:"social"},Fn="Part";function dl(e){return i("Part of {name}",{name:i(e)})}function Gu(e,t,o){let a=e.describeNode(t);return{name:o,kindLabel:a?dl(a.label):i(Fn)}}function Ku(e){switch(e){case"Header":return{title:i("Header settings belong to a website."),own:i("Each website created from this template sets its own header afterwards.")};case"Appearance":return{title:i("Appearance settings belong to a website."),own:i("Each website created from this template sets its own appearance afterwards.")};case"Live chat":return{title:i("Live chat settings belong to a website."),own:i("Each website created from this template sets its own live chat afterwards.")};case"Social link":return{title:i("Social link settings belong to a website."),own:i("Each website created from this template sets its own social link afterwards.")};default:return{title:i("{what} settings belong to a website.",{what:e}),own:i("Each website created from this template sets its own {what} afterwards.",{what:e.toLowerCase()})}}}function pl({what:e}){let t=Ku(e);return Ue("div",{className:"sf-note",children:[W("p",{children:W("strong",{children:t.title})}),Ue("p",{children:[i("A template is a blueprint \u2014 it has no website of its own, so there is nothing here to change.")," ",t.own]})]})}var Uu={header:{name:"Header",kindLabel:"Site settings",icon:"header",render:(e,t)=>{let o=t.hostPanels?.header;return o?W(o,{placeholderMode:t.capabilities.placeholderFrames,tokenRef:t.tokenRef,siteId:t.siteId,websiteName:t.websiteName,onOpenWebsiteSettings:t.onOpenWebsiteSettings,onAuthExpired:()=>t.notifyParent("storefront-editor:auth-expired")}):null}},website:{name:"Appearance",kindLabel:"Site settings",icon:"website",render:(e,t)=>W(Tn,{themeFromDocument:!t.capabilities.hasSiteTheme,tokenRef:t.tokenRef,siteId:t.siteId,onNotify:t.onNotify})},chat:{name:"Live chat",kindLabel:"Site settings",icon:"chat",render:()=>W(Bs,{})},social:{name:"Social links",kindLabel:"Site settings",icon:"social",render:()=>W($s,{unavailable:W(pl,{what:"Social link"})})},ticker:{name:kt,kindLabel:Fn,icon:"ticker",head:(e,t)=>e.kind==="ticker"?Gu(t,e.heroId,i(kt)):null,render:e=>W(Gs,{heroId:e.kind==="ticker"?e.heroId:""})},part:{name:Fn,kindLabel:Fn,icon:"Text",head:(e,t)=>{if(e.kind!=="part")return null;let o=t.describeNode(e.nodeId);if(!o)return null;let{key:a,row:s}=Ge(e.propKey),l=s?at(o.fields[a],s):o.fields[a],d=$r(i(Vr(Ur(l??{},a))),s),c=t.styleNameOfPart(e.nodeId,e.propKey);return{name:c!==null?i(c):d,kindLabel:dl(o.label)}},render:(e,t)=>e.kind==="part"?W(hs,{nodeId:e.nodeId,propKey:e.propKey,onBack:()=>t.onSelectNode(e.nodeId),onEditStyle:t.onOpenSiteStyles}):null}},Vu=new Set(["header","website","chat"]);function Yu(e,t){if(e==="puck")return null;let o=Uu[e];return Vu.has(e)&&!t.hasSiteSettings?{...o,kindLabel:"Not part of a template",render:()=>W(pl,{what:o.name})}:o}function hl({mode:e,onOpenWebsiteSettings:t,onOpenSiteStyles:o,onSelectNode:a,hideNodeActions:s=!1,onNotify:l,onHidePanel:d}){let{capabilities:c,tokenRef:h,notifyParent:g,currentSlug:f,siteId:x,runAuthed:E,readOnly:C}=ae(),{websiteName:A,fonts:P}=ie(),{partStyle:b}=jt(),v=rt({readOnly:C}),{select:k}=bt(),{selectedItem:u,getItemById:y,getSelectorForId:N,config:w,appState:F}=Bu(oe=>oe),_=_s(w,u?{type:u.type,props:u.props}:null),ge=u?Yr(_??w.components[u.type]?.fields,u.props):[],V=oe=>w.components[oe]?.label??oe,M=u?N(u.props.id):void 0,X=Yu(e.kind,c),de=Ne(),D=de.chrome?.panels?.chromePage,ee={capabilities:c,tokenRef:h,hostPanels:de.chrome?.panels,describeNode:oe=>{let re=y(oe);if(!re)return null;let me=w.components[re.type];return{type:re.type,label:me?.label??re.type,fields:me?.fields??{}}},styleNameOfPart:(oe,re)=>{let me=y(oe);if(!me)return null;let qe=wt(oe,re),Ht=b?.partId===qe?b:null;return ps(me.props,re,Ht,P)},siteId:x,websiteName:A??null,notifyParent:g,onNotify:l,onOpenWebsiteSettings:t,onOpenSiteStyles:o,onSelectNode:a},Ae=X?.head?.(e,ee)??null,we=Ae?.name??(X?i(X.name):u?i(V(u.type)):i("Page settings")),Be=Ae?.kindLabel??(X?i(X.kindLabel):u?M&&M.zone!==$e?i("Block"):i("Section"):i("Page")),xe=X?X.icon:u?u.type:"page",Ce=X?null:u?w.components[u.type]?.fields??null:w.root?.fields??null,We=Ce?$i(Ce):2,ye=e.kind==="puck"&&u?gn(u.type):null,fe=!!u&&!!M&&M.zone===$e&&u.type!==te&&u.type!==Oe,J=Mt(F?.data,u),G=()=>{J||M&&v.duplicateComponent(M.zone,M.index)},_e=()=>{M&&(v.removeComponent(M.zone,M.index),v.select(null))},S=u?w.components[u.type]?.defaultProps?.previewHover:void 0,q=e.kind==="puck"&&!!u&&!!M&&S!==void 0,$=q&&u.props.previewHover===!0,pe=()=>{!u||!M||v.replaceComponent(M.zone,M.index,{...u,props:{...u.props,previewHover:!$}})},[he,je]=Mu(_o);return Ue("div",{className:`es-sidepanel es-sidepanel--right sf-panel sf-panel--right${he||!(!X&&u)?"":" sf-hints-folded"}`,children:[W(Wu,{icon:W(ut,{type:xe,size:15}),name:we,kind:Be,actions:!s&&e.kind==="puck"&&u&&u.type!==te?Ue(er,{children:[W(al,{label:i("Duplicate section"),title:J??void 0,disabled:J!==null,onClick:G,children:W(ju,{size:15})}),fe&&c.hasSiteSettings&&W(Us,{node:u,currentSlug:f,siteId:x??void 0,tokenRef:h,runAuthed:E,onNotify:l}),W(al,{label:i("Remove section"),danger:!0,onClick:_e,children:W(qu,{size:15})}),d?W(ao,{side:"right",onHide:d,divider:!0}):null]}):d?W(ao,{side:"right",onHide:d}):void 0}),q&&Ue("div",{className:"sf-preview-pin",children:[Ue("div",{className:"sf-preview-pin-text",children:[W("span",{className:"sf-preview-pin-label",children:i("Preview hover state")}),W("span",{className:"sf-preview-pin-hint",children:i("not shown live")})]}),W($u,{checked:$,onChange:pe,ariaLabel:i("Preview hover state")})]}),W(_i,{tier:We,children:W("div",{className:"sf-insp-body sf-scroll",children:X?X.render(e,ee):u?Ue(er,{children:[W(Di,{children:W(Qo,{entries:W(Ys,{parts:ge,heading:!1,onOpen:oe=>k(wt(u.props.id,oe))}),entryCount:Ko(ge).length})}),u.type===te&&c.hasSiteSettings&&W(Qs,{}),ye&&W(xn,{source:ye,slug:Tt(u?.props)}),W(Oo,{shown:he,onChange:je})]}):Ue(er,{children:[W(Qo,{}),f===Ze&&c.hasSiteSettings&&D&&W(D,{})]})})})]})}import{jsx as n,jsxs as p,Fragment as yl}from"react/jsx-runtime";var se={dark:"var(--sf-thumb-bar-dark)",soft:"var(--sf-thumb-bar-light)",accent:"var(--sf-thumb-accent)",tint:"var(--sf-thumb-accent-tint)",block:"var(--sf-thumb-block)",line:"var(--sf-thumb-border)",card:"var(--sf-thumb-card)"},or="repeating-linear-gradient(135deg,var(--sf-thumb-hatch1) 0,var(--sf-thumb-hatch1) 5px,var(--sf-thumb-hatch2) 5px,var(--sf-thumb-hatch2) 10px)";function T({w:e,h:t,tone:o="dark",r:a=2,style:s}){return n("div",{style:{width:e,height:t,borderRadius:a,background:se[o],flex:"none",...s}})}var Xu={Hero:"hero",HeroSingle:"herosingle",IntroBleed:"intro",Collections:"collections",AlloyWheelsListing:"wheelslisting",CatalogFilterBar:"catalogfilterbar",ProductGrid:"productgrid",BrandStrip:"brandstrip",FitmentFinder:"fitmentfinder",Gallery:"gallery",GalleryB:"gallerygrid",SpecStrip:"specstrip",ProductHero:"producthero",SpecTable:"spectable",ProcessSteps:"processsteps",DetailRows:"detailrows",FitmentTable:"fitmenttable",CompatibleTyres:"compatibletyres",TyreSizes:"tyresizes",TyreFitment:"tyrefitment",EuTyreLabel:"eutyrelabel",RelatedProducts:"productgrid",BundleOffer:"bundleoffer",OrderSummary:"ordersummary",DeliveryOptions:"deliveryoptions",PaymentBadges:"paymentbadges",CheckoutCTA:"checkoutcta",Manifesto:"manifesto",ParagraphsA:"paragraphs",Prose:"prose",StatsParagraph:"statsparagraph",Chart:"chart",Mockup:"mockup",Footprint:"footprint",Timeline:"timeline",TimelineTrack:"timelinetrack",TitleWithButtons:"titlewithbuttons",Split:"split",Cards:"cards",FAQ:"faq",Testimonials:"testimonials",Masthead:"masthead",Breadcrumb:"breadcrumb",CategoryBar:"categorybar",FeaturedCover:"featuredcover",LongRead:"longread",Series:"series",Subscribe:"subscribe",SubscribeBlogs:"subscribe",Events:"events",DocMasthead:"docmasthead",DocTabs:"doctabs",DocBody:"docbody",DocMetaCards:"docmetacards",Banner:"banner",Stats:"stats",KeyFeatures:"keyfeatures",Logos:"logos",Ticker:"ticker",Countdown:"countdown",Reviews:"reviews",SubmitBuild:"submitbuild",ReviewForm:"reviewform",Form:"form",AppointmentBooking:"appointmentbooking",ContactRouting:"contact",ContactLocations:"contactlocations",Header:"header",Footer:"footer",SectionHeader:"sectionheader",Grid:"grid",Flex:"blanksection",Spacer:"spacer",Divider:"divider",CustomHTML:"customhtml",Heading:"heading",Text:"text",ImageBlock:"image",ButtonBlock:"button",MenuBlock:"menu",EmailFormBlock:"emailform",SocialLogosBlock:"sociallogos",LegalLineBlock:"legalline",SearchBlock:"search",CartBlock:"cart",CountrySwitchBlock:"countryswitch"},R={position:"absolute",inset:0},r={ink:"var(--sf-thumb-ink)",ink2:"var(--sf-thumb-ink-2)",inkSoft:"var(--sf-thumb-ink-soft)",inkSoft2:"var(--sf-thumb-ink-soft-2)",paper:"var(--sf-thumb-paper)",paper2:"var(--sf-thumb-paper-2)",warm:"var(--sf-thumb-warm)",rust:"var(--sf-thumb-rust)",onInk:"var(--sf-thumb-on-ink)",text:"var(--sf-thumb-scene-text)",muted:"var(--sf-thumb-scene-muted)",rule:"var(--sf-thumb-scene-rule)",mark1:"var(--sf-thumb-mark-1)",mark2:"var(--sf-thumb-mark-2)",card:"var(--sf-thumb-card)",scrim:"var(--sf-thumb-scrim)"},Y=(e,t,o=160)=>({background:`linear-gradient(${o}deg,${e},${t})`});function Me({size:e,style:t}){let o=Math.max(2,Math.round(e*.13)),a=(s,l,d)=>({position:"absolute",inset:s,background:l,borderRadius:o,...d?{mixBlendMode:d}:null});return p("span",{style:{position:"absolute",display:"block",width:e,height:e,...t},children:[n("span",{style:a("8% 26% 30% 6%",r.mark1)}),n("span",{style:a("26% 6% 8% 30%",r.mark2,"multiply")})]})}function Ft({children:e}){return n("span",{style:{fontSize:"4.64cqw",fontWeight:700,letterSpacing:"0.06em",textTransform:"uppercase",color:r.muted},children:e})}function ul({over:e,overTone:t,head:o,headSize:a=11.5,cta:s,ctaBg:l,ctaFg:d,tone:c}){return p(yl,{children:[e&&n("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.16em",fontWeight:700,color:t},children:e}),n("span",{style:{fontSize:a,lineHeight:1.15,fontWeight:700,maxWidth:"78%",color:c},children:o}),s&&n("span",{style:{alignSelf:"flex-start",fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"4px 8px",borderRadius:2,marginTop:2,background:l,color:d},children:s})]})}function rr({name:e,price:t}){return p("div",{style:{display:"flex",flexDirection:"column",gap:2,minWidth:0},children:[n("div",{style:{flex:1,minHeight:0,borderRadius:3,position:"relative",overflow:"hidden",...Y(r.paper,r.paper2,150)},children:n(Me,{size:34,style:{left:"50%",top:"50%",transform:"translate(-50%,-50%)"}})}),n("span",{style:{fontSize:"3.65cqw",fontWeight:600,color:r.text},children:e}),n("span",{style:{fontSize:"3.65cqw",color:r.muted},children:t})]})}function He({k:e,v:t,ok:o}){return p("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",gap:6,padding:"3.5px 2px",borderBottom:`1px solid ${r.rule}`,fontSize:"3.98cqw",color:r.muted},children:[n("span",{children:e}),p("span",{style:{display:"flex",gap:6,alignItems:"center"},children:[n("b",{style:{color:r.text,fontWeight:700},children:t}),o&&n("span",{style:{color:r.rust,fontWeight:700},children:"\u2713"})]})]})}function K({title:e,children:t}){return p("div",{style:{...R,background:r.card,padding:"9px 10px",display:"flex",flexDirection:"column",gap:6},children:[n(Ft,{children:e}),t]})}function fl({size:e=14}){return n("span",{style:{width:e,height:e,borderRadius:"50%",flex:"none",display:"block",background:`linear-gradient(150deg,${r.mark1},${r.mark2})`}})}function ir({filled:e=5,size:t=6}){return p("span",{style:{fontSize:t,letterSpacing:"0.06em",color:r.rust,lineHeight:1},children:["\u2605".repeat(e),n("span",{style:{color:r.mark1},children:"\u2605".repeat(5-e)})]})}function Dt({n:e,label:t,tone:o=r.text}){return p("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:1,minWidth:0},children:[n("b",{style:{fontSize:"8.16cqw",lineHeight:1,color:o},children:e}),n("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.08em",textTransform:"uppercase",opacity:.62,color:o},children:t})]})}function ce({children:e,w:t}){return n("span",{style:{fontSize:"3.98cqw",lineHeight:1.45,color:r.muted,width:t,display:"block"},children:e})}function zn({label:e,w:t="100%",filled:o}){return p("div",{style:{width:t,display:"flex",flexDirection:"column",gap:2},children:[n("span",{style:{fontSize:"3.32cqw",letterSpacing:"0.08em",textTransform:"uppercase",color:r.muted},children:e}),n("span",{style:{height:9,borderRadius:3,border:`1px solid ${r.rule}`,background:o?r.paper:r.card}})]})}function ml({children:e}){return n("span",{style:{alignSelf:"flex-start",fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"5px 9px",borderRadius:2,background:r.text,color:r.onInk},children:e})}var Zu={wheelslisting:n(K,{title:"All wheels",children:n("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:[["Ridge 19","20\xD79 +12","$365"],["Ridge 29","18\xD79 +20","$410"],["Ridge 39","17\xD78 \u221210","$455"]].map(([e,t,o])=>p("div",{style:{display:"flex",alignItems:"center",gap:6},children:[n("span",{style:{width:20,height:15,borderRadius:3,flex:"none",position:"relative",overflow:"hidden",...Y(r.paper,r.paper2,150)},children:n(Me,{size:12,style:{left:"50%",top:"50%",transform:"translate(-50%,-50%)"}})}),n("b",{style:{flex:1,fontSize:"4.31cqw",color:r.text},children:e}),n("span",{style:{fontSize:"3.65cqw",color:r.muted},children:t}),n("b",{style:{fontSize:"4.31cqw",color:r.text,width:26,textAlign:"right"},children:o})]},e))})}),catalogfilterbar:p("div",{style:{...R,background:r.card,display:"flex",flexDirection:"column",justifyContent:"center",gap:7,padding:"0 11px"},children:[p("div",{style:{display:"flex",gap:4,alignItems:"center"},children:[["20 inch","6\xD7139.7","Black"].map(e=>p("span",{style:{fontSize:"3.65cqw",fontWeight:600,padding:"4px 7px",borderRadius:99,background:r.text,color:r.onInk,display:"flex",gap:4,alignItems:"center"},children:[e,n("span",{style:{opacity:.6},children:"\u2715"})]},e)),n("span",{style:{fontSize:"3.65cqw",color:r.rust,fontWeight:700},children:"Clear"})]}),p("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[n("span",{style:{fontSize:"3.65cqw",color:r.muted},children:"128 results"}),n("span",{style:{fontSize:"3.65cqw",color:r.muted,border:`1px solid ${r.rule}`,borderRadius:3,padding:"3px 6px"},children:"Sort: Price \u25BE"})]})]}),fitmentfinder:p("div",{style:{...R,padding:"10px 12px",display:"flex",flexDirection:"column",gap:6,justifyContent:"center",...Y(r.ink,r.inkSoft)},children:[n("span",{style:{fontSize:"5.31cqw",fontWeight:700,color:r.onInk},children:"Will it fit your rig?"}),p("div",{style:{display:"flex",gap:4},children:[["2021","Toyota","Hilux"].map(e=>p("span",{style:{flex:1,fontSize:"3.65cqw",color:r.text,background:r.card,borderRadius:3,padding:"5px 6px",display:"flex",justifyContent:"space-between"},children:[e," ",n("span",{style:{color:r.muted},children:"\u25BE"})]},e)),n("span",{style:{fontSize:"3.65cqw",fontWeight:700,letterSpacing:"0.08em",background:r.warm,color:r.ink,borderRadius:3,padding:"5px 7px"},children:"GO"})]})]}),compatibletyres:n(K,{title:"Tyres that suit",children:n("div",{style:{flex:1,display:"grid",gridTemplateColumns:"repeat(3,1fr)",gap:5,minHeight:0},children:[["Ridge Grappler","$489"],["Trail Grappler","$525"],["Terra Grappler","$438"]].map(([e,t])=>p("div",{style:{display:"flex",flexDirection:"column",gap:2,minWidth:0},children:[n("div",{style:{flex:1,minHeight:0,borderRadius:3,position:"relative",overflow:"hidden",background:r.ink},children:n("span",{style:{position:"absolute",left:"50%",top:"50%",transform:"translate(-50%,-50%)",width:26,height:26,borderRadius:"50%",border:`5px solid ${r.mark2}`,boxSizing:"border-box"}})}),n("span",{style:{fontSize:"3.32cqw",fontWeight:600,color:r.text,overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},children:e}),n("span",{style:{fontSize:"3.32cqw",color:r.muted},children:t})]},e))})}),tyresizes:n(K,{title:"Available sizes",children:n("div",{style:{flex:1,display:"flex",flexWrap:"wrap",gap:4,alignContent:"center"},children:["265/65R17","285/70R17","265/60R18","275/55R20"].map((e,t)=>n("span",{style:{fontSize:"3.65cqw",fontWeight:600,padding:"5px 7px",borderRadius:3,border:`1px solid ${t===0?r.rust:r.rule}`,color:t===0?r.rust:r.text,background:t===0?r.paper:r.card},children:e},e))})}),tyrefitment:p(K,{title:"Will it fit your car?",children:[n("div",{style:{display:"flex",gap:3},children:["Make","Model","Year","Trim"].map(e=>p("span",{style:{flex:1,minWidth:0,fontSize:"3.32cqw",color:r.muted,background:r.paper,border:`1px solid ${r.rule}`,borderRadius:3,padding:"4px 5px",display:"flex",justifyContent:"space-between",gap:2,overflow:"hidden",whiteSpace:"nowrap"},children:[e," ",n("span",{style:{color:r.muted},children:"\u25BE"})]},e))}),n("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:2,justifyContent:"center",minHeight:0},children:[["265/65R17","Fits",!0],["285/70R17","Not your size",!1]].map(([e,t,o])=>p("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"baseline",gap:6,borderTop:`1px solid ${r.rule}`,paddingTop:3},children:[n("span",{style:{fontSize:"3.32cqw",fontWeight:600,color:r.text},children:e}),n("span",{style:{fontSize:"3.32cqw",fontWeight:o?700:400,letterSpacing:"0.06em",color:o?r.warm:r.muted},children:t})]},e))})]}),eutyrelabel:p("div",{style:{...R,background:r.card,padding:"9px 11px",display:"flex",gap:8,alignItems:"center"},children:[n("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:1.5},children:[["A","42%"],["B","56%"],["C","70%"],["D","84%"]].map(([e,t],o)=>p("div",{style:{display:"flex",alignItems:"center",gap:3},children:[n("span",{style:{width:t,height:6,borderRadius:"0 2px 2px 0",background:o===1?r.rust:r.mark1}}),n("span",{style:{fontSize:"3.32cqw",fontWeight:700,color:o===1?r.rust:r.muted},children:e})]},e))}),p("div",{style:{flex:"none",display:"flex",flexDirection:"column",gap:3,alignItems:"center"},children:[n("b",{style:{fontSize:"6.63cqw",lineHeight:1,color:r.text},children:"72"}),n("span",{style:{fontSize:"3.32cqw",letterSpacing:"0.08em",color:r.muted},children:"dB"})]})]}),bundleoffer:p("div",{style:{...R,background:r.paper,padding:"9px 11px",display:"flex",flexDirection:"column",gap:5,justifyContent:"center"},children:[n(Ft,{children:"Buy it with"}),p("div",{style:{display:"flex",alignItems:"center",gap:5},children:[[0,1].map(e=>n("span",{style:{width:26,height:22,borderRadius:3,flex:"none",position:"relative",overflow:"hidden",background:r.card},children:n(Me,{size:17,style:{left:"50%",top:"50%",transform:"translate(-50%,-50%)"}})},e)),n("span",{style:{fontSize:"5.69cqw",fontWeight:700,color:r.muted},children:"+"}),p("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:1},children:[n("span",{style:{fontSize:"3.65cqw",color:r.muted,textDecoration:"line-through"},children:"$1,024"}),n("b",{style:{fontSize:"6.02cqw",color:r.rust,lineHeight:1},children:"$899"})]})]})]}),checkoutcta:p("div",{style:{...R,display:"flex",alignItems:"center",justifyContent:"space-between",padding:"0 13px",gap:8,...Y(r.ink,r.ink2)},children:[p("div",{style:{display:"flex",flexDirection:"column",gap:2},children:[n("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.12em",color:r.warm,fontWeight:700},children:"READY TO ORDER"}),n("b",{style:{fontSize:"6.63cqw",color:r.onInk,lineHeight:1},children:"$1,956"}),n("span",{style:{fontSize:"3.65cqw",color:r.onInk,opacity:.65},children:"4 items \xB7 fitted free"})]}),n("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"6px 10px",borderRadius:2,background:r.warm,color:r.ink,flex:"none"},children:"CHECKOUT"})]}),contact:n(K,{title:"Who do you need?",children:n("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:[["Fitment help","the workshop"],["Order status","the front desk"],["Trade accounts","sales"]].map(([e,t])=>p("div",{style:{display:"flex",alignItems:"center",gap:5},children:[n("b",{style:{flex:1,fontSize:"4.31cqw",color:r.text},children:e}),n("span",{style:{fontSize:"3.65cqw",color:r.muted},children:t}),n("span",{style:{fontSize:"4.64cqw",color:r.rust,lineHeight:1},children:"\u203A"})]},e))})}),contactlocations:n(K,{title:"Find us",children:n("div",{style:{flex:1,display:"grid",gridTemplateColumns:"repeat(2,1fr)",gap:5,minHeight:0},children:[["Brisbane","7 Kerry Rd","Mon\u2013Sat"],["Townsville","12 Enterprise","Mon\u2013Fri"]].map(([e,t,o])=>p("div",{style:{border:`1px solid ${r.rule}`,borderRadius:4,padding:"5px 6px",display:"flex",flexDirection:"column",gap:1},children:[n("b",{style:{fontSize:"4.31cqw",color:r.text},children:e}),n("span",{style:{fontSize:"3.32cqw",color:r.muted},children:t}),n("span",{style:{fontSize:"3.32cqw",color:r.rust,fontWeight:700},children:o})]},e))})}),form:n(K,{title:"Send us a message",children:p("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:[p("div",{style:{display:"flex",gap:5},children:[n(zn,{label:"Name"}),n(zn,{label:"Email"})]}),n(zn,{label:"Message",filled:!0}),n(ml,{children:"SEND"})]})}),appointmentbooking:n(K,{title:"Book a fitting",children:p("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:[n("div",{style:{display:"flex",gap:3},children:["Mon","Tue","Wed","Thu"].map((e,t)=>n("span",{style:{flex:1,textAlign:"center",fontSize:"3.32cqw",fontWeight:t===2?700:500,padding:"4px 0",borderRadius:3,background:t===2?r.text:r.paper,color:t===2?r.onInk:r.muted},children:e},e))}),n("div",{style:{display:"flex",gap:3},children:["8:00","10:30","13:00","15:30"].map((e,t)=>n("span",{style:{flex:1,textAlign:"center",fontSize:"3.32cqw",padding:"4px 0",borderRadius:3,border:`1px solid ${t===1?r.rust:r.rule}`,color:t===1?r.rust:r.muted,background:t===3?r.paper:r.card,textDecoration:t===3?"line-through":"none"},children:e},e))})]})}),reviewform:n(K,{title:"Leave a review",children:p("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:5,justifyContent:"center"},children:[n(ir,{filled:4,size:14}),n(zn,{label:"Your review",filled:!0}),n(ml,{children:"POST"})]})}),submitbuild:n(K,{title:"Show us your build",children:p("div",{style:{flex:1,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:3,border:`1px dashed ${r.mark1}`,borderRadius:5,background:r.paper},children:[n("span",{style:{fontSize:"6.63cqw",lineHeight:1,color:r.rust,fontWeight:300},children:"+"}),n("span",{style:{fontSize:"3.65cqw",color:r.muted},children:"Drop a photo of your rig"})]})}),masthead:p("div",{style:{...R,background:r.paper,display:"flex",flexDirection:"column",justifyContent:"center",padding:"0 13px",gap:5},children:[n("span",{style:{height:1.5,background:r.text}}),n("span",{style:{fontSize:"7.65cqw",fontWeight:800,letterSpacing:"0.02em",color:r.text,lineHeight:1},children:"THE TRACK"}),p("div",{style:{display:"flex",justifyContent:"space-between",fontSize:"3.65cqw",letterSpacing:"0.1em",textTransform:"uppercase",color:r.muted},children:[n("span",{children:"Issue 14"}),n("span",{children:"Spring 2026"})]}),n("span",{style:{height:1,background:r.rule}})]}),featuredcover:p("div",{style:{...R,overflow:"hidden",...Y(r.ink,r.inkSoft2)},children:[n(Me,{size:92,style:{right:-18,top:-14}}),n("div",{style:{position:"absolute",inset:0,background:`linear-gradient(0deg,${r.scrim},transparent 62%)`}}),p("div",{style:{position:"absolute",left:12,right:12,bottom:11,display:"flex",flexDirection:"column",gap:3},children:[n("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.16em",fontWeight:700,color:r.warm},children:"FEATURE"}),n("span",{style:{fontSize:"6.16cqw",lineHeight:1.15,fontWeight:700,color:r.onInk},children:"Four days on the Madigan Line"})]})]}),longread:p("div",{style:{...R,background:r.card,padding:"10px 14px",display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:[n("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.14em",fontWeight:700,color:r.rust},children:"12 MIN READ"}),n("span",{style:{fontSize:"6.02cqw",lineHeight:1.15,fontWeight:700,color:r.text},children:"What breaks first, and why"}),n(ce,{children:"Every failure starts in the same place \u2014 not the rim, not"}),n(ce,{w:"62%",children:"the tyre, but the bolt nobody re-torqued."})]}),series:n(K,{title:"Recurring columns",children:n("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:5,justifyContent:"center"},children:[["Shed Notes","Monthly"],["Track Tested","Fortnightly"],["Reader Rigs","Weekly"]].map(([e,t])=>p("div",{style:{display:"flex",alignItems:"center",gap:6},children:[n("span",{style:{width:3,height:12,borderRadius:2,background:r.rust,flex:"none"}}),n("b",{style:{flex:1,fontSize:"4.64cqw",color:r.text},children:e}),n("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.08em",textTransform:"uppercase",color:r.muted},children:t})]},e))})}),events:n(K,{title:"Latest posts",children:n("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:5,justifyContent:"center"},children:[[r.inkSoft,r.inkSoft2,"Madigan Line, four days"],[r.rust,r.warm,"Why offset beats width"]].map(([e,t,o])=>p("div",{style:{display:"flex",gap:6,alignItems:"center"},children:[n("span",{style:{width:24,height:18,borderRadius:3,flex:"none",...Y(e,t,150)}}),p("div",{style:{display:"flex",flexDirection:"column",gap:1,minWidth:0},children:[n("b",{style:{fontSize:"4.31cqw",color:r.text},children:o}),n("span",{style:{fontSize:"3.65cqw",color:r.muted},children:"4 Sep \xB7 Shed Notes"})]})]},o))})}),docmasthead:p("div",{style:{...R,background:r.card,padding:"12px 14px",display:"flex",flexDirection:"column",gap:5,justifyContent:"center"},children:[n("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.16em",fontWeight:700,color:r.muted},children:"POLICY"}),n("span",{style:{fontSize:"6.49cqw",fontWeight:700,color:r.text,lineHeight:1.1},children:"Returns & refunds"}),n("span",{style:{fontSize:"3.65cqw",color:r.muted},children:"Version 3 \xB7 Updated 4 Sep 2026"}),n("span",{style:{height:2,width:26,background:r.rust,borderRadius:1}})]}),docbody:n("div",{style:{...R,background:r.card,padding:"9px 13px",display:"flex",flexDirection:"column",gap:3,justifyContent:"center"},children:[["1.","You may return an unfitted wheel within 30 days."],["2.","Fitted wheels are covered by the structural warranty."],["3.","Freight on a change of mind is yours."]].map(([e,t])=>p("div",{style:{display:"flex",gap:5},children:[n("b",{style:{fontSize:"3.98cqw",color:r.rust,flex:"none"},children:e}),n(ce,{children:t})]},e))}),docmetacards:n(K,{title:"At a glance",children:n("div",{style:{flex:1,display:"grid",gridTemplateColumns:"repeat(2,1fr)",gap:5,minHeight:0},children:[["30 days","To return"],["5 years","Structural"],["Free","Fitting"],["48 hrs","Dispatch"]].map(([e,t])=>p("div",{style:{border:`1px solid ${r.rule}`,borderRadius:4,padding:"5px 6px",display:"flex",flexDirection:"column",gap:1},children:[n("b",{style:{fontSize:"5.31cqw",color:r.text,lineHeight:1},children:e}),n("span",{style:{fontSize:"3.32cqw",letterSpacing:"0.08em",textTransform:"uppercase",color:r.muted},children:t})]},t))})}),doctabs:p("div",{style:{...R,background:r.card,display:"flex",flexDirection:"column",justifyContent:"center",gap:0,padding:"0 11px"},children:[n("div",{style:{display:"flex",gap:0},children:["Returns","Warranty","Shipping"].map((e,t)=>n("span",{style:{fontSize:"3.98cqw",fontWeight:t===0?700:500,padding:"5px 8px",color:t===0?r.text:r.muted,background:t===0?r.paper:"transparent",borderRadius:"4px 4px 0 0",border:`1px solid ${t===0?r.rule:"transparent"}`,borderBottom:"none"},children:e},e))}),n("span",{style:{height:1,background:r.rule}}),p("div",{style:{paddingTop:6,display:"flex",flexDirection:"column",gap:2},children:[n(ce,{children:"Unfitted wheels come back within 30 days, no questions."}),n(ce,{w:"58%",children:"Freight on a change of mind is yours."})]})]}),paragraphs:p("div",{style:{...R,background:r.card,padding:"11px 14px",display:"flex",gap:10,alignItems:"center"},children:[n("span",{style:{flex:1,fontSize:"5.86cqw",lineHeight:1.2,fontWeight:700,color:r.text},children:"The right wheel is the boring one."}),p("div",{style:{flex:1,display:"flex",flexDirection:"column"},children:[n(ce,{children:"Forged, correctly offset, rated for what you actually"}),n(ce,{children:"carry. Everything else is a photograph."})]})]}),keyfeatures:n(K,{title:"Key features",children:n("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:["Flow-formed barrel","1250 kg per corner","Hub-centric fit"].map(e=>p("div",{style:{display:"flex",gap:6,alignItems:"center"},children:[n("span",{style:{fontSize:"4.64cqw",color:r.rust,fontWeight:700,lineHeight:1},children:"\u2713"}),n("span",{style:{fontSize:"4.31cqw",color:r.text},children:e})]},e))})}),statsparagraph:p("div",{style:{...R,background:r.paper,padding:"10px 12px",display:"flex",gap:10,alignItems:"center"},children:[p("div",{style:{flex:"none",display:"flex",flexDirection:"column",gap:5},children:[n(Dt,{n:"27k",label:"Rigs"}),n(Dt,{n:"4.9",label:"Rating"})]}),p("div",{style:{flex:1,display:"flex",flexDirection:"column"},children:[n(ce,{children:"Twelve years of fitting the same three questions, and the"}),n(ce,{children:"answer has not moved: load rating, offset, then looks."})]})]}),chart:p(K,{title:"Load vs weight",children:[n("div",{style:{flex:1,display:"flex",alignItems:"flex-end",gap:5,paddingBottom:2},children:[38,62,84,71,96].map((e,t)=>n("span",{style:{flex:1,height:`${e}%`,borderRadius:"2px 2px 0 0",background:t===4?r.rust:r.mark1}},t))}),n("span",{style:{height:1,background:r.rule,marginTop:-4}})]}),mockup:n("div",{style:{...R,overflow:"hidden",display:"flex",alignItems:"center",justifyContent:"center",...Y(r.inkSoft,r.ink)},children:p("div",{style:{width:"72%",height:"74%",borderRadius:4,overflow:"hidden",background:r.card,boxShadow:`0 6px 14px ${r.scrim}`},children:[n("div",{style:{height:9,background:r.paper,display:"flex",alignItems:"center",gap:2,padding:"0 4px"},children:[0,1,2].map(e=>n("span",{style:{width:2.5,height:2.5,borderRadius:"50%",background:r.mark1}},e))}),p("div",{style:{padding:5,display:"flex",flexDirection:"column",gap:3},children:[n("span",{style:{height:4,width:"56%",borderRadius:1,background:r.mark2}}),n("span",{style:{height:14,borderRadius:2,...Y(r.paper,r.paper2,150)}}),n("span",{style:{height:3,width:"38%",borderRadius:1,background:r.rust}})]})]})}),manifesto:n("div",{style:{...R,overflow:"hidden",display:"flex",alignItems:"center",padding:"0 16px",...Y(r.ink,r.ink2)},children:p("span",{style:{fontSize:"6.63cqw",lineHeight:1.2,fontWeight:700,color:r.onInk},children:["We build for the ",n("span",{style:{color:r.warm},children:"last"})," ten percent of the track."]})}),timeline:n(K,{title:"Our story",children:n("div",{style:{flex:1,display:"flex",flexDirection:"column",justifyContent:"center",gap:6,paddingLeft:4},children:[["1998","One shed, one lathe."],["2009","First forged rim."],["2024","27,000 rigs on."]].map(([e,t],o)=>p("div",{style:{display:"flex",gap:7,alignItems:"flex-start",position:"relative"},children:[o<2&&n("span",{style:{position:"absolute",left:3,top:8,bottom:-8,width:1,background:r.rule}}),n("span",{style:{width:7,height:7,borderRadius:"50%",flex:"none",marginTop:1,background:r.rust,zIndex:1}}),p("div",{style:{display:"flex",flexDirection:"column",gap:0,minWidth:0},children:[n("b",{style:{fontSize:"4.64cqw",color:r.text},children:e}),n(ce,{children:t})]})]},e))})}),timelinetrack:p("div",{style:{...R,padding:"0 12px",display:"flex",flexDirection:"column",gap:10,justifyContent:"center",...Y(r.ink,r.inkSoft)},children:[n("span",{style:{fontSize:"3.98cqw",fontWeight:700,letterSpacing:"0.14em",textTransform:"uppercase",color:r.warm},children:"Milestones"}),p("div",{style:{position:"relative",display:"flex",justifyContent:"space-between",paddingTop:7},children:[n("span",{style:{position:"absolute",left:0,right:0,top:3,height:1,background:r.mark2,opacity:.55}}),["1998","2009","2016","2024"].map((e,t)=>p("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",gap:3,position:"relative"},children:[n("span",{style:{position:"absolute",top:-7,width:6,height:6,borderRadius:"50%",background:t===3?r.warm:r.mark1}}),n("span",{style:{fontSize:"4.31cqw",fontWeight:700,color:t===3?r.warm:r.onInk,opacity:t===3?1:.75},children:e})]},e))]})]}),footprint:p("div",{style:{...R,overflow:"hidden",...Y(r.paper,r.paper2,150)},children:[n("span",{style:{position:"absolute",left:"8%",top:"18%",width:"62%",height:"64%",borderRadius:"48% 52% 40% 60% / 55% 45% 55% 45%",background:r.mark1,opacity:.75}}),n("span",{style:{position:"absolute",left:"52%",top:"52%",width:"34%",height:"34%",borderRadius:"58% 42% 55% 45% / 45% 58% 42% 55%",background:r.mark2,opacity:.55}}),[["26%","38%"],["44%","58%"],["62%","34%"]].map(([e,t])=>n("span",{style:{position:"absolute",left:e,top:t,width:7,height:7,borderRadius:"50% 50% 50% 0",transform:"rotate(-45deg)",background:r.rust}},e)),n("span",{style:{position:"absolute",left:11,bottom:9,fontSize:"4.64cqw",fontWeight:700,color:r.text},children:"3 fitting bays"})]}),banner:p("div",{style:{...R,display:"flex",alignItems:"center",justifyContent:"space-between",padding:"0 13px",gap:8,background:r.rust},children:[p("div",{style:{display:"flex",flexDirection:"column",gap:2},children:[n("b",{style:{fontSize:"6.02cqw",color:r.onInk},children:"End of season \xB7 20% off"}),n("span",{style:{fontSize:"3.98cqw",color:r.onInk,opacity:.8},children:"Fitted free, this month only."})]}),n("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"5px 9px",borderRadius:2,background:r.onInk,color:r.text,flex:"none"},children:"SHOP"})]}),titlewithbuttons:p("div",{style:{...R,background:r.paper,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:7,padding:"0 14px",textAlign:"center"},children:[n("span",{style:{fontSize:"6.49cqw",lineHeight:1.15,fontWeight:700,color:r.text},children:"Not sure what fits?"}),p("div",{style:{display:"flex",gap:5},children:[n("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"5px 9px",borderRadius:2,background:r.text,color:r.onInk},children:"FIND MY FIT"}),n("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"5px 9px",borderRadius:2,border:`1px solid ${r.text}`,color:r.text},children:"CALL US"})]})]}),ticker:n("div",{style:{...R,overflow:"hidden",background:r.ink,display:"flex",alignItems:"center"},children:n("span",{style:{whiteSpace:"nowrap",fontSize:"6.29cqw",fontWeight:800,letterSpacing:"0.06em",color:r.warm,marginLeft:-14},children:"FREE FITTING \xB7 48HR DISPATCH \xB7 FREE FITTING \xB7 48HR DISPATCH"})}),countdown:p("div",{style:{...R,padding:"10px 12px",display:"flex",flexDirection:"column",alignItems:"center",gap:6,justifyContent:"center",...Y(r.ink,r.ink2)},children:[n("span",{style:{fontSize:"3.65cqw",fontWeight:700,letterSpacing:"0.16em",textTransform:"uppercase",color:r.muted},children:"Back online in"}),n("div",{style:{display:"flex",alignItems:"flex-start",gap:5},children:[["23","Hours"],["59","Minutes"],["48","Seconds"]].map(([e,t],o)=>p("div",{style:{display:"flex",alignItems:"flex-start",gap:5},children:[o>0&&n("b",{style:{fontSize:"9.5cqw",lineHeight:1,color:r.warm},children:":"}),p("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",gap:2},children:[n("b",{style:{fontSize:"11.5cqw",lineHeight:1,color:r.onInk,fontVariantNumeric:"tabular-nums"},children:e}),n("span",{style:{fontSize:"3.2cqw",letterSpacing:"0.1em",textTransform:"uppercase",opacity:.62,color:r.onInk},children:t})]})]},t))})]}),breadcrumb:n("div",{style:{...R,background:r.card,display:"flex",alignItems:"center",padding:"0 13px"},children:p("span",{style:{fontSize:"4.64cqw",color:r.muted},children:["Home ",n("span",{style:{opacity:.5},children:"/"})," Wheels ",n("span",{style:{opacity:.5},children:"/"})," ",n("span",{style:{color:r.text,fontWeight:700},children:"20 inch"})]})}),categorybar:p("div",{style:{...R,background:r.card,display:"flex",flexDirection:"column",justifyContent:"center",gap:7,padding:"0 11px"},children:[n("div",{style:{display:"flex",gap:5},children:["All","Wheels","Tyres","Lift"].map((e,t)=>n("span",{style:{fontSize:"3.98cqw",fontWeight:t===0?700:500,padding:"4px 7px",borderRadius:99,background:t===0?r.text:r.paper,color:t===0?r.onInk:r.muted},children:e},e))}),n("span",{style:{height:1,background:r.rule}})]}),intro:p("div",{style:{...R,overflow:"hidden",background:r.card},children:[n("div",{style:{position:"absolute",inset:0,...Y(r.ink,r.inkSoft2)}}),n(Me,{size:64,style:{right:8,top:6}}),p("div",{style:{position:"absolute",left:16,right:16,bottom:8,top:"46%",background:r.paper,borderRadius:6,padding:"8px 11px",display:"flex",flexDirection:"column",gap:2,boxShadow:`0 -4px 10px ${r.scrim}`},children:[n("span",{style:{fontSize:"5.69cqw",fontWeight:700,color:r.text},children:"Since 1998"}),n(ce,{children:"One shed, one lathe, one idea."}),n(ce,{w:"66%",children:"It turned out to be right."})]})]}),gallerygrid:n(K,{title:"From our customers",children:n("div",{style:{flex:1,display:"grid",gridTemplateColumns:"repeat(3,1fr)",gridTemplateRows:"repeat(2,1fr)",gap:4,minHeight:0},children:[[r.rust,r.warm],[r.inkSoft,r.ink],[r.paper2,r.mark2],[r.ink,r.inkSoft2],[r.warm,r.paper2],[r.mark2,r.inkSoft]].map(([e,t],o)=>n("div",{style:{borderRadius:3,...Y(e,t,140+o*22)}},o))})}),gallery:p(K,{title:"Gallery",children:[n("div",{style:{display:"flex",gap:8,alignItems:"center",marginTop:-2},children:["On the truck","Studio","Close-ups"].map((e,t)=>n("span",{style:{fontSize:"3.98cqw",fontWeight:t===0?700:500,color:t===0?r.text:r.muted,borderBottom:`1.5px solid ${t===0?r.rust:"transparent"}`,paddingBottom:2},children:e},e))}),n("div",{style:{flex:1,display:"grid",gridTemplateColumns:"repeat(3,1fr)",gap:4,minHeight:0},children:[[r.rust,r.warm],[r.ink,r.inkSoft],[r.paper2,r.mark2]].map(([e,t],o)=>n("div",{style:{borderRadius:3,...Y(e,t,150+o*20)}},o))})]}),ordersummary:p(K,{title:"Order summary",children:[p("div",{style:{display:"flex",gap:6,alignItems:"center",paddingBottom:4},children:[n("span",{style:{width:26,height:26,borderRadius:4,position:"relative",overflow:"hidden",flex:"none",...Y(r.paper,r.paper2,150)},children:n(Me,{size:18,style:{left:"50%",top:"50%",transform:"translate(-50%,-50%)"}})}),p("div",{style:{display:"flex",flexDirection:"column",gap:1,minWidth:0},children:[n("b",{style:{fontSize:"4.31cqw",color:r.text},children:"Ridge Grappler"}),n("span",{style:{fontSize:"3.65cqw",color:r.muted},children:"20\xD79 +12 \xB7 qty 4"})]})]}),p("div",{style:{flex:1,minHeight:0,display:"flex",flexDirection:"column",justifyContent:"center"},children:[n(He,{k:"Subtotal",v:"$1,956"}),n(He,{k:"Fitting",v:"Free"}),p("div",{style:{display:"flex",justifyContent:"space-between",paddingTop:5,fontSize:"4.64cqw"},children:[n("b",{style:{color:r.text},children:"Total"}),n("b",{style:{color:r.text,fontSize:"6.02cqw"},children:"$1,956"})]})]})]}),deliveryoptions:n(K,{title:"Delivery",children:n("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:[["Standard","3\u20135 days","Free",!0],["Express","Next day","$19",!1]].map(([e,t,o,a])=>p("div",{style:{display:"flex",alignItems:"center",gap:6,padding:"5px 6px",borderRadius:4,border:`1px solid ${a?r.rust:r.rule}`,background:a?r.paper:r.card},children:[n("span",{style:{width:7,height:7,borderRadius:"50%",flex:"none",border:`1.5px solid ${a?r.rust:r.mark1}`,background:a?r.rust:"transparent"}}),n("span",{style:{flex:1,fontSize:"4.31cqw",fontWeight:600,color:r.text},children:e}),n("span",{style:{fontSize:"3.98cqw",color:r.muted},children:t}),n("b",{style:{fontSize:"4.31cqw",color:r.text},children:o})]},e))})}),paymentbadges:p("div",{style:{...R,background:r.paper,display:"flex",flexDirection:"column",gap:8,justifyContent:"center",padding:"0 12px"},children:[n(Ft,{children:"Ways to pay"}),n("div",{style:{display:"flex",gap:5},children:[["VISA",r.ink],["MC",r.rust],["AMEX",r.inkSoft],["PayPal",r.ink2]].map(([e,t])=>n("span",{style:{flex:1,textAlign:"center",fontSize:"3.65cqw",fontWeight:800,letterSpacing:"0.06em",color:r.onInk,borderRadius:3,padding:"6px 0",background:t},children:e},e))})]}),stats:p("div",{style:{...R,padding:"10px 12px",display:"flex",flexDirection:"column",gap:9,justifyContent:"center",...Y(r.ink,r.ink2)},children:[n("span",{style:{fontSize:"3.98cqw",fontWeight:700,letterSpacing:"0.14em",textTransform:"uppercase",color:r.warm},children:"By the numbers"}),p("div",{style:{display:"flex",gap:8},children:[n(Dt,{n:"27k",label:"Rigs fitted",tone:r.onInk}),n(Dt,{n:"12",label:"Years",tone:r.onInk}),n(Dt,{n:"4.9",label:"Avg rating",tone:r.warm})]})]}),testimonials:p("div",{style:{...R,overflow:"hidden",background:r.paper,padding:"10px 11px",display:"flex",flexDirection:"column",gap:6,justifyContent:"center"},children:[n("span",{style:{position:"absolute",right:10,top:2,fontSize:"22.4cqw",lineHeight:1,fontWeight:800,color:r.rust,opacity:.16},children:"\u201D"}),n(ir,{filled:5,size:7}),n("span",{style:{position:"relative",fontSize:"5.31cqw",lineHeight:1.35,color:r.text,fontWeight:600},children:"\u201CTook them out to the Simpson and back. Not one chip.\u201D"}),p("div",{style:{display:"flex",alignItems:"center",gap:5},children:[n(fl,{}),n("span",{style:{fontSize:"3.98cqw",color:r.muted},children:"Dave M. \xB7 Hilux N80"})]})]}),reviews:p(K,{title:"Reviews",children:[n("div",{style:{display:"flex",gap:4,height:22},children:[[r.inkSoft,r.inkSoft2],[r.rust,r.warm],[r.ink,r.inkSoft],[r.mark2,r.mark1]].map(([e,t],o)=>n("div",{style:{flex:1,borderRadius:3,...Y(e,t,140+o*15)}},o))}),n("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:5,justifyContent:"center"},children:[["Dave M.",5,"Not one chip after the Simpson."],["Sara K.",4,"Fitted in an hour, no fuss."]].map(([e,t,o])=>p("div",{style:{display:"flex",gap:5,alignItems:"flex-start"},children:[n(fl,{size:12}),p("div",{style:{display:"flex",flexDirection:"column",gap:1,minWidth:0},children:[p("div",{style:{display:"flex",gap:4,alignItems:"center"},children:[n("b",{style:{fontSize:"3.98cqw",color:r.text},children:e}),n(ir,{filled:t})]}),n(ce,{children:o})]})]},e))})]}),logos:p("div",{style:{...R,display:"flex",flexDirection:"column",gap:9,justifyContent:"center",padding:"0 12px",...Y(r.ink,r.inkSoft)},children:[n("span",{style:{fontSize:"3.98cqw",fontWeight:700,letterSpacing:"0.14em",textTransform:"uppercase",color:r.warm},children:"As fitted by"}),n("div",{style:{display:"grid",gridTemplateColumns:"repeat(4,1fr)",gap:8},children:["ARB","TJM","IRONMAN","OPPOSITE"].map(e=>n("span",{style:{textAlign:"center",fontSize:"4.31cqw",fontWeight:800,letterSpacing:"0.08em",color:r.onInk,opacity:.82},children:e},e))})]}),prose:p("div",{style:{...R,background:r.paper,padding:"11px 14px",display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:[n("span",{style:{fontSize:"5.86cqw",fontWeight:700,color:r.text},children:"Why offset matters"}),p("div",{style:{display:"flex",gap:6},children:[n("span",{style:{fontSize:"15.3cqw",lineHeight:.78,fontWeight:800,color:r.rust,marginTop:1},children:"T"}),p("div",{style:{display:"flex",flexDirection:"column"},children:[n(ce,{children:"he number on the back of your wheel decides whether the"}),n(ce,{w:"76%",children:"tyre sits under the guard or an inch outside it."})]})]})]}),cards:n(K,{title:"What you get",children:n("div",{style:{flex:1,display:"grid",gridTemplateColumns:"repeat(3,1fr)",gap:5,minHeight:0},children:[["Fitted free","In store, same day."],["5 yr cover","Structural, no fine print."],["Swap it","30 days, any reason."]].map(([e,t])=>p("div",{style:{border:`1px solid ${r.rule}`,borderRadius:4,padding:6,display:"flex",flexDirection:"column",gap:2},children:[n("span",{style:{width:11,height:11,borderRadius:3,background:r.rust,opacity:.9}}),n("b",{style:{fontSize:"3.98cqw",color:r.text},children:e}),n(ce,{children:t})]},e))})}),faq:n(K,{title:"Questions",children:n("div",{style:{flex:1,display:"flex",flexDirection:"column",justifyContent:"center"},children:[["Will these fit my Hilux?",!0],["Do you fit them for me?",!1],["What if I pick wrong?",!1]].map(([e,t])=>p("div",{style:{borderBottom:`1px solid ${r.rule}`,padding:"4px 2px"},children:[p("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",gap:6},children:[n("b",{style:{fontSize:"4.31cqw",color:r.text},children:e}),n("span",{style:{fontSize:"4.64cqw",color:r.muted,lineHeight:1},children:t?"\u2212":"+"})]}),t&&n(ce,{w:"90%",children:"Use the fitment finder \u2014 it reads your build, not just the model."})]},e))})}),hero:p("div",{style:{...R,overflow:"hidden",...Y(r.ink,r.ink2)},children:[n("div",{style:{...R,background:`linear-gradient(90deg,${r.scrim},transparent 70%)`}}),n("div",{style:{position:"relative",height:"100%",display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"flex-start",padding:"12px 14px",gap:5},children:n(ul,{over:"NEW \xB7 SUMMER",overTone:r.warm,head:"Built for the worst road you own",cta:"SHOP ALL",ctaBg:r.warm,ctaFg:r.ink,tone:r.onInk})}),n(Me,{size:104,style:{right:-24,bottom:-30}})]}),herosingle:p("div",{style:{...R,display:"flex",background:r.paper,overflow:"hidden"},children:[n("div",{style:{flex:1,padding:12,display:"flex",flexDirection:"column",gap:5,justifyContent:"center"},children:n(ul,{over:"ALL-TERRAIN",overTone:r.rust,head:"Grip that does not ask",headSize:12,cta:"EXPLORE",ctaBg:r.text,ctaFg:r.onInk,tone:r.text})}),n("div",{style:{flex:1,position:"relative",...Y(r.inkSoft,r.inkSoft2)},children:n(Me,{size:74,style:{right:-14,top:16}})})]}),productgrid:n(K,{title:"Best sellers",children:p("div",{style:{flex:1,display:"grid",gridTemplateColumns:"repeat(3,1fr)",gap:5,minHeight:0},children:[n(rr,{name:"Ridge 19",price:"$365"}),n(rr,{name:"Ridge 29",price:"$410"}),n(rr,{name:"Ridge 39",price:"$455"})]})}),collections:n(K,{title:"Shop by category",children:n("div",{style:{flex:1,display:"grid",gridTemplateColumns:"repeat(3,1fr)",gap:5,minHeight:0},children:[["Wheels",r.inkSoft,r.inkSoft2],["Tyres",r.rust,r.warm],["Lift kits",r.ink,r.inkSoft]].map(([e,t,o])=>n("div",{style:{borderRadius:4,display:"flex",alignItems:"flex-end",padding:5,color:r.onInk,...Y(t,o)},children:n("span",{style:{fontSize:"3.98cqw",fontWeight:700,letterSpacing:"0.04em"},children:e})},e))})}),producthero:p("div",{style:{...R,display:"flex",background:r.card,overflow:"hidden"},children:[n("div",{style:{flex:1.1,position:"relative",...Y(r.paper,r.paper2,150)},children:n(Me,{size:78,style:{left:"50%",top:"50%",transform:"translate(-50%,-50%)"}})}),p("div",{style:{flex:1,padding:"10px 10px 10px 8px",display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:[n("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.16em",fontWeight:700,color:r.rust},children:"NITTO"}),n("b",{style:{fontSize:"6.29cqw",color:r.text},children:"Ridge Grappler"}),n("span",{style:{fontSize:"6.63cqw",fontWeight:700,color:r.text},children:"$489"}),n("span",{style:{alignSelf:"flex-start",fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"4px 8px",borderRadius:2,background:r.text,color:r.onInk},children:"ADD TO CART"})]})]}),spectable:n(K,{title:"Specifications",children:p("div",{style:{flex:1,display:"flex",flexDirection:"column",justifyContent:"center"},children:[n(He,{k:"Diameter",v:'20"'}),n(He,{k:"Width",v:"9.0J"}),n(He,{k:"Offset",v:"+12"}),n(He,{k:"Load",v:"1250 kg"})]})}),fitmenttable:n(K,{title:"Will it fit?",children:p("div",{style:{flex:1,display:"flex",flexDirection:"column",justifyContent:"center"},children:[n(He,{k:"Hilux N80",v:"20\xD79 +12",ok:!0}),n(He,{k:"Ranger PX3",v:"20\xD79 +12",ok:!0}),n(He,{k:"LC79",v:"17\xD78 \u221210",ok:!0})]})}),brandstrip:p("div",{style:{...R,background:r.paper,display:"flex",flexDirection:"column",gap:8,justifyContent:"center",padding:"0 12px"},children:[n(Ft,{children:"Brands we carry"}),n("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:["NITTO","BFG","FUEL","TOYO"].map(e=>n("span",{style:{fontSize:"4.64cqw",fontWeight:800,letterSpacing:"0.1em",color:r.mark2},children:e},e))})]}),processsteps:p("div",{style:{...R,background:r.paper,padding:10,display:"flex",flexDirection:"column",gap:7,justifyContent:"center"},children:[n(Ft,{children:"How it works"}),n("div",{style:{display:"flex",gap:6},children:["Pick your rig","Match the fit","We fit it"].map((e,t)=>p("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:2},children:[n("span",{style:{width:11,height:11,borderRadius:"50%",background:r.text,color:r.onInk,fontSize:"3.98cqw",display:"flex",alignItems:"center",justifyContent:"center",fontWeight:700},children:t+1}),n("span",{style:{fontSize:"3.98cqw",color:r.text,fontWeight:600},children:e})]},e))})]}),detailrows:n("div",{style:{...R,background:r.card,display:"flex",flexDirection:"column",overflow:"hidden"},children:[["Forged, not cast","Half the weight, twice the road.",!1],["Fits your load","Rated to 1250 kg a corner.",!0]].map(([e,t,o])=>{let a=n("div",{style:{flex:1,...Y(o?r.rust:r.inkSoft,o?r.warm:r.inkSoft2)}},"art"),s=p("div",{style:{flex:1.1,padding:8,display:"flex",flexDirection:"column",gap:2,justifyContent:"center"},children:[n("b",{style:{fontSize:"4.64cqw",color:r.text},children:e}),n("span",{style:{fontSize:"3.98cqw",color:r.muted,lineHeight:1.3},children:t})]},"tx");return n("div",{style:{flex:1,display:"flex",minHeight:0},children:o?[s,a]:[a,s]},e)})}),specstrip:n("div",{style:{...R,background:r.ink,color:r.onInk,display:"flex",alignItems:"center",justifyContent:"space-around",padding:"0 8px"},children:[["5 yr","Warranty"],["Free","Fitting"],["48 hr","Dispatch"]].map(([e,t])=>p("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",gap:1},children:[n("b",{style:{fontSize:"5.69cqw",letterSpacing:"0.02em"},children:e}),n("span",{style:{fontSize:"3.65cqw",color:r.mark2,letterSpacing:"0.1em",textTransform:"uppercase"},children:t})]},t))})},gl={subscribe:p("div",{style:{...R,padding:13,display:"flex",flexDirection:"column"},children:[p("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",marginBottom:8},children:[p("div",{style:{display:"flex",alignItems:"center",gap:6},children:[n(T,{w:8,h:8,r:2,tone:"accent"}),n(T,{w:38,h:7,r:3,tone:"dark"}),n(T,{w:16,h:7,r:3,tone:"accent"})]}),n(T,{w:38,h:4,r:2,tone:"soft"})]}),n("div",{style:{height:1,background:se.line,marginBottom:10}}),p("div",{style:{flex:1,display:"flex",gap:10,border:`1px solid ${se.line}`,borderRadius:7,padding:10},children:[p("div",{style:{flex:1.1,display:"flex",flexDirection:"column",justifyContent:"center",gap:5},children:[n(T,{w:"46%",h:3,r:2,tone:"accent"}),n(T,{w:"84%",h:8,r:4,tone:"dark"}),n(T,{w:"56%",h:8,r:4,tone:"accent"}),n(T,{w:"96%",h:3,r:2,tone:"soft",style:{marginTop:2}}),p("div",{style:{display:"flex",gap:5,marginTop:4},children:[n("div",{style:{flex:1,height:13,borderRadius:5,border:`1px solid ${se.line}`,background:se.block}}),n(T,{w:34,h:13,r:5,tone:"accent"})]})]}),p("div",{style:{flex:1,background:se.block,borderRadius:6,padding:8,display:"flex",flexDirection:"column",gap:6},children:[n(T,{w:"52%",h:4,r:2,tone:"accent"}),Array.from({length:3}).map((e,t)=>p("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",gap:6,borderTop:t?`1px solid ${se.line}`:"none",paddingTop:t?4:0},children:[n(T,{w:34,h:4,r:2,tone:"dark"}),n(T,{w:16,h:3,r:2,tone:"soft"})]},t))]})]})]}),split:p("div",{style:{...R,display:"flex"},children:[n("div",{style:{width:"44%",background:or}}),p("div",{style:{flex:1,padding:15,display:"flex",flexDirection:"column",justifyContent:"center",gap:7},children:[n(T,{w:"44%",h:5,r:3,tone:"accent"}),n(T,{w:"88%",h:8,r:4,tone:"dark"}),n(T,{w:"70%",h:8,r:4,tone:"dark"}),n(T,{w:"94%",h:5,r:2,tone:"soft",style:{marginTop:2}}),n(T,{w:"80%",h:5,r:2,tone:"soft"}),n(T,{w:"40%",h:13,r:6,tone:"accent",style:{marginTop:5}})]})]}),sectionheader:p(yl,{children:[n(T,{w:"18%",h:6,r:3,tone:"accent",style:{position:"absolute",top:15,right:16}}),p("div",{style:{...R,padding:16,display:"flex",flexDirection:"column",justifyContent:"center",gap:10},children:[p("div",{style:{display:"flex",alignItems:"center",gap:9},children:[n(T,{w:16,h:16,r:4,tone:"accent"}),n(T,{w:"20%",h:9,r:4,tone:"dark"})]}),n(T,{w:"62%",h:10,r:5,tone:"dark"}),n(T,{w:"42%",h:6,r:3,tone:"soft"})]})]}),header:n("div",{style:{...R,padding:14,display:"flex",flexDirection:"column",justifyContent:"center"},children:p("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between"},children:[n(T,{w:"22%",h:12,r:4,tone:"dark"}),p("div",{style:{display:"flex",gap:9,alignItems:"center"},children:[n(T,{w:26,h:6,r:3,tone:"soft"}),n(T,{w:26,h:6,r:3,tone:"soft"}),n(T,{w:26,h:6,r:3,tone:"soft"}),n(T,{w:18,h:14,r:5,tone:"accent"})]})]})}),footer:p("div",{style:{...R,padding:15,display:"flex",flexDirection:"column",justifyContent:"center",gap:12},children:[p("div",{style:{display:"flex",gap:14},children:[p("div",{style:{flex:1.4,display:"flex",flexDirection:"column",gap:6},children:[n(T,{w:"60%",h:9,r:4,tone:"dark"}),n(T,{w:"90%",h:5,r:2,tone:"soft"}),n(T,{w:"70%",h:5,r:2,tone:"soft"})]}),[0,1].map(e=>p("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:6},children:[n(T,{w:"50%",h:6,r:3,tone:"dark"}),n(T,{w:"80%",h:5,r:2,tone:"soft"}),n(T,{w:"66%",h:5,r:2,tone:"soft"})]},e))]}),n("div",{style:{height:1,background:se.line}}),p("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[n(T,{w:"30%",h:5,r:2,tone:"soft"}),n(T,{w:"16%",h:5,r:2,tone:"soft"})]})]}),grid:n("div",{style:{...R,padding:14,display:"grid",gridTemplateColumns:"1fr 1fr",gridTemplateRows:"1fr 1fr",gap:9},children:Array.from({length:4}).map((e,t)=>n("div",{style:{borderRadius:6,background:se.block}},t))}),blanksection:n("div",{style:{...R,padding:14,display:"flex"},children:p("div",{style:{flex:1,border:`1px dashed ${se.line}`,borderRadius:7,display:"flex",alignItems:"center",justifyContent:"center",position:"relative"},children:[n(T,{w:14,h:2,r:1,tone:"tint"}),n(T,{w:2,h:14,r:1,tone:"tint",style:{position:"absolute"}})]})}),spacer:p("div",{style:{...R,padding:14,display:"flex",flexDirection:"column",justifyContent:"space-between"},children:[n(T,{w:"100%",h:6,r:3,tone:"soft"}),n(T,{w:16,h:22,r:3,tone:"block",style:{alignSelf:"center"}}),n(T,{w:"100%",h:6,r:3,tone:"soft"})]}),divider:n("div",{style:{...R,padding:14,display:"flex",alignItems:"center"},children:n(T,{w:"100%",h:3,r:2,tone:"dark"})}),customhtml:p("div",{style:{...R,display:"flex",alignItems:"center",justifyContent:"center",gap:8,background:or},children:[n(T,{w:5,h:16,r:2,tone:"dark",style:{transform:"skewX(-14deg)"}}),n(T,{w:16,h:10,r:3,tone:"accent"}),n(T,{w:5,h:16,r:2,tone:"dark",style:{transform:"skewX(14deg)"}})]}),heading:n("div",{style:{...R,padding:14,display:"flex",alignItems:"center"},children:n(T,{w:"64%",h:13,r:4,tone:"dark"})}),text:p("div",{style:{...R,padding:16,display:"flex",flexDirection:"column",justifyContent:"center",gap:7},children:[n(T,{w:"100%",h:6,r:3,tone:"soft"}),n(T,{w:"96%",h:6,r:3,tone:"soft"}),n(T,{w:"100%",h:6,r:3,tone:"soft"}),n(T,{w:"58%",h:6,r:3,tone:"soft"})]}),image:n("div",{style:{position:"absolute",inset:14,borderRadius:7,background:or}}),button:n("div",{style:{...R,display:"flex",alignItems:"center",justifyContent:"center"},children:n(T,{w:"34%",h:16,r:8,tone:"accent"})}),menu:p("div",{style:{...R,padding:"14px 22%",display:"flex",flexDirection:"column",justifyContent:"center",gap:7},children:[n(T,{w:"48%",h:7,r:3,tone:"dark"}),n(T,{w:"82%",h:5,r:2,tone:"soft"}),n(T,{w:"66%",h:5,r:2,tone:"soft"}),n(T,{w:"74%",h:5,r:2,tone:"soft"}),n(T,{w:"58%",h:5,r:2,tone:"soft"})]}),emailform:p("div",{style:{...R,padding:16,display:"flex",flexDirection:"column",justifyContent:"center",gap:9},children:[n(T,{w:"56%",h:8,r:3,tone:"dark"}),p("div",{style:{display:"flex",gap:6},children:[n("div",{style:{flex:1,height:16,borderRadius:5,border:`1px solid ${se.line}`}}),n(T,{w:"30%",h:16,r:5,tone:"accent"})]})]}),sociallogos:n("div",{style:{...R,display:"flex",alignItems:"center",justifyContent:"center",gap:9},children:[0,1,2,3].map(e=>n(T,{w:16,h:16,r:8,tone:"dark"},e))}),search:n("div",{style:{...R,padding:"0 18%",display:"flex",alignItems:"center"},children:p("div",{style:{flex:1,height:22,borderRadius:11,border:`1px solid ${se.line}`,display:"flex",alignItems:"center",gap:7,padding:"0 9px"},children:[n("div",{style:{width:9,height:9,borderRadius:5,border:`2px solid ${se.dark}`}}),n(T,{w:"46%",h:5,r:2,tone:"soft"})]})}),cart:p("div",{style:{...R,display:"flex",alignItems:"center",justifyContent:"center",gap:7},children:[n("div",{style:{width:22,height:18,borderRadius:"3px 3px 6px 6px",border:`2px solid ${se.dark}`}}),n("div",{style:{padding:"2px 6px",borderRadius:6,border:`1.5px solid ${se.dark}`},children:n(T,{w:7,h:7,r:2,tone:"dark"})})]}),countryswitch:p("div",{style:{...R,padding:14,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:5},children:[p("div",{style:{display:"flex",alignItems:"center",gap:6,padding:"4px 8px",border:`1px solid ${se.line}`},children:[n(T,{w:22,h:6,r:2,tone:"dark"}),n(T,{w:6,h:4,r:1,tone:"soft"})]}),p("div",{style:{width:"46%",display:"flex",flexDirection:"column",gap:4,padding:6,border:`1px solid ${se.line}`},children:[n(T,{w:"80%",h:4,r:2,tone:"accent"}),n(T,{w:"64%",h:4,r:2,tone:"soft"}),n(T,{w:"72%",h:4,r:2,tone:"soft"})]})]}),legalline:p("div",{style:{...R,padding:16,display:"flex",flexDirection:"column",justifyContent:"center",gap:9},children:[n("div",{style:{height:1,background:se.line}}),p("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[n(T,{w:"38%",h:5,r:2,tone:"soft"}),p("div",{style:{display:"flex",gap:5},children:[n(T,{w:14,h:5,r:2,tone:"soft"}),n(T,{w:14,h:5,r:2,tone:"soft"}),n(T,{w:14,h:5,r:2,tone:"soft"})]})]})]}),fallback:n("div",{style:{position:"absolute",inset:14,borderRadius:8,background:se.block}})};function bl({type:e}){let t=Xu[e]??"",o=Zu[t]??gl[t]??gl.fallback;return n("div",{className:"sf-thumb","aria-hidden":"true",style:{position:"absolute",inset:0,background:"var(--sf-thumb-thumb-bg)",pointerEvents:"none",containerType:"inline-size"},children:o})}import{jsx as mt,jsxs as Ju}from"react/jsx-runtime";import{StylesIcon as Qu}from"efficient-easel/rail";import{Tooltip as ef}from"efficient-shell/ui";function wl({tokenRef:e,siteId:t,onClose:o,onNotify:a,tab:s,onTabChange:l}){let d=dt();return Ju("div",{className:"sf-styles",children:[mt(on,{icon:mt(Qu,{}),title:i("Site styles"),context:mt(ef,{content:i("{name} \u2014 renamed in the Console: {place}.",{name:d,place:i("Storefront \u25B8 Sites \u25B8 Settings")}),className:"sf-name-tip",children:mt("span",{className:"sf-name-text",children:d})}),onHide:o}),mt("div",{className:"sf-insp-body sf-scroll",children:mt(Tn,{tokenRef:e,siteId:t,onNotify:a,tab:s,onTabChange:l})})]})}import{jsx as xl}from"react/jsx-runtime";var tf="M6 3h12a1 1 0 0 1 1 1v17l-7-4-7 4V4a1 1 0 0 1 1-1z";function vl({size:e=15,className:t,strokeWidth:o=1.7}){return xl("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:o,strokeLinecap:"round",strokeLinejoin:"round",className:t,"aria-hidden":"true",focusable:"false",children:xl("path",{d:tf})})}import{useEffect as sr,useRef as nf}from"react";var ar="sf-editor-footer-return";function rS(e){if(!(typeof window>"u"))try{window.sessionStorage.setItem(ar,e)}catch{}}function Sl(){if(typeof window>"u")return null;try{return window.sessionStorage.getItem(ar)}catch{return null}}function kl(){if(!(typeof window>"u"))try{window.sessionStorage.removeItem(ar)}catch{}}function Cl(e,t){let{currentSlug:o,siteId:a,navigate:s,footerOriginSlug:l}=ae(),{selected:d}=e,c=e.data?.content??[],h=t.refreshes,g=o===Ze,{editFooter:f}=Ki(),x=nf(null);sr(()=>{let C=d?.props.id;g&&typeof C=="string"&&(x.current?.(),x.current=kn(C))},[d?.props.id,g]);let E=C=>{x.current?.(),x.current=kn(C)};return sr(()=>{if(!g||!l)return;let C=c.find(A=>A.type===te)?.props?.id;if(C)return x.current?.(),x.current=kn(String(C)),()=>{x.current?.(),x.current=null}},[g,l,h]),sr(()=>{if(!(g||!Sl()))return bs(()=>kl())},[]),{pinnedSource:g,holdCanvasOn:g?E:void 0,editPinnedSource:()=>f?f():s({kind:"page",slug:Ze,siteId:a??void 0})}}import{jsx as U,jsxs as ze,Fragment as of}from"react/jsx-runtime";import{Fragment as Tl,useEffect as Il,useRef as lr}from"react";import{useTreeDrag as El}from"efficient-easel/drag";import{ImageIcon as rf,TextLinesIcon as af,TrashIcon as Pl}from"efficient-easel/icons";import{Subtree as Rl,TreeRow as zt,TreeRowAction as Al,TreeSeam as Ll}from"efficient-easel/tree";import{useEaselStrings as sf}from"efficient-easel/strings";var On="ContactLocations";function lf({size:e=13}){return ze("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:1.7,strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[U("circle",{cx:"12",cy:"12",r:"9"}),U("path",{d:"M3 12h18M12 3c2.6 2.6 2.6 15.4 0 18M12 3c-2.6 2.6-2.6 15.4 0 18"})]})}function cf({size:e=13}){return ze("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:1.7,strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[U("path",{d:"M12 21s6-5 6-10a6 6 0 10-12 0c0 5 6 10 6 10z"}),U("circle",{cx:"12",cy:"11",r:"2"})]})}function df({size:e=13}){return ze("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:1.7,strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[U("path",{d:"M9 4 3 6.5v13L9 17l6 3 6-2.5v-13L15 7z"}),U("path",{d:"M9 4v13M15 7v13"})]})}var _n=e=>({parentId:`locations-${e}`,slot:"groups"}),cr=(e,t)=>({parentId:`locations-${e}`,slot:`cities:${t}`});function Nl(e,t){let{readOnly:o,selected:a}=t,s=sf().tree,l=t.data?.content??[],d=e.kind===sl.kind,c=lr(null);Il(()=>{let u=a?.type===On?String(a.props.id):null;u&&u!==c.current&&Pe({level:"groups"}),c.current=u},[a?.props.id]);let{selectedLocationPartId:h,setSelectedLocationPartId:g,setSelectHandler:f}=Zi(),x=fa(),E=(u,y)=>{let N=l[u];N&&t.replace(u,{type:N.type,props:{...N.props,locations:y}})},C=u=>{let y=l[u]?.props?.locations;return Array.isArray(y)?y:[]},A=El({keyOf:u=>`group:${u.si}:${u.index}`,readOnly:!!o,canDrop:(u,y)=>y.parentId===_n(u.si).parentId&&y.slot==="groups",onDrop:(u,y)=>{E(u.si,no(C(u.si),u.index,y.index)),x.level==="city"&&Pe({level:"groups"})},onStep:(u,y)=>{E(u.si,no(C(u.si),u.index,y<0?u.index-1:u.index+2)),x.level==="city"&&Pe({level:"groups"})}}),P=El({keyOf:u=>`city:${u.si}:${u.group}:${u.index}`,readOnly:!!o,canDrop:(u,y)=>y.parentId===_n(u.si).parentId&&y.slot.startsWith("cities:"),onDrop:(u,y)=>{let N=y.slot.slice(7);E(u.si,oo(C(u.si),u.group,u.index,N,y.index)),Pe({level:"group",key:N})},onStep:(u,y)=>{E(u.si,oo(C(u.si),u.group,u.index,u.group,y<0?u.index-1:u.index+2)),x.level==="city"&&Pe({level:"group",key:u.group})}}),b=lr(l);b.current=l;let v=lr(()=>{});Il(()=>{f(u=>{let y=Qi(u);if(!y)return;let N=b.current.findIndex(w=>w.props?.id===y.nodeId);N<0||v.current(N,{level:y.part,index:y.index})})},[f]);let k=(u,y)=>{c.current=l[u]?.props?.id??null,t.select(u),Pe(y),e.reveal();let N=l[u]?.props?.id;typeof N=="string"&&(y.level==="image"||y.level==="map")?g(Ji(N,y.index,y.level)):g(null),typeof N=="string"&&t.scrollTo(N)};return v.current=k,{renderLocationTree:(u,y,{rowClick:N,isCollapsed:w,toggleCollapse:F})=>{let _=C(y),ge=eo(_),V=String(u.props.id),M=d&&a?.props.id===V,X=D=>U(Ll,{...o?{}:A.seam({place:{..._n(y),index:D}})},`seam:${V}:groups:${D}`),de=(D,ee)=>U(Ll,{...o?{}:P.seam({place:{...cr(y,D),index:ee}})},`seam:${V}:cities:${D}:${ee}`);return ze(of,{children:[U(zt,{icon:U(af,{size:13}),name:i("Texts"),words:s,onSelect:()=>k(y,{level:"texts"}),selected:M&&x.level==="texts",rowProps:{onClick:N(()=>k(y,{level:"texts"}))}}),ge.map((D,ee)=>{let Ae=`${V}::grp::${D.key}`,we=w(Ae),Be=M&&x.level==="group"&&x.key===D.key,xe=D.name||D.key?ma(D.key,D.name):i("Ungrouped"),Ce={...cr(y,D.key),index:D.cards.length},We=P.row({item:{si:y,group:D.key,index:-1},place:Ce,into:Ce,canDrag:!1},{onClick:N(()=>k(y,{level:"group",key:D.key}))}),ye=A.row({item:{si:y,index:ee},place:{..._n(y),index:ee}},We.rowProps);return ze(Tl,{children:[ee===0&&X(0),U(zt,{icon:U(lf,{size:13}),name:xe,words:s,onSelect:()=>k(y,{level:"group",key:D.key}),selected:Be,draggable:ye.draggable,dragging:ye.dragging,drop:ye.drop??We.drop,fold:{open:!we,label:i("group"),onToggle:()=>F(Ae)},actions:U(Al,{kind:"delete",label:Xt("Delete {label} group ({n} city)","Delete {label} group ({n} cities)",D.cards.length,{label:xe}),onClick:()=>{E(y,ba(_,D.key)),Pe({level:"groups"})},children:U(Pl,{size:15})}),rowProps:ye.rowProps,children:U("span",{className:"es-group-count",children:D.cards.length})}),!we&&ze(Rl,{children:[D.cards.map((fe,J)=>{let G=to(_,D.key,J),_e=M&&x.level==="city"&&x.index===G,S=String(fe?.name??"")||i("City"),q=`${V}::city::${Qn(fe)}`,$=w(q),{rowProps:pe,...he}=P.row({item:{si:y,group:D.key,index:J},place:{...cr(y,D.key),index:J}},{onClick:N(()=>k(y,{level:"city",index:G}))});return ze(Tl,{children:[J===0&&de(D.key,0),U(zt,{icon:U(cf,{size:13}),name:S,words:s,onSelect:()=>k(y,{level:"city",index:G}),selected:_e,...he,fold:{open:!$,label:S,onToggle:()=>F(q)},actions:U(Al,{kind:"delete",label:i("Delete {name}",{name:S}),onClick:()=>{E(y,wa(_,D.key,J)),Pe({level:"group",key:D.key})},children:U(Pl,{size:15})}),rowProps:pe}),!$&&ze(Rl,{children:[U(zt,{icon:U(rf,{size:13}),name:i("Image"),words:s,onSelect:()=>k(y,{level:"image",index:G}),selected:M&&x.level==="image"&&x.index===G,rowProps:{onClick:N(()=>k(y,{level:"image",index:G}))}}),U(zt,{icon:U(df,{size:13}),name:i("Map"),words:s,onSelect:()=>k(y,{level:"map",index:G}),selected:M&&x.level==="map"&&x.index===G,rowProps:{onClick:N(()=>k(y,{level:"map",index:G}))}})]}),de(D.key,J+1)]},Qn(fe))}),ze("button",{type:"button",className:"sf-add-card",onClick:()=>{let fe=ga(_,D.key);E(y,fe);let J=eo(fe).find(G=>G.key===D.key);Pe(J&&J.cards.length?{level:"city",index:to(fe,D.key,J.cards.length-1)}:{level:"group",key:D.key})},children:[U("span",{className:"sf-plus sf-plus--sm",children:"+"}),i("Add city")]})]}),X(ee+1)]},Ae)}),ze("button",{type:"button",className:"sf-add-card",onClick:()=>{let{cards:D,key:ee}=ya(_);E(y,D),k(y,{level:"group",key:ee})},children:[U("span",{className:"sf-plus sf-plus--sm",children:"+"}),i("Add group")]})]})},sectionPressed:u=>{u?.type===On&&Pe({level:"groups"})}}}import{useEffect as ff,useRef as mf}from"react";import{createNode as gf,newId as yf}from"efficient-easel/data";import{useEaselApi as bf}from"efficient-easel/easel";import{resetForDocumentSwitch as pf,saveStatusForNewDocument as hf,saveStatusOf as uf}from"efficient-easel/screen/lib/document-switch";function Dl(e){return!e.docId||e.saveStatus==="saving"?!1:e.seededDocId!==e.docId}function Fl(e,t){let{capabilities:o,currentSlug:a,docId:s,data:l,saveStatus:d}=ae(),{hasSiteSettings:c,hasPinnedChrome:h}=o,g=a===Ze,f=bf().getState,x=mf(null);ff(()=>{if(!Dl({docId:s,saveStatus:d,seededDocId:x.current})||(x.current=s,!h))return;let E=f().appState.data,C=E.content,A=l?.content??[],P=(u,y)=>u.some(N=>N?.type===y);if(!c){let u=new Set(Wn(C)),y=u.size?C.filter(w=>!u.has(w.props.id)):C;u.size&&e.setDocument({...E,content:y});let N=wr(y,A);if(N.includes(te)){let w=y.length,F=e.insertSection(te,w);e.replaceComponent($e,w,{type:te,props:{id:F,blocks:Jn()}})}N.includes(Oe)&&e.insertNode($e,0,Zn());return}if(g){let u=Ir(C);if(u!==C&&e.setDocument({...E,content:[...u]}),!u.find(y=>y.type===te)&&!P(A,te)&&!P(u,Te)&&!P(A,Te)){let y=(w,F)=>gf(t,w,F),N={type:te,props:{blocks:Jn()}};e.insertNode($e,u.length,Ln(N,y,yf(Te)))}return}let b=C.filter(u=>u.type!==te),v=new Set(Wn(b)),k=v.size?b.filter(u=>!v.has(u.props.id)):b;k.length!==C.length&&e.setDocument({...E,content:k}),!P(k,Oe)&&!P(A,Oe)&&e.insertNode($e,0,Zn())},[s,d,l,f,e,c,h,g])}import{useEffect as zl,useState as _l}from"react";function Ol(e){let{pageSlug:t,siteId:o,token:a}=e,[s,l]=_l(null),[d,c]=_l(null),h=ka();zl(()=>c(h?new URL(h).hostname:window.location.hostname),[h]),zl(()=>{if(!va(d)||!o||!a){l(null);return}let f=!1;return xa(a,o).then(x=>{f||l(x)}),()=>{f=!0}},[d,o,a]);let g=Sa({pageSlug:t,siteSlug:s,hostname:d});return h?`${h}${g}`:g}import{jsx as _t,jsxs as wf}from"react/jsx-runtime";import{ExternalIcon as Hl}from"efficient-easel/icons";import{Button as xf,Tooltip as Ml,buttonClasses as vf}from"efficient-shell/ui";function Sf({pageId:e,liveHref:t,draftLink:o,win:a=window}){let s=a.open("","_blank");if(s)try{s.opener=null}catch{}let l=d=>{s&&!s.closed?s.location.href=d:a.open(d,"_blank","noopener,noreferrer")};return o(e).then(d=>l(d.url??t),()=>l(t))}function Bl({liveHref:e,pageId:t,draftLink:o}){return o&&t?_t(Ml,{content:i("Open your saved draft in a new tab. Visitors don't see it."),children:_t(xf,{variant:"secondary",onClick:()=>{Sf({pageId:t,liveHref:e,draftLink:o})},rightIcon:_t(Hl,{size:15}),"aria-label":i("Preview your saved draft in a new tab"),children:i("Preview")})}):_t(Ml,{content:i("Preview the live site (opens in a new tab)"),children:wf("a",{className:vf({variant:"secondary"}),href:e,target:"_blank",rel:"noopener noreferrer","aria-label":i("Preview the live site in a new tab"),children:[i("Preview"),_t(Hl,{size:15})]})})}import{useCallback as Tf,useEffect as If,useRef as $l,useState as Ef}from"react";import{useSyncExternalStore as kf}from"react";var Ot=new Map,dr=new Set;function pr(e,t){if(!(Ot.has(e)&&Ot.get(e)===t)){Ot.set(e,t);for(let o of dr)o()}}function QS(e,t){pr(e,t)}function e1(e,t){let o=Ot.get(e);pr(e,t??(o==="live"?"changed":o))}function t1(e,t){pr(e,t??"live")}function Cf(e){return dr.add(e),()=>{dr.delete(e)}}function Wl(e){let t=()=>e?Ot.get(e):void 0;return kf(Cf,t,t)}function jl(e,t){return e==="live"&&t?"changed":e}function ql({live:e,onPress:t,busy:o=!1}){let a=e==="live"?i("Everything is live"):e==="changed"?i("Changes not live yet"):e==="never"?i("Never published"):null;return{label:i("Publish"),tooltip:e==="never"?i("Put this page on your site"):i("Put your changes on your site"),status:a,quiet:e==="live"?{label:i("Published"),reason:i("Everything is live")}:null,onPress:t,busy:o}}function Gl(e){let{docId:t,capabilities:o,hasUnsavedEdits:a,onPublish:s}=ae(),l=jl(Wl(t??null),a),[d,c]=Ef(!1),h=$l(e);h.current=e;let g=$l(!0);If(()=>(g.current=!0,()=>{g.current=!1}),[]);let f=Tf(()=>{c(!0),s(h.current).finally(()=>{g.current&&c(!1)})},[s]);if(o.canPublish)return ql({live:l,onPress:f,busy:d})}import{buildPaletteSections as Pf,categoryLabel as Rf,matchesQuery as Af,paletteWithoutPinned as Lf,pinnedSection as Nf}from"efficient-easel/screen/lib/puck/palette-sections";var Df={openers:{label:"Hero & intros",icon:"image"},shop:{label:"Shop & galleries",icon:"bag"},product:{label:"Product page",icon:"box"},checkout:{label:"Checkout & ordering",icon:"bag"},about:{label:"About & brand story",icon:"book"},content:{label:"Text & content",icon:"type"},proof:{label:"Stats & social proof",icon:"star"},promo:{label:"Promotions & sign-ups",icon:"sparkles"},blog:{label:"Blog & journal",icon:"newspaper"},navigation:{label:"Navigation & wayfinding",icon:"bookmark"},legal:{label:"Legal & documents",icon:"file"},contact:{label:"Contact, FAQ & forms",icon:"mail"},structure:{label:"Layout, structure & embeds",icon:"grid"}};function Kl(e){return Df[e]?.label}var Ul=mr;function Vl(e,t){let o=e.props;if(e.type==="FooterMenu"){let a=o.menu;return o.heading||a?.name||i("Menu")}if(e.type==="FooterText"){let a=typeof o.text=="string"?o.text.trim():"";return a?a.length>28?`${a.slice(0,28)}\u2026`:a:i("Text")}return e.type==="FooterEmailSignup"?o.heading||i("Email signup"):t(e.type)}var Yl="sf-editor-left-view";function Xl(){if(typeof window>"u")return"pages";try{let e=window.localStorage.getItem(Yl);return e==="sections"||e==="styles"||e==="media"?e:"pages"}catch{return"pages"}}function Zl(e){if(!(typeof window>"u"))try{window.localStorage.setItem(Yl,e)}catch{}}function Jl(e,t,o=!1){return e==="styles"&&!t||e==="media"&&!o?"sections":e}function Ql(e,t){return e?"sections":t}var Ff=new Set(["BookingBox","SubmitBox"]);function ec(e){return typeof e=="string"&&Ff.has(e)}import{Fragment as ic,jsx as hr}from"react/jsx-runtime";import{useMemo as Wf,useRef as ac}from"react";import{EaselCanvas as jf,useEaselApi as qf}from"efficient-easel/easel";import{jsx as nc,Fragment as Of,jsxs as Hf}from"react/jsx-runtime";import{useEffect as oc,useLayoutEffect as Mf}from"react";var zf=String.raw`(function (doc) {
|
|
2
|
+
if (doc.__sfFitWords) return;
|
|
3
|
+
var win = doc.defaultView;
|
|
4
|
+
var SELECTOR = "h1,h2,h3,h4,h5,h6,[class*='font-heading'],[class*='font-display']";
|
|
5
|
+
var MIN_SCALE = 0.3, MIN_PX = 16, SLACK = 1;
|
|
6
|
+
|
|
7
|
+
function measure(el) {
|
|
8
|
+
var widest = 0, current = 0, last = null, split = false, lastBlock = null;
|
|
9
|
+
function blockOf(n) {
|
|
10
|
+
for (var p = n.parentElement; p && p !== el; p = p.parentElement) {
|
|
11
|
+
var d = win.getComputedStyle(p).display;
|
|
12
|
+
if (d.indexOf("inline") !== 0 && d !== "contents") return p;
|
|
13
|
+
}
|
|
14
|
+
return el;
|
|
15
|
+
}
|
|
16
|
+
function close() { if (current > widest) widest = current; current = 0; last = null; }
|
|
17
|
+
var walker = doc.createTreeWalker(el, 5), range = doc.createRange(), node;
|
|
18
|
+
while ((node = walker.nextNode())) {
|
|
19
|
+
if (node.nodeType === 1) {
|
|
20
|
+
if (node.tagName === "BR" || node.tagName === "WBR") close();
|
|
21
|
+
continue;
|
|
22
|
+
}
|
|
23
|
+
var block = blockOf(node);
|
|
24
|
+
if (block !== lastBlock) close();
|
|
25
|
+
lastBlock = block;
|
|
26
|
+
var re = /(\S+)|(\s+)/g, m;
|
|
27
|
+
while ((m = re.exec(node.data))) {
|
|
28
|
+
if (m[2]) { close(); continue; }
|
|
29
|
+
range.setStart(node, m.index);
|
|
30
|
+
range.setEnd(node, m.index + m[0].length);
|
|
31
|
+
var rects = range.getClientRects();
|
|
32
|
+
for (var i = 0; i < rects.length; i++) {
|
|
33
|
+
var r = rects[i];
|
|
34
|
+
if (r.width <= 0) continue;
|
|
35
|
+
current += r.width;
|
|
36
|
+
if (last && r.top > last.top + last.height / 2) split = true;
|
|
37
|
+
last = r;
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
close();
|
|
42
|
+
return { widest: widest, split: split };
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
function lineWidth(el) {
|
|
46
|
+
var cs = win.getComputedStyle(el);
|
|
47
|
+
return el.getBoundingClientRect().width - parseFloat(cs.paddingLeft) - parseFloat(cs.paddingRight)
|
|
48
|
+
- parseFloat(cs.borderLeftWidth) - parseFloat(cs.borderRightWidth);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
// ⚠️ THE HEADING ELEMENT IS NEVER TOUCHED — no style="", no data-*. This
|
|
52
|
+
// runs before React hydrates, and React 19 in development reports ANY
|
|
53
|
+
// attribute that differs from what it rendered ("a tree hydrated but some
|
|
54
|
+
// attributes didn't match"): first our inline font-size on the hero (which
|
|
55
|
+
// React owns via --heading-size), then, when that moved to a data-sf-fit
|
|
56
|
+
// attribute, the attribute itself. So the fitted size lives only in this
|
|
57
|
+
// script's own stylesheet, in <head>, addressed to each heading by its
|
|
58
|
+
// POSITION (":root>*:nth-child(2)>…"). A position goes stale when the page's
|
|
59
|
+
// structure changes, so the rules are rewritten in the MutationObserver
|
|
60
|
+
// callback, which runs before the next paint. !important so the size also
|
|
61
|
+
// beats a part's own inline size.
|
|
62
|
+
var head = doc.head || doc.documentElement;
|
|
63
|
+
var fitEl = doc.createElement("style");
|
|
64
|
+
fitEl.id = "storefront-fit-words-sizes";
|
|
65
|
+
head.appendChild(fitEl);
|
|
66
|
+
var fitted = new Map(); // heading -> fitted size, e.g. "43.8px"
|
|
67
|
+
|
|
68
|
+
function pathOf(el) {
|
|
69
|
+
var parts = [];
|
|
70
|
+
for (var e = el; e && e.parentElement; e = e.parentElement) {
|
|
71
|
+
var i = 1, s = e;
|
|
72
|
+
while ((s = s.previousElementSibling)) i++;
|
|
73
|
+
parts.unshift("*:nth-child(" + i + ")");
|
|
74
|
+
}
|
|
75
|
+
return ":root>" + parts.join(">");
|
|
76
|
+
}
|
|
77
|
+
function writeRules() {
|
|
78
|
+
var css = "";
|
|
79
|
+
fitted.forEach(function (size, el) {
|
|
80
|
+
if (!el.isConnected) { fitted.delete(el); return; }
|
|
81
|
+
css += pathOf(el) + "{font-size:" + size + " !important}";
|
|
82
|
+
});
|
|
83
|
+
if (fitEl.textContent !== css) fitEl.textContent = css;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
function unfit(el) {
|
|
87
|
+
if (fitted.delete(el)) writeRules();
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
function fits(el) {
|
|
91
|
+
var m = measure(el);
|
|
92
|
+
return !m.split && m.widest <= lineWidth(el) + SLACK;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
function fit(el) {
|
|
96
|
+
unfit(el);
|
|
97
|
+
if (lineWidth(el) <= 0) return; // hidden, or not laid out yet
|
|
98
|
+
if (fits(el)) return;
|
|
99
|
+
var set = parseFloat(win.getComputedStyle(el).fontSize);
|
|
100
|
+
if (!set) return;
|
|
101
|
+
var floor = Math.max(set * MIN_SCALE, MIN_PX);
|
|
102
|
+
if (floor >= set) return;
|
|
103
|
+
function size(px) { return Math.floor(px * 10) / 10 + "px"; }
|
|
104
|
+
// The SEARCH tries sizes on the element's own style and then puts that
|
|
105
|
+
// attribute back byte for byte (or removes it, if it had none), so nothing
|
|
106
|
+
// is left for React to see. A trial in a stylesheet instead restyles the
|
|
107
|
+
// whole page per step: a full pass on the Hartes home took 75–160ms at 4x
|
|
108
|
+
// CPU that way.
|
|
109
|
+
var hadStyle = el.hasAttribute("style"), origStyle = el.getAttribute("style");
|
|
110
|
+
function attempt(px) { el.style.setProperty("font-size", size(px), "important"); }
|
|
111
|
+
function done() { if (hadStyle) el.setAttribute("style", origStyle); else el.removeAttribute("style"); }
|
|
112
|
+
attempt(floor);
|
|
113
|
+
if (!fits(el)) { done(); return; } // even the floor does not fit: leave it as set
|
|
114
|
+
var lo = floor, hi = set;
|
|
115
|
+
for (var i = 0; i < 8; i++) {
|
|
116
|
+
var mid = (lo + hi) / 2;
|
|
117
|
+
attempt(mid);
|
|
118
|
+
if (fits(el)) lo = mid; else hi = mid;
|
|
119
|
+
}
|
|
120
|
+
done();
|
|
121
|
+
fitted.set(el, size(lo));
|
|
122
|
+
writeRules();
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
// What each heading measured right after we last fitted it, so the
|
|
126
|
+
// ResizeObserver below can tell a real change (a font swap, a rotate, a
|
|
127
|
+
// container that moved) from the size change our own write just caused.
|
|
128
|
+
var seen = new WeakMap();
|
|
129
|
+
function remember(el) {
|
|
130
|
+
var b = el.getBoundingClientRect();
|
|
131
|
+
seen.set(el, b.width + "x" + b.height);
|
|
132
|
+
}
|
|
133
|
+
function fitAndRemember(el) { fit(el); remember(el); }
|
|
134
|
+
|
|
135
|
+
// ⚠️ A ResizeObserver, NOT fonts.ready or a resize event, and the reason is
|
|
136
|
+
// WHEN it runs: after layout, BEFORE paint. The web font arriving re-wraps a
|
|
137
|
+
// fitted heading, and fonts.ready resolves only after that frame is painted —
|
|
138
|
+
// measured on the Hartes hero: a 42px jump in 2 of 3 loads. A size change
|
|
139
|
+
// reported here is fitted in the same frame, so the broken state is never
|
|
140
|
+
// drawn. It also covers a container that resizes.
|
|
141
|
+
var ro = new win.ResizeObserver(function (entries) {
|
|
142
|
+
for (var i = 0; i < entries.length; i++) {
|
|
143
|
+
var el = entries[i].target;
|
|
144
|
+
var b = el.getBoundingClientRect();
|
|
145
|
+
if (seen.get(el) === b.width + "x" + b.height) continue; // our own write
|
|
146
|
+
fitAndRemember(el);
|
|
147
|
+
}
|
|
148
|
+
});
|
|
149
|
+
function watch(el) { if (!seen.has(el)) { remember(el); ro.observe(el); } }
|
|
150
|
+
|
|
151
|
+
function fitAll() {
|
|
152
|
+
var els = doc.querySelectorAll(SELECTOR);
|
|
153
|
+
for (var i = 0; i < els.length; i++) { fitAndRemember(els[i]); watch(els[i]); }
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
var queued = 0, all = false, touched = new Set();
|
|
157
|
+
function run() {
|
|
158
|
+
queued = 0;
|
|
159
|
+
if (all) { all = false; touched.clear(); fitAll(); return; }
|
|
160
|
+
var els = Array.from(touched);
|
|
161
|
+
touched.clear();
|
|
162
|
+
for (var i = 0; i < els.length; i++) if (els[i].isConnected) { fitAndRemember(els[i]); watch(els[i]); }
|
|
163
|
+
}
|
|
164
|
+
function schedule() { if (!queued) queued = win.requestAnimationFrame(run); }
|
|
165
|
+
function scheduleAll() { all = true; schedule(); }
|
|
166
|
+
|
|
167
|
+
fitAll();
|
|
168
|
+
// A backstop only: a font that changes widths without changing any
|
|
169
|
+
// heading's box is not seen by the ResizeObserver.
|
|
170
|
+
if (doc.fonts && doc.fonts.ready) doc.fonts.ready.then(scheduleAll, function () {});
|
|
171
|
+
|
|
172
|
+
// …and the viewport WIDTH, which the ResizeObserver cannot stand in for: a
|
|
173
|
+
// heading sized to its own text (fit-content, a flex item) keeps the SAME box
|
|
174
|
+
// when the phone turns to 844, so nothing reports a change and it would stay
|
|
175
|
+
// shrunk. The probe's rotate check caught exactly that.
|
|
176
|
+
var lastWidth = win.innerWidth;
|
|
177
|
+
function onResize() {
|
|
178
|
+
if (win.innerWidth === lastWidth) return; // a phone's toolbar changing HEIGHT is not our business
|
|
179
|
+
lastWidth = win.innerWidth;
|
|
180
|
+
scheduleAll();
|
|
181
|
+
}
|
|
182
|
+
win.addEventListener("resize", onResize);
|
|
183
|
+
|
|
184
|
+
var mo = new win.MutationObserver(function (records) {
|
|
185
|
+
// Positions first: a node added or removed anywhere can shift the
|
|
186
|
+
// nth-child path of a fitted heading, and this callback runs before paint.
|
|
187
|
+
if (fitted.size) {
|
|
188
|
+
for (var q = 0; q < records.length; q++) if (records[q].type === "childList") { writeRules(); break; }
|
|
189
|
+
}
|
|
190
|
+
for (var i = 0; i < records.length; i++) {
|
|
191
|
+
var r = records[i];
|
|
192
|
+
var target = r.target.nodeType === 1 ? r.target : r.target.parentElement;
|
|
193
|
+
var own = target && target.closest(SELECTOR);
|
|
194
|
+
if (own) touched.add(own);
|
|
195
|
+
for (var j = 0; j < r.addedNodes.length; j++) {
|
|
196
|
+
var n = r.addedNodes[j];
|
|
197
|
+
if (n.nodeType !== 1) continue;
|
|
198
|
+
if (n.matches(SELECTOR)) touched.add(n);
|
|
199
|
+
var inner = n.querySelectorAll(SELECTOR);
|
|
200
|
+
for (var k = 0; k < inner.length; k++) touched.add(inner[k]);
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
if (touched.size) schedule();
|
|
204
|
+
});
|
|
205
|
+
mo.observe(doc.body, { childList: true, subtree: true, characterData: true });
|
|
206
|
+
|
|
207
|
+
doc.__sfFitWords = function stop() {
|
|
208
|
+
win.removeEventListener("resize", onResize);
|
|
209
|
+
ro.disconnect();
|
|
210
|
+
mo.disconnect();
|
|
211
|
+
if (queued) win.cancelAnimationFrame(queued);
|
|
212
|
+
fitted.clear();
|
|
213
|
+
fitEl.remove();
|
|
214
|
+
delete doc.__sfFitWords;
|
|
215
|
+
};
|
|
216
|
+
// For the probe and for debugging: which headings are fitted, at what size,
|
|
217
|
+
// and the sheet that holds it (disable it to read a heading's set size).
|
|
218
|
+
doc.__sfFitWords.fitted = fitted;
|
|
219
|
+
doc.__sfFitWords.sheet = fitEl;
|
|
220
|
+
})(document);`,_f="storefront-fit-words";function tc(e){let t=e.createElement("script");return t.id=_f,t.textContent=zf,(e.head??e.documentElement).appendChild(t),()=>{e.__sfFitWords?.(),t.remove()}}var Bf=`
|
|
221
|
+
[${Ee}][${Ee}] { cursor: text; }
|
|
222
|
+
[${be}][${be}][${be}] {
|
|
223
|
+
outline: 1px solid ${ha.accent};
|
|
224
|
+
outline-offset: 2px;
|
|
225
|
+
}
|
|
226
|
+
[${be}][${be}]:has([${be}]),
|
|
227
|
+
[data-puck-overlay-portal][data-puck-overlay-portal]:has([${be}]) {
|
|
228
|
+
outline: none;
|
|
229
|
+
}
|
|
230
|
+
[${be}][${be}][${be}][data-es-typing],
|
|
231
|
+
[data-es-typing] [${be}][${be}][${be}] {
|
|
232
|
+
outline: none;
|
|
233
|
+
}
|
|
234
|
+
`;function rc({children:e,document:t}){let{theme:o,themeMode:a,themeSwitchShown:s}=ie(),l=Yt(o);return oc(()=>{if(t)return Ea(t,{mode:a,switchShown:s})},[t,a,s]),oc(()=>{if(t)return Pa(t,l)},[t,l]),Mf(()=>{if(t)return tc(t)},[t]),Hf(Of,{children:[nc(Aa,{}),nc("style",{children:Bf}),e]})}function $f({children:e,componentId:t}){let{selectedPartId:o}=bt();return Gr(o,t)?hr(ic,{}):hr(ic,{children:e})}function sc(e){let{mirrorHostStyles:t}=io(),o=Na(),a=ac(null),s=Gf(a),{onDocument:l}=e;return hr(jf,{...e,onDocument:d=>{a.current=d,l?.(d)},typing:s,metadata:e.metadata??o,height:"fill",mirrorStyles:t,frameWrapper:rc,overlay:$f})}function Gf(e){let t=qf(),o=rt(),a=bt(),s=ac({ops:o,parts:a});return s.current={ops:o,parts:a},Wf(()=>{let l={getItemById:c=>t.getState().getItemById(c),getSelectorForId:c=>t.getState().getSelectorForId(c),get components(){return t.getState().config.components},replace:(c,h,g)=>s.current.ops.replaceComponent(c,h,g)},d=(c,h)=>{let g=Ja(c,l);if(!g)return null;let f=h,x=()=>(f=Qa(f,f?.ownerDocument??e.current,c),f);return x()?{element:x,value:g.value,rules:g.rules,multiline:g.multiline,write:g.write,toolbar:{offered:g.offered}}:null};return{at:c=>{let h=c.closest(`[${Ee}]`),g=h?.getAttribute(Ee);return h&&g?d(g,h):null},atSelection:()=>{let c=s.current.parts.selectedPartId;return c?d(c,null):null},onChange:c=>{if(!c.typing){To(null);return}let h=c.element.closest(`[${Ee}]`)?.getAttribute(Ee)??null;To(h),h&&s.current.parts.selectedPartId!==h&&s.current.parts.select(h)}}},[t,e])}var lc={Hero:"Full-screen opener with rotating slides.",HeroSingle:"Full-screen image or video with a headline.",IntroBleed:"Full-bleed intro image the next section scrolls over.",Collections:"Product collections in a tidy grid.",AlloyWheelsListing:"A full product-listing page: filter rail, sortable card grid and pagination, from the live catalog. Choose which product types it shows.",CatalogFilterBar:"Filters the collection grids below it \u2014 a sticky row of Pills (the default), or Columns, one per filter you switch on.",ProductGrid:"Hand-picked products in a tidy grid.",FitmentFinder:"A vehicle picker \u2014 make, model, year and trim resolve the OEM stock fitment live.",Gallery:"Two image galleries with tabs and filters.",GalleryB:"Customer photos in a card grid with a click-to-open lightbox.",SpecStrip:"A thin one-line spec strip \u2014 small-caps items spread across the width, as a dark band or a bare hairline row.",ProductHero:"A product hero \u2014 image beside price, bullets and a buy button.",SpecTable:"A spec sheet \u2014 labeled rows of product specifications.",ProcessSteps:"A heading over columns of image, title, blurb and specs.",DetailRows:"Repeating full-width rows \u2014 eyebrow, title and copy beside a numbered close-up image, alternating sides each row.",FitmentTable:"A fitment table \u2014 per-size bolt patterns, offsets and load ratings, filterable by diameter.",CompatibleTyres:"The current product's compatible tyres \u2014 image, size, key specs and price per tyre, with an inquiry link. Display only.",RelatedProducts:"The current product's related items in a tidy row \u2014 the product page's built-in 'Pair with' cross-sell.",OrderSummary:"A display order-summary panel \u2014 items, totals and a note.",DeliveryOptions:"Delivery tiers as cards \u2014 name, window and price, one highlighted.",PaymentBadges:"A payment-methods trust strip with reassurance lines.",CheckoutCTA:"A centered 'ready to order?' headline with the checkout button.",Manifesto:"A bold brand statement beside a full-height image, with a stat strip.",ParagraphsA:"An editorial text panel with a stat strip and founders' note.",StatsParagraph:"An editorial heading and paragraph over a row of theme-color-accented stat cards.",Chart:"A titled chart \u2014 bars, line or donut \u2014 drawn from your own labeled data points.",Mockup:"A headline beside a stylized product-UI mockup card \u2014 spec sheet, fitment, portal, kanban and more.",Prose:"A plain editorial text section \u2014 eyebrow, heading and body copy.",Timeline:"An editorial aside beside a rail-marked timeline of dated entries.",TimelineTrack:"A horizontal year track of milestones \u2014 company history or roadmap.",Footprint:"A world map of your locations with a legend \u2014 designed here, sold worldwide.",TitleWithButtons:"A big headline beside a stack of call-to-action buttons.",Split:"Side-by-side image and text in two columns.",Cards:"A heading over a grid of free-text title-and-blurb cards.",FAQ:"A frequently-asked-questions accordion with a header.",Testimonials:"Customer quotes in a grid \u2014 the quote, a name and a role.",Masthead:"A journal issue header with a lead statement and contents.",Breadcrumb:"A slim trail showing where the reader is (Home / Journal\u2026).",CategoryBar:"A sticky row of category tabs with counts and links.",FeaturedCover:"A featured article \u2014 big cover image beside a headline and dek.",LongRead:"A long-form article spread with a pull-quote and cover image.",Series:"A section heading over a grid of column cards.",Subscribe:"A newsletter signup beside a list of recent issues.",SubscribeBlogs:"A newsletter signup beside your latest blog posts, pulled live.",Events:"Latest journal posts in a three-card row.",DocMasthead:"A document header \u2014 headline, metadata and standfirst.",DocTabs:"A sticky tab bar to switch between documents.",DocBody:"Long-form document body with an 'On this page' contents list.",DocMetaCards:"A three-up meta strip for the foot of a document.",Banner:"Wide promo strip with background image.",Stats:"Highlight key numbers \u2014 years, designs.",Countdown:"Hours, minutes and seconds to a set date and time, then one line.",KeyFeatures:"A theme-color chip and heading over a grid of short feature labels.",Logos:"A row of partner or brand logos.",Ticker:"A scrolling marquee of short phrases, full width.",Reviews:"Approved customer reviews in a star-rated card grid, pulled live.",SubmitBuild:"A 'Show us yours.' headline with a photo-submission form.",ReviewForm:"A write-a-review form \u2014 submissions wait for your approval before they show.",ContactRouting:"Pick who to reach, then a form that routes the message.",ContactLocations:"Your locations as a city gallery plus address and map cards.",SectionHeader:"A numbered section title with optional link.",Grid:"Multi-column container for blocks.",Flex:"An empty section. Add whatever you want inside.",Spacer:"Vertical breathing room between sections.",Divider:"A thin horizontal rule between sections.",CustomHTML:"Drop in your own sanitized HTML.",Heading:"A single heading line.",Text:"A paragraph of body copy.",ImageBlock:"A standalone image, at the width you set.",ButtonBlock:"A call-to-action button."};var Kf="Save your page changes first";function cc(e){return e.hasTrustedConsole?e.canCreatePlatformTemplate?!e.capabilities.canPublish||!e.capabilities.hasSiteSettings?{visible:!1,hiddenReason:"not-a-site-page"}:e.siteId?e.hasUnsavedEdits?{visible:!0,enabled:!1,disabledReason:Kf}:{visible:!0,enabled:!0}:{visible:!1,hiddenReason:"no-site"}:{visible:!1,hiddenReason:"not-operator"}:{visible:!1,hiddenReason:"no-console"}}var dc="storefront-editor:save-as-template";function pc(e,{nodeDefaults:t,newNodeId:o,sectionLabel:a,blockIsOffered:s}){let l=gr(e);return l?l(t,o):Pr(e)&&s(yt)&&s(nt)?{type:yt,props:{...t(yt),id:o(yt),direction:"column",name:`${a(e)} section`,content:[{type:nt,props:{...t(nt),id:o(nt),...Ye[e]?.headStyle?{headStyle:Ye[e].headStyle}:{},...Ye[e]?.headRowGap?{rowGap:Ye[e].headRowGap}:{},...Ye[e]?.headDescriptionSize?{descriptionSize:Ye[e].headDescriptionSize}:{},...nn(e)!==nn(nt)?{eyebrowLook:nn(e)}:{}}},{type:e,props:{...t(e),id:o(e),headPlacement:"own-box"}}]}}:xr[e]?.fixed===!0?{type:e,props:{...t(e),id:o(e),layout:"boxes"}}:null}import{useEffect as Uf,useState as Vf}from"react";function hc(){let e=Ne().chrome?.products?.list,[t,o]=Vf(null);return Uf(()=>{if(!e)return;let a=!1;return e().then(s=>{a||o(s)}),()=>{a=!0}},[e]),t}function mc({mode:e,open:t}){let{setSelectedHeroId:o,setSelectHandler:a}=Xi(),s=nm().tree,l=e,d=l.kind==="ticker"?l.heroId:null,c=Hn(h=>{h&&(t({kind:"ticker",heroId:h}),xs(h))},[t]);return Ve(()=>{o(d)},[d,o]),Ve(()=>{a(c)},[a,c]),{partRows:(h,{rowClick:g})=>{let f=String(h.props.id);return h.type==="Hero"&&Q(tm,{icon:Q(ut,{type:"ticker",size:13}),name:i(kt),onSelect:()=>c(f),selected:d===f,rowProps:{onClick:g(()=>c(f))},words:s})}}}function om(e){let{adapter:t,capabilities:o,currentSlug:a,siteId:s,docId:l,hasUnsavedEdits:d,bridgeCapabilities:c,notifyParent:h,token:g}=ae(),{hasPreviewLink:f}=o,x=gt(Ne()).preview?.draftLink,E=Gl(e.data),C=cc({hasTrustedConsole:!!g,canCreatePlatformTemplate:c.canCreatePlatformTemplate,capabilities:o,siteId:s,hasUnsavedEdits:d}),A=Hn(()=>{!s||!a||h(dc,{siteId:s,slug:a})},[h,s,a]),P=Ol({pageSlug:a,siteId:s,token:g}),b=t.previewHref?.(a)??P;return{barLead:()=>C.visible&&Q(Zf,{side:"bottom",content:C.enabled?i("Save this website as a platform template"):i(C.disabledReason),children:Q("span",{className:"sf-tip-disabled",tabIndex:C.enabled?void 0:0,children:Q(Xf,{variant:"secondary",disabled:!C.enabled,onClick:A,rightIcon:Q(vl,{}),children:i("Save as Template")})})}),barTrail:()=>f&&a&&Q(Bl,{liveHref:b,pageId:l??null,draftLink:x}),mainAction:E}}function rm(){return fr("svg",{width:"17",height:"17",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:1.7,strokeLinecap:"round",strokeLinejoin:"round",children:[Q("path",{d:"M12 3a9 9 0 0 0 0 18 2.3 2.3 0 0 0 2.3-2.3c0-.55-.22-1.05-.57-1.42-.34-.37-.56-.87-.56-1.43A2.35 2.35 0 0 1 15.6 13.5H18a3 3 0 0 0 3-3c0-4.14-4-7.5-9-7.5z"}),Q("circle",{cx:"7.7",cy:"11.3",r:"1.05",fill:"currentColor",stroke:"none"}),Q("circle",{cx:"12",cy:"8",r:"1.05",fill:"currentColor",stroke:"none"}),Q("circle",{cx:"16",cy:"11",r:"1.05",fill:"currentColor",stroke:"none"})]})}function im(e,t){let{capabilities:o,templateId:a,siteId:s,tokenRef:l,navigate:d}=ae(),{hasSiteTheme:c,explainsSiteSettings:h}=o,g=v=>t.setView(v),[f,x]=Yf(lt[0].id),{surface:E,setSurface:C}=Yi(),A=()=>{if(c){g("styles"),t.reveal(),Do();return}e.show(nr),e.reveal(),Do()},P={id:"pages",label:i("Pages"),icon:Q(Qf,{}),panel:({onHide:v})=>Q(Fs,{activeSurface:E,onPreviewSurface:C,onNavigate:k=>{C(null),d(a?{kind:"template",id:a,pageSlug:k}:{kind:"page",slug:k,siteId:s??void 0})},onClose:v})},b=[];return!c&&h&&b.push({id:"appearance",label:i("Appearance"),icon:Q(rm,{}),active:e.kind==="website",onSelect:A}),c&&b.push({id:"styles",label:i("Site styles"),icon:Q(em,{}),panel:({onHide:v,notify:k})=>Q(wl,{tokenRef:l,siteId:s??void 0,onClose:v,onNotify:k,tab:f,onTabChange:x})}),{railLead:[P],railTrail:b,resolveLeftView:(v,k)=>Jl(v,c,k),openSettings:A,openStyles:()=>{x(Ss),g("styles")}}}function am(e,t,o,a){let{kind:s,open:l}=e,{selected:d,zoneOf:c}=t,h=Cl(t,o);Ve(()=>{Ta(d?.type==="BookingBox"&&d.props.region==="confirm"?Ia(c(String(d.props.id))):null)},[d?.props.id]);let g=Nl(e,t),{capabilities:{hasSiteSettings:f}}=ae(),{setSelected:x,setSelectHandler:E}=ie(),{chat:C,setChat:A,setSelected:P,setSelectHandler:b}=tn(),v=s==="header";Ve(()=>{x(v)},[v,x]),Ve(()=>{E(()=>l(tr))},[E,l]);let k=Hn(()=>l(ll),[l]),u=s==="chat";Ve(()=>{P(u)},[u,P]),Ve(()=>{b(k)},[b,k]);let{setOpenHandler:y}=St(),N=Hn(()=>l(cl),[l]);Ve(()=>{y(N)},[y,N]);let w=mc(e),F=om(t),_=im(e,a),ge=o.device;return{...h,...w,...F,..._,hasOwnRows:V=>V.type===On,ownRows:g.renderLocationTree,sectionPressed:g.sectionPressed,wrap:V=>Q(ea.Provider,{value:!0,children:Q(ca.Provider,{value:ge,children:V})}),addPanelRow:V=>f?fr("div",{className:"sf-addside-sitewide",children:[Q("span",{className:"sf-addside-sitewide-glyph","aria-hidden":"true",children:Q(ut,{type:"chat",size:16})}),fr("button",{type:"button",className:"sf-addside-sitewide-name",onClick:()=>{V(),k()},children:[i("Live chat"),Q("span",{className:"sf-addside-sitewide-desc",children:i("A chat bubble on every page")})]}),Q(Jf,{checked:C.enabled,onChange:M=>A({enabled:M}),ariaLabel:i("Show the chat bubble on the whole site")})]}):void 0}}var uc=null,ur=new WeakMap;function sm(e){let t=Pi();if(!e||!t)return e;uc!==t&&(uc=t,ur=new WeakMap);let o=ur.get(e);return o||(o={...e,choices:e.choices?e.choices.map(a=>({...a,label:i(a.label)})):null,spec:e.spec?{...e.spec,addLabel:i(e.spec.addLabel)}:null},ur.set(e,o)),o}var lm={isLockedBlock:ec,duplicateBlocked:Mt,nestDepth:(e,t,o)=>t===yr?br(e,o):0,newSectionNode:pc,canAddTo:(e,t)=>sm(Ca(e,t)),blockIsOffered:vr},cm=new Proxy(lc,{get:(e,t)=>{let o=Reflect.get(e,t);return typeof o=="string"?i(o):o}}),dm={labelAtLevel:(e,t,o)=>i(Bn(e,t,o)),descriptions:cm,categoryLabel:e=>{let t=Kl(e);return t===void 0?void 0:i(t)},firstSection:Ul,blockRowName:Vl,plainText:_r,Icon:ut,Thumbnail:bl,useProducts:hc},pm={desktop:2e3,tablet:800,mobile:390},fc="desktop",hm={options:zs,initial:fc,fluid:fc,widths:pm},um={read:Xl,write:e=>Zl(e),forSelection:(e,t)=>Ql(e,t)},fm={first:Oe,last:te,firstGroup:Sr,lastGroup:Te,isSectionGroup:kr,sectionGroupZone:Cr,panelOf:e=>e===Oe?tr:null};function mm(e){return{...mc(e),openSettings:()=>e.show(nr)}}var Uk={useOwnerName:dt,useDocumentLabel:Is,useBridges:am,useStandaloneBridges:mm,useDocumentPass:Fl,blockRules:lm,blockLook:dm,devices:hm,leftView:um,pinned:fm,Canvas:sc,Inspector:hl};export{rS as a,Sl as b,kl as c,QS as d,e1 as e,t1 as f,_o as g,Oo as h,rx as i,ix as j,uf as k,bm as l,Sm as m,Uk as n};
|