efficient-storefront-blocks 0.27.0 → 0.29.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 +90 -0
- package/dist/chunks/{EditorPreviewCheckout-SRCARSQ3.js → EditorPreviewCheckout-DYIFFWDV.js} +1 -1
- package/dist/chunks/{PreviewFooter-FSNNVHPC.js → PreviewFooter-MSX5VU2X.js} +1 -1
- package/dist/chunks/SiteEditorProvider-L25VIEGY.js +1 -0
- package/dist/chunks/chunk-4TBMAZTS.js +234 -0
- package/dist/chunks/{chunk-TWNYQY4T.js → chunk-AS47U6BL.js} +30 -30
- package/dist/chunks/{chunk-IM2BNZNF.js → chunk-CDVN6WLL.js} +1 -1
- package/dist/chunks/chunk-GB535QZ5.js +16 -0
- package/dist/chunks/{chunk-KHIAJRGY.js → chunk-TSZ373JT.js} +1 -1
- package/dist/chunks/{fitment-data-HO7IRCLU.js → fitment-data-JL37VB22.js} +1 -1
- package/dist/chunks/{render-client-POVEFYOC.js → render-client-V36O2I3G.js} +1 -1
- package/dist/index.js +36 -17
- package/dist/words.d.ts +2 -0
- package/dist/words.js +2 -2
- package/package.json +3 -3
- package/dist/chunks/SiteEditorProvider-EM7PM3YX.js +0 -1
- package/dist/chunks/chunk-HDRNAE62.js +0 -16
- package/dist/chunks/chunk-XMVMMYNE.js +0 -230
- /package/dist/chunks/{SectionEditorShell-THRVEFYH.js → SectionEditorShell-FHSP7IXG.js} +0 -0
- /package/dist/chunks/{chunk-4NZU2IB7.js → chunk-6ALFNHF5.js} +0 -0
- /package/dist/chunks/{chunk-TWNYQY4T.js.LEGAL.txt → chunk-AS47U6BL.js.LEGAL.txt} +0 -0
- /package/dist/chunks/{chunk-HDRNAE62.js.LEGAL.txt → chunk-GB535QZ5.js.LEGAL.txt} +0 -0
- /package/dist/chunks/{chunk-GONJOVIE.js → chunk-NGRN4SN6.js} +0 -0
|
@@ -0,0 +1,234 @@
|
|
|
1
|
+
import{$a as jr,$h as no,Ae as zi,Ce as _i,Da as bt,De as Oi,Eg as ea,Fa as Bt,Gb as Ci,Ge as Zt,Ha as $e,Hb as Ti,Hf as Xn,I as mr,Ia as Dr,Ig as ta,Ja as wt,Jf as Bi,Jg as na,K as Ot,Ka as Wt,Kf as Wi,Kg as oa,L as gr,Lc as le,Lg as ra,Ma as Fr,Mg as ia,N as te,Nc as se,Ng as aa,Nh as ha,O as _e,Oa as zr,Ob as xt,Oc as Ei,Od as Ze,Og as sa,P as yr,Pc as i,Pe as Hi,Ph as Zn,Qa as Xe,Qc as Vt,Qe as Mi,Qg as la,Qh as Jn,R as Wn,Rc as Pi,Rh as Pe,Sa as jt,Sc as Ri,Sg as ca,Sh as ua,T as qe,Ta as qt,Tc as Ai,Tf as ji,U as br,Ua as _r,Ub as vt,Ug as da,Va as Or,Vc as Ge,Wa as Hr,We as Jt,Wh as Qn,Xa as Mr,Xh as fa,Y as wr,Ya as $t,Yc as Ni,Za as Br,Ze as De,Zh as eo,_a as Wr,_h as to,ab as Ee,ad as rt,ai as oo,bb as be,bg as qi,bi as ma,ci as ga,db as qr,dc as Yn,di as ya,e as ur,ee as Le,ei as ba,fb as $r,g as Bn,gb as Gr,gc as Ii,hb as Kr,hg as Gi,hi as xa,ii as va,j as gt,ja as xr,ka as Te,kb as Ur,kg as Qt,ki as Sa,l as yt,le as Fi,ma as vr,mb as Vr,md as Li,me as Xt,na as Sr,nb as Yr,ng as St,o as fr,oa as kr,ob as Xr,pa as Cr,pb as Zr,pg as Vi,pi as ka,qa as Tr,qb as Gt,qg as kt,qi as Ca,rb as Jr,sa as Ye,sg as Yi,ta as nt,tb as qn,th as pa,ua as Ir,ub as Kt,ug as Xi,ui as en,vb as Qr,vd as Di,vg as Zi,wb as ei,wg as Ji,xg as Qi,za as Lr,zd as Yt}from"./chunk-GB535QZ5.js";import{$ as pi,A as ni,Aa as xi,B as oi,Ba as vi,C as ri,Ca as Si,Fa as ki,La as ie,Ma as $i,Oa as Ki,Pa as Ui,S as ii,T as ai,U as si,V as li,Y as ci,Z as $n,_ as di,aa as hi,d as Er,da as ui,e as Pr,ea as Gn,f as Rr,g as Ar,h as Ie,ha as fi,i as Ht,ia as Kn,j as Mt,ka as Un,n as ot,o as jn,oa as mi,p as Nr,ta as Vn,ua as gi,wa as yi,y as Ut,ya as bi,z as ti,za as wi}from"./chunk-6ALFNHF5.js";import{q as wa}from"./chunk-NGRN4SN6.js";import{jsx as ro,Fragment as lc,jsxs as cc}from"react/jsx-runtime";import{createContext as dc,useContext as pc}from"react";var hc={mirrorHostStyles:!0,css:null,fontHrefs:[]},Ta=dc(hc);function om({value:e,children:t}){return ro(Ta.Provider,{value:e,children:t})}function io(){return pc(Ta)}function Ia(){let{css:e,fontHrefs:t}=io();return cc(lc,{children:[t.map(o=>ro("link",{rel:"stylesheet",href:o},o)),e?ro("style",{"data-sf-canvas-css":"",children:e}):null]})}import{jsx as uc}from"react/jsx-runtime";import{createContext as fc,useContext as mc}from"react";var Ea=fc(void 0);function sm({metadata:e,children:t}){return uc(Ea.Provider,{value:e,children:t})}var Pa=()=>mc(Ea);import{jsx as J,jsxs as On}from"react/jsx-runtime";import{useCallback as Hn,useEffect as Ve,useState as Df}from"react";import{ExternalIcon as Ff}from"efficient-easel/icons";import{Button as zf,Tooltip as oc,buttonClasses as _f}from"efficient-shell/ui";import{SettingsSwitch as Of}from"efficient-easel/panel";import{PagesIcon as Hf,StylesIcon as Mf}from"efficient-easel/rail";import{TreeRow as Bf}from"efficient-easel/tree";import{useEaselStrings as Wf}from"efficient-easel/strings";import{jsx as B,Fragment as Bo,jsxs as ht}from"react/jsx-runtime";import{Fragment as sh,useEffect as lh,useId as ch,useMemo as ks,useState as pt}from"react";import{default as tn,PanelHideButton as ao,PanelModeExit as dm,PanelShowStrip as pm}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 Ip,useRef as ys,useState as Sn}from"react";import{jsx as Ke,jsxs as La,Fragment as wc}from"react/jsx-runtime";import{useState as Da}from"react";import{SettingsDefaultReset as xc,SettingsField as vc}from"efficient-easel/panel";import{useEaselStrings as Sc}from"efficient-easel/strings";import{jsx as nn,Fragment as gc,jsxs as Ra}from"react/jsx-runtime";import{Button as Aa,Dialog as yc}from"efficient-shell/ui";function bc(e){return Vt("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 Na({count:e,onCancel:t,onConfirm:o}){return Ra(yc,{open:!0,onClose:t,role:"alertdialog",size:"sm",title:i("Clear this site\u2019s colors?"),footer:Ra(gc,{children:[nn(Aa,{variant:"secondary",onClick:t,children:i("Cancel")}),nn(Aa,{variant:"danger",onClick:o,children:i("Clear colors")})]}),children:[nn("p",{children:bc(e)}),nn("p",{className:"mt-2 font-medium",children:i("This cannot be undone.")})]})}var kc=_i("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 Cc(){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 Tc="Reset color",Ic={selected:0,themes:[]};function Ec(e){e(Ic)}function Fa({value:e,onChange:t}){let o=e?.themes??[],a=o.length===0,s=Ut(e),[l,d]=Da(!1),c=Sc(),[h,g]=Da(null),f=(v,k)=>{t({...s,themes:s.themes.map((u,y)=>y===v?k:u)})},x=oi(s).accent,E=new Set(s.themes.map(v=>v.brandInk).filter(Boolean)),T=ti.filter(v=>!E.has(v)).map(v=>ni(x,v)),A=[...s.themes,...T],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,{...ri(s.themes[s.selected])}];t({...s,themes:v,selected:v.length-1}),g(v.length-1)};return La(wc,{children:[a?null:Ke(vc,{label:i(Tc),icon:Oi(kc),labelId:"sf-theme-reset",action:Ke(xc,{label:i("all theme colors"),words:c.panel,changed:!0,onReset:()=>d(!0)})}),l&&Ke(Na,{count:o.length,onCancel:()=>d(!1),onConfirm:()=>{d(!1),Ec(t)}}),Ke("div",{className:"sf-theme-list",role:"radiogroup","aria-label":i("Theme"),children:A.map((v,k)=>Ke(Ai,{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))}),La("button",{type:"button",onClick:b,className:"sf-theme-add",children:[Ke(Cc,{}),i("Add new theme")]})]})}import{jsx as on}from"react/jsx-runtime";import{SettingsDefaultReset as Pc,SettingsField as Rc}from"efficient-easel/panel";import{SquareIcon as Ac}from"efficient-easel/icons";var Nc="Applies to panels, cards, inputs and buttons. Round things \u2014 color swatches, switches, status dots \u2014 stay round.",so="Corners";function za({value:e,onChange:t,showHint:o=!0}){let a=e===null;return on(Rc,{label:i(so),icon:on(Ac,{}),value:a?void 0:`${e}px`,changed:!a,action:on(Pc,{words:se()?.panel,label:i(so),changed:!a,detail:i("the built-in corners"),onReset:()=>t(null)}),hint:o?i(Nc):void 0,children:on(De,{min:$n,max:di,step:1,value:e??$n,readout:!1,ariaLabel:i(so),onChange:t})})}import{jsx as Ct}from"react/jsx-runtime";import{SettingsDefaultReset as Lc,SettingsField as Dc,SettingsSegmented as Fc}from"efficient-easel/panel";import{ShadowIcon as zc}from"efficient-easel/icons";var lo={none:"None",soft:"Soft",lifted:"Lifted"},_c="Applies to cards \u2014 products, brands, journal entries and filter cells. Round things like swatches and status dots are never shadowed.",Oc={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)"},Hc={labelsPx:90.25,widestLabelPx:34.6};function _a({value:e,onChange:t,showHint:o=!0}){let a=e===null,s=e??Gn;return Ct(Dc,{label:i("Card shadow"),icon:Ct(zc,{}),value:i(lo[s]),changed:!a,action:Ct(Lc,{words:se()?.panel,label:i("Card shadow"),changed:!a,detail:i(lo[Gn]),onReset:()=>t(null)}),hint:o?i(_c):void 0,children:Ct(Fc,{options:ui.map(l=>({id:l,label:i(lo[l]),icon:Ct("span",{className:"sf-shadow-chip",style:{boxShadow:Oc[l]}})})),value:s,ariaLabel:i("Card shadow"),fit:Hc,onChange:t})})}import{jsx as co}from"react/jsx-runtime";import{SettingsDefaultReset as Mc,SettingsField as Bc}from"efficient-easel/panel";import{ShadowIcon as Wc}from"efficient-easel/icons";var jc="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 Oa({value:e,onChange:t,showHint:o=!0}){let a=e===null;return co(Bc,{label:i("Shadow color"),icon:co(Wc,{}),changed:!a,action:Pi({value:e??"",inherited:a?Un:void 0,onChange:t,label:"Shadow color",after:co(Mc,{words:se()?.panel,label:i("Shadow color"),changed:!a,detail:Un,onReset:()=>t(null)})}),hint:o?i(jc):void 0})}import{jsx as rn}from"react/jsx-runtime";import{SettingsDefaultReset as qc,SettingsField as $c}from"efficient-easel/panel";import{AlignSeparateIcon as Gc}from"efficient-easel/icons";var Kc="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",Uc=Fi.Grid;function Ha({value:e,onChange:t,showHint:o=!0}){let a=e===null;return rn($c,{label:i(po),labelId:"sf-block-gap",icon:rn(Gc,{}),value:a?void 0:`${e}px`,changed:!a,action:rn(qc,{words:se()?.panel,label:i(po),changed:!a,detail:i("each block's own spacing"),onReset:()=>t(null)}),hint:o?i(Kc):void 0,children:rn(De,{min:Xt.min,max:Xt.max,step:Xt.step,value:a?Uc:e,readout:!1,ariaLabel:i(po),onChange:t})})}import{jsx as an}from"react/jsx-runtime";import{SettingsDefaultReset as Vc,SettingsField as Yc,SettingsSegmented as Xc}from"efficient-easel/panel";import{HoverIcon as Zc}from"efficient-easel/icons";var ho={none:"None",lift:"Lift",highlight:"Highlight"},Jc="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 Ma({value:e,onChange:t,showHint:o=!0}){let a=e===null,s=e??Kn;return an(Yc,{label:i("Hover effect"),icon:an(Zc,{}),value:i(ho[s]),changed:!a,action:an(Vc,{words:se()?.panel,label:i("Hover effect"),changed:!a,detail:i(ho[Kn]),onReset:()=>t(null)}),hint:o?i(Jc):void 0,children:an(Xc,{options:fi.map(l=>({id:l,label:i(ho[l])})),value:s,ariaLabel:i("Hover effect"),onChange:t})})}import{jsx as sn}from"react/jsx-runtime";import{SettingsDefaultReset as Qc,SettingsField as ed,SettingsSegmented as td}from"efficient-easel/panel";import{ImageIcon as nd}from"efficient-easel/icons";var uo="Hero image",fo=[{followsWidth:!1,label:Yn.full},{followsWidth:!0,label:Yn.page}],od="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 Ba({value:e,onChange:t,showHint:o=!0}){let a=e===null,s=e??!1;return sn(ed,{label:i(uo),icon:sn(nd,{}),value:i(fo.find(l=>l.followsWidth===s).label),changed:!a,action:sn(Qc,{words:se()?.panel,label:i(uo),changed:!a,detail:i(fo.find(l=>!l.followsWidth).label),onReset:()=>t(null)}),hint:o?i(od):void 0,children:sn(td,{options:fo.map(l=>({id:l.followsWidth,label:i(l.label)})),value:s,ariaLabel:i(uo),onChange:t})})}import{jsx as ln}from"react/jsx-runtime";import{SettingsDefaultReset as rd,SettingsField as id,SettingsSegmented as ad}from"efficient-easel/panel";import{DropIcon as sd}from"efficient-easel/icons";var mo="Photography",Wa={shot:"As shot",mono:"Black and white"},go=[{grayscale:!1,label:Wa.shot},{grayscale:!0,label:Wa.mono}],ld="Black and white photographs return to color on hover. Wheels and tyres keep their real finish either way.";function ja({value:e,onChange:t,showHint:o=!0}){let a=e===null,s=e??!1;return ln(id,{label:i(mo),icon:ln(sd,{}),value:i(go.find(l=>l.grayscale===s).label),changed:!a,action:ln(rd,{words:se()?.panel,label:i(mo),changed:!a,detail:i(go.find(l=>!l.grayscale).label),onReset:()=>t(null)}),hint:o?i(ld):void 0,children:ln(ad,{options:go.map(l=>({id:l.grayscale,label:i(l.label)})),value:s,ariaLabel:i(mo),onChange:t})})}import{jsx as cn}from"react/jsx-runtime";import{SettingsDefaultReset as cd,SettingsField as dd}from"efficient-easel/panel";import{PaddingXIcon as pd}from"efficient-easel/icons";var yo="Side space",bo=vt.default,hd="The room left at the left and right edge of every page.";function qa({value:e,onChange:t,showHint:o=!0}){let a=e===null;return cn(dd,{label:i(yo),labelId:"sf-side-space",icon:cn(pd,{}),value:`${e??bo}px`,changed:!a,action:cn(cd,{words:se()?.panel,label:i(yo),changed:!a,detail:`${bo}px`,onReset:()=>t(null)}),hint:o?i(hd):void 0,children:cn(De,{min:vt.min,max:vt.max,step:vt.step,value:e??bo,readout:!1,ariaLabel:i(yo),onChange:t})})}import{jsx as dn}from"react/jsx-runtime";import{SettingsDefaultReset as ud,SettingsField as fd}from"efficient-easel/panel";import{WidthIcon as md}from"efficient-easel/icons";var wo="Content width",xo=xt.default,gd="The standard width every page on this site renders at.";function $a({value:e,onChange:t,showHint:o=!0}){let a=e===null;return dn(fd,{label:i(wo),labelId:"sf-site-width",icon:dn(md,{}),value:`${e??xo}px`,changed:!a,action:dn(ud,{words:se()?.panel,label:i(wo),changed:!a,detail:`${xo}px`,onReset:()=>t(null)}),hint:o?i(gd):void 0,children:dn(De,{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 wn,Fragment as No}from"react/jsx-runtime";import{FieldSelect as op}from"efficient-easel/fields";import{SettingsField as xn}from"efficient-easel/panel";import{Tooltip as cs}from"efficient-shell/ui";import{AccentIcon as rp,CaseIcon as ip,StylesIcon as ap,TextLinesIcon as ps,TextSizeIcon as Pt,TextSmallIcon as sp,TypeIcon as lp,WeightIcon as cp}from"efficient-easel/icons";import{jsx as I,jsxs as ne,Fragment as It}from"react/jsx-runtime";import{useEffect as gn,useId as Dd,useRef as Eo,useState as Po}from"react";import{jsx as it,jsxs as Ga}from"react/jsx-runtime";import{Tooltip as yd}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(yd,{content:s,children:it("button",{type:"button",className:"sf-part-mark","aria-label":l,onClick:t,children:it(bd,{})})})}function bd(){return Ga("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"}),Ga("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 os,InspectorField as Fd}from"efficient-easel/fields";import{SettingsField as rs,SettingsGroup as zd}from"efficient-easel/panel";import{InspectorUpLevel as yn}from"efficient-easel/chrome";import{StylesIcon as _d,TextColorIcon as Od,TypeIcon as is}from"efficient-easel/icons";import{useEasel as Hd}from"efficient-easel/easel";import{Tooltip as Md}from"efficient-shell/ui";import{jsx as pn,jsxs as vo}from"react/jsx-runtime";import{ColorSwatch as wd,Tooltip as xd}from"efficient-shell/ui";function Ka({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:[pn("span",{className:"sf-part-ink-label",children:i(t)}),pn("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=>pn(xd,{content:`${i(h.name)} \xB7 ${h.value.toUpperCase()}`,children:pn(wd,{color:h.value,"aria-label":i(h.name),size:"sm",selected:l===h.key,onClick:()=>a(l===h.key?null:h.key)})},h.key)),Ri({value:d?"":(c??"").toLowerCase(),label:"Any color",onChange:a})]})]})}import{jsx as Io,jsxs as Ed}from"react/jsx-runtime";import{COPY_CELLS as un,CopyBox as Pd}from"efficient-easel/copy";import{PaddingYIcon as Rd,WidthIcon as Ad}from"efficient-easel/icons";import{useSyncExternalStore as vd}from"react";function at(e,t){let o=Hr(e);return o?.control==="textList"?t.rowKey===(o.itemKey??"text")?Wi(o,t.index):null:Mr(e)?.[t.rowKey]??null}function hn(e,t,o){let a=e.node.props,{key:s,row:l}=$e(e.propKey),d=l?Wr(a,s,l,e.kind,t):Or(a,s,e.kind,t);return d?(o(e.zone,e.index,{...e.node,props:d}),!0):!1}var Sd=["bold","italic","underline","strike","link","sup","sub"],kd=["bullet","number"];function Co(e,t){return e?[...Sd,...t?kd:[]]:[]}function Ua(e,t){let o=Dr(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}=$e(s),g=t.components[l.type]?.fields?.[c],f=h?at(g,h):g,x=jt(f);if(!x)return null;let E=l.props??{};if(h&&!(Array.isArray(E[c])&&h.index<E[c].length))return null;let T=h?$t(E[c],h):E[c];return{node:l,selector:d,propKey:s,kind:x,stored:T,offPage:Zt(f)}}function Va(e,t){let o=Ua(e,t);if(!o||o.offPage)return null;let{text:a,hidden:s}=Xe(o.stored);if(s)return null;let l=qt(o.kind);return{partId:e,value:a,rules:Wt,multiline:l,offered:Co(o.kind!=="plainText",l),write:d=>{let c=Ua(e,t);c&&hn({node:c.node,propKey:c.propKey,kind:c.kind,zone:c.selector.zone,index:c.selector.index},d,t.replace)}}}function Ya(e,t,o){return e?.isConnected&&e.getAttribute(Ee)===o?e:t?.querySelector(`[${Ee}="${Cd(o)}"]`)??null}function Cd(e){return e.replace(/["\\]/g,"\\$&")}function Xa(e){let t=e.activeElement;return t?t.tagName==="IFRAME"||!!t.closest(".es-canvas"):!1}var So=null,ko=new Set;function Td(){return So}function To(e){if(e!==So){So=e;for(let t of ko)t()}}function Id(e){return ko.add(e),()=>{ko.delete(e)}}function Za(){return vd(Id,Td,()=>null)}var Nd=["left","center","right","justify"];function Ja({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 T=ei(l),A=l.size??d.sizePx,P=[{...un.fontSize,value:l.size,styleValue:Math.round(d.sizePx),onChange:v=>c({size:v??null})},{...un.lineHeight,value:T.lineHeight,styleValue:d.lineRatio,onChange:v=>c(v===void 0?{lineHeight:null,line:null}:{lineHeight:v})},{...un.letterSpacing,scale:A,value:T.letterSpacingEm,styleValue:d.letterEm,onChange:v=>c(v===void 0?{letterSpacing:null,letter:null}:{letterSpacing:v})},{...un.paragraphSpacing,value:l.paragraphSpacing,styleValue:0,onChange:v=>c({paragraphSpacing:v??null})},{key:"padding",name:i("Padding"),icon:Io(Rd,{}),unit:"px",step:Xr,shiftStep:10,min:Vr,max:Yr,value:l.padding,styleValue:d.paddingPx,onChange:v=>c({padding:v??null})},{key:"width",name:i("Width"),icon:Io(Ad,{}),unit:"px",step:Jr,shiftStep:100,min:Zr,max:Gt,value:l.width,styleValue:d.widthPx,onChange:v=>c({width:v??null})}],b=Co(a,o);return Ed("div",{className:"sf-part-textbox",children:[x,Io(Pd,{value:e,onChange:t,multiline:o,placeholder:g,ariaLabel:f,rules:Wt,tools:b,barShows:E?"focus":"always",colors:a?h:[],align:s?{value:l.align??d.align,allow:Nd,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 Ld={CollectionCard:"product",FooterMenu:"menu",Gallery:"product",GalleryItem:"product",ProductGrid:"product",ProductHero:"product",SpecTable:"product",Events:"blog",FeaturedCover:"blog",LongRead:"blog",SubscribeBlogs:"blog"},Qa={product:"Synced from the product.",blog:"Synced from the blog post.",menu:"Synced from the site menu."},es="Open",ts={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 fn(e){return Ld[e]??null}var Bd={400:"Regular",500:"Medium",600:"Semibold",700:"Bold"},as=[{key:"font",label:"Font",group:"Style"},{key:"color",label:"Color",group:"Style"}],Wd=[...new Set(as.map(e=>e.group))],jd={font:I(is,{}),color:I(Od,{})};function Et(e){return e?i(e):null}function Qe(e){return e.kind==="role"?Mt[e.role]:e.kind==="custom"?"Custom":null}var qd=e=>e.kind==="role"?`role:${e.role}`:e.kind;function $d(e){let t=e.role;return t&&Ht.includes(t)?{kind:"role",role:t}:null}function Gd(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 $d(qn(e,t))??Gd(o,a)}function ss(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 Kd(e){return Object.values(e).filter(t=>t!==void 0).length}function Ud(e,t){let o=e.style[t];return t==="color"?o??"":o!==void 0?String(o):e.base.fontKey}function Vd({face:e,base:t,onPick:o}){let[a,s]=Po(!1),l=Eo(null),d=Eo(null),c=Dd();gn(()=>{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")})]}),Ht.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(Mt[f])})},f))]})]})}var mn="";function Yd({face:e,base:t,onPick:o}){let a=e.kind==="role"?e.role:mn,s=[{label:i("No style"),value:mn},...Ht.map(l=>({label:i(Mt[l]),value:l}))];return I(os,{ariaLabel:i("Style"),value:a,options:s,inline:!0,onChange:l=>o(l===mn?null:l),renderOption:l=>l.value===mn?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 Xd({parts:e,onEditStyle:t,onClearAll:o,onFollowStyle:a,kindLabel:s}){let l=Ao(e,f=>qd(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+Kd(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(Vd,{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(Bd[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 Zd({sectionName:e,onBack:t,textEditor:o,styleRow:a,children:s}){return ne("div",{className:"sf-part-panel",children:[I(yn,{inline:!0,name:i(e),onSelect:t}),o,a,s]})}function bn({source:e,slug:t}){let o=Yt(),a=ts[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(Qa[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(es)})]}):null]})})}var ns=4,Jd=120;function Qd({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(rs,{label:i("Style"),icon:I(_d,{}),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(Yd,{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(bn,{source:l,slug:d}):null,I(yn,{inline:!0,name:i("Page"),onSelect:c})]})}function ep({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(yn,{inline:!0,name:i("Page"),onSelect:e})]})}function tp({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(yn,{inline:!0,name:i("Page"),onSelect:e})]})}function ls({nodeId:e,propKey:t,onBack:o,onEditStyle:a}){let{getItemById:s,getSelectorForId:l,config:d}=Hd(N=>N),c=rt(),h=Za(),{partStyle:g}=Bt(),{fonts:f}=ie(),[x,E]=Po({}),T=Eo(null),A=s(e),P=l(e),b=A?d.components[A.type]:void 0,{key:v,row:k}=$e(t),u=b?.fields?.[v],y=k?at(u,k):u,L=wt(e,t),w=A?.props??{},F=jt(y),_=Zt(y),ge=$r(y),V=A?fn(A.type):null,M=k?$t(w[v],k):w[v],X=!!k&&!(Array.isArray(w[v])&&k.index<w[v].length);gn(()=>{Xa(document)||T.current?.querySelector(".es-copy [contenteditable='true'], .es-copy textarea, .sf-copybox textarea, .sf-copybox input")?.focus()},[L]);let[de,D]=Po(0);gn(()=>D(0),[L]);let ee=!!A&&!X&&(!P||!y);gn(()=>{if(!ee||de>=ns)return;let N=setTimeout(()=>D(Z=>Z+1),Jd);return()=>clearTimeout(N)},[ee,de]);let Ae=ee&&de<ns;if(!A||X)return I(ep,{onBack:o});let we=ta(A.type),Me=we?ea(we,t):null;if(we&&Me){let N=g?.partId===L?g:null,Z=we[Me],ve=Z.writable===!0&&!!P,Se=ue=>{P&&c.replaceComponent(P.zone,P.index,{...A,props:Kt(w,t,"role",ue)})};return I(Qd,{region:Z,sizePx:N?.base.sizePx??null,face:Ro(w,t,N,f),base:N?.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(tp,{onBack:o,partId:L,why:P?"no field":"no selector"});let xe=N=>{c.replaceComponent(P.zone,P.index,{...A,props:N})},Ce=N=>{if(Xe(N).hidden!==Xe(M).hidden||!F){let Z=k?Br(w,v,k,N):{...w,[v]:N};Z&&xe(Z);return}hn({node:A,propKey:t,kind:F,zone:P.zone,index:P.index},Xe(N).text,c.replaceComponent)},Be=M,ye=Ti(A?.type,t),fe=qn(w,ye),Q=g?.partId===L?g:null,G=[{partKey:ye,face:Ro(w,ye,Q,f),sizeGroup:Q?.sizeGroup??null,base:Q?.base??np,style:fe}],ze=Ao(G,N=>N.sizeGroup),S=Lr(Q?.inks),q=(N,Z)=>{let ve=w;for(let Se of G)ve=Kt(ve,Se.partKey,N,Z);xe(ve)},$=N=>q("role",N),pe=()=>{let N=w;for(let Z of G)N=Qr(N,Z.partKey);xe(N)},he=N=>{let Z=w;for(let ve of G)for(let[Se,ue]of Object.entries(N))Z=Kt(Z,ve.partKey,Se,ue??null);xe(Z)},We=(N,Z)=>{let ve=G.some(Ne=>Ne.style[N]!==void 0),Se=Ao(G,Ne=>Ud(Ne,N)),ue=Se===null,tt=`sf-part-${e}-${t}-${N}`;return N==="color"?I(Ka,{value:ue?null:String(Se),label:Z,colors:S,onChange:Ne=>q("color",Ne)},N):I(rs,{label:i(Z),icon:jd[N],className:"sf-part-field",changed:ve,htmlFor:tt,action:ve?I(Je,{label:Z,onClear:()=>q(N,null)}):void 0,children:N==="font"?I(os,{id:tt,ariaLabel:i(Z),value:!ue&&Ie(String(Se))?String(Se):void 0,placeholder:ue?i("Mixed"):i("Site style"),options:Er.map(Ne=>({label:Ne.label,value:Ne.key})),onChange:Ne=>q("font",Ne||null)}):null},N)},oe=F==="text"||F==="textarea",{text:re,hidden:me}=Xe(M),je=y?.[zr]?.label??t,_t=me?i("Show {label} on the slide",{label:i(je)}):i("Hide {label} on the slide",{label:i(je)}),sc=ne("div",{className:"sf-field-head",children:[I(is,{}),I("span",{className:"sf-field-label sf-field-label--inline",children:i(je)}),oe&&I(Md,{content:_t,children:I("button",{type:"button",className:"sf-field-eye","aria-pressed":me,"aria-label":_t,onClick:()=>Ce({text:re,hidden:!me}),children:me?I(Le,{name:"eye-off",size:14}):I(Le,{name:"eye",size:14})})})]}),Mn=!_&≥return ne(Zd,{sectionName:b?.label??A.type,onBack:o,textEditor:ne("div",{ref:T,className:"sf-part-text",children:[F?I(Ja,{text:re,onTextChange:N=>Ce(oe?{text:N,hidden:me}:N),multiline:qt(F),markup:F!=="plainText",styled:Mn,style:G[0].style,base:G[0].base,setValue:he,colors:S.map(N=>({name:N.key,label:i(N.name),value:N.value})),placeholder:Et(_r(y))??void 0,ariaLabel:i(je),head:sc,typedOnCanvas:h===L}):I(Fd,{field:y,name:t,value:Be,onChange:Ce,id:`sf-part-${e}-${t}`}),Mn&&F&&ze===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(bn,{source:V,slug:Tt(w)}),Mn&&Wd.map(N=>{let Z=as.filter(ue=>ue.group===N),ve=Z.filter(ue=>G.some(tt=>tt.style[ue.key]!==void 0)).length,Se=`sf-part-g-${e}-${t}-${N.replace(/\W+/g,"-")}`;return ne(zd,{id:Se,title:i(N),open:x[N]!==!0,onToggle:ue=>E(tt=>({...tt,[N]:!ue})),count:ve,children:[I(Xd,{parts:G,onEditStyle:a,onClearAll:pe,onFollowStyle:$,kindLabel:Ci[ye]}),Z.map(ue=>We(ue.key,ue.label))]},N)})]})}var np={fontKey:"",sizePx:16,weight:400,lineRatio:1.4,letterEm:0,align:"left",case:"none",paddingPx:0,widthPx:Gt};var dp=[{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(rp,{})},{role:"body",title:"Body",group:"body",step:"body",base:14,icon:z(ps,{})},{role:"label",title:"Labels",group:"label",step:"label",base:11,icon:z(sp,{})}];var pp=9,st=500,hp=100,up=80,fp=4,mp=600,gp=700,yp=400,bp="0.18em";function wp({id:e,value:t,onChange:o}){let a=Rr().flatMap(([l,d])=>d.map(c=>({label:c.label,value:c.key,group:i(Pr[l])}))),s=(l,d)=>z("span",{style:{fontFamily:`var(${Ie(l)?.cssVar??"--font-body"})`},children:d});return z(op,{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 xp({label:e,icon:t,readout:o,min:a,max:s,step:l,value:d,onChange:c,action:h,hint:g}){return z(xn,{label:i(e),icon:t,value:o,action:h,hint:g,children:z(De,{min:a,max:s,step:l,value:d,readout:!1,ariaLabel:i(e),onChange:c})})}function Lo({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(xp,{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 ds({label:e,icon:t,options:o,value:a,onChange:s,hint:l,action:d}){return z(xn,{label:i(e),icon:t,value:vp(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 vp=e=>e===void 0?void 0:i(e),Sp=[{value:"authored",label:"As designed"},{value:"sentence",label:"As typed"}],kp=[{value:"normal",label:"Normal"},{value:"tight",label:"Tight"},{value:"compressed",label:"Compressed"}];function Cp({fontKey:e,weight:t,fallbackWeight:o,onWeight:a}){let s=(t??o)>=mp,l=Ar(e),d=Ie(e)?.label??i("This face");return z(xn,{label:i("Style"),icon:z(ap,{}),value:s?i("Bold"):i("Normal"),hint:i("Bold is the weight above \u2014 one value, two ways to set it."),children:wn("div",{className:"sf-rungs",children:[z(cs,{content:i("Bold"),className:"sf-rung-tip",children:z("button",{type:"button","aria-pressed":s,"aria-label":i("Bold"),onClick:()=>a(s?yp:gp),className:`sf-rung sf-rung--glyph${s?" is-active":""}`,style:{fontWeight:700},children:"B"})}),z(cs,{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 hs({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}),T=b=>b==="accent"?"weightStrong":b==="heading2"?"weight2":b==="heading3"?"weight3":"weight",A=b=>b==="heading2"?"case2":b==="heading3"?"case3":"case",P=yi(t);return z("div",{className:"sf-style-list",children:dp.map(b=>{let v=a===b.role;return z(Di,{styleKey:b.role,label:b.title,icon:b.icon,value:Ie(e[b.role])?.label??e[b.role],sampleStyle:Tp(b,e,o,P),open:v,onToggle:()=>s(v?null:b.role),saved:x===b.role,children:v&&wn(No,{children:[z(xn,{label:i("Font"),icon:z(lp,{}),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(wp,{id:`sf-font-${b.role}`,value:e[b.role],onChange:k=>l(b.role,k)})}),b.step&&c&&z(Lo,{label:"Size",icon:z(Pt,{}),value:d[b.step],fallback:b.base*2,min:ai,max:si,step:li,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")&&wn(No,{children:[z(Lo,{label:"Weight",icon:z(cp,{}),value:o[T(b.role)],fallback:ot(b.role)?st:o.weight??st,min:bi,max:wi,step:hp,hint:b.role==="accent"?i("Auto = the accent phrase takes the heading's own weight."):void 0,onChange:k=>E({[T(b.role)]:k})}),z(Cp,{fontKey:e[b.role],weight:o[T(b.role)],fallbackWeight:ot(b.role)?st:o.weight??st,onWeight:k=>E({[T(b.role)]:k})})]}),ot(b.role)&&wn(No,{children:[z(ds,{label:"Line & text gap",icon:z(ps,{}),options:kp,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(ds,{label:"Capitals",icon:z(ip,{}),options:Sp,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(Lo,{label:"Largest size",icon:z(Pt,{}),value:o.maxPx,fallback:up,min:xi,max:vi,step:fp,suffix:"px",hint:i("Caps the biggest heading on the site. Auto = each section's own."),onChange:k=>E({maxPx:k})})]})]})},b.role)})})}function Tp(e,t,o,a){let s=Math.max(pp,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=bp),l}import{SettingsTabs as Ep}from"efficient-easel/panel";import{Tooltip as Ab,tabButtonId as Pp,tabPanelId as Rp}from"efficient-shell/ui";import{ContrastIcon as Ap,NoteIcon as Np,SettingsIcon as Lp,TypeIcon as Dp}from"efficient-easel/icons";function us(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 pb,pinPreviewToBottom as fs,pinPreviewToSection as vn,previewFrame as ms,scrollPreviewToSection as gs,scrollPreviewToTop as Do}from"efficient-easel/screen/lib/puck/preview-dom";var Fo="sf-site-styles",Fp="sf-site-styles-tabpanel",_o=!1,zp="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(Np,{size:13}),i(zp)]})})}var bs="text",lt=[{id:"basics",label:"Basics",icon:j(Lp,{})},{id:"theme",label:"Theme",icon:j(Ap,{})},{id:"text",label:"Text",icon:j(Dp,{})}];function _p({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(Fa,{value:e?c.theme:s,onChange:h})}function Op(e,t){let[o,a]=Sn(null),s=ys(null),l=JSON.stringify(e),d=ys(t);return d.current=t,Ip(()=>{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 Hp({themeFromDocument:e,persist:t}){let{appState:o,dispatch:a}=zo(w=>w),[s,l]=Sn(null),{fonts:d,setFonts:c,sizes:h,setSizes:g,headingCompression:f,setHeadingCompression:x,headingTypography:E,setHeadingTypography:T}=ie(),A=o.data,P=A.root?.props??{},b=e?Nr(P.fonts):d,v=e?ii:h,k=e?gi(P.headingCompression):f,u=e?Si(P.headingTypography):E,y=w=>a({type:"replaceRoot",root:{...A.root,props:{...P,...w}},recordHistory:!0}),L=Op({curFonts:b,curCompression:k,curTypography:u},s);return j(hs,{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}):T(w),t(ki(w))},livePx:Bp,savedRole:L})}var Mp={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 Bp(e){if(typeof document>"u")return null;let t=(ms()?.contentDocument??document).querySelector(Mp[e]);if(!t)return null;let o=parseFloat(getComputedStyle(t).fontSize);return Number.isFinite(o)?o:null}function Wp({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?pi[ci(h.cornerStyle)]:hi(h.cornerRadiusPx),f=e?g:l,x=E=>s({type:"replaceRoot",root:{...c.root,props:{...h,...E}},recordHistory:!0});return j(za,{value:f,onChange:E=>{e?x({cornerRadiusPx:E}):d(E),t({corner_radius_px:E})},showHint:o})}function jp(e){return{site_width:e}}function qp({persist:e,showHint:t}){let{siteWidth:o,setSiteWidth:a}=ie();return j($a,{value:o,onChange:s=>{a(s),e(jp(s),s===null)},showHint:t})}function $p(e){return{block_gap:e}}function Gp(e){return{site_gutter:e}}function Kp({persist:e,showHint:t}){let{siteGutter:o,setSiteGutter:a}=ie();return j(qa,{value:o,onChange:s=>{a(s),e(Gp(s),s===null)},showHint:t})}function Up({persist:e,showHint:t}){let{blockGap:o,setBlockGap:a}=ie();return j(Ha,{value:o,onChange:s=>{a(s),e($p(s),s===null)},showHint:t})}function Vp({persist:e,showHint:t}){let{heroBackgroundFollowsWidth:o,setHeroBackgroundFollowsWidth:a}=ie();return j(Ba,{value:o,onChange:s=>{a(s),e({hero_background_follows_width:s},!0)},showHint:t})}function Yp({persist:e,showHint:t=!0}){return ct(Rt,{children:[j(qp,{persist:e,showHint:t}),j(Kp,{persist:e,showHint:t}),j(Up,{persist:e,showHint:t}),j(Vp,{persist:e,showHint:t})]})}function Xp(e){return{card_shadow:e}}function Zp(e){return e===null?{shadow_color:null}:{shadow_color:mi(e)}}function Jp(e){return{hover_effect:e}}function Qp({persist:e,showHint:t=!0}){let{cardShadow:o,setCardShadow:a,shadowColor:s,setShadowColor:l,hoverEffect:d,setHoverEffect:c}=ie();return ct(Rt,{children:[j(_a,{value:o,onChange:h=>{a(h),e(Xp(h),!0)},showHint:t}),j(Oa,{value:s,onChange:h=>{l(h),e(Zp(h),h===null)},showHint:t}),j(Ma,{value:d,onChange:h=>{c(h),e(Jp(h),!0)},showHint:t})]})}function eh(e){return{photography_grayscale:e}}function th({persist:e,showHint:t}){let{photographyGrayscale:o,setPhotographyGrayscale:a}=ie();return j(ja,{value:o,onChange:s=>{a(s),e(eh(s),!0)},showHint:t})}function nh({persist:e,showHint:t=!0}){return j(Rt,{children:j(th,{persist:e,showHint:t})})}function dt(){let{websiteName:e}=ie();return e?.trim()||$i}function kn({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=us(P);b&&a?.(b.msg,b.tone)}}),[c,h]=Sn(lt[0].id),g=s!==void 0,f=g?s:c,x=g?l??(()=>{}):h,E=lt.find(P=>P.id===f)??lt[0],[T,A]=Sn(_o);return ct(Rt,{children:[j(Ep,{items:lt.map(P=>({...P,label:i(P.label)})),activeId:E.id,onSelect:x,ariaLabel:i("Site styles"),idPrefix:Fo}),ct("div",{id:Rp(Fo,E.id),className:Fp,role:"tabpanel","aria-labelledby":Pp(Fo,E.id),children:[f==="basics"&&ct(Rt,{children:[j(Wp,{themeFromDocument:e,persist:d,showHint:T}),!e&&j(Qp,{persist:d,showHint:T}),!e&&j(Yp,{persist:d,showHint:T}),!e&&j(nh,{persist:d,showHint:T}),j(Oo,{shown:T,onChange:A})]}),f==="theme"&&j(_p,{themeFromDocument:e,persist:d}),f==="text"&&j(Hp,{themeFromDocument:e,persist:d})]})]})}import{InspectorIconButton as dh}from"efficient-easel/chrome";import{Button as Cs,Dialog as ph,FormField as hh,Input as Ts,toast as Is}from"efficient-shell/ui";import{LayersTree as uh,TreeGroupLabel as fh,TreeRow as Es,TreeRowAction as Wo}from"efficient-easel/tree";import{AddIcon as mh}from"efficient-easel/icons";import{PagesIcon as gh}from"efficient-easel/rail";import{useCallback as Cn,useEffect as oh,useSyncExternalStore as rh}from"react";var ws=new WeakMap;function At(e){let t=ws.get(e);return t||(t={rows:null,loading:null,listeners:new Set},ws.set(e,t)),t}function Ho(e,t){e.rows=t;for(let o of e.listeners)o()}var Tn=new Set;function In(e,t){t?Tn.add(e):Tn.delete(e)}function xs(e){let t=At(e),o=e.listPages().then(a=>Ho(t,Tn.size?a.filter(s=>!Tn.has(s.id)):a),()=>Ho(t,[])).finally(()=>{t.loading===o&&(t.loading=null)});return t.loading=o,o}var vs=()=>null,ih=()=>()=>{};function Mo(){let{adapter:e,ready:t}=le(),o=Cn(c=>{let{listeners:h}=At(e);return h.add(c),()=>h.delete(c)},[e]),a=Cn(()=>At(e).rows,[e]),s=rh(t?o:ih,t?a:vs,vs);oh(()=>{if(!t)return;let c=At(e);c.rows===null&&!c.loading&&xs(e)},[e,t]);let l=Cn(()=>t?xs(e):Promise.resolve(),[e,t]),d=Cn(c=>Ho(At(e),c),[e]);return{rows:s,reload:l,setRows:d,getRows:a}}function ah(e,t){return e?.find(o=>o.slug===t)?.label?.trim()||`/${t}`}function Ss(){let{currentSlug:e}=le(),{rows:t}=Mo();return ah(t,e)}var Ps="sf-editor-pages-collapsed-groups",yh=e=>e.toLowerCase().trim().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,""),Rs=(e,t)=>{let o=yh(e)||"page";if(!t.has(o))return o;let a=2;for(;t.has(`${o}-${a}`);)a+=1;return`${o}-${a}`};function As({onNavigate:e,onClose:t,activeSurface:o,onPreviewSurface:a}){let s=Ge().chrome?.pageRows,l=Yt(),{adapter:d,capabilities:c,ready:h,currentSlug:g}=le(),f=dt(),{rows:x,reload:E,setRows:T,getRows:A}=Mo(),[P,b]=pt(""),[v,k]=pt(!1),[u,y]=pt(null),[L,w]=pt(!1),[F,_]=pt(""),ge=ch(),[V,M]=pt(()=>{if(typeof window>"u")return new Set;try{let S=window.localStorage.getItem(Ps);return new Set(S?JSON.parse(S):[])}catch{return new Set}});lh(()=>{try{window.localStorage.setItem(Ps,JSON.stringify([...V]))}catch{}},[V]);let X=S=>M(q=>{let $=new Set(q);return $.has(S)?$.delete(S):$.add(S),$}),de=ks(()=>ia(x??[]),[x]),D=P.trim().toLowerCase(),ee=S=>!D||S.toLowerCase().includes(D),Ae=S=>D?!0:!V.has(S),we=ks(()=>new Set((x??[]).map(S=>S.slug)),[x]),Me=()=>{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:Rs(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),We=S.slug===g;In(S.id,!0),T(he),y(null),We&&he[0]&&e(he[0].slug);let oe=()=>{In(S.id,!1);let re=A()??[];if(re.some(je=>je.id===S.id))return;let me=[...re];me.splice(Math.max(0,Math.min(pe,me.length)),0,S),T(me)};Is.undoable(i("Deleted \u201C{name}\u201D",{name:S.label}),{actionLabel:i("Undo"),commit:async re=>{await $(S.id,re),In(S.id,!1)},undo:()=>{oe(),We&&e(S.slug)},onFail:()=>{oe(),Is.error(i("Couldn\u2019t delete the page \u2014 please retry."))}})},Be=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=ra(S),he=S.kind==="lightbox",We=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:()=>Be(S.slug),children:B(Le,{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(Le,{name:"trash",size:13,strokeWidth:1.7,rounded:!0})})]}):void 0;return B(Es,{icon:B(bh,{}),name:S.label,selected:q,onSelect:()=>e(S.slug),preview:We,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(sh,{children:[B(fh,{count:pe.length,expanded:he,onToggle:()=>X(S),children:q}),he&&pe]},S)},Q=(s?.rows??[]).filter(S=>ee(S.label)).map(S=>{let q=o===S.key;return B(Es,{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(Le,{name:"external-link",size:13,strokeWidth:1.7,rounded:!0})}),rowProps:{"data-shop-surface":S.key}},S.key)}),G=c.hasSiteSettings&&!!s,ze=(()=>{if(x===null)return null;let S=[],q=!1;for(let $ of de){G&&!q&&$.key.startsWith("system:")&&(S.push(fe("shop",s.title,Q)),q=!0);let pe=$.key===oa||$.label===na?i($.label):$.label;S.push(fe($.key,pe,$.rows.map(ye)))}return G&&!q&&S.push(fe("shop",s.title,Q)),S})();return ht("div",{className:"sf-pages",children:[B(tn,{icon:B(gh,{}),title:i("Pages"),context:f,actions:B(dh,{label:i("New page"),onClick:Me,children:B(mh,{size:15})}),onHide:t}),B("div",{className:"sf-pages-find",children:B(Ts,{type:"search",leftIcon:B(Le,{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&&!L&&B("div",{className:"sf-note sf-note--error",role:"alert",children:u}),ze===null?B("div",{className:"sf-note",children:i("Loading\u2026")}):ze.some(Boolean)?B(uh,{ariaLabel:i("Pages"),className:"sf-scroll",children:ze}):B("div",{className:"sf-note",children:P.trim()?i("No pages match your search"):i("No pages yet. Add one with + above.")}),B(ph,{open:L,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(Cs,{variant:"secondary",onClick:()=>w(!1),children:i("Cancel")}),B(Cs,{onClick:()=>{xe()},disabled:v||!F.trim(),loading:v,children:i("Add page")})]}),children:B(hh,{label:i("Page name"),htmlFor:ge,hint:F.trim()?i("URL: /{slug}",{slug:Rs(F,we)}):void 0,error:u??void 0,children:B(Ts,{id:ge,value:F,invalid:!!u,onChange:S=>_(S.target.value),onKeyDown:S=>{S.key==="Enter"&&xe()},placeholder:i("e.g. About")})})})]})}function bh(){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 wh,PhoneIcon as xh,TabletIcon as vh}from"efficient-easel/icons";var Sh={desktop:jo(wh,{}),tablet:jo(vh,{}),mobile:jo(xh,{})},Ns=sa.map(e=>({id:e,get label(){return i(aa[e])},icon:Sh[e]}));import{jsx as W,jsxs as Ue,Fragment as er}from"react/jsx-runtime";import{useState as Au}from"react";import{useEasel as Nu}from"efficient-easel/easel";import{InspectorHead as Lu,InspectorIconButton as nl}from"efficient-easel/chrome";import{DuplicateIcon as Du,TrashIcon as Fu}from"efficient-easel/icons";import{panelFieldsOf as Ls}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 kh,BlockBoxIcon as Ch,BlockButtonIcon as Th,BlockDividerIcon as Ds,BlockFooterIcon as Fs,BlockHeadingIcon as Ih,BlockProductIcon as Eh,BlockSocialIcon as Ph,BlockTextIcon as Rh,ChatIcon as Ah,GridIcon as Nh,ImageIcon as Lh,PageIcon as Dh}from"efficient-easel/icons";var Fh={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:ca,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"})},zh=m("rect",{x:"4",y:"4",width:"16",height:"16",rx:"2.5"}),_h={footer:Fs,Footer:Fs,Divider:Ds,FooterDivider:Ds,Banner:kh,Flex:Ch,FooterSocial:Ph,page:Dh,chat:Ah,Heading:Ih,Text:Rh,ImageBlock:Lh,ButtonBlock:Th,Grid:Nh,ProductRef:Eh},Oh={MenuBlock:"FooterMenu",EmailFormBlock:"FooterEmailSignup",SocialLogosBlock:"FooterSocial",SiteHeader:"header",SiteFooter:"footer"};function ut({type:e,size:t=16,className:o}){let a=Oh[e]??e,s=_h[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:Fh[a]??zh})}import{jsx as ke,Fragment as Hh,jsxs as Mh}from"react/jsx-runtime";import{useEffect as Bh,useId as Wh,useState as jh}from"react";import{SettingsField as zs,SettingsSwitch as qh}from"efficient-easel/panel";import{EyeIcon as $h,TypeIcon as Gh}from"efficient-easel/icons";var Kh="Chat with us",Uh="We usually reply within a few minutes",Vh="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]=jh(t);Bh(()=>d(t),[t]);let c=()=>{l!==t&&a(l)};return ke(zs,{label:e,icon:ke(Gh,{}),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 _s(){let{chat:e,setChat:t}=Qt(),o=Wh();return Mh(Hh,{children:[ke(zs,{label:i("Show the chat bubble"),labelId:o,icon:ke($h,{}),action:ke(qh,{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(Jt,{label:"Wording"}),ke(qo,{label:i("Title"),value:e.title,placeholder:Kh,onCommit:a=>t({title:a})}),ke(qo,{label:i("Subtitle"),value:e.subtitle,placeholder:Uh,onCommit:a=>t({subtitle:a})}),ke(qo,{label:i("Greeting message"),value:e.greeting,placeholder:Vh,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 Ms}from"react/jsx-runtime";import{useEffect as Yh,useId as Os,useState as Hs}from"react";import{SettingsField as Xh}from"efficient-easel/panel";var Zh={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 Jh({platform:e}){let{rows:t,saveLink:o}=St(),{value:a,error:s}=t[e],[l,d]=Hs(a),[c,h]=Hs(!1),g=Os(),f=Os();Yh(()=>d(a),[a]);let x=async()=>{if(l.trim()===a){l!==a&&d(a);return}h(!0),await o(e,l),h(!1)},E=Ui[e];return Ms($o,{children:[et(Xh,{label:i(E),htmlFor:g,icon:et(da,{platform:e,iconStyle:"outline",size:18}),children:et("input",{id:g,type:"text",inputMode:"url",value:l,placeholder:Zh[e],onChange:T=>d(T.target.value),onBlur:()=>{x()},onKeyDown:T=>{T.key==="Enter"&&T.currentTarget.blur(),T.key==="Escape"&&(d(a),T.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 Bs({unavailable:e}){let{canSave:t}=St();return!t&&e?et($o,{children:e}):Ms($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.")}),Ki.map(o=>et(Jh,{platform:o},o))]})}import{jsx as ft,jsxs as Qh}from"react/jsx-runtime";import{useId as eu,useMemo as tu}from"react";import{useEasel as nu}from"efficient-easel/easel";import{SettingsField as ou,SettingsSwitch as ru}from"efficient-easel/panel";import{EyeIcon as iu}from"efficient-easel/icons";var au="root:default-zone";function Ws({heroId:e}){let{appState:t,dispatch:o}=nu(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=tu(()=>{let f=l?.props.tickerItems;return Array.isArray(f)?f:ha.map(x=>({text:x}))},[l]),h=eu();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:au,destinationIndex:s,data:{...l,props:{...l.props,...f}}});return Qh("div",{children:[ft(Jt,{label:"Ticker"}),ft(ou,{label:i("Show ticker"),labelId:h,icon:ft(iu,{}),action:ft(ru,{checked:d,onChange:f=>g({showTicker:f}),ariaLabelledBy:h})}),ft(Bi,{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 su}from"react/jsx-runtime";import{useCallback as lu,useRef as cu,useState as Nt}from"react";import{InspectorIconButton as du}from"efficient-easel/chrome";import{PopupMenu as pu,PopupMenuItem as hu,PopupMenuLabel as En}from"efficient-shell/ui";import{CopyToPageIcon as uu}from"efficient-easel/icons";import{cloneNodeWithFreshIds as js,docToNode as qw,nodeToDoc as $w}from"efficient-easel/screen/lib/puck/section-doc";function qs({node:e,currentSlug:t,siteId:o,tokenRef:a,runAuthed:s,onNotify:l}){let[d,c]=Nt(!1),[h,g]=Nt(null),f=Ge(),[x,E]=Nt(!1),[T,A]=Nt(null),P=cu(null),[b,v]=Nt(null),k=lu(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),L=async w=>{if(T)return;A(w.slug);let F=js(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(su,{children:[Re("span",{"data-menu-toggle":!0,style:{display:"contents"},children:Re(du,{buttonRef:P,label:i("Duplicate to another page"),hasPopup:"menu",expanded:d,onClick:u,children:Re(uu,{size:15})})}),d&&b&&Re(pu,{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(En,{children:i("Duplicate to page")}),x?Re(En,{children:i("Couldn\u2019t load pages")}):h===null?Re(En,{children:i("Loading\u2026")}):y.length===0?Re(En,{children:i("No other pages")}):y.map(w=>Go(hu,{role:"menuitem",disabled:T!==null,onClick:()=>{L(w)},children:[Re("span",{className:"min-w-0 flex-1 truncate",children:w.label}),T===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 rx,sameInspectorMode as ix,SELECTION_MODE as $s,useScreenParts as ax,useScreenBlockLook as sx,useScreenBlockRules as lx,useScreenBridges as cx,useScreenCanvasFrame as dx,useScreenDevices as px,useScreenDocumentPass as hx,useScreenInspectorPanel as ux,useScreenLeftView as fx,useScreenOwnerName as mx,useScreenPinned as gx,useStandaloneScreenBridges as yx}from"efficient-easel/screen/lib/screen-parts";import{jsx as Lt,jsxs as fu}from"react/jsx-runtime";import{SettingsDrill as mu}from"efficient-easel/panel";var gu="Not shown on the page";function yu({part:e,onOpen:t}){return Lt(mu,{name:i(e.label),preview:e.offPage?i(gu):e.preview||i("Empty"),offPage:e.offPage,status:e.hidden?Lt("span",{className:"sf-entry-eye",role:"img","aria-label":i("Hidden on the page"),children:Lt(Le,{name:"eye-off",size:14})}):void 0,onOpen:()=>t(e.key)})}function Ko(e){return e.filter(t=>!t.identifier)}function Gs({parts:e,onOpen:t,heading:o=!0}){let a=Ko(e);return a.length?fu("div",{className:"sf-entries",children:[o?Lt("h3",{className:"sf-entries-head",children:i("Text")}):null,a.map(s=>Lt(yu,{part:s,onOpen:t},s.key))]}):null}import{jsx as An,jsxs as Vs}from"react/jsx-runtime";import{useState as xu}from"react";import{createNode as vu,newId as Su}from"efficient-easel/data";import{useEasel as ku}from"efficient-easel/easel";import{Button as Uo}from"efficient-shell/ui";var Pn="Flex",bu={FooterMenu:"MenuBlock",FooterEmailSignup:"EmailFormBlock",FooterSocial:"SocialLogosBlock"},wu=e=>{let{id:t,...o}=e;return o},Ks=e=>typeof e=="string"?e:"";function Us(e,t){let o=e.props??{},a=bu[e.type];if(a)return[t(a,wu(o))];switch(e.type){case"FooterLogo":{let s=t("LogoBlock",o.reverse?{reverse:o.reverse}:{}),l=Ks(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:Ks(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(Pn,{direction:o.direction==="horizontal"?"row":"column",content:s.flatMap(l=>Us(l,t))})]}default:return[]}}function Rn(e,t,o){let a=(e&&Array.isArray(e.props?.blocks)?e.props.blocks:[]).flatMap(d=>{let c=Us(d,t);return c.length<=1?c:[t(Pn,{direction:"column",content:c})]}),s=t(Pn,{direction:"row",wrap:!0,share:"equal",content:a}),l=t(Pn,{direction:"column",content:[t("LegalLineBlock")]});return kr(Te,o,[s,l])}function Ys(){let{appState:e,dispatch:t,config:o}=ku(f=>f),{readOnly:a}=le(),[s,l]=xu(!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)=>vu(o,f,x),g=()=>{let f=Rn(c,h,Su(Te));t({type:"setData",data:x=>({...x,content:[...Tr(x.content,f)]}),recordHistory:!0}),l(!1)};return Vs("div",{className:"sf-box-footer-switch",children:[An("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?Vs("div",{className:"sf-box-footer-switch-row",children:[An(Uo,{variant:"primary",size:"sm",onClick:g,children:i("Switch now")}),An(Uo,{variant:"secondary",size:"sm",onClick:()=>l(!1),children:i("Cancel")})]}):An(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 Cu,useMemo as el,useRef as Tu,useState as Xo}from"react";import{useSelectedFields as Iu}from"efficient-easel/easel";import{Inspector as Eu,planFields as tl}from"efficient-easel/fields";var Vo=" text",Xs="Text";function Yo(e){let t=e.rows.filter(o=>o.shown);return t.length===0||t.length===1&&t[0].labelled}function Zs(e){return e.filter(Yo).map(t=>t.key)}function Js(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 Qs(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,Nn=new Set;function Pu(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 Ru=Object.fromEntries(ji.map(e=>{let t=Hi[e];return[e,Jo(t,{},e)]}));function Qo({entries:e,entryCount:t=0}){let{id:o,fields:a,values:s,readOnly:l,onChange:d}=Iu(),[c,h]=Xo(()=>new Set(Nn)),[g,f]=Xo(()=>new Set),x=Tu(null),E=el(()=>{let w=new Map;for(let F of tl(a).rows){if(!F.fold)continue;let _=w.get(F.fold.key)??[];_.push(F.name),w.set(F.fold.key,_)}return w},[a]);Cu(()=>{let w=x.current?.parentElement;if(!w)return;let F=new Set(Zs(Pu(w,E)));f(_=>Qs(_,F)?_:F)});let T=el(()=>Js(a,g),[a,g]),A={key:Vo,rows:Array.from({length:t},()=>({shown:!0,labelled:!0}))},P=Yo(A)?void 0:{key:Vo,title:Xs},[b,v]=Xo(()=>Zo.get(o)),k=Zo.get(o),u=tl(a).buckets,y=k&&u.includes(k)?k:b&&u.includes(b)?b:u[0],L=y===void 0||Mi(u,y)!==!0;return Jo(Eu,{fields:T,values:s,onChange:d,readOnly:l,tab:y,onTab:w=>{Zo.set(o,w),v(w)},tabIcons:Ru,idPrefix:o,ariaLabel:i("Section settings"),lead:L?e:null,leadFold:P,closedFolds:c,onFold:(w,F)=>{F?Nn.delete(w):Nn.add(w),h(new Set(Nn))},children:Jo("span",{ref:x,hidden:!0})})}import{SettingsSwitch as zu}from"efficient-easel/panel";var ol=$s,tr={kind:"header"},nr={kind:"website"},rl={kind:"chat"},il={kind:"social"},Ln="Part";function al(e){return i("Part of {name}",{name:i(e)})}function _u(e,t,o){let a=e.describeNode(t);return{name:o,kindLabel:a?al(a.label):i(Ln)}}function Ou(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 sl({what:e}){let t=Ou(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 Hu={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(kn,{themeFromDocument:!t.capabilities.hasSiteTheme,tokenRef:t.tokenRef,siteId:t.siteId,onNotify:t.onNotify})},chat:{name:"Live chat",kindLabel:"Site settings",icon:"chat",render:()=>W(_s,{})},social:{name:"Social links",kindLabel:"Site settings",icon:"social",render:()=>W(Bs,{unavailable:W(sl,{what:"Social link"})})},ticker:{name:kt,kindLabel:Ln,icon:"ticker",head:(e,t)=>e.kind==="ticker"?_u(t,e.heroId,i(kt)):null,render:e=>W(Ws,{heroId:e.kind==="ticker"?e.heroId:""})},part:{name:Ln,kindLabel:Ln,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}=$e(e.propKey),l=s?at(o.fields[a],s):o.fields[a],d=jr(i(Kr(Gr(l??{},a))),s),c=t.styleNameOfPart(e.nodeId,e.propKey);return{name:c!==null?i(c):d,kindLabel:al(o.label)}},render:(e,t)=>e.kind==="part"?W(ls,{nodeId:e.nodeId,propKey:e.propKey,onBack:()=>t.onSelectNode(e.nodeId),onEditStyle:t.onOpenSiteStyles}):null}},Mu=new Set(["header","website","chat"]);function Bu(e,t){if(e==="puck")return null;let o=Hu[e];return Mu.has(e)&&!t.hasSiteSettings?{...o,kindLabel:"Not part of a template",render:()=>W(sl,{what:o.name})}:o}function ll({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:T}=le(),{websiteName:A,fonts:P}=ie(),{partStyle:b}=Bt(),v=rt({readOnly:T}),{select:k}=bt(),{selectedItem:u,getItemById:y,getSelectorForId:L,config:w,appState:F}=Nu(oe=>oe),_=Ls(w,u?{type:u.type,props:u.props}:null),ge=u?Ur(_??w.components[u.type]?.fields,u.props):[],V=oe=>w.components[oe]?.label??oe,M=u?L(u.props.id):void 0,X=Bu(e.kind,c),de=Ge(),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 je=wt(oe,re),_t=b?.partId===je?b:null;return ss(me.props,re,_t,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")),Me=Ae?.kindLabel??(X?i(X.kindLabel):u?M&&M.zone!==qe?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,Be=Ce?qi(Ce):2,ye=e.kind==="puck"&&u?fn(u.type):null,fe=!!u&&!!M&&M.zone===qe&&u.type!==te&&u.type!==_e,Q=Ot(F?.data,u),G=()=>{Q||M&&v.duplicateComponent(M.zone,M.index)},ze=()=>{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,We]=Au(_o);return Ue("div",{className:`es-sidepanel es-sidepanel--right sf-panel sf-panel--right${he||!(!X&&u)?"":" sf-hints-folded"}`,children:[W(Lu,{icon:W(ut,{type:xe,size:15}),name:we,kind:Me,actions:!s&&e.kind==="puck"&&u&&u.type!==te?Ue(er,{children:[W(nl,{label:i("Duplicate section"),title:Q??void 0,disabled:Q!==null,onClick:G,children:W(Du,{size:15})}),fe&&c.hasSiteSettings&&W(qs,{node:u,currentSlug:f,siteId:x??void 0,tokenRef:h,runAuthed:E,onNotify:l}),W(nl,{label:i("Remove section"),danger:!0,onClick:ze,children:W(Fu,{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(zu,{checked:$,onChange:pe,ariaLabel:i("Preview hover state")})]}),W(zi,{tier:Be,children:W("div",{className:"sf-insp-body sf-scroll",children:X?X.render(e,ee):u?Ue(er,{children:[W(Li,{children:W(Qo,{entries:W(Gs,{parts:ge,heading:!1,onOpen:oe=>k(wt(u.props.id,oe))}),entryCount:Ko(ge).length})}),u.type===te&&c.hasSiteSettings&&W(Ys,{}),ye&&W(bn,{source:ye,slug:Tt(u?.props)}),W(Oo,{shown:he,onChange:We})]}):Ue(er,{children:[W(Qo,{}),f===Ze&&c.hasSiteSettings&&D&&W(D,{})]})})})]})}import{jsx as n,jsxs as p,Fragment as ul}from"react/jsx-runtime";var ae={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 C({w:e,h:t,tone:o="dark",r:a=2,style:s}){return n("div",{style:{width:e,height:t,borderRadius:a,background:ae[o],flex:"none",...s}})}var Wu={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 He({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 cl({over:e,overTone:t,head:o,headSize:a=11.5,cta:s,ctaBg:l,ctaFg:d,tone:c}){return p(ul,{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(He,{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 Oe({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 dl({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 Dn({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 pl({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 ju={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(He,{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(He,{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(Dn,{label:"Name"}),n(Dn,{label:"Email"})]}),n(Dn,{label:"Message",filled:!0}),n(pl,{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(Dn,{label:"Your review",filled:!0}),n(pl,{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(He,{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(He,{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(He,{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(Oe,{k:"Subtotal",v:"$1,956"}),n(Oe,{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(dl,{}),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(dl,{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(cl,{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(He,{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(cl,{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(He,{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(He,{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(Oe,{k:"Diameter",v:'20"'}),n(Oe,{k:"Width",v:"9.0J"}),n(Oe,{k:"Offset",v:"+12"}),n(Oe,{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(Oe,{k:"Hilux N80",v:"20\xD79 +12",ok:!0}),n(Oe,{k:"Ranger PX3",v:"20\xD79 +12",ok:!0}),n(Oe,{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))})},hl={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(C,{w:8,h:8,r:2,tone:"accent"}),n(C,{w:38,h:7,r:3,tone:"dark"}),n(C,{w:16,h:7,r:3,tone:"accent"})]}),n(C,{w:38,h:4,r:2,tone:"soft"})]}),n("div",{style:{height:1,background:ae.line,marginBottom:10}}),p("div",{style:{flex:1,display:"flex",gap:10,border:`1px solid ${ae.line}`,borderRadius:7,padding:10},children:[p("div",{style:{flex:1.1,display:"flex",flexDirection:"column",justifyContent:"center",gap:5},children:[n(C,{w:"46%",h:3,r:2,tone:"accent"}),n(C,{w:"84%",h:8,r:4,tone:"dark"}),n(C,{w:"56%",h:8,r:4,tone:"accent"}),n(C,{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 ${ae.line}`,background:ae.block}}),n(C,{w:34,h:13,r:5,tone:"accent"})]})]}),p("div",{style:{flex:1,background:ae.block,borderRadius:6,padding:8,display:"flex",flexDirection:"column",gap:6},children:[n(C,{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 ${ae.line}`:"none",paddingTop:t?4:0},children:[n(C,{w:34,h:4,r:2,tone:"dark"}),n(C,{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(C,{w:"44%",h:5,r:3,tone:"accent"}),n(C,{w:"88%",h:8,r:4,tone:"dark"}),n(C,{w:"70%",h:8,r:4,tone:"dark"}),n(C,{w:"94%",h:5,r:2,tone:"soft",style:{marginTop:2}}),n(C,{w:"80%",h:5,r:2,tone:"soft"}),n(C,{w:"40%",h:13,r:6,tone:"accent",style:{marginTop:5}})]})]}),sectionheader:p(ul,{children:[n(C,{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(C,{w:16,h:16,r:4,tone:"accent"}),n(C,{w:"20%",h:9,r:4,tone:"dark"})]}),n(C,{w:"62%",h:10,r:5,tone:"dark"}),n(C,{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(C,{w:"22%",h:12,r:4,tone:"dark"}),p("div",{style:{display:"flex",gap:9,alignItems:"center"},children:[n(C,{w:26,h:6,r:3,tone:"soft"}),n(C,{w:26,h:6,r:3,tone:"soft"}),n(C,{w:26,h:6,r:3,tone:"soft"}),n(C,{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(C,{w:"60%",h:9,r:4,tone:"dark"}),n(C,{w:"90%",h:5,r:2,tone:"soft"}),n(C,{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(C,{w:"50%",h:6,r:3,tone:"dark"}),n(C,{w:"80%",h:5,r:2,tone:"soft"}),n(C,{w:"66%",h:5,r:2,tone:"soft"})]},e))]}),n("div",{style:{height:1,background:ae.line}}),p("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[n(C,{w:"30%",h:5,r:2,tone:"soft"}),n(C,{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:ae.block}},t))}),blanksection:n("div",{style:{...R,padding:14,display:"flex"},children:p("div",{style:{flex:1,border:`1px dashed ${ae.line}`,borderRadius:7,display:"flex",alignItems:"center",justifyContent:"center",position:"relative"},children:[n(C,{w:14,h:2,r:1,tone:"tint"}),n(C,{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(C,{w:"100%",h:6,r:3,tone:"soft"}),n(C,{w:16,h:22,r:3,tone:"block",style:{alignSelf:"center"}}),n(C,{w:"100%",h:6,r:3,tone:"soft"})]}),divider:n("div",{style:{...R,padding:14,display:"flex",alignItems:"center"},children:n(C,{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(C,{w:5,h:16,r:2,tone:"dark",style:{transform:"skewX(-14deg)"}}),n(C,{w:16,h:10,r:3,tone:"accent"}),n(C,{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(C,{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(C,{w:"100%",h:6,r:3,tone:"soft"}),n(C,{w:"96%",h:6,r:3,tone:"soft"}),n(C,{w:"100%",h:6,r:3,tone:"soft"}),n(C,{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(C,{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(C,{w:"48%",h:7,r:3,tone:"dark"}),n(C,{w:"82%",h:5,r:2,tone:"soft"}),n(C,{w:"66%",h:5,r:2,tone:"soft"}),n(C,{w:"74%",h:5,r:2,tone:"soft"}),n(C,{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(C,{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 ${ae.line}`}}),n(C,{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(C,{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 ${ae.line}`,display:"flex",alignItems:"center",gap:7,padding:"0 9px"},children:[n("div",{style:{width:9,height:9,borderRadius:5,border:`2px solid ${ae.dark}`}}),n(C,{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 ${ae.dark}`}}),n("div",{style:{padding:"2px 6px",borderRadius:6,border:`1.5px solid ${ae.dark}`},children:n(C,{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 ${ae.line}`},children:[n(C,{w:22,h:6,r:2,tone:"dark"}),n(C,{w:6,h:4,r:1,tone:"soft"})]}),p("div",{style:{width:"46%",display:"flex",flexDirection:"column",gap:4,padding:6,border:`1px solid ${ae.line}`},children:[n(C,{w:"80%",h:4,r:2,tone:"accent"}),n(C,{w:"64%",h:4,r:2,tone:"soft"}),n(C,{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:ae.line}}),p("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[n(C,{w:"38%",h:5,r:2,tone:"soft"}),p("div",{style:{display:"flex",gap:5},children:[n(C,{w:14,h:5,r:2,tone:"soft"}),n(C,{w:14,h:5,r:2,tone:"soft"}),n(C,{w:14,h:5,r:2,tone:"soft"})]})]})]}),fallback:n("div",{style:{position:"absolute",inset:14,borderRadius:8,background:ae.block}})};function fl({type:e}){let t=Wu[e]??"",o=ju[t]??hl[t]??hl.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 qu}from"react/jsx-runtime";import{StylesIcon as $u}from"efficient-easel/rail";import{Tooltip as Gu}from"efficient-shell/ui";function ml({tokenRef:e,siteId:t,onClose:o,onNotify:a,tab:s,onTabChange:l}){let d=dt();return qu("div",{className:"sf-styles",children:[mt(tn,{icon:mt($u,{}),title:i("Site styles"),context:mt(Gu,{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(kn,{tokenRef:e,siteId:t,onNotify:a,tab:s,onTabChange:l})})]})}import{jsx as gl}from"react/jsx-runtime";var Ku="M6 3h12a1 1 0 0 1 1 1v17l-7-4-7 4V4a1 1 0 0 1 1-1z";function yl({size:e=15,className:t,strokeWidth:o=1.7}){return gl("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:gl("path",{d:Ku})})}import{useEffect as sr,useRef as Uu}from"react";var ar="sf-editor-footer-return";function qv(e){if(!(typeof window>"u"))try{window.sessionStorage.setItem(ar,e)}catch{}}function bl(){if(typeof window>"u")return null;try{return window.sessionStorage.getItem(ar)}catch{return null}}function wl(){if(!(typeof window>"u"))try{window.sessionStorage.removeItem(ar)}catch{}}function xl(e,t){let{currentSlug:o,siteId:a,navigate:s,footerOriginSlug:l}=le(),{selected:d}=e,c=e.data?.content??[],h=t.refreshes,g=o===Ze,{editFooter:f}=Gi(),x=Uu(null);sr(()=>{let T=d?.props.id;g&&typeof T=="string"&&(x.current?.(),x.current=vn(T))},[d?.props.id,g]);let E=T=>{x.current?.(),x.current=vn(T)};return sr(()=>{if(!g||!l)return;let T=c.find(A=>A.type===te)?.props?.id;if(T)return x.current?.(),x.current=vn(String(T)),()=>{x.current?.(),x.current=null}},[g,l,h]),sr(()=>{if(!(g||!bl()))return fs(()=>wl())},[]),{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 Fe,Fragment as Vu}from"react/jsx-runtime";import{Fragment as vl,useEffect as Sl,useRef as lr}from"react";import{useTreeDrag as kl}from"efficient-easel/drag";import{ImageIcon as Yu,TextLinesIcon as Xu,TrashIcon as Cl}from"efficient-easel/icons";import{Subtree as Tl,TreeRow as zt,TreeRowAction as Il,TreeSeam as El}from"efficient-easel/tree";import{useEaselStrings as Zu}from"efficient-easel/strings";var zn="ContactLocations";function Ju({size:e=13}){return Fe("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 Qu({size:e=13}){return Fe("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 ef({size:e=13}){return Fe("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 Fn=e=>({parentId:`locations-${e}`,slot:"groups"}),cr=(e,t)=>({parentId:`locations-${e}`,slot:`cities:${t}`});function Pl(e,t){let{readOnly:o,selected:a}=t,s=Zu().tree,l=t.data?.content??[],d=e.kind===ol.kind,c=lr(null);Sl(()=>{let u=a?.type===zn?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}=Xi(),x=ua(),E=(u,y)=>{let L=l[u];L&&t.replace(u,{type:L.type,props:{...L.props,locations:y}})},T=u=>{let y=l[u]?.props?.locations;return Array.isArray(y)?y:[]},A=kl({keyOf:u=>`group:${u.si}:${u.index}`,readOnly:!!o,canDrop:(u,y)=>y.parentId===Fn(u.si).parentId&&y.slot==="groups",onDrop:(u,y)=>{E(u.si,no(T(u.si),u.index,y.index)),x.level==="city"&&Pe({level:"groups"})},onStep:(u,y)=>{E(u.si,no(T(u.si),u.index,y<0?u.index-1:u.index+2)),x.level==="city"&&Pe({level:"groups"})}}),P=kl({keyOf:u=>`city:${u.si}:${u.group}:${u.index}`,readOnly:!!o,canDrop:(u,y)=>y.parentId===Fn(u.si).parentId&&y.slot.startsWith("cities:"),onDrop:(u,y)=>{let L=y.slot.slice(7);E(u.si,oo(T(u.si),u.group,u.index,L,y.index)),Pe({level:"group",key:L})},onStep:(u,y)=>{E(u.si,oo(T(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(()=>{});Sl(()=>{f(u=>{let y=Ji(u);if(!y)return;let L=b.current.findIndex(w=>w.props?.id===y.nodeId);L<0||v.current(L,{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 L=l[u]?.props?.id;typeof L=="string"&&(y.level==="image"||y.level==="map")?g(Zi(L,y.index,y.level)):g(null),typeof L=="string"&&t.scrollTo(L)};return v.current=k,{renderLocationTree:(u,y,{rowClick:L,isCollapsed:w,toggleCollapse:F})=>{let _=T(y),ge=eo(_),V=String(u.props.id),M=d&&a?.props.id===V,X=D=>U(El,{...o?{}:A.seam({place:{...Fn(y),index:D}})},`seam:${V}:groups:${D}`),de=(D,ee)=>U(El,{...o?{}:P.seam({place:{...cr(y,D),index:ee}})},`seam:${V}:cities:${D}:${ee}`);return Fe(Vu,{children:[U(zt,{icon:U(Xu,{size:13}),name:i("Texts"),words:s,onSelect:()=>k(y,{level:"texts"}),selected:M&&x.level==="texts",rowProps:{onClick:L(()=>k(y,{level:"texts"}))}}),ge.map((D,ee)=>{let Ae=`${V}::grp::${D.key}`,we=w(Ae),Me=M&&x.level==="group"&&x.key===D.key,xe=D.name||D.key?fa(D.key,D.name):i("Ungrouped"),Ce={...cr(y,D.key),index:D.cards.length},Be=P.row({item:{si:y,group:D.key,index:-1},place:Ce,into:Ce,canDrag:!1},{onClick:L(()=>k(y,{level:"group",key:D.key}))}),ye=A.row({item:{si:y,index:ee},place:{...Fn(y),index:ee}},Be.rowProps);return Fe(vl,{children:[ee===0&&X(0),U(zt,{icon:U(Ju,{size:13}),name:xe,words:s,onSelect:()=>k(y,{level:"group",key:D.key}),selected:Me,draggable:ye.draggable,dragging:ye.dragging,drop:ye.drop??Be.drop,fold:{open:!we,label:i("group"),onToggle:()=>F(Ae)},actions:U(Il,{kind:"delete",label:Vt("Delete {label} group ({n} city)","Delete {label} group ({n} cities)",D.cards.length,{label:xe}),onClick:()=>{E(y,ya(_,D.key)),Pe({level:"groups"})},children:U(Cl,{size:15})}),rowProps:ye.rowProps,children:U("span",{className:"es-group-count",children:D.cards.length})}),!we&&Fe(Tl,{children:[D.cards.map((fe,Q)=>{let G=to(_,D.key,Q),ze=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:Q},place:{...cr(y,D.key),index:Q}},{onClick:L(()=>k(y,{level:"city",index:G}))});return Fe(vl,{children:[Q===0&&de(D.key,0),U(zt,{icon:U(Qu,{size:13}),name:S,words:s,onSelect:()=>k(y,{level:"city",index:G}),selected:ze,...he,fold:{open:!$,label:S,onToggle:()=>F(q)},actions:U(Il,{kind:"delete",label:i("Delete {name}",{name:S}),onClick:()=>{E(y,ba(_,D.key,Q)),Pe({level:"group",key:D.key})},children:U(Cl,{size:15})}),rowProps:pe}),!$&&Fe(Tl,{children:[U(zt,{icon:U(Yu,{size:13}),name:i("Image"),words:s,onSelect:()=>k(y,{level:"image",index:G}),selected:M&&x.level==="image"&&x.index===G,rowProps:{onClick:L(()=>k(y,{level:"image",index:G}))}}),U(zt,{icon:U(ef,{size:13}),name:i("Map"),words:s,onSelect:()=>k(y,{level:"map",index:G}),selected:M&&x.level==="map"&&x.index===G,rowProps:{onClick:L(()=>k(y,{level:"map",index:G}))}})]}),de(D.key,Q+1)]},Qn(fe))}),Fe("button",{type:"button",className:"sf-add-card",onClick:()=>{let fe=ma(_,D.key);E(y,fe);let Q=eo(fe).find(G=>G.key===D.key);Pe(Q&&Q.cards.length?{level:"city",index:to(fe,D.key,Q.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)}),Fe("button",{type:"button",className:"sf-add-card",onClick:()=>{let{cards:D,key:ee}=ga(_);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===zn&&Pe({level:"groups"})}}}import{useEffect as rf,useRef as af}from"react";import{createNode as sf,newId as lf}from"efficient-easel/data";import{useEaselApi as cf}from"efficient-easel/easel";import{resetForDocumentSwitch as tf,saveStatusForNewDocument as nf,saveStatusOf as of}from"efficient-easel/screen/lib/document-switch";function Rl(e){return!e.docId||e.saveStatus==="saving"?!1:e.seededDocId!==e.docId}function Al(e,t){let{capabilities:o,currentSlug:a,docId:s,data:l,saveStatus:d}=le(),{hasSiteSettings:c,hasPinnedChrome:h}=o,g=a===Ze,f=cf().getState,x=af(null);rf(()=>{if(!Rl({docId:s,saveStatus:d,seededDocId:x.current})||(x.current=s,!h))return;let E=f().appState.data,T=E.content,A=l?.content??[],P=(u,y)=>u.some(L=>L?.type===y);if(!c){let u=new Set(Wn(T)),y=u.size?T.filter(w=>!u.has(w.props.id)):T;u.size&&e.setDocument({...E,content:y});let L=yr(y,A);if(L.includes(te)){let w=y.length,F=e.insertSection(te,w);e.replaceComponent(qe,w,{type:te,props:{id:F,blocks:Jn()}})}L.includes(_e)&&e.insertNode(qe,0,Zn());return}if(g){let u=Cr(T);if(u!==T&&e.setDocument({...E,content:[...u]}),!u.find(y=>y.type===te)&&!P(A,te)&&!P(u,Te)&&!P(A,Te)){let y=(w,F)=>sf(t,w,F),L={type:te,props:{blocks:Jn()}};e.insertNode(qe,u.length,Rn(L,y,lf(Te)))}return}let b=T.filter(u=>u.type!==te),v=new Set(Wn(b)),k=v.size?b.filter(u=>!v.has(u.props.id)):b;k.length!==T.length&&e.setDocument({...E,content:k}),!P(k,_e)&&!P(A,_e)&&e.insertNode(qe,0,Zn())},[s,d,l,f,e,c,h,g])}import{useEffect as Dl,useState as Fl}from"react";var _n=new Map;async function df(e,t){try{return(await gt().site.get({siteId:t})).slug?.trim()||null}catch(o){return console.warn("[editor-site-slug] could not resolve the site slug",o),null}}function Nl(e,t){let o=_n.get(t);return o||(o=df(e,t),_n.set(t,o),o.catch(()=>{_n.get(t)===o&&_n.delete(t)})),o}var pf=/^(localhost|(?:[a-z0-9-]+\.)+localhost|127(?:\.\d{1,3}){3}|0\.0\.0\.0|\[::1\]|::1)$/i;function dr(e){return!!e&&pf.test(e)}function Ll(e){let{pageSlug:t,siteSlug:o,hostname:a}=e,s=t===Ii?"/":`/${encodeURIComponent(t)}`;if(!dr(a))return s;let l=o?.trim();return l?`${s}?site=${encodeURIComponent(l)}`:s}function zl(e){let{pageSlug:t,siteId:o,token:a}=e,[s,l]=Fl(null),[d,c]=Fl(null),h=wa();Dl(()=>c(h?new URL(h).hostname:window.location.hostname),[h]),Dl(()=>{if(!dr(d)||!o||!a){l(null);return}let f=!1;return Nl(a,o).then(x=>{f||l(x)}),()=>{f=!0}},[d,o,a]);let g=Ll({pageSlug:t,siteSlug:s,hostname:d});return h?`${h}${g}`:g}import{buildPaletteSections as hf,categoryLabel as uf,matchesQuery as ff,paletteWithoutPinned as mf,pinnedSection as gf}from"efficient-easel/screen/lib/puck/palette-sections";var yf={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 _l(e){return yf[e]?.label}var Ol=ur;function Hl(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 Ml="sf-editor-left-view";function Bl(){if(typeof window>"u")return"pages";try{let e=window.localStorage.getItem(Ml);return e==="sections"||e==="styles"||e==="media"?e:"pages"}catch{return"pages"}}function Wl(e){if(!(typeof window>"u"))try{window.localStorage.setItem(Ml,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 bf=new Set(["BookingBox","SubmitBox"]);function $l(e){return typeof e=="string"&&bf.has(e)}import{Fragment as Yl,jsx as pr}from"react/jsx-runtime";import{useMemo as Tf,useRef as Xl}from"react";import{EaselCanvas as If,useEaselApi as Ef}from"efficient-easel/easel";import{jsx as Kl,Fragment as vf,jsxs as Sf}from"react/jsx-runtime";import{useEffect as Ul,useLayoutEffect as kf}from"react";var wf=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);`,xf="storefront-fit-words";function Gl(e){let t=e.createElement("script");return t.id=xf,t.textContent=wf,(e.head??e.documentElement).appendChild(t),()=>{e.__sfFitWords?.(),t.remove()}}var Cf=`
|
|
221
|
+
[${Ee}][${Ee}] { cursor: text; }
|
|
222
|
+
[${be}][${be}][${be}] {
|
|
223
|
+
outline: 1px solid ${pa.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 Vl({children:e,document:t}){let{theme:o,themeMode:a,themeSwitchShown:s}=ie(),l=Ut(o);return Ul(()=>{if(t)return ka(t,{mode:a,switchShown:s})},[t,a,s]),Ul(()=>{if(t)return Ca(t,l)},[t,l]),kf(()=>{if(t)return Gl(t)},[t]),Sf(vf,{children:[Kl(Ia,{}),Kl("style",{children:Cf}),e]})}function Pf({children:e,componentId:t}){let{selectedPartId:o}=bt();return qr(o,t)?pr(Yl,{}):pr(Yl,{children:e})}function Zl(e){let{mirrorHostStyles:t}=io(),o=Pa(),a=Xl(null),s=Rf(a),{onDocument:l}=e;return pr(If,{...e,onDocument:d=>{a.current=d,l?.(d)},typing:s,metadata:e.metadata??o,height:"fill",mirrorStyles:t,frameWrapper:Vl,overlay:Pf})}function Rf(e){let t=Ef(),o=rt(),a=bt(),s=Xl({ops:o,parts:a});return s.current={ops:o,parts:a},Tf(()=>{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=Va(c,l);if(!g)return null;let f=h,x=()=>(f=Ya(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 Jl={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 Af="Save your page changes first";function Ql(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:Af}:{visible:!0,enabled:!0}:{visible:!1,hiddenReason:"no-site"}:{visible:!1,hiddenReason:"not-operator"}:{visible:!1,hiddenReason:"no-console"}}var ec="storefront-editor:save-as-template";function tc(e,{nodeDefaults:t,newNodeId:o,sectionLabel:a,blockIsOffered:s}){let l=fr(e);return l?l(t,o):Ir(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}:{},...en(e)!==en(nt)?{eyebrowLook:en(e)}:{}}},{type:e,props:{...t(e),id:o(e),headPlacement:"own-box"}}]}}:br[e]?.fixed===!0?{type:e,props:{...t(e),id:o(e),layout:"boxes"}}:null}import{useEffect as Nf,useState as Lf}from"react";function nc(){let e=Ge().chrome?.products?.list,[t,o]=Lf(null);return Nf(()=>{if(!e)return;let a=!1;return e().then(s=>{a||o(s)}),()=>{a=!0}},[e]),t}function ac({mode:e,open:t}){let{setSelectedHeroId:o,setSelectHandler:a}=Yi(),s=Wf().tree,l=e,d=l.kind==="ticker"?l.heroId:null,c=Hn(h=>{h&&(t({kind:"ticker",heroId:h}),gs(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"&&J(Bf,{icon:J(ut,{type:"ticker",size:13}),name:i(kt),onSelect:()=>c(f),selected:d===f,rowProps:{onClick:g(()=>c(f))},words:s})}}}function jf(){let{adapter:e,capabilities:t,currentSlug:o,siteId:a,hasUnsavedEdits:s,bridgeCapabilities:l,notifyParent:d,token:c}=le(),{hasPreviewLink:h}=t,g=Ql({hasTrustedConsole:!!c,canCreatePlatformTemplate:l.canCreatePlatformTemplate,capabilities:t,siteId:a,hasUnsavedEdits:s}),f=Hn(()=>{!a||!o||d(ec,{siteId:a,slug:o})},[d,a,o]),x=zl({pageSlug:o,siteId:a,token:c}),E=e.previewHref?.(o)??x;return{barLead:()=>g.visible&&J(oc,{side:"bottom",content:g.enabled?i("Save this website as a platform template"):i(g.disabledReason),children:J("span",{className:"sf-tip-disabled",tabIndex:g.enabled?void 0:0,children:J(zf,{variant:"secondary",disabled:!g.enabled,onClick:f,rightIcon:J(yl,{}),children:i("Save as Template")})})}),barTrail:()=>h&&o&&J(oc,{content:i("Preview the live site (opens in a new tab)"),children:On("a",{className:_f({variant:"secondary"}),href:E,target:"_blank",rel:"noopener noreferrer","aria-label":i("Preview the live site in a new tab"),children:[i("Preview"),J(Ff,{size:15})]})})}}function qf(){return On("svg",{width:"17",height:"17",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:1.7,strokeLinecap:"round",strokeLinejoin:"round",children:[J("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"}),J("circle",{cx:"7.7",cy:"11.3",r:"1.05",fill:"currentColor",stroke:"none"}),J("circle",{cx:"12",cy:"8",r:"1.05",fill:"currentColor",stroke:"none"}),J("circle",{cx:"16",cy:"11",r:"1.05",fill:"currentColor",stroke:"none"})]})}function $f(e,t){let{capabilities:o,templateId:a,siteId:s,tokenRef:l,navigate:d}=le(),{hasSiteTheme:c,explainsSiteSettings:h}=o,g=v=>t.setView(v),[f,x]=Df(lt[0].id),{surface:E,setSurface:T}=Vi(),A=()=>{if(c){g("styles"),t.reveal(),Do();return}e.show(nr),e.reveal(),Do()},P={id:"pages",label:i("Pages"),icon:J(Hf,{}),panel:({onHide:v})=>J(As,{activeSurface:E,onPreviewSurface:T,onNavigate:k=>{T(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:J(qf,{}),active:e.kind==="website",onSelect:A}),c&&b.push({id:"styles",label:i("Site styles"),icon:J(Mf,{}),panel:({onHide:v,notify:k})=>J(ml,{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(bs),g("styles")}}}function Gf(e,t,o,a){let{kind:s,open:l}=e,{selected:d,zoneOf:c}=t,h=xl(t,o);Ve(()=>{va(d?.type==="BookingBox"&&d.props.region==="confirm"?Sa(c(String(d.props.id))):null)},[d?.props.id]);let g=Pl(e,t),{capabilities:{hasSiteSettings:f}}=le(),{setSelected:x,setSelectHandler:E}=ie(),{chat:T,setChat:A,setSelected:P,setSelectHandler:b}=Qt(),v=s==="header";Ve(()=>{x(v)},[v,x]),Ve(()=>{E(()=>l(tr))},[E,l]);let k=Hn(()=>l(rl),[l]),u=s==="chat";Ve(()=>{P(u)},[u,P]),Ve(()=>{b(k)},[b,k]);let{setOpenHandler:y}=St(),L=Hn(()=>l(il),[l]);Ve(()=>{y(L)},[y,L]);let w=ac(e),F=jf(),_=$f(e,a),ge=o.device;return{...h,...w,...F,..._,hasOwnRows:V=>V.type===zn,ownRows:g.renderLocationTree,sectionPressed:g.sectionPressed,wrap:V=>J(Qi.Provider,{value:!0,children:J(la.Provider,{value:ge,children:V})}),addPanelRow:V=>f?On("div",{className:"sf-addside-sitewide",children:[J("span",{className:"sf-addside-sitewide-glyph","aria-hidden":"true",children:J(ut,{type:"chat",size:16})}),On("button",{type:"button",className:"sf-addside-sitewide-name",onClick:()=>{V(),k()},children:[i("Live chat"),J("span",{className:"sf-addside-sitewide-desc",children:i("A chat bubble on every page")})]}),J(Of,{checked:T.enabled,onChange:M=>A({enabled:M}),ariaLabel:i("Show the chat bubble on the whole site")})]}):void 0}}var rc=null,hr=new WeakMap;function Kf(e){let t=Ei();if(!e||!t)return e;rc!==t&&(rc=t,hr=new WeakMap);let o=hr.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},hr.set(e,o)),o}var Uf={isLockedBlock:$l,duplicateBlocked:Ot,nestDepth:(e,t,o)=>t===mr?gr(e,o):0,newSectionNode:tc,canAddTo:(e,t)=>Kf(xa(e,t)),blockIsOffered:wr},Vf=new Proxy(Jl,{get:(e,t)=>{let o=Reflect.get(e,t);return typeof o=="string"?i(o):o}}),Yf={labelAtLevel:(e,t,o)=>i(Bn(e,t,o)),descriptions:Vf,categoryLabel:e=>{let t=_l(e);return t===void 0?void 0:i(t)},firstSection:Ol,blockRowName:Hl,plainText:Fr,Icon:ut,Thumbnail:fl,useProducts:nc},Xf={desktop:2e3,tablet:800,mobile:390},ic="desktop",Zf={options:Ns,initial:ic,fluid:ic,widths:Xf},Jf={read:Bl,write:e=>Wl(e),forSelection:(e,t)=>ql(e,t)},Qf={first:_e,last:te,firstGroup:xr,lastGroup:Te,isSectionGroup:vr,sectionGroupZone:Sr,panelOf:e=>e===_e?tr:null};function em(e){return{...ac(e),openSettings:()=>e.show(nr)}}var bk={useOwnerName:dt,useDocumentLabel:Ss,useBridges:Gf,useStandaloneBridges:em,useDocumentPass:Al,blockRules:Uf,blockLook:Yf,devices:Zf,leftView:Jf,pinned:Qf,Canvas:Zl,Inspector:ll};export{qv as a,bl as b,wl as c,_o as d,Oo as e,qw as f,$w as g,of as h,Nl as i,om as j,sm as k,bk as l};
|