efficient-storefront-blocks 0.58.1 → 0.59.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 +11 -0
- package/dist/chunks/{EditorPreviewCheckout-4NGRJA3T.js → EditorPreviewCheckout-RH4YMFWR.js} +1 -1
- package/dist/chunks/{SiteEditorProvider-V5FE5UD6.js → SiteEditorProvider-CDMOH46L.js} +1 -1
- package/dist/chunks/{chunk-SJQTKWV3.js → chunk-76GXRMJK.js} +1 -1
- package/dist/chunks/chunk-U72V3KUB.js +261 -0
- package/dist/chunks/chunk-UZYSAKGR.js +1 -0
- package/dist/chunks/{fitment-data-OIWU6HGJ.js → fitment-data-NSCUVNS2.js} +1 -1
- package/dist/contract.js +7 -1
- package/dist/index.js +79 -87
- package/dist/render/built-with.json +1 -1
- package/dist/render/lib/content/site.d.ts +0 -2
- package/dist/render/lib/content/site.js +1 -1
- package/dist/words.d.ts +6 -5
- package/dist/words.js +3 -3
- package/package.json +4 -4
- package/dist/chunks/chunk-4AKN63X5.js +0 -1
- package/dist/chunks/chunk-PHH7L5FJ.js +0 -255
- package/dist/render/components/LiveSiteMapsProvider.d.ts +0 -6
- package/dist/render/components/LiveSiteMapsProvider.js +0 -1
- /package/dist/chunks/{chunk-K4AZ5SUU.js → chunk-2PHMIP2S.js} +0 -0
- /package/dist/chunks/{chunk-76HTJBKU.js → chunk-GHD5CTVU.js} +0 -0
- /package/dist/chunks/{chunk-PHH7L5FJ.js.LEGAL.txt → chunk-U72V3KUB.js.LEGAL.txt} +0 -0
|
@@ -0,0 +1,261 @@
|
|
|
1
|
+
import{$ as Ks,A as Yo,Aa as Uu,B as $t,C as qt,Ca as tn,Da as $u,E as Pu,Ea as qu,H as zr,J as Lu,Ja as ju,K as qs,L as Ou,N as Ru,O as Au,Q as Bu,R as js,T as _u,U as lo,V as mt,W as Du,X as bo,Y as on,_ as Nu,a as yu,c as Su,ca as Mu,d as co,da as Vs,e as Gt,f as Ao,fa as Ys,g as Gs,h as wu,ja as Hu,l as Wr,n as Us,pa as xt,ra as Wu,s as ku,t as Tu,ta as zu,u as $s,v as Je,va as Gu,w as Eu,x as Fu,y as Ut,z as go,za as V}from"./chunk-2PHMIP2S.js";import{d as Cu,e as Hr,f as vu,i as Ku,m as Xs}from"./chunk-GHD5CTVU.js";var rn=null,Yu="en",Xu=null;function r3(e,o,t){rn=e??null,Yu=o||"en",Xu=t??null}function Q(){return Xu}function Zs(){return Yu}function Zu(){return rn}function Vu(e,o){return o?e.replace(/\{([A-Za-z][A-Za-z0-9_]*)\}/g,(t,r)=>Object.prototype.hasOwnProperty.call(o,r)?String(o[r]):t):e}function l(e,o){let t=rn?rn[e]:void 0;if(typeof t=="function"){try{let r=t(o??{});if(typeof r=="string"&&r)return r}catch{}return Vu(e,o)}return Vu(typeof t=="string"&&t?t:e,o)}function so(e,o,t,r){return l(t===1?e:o,{...r,n:t})}function Be(e,o){if(typeof e=="string")return e||o;if(e&&typeof e=="object"&&"text"in e){let t=e.text;return typeof t=="string"&&t?t:o}return o}function Qu(e,o){return typeof e=="number"&&Number.isFinite(e)?e:o}function Ju(e,o){return typeof e=="boolean"?e:o}function an(e,o){if(!Array.isArray(e))return o;let t=e.map(r=>typeof r=="string"?r:Be(r?.text,"")).map(r=>r.trim()).filter(Boolean);return t.length?t:o}var ep="cart-drawer",s3="cart-drawer";var iw={kickerBadge:"",kickerText:"Your order",titleLead:"Your",titleAccent:"cart.",subtitleEmpty:"Empty for now.",subtitleOne:"One set in your cart.",subtitleMany:"{count} sets in your cart.",leadTimeValue:"",shipsToFallback:"",promises:[],emptyKicker:"No wheels yet",emptyBody:"Your cart is empty. Pick a wheel to get started."};function i3(e,o){return o===0?e.subtitleEmpty:o===1?e.subtitleOne:e.subtitleMany.replace("{count}",String(o))}function f3(e){let o=e??{},t=iw;return{kickerBadge:Be(o.kickerBadge,t.kickerBadge),kickerText:Be(o.kickerText,t.kickerText),titleLead:Be(o.titleLead,t.titleLead),titleAccent:Be(o.titleAccent,t.titleAccent),subtitleEmpty:Be(o.subtitleEmpty,t.subtitleEmpty),subtitleOne:Be(o.subtitleOne,t.subtitleOne),subtitleMany:Be(o.subtitleMany,t.subtitleMany),leadTimeValue:Be(o.leadTimeValue,t.leadTimeValue),shipsToFallback:Be(o.shipsToFallback,t.shipsToFallback),promises:an(o.promises,t.promises),emptyKicker:Be(o.emptyKicker,t.emptyKicker),emptyBody:Be(o.emptyBody,t.emptyBody)}}var tp="consent-banner",u3="consent-banner";var fw=[{value:"bar",label:"Bar"},{value:"card",label:"Card"}],p3="Layout",op={layout:"bar"},cw=e=>fw.some(o=>o.value===e);function m3(e){let o=Be((e??{}).layout,op.layout);return{layout:cw(o)?o:op.layout}}var dw=["meta","eyebrow","heading","body","statName","statValue","formEyebrow","formHeading","formIntro","fieldLabel","option","finePrint","dismiss","doneHeading","doneBody"],h3={meta:"Meta line",eyebrow:"Eyebrow",heading:"Heading",body:"Body",statName:"Stat name",statValue:"Stat value",formEyebrow:"Form eyebrow",formHeading:"Form heading",formIntro:"Form intro",fieldLabel:"Field label",option:"Option",finePrint:"Fine print",dismiss:"Dismiss link",doneHeading:"Success heading",doneBody:"Success message"},uw={meta:"styleMeta",eyebrow:"styleEyebrow",heading:"styleHeading",body:"styleBody",statName:"styleStatName",statValue:"styleStatValue",formEyebrow:"styleFormEyebrow",formHeading:"styleFormHeading",formIntro:"styleFormIntro",fieldLabel:"styleFieldLabel",option:"styleOption",finePrint:"styleFinePrint",dismiss:"styleDismiss",doneHeading:"styleDoneHeading",doneBody:"styleDoneBody"},g3={meta:{font:"--pp-meta-font",size:"--pp-meta-size"},eyebrow:{font:"--pp-eyebrow-font",size:"--pp-eyebrow-size"},heading:{font:"--pp-heading-font",size:"--pp-heading-size"},body:{font:"--pp-body-font",size:"--pp-body-size"},statName:{font:"--pp-statname-font",size:"--pp-statname-size"},statValue:{font:"--pp-statvalue-font",size:"--pp-statvalue-size"},formEyebrow:{font:"--pp-formeyebrow-font",size:"--pp-formeyebrow-size"},formHeading:{font:"--pp-formheading-font",size:"--pp-formheading-size"},formIntro:{font:"--pp-formintro-font",size:"--pp-formintro-size"},fieldLabel:{font:"--pp-fieldlabel-font",size:"--pp-fieldlabel-size"},option:{font:"--pp-option-font",size:"--pp-option-size"},finePrint:{font:"--pp-fineprint-font",size:"--pp-fineprint-size"},dismiss:{font:"--pp-dismiss-font",size:"--pp-dismiss-size"},doneHeading:{font:"--pp-doneheading-font",size:"--pp-doneheading-size"},doneBody:{font:"--pp-donebody-font",size:"--pp-donebody-size"}};function pw(e){return typeof e=="string"&&Ao.includes(e)?e:null}function rp(e){let o={};for(let t of dw){let r=pw(e[uw[t]]);r&&(o[t]=r)}return o}var jt="site-footer";var y3=jt,S3={desktop:!0,tablet:!0,mobile:!0},C3={desktop:!1,tablet:!1,mobile:!1},Qs=1,ap=6,v3=Array.from({length:ap-Qs+1},(e,o)=>Qs+o),nn={desktop:6,tablet:3,mobile:2},mw={2:{desktop:2,tablet:2,mobile:1},3:{desktop:3,tablet:3,mobile:1},4:{desktop:4,tablet:2,mobile:2},5:{desktop:5,tablet:3,mobile:2},6:{desktop:6,tablet:3,mobile:2}},It=e=>Math.min(Math.max(Math.round(e),Qs),ap);function w3(e){if(typeof e=="number")return mw[It(e)]??{desktop:It(e),tablet:It(e),mobile:It(e)};if(e&&typeof e=="object"){let o=e;return{desktop:It(o.desktop??nn.desktop),tablet:It(o.tablet??nn.tablet),mobile:It(o.mobile??nn.mobile)}}return{...nn}}var xw="subscribe-popup",O3="subscribe-popup";var Iw=[xw,jt,ep,tp];function sp(e){return Iw.includes(e)}var hw=["delay","scroll","exit"],gw=["all","chosen"],bw=["visit","days","never"],yw=["right","left"],Sw={min:0,max:60},Cw={min:10,max:90},vw={min:1,max:90},ei={metaLabel:"Meta label",issueLabel:"Label",issueNumber:"00",kicker:"Kicker",heading:`Main heading
|
|
2
|
+
*Highlight line*`,deck:"Add a sentence or two of supporting copy.",stats:[{label:"Label",value:"Value"},{label:"Label",value:"Value"},{label:"Label",value:"Value"},{label:"Label",value:"Value"}],formLabel:"Section label",formHeading:"Main heading *highlight*",formIntro:"Add a sentence or two of supporting copy.",firstNameLabel:"Field label",firstNamePlaceholder:"Placeholder",emailLabel:"Field label",emailPlaceholder:"Placeholder",interestsLabel:"Field label",interests:["Option one","Option two","Option three"],frequencyLabel:"Field label",frequencies:["Option one","Option two","Option three"],submitText:"Button label",finePrint:"Fine print",dismissText:"Dismiss link",emailInvalidText:"Enter a valid email address.",submitErrorText:"Could not subscribe right now. Please try again.",successHeading:"Main heading *highlight*",successBody:"Add a sentence or two of supporting copy \u2014 the {email} and {issue} tokens are substituted here.",keepBrowsingText:"Button label",autoOpen:!1,autoOpenDelaySec:15,formSlug:"",trigger:"delay",scrollPercent:50,showOn:"all",showOnPages:[],hideAfter:"days",hideDays:7,formSide:"right",valuePanelOnPhone:!1,sectionAccent:void 0,sectionCorners:void 0,sectionCornerSides:void 0,textStyles:{}},be=Be,ww=Qu,np=Ju,ip=an;function ln(e,o,t){return typeof o=="string"&&e.includes(o)?o:t}function Js(e,o,t){let r=ww(e,t);return Math.min(o.max,Math.max(o.min,Math.round(r)))}function kw(e){return typeof e.hideAfter=="string"?ln(bw,e.hideAfter,ei.hideAfter):e.oncePerSession===!0?"visit":e.oncePerSession===!1?"never":ei.hideAfter}function Tw(e){return Array.isArray(e)?e.map(o=>typeof o=="string"?o.trim():"").filter(Boolean).map(o=>o.startsWith("/")?o:`/${o}`):[]}function lp(e,o){if(e==null)return o;let t=r=>r.trim()?r:"";if(typeof e=="string")return t(e);if(typeof e=="object"&&"text"in e){let r=e.text;return typeof r=="string"?t(r):""}return o}function Ew(e,o){return Array.isArray(e)?ip(e,[]):o}function Fw(e,o){return Array.isArray(e)?e.map(t=>{let r=t??{};return{label:be(r.label,""),value:be(r.value,"")}}).filter(t=>t.label||t.value):o}function R3(e){let o=e??{},t=ei;return{metaLabel:be(o.metaLabel,t.metaLabel),issueLabel:lp(o.issueLabel,t.issueLabel),issueNumber:lp(o.issueNumber,t.issueNumber),kicker:be(o.kicker,t.kicker),heading:be(o.heading,t.heading),deck:be(o.deck,t.deck),stats:Fw(o.stats,t.stats),formLabel:be(o.formLabel,t.formLabel),formHeading:be(o.formHeading,t.formHeading),formIntro:be(o.formIntro,t.formIntro),firstNameLabel:be(o.firstNameLabel,t.firstNameLabel),firstNamePlaceholder:be(o.firstNamePlaceholder,t.firstNamePlaceholder),emailLabel:be(o.emailLabel,t.emailLabel),emailPlaceholder:be(o.emailPlaceholder,t.emailPlaceholder),interestsLabel:be(o.interestsLabel,t.interestsLabel),interests:ip(o.interests,t.interests),frequencyLabel:be(o.frequencyLabel,t.frequencyLabel),frequencies:Ew(o.frequencies,t.frequencies),submitText:be(o.submitText,t.submitText),finePrint:be(o.finePrint,t.finePrint),dismissText:be(o.dismissText,t.dismissText),emailInvalidText:be(o.emailInvalidText,t.emailInvalidText),submitErrorText:be(o.submitErrorText,t.submitErrorText),successHeading:be(o.successHeading,t.successHeading),successBody:be(o.successBody,t.successBody),keepBrowsingText:be(o.keepBrowsingText,t.keepBrowsingText),formSlug:typeof o.formSlug=="string"?o.formSlug.trim():t.formSlug,autoOpen:np(o.autoOpen,t.autoOpen),autoOpenDelaySec:Js(o.autoOpenDelaySec,Sw,t.autoOpenDelaySec),trigger:ln(hw,o.trigger,t.trigger),scrollPercent:Js(o.scrollPercent,Cw,t.scrollPercent),showOn:ln(gw,o.showOn,t.showOn),showOnPages:Tw(o.showOnPages),hideAfter:kw(o),hideDays:Js(o.hideDays,vw,t.hideDays),formSide:ln(yw,o.formSide,t.formSide),valuePanelOnPhone:np(o.valuePanelOnPhone,t.valuePanelOnPhone),sectionAccent:o.sectionAccent,sectionCorners:o.sectionCorners,sectionCornerSides:o.sectionCornerSides,textStyles:rp(o)}}import{jsx as oi,Fragment as Pw,jsxs as Lw}from"react/jsx-runtime";import{createContext as Ow,useContext as Rw}from"react";var Aw={mirrorHostStyles:!0,css:null,fontHrefs:[]},fp=Ow(Aw);function D3({value:e,children:o}){return oi(fp.Provider,{value:e,children:o})}function ti(){return Rw(fp)}function cp(){let{css:e,fontHrefs:o}=ti();return Lw(Pw,{children:[o.map(t=>oi("link",{rel:"stylesheet",href:t},t)),e?oi("style",{"data-sf-canvas-css":"",children:e}):null]})}import{jsx as Bw}from"react/jsx-runtime";import{createContext as _w,useContext as Dw}from"react";var dp=_w(void 0);function W3({metadata:e,children:o}){return Bw(dp.Provider,{value:e,children:o})}var up=()=>Dw(dp);import{jsx as ke,Fragment as Xv,jsxs as Qa}from"react/jsx-runtime";import{useCallback as Ja,useEffect as Ro,useRef as L5,useState as O5}from"react";import{Button as R5,Tooltip as A5}from"efficient-shell/ui";import{SettingsSwitch as B5}from"efficient-easel/panel";import{PagesIcon as _5,StylesIcon as D5}from"efficient-easel/rail";import{PaletteIcon as N5}from"efficient-shell/icons/efficient";import{TemplateIcon as M5}from"efficient-easel/icons";import{Subtree as H5,TreeRow as Zv}from"efficient-easel/tree";import{useEasel as W5}from"efficient-easel/easel";import{useEaselStrings as Qv}from"efficient-easel/strings";import{createContext as Nw,useContext as Mw}from"react";var ri=Nw(!1),U3=()=>Mw(ri);import{jsx as fe,Fragment as sg,jsxs as Al}from"react/jsx-runtime";import{Fragment as uR,useEffect as pR,useId as mR,useMemo as ig,useState as Rt}from"react";import{useScreenDocument as xR}from"efficient-easel/screen/components/ScreenDocumentContext";import{UiIcon as Bl}from"efficient-easel/draw/client";import IR from"efficient-easel/screen/components/SidePanelHead";import{jsx as te,jsxs as st,Fragment as Lt}from"react/jsx-runtime";import{useEasel as jh}from"efficient-easel/easel";import{useState as ic}from"react";import{jsx as ar,jsxs as PI,Fragment as tP}from"react/jsx-runtime";import{useState as LI}from"react";import{SettingsDefaultReset as rP,SettingsField as aP}from"efficient-easel/panel";import{useEaselStrings as nP}from"efficient-easel/strings";import{AddIcon as lP}from"efficient-easel/icons";import{jsx as h,jsxs as ot,Fragment as Wo}from"react/jsx-runtime";import{cloneElement as qx,useId as jE,useRef as If,useState as $n}from"react";import{useEasel as ta,useSelectedFields as hf}from"efficient-easel/easel";import{readHidable as rt,hidableText as KE}from"efficient-easel/draw";import{FOLD_FIELD_MARKER as gf,LINK_FIELD_MARKER as VE,MEDIA_FIELD_MARKER as YE,SCAFFOLD_FIELD_MARKER as XE,TEXT_FIELD_MARKER as Ho,foldMetaOf as zo,textFieldIdentifier as bU}from"efficient-easel/draw";import{jsx as bp}from"react/jsx-runtime";import{useCallback as Uw,useEffect as $w,useRef as qw,useState as jw}from"react";import{useEasel as Kw}from"efficient-easel/easel";import{SettingsAction as Vw}from"efficient-easel/panel";function ai(e){return typeof e=="number"&&Number.isFinite(e)}function j3(e,o){if(!ai(e))return;let t=on(bo(e));if(Object.keys(t).length===0)return;let r=t[sn];if(typeof r!="string")return t;let a=Gr(o)?Ur(r,Bo(o)??[]):r;return{...t,[Hw]:a}}var Hw="--sf-section-radius",sn="--sf-card-radius",ht=["tl","tr","br","bl"];function Bo(e){if(!Array.isArray(e))return null;let o=e.filter(t=>ht.includes(t));return ht.filter(t=>o.includes(t))}function Gr(e){let o=Bo(e);return o!==null&&o.length<ht.length}function Ur(e,o){return ht.map(t=>o.includes(t)?e:"0").join(" ")}var pp=[{value:"tl",label:"Top left"},{value:"tr",label:"Top right"},{value:"bl",label:"Bottom left"},{value:"br",label:"Bottom right"}];var Ww="--sf-card-box-radius",zw="--sf-site-card-radius",X3="sf-section-bleeds";function ni(e){return typeof e=="number"&&Number.isFinite(e)}function Z3(e,o){if(!ni(e))return;let t=on(bo(e))[sn];if(typeof t!="string")return;let r=Gr(o)?Ur(t,Bo(o)??[]):t;return{[Ww]:r}}function Q3(e){let o=e[sn];return typeof o=="string"?{[zw]:o}:{}}function mp(e,o){let t=e.find(n=>n?.props?.id===o);if(!t)return[...e];let r=t.props?.cardCorners,a=t.props?.cardCornerSides;return e.map(n=>n?.props?.id===o?n:{...n,props:{...n.props,cardCorners:r,cardCornerSides:a}})}import{locateNode as Gw}from"efficient-easel/draw";function $r(e){if(!e)return null;let o=e.lastIndexOf(":");return o>0?{ownerId:e.slice(0,o),slot:e.slice(o+1)}:null}function fn(e,o,t){let r=$r(t?.zone),a=r?Gw(e,o,r.ownerId):null;return a&&r?{...a,slot:r.slot}:null}function xp(e,o,t){let r=fn(e,o,t),a=r?.slot??"",n=r&&Array.isArray(r.item.props[a])?r.item.props[a]:[],s=t?.index??-1,i=s>=0?n[s]:void 0,f=i?.props?.id?String(i.props.id):"",u=Math.max(n.length-1,0);return!r||!f?{can:!1,reason:"unreachable",others:0}:n.length<=1?{can:!1,reason:"alone",others:u}:ni(i?.props?.cardCorners)?{can:!0,others:u,zone:r.zone,index:r.index,data:{...r.item,props:{...r.item.props,[a]:mp(n,f)}}}:{can:!1,reason:"unset",others:u}}function Ip(e){return e.can?so("Gives the other card this card's Corners.","Gives the other {n} cards this card's Corners.",e.others):e.reason==="alone"?l("This is the only card in the section."):e.reason==="unset"?l("Set this card's corners first."):l("This card is not in a section that can share corners.")}function hp(e){return so("Applied to {n} card","Applied to {n} cards",e)}function gp(e,o){e.can&&o(e.zone,e.index,e.data)}import{useSectionOps as Yw}from"efficient-easel/screen/lib/puck/use-section-ops";var Xw=2200,Zw="apply-corners-to-siblings",Qw="Apply to all cards";function Jw({plan:e,doneCount:o,onPress:t}){return bp(Vw,{id:Zw,label:l(Qw),note:Ip(e),disabled:!e.can,done:o!==null,doneLabel:hp(o??0),onPress:t})}function yp(){let{appState:e,config:o}=Kw(f=>f),t=Yw(),[r,a]=jw(null),n=qw(null);$w(()=>()=>{n.current&&clearTimeout(n.current)},[]);let s=xp(o,e.data.content??[],e.ui.itemSelector),i=Uw(()=>{gp(s,t.replaceComponent),s.can&&(a(s.others),n.current&&clearTimeout(n.current),n.current=setTimeout(()=>a(null),Xw))},[s,t]);return bp(Jw,{plan:s,doneCount:r,onPress:i})}var Sp=1;function ek(e){return bo(e)}function x4(e){let o=ek(e);return o===null?{}:{"--sf-card-image-radius":`${o}px`}}var Cp=1,vp="Corners";function ok(e){return bo(e)}function b4(e,o){let t=ok(e);if(t===null)return null;let r=`${t}px`;return{borderRadius:Gr(o)?Ur(r,Bo(o)??[]):r}}var _o={twoAcross:{label:"Two across",across:2,acrossPhone:2,desktop:[[6,1],[6,1]],phone:[[3,1],[3,1]]},zigzag:{label:"Zigzag",across:2,acrossPhone:2,desktop:[[8,1],[4,1],[4,1],[8,1]],phone:[[4,1],[2,1],[2,1],[4,1]]},brick:{label:"Brick",across:2,acrossPhone:2,desktop:[[5,1],[7,1],[7,1],[5,1]],phone:[[2,1],[4,1],[4,1],[2,1]]},twoTall:{label:"Two tall",across:2,acrossPhone:2,desktop:[[6,2],[6,2]],phone:[[3,2],[3,2]]},offsetTall:{label:"Offset tall",across:2,acrossPhone:2,desktop:[[5,2],[7,1],[3,1],[4,1]],phone:[[3,2],[3,1],[3,1]]},ladder:{label:"Ladder",across:2,acrossPhone:2,desktop:[[3,2],[9,1],[5,1],[4,1]],phone:[[2,2],[4,1],[2,1],[2,1]]},threeAcross:{label:"Three across",across:3,acrossPhone:3,desktop:[[4,1],[4,1],[4,1]],phone:[[2,1],[2,1],[2,1]]},bigLeft:{label:"Big left",across:3,acrossPhone:3,desktop:[[6,1],[3,1],[3,1]],phone:[[4,1],[1,1],[1,1]]},bigRight:{label:"Big right",across:3,acrossPhone:3,desktop:[[3,1],[3,1],[6,1]],phone:[[1,1],[1,1],[4,1]]},threeStagger:{label:"Three stagger",across:3,acrossPhone:3,desktop:[[5,1],[4,1],[3,1],[3,1],[4,1],[5,1]],phone:[[3,1],[2,1],[1,1],[1,1],[2,1],[3,1]]},threeLadder:{label:"Three ladder",across:3,acrossPhone:3,desktop:[[3,1],[4,1],[5,1],[5,1],[4,1],[3,1]],phone:[[1,1],[2,1],[3,1],[3,1],[2,1],[1,1]]},tallMiddle:{label:"Tall middle",across:3,acrossPhone:3,desktop:[[4,1],[4,2],[4,1],[4,1],[4,1]],phone:[[2,1],[2,2],[2,1],[2,1],[2,1]]},fourAcross:{label:"Four across",across:4,acrossPhone:2,desktop:[[3,1],[3,1],[3,1],[3,1]],phone:[[3,1],[3,1]]},bigFirst:{label:"Big first",across:4,acrossPhone:2,desktop:[[6,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1]],phone:[[6,1],[3,1],[3,1]]},fourStagger:{label:"Four stagger",across:4,acrossPhone:2,desktop:[[4,1],[3,1],[2,1],[3,1],[2,1],[3,1],[4,1],[3,1]],phone:[[4,1],[2,1],[2,1],[4,1]]},tallFirst:{label:"Tall first",across:4,acrossPhone:2,desktop:[[3,2],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1]],phone:[[3,2],[3,1],[3,1]]},oneThenFour:{label:"One then four",across:4,acrossPhone:2,desktop:[[12,1],[3,1],[3,1],[3,1],[3,1]],phone:[[6,1],[3,1],[3,1]]},sixAcross:{label:"Six across",across:6,acrossPhone:3,desktop:[[2,1],[2,1],[2,1],[2,1],[2,1],[2,1]],phone:[[2,1],[2,1],[2,1]]},sixStagger:{label:"Six stagger",across:6,acrossPhone:6,desktop:[[3,1],[2,1],[1,1],[2,1],[1,1],[3,1],[1,1],[3,1],[2,1],[2,1],[1,1],[3,1]],phone:[[1,1],[1,1],[1,1],[1,1],[1,1],[1,1]]}},li=Object.keys(_o),kp=[2,3,4,6];function Tp(e){return typeof e!="string"||e===""?null:_o[e]??null}function wp(e,o){return o?6/e.acrossPhone:12/e.across}var tk="sf-wall--";function rk(e){return`${tk}${e}`}function S4(e){let o=_o[e],t=`.${rk(e)}`,r=[],a=(n,s)=>{let i=[],f=n.length;n.forEach(([u,p],m)=>{i.push(`${t} > :nth-child(${f}n+${m+1}){grid-column:span ${u};grid-row:span ${p}}`)});for(let u=1;u<f;u+=1)i.push(`${t}:has(> :nth-child(${f}n+${u}):last-child) > :nth-last-child(-n+${u}){grid-column:span ${s};grid-row:span 1}`);return i};return r.push(`${t}{grid-template-columns:repeat(12,minmax(0,1fr))}`),r.push(...a(o.desktop,wp(o,!1))),r.push("@media (max-width:800px){"),r.push(`${t}{grid-template-columns:repeat(6,minmax(0,1fr))}`),r.push(...a(o.phone,wp(o,!0))),r.push("}"),r.join("")}var cn=12,Ep=1,ak=3;var nk=3;function si(e,o,t){let r=typeof e=="number"?e:Number.parseInt(String(e??""),10);return Number.isFinite(r)?Math.min(t,Math.max(o,Math.trunc(r))):null}function lk(e){return si(e,1,cn)??nk}function w4(e,o){return si(e,Ep,ak)??(lk(o)===4?2:Ep)}function k4(e){return e==null||e===""?null:si(e,1,cn)}var T4="data-sf-span";function E4(e){if(!e)return!1;if(e.type==="Grid")return!0;if(e.type==="GalleryB"){if(Tp(e.props?.layout))return!1;let o=e.props?.columns;return o!=null&&o!==""}return!1}var yo=["top-left","top-center","top-right","left","center","right","bottom-left","bottom-center","bottom-right"],dn="bottom-left";var un={"top-left":"Top left","top-center":"Top center","top-right":"Top right",left:"Left",center:"Center",right:"Right","bottom-left":"Bottom left","bottom-center":"Bottom center","bottom-right":"Bottom right"};function sk(e){let o=yo.indexOf(gt(e));return{band:Math.floor(o/3),column:["start","center","end"][o%3]}}function ik(e){return 1+sk(e).band*6}function P4(e){return ik(e)+1}function gt(e){return yo.includes(e)?e:dn}function L4(e){let o=typeof e=="number"&&Number.isFinite(e)?e:0;return Math.max(-40,Math.min(40,Math.round(o)))}function O4(e,o=60){let t=typeof e=="number"&&Number.isFinite(e)?e:o;return Math.max(30,Math.min(100,Math.round(t)))}function ii(e,o){let t=gt(o);return e.filter(r=>gt(r?.props?.placement)===t).length}function Fp(e){return`${un[gt(e)]} already holds 4 boxes. Move one somewhere else first.`}function fi(e,o){let t=e.filter(r=>r?.props?.id!==o);return yo.map(r=>{let a=ii(t,r)>=4,n=un[r];return a?{value:r,label:n,disabled:!0,title:Fp(r)}:{value:r,label:n}})}function pn(e,o){let t=o===void 0?dn:gt(o?.props?.placement);return ii(e,t)>=4?Fp(t):null}var mn="HeroGroup";function fk(e){return yo.map(o=>{let t=ii(e,o);return{anchor:o,total:t,hidden:t-4}}).filter(o=>o.hidden>0)}function ci(e){let o=fk(e);return o.length===0?null:o.map(({anchor:t,total:r,hidden:a})=>{let n=un[t],s=a===1?"1 is not shown":`${a} are not shown`;return`${n} holds ${r} boxes. The published page draws the first 4, so ${s}. ${a===1?"Move it":"Move them"} somewhere else.`}).join(" ")}function Pp(e,o){let t=o;if(t?.type!==mn)return null;let r=t.props?.id===void 0?"":String(t.props.id);return r?pn(di(e,r),t):null}function di(e,o){let t=Op(e,o);return t&&t.ownerType===dk?t.siblings:[]}function Lp(e,o){let t=Op(e,o);return t?t.ancestorTypes.filter(r=>r===mn).length:ck}var ck=1,dk="HeroSlide";function Op(e,o){let t=a=>Array.isArray(a)&&a.length>0&&a.every(n=>!!n&&typeof n=="object"&&typeof n.type=="string"),r=(a,n,s)=>{if(n>12||!a||typeof a!="object")return null;if(t(a)){if(a.some(i=>i?.props?.id===o))return{siblings:a,ownerType:s.at(-1)??null,ancestorTypes:s};for(let i of a){let f=i.type,u=r(i,n+1,[...s,String(f)]);if(u)return u}return null}for(let i of Object.values(a)){let f=r(i,n+1,s);if(f)return f}return null};return r(e,0,[])}import{jsx as uk}from"react/jsx-runtime";var pk="sf-hint-keep";function Rp({children:e}){return uk("span",{className:pk,children:e})}import{AdjustIcon as ZE,AlignLeftIcon as QE,EyeIcon as JE,AlignSeparateIcon as eF,AnimationIcon as jx,BackgroundIcon as oF,BorderAllIcon as tF,BlockSectionIcon as rF,CartIcon as aF,ColumnWidthsIcon as Kx,ColumnsIcon as nF,CornerIcon as lF,DirectionDownIcon as sF,DirectionLeftIcon as iF,DirectionRightIcon as fF,DirectionUpIcon as cF,DollarIcon as dF,FinishIcon as uF,GapIcon as Vx,GridIcon as pF,GroundIcon as mF,HashIcon as Yx,HeightIcon as xF,ImageIcon as IF,ListIcon as hF,LocationIcon as xf,NudgeIcon as gF,PaddingAllIcon as bF,PaddingBottomIcon as Xx,PaddingLeftIcon as Zx,PaddingRightIcon as Qx,PaddingTopIcon as Jx,PageIcon as eI,PhoneIcon as yF,PlacementIcon as SF,ProductSizeIcon as CF,StickyIcon as vF,RotateIcon as wF,SquareIcon as kF,TypeIcon as TF,WidthIcon as EF,WrapIcon as FF}from"efficient-easel/icons";import{jsx as ne,Fragment as So,jsxs as Co}from"react/jsx-runtime";import{TitleIcon as mk,ButtonIcon as xk,DollarIcon as Ik,HashIcon as hk,LinkIcon as gk,NoteIcon as bk,TagIcon as yk,TextLinesIcon as Sk}from"efficient-easel/icons";var Ap={body:Sk,button:xk,link:gk,label:yk,number:hk,price:Ik,note:bk,title:mk},Bp={eyebrow:Co(So,{children:[ne("path",{d:"M5 6.5h5"}),ne("path",{d:"M5 12.5h14"}),ne("path",{d:"M5 18h11"})]}),heading:Co(So,{children:[ne("path",{d:"M6.5 5v14"}),ne("path",{d:"M17.5 5v14"}),ne("path",{d:"M6.5 12h11"})]}),intro:Co(So,{children:[ne("path",{d:"M4 5.5v13"}),ne("path",{d:"M8 7.5h12"}),ne("path",{d:"M8 12h12"}),ne("path",{d:"M8 16.5h8"})]}),value:Co(So,{children:[ne("rect",{x:"2.5",y:"7",width:"19",height:"10",rx:"2"}),ne("path",{d:"M6.5 12h7"})]}),name:Co(So,{children:[ne("path",{d:"M6 3.5v17"}),ne("path",{d:"M6 5h11.5l-2.6 3.6L17.5 12H6z"})]}),date:Co(So,{children:[ne("rect",{x:"4",y:"5.5",width:"16",height:"15",rx:"2"}),ne("path",{d:"M4 10.5h16"}),ne("path",{d:"M9 3.2v4.4"}),ne("path",{d:"M15 3.2v4.4"})]}),caption:Co(So,{children:[ne("rect",{x:"3.5",y:"4.5",width:"17",height:"11",rx:"2"}),ne("path",{d:"M3.5 12.8l4.2-3.2 3.6 2.8 3.4-2.4 5.8 4"}),ne("path",{d:"M6.5 19.5h11"})]}),quote:Co(So,{children:[ne("path",{d:"M9.5 5.5C7 7.2 5.5 9.7 5.5 12.8h4v5.7h-5v-5.7"}),ne("path",{d:"M19.5 5.5c-2.5 1.7-4 4.2-4 7.3h4v5.7h-5v-5.7"})]}),tag:Co(So,{children:[ne("rect",{x:"3",y:"5.5",width:"18",height:"13",rx:"2.5"}),ne("path",{d:"M8 9.5h8"}),ne("path",{d:"M12 9.5v5"})]}),meta:Co(So,{children:[ne("path",{d:"M4 7h16"}),ne("path",{d:"M4 14h3.5"}),ne("path",{d:"M10.5 14h3"}),ne("path",{d:"M17 14h3"})]})};function ui({noun:e,size:o=14,strokeWidth:t=1.8,className:r,style:a}){let n=Ap[e];return n?ne("span",{className:r,style:{display:"inline-flex",...a},"aria-hidden":"true",children:ne(n,{size:o})}):ne("svg",{className:r,style:a,width:o,height:o,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:t,strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:Bp[e]})}var N4=Object.keys(Ap);var M4=Object.keys(Bp);var Ck="#ffffff",vk=/^#[0-9a-fA-F]{6}$/;function pi(e){return wk(e)?e:Ck}function wk(e){return typeof e=="string"&&vk.test(e)}function W4(e){return{"--bg":pi(e)}}var mi=[{role:"bg",token:"--bg",ink:!1},{role:"fg",token:"--fg",ink:!0},{role:"surface",token:"--site-surface",ink:!1},{role:"surface-2",token:"--site-surface-2",ink:!1},{role:"line",token:"--site-line",ink:!0},{role:"muted",token:"--fg-dim",ink:!0}],kk=mi.filter(e=>e.ink);function Tk(e){let o={color:e.fg};for(let{role:t,token:r}of kk)o[r]=e[t];return o}var Ek={fg:"var(--overlay-fg)",line:"color-mix(in srgb, var(--overlay-fg) 24%, transparent)",muted:"color-mix(in srgb, var(--overlay-fg) 76%, transparent)"},_p=Object.freeze(Tk(Ek));var xn=-1,Fk="sf-section-accent",Dp="Color",Np=new Set(["CategoryBar","DocTabs"]),$4=new Set(["Flex"]),Pk=0;function xi(e){return e===xn?null:typeof e=="number"&&Number.isInteger(e)&&e>=0?e:Pk}function q4(e){return e??xn}function Lk(e){let o=`--theme-preset-${e}`,t={"--sf-sec-accent":`var(${o}-accent)`,"--sf-sec-accent-2":`var(${o}-accent-2)`,"--sf-sec-accent-ink":`var(${o}-accent-ink)`};for(let{role:r}of mi)t[`--sf-sec-${r}`]=`var(${o}-${r}, var(--theme-${r}))`;return t}function j4(e){let o=xi(e.sectionAccent);return o===null?null:{className:Fk,style:Lk(o)}}var Ok=["fade","rise","scale"],Ii="none",Mp=[{label:"None",value:Ii},{label:"Fade",value:"fade"},{label:"Rise",value:"rise"},{label:"Scale",value:"scale"}];function Y4(e){return Ok.includes(e)?e:null}var Hp="data-sf-anim",qr="data-sf-anim-state";function X4(e){let o=()=>{};if(typeof IntersectionObserver>"u"||!e.getAttribute(Hp))return o;let t=window.innerHeight||document.documentElement.clientHeight;if(e.getBoundingClientRect().top<t)return o;e.setAttribute(qr,"armed");let r=new IntersectionObserver(a=>{for(let n of a)if(n.isIntersecting){r.disconnect(),Rk(e);break}},{threshold:0});return r.observe(e),()=>{r.disconnect(),e.removeAttribute(qr)}}function Rk(e){if(!e.getAttribute(Hp))return;e.removeAttribute(qr),e.offsetWidth,e.setAttribute(qr,"play");let o=t=>{t.target===e&&(e.removeAttribute(qr),e.removeEventListener("animationend",o))};e.addEventListener("animationend",o)}var Z4=Np;function gi(e,o){let t=e?.content;if(!Array.isArray(t))return null;for(let r of t){if(!r||typeof r!="object")continue;let a=r.props;if(a?.id===o)return null;if(hi(r,o,0))return a??{}}return null}function hi(e,o,t){if(t>12||!e||typeof e!="object")return!1;if(Array.isArray(e))return e.some(a=>hi(a,o,t+1));let r=e.props;return r&&typeof r=="object"&&r.id===o?!0:Object.values(e).some(a=>hi(a,o,t+1))}import{SettingsDefaultReset as Ge,SettingsField as ie,SettingsGroupHead as PF,SettingsGroupSub as LF,SettingsBorder as OF,SettingsSegmented as RF,SettingsSides as AF,SettingsSidesEach as oI,sidesStartEach as BF,SettingsSwitch as tI,borderSides as _F,borderStartEach as DF}from"efficient-easel/panel";import{FieldSelect as NF,ListField as MF}from"efficient-easel/fields";import{DisplayChips as HF}from"efficient-shell/ui";function Kt(e){if(!e||typeof e!="object"||Array.isArray(e))return{};let o={};for(let[t,r]of Object.entries(e))typeof r=="boolean"&&(o[t]=r);return o}function In(e,o){return Kt(e)[o]!==!1}function bi(e,o,t){let r=Kt(o)[t];return typeof r=="boolean"?r:In(e,t)}function Wp(e){return Object.values(Kt(e)).some(o=>o===!1)}function zp(e){return Object.keys(Kt(e)).length>0}function Gp(e,o,t){let r={...Kt(e)};return t?delete r[o]:r[o]=!1,Object.keys(r).length?r:void 0}function Up(e,o,t){return{...Kt(e),[o]:t}}function e6(e,o,t){let r=In(e,t),a=bi(e,o,t);return r&&a?"":!r&&!a?"hidden":r?"max-[720px]:hidden":"min-[720px]:hidden"}import{AlignmentGrid as WF,Checkbox as MU,CornersInput as zF,DateTimePicker as GF,FOCAL_DEFAULT as HU,PictureTiles as rI,PositionInput as UF,Slider as $F,Tooltip as aI}from"efficient-shell/ui";import{jsx as bt,jsxs as Bk}from"react/jsx-runtime";import{ColorPicker as _k,HexInput as Dk}from"efficient-shell/ui";import{SettingsDefaultReset as Nk,SettingsField as Mk}from"efficient-easel/panel";import{typedHex as yi}from"efficient-easel/pick";import{typedHex as Ak}from"efficient-easel/pick";function $p(e){let o=new Set,t=[];return Je(e).themes.forEach((r,a)=>{let n=[[l("Theme {n} main color",{n:a+1}),r.accent],[l("Theme {n} text color",{n:a+1}),r.text],[l("Theme {n} background",{n:a+1}),r.background]];for(let[s,i]of n){let f=i?Ak(i):null;!f||o.has(f)||(o.add(f),t.push({name:s,value:f}))}}),t}function io({value:e,onChange:o,label:t,id:r,caption:a,inherited:n,after:s,ariaLabel:i}){return bt(Wk,{value:e,onChange:o,label:l(i??t),id:r,caption:a,inherited:n,after:s})}function Hk(){let{theme:e}=V();return $p(e).map(o=>({value:o.value,label:o.name}))}function Wk({value:e,onChange:o,label:t,id:r,caption:a,inherited:n,after:s}){let i=Hk(),f=e?null:yi(n??""),u=a!==void 0&&(!e||yi(a)!==yi(e))?a:null,p=m=>{m!==e&&o(m)};return Bk("div",{className:"sf-colour",children:[bt(_k,{id:r,value:e,onChange:p,label:t,presets:i,fallback:f??void 0,size:"sm",align:"end"}),u!==null?bt("span",{className:"sf-colour-caption",children:u}):bt("span",{className:"sf-colour-hexwrap",children:bt(Dk,{value:e||f||"",onChange:p,label:l("{label} hex code",{label:t}),placeholder:e||f?void 0:l("Not set"),className:f?"sf-colour-hex is-inherited":"sf-colour-hex",size:"sm"})}),s]})}function hn({label:e,icon:o,value:t,inherited:r,resetTo:a,onChange:n,onReset:s,hint:i}){let f=!!t;return bt(Mk,{label:e,icon:o,changed:f,action:io({value:t,inherited:f?void 0:r,onChange:n,label:e,after:bt(Nk,{words:Q()?.panel,label:e,changed:f,detail:a,onReset:s})}),hint:i})}import{jsx as jr}from"react/jsx-runtime";import{useEffect as iT,useState as fT}from"react";import{markSelection as cT,useCaretEdit as dT}from"efficient-easel/copy";import{RevertIcon as uT}from"efficient-easel/icons";import{IconButton as pT,TextToolbar as mT,Tooltip as xT}from"efficient-shell/ui";import{applyMark as b6,markupTools as y6,MARKUP_TOOLS as S6,COPY_FIELD_TOOLS as C6,STOREFRONT_MARKUP as v6,tokenizeInline as w6,stripInline as k6,isSafeLinkHref as T6}from"efficient-shell/markup";import{applyMark as Qk,markedAt as Jk,markupTools as eT,MARKUP_TOOLS as oT,parseMarkup as tT,RETIRED_MARKS as rT,STOREFRONT_MARKUP as aT,tokenizeInline as F6}from"efficient-shell/markup";var yt=["highlight","strong","quiet"],St={highlight:"Highlight",strong:"Bold",quiet:"Quiet"},vo={highlight:{kind:"wordHighlight",delimiter:"@@"},strong:{kind:"wordStrong",delimiter:"++"},quiet:{kind:"wordQuiet",delimiter:"^^"}},Vp=Object.fromEntries(yt.map(e=>[vo[e].kind,e])),Yp="data-sf-ws",gn=["accent","text","labels"],Xp={accent:"Accent",text:"Text",labels:"Labels"},Do={accent:"var(--accent)",text:"var(--fg)",labels:"var(--fg-dim)"},zk=80,Gk=120,Uk=100,$k=900,qk=.5,jk=3,Kk=-.1,Vk=.5,Yk=3,Si={font:null,size:null,weight:null,bold:null,italic:null,lineGap:null,textGap:null,colour:null},Xk={highlight:{...Si},strong:{...Si},quiet:{...Si}};function qp(e,o,t){return typeof e!="number"||!Number.isFinite(e)?null:Math.round(Math.min(Math.max(e,o),t))}function jp(e,o,t){if(typeof e!="number"||!Number.isFinite(e))return null;let r=10**Yk;return Math.round(Math.min(Math.max(e,o),t)*r)/r}function Kp(e){return typeof e=="boolean"?e:null}function Zk(e){let o=typeof e?.font=="string"&&co.some(r=>r.key===e.font)?e.font:null,t=typeof e?.colour=="string"&&gn.includes(e.colour)?e.colour:null;return{font:o,size:qp(e?.size,zk,Gk),weight:qp(e?.weight,Uk,$k),bold:Kp(e?.bold),italic:Kp(e?.italic),lineGap:jp(e?.lineGap,qk,jk),textGap:jp(e?.textGap,Kk,Vk),colour:t}}function Zp(e){let o={};for(let t of yt)o[t]=e&&t in e&&e[t]?Zk(e[t]):{...Xk[t]};return o}function x6(e){let o=Zp(e),t={};for(let r of yt){let a=o[r],n=`--sf-ws-${r}`;if(a.font){let s=co.find(i=>i.key===a.font);s&&(t[`${n}-font`]=`var(${s.cssVar})`)}a.size!==null&&(t[`${n}-size`]=`${a.size/100}em`),a.weight!==null&&(t[`${n}-weight`]=String(a.weight)),a.bold!==null&&(t[`${n}-weight-bold`]=a.bold?"700":"400"),a.italic!==null&&(t[`${n}-style`]=a.italic?"italic":"normal"),a.lineGap!==null&&(t[`${n}-line`]=String(a.lineGap)),a.textGap!==null&&(t[`${n}-track`]=`${a.textGap}em`),a.colour!==null&&(t[`${n}-color`]=Do[a.colour])}return t}function I6(e){let o=e?.word_styles??void 0,t={};for(let r of yt)o&&r in o&&(t[r]=o[r]??null);return Zp(t)}var nT=new Set(["strong"]),Qp=yt.map(e=>({open:vo[e].delimiter,close:vo[e].delimiter,kind:vo[e].kind,...nT.has(e)?{wordStart:!0}:{}})),L6=[{style:vo.highlight.kind,label:St.highlight,title:`${St.highlight} word style`},{style:vo.strong.kind,label:St.strong,title:`${St.strong} word style`},{style:vo.quiet.kind,label:St.quiet,title:`${St.quiet} word style`}],lT=new Set(Qp.map(e=>e.open)),Vt=[...aT.filter(e=>!lT.has(e.open)),...Qp];function Ci(e){return e.bullet?"- ":e.number!=null?`${e.number}. `:""}function vi(e){return tT(typeof e=="string"?e:"",Vt)}var sT=oT.map(e=>e.style).filter(e=>!rT.includes(e)).filter(e=>Vt.some(o=>o.kind===e));function Jp(){return eT(sT)}var em=Object.fromEntries(yt.map(e=>[vo[e].kind,vo[e].delimiter]));function om(e,o,t,r){let a=em[r];if(!a)return Qk(e,o,t,r);let n=e.slice(o,t),s=e.slice(Math.max(0,o-a.length),o),i=e.slice(t,t+a.length);if(s===a&&i===a)return{text:e.slice(0,o-a.length)+n+e.slice(t+a.length),selectionStart:o-a.length,selectionEnd:o-a.length+n.length};let f=n||"styled text";return{text:e.slice(0,o)+a+f+a+e.slice(t),selectionStart:o+a.length,selectionEnd:o+a.length+f.length}}function tm(e,o,t,r){let a=em[r];return a?o>=a.length&&e.slice(o-a.length,o)===a&&e.slice(t,t+a.length)===a:Jk(e,o,t,r)}function Ct(e){return vi(e).map(o=>Ci(o)+rm(o.children)).join(`
|
|
3
|
+
`)}function rm(e){return e.map(o=>o.kind==="text"?o.text:rm(o.children)).join("")}var am="Clear formatting";function IT(e,o,t){return cT(e,o,t,om)}function hT(e){let[o,t]=fT(null);return iT(()=>{let r=e.current?.ownerDocument??(typeof document>"u"?null:document);if(!r)return;let a=()=>{let n=e.current;if(!n||r.activeElement!==n)return;let s=n.selectionStart??n.value.length,i=n.selectionEnd??s;t(f=>f&&f.start===s&&f.end===i?f:{start:s,end:i})};return r.addEventListener("selectionchange",a),()=>r.removeEventListener("selectionchange",a)},[e]),[o,t]}function gT({target:e,value:o,onChange:t,disabled:r=!1,label:a="Formatting"}){let n=dT({target:e,onChange:t}),[s,i]=hT(e),f=x=>n(I=>{let b=IT(o,x,I);return i({start:b.selectionStart,end:b.selectionEnd}),b}),u=Jp(),p={};if(s)for(let x of u)p[x.style]=tm(o,s.start,s.end,x.style);let m=Ct(o);return jr(mT,{offered:new Set(u.map(x=>x.style)),onMark:x=>f(x),pressed:p,disabled:r,"aria-label":l(a),className:"sf-markup-bar",last:jr("span",{className:"sf-markup-clear",children:jr(xT,{content:l(am),children:jr(pT,{size:"sm",onMouseDown:x=>x.preventDefault(),onClick:()=>t(m),disabled:r||m===o,"aria-label":l(am),children:jr(uT,{size:14})})})})})}var wi=gT;import{deviceField as _e}from"efficient-easel/screen/lib/puck/device-fields";import{NO_CONTROL_FIELD as qF,NoControlMark as qn,noControlField as ra}from"efficient-easel/screen/lib/puck/panel-no-control-mark";var ki="__ownBox";function nm(e){return!!e&&typeof e=="object"&&e[ki]===!0}function No(e){return`${e}Phone`}function bn(e,o,t){return typeof e=="number"?e:typeof o=="number"?o:t}var yn=void 0;import{jsx as Ei,Fragment as ST}from"react/jsx-runtime";import{createContext as CT,useContext as vT}from"react";var Sn={ProductGrid:{source:{keep:["slug"]}},GalleryItem:{product:{keep:["code","finish"]}},FeaturedCover:{source:{keep:["slug"]}},LongRead:{source:{keep:["slug"]}}},Cn={Events:["posts"],SubscribeBlogs:["posts"]};var bT=["anchor"],yT=/^href$|Href$|^url$|Url$|^link$|^mailto$|^tel$/;function Kr(e){return bT.includes(e)||yT.test(e)}var Ti={Gallery:{source:{verb:"snapshot",keep:[]}},ProductHero:{source:{verb:"snapshot",keep:[]}},SpecTable:{source:{verb:"snapshot",keep:[]},wheel:{verb:"reference"},finish:{verb:"reference"},size:{verb:"reference"}},CollectionCard:{collection:{verb:"snapshot",keep:[]}},FooterMenu:{menu:{verb:"snapshot",keep:[]}},MenuBlock:{menu:{verb:"snapshot",keep:[]}},ProductGrid:{design_codes:{verb:"reference"}},ProductRef:{code:{verb:"reference"},finish:{verb:"reference"}},FitmentTable:{wheel:{verb:"reference"}},GalleryItem:{fromProduct:{verb:"reference"}},Footprint:{"offices[].group":{verb:"groupKey"},"offices[].lat":{verb:"pii"},"offices[].lng":{verb:"pii"},"offices[].geocode":{verb:"pii"}}};Ti.ContactLocations={"locations[].lat":{verb:"pii"},"locations[].lng":{verb:"pii"},"locations[].mapsUrl":{verb:"pii"},"locations[].geocode":{verb:"pii"}};var $6=Object.fromEntries(Object.entries(Sn).map(([e,o])=>[e,Object.keys(o)])),q6=Object.fromEntries(Object.entries(Cn).map(([e,o])=>[e,[...o]]));import{NoControlMark as wT}from"efficient-easel/screen/lib/puck/panel-no-control-mark";var lm=CT(!1);function sm({children:e}){return Ei(lm.Provider,{value:!0,children:e})}function kT(){return vT(lm)}function im({name:e,children:o}){return!kT()||!e||Kr(e)?Ei(ST,{children:o}):Ei(wT,{})}function eo(e,o,t){return e.some(r=>(typeof r=="object"?r.value:r)===t)?t:o}var Fi="off",Pi="none",Li=[{label:"None",value:"off"},{label:"1, 2, 3",value:"plain"},{label:"01, 02, 03",value:"padded"},{label:"N\xB001, N\xB002",value:"numero"}],Oi=[{label:"None",value:"none"},{label:"Hairline",value:"hairline"}];function eW(e){return eo(Li,Fi,e)}function oW(e){return eo(Oi,Pi,e)}var fm="sf-card-index",Vr="sf-card-index",tW="pointer-events-none absolute left-[18px] top-[18px] z-10 border border-line bg-bg/70 px-2 py-1 font-mono text-[length:var(--size-label,10px)] uppercase tracking-[0.16em] text-fg-dim",TT={plain:`counter(${Vr})`,padded:`counter(${Vr}, decimal-leading-zero)`,numero:`"N\xB0" counter(${Vr}, decimal-leading-zero)`};function rW(e,o){return o==="off"?"":`.${e}{counter-reset:${Vr}}.${e} .${fm}{counter-increment:${Vr}}.${e} .${fm}::before{content:${TT[o]}}`}function aW(e){return e==="hairline"?"border border-line hover:border-accent":""}var cm=[{value:"1",label:"1st rendering"},{value:"2",label:"2nd rendering"},{value:"3",label:"3rd rendering"},{value:"4",label:"4th rendering"},{value:"5",label:"5th rendering"}];import{SCALAR_TEXT_CONTROLS as jF}from"efficient-easel/draw";import{jsx as wo}from"react/jsx-runtime";import{SettingsDefaultReset as PT,SettingsField as um}from"efficient-easel/panel";import{useSelectedFields as LT}from"efficient-easel/easel";import{FOCAL_DEFAULT as OT}from"efficient-shell/format";import{ImageIcon as pm,PlayIcon as mm}from"efficient-easel/icons";import{MediaUploadField as RT}from"efficient-shell/ui";import{useContext as AT}from"react";import{ScreenDocumentContext as BT}from"efficient-easel/screen/components/ScreenDocumentContext";import{usePreviewDevice as _T}from"efficient-easel/draw/client";import{requestMediaPick as DT}from"efficient-easel/screen/lib/media-picker";import{useEaselHost as NT}from"efficient-easel/screen/lib/host";function ET(e){return!!e&&typeof e=="object"&&!Array.isArray(e)&&typeof e.src=="string"}function dm(e){return typeof e=="string"?e:ET(e)?e.src:""}function sW(e,o,t){return Ri(e,o.split("."),t)}function Ri(e,o,t){if(o.length===0)return t(e);let[r,...a]=o,n=r.endsWith("[]"),s=n?r.slice(0,-2):r;if(!e||typeof e!="object"||Array.isArray(e))return e;let i=e;if(!(s in i))return e;let f=i[s];if(n){if(!Array.isArray(f))return e;let p=!1,m=f.map(x=>{let I=Ri(x,a,t);return I!==x&&(p=!0),I});return p?{...i,[s]:m}:e}let u=Ri(f,a,t);return u===f?e:{...i,[s]:u}}import{backendOf as FT}from"efficient-easel/screen/lib/session";var We=FT,vn=e=>e.blocks;import{useEaselSession as MT}from"efficient-easel/screen/lib/session-context";function HT(e,o){let t=null;try{t=LT()}catch{t=null}let r=_T()==="mobile";if(!e||!t||o&&!o(t.values??{}))return null;let a=typeof t.values?.[e]=="string"&&t.values[e]?String(t.values[e]):OT,n=No(e),s=typeof t.values?.[n]=="string"&&t.values[n]?String(t.values[n]):void 0,i=t.onChange;return{phone:r,desktop:a,own:s,focus:r?s??a:a,set:f=>i(r?n:e,f),clear:()=>i(n,yn)}}function xm({value:e,onChange:o,label:t,accept:r,placeholder:a,focusKey:n,focusWhen:s}){let i=NT(),f=MT(),u=l(t),p=r.startsWith("video"),m=HT(p?void 0:n,s),x=AT(BT),I=w=>DT(i,{accept:r,title:u,...w?{file:w}:{}}).then(k=>k?.url??null);if(x&&!x.capabilities.mediaEditing)return wo(um,{label:u,icon:p?wo(mm,{}):wo(pm,{}),children:wo("div",{className:"sf-image-slot-inert",children:p?l("Templates don\u2019t store videos \u2014 this slot stays a placeholder. Each website picks its own after it\u2019s created."):l("Templates don\u2019t store images \u2014 this slot stays a placeholder. Each website picks its own after it\u2019s created.")})});let b=dm(e),C=m?.phone&&b?wo(PT,{words:Q()?.panel,label:l("Image focus"),changed:!!m.own,detail:l("{value} on desktop",{value:m.desktop}),onReset:m.clear}):void 0;return wo(um,{label:u,icon:p?wo(mm,{}):wo(pm,{}),action:C,children:wo("div",{style:{flex:"1 1 auto",minWidth:0},children:wo(RT,{value:b,onChange:o,onPick:I,accept:p?"video/*":"image/*",kind:p?"video":"image",placeholder:a===void 0?void 0:l(a),maxSizeBytes:We(f).media.maxUploadBytes,...m?{focus:m.focus,onFocusChange:m.set}:{}})})})}import{jsx as Im}from"react/jsx-runtime";import{useId as WT}from"react";import{FieldSelect as zT}from"efficient-easel/fields";import{SettingsField as GT}from"efficient-easel/panel";function UT(e){return e.map(({value:o,label:t,note:r})=>({value:o,label:t,...r?{meta:r}:{}}))}function hm({label:e,options:o,value:t,onChange:r,emptyLabel:a,icon:n,hint:s}){let i=WT(),f=`${i}-label`,u=`${i}-button`,p=Array.isArray(t)?t:[];return Im(GT,{label:l(e),labelId:f,icon:n,hint:s,children:Im(zT,{id:u,multiple:!0,value:p,options:UT(o),onChange:r,placeholder:a===void 0?l("None"):l(a),ariaLabelledBy:`${f} ${u}`,inline:!0})})}import{jsx as Pe,jsxs as wt,Fragment as m0}from"react/jsx-runtime";import{useCallback as x0,useContext as I0,useEffect as h0,useId as Rm,useRef as Lm,useState as Om}from"react";import{ThemeIcon as g0}from"efficient-easel/icons";import{SettingsField as b0}from"efficient-easel/panel";import{ScreenDocumentContext as y0}from"efficient-easel/screen/components/ScreenDocumentContext";import{jsx as Y,jsxs as Zo,Fragment as ZT}from"react/jsx-runtime";import{SettingsField as _i,SettingsGroupSub as QT}from"efficient-easel/panel";import{Button as Bi}from"efficient-shell/ui";import{jsx as Xo,jsxs as gm}from"react/jsx-runtime";import{SettingsField as $T}from"efficient-easel/panel";import{AccentIcon as qT}from"efficient-easel/icons";import{Tooltip as jT}from"efficient-shell/ui";function Ai(e){return go(e).background}function KT(e){let o=Yo(e.accent,Ai(e));return o===null?null:{ratio:o,grade:qt(o)}}function VT(e){let o=Ai(e),t=Yo(e.accent,o);return t===null?[]:Pu(e.accent).filter(r=>{let a=Yo(r,o);return a!==null&&a>t&&qt(a)==="good"})}var YT={good:"Easy to read","large-only":$t["large-only"],hard:$t.hard};function bm({value:e,onChange:o}){let t=KT(e),r=t?.grade,a=t&&t.grade!=="good"?VT(e):[];return Xo($T,{label:l("Main color"),icon:Xo(qT,{}),hint:t?l(YT[t.grade]):void 0,action:Xo(io,{value:e.accent,onChange:n=>o({...e,accent:n}),label:l("Main color")}),children:a.length>0?Xo("div",{className:"w-full min-w-0",children:gm("div",{className:"sf-readability",children:[Xo("p",{className:"sf-readability-advice",children:XT(r,!0)}),Xo("div",{className:"sf-readability-suggestions",children:a.map(n=>{let s=Yo(n,Ai(e));return Xo(jT,{content:l("Use {colour}",{colour:n.toUpperCase()}),children:gm("button",{type:"button",className:"sf-readability-suggestion",onClick:()=>o({...e,accent:n}),children:[Xo("span",{className:"sf-readability-chip",style:{background:n},"aria-hidden":!0}),s?`${s.toFixed(1)}:1`:n.toUpperCase()]})},n)})})]})}):null})}function XT(e,o){return e?e==="good"?l("This color reads clearly on your pages."):o?l("This color is hard to read on this theme's page. The buttons below are the same hue, darkened."):l("This color is hard to read on your page background. Pick one further from it \u2014 lighter if your pages are dark, deeper if they are light."):l("Pick a color to see how it reads.")}import{ButtonIcon as JT,GroundIcon as e0,LayoutIcon as o0,SquareIcon as t0,TextSmallIcon as r0,TypeIcon as ym}from"efficient-easel/icons";var Yr=e=>l("Theme {n}",{n:e+1});function Sm({colors:e}){let o=go(e),t=zr(e)??o.accent;return Zo("span",{className:"sf-theme-page",style:{background:o.background,color:o.text},"aria-hidden":!0,children:[Y("span",{className:"sf-theme-eyebrow",style:{color:o.muted},children:l("label")}),Zo("span",{className:"sf-theme-headline",children:[l("Heading")," ",Y("span",{style:{color:o.accent},children:l("accent")})]}),Y("span",{className:"sf-theme-body",children:l("body text")}),Zo("span",{className:"sf-theme-row",children:[Y("span",{className:"sf-theme-btn",style:{background:t,color:qs(e,o.accent)},children:l("button")}),Y("span",{className:"sf-theme-mini",style:{background:o.surface,borderColor:o.line},children:l("card")})]})]})}var Di={"Text color":Y(ym,{}),"Label color":Y(r0,{}),Background:Y(e0,{}),"Panels & cards":Y(o0,{}),Borders:Y(t0,{}),"Button color":Y(JT,{}),"Button text color":Y(ym,{})};function a0({label:e,colorKey:o,value:t,onChange:r,idPrefix:a="sf-theme-ink"}){let n=`${a}-${o}`;return Y(_i,{label:l(e),icon:Di[e],htmlFor:n,action:Y(io,{id:n,label:l(e),value:t,onChange:s=>r(o,s)})})}function n0({value:e,accent:o,onChange:t,idPrefix:r="sf-theme-ink"}){let a=`${r}-button`,n=/^#[0-9a-fA-F]{6}$/.test(e??""),s=n?e:o;return Y(_i,{label:l("Button color"),icon:Di["Button color"],htmlFor:a,action:Y(io,{id:a,label:l("Button color"),value:s,caption:n?s:l("Main"),onChange:t})})}function l0({colors:e,accent:o,onChange:t,idPrefix:r="sf-theme-ink"}){let a=`${r}-button-ink`,n=Lu(e),s=qs(e,o),i=zr(e)??o,f=qt(Yo(s,i)??0);return Y(_i,{label:l("Button text color"),icon:Di["Button text color"],hint:n&&f!=="good"?l("{grade} on the button",{grade:l($t[f])}):void 0,htmlFor:a,action:Y(io,{id:a,label:l("Button text color"),value:s,caption:n?s:l("Auto"),onChange:t})})}var s0=[{colour:!0},{label:"Text color",key:"text"},{label:"Label color",key:"muted"},{button:!0},{buttonInk:!0},{group:"Surfaces"},{label:"Background",key:"background"},{label:"Panels & cards",key:"surface"},{label:"Borders",key:"line"}];function Ni({colors:e,onChange:o,idPrefix:t}){let r=go(e);return Y(ZT,{children:s0.map(a=>"colour"in a?Y(bm,{value:e,onChange:o},"colour"):"group"in a?Y(QT,{title:l(a.group)},a.group):"button"in a?Y(n0,{value:e.button,accent:r.accent,onChange:n=>o({...e,button:n}),idPrefix:t},"button"):"buttonInk"in a?Y(l0,{colors:e,accent:r.accent,onChange:n=>o({...e,buttonInk:n}),idPrefix:t},"buttonInk"):Y(a0,{label:a.label,colorKey:a.key,value:r[a.key],onChange:(n,s)=>o({...e,[n]:s}),idPrefix:t},a.key))})}function wn({index:e,colors:o,selected:t,role:r="radio",open:a,editable:n=!0,onPick:s,onEdit:i,onChangeColors:f}){let u=go(o),p=Yr(e),m=e<$s.length&&!o.brandInk?$s[e]:null,x=qt(Yo(u.text,u.background)??0),I=m?JSON.stringify(o)!==JSON.stringify(m):!1,b=a!==void 0;return Zo("div",{className:`sf-theme-card${t?" is-selected":""}`,children:[Y("button",{type:"button",role:r,"aria-checked":r==="radio"?t:void 0,"aria-selected":r==="option"?t:void 0,"aria-label":p,className:"sf-theme-pick",onClick:s,children:Y(Sm,{colors:o})}),Zo("div",{className:"sf-theme-foot",children:[Y("span",{className:"sf-theme-name",children:p}),x!=="good"&&Y("span",{className:"sf-theme-warn",children:l($t[x])}),n&&i&&Y(Bi,{variant:a?"primary":"secondary",size:"sm",className:"sf-theme-edit","aria-expanded":b?a:void 0,"aria-controls":b?`sf-theme-colours-${e}`:void 0,"aria-label":a?l("Done {name}",{name:p}):l("Edit {name}",{name:p}),onClick:i,children:a?l("Done"):l("Edit")})]}),a&&Zo("div",{id:`sf-theme-colours-${e}`,className:"sf-theme-colours",children:[Y(Ni,{colors:o,onChange:C=>f?.(C)}),m&&Y(Bi,{variant:"link",size:"sm",className:"sf-theme-reset",disabled:!I,onClick:()=>f?.({...m}),children:I?l("Reset {name} to the preset",{name:p}):l("Not changed")})]})]})}function Cm({colors:e,name:o,nameId:t,open:r,menuId:a,labelId:n,buttonRef:s,onClick:i,onKeyDown:f,onEdit:u}){return Zo("div",{className:"sf-secttheme-btn",children:[Y("button",{ref:s,type:"button",className:"sf-theme-pick","aria-expanded":r,"aria-controls":a,"aria-labelledby":`${n} ${t}`,onClick:i,onKeyDown:f,children:e?Y(Sm,{colors:e}):Y("span",{className:"sf-secttheme-nopreview","aria-hidden":"true"})}),Zo("div",{className:"sf-theme-foot",children:[Y("span",{id:t,className:"sf-theme-name",children:o}),u&&Y(Bi,{variant:"secondary",size:"sm",className:"sf-theme-edit","aria-label":l("Edit {name}",{name:o}),onClick:u,children:l("Edit")}),Y("button",{type:"button",className:"sf-secttheme-caret","aria-hidden":"true",tabIndex:-1,onClick:i,children:Y("span",{className:"sf-multi-caret",children:"\u25BE"})})]})]})}import{useCallback as Ui,useEffect as Em,useRef as Fn}from"react";import{currentEaselSession as c0}from"efficient-easel/screen/lib/session";import{useEaselSession as d0}from"efficient-easel/screen/lib/session-context";import{useSyncExternalStore as i0}from"react";var wm,Mi=null,vt=null,kn=0,Hi=new Set;function Wi(e){wm=e;for(let o of Hi)o()}function zi(e){Mi=e,kn+=1,vt&&clearTimeout(vt),vt=null,Wi(void 0)}function km(e){kn+=1,Wi(e)}function Tn(e=250){Mi&&(vt&&clearTimeout(vt),vt=setTimeout(()=>{vt=null;let o=Mi;if(!o)return;let t=++kn;o().then(r=>{t===kn&&Wi(r)}).catch(()=>{})},e))}function vm(){return wm}function f0(e){return Hi.add(e),()=>{Hi.delete(e)}}function En(){return i0(f0,vm,vm)}var Gi=new Set;function Tm(e){return Gi.add(e),()=>{Gi.delete(e)}}async function JW(){let e=(await Promise.allSettled([...Gi].map(async o=>o()))).find(o=>o.status==="rejected");if(e)throw e.reason}import{WebsiteBackendError as u0}from"efficient-easel/screen/lib/backend-error";function Fm(e=c0()){return(o,t,r)=>{let a=We(e).theme;return a?a.update(o,r?{siteId:r}:void 0):Promise.reject(new u0("invalid","This backend stores no site theme."))}}function Pm(e){return e.themeFromDocument?{status:"skipped",reason:"template"}:e.token?null:{status:"skipped",reason:"no-token"}}async function p0(e,o=Fm()){let{themeFromDocument:t,token:r,siteId:a,patch:n}=e,s=Pm({themeFromDocument:t,token:r});if(s)return s;if(Object.keys(n).length===0)return{status:"skipped",reason:"empty"};try{return await o(n,r,a??void 0),{status:"saved"}}catch(i){return{status:"failed",error:i}}}function Yt({themeFromDocument:e,tokenRef:o,siteId:t,onResult:r}){let a=Fn(null),n=Fn({}),s=d0(),i=Fn(r);i.current=r;let f=Fn(null),u=Ui(x=>{if(x.status==="skipped"){let I=`skipped:${x.reason}`;if(f.current===I)return;f.current=I}else f.current=null;i.current?.(x)},[]),p=Ui(async()=>{a.current&&(clearTimeout(a.current),a.current=null);let x=n.current;n.current={};let I=await p0({themeFromDocument:e,token:o?.current,siteId:t,patch:x},Fm(s));return u(I),I.status==="saved"&&Tn(),I.status==="failed"&&(n.current={...x,...n.current}),I},[e,o,t,u,s]),m=Ui((x,I=!1)=>{let b=Pm({themeFromDocument:e,token:o?.current});if(b){u(b);return}n.current={...n.current,...x},a.current&&clearTimeout(a.current),I?p():a.current=setTimeout(()=>{p()},500)},[e,o,p,u]);return Em(()=>()=>{p()},[p]),Em(()=>Tm(async()=>{if(!a.current&&Object.keys(n.current).length===0)return;let x=await p();if(x.status==="failed")throw x.error}),[p]),{persist:m,flush:p}}var S0="Follow the page",yz="Follow the slideshow",C0=e=>l("Editing {name} changes it everywhere.",{name:e});function v0({colors:e}){if(!e)return Pe("span",{className:"sf-secttheme-chip sf-secttheme-chip--none","aria-hidden":"true"});let o=go(e);return wt("span",{className:"sf-secttheme-chip","aria-hidden":"true",children:[Pe("i",{style:{background:o.background}}),Pe("i",{className:"sf-secttheme-chip-accent",style:{background:o.accent}})]})}function w0({themes:e,value:o,onPick:t,onEdit:r,menuId:a,followLabel:n}){return wt("div",{className:"sf-multi-menu sf-secttheme-menu",id:a,role:"listbox",children:[n!==void 0&&wt(m0,{children:[wt("button",{type:"button",role:"option","aria-selected":o===null,className:`sf-secttheme-item${o===null?" is-active":""}`,onClick:()=>t(xn),children:[Pe(v0,{}),Pe("span",{className:"sf-secttheme-name",children:l(n)})]}),Pe("div",{className:"sf-secttheme-sep",role:"presentation"})]}),o!==null&&e[o]&&Pe("p",{className:"sf-secttheme-oncard",role:"presentation",children:l("{name} is on this section",{name:Yr(o)})}),e.map((s,i)=>i===o?null:Pe(wn,{role:"option",index:i,colors:s,selected:!1,onPick:()=>t(i),onEdit:()=>r(i)},i))]})}function k0({index:e,colors:o,onChange:t,onDone:r}){let a=Yr(e),n=Rm();return wt("div",{className:"sf-secttheme-sheet",children:[wt("div",{className:"sf-secttheme-sheet-head",children:[Pe("span",{children:a}),Pe("button",{type:"button",className:"sf-secttheme-done",onClick:r,children:l("Done")})]}),Pe("div",{className:"sf-secttheme-rows",children:Pe(Ni,{colors:o,onChange:t,idPrefix:n})}),Pe("p",{className:"sf-secttheme-warn",children:C0(a)})]})}function Am({value:e,onChange:o,followLabel:t,hint:r}){let{theme:a,setTheme:n}=V(),s=Je(a),i=I0(y0),f=i?.tokenRef,u=i?.siteId??null,p=!i?.capabilities?.hasSiteTheme,{persist:m,flush:x}=Yt({themeFromDocument:p,tokenRef:f,siteId:u}),I=Je(s),b=I.themes,C=xi(e),w=C!==null?b[C]:void 0,k=w??(b.length?Ut(I):void 0),[v,g]=Om(!1),[y,L]=Om(null),F=Lm(null),O=Lm(null),E=Rm(),D=x0(()=>{g(!1),L(null)},[]);h0(()=>{if(!v&&y===null)return;let R=H=>{F.current&&!F.current.contains(H.target)&&(x(),D())};return document.addEventListener("mousedown",R),()=>document.removeEventListener("mousedown",R)},[v,y,D,x]);let G=R=>{o(R),D()},B=R=>{if(y===null)return;let H=b.map((ae,se)=>se===y?R:ae),_={...I,themes:H};n(_),m({selected_preset:_.selected,theme_presets:_.themes})};return wt("div",{className:"sf-secttheme",ref:F,children:[Pe(b0,{label:l("Theme"),icon:Pe(g0,{}),labelId:`${E}-label`,hint:r,children:Pe(Cm,{colors:k,onEdit:C!==null?()=>{L(C),g(!1)}:void 0,name:w?Yr(C):l(t??S0),nameId:`${E}-value`,labelId:`${E}-label`,open:v,menuId:E,buttonRef:O,onClick:()=>{L(null),g(R=>!R)},onKeyDown:R=>{R.key==="Escape"&&(v||y!==null)&&(R.preventDefault(),D())}})}),v&&y===null&&Pe("div",{onKeyDown:R=>{R.key==="Escape"&&(R.preventDefault(),D(),O.current?.focus())},children:Pe(w0,{themes:b,value:C,onPick:G,onEdit:R=>{L(R),g(!1)},menuId:E,followLabel:t})}),y!==null&&b[y]&&Pe(k0,{index:y,colors:b[y],onChange:B,onDone:()=>{x(),D(),O.current?.focus()}})]})}import{jsx as Bm}from"react/jsx-runtime";import{useId as T0}from"react";import{FieldSelect as E0}from"efficient-easel/fields";import{SettingsField as F0}from"efficient-easel/panel";function P0(e){return e.map(({value:o,label:t,group:r,thumb:a,meta:n})=>({value:o,label:t,...r!==void 0?{group:r}:{},...a!==void 0?{thumb:a}:{},...n!==void 0?{meta:n}:{}}))}function Ez({label:e,options:o,fallback:t,value:r,onChange:a,placeholder:n,bare:s=!1,icon:i}){let f=T0(),u=`${f}-label`,p=`${f}-button`,m=r??"",x=o.some(w=>w.value===m)?m:t,I=l(e),b=n===void 0?void 0:l(n),C=Bm(E0,{id:p,value:x,options:P0(o),onChange:a,placeholder:b,searchPlaceholder:b,...s?{ariaLabel:I}:{ariaLabelledBy:`${u} ${p}`},searchable:!0,groupCount:!0,inline:!0});return s?C:Bm(F0,{label:I,labelId:u,icon:i,children:C})}import{jsx as Tt,jsxs as B0}from"react/jsx-runtime";import{SettingsField as Um}from"efficient-easel/panel";import{LinkIcon as _0}from"efficient-easel/icons";import{LinkPicker as D0,TextLinkField as N0}from"efficient-shell/ui";import{useEffect as Gm,useMemo as On,useRef as M0,useState as Ln}from"react";import{currentEaselSession as L0}from"efficient-easel/screen/lib/session";function _m(){return L0().auth.token}import{currentEaselSession as H0}from"efficient-easel/screen/lib/session";import{useScreenDocument as W0}from"efficient-easel/screen/components/ScreenDocumentContext";var Pn="homepage";function kt(e){return(e??"").toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"")}var Dm=[{value:"page",label:"Page"},{value:"anchor",label:"Anchor"},{value:"blog",label:"Blog post",needs:"service"},{value:"product",label:"Product",needs:"commerce"},{value:"custom",label:"Custom URL"}];function Nm(e){return e.offersCommerce&&e.offersService?Dm:Dm.filter(o=>!o.needs||(o.needs==="commerce"?e.offersCommerce:e.offersService))}function Xr(e){return e===Pn?"/":`/${e}`}function Mm(e){return`/journal/${e}`}function _z(e){return`/wheels/${e}`}function Hm(e,o){return`${Xr(e)}#${o}`}function O0(e){return kt(e)}function R0(e){return typeof e=="string"?e.trim():e&&typeof e=="object"&&typeof e.text=="string"?e.text.trim():""}function Wm(...e){let o=new Set,t=[];for(let r of e)for(let a of r?.content??[]){let n=R0(a?.props?.anchor);if(!n)continue;let s=O0(n);!s||o.has(s)||(o.add(s),t.push({slug:s,name:n}))}return t}function Dz(e){let o=e.indexOf("#"),t=o===-1?e:e.slice(0,o),r=t.indexOf("?");return r===-1?t:t.slice(0,r)}var A0=()=>({choosePage:l("Choose a page"),chooseSection:l("Choose a section"),noSections:l("No section anchors yet"),sectionHint:l("Jumps to a section on that page."),choosePost:l("Choose a post"),chooseProduct:l("Choose a product")});function zm(e,o,t){if(!e)return"page";if(e.startsWith("/journal/"))return"blog";if(e.startsWith("/wheels/"))return"product";if(e.includes("#")){let r=e.slice(0,e.indexOf("#"));if(r===""||r==="/"||o.includes(r))return"anchor"}return e==="/"||o.includes(e)||t&&t.listingPaths.includes(t.targetOf(e))?"page":"custom"}function $i(e,o){let t=A0(),r=e.pages.map(p=>({value:Xr(p.slug),label:p.title})),a=o?.pageOptions?o.pageOptions(r):r,n=a.map(p=>p.value),s=e.pages.map(p=>({label:p.title,options:Wm(...p.docs).map(m=>({value:Hm(p.slug,m.slug),label:m.name}))})).filter(p=>p.options.length>0),i=p=>{switch(p){case"page":return{type:"select",options:a,placeholder:t.choosePage};case"anchor":return{type:"groups",groups:s,placeholder:s.length?t.chooseSection:t.noSections};case"blog":return{type:"select",options:e.posts.map(m=>({value:Mm(m.slug),label:m.title||m.slug})),placeholder:t.choosePost};case"product":return{type:"select",options:e.products.map(m=>({value:m.href,label:m.name||m.href})),placeholder:t.chooseProduct};case"custom":return{type:"text"}}},f=Nm(e.offers).map(p=>({value:p.value,label:l(p.label),target:i(p.value),...p.value==="anchor"?{hint:t.sectionHint}:{},...p.value==="blog"||p.value==="product"?{hideWhenEmpty:!0}:{}}));if(!o)return{kinds:f,rules:{kindOf:p=>zm(p,n),targetOf:p=>p,readFilter:()=>null,withFilter:p=>p}};let u=p=>{let m=o.withFilter(p,null);return o.listingPaths.includes(m)?m:p};return{kinds:f,rules:{kindOf:p=>zm(p,n,{listingPaths:o.listingPaths,targetOf:u}),targetOf:u,readFilter:o.readFilter,withFilter:o.withFilter},filtersFor:p=>o.listingPaths.includes(p)?o.filtersFor(p):null}}import{useEaselSession as z0}from"efficient-easel/screen/lib/session-context";function $m(e){let o=new Map;return(t="")=>{let r=_m(),a=o.get(t);if(!a||a.token===null&&r!==null){let n=r||!H0().usesBridgedToken?e(r??"",t).catch(()=>[]):Promise.resolve([]);return o.set(t,{promise:n,token:r}),n}return a.promise}}var G0=$m(async(e,o)=>{let t=o?{siteId:o}:void 0,{pages:r}=We();return r.linkTargets?r.linkTargets(t):(await r.list(t)).map(a=>({id:a.id,slug:a.slug,label:a.label,layout:null}))}),U0=$m(async(e,o)=>await We().blog?.posts(o?{siteId:o}:void 0)??[]);function $0({value:e,onChange:o,label:t="Link",data:r,filters:a}){let n=On(()=>$i(r,a),[r,a]),s=l(t);return Tt(Um,{label:s,icon:Tt(_0,{}),children:Tt(D0,{value:e,onChange:i=>o(i),kinds:n.kinds,rules:n.rules,filtersFor:n.filtersFor,label:s})})}function qm(){let{siteId:e,capabilities:o}=W0(),{offersCommerce:t,hasBlog:r}=o,[a,n]=Ln([]),[s,i]=Ln([]),[f,u]=Ln([]),[p,m]=Ln(null),x=z0().chrome,I=x?.products?.list,b=x?.linkFilters,C=b?void 0:x?.linkRow,w=M0(!0);Gm(()=>(w.current=!0,()=>{w.current=!1}),[]),Gm(()=>{let g=!0;return G0(e??void 0).then(y=>g&&w.current&&n(y)),r&&U0(e??void 0).then(y=>g&&w.current&&i(y)),t&&I?.().then(y=>g&&w.current&&u(y)),t&&b?b.load(e).catch(()=>null).then(y=>g&&w.current&&m(()=>y)):m(null),()=>{g=!1}},[e,t,r,I,b]);let k=On(()=>({pages:a.filter(g=>!sp(g.slug)).map(g=>({slug:g.slug,title:g.label,docs:[g.layout]})),posts:r?s.map(g=>({slug:g.slug,title:g.title})):[],products:t?f.map(g=>({href:g.href,name:g.name})):[],offers:{offersCommerce:t,offersService:r}}),[a,s,f,t,r]),v=On(()=>p?p(k.pages):null,[p,k]);return{data:k,filters:v,pages:a,offersCommerce:t,HostLinkRow:C}}function oG({label:e,icon:o,text:t,onTextChange:r,link:a,onLinkChange:n}){let{data:s,filters:i}=qm(),f=On(()=>$i(s,i),[s,i]),u=l(e);return Tt(Um,{label:u,icon:o,children:Tt(N0,{label:u,text:t,onTextChange:r,link:a,onLinkChange:p=>n(p),kinds:f.kinds,rules:f.rules,filtersFor:f.filtersFor})})}function jm({value:e,onChange:o,label:t="Link"}){let r=typeof e=="string"?e:"",{data:a,filters:n,pages:s,offersCommerce:i,HostLinkRow:f}=qm(),u=a.pages.map(m=>Xr(m.slug)),p=i&&f&&(r==="/"||u.includes(r))?f:void 0;return B0("div",{children:[Tt($0,{value:r,onChange:o,label:t,data:a,filters:n}),p&&Tt(p,{value:r,onChange:o,pages:s})]})}import{UiIcon as Hx}from"efficient-easel/draw/client";var uo={min:10,max:200,step:10};function Km(e,o){let t=typeof e=="number"?e:void 0,r=typeof o=="number"?o:void 0;if(!(t===void 0&&r===void 0))return{paddingTop:t,paddingBottom:r}}var q0="sf-pad-top-phone",j0="sf-pad-bottom-phone",K0="--sf-pad-t-phone",V0="--sf-pad-b-phone",Y0="sf-pad-left-phone",X0="sf-pad-right-phone",Z0="--sf-pad-l-phone",Q0="--sf-pad-r-phone";function Xm(e,o,t,r,a,n,s,i){let f=Km(e,o)??{},u={},p=["sf-section-pad"];typeof t=="number"&&(p.push(q0),u[K0]=`${t}px`),typeof r=="number"&&(p.push(j0),u[V0]=`${r}px`);let m={};return typeof a=="number"&&(m.paddingLeft=a),typeof n=="number"&&(m.paddingRight=n),typeof s=="number"&&(p.push(Y0),u[Z0]=`${s}px`),typeof i=="number"&&(p.push(X0),u[Q0]=`${i}px`),p.length===1&&Km(e,o)===void 0&&!Object.keys(m).length?null:{className:p.join(" "),style:{...f,...m,...u}}}var Vm=e=>typeof e=="number"?e:void 0;function Ym(e,o,t){let r=Vm(e)??t,a=Vm(o);return r===void 0?a:a===void 0?r:r+a}function rG(e,o={}){return{top:Ym(e.padTop,e.sectionPaddingTop,o.top),bottom:Ym(e.padBottom,e.sectionPaddingBottom,o.bottom)}}function aG(e){return{top:e.sectionPaddingTop,bottom:e.sectionPaddingBottom,topPhone:e.sectionPaddingTopPhone,bottomPhone:e.sectionPaddingBottomPhone,left:e.sectionPaddingLeft,right:e.sectionPaddingRight,leftPhone:e.sectionPaddingLeftPhone,rightPhone:e.sectionPaddingRightPhone}}function nG(e){return Xm(e.top,e.bottom,e.topPhone,e.bottomPhone,e.left,e.right,e.leftPhone,e.rightPhone)}function lG(e,o){let t=r=>typeof r=="number"?r+o:void 0;return Xm(t(e.top),t(e.bottom),t(e.topPhone),t(e.bottomPhone),e.left,e.right,e.leftPhone,e.rightPhone)}var J0=["auto","fixed","screen"],eE=["px","%"];var oE="var(--sf-header-h, 88px)",qi={min:40,max:2e3,step:10,fallback:600},ji={min:10,max:200,step:5,fallback:100},tE="sf-section-minh",Zm={base:"--sf-section-minh",small:"--sf-section-minh-s"},Jm=e=>typeof e=="string"&&J0.includes(e),rE=e=>typeof e=="string"&&eE.includes(e);function Rn(e){let o=Jm(e.sectionHeightMode)?e.sectionHeightMode:"auto",t=o==="screen"?"%":rE(e.sectionHeightUnit)?e.sectionHeightUnit:"px",r=o==="screen"?ji.fallback:qi.fallback,a=typeof e.sectionHeightValue=="number"?e.sectionHeightValue:r;return{mode:o,value:a,unit:t}}function ex(e){let{mode:o,value:t,unit:r}=Rn(e);if(o==="auto")return;if(o==="fixed"&&r==="px")return[`${t}px`,null];let a=t/100,n=s=>o==="screen"?`(100${s} - ${oE})`:`100${s}`;return[`calc(${n("vh")} * ${a})`,`calc(${n("svh")} * ${a})`]}function aE(e){let o=ex(e);if(!o)return;let[t,r]=o;return{display:"grid",[Zm.base]:t,...r?{[Zm.small]:r}:{}}}var iG=new Set(["Hero","HeroSingle","IntroBleed","CategoryBar","DocTabs"]),Xt="Height",nE="sf-section-minh-phone",Qm={base:"--sf-section-minh-p",small:"--sf-section-minh-ps"};function Ki(e){return Jm(e.sectionHeightModePhone)}function fG(e){return Rn({sectionHeightMode:e.sectionHeightModePhone,sectionHeightValue:e.sectionHeightValuePhone,sectionHeightUnit:e.sectionHeightUnitPhone})}function lE(e){let o=aE(e),t=Ki(e)?ex({sectionHeightMode:e.sectionHeightModePhone,sectionHeightValue:e.sectionHeightValuePhone,sectionHeightUnit:e.sectionHeightUnitPhone}):void 0;if(!o&&!t)return null;let r=[tE],a={...o??{}};return t&&(r.push(nE),a[Qm.base]=t[0],t[1]&&(a[Qm.small]=t[1])),{className:r.join(" "),style:a}}function cG(e){return lE(e)!==null}var An="Stick to top",Qo={min:0,max:200,step:4,fallback:0},sE="sf-section-stick",iE="sf-section-stick-phone-on",fE="sf-section-stick-phone-off",ox={desktop:"--sf-stick-distance",phone:"--sf-stick-distance-phone"},uG=new Set(["CategoryBar","DocTabs","IntroBleed"]);function tx(e){let o=typeof e=="number"&&Number.isFinite(e)?e:Qo.fallback;return Math.min(Qo.max,Math.max(Qo.min,Math.round(o)))}function Vi(e){return typeof e.stickTopPhone=="boolean"}function Yi(e){let o=e.stickTop===!0,t=tx(e.stickTopDistance),r=Vi(e),a=r?e.stickTopPhone===!0:o,n=r?tx(e.stickTopDistancePhone):t;return{desktop:o,desktopDistance:t,phone:a,phoneDistance:n,ownPhone:r}}function pG(e){let o=Yi(e);if(!o.desktop&&!o.phone)return null;let t=[sE],r={};return o.desktop&&(r[ox.desktop]=`${o.desktopDistance}px`),(o.ownPhone||o.phone!==o.desktop)&&(t.push(o.phone?iE:fE),o.phone&&(r[ox.phone]=`${o.phoneDistance}px`)),o.desktop||t.push("sf-section-stick-desktop-off"),{className:t.join(" "),style:r}}var cE=["column","row","tabs"],rx="Direction",dE={column:"Stacked",row:"One row",tabs:"Tabs"},ax={Flex:cE,HeroGroup:["column","row"]},uE={Flex:"row",HeroGroup:"column"},pE={column:"flex-col",row:"flex-row",tabs:"flex-col"};function Bn(e,o){return ax[e].includes(o)?o:uE[e]}function xG(e,o){return pE[Bn(e,o)]}function nx(e){return ax[e].map(o=>({label:dE[o],value:o}))}var Xi=[{label:"Start",value:"start"},{label:"Center",value:"center"},{label:"Space between",value:"between"},{label:"End",value:"end"}],ix=[{label:"Start",value:"start"},{label:"Center",value:"center"},{label:"End",value:"end"},{label:"Stretch",value:"stretch"}],fx="Wrap",Zi=[{label:"Wrap",value:"wrap"},{label:"No wrap",value:"nowrap"}],lx={start:"justify-start",center:"justify-center",between:"justify-between",end:"justify-end"},sx={start:"items-start",center:"items-center",end:"items-end",stretch:"items-stretch"};function hG(e,o){let t=typeof e=="string"&&e in lx?lx[e]:"",r=typeof o=="string"&&o in sx?sx[o]:"";return[t,r].filter(Boolean).join(" ")}function gG(e){return e===!0||e==="wrap"?"flex-wrap":""}var Qi="Block widths",_n=[{label:"Fit content",value:"content",weights:null},{label:"Equal",value:"equal",weights:[1,1]},{label:"Big left",value:"bigLeft",weights:[2,1]},{label:"Big right",value:"bigRight",weights:[1,2]},{label:"Bigger left",value:"biggerLeft",weights:[3,1]},{label:"Bigger right",value:"biggerRight",weights:[1,3]}],Zr="[&>*]:min-w-0 [&>*]:flex-1 [&>*]:basis-0",mE={equal:Zr,bigLeft:`${Zr} [&>*:first-child]:min-[800px]:grow-[2]`,bigRight:`${Zr} [&>*:last-child]:min-[800px]:grow-[2]`,biggerLeft:`${Zr} [&>*:first-child]:min-[800px]:grow-[3]`,biggerRight:`${Zr} [&>*:last-child]:min-[800px]:grow-[3]`};function bG(e){return typeof e=="string"?mE[e]??"":""}var cx="Columns on phone",Ji=1,dx=3,xE={2:"max-[800px]:flex-wrap [&>*]:max-[800px]:min-w-0 [&>*]:max-[800px]:basis-[calc((100%_-_var(--sf-gap-len,0px))/2)]",3:"max-[800px]:flex-wrap [&>*]:max-[800px]:min-w-0 [&>*]:max-[800px]:basis-[calc((100%_-_var(--sf-gap-len,0px)_*_2)/3)]"};function yG(e){let o=Number(e);return xE[o]??"max-[800px]:flex-col"}var ux="Block spacing",ef=[{label:"Each block",value:"each"},{label:"Gap only",value:"gap"}],IE="sf-box-gap-only";function SG(e){return e==="gap"?IE:""}var hE=["solid","dashed","dotted"],gE=["top","right","bottom","left"],vG="sf-section-border",wG="sf-section-border-self",bE=/^#(?:[0-9a-f]{3}|[0-9a-f]{4}|[0-9a-f]{6}|[0-9a-f]{8})$/i,px=e=>typeof e=="number"&&Number.isFinite(e)?`${Math.min(20,Math.max(0,Math.round(e)))}px`:void 0;function mx(e,{phone:o=!1}={}){if(!e||typeof e!="object")return;let t=o?"-phone":"",r={};for(let a of gE){let n=px(e[a])??px(e.width);n!==void 0&&(r[`--sf-border-${a}-width${t}`]=n)}return typeof e.style=="string"&&hE.includes(e.style)&&(r[`--sf-border-style${t}`]=e.style),typeof e.color=="string"&&bE.test(e.color)&&(r[`--sf-border-color${t}`]=e.color.toLowerCase()),Object.keys(r).length?r:void 0}function kG(e,o){let t=mx(e),r=mx(o,{phone:!0});return t||r?{...t,...r}:void 0}var hx="sf.gapContainer",Jo={min:-32,max:64,step:2},gx={Grid:{sm:12,md:24,lg:40},Flex:{sm:12,md:24,lg:40},FooterGroup:{sm:8,md:16,lg:32},HeroGroup:null,Events:null,GalleryB:null,ProductGrid:null},Zt={Grid:24,Flex:24,FooterGroup:16,HeroGroup:0,Events:24,GalleryB:8,ProductGrid:2},yE=new Set(["Events","GalleryB"]);function Qr(e,o,t){if(typeof o=="number"&&Number.isFinite(o)&&o>=Jo.min)return o;if(typeof o=="string"){let r=gx[e]?.[o];if(typeof r=="number")return r}return typeof t=="number"&&Number.isFinite(t)?t:Zt[e]}var SE="sf-gap-overlap",CE="--sf-gap-overlap",bx="--sf-block-gap",vE="--sf-block-gap-rem",Et={min:0,max:Jo.max,step:Jo.step};function wE(e){if(typeof e!="number"||!Number.isFinite(e))return null;let o=Math.min(Math.max(Math.round(e),Et.min),Et.max);return o-o%Et.step}function EG(e){let o=wE(e);return o===null?{}:{[bx]:`${o}px`,[vE]:`${o/16}rem`}}var xx="sf-gap-zone",Ix="--sf-gap-len";function of(e,o){return typeof o=="number"&&Number.isFinite(o)&&o>=Jo.min?!0:typeof o=="string"&&typeof gx[e]?.[o]=="number"}var kE={block:"sf-gap-overlap-block",inline:"sf-gap-overlap-inline",both:"sf-gap-overlap-both"};function FG(e,o,t){if(!of(e,o)){let a=`${Zt[e]}px`,n=yE.has(e)?`var(--sf-card-gap, ${a})`:a;return{className:` ${xx}`,style:{[Ix]:`var(${bx}, ${n})`}}}let r=Qr(e,o);return r>=0?{className:` ${xx}`,style:{[Ix]:`${r}px`}}:{className:` ${SE} ${kE[t]}`,style:{gap:"0px",[CE]:`${-r/2}px`}}}var yx=["transparent","var(--section-bg)","var(--surface)","var(--surface-2)"],Sx={transparent:"No fill","var(--section-bg)":"Section band","var(--surface)":"Panels and cards","var(--surface-2)":"Second surface"},Dn="var(--section-bg)",Nn="inherit";function LG(e,o){return e===Nn?Dn:e===void 0?o:Mn(e)}var TE=/var\(\s*--(surface-2|surface|line)\s*(?=[,)])/g;function Mn(e){return e.replace(TE,"var(--site-$1")}function Cx(e,o){return e===Nn?!0:e===void 0&&o===Dn}var vx=["transparent","var(--wheel-stage)","var(--surface)","var(--surface-2)"],wx={transparent:"No fill","var(--wheel-stage)":"Image stage","var(--surface)":"Panels and cards","var(--surface-2)":"Second surface"},Qt="var(--wheel-stage)",Hn="transparent",Jr="inherit";function AG(e,o){return Mn(tf(e,o))}function tf(e,o){return e===Jr?Qt:e==null?o:e===!0?Qt:e===!1?Hn:e}function BG(e){return typeof e=="string"&&e!==Jr?Mn(e):Qt}function _G(e){return e!==Hn&&e!=="none"&&e!==""}function kx(e,o){return e===Jr||e===!0?!0:e==null?o===Qt:!1}var Tx="inherit",Wn="fixed",Ex=e=>typeof e!="number"&&e!==Wn,EE="var(--sf-heading-max, 9999px)";function NG(e,o,t,r){if(typeof e=="number")return`${e}px`;if(e===Wn)return o;let a=r?`var(--size-${r}, ${o})`:o;return t==="heading"?`min(${a}, ${EE})`:a}var we={min:1e3,max:2e3,step:50,default:1600};function FE(e){return{maxWidth:e,marginInline:"auto",width:"100%"}}var Fx="--sf-site-width",rf=`var(${Fx},${we.default}px)`,HG=`max-w-[${rf}]`,WG=`max-w-[${we.default}px]`;function PE(e){return typeof e!="number"||!Number.isFinite(e)?we.default:Math.round(Math.min(Math.max(e,we.min),we.max))}function zG(e){let o=PE(e);return o===we.default?{}:{[Fx]:`${o}px`}}var ko={min:0,max:80,step:4,default:40},Px="--sf-site-gutter",qe=`var(${Px},${ko.default}px)`,LE=`px-[${qe}]`;var et={md:`min(24px,${qe})`,sm:`min(20px,${qe})`,frame:`min(24px,${qe})`,tabs:`min(16px,${qe})`},GG=[[`max-[1100px]:px-[${et.md}]`,"max-[1100px]:px-6"],[`max-[1100px]:px-[${et.tabs}]`,"max-[1100px]:px-4"],[`max-[960px]:px-[${et.frame}]`,"max-[960px]:px-6"],[`max-[900px]:px-[${et.md}]`,"max-[900px]:px-6"],[`max-[800px]:px-[${et.md}]`,"max-[800px]:px-6"],[`max-[720px]:px-[${et.sm}]`,"max-[720px]:px-5"],[`max-[800px]:px-[${et.sm}]`,"max-[800px]:px-5"],[`max-[640px]:px-[${et.sm}]`,"max-[640px]:px-5"],[`min-[800px]:px-[${qe}]`,"min-[800px]:px-10"],[`max-[720px]:px-[min(24px,${qe})]`,"max-[720px]:px-6"],[`max-[800px]:-mx-[min(20px,${qe})]`,"max-[800px]:-mx-5"],[`max-[720px]:-mx-[min(20px,${qe})]`,"max-[720px]:-mx-5"],[`-mx-[${qe}]`,"-mx-10"],[LE,"px-10"]];var UG="mx-auto max-w-[var(--sf-site-width,1600px)] px-[var(--sf-site-gutter,40px)] max-[800px]:px-[min(20px,var(--sf-site-gutter,40px))]",$G="mx-auto max-w-[var(--sf-site-width,1600px)] px-[var(--sf-site-gutter,40px)] max-[1100px]:px-[min(24px,var(--sf-site-gutter,40px))]";function OE(e){return typeof e!="number"||!Number.isFinite(e)?ko.default:Math.round(Math.min(Math.max(e,ko.min),ko.max))}function qG(e){let o=OE(e);return o===ko.default?{}:{[Px]:`${o}px`}}var zn=rf,jG=`max-w-[${zn}]`,KG=`max-w-[min(var(--sf-page-cap,${we.default}px),${we.default}px)]`,Lx="--sf-hero-cap",RE=`var(${Lx},none)`,VG=`max-w-[${RE}]`,af="--sf-hero-bleed-m",nf="--sf-hero-bleed-w",YG=`var(${af},calc(50% - 50vw))`,XG=`var(${nf},100vw)`,ZG=`mx-[var(${af},calc(50%_-_50vw))]`,QG=`w-[var(${nf},100vw)]`,lf="--sf-hero-chrome-x",sf="--sf-hero-chrome-cap";function JG(e){return e===!0?{[Lx]:zn,[af]:"auto",[nf]:"100%",[lf]:"24px",[sf]:"none"}:{}}var ff=`calc(${rf} - ${qe}*2)`,eU=`max-w-[${ff.replace(/ /g,"_")}]`;var AE="--sf-chrome-cap",BE=`var(${AE},${ff})`,oU="data-page-width";function tU(e){return e==="full"?"full":null}function rU(e){return e==="full"?null:FE(e==="content"?ff:BE)}function aU(e){if(e==="full")return"full";if(e==="content")return"content"}var _E=["contained","page","full"],Rx=["full","page"],Jt={full:"Full width",page:"Content width"},df="inherit",DE=e=>typeof e=="string"&&_E.includes(e),Ax=e=>e===df;function Mo(e,o){let t=typeof e.pageWidth=="number"?e.pageWidth:we.default;return Ax(e.widthMode)?{mode:"full",pageWidth:t,inherited:!0}:e.widthMode==="contained"?{mode:"page",pageWidth:t,inherited:!1}:DE(e.widthMode)?{mode:e.widthMode,pageWidth:t,inherited:!1}:e.contained===!0?{mode:"page",pageWidth:t,inherited:!1}:typeof e.fullWidth=="boolean"?{mode:e.fullWidth?"full":"page",pageWidth:t,inherited:!1}:e.contained===!1?{mode:"full",pageWidth:t,inherited:!1}:{mode:o,pageWidth:t,inherited:o==="full"}}function uf(e){return Mo(e,"page").mode==="full"}var ea="site",Bx={Hero:"hero",HeroSingle:"hero",IntroBleed:"scrollOver",SpecStrip:"background",Timeline:"background",Footprint:"background",Prose:"background",ParagraphsA:"background",Cards:"background",KeyFeatures:"background",Chart:"background",Mockup:"background",Testimonials:"background",TitleWithButtons:"background",Countdown:"background",DocMasthead:"background",DocBody:"background",DocMetaCards:"background",Gallery:"background",GalleryB:"background",Reviews:"background",ReviewForm:"background",Form:"background",AppointmentBooking:"background",FAQ:"background",Events:"background",Split:"both",Breadcrumb:"both",Collections:"both",CatalogFilterBar:"both",AlloyWheelsListing:"both",Banner:"contained",Stats:"contained",Logos:"contained",Divider:"contained",OrderSummary:"contained",DeliveryOptions:"contained",PaymentBadges:"contained",CheckoutCTA:"contained",Flex:"contained",Grid:"contained",Manifesto:"contentColumn",SectionHeader:"contentFull",ProductHero:"contentFull",ProductGrid:"productGrid",TimelineTrack:"capped",DetailRows:"capped",FitmentTable:"capped",TyreSizes:"capped",TyreFitment:"capped",EuTyreLabel:"capped",BundleOffer:"capped",CompatibleTyres:"capped",RelatedProducts:"capped",ProcessSteps:"capped",StatsParagraph:"capped",Masthead:"capped",FeaturedCover:"capped",LongRead:"capped",Series:"capped",ContactLocations:"capped",FitmentFinder:"capped",SpecTable:"capped",Subscribe:"capped",SubscribeBlogs:"capped",ContactRouting:"capped",SubmitBuild:"capped"};function NE(e){return Object.prototype.hasOwnProperty.call(Bx,e)}var cf=e=>e==="full"||e==="content",ME=e=>typeof e=="number"&&Number.isFinite(e)&&e>0,Ox=({widthMode:e,fullWidth:o,pageWidth:t})=>({widthMode:e,fullWidth:o,pageWidth:t});function HE(e,o){let t={background:null,content:null,contentMax:null};switch(e){case"hero":return Ax(o.widthMode)||o.widthMode!=="full"?t:{...t,background:"full"};case"scrollOver":return o.fullWidth===!1?t:{...t,content:"full"};case"background":return Mo(o,"full").mode==="full"?t:{...t,background:"content"};case"both":return Mo(o,"full").mode==="full"?{...t,content:"full"}:{...t,background:"content"};case"contained":return Mo(o,"page").mode==="full"?{...t,content:"full"}:{...t,background:"content"};case"contentColumn":return Mo(Ox(o),"page").mode==="full"?{...t,content:"full"}:t;case"contentFull":return Mo(Ox(o),"full").mode==="full"?{...t,content:"full"}:t;case"productGrid":{let r=Mo(o,"full");return r.mode==="full"?{...t,content:"full"}:{background:"content",content:"content",contentMax:r.pageWidth}}case"capped":return{...t,background:"content"}}}function pf(e,o){if(!NE(e))return{background:null,content:null,contentMax:null};let t=Bx[e],r=o,a=HE(t,r),n=r.backgroundWidth===ea?null:cf(r.backgroundWidth)?r.backgroundWidth:a.background;return r.contentWidth===ea?{background:n,content:null,contentMax:null}:cf(r.contentWidth)?{background:n,content:r.contentWidth,contentMax:r.contentWidth==="content"&&ME(r.contentMax)?r.contentMax:null}:{background:n,content:a.content,contentMax:a.contentMax}}var _x="siteWidths";function Gn(e){return cf(e)?e:null}function Dx(e,o){return{[_x]:{background:Gn(e),content:Gn(o)}}}function sU(e){let o=e.puck?.metadata?.[_x];return{background:Gn(o?.background),content:Gn(o?.content)}}import{jsx as WE}from"react/jsx-runtime";import{createContext as zE,useContext as GE}from"react";var UE=2,$E=UE+1,Nx=zE(2);function Mx({tier:e,children:o}){return WE(Nx.Provider,{value:e,children:o})}function mf(e){let o=GE(Nx);return $E+Math.max(0,e-o)}import{withStyleKind as KF}from"efficient-easel/style-clipboard";import{TEXT_CONTROL_KINDS as C$,SCALAR_TEXT_CONTROLS as v$}from"efficient-easel/draw";function at(e){for(let[o,t]of Object.entries(e))t&&typeof t=="object"&&!zo(t)&&KF(t,`section:${o}`);return e}function nI(){return null}function bf(e){if(!e.trim())throw new Error("noGlyph() needs a reason naming the ruling that decided it.");return h(nI,{},e)}function VF(e){return e.type===nI}function To(e){return VF(e)?void 0:e}function Pt(e,o){return l("{value} from {from}",{value:e,from:o})}function YF(){let{appState:e}=ta(a=>a),o=e.data.root?.props??{},{mode:t,pageWidth:r}=Mo(o,"full");return t==="page"?Pt(`${r}px`,l("the page")):t==="contained"?Pt(l("Contained"),l("the page")):Pt(l("Full"),l("the page"))}function XF(){let{blockGap:e}=V();return e===null?l("this container's own spacing"):Pt(`${e}px`,l("Site styles"))}function ZF({inherited:e,onReset:o,label:t}){return h(Ge,{words:Q()?.panel,label:l(t),changed:!e,detail:XF(),onReset:o})}function QF({inherited:e,onReset:o,label:t}){return h(Ge,{words:Q()?.panel,label:l(t),changed:!e,detail:YF(),onReset:o})}function or({value:e,onChange:o,label:t,placeholder:r,hint:a,multiline:n,hideable:s=!0,markup:i=!0}){let{text:f,hidden:u}=rt(e),p=If(null),m=If(null),x=v=>o(s?{text:v,hidden:u}:v),I=()=>o({text:f,hidden:!u}),b=s&&u,C=jE(),w=a?a1(a)?h("span",{className:"sf-hint-keep sf-hint-while-typing",children:l(a)}):h(Rp,{children:l(a)}):void 0,k=u?l("Show {label} on the slide",{label:l(t)}):l("Hide {label} on the slide",{label:l(t)});return h(ie,{label:l(t),icon:h(TF,{}),htmlFor:C,className:b?"is-hidden":void 0,hint:w,action:s?h(aI,{content:k,children:h("button",{type:"button",className:"sf-field-eye","aria-pressed":u,"aria-label":k,onClick:I,children:u?h(Hx,{name:"eye-off",size:14}):h(Hx,{name:"eye",size:14})})}):void 0,children:ot("div",{className:"sf-copybox",children:[i&&h(wi,{target:n?m:p,value:f,onChange:x}),n?h("textarea",{id:C,ref:m,value:f,placeholder:r===void 0?void 0:l(r),onChange:v=>x(v.target.value)}):h("input",{id:C,ref:p,type:"text",value:f,placeholder:r===void 0?void 0:l(r),onChange:v=>x(v.target.value)})]})})}function h$(e,o){return{...e,[XE]:o}}function g$(e){let o=e[Ho];if(!o)throw new Error("withOffPage: the field holds no authored text");return{...e,[Ho]:{...o,offPage:!0}}}function jn(e){return!e||typeof e!="object"?!1:e[Ho]?.offPage===!0}var lI="sfPanelOnly";function b$(e){if(!e[Ho])throw new Error("withPanelOnly: the field holds no authored text");return{...e,[lI]:!0}}function sI(e){return!!e&&typeof e=="object"&&e[lI]===!0}function y$(e){let o=e[Ho];if(!o)throw new Error("withIdentifier: the field holds no authored text");return{...e,[Ho]:{...o,identifier:!0}}}function w$(e,o){if(!e[Ho])throw new Error("inOwnBox: the field holds no authored text");let{[qF]:t,...r}=e;return{...r,[ki]:!0,render:o}}var JF=new Set(jF),tr=(e,o)=>{let t={...o,[Ho]:e};if(!JF.has(e.control))return t;let r=o.render;return{...ra(t,"authored-copy"),render:a=>h(im,{name:a.name,children:r(a)})}},k$="Everything else on this block comes from the linked post. Unlink it to edit by hand.",e1={field:"source.slug",set:!0},T$={not:e1},o1="Select a word, then press the highlighter.",t1="A short name so a link can jump straight to this section, like yoursite.com/page#about.",r1=new Set([o1]),a1=e=>r1.has(e);function E$(e,o,t){return tr({control:"text",label:e,placeholder:o,hint:t},{type:"custom",render:({value:r,onChange:a})=>h(or,{value:r,onChange:a,label:e,placeholder:o,hint:t})})}function F$(e,o,t){return tr({control:"textarea",label:e,placeholder:o,hint:t},{type:"custom",render:({value:r,onChange:a})=>h(or,{value:r,onChange:a,label:e,placeholder:o,hint:t,multiline:!0})})}function n1(e,o,t){return tr({control:"plainText",label:e,placeholder:o,hint:t},{type:"custom",render:({value:r,onChange:a})=>h(or,{value:r,onChange:a,label:e,placeholder:o,hint:t,hideable:!1,markup:!1})})}function P$(e,o,t){return tr({control:"copyText",label:e,placeholder:o,hint:t},{type:"custom",render:({value:r,onChange:a})=>h(or,{value:r,onChange:a,label:e,placeholder:o,hint:t,hideable:!1})})}function L$(e){return{type:"custom",[VE]:{label:e},render:({value:o,onChange:t})=>h(jm,{value:KE(o),onChange:t,label:e})}}function O$(e,o,t){return tr({control:"plainTextarea",label:e,placeholder:o,hint:t},{type:"custom",render:({value:r,onChange:a})=>h(or,{value:r,onChange:a,label:e,placeholder:o,hint:t,multiline:!0,hideable:!1})})}var iI={Design:ZE,Animation:jx};function fI(e,o){return e.includes("Design")?o!=="Design":null}function l1({label:e}){return h(PF,{title:l(e),level:mf(1)})}function s1({level:e,label:o}){return e===1?h(l1,{label:o}):h(rr,{label:o})}function cI(e,o){return{type:"custom",[gf]:{label:e,level:o},render:()=>h(s1,{level:o,label:e})}}function De(e){return cI(e,2)}function R$(e){return{type:"custom",render:()=>h(i1,{text:e})}}function i1({text:e}){return h("p",{className:"sf-note",children:l(e)})}function A$(e){return cI(e,1)}function B$(e){return zo(e)!==null&&e?.tabs!==void 0}var Wx=new Map;function Kn(e,o){let t=`${e}\0${o?o.join(""):""}`,r=Wx.get(t)??{type:"custom",tabs:o,[gf]:{label:e,level:1},bucket:e,marker:!0,render:()=>h(Wo,{})};return Wx.set(t,r),r}var zx=new Map;function yf(e){let o=zx.get(e)??{type:"custom",[gf]:{label:e,level:1},designGroup:e,marker:!0,...e==="Content"?{}:{fold:e},render:()=>h(Wo,{})};return zx.set(e,o),o}function f1(e){let o=e;return o?.marker===!0&&typeof o.fold=="string"?o.fold:null}function dI(e,o){return f1(e)===o?e:{...e,marker:!0,fold:o,render:()=>h(Wo,{})}}function uI(e){let o=e;if(o.marker===!0&&o.fold===void 0)return e;let{fold:t,...r}=e;return{...r,marker:!0,render:()=>h(Wo,{})}}function rr({label:e}){return h(LF,{title:l(e),level:mf(2)})}function pI({swatches:e,current:o,onPick:t,names:r}){let a=e.find(i=>i.toLowerCase()===o.toLowerCase()),n=a?r?.[a]:void 0,s=n?l(n):o;return ot("div",{className:"sf-swatches",children:[e.map(i=>{let f=r?.[i]?l(r[i]):i;return h(aI,{content:f,children:h("button",{type:"button","aria-pressed":o.toLowerCase()===i.toLowerCase(),className:`sf-swatch ${o.toLowerCase()===i.toLowerCase()?"is-active":""}`,style:{background:i},onClick:()=>t(i),"aria-label":f})},i)}),h("span",{className:"sf-swatch-hex",children:s})]})}function _$(e,o){return{type:"custom",render:({value:t,onChange:r})=>{let a=Cx(t,o);return h(ie,{label:l(e),icon:h(oF,{}),changed:!a,action:h(Ge,{words:Q()?.panel,label:l(e),changed:!a,detail:l("the theme's section background"),onReset:()=>r(Nn)}),children:pI({swatches:yx,current:a?Dn:t??o??"",onPick:r,names:Sx})})}}}function c1(e,o){return{type:"custom",render:({value:t,onChange:r})=>{let a=t,n=kx(a,o);return h(ie,{label:l(e),icon:h(mF,{}),changed:!n,action:h(Ge,{words:Q()?.panel,label:l(e),changed:!n,detail:l("the theme's image stage"),onReset:()=>r(Jr)}),children:pI({swatches:vx,current:n?Qt:tf(a,o),onPick:r,names:wx})})}}}function Vn(e=t=>t,o){return at({_gSectionTheme:De(Dp),sectionAccent:{type:"custom",render:({value:t,onChange:r})=>h(Am,{value:e(t),onChange:r,followLabel:o})}})}function je({min:e,max:o,step:t,value:r,onChange:a,suffix:n="",readout:s=!0,notch:i,ariaLabel:f,disabled:u=!1}){let p=i!==void 0&&Number.isFinite(i)&&i>=e&&i<=o;return h("div",{className:p?"sf-slider has-notch":"sf-slider",style:p?{"--sf-notch":(i-e)/(o-e)}:void 0,children:h($F,{min:e,max:o,step:t,value:r,suffix:n||void 0,showInput:s,label:f===void 0?void 0:l(f),disabled:u,size:"sm",className:"sf-slider-track",onChange:m=>{m!==null&&m!==r&&a(m)}})})}function er(e,o,t,r,a,n,s="",i){return{type:"custom",render:f=>h(ie,{label:l(e),icon:To(o),action:i?i("storedValue"in f?f.storedValue:f.value,f.onChange):void 0,children:je({min:t,max:r,step:a,value:typeof f.value=="number"?f.value:n,suffix:s,ariaLabel:e,onChange:f.onChange})})}}function mI(e,o){let{min:t,max:r,step:a=1,unsetLabel:n,hint:s,restTrack:i,unsetMark:f,icon:u}=o;return{type:"custom",render:({value:p,onChange:m})=>{let x=typeof p=="number"?p:null,I=x===null;return h(ie,{label:l(e),icon:u?To(u):void 0,value:I?f||n===void 0?void 0:l(n):`${x}px`,changed:!I,action:f?qx(f,{changed:!I,onReset:()=>m(null)}):h(Ge,{words:Q()?.panel,label:l(e),changed:!I,onReset:()=>m(null)}),hint:typeof s=="string"?l(s):s,children:i?i({min:t,max:r,step:a,px:x,label:e,onChange:m}):je({min:t,max:r,step:a,value:x??t,readout:!1,ariaLabel:e,onChange:m})})}}}function D$(e){let o=er("Gap",h(Vx,{}),Jo.min,Jo.max,Jo.step,Zt[e],"px",(t,r)=>h(ZF,{inherited:!of(e,t),onReset:()=>r(void 0),label:"Gap"}));return{type:"custom",[hx]:e,render:t=>o.render({...t,value:Qr(e,t.value,t.field?.siteGap),storedValue:t.value,onChange:r=>t.onChange(r)})}}var Yn="Corners";function Sf(e){return{type:"custom",render:({value:o,onChange:t})=>{let r=typeof o=="number"&&Number.isFinite(o)?o:null,a=r!==null;return h(ie,{label:l(Yn),icon:h(lF,{}),changed:a,action:qx(e.mark,{changed:a,onReset:()=>t(null)}),hint:e.hint,children:h(d1,{tier:e,px:r,onRadius:t})})}}}function Xn(e){let o=null;try{o=hf()}catch{o=null}return[o?.values?.[e],t=>o?.onChange(e,t)]}function d1({tier:e,px:o,onRadius:t}){let r=e.useFollowed(),a=e.useClosedReason?e.useClosedReason():null,[n,s]=Xn(e.sidesKey),i=Bo(n)??[...ht];return h(zF,{label:l(Yn),value:i,corners:pp,onChange:f=>{let u=Bo(f)??[];s(u.length===ht.length?null:u)},radius:o,onRadiusChange:t,radiusMin:lo,radiusMax:mt,radiusStep:e.step??1,radiusPlaceholder:String(r),disabled:a!==null,disabledReason:a??void 0})}function xI(){return ra({type:"custom",render:()=>h(qn,{})},"always")}function u1({label:e,changed:o=!1,onReset:t=()=>{}}){let{cornerRadiusPx:r}=V(),a=typeof r=="number"?`${r}px`:l("not set");return h(Ge,{words:Q()?.panel,label:l(e),changed:o,detail:r==null?l("the built-in corners"):Pt(a,l("Site styles")),onReset:t})}function p1(){let{cornerRadiusPx:e}=V();return typeof e=="number"?e:lo}function m1(){return Sf({sidesKey:"sectionCornerSides",useFollowed:p1,useClosedReason:()=>hI()?l(II):null,mark:h(u1,{label:Yn}),hint:h(x1,{})})}var II="This section runs edge to edge, so its corners sit off the page. Set Width to Content width to use them.";function hI(){return uf(Eo())}function x1(){return h(Wo,{children:hI()?II:"Follows Site styles \u25B8 Basics \u25B8 Corners until you set a number here."})}function Zn(){return at({_gShape:De("Shape"),sectionCorners:m1(),sectionCornerSides:xI(),sectionBorder:Gx("desktop"),sectionBorderPhone:Gx("mobile")})}var I1=()=>({width:l("Border width"),sides:{top:l("Border top"),right:l("Border right"),bottom:l("Border bottom"),left:l("Border left")},style:l("Border style"),styles:{solid:l("Solid"),dashed:l("Dashed"),dotted:l("Dotted")},color:l("Border color"),unit:"px"});function h1(e){let o=Object.fromEntries(Object.entries(e).filter(([,t])=>t!=null&&t!==""));return Object.keys(o).length?o:void 0}function g1(){let e;try{let o=Je(V().theme);e=o.themes[o.selected]?.line}catch{e=void 0}return e||Tu.line}function b1({value:e,onChange:o,tier:t}){let[r]=Xn("sectionBorder"),a=g1(),n=e&&typeof e=="object"?e:{},s=t==="mobile"?r&&typeof r=="object"?r:{}:{},[i,f]=$n(()=>DF(n,s)),u=I1();return h(ie,{label:l("Border"),icon:h(tF,{}),action:h(oI,{each:i,label:l("Each side"),onChange:f}),children:h(OF,{label:l("Border"),value:n,each:i,onChange:p=>o(h1(p)),placeholder:{sides:_F(s),style:s.style??"solid",color:s.color||a},presets:[a],words:u,max:20})})}function Gx(e){return _e(e,{type:"custom",render:({value:o,onChange:t})=>h(b1,{value:o,onChange:t,tier:e})})}function Qn(){return{_gMotion:De("Motion"),sectionAnimation:wf("Entrance",h(jx,{}),[...Mp],Ii)}}function Cf(){let e=null;try{let{appState:o,selectedItem:t}=ta(a=>a),r=t?.props?.id?String(t.props.id):void 0;e=r?gi(o?.data,r):null}catch{e=null}return e!==null&&uf(e)}function gI(e){let{cornerRadiusPx:o}=V(),t=Cf(),r=typeof o=="number"?o:e,a=null;try{let{appState:s,selectedItem:i}=ta(u=>u),f=i?.props?.id?String(i.props.id):void 0;a=f?gi(s?.data,f):null}catch{a=null}if(t||!a)return r;let n=a.sectionCorners;return ai(n)?n:r}function y1({label:e,changed:o=!1,onReset:t=()=>{}}){let r=Cf(),a=gI(lo),n=r?"Site":"Section";return h(Ge,{words:Q()?.panel,label:l(e),changed:o,detail:Pt(`${a}px`,r?l("Site styles"):l("the section")),onReset:t})}function S1(){return h(Wo,{children:Cf()?l("The section is full width, so this card follows Site styles \u25B8 Basics \u25B8 Corners."):l("Follows the section's Corners until you set a number here.")})}function C1(){return Sf({sidesKey:"cardCornerSides",useFollowed:()=>gI(lo),mark:h(y1,{label:Yn}),hint:h(S1,{})})}function v1(){return{type:"custom",render:()=>h(yp,{})}}function N$(){return{_gShape:De("Shape"),cardCorners:C1(),cardCornerSides:xI(),cardCornersApplyAll:v1()}}function M$(){return tt("Justify",h(eF,{}),Xi,Xi[0].value)}function H$(){return tt("Item alignment",h(QE,{}),ix,"stretch")}function W$(){return tt(fx,h(FF,{}),Zi,Zi[0].value)}function z$(){return{type:"custom",render:({value:e,onChange:o})=>{let t=_n.find(r=>r.value===e)??_n[0];return h(ie,{label:l(Qi),icon:h(Kx,{}),value:l(t.label),children:h(rI,{className:"sf-gallery-layouts",label:l(Qi),value:t.value,onChange:o,options:_n.map(r=>({value:r.value,label:l(r.label),picture:h("span",{className:"sf-gallery-pic",children:w1(r.weights).map((a,n)=>h("i",{style:{gridColumn:`span ${a}`}},n))})}))})})}}}function w1(e){if(!e)return[3,4];let o=e.reduce((t,r)=>t+r,0);return e.map(t=>Math.round(t/o*12))}function G$(){return tt(ux,h(Vx,{}),ef,ef[0].value)}function U$(){return er(cx,h(yF,{}),Ji,dx,1,Ji)}function $$(e){let o=wf(rx,bf("`Direction` names how a container's children run \u2014 a MODIFIER, not a thing. doc/naming.md N10.1 gives the idea a dash in its Glyph column; editor-shell's own `direction` meaning says the bare row is CORRECT and not an omission (SS seat, 2026-09-11)."),nx(e),Bn(e,void 0));return{type:"custom",render:t=>o.render({...t,value:Bn(e,t.value),onChange:r=>t.onChange(r)})}}function q$(e,o,t,r,a,n){return{type:"custom",render:({value:s,onChange:i})=>h(ie,{label:l(e),icon:h(ui,{noun:n}),action:h(Ge,{words:Q()?.panel,label:l(e),changed:!Ex(s),detail:l("the Text style in Site styles"),onReset:()=>i(Tx),defaultAction:{onPress:()=>i(Wn),title:l("Keep this section's own built-in size"),icon:h(rF,{})}}),children:je({min:o,max:t,step:r,value:typeof s=="number"?s:a,suffix:"px",ariaLabel:e,onChange:i})})}}function j$(){return{_gCellWidth:De("Cell width"),gridSpan:tt("Positions",h(Kx,{}),[{label:"Auto",value:""},...Array.from({length:cn},(e,o)=>({label:o===0?"1 position":`${o+1} positions`,value:String(o+1)}))],"")}}function Eo(){let e=null;try{e=ta(o=>o).selectedItem}catch{e=null}return e?.props??{}}function k1({min:e,max:o,step:t,px:r,label:a,onChange:n,desktopKey:s,fallback:i}){let f=Eo()[s],u=bn(void 0,f,i);return h(Wo,{children:je({min:e,max:o,step:t,value:bn(r,f,i),readout:!1,ariaLabel:a,notch:u,onChange:n})})}function T1({label:e,desktopKey:o,fallback:t,changed:r=!1,onReset:a=()=>{}}){let n=Eo()[o],s=bn(void 0,n,t);return h(Ge,{words:Q()?.panel,label:l(e),changed:r,detail:l("{value} on desktop",{value:`${s}px`}),onReset:a})}function E1(e){return mI(e.label,{icon:e.icon,min:e.min,max:e.max,step:e.step,unsetLabel:"Follows Desktop",unsetMark:h(T1,{label:e.label,desktopKey:e.desktopKey,fallback:e.fallback}),restTrack:o=>h(k1,{...o,desktopKey:e.desktopKey,fallback:e.fallback})})}function K$(e){return{type:"custom",render:({value:o,onChange:t})=>h(P1,{...e,value:o,onChange:t})}}function F1({label:e,icon:o,options:t,value:r,resolved:a,restWord:n,onChange:s}){let i=t.some(f=>f.value===r);return h(ie,{label:l(e),icon:To(o),action:h(Ge,{words:Q()?.panel,label:l(e),changed:i,detail:l("{value} on desktop",{value:l(n)}),onReset:()=>s(void 0)}),children:rl({options:t,value:i?r:a,onChange:f=>s(f),ariaLabel:e})})}function P1({label:e,icon:o,options:t,desktopKey:r,resolve:a,value:n,onChange:s}){let i=Eo()[r],f=a(void 0,i),u=t.find(p=>p.value===f)?.label??"";return h(F1,{label:e,icon:o,options:t,value:n,resolved:f,restWord:u,onChange:s})}var L1={Top:"Padding top",Bottom:"Padding bottom",Left:"Padding left",Right:"Padding right"},O1={Top:Jx,Bottom:Xx,Left:Zx,Right:Qx},R1=e=>{let o=O1[e];return h(o,{})};function V$(e={}){let o=e.keys?.top??"sectionPaddingTop",t=e.keys?.bottom??"sectionPaddingBottom",r=e.group!==!1,a=w=>L1[w],n=w=>er(a("Top"),h(Jx,{}),uo.min,uo.max,uo.step,w,"px"),s=(w,k,v,g=uo)=>_e("mobile",E1({label:a(w),icon:R1(w),desktopKey:k,min:g.min,max:g.max,step:g.step,fallback:v})),i=e.top??uo.min,f=e.bottom??uo.min,u="sectionPaddingLeft",p="sectionPaddingRight",m=e.sideBounds??uo,x=e.side??m.min,I=e.sidePhone??x,b=e.phone===!0,C=w=>b?_e("desktop",w):w;return at({...r?{_gSpacing:De("Padding")}:{},[o]:C(n(i)),...b?{[No(o)]:s("Top",o,i)}:{},...e.only==="top"?{}:{[t]:C(er(a("Bottom"),h(Xx,{}),uo.min,uo.max,uo.step,f,"px")),...b?{[No(t)]:s("Bottom",t,f)}:{}},...e.sides?{[u]:C(er(a("Left"),h(Zx,{}),m.min,m.max,m.step,x,"px")),...b?{[No(u)]:s("Left",u,I,m)}:{},[p]:C(er(a("Right"),h(Qx,{}),m.min,m.max,m.step,x,"px")),...b?{[No(p)]:s("Right",p,I,m)}:{}}:{}})}var oa=["top","right","bottom","left"],A1={top:"sectionPaddingTop",right:"sectionPaddingRight",bottom:"sectionPaddingBottom",left:"sectionPaddingLeft"},Ux=e=>typeof e=="number"?e:null;function B1(e,o,t){let r={};for(let a of oa)t[a]!==o[a]&&(r[e[a]]=t[a]??void 0);return r}function _1({tier:e,o}){let t=null;try{t=hf()}catch{t=null}let r=t?.values??{},a=e==="mobile"?o.phoneKeys:o.keys,n=Object.fromEntries(oa.map(u=>[u,Ux(r[a[u]])])),s=Object.fromEntries(oa.map(u=>[u,String(e==="mobile"?Ux(r[o.keys[u]])??o.fallback[u]:o.fallback[u])])),[i,f]=$n(()=>BF(n,s));return h(ie,{label:l("Padding"),icon:h(bF,{}),action:h(oI,{each:i,label:l("Each side"),onChange:f}),children:h(AF,{label:l("Padding"),each:i,value:n,placeholder:s,min:o.min,max:o.max,step:o.step,onChange:u=>{let p=B1(a,n,u);Object.keys(p).length&&t?.onChangeMany(p)},words:{sides:{top:l("Padding top"),right:l("Padding right"),bottom:l("Padding bottom"),left:l("Padding left")},vertical:l("Top and bottom"),horizontal:l("Left and right"),unit:"px"}})})}function Jn(e={}){let o={...A1,...e.keys},t={keys:o,phoneKeys:Object.fromEntries(oa.map(i=>[i,No(o[i])])),fallback:{top:0,right:0,bottom:0,left:0,...e.fallback},min:e.min??0,max:e.max??200,step:e.step??4},r=e.phone!==!1,a=i=>{let f={type:"custom",render:()=>h(_1,{tier:i,o:t})};return r?_e(i,f):f},n=()=>ra({type:"custom",render:()=>h(qn,{})},"always"),s=oa.filter(i=>i!=="top");return at({...e.group===!1?{}:{_gSpacing:De("Padding")},[t.keys.top]:a("desktop"),...r?{[t.phoneKeys.top]:a("mobile")}:{},...Object.fromEntries(s.map(i=>[t.keys[i],{...n(),reachedBy:t.keys.top}])),...r?Object.fromEntries(s.map(i=>[t.phoneKeys[i],_e("mobile",n())])):{}})}var $x=e=>typeof e=="number"?e:null;function D1(e,o,t){let r={};for(let a of["x","y"])t[a]!==o[a]&&(r[e[a]]=t[a]??void 0);return r}function N1({o:e}){let o=null;try{o=hf()}catch{o=null}let t=o?.values??{},r={x:$x(t[e.keys.x]),y:$x(t[e.keys.y])},a=l(e.label??"Position"),n=!!(r.x||r.y),s=u=>{let p=D1(e.keys,r,u);Object.keys(p).length&&o?.onChangeMany(p)},i=h(UF,{label:a,value:r,onChange:s,words:{x:l("Left and right"),y:l("Up and down"),unit:"px"},placeholder:{x:"0",y:"0"},min:e.min,max:e.max,step:e.step??1}),f=h(Ge,{words:Q()?.panel,label:a,changed:n,detail:"0 px, 0 px",onReset:()=>s({x:null,y:null})});return e.label===null?ot("div",{className:"sf-position-line",children:[i,f]}):h(ie,{label:a,icon:h(gF,{}),changed:n,action:f,children:i})}function Y$(e){return{[e.keys.x]:{type:"custom",render:()=>h(N1,{o:e})},[e.keys.y]:{...ra({type:"custom",render:()=>h(qn,{})},"always"),reachedBy:e.keys.x}}}var M1={contained:"Contained",page:"Page",full:"Full"},Un="Width";function el(e,o=Rx,t=!0){let r=o.map(a=>({label:Jt[a]??M1[a],value:a}));return at({...t?{_gWidth:De(Un)}:{},widthMode:{type:"custom",render:({onChange:a,field:n})=>h(ie,{label:l(Un),icon:h(EF,{}),action:t?h(QF,{inherited:n?.inherited??!1,onReset:()=>a(df),label:Un}):void 0,children:rl({options:r,value:n?.currentValue||e,onChange:a,ariaLabel:Un})})}})}function ol(){let e=r=>({type:"custom",render:({value:a,onChange:n})=>h(ie,{label:Xt,icon:To(h(xF,{})),action:r?r(n):void 0,children:rl({options:[{label:"Auto",value:"auto"},{label:"Fixed",value:"fixed"},{label:"Screen",value:"screen"}],value:["auto","fixed","screen"].includes(a)?a:"auto",onChange:n,ariaLabel:Xt})})}),o=()=>({type:"custom",render:({value:r,onChange:a,field:n})=>{let s=n?.unit==="%"?"%":"px",i=s==="%"?ji:qi;return h("div",{className:"sf-field",children:je({min:i.min,max:i.max,step:i.step,value:typeof r=="number"?r:i.fallback,suffix:s,ariaLabel:Xt,onChange:a})})}}),t=()=>wf("Unit",h(Yx,{}),[{label:"px",value:"px"},{label:"%",value:"%"}],"px");return at({_gHeight:De(Xt),sectionHeightMode:_e("desktop",e()),sectionHeightValue:_e("desktop",o()),sectionHeightUnit:_e("desktop",t()),sectionHeightModePhone:_e("mobile",e(r=>h(H1,{onClear:()=>r(void 0)}))),sectionHeightValuePhone:_e("mobile",o()),sectionHeightUnitPhone:_e("mobile",t())})}function H1({onClear:e}){let o=Eo(),t=Ki(o),r=Rn(o),a=l("{value} on desktop",{value:r.mode==="auto"?l("Auto"):`${r.value}${r.unit}`});return h(Ge,{words:Q()?.panel,label:l(Xt),changed:t,detail:a,onReset:e})}function vf(){let e=t=>({type:"custom",render:({value:r,onChange:a,id:n,name:s})=>h(W1,{value:r,onChange:a,labelId:`${n??s??"stickTop"}-label`,phone:t})}),o=()=>({type:"custom",render:({value:t,onChange:r})=>h("div",{className:"sf-field",children:je({min:Qo.min,max:Qo.max,step:Qo.step,value:typeof t=="number"?t:Qo.fallback,suffix:"px",ariaLabel:l("Distance from top"),onChange:r})})});return{_gStick:De(An),stickTop:_e("desktop",e(!1)),stickTopDistance:_e("desktop",o()),stickTopPhone:_e("mobile",e(!0)),stickTopDistancePhone:_e("mobile",o())}}function W1({value:e,onChange:o,labelId:t,phone:r}){let a=Eo(),n=Yi(a),s=r?n.phone:e===!0;return h(ie,{label:l(An),labelId:t,icon:To(h(vF,{})),action:ot(Wo,{children:[r?h(Ge,{words:Q()?.panel,label:l(An),changed:Vi(a),detail:l("{value} on desktop",{value:n.desktop?`${n.desktopDistance}px`:l("Off")}),onReset:()=>o(void 0)}):null,h(tI,{checked:s,onChange:o,ariaLabelledBy:t})]})})}function tl(){return{_gAnchor:De("Anchor"),anchor:n1("Anchor name","e.g. about",t1)}}function X$(e,o,t){return{type:"custom",render:({value:r,onChange:a,id:n,name:s})=>{let i=`${n??s??e}-datetime`,f=Date.parse(typeof r=="string"?r:"");return h(ie,{label:l(e),icon:o,htmlFor:i,hint:t===void 0?void 0:l(t),children:h(GF,{id:i,value:Number.isFinite(f)?new Date(f):null,onChange:u=>a(u?u.toISOString():"")})})}}}function Ft(e,o,t){return{type:"custom",render:({value:r,onChange:a,id:n,name:s})=>{let i=typeof r=="boolean"?r:o,f=`${n??s??e}-label`;return h(ie,{label:l(e),labelId:f,icon:t,action:h(tI,{checked:i,onChange:a,ariaLabelledBy:f})})}}}function Z$(){return{type:"custom",render:({value:e,onChange:o,id:t,name:r})=>{let a=`${String(t??r??"pageBackground")}-colour`;return h(ie,{label:l("Background"),icon:h(eI,{}),htmlFor:a,action:h(io,{id:a,label:"Background",value:pi(e),onChange:o})})}}}var Q$={follows:"fill"},J$={follows:"ink"};function e7(e,o,t){if(typeof o!="string"){let r=o.follows;return{type:"custom",render:({value:a,onChange:n})=>h(z1,{label:e,part:r,icon:t,value:a,onChange:n})}}return{type:"custom",render:({value:r,onChange:a})=>h(ie,{label:l(e),icon:t,action:io({value:r||o,onChange:a,label:e})})}}function z1({label:e,part:o,icon:t,value:r,onChange:a}){let n=Ou(V().theme),s=o==="fill"?n.fill:n.ink;return h(hn,{label:l(e),icon:t,value:r||"",inherited:s,resetTo:Pt(s.toUpperCase(),l("Site styles")),onChange:a,onReset:()=>a("")})}var G1=[{value:"0% 0%",label:"Top left"},{value:"50% 0%",label:"Top"},{value:"100% 0%",label:"Top right"},{value:"0% 50%",label:"Left"},{value:"50% 50%",label:"Center"},{value:"100% 50%",label:"Right"},{value:"0% 100%",label:"Bottom left"},{value:"50% 100%",label:"Bottom"},{value:"100% 100%",label:"Bottom right"}];function bI({label:e,value:o,onChange:t,points:r=G1}){let a=r.map(n=>({...n,label:l(n.label),...n.title?{title:l(n.title)}:null}));return h(WF,{label:l(e),value:o,points:a,onChange:t})}function o7(){return ra({type:"custom",render:()=>h(qn,{})},"always")}var U1=fi([]);function t7(e,{stacking:o,fallback:t=dn}){return{type:"custom",render:({value:r,onChange:a})=>{let n=yo.includes(r)?r:t;return o?h($1,{label:e,value:n,onChange:a}):yI({label:e,value:n,onChange:a,points:U1})}}}function $1({label:e,value:o,onChange:t}){let{appState:r,selectedItem:a}=ta(i=>i),n=a?.props?.id?String(a.props.id):void 0,s=n?di(r?.data,n):[];return yI({label:e,value:o,onChange:t,points:fi(s,n)})}function yI({label:e,value:o,onChange:t,points:r}){let a=r.find(n=>n.disabled);return h(ie,{label:l(e),icon:h(SF,{}),hint:a?.title?l(a.title):void 0,children:bI({label:e,value:gt(o),onChange:t,points:r})})}var r7={top:h(cF,{}),right:h(fF,{}),bottom:h(sF,{}),left:h(iF,{})};function a7(e,o,t,r,a,n){let s=p=>o.find(m=>m.value===p),i=p=>({value:p,label:"",disabled:!0,title:r}),f=p=>{let m=o.find(I=>I.cell===p);if(!m)return i(`missing-${p}`);let x=n?.[p];return x?{value:m.value,label:m.label,icon:x}:{value:m.value,label:m.label}},u=[i("corner-top-left"),f("top"),i("corner-top-right"),f("left"),i("centre"),f("right"),i("corner-bottom-left"),f("bottom"),i("corner-bottom-right")];return{type:"custom",render:({value:p,onChange:m})=>{let x=o.some(I=>I.value===p)?p:t;return h(ie,{label:l(e),icon:a,value:s(x)?.label?l(s(x).label):"",children:bI({label:e,value:x,onChange:m,points:u})})}}}var q1="\0note";function tt(e,o,t,r,a){return{type:"custom",options:t,fallback:r,...a?{note:a}:{},render:({value:n,onChange:s,field:i})=>{let f=i.options??t,u=i.fallback??r,p=f.some(m=>m.value===n)?n:u;return h(ie,{label:l(e),icon:To(o),children:h(NF,{value:p,ariaLabel:l(e),onChange:s,options:[...a?[{label:l(a),value:q1,disabled:!0}]:[],...f.map(m=>({label:l(m.label),value:m.value}))]})})}}}function n7(e,o,t){return{type:"custom",options:o,render:({value:r,onChange:a,field:n})=>h(hm,{label:e,options:(n.options??o).map(s=>({...s,label:l(s.label)})),value:Array.isArray(r)?r:[],onChange:a,...t?{emptyLabel:l(t)}:{}})}}function l7(e,o={}){return{type:"custom",render:({value:t,onChange:r})=>{let a={value:t,onChange:r,...o};return h(e,{...a})}}}function rl({options:e,value:o,onChange:t,ariaLabel:r,disabled:a=!1}){return h(RF,{options:e.map(n=>n.picture?{id:n.value,label:n.picture,title:l(n.title??n.label)}:{id:n.value,label:l(n.label),title:n.title===void 0?void 0:l(n.title)}),value:o,onChange:t,ariaLabel:l(r),disabled:a})}var s7=[{label:"Image",value:"image"},{label:"Video",value:"video"}];function wf(e,o,t,r){let a=t.map(n=>typeof n=="string"?{label:n,value:n}:n);return{type:"custom",render:({value:n,onChange:s,field:i})=>h(ie,{label:l(e),icon:To(o),children:rl({options:a,value:a.some(f=>f.value===n)?n:n||i?.currentValue||r,onChange:s,ariaLabel:e})})}}function i7(e,o,t,r={}){return{type:"custom",[YE]:!0,render:({value:a,onChange:n})=>h(xm,{value:a||"",onChange:n,label:e,accept:o,placeholder:t,focusKey:r.focus,focusWhen:r.focusWhen})}}function f7({value:e,onChange:o,label:t}){let r=e||{},a=!!r.pending,n=a?"var(--fg-dim, #888)":r.ok?"#1d9e75":"#d85a30",s=(i,f)=>o({...r,[i]:f===""?void 0:Number(f)});return ot(ie,{label:l(t),icon:h(xf,{}),children:[h("button",{type:"button",disabled:a,onClick:()=>o({...r,pending:!0,ok:!1,status:"Finding\u2026"}),style:{width:"100%",display:"flex",alignItems:"center",justifyContent:"center",gap:6,padding:"8px 10px",fontSize:13,cursor:a?"default":"pointer",opacity:a?.6:1,border:"1px solid var(--border-strong, #ccc)",borderRadius:6,background:"transparent",color:"inherit"},children:a?l("Finding\u2026"):l("Find coordinates")}),r.status&&h("div",{style:{marginTop:6,fontSize:12,lineHeight:1.4,color:n},children:l(r.status)}),h("div",{style:{marginTop:6,fontSize:11,color:"var(--fg-dim, #999)"},children:l("Coordinates from OpenStreetMap")}),h("button",{type:"button",onClick:()=>o({...r,manual:!r.manual}),style:{marginTop:8,padding:0,border:"none",background:"none",font:"inherit",fontSize:12,color:"var(--sf-accent, #2563eb)",cursor:"pointer",textDecoration:"underline"},children:r.manual?l("Hide manual coordinates"):l("Enter coordinates manually")}),r.manual&&ot("div",{style:{marginTop:8,display:"grid",gap:8},children:[h(ie,{label:l("Latitude"),icon:h(xf,{}),children:h("input",{type:"number",step:"any",placeholder:l("e.g. {example}",{example:"34.0990198"}),value:typeof r.lat=="number"?r.lat:"",onChange:i=>s("lat",i.target.value)})}),h(ie,{label:l("Longitude"),icon:h(xf,{}),children:h("input",{type:"number",step:"any",placeholder:l("e.g. {example}",{example:"-117.9842833"}),value:typeof r.lng=="number"?r.lng:"",onChange:i=>s("lng",i.target.value)})})]})]})}function j1(e,o){return o===null||o<0||o>=e.length?"":e[o]?.text??""}function K1(e,o,t){let r=e.map(a=>({text:a?.text??""}));return o===null||o<0||o>=e.length?r:r.map((a,n)=>n===o?{text:t}:a)}function V1(e,o,t){if(t===null||t>=o.length)return null;for(let r=0;r<t;r+=1)if(e[r]!==o[r])return null;return e[t]!==o[t]&&o.includes(e[t])||e[t]!==o[t]&&o.length!==e.length?null:t}var kf={label:"Ticker items",icon:h(hF,{})};function c7(e,o,t,r){return{type:"custom",[Ho]:{control:"textList",label:e,placeholder:t,itemKey:"text",rendering:r},render:({value:a,onChange:n})=>h(Tf,{label:e,icon:To(o),items:Array.isArray(a)?a:[],placeholder:t,onChange:n,markup:r==="markup"})}}function Tf({label:e,icon:o,items:t,placeholder:r,onChange:a,markup:n=!1}){let s=If(null),[i,f]=$n(null),u=m=>m.map(x=>({text:x?.text??""})),p=m=>{let x=V1(t,m,i);x===null&&(s.current=null),f(x),a(u(m))};return h(MF,{label:l(e),icon:o,noun:l("item"),items:t,onChange:p,newItem:()=>({text:""}),open:null,onOpen:()=>{},renderItem:()=>null,above:n?h(wi,{target:s,value:j1(t,i),onChange:m=>a(K1(t,i??-1,m)),disabled:i===null,label:i===null?l("Formatting \u2014 click a row first"):l("Formatting \u2014 row {n}",{n:i+1})}):void 0,renderRow:(m,x,I)=>h("input",{type:"text",className:n&&i===x?"sf-list-marking":void 0,value:m?.text??"",placeholder:l(r),"aria-label":l("{label} {n}",{label:l(e),n:x+1}),onChange:b=>I({text:b.target.value}),onFocus:b=>{s.current=b.currentTarget,f(x)}})})}function SI(e,o){let t=`${e.label} \u2014 row ${o+1}`;return tr({control:"plainText",label:t,placeholder:e.placeholder,offPage:e.offPage},{type:"custom",render:({value:r,onChange:a})=>h(or,{value:r,onChange:a,label:l("{label} \u2014 row {n}",{label:l(e.label),n:o+1}),placeholder:e.placeholder,hideable:!1,markup:e.rendering==="markup"})})}function CI(e){return{_gCards:De("Cards"),coverIndex:tt("Cover image",h(IF,{}),cm,String(1),e?.coverHint??"A card's opening picture \u2014 a card pinned to a finish keeps its own."),imageBackground:c1("Image background",Hn),cardImage:X1(),spinOnHover:Ft("Rotate on hover",e?.spinDefault??!0,h(wF,{}))}}function vI(){return{outline:tt("Card outline",h(kF,{}),Oi,Pi),indexBadge:tt("Card number",h(Yx,{}),Li,Fi),showBadge:Ft("Product badge",!0,h(ui,{noun:"tag"}))}}function wI(e){let o=e&&"bottomDefault"in e?e.bottomDefault:!0,t=e&&"defaults"in e?e.defaults:{showCardSizes:o,showCardBuy:o,showCardPage:o};return{_gShowOnCard:De("Show on a card"),showCardPrice:Ft("Price",!0,h(dF,{})),showCardFinishes:Ft("Finish swatches",!0,h(uF,{})),showCardSizes:Ft("Sizes",t.showCardSizes,h(CF,{})),showCardBuy:Ft("Buy button",t.showCardBuy,h(aF,{})),showCardPage:Ft("Page button",t.showCardPage,h(eI,{}))}}function d7(e,o="display"){let t=No(o);return{[o]:_e("desktop",{type:"custom",render:({value:r,onChange:a})=>h(kI,{parts:e,changed:Wp(r),shown:n=>In(r,n),onPress:(n,s)=>a(Gp(r,n,s)),onReset:()=>a(void 0)})}),[t]:_e("mobile",{type:"custom",render:({value:r,onChange:a})=>h(Y1,{parts:e,desktopKey:o,value:r,onChange:a})})}}function kI({parts:e,changed:o,shown:t,onPress:r,onReset:a,detail:n}){let s=l("Display");return h(ie,{label:s,icon:h(JE,{}),changed:o,action:h(Ge,{words:Q()?.panel,label:s,changed:o,detail:n,onReset:a}),children:h(HF,{label:s,items:e.map(i=>({id:i.id,label:l(i.label),shown:t(i.id)})),onChange:r})})}function Y1({parts:e,desktopKey:o,value:t,onChange:r}){let a=Eo()[o];return h(kI,{parts:e,changed:zp(t),shown:n=>bi(a,t,n),onPress:(n,s)=>r(Up(t,n,s)),onReset:()=>r(yn),detail:l("the same as Desktop")})}function X1(){return mI("Card image",{min:lo,max:mt,step:Sp,hint:"Rounds the picture. The card's own corner is in Site styles."})}function u7(){return Sf({sidesKey:"cornerSides",step:Cp,useFollowed:()=>lo,mark:h(Z1,{label:vp}),hint:l("Rounds the picture. Left alone it stays square.")})}function Z1({label:e,changed:o=!1,onReset:t=()=>{}}){return h(Ge,{words:Q()?.panel,label:l(e),changed:o,onReset:t})}function p7(){return{type:"custom",render:({value:e,onChange:o})=>h(Q1,{value:typeof e=="string"?e:"",onChange:o})}}function Q1({value:e,onChange:o}){let[t,r]=$n(null),a=li.filter(s=>t===null||_o[s].across===t),n=e&&e in _o?_o[e]:null;return ot(Wo,{children:[h(ie,{label:l("Photos in a row"),icon:h(nF,{}),children:ot("div",{className:"sf-gallery-filter",children:[h("button",{type:"button","aria-pressed":t===null,onClick:()=>r(null),children:l("All")}),kp.map(s=>h("button",{type:"button","aria-pressed":t===s,onClick:()=>r(s),children:s},s))]})}),h(ie,{label:l("Layout"),icon:h(pF,{}),value:n?l(n.label):l("Not chosen"),hint:l("{n} of {total} layouts",{n:a.length,total:li.length}),children:h(rI,{className:"sf-gallery-layouts",label:l("Layout"),value:e,onChange:o,onClear:()=>o(""),options:a.map(s=>({value:s,label:l(_o[s].label),picture:h("span",{className:"sf-gallery-pic",children:_o[s].desktop.map(([i,f],u)=>h("i",{style:{gridColumn:`span ${i}`,gridRow:`span ${f}`}},u))})}))})})]})}import{jsx as al,Fragment as J1,jsxs as TI}from"react/jsx-runtime";import{Button as EI,Dialog as eP}from"efficient-shell/ui";function oP(e){return so("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 FI({count:e,onCancel:o,onConfirm:t}){return TI(eP,{open:!0,onClose:o,role:"alertdialog",size:"sm",title:l("Clear this site\u2019s colors?"),footer:TI(J1,{children:[al(EI,{variant:"secondary",onClick:o,children:l("Cancel")}),al(EI,{variant:"danger",onClick:t,children:l("Clear colors")})]}),children:[al("p",{children:oP(e)}),al("p",{className:"mt-2 font-medium",children:l("This cannot be undone.")})]})}var sP=bf("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"),iP="Reset color",fP={selected:0,themes:[]};function cP(e){e(fP)}function OI({value:e,onChange:o}){let t=e?.themes??[],r=t.length===0,a=Je(e),[n,s]=LI(!1),i=nP(),[f,u]=LI(null),p=(k,v)=>{o({...a,themes:a.themes.map((g,y)=>y===k?v:g)})},m=Ut(a).accent,x=new Set(a.themes.map(k=>k.brandInk).filter(Boolean)),I=Eu.filter(k=>!x.has(k)).map(k=>Fu(m,k)),b=[...a.themes,...I],C=k=>{if(k<a.themes.length)return o({...a,selected:k});let v=[...a.themes,b[k]];o({...a,themes:v,selected:v.length-1})},w=()=>{let k=[...a.themes,{...go(a.themes[a.selected])}];o({...a,themes:k,selected:k.length-1}),u(k.length-1)};return PI(tP,{children:[r?null:ar(aP,{label:l(iP),icon:To(sP),labelId:"sf-theme-reset",action:ar(rP,{label:l("all theme colors"),words:i.panel,changed:!0,onReset:()=>s(!0)})}),n&&ar(FI,{count:t.length,onCancel:()=>s(!1),onConfirm:()=>{s(!1),cP(o)}}),ar("div",{className:"sf-theme-list",role:"radiogroup","aria-label":l("Theme"),children:b.map((k,v)=>ar(wn,{index:v,colors:k,selected:v===a.selected,open:f===v&&v<a.themes.length,editable:v<a.themes.length,onPick:()=>C(v),onEdit:()=>u(g=>g===v?null:v),onChangeColors:g=>p(v,g)},v))}),PI("button",{type:"button",onClick:w,className:"sf-theme-add",children:[ar(lP,{size:12}),l("Add new theme")]})]})}import{jsx as nl}from"react/jsx-runtime";import{SettingsDefaultReset as dP,SettingsField as uP}from"efficient-easel/panel";import{SquareIcon as pP}from"efficient-easel/icons";var mP="Applies to panels, cards, inputs and buttons. Round things \u2014 color swatches, switches, status dots \u2014 stay round.",Ef="Corners";function RI({value:e,onChange:o,showHint:t=!0}){let r=e===null;return nl(uP,{label:l(Ef),icon:nl(pP,{}),value:r?l("Default"):`${e}px`,changed:!r,action:nl(dP,{words:Q()?.panel,label:l(Ef),changed:!r,detail:l("the built-in corners"),onReset:()=>o(null)}),hint:t?l(mP):void 0,children:nl(je,{min:lo,max:mt,step:1,value:e??lo,readout:!1,ariaLabel:l(Ef),onChange:o})})}import{jsx as aa}from"react/jsx-runtime";import{SettingsDefaultReset as xP,SettingsField as IP,SettingsSegmented as hP}from"efficient-easel/panel";import{ShadowIcon as gP}from"efficient-easel/icons";var Ff={none:"None",soft:"Soft",lifted:"Lifted"},bP="Applies to cards \u2014 products, brands, journal entries and filter cells. Round things like swatches and status dots are never shadowed.",yP={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)"},SP={labelsPx:90.25,widestLabelPx:34.6};function AI({value:e,onChange:o,showHint:t=!0}){let r=e===null,a=e??Ks;return aa(IP,{label:l("Card shadow"),icon:aa(gP,{}),value:l(Ff[a]),changed:!r,action:aa(xP,{words:Q()?.panel,label:l("Card shadow"),changed:!r,detail:l(Ff[Ks]),onReset:()=>o(null)}),hint:t?l(bP):void 0,children:aa(hP,{options:Nu.map(n=>({id:n,label:l(Ff[n]),icon:aa("span",{className:"sf-shadow-chip",style:{boxShadow:yP[n]}})})),value:a,ariaLabel:l("Card shadow"),fit:SP,onChange:o})})}import{jsx as BI}from"react/jsx-runtime";import{ShadowIcon as CP}from"efficient-easel/icons";var vP="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 _I({value:e,onChange:o,showHint:t=!0}){let r=e===null;return BI(hn,{label:l("Shadow color"),icon:BI(CP,{}),value:e??"",inherited:Ys,resetTo:Ys,onChange:o,onReset:()=>o(null),hint:t?l(vP):void 0})}import{jsx as ll}from"react/jsx-runtime";import{SettingsDefaultReset as wP,SettingsField as kP}from"efficient-easel/panel";import{AlignSeparateIcon as TP}from"efficient-easel/icons";var EP="The space between the blocks inside a row, a grid or a box. Default means each one keeps the spacing it already has.",Pf="Block gap",FP=Zt.Grid;function DI({value:e,onChange:o,showHint:t=!0}){let r=e===null;return ll(kP,{label:l(Pf),labelId:"sf-block-gap",icon:ll(TP,{}),value:r?l("Default"):`${e}px`,changed:!r,action:ll(wP,{words:Q()?.panel,label:l(Pf),changed:!r,detail:l("each block's own spacing"),onReset:()=>o(null)}),hint:t?l(EP):void 0,children:ll(je,{min:Et.min,max:Et.max,step:Et.step,value:r?FP:e,readout:!1,ariaLabel:l(Pf),onChange:o})})}import{jsx as sl}from"react/jsx-runtime";import{SettingsDefaultReset as PP,SettingsField as LP,SettingsSegmented as OP}from"efficient-easel/panel";import{HoverIcon as RP}from"efficient-easel/icons";var Lf={none:"None",lift:"Lift",highlight:"Highlight"},AP="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 NI({value:e,onChange:o,showHint:t=!0}){let r=e===null,a=e??Vs;return sl(LP,{label:l("Hover effect"),icon:sl(RP,{}),value:l(Lf[a]),changed:!r,action:sl(PP,{words:Q()?.panel,label:l("Hover effect"),changed:!r,detail:l(Lf[Vs]),onReset:()=>o(null)}),hint:t?l(AP):void 0,children:sl(OP,{options:Mu.map(n=>({id:n,label:l(Lf[n])})),value:a,ariaLabel:l("Hover effect"),onChange:o})})}import{jsx as il}from"react/jsx-runtime";import{SettingsDefaultReset as BP,SettingsField as _P,SettingsSegmented as DP}from"efficient-easel/panel";import{DropIcon as NP}from"efficient-easel/icons";var Of="Photography",MI={shot:"As shot",mono:"Black and white"},Rf=[{grayscale:!1,label:MI.shot},{grayscale:!0,label:MI.mono}],MP="Black and white photographs return to color on hover. Wheels and tyres keep their real finish either way.";function HI({value:e,onChange:o,showHint:t=!0}){let r=e===null,a=e??!1;return il(_P,{label:l(Of),icon:il(NP,{}),value:l(Rf.find(n=>n.grayscale===a).label),changed:!r,action:il(BP,{words:Q()?.panel,label:l(Of),changed:!r,detail:l(Rf.find(n=>!n.grayscale).label),onReset:()=>o(null)}),hint:t?l(MP):void 0,children:il(DP,{options:Rf.map(n=>({id:n.grayscale,label:l(n.label)})),value:a,ariaLabel:l(Of),onChange:o})})}import{jsx as Af}from"react/jsx-runtime";import{useId as HP}from"react";import{SettingsField as WP,SettingsSwitch as zP}from"efficient-easel/panel";import{ShareIcon as GP}from"efficient-easel/icons";var UP="Share button",$P="On every blog post.";function WI({value:e,onChange:o,showHint:t=!0}){let r=HP();return Af(WP,{label:l(UP),labelId:r,icon:Af(GP,{}),action:Af(zP,{checked:e===!0,onChange:o,ariaLabelledBy:r}),hint:t?l($P):void 0})}import{jsx as fl}from"react/jsx-runtime";import{SettingsDefaultReset as qP,SettingsField as jP}from"efficient-easel/panel";import{PaddingXIcon as KP}from"efficient-easel/icons";var Bf="Side space",_f=ko.default,VP="The room left at the left and right edge of every page.";function zI({value:e,onChange:o,showHint:t=!0}){let r=e===null;return fl(jP,{label:l(Bf),labelId:"sf-side-space",icon:fl(KP,{}),value:`${e??_f}px`,changed:!r,action:fl(qP,{words:Q()?.panel,label:l(Bf),changed:!r,detail:`${_f}px`,onReset:()=>o(null)}),hint:t?l(VP):void 0,children:fl(je,{min:ko.min,max:ko.max,step:ko.step,value:e??_f,readout:!1,ariaLabel:l(Bf),onChange:o})})}import{jsx as Go,jsxs as YP}from"react/jsx-runtime";import{SettingsDefaultReset as GI,SettingsField as UI,SettingsSegmented as $I}from"efficient-easel/panel";import{BackgroundIcon as XP,WidthIcon as ZP}from"efficient-easel/icons";var cl="Width",QP="Background",JP="Content",qI=["full","content"],jI=e=>l(Jt[e==="content"?"page":"full"]),eL=400,KI="Content cannot be wider than the background.",VI="The width of every section's background, until the section sets its own.",YI="The width of every section's content, until the section sets its own.",XI="On phones, content always fills the screen.";function dl({value:e,changed:o,detail:t,onChange:r,onReset:a,disabled:n=!1,hint:s,labelId:i}){let f=l(QP);return Go(UI,{label:f,labelId:i,icon:Go(XP,{}),changed:o,hint:s?l(s):void 0,action:Go(GI,{words:Q()?.panel,label:f,changed:o,detail:t,onReset:a}),children:Go($I,{options:qI.map(u=>({id:u,label:jI(u)})),value:e,onChange:r,ariaLabel:f,disabled:n})})}function ul({mode:e,px:o,max:t=we.max,min:r=eL,changed:a,detail:n,onMode:s,onPx:i,onReset:f,fullClosed:u=!1,disabled:p=!1,hint:m,labelId:x}){let I=l(JP),b=e!=="full"?Go(je,{min:r,max:t,step:we.step,value:Math.min(Math.max(o,r),t),onChange:i,suffix:"px",ariaLabel:I,disabled:p}):null;return Go(UI,{label:I,labelId:x,icon:Go(ZP,{}),changed:a,hint:m?l(m):void 0,action:Go(GI,{words:Q()?.panel,label:I,changed:a,detail:n,onReset:f}),children:e===void 0||!s?b:YP("div",{className:"flex w-full min-w-0 flex-col gap-2",children:[Go($I,{options:qI.map(C=>({id:C,label:jI(C),disabled:C==="full"&&u})),value:e,onChange:s,ariaLabel:I,disabled:p}),b]})})}import{jsx as Gh}from"react/jsx-runtime";import{TextStyleItem as uO,TextStylesGroup as pO}from"efficient-easel/text-styles";import{jsx as lO}from"react/jsx-runtime";import{useState as sO}from"react";import{TextStylesList as iO}from"efficient-easel/text-styles";import{usePreviewDevice as fO}from"efficient-easel/draw/client";import{defaultTextStyles as eO}from"efficient-easel/text-styles";import{textStyleCaseCss as oO}from"efficient-easel/draw";import{textStyleCaseCss as dL,textStyleCaseOfCss as uL}from"efficient-easel/draw";function Df(e,o){return o?`${e}[${o.index}].${o.rowKey}`:e}function po(e){let o=/^([A-Za-z0-9_$]+)\[(\d+)\]\.([A-Za-z0-9_$]+)$/u.exec(e);return o?{key:o[1],row:{index:Number(o[2]),rowKey:o[3]}}:{key:e,row:null}}import{decodePartId as Il,encodePartId as hl}from"efficient-easel/draw";import{LINK_FIELD_MARKER as lh,SCAFFOLD_FIELD_MARKER as ah,TEXT_FIELD_MARKER as gl}from"efficient-easel/draw";import{readHidable as sh}from"efficient-easel/draw";import{SCALAR_TEXT_CONTROLS as sL}from"efficient-easel/draw";import{TEXT_FIELD_MARKER as lL}from"efficient-easel/draw";import{TEXT_FIELD_MARKER as ZI}from"efficient-easel/draw";import{readHidable as QI}from"efficient-easel/draw";import{SCALAR_TEXT_CONTROLS as oL}from"efficient-easel/draw";var tL=oL,rL=["text","textarea"],aL=["textarea","plainTextarea"];function nL(e){return!e||typeof e!="object"?null:e[ZI]?.control??null}function nr(e){let o=nL(e);return o&&tL.includes(o)?o:null}function pl(e){return aL.includes(e)}function JI(e){return!e||typeof e!="object"?void 0:e[ZI]?.placeholder}function ml(e){return QI(e).text}function Nf(e,o,t){return rL.includes(e)?{text:t,hidden:QI(o).hidden}:t}function eh(e,o,t,r){return ml(e[o])===r?null:{...e,[o]:Nf(t,e[o],r)}}function Mf(e){if(!(!e||typeof e!="object"))return e[lL]}function Hf(e){if(!e||typeof e!="object")return null;let o=e.arrayFields;return o&&typeof o=="object"?o:null}function oh(e,o){if(!Array.isArray(o))return[];let t=Mf(e),r=[];if(t?.control==="textList"){let n=t.itemKey??"text";return o.forEach((s,i)=>{let f=s?.[n];typeof f=="string"&&f&&r.push({row:{index:i,rowKey:n},text:f})}),r}let a=Hf(e);return a?(o.forEach((n,s)=>{for(let[i,f]of Object.entries(a)){if(!nr(f))continue;let u=ml(n?.[i]);u&&r.push({row:{index:s,rowKey:i},text:u})}}),r):[]}function na(e,o){if(Array.isArray(e))return e[o.index]?.[o.rowKey]}function Wf(e,o,t,r){let a=e[o];return!Array.isArray(a)||t.index<0||t.index>=a.length?null:{...e,[o]:a.map((n,s)=>s===t.index?{...n,[t.rowKey]:r}:n)}}function th(e,o,t,r,a){let n=na(e[o],t);return ml(n)===a?null:Wf(e,o,t,Nf(r,n,a))}function rh(e,o){return o?`${e} \xB7 row ${o.index+1}`:e}var mo="data-sf-part",Z8="data-sf-region-part",Ke="data-sf-part-selected",Q8="data-sf-part-kind",iL="data-sf-part-style-owner",fL="data-sf-part-style-kind";function J8(e){for(let o=e;o;o=o.parentElement){let t=o.getAttribute(iL),r=o.getAttribute(fL);if(t&&r)return{owner:t,kind:r};if(o.getAttribute("data-puck-component"))return null}return null}var nh=2;function ih(e,o){if(!e)return!1;let t=Il(e);return!!t?.propKey&&t.nodeId===o}function lr(e){return Ct(e).replace(/\s+/gu,"")}function xl(e,o,t){let r=e[gl];if(r){if(r.control==="textList"){let n=r.itemKey??"text";if(!Array.isArray(o))return;for(let s of o){let i=s?.[n];typeof i=="string"&&t.push(i)}return}let{text:a}=sh(o);a?t.push(a):r.placeholder&&t.push(r.placeholder);return}if(!e[lh]){if(e.type==="text"||e.type==="textarea"){typeof o=="string"&&o&&t.push(o);return}if(e.arrayFields&&Array.isArray(o)){for(let a of o)for(let[n,s]of Object.entries(e.arrayFields))xl(s,a?.[n],t);return}if(e.objectFields&&o&&typeof o=="object")for(let[a,n]of Object.entries(e.objectFields))xl(n,o[a],t)}}function fh(e){if(!e||typeof e!="object")return!1;let o=e;return o[lh]?!1:!!o[gl]||o.type==="text"||o.type==="textarea"}function bl(e,o){let t=e[gl];return t?.label?t.label:typeof e.label=="string"?e.label:o}function zf(e){let o=e.indexOf(" (");return(o>0?e.slice(0,o):e).trim()}function eq(e,o){if(!e)return[];let t=[];for(let[r,a]of Object.entries(e)){if(!a||typeof a!="object"||Kr(r))continue;let n=a,s=[];xl(n,o?.[r],s),!s.length&&n[ah]!==void 0&&xl(n,n[ah],s);let i=bl(n,r),f=new Set;for(let{row:m,text:x}of oh(n,o?.[r])){let I=lr(x);I.length<nh||(f.add(I),t.push({key:r,label:i,texts:[I],row:m}))}let u=new Set(f),p=[];for(let m of s){let x=lr(m);x.length<nh||u.has(x)||(u.add(x),p.push(x))}p.length&&t.push({key:r,label:i,texts:p})}return t}var cL=sL;function ch(e,o){if(!o||typeof o!="object"||Kr(e)||nm(o))return null;let t=o[gl];return!t||!cL.includes(t.control)?null:t}function oq(e,o){let t=ch(e,o);return t!==null&&t.identifier!==!0}function dh(e,o){if(!e)return[];let t=[];for(let[r,a]of Object.entries(e)){let n=ch(r,a);if(!n)continue;let{text:s,hidden:i}=sh(o?.[r]),f=s||n.placeholder||"",u=Ct(f).replace(/\s+/gu," ").trim();t.push({key:r,label:zf(bl(a,r)),preview:u,offPage:n.offPage===!0,identifier:n.identifier===!0,hidden:!!i})}return t}var $f="_partStyles",jf="data-sf-part-styled",sr="data-sf-text-style",pL=/^(heading|body)-[1-7]$/;function ir(e){return typeof e=="string"&&pL.test(e)}var Sl={heading:"heading-1",heading2:"heading-2",heading3:"heading-3",body:"body-1",label:"body-5"};function mL(e){if(!e)return null;for(let[o,t]of Object.entries(Sl))if(t===e)return o;return null}function bh(e){if(ir(e.textStyle))return e.textStyle;let o=e.role&&Ao.includes(e.role)?e.role:null;return o?Sl[o]:void 0}var xL=[400,500,600,700],yh=["left","center","right","justify"],uh=5,ph=1e3,IL=-5,hL=10,Kf=0,Vf=64,Yf=2,Xf=120,nt=1280,Zf=10,mh={size:{min:uh,max:ph,step:1},sizePhone:{min:uh,max:ph,step:1},padding:{min:Kf,max:Vf,step:Yf},width:{min:Xf,max:nt,step:Zf}},gL=.05,bL=.01,yL=["line","letter"],SL=.5,CL=2.5,vL=-1,wL=1,kL=0,TL=400;function sa(e){return!e||typeof e!="object"||Array.isArray(e)?null:e}function Sh(e){return sa(e?.[$f])??{}}function Cl(e,o){let t=Sh(e);return Object.hasOwn(t,o)?sa(t[o])??{}:{}}function Ch(e,o,t){let r={...Sh(e)};if(EL(t).length?r[o]=t:delete r[o],!Object.keys(r).length){let{[$f]:a,...n}=e;return n}return{...e,[$f]:r}}function EL(e){return Object.entries(e).filter(([,o])=>o!==void 0)}function FL(e){return yL.includes(e)}var la=(e,o,t)=>Math.min(t,Math.max(o,e));function PL(e,o){if(FL(e)){let t=Math.round(Number(o));return!Number.isFinite(t)||t===0?null:la(t,IL,hL)}if(e==="lineHeight"){let t=Number(o);return Number.isFinite(t)?fr(la(t,SL,CL),3):null}if(e==="letterSpacing"){let t=Number(o);return Number.isFinite(t)?fr(la(t,vL,wL),4):null}if(e==="paragraphSpacing"){let t=Math.round(Number(o));return!Number.isFinite(t)||t<=0?null:la(t,kL,TL)}if(Object.hasOwn(mh,e)){let{min:t,max:r}=mh[e],a=Math.round(Number(o));return Number.isFinite(a)?la(a,t,r):null}return e==="italic"?typeof o=="boolean"?o:null:e==="role"?Ao.includes(String(o))?o:null:e==="textStyle"?ir(o)?o:null:o}var LL=["weight","size","sizePhone","line","letter","lineHeight","letterSpacing","paragraphSpacing","padding","width"];function vh(e){let o=null,t=r=>{o??={...e},delete o[r]};for(let r of LL){let a=e[r];a!==void 0&&!(typeof a=="number"&&Number.isFinite(a))&&t(r)}return e.align!==void 0&&!yh.includes(e.align)&&t("align"),e.textStyle!==void 0&&!ir(e.textStyle)&&t("textStyle"),o??e}var OL=[["font","role"],["role","textStyle"],["line","lineHeight"],["letter","letterSpacing"]];function RL(e){let o=[];for(let[t,r]of OL)t===e?o.push(r):r===e&&o.push(t);return o}function cr(e,o,t,r){let a={...Cl(e,o)},n=r==null?null:PL(t,r);if(n===null)delete a[t];else{a[t]=n;for(let s of RL(t))delete a[s]}return Ch(e,o,a)}function wh(e,o){return Ch(e,o,{})}function AL(e){return uL(e)??"none"}function BL(e){return dL(e)??""}var _L={heading:"--font-role-heading",heading2:"--font-role-heading2",heading3:"--font-role-heading3",body:"--font-role-body",accent:"--font-role-accent",label:"--font-role-label"};function DL(e,o){let t=e.role;return t&&Ao.includes(t)?t:o?.blockDrawsStyle?null:mL(e.textStyle)}function kh(e,o){return e==="Text"&&o==="text"}var NL={headingLarge:"min(clamp(64px,9vw,144px), var(--sf-heading-max,9999px))",headingMedium:"min(32px, var(--sf-heading-max,9999px))",headingSmall:"min(24px, var(--sf-heading-max,9999px))",accent:"32px",body:"14px",label:"12px"};function ML(e){let o=wu[e],t=NL[o];return t?`var(--size-${o}, ${t})`:`var(--size-${o})`}function fa(e){let o={};return typeof e.lineHeight=="number"?o.lineHeight=e.lineHeight:e.line&&(o.lineHeight=fr(HL+e.line*gL,3)),typeof e.letterSpacing=="number"?o.letterSpacingEm=e.letterSpacing:e.letter&&(o.letterSpacingEm=fr(e.letter*bL,4)),o}var HL=1,ca="--sf-part-para",Qf="(max-width: 719.98px)";function xh(e){return e=vh(e),typeof e.sizePhone=="number"&&e.sizePhone>0?{fontSize:`${e.sizePhone}px`}:{}}function WL(e,o){return o&&typeof e.sizePhone=="number"&&e.sizePhone>0?{...e,size:e.sizePhone}:e}function yl(e,o,t){e=vh(e);let r=DL(e,t),a=fa(e),n=e.size?`${e.size}px`:r?ML(r):"";return{fontFamily:e.font?$L(e.font):r?`var(${_L[r]})`:"",fontWeight:e.weight?String(e.weight):"",fontSize:n,minWidth:n?"0":"",overflowWrap:n?"break-word":"",lineHeight:a.lineHeight!==void 0?String(a.lineHeight):"",letterSpacing:a.letterSpacingEm!==void 0?`${a.letterSpacingEm}em`:"",[ca]:e.paragraphSpacing?`${e.paragraphSpacing}px`:"",textTransform:BL(e.case),textAlign:e.align??"",paddingTop:Gf(e.padding),paddingBottom:Gf(e.padding),maxWidth:Gf(e.width),color:zL(e.color),fontStyle:e.italic===!0?"italic":e.italic===!1?"normal":""}}var zL=e=>e===void 0||e===""?"":Object.hasOwn(Do,e)?Do[e]:Th.test(e)?e:"",Th=/^#[0-9a-fA-F]{6}$/;function Eh(e){return Th.test(e)}var Gf=e=>e===void 0?"":`${e}px`,fr=(e,o)=>Number(e.toFixed(o));function iq(e,o){let t=Number.parseFloat(e.fontSize)||16,r=Number.parseFloat(e.lineHeight),a=Number.parseFloat(e.letterSpacing),n=Number.parseFloat(e.paddingTop),s=Number.parseFloat(e.maxWidth);return{fontKey:o,sizePx:t,weight:GL(Number.parseInt(e.fontWeight,10)),lineRatio:Number.isFinite(r)?fr(r/t,3):1.2,letterEm:Number.isFinite(a)?fr(a/t,4):0,align:UL(e.textAlign),case:AL(e.textTransform),paddingPx:Number.isFinite(n)?Math.round(n):0,widthPx:Number.isFinite(s)&&s<nt?Math.round(s):nt}}function GL(e){return Number.isFinite(e)?xL.reduce((o,t)=>Math.abs(t-e)<Math.abs(o-e)?t:o):400}function UL(e){for(let o of yh)if(o===e)return o;return e==="end"?"right":"left"}function fq(e,o){let t=Ih(e);if(!t)return"";for(let r of co)if(Ih(o(r.cssVar))===t)return r.key;return""}var Ih=e=>(e.split(",")[0]??"").replace(/["']/g,"").replace(/\s+/g," ").trim().toLowerCase();function $L(e){let o=Gt(e);return o?`var(${o.cssVar})`:""}function cq(e,o,t,r){return!o||Il(o)?.nodeId!==e?null:t.find(a=>r(a.getAttribute("class")))??t[0]??null}function dq(e,o,t=()=>ia,r=i=>i,a=KL,n=!1,s=()=>!1){let i=0;for(let{element:f,partId:u}of e){let p=Il(u)?.propKey;if(!p)continue;let m=r(p),x=Object.hasOwn(o,m)?sa(o[m])??{}:{},I=yl(WL(x,n),ia,{blockDrawsStyle:s(p)});ir(x.textStyle)?f.setAttribute?.(sr,x.textStyle):f.removeAttribute?.(sr);let b=Uf.some(w=>f.style[w]),C=!1;for(let[w,k]of Object.entries(I))VL(f,w,k),k&&(C=!0);if(b||Uf.some(w=>I[w]))for(let w of qL(f,a))for(let k of Uf)w.style[k]=I[k]??"";C&&(i+=1)}return i}function qL(e,o){let t=lr(e.textContent??""),r=[],a=e;for(let n=0;n<jL&&o(a);n+=1){let s=a.parentElement;if(!s||lr(s.textContent??"")!==t)break;r.push(s),a=s}return r}var jL=8;function KL(e){let o=e;return typeof window>"u"||!o?.ownerDocument?!1:window.getComputedStyle(o).display==="inline"}var ia={fontKey:"",sizePx:16,weight:400,lineRatio:1,letterEm:0,align:"left",case:"none",paddingPx:0,widthPx:nt};function VL(e,o,t){if(!o.startsWith("--")){e.style[o]=t;return}let r=e.style;typeof r.setProperty=="function"?t?r.setProperty(o,t):r.removeProperty?.(o):r[o]=t;let a=e;o===ca&&(t?a.setAttribute?.(hh,""):a.removeAttribute?.(hh))}var hh="data-sf-part-para",YL=Object.keys(yl({},ia)),qf=new Set(["color","overflowWrap",ca,"fontStyle"]),Uf=YL.filter(e=>!qf.has(e));function Fh(e,o,t,r=n=>n,a=()=>!1){let n=new Map;for(let f of e){let u=Df(f.key,f.row);for(let p of f.texts){let m=n.get(p);m?(m.keys.add(f.key),m.partKeys.add(u)):n.set(p,{keys:new Set([f.key]),partKeys:new Set([u])})}}let s=new Map;for(let f of Object.keys(o)){if(!XL(f))continue;let u=sa(o[f])??{},p=yl(u,ia),m=xh(u),x=ir(u.textStyle)?u.textStyle:void 0;!Object.values(p).some(Boolean)&&!Object.keys(m).length&&!x||s.set(f,{stamp:gh(t,f),declarations:p,...Object.keys(m).length?{phone:m}:{},...x?{textStyle:x}:{}})}let i=new Map;for(let[f,{keys:u,partKeys:p}]of n){let m=p.size===1?[...p][0]:u.size===1?[...u][0]:null;if(!m)continue;let x=r(m);if(!Object.hasOwn(o,x))continue;let I=sa(o[x])??{},b=yl(I,ia,{blockDrawsStyle:a(m)}),C=xh(I),w=ir(I.textStyle)?I.textStyle:void 0;!Object.values(b).some(Boolean)&&!Object.keys(C).length&&!w||i.set(f,{stamp:gh(t,m),declarations:b,...Object.keys(C).length?{phone:C}:{},...w?{textStyle:w}:{}})}return i.size||s.size?{rules:i,kindRules:s,drawn:new Set(n.keys())}:null}function XL(e){return e.startsWith("@")}function Jf(e,o){return e?.kindRules.get(o)??null}function gh(e,o){let t=r=>r.replace(/[^A-Za-z0-9_-]+/g,"-");return`${t(e)}~${t(o)}`}function Ph(e){let o=[],t=new Set,r=a=>{let{stamp:n,declarations:s}=a;if(t.has(n))return;t.add(n);let i=Object.entries(s).filter(([,I])=>I!==""),f=I=>I.map(([b,C])=>`${QL(b)}: ${C}`).join("; "),u=`[${jf}="${n}"]`,p=i.filter(([I])=>!qf.has(I)),m=i.filter(([I])=>qf.has(I));p.length&&o.push(`${u}, *:has(> ${u}) { ${f(p)} }`),m.length&&o.push(`${u} { ${f(m)} }`),s[ca]&&o.push(...ZL(u));let x=Object.entries(a.phone??{}).filter(([,I])=>I!=="");x.length&&o.push(`@media ${Qf} { ${u}, *:has(> ${u}) { ${f(x)} } }`)};for(let a of e.rules.values())r(a);for(let a of e.kindRules.values())r(a);return o.join(`
|
|
4
|
+
`)}function ZL(e){let o=`var(${ca})`,t=":is([data-sf-bullet], [data-sf-number])";return[`${e} br:not(br + br) { display: block; content: ""; margin-top: ${o} }`,`${e} ${t}:not(:first-child) { margin-top: ${o} }`,`${e} ${t}:not(:last-child) { margin-bottom: ${o} }`]}var QL=e=>e.replace(/[A-Z]/g,o=>`-${o.toLowerCase()}`);function Lh(e,o){if(!e)return null;let t=lr(o),r=e.rules.get(t);if(r)return r;if(t.length<JL||e.drawn.has(t))return null;let a=null;for(let[n,s]of e.rules)if(n.includes(t)){if(a&&a.stamp!==s.stamp)return null;a=s}return a}var JL=8;function Oh(e){switch(e.id){case"heading-1":return"font-display";case"heading-2":return"font-heading2";case"heading-3":return"font-heading3";case"body-1":return"font-body";case"body-5":return"font-mono";default:return`font-${e.id}`}}var ec=e=>e==="sentence"?"none":void 0,Uo=e=>typeof e=="number"&&Number.isFinite(e)?e:void 0,da=e=>typeof e=="string"&&e?e:void 0,Ah=["font","color","size","sizePhone","weight","italic","lineHeight","letterSpacing","paragraphSpacing","letterCase","largestSize"];function Fo(e){let o={};for(let t of Ah)e[t]!==void 0&&(o[t]=e[t]);return o}function tc(e,o){let{auto:t,...r}=e,a=new Set(o??[]),n=Ah.filter(s=>a.has(s)&&e.values[s]===void 0);return n.length?{...r,auto:n}:r}function rc(e){let o=e.fonts,t=e.sizes,r=e.typography,a=Wu(e.compression),n={"heading-1":{font:da(o.heading),size:Uo(t.headingLarge),weight:Uo(r.weight),lineHeight:a.lineHeight,letterSpacing:a.letterSpacing,letterCase:ec(r.case),largestSize:Uo(r.maxPx)},"heading-2":{font:da(o.heading2),size:Uo(t.headingMedium),weight:Uo(r.weight2),lineHeight:a.lineHeight,letterSpacing:a.letterSpacing,letterCase:ec(r.case2)},"heading-3":{font:da(o.heading3),size:Uo(t.headingSmall),weight:Uo(r.weight3),lineHeight:a.lineHeight,letterSpacing:a.letterSpacing,letterCase:ec(r.case3)},"body-1":{font:da(o.body),size:Uo(t.body)},"body-5":{font:da(o.label),size:Uo(t.label)}};return eO().map(({id:s,kind:i,name:f})=>({id:s,kind:i,name:f,values:Fo(n[s]??{})}))}function vl(e){return Array.isArray(e)&&e.every(o=>o&&typeof o=="object"&&typeof o.id=="string"&&(o.kind==="heading"||o.kind==="body")&&typeof o.name=="string")?e.map(o=>tc({...o,values:Fo(o.values??{})},Array.isArray(o.auto)?o.auto:void 0)):null}function yq(e){return vl(e)??[]}function lt(e,o){let t=rc(o),r=vl(e);return r?r.map(a=>{let n={...oc(t,a.id)};for(let s of a.auto??[])delete n[s];return{...a,values:Fo({...n,...a.values})}}):t}var oc=(e,o)=>e.find(t=>t.id===o)?.values??{},Rh=["heading-1","heading-2","heading-3"];function Bh({saved:e,old:o,cur:t,next:r,sizeOf:a}){let n=rc(o),s=vl(e)??n.map(m=>({...m,values:{}})),i=lt(s,o),f=[],u=r.map(m=>{let x=t.find(g=>g.id===m.id),I=s.find(g=>g.id===m.id);if(!x||!I)return tO([m],a)[0];let b={...I.values},C=new Set(I.auto??[]),w=m.values,k=x.values,v=[...new Set([...Object.keys(w),...Object.keys(k)])].filter(g=>JSON.stringify(w[g])!==JSON.stringify(k[g]));v.sort((g,y)=>+(g==="letterSpacing")-+(y==="letterSpacing"));for(let g of v){let y=g==="lineSpacing"?"lineHeight":g,L=w[g];if(L===void 0){delete b[y],oc(n,m.id)[y]!==void 0&&(f.push([m.id,y]),C.add(y));continue}if(C.delete(y),g==="lineSpacing")b.lineHeight=dr(L/100,3);else if(g==="letterSpacing"){let F=i.find(E=>E.id===m.id),O=a({...m,values:Fo({...F?.values??{},...b})});b.letterSpacing=O?dr(L/O,4):0}else b[y]=L}return tc({id:m.id,kind:m.kind,name:m.name,values:Fo(b)},C)}),p=o.compression;if(f.some(([m,x])=>(x==="lineHeight"||x==="letterSpacing")&&Rh.includes(m))&&xt(p)!=="normal"){for(let m of Rh){let x=u.find(b=>b.id===m);if(!x)continue;let I={...x.values};for(let b of["lineHeight","letterSpacing"])f.some(([C,w])=>C===m&&w===b)||I[b]===void 0&&!(x.auto??[]).includes(b)&&(I[b]=oc(n,m)[b]);x.values=Fo(I)}p="normal"}return{saved:u,old:{...o,compression:p}}}function _h(e,o){let t={text_styles:e.saved};return e.old.compression!==o.compression&&(t.heading_compression=xt(e.old.compression)),t}var dr=(e,o)=>Number(e.toFixed(o));function Dh(e,o){return e.map(t=>{let{lineHeight:r,letterSpacing:a,...n}=t.values,s={...n};return r!==void 0&&(s.lineSpacing=dr(r*100,1)),a!==void 0&&(s.letterSpacing=dr(a*o(t),2)),{id:t.id,kind:t.kind,name:t.name,values:s}})}function tO(e,o){return e.map(t=>{let{lineSpacing:r,letterSpacing:a,...n}=t.values,s={id:t.id,kind:t.kind,name:t.name,values:Fo({...n})},i={...s.values};if(r!==void 0&&(i.lineHeight=dr(r/100,3)),a!==void 0){let f=o({...s,values:{...s.values}});i.letterSpacing=f?dr(a/f,4):0}return{...s,values:Fo(i)}})}function Sq(e){let o={fonts:Wr({heading:e.heading_font??void 0,heading2:e.heading_2_font??void 0,heading3:e.heading_3_font??void 0,body:e.body_font??void 0,accent:e.accent_font??void 0,label:e.label_font??void 0}),sizes:js({headingLarge:e.heading_size_large_px,headingMedium:e.heading_size_medium_px,headingSmall:e.heading_size_small_px,accent:e.accent_size_px,body:e.body_size_px,label:e.label_size_px}),compression:xt(e.heading_compression),typography:Gu(e)},t=e.text_styles??null,r=Array.isArray(t)?ac(lt(t,o),o):o;return{fonts:Wr(r.fonts),sizes:js(r.sizes),compression:xt(r.compression),typography:r.typography,textStyles:t}}function ac(e,o){let t=x=>e.find(I=>I.id===x)?.values??{},r=t("heading-1"),a=t("heading-2"),n=t("heading-3"),s=t("body-1"),i=t("body-5"),f=o.fonts,u=o.sizes,p=o.typography,m=x=>x==="none"?"sentence":"authored";return{fonts:{...f,heading:r.font??f.heading,heading2:a.font??r.font??f.heading2,heading3:n.font??r.font??f.heading3,body:s.font??f.body,label:i.font??f.label},sizes:{...u,headingLarge:r.size??null,headingMedium:a.size??null,headingSmall:n.size??null,body:s.size??null,label:i.size??null},compression:o.compression,typography:{...p,case:m(r.letterCase),weight:r.weight??null,maxPx:r.largestSize??null,weight2:a.weight??null,weight3:n.weight??null,case2:m(a.letterCase),case3:m(n.letterCase)}}}function rO(e){return e==="accent"?"var(--accent)":e==="text"?"var(--fg)":e==="labels"?"var(--fg-dim)":/^#[0-9a-f]{6}$/i.test(e)?e:null}function aO(e){let o=":is([data-sf-bullet], [data-sf-number])";return[`${e} br:not(br + br) { display: block; content: ""; margin-top: var(--sf-part-para) }`,`${e} ${o}:not(:first-child) { margin-top: var(--sf-part-para) }`,`${e} ${o}:not(:last-child) { margin-bottom: var(--sf-part-para) }`]}function Cq(e){let o=[];for(let t of e){let r=t.values,a=`.${Oh(t)}`,n=`[${sr}="${t.id}"]`,s=`${a}, ${n}`,i=[],f=r.font!==void 0?co.find(x=>x.key===r.font)?.cssVar:void 0;if(f&&i.push(`font-family: var(${f})`),r.size!==void 0){let x=r.largestSize!==void 0?Math.min(r.size,r.largestSize):r.size;i.push(`font-size: ${x}px`)}let u=r.color!==void 0?rO(r.color):null;u&&i.push(`color: ${u}`),r.italic===!0&&i.push("font-style: italic"),r.weight!==void 0&&i.push(`font-weight: ${r.weight}`);let p=[];r.lineHeight!==void 0&&p.push(`line-height: ${r.lineHeight}`),r.letterSpacing!==void 0&&p.push(`letter-spacing: ${r.letterSpacing}em`),t.kind==="body"&&i.push(...p);let m=oO(r.letterCase);if(m&&i.push(`text-transform: ${m}`),r.paragraphSpacing&&i.push(`--sf-part-para: ${r.paragraphSpacing}px`),i.length&&o.push(`${s} { ${i.join("; ")} }`),t.kind==="heading"&&p.length&&o.push(`${s}, ${a}:is(h1, h2, h3, h4), ${n}:is(h1, h2, h3, h4) { ${p.join("; ")} }`),r.paragraphSpacing&&o.push(...aO(`:is(${s})`)),r.sizePhone!==void 0){let x=nO[t.id],I=[`${s} { font-size: ${r.sizePhone}px }`];x&&I.push(`.sf-themed-content { --size-${x}: ${r.sizePhone}px !important }`),o.push(`@media ${Qf} { ${I.join(" ")} }`)}}return o.join(`
|
|
5
|
+
`)}var nO={"heading-1":"headingLarge","heading-2":"headingMedium","heading-3":"headingSmall","body-1":"body","body-5":"label"};function vq(e){return e!==!0&&e!==!1?"":`em.text-accent { font-style: ${e?"italic":"normal"} }`}function Nh(e){return e?Sl[e]:void 0}function nc(e){let o=fa(e);return Fo({font:e.font,color:e.color,size:e.size,weight:e.weight,italic:e.italic,lineHeight:o.lineHeight,letterSpacing:o.letterSpacingEm,paragraphSpacing:e.paragraphSpacing,letterCase:e.case})}function Mh(e){return Object.keys(nc(e)).length>0}function Hh({saved:e,old:o,styleId:t,values:r}){return{saved:(vl(e)??rc(o).map(a=>({...a,values:{}}))).map(a=>a.id===t?tc({...a,values:Fo({...a.values,...r})},a.auto):a),old:o}}var Wh=["font","color","size","weight","emphasis","lineSpacing","letterSpacing","paragraphSpacing","letterCase","largestSize"],cO=["size","lineSpacing","letterSpacing","letterCase"],dO=500,lc=co.map(e=>({value:e.key,label:e.label,family:`var(${e.cssVar})`,italic:e.italicLoaded}));function zh({saved:e,old:o,colours:t,sizeOf:r,onChange:a,openId:n,onOpenChange:s,readOnly:i=!1,withoutSize:f=!1}){let[u,p]=sO(null),m=fO()==="mobile",x=lt(e,o),I=Dh(x,r);return lO(iO,{styles:I,onChange:b=>a(Bh({saved:e,old:o,cur:I,next:b,sizeOf:r})),fonts:lc,colours:t,settings:f?Wh.filter(b=>b!=="size"):Wh,auto:cO,openId:n===void 0?u:n,onOpenChange:s??p,readOnly:i,device:m?"phone":"desktop",fallback:b=>{let C=x.find(k=>k.id===(b.kind==="heading"?"heading-1":"body-1")),w={};return C?.values.font&&b.id!==C.id&&(w.font=C.values.font),b.kind==="heading"&&(w.weight=dO),w}})}var Uh=["font","size","weight","emphasis"],mO=500;function xO({font:e,size:o,weight:t,italic:r}){let a={font:e};return o!==null&&(a.size=o),t!==null&&(a.weight=t),r!==null&&(a.italic=r),{id:"accent",kind:"heading",name:l("Accent"),values:a}}function IO(e,o){let t=[],r=e.values,a=o.values;return a.font!==r.font&&a.font!==void 0&&t.push({key:"font",value:a.font}),a.size!==r.size&&t.push({key:"size",value:a.size??null}),a.weight!==r.weight&&t.push({key:"weight",value:a.weight??null}),a.italic!==r.italic&&t.push({key:"italic",value:a.italic??null}),t}function $h(e){let{headingWeight:o,open:t,onOpenChange:r,onChange:a,withoutSize:n=!1}=e,s=xO(e);return Gh(pO,{label:l("Accent"),children:Gh(uO,{style:s,fonts:lc,settings:n?Uh.filter(i=>i!=="size"):Uh,auto:["size"],fallback:()=>({weight:o??mO}),open:t,onOpenChange:r,onChange:i=>IO(s,i).forEach(a)})})}import{Tabs as gO,Tooltip as i9,tabButtonId as bO,tabPanelId as yO}from"efficient-shell/ui";import{ContrastIcon as SO,NoteIcon as CO,SettingsIcon as vO,TypeIcon as wO}from"efficient-easel/icons";function qh(e){switch(e.status){case"saved":return null;case"failed":return{msg:l("Not saved. Try again."),tone:"error"};case"skipped":switch(e.reason){case"empty":return null;case"no-token":return{msg:l("Not saved. Reload the page."),tone:"error"};case"template":return{msg:l("Templates keep their look. Press Done."),tone:"success"}}}}import{SettingsGroupSub as kO}from"efficient-easel/panel";import{previewFrame as TO}from"efficient-easel/screen/lib/puck/preview-dom";import{useEasel as hO}from"efficient-easel/easel";function wl({themeFromDocument:e,persist:o}){let{appState:t,dispatch:r}=hO(O=>O),{fonts:a,setFonts:n,sizes:s,setSizes:i,headingCompression:f,setHeadingCompression:u,headingTypography:p,setHeadingTypography:m,textStyles:x,setTextStyles:I}=V(),b=t.data,C=b.root?.props??{},w=e?Wr(C.fonts):a,k=e?Bu:s,v=e?xt(C.headingCompression):f,g=e?zu(C.headingTypography):p,y={fonts:w,sizes:k,compression:v,typography:g},L=e?C.textStyles:x,F=O=>r({type:"replaceRoot",root:{...b.root,props:{...C,...O}},recordHistory:!0});return{fonts:w,sizes:k,compression:v,typography:g,old:y,saved:L,write:(O,E)=>{let D=ac(lt(O.saved,O.old),O.old);e?F({textStyles:O.saved,fonts:D.fonts,headingCompression:D.compression,headingTypography:D.typography}):(I(O.saved),n(D.fonts),i(D.sizes),u(D.compression),m(D.typography)),o(_h(O,y),E)},writeRoot:F}}var fc="sf-site-styles",EO="sf-site-styles-tabpanel",cc=!1,FO="Show hints";function dc({shown:e,onChange:o}){return te("div",{className:"sf-hints",children:st("button",{type:"button","aria-pressed":e,onClick:()=>o(!e),className:`sf-rung sf-hints-toggle${e?" is-active":""}`,children:[te(CO,{size:13}),l(FO)]})})}var Kh="text",ur=[{id:"basics",label:"Basics",icon:te(vO,{})},{id:"theme",label:"Theme",icon:te(SO,{})},{id:"text",label:"Text",icon:te(wO,{})}];function PO({themeFromDocument:e,persist:o}){let{appState:t,dispatch:r}=jh(u=>u),{theme:a,setTheme:n}=V(),s=t.data,i=s.root?.props??{},f=u=>{if(e){let p={...i,theme:u};r({type:"replaceRoot",root:{...s.root,props:p},recordHistory:!0})}else n(u);o({selected_preset:u.selected,theme_presets:u.themes})};return te(OI,{value:e?i.theme:a,onChange:f})}function LO({themeFromDocument:e,persist:o}){let[t,r]=ic(null),{theme:a,setFonts:n,setSizes:s,setHeadingTypography:i}=V(),f=wl({themeFromDocument:e,persist:o}),{old:u,saved:p,writeRoot:m}=f,x=f.fonts,I=f.sizes,b=f.typography,C=F=>F.values.size??_O(RO[F.id]??"body")??AO[F.kind],w=F=>f.write(F),k=OO(a),v=F=>{let O={...x,accent:F};e?m({fonts:O}):n(O),o({accent_font:F})},g=F=>{s({...I,accent:F}),o({accent_size_px:F})},y=F=>{let O={...b,weightStrong:F};e?m({headingTypography:O}):i(O),o({heading_weight_strong:F})},L=F=>{let O={...b,italicStrong:F};e?m({headingTypography:O}):i(O),o({accent_italic:F})};return st(Lt,{children:[te(zh,{saved:p,old:u,colours:k,sizeOf:C,onChange:w,openId:t===sc?null:t,onOpenChange:r,withoutSize:e}),te($h,{font:x.accent,size:I.accent,weight:b.weightStrong,italic:b.italicStrong,headingWeight:b.weight,open:t===sc,onOpenChange:F=>r(F?sc:null),onChange:F=>{F.key==="font"?v(F.value):F.key==="size"?g(F.value):F.key==="weight"?y(F.value):L(F.value)},withoutSize:e})]})}var sc="accent";function OO(e){let o=Ut(e);return[{key:"accent",name:l("Accent"),value:o.accent},{key:"text",name:l("Text"),value:o.text},{key:"labels",name:l("Labels"),value:o.muted??o.text}]}var RO={"heading-1":"heading","heading-2":"heading2","heading-3":"heading3","body-1":"body","body-5":"label"},AO={heading:32,body:14},BO={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 _O(e){if(typeof document>"u")return null;let o=(TO()?.contentDocument??document).querySelector(BO[e]);if(!o)return null;let t=parseFloat(getComputedStyle(o).fontSize);return Number.isFinite(t)?t:null}function DO({themeFromDocument:e,persist:o,showHint:t}){let{appState:r,dispatch:a}=jh(x=>x),{cornerRadiusPx:n,setCornerRadiusPx:s}=V(),i=r.data,f=i.root?.props??{},u=f.cornerRadiusPx===void 0?Du[_u(f.cornerStyle)]:bo(f.cornerRadiusPx),p=e?u:n,m=x=>a({type:"replaceRoot",root:{...i.root,props:{...f,...x}},recordHistory:!0});return te(RI,{value:p,onChange:x=>{e?m({cornerRadiusPx:x}):s(x),o({corner_radius_px:x})},showHint:t})}function NO(e){return{site_width:e}}function MO({persist:e,showHint:o}){let{siteWidth:t,setSiteWidth:r,sectionBackgroundWidth:a,setSectionBackgroundWidth:n,sectionContentWidth:s,setSectionContentWidth:i}=V(),f=typeof t=="number"?t:we.default,u=x=>{r(x),e(NO(x),x===null)},p=x=>{n(x),e({section_background_width:x},!0)},m=x=>{i(x),e({section_content_width:x},!0)};return st(Lt,{children:[te(kO,{title:l(cl),level:4}),te(dl,{value:a??"full",changed:a!==null,detail:l("Full width"),onChange:p,onReset:()=>p(null),hint:o?VI:void 0}),te(ul,{mode:s??"content",px:f,min:we.min,max:we.max,changed:typeof t=="number"||s!==null,detail:`${l("Content width")} ${we.default}px`,onMode:m,onPx:x=>u(x),onReset:()=>{m(null),u(null)},hint:o?YI:void 0})]})}function HO(e){return{block_gap:e}}function WO(e){return{site_gutter:e}}function zO({persist:e,showHint:o}){let{siteGutter:t,setSiteGutter:r}=V();return te(zI,{value:t,onChange:a=>{r(a),e(WO(a),a===null)},showHint:o})}function GO({persist:e,showHint:o}){let{blockGap:t,setBlockGap:r}=V();return te(DI,{value:t,onChange:a=>{r(a),e(HO(a),a===null)},showHint:o})}function UO({persist:e,showHint:o=!0}){return st(Lt,{children:[te(MO,{persist:e,showHint:o}),te(zO,{persist:e,showHint:o}),te(GO,{persist:e,showHint:o})]})}function $O(e){return{card_shadow:e}}function qO(e){return e===null?{shadow_color:null}:{shadow_color:Hu(e)}}function jO(e){return{hover_effect:e}}function KO({persist:e,showHint:o=!0}){let{cardShadow:t,setCardShadow:r,shadowColor:a,setShadowColor:n,hoverEffect:s,setHoverEffect:i}=V();return st(Lt,{children:[te(AI,{value:t,onChange:f=>{r(f),e($O(f),!0)},showHint:o}),te(_I,{value:a,onChange:f=>{n(f),e(qO(f),f===null)},showHint:o}),te(NI,{value:s,onChange:f=>{i(f),e(jO(f),!0)},showHint:o})]})}function VO(e){return{photography_grayscale:e}}function YO({persist:e,showHint:o}){let{photographyGrayscale:t,setPhotographyGrayscale:r}=V();return te(HI,{value:t,onChange:a=>{r(a),e(VO(a),!0)},showHint:o})}function XO({persist:e,showHint:o=!0}){return te(Lt,{children:te(YO,{persist:e,showHint:o})})}function ZO(e){return{share_button_on_posts:e}}function QO({persist:e,showHint:o=!0}){let{shareButtonOnPosts:t,setShareButtonOnPosts:r}=V();return te(WI,{value:t,onChange:a=>{r(a),e(ZO(a),!0)},showHint:o})}function pr(){let{websiteName:e}=V();return e?.trim()||Uu}function kl({themeFromDocument:e=!1,tokenRef:o,siteId:t,onNotify:r,tab:a,onTabChange:n}){let{persist:s}=Yt({themeFromDocument:e,tokenRef:o,siteId:t,onResult:C=>{let w=qh(C);w&&r?.(w.msg,w.tone)}}),[i,f]=ic(ur[0].id),u=a!==void 0,p=u?a:i,m=u?n??(()=>{}):f,x=ur.find(C=>C.id===p)??ur[0],[I,b]=ic(cc);return st(Lt,{children:[te(JO,{activeId:x.id,onSelect:m}),st("div",{id:yO(fc,x.id),className:EO,role:"tabpanel","aria-labelledby":bO(fc,x.id),children:[p==="basics"&&st(Lt,{children:[te(DO,{themeFromDocument:e,persist:s,showHint:I}),!e&&te(KO,{persist:s,showHint:I}),!e&&te(UO,{persist:s,showHint:I}),!e&&te(XO,{persist:s,showHint:I}),!e&&te(QO,{persist:s,showHint:I}),te(dc,{shown:I,onChange:b})]}),p==="theme"&&te(PO,{themeFromDocument:e,persist:s}),p==="text"&&te(LO,{themeFromDocument:e,persist:s})]})]})}function JO({activeId:e,onSelect:o}){return te("div",{className:"es-insp-tabs",children:te(gO,{variant:"underline",block:!0,labelsFit:!0,"aria-label":l("Site styles"),idPrefix:fc,value:e,onChange:o,items:ur.map(t=>{let r=l(t.label);return{id:t.id,icon:t.icon,label:r}})})})}import{InspectorIconButton as hR}from"efficient-easel/chrome";import{Button as fg,Dialog as gR,FormField as bR,Input as cg,toast as dg}from"efficient-shell/ui";import{LayersTree as yR,TreeGroupLabel as SR,TreeRow as ug,TreeRowAction as _l}from"efficient-easel/tree";import{AddIcon as CR,DuplicateIcon as vR,PageIcon as wR}from"efficient-easel/icons";import{PagesIcon as kR}from"efficient-easel/rail";import{useEaselHost as TR}from"efficient-easel/screen/lib/host";var uc="Main Pages",eR="Dynamic Pages",pc="dynamic",oR="dynamic";function mc(e){return e.kind===oR}function Vh(e){let o=[],t=[];for(let r of e){if(mc(r)){t.push(r);continue}let a=r.groupKey??(r.group?`folder:${r.group}`:"top"),n=o[o.length-1];n&&n.key===a?n.rows.push(r):o.push({key:a,label:r.group??uc,rows:[r]})}if(t.length){let r=o.findIndex(a=>a.key.startsWith("system:"));o.splice(r===-1?o.length:r,0,{key:pc,label:eR,rows:t})}return o}import{useEaselSession as ER}from"efficient-easel/screen/lib/session-context";import{useCallback as Tl,useEffect as tR,useSyncExternalStore as rR}from"react";import{useScreenDocument as Qh}from"efficient-easel/screen/components/ScreenDocumentContext";var Yh=new WeakMap;function ua(e){let o=Yh.get(e);return o||(o={rows:null,loading:null,listeners:new Set},Yh.set(e,o)),o}function xc(e,o){e.rows=o;for(let t of e.listeners)t()}var El=new Set;function Fl(e,o){o?El.add(e):El.delete(e)}function Xh(e){let o=ua(e),t=e.listPages().then(r=>xc(o,El.size?r.filter(a=>!El.has(a.id)):r),()=>xc(o,[])).finally(()=>{o.loading===t&&(o.loading=null)});return o.loading=t,t}var Zh=()=>null,aR=()=>()=>{};function pa(){let{adapter:e,ready:o}=Qh(),t=Tl(i=>{let{listeners:f}=ua(e);return f.add(i),()=>f.delete(i)},[e]),r=Tl(()=>ua(e).rows,[e]),a=rR(o?t:aR,o?r:Zh,Zh);tR(()=>{if(!o)return;let i=ua(e);i.rows===null&&!i.loading&&Xh(e)},[e,o]);let n=Tl(()=>o?Xh(e):Promise.resolve(),[e,o]),s=Tl(i=>xc(ua(e),i),[e]);return{rows:a,reload:n,setRows:s,getRows:r}}function nR(e,o){return e?.find(t=>t.slug===o)?.label?.trim()||`/${o}`}function Jh(){let{currentSlug:e}=Qh(),{rows:o}=pa();return nR(o,e)}import{useEaselSession as lR}from"efficient-easel/screen/lib/session-context";import{useScreenDocument as sR}from"efficient-easel/screen/components/ScreenDocumentContext";var iR=new Set(["normal","dynamic"]);function Pl(e){return!e.kind||iR.has(e.kind)}function Ll(e,o){let t=kt(e)||"page";if(!o.has(t))return t;let r=2;for(;o.has(`${t}-${r}`);)r+=1;return`${t}-${r}`}function eg(e,o){return o.has(e)}function og(e,o){return{title:`${e.label||e.slug} copy`,slug:Ll(`${e.slug}-copy`,o)}}function Ol(){let e=lR(),{siteId:o,templateId:t}=sR(),r=We(e).pages;if(!(!r.duplicate||t))return(a,n)=>r.duplicate(a.id,{...n,...o?{siteId:o}:{}})}import{jsx as Ot,jsxs as tg,Fragment as fR}from"react/jsx-runtime";import{useId as rg,useState as mr}from"react";import{Button as ag,Dialog as cR,FormField as ng,Input as lg,Stack as dR}from"efficient-shell/ui";function Rl({source:e,taken:o,duplicate:t,onClose:r,onDuplicated:a}){let n=rg(),s=rg(),[i,f]=mr(null),[u,p]=mr(""),[m,x]=mr(""),[I,b]=mr(!1),[C,w]=mr(!1),[k,v]=mr(null);if(e!==i&&(f(e),e)){let F=og(e,o);p(F.title),x(F.slug),b(!1),v(null)}let g=eg(m,o),y=!!(e&&u.trim()&&m&&!g&&!C),L=async()=>{if(!(!e||!y)){w(!0),v(null);try{let F=await t(e,{title:u.trim(),slug:m});a(F)}catch{v(l("Couldn\u2019t duplicate the page \u2014 please retry."))}finally{w(!1)}}};return Ot(cR,{open:e!==null,onClose:()=>{C||r()},size:"sm",title:l("Duplicate \u201C{name}\u201D",{name:e?.label??""}),description:l("The copy is a draft and stays hidden until you publish it. It opens in the editor."),footer:tg(fR,{children:[Ot(ag,{variant:"secondary",onClick:r,disabled:C,children:l("Cancel")}),Ot(ag,{onClick:()=>{L()},disabled:!y,loading:C,children:l("Duplicate page")})]}),children:tg(dR,{gap:4,children:[Ot(ng,{label:l("Title"),htmlFor:n,error:k??void 0,children:Ot(lg,{id:n,value:u,invalid:!!k,onChange:F=>{p(F.target.value),I||x(kt(F.target.value))},onKeyDown:F=>{F.key==="Enter"&&L()}})}),Ot(ng,{label:l("URL handle"),htmlFor:s,hint:g?void 0:l("URL: /{slug}",{slug:m}),error:g?l("Another page uses this URL handle."):void 0,children:Ot(lg,{id:s,value:m,invalid:g,onChange:F=>{b(!0),x(kt(F.target.value))},onKeyDown:F=>{F.key==="Enter"&&L()}})})]})})}var pg="sf-editor-pages-collapsed-groups";function mg({onNavigate:e,onClose:o,activeSurface:t,onPreviewSurface:r}){let a=ER().chrome?.pageRows,n=TR(),{adapter:s,capabilities:i,ready:f,currentSlug:u}=xR(),p=pr(),{rows:m,reload:x,setRows:I,getRows:b}=pa(),[C,w]=Rt(""),[k,v]=Rt(!1),[g,y]=Rt(null),[L,F]=Rt(!1),[O,E]=Rt(""),D=mR(),G=Ol(),[B,R]=Rt(null),[H,_]=Rt(()=>{if(typeof window>"u")return new Set;try{let P=window.localStorage.getItem(pg);return new Set(P?JSON.parse(P):[])}catch{return new Set}});pR(()=>{try{window.localStorage.setItem(pg,JSON.stringify([...H]))}catch{}},[H]);let ae=P=>_(oe=>{let j=new Set(oe);return j.has(P)?j.delete(P):j.add(P),j}),se=ig(()=>Vh(m??[]),[m]),Ie=C.trim().toLowerCase(),ro=P=>!Ie||P.toLowerCase().includes(Ie),Ye=P=>Ie?!0:!H.has(P),Fe=ig(()=>new Set((m??[]).map(P=>P.slug)),[m]),ao=()=>{if(i.pageCreationInAdminForm){n.send("storefront-editor:new-page");return}E(""),y(null),F(!0)},Me=async()=>{let P=O.trim();if(!(!P||!f||k||!s.createPage)){v(!0),y(null);try{let oe=await s.createPage({slug:Ll(P,Fe),title:P,layout:{}});await x(),F(!1),E(""),e(oe.slug)}catch{y(l("Couldn\u2019t add the page \u2014 please retry."))}finally{v(!1)}}},Re=P=>{let oe=m??[],j=s.deletePage;if(!f||k||!j||oe.length<=1)return;let ge=oe.findIndex(ee=>ee.id===P.id),ve=oe.filter(ee=>ee.id!==P.id),ze=P.slug===u;Fl(P.id,!0),I(ve),y(null),ze&&ve[0]&&e(ve[0].slug);let $e=()=>{Fl(P.id,!1);let ee=b()??[];if(ee.some(Qe=>Qe.id===P.id))return;let le=[...ee];le.splice(Math.max(0,Math.min(ge,le.length)),0,P),I(le)};dg.undoable(l("Deleted \u201C{name}\u201D",{name:P.label}),{actionLabel:l("Undo"),commit:async ee=>{await j(P.id,ee),Fl(P.id,!1)},undo:()=>{$e(),ze&&e(P.slug)},onFail:()=>{$e(),dg.error(l("Couldn\u2019t delete the page \u2014 please retry."))}})},ye=P=>n.send("storefront-editor:open-page",{slug:P}),Ce=P=>{if(!ro(P.label))return null;let oe=!t&&P.slug===u,j=i.canDeletePagesInline&&(m??[]).length>1,ge=mc(P),ve=P.kind==="lightbox",ze=[...ge?[{label:l("Dynamic"),tone:"info"}]:[],...ve?[{label:l("Lightbox"),tone:"success"}]:[],...P.draft?[{label:l("draft"),tone:"draft"}]:[]],$e=ze.length>0?ze:void 0,ee=!!G&&Pl(P),le=ee||i.pageCreationInAdminForm||j?Al(sg,{children:[ee&&fe(_l,{kind:"plain",label:l("Duplicate \u201C{name}\u201D",{name:P.label}),disabled:k,onClick:()=>R(P),children:fe(vR,{size:13})}),i.pageCreationInAdminForm&&fe(_l,{kind:"plain",label:l("Edit \u201C{name}\u201D in {place}",{name:P.label,place:l("the admin")}),onClick:()=>ye(P.slug),children:fe(Bl,{name:"pencil",size:13,strokeWidth:1.7,rounded:!0})}),j&&fe(_l,{kind:"delete",label:l("Delete \u201C{name}\u201D",{name:P.label}),disabled:k,onClick:()=>Re(P),children:fe(Bl,{name:"trash",size:13,strokeWidth:1.7,rounded:!0})})]}):void 0;return fe(ug,{icon:fe(wR,{size:14}),name:P.label,selected:oe,onSelect:()=>e(P.slug),badge:$e,actions:le,rowProps:{"data-page-slug":P.slug}},P.id)},Xe=(P,oe,j)=>{let ge=j.filter(Boolean);if(ge.length===0)return null;let ve=Ye(P);return Al(uR,{children:[fe(SR,{count:ge.length,expanded:ve,onToggle:()=>ae(P),children:oe}),ve&&ge]},P)},He=(a?.rows??[]).filter(P=>ro(P.label)).map(P=>{let oe=t===P.key;return fe(ug,{icon:P.icon,name:P.label,selected:oe,onSelect:()=>r(P.key),badge:{label:l("Preview"),tone:"warning"},actions:fe(_l,{kind:"plain",label:l("Open the {name} in a new tab",{name:P.label}),onClick:()=>window.open(P.href,"_blank","noopener,noreferrer"),children:fe(Bl,{name:"external-link",size:13,strokeWidth:1.7,rounded:!0})}),rowProps:{"data-shop-surface":P.key}},P.key)}),Ze=i.hasSiteSettings&&!!a,Ae=(()=>{if(m===null)return null;let P=[],oe=!1;for(let j of se){Ze&&!oe&&j.key.startsWith("system:")&&(P.push(Xe("shop",a.title,He)),oe=!0);let ge=j.key===pc||j.label===uc?l(j.label):j.label;P.push(Xe(j.key,ge,j.rows.map(Ce)))}return Ze&&!oe&&P.push(Xe("shop",a.title,He)),P})();return Al("div",{className:"sf-pages",children:[fe(IR,{icon:fe(kR,{}),title:l("Pages"),context:p,actions:fe(hR,{label:l("New page"),onClick:ao,children:fe(CR,{size:15})}),onHide:o}),fe("div",{className:"sf-pages-find",children:fe(cg,{type:"search",leftIcon:fe(Bl,{name:"search",size:14,rounded:!0}),placeholder:l("Search all pages\u2026"),value:C,onChange:P=>w(P.target.value),"aria-label":l("Search all pages")})}),g&&!L&&fe("div",{className:"sf-note sf-note--error",role:"alert",children:g}),Ae===null?fe("div",{className:"sf-note",children:l("Loading\u2026")}):Ae.some(Boolean)?fe(yR,{ariaLabel:l("Pages"),className:"sf-scroll",children:Ae}):fe("div",{className:"sf-note",children:C.trim()?l("No pages match your search"):l("No pages yet. Add one with + above.")}),G&&fe(Rl,{source:B,taken:Fe,duplicate:G,onClose:()=>R(null),onDuplicated:P=>{R(null),x(),e(P.slug)}}),fe(gR,{open:L,onClose:()=>F(!1),size:"sm",title:l("Add a page"),description:l("Give the new template page a name. It starts blank \u2014 add sections once it opens."),footer:Al(sg,{children:[fe(fg,{variant:"secondary",onClick:()=>F(!1),children:l("Cancel")}),fe(fg,{onClick:()=>{Me()},disabled:k||!O.trim(),loading:k,children:l("Add page")})]}),children:fe(bR,{label:l("Page name"),htmlFor:D,hint:O.trim()?l("URL: /{slug}",{slug:Ll(O,Fe)}):void 0,error:g??void 0,children:fe(cg,{id:D,value:O,invalid:!!g,onChange:P=>E(P.target.value),onKeyDown:P=>{P.key==="Enter"&&Me()},placeholder:l("e.g. About")})})})]})}import{jsx as FR}from"react/jsx-runtime";import{createContext as PR,useCallback as LR,useContext as OR,useState as RR}from"react";import{useSelectHandler as AR}from"efficient-easel/draw/client";var Dl=["chat-bubble-left-right","chat-bubble-oval-left-ellipsis","chat","megaphone","phone","sparkles"],xr=Dl[0];var At="right";function Nl(e){return Dl.includes(e??"")?e:xr}function xg(e){return e==="left"?"left":At}function Ig(e){return/^#[0-9a-fA-F]{6}$/.test(e??"")?e.toLowerCase():""}var Ml={enabled:!0,title:"",subtitle:"",greeting:"",launcherColor:"",launcherIcon:"",launcherPosition:At,launcherLabel:"",showOnPhones:!0};function lj(e){return{enabled:e.enabled,title:e.title,subtitle:e.subtitle,greeting:e.greeting,launcherColor:Ig(e.launcherColor),launcherIcon:e.launcherIcon?Nl(e.launcherIcon):"",launcherPosition:xg(e.launcherPosition),launcherLabel:e.launcherLabel??"",showOnPhones:e.showOnPhones!==!1}}var hg=PR({chat:Ml,setChat:()=>{},selected:!1,setSelected:()=>{},select:()=>{},setSelectHandler:()=>{}});function sj({children:e,chat:o=Ml,onChatChange:t}){let[r,a]=RR(!1),n=LR(f=>t?.(f),[t]),{select:s,setSelectHandler:i}=AR();return FR(hg.Provider,{value:{chat:o,setChat:n,selected:r,setSelected:a,select:s,setSelectHandler:i},children:e})}var Hl=()=>OR(hg);import{jsx as Ic}from"react/jsx-runtime";import{DesktopIcon as BR,PhoneIcon as _R,TabletIcon as DR}from"efficient-easel/icons";import{VIEW_TIERS as NR,VIEW_TIER_LABEL as MR}from"efficient-easel/draw";var HR={desktop:Ic(BR,{}),tablet:Ic(DR,{}),mobile:Ic(_R,{})},gg=NR.map(e=>({id:e,get label(){return l(MR[e])},icon:HR[e]}));import{PreviewDeviceContext as z5}from"efficient-easel/draw/client";import{jsx as WR}from"react/jsx-runtime";import{createContext as zR,useCallback as bg,useContext as GR,useMemo as UR,useRef as $R}from"react";var qR=Object.fromEntries(tn.map(e=>[e,{value:"",error:null}])),yg=zR({links:qu,rows:qR,canSave:!1,saveLink:async()=>({ok:!1,error:"There is no website to save to."}),openPanel:()=>{},setOpenHandler:()=>{}});function hj({children:e,value:o}){let t=$R(()=>{}),r=bg(()=>t.current(),[]),a=bg(s=>{t.current=s},[]),n=UR(()=>({...o,openPanel:r,setOpenHandler:a}),[o,r,a]);return WR(yg.Provider,{value:n,children:e})}var ma=()=>GR(yg);import{jsx as jR}from"react/jsx-runtime";import{createContext as KR,useContext as VR,useMemo as YR,useState as XR}from"react";var Sg=KR(null);function Sj({children:e}){let[o,t]=XR(null),r=YR(()=>({surface:o,setSurface:t}),[o]);return jR(Sg.Provider,{value:r,children:e})}function Cg(){return VR(Sg)??{surface:null,setSurface:()=>{}}}import{createPreviewSelectionContext as ZR}from"efficient-easel/draw/client";var xa="Scrolling Bar",{Provider:wj,useSelection:Wl}=ZR("selectedHeroId");import{createPreviewSelectionContext as QR}from"efficient-easel/draw/client";var{Provider:Ej,useSelection:zl}=QR("selectedHeroPart");import{isShown as mA,lazyShowWhenContext as xA}from"efficient-shell/format";var Gl="product",JR="recordType",eA={key:Gl,label:"Product",fields:[]};var oA=new Map,tA=0;function Pj(){return[eA,...oA.values()]}function Lj(){return tA}function rA(e){let o=e?.[JR];return typeof o!="string"?Gl:o.trim()||Gl}function hc(e){return rA(e)===Gl}var gc="product",aA="tyre";var nA="productType",lA={[gc]:"alloy-wheel",[aA]:"tyre"},sA=["alloy-wheel","tyre"];function vg(e,o){return hc(o)?iA(o)??lA[e]??null:null}function iA(e){if(!hc(e))return null;let o=e?.[nA];return typeof o=="string"&&sA.includes(o)?o:null}var Ul=null,wg=null;function fA(e,o){Ul=e,wg=o}function _j(e){fA(e,null)}function Dj(){return Ul}function kg(){return wg==="dynamic"||Ul===gc}function Nj(e){return vg(Ul??"",e)??"alloy-wheel"}import{addShowWhenFacts as cA}from"efficient-shell/format";import{showWhenOf as bc,shownForOption as dA,truthy as uA,withRowRules as pA,withRowsShownWhen as $l,withShowWhen as ql}from"efficient-shell/format";var zj=cA;function Eg(e,o,t){let r=!1,a={};for(let[n,s]of Object.entries(e))mA(bc(s),o??{},t)?a[n]=s:r=!0;return r?a:e}function Fg(e,o,t,r){let a=fn(o,t,r);return{device:e,parentType:a?.item.type,parent:a?.item.props}}function Tg(e,o){if(!e||typeof e!="object")return!1;let t=e;if(typeof t.context=="string"&&(t.context===o||t.context.startsWith(`${o}.`)))return!0;if("not"in t)return Tg(t.not,o);for(let r of[t.all,t.any])if(Array.isArray(r)&&r.some(a=>Tg(a,o)))return!0;return!1}function Vj(e,o={}){return xA({parentType:()=>e.parent?.type??void 0,parent:()=>e.parent?.props??void 0,dynamicPage:()=>kg(),root:()=>e.appState?.data?.root?.props,...o})}var Lg=["one","side","stacked"];var Xj={one:"One",side:"Side by side",stacked:"Stacked"};function Og(e){return Lg.includes(e)?e:"one"}function Pg(e){return e==="one"?1:2}function IA(e,o){if(Lg.includes(e))return e;let t=Og(o);return t==="side"?"stacked":t}function yc(e){let o=Og(e.mediaLayout);return Math.max(Pg(o),Pg(IA(e.mediaLayoutPhone,o)))}var Ia=["media","image","image2"],Ir={media:"Media",image:"Image",image2:"Image 2"},ha={media:"heroMedia",image:"heroImage",image2:"heroImage2"};function jl(e,o){return e==="image"&&yc(o)>1?"Image 1":Ir[e]}var eK="Video file",oK="Upload a video file";function hA(e,o){return{field:"mediaType",is:e,default:o}}var gA=new Set(["HeroSingle"]),Rg="heroPart";function bA(e,o){return{...o,[Rg]:e}}function tK(e,{parts:o={},onlyFor:t,fallback:r,rules:a}){let n={...e};for(let s of["image","video"])for(let i of t[s])n[i]=ql(n[i],hA(s,r));for(let[s,i]of Object.entries(a??{}))i&&(n[s]=ql(n[s],i));for(let s of Ia)for(let i of o[s]??[])n[i]=bA(s,n[i]);return n}function yA(e){let o=e?.[Rg];return Ia.includes(o)?o:null}function Ag(e,o){let t={};for(let[r,a]of Object.entries(e))yA(a)===o&&(t[r]=a);return t}function Bg(e){if(!gA.has(e.type))return[];let o=[{part:"media",label:Ir.media,depth:0}];return(e.props.mediaType??"image")!=="video"&&(o.push({part:"image",label:jl("image",e.props),depth:1}),yc(e.props)>1&&o.push({part:"image2",label:jl("image2",e.props),depth:1})),o}function ga(e,o){return`${e}::${o}`}function _g(e){if(!e)return null;let o=e.lastIndexOf("::");if(o<=0)return null;let t=e.slice(o+2);return Ia.includes(t)?{nodeId:e.slice(0,o),part:t}:null}var rK="data-sf-hero-part";import{jsx as J,jsxs as it,Fragment as Ss}from"react/jsx-runtime";import{useState as kS}from"react";import{useEasel as WM}from"efficient-easel/easel";import{headWords as FS,InspectorHead as zM,InspectorIconButton as Bd}from"efficient-easel/chrome";import{DuplicateIcon as TS,TrashIcon as GM}from"efficient-easel/icons";import{panelFieldsOf as UM}from"efficient-easel/screen/lib/puck/panel-fields";import{jsx as T,Fragment as K,jsxs as X}from"react/jsx-runtime";import{BlockBannerIcon as vA,BlockBoxIcon as wA,BlockButtonIcon as kA,BlockDividerIcon as Ng,BlockFooterIcon as Mg,BlockHeadingIcon as TA,BlockProductIcon as EA,BlockSocialIcon as FA,BlockTextIcon as PA,ChatIcon as LA,GridIcon as OA,ImageIcon as Cc,MediaIcon as RA,PageIcon as AA}from"efficient-easel/icons";import{jsx as Sc,Fragment as SA,jsxs as CA}from"react/jsx-runtime";var Dg=CA(SA,{children:[Sc("circle",{cx:"9",cy:"20",r:"1.3"}),Sc("circle",{cx:"18",cy:"20",r:"1.3"}),Sc("path",{d:"M2.5 3.5h3l2.3 11.3a1.6 1.6 0 0 0 1.6 1.3h8.1a1.6 1.6 0 0 0 1.6-1.2L21 7H6"})]});var BA={header:X(K,{children:[T("rect",{x:"3",y:"5",width:"18",height:"14",rx:"2"}),T("path",{d:"M3 9.5h18"})]}),website:X(K,{children:[T("circle",{cx:"12",cy:"12",r:"9"}),T("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:X(K,{children:[T("circle",{cx:"6",cy:"12",r:"2.5"}),T("circle",{cx:"18",cy:"6",r:"2.5"}),T("circle",{cx:"18",cy:"18",r:"2.5"}),T("path",{d:"M8.2 10.8l7.6-3.6M8.2 13.2l7.6 3.6"})]}),ticker:X(K,{children:[T("rect",{x:"3",y:"8.5",width:"18",height:"7",rx:"2"}),T("path",{d:"M6 12h3.5M11.5 12h2M15.5 12h2.5"})]}),FooterLogo:X(K,{children:[T("path",{d:"M4 15.5h6M4 18h4"}),T("path",{d:"M14 8.5l3 7 3-7"})]}),FooterMenu:T("path",{d:"M6 7h12M6 11h12M6 15h8M6 19h8"}),FooterGroup:X(K,{children:[T("rect",{x:"4",y:"4",width:"16",height:"16",rx:"2",strokeDasharray:"3 2.5"}),T("path",{d:"M8 9h8M8 13h8M8 16h5"})]}),FooterText:T("path",{d:"M5 7h14M5 12h14M5 17h9"}),FooterEmailSignup:X(K,{children:[T("rect",{x:"3",y:"6",width:"18",height:"12",rx:"2"}),T("path",{d:"M3.5 7l8.5 6 8.5-6"})]}),SearchBlock:X(K,{children:[T("circle",{cx:"11",cy:"11",r:"6"}),T("path",{d:"M20 20l-4.2-4.2"})]}),CartBlock:Dg,CountrySwitchBlock:X(K,{children:[T("circle",{cx:"12",cy:"12",r:"8.5"}),T("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"})]}),AccountBlock:X(K,{children:[T("circle",{cx:"12",cy:"8",r:"4"}),T("path",{d:"M4.5 20c.8-3.8 3.8-6 7.5-6s6.7 2.2 7.5 6"})]}),ThemeSwitchBlock:X(K,{children:[T("circle",{cx:"12",cy:"12",r:"8.5"}),T("path",{d:"M12 3.5v17M12 5.5l6 6M12 10.5l5.2 5.2M12 15.5l2.8 2.8"})]}),LegalLineBlock:X(K,{children:[T("path",{d:"M3 9h18"}),T("path",{d:"M3 14h8M14 14h2M18 14h3"})]}),Hero:X(K,{children:[T("rect",{x:"3",y:"4",width:"18",height:"16",rx:"2"}),T("path",{d:"M7 13.5h7M7 16.5h10"})]}),HeroSlide:X(K,{children:[T("rect",{x:"3",y:"5",width:"18",height:"14",rx:"2"}),T("path",{d:"M7 15h6M16 9.5h.01M9.5 12l-2.5 3"})]}),HeroSingle:X(K,{children:[T("rect",{x:"3",y:"4",width:"18",height:"16",rx:"2"}),T("path",{d:"M10.5 8.5l4 2.5-4 2.5z"}),T("path",{d:"M7 17h7"})]}),Collections:X(K,{children:[T("rect",{x:"3",y:"5",width:"4.6",height:"14",rx:"1.3"}),T("rect",{x:"9.7",y:"5",width:"4.6",height:"14",rx:"1.3"}),T("rect",{x:"16.4",y:"5",width:"4.6",height:"14",rx:"1.3"})]}),CollectionCard:X(K,{children:[T("rect",{x:"6",y:"4",width:"12",height:"16",rx:"2"}),T("path",{d:"M9 15h6M9 17.5h4"})]}),AlloyWheelsListing:X(K,{children:[T("path",{d:"M3 5h5M3 9h5M3 13h5M3 17h5"}),T("rect",{x:"11.5",y:"5",width:"4.2",height:"5",rx:"1"}),T("rect",{x:"17.3",y:"5",width:"4.2",height:"5",rx:"1"}),T("rect",{x:"11.5",y:"12",width:"4.2",height:"5",rx:"1"}),T("rect",{x:"17.3",y:"12",width:"4.2",height:"5",rx:"1"})]}),CatalogFilterBar:X(K,{children:[T("path",{d:"M3 7h9M15.5 7H21"}),T("circle",{cx:"13.5",cy:"7",r:"1.7"}),T("path",{d:"M3 12h4M10.5 12H21"}),T("circle",{cx:"8.5",cy:"12",r:"1.7"}),T("path",{d:"M3 17h9M15.5 17H21"}),T("circle",{cx:"13.5",cy:"17",r:"1.7"})]}),ProductGrid:X(K,{children:[T("rect",{x:"3",y:"5",width:"4.8",height:"6",rx:"1"}),T("rect",{x:"9.6",y:"5",width:"4.8",height:"6",rx:"1"}),T("rect",{x:"16.2",y:"5",width:"4.8",height:"6",rx:"1"}),T("rect",{x:"3",y:"13",width:"4.8",height:"6",rx:"1"}),T("rect",{x:"9.6",y:"13",width:"4.8",height:"6",rx:"1"}),T("rect",{x:"16.2",y:"13",width:"4.8",height:"6",rx:"1"})]}),RelatedProducts:X(K,{children:[T("path",{d:"M3 5h10"}),T("rect",{x:"3",y:"9.5",width:"5",height:"9",rx:"1"}),T("rect",{x:"9.5",y:"9.5",width:"5",height:"9",rx:"1"}),T("rect",{x:"16",y:"9.5",width:"5",height:"9",rx:"1"})]}),Gallery:X(K,{children:[T("rect",{x:"3",y:"4",width:"11",height:"16",rx:"2"}),T("rect",{x:"15.5",y:"4",width:"5.5",height:"7.5",rx:"1.5"}),T("rect",{x:"15.5",y:"12.5",width:"5.5",height:"7.5",rx:"1.5"})]}),GalleryB:X(K,{children:[T("rect",{x:"3.5",y:"4",width:"7.5",height:"7.5",rx:"1.5"}),T("rect",{x:"13",y:"4",width:"7.5",height:"7.5",rx:"1.5"}),T("rect",{x:"3.5",y:"12.5",width:"7.5",height:"7.5",rx:"1.5"}),T("rect",{x:"13",y:"12.5",width:"7.5",height:"7.5",rx:"1.5"})]}),GalleryItem:X(K,{children:[T("rect",{x:"4",y:"5",width:"16",height:"14",rx:"2"}),T("circle",{cx:"9",cy:"10",r:"1.6"}),T("path",{d:"M20 15.5l-4.5-4L7 19"})]}),Events:X(K,{children:[T("rect",{x:"4",y:"5",width:"16",height:"15",rx:"2"}),T("path",{d:"M4 9.5h16M8.5 3v4M15.5 3v4M8 14h2M14 14h2"})]}),PostCard:X(K,{children:[T("rect",{x:"4",y:"3.5",width:"16",height:"17",rx:"2"}),T("rect",{x:"6.5",y:"6",width:"11",height:"6",rx:"1"}),T("path",{d:"M6.5 14.5h11M6.5 17.5h7"})]}),Manifesto:X(K,{children:[T("path",{d:"M7 8h3.2v4c0 1.6-1 2.6-3 3.2"}),T("path",{d:"M14 8h3.2v4c0 1.6-1 2.6-3 3.2"})]}),Stats:X(K,{children:[T("path",{d:"M3.5 20h17"}),T("path",{d:"M6 20v-7M11 20V7M16 20v-5M20.5 20v-9"})]}),Logos:X(K,{children:[T("circle",{cx:"6",cy:"12",r:"2.6"}),T("rect",{x:"10",y:"9.4",width:"5.2",height:"5.2",rx:"1.2"}),T("path",{d:"M19 9.2l2.4 5h-4.8z"})]}),Ticker:X(K,{children:[T("rect",{x:"3",y:"8.5",width:"18",height:"7",rx:"2"}),T("path",{d:"M6 12h3.5M11.5 12h2M15.5 12h2.5"})]}),SectionHeader:X(K,{children:[T("rect",{x:"3.5",y:"6",width:"5",height:"5",rx:"1.2"}),T("path",{d:"M11 8.5h9M3.5 15.5h17"})]}),IntroBleed:X(K,{children:[T("rect",{x:"3",y:"4",width:"18",height:"16",rx:"2"}),T("path",{d:"M3 13.5h18M7 16.8h6"})]}),Split:X(K,{children:[T("rect",{x:"3",y:"5",width:"8",height:"14",rx:"1.5"}),T("path",{d:"M14 8.5h6M14 12h6M14 15.5h4"})]}),Eyebrow:X(K,{children:[T("path",{d:"M4 8.5h4.5M11 8.5h9"}),T("path",{d:"M4 14.5h16"})]}),HeroGroup:X(K,{children:[T("rect",{x:"3.5",y:"4.5",width:"17",height:"15",rx:"2"}),T("path",{d:"M7 9h8M7 12.5h10M7 16h6"})]}),Form:X(K,{children:[T("rect",{x:"3",y:"4",width:"18",height:"16",rx:"2"}),T("path",{d:"M6.5 9h11M6.5 12.5h11"}),T("rect",{x:"6.5",y:"15",width:"6.5",height:"2.6",rx:"1.3"})]}),LogoBlock:T(K,{children:T("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:X(K,{children:[T("path",{d:"M12 4v6M9.5 6.5L12 4l2.5 2.5M12 20v-6M9.5 17.5L12 20l2.5-2.5"}),T("path",{d:"M5 13h14",strokeDasharray:"2 2.5"})]}),ContactRouting:X(K,{children:[T("rect",{x:"3",y:"4",width:"5",height:"5",rx:"1"}),T("rect",{x:"9.5",y:"4",width:"5",height:"5",rx:"1"}),T("rect",{x:"16",y:"4",width:"5",height:"5",rx:"1"}),T("path",{d:"M4 13.5h11M4 17.5h7"}),T("path",{d:"M17 15l3 2-3 2"})]}),CustomHTML:T("path",{d:"M9 8l-4 4 4 4M15 8l4 4-4 4"})},_A=T("rect",{x:"4",y:"4",width:"16",height:"16",rx:"2.5"}),DA={footer:Mg,Footer:Mg,Divider:Ng,FooterDivider:Ng,Banner:vA,Flex:wA,FooterSocial:FA,page:AA,chat:LA,Heading:TA,Text:PA,ImageBlock:Cc,ButtonBlock:kA,Grid:OA,ProductRef:EA,heroMedia:RA,heroImage:Cc,heroImage2:Cc},NA={MenuBlock:"FooterMenu",EmailFormBlock:"FooterEmailSignup",SocialLogosBlock:"FooterSocial",SiteHeader:"header",SiteFooter:"footer"};function Bt({type:e,size:o=16,className:t}){let r=NA[e]??e,a=DA[r];return a?T(a,{size:o,className:t}):T("svg",{width:o,height:o,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:1.7,strokeLinecap:"round",strokeLinejoin:"round",className:t,"aria-hidden":"true",children:BA[r]??_A})}import{PanelHideButton as _d}from"efficient-easel/screen/components/SidePanelHead";import{useEaselSession as $M}from"efficient-easel/screen/lib/session-context";import{jsx as re,jsxs as vc,Fragment as MA}from"react/jsx-runtime";import{useEffect as HA,useId as Hg,useState as WA}from"react";import{IconPicker as zA}from"efficient-shell/ui";import{SettingsDefaultReset as GA,SettingsField as hr,SettingsSegmented as UA,SettingsSwitch as Wg}from"efficient-easel/panel";import*as $A from"efficient-easel/icons";import{ButtonIcon as qA,ButtonIconIcon as jA,EyeIcon as KA,PhoneIcon as VA,PlacementIcon as YA,TypeIcon as XA}from"efficient-easel/icons";var ZA="Chat with us",QA="We usually reply within a few minutes",JA="Hi! Ask us anything \u2014 about a wheel, an order, or fitment. Leave your details and we\u2019ll reply.";function Kl({label:e,value:o,placeholder:t,onCommit:r,multiline:a=!1,hint:n}){let[s,i]=WA(o);HA(()=>i(o),[o]);let f=()=>{s!==o&&r(s)};return re(hr,{label:e,icon:re(XA,{}),changed:o!=="",action:re(gr,{label:e,changed:o!=="",onReset:()=>r("")}),hint:n,children:a?re("textarea",{value:s,placeholder:t,rows:3,onChange:u=>i(u.target.value),onBlur:f,"aria-label":e}):re("input",{type:"text",value:s,placeholder:t,onChange:u=>i(u.target.value),onBlur:f,onKeyDown:u=>{u.key==="Enter"&&u.currentTarget.blur()},"aria-label":e,autoComplete:"off"})})}function gr({label:e,changed:o,onReset:t}){return re(GA,{words:Q()?.panel,label:e,changed:o,onReset:t})}function eB({label:e,icon:o,checked:t,fallback:r,onChange:a,hint:n}){let s=Hg();return re(hr,{label:e,labelId:s,icon:o,changed:t!==r,action:vc("span",{className:"inline-flex items-center gap-2",children:[re(Wg,{checked:t,onChange:a,ariaLabelledBy:s}),re(gr,{label:e,changed:t!==r,onReset:()=>a(r)})]}),hint:n})}function oB(e){let o=e.replace(/(^|-)([a-z])/g,(r,a,n)=>n.toUpperCase()),t=$A[`${o}Icon`];return t?re(t,{size:16}):null}var tB=Dl.map(e=>({value:e,icon:oB(e)}));function rB(){let{theme:e}=V(),o=Je(e).themes[0];return zr(o)??o?.accent??""}function zg(){let{chat:e,setChat:o}=Hl(),t=Hg(),r=rB(),a=e.launcherIcon?Nl(e.launcherIcon):xr;return vc(MA,{children:[re(hr,{label:l("Show the chat bubble"),labelId:t,icon:re(KA,{}),changed:!e.enabled,action:vc("span",{className:"inline-flex items-center gap-2",children:[re(Wg,{checked:e.enabled,onChange:n=>o({enabled:n}),ariaLabelledBy:t}),re(gr,{label:l("Show the chat bubble"),changed:!e.enabled,onReset:()=>o({enabled:!0})})]}),hint:e.enabled?l("The floating chat bubble shows in the corner of every page."):l("The chat bubble is hidden across the whole site.")}),re(rr,{label:"Look"}),re(hr,{label:l("Button color"),icon:re(qA,{}),changed:e.launcherColor!=="",action:re(io,{label:l("Button color"),value:e.launcherColor,inherited:r,caption:e.launcherColor?void 0:l("Site button color"),onChange:n=>o({launcherColor:n}),after:re(gr,{label:l("Button color"),changed:e.launcherColor!=="",onReset:()=>o({launcherColor:""})})})}),re(hr,{label:l("Icon"),icon:re(jA,{}),changed:a!==xr,action:re(gr,{label:l("Icon"),changed:a!==xr,onReset:()=>o({launcherIcon:""})}),children:re(zA,{label:l("Icon"),value:a,options:tB,onChange:n=>o({launcherIcon:n===xr?"":n})})}),re(hr,{label:l("Position"),icon:re(YA,{}),changed:e.launcherPosition!==At,action:re(gr,{label:l("Position"),changed:e.launcherPosition!==At,onReset:()=>o({launcherPosition:At})}),children:re(UA,{options:[{label:l("Right"),id:"right"},{label:l("Left"),id:"left"}],value:e.launcherPosition,ariaLabel:l("Position"),onChange:n=>o({launcherPosition:n})})}),re(Kl,{label:l("Label"),value:e.launcherLabel,placeholder:l("Icon only"),onCommit:n=>o({launcherLabel:n}),hint:l("Shows when a visitor points at the button")}),re(eB,{label:l("Show on phones"),icon:re(VA,{}),checked:e.showOnPhones,fallback:Ml.showOnPhones,onChange:n=>o({showOnPhones:n})}),re(rr,{label:"Wording"}),re(Kl,{label:l("Title"),value:e.title,placeholder:ZA,onCommit:n=>o({title:n})}),re(Kl,{label:l("Subtitle"),value:e.subtitle,placeholder:QA,onCommit:n=>o({subtitle:n})}),re(Kl,{label:l("Greeting message"),value:e.greeting,placeholder:JA,onCommit:n=>o({greeting:n}),multiline:!0}),re("p",{className:"es-field-hint sf-hint-keep",children:l("Leave a field blank to use the built-in wording.")})]})}import{jsx as _t,Fragment as qc,jsxs as jg}from"react/jsx-runtime";import{useEffect as AB,useId as $g,useState as qg}from"react";import{SettingsField as BB}from"efficient-easel/panel";import{jsx as wB}from"react/jsx-runtime";import{forwardRef as aB,createElement as wc}from"react";var Gg={outline:{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"},filled:{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"currentColor",stroke:"none"}};var $=(e,o,t,r)=>{let a=aB(({color:n="currentColor",size:s=24,stroke:i=2,title:f,className:u,children:p,...m},x)=>wc("svg",{ref:x,...Gg[e],width:s,height:s,className:["tabler-icon",`tabler-icon-${o}`,u].filter(Boolean).join(" "),...e==="filled"?{fill:n}:{strokeWidth:i,stroke:n},...m},[f&&wc("title",{key:"svg-title"},f),...r.map(([I,b])=>wc(I,b)),...Array.isArray(p)?p:[p]]));return a.displayName=`${t}`,a};var nB=[["path",{d:"M7 10v4h3v7h4v-7h3l1 -4h-4v-2a1 1 0 0 1 1 -1h3v-4h-3a5 5 0 0 0 -5 5v2h-3",key:"svg-0"}]],kc=$("outline","brand-facebook","BrandFacebook",nB);var lB=[["path",{d:"M3 7a4 4 0 0 1 4 -4h10a4 4 0 0 1 4 4v10a4 4 0 0 1 -4 4h-10a4 4 0 0 1 -4 -4l0 -10",key:"svg-0"}],["path",{d:"M8.5 12a3.5 3.5 0 1 0 7 0a3.5 3.5 0 0 0 -7 0",key:"svg-1"}],["path",{d:"M17 7v.01",key:"svg-2"}]],Tc=$("outline","brand-instagram","BrandInstagram",lB);var sB=[["path",{d:"M21 10.663c0 -4.224 -4.041 -7.663 -9 -7.663s-9 3.439 -9 7.663c0 3.783 3.201 6.958 7.527 7.56c1.053 .239 .932 .644 .696 2.133c-.039 .238 -.184 .932 .777 .512c.96 -.42 5.18 -3.201 7.073 -5.48c1.304 -1.504 1.927 -3.029 1.927 -4.715v-.01",key:"svg-0"}]],Ec=$("outline","brand-line","BrandLine",sB);var iB=[["path",{d:"M8 11v5",key:"svg-0"}],["path",{d:"M8 8v.01",key:"svg-1"}],["path",{d:"M12 16v-5",key:"svg-2"}],["path",{d:"M16 16v-3a2 2 0 1 0 -4 0",key:"svg-3"}],["path",{d:"M3 7a4 4 0 0 1 4 -4h10a4 4 0 0 1 4 4v10a4 4 0 0 1 -4 4h-10a4 4 0 0 1 -4 -4l0 -10",key:"svg-4"}]],Fc=$("outline","brand-linkedin","BrandLinkedin",iB);var fB=[["path",{d:"M8 20l4 -9",key:"svg-0"}],["path",{d:"M10.7 14c.437 1.263 1.43 2 2.55 2c2.071 0 3.75 -1.554 3.75 -4a5 5 0 1 0 -9.7 1.7",key:"svg-1"}],["path",{d:"M3 12a9 9 0 1 0 18 0a9 9 0 1 0 -18 0",key:"svg-2"}]],Pc=$("outline","brand-pinterest","BrandPinterest",fB);var cB=[["path",{d:"M15 10l-4 4l6 6l4 -16l-18 7l4 2l2 6l3 -4",key:"svg-0"}]],Lc=$("outline","brand-telegram","BrandTelegram",cB);var dB=[["path",{d:"M21 7.917v4.034a9.948 9.948 0 0 1 -5 -1.951v4.5a6.5 6.5 0 1 1 -8 -6.326v4.326a2.5 2.5 0 1 0 4 2v-11.5h4.083a6.005 6.005 0 0 0 4.917 4.917",key:"svg-0"}]],Oc=$("outline","brand-tiktok","BrandTiktok",dB);var uB=[["path",{d:"M16.5 10c3.038 0 5.5 2.015 5.5 4.5c0 1.397 -.778 2.645 -2 3.47l0 2.03l-1.964 -1.178a6.649 6.649 0 0 1 -1.536 .178c-3.038 0 -5.5 -2.015 -5.5 -4.5s2.462 -4.5 5.5 -4.5",key:"svg-0"}],["path",{d:"M11.197 15.698c-.69 .196 -1.43 .302 -2.197 .302a8.008 8.008 0 0 1 -2.612 -.432l-2.388 1.432v-2.801c-1.237 -1.082 -2 -2.564 -2 -4.199c0 -3.314 3.134 -6 7 -6c3.782 0 6.863 2.57 7 5.785l0 .233",key:"svg-1"}],["path",{d:"M10 8h.01",key:"svg-2"}],["path",{d:"M7 8h.01",key:"svg-3"}],["path",{d:"M15 14h.01",key:"svg-4"}],["path",{d:"M18 14h.01",key:"svg-5"}]],Rc=$("outline","brand-wechat","BrandWechat",uB);var pB=[["path",{d:"M3 21l1.65 -3.8a9 9 0 1 1 3.4 2.9l-5.05 .9",key:"svg-0"}],["path",{d:"M9 10a.5 .5 0 0 0 1 0v-1a.5 .5 0 0 0 -1 0v1a5 5 0 0 0 5 5h1a.5 .5 0 0 0 0 -1h-1a.5 .5 0 0 0 0 1",key:"svg-1"}]],Ac=$("outline","brand-whatsapp","BrandWhatsapp",pB);var mB=[["path",{d:"M4 4l11.733 16h4.267l-11.733 -16l-4.267 0",key:"svg-0"}],["path",{d:"M4 20l6.768 -6.768m2.46 -2.46l6.772 -6.772",key:"svg-1"}]],Bc=$("outline","brand-x","BrandX",mB);var xB=[["path",{d:"M2 8a4 4 0 0 1 4 -4h12a4 4 0 0 1 4 4v8a4 4 0 0 1 -4 4h-12a4 4 0 0 1 -4 -4v-8",key:"svg-0"}],["path",{d:"M10 9l5 3l-5 3l0 -6",key:"svg-1"}]],_c=$("outline","brand-youtube","BrandYoutube",xB);var IB=[["path",{d:"M18 2a1 1 0 0 1 .993 .883l.007 .117v4a1 1 0 0 1 -.883 .993l-.117 .007h-3v1h3a1 1 0 0 1 .991 1.131l-.02 .112l-1 4a1 1 0 0 1 -.858 .75l-.113 .007h-2v6a1 1 0 0 1 -.883 .993l-.117 .007h-4a1 1 0 0 1 -.993 -.883l-.007 -.117v-6h-2a1 1 0 0 1 -.993 -.883l-.007 -.117v-4a1 1 0 0 1 .883 -.993l.117 -.007h2v-1a6 6 0 0 1 5.775 -5.996l.225 -.004h3z",key:"svg-0"}]],Dc=$("filled","brand-facebook-filled","BrandFacebookFilled",IB);var hB=[["path",{d:"M16 3a5 5 0 0 1 5 5v8a5 5 0 0 1 -5 5h-8a5 5 0 0 1 -5 -5v-8a5 5 0 0 1 5 -5zm-4 5a4 4 0 0 0 -3.995 3.8l-.005 .2a4 4 0 1 0 4 -4m4.5 -1.5a1 1 0 0 0 -.993 .883l-.007 .127a1 1 0 0 0 1.993 .117l.007 -.127a1 1 0 0 0 -1 -1",key:"svg-0"}]],Nc=$("filled","brand-instagram-filled","BrandInstagramFilled",hB);var gB=[["path",{d:"M17 2a5 5 0 0 1 5 5v10a5 5 0 0 1 -5 5h-10a5 5 0 0 1 -5 -5v-10a5 5 0 0 1 5 -5zm-9 8a1 1 0 0 0 -1 1v5a1 1 0 0 0 2 0v-5a1 1 0 0 0 -1 -1m6 0a3 3 0 0 0 -1.168 .236l-.125 .057a1 1 0 0 0 -1.707 .707v5a1 1 0 0 0 2 0v-3a1 1 0 0 1 2 0v3a1 1 0 0 0 2 0v-3a3 3 0 0 0 -3 -3m-6 -3a1 1 0 0 0 -.993 .883l-.007 .127a1 1 0 0 0 1.993 .117l.007 -.127a1 1 0 0 0 -1 -1",key:"svg-0"}]],Mc=$("filled","brand-linkedin-filled","BrandLinkedinFilled",gB);var bB=[["path",{d:"M17 3.34a10 10 0 0 1 -8.512 18.023l2.364 -5.315a3.5 3.5 0 0 0 2.398 .952c2.708 0 4.75 -2.089 4.75 -5a6 6 0 1 0 -11.64 2.041a1 1 0 1 0 1.88 -.682a4 4 0 1 1 7.76 -1.36c0 1.818 -1.156 3.001 -2.75 3.001c-.609 0 -1.153 -.361 -1.478 -1.022l1.142 -2.572a1 1 0 0 0 -1.828 -.812l-4.392 9.882a10 10 0 0 1 -4.694 -8.476l.005 -.324a10 10 0 0 1 14.995 -8.336",key:"svg-0"}]],Hc=$("filled","brand-pinterest-filled","BrandPinterestFilled",bB);var yB=[["path",{d:"M16.083 2h-4.083a1 1 0 0 0 -1 1v11.5a1.5 1.5 0 1 1 -2.519 -1.1l.12 -.1a1 1 0 0 0 .399 -.8v-4.326a1 1 0 0 0 -1.23 -.974a7.5 7.5 0 0 0 1.73 14.8l.243 -.005a7.5 7.5 0 0 0 7.257 -7.495v-2.7l.311 .153c1.122 .53 2.333 .868 3.59 .993a1 1 0 0 0 1.099 -.996v-4.033a1 1 0 0 0 -.834 -.986a5.005 5.005 0 0 1 -4.097 -4.096a1 1 0 0 0 -.986 -.835z",key:"svg-0"}]],Wc=$("filled","brand-tiktok-filled","BrandTiktokFilled",yB);var SB=[["path",{d:"M18.497 4.409a10 10 0 0 1 -10.36 16.828l-.223 -.098l-4.759 .849l-.11 .011a1 1 0 0 1 -.11 0l-.102 -.013l-.108 -.024l-.105 -.037l-.099 -.047l-.093 -.058l-.014 -.011l-.012 -.007l-.086 -.073l-.077 -.08l-.067 -.088l-.056 -.094l-.034 -.07l-.04 -.108l-.028 -.128l-.012 -.102a1 1 0 0 1 0 -.125l.012 -.1l.024 -.11l.045 -.122l1.433 -3.304l-.009 -.014a10 10 0 0 1 1.549 -12.454l.215 -.203a10 10 0 0 1 13.226 -.217m-8.997 3.09a1.5 1.5 0 0 0 -1.5 1.5v1a6 6 0 0 0 6 6h1a1.5 1.5 0 0 0 0 -3h-1l-.144 .007a1.5 1.5 0 0 0 -1.128 .697l-.042 .074l-.022 -.007a4.01 4.01 0 0 1 -2.435 -2.435l-.008 -.023l.075 -.041a1.5 1.5 0 0 0 .704 -1.272v-1a1.5 1.5 0 0 0 -1.5 -1.5",key:"svg-0"}]],zc=$("filled","brand-whatsapp-filled","BrandWhatsappFilled",SB);var CB=[["path",{d:"M8.267 3a1 1 0 0 1 .73 .317l.076 .092l4.274 5.828l5.946 -5.944a1 1 0 0 1 1.497 1.32l-.083 .094l-6.163 6.162l6.262 8.54a1 1 0 0 1 -.697 1.585l-.109 .006h-4.267a1 1 0 0 1 -.73 -.317l-.076 -.092l-4.276 -5.829l-5.944 5.945a1 1 0 0 1 -1.497 -1.32l.083 -.094l6.161 -6.163l-6.26 -8.539a1 1 0 0 1 .697 -1.585l.109 -.006h4.267z",key:"svg-0"}]],Gc=$("filled","brand-x-filled","BrandXFilled",CB);var vB=[["path",{d:"M18 3a5 5 0 0 1 5 5v8a5 5 0 0 1 -5 5h-12a5 5 0 0 1 -5 -5v-8a5 5 0 0 1 5 -5zm-9 6v6a1 1 0 0 0 1.514 .857l5 -3a1 1 0 0 0 0 -1.714l-5 -3a1 1 0 0 0 -1.514 .857z",key:"svg-0"}]],Uc=$("filled","brand-youtube-filled","BrandYoutubeFilled",vB);var _V="outline",Vl={fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},kB={},$c={fillRule:"evenodd"},TB=[["path",{...Vl,d:"M21 4L3 11L7 13L9 19L12 15L17 20z"}],["path",{...$c,d:"M21 4L3 11L7 13L9 19L12 15L17 20zM15.212 8.939 10.576 13.576 11.424 14.424 16.061 9.788z"}]],EB=[["path",{...Vl,d:["M21 10.663c0 -4.224 -4.041 -7.663 -9 -7.663s-9 3.439 -9 7.663","c0 3.783 3.201 6.958 7.527 7.56c1.053 .239 .932 .644 .696 2.133","c-.039 .238 -.184 .932 .777 .512c.96 -.42 5.18 -3.201 7.073 -5.48","c1.304 -1.504 1.927 -3.029 1.927 -4.715v-.01z"].join("")}],["path",{...kB,d:["M21 10.663c0 -4.224 -4.041 -7.663 -9 -7.663s-9 3.439 -9 7.663","c0 3.783 3.201 6.958 7.527 7.56c1.053 .239 .932 .644 .696 2.133","c-.039 .238 -.184 .932 .777 .512c.96 -.42 5.18 -3.201 7.073 -5.48","c1.304 -1.504 1.927 -3.029 1.927 -4.715v-.01z"].join("")}]],FB=[["path",{...Vl,d:["M16.5 10c3.038 0 5.5 2.015 5.5 4.5c0 1.397 -.778 2.645 -2 3.47l0 2.03l-1.964 -1.178","a6.649 6.649 0 0 1 -1.536 .178c-3.038 0 -5.5 -2.015 -5.5 -4.5s2.462 -4.5 5.5 -4.5z"].join("")}],["path",{...Vl,d:["M8.319 15.972L7.84 15.918L7.349 15.832L6.865 15.715L6.388 15.568L4 17L4 14.199","L3.559 13.775L3.197 13.356L2.877 12.91L2.603 12.439L2.376 11.946L2.201 11.433","L2.079 10.902L2.016 10.405L2.001 9.897L2.036 9.386L2.12 8.889L2.25 8.405L2.425 7.937","L2.642 7.486L2.9 7.055L3.195 6.645L3.459 6.333L3.744 6.037L4.05 5.757L4.377 5.495","L4.723 5.25L5.086 5.025L5.467 4.819L5.864 4.634L6.275 4.471L6.701 4.331L7.139 4.214","L7.589 4.122L8.05 4.055L8.521 4.014L9.352 4.007L9.815 4.04L10.269 4.098L10.713 4.181","L11.146 4.287L11.567 4.416L11.975 4.567L12.369 4.739L12.748 4.932L13.112 5.143","L13.459 5.374L13.788 5.622L14.172 5.956L14.458 6.241L14.722 6.542L14.965 6.856","L15.217 7.237A8.35 7.35 0 0 0 8.319 15.972z"].join("")}],["path",{...$c,d:["M8.319 15.972L7.84 15.918L7.349 15.832L6.865 15.715L6.388 15.568L4 17L4 14.199","L3.559 13.775L3.197 13.356L2.877 12.91L2.603 12.439L2.376 11.946L2.201 11.433","L2.079 10.902L2.016 10.405L2.001 9.897L2.036 9.386L2.12 8.889L2.25 8.405L2.425 7.937","L2.642 7.486L2.9 7.055L3.195 6.645L3.459 6.333L3.744 6.037L4.05 5.757L4.377 5.495","L4.723 5.25L5.086 5.025L5.467 4.819L5.864 4.634L6.275 4.471L6.701 4.331L7.139 4.214","L7.589 4.122L8.05 4.055L8.521 4.014L9.352 4.007L9.815 4.04L10.269 4.098L10.713 4.181","L11.146 4.287L11.567 4.416L11.975 4.567L12.369 4.739L12.748 4.932L13.112 5.143","L13.459 5.374L13.788 5.622L14.172 5.956L14.458 6.241L14.722 6.542L14.965 6.856","L15.217 7.237A8.35 7.35 0 0 0 8.319 15.972zM5.25 7.9a0.85 0.85 0 1 0 1.7 0","a0.85 0.85 0 1 0 -1.7 0zM8.25 7.9a0.85 0.85 0 1 0 1.7 0a0.85 0.85 0 1 0 -1.7 0z"].join("")}],["path",{...$c,d:["M16.5 10c3.038 0 5.5 2.015 5.5 4.5c0 1.397 -.778 2.645 -2 3.47l0 2.03l-1.964 -1.178","a6.649 6.649 0 0 1 -1.536 .178c-3.038 0 -5.5 -2.015 -5.5 -4.5s2.462 -4.5 5.5 -4.5z","M14.15 14a0.85 0.85 0 1 0 1.7 0a0.85 0.85 0 1 0 -1.7 0zM17.15 14","a0.85 0.85 0 1 0 1.7 0a0.85 0.85 0 1 0 -1.7 0z"].join("")}]],PB=$("filled","brand-telegram-filled","BrandTelegramFilled",TB),LB=$("filled","brand-line-filled","BrandLineFilled",EB),OB=$("filled","brand-wechat-filled","BrandWechatFilled",FB),RB={instagram:{outline:Tc,solid:Nc},facebook:{outline:kc,solid:Dc},tiktok:{outline:Oc,solid:Wc},youtube:{outline:_c,solid:Uc},x:{outline:Bc,solid:Gc},linkedin:{outline:Fc,solid:Mc},pinterest:{outline:Pc,solid:Hc},whatsapp:{outline:Ac,solid:zc},telegram:{outline:Lc,solid:PB},line:{outline:Ec,solid:LB},wechat:{outline:Rc,solid:OB}};function Ug({platform:e,iconStyle:o,size:t}){let r=RB[e][o];return wB(r,{size:t,stroke:1.75,"aria-hidden":"true",focusable:"false"})}var _B={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 DB({platform:e}){let{rows:o,saveLink:t}=ma(),{value:r,error:a}=o[e],[n,s]=qg(r),[i,f]=qg(!1),u=$g(),p=$g();AB(()=>s(r),[r]);let m=async()=>{if(n.trim()===r){n!==r&&s(r);return}f(!0),await t(e,n),f(!1)},x=$u[e];return jg(qc,{children:[_t(BB,{label:l(x),htmlFor:u,icon:_t(Ug,{platform:e,iconStyle:"outline",size:18}),children:_t("input",{id:u,type:"text",inputMode:"url",value:n,placeholder:_B[e],onChange:I=>s(I.target.value),onBlur:()=>{m()},onKeyDown:I=>{I.key==="Enter"&&I.currentTarget.blur(),I.key==="Escape"&&(s(r),I.currentTarget.blur())},"aria-invalid":a?!0:void 0,"aria-describedby":a?p:void 0,"aria-busy":i||void 0,autoComplete:"off",spellCheck:!1})}),a&&_t("p",{id:p,className:"sf-note sf-note--error",role:"alert",children:a})]})}function Kg({unavailable:e}){let{canSave:o}=ma();return!o&&e?_t(qc,{children:e}):jg(qc,{children:[_t("p",{className:"es-field-hint sf-hint-keep",children:l("Paste a link to each profile. A platform left empty shows nothing on the site.")}),tn.map(t=>_t(DB,{platform:t},t))]})}import{jsx as vr,jsxs as TD}from"react/jsx-runtime";import{useId as ED,useMemo as FD}from"react";import{useEasel as PD}from"efficient-easel/easel";import{SettingsField as LD,SettingsSwitch as OD}from"efficient-easel/panel";import{EyeIcon as RD}from"efficient-easel/icons";import{jsx as Po,jsxs as rs}from"react/jsx-runtime";import{useCallback as Sr,useEffect as Cr,useId as bD,useRef as $o,useState as Ea}from"react";var Vg="data-puck-overlay-portal";function Yl(e){return e.setAttribute(Vg,"true"),()=>e.removeAttribute(Vg)}import{jsx as va,jsxs as mb}from"react/jsx-runtime";var jc="small",Kc="dot",NB=[{label:"Small",value:"small"},{label:"Display",value:"display"}],MB=[{label:"Dot \u25CF",value:"dot"},{label:"Cross \u2715",value:"cross"},{label:"Slash /",value:"slash"},{label:"Triangle \u25BC",value:"triangle"},{label:"None",value:"none"}],Yg={dot:"\u25CF",cross:"\u2715",slash:"/",triangle:"\u25BC",none:""},HB={small:"font-mono text-[length:var(--size-label,14px)] uppercase tracking-[0.25em] max-[800px]:text-[length:var(--size-label,12px)]",display:"font-display font-medium text-[length:var(--size-headingMedium,44px)] uppercase leading-none tracking-[0.005em] max-[800px]:text-[length:var(--size-headingMedium,28px)]"},WB={small:{dot:"",cross:"text-[0.77em]",slash:"text-[0.77em]",triangle:"",none:""},display:{dot:"text-[0.3em]",cross:"text-[0.64em]",slash:"text-[0.64em]",triangle:"text-[0.3em]",none:""}};function Xg(e){return eo(NB,jc,e)}function Zg(e){return eo(MB,Kc,e)}function Qg(e){return HB[e]}function Jg(e,o){return WB[e][o]}var Vc="left",zB=[{label:"Left",value:"left",cell:"left"},{label:"Right",value:"right",cell:"right"},{label:"Up",value:"up",cell:"top"},{label:"Down",value:"down",cell:"bottom"}],GB={left:"storefront-ticker",right:"storefront-ticker-right",up:"storefront-ticker-up",down:"storefront-ticker-down"};function eb(e){return eo(zB,Vc,e)}function ob(e){return e==="up"||e==="down"}function tb(e,o){return`${GB[e]} ${o}s linear infinite`}import{jsx as pe,jsxs as Qc}from"react/jsx-runtime";import{Fragment as ub}from"react";import{Fragment as VB,jsx as Xc}from"react/jsx-runtime";import{Fragment as nb,jsx as ya,jsxs as qB}from"react/jsx-runtime";import{createContext as Yc,useContext as Sa,useId as jB,useMemo as KB}from"react";var ba="@name",rb="@body",ab="@value",ZV={[ba]:"Name",[rb]:"Body",[ab]:"Value"},UB={TimelineTrack:{"entries.date":ba,"entries.title":ba,"entries.blurb":rb},Footprint:{"offices.city":ba},Stats:{"items.label":ba,"items.value":ab}};function $B(e){let{key:o,row:t}=po(e);return t?`${o}.${t.rowKey}`:null}function Xl(e,o){if(!e)return o;let t=$B(o);return t?UB[e]?.[t]??o:o}var Zl=Yc(null),lb=Yc(null),sb=Yc(null);function rY({needles:e,styles:o,type:t,children:r}){let a=jB(),n=JSON.stringify([a,e,o,t]),s=KB(()=>Fh(e,o,a,i=>Xl(t,i),i=>kh(t,i)),[n]);return s?qB(nb,{children:[ya("style",{"data-sf-part-styles":"",dangerouslySetInnerHTML:{__html:Ph(s).replace(/</g,"\\3c ")}}),ya(Zl.Provider,{value:s,children:r})]}):ya(nb,{children:r})}function ib(e){let o=Sa(Zl),t=Sa(lb),r=Lh(o,e);return r&&r.stamp!==t?r:null}function aY(e){return Jf(Sa(Zl),e)}function fb({stamp:e,children:o}){return ya(lb.Provider,{value:e,children:o})}function nY({children:e}){let o=Sa(Zl);return ya(sb.Provider,{value:o,children:e})}function lY(e){return Jf(Sa(sb),e)}function Ca({value:e,children:o}){let t=ib(e);return t?Xc(fb,{stamp:t.stamp,children:Xc("span",{[jf]:t.stamp,...t.textStyle?{[sr]:t.textStyle}:{},children:o})}):Xc(VB,{children:o})}import{jsx as Zc,Fragment as YB}from"react/jsx-runtime";function cb({className:e=""}){return Zc("sup",{className:`text-accent tracking-normal text-[length:min(1em,max(0.75em,11px))] ${e}`,children:"\xAE"})}function Ql(e){if(!e.includes("\xAE"))return e;let o=e.split("\xAE"),t=[];return o.forEach((r,a)=>{r&&t.push(r),a<o.length-1&&t.push(Zc(cb,{},`r${a}`))}),Zc(YB,{children:t})}var pY=cb;function Jc(e,o=!1){let t=r_(o),r=vi(e);if(r.length===1){let[n]=r,s=Ci(n),i=s?o_(s,n.children):n.children;return pe(Ca,{value:e,children:Jl(i,t)})}let a=[];return r.forEach((n,s)=>{if(n.bullet){a.push(pe("span",{"data-sf-bullet":"",className:XB,children:Jl(n.children,t)},s));return}if(n.number!=null){a.push(Qc("span",{"data-sf-number":n.number,className:ZB,children:[Qc("span",{className:QB,children:[n.number,"."]}),Jl(n.children,t)]},s));return}s>0&&!JB(r[s-1])&&a.push(pe("br",{},`br${s}`)),a.push(pe(ub,{children:Jl(n.children,t)},s))}),pe(Ca,{value:e,children:a})}var XB="relative block pl-6 before:absolute before:left-1.5 before:font-bold before:text-accent before:content-['\xB7']",ZB="relative block pl-[2em]",QB="absolute left-0 w-[1.6em] text-right tabular-nums";function JB(e){return e.bullet||e.number!=null}var e_="text-accent underline underline-offset-[0.18em]";function o_(e,o){let[t,...r]=o;return t?.kind==="text"?[{kind:"text",text:`${e}${t.text}`},...r]:[{kind:"text",text:e},...o]}function t_(e){if(e)return Eh(e)?e:Object.hasOwn(Do,e)?Do[e]:void 0}function Jl(e,o){let t=[],r=!1;return e.forEach((a,n)=>{if(a.kind==="text"){t.push(pe("span",{children:Ql(a.text)},n)),r=!0;return}r||t.push(pe("span",{},`e${n}`)),t.push(pb(a,n,o)),r=!1}),r||t.push(pe("span",{},"end")),t}function db(e,o){return e.length===1&&e[0].kind==="text"?Ql(e[0].text):e.map((t,r)=>t.kind==="text"?pe(ub,{children:Ql(t.text)},r):pb(t,r,o))}function r_(e){return e?"font-normal italic text-accent":"not-italic text-accent"}function CY(e){return pe(Ca,{value:e,children:pe("span",{children:e})})}function pb(e,o,t){if(e.kind==="link")return pe("a",{href:e.href,className:e_,children:db(e.children,t)},o);let r=db(e.children,t),a=Vp[e.kind];if(a)return pe("span",{[Yp]:a,children:r},o);switch(e.kind){case"underline":return pe("u",{children:r},o);case"sup":return pe("sup",{children:r},o);case"sub":return pe("sub",{children:r},o);case"color":{let n=t_(e.color);return n?pe("span",{style:{color:n},children:r},o):pe("span",{children:r},o)}case"accent":case"highlight":return pe("em",{className:t,children:r},o);case"bold":return pe("strong",{className:"font-semibold",children:r},o);case"italic":return pe("em",{className:"italic",children:r},o);case"strike":return pe("s",{className:"line-through",children:r},o);default:return pe("span",{children:r},o)}}function vY(e,o=!0){let t=e.split(`
|
|
6
|
+
`);return pe(Ca,{value:e,children:t.map((r,a)=>Qc("span",{children:[Jc(r,o),a<t.length-1?pe("br",{}):null]},a))})}function wY(e){return e.split(/\n\s*\n/).map(o=>o.trim()).filter(Boolean)}var a_={"themed-band":"text-fg/70","themed-section":"text-fg-dim","dark-media":"text-overlay-fg/70"};function xb({items:e,separator:o=Kc,size:t=jc,durationSec:r=50,scroll:a=Vc,backdrop:n="themed-band",className:s}){let i=Xg(t),f=eb(a),u=Zg(o),p=`text-accent ${Jg(i,u)}`.trim(),m=Yg[u],x=m===""?va("span",{}):va("span",{className:p,children:m}),I=ob(f),b=I?"inline-flex flex-col items-center gap-[60px] pb-[60px] max-[800px]:gap-8 max-[800px]:pb-8":"inline-flex items-center gap-[60px] pr-[60px] max-[800px]:gap-8 max-[800px]:pr-8",C=I?"inline-flex flex-col items-center gap-[60px] max-[800px]:gap-8":"inline-flex items-center gap-[60px] max-[800px]:gap-8",w=k=>va("span",{className:b,children:e.map((v,g)=>{let y=typeof v=="string"?v:v.text,L=typeof v=="object"&&v.gold;return mb("span",{className:C,children:[va("span",{className:L?"text-accent":void 0,children:Jc(y)}),x]},g)})},k);return va("div",{className:`overflow-hidden ${s??""}`,children:mb("div",{className:`flex ${I?"flex-col ":""}whitespace-nowrap ${Qg(i)} ${a_[n]}`,style:{animation:tb(f,r)},children:[w("a"),w("b")]})})}import{jsx as ka,jsxs as A_}from"react/jsx-runtime";import{createContext as B_,useContext as __}from"react";import{jsx as br,jsxs as Tb}from"react/jsx-runtime";import{useEffect as od,useRef as S_,useState as wa}from"react";import{jsx as Ib}from"react/jsx-runtime";import{createContext as n_,lazy as _Y,Suspense as DY,useContext as l_}from"react";var s_={Link:Su,Image:yu},i_=n_(s_);function hb(){return l_(i_)}function NY(e){let{Link:o}=hb();return Ib(o,{...e})}function gb(e){let{Image:o}=hb();return Ib(o,{...e})}import{jsx as bb,Fragment as f_,jsxs as c_}from"react/jsx-runtime";import{useEffect as d_,useRef as yb,useState as u_}from"react";var p_="#t=0.001",m_=2;function x_(e,o){if(e.readyState<m_||!e.videoWidth||!e.videoHeight)return!1;let t=o.getContext("2d");return t?(o.width=e.videoWidth,o.height=e.videoHeight,t.drawImage(e,0,0,o.width,o.height),!0):!1}function Sb({src:e,objectPosition:o="50% 50%",onError:t}){let r=yb(null),a=yb(null),[n,s]=u_(!1);return d_(()=>{let i=r.current,f=a.current;if(n||!i||!f)return;let u=()=>{x_(i,f)&&s(!0)};return u(),i.addEventListener("loadeddata",u),i.addEventListener("seeked",u),()=>{i.removeEventListener("loadeddata",u),i.removeEventListener("seeked",u)}},[n]),c_(f_,{children:[bb("canvas",{ref:a,"aria-hidden":!0,className:"absolute inset-0 z-[3] h-full w-full object-cover",style:{objectPosition:o,visibility:n?"visible":"hidden"}}),!n&&bb("video",{ref:r,src:`${e}${p_}`,muted:!0,playsInline:!0,preload:"auto",className:"hidden",onError:t})]})}import{imageCopyUrl as vb,imageSrcSet as I_}from"efficient-shell/image-copies";var Cb;function ed(){return Cb===void 0?{}:{host:Cb}}var UY="(max-width: 800px) 100vw, min(100vw, 1600px)";function wb(e,{fallbackWidth:o=1280,maxWidth:t}={}){let r=I_(e,{...ed(),...t===void 0?{}:{maxWidth:t}});return r?{src:vb(e,o,ed()),srcSet:r}:{src:e}}function $Y(e){let o=vb(e,1920,ed());return o===e?`url(${e})`:`url("${o}")`}import{formatFocal as h_,parseFocal as g_}from"efficient-shell/format";var b_="sf-focus-phone",y_="--sf-focus-phone";function kb(e){if(typeof e!="string"||!/^\s*-?\d+(\.\d+)?%\s+-?\d+(\.\d+)?%\s*$/.test(e))return{className:"",style:{}};let{x:o,y:t}=g_(e);return{className:b_,style:{[y_]:h_(o,t)}}}var C_=.5;function Eb({videoSrc:e,posterSrc:o,showVideo:t=!0,playbackRate:r=C_,objectPosition:a="50% 50%",objectPositionPhone:n,quiet:s=!1}){let i=kb(n),f=o||"",u=e||"",[p,m]=wa(!1),[x,I]=wa(!1),[b,C]=wa(!1),[w,k]=wa(!1),[v,g]=wa(!1),y=S_(null);od(()=>{m(!1),I(!1),C(!1),k(!1)},[e,o]),od(()=>{if(typeof window>"u")return;let O=()=>{let E=window;E.requestIdleCallback?E.requestIdleCallback(()=>g(!0),{timeout:2e3}):setTimeout(()=>g(!0),800)};if(document.readyState==="complete"){O();return}return window.addEventListener("load",O,{once:!0}),()=>window.removeEventListener("load",O)},[]),od(()=>{let O=y.current;if(!O)return;let E=()=>{O.playbackRate=r};return E(),O.addEventListener("loadedmetadata",E),()=>O.removeEventListener("loadedmetadata",E)},[e,r]);let L=Cu(f),F=f&&L&&!x?wb(f):{src:f};return Tb("div",{className:"absolute inset-0 z-[1]",children:[br("div",{className:"absolute inset-0",style:{background:"var(--site-surface)"}}),f&&(L?br("img",{src:F.src,...F.srcSet?{srcSet:F.srcSet,sizes:"100vw"}:{},alt:"",className:`absolute inset-0 z-[2] h-full w-full object-cover ${i.className}`.trim(),style:{display:p?"none":"block",objectPosition:a,...i.style},onError:()=>F.srcSet?I(!0):m(!0)},f):br(gb,{src:f,alt:"",fill:!0,priority:!0,sizes:"100vw",className:`z-[2] object-cover ${i.className}`.trim(),style:{display:p?"none":"block",objectPosition:a,...i.style},onError:()=>m(!0)},f)),t&&!s&&u&&v&&!b&&Tb("video",{ref:y,autoPlay:!0,loop:!0,muted:!0,playsInline:!0,preload:"metadata",className:"absolute inset-0 z-[3] h-full w-full object-cover",style:{objectPosition:a},onError:()=>C(!0),children:[vu(u)&&br("source",{src:u.replace(/\.mp4$/,".av1.mp4"),type:'video/mp4; codecs="av01.0.08M.10"'}),br("source",{src:u,type:"video/mp4"})]},u),t&&s&&u&&v&&!w&&(!f||p)&&br(Sb,{src:u,objectPosition:a,onError:()=>k(!0)},u)]})}var Fb=["top","middle","bottom"],Pb=["left","center","right"],Lb="bottom",Ob="left",v_={top:"Top",middle:"Middle",bottom:"Bottom"},w_={left:"Left",center:"Center",right:"Right"};var tX="Up and down",rX="Sideways",k_={top:"flex-start",middle:"center",bottom:"flex-end"},T_={left:"flex-start",center:"center",right:"flex-end"},E_="--sf-hero-phone-y",F_="--sf-hero-phone-x";function P_(e){return Fb.includes(e)?e:Lb}function L_(e){return Pb.includes(e)?e:Ob}function Rb(e,o){let t=P_(e),r=L_(o),a={};return t!==Lb&&(a[E_]=k_[t]),r!==Ob&&(a[F_]=T_[r]),a}function aX(){return Fb.map(e=>({label:v_[e],value:e}))}function nX(){return Pb.map(e=>({label:w_[e],value:e}))}var O_="#0A0A0A",R_=[[0,".5"],[30,".1"],[60,".1"],[100,".85"]];function Ab(e){let o=e.trim().replace(/^#/,""),t=o.length===3?o.split("").map(a=>a+a).join(""):o;if(!/^[0-9a-fA-F]{6}$/.test(t))return null;let r=Number.parseInt(t,16);return`${r>>16&255},${r>>8&255},${r&255}`}function Bb(e){return e==null?!0:e!==!1}function _b(e){let o=(e?Ab(e):null)??Ab(O_);return`linear-gradient(180deg, ${R_.map(([t,r])=>`rgba(${o},${r}) ${t}%`).join(", ")})`}var td=B_({});function xX({name:e,process:o,mediaType:t="video",mediaSrc:r,videoSpeed:a,poster:n,objectPosition:s,objectPositionPhone:i,tintColor:f="#000000",tintOpacity:u=0,groups:p,editing:m=!1,themeClassName:x,themeStyle:I}){let{alignment:b="left",textureOpacity:C,textureOn:w,textureColor:k,quietVideo:v,phoneUpDown:g,phoneSideways:y}=__(td),L=t==="video",F=L?Hr(r):void 0,O=L?Hr(n):Hr(r)??Hr(n),E=typeof a=="number"?a/100:1;return A_("section",{className:x?`relative h-full w-full overflow-hidden ${x}`:"relative h-full w-full overflow-hidden",style:I,"data-slide-name":e??"","data-slide-process":o??"","data-slide-media":F?"video":"still",children:[ka(Eb,{videoSrc:F,posterSrc:O,showVideo:L,playbackRate:E,objectPosition:s,objectPositionPhone:L?void 0:i,quiet:v}),u>0&&ka("div",{className:"absolute inset-0 z-[2]",style:{background:f,opacity:Math.min(Math.max(u,0),100)/100}}),Bb(w)&&ka("div",{className:"absolute inset-0 z-[2]",style:{background:_b(k),...C!==void 0?{opacity:C/100}:null}}),ka("div",{className:["sf-hero-group-layer absolute inset-0 z-[3] mx-auto max-w-[var(--sf-site-width,1600px)] px-[var(--sf-site-gutter,40px)] pt-[140px] pb-14",m?"sf-hero-group-layer-edit":""].filter(Boolean).join(" "),style:{..._p,...Rb(g,y)},children:p&&ka(p,{className:"sf-hero-group-zone",minEmptyHeight:160})})]})}var Db=Array.from({length:3},(e,o)=>({name:`Slide ${o+1}`,process:"Category",mediaType:"image",mediaVideo:"",poster:""}));import{jsx as rd}from"react/jsx-runtime";import{UiIcon as q_}from"efficient-easel/draw/client";var D_={"top-left":"left-0 top-[120px]","top-center":"left-1/2 top-[120px] -translate-x-1/2","top-right":"right-0 top-[120px]",left:"left-0 top-1/2 -translate-y-1/2",center:"left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2",right:"right-0 top-1/2 -translate-y-1/2","bottom-left":"left-0 bottom-[120px]","bottom-center":"left-1/2 bottom-[120px] -translate-x-1/2","bottom-right":"right-0 bottom-[120px]"},N_=`calc(${zn} - ${qe}*2)`,Nb=`var(${lf},${qe})`,bX=`pointer-events-none absolute inset-y-0 left-[${Nb}] right-[${Nb}] z-[6] mx-auto max-w-[var(${sf},${N_.replace(/ /g,"_")})]`;function es(e,o){return`pointer-events-auto absolute ${D_[e]} z-[6] sf-hero-overlay-rail flex ${o}`}function Mb(e){return yo.includes(e)?e:null}var M_="bottom-right",H_=["outline","solid","square","bare"],W_="outline",CX={outline:"Outline",solid:"Solid",square:"Square",bare:"Bare"},vX=!1,Hb=["prev","next"],Wb={prev:"Previous slide",next:"Next slide"};function z_(e){return H_.includes(e)?e:W_}function G_(e){return Mb(e)??M_}var U_="flex-row items-center gap-2";function zb(e){return es(G_(e),U_)}var $_={outline:"grid h-10 w-10 cursor-pointer place-items-center rounded-full border border-overlay-chrome/60 text-overlay-fg transition-colors hover:border-overlay-chrome hover:bg-overlay-scrim/30",solid:"grid h-10 w-10 cursor-pointer place-items-center rounded-full border border-overlay-chrome bg-overlay-chrome text-overlay-scrim transition-colors hover:bg-overlay-chrome/85",square:"grid h-10 w-10 cursor-pointer place-items-center rounded-md border border-overlay-chrome/60 text-overlay-fg transition-colors hover:border-overlay-chrome hover:bg-overlay-scrim/30",bare:"grid h-10 w-10 cursor-pointer place-items-center text-overlay-fg transition-colors hover:text-overlay-chrome"};function Gb(e){return $_[z_(e)]}function Ub(e){return e.shown===!0&&(e.count??0)>1}function os(e,o,t){if(t<=1)return o;let r=Math.min(Math.max(o,0),t-1);return e==="prev"?(r-1+t)%t:(r+1)%t}function $b({shape:e,placement:o,ref:t}){let r=Gb(e);return rd("div",{ref:t,className:zb(o),style:{color:"var(--overlay-fg)"},children:Hb.map(a=>rd("button",{type:"button","data-hero-nav":a,"aria-label":Wb[a],className:r,children:rd(q_,{name:"chevron-right",size:18,rounded:!0,style:a==="prev"?{rotate:"180deg"}:void 0})},a))})}import{jsx as Ee,jsxs as ad,Fragment as yr}from"react/jsx-runtime";var j_=yo;var K_="top-right",V_=["cards","dots","numbers","bar","squares","tabs"],Y_=["cards","dots","numbers","bar","squares"],qb="cards",OX={cards:"Cards",dots:"Dots",numbers:"Numbers",bar:"Bar",squares:"Squares",tabs:"Tabs"},RX=!0;function ts(e){return V_.includes(e)?e:qb}function jb(e){return Y_.includes(e)?e:qb}function X_(e){return j_.includes(e)?e:K_}var Kb={cards:"flex-col gap-2.5",dots:"flex-row items-center gap-2",numbers:"flex-col gap-2",bar:"h-0.5 w-[34%] max-w-[420px] gap-px overflow-hidden rounded-full",squares:"flex-col gap-0",tabs:"flex-row items-stretch w-full overflow-x-auto"};function Vb(e,o){return es(X_(o),Kb[ts(e)])}function Yb(e){return`flex ${Kb[ts(e)]}`}function Xb(e){return e.shown!==!1&&(e.count??0)>1}function Z_(e){return{name:e.dataset.slideName||"",process:e.dataset.slideProcess||"",video:e.dataset.slideMedia==="video"}}function Q_(e,o){return e===o?!0:e.length!==o.length?!1:e.every((t,r)=>t.name===o[r].name&&t.process===o[r].process&&t.video===o[r].video)}function Zb(e,o){let t=Array.from(o,Z_);return Q_(e,t)?e:t}function Qb({slides:e,active:o,shape:t,placement:r,ref:a,tone:n="media",label:s}){let i=ts(t),f=n==="surface"?{"--overlay-fg":"var(--fg)","--overlay-chrome":"var(--fg)","--overlay-scrim":"var(--site-surface-2)"}:void 0;return ad("aside",{ref:a,"aria-label":s??"Featured slides",className:n==="surface"?Yb(i):Vb(i,r),style:{color:"var(--overlay-fg)",...f},children:[i==="cards"&&Ee(J_,{slides:e,active:o}),i==="dots"&&Ee(eD,{count:e.length,active:o}),i==="numbers"&&Ee(oD,{count:e.length,active:o}),i==="bar"&&Ee(rD,{count:e.length,active:o}),i==="squares"&&Ee(tD,{count:e.length,active:o}),i==="tabs"&&Ee(aD,{slides:e,active:o})]})}function J_({slides:e,active:o}){return ad(yr,{children:[Ee("span",{className:"mb-1 font-mono text-[length:var(--size-label,10px)] uppercase tracking-[0.28em] text-overlay-chrome/55",children:"Reel \xB7 pick a slide"}),e.map((t,r)=>{let a=r===o;return ad("button",{type:"button","data-idx":r,"aria-pressed":a,"aria-label":`Go to ${t.name||`slide ${r+1}`}`,className:["group flex w-[170px] cursor-pointer flex-col items-start gap-0.5 border bg-overlay-scrim/55 px-3 py-2.5 text-left transition-all motion-reduce:transition-none max-[1100px]:w-[140px]",a?"border-accent bg-overlay-scrim/70":"border-overlay-chrome/15 hover:border-overlay-chrome/45 hover:bg-overlay-scrim/70"].join(" "),children:[Ee("span",{className:["font-display text-[length:var(--size-body,13px)] font-medium uppercase leading-tight tracking-[-0.01em]",a?"text-accent":"text-overlay-fg"].join(" "),children:t.name||`Slide ${r+1}`}),Ee("span",{className:"font-mono text-[length:var(--size-label,9px)] uppercase tracking-[0.2em] text-overlay-chrome/55",children:a?"\u25B6 Now playing":t.process||" "})]},r)})]})}function eD({count:e,active:o}){return Ee(yr,{children:Array.from({length:e},(t,r)=>Ee("button",{type:"button","data-idx":r,"aria-pressed":r===o,"aria-label":`Go to slide ${r+1}`,className:`h-2 cursor-pointer rounded-full transition-all motion-reduce:transition-none ${r===o?"w-5 bg-accent":"w-2 bg-overlay-chrome/45 hover:bg-overlay-chrome/70"}`},r))})}function oD({count:e,active:o}){return Ee(yr,{children:Array.from({length:e},(t,r)=>Ee("button",{type:"button","data-idx":r,"aria-pressed":r===o,"aria-label":`Go to slide ${r+1}`,className:`cursor-pointer font-mono text-[length:var(--size-label,11px)] leading-none tracking-[0.06em] transition-colors ${r===o?"text-overlay-fg":"text-overlay-chrome/45 hover:text-overlay-chrome/80"}`,children:String(r+1).padStart(2,"0")},r))})}function tD({count:e,active:o}){return Ee(yr,{children:Array.from({length:e},(t,r)=>Ee("button",{type:"button","data-idx":r,"aria-pressed":r===o,"aria-label":`Go to slide ${r+1}`,className:`grid h-8 w-8 cursor-pointer place-items-center border border-overlay-chrome/25 text-[length:var(--size-label,14px)] font-bold leading-none transition-colors motion-reduce:transition-none ${r===o?"bg-accent text-[color:var(--accent-ink)]":"bg-overlay-scrim/45 text-overlay-chrome/75 hover:text-overlay-chrome"}`,children:r+1},r))})}function rD({count:e,active:o}){return Ee(yr,{children:Array.from({length:e},(t,r)=>Ee("button",{type:"button","data-idx":r,"aria-pressed":r===o,"aria-label":`Go to slide ${r+1}`,className:`h-full flex-1 cursor-pointer transition-colors ${r<=o?"bg-overlay-fg":"bg-overlay-chrome/25"}`},r))})}function aD({slides:e,active:o}){return Ee(yr,{children:e.map((t,r)=>{let a=r===o;return Ee("button",{type:"button","data-idx":r,"aria-pressed":a,className:["flex min-w-[140px] flex-1 cursor-pointer items-end px-6 py-7 text-left transition-colors",r>0?"border-l border-overlay-chrome/15":"",a?"bg-overlay-scrim/70":"hover:bg-overlay-scrim/40"].join(" "),children:Ee("span",{className:["font-heading3 text-[length:var(--size-headingSmall,24px)] font-medium uppercase leading-tight tracking-[-0.02em]",a?"text-overlay-fg":"text-overlay-chrome/55"].join(" "),children:t.name})},r)})})}import{useEffect as nD,useState as lD}from"react";var Jb="(prefers-reduced-motion: reduce)";function sD(){return globalThis.window?.matchMedia?.(Jb)?.matches??!1}function MX(){return sD()?"auto":"smooth"}function ey(){let[e,o]=lD(!1);return nD(()=>{let t=globalThis.window?.matchMedia?.(Jb);if(!t||(o(t.matches),typeof t.addEventListener!="function"))return;let r=a=>o(a.matches);return t.addEventListener("change",r),()=>t.removeEventListener("change",r)},[]),e}var Ta={accent:"#2563eb",accentTint:"#eff6ff",accentText:"#1d4ed8",appBg:"#f9fafb",previewBg:"#f3f4f6",panel:"#ffffff",fieldBg:"#ffffff",inputBorder:"#d1d5db",text:"#111827",text2:"#374151",muted:"#6b7280",line:"#e5e7eb",chipBg:"#f3f4f6",chipFg:"#6b7280",panelRadius:12,rowRadius:8,panelShadow:"0 1px 2px rgba(0,0,0,.05), 0 10px 30px rgba(0,0,0,.06)",topbarShadow:"0 1px 3px rgba(0,0,0,.06)",panelGap:10,leftWidth:288,rightWidth:308,topbarHeight:52,labelFont:"-apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif"};var oy={min:40,max:100,step:5,fallback:100,unit:"vh"};function nd(e){return`${typeof e=="number"?e:oy.fallback}${oy.unit}`}function ty(...e){return e.some(o=>typeof o=="number")}import{HEADER_TYPE as ld,FOOTER_TYPE as iD}from"efficient-easel/draw";var fD=new Set(["Hero","HeroSingle","IntroBleed"]),ry={min:56,max:140,default:88},UX={min:0,max:120,step:2,default:32},ay=`var(--sf-header-h, ${ry.default}px)`,cD="--sf-header-set-h",$X="--sf-header-h",qX=`var(${cD}, ${ry.default}px)`,jX="sf-header-clearance",KX="sf-sticky-underheader";function dD(e){return e?.find(o=>o?.type&&o.type!==ld)??null}function ny(e){let o=dD(e)?.type;return!o||!fD.has(o)}function VX(e){return!ny(e)}function YX(e){return!!e?.some(o=>o?.type===ld)}function XX(e){return!e||e.length===0?!1:!e.some(o=>o?.type===ld||o?.type===iD)}var uD=["auto","shared","own"],pD="auto",mD="topSpace",ZX="data-top-space";function xD(e){return uD.includes(e)?e:pD}function ID(e,o){let t=xD(e?.props?.[mD]);return t==="own"?!0:t==="shared"?!1:ny(o)}function QX(e,o){return ID(e,o)?"own":null}var hD=40;function gD(e,o){return Math.abs(e)<=hD||Math.abs(e)<=Math.abs(o)?null:e<0?"next":"prev"}function ly(e,o,t,r){let a=gD(e,o);return a?os(a,t,r):t}function sy(e){return(e.count??0)>1&&e.editing!==!0}function iy(e){return e.editing!==!0?!1:(e.slides??[])[e.shown??0]?.video===!0}function fy(e){return e.editing!==!0?!1:!(e.playing===!0&&e.controlShown===!0)}import{HERO_SLIDER_GOTO_EVENT as cy}from"efficient-easel/draw";var yD=`
|
|
7
|
+
.hero-ticker-pick { cursor: pointer; }
|
|
8
|
+
.hero-ticker-pick:hover {
|
|
9
|
+
outline: 2px solid color-mix(in srgb, ${Ta.accent} 45%, transparent);
|
|
10
|
+
outline-offset: -2px;
|
|
11
|
+
}
|
|
12
|
+
.hero-ticker-pick[data-selected] {
|
|
13
|
+
outline: 2px solid ${Ta.accent};
|
|
14
|
+
outline-offset: -2px;
|
|
15
|
+
}
|
|
16
|
+
`,SD="Play video",CD="Hold video",vD="flex h-7 cursor-pointer items-center gap-1.5 rounded-full border border-overlay-chrome/25 bg-overlay-scrim/80 px-[11px] font-mono text-[11px] leading-none tracking-[0.05em] text-overlay-fg",wD=()=>l("item"),sd=["","","","","",""],dy=new Map;function kD(e,o){let t=e?.ownerDocument?.defaultView;if(t)return t.addEventListener(cy,o),()=>t.removeEventListener(cy,o)}function SZ({slides:e,alignment:o,textureOpacity:t,showTexture:r,textureColor:a,phoneUpDown:n,phoneSideways:s,autoplay:i,autoplayInterval:f,showTicker:u,tickerItems:p,heightDesktop:m,heightMobile:x,showPicker:I,pickerShape:b,pickerPlacement:C,showArrows:w,arrowsShape:k,arrowsPlacement:v,editing:g}){let y=ty(m,x),L=y?"h-[var(--sf-hero-h-m)] min-[720px]:h-[var(--sf-hero-h-d)]":"h-screen min-h-[680px]",F=y?{"--sf-hero-h-d":nd(m),"--sf-hero-h-m":nd(x)}:void 0,O=(p??sd.map(z=>({text:z}))).map(z=>z?.text?.trim()?z.text:g?wD():"").filter(Boolean),E=u!==!1,D=$o(null),G=$o(null),B=$o(null),R=$o(null),H=$o(null),_=bD(),ae=$o(_),[se,Ie]=Ea([]),[ro,Ye]=Ea(0),Fe=$o(0),[ao,Me]=Ea(!1),[Re,ye]=Ea(!1),[Ce,Xe]=Ea(null),He=ey(),{selectedHeroId:Ze,select:Ae}=Wl(),P=Sr(()=>D.current?.querySelector(".hero-track")??null,[]),oe=Sr((z,q=!1)=>{Ye(z),Fe.current=z,dy.set(ae.current,z);let Z=D.current?.querySelector(".hero-track");if(Z)if(q){let ce=Z.style.transition;Z.style.transition="none",Z.style.transform=`translateX(-${Math.max(0,z)*100}%)`,Z.offsetHeight,Z.style.transition=ce}else Z.style.transform=`translateX(-${Math.max(0,z)*100}%)`},[]);Cr(()=>{let z=D.current,q=z?.getAttribute("data-puck-component")||z?.closest("[data-puck-component]")?.getAttribute("data-puck-component")||_;ae.current=q,Xe(q);let Z=dy.get(q);typeof Z=="number"&&(Ye(Z),Fe.current=Z)},[]),Cr(()=>{let z=P();if(!z)return;let q=()=>{Ie(ce=>Zb(ce,z.querySelectorAll("[data-slide-name]")))};q();let Z=new MutationObserver(q);return Z.observe(z,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["data-slide-name","data-slide-process","data-slide-media"]}),()=>{Z.disconnect()}},[P]),Cr(()=>{if(!g)return;let z=q=>{let Z=q.detail;if(!Z||typeof Z.index!="number")return;let ce=D.current,no=ce?.getAttribute("data-puck-component")||ce?.closest("[data-puck-component]")?.getAttribute("data-puck-component")||ae.current;Z.id&&Z.id!==no||oe(Z.index,!0)};return kD(D.current,z)},[g,oe]);let j=se.length,ge=Math.min(Math.max(ro,0),Math.max(0,j-1)),ve=Xb({shown:I,count:j}),ze=Ub({shown:w,count:j}),$e=iy({editing:g,shown:ge,slides:se}),ee=fy({editing:g,playing:Re,controlShown:$e}),le=sy({count:j,editing:g}),Qe=$o(null),dt=$o(null),ut=Sr(z=>{if(Qe.current=null,dt.current=null,!le||z.touches.length!==1)return;let q=z.touches[0];Qe.current={x:q.clientX,y:q.clientY},dt.current={x:q.clientX,y:q.clientY}},[le]),Hs=Sr(z=>{if(!Qe.current)return;if(z.touches.length!==1){Qe.current=null;return}let q=z.touches[0];dt.current={x:q.clientX,y:q.clientY}},[]),Nr=Sr(()=>{let z=Qe.current,q=dt.current;if(Qe.current=null,dt.current=null,!le||!z||!q)return;let Z=ly(q.x-z.x,q.y-z.y,Fe.current,j);Z!==Fe.current&&oe(Z)},[le,j,oe]);Cr(()=>{if(g||!i||ao||He||j<=1)return;let z=Math.max(1,typeof f=="number"?f:6)*1e3,q=window.setTimeout(()=>oe((ge+1)%j),z);return()=>window.clearTimeout(q)},[g,i,f,ao,He,j,ge,oe]),Cr(()=>{let z=[G.current,B.current,R.current].filter(Boolean),q=z.map(ce=>Yl(ce)),Z=ce=>{let no=ce.target,Ko=no.closest("[data-hero-nav]"),en=Ko??no.closest("[data-idx]");if(!en)return;ce.stopPropagation(),ce.preventDefault();let zt=Ko?os(Ko.dataset.heroNav,Fe.current,j):Number(en.dataset.idx);Number.isNaN(zt)||(oe(zt,g),P()?.querySelectorAll("[data-slide-name]")[zt]?.click())};return z.forEach(ce=>ce.addEventListener("click",Z,{capture:!0})),()=>{q.forEach(ce=>ce?.()),z.forEach(ce=>ce.removeEventListener("click",Z,{capture:!0}))}},[j,oe,P,g]),Cr(()=>{if(!g)return;let z=H.current;if(!z)return;let q=Yl(z),Z=ce=>{ce.stopPropagation(),ce.preventDefault();let no=D.current,Ko=no?.getAttribute("data-puck-component")||no?.closest("[data-puck-component]")?.getAttribute("data-puck-component")||ae.current;Ae(Ko)};return z.addEventListener("click",Z,{capture:!0}),()=>{q?.(),z.removeEventListener("click",Z,{capture:!0})}},[g,Ae,E,O.length]);let Mr=Sr(z=>{if(!z)return;let q=Yl(z),Z=ce=>{ce.stopPropagation(),ce.preventDefault(),ye(no=>!no)};return z.addEventListener("click",Z,{capture:!0}),()=>{q?.(),z.removeEventListener("click",Z,{capture:!0})}},[]);return Po(td.Provider,{value:{alignment:o,textureOpacity:t,textureOn:r,textureColor:a,quietVideo:ee,phoneUpDown:n,phoneSideways:s},children:rs("div",{ref:D,className:`relative mx-[var(--sf-hero-bleed-m,calc(50%_-_50vw))] w-[var(--sf-hero-bleed-w,100vw)] ${L} max-w-[var(--sf-hero-cap,none)] overflow-hidden`,style:F,onMouseEnter:()=>Me(!0),onMouseLeave:()=>Me(!1),onTouchStart:ut,onTouchMove:Hs,onTouchEnd:Nr,children:[Po(e,{className:"hero-track flex h-full [&>*]:h-full [&>*]:min-w-full [&>*]:shrink-0 [&>*]:basis-full",style:{transform:`translateX(-${ge*100}%)`,transition:He?"none":"transform 600ms cubic-bezier(.22,.61,.36,1)"},minEmptyHeight:400}),$e&&Po("div",{ref:Mr,"data-hero-video-control":Re?"playing":"held",className:"sf-hero-video-control absolute left-6 z-[7]",style:{top:`calc(${ay} + 16px)`},children:rs("button",{type:"button",className:vD,children:[Po("span",{"aria-hidden":"true",children:Re?"\u275A\u275A":"\u25B6"}),l(Re?CD:SD)]})}),(ve||ze)&&rs("div",{className:"pointer-events-none absolute inset-y-0 left-[var(--sf-hero-chrome-x,var(--sf-site-gutter,40px))] right-[var(--sf-hero-chrome-x,var(--sf-site-gutter,40px))] z-[6] mx-auto max-w-[var(--sf-hero-chrome-cap,calc(var(--sf-site-width,1600px)_-_var(--sf-site-gutter,40px)*2))]",children:[ve&&Po(Qb,{ref:G,slides:se,active:ge,shape:jb(b),placement:C}),ze&&Po($b,{ref:R,shape:k,placement:v})]}),ve&&Po("div",{ref:B,className:"sf-hero-phone-dots absolute bottom-[80px] left-1/2 z-[6] hidden -translate-x-1/2 items-center gap-2",children:se.map((z,q)=>Po("button",{type:"button","data-idx":q,"aria-label":`Go to slide ${q+1}`,className:`h-2 rounded-full transition-all motion-reduce:transition-none ${q===ge?"w-5 bg-accent":"w-2 bg-white/45 hover:bg-white/70"}`},q))}),E&&O.length>0&&rs("div",{ref:H,className:`sf-hero-ticker absolute inset-x-0 bottom-0 z-[5] border-t border-overlay-chrome/10 py-3.5${g?" hero-ticker-pick":""}`,"data-selected":g&&Ce!=null&&Ze===Ce?"":void 0,style:{background:"rgba(10,10,10,.55)"},children:[g&&Po("style",{children:yD}),Po(xb,{items:O,backdrop:"dark-media"})]})]})})}var AD="root:default-zone";function uy({heroId:e}){let{appState:o,dispatch:t}=PD(p=>p),r=o.data.content??[],a=r.findIndex(p=>p.props.id===e),n=a>=0?r[a]:null,s=n?n.props.showTicker??!0:!0,i=FD(()=>{let p=n?.props.tickerItems;return Array.isArray(p)?p:sd.map(m=>({text:m}))},[n]),f=ED();if(!n)return vr("p",{className:"sf-note",children:l("This ticker\u2019s hero is no longer on the page.")});let u=p=>t({type:"replace",destinationZone:AD,destinationIndex:a,data:{...n,props:{...n.props,...p}}});return TD("div",{children:[vr(rr,{label:"Ticker"}),vr(LD,{label:l("Show ticker"),labelId:f,icon:vr(RD,{}),action:vr(OD,{checked:s,onChange:p=>u({showTicker:p}),ariaLabelledBy:f})}),vr(Tf,{label:kf.label,icon:kf.icon,items:i,placeholder:"item",onChange:p=>u({tickerItems:p}),markup:!0})]})}import{jsx as U,Fragment as gd,jsxs as Lo}from"react/jsx-runtime";import{useContext as fN,useEffect as xd,useRef as cN,useState as _y}from"react";import{FieldSelect as dN,InspectorField as uN}from"efficient-easel/fields";import{SettingsField as pN}from"efficient-easel/panel";import{InspectorUpLevel as fs}from"efficient-easel/chrome";import{StylesIcon as mN,TypeIcon as xN}from"efficient-easel/icons";import{useEasel as IN}from"efficient-easel/easel";import{TextPartPanel as hN}from"efficient-easel/copy";import{Tooltip as gN}from"efficient-shell/ui";import{jsx as ud,jsxs as zD}from"react/jsx-runtime";import{COPY_CELLS as Fa,CopyBox as GD}from"efficient-easel/copy";import{PaddingYIcon as UD,WidthIcon as $D}from"efficient-easel/icons";import{useSyncExternalStore as BD}from"react";import{decodePartId as _D}from"efficient-easel/draw";function wr(e,o){let t=Mf(e);return t?.control==="textList"?o.rowKey===(t.itemKey??"text")?SI(t,o.index):null:Hf(e)?.[o.rowKey]??null}function as(e,o,t){let r=e.node.props,{key:a,row:n}=po(e.propKey),s=n?th(r,a,n,e.kind,o):eh(r,a,e.kind,o);return s?(t(e.zone,e.index,{...e.node,props:s}),!0):!1}var DD=["bold","italic","underline","strike","link","sup","sub"],ND=["bullet","number"];function cd(e,o){return e?[...DD,...o?ND:[]]:[]}function py(e,o){let t=_D(e);if(!t?.propKey)return null;let{nodeId:r,propKey:a}=t,n=o.getItemById(r),s=o.getSelectorForId(r);if(!n||!s)return null;let{key:i,row:f}=po(a),u=o.components[n.type]?.fields?.[i],p=f?wr(u,f):u,m=nr(p);if(!m)return null;let x=n.props??{};if(f&&!(Array.isArray(x[i])&&f.index<x[i].length))return null;let I=f?na(x[i],f):x[i];return{node:n,selector:s,propKey:a,kind:m,stored:I,offPage:jn(p)}}function my(e,o){let t=py(e,o);if(!t||t.offPage)return null;let{text:r,hidden:a}=rt(t.stored);if(a)return null;let n=pl(t.kind);return{partId:e,value:r,rules:Vt,multiline:n,offered:cd(t.kind!=="plainText",n),write:s=>{let i=py(e,o);i&&as({node:i.node,propKey:i.propKey,kind:i.kind,zone:i.selector.zone,index:i.selector.index},s,o.replace)}}}function xy(e,o,t){return e?.isConnected&&e.getAttribute(mo)===t?e:o?.querySelector(`[${mo}="${MD(t)}"]`)??null}function MD(e){return e.replace(/["\\]/g,"\\$&")}function Iy(e){let o=e.activeElement;return o?o.tagName==="IFRAME"||!!o.closest(".es-canvas"):!1}var id=null,fd=new Set;function HD(){return id}function dd(e){if(e!==id){id=e;for(let o of fd)o()}}function WD(e){return fd.add(e),()=>{fd.delete(e)}}function hy(){return BD(WD,HD,()=>null)}var qD=["left","center","right","justify"];function pd(e,o,t,r={}){let a=fa(e),n=(r.phone?e.sizePhone:void 0)??e.size??o.sizePx;return[r.phone?{...Fa.fontSize,value:e.sizePhone,styleValue:Math.round(o.sizePx),onChange:s=>t({sizePhone:s??null})}:{...Fa.fontSize,value:e.size,styleValue:Math.round(o.sizePx),onChange:s=>t({size:s??null})},{...Fa.lineHeight,value:a.lineHeight,styleValue:o.lineRatio,onChange:s=>t(s===void 0?{lineHeight:null,line:null}:{lineHeight:s})},{...Fa.letterSpacing,scale:n,value:a.letterSpacingEm,styleValue:o.letterEm,onChange:s=>t(s===void 0?{letterSpacing:null,letter:null}:{letterSpacing:s})},{...Fa.paragraphSpacing,value:e.paragraphSpacing,styleValue:0,onChange:s=>t({paragraphSpacing:s??null})},{key:"padding",name:l("Padding"),icon:ud(UD,{}),unit:"px",step:Yf,shiftStep:10,min:Kf,max:Vf,value:e.padding,styleValue:o.paddingPx,onChange:s=>t({padding:s??null})},{key:"width",name:l("Width"),icon:ud($D,{}),unit:"px",step:Zf,shiftStep:100,min:Xf,max:nt,value:e.width,styleValue:o.widthPx,onChange:s=>t({width:s??null})}]}function gy({text:e,onTextChange:o,multiline:t,markup:r=!0,styled:a=!0,style:n,base:s,setValue:i,colors:f,placeholder:u,ariaLabel:p,head:m,typedOnCanvas:x=!1}){let I=pd(n,s,i),b=cd(r,t);return zD("div",{className:"sf-part-textbox",children:[m,ud(GD,{value:e,onChange:o,multiline:t,placeholder:u,ariaLabel:p,rules:Vt,tools:b,barShows:x?"focus":"always",colors:r?f:[],align:a?{value:n.align??s.align,allow:qD,onChange:C=>i({align:C})}:void 0,letterCase:a?{value:n.case==="capitalize"?"":n.case??"",onChange:C=>i({case:C||null})}:void 0,cells:a?I:void 0})]})}import{UiIcon as Dy}from"efficient-easel/draw/client";import{jsx as ns,Fragment as jD,jsxs as KD}from"react/jsx-runtime";import{Button as by,Dialog as VD}from"efficient-shell/ui";function yy({styleName:e,onCancel:o,onConfirm:t}){return ns(VD,{open:!0,onClose:o,role:"alertdialog",size:"sm",title:l("Update {style}?",{style:e}),footer:KD(jD,{children:[ns(by,{variant:"secondary",onClick:o,children:l("Cancel")}),ns(by,{variant:"primary",onClick:t,children:l("Update style")})]}),children:ns("p",{children:l("Every text on the site that follows {style} changes to look like this one. This text\u2019s own changes are cleared, and it keeps following {style}.",{style:e})})})}import{ScreenDocumentContext as bN}from"efficient-easel/screen/components/ScreenDocumentContext";import{usePreviewDevice as yN}from"efficient-easel/draw/client";import{jsx as YD}from"react/jsx-runtime";import{createContext as XD,useContext as ZD,useMemo as QD,useState as JD}from"react";var eN={partStyle:null,setPartStyle:()=>{}},Sy=XD(eN);function iQ({children:e}){let[o,t]=JD(null),r=QD(()=>({partStyle:o,setPartStyle:t}),[o]);return YD(Sy.Provider,{value:r,children:e})}function Cy(){return ZD(Sy)}import{TEXT_FIELD_MARKER as SN}from"efficient-easel/draw";import{useSectionOps as CN}from"efficient-easel/screen/lib/puck/use-section-ops";var oN="#9ca3af";function tN(e){return gn.map(o=>({key:o,name:Xp[o],value:e?.[o]||oN}))}function ls(e){return tN(e).map(o=>({name:o.key,label:l(o.name),value:o.value}))}function wy(e){let o={},t=e.ownerDocument,r=t?.defaultView;if(!t||!r)return o;let a=r.getComputedStyle(e),n=t.createElement("canvas").getContext("2d");for(let s of gn){let i=Do[s].replace(/^var\((--[\w-]+)\)$/,"$1"),f=a.getPropertyValue(i).trim();if(!f)continue;let u=vy(f);!u&&n&&(n.fillStyle="#000000",n.fillStyle=f,u=vy(String(n.fillStyle))),u&&(o[s]=u)}return o}function vy(e){let o=e.trim().toLowerCase();if(/^#[0-9a-f]{6}$/.test(o))return o;if(/^#[0-9a-f]{3}$/.test(o))return`#${[...o.slice(1)].map(r=>r+r).join("")}`;let t=o.match(/^rgba?\(\s*(\d+)[\s,]+(\d+)[\s,]+(\d+)/);return t?`#${t.slice(1,4).map(r=>Math.min(255,Number(r)).toString(16).padStart(2,"0")).join("")}`:null}import{useEaselHost as vN}from"efficient-easel/screen/lib/host";function rN(e){let o=new Set([...Object.keys(Sn[e]??{}),...Cn[e]??[]]);for(let[t,r]of Object.entries(Ti[e]??{}))r.verb==="snapshot"&&o.add(t);return[...o].sort()}var aN={CollectionCard:"product",FooterMenu:"menu",Gallery:"product",GalleryItem:"product",ProductGrid:"product",ProductHero:"product",SpecTable:"product",Events:"blog",FeaturedCover:"blog",LongRead:"blog",SubscribeBlogs:"blog"},ky={product:"Synced from the product.",blog:"Synced from the blog post.",menu:"Synced from the site menu."},Ty="Open",Ey={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 Pa(e){let o=e?.source?.slug;return typeof o=="string"&&o.length>0?o:void 0}function La(e){return aN[e]??null}function Fy(e,o){let t=La(e);return t&&rN(e).includes(o)?t:null}function ss(e){let o=e?.menu?.id;return typeof o=="string"&&o.length>0?o:void 0}var Py="data-sf-spec-region";function IQ(e,o,t){if(!e)return;let r=t[e];if(r)return{fontFamily:`var(--font-role-${e})`,fontSize:`var(--size-${r}, ${o.builtIn})`}}function kr(e){let o=/var\(--size-[A-Za-z]+, ?([0-9.]+px)\)/.exec(e);if(!o)throw new Error(`builtInOf: no --size-* fallback in ${e}`);return o[1]}function nN(e){return`@${e}`}function md(e,o){if(!o.startsWith("@"))return null;let t=o.slice(1);return t in e?t:null}function lN(e,o){return o&&o in e?o:null}var Oa={tag:"text-[length:var(--size-label,13px)]",name:"text-[length:min(var(--size-headingMedium,48px),var(--sf-heading-max,9999px))]",namePhone:"max-[800px]:text-[length:min(var(--size-headingMedium,36px),var(--sf-heading-max,9999px))]",body:"text-[length:var(--size-body,14px)]",price:"text-[length:var(--size-label,15px)]",link:"text-[length:var(--size-label,14px)]"},sN={tag:{label:"Tag",follows:"Labels",builtIn:kr(Oa.tag),writable:!0},name:{label:"Name",follows:"Heading 2",builtIn:kr(Oa.name),writable:!0},body:{label:"Body",follows:"Body",builtIn:kr(Oa.body),writable:!0},price:{label:"Price",follows:"Labels",builtIn:kr(Oa.price),writable:!0},link:{label:"Link",follows:"Labels",builtIn:kr(Oa.link),writable:!0}},Ly=sN;var iN={number:{label:"Number",follows:"Labels",builtIn:"14px",writable:!0},question:{label:"Question",follows:"Body",builtIn:"18px",writable:!0},answer:{label:"Answer",follows:"Body",builtIn:"15px",writable:!0}},Oy=iN;var wQ=Py;var Ry={rowLabel:{label:"Spec row name",follows:"Labels",builtIn:"14px"},rowValue:{label:"Spec row value",follows:"Labels",builtIn:"14px"},diagramTitle:{label:"Diagram title",follows:"Labels",builtIn:"12px"},diagramCallout:{label:"Diagram measurement",follows:"Labels",builtIn:"12px"},diagramStatLabel:{label:"Diagram stat name",follows:"Labels",builtIn:"11px"},diagramStatValue:{label:"Diagram stat value",follows:"Labels",builtIn:"11px"}};var Ay={SpecTable:Ry,FAQ:Oy,Collections:Ly};function By(e){return e&&Object.hasOwn(Ay,e)?Ay[e]:null}function hd(e){return e?l(e):null}function Ny(e){return e.kind==="role"?Gs[e.role]:e.kind==="custom"?"Custom":null}function wN(e){let o=e.role;return o&&Ao.includes(o)?{kind:"role",role:o}:null}function kN(e,o){if(!e)return{kind:"unread"};let{faceRole:t,base:r}=e;if(o[t]===r.fontKey)return{kind:"role",role:t};let a=Object.keys(o).filter(n=>o[n]===r.fontKey);return a.length===1?{kind:"role",role:a[0]}:{kind:"custom"}}function Id(e,o,t,r){return wN(Cl(e,o))??kN(t,r)}function TN(e,o){if(!e.length)return null;let t=o(e[0]);return e.every(r=>o(r)===t)?t:null}var is="";function EN({face:e,base:o,onPick:t}){let r=e.kind==="role"?e.role:is,a=[{label:l("No style"),value:is},...Ao.map(n=>({label:l(Gs[n]),value:n}))];return U(dN,{ariaLabel:l("Style"),value:r,options:a,inline:!0,onChange:n=>t(n===is?null:n),renderOption:n=>n.value===is?Lo(gd,{children:[U("span",{className:"es-fsel-label sf-part-style-keep",children:n.label}),U("span",{className:"sf-part-style-aside","aria-hidden":"true",children:l("Section\u2019s own")})]}):U("span",{className:"es-fsel-label",style:{fontFamily:`var(--font-role-${n.value})`},children:n.label}),renderValue:()=>U("span",{style:{fontFamily:o?.fontKey?`var(${Gt(o.fontKey)?.cssVar})`:void 0,fontWeight:o?.weight},children:hd(Ny(e))}),valueText:n=>hd(Ny(e))??n?.label??""})}function FN({sectionName:e,onBack:o,textEditor:t,styleRow:r,children:a}){return Lo("div",{className:"sf-part-panel",children:[U(fs,{inline:!0,name:l(e),onSelect:o}),t,r,a]})}function cs({source:e,slug:o,menuId:t}){let r=vN(),a=Ey[e],n=!a.needsSlug||!!o;return U("div",{className:"sf-note sf-note--source",children:Lo("p",{className:"es-field-hint sf-hint-keep",children:[l(ky[e]),n?Lo(gd,{children:[" ",U("button",{type:"button",className:"sf-source-open",onClick:()=>{a.type==="storefront-editor:open-menus"?r.send(a.type,{menuId:t??null}):o&&r.send(a.type,{slug:o})},children:l(Ty)})]}):null]})})}var My=4,PN=120;function LN({region:e,sizePx:o,face:t,base:r,onFollowStyle:a,source:n,slug:s,onBack:i}){let f=e.follows;return Lo("div",{className:"sf-note",children:[U("p",{children:U("strong",{children:l(e.label)})}),U("p",{children:o?l("Its size follows Site styles \u25B8 {follows} \u2014 {px}px right now.",{follows:l(f),px:Math.round(o)}):l("Its size follows Site styles \u25B8 {follows}.",{follows:l(f)})}),a?U(gd,{children:U(pN,{label:l("Style"),icon:U(mN,{}),hint:l("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:l(e.label).toLowerCase()}),children:U(EN,{face:t,base:r,onPick:a})})}):U("p",{className:"es-field-hint sf-hint-keep",children:l("Only the size follows a site style. This section sets its own font, weight and letter case.")}),n?U(cs,{source:n,slug:s}):null,U(fs,{inline:!0,name:l("Page"),onSelect:i})]})}function ON({onBack:e}){return Lo("div",{className:"sf-note",children:[U("p",{children:U("strong",{children:l("This part is no longer here.")})}),U("p",{children:l("The section it belonged to has been changed or removed.")}),U(fs,{inline:!0,name:l("Page"),onSelect:e})]})}function RN({onBack:e,partId:o,why:t}){return Lo("div",{className:"sf-note",children:[U("p",{children:U("strong",{children:l("This part's settings did not open.")})}),U("p",{children:l("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.")}),U("p",{className:"sf-note-detail",children:Lo("code",{children:[o," \u2014 ",t]})}),U(fs,{inline:!0,name:l("Page"),onSelect:e})]})}function Hy({nodeId:e,propKey:o,onBack:t,onEditStyle:r}){let{getItemById:a,getSelectorForId:n,config:s}=IN(N=>N),i=CN(),f=hy(),{partStyle:u}=Cy(),{fonts:p,textStyles:m}=V(),x=fN(bN),I=!x?.capabilities?.hasSiteTheme,{persist:b}=Yt({themeFromDocument:I,tokenRef:x?.tokenRef,siteId:x?.siteId??null}),C=wl({themeFromDocument:I,persist:b}),[w,k]=_y(!1),v=yN()==="mobile",g=cN(null),y=a(e),L=n(e),F=y?s.components[y.type]:void 0,{key:O,row:E}=po(o),D=F?.fields?.[O],G=E?wr(D,E):D,B=hl(e,o),R=y?.props??{},H=nr(G),_=jn(G),ae=fh(G),se=y?La(y.type):null,Ie=y?Fy(y.type,O):null,ro=E?na(R[O],E):R[O],Ye=!!E&&!(Array.isArray(R[O])&&E.index<R[O].length);xd(()=>{Iy(document)||g.current?.querySelector(".es-copy [contenteditable='true'], .es-copy textarea, .sf-copybox textarea, .sf-copybox input")?.focus()},[B]);let[Fe,ao]=_y(0);xd(()=>ao(0),[B]);let Me=!!y&&!Ye&&(!L||!G);xd(()=>{if(!Me||Fe>=My)return;let N=setTimeout(()=>ao(Te=>Te+1),PN);return()=>clearTimeout(N)},[Me,Fe]);let Re=Me&&Fe<My;if(!y||Ye)return U(ON,{onBack:t});let ye=By(y.type),Ce=ye?md(ye,o):null;if(ye&&Ce){let N=u?.partId===B?u:null,Te=ye[Ce],ho=Te.writable===!0&&!!L,Vo=zs=>{L&&i.replaceComponent(L.zone,L.index,{...y,props:cr(R,o,"role",zs)})};return U(LN,{region:Te,sizePx:N?.base.sizePx??null,face:Id(R,o,N,p),base:N?.base??null,onFollowStyle:ho?Vo:void 0,source:se,slug:Pa(R),onBack:t})}if(!L||!G)return Re?U("div",{className:"sf-note","aria-busy":"true"}):U(RN,{onBack:t,partId:B,why:L?"no field":"no selector"});let Xe=N=>{i.replaceComponent(L.zone,L.index,{...y,props:N})},He=N=>{if(rt(N).hidden!==rt(ro).hidden||!H){let Te=E?Wf(R,O,E,N):{...R,[O]:N};Te&&Xe(Te);return}as({node:y,propKey:o,kind:H,zone:L.zone,index:L.index},rt(N).text,i.replaceComponent)},Ze=ro,Ae=u?.partId===B?u:null,P=Ae?.styleOwner,oe=P?a(P.owner):null,j=P&&oe?n(P.owner):null,ge=!!(P&&oe&&j),ve=ge?oe.props??{}:R,ze=ge?N=>i.replaceComponent(j.zone,j.index,{...oe,props:N}):Xe,$e=ge?P.kind:Xl(y?.type,o),ee=Cl(ve,$e),le=[{partKey:$e,face:Id(ve,$e,Ae,p),sizeGroup:Ae?.sizeGroup??null,base:Ae?.base??BN,style:ee}],Qe=TN(le,N=>N.sizeGroup),dt=ls(Ae?.inks),ut=(N,Te)=>{let ho=ve;for(let Vo of le)ho=cr(ho,Vo.partKey,N,Te);ze(ho)},Hs=N=>N?ut("textStyle",N):Nr({textStyle:null,role:null}),Nr=N=>{let Te=ve;for(let ho of le)for(let[Vo,zs]of Object.entries(N))Te=cr(Te,ho.partKey,Vo,zs??null);ze(Te)},Mr=H==="text"||H==="textarea",{text:z,hidden:q}=rt(ro),Z=G?.[SN]?.label??o,ce=q?l("Show {label} on the slide",{label:l(Z)}):l("Hide {label} on the slide",{label:l(Z)}),no=Lo("div",{className:"sf-field-head",children:[U(xN,{}),U("span",{className:"sf-field-label sf-field-label--inline",children:l(Z)}),Mr&&U(gN,{content:ce,children:U("button",{type:"button",className:"sf-field-eye","aria-pressed":q,"aria-label":ce,onClick:()=>He({text:z,hidden:!q}),children:q?U(Dy,{name:"eye-off",size:14}):U(Dy,{name:"eye",size:14})})})]}),Ko=!_&&ae,en=!!H&&(sI(G)||_||q||!ae),zt=Id(ve,$e,Ae,p),tw=zt.kind==="role"?zt.role:null,Ws=bh(ee)??Nh(tw),bu=lt(C.saved,C.old),rw=Object.entries(ee).filter(([N,Te])=>N!=="role"&&N!=="textStyle"&&Te!==void 0).length,aw=()=>{let N=ve;for(let Te of le){let{role:ho,textStyle:Vo}=Te.style;N=wh(N,Te.partKey),ho&&(N=cr(N,Te.partKey,"role",ho)),Vo&&(N=cr(N,Te.partKey,"textStyle",Vo))}ze(N)},pt=Ws,nw=Mh(le[0].style),lw=pt?bu.find(N=>N.id===pt)?.name??pt:"",sw=()=>{k(!1),pt&&(C.write(Hh({saved:C.saved,old:C.old,styleId:pt,values:nc(le[0].style)}),!0),aw())};return Lo(FN,{sectionName:F?.label??y.type,onBack:t,textEditor:U("div",{ref:g,className:"sf-part-text",children:en?U(gy,{text:z,onTextChange:N=>He(Mr?{text:N,hidden:q}:N),multiline:pl(H),markup:H!=="plainText",styled:!1,style:le[0].style,base:le[0].base,setValue:Nr,colors:dt,placeholder:hd(JI(G))??void 0,ariaLabel:l(Z),head:no,typedOnCanvas:f===B}):H?Mr?no:null:U(uN,{field:G,name:o,value:Ze,onChange:He,id:`sf-part-${e}-${o}`})}),children:[Ie&&U(cs,{source:Ie,slug:Pa(R),menuId:ss(R)}),Ko&&U(hN,{style:{value:Ws??"",options:[{value:"",label:l("No style"),description:l("Section\u2019s own")},...bu.map(N=>({value:N.id,label:N.name,description:N.values.font?Gt(N.values.font)?.label:void 0}))],onChange:N=>Hs(N||null),changed:rw>0,onEditStyles:r,onUpdateStyle:pt&&nw?()=>k(!0):void 0},font:{value:ee.font??"",styleValue:Gt(le[0].base.fontKey)?.label,options:co.map(N=>({label:N.label,value:N.key})),onChange:N=>ut("font",N||null)},italic:{value:ee.italic,styleValue:AN(m,Ws),onChange:N=>ut("italic",N??null)},cells:pd(le[0].style,le[0].base,Nr,{phone:v}),align:{value:ee.align??"",styleValue:le[0].base.align,onChange:N=>ut("align",N||null)},letterCase:{value:ee.case??"",styleValue:le[0].base.case,onChange:N=>ut("case",N||null)}}),w&&pt&&U(yy,{styleName:lw,onCancel:()=>k(!1),onConfirm:sw}),Ko&&Qe===null&&U("p",{className:"es-field-hint sf-hint-keep",children:l("Fixed size \u2014 the site\u2019s Text setting doesn\u2019t resize this.")})]})}function AN(e,o){return!o||!Array.isArray(e)?!1:e.find(t=>t?.id===o)?.values?.italic===!0}var BN={fontKey:"",sizePx:16,weight:400,lineRatio:1.4,letterEm:0,align:"left",case:"none",paddingPx:0,widthPx:nt};import{jsx as xo,jsxs as bd,Fragment as _N}from"react/jsx-runtime";import{useCallback as DN,useRef as NN,useState as Ra}from"react";import{InspectorIconButton as MN}from"efficient-easel/chrome";import{PopupMenu as HN,PopupMenuItem as WN,PopupMenuLabel as ds}from"efficient-shell/ui";import{CopyToPageIcon as zN}from"efficient-easel/icons";import{useEaselSession as GN}from"efficient-easel/screen/lib/session-context";import{cloneNodeWithFreshIds as UN}from"efficient-easel/screen/lib/puck/section-doc";import{FOOTER_TYPE as $N}from"efficient-easel/draw";function Wy({node:e,currentSlug:o,siteId:t,tokenRef:r,runAuthed:a,onNotify:n}){let[s,i]=Ra(!1),[f,u]=Ra(null),p=GN(),[m,x]=Ra(!1),[I,b]=Ra(null),C=NN(null),[w,k]=Ra(null),v=DN(async()=>{if(p.usesBridgedToken&&!r.current){x(!0);return}try{u(await We(p).pages.list(t?{siteId:t}:void 0))}catch{x(!0)}},[r,t,p]),g=()=>{if(s){i(!1);return}let F=C.current?.getBoundingClientRect();F&&k({top:F.bottom+6,right:Math.max(8,window.innerWidth-F.right)}),u(null),x(!1),v(),i(!0)},y=(f??[]).filter(F=>F.slug!==o),L=async F=>{if(I)return;b(F.slug);let O=UN(e),E=p.documentHooks?.storedNode?.(O)??O,D=We(p).pages,G=await a(async()=>{let B=await D.load({id:F.id});if(!B)throw new Error(`Page "${F.slug}" no longer exists.`);let R=B.layout??{},H=Array.isArray(R.content)?[...R.content]:[],_=H.findIndex(ae=>ae?.type===$N);H.splice(_===-1?H.length:_,0,E),await D.save(F.id,{layout:{root:{},zones:{},...R,content:H}},{version:B.version,clientId:""})});b(null),i(!1),n?.(G?l("Duplicated to \u201C{name}\u201D",{name:F.label}):l("Couldn\u2019t duplicate the section \u2014 please retry"),G?"success":"error")};return bd(_N,{children:[xo("span",{"data-menu-toggle":!0,style:{display:"contents"},children:xo(MN,{buttonRef:C,label:l("Duplicate to another page"),hasPopup:"menu",expanded:s,onClick:g,children:xo(zN,{size:15})})}),s&&w&&xo(HN,{portal:!0,style:{top:w.top,right:w.right},onClose:()=>i(!1),children:bd("div",{role:"menu","aria-label":l("Duplicate to page"),children:[xo(ds,{children:l("Duplicate to page")}),m?xo(ds,{children:l("Couldn\u2019t load pages")}):f===null?xo(ds,{children:l("Loading\u2026")}):y.length===0?xo(ds,{children:l("No other pages")}):y.map(F=>bd(WN,{role:"menuitem",disabled:I!==null,onClick:()=>{L(F)},children:[xo("span",{className:"min-w-0 flex-1 truncate",children:F.label}),I===F.slug?xo("span",{className:"shrink-0 text-xs",children:l("Copying\u2026")}):F.draft&&xo("span",{className:"shrink-0 text-xs",children:l("draft")})]},F.id))]})})]})}import{useScreenDocument as qM}from"efficient-easel/screen/components/ScreenDocumentContext";import{useSectionOps as jM}from"efficient-easel/screen/lib/puck/use-section-ops";import{SELECTION_MODE as KM}from"efficient-easel/screen/lib/screen-parts";import{usePreviewParts as VM}from"efficient-easel/draw/client";import{jsx as Aa,jsxs as qN}from"react/jsx-runtime";import{SettingsDrill as jN}from"efficient-easel/panel";import{UiIcon as KN}from"efficient-easel/draw/client";var VN="Not shown on the page";function YN({part:e,onOpen:o}){return Aa(jN,{name:l(e.label),preview:e.offPage?l(VN):e.preview||l("Empty"),offPage:e.offPage,status:e.hidden?Aa("span",{className:"sf-entry-eye",role:"img","aria-label":l("Hidden on the page"),children:Aa(KN,{name:"eye-off",size:14})}):void 0,onOpen:()=>o(e.key)})}function yd(e){return e.filter(o=>!o.identifier)}function zy({parts:e,onOpen:o,heading:t=!0}){let r=yd(e);return r.length?qN("div",{className:"sf-entries",children:[t?Aa("h3",{className:"sf-entries-head",children:l("Text")}):null,r.map(a=>Aa(YN,{part:a,onOpen:o},a.key))]}):null}import{HEADER_TYPE as YM,ROOT_ZONE as ES}from"efficient-easel/draw";import{HEADER_TYPE as Ve,FOOTER_TYPE as me,newNodeId as XN}from"efficient-easel/draw";function us(){return{type:Ve,props:{id:XN(Ve)}}}var Gy=[{type:"FooterLogo",label:"Logo"},{type:"FooterMenu",label:"Menu"},{type:"FooterText",label:"Text"},{type:"FooterEmailSignup",label:"Email Form"},{type:"FooterSocial",label:"Social Logos"},{type:"FooterGroup",label:"Footer Box"},{type:"FooterDivider",label:"Divider"}],ZN=Gy.filter(e=>e.type!=="FooterLogo"&&e.type!=="FooterGroup"),QN="FooterGroup",Uy="blocks";function $y(e){return e===me?Gy:e===QN?ZN:null}function ps(){let e=(o,t)=>({type:o,props:{id:`${o}-${crypto.randomUUID()}`,...t}});return[e("FooterLogo",{widthPct:100,align:"left",tagline:""}),e("FooterGroup",{direction:"vertical",align:"start",blocks:[e("FooterText",{text:"Join our email list",size:"md",tone:"default"}),e("FooterEmailSignup",{heading:"",placeholder:"Email address",buttonLabel:"Subscribe"})]})]}var xe="SiteHeader",de="SiteFooter",Sd="sections",RJ=[xe,de],Tr=e=>e===xe||e===de,qy=e=>`${e}:${Sd}`;function jy(e,o,t=[]){return{type:e,props:{id:o,[Sd]:t}}}var JN=new Set(["Footer",xe,de]);function Er(e){let o=new Set,t=!1,r=e.filter(a=>{let n=a?.type??"";return n==="Header"?(t=!0,!1):JN.has(n)?o.has(n)?(t=!0,!1):(o.add(n),!0):!0});return t?r:e}function ms(e,o){return e.some(t=>t?.type===o.type)?e:o.type===xe?[o,...e]:[...e,o]}var Ky={[xe]:{max:3,takes:["Flex","Ticker"]},[de]:{max:6,takes:["Flex","Prose","Logos","Divider"]}};function Vy(e,o,t){if(!Tr(e))return!0;let r=Ky[e];return t<r.max&&r.takes.includes(o)}function Yy(e,o){let t=o,r=t?.props?.id;if(r==null)return null;let a=e?.content;if(!Array.isArray(a))return null;for(let n of a){if(!Tr(n?.type))continue;let s=n.props?.[Sd];if(!Array.isArray(s)||!s.some(f=>f?.props?.id===r))continue;let i=Ky[n.type];return i.takes.includes(t?.type??"")?s.length>=i.max?{group:n.type,why:"full"}:null:{group:n.type,why:"type"}}return null}function Cd(e){switch(e?.type){case xe:case de:return l("On every page");case Ve:case me:return l("On every page \xB7 old style");default:return null}}var Xy=()=>null,Zy=()=>l("Changed on every page");function xs(e,o){let t=Pp(e,o);if(t)return t;let r=Yy(e,o);if(!r)return null;let a=r.group===xe;return r.why==="type"?a?l("The header cannot take another one of these"):l("The footer cannot take another one of these"):a?l("The header holds at most 3 sections"):l("The footer holds at most 6 sections")}import{jsx as gs,Fragment as iM,jsxs as fM}from"react/jsx-runtime";import{useState as cM}from"react";import{createNode as dM,newId as uM}from"efficient-easel/data";import{useEasel as pM}from"efficient-easel/easel";import{Banner as mM,Button as vd}from"efficient-shell/ui";import{useScreenDocument as xM}from"efficient-easel/screen/components/ScreenDocumentContext";var Is="Flex",eM={FooterMenu:"MenuBlock",FooterEmailSignup:"EmailFormBlock",FooterSocial:"SocialLogosBlock"},oM=e=>{let{id:o,...t}=e;return t},Qy=e=>typeof e=="string"?e:"",hs=e=>typeof e=="number"&&Number.isFinite(e)?e:void 0,Jy={sm:12,md:13,lg:15},tM="md",eS=1.5,rM={size:13,lineHeight:eS,width:280},aM=14,nM=40,lM=e=>e==="center"||e==="right"?e:"left";function sM(e){let o={},t=[["padTop","sectionPaddingTop"],["padRight","sectionPaddingRight"],["padBottom","sectionPaddingBottom"],["padLeft","sectionPaddingLeft"]];for(let[r,a]of t){let n=hs(e[r]);n&&(o[a]=n)}return o}function oS(e,o){let t=e.props??{},r=eM[e.type];if(r)return[o(r,oM(t))];switch(e.type){case"FooterLogo":{let a=lM(t.align),n=o("LogoBlock",{...t.reverse?{reverse:t.reverse}:{},...typeof t.customColor=="string"&&t.customColor?{customColor:t.customColor}:{},heightPx:Math.round(ju*((hs(t.widthPct)??100)/100)),href:"/",align:a,...sM(t)}),s=Qy(t.tagline).trim();return s?[n,o("Text",{text:s,tone:"dim",align:a,_partStyles:{text:{...rM}}})]:[n]}case"FooterText":{let a=typeof t.size=="string"&&t.size in Jy?t.size:tM;return[o("Text",{text:Qy(t.text),tone:typeof t.tone=="string"?t.tone:"default",_partStyles:{text:{size:Jy[a],lineHeight:eS}}})]}case"FooterDivider":{let a=hs(t.thickness),n=hs(t.lengthPct);return[o("Divider",{...a!==void 0?{thickness:a}:{},...n!==void 0?{lengthPct:n}:{},...t.hideOnMobile===!0?{hideOnMobile:!0}:{}})]}case"FooterGroup":{let a=Array.isArray(t.blocks)?t.blocks:[];return[o(Is,{direction:t.direction==="horizontal"?"row":"column",gap:Qr("FooterGroup",t.gap),align:t.align==="center"||t.align==="end"?t.align:"start",content:a.flatMap(n=>oS(n,o))})]}default:return[]}}function Ba(e,o,t){let r=e&&Array.isArray(e.props?.blocks)?e.props.blocks:[],a=u=>o(Is,{direction:"row",wrap:!0,share:"equal",gap:nM,content:u}),n=[],s=[];for(let u of r){let p=oS(u,o);if(u.type==="FooterDivider"){s.length&&n.push(a(s)),s=[],n.push(...p);continue}p.length<=1?s.push(...p):s.push(o(Is,{direction:"column",gap:aM,align:"stretch",content:p}))}(s.length||!n.length)&&n.push(a(s));let i=o(Is,{direction:"column",content:[o("LegalLineBlock")]}),f=jy(de,t,[...n,i]);return{...f,props:{...f.props,...e?.props?.width==="full"?{fullWidth:!0}:{}}}}function tS(){let{appState:e,dispatch:o,config:t}=pM(p=>p),{readOnly:r}=xM(),[a,n]=cM(!1),s=e.data.content;if(r||s.some(p=>p.type===de))return null;let i=s.find(p=>p.type===me)??null,f=(p,m)=>dM(t,p,m),u=()=>{let p=Ba(i,f,uM(de));o({type:"setData",data:m=>({...m,content:[...ms(m.content,p)]}),recordHistory:!0}),n(!1)};return gs(mM,{tone:"info",title:l("This footer uses the old layout"),action:a?fM(iM,{children:[gs(vd,{variant:"primary",size:"sm",onClick:u,children:l("Switch now")}),gs(vd,{variant:"secondary",size:"sm",onClick:()=>n(!1),children:l("Cancel")})]}):gs(vd,{variant:"secondary",size:"sm",onClick:()=>n(!0),children:l("Switch to Box footer")}),children:l("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.")})}import{jsx as Rd}from"react/jsx-runtime";import{useLayoutEffect as OM,useMemo as SS,useRef as RM,useState as Ld}from"react";import{useEasel as AM,useSelectedFields as BM}from"efficient-easel/easel";import{Inspector as _M,planFields as CS}from"efficient-easel/fields";import{jsx as Fr}from"react/jsx-runtime";import{usePreviewDevice as IM}from"efficient-easel/draw/client";import{NoControlMark as rS,noControlField as aS}from"efficient-easel/screen/lib/puck/panel-no-control-mark";var wd=e=>l(Jt[e==="content"?"page":"full"]),nS=e=>`${e} ${l("from Site styles")}`;function lS(){let{siteWidth:e,sectionBackgroundWidth:o,sectionContentWidth:t}=V();return{px:typeof e=="number"?e:we.default,background:o??"full",content:t??"content"}}function sS(){try{return IM()==="mobile"}catch{return!1}}function hM({type:e,onChange:o}){let t=Eo(),r=lS(),a=sS(),n=pf(e,t).background;return Fr(dl,{value:n??r.background,changed:n!==null,detail:nS(wd(r.background)),onChange:s=>o(s),onReset:()=>o(ea),disabled:a})}function gM({type:e,onChange:o}){let t=Eo(),[,r]=Xn("contentMax"),a=lS(),n=sS(),s=pf(e,t),i=(s.background??a.background)==="content",f=s.content??a.content;return Fr(ul,{mode:i&&f==="full"?"content":f,px:s.contentMax??a.px,max:i?a.px:we.max,changed:s.content!==null,detail:nS(a.content==="full"?wd("full"):`${wd("content")} ${a.px}px`),fullClosed:i,disabled:n,hint:n?XI:i?KI:void 0,onMode:u=>{o(u),u==="full"&&r(null)},onPx:u=>{o("content"),r(u===a.px?null:u)},onReset:()=>{o(ea),r(null)}})}function bM(e){return at({_gWidth:De(cl),backgroundWidth:{type:"custom",render:({onChange:o})=>Fr(hM,{type:e,onChange:o})},contentWidth:{type:"custom",render:({onChange:o})=>Fr(gM,{type:e,onChange:o})},contentMax:{...aS({type:"custom",render:()=>Fr(rS,{})},"always"),reachedBy:"contentWidth"},widthMode:{...aS({type:"custom",render:()=>Fr(rS,{})},"always"),reachedBy:"backgroundWidth"}})}var iS=Object.keys(bM(""));import{deviceField as yM,deviceMetaOf as cS}from"efficient-easel/screen/lib/puck/device-fields";import{DESIGN_GROUPS as Td,SETTINGS_BUCKETS as SM}from"efficient-easel/panel";import{BUCKET_KEY as oo,DESIGN_GROUP_KEY as _a}from"efficient-easel/screen/lib/puck/field-buckets";var Da=SM;var CM="Editor only \u2014 not shown live",Ed={"Archive link":"Content",Article:"Content",Blocks:"Content","Blog posts":"Content","Browser mock":"Content",Button:"Content","Call to action":"Content","Car prompt":"Content","Card link":"Content",Cards:"Content","Claims bars":"Content","Contact info":"Content",Content:"Content","Content source":"Content",Contents:"Content",Filters:"Content","Show on a card":"Content",Footnote:"Content",Form:"Content",Founders:"Content","Gallery A":"Content","Gallery B":"Content","Gallery link":"Content",Header:"Content","Header link":"Content","Image caption":"Content","In this issue":"Content",Items:"Content","Kanban columns":"Content",Lead:"Content","Left panel":"Content",Link:"Content",Links:"Content",List:"Content","Message form":"Content",Metadata:"Content",Milestones:"Content","Mockup card":"Content","Newsletter panel":"Content",Offices:"Content",Options:"Content","Others gallery":"Content","Overlay button":"Content",Product:"Content","Product page":"Content",Products:"Content","Pull quote":"Content",Questions:"Content","Recent issues":"Content","Recent posts":"Content",Reviews:"Content","Right panel \xB7 actions":"Content","Right panel \xB7 choices":"Content","Right panel \xB7 form":"Content","Routing groups":"Content",Rows:"Content",Search:"Content",Section:"Content","Section header":"Content",Sections:"Content","Signup form":"Content","Source product":"Content","Stat & note":"Content",Stats:"Content","Submit button":"Content","Success state":"Content",Wheel:"Content",Terminal:"Content",Text:"Content","Text column":"Content","Timeline entries":"Content","Top row":"Content",Total:"Content","Trailing note":"Content","\u201COther\u201D reason":"Content","Background images":"Design",Gallery:"Content",Image:"Content","Image column":"Content",Images:"Content",Logo:"Content",Media:"Content","Background image":"Design",Color:"Design","Image tint":"Design",Style:"Design",Shape:"Design",Texture:"Design","Text style":"Design",Motion:"Animation",Anchor:"Anchor",Arrangement:"Layout","Auto-slide":"Layout",Bar:"Layout","Cell width":"Size",Behavior:"Layout",Controls:"Layout",Diagram:"Layout",[CM]:"Layout","Filters shown":"Layout","Slide picker":"Layout",Arrows:"Layout","On a phone":"Layout",Nudge:"Position","Stick to top":"Position","Image gallery":"Layout",Grid:"Layout",Layout:"Layout",Padding:"Layout",Price:"Layout",Preview:"Layout",Setup:"Layout","Show / hide elements":"Layout","Show in the buy box":"Layout",Visibility:"Layout",Width:"Size",Height:"Size"},dS={"AlloyWheelsListing._gCards":"Design","ProductGrid._gCards":"Design"},uS={"Text._gSpacing":"Size","Heading._gSpacing":"Size"};function kd(e,o,t){let r=`${e}.${o}`;return uS[r]??dS[r]??Ed[t]}function pS(e){return e==="Animation"?[oo.Animation]:[oo.Design,_a[e]]}function bs(...e){let o=[];for(let t of e)for(let r of Object.values(t)){let a=cS(r),n=zo(a?a.inner:r),s=n?Ed[n.label]:void 0;if(s)for(let i of pS(s))o.includes(i)||o.push(i)}return o}var xee=[...bs(Jn(),el("full"),ol(),tl(),vf()),...Object.keys(Jn()),...Object.keys(el("full")),...Object.keys(ol()),...Object.keys(tl()),...Object.keys(vf()),...iS],Iee=[...bs(Vn()),...Object.keys(Vn())],hee=[...bs(Zn()),...Object.keys(Zn())],gee=[...bs(Qn()),...Object.keys(Qn())],vM=Object.keys(CI()),wM=new Set(["cardImage","imageBackground"]),bee=[...pS(kd("ProductGrid","_gCards","Cards")??"Design"),...vM.filter(e=>e.startsWith("_g")||wM.has(e))],yee=Object.keys(vI()),See=Object.keys(wI({bottomDefault:!0})),kM={"ImageBlock._gStyle":"duplicated the Style bucket header above it (2026-09-04)","ButtonBlock._gStyle":"duplicated the Style bucket header above it (2026-09-04)","HeroGroup._gContent":"duplicated the Content bucket header above it (2026-09-04)","HeroGroup._gLayout":"duplicated the Layout bucket header above it (2026-09-04)","Footer._gLayout":"duplicated the Layout bucket header above it (2026-09-04)","FooterLogo._gContent":"duplicated the Content bucket header above it (2026-09-04)","FooterLogo._gStyle":"duplicated the Style bucket header above it (2026-09-04)","FooterMenu._gContent":"duplicated the Content bucket header above it (2026-09-04)","FooterMenu._gStyle":"duplicated the Style bucket header above it (2026-09-04)","FooterGroup._gLayout":"duplicated the Layout bucket header above it (2026-09-04)","FooterText._gContent":"duplicated the Content bucket header above it (2026-09-04)","FooterText._gStyle":"duplicated the Style bucket header above it (2026-09-04)","FooterSocial._gStyle":"duplicated the Style bucket header above it (born tabbed, 2026-09-17)","FooterSocial._gLayout":"duplicated the Layout bucket header above it (born tabbed, 2026-09-17)","MenuBlock._gContent":"duplicated the Content bucket header above it (born tabbed, H.1)","MenuBlock._gStyle":"duplicated the Style bucket header above it (born tabbed, H.1)","EmailFormBlock._gContent":"duplicated the Content bucket header above it (born tabbed, H.1)","SocialLogosBlock._gStyle":"duplicated the Style bucket header above it (born tabbed, H.1)","SocialLogosBlock._gLayout":"duplicated the Layout bucket header above it (born tabbed, H.1)","SearchBlock._gStyle":"duplicated the Style bucket header above it (born tabbed, H.2)","CartBlock._gStyle":"duplicated the Style bucket header above it (born tabbed, H.2)","CountrySwitchBlock._gStyle":"duplicated the Style bucket header above it (born tabbed with its Show as, 2026-10-17)","Split._gContent":"duplicated the Content bucket header above it (2026-09-04)","Gallery._gVehicleContent":"duplicated the Content bucket header above it (2026-09-04)","Gallery._gWheelContent":"duplicated the Content bucket header above it (2026-09-04)","Gallery._gOthersContent":"duplicated the Content bucket header above it (2026-09-04)","Subscribe._gHeadCopy":"duplicated the Content bucket header above it (2026-09-04)","Subscribe._gLeftCopy":"duplicated the Content bucket header above it (2026-09-04)","Subscribe._gRightCopy":"duplicated the Content bucket header above it (2026-09-04)","CollectionCard._gContent":"duplicated the Content bucket header above it (A Card Sets Its Own Corners)","HeroSlide._gContent":"duplicated the Content bucket header above it (Hero Slide Tabs And Theme)","KeyFeatures._gContent":"duplicated the Content bucket header above it (66049)","KeyFeatures._gStyle":"duplicated the Style bucket header above it (66049)","ParagraphsA._gContent":"duplicated the Content bucket header above it (66049)","ParagraphsA._gStyle":"duplicated the Style bucket header above it (66049)","Chart._gContent":"duplicated the Content bucket header above it (66049)","Chart._gStyle":"duplicated the Style bucket header above it (66049)","Logos._gContent":"duplicated the Content bucket header above it (66049)","Logos._gStyle":"duplicated the Style bucket header above it (66049)","Mockup._gContent":"duplicated the Content bucket header above it (66049)","Mockup._gStyle":"duplicated the Style bucket header above it (66049)","Stats._gContent":"duplicated the Content bucket header above it (66049)","Stats._gStyle":"duplicated the Style bucket header above it (66049)","StatsParagraph._gContent":"duplicated the Content bucket header above it (66049)","StatsParagraph._gStyle":"duplicated the Style bucket header above it (66049)","Testimonials._gContent":"duplicated the Content bucket header above it (66049)","Testimonials._gStyle":"duplicated the Style bucket header above it (66049)","AppointmentBooking._gContent":"duplicated the Content bucket header above it (66050)","BookingBox._gContent":"duplicated the Content bucket header above it ([SPLIT] Booking Form Into Three Boxes) \u2014 the same fault its own section retired in 66050, one level down","FAQ._gContent":"duplicated the Content bucket header above it (66050, family sweep)","FAQ._gLayout":"duplicated the Layout bucket header above it (66050, family sweep)","Form._gContent":"duplicated the Content bucket header above it (66050)","ReviewForm._gContent":"duplicated the Content bucket header above it (66050)","SubmitBuild._gContent":"duplicated the Content bucket header above it (66050)","SubmitBox._gContent":"duplicated the Content bucket header above it ([SPLIT] SubmitBuild Keeps Its Two Columns) \u2014 the same fault its own section retired in 66050, one level down","CheckoutCTA._gContent":"duplicated the Content bucket header above it (66051)","CheckoutCTA._gLayout":"duplicated the Layout bucket header above it (66051)","DeliveryOptions._gContent":"duplicated the Content bucket header above it (66051)","DeliveryOptions._gLayout":"duplicated the Layout bucket header above it (66051)","OrderSummary._gContent":"duplicated the Content bucket header above it (66051)","OrderSummary._gLayout":"duplicated the Layout bucket header above it (66051)","PaymentBadges._gContent":"duplicated the Content bucket header above it (66051)","PaymentBadges._gLayout":"duplicated the Layout bucket header above it (66051)","Collections._gContent":"duplicated the Content bucket header above it (66052)","Collections._gLayout":"duplicated the Layout bucket header above it (66052)","DocMasthead._gContent":"duplicated the Content bucket header above it (66053)","Events._gContent":"duplicated the Content bucket header above it (66054)","Events._gLayout":"duplicated the Layout bucket header above it (66054)","FeaturedCover._gContent":"duplicated the Content bucket header above it (66054)","Series._gStyle":"duplicated the Style bucket header above it (66054)","Flex._gContent":"duplicated the Content bucket header above it (66055)","Flex._gLayout":"duplicated the Layout bucket header above it (66055)","SectionHeader._gContent":"duplicated the Content bucket header above it (66055)","Breadcrumb._gContent":"duplicated the Content bucket header above it (66056)","CategoryBar._gStyle":"duplicated the Style bucket header above it (66056)","Hero._gContent":"duplicated the Content bucket header above it (66056)","Hero._gStyle":"duplicated the Style bucket header above it (66056)","HeroSingle._gStyle":"duplicated the Style bucket header above it (66056)","IntroBleed._gContent":"duplicated the Content bucket header above it (66056)","IntroBleed._gLayout":"duplicated the Layout bucket header above it (66056)","BundleOffer._gLayout":"duplicated the Layout bucket header above it (66059)","ProcessSteps._gContent":"duplicated the Content bucket header above it (66059)","Banner._gContent":"duplicated the Content bucket header above it (66060.1)","Banner._gLayout":"duplicated the Layout bucket header above it, and governed no controls (66060.1)","Manifesto._gContent":"duplicated the Content bucket header above it (66060.1)","SubscribeBlogs._gHeadCopy":"duplicated the Content bucket header above it (66060.1)","SubscribeBlogs._gLeftCopy":"duplicated the Content bucket header above it (66060.1)","SubscribeBlogs._gRightCopy":"duplicated the Content bucket header above it (66060.1)","Ticker._gContent":"duplicated the Content bucket header above it (66060.1)","Ticker._gStyle":"duplicated the Style bucket header above it (66060.1)","Timeline._gContent":"duplicated the Content bucket header above it (66060.1)","TitleWithButtons._gContent":"duplicated the Content bucket header above it (66060.1)","TitleWithButtons._gStyle":"duplicated the Style bucket header above it (66060.1)","Cards._gContent":"duplicated the Content bucket header above it (66218)","Cards._gStyle":"duplicated the Style bucket header above it (66218)","Prose._gContent":"duplicated the Content bucket header above it (66218)","Reviews._gContent":"duplicated the Content bucket header above it (66218)","Reviews._gStyle":"duplicated the Style bucket header above it (66218)"},mS={Content:["Content"],Size:["Size"],Design:["Design","Style"],Layout:["Layout"],Position:["Position"],Anchor:["Anchor"],Animation:["Animation"]},xS={_gAnchor:"repeated the Anchor group heading above it (two tabs, 11.0.0)"};{let e={...Jn(),...el("full"),...ol(),...tl(),...Vn(),...Zn(),...Qn()};for(let o of Object.keys(xS)){let t=zo(e[o]),r=t?Ed[t.label]:void 0;if(!t||t.level!==2||!r||!mS[r].includes(t.label))throw new Error(`INJECTED_RETIRED (lib/puck/field-groups.ts) lists "${o}", but no uniform builder makes a level-2 heading by that key whose label repeats its place's word. The heading was renamed, moved or removed and the row is stale \u2014 a list that quietly matches nothing is worse than no list.`)}}var TM=new Set(["_sContent","_sStyle","_sLayout","_sMedia"]),EM=new Map([[oo.Design,"Content"],[oo.Animation,"Animation"],...Td.map(e=>[_a[e],e])]);function IS(e){let o=new Set([...Object.values(oo),_a.Content]);for(let[t,r]of Object.entries(e))if(!o.has(t)&&zo(r)?.level===1)return 1;return 2}function FM(e){let o=`${e}.`;return Object.keys(kM).filter(t=>t.startsWith(o)).map(t=>t.slice(o.length))}function PM(e,o){let t=cS(e),r=De(o);return t?yM(t.tier,r):r}function LM(e,o){let t=zo(o);return t?e==="Content"||e==="Animation"?dI(o,t.label):uI(o):o}function fS(e){return e==="Design"?Td:["Animation"]}function Cee(e,o){let t=[],r=new Set(FM(o)),a=new Set,n=!1,s=null;for(let[x,I]of Object.entries(e)){let b=zo(I);if(TM.has(x))throw new Error(`${o}.${x}: that key was a tab header until efficient-web-builder 11.0.0, when the panel moved to two tabs (Design \xB7 Animation). Its tab is gone, so the key may not come back. Give the heading a key of the section's own (\`_g\u2026\`), or open a Design group with its own key (\`_dDesign: section("Design")\`, \`_dLayout: section("Layout")\`).`);let C=EM.get(x);if(C!==void 0){if(b?.level!==1)throw new Error(`${o}.${x}: that key is reserved for the ${C} heading of the settings panel, but this field is ${b?`a level-${b.level} "${b.label}" header`:"not a header"}, so it cannot serve as one. Rename the section's own field.`);(x===oo.Design||x===oo.Animation)&&(n=!0),t.push(s={place:C,entries:[],adopted:!0});continue}if(!b){s||t.push(s={place:"Content",entries:[]}),s.entries.push([x,I]);continue}if(r.has(x)||x in xS){let k=kd(o,x,b.label);if(b.level!==2||!k||!mS[k].includes(b.label))throw new Error(`${o}.${x}: ${r.has(x)?"RETIRED":"INJECTED_RETIRED"} (lib/puck/field-groups.ts) lists this sub-heading as one whose name repeats the place it sits in, but it is a level-${b.level} "${b.label}" header in the ${k??"(unclassified)"} place. Only a level-2 header whose label is one of its place's words (PLACE_WORDS) may be retired \u2014 anything else is a heading a merchant reads for its own sake. Fix the row or drop it.`);r.has(x)&&a.add(x),t.push(s={place:k,entries:[]});continue}let w=kd(o,x,b.label);if(!w)throw new Error(`${o}.${x}: the inspector group "${b.label}" is not classified in LABEL_GROUP (lib/puck/field-groups.ts), so there is no way to say which of ${[...Td,"Animation"].join(" / ")} its controls belong under. Classify it \u2014 an unclassified group silently lands wherever it was declared, which is the whole bug.`);t.push(s={place:w,entries:[[x,b.level===2?I:PM(I,b.label)]]})}let i=new Set(Object.entries(e).filter(([,x])=>zo(x)).map(([x])=>x));for(let[x,I]of[["BLOCK_KEY_GROUP",uS],["KEY_GROUP",dS]]){let b=Object.keys(I).filter(C=>C.startsWith(`${o}.`)).filter(C=>!i.has(C.slice(o.length+1)));if(b.length)throw new Error(`${o}: ${x} (lib/puck/field-groups.ts) lists ${JSON.stringify(b)}, but no fold header by that key is in this section's panel. Either the heading was renamed or removed and the row is stale, or the row names the wrong key \u2014 an override that quietly matches nothing is worse than no override.`)}let f=n?[]:[...r].filter(x=>!a.has(x));if(f.length)throw new Error(`${o}: RETIRED (lib/puck/field-groups.ts) lists ${JSON.stringify(f)}, but this section has no such fold header${f.length>1?"s":""}. Either the heading was renamed or removed and the row is stale, or the row names the wrong section \u2014 a list that quietly matches nothing is worse than no list.`);let u=new Set(t.filter(x=>x.entries.length>0).map(x=>x.place)),p=Da.filter(x=>fS(x).some(I=>u.has(I))),m={};for(let x of p){m[oo[x]]=Kn(x,x===p[0]?p:null);for(let I of fS(x)){if(!u.has(I))continue;let b=t.filter(w=>w.place===I),C=b.findIndex(w=>w.adopted);C>0&&b.unshift(...b.splice(C,1)),x==="Design"&&(m[_a[I]]=yf(I));for(let w of b)for(let[k,v]of w.entries)m[k]=LM(I,v)}}return m}function vee(e){return oo.Design in e?e:{[oo.Design]:Kn("Design",null),[_a.Content]:yf("Content"),...e}}function wee(e){return Da.some(o=>oo[o]in e)}function kee(e){let o=Da.filter(r=>oo[r]in e);if(o.length===0)return e;let t={...e};for(let r of o)t[oo[r]]=Kn(r,r===o[0]?o:null);return t}import{usePreviewDevice as DM}from"efficient-easel/draw/client";var Fd=" text",hS="Text";function Pd(e){let o=e.rows.filter(t=>t.shown);return o.length===0||o.length===1&&o[0].labelled}function gS(e){return e.filter(Pd).map(o=>o.key)}function bS(e,o){let t=null;for(let r of o){let a=e[r];!a||a.marker!==!0||typeof a.fold!="string"||(t??={...e},t[r]={...a,fold:!1})}return t??e}function yS(e,o){if(e.size!==o.size)return!1;for(let t of e)if(!o.has(t))return!1;return!0}var Od=new Map,ys=new Set;function NM(e,o){let t=new Map;for(let a of e.querySelectorAll(".es-insp-row[data-field]"))t.set(a.getAttribute("data-field")??"",a);let r=[];for(let[a,n]of o)r.push({key:a,rows:n.map(s=>{let i=t.get(s),f=!!i&&[...i.children].some(p=>!p.hidden),u=i?.querySelector(".es-field-label, .es-list-label")?.textContent?.trim();return{shown:f,labelled:f&&!!u}})});return r}var MM=Object.fromEntries(Da.map(e=>{let o=iI[e];return[e,Rd(o,{},e)]}));function Na({entries:e,entryCount:o=0,part:t=null}){let{id:r,fields:a,values:n,readOnly:s,onChange:i}=BM(),f=DM(),{appState:u,config:p}=AM(H=>H),m=Fg(f,p,u.data.content??[],u.ui.itemSelector),x=Ag(a,t),I=Eg(x,n,m),[b,C]=Ld(()=>new Set(ys)),[w,k]=Ld(()=>new Set),v=RM(null),g=SS(()=>{let H=new Map;for(let _ of CS(I).rows){if(!_.fold)continue;let ae=H.get(_.fold.key)??[];ae.push(_.name),H.set(_.fold.key,ae)}return H},[I]);OM(()=>{let H=v.current?.parentElement;if(!H)return;let _=new Set(gS(NM(H,g)));k(ae=>yS(ae,_)?ae:_)});let y=SS(()=>bS(I,w),[I,w]),L={key:Fd,rows:Array.from({length:o},()=>({shown:!0,labelled:!0}))},F=Pd(L)?void 0:{key:Fd,title:hS},[O,E]=Ld(()=>Od.get(r)),D=Od.get(r),G=CS(I).buckets,B=D&&G.includes(D)?D:O&&G.includes(O)?O:G[0],R=B===void 0||fI(G,B)!==!0;return Rd(_M,{fields:y,values:n,onChange:i,readOnly:s,showWhenContext:{...m,node:n},tab:B,onTab:H=>{Od.set(r,H),E(H)},tabIcons:MM,idPrefix:r,ariaLabel:l("Section settings"),lead:R?e:null,leadFold:F,closedFolds:b,onFold:(H,_)=>{_?ys.delete(H):ys.add(H),C(new Set(ys))},children:Rd("span",{ref:v,hidden:!0})})}import{jsx as Ad,jsxs as HM}from"react/jsx-runtime";import{InspectorUpLevel as vS}from"efficient-easel/chrome";function wS({nodeId:e,part:o,sectionName:t,onUpToSection:r}){let{select:a}=zl();return HM("div",{children:[o!=="media"?Ad(vS,{inline:!0,name:l(Ir.media),onSelect:()=>a(ga(e,"media"))}):Ad(vS,{inline:!0,name:l(t),onSelect:r}),Ad(Na,{part:o})]})}import{SettingsSwitch as XM}from"efficient-easel/panel";var PS=KM,Nd={kind:"header"},Md={kind:"website"},LS={kind:"chat"},OS={kind:"social"},Ma="Part";function ZM(e){return l("Part of {name}",{name:l(e)})}function QM(e,o,t){let r=e.describeNode(o);return{name:t,kindLabel:r?ZM(r.label):l(Ma)}}function JM(e){switch(e){case"Header":return{title:l("Header settings belong to a website."),own:l("Each website created from this template sets its own header afterwards.")};case"Appearance":return{title:l("Appearance settings belong to a website."),own:l("Each website created from this template sets its own appearance afterwards.")};case"Live chat":return{title:l("Live chat settings belong to a website."),own:l("Each website created from this template sets its own live chat afterwards.")};case"Social link":return{title:l("Social link settings belong to a website."),own:l("Each website created from this template sets its own social link afterwards.")};default:return{title:l("{what} settings belong to a website.",{what:e}),own:l("Each website created from this template sets its own {what} afterwards.",{what:e.toLowerCase()})}}}function RS({what:e}){let o=JM(e);return it("div",{className:"sf-note",children:[J("p",{children:J("strong",{children:o.title})}),it("p",{children:[l("A template is a blueprint \u2014 it has no website of its own, so there is nothing here to change.")," ",o.own]})]})}function Dd(e){let o=ha[e];return{name:Ir[e],kindLabel:Ma,icon:o,head:(t,r)=>{if(t.kind!==o)return null;let a=r.describeNode(t.nodeId);if(!a)return null;let n=FS({name:l(jl(e,a.props)),tier:"part",of:l(a.label)},{partOf:({name:s})=>l("Part of {name}",{name:s})});return{name:n.name,kindLabel:n.kind}},render:(t,r)=>t.kind===o?J(wS,{nodeId:t.nodeId,part:e,sectionName:r.describeNode(t.nodeId)?.label??"Hero",onUpToSection:()=>r.onSelectNode(t.nodeId)}):null}}var e2={header:{name:"Header",kindLabel:"Site settings",icon:"header",render:(e,o)=>{let t=o.hostPanels?.header;return t?J(t,{placeholderMode:o.capabilities.placeholderFrames,tokenRef:o.tokenRef,siteId:o.siteId,websiteName:o.websiteName,onOpenWebsiteSettings:o.onOpenWebsiteSettings,onAuthExpired:()=>o.notifyParent("storefront-editor:auth-expired")}):null}},website:{name:"Appearance",kindLabel:"Site settings",icon:"website",render:(e,o)=>J(kl,{themeFromDocument:!o.capabilities.hasSiteTheme,tokenRef:o.tokenRef,siteId:o.siteId,onNotify:o.onNotify})},chat:{name:"Live chat",kindLabel:"Site settings",icon:"chat",render:()=>J(zg,{})},social:{name:"Social links",kindLabel:"Site settings",icon:"social",render:()=>J(Kg,{unavailable:J(RS,{what:"Social link"})})},ticker:{name:xa,kindLabel:Ma,icon:"ticker",head:(e,o)=>e.kind==="ticker"?QM(o,e.heroId,l(xa)):null,render:e=>J(uy,{heroId:e.kind==="ticker"?e.heroId:""})},heroMedia:Dd("media"),heroImage:Dd("image"),heroImage2:Dd("image2"),part:{name:Ma,kindLabel:Ma,icon:"Text",head:(e,o)=>{if(e.kind!=="part")return null;let t=o.describeNode(e.nodeId);if(!t)return null;let{key:r,row:a}=po(e.propKey),n=a?wr(t.fields[r],a):t.fields[r],s=rh(l(zf(bl(n??{},r))),a),i=FS({name:s,tier:"part",of:l(t.label)},{partOf:({name:f})=>l("Part of {name}",{name:f})});return{name:i.name,kindLabel:i.kind}},render:(e,o)=>e.kind==="part"?J(Hy,{nodeId:e.nodeId,propKey:e.propKey,onBack:()=>o.onSelectNode(e.nodeId),onEditStyle:o.onOpenSiteStyles}):null}},o2=new Set(["header","website","chat"]);function t2(e,o){if(e==="puck")return null;let t=e2[e];return o2.has(e)&&!o.hasSiteSettings?{...t,kindLabel:"Not part of a template",render:()=>J(RS,{what:t.name})}:t}function AS({mode:e,onOpenWebsiteSettings:o,onOpenSiteStyles:t,onSelectNode:r,hideNodeActions:a=!1,onNotify:n,onHidePanel:s}){let{capabilities:i,tokenRef:f,notifyParent:u,currentSlug:p,siteId:m,runAuthed:x,readOnly:I,navigate:b}=qM(),C=Ol(),{rows:w,reload:k}=pa(),v=w?.find(ee=>ee.slug===p)??null,[g,y]=kS(null),{websiteName:L}=V(),F=jM({readOnly:I}),{select:O}=VM(),{selectedItem:E,getItemById:D,getSelectorForId:G,config:B,appState:R}=WM(ee=>ee),H=UM(B,E?{type:E.type,props:E.props}:null),_=E?dh(H??B.components[E.type]?.fields,E.props):[],ae=ee=>B.components[ee]?.label??ee,se=E?G(E.props.id):void 0,Ie=t2(e.kind,i),ro=$M(),Ye={capabilities:i,tokenRef:f,hostPanels:ro.chrome?.panels,describeNode:ee=>{let le=D(ee);if(!le)return null;let Qe=B.components[le.type];return{type:le.type,label:Qe?.label??le.type,fields:Qe?.fields??{},props:le.props??{}}},siteId:m,websiteName:L??null,notifyParent:u,onNotify:n,onOpenWebsiteSettings:o,onOpenSiteStyles:t,onSelectNode:r},Fe=Ie?.head?.(e,Ye)??null,ao=Fe?.name??(Ie?l(Ie.name):E?l(ae(E.type)):l("Page settings")),Me=Fe?.kindLabel??(Ie?l(Ie.kindLabel):E?se&&se.zone!==ES?l("Block"):l("Section"):l("Page")),Re=Ie?Ie.icon:E?E.type:"page",ye=Ie?null:E?B.components[E.type]?.fields??null:B.root?.fields??null,Ce=ye?IS(ye):2,Xe=e.kind==="puck"&&E?La(E.type):null,He=!!E&&!!se&&se.zone===ES&&E.type!==me&&E.type!==YM,Ze=xs(R?.data,E),Ae=()=>{Ze||se&&F.duplicateComponent(se.zone,se.index)},P=()=>{se&&(F.removeComponent(se.zone,se.index),F.select(null))},oe=E?B.components[E.type]?.defaultProps?.previewHover:void 0,j=e.kind==="puck"&&!!E&&!!se&&oe!==void 0,ge=j&&E.props.previewHover===!0,ve=()=>{!E||!se||F.replaceComponent(se.zone,se.index,{...E,props:{...E.props,previewHover:!ge}})},[ze,$e]=kS(cc);return it("div",{className:`es-sidepanel es-sidepanel--right sf-panel sf-panel--right${ze||!(!Ie&&E)?"":" sf-hints-folded"}`,children:[J(zM,{icon:J(Bt,{type:Re,size:15}),name:ao,kind:Me,actions:!a&&e.kind==="puck"&&E&&E.type!==me?it(Ss,{children:[J(Bd,{label:l("Duplicate section"),title:Ze??void 0,disabled:Ze!==null,onClick:Ae,children:J(TS,{size:15})}),He&&i.hasSiteSettings&&J(Wy,{node:E,currentSlug:p,siteId:m??void 0,tokenRef:f,runAuthed:x,onNotify:n}),J(Bd,{label:l("Remove section"),danger:!0,onClick:P,children:J(GM,{size:15})}),s?J(_d,{side:"right",onHide:s,divider:!0}):null]}):!Ie&&!E&&e.kind==="puck"&&C&&v&&Pl(v)?it(Ss,{children:[J(Bd,{label:l("Duplicate page"),onClick:()=>y(v),children:J(TS,{size:15})}),s?J(_d,{side:"right",onHide:s,divider:!0}):null]}):s?J(_d,{side:"right",onHide:s}):void 0}),C&&J(Rl,{source:g,taken:new Set((w??[]).map(ee=>ee.slug)),duplicate:C,onClose:()=>y(null),onDuplicated:ee=>{y(null),k(),b({kind:"page",slug:ee.slug,siteId:m??void 0})}}),j&&it("div",{className:"sf-preview-pin",children:[it("div",{className:"sf-preview-pin-text",children:[J("span",{className:"sf-preview-pin-label",children:l("Preview hover state")}),J("span",{className:"sf-preview-pin-hint",children:l("not shown live")})]}),J(XM,{checked:ge,onChange:ve,ariaLabel:l("Preview hover state")})]}),J(Mx,{tier:Ce,children:J("div",{className:"sf-insp-body es-insp-body sf-scroll",children:Ie?Ie.render(e,Ye):E?it(Ss,{children:[E.type===me&&i.hasSiteSettings&&J(tS,{}),J(sm,{children:J(Na,{entries:J(zy,{parts:_,heading:!1,onOpen:ee=>O(hl(E.props.id,ee))}),entryCount:yd(_).length})}),Xe&&J(cs,{source:Xe,slug:Pa(E?.props),menuId:ss(E?.props)}),J(dc,{shown:ze,onChange:$e})]}):J(Ss,{children:J(Na,{})})})})]})}import{jsx as c,jsxs as S,Fragment as MS}from"react/jsx-runtime";var Le={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)"},Hd="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 A({w:e,h:o,tone:t="dark",r=2,style:a}){return c("div",{style:{width:e,height:o,borderRadius:r,background:Le[t],flex:"none",...a}})}var r2={Hero:"hero",HeroSingle:"herosingle",IntroBleed:"intro",Collections:"collections",AlloyWheelsListing:"wheelslisting",CatalogFilterBar:"catalogfilterbar",ProductGrid:"productgrid",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"},M={position:"absolute",inset:0},d={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)"},he=(e,o,t=160)=>({background:`linear-gradient(${t}deg,${e},${o})`});function jo({size:e,style:o}){let t=Math.max(2,Math.round(e*.13)),r=(a,n,s)=>({position:"absolute",inset:a,background:n,borderRadius:t,...s?{mixBlendMode:s}:null});return S("span",{style:{position:"absolute",display:"block",width:e,height:e,...o},children:[c("span",{style:r("8% 26% 30% 6%",d.mark1)}),c("span",{style:r("26% 6% 8% 30%",d.mark2,"multiply")})]})}function vs({children:e}){return c("span",{style:{fontSize:"4.64cqw",fontWeight:700,letterSpacing:"0.06em",textTransform:"uppercase",color:d.muted},children:e})}function BS({over:e,overTone:o,head:t,headSize:r=11.5,cta:a,ctaBg:n,ctaFg:s,tone:i}){return S(MS,{children:[e&&c("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.16em",fontWeight:700,color:o},children:e}),c("span",{style:{fontSize:r,lineHeight:1.15,fontWeight:700,maxWidth:"78%",color:i},children:t}),a&&c("span",{style:{alignSelf:"flex-start",fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"4px 8px",borderRadius:2,marginTop:2,background:n,color:s},children:a})]})}function Wd({name:e,price:o}){return S("div",{style:{display:"flex",flexDirection:"column",gap:2,minWidth:0},children:[c("div",{style:{flex:1,minHeight:0,borderRadius:3,position:"relative",overflow:"hidden",...he(d.paper,d.paper2,150)},children:c(jo,{size:34,style:{left:"50%",top:"50%",transform:"translate(-50%,-50%)"}})}),c("span",{style:{fontSize:"3.65cqw",fontWeight:600,color:d.text},children:e}),c("span",{style:{fontSize:"3.65cqw",color:d.muted},children:o})]})}function qo({k:e,v:o,ok:t}){return S("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",gap:6,padding:"3.5px 2px",borderBottom:`1px solid ${d.rule}`,fontSize:"3.98cqw",color:d.muted},children:[c("span",{children:e}),S("span",{style:{display:"flex",gap:6,alignItems:"center"},children:[c("b",{style:{color:d.text,fontWeight:700},children:o}),t&&c("span",{style:{color:d.rust,fontWeight:700},children:"\u2713"})]})]})}function ue({title:e,children:o}){return S("div",{style:{...M,background:d.card,padding:"9px 10px",display:"flex",flexDirection:"column",gap:6},children:[c(vs,{children:e}),o]})}function _S({size:e=14}){return c("span",{style:{width:e,height:e,borderRadius:"50%",flex:"none",display:"block",background:`linear-gradient(150deg,${d.mark1},${d.mark2})`}})}function zd({filled:e=5,size:o=6}){return S("span",{style:{fontSize:o,letterSpacing:"0.06em",color:d.rust,lineHeight:1},children:["\u2605".repeat(e),c("span",{style:{color:d.mark1},children:"\u2605".repeat(5-e)})]})}function Ha({n:e,label:o,tone:t=d.text}){return S("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:1,minWidth:0},children:[c("b",{style:{fontSize:"8.16cqw",lineHeight:1,color:t},children:e}),c("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.08em",textTransform:"uppercase",opacity:.62,color:t},children:o})]})}function Ne({children:e,w:o}){return c("span",{style:{fontSize:"3.98cqw",lineHeight:1.45,color:d.muted,width:o,display:"block"},children:e})}function Cs({label:e,w:o="100%",filled:t}){return S("div",{style:{width:o,display:"flex",flexDirection:"column",gap:2},children:[c("span",{style:{fontSize:"3.32cqw",letterSpacing:"0.08em",textTransform:"uppercase",color:d.muted},children:e}),c("span",{style:{height:9,borderRadius:3,border:`1px solid ${d.rule}`,background:t?d.paper:d.card}})]})}function DS({children:e}){return c("span",{style:{alignSelf:"flex-start",fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"5px 9px",borderRadius:2,background:d.text,color:d.onInk},children:e})}var a2={wheelslisting:c(ue,{title:"All wheels",children:c("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,o,t])=>S("div",{style:{display:"flex",alignItems:"center",gap:6},children:[c("span",{style:{width:20,height:15,borderRadius:3,flex:"none",position:"relative",overflow:"hidden",...he(d.paper,d.paper2,150)},children:c(jo,{size:12,style:{left:"50%",top:"50%",transform:"translate(-50%,-50%)"}})}),c("b",{style:{flex:1,fontSize:"4.31cqw",color:d.text},children:e}),c("span",{style:{fontSize:"3.65cqw",color:d.muted},children:o}),c("b",{style:{fontSize:"4.31cqw",color:d.text,width:26,textAlign:"right"},children:t})]},e))})}),catalogfilterbar:S("div",{style:{...M,background:d.card,display:"flex",flexDirection:"column",justifyContent:"center",gap:7,padding:"0 11px"},children:[S("div",{style:{display:"flex",gap:4,alignItems:"center"},children:[["20 inch","6\xD7139.7","Black"].map(e=>S("span",{style:{fontSize:"3.65cqw",fontWeight:600,padding:"4px 7px",borderRadius:99,background:d.text,color:d.onInk,display:"flex",gap:4,alignItems:"center"},children:[e,c("span",{style:{opacity:.6},children:"\u2715"})]},e)),c("span",{style:{fontSize:"3.65cqw",color:d.rust,fontWeight:700},children:"Clear"})]}),S("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[c("span",{style:{fontSize:"3.65cqw",color:d.muted},children:"128 results"}),c("span",{style:{fontSize:"3.65cqw",color:d.muted,border:`1px solid ${d.rule}`,borderRadius:3,padding:"3px 6px"},children:"Sort: Price \u25BE"})]})]}),fitmentfinder:S("div",{style:{...M,padding:"10px 12px",display:"flex",flexDirection:"column",gap:6,justifyContent:"center",...he(d.ink,d.inkSoft)},children:[c("span",{style:{fontSize:"5.31cqw",fontWeight:700,color:d.onInk},children:"Will it fit your rig?"}),S("div",{style:{display:"flex",gap:4},children:[["2021","Toyota","Hilux"].map(e=>S("span",{style:{flex:1,fontSize:"3.65cqw",color:d.text,background:d.card,borderRadius:3,padding:"5px 6px",display:"flex",justifyContent:"space-between"},children:[e," ",c("span",{style:{color:d.muted},children:"\u25BE"})]},e)),c("span",{style:{fontSize:"3.65cqw",fontWeight:700,letterSpacing:"0.08em",background:d.warm,color:d.ink,borderRadius:3,padding:"5px 7px"},children:"GO"})]})]}),compatibletyres:c(ue,{title:"Tyres that suit",children:c("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,o])=>S("div",{style:{display:"flex",flexDirection:"column",gap:2,minWidth:0},children:[c("div",{style:{flex:1,minHeight:0,borderRadius:3,position:"relative",overflow:"hidden",background:d.ink},children:c("span",{style:{position:"absolute",left:"50%",top:"50%",transform:"translate(-50%,-50%)",width:26,height:26,borderRadius:"50%",border:`5px solid ${d.mark2}`,boxSizing:"border-box"}})}),c("span",{style:{fontSize:"3.32cqw",fontWeight:600,color:d.text,overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},children:e}),c("span",{style:{fontSize:"3.32cqw",color:d.muted},children:o})]},e))})}),tyresizes:c(ue,{title:"Available sizes",children:c("div",{style:{flex:1,display:"flex",flexWrap:"wrap",gap:4,alignContent:"center"},children:["265/65R17","285/70R17","265/60R18","275/55R20"].map((e,o)=>c("span",{style:{fontSize:"3.65cqw",fontWeight:600,padding:"5px 7px",borderRadius:3,border:`1px solid ${o===0?d.rust:d.rule}`,color:o===0?d.rust:d.text,background:o===0?d.paper:d.card},children:e},e))})}),tyrefitment:S(ue,{title:"Will it fit your car?",children:[c("div",{style:{display:"flex",gap:3},children:["Make","Model","Year","Trim"].map(e=>S("span",{style:{flex:1,minWidth:0,fontSize:"3.32cqw",color:d.muted,background:d.paper,border:`1px solid ${d.rule}`,borderRadius:3,padding:"4px 5px",display:"flex",justifyContent:"space-between",gap:2,overflow:"hidden",whiteSpace:"nowrap"},children:[e," ",c("span",{style:{color:d.muted},children:"\u25BE"})]},e))}),c("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,o,t])=>S("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"baseline",gap:6,borderTop:`1px solid ${d.rule}`,paddingTop:3},children:[c("span",{style:{fontSize:"3.32cqw",fontWeight:600,color:d.text},children:e}),c("span",{style:{fontSize:"3.32cqw",fontWeight:t?700:400,letterSpacing:"0.06em",color:t?d.warm:d.muted},children:o})]},e))})]}),eutyrelabel:S("div",{style:{...M,background:d.card,padding:"9px 11px",display:"flex",gap:8,alignItems:"center"},children:[c("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:1.5},children:[["A","42%"],["B","56%"],["C","70%"],["D","84%"]].map(([e,o],t)=>S("div",{style:{display:"flex",alignItems:"center",gap:3},children:[c("span",{style:{width:o,height:6,borderRadius:"0 2px 2px 0",background:t===1?d.rust:d.mark1}}),c("span",{style:{fontSize:"3.32cqw",fontWeight:700,color:t===1?d.rust:d.muted},children:e})]},e))}),S("div",{style:{flex:"none",display:"flex",flexDirection:"column",gap:3,alignItems:"center"},children:[c("b",{style:{fontSize:"6.63cqw",lineHeight:1,color:d.text},children:"72"}),c("span",{style:{fontSize:"3.32cqw",letterSpacing:"0.08em",color:d.muted},children:"dB"})]})]}),bundleoffer:S("div",{style:{...M,background:d.paper,padding:"9px 11px",display:"flex",flexDirection:"column",gap:5,justifyContent:"center"},children:[c(vs,{children:"Buy it with"}),S("div",{style:{display:"flex",alignItems:"center",gap:5},children:[[0,1].map(e=>c("span",{style:{width:26,height:22,borderRadius:3,flex:"none",position:"relative",overflow:"hidden",background:d.card},children:c(jo,{size:17,style:{left:"50%",top:"50%",transform:"translate(-50%,-50%)"}})},e)),c("span",{style:{fontSize:"5.69cqw",fontWeight:700,color:d.muted},children:"+"}),S("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:1},children:[c("span",{style:{fontSize:"3.65cqw",color:d.muted,textDecoration:"line-through"},children:"$1,024"}),c("b",{style:{fontSize:"6.02cqw",color:d.rust,lineHeight:1},children:"$899"})]})]})]}),checkoutcta:S("div",{style:{...M,display:"flex",alignItems:"center",justifyContent:"space-between",padding:"0 13px",gap:8,...he(d.ink,d.ink2)},children:[S("div",{style:{display:"flex",flexDirection:"column",gap:2},children:[c("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.12em",color:d.warm,fontWeight:700},children:"READY TO ORDER"}),c("b",{style:{fontSize:"6.63cqw",color:d.onInk,lineHeight:1},children:"$1,956"}),c("span",{style:{fontSize:"3.65cqw",color:d.onInk,opacity:.65},children:"4 items \xB7 fitted free"})]}),c("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"6px 10px",borderRadius:2,background:d.warm,color:d.ink,flex:"none"},children:"CHECKOUT"})]}),contact:c(ue,{title:"Who do you need?",children:c("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,o])=>S("div",{style:{display:"flex",alignItems:"center",gap:5},children:[c("b",{style:{flex:1,fontSize:"4.31cqw",color:d.text},children:e}),c("span",{style:{fontSize:"3.65cqw",color:d.muted},children:o}),c("span",{style:{fontSize:"4.64cqw",color:d.rust,lineHeight:1},children:"\u203A"})]},e))})}),contactlocations:c(ue,{title:"Find us",children:c("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,o,t])=>S("div",{style:{border:`1px solid ${d.rule}`,borderRadius:4,padding:"5px 6px",display:"flex",flexDirection:"column",gap:1},children:[c("b",{style:{fontSize:"4.31cqw",color:d.text},children:e}),c("span",{style:{fontSize:"3.32cqw",color:d.muted},children:o}),c("span",{style:{fontSize:"3.32cqw",color:d.rust,fontWeight:700},children:t})]},e))})}),form:c(ue,{title:"Send us a message",children:S("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:[S("div",{style:{display:"flex",gap:5},children:[c(Cs,{label:"Name"}),c(Cs,{label:"Email"})]}),c(Cs,{label:"Message",filled:!0}),c(DS,{children:"SEND"})]})}),appointmentbooking:c(ue,{title:"Book a fitting",children:S("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:[c("div",{style:{display:"flex",gap:3},children:["Mon","Tue","Wed","Thu"].map((e,o)=>c("span",{style:{flex:1,textAlign:"center",fontSize:"3.32cqw",fontWeight:o===2?700:500,padding:"4px 0",borderRadius:3,background:o===2?d.text:d.paper,color:o===2?d.onInk:d.muted},children:e},e))}),c("div",{style:{display:"flex",gap:3},children:["8:00","10:30","13:00","15:30"].map((e,o)=>c("span",{style:{flex:1,textAlign:"center",fontSize:"3.32cqw",padding:"4px 0",borderRadius:3,border:`1px solid ${o===1?d.rust:d.rule}`,color:o===1?d.rust:d.muted,background:o===3?d.paper:d.card,textDecoration:o===3?"line-through":"none"},children:e},e))})]})}),reviewform:c(ue,{title:"Leave a review",children:S("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:5,justifyContent:"center"},children:[c(zd,{filled:4,size:14}),c(Cs,{label:"Your review",filled:!0}),c(DS,{children:"POST"})]})}),submitbuild:c(ue,{title:"Show us your build",children:S("div",{style:{flex:1,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:3,border:`1px dashed ${d.mark1}`,borderRadius:5,background:d.paper},children:[c("span",{style:{fontSize:"6.63cqw",lineHeight:1,color:d.rust,fontWeight:300},children:"+"}),c("span",{style:{fontSize:"3.65cqw",color:d.muted},children:"Drop a photo of your rig"})]})}),masthead:S("div",{style:{...M,background:d.paper,display:"flex",flexDirection:"column",justifyContent:"center",padding:"0 13px",gap:5},children:[c("span",{style:{height:1.5,background:d.text}}),c("span",{style:{fontSize:"7.65cqw",fontWeight:800,letterSpacing:"0.02em",color:d.text,lineHeight:1},children:"THE TRACK"}),S("div",{style:{display:"flex",justifyContent:"space-between",fontSize:"3.65cqw",letterSpacing:"0.1em",textTransform:"uppercase",color:d.muted},children:[c("span",{children:"Issue 14"}),c("span",{children:"Spring 2026"})]}),c("span",{style:{height:1,background:d.rule}})]}),featuredcover:S("div",{style:{...M,overflow:"hidden",...he(d.ink,d.inkSoft2)},children:[c(jo,{size:92,style:{right:-18,top:-14}}),c("div",{style:{position:"absolute",inset:0,background:`linear-gradient(0deg,${d.scrim},transparent 62%)`}}),S("div",{style:{position:"absolute",left:12,right:12,bottom:11,display:"flex",flexDirection:"column",gap:3},children:[c("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.16em",fontWeight:700,color:d.warm},children:"FEATURE"}),c("span",{style:{fontSize:"6.16cqw",lineHeight:1.15,fontWeight:700,color:d.onInk},children:"Four days on the Madigan Line"})]})]}),longread:S("div",{style:{...M,background:d.card,padding:"10px 14px",display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:[c("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.14em",fontWeight:700,color:d.rust},children:"12 MIN READ"}),c("span",{style:{fontSize:"6.02cqw",lineHeight:1.15,fontWeight:700,color:d.text},children:"What breaks first, and why"}),c(Ne,{children:"Every failure starts in the same place \u2014 not the rim, not"}),c(Ne,{w:"62%",children:"the tyre, but the bolt nobody re-torqued."})]}),series:c(ue,{title:"Recurring columns",children:c("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:5,justifyContent:"center"},children:[["Shed Notes","Monthly"],["Track Tested","Fortnightly"],["Reader Rigs","Weekly"]].map(([e,o])=>S("div",{style:{display:"flex",alignItems:"center",gap:6},children:[c("span",{style:{width:3,height:12,borderRadius:2,background:d.rust,flex:"none"}}),c("b",{style:{flex:1,fontSize:"4.64cqw",color:d.text},children:e}),c("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.08em",textTransform:"uppercase",color:d.muted},children:o})]},e))})}),events:c(ue,{title:"Latest posts",children:c("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:5,justifyContent:"center"},children:[[d.inkSoft,d.inkSoft2,"Madigan Line, four days"],[d.rust,d.warm,"Why offset beats width"]].map(([e,o,t])=>S("div",{style:{display:"flex",gap:6,alignItems:"center"},children:[c("span",{style:{width:24,height:18,borderRadius:3,flex:"none",...he(e,o,150)}}),S("div",{style:{display:"flex",flexDirection:"column",gap:1,minWidth:0},children:[c("b",{style:{fontSize:"4.31cqw",color:d.text},children:t}),c("span",{style:{fontSize:"3.65cqw",color:d.muted},children:"4 Sep \xB7 Shed Notes"})]})]},t))})}),docmasthead:S("div",{style:{...M,background:d.card,padding:"12px 14px",display:"flex",flexDirection:"column",gap:5,justifyContent:"center"},children:[c("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.16em",fontWeight:700,color:d.muted},children:"POLICY"}),c("span",{style:{fontSize:"6.49cqw",fontWeight:700,color:d.text,lineHeight:1.1},children:"Returns & refunds"}),c("span",{style:{fontSize:"3.65cqw",color:d.muted},children:"Version 3 \xB7 Updated 4 Sep 2026"}),c("span",{style:{height:2,width:26,background:d.rust,borderRadius:1}})]}),docbody:c("div",{style:{...M,background:d.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,o])=>S("div",{style:{display:"flex",gap:5},children:[c("b",{style:{fontSize:"3.98cqw",color:d.rust,flex:"none"},children:e}),c(Ne,{children:o})]},e))}),docmetacards:c(ue,{title:"At a glance",children:c("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,o])=>S("div",{style:{border:`1px solid ${d.rule}`,borderRadius:4,padding:"5px 6px",display:"flex",flexDirection:"column",gap:1},children:[c("b",{style:{fontSize:"5.31cqw",color:d.text,lineHeight:1},children:e}),c("span",{style:{fontSize:"3.32cqw",letterSpacing:"0.08em",textTransform:"uppercase",color:d.muted},children:o})]},o))})}),doctabs:S("div",{style:{...M,background:d.card,display:"flex",flexDirection:"column",justifyContent:"center",gap:0,padding:"0 11px"},children:[c("div",{style:{display:"flex",gap:0},children:["Returns","Warranty","Shipping"].map((e,o)=>c("span",{style:{fontSize:"3.98cqw",fontWeight:o===0?700:500,padding:"5px 8px",color:o===0?d.text:d.muted,background:o===0?d.paper:"transparent",borderRadius:"4px 4px 0 0",border:`1px solid ${o===0?d.rule:"transparent"}`,borderBottom:"none"},children:e},e))}),c("span",{style:{height:1,background:d.rule}}),S("div",{style:{paddingTop:6,display:"flex",flexDirection:"column",gap:2},children:[c(Ne,{children:"Unfitted wheels come back within 30 days, no questions."}),c(Ne,{w:"58%",children:"Freight on a change of mind is yours."})]})]}),paragraphs:S("div",{style:{...M,background:d.card,padding:"11px 14px",display:"flex",gap:10,alignItems:"center"},children:[c("span",{style:{flex:1,fontSize:"5.86cqw",lineHeight:1.2,fontWeight:700,color:d.text},children:"The right wheel is the boring one."}),S("div",{style:{flex:1,display:"flex",flexDirection:"column"},children:[c(Ne,{children:"Forged, correctly offset, rated for what you actually"}),c(Ne,{children:"carry. Everything else is a photograph."})]})]}),keyfeatures:c(ue,{title:"Key features",children:c("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=>S("div",{style:{display:"flex",gap:6,alignItems:"center"},children:[c("span",{style:{fontSize:"4.64cqw",color:d.rust,fontWeight:700,lineHeight:1},children:"\u2713"}),c("span",{style:{fontSize:"4.31cqw",color:d.text},children:e})]},e))})}),statsparagraph:S("div",{style:{...M,background:d.paper,padding:"10px 12px",display:"flex",gap:10,alignItems:"center"},children:[S("div",{style:{flex:"none",display:"flex",flexDirection:"column",gap:5},children:[c(Ha,{n:"27k",label:"Rigs"}),c(Ha,{n:"4.9",label:"Rating"})]}),S("div",{style:{flex:1,display:"flex",flexDirection:"column"},children:[c(Ne,{children:"Twelve years of fitting the same three questions, and the"}),c(Ne,{children:"answer has not moved: load rating, offset, then looks."})]})]}),chart:S(ue,{title:"Load vs weight",children:[c("div",{style:{flex:1,display:"flex",alignItems:"flex-end",gap:5,paddingBottom:2},children:[38,62,84,71,96].map((e,o)=>c("span",{style:{flex:1,height:`${e}%`,borderRadius:"2px 2px 0 0",background:o===4?d.rust:d.mark1}},o))}),c("span",{style:{height:1,background:d.rule,marginTop:-4}})]}),mockup:c("div",{style:{...M,overflow:"hidden",display:"flex",alignItems:"center",justifyContent:"center",...he(d.inkSoft,d.ink)},children:S("div",{style:{width:"72%",height:"74%",borderRadius:4,overflow:"hidden",background:d.card,boxShadow:`0 6px 14px ${d.scrim}`},children:[c("div",{style:{height:9,background:d.paper,display:"flex",alignItems:"center",gap:2,padding:"0 4px"},children:[0,1,2].map(e=>c("span",{style:{width:2.5,height:2.5,borderRadius:"50%",background:d.mark1}},e))}),S("div",{style:{padding:5,display:"flex",flexDirection:"column",gap:3},children:[c("span",{style:{height:4,width:"56%",borderRadius:1,background:d.mark2}}),c("span",{style:{height:14,borderRadius:2,...he(d.paper,d.paper2,150)}}),c("span",{style:{height:3,width:"38%",borderRadius:1,background:d.rust}})]})]})}),manifesto:c("div",{style:{...M,overflow:"hidden",display:"flex",alignItems:"center",padding:"0 16px",...he(d.ink,d.ink2)},children:S("span",{style:{fontSize:"6.63cqw",lineHeight:1.2,fontWeight:700,color:d.onInk},children:["We build for the ",c("span",{style:{color:d.warm},children:"last"})," ten percent of the track."]})}),timeline:c(ue,{title:"Our story",children:c("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,o],t)=>S("div",{style:{display:"flex",gap:7,alignItems:"flex-start",position:"relative"},children:[t<2&&c("span",{style:{position:"absolute",left:3,top:8,bottom:-8,width:1,background:d.rule}}),c("span",{style:{width:7,height:7,borderRadius:"50%",flex:"none",marginTop:1,background:d.rust,zIndex:1}}),S("div",{style:{display:"flex",flexDirection:"column",gap:0,minWidth:0},children:[c("b",{style:{fontSize:"4.64cqw",color:d.text},children:e}),c(Ne,{children:o})]})]},e))})}),timelinetrack:S("div",{style:{...M,padding:"0 12px",display:"flex",flexDirection:"column",gap:10,justifyContent:"center",...he(d.ink,d.inkSoft)},children:[c("span",{style:{fontSize:"3.98cqw",fontWeight:700,letterSpacing:"0.14em",textTransform:"uppercase",color:d.warm},children:"Milestones"}),S("div",{style:{position:"relative",display:"flex",justifyContent:"space-between",paddingTop:7},children:[c("span",{style:{position:"absolute",left:0,right:0,top:3,height:1,background:d.mark2,opacity:.55}}),["1998","2009","2016","2024"].map((e,o)=>S("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",gap:3,position:"relative"},children:[c("span",{style:{position:"absolute",top:-7,width:6,height:6,borderRadius:"50%",background:o===3?d.warm:d.mark1}}),c("span",{style:{fontSize:"4.31cqw",fontWeight:700,color:o===3?d.warm:d.onInk,opacity:o===3?1:.75},children:e})]},e))]})]}),footprint:S("div",{style:{...M,overflow:"hidden",...he(d.paper,d.paper2,150)},children:[c("span",{style:{position:"absolute",left:"8%",top:"18%",width:"62%",height:"64%",borderRadius:"48% 52% 40% 60% / 55% 45% 55% 45%",background:d.mark1,opacity:.75}}),c("span",{style:{position:"absolute",left:"52%",top:"52%",width:"34%",height:"34%",borderRadius:"58% 42% 55% 45% / 45% 58% 42% 55%",background:d.mark2,opacity:.55}}),[["26%","38%"],["44%","58%"],["62%","34%"]].map(([e,o])=>c("span",{style:{position:"absolute",left:e,top:o,width:7,height:7,borderRadius:"50% 50% 50% 0",transform:"rotate(-45deg)",background:d.rust}},e)),c("span",{style:{position:"absolute",left:11,bottom:9,fontSize:"4.64cqw",fontWeight:700,color:d.text},children:"3 fitting bays"})]}),banner:S("div",{style:{...M,display:"flex",alignItems:"center",justifyContent:"space-between",padding:"0 13px",gap:8,background:d.rust},children:[S("div",{style:{display:"flex",flexDirection:"column",gap:2},children:[c("b",{style:{fontSize:"6.02cqw",color:d.onInk},children:"End of season \xB7 20% off"}),c("span",{style:{fontSize:"3.98cqw",color:d.onInk,opacity:.8},children:"Fitted free, this month only."})]}),c("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"5px 9px",borderRadius:2,background:d.onInk,color:d.text,flex:"none"},children:"SHOP"})]}),titlewithbuttons:S("div",{style:{...M,background:d.paper,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:7,padding:"0 14px",textAlign:"center"},children:[c("span",{style:{fontSize:"6.49cqw",lineHeight:1.15,fontWeight:700,color:d.text},children:"Not sure what fits?"}),S("div",{style:{display:"flex",gap:5},children:[c("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"5px 9px",borderRadius:2,background:d.text,color:d.onInk},children:"FIND MY FIT"}),c("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"5px 9px",borderRadius:2,border:`1px solid ${d.text}`,color:d.text},children:"CALL US"})]})]}),ticker:c("div",{style:{...M,overflow:"hidden",background:d.ink,display:"flex",alignItems:"center"},children:c("span",{style:{whiteSpace:"nowrap",fontSize:"6.29cqw",fontWeight:800,letterSpacing:"0.06em",color:d.warm,marginLeft:-14},children:"FREE FITTING \xB7 48HR DISPATCH \xB7 FREE FITTING \xB7 48HR DISPATCH"})}),countdown:S("div",{style:{...M,padding:"10px 12px",display:"flex",flexDirection:"column",alignItems:"center",gap:6,justifyContent:"center",...he(d.ink,d.ink2)},children:[c("span",{style:{fontSize:"3.65cqw",fontWeight:700,letterSpacing:"0.16em",textTransform:"uppercase",color:d.muted},children:"Back online in"}),c("div",{style:{display:"flex",alignItems:"flex-start",gap:5},children:[["23","Hours"],["59","Minutes"],["48","Seconds"]].map(([e,o],t)=>S("div",{style:{display:"flex",alignItems:"flex-start",gap:5},children:[t>0&&c("b",{style:{fontSize:"9.5cqw",lineHeight:1,color:d.warm},children:":"}),S("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",gap:2},children:[c("b",{style:{fontSize:"11.5cqw",lineHeight:1,color:d.onInk,fontVariantNumeric:"tabular-nums"},children:e}),c("span",{style:{fontSize:"3.2cqw",letterSpacing:"0.1em",textTransform:"uppercase",opacity:.62,color:d.onInk},children:o})]})]},o))})]}),breadcrumb:c("div",{style:{...M,background:d.card,display:"flex",alignItems:"center",padding:"0 13px"},children:S("span",{style:{fontSize:"4.64cqw",color:d.muted},children:["Home ",c("span",{style:{opacity:.5},children:"/"})," Wheels ",c("span",{style:{opacity:.5},children:"/"})," ",c("span",{style:{color:d.text,fontWeight:700},children:"20 inch"})]})}),categorybar:S("div",{style:{...M,background:d.card,display:"flex",flexDirection:"column",justifyContent:"center",gap:7,padding:"0 11px"},children:[c("div",{style:{display:"flex",gap:5},children:["All","Wheels","Tyres","Lift"].map((e,o)=>c("span",{style:{fontSize:"3.98cqw",fontWeight:o===0?700:500,padding:"4px 7px",borderRadius:99,background:o===0?d.text:d.paper,color:o===0?d.onInk:d.muted},children:e},e))}),c("span",{style:{height:1,background:d.rule}})]}),intro:S("div",{style:{...M,overflow:"hidden",background:d.card},children:[c("div",{style:{position:"absolute",inset:0,...he(d.ink,d.inkSoft2)}}),c(jo,{size:64,style:{right:8,top:6}}),S("div",{style:{position:"absolute",left:16,right:16,bottom:8,top:"46%",background:d.paper,borderRadius:6,padding:"8px 11px",display:"flex",flexDirection:"column",gap:2,boxShadow:`0 -4px 10px ${d.scrim}`},children:[c("span",{style:{fontSize:"5.69cqw",fontWeight:700,color:d.text},children:"Since 1998"}),c(Ne,{children:"One shed, one lathe, one idea."}),c(Ne,{w:"66%",children:"It turned out to be right."})]})]}),gallerygrid:c(ue,{title:"From our customers",children:c("div",{style:{flex:1,display:"grid",gridTemplateColumns:"repeat(3,1fr)",gridTemplateRows:"repeat(2,1fr)",gap:4,minHeight:0},children:[[d.rust,d.warm],[d.inkSoft,d.ink],[d.paper2,d.mark2],[d.ink,d.inkSoft2],[d.warm,d.paper2],[d.mark2,d.inkSoft]].map(([e,o],t)=>c("div",{style:{borderRadius:3,...he(e,o,140+t*22)}},t))})}),gallery:S(ue,{title:"Gallery",children:[c("div",{style:{display:"flex",gap:8,alignItems:"center",marginTop:-2},children:["On the truck","Studio","Close-ups"].map((e,o)=>c("span",{style:{fontSize:"3.98cqw",fontWeight:o===0?700:500,color:o===0?d.text:d.muted,borderBottom:`1.5px solid ${o===0?d.rust:"transparent"}`,paddingBottom:2},children:e},e))}),c("div",{style:{flex:1,display:"grid",gridTemplateColumns:"repeat(3,1fr)",gap:4,minHeight:0},children:[[d.rust,d.warm],[d.ink,d.inkSoft],[d.paper2,d.mark2]].map(([e,o],t)=>c("div",{style:{borderRadius:3,...he(e,o,150+t*20)}},t))})]}),ordersummary:S(ue,{title:"Order summary",children:[S("div",{style:{display:"flex",gap:6,alignItems:"center",paddingBottom:4},children:[c("span",{style:{width:26,height:26,borderRadius:4,position:"relative",overflow:"hidden",flex:"none",...he(d.paper,d.paper2,150)},children:c(jo,{size:18,style:{left:"50%",top:"50%",transform:"translate(-50%,-50%)"}})}),S("div",{style:{display:"flex",flexDirection:"column",gap:1,minWidth:0},children:[c("b",{style:{fontSize:"4.31cqw",color:d.text},children:"Ridge Grappler"}),c("span",{style:{fontSize:"3.65cqw",color:d.muted},children:"20\xD79 +12 \xB7 qty 4"})]})]}),S("div",{style:{flex:1,minHeight:0,display:"flex",flexDirection:"column",justifyContent:"center"},children:[c(qo,{k:"Subtotal",v:"$1,956"}),c(qo,{k:"Fitting",v:"Free"}),S("div",{style:{display:"flex",justifyContent:"space-between",paddingTop:5,fontSize:"4.64cqw"},children:[c("b",{style:{color:d.text},children:"Total"}),c("b",{style:{color:d.text,fontSize:"6.02cqw"},children:"$1,956"})]})]})]}),deliveryoptions:c(ue,{title:"Delivery",children:c("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,o,t,r])=>S("div",{style:{display:"flex",alignItems:"center",gap:6,padding:"5px 6px",borderRadius:4,border:`1px solid ${r?d.rust:d.rule}`,background:r?d.paper:d.card},children:[c("span",{style:{width:7,height:7,borderRadius:"50%",flex:"none",border:`1.5px solid ${r?d.rust:d.mark1}`,background:r?d.rust:"transparent"}}),c("span",{style:{flex:1,fontSize:"4.31cqw",fontWeight:600,color:d.text},children:e}),c("span",{style:{fontSize:"3.98cqw",color:d.muted},children:o}),c("b",{style:{fontSize:"4.31cqw",color:d.text},children:t})]},e))})}),paymentbadges:S("div",{style:{...M,background:d.paper,display:"flex",flexDirection:"column",gap:8,justifyContent:"center",padding:"0 12px"},children:[c(vs,{children:"Ways to pay"}),c("div",{style:{display:"flex",gap:5},children:[["VISA",d.ink],["MC",d.rust],["AMEX",d.inkSoft],["PayPal",d.ink2]].map(([e,o])=>c("span",{style:{flex:1,textAlign:"center",fontSize:"3.65cqw",fontWeight:800,letterSpacing:"0.06em",color:d.onInk,borderRadius:3,padding:"6px 0",background:o},children:e},e))})]}),stats:S("div",{style:{...M,padding:"10px 12px",display:"flex",flexDirection:"column",gap:9,justifyContent:"center",...he(d.ink,d.ink2)},children:[c("span",{style:{fontSize:"3.98cqw",fontWeight:700,letterSpacing:"0.14em",textTransform:"uppercase",color:d.warm},children:"By the numbers"}),S("div",{style:{display:"flex",gap:8},children:[c(Ha,{n:"27k",label:"Rigs fitted",tone:d.onInk}),c(Ha,{n:"12",label:"Years",tone:d.onInk}),c(Ha,{n:"4.9",label:"Avg rating",tone:d.warm})]})]}),testimonials:S("div",{style:{...M,overflow:"hidden",background:d.paper,padding:"10px 11px",display:"flex",flexDirection:"column",gap:6,justifyContent:"center"},children:[c("span",{style:{position:"absolute",right:10,top:2,fontSize:"22.4cqw",lineHeight:1,fontWeight:800,color:d.rust,opacity:.16},children:"\u201D"}),c(zd,{filled:5,size:7}),c("span",{style:{position:"relative",fontSize:"5.31cqw",lineHeight:1.35,color:d.text,fontWeight:600},children:"\u201CTook them out to the Simpson and back. Not one chip.\u201D"}),S("div",{style:{display:"flex",alignItems:"center",gap:5},children:[c(_S,{}),c("span",{style:{fontSize:"3.98cqw",color:d.muted},children:"Dave M. \xB7 Hilux N80"})]})]}),reviews:S(ue,{title:"Reviews",children:[c("div",{style:{display:"flex",gap:4,height:22},children:[[d.inkSoft,d.inkSoft2],[d.rust,d.warm],[d.ink,d.inkSoft],[d.mark2,d.mark1]].map(([e,o],t)=>c("div",{style:{flex:1,borderRadius:3,...he(e,o,140+t*15)}},t))}),c("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,o,t])=>S("div",{style:{display:"flex",gap:5,alignItems:"flex-start"},children:[c(_S,{size:12}),S("div",{style:{display:"flex",flexDirection:"column",gap:1,minWidth:0},children:[S("div",{style:{display:"flex",gap:4,alignItems:"center"},children:[c("b",{style:{fontSize:"3.98cqw",color:d.text},children:e}),c(zd,{filled:o})]}),c(Ne,{children:t})]})]},e))})]}),logos:S("div",{style:{...M,display:"flex",flexDirection:"column",gap:9,justifyContent:"center",padding:"0 12px",...he(d.ink,d.inkSoft)},children:[c("span",{style:{fontSize:"3.98cqw",fontWeight:700,letterSpacing:"0.14em",textTransform:"uppercase",color:d.warm},children:"As fitted by"}),c("div",{style:{display:"grid",gridTemplateColumns:"repeat(4,1fr)",gap:8},children:["ARB","TJM","IRONMAN","OPPOSITE"].map(e=>c("span",{style:{textAlign:"center",fontSize:"4.31cqw",fontWeight:800,letterSpacing:"0.08em",color:d.onInk,opacity:.82},children:e},e))})]}),prose:S("div",{style:{...M,background:d.paper,padding:"11px 14px",display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:[c("span",{style:{fontSize:"5.86cqw",fontWeight:700,color:d.text},children:"Why offset matters"}),S("div",{style:{display:"flex",gap:6},children:[c("span",{style:{fontSize:"15.3cqw",lineHeight:.78,fontWeight:800,color:d.rust,marginTop:1},children:"T"}),S("div",{style:{display:"flex",flexDirection:"column"},children:[c(Ne,{children:"he number on the back of your wheel decides whether the"}),c(Ne,{w:"76%",children:"tyre sits under the guard or an inch outside it."})]})]})]}),cards:c(ue,{title:"What you get",children:c("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,o])=>S("div",{style:{border:`1px solid ${d.rule}`,borderRadius:4,padding:6,display:"flex",flexDirection:"column",gap:2},children:[c("span",{style:{width:11,height:11,borderRadius:3,background:d.rust,opacity:.9}}),c("b",{style:{fontSize:"3.98cqw",color:d.text},children:e}),c(Ne,{children:o})]},e))})}),faq:c(ue,{title:"Questions",children:c("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,o])=>S("div",{style:{borderBottom:`1px solid ${d.rule}`,padding:"4px 2px"},children:[S("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",gap:6},children:[c("b",{style:{fontSize:"4.31cqw",color:d.text},children:e}),c("span",{style:{fontSize:"4.64cqw",color:d.muted,lineHeight:1},children:o?"\u2212":"+"})]}),o&&c(Ne,{w:"90%",children:"Use the fitment finder \u2014 it reads your build, not just the model."})]},e))})}),hero:S("div",{style:{...M,overflow:"hidden",...he(d.ink,d.ink2)},children:[c("div",{style:{...M,background:`linear-gradient(90deg,${d.scrim},transparent 70%)`}}),c("div",{style:{position:"relative",height:"100%",display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"flex-start",padding:"12px 14px",gap:5},children:c(BS,{over:"NEW \xB7 SUMMER",overTone:d.warm,head:"Built for the worst road you own",cta:"SHOP ALL",ctaBg:d.warm,ctaFg:d.ink,tone:d.onInk})}),c(jo,{size:104,style:{right:-24,bottom:-30}})]}),herosingle:S("div",{style:{...M,display:"flex",background:d.paper,overflow:"hidden"},children:[c("div",{style:{flex:1,padding:12,display:"flex",flexDirection:"column",gap:5,justifyContent:"center"},children:c(BS,{over:"ALL-TERRAIN",overTone:d.rust,head:"Grip that does not ask",headSize:12,cta:"EXPLORE",ctaBg:d.text,ctaFg:d.onInk,tone:d.text})}),c("div",{style:{flex:1,position:"relative",...he(d.inkSoft,d.inkSoft2)},children:c(jo,{size:74,style:{right:-14,top:16}})})]}),productgrid:c(ue,{title:"Best sellers",children:S("div",{style:{flex:1,display:"grid",gridTemplateColumns:"repeat(3,1fr)",gap:5,minHeight:0},children:[c(Wd,{name:"Ridge 19",price:"$365"}),c(Wd,{name:"Ridge 29",price:"$410"}),c(Wd,{name:"Ridge 39",price:"$455"})]})}),collections:c(ue,{title:"Shop by category",children:c("div",{style:{flex:1,display:"grid",gridTemplateColumns:"repeat(3,1fr)",gap:5,minHeight:0},children:[["Wheels",d.inkSoft,d.inkSoft2],["Tyres",d.rust,d.warm],["Lift kits",d.ink,d.inkSoft]].map(([e,o,t])=>c("div",{style:{borderRadius:4,display:"flex",alignItems:"flex-end",padding:5,color:d.onInk,...he(o,t)},children:c("span",{style:{fontSize:"3.98cqw",fontWeight:700,letterSpacing:"0.04em"},children:e})},e))})}),producthero:S("div",{style:{...M,display:"flex",background:d.card,overflow:"hidden"},children:[c("div",{style:{flex:1.1,position:"relative",...he(d.paper,d.paper2,150)},children:c(jo,{size:78,style:{left:"50%",top:"50%",transform:"translate(-50%,-50%)"}})}),S("div",{style:{flex:1,padding:"10px 10px 10px 8px",display:"flex",flexDirection:"column",gap:4,justifyContent:"center"},children:[c("span",{style:{fontSize:"3.65cqw",letterSpacing:"0.16em",fontWeight:700,color:d.rust},children:"NITTO"}),c("b",{style:{fontSize:"6.29cqw",color:d.text},children:"Ridge Grappler"}),c("span",{style:{fontSize:"6.63cqw",fontWeight:700,color:d.text},children:"$489"}),c("span",{style:{alignSelf:"flex-start",fontSize:"3.65cqw",letterSpacing:"0.12em",fontWeight:700,padding:"4px 8px",borderRadius:2,background:d.text,color:d.onInk},children:"ADD TO CART"})]})]}),spectable:c(ue,{title:"Specifications",children:S("div",{style:{flex:1,display:"flex",flexDirection:"column",justifyContent:"center"},children:[c(qo,{k:"Diameter",v:'20"'}),c(qo,{k:"Width",v:"9.0J"}),c(qo,{k:"Offset",v:"+12"}),c(qo,{k:"Load",v:"1250 kg"})]})}),fitmenttable:c(ue,{title:"Will it fit?",children:S("div",{style:{flex:1,display:"flex",flexDirection:"column",justifyContent:"center"},children:[c(qo,{k:"Hilux N80",v:"20\xD79 +12",ok:!0}),c(qo,{k:"Ranger PX3",v:"20\xD79 +12",ok:!0}),c(qo,{k:"LC79",v:"17\xD78 \u221210",ok:!0})]})}),processsteps:S("div",{style:{...M,background:d.paper,padding:10,display:"flex",flexDirection:"column",gap:7,justifyContent:"center"},children:[c(vs,{children:"How it works"}),c("div",{style:{display:"flex",gap:6},children:["Pick your rig","Match the fit","We fit it"].map((e,o)=>S("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:2},children:[c("span",{style:{width:11,height:11,borderRadius:"50%",background:d.text,color:d.onInk,fontSize:"3.98cqw",display:"flex",alignItems:"center",justifyContent:"center",fontWeight:700},children:o+1}),c("span",{style:{fontSize:"3.98cqw",color:d.text,fontWeight:600},children:e})]},e))})]}),detailrows:c("div",{style:{...M,background:d.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,o,t])=>{let r=c("div",{style:{flex:1,...he(t?d.rust:d.inkSoft,t?d.warm:d.inkSoft2)}},"art"),a=S("div",{style:{flex:1.1,padding:8,display:"flex",flexDirection:"column",gap:2,justifyContent:"center"},children:[c("b",{style:{fontSize:"4.64cqw",color:d.text},children:e}),c("span",{style:{fontSize:"3.98cqw",color:d.muted,lineHeight:1.3},children:o})]},"tx");return c("div",{style:{flex:1,display:"flex",minHeight:0},children:t?[a,r]:[r,a]},e)})}),specstrip:c("div",{style:{...M,background:d.ink,color:d.onInk,display:"flex",alignItems:"center",justifyContent:"space-around",padding:"0 8px"},children:[["5 yr","Warranty"],["Free","Fitting"],["48 hr","Dispatch"]].map(([e,o])=>S("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",gap:1},children:[c("b",{style:{fontSize:"5.69cqw",letterSpacing:"0.02em"},children:e}),c("span",{style:{fontSize:"3.65cqw",color:d.mark2,letterSpacing:"0.1em",textTransform:"uppercase"},children:o})]},o))})},NS={subscribe:S("div",{style:{...M,padding:13,display:"flex",flexDirection:"column"},children:[S("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",marginBottom:8},children:[S("div",{style:{display:"flex",alignItems:"center",gap:6},children:[c(A,{w:8,h:8,r:2,tone:"accent"}),c(A,{w:38,h:7,r:3,tone:"dark"}),c(A,{w:16,h:7,r:3,tone:"accent"})]}),c(A,{w:38,h:4,r:2,tone:"soft"})]}),c("div",{style:{height:1,background:Le.line,marginBottom:10}}),S("div",{style:{flex:1,display:"flex",gap:10,border:`1px solid ${Le.line}`,borderRadius:7,padding:10},children:[S("div",{style:{flex:1.1,display:"flex",flexDirection:"column",justifyContent:"center",gap:5},children:[c(A,{w:"46%",h:3,r:2,tone:"accent"}),c(A,{w:"84%",h:8,r:4,tone:"dark"}),c(A,{w:"56%",h:8,r:4,tone:"accent"}),c(A,{w:"96%",h:3,r:2,tone:"soft",style:{marginTop:2}}),S("div",{style:{display:"flex",gap:5,marginTop:4},children:[c("div",{style:{flex:1,height:13,borderRadius:5,border:`1px solid ${Le.line}`,background:Le.block}}),c(A,{w:34,h:13,r:5,tone:"accent"})]})]}),S("div",{style:{flex:1,background:Le.block,borderRadius:6,padding:8,display:"flex",flexDirection:"column",gap:6},children:[c(A,{w:"52%",h:4,r:2,tone:"accent"}),Array.from({length:3}).map((e,o)=>S("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",gap:6,borderTop:o?`1px solid ${Le.line}`:"none",paddingTop:o?4:0},children:[c(A,{w:34,h:4,r:2,tone:"dark"}),c(A,{w:16,h:3,r:2,tone:"soft"})]},o))]})]})]}),split:S("div",{style:{...M,display:"flex"},children:[c("div",{style:{width:"44%",background:Hd}}),S("div",{style:{flex:1,padding:15,display:"flex",flexDirection:"column",justifyContent:"center",gap:7},children:[c(A,{w:"44%",h:5,r:3,tone:"accent"}),c(A,{w:"88%",h:8,r:4,tone:"dark"}),c(A,{w:"70%",h:8,r:4,tone:"dark"}),c(A,{w:"94%",h:5,r:2,tone:"soft",style:{marginTop:2}}),c(A,{w:"80%",h:5,r:2,tone:"soft"}),c(A,{w:"40%",h:13,r:6,tone:"accent",style:{marginTop:5}})]})]}),sectionheader:S(MS,{children:[c(A,{w:"18%",h:6,r:3,tone:"accent",style:{position:"absolute",top:15,right:16}}),S("div",{style:{...M,padding:16,display:"flex",flexDirection:"column",justifyContent:"center",gap:10},children:[S("div",{style:{display:"flex",alignItems:"center",gap:9},children:[c(A,{w:16,h:16,r:4,tone:"accent"}),c(A,{w:"20%",h:9,r:4,tone:"dark"})]}),c(A,{w:"62%",h:10,r:5,tone:"dark"}),c(A,{w:"42%",h:6,r:3,tone:"soft"})]})]}),header:c("div",{style:{...M,padding:14,display:"flex",flexDirection:"column",justifyContent:"center"},children:S("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between"},children:[c(A,{w:"22%",h:12,r:4,tone:"dark"}),S("div",{style:{display:"flex",gap:9,alignItems:"center"},children:[c(A,{w:26,h:6,r:3,tone:"soft"}),c(A,{w:26,h:6,r:3,tone:"soft"}),c(A,{w:26,h:6,r:3,tone:"soft"}),c(A,{w:18,h:14,r:5,tone:"accent"})]})]})}),footer:S("div",{style:{...M,padding:15,display:"flex",flexDirection:"column",justifyContent:"center",gap:12},children:[S("div",{style:{display:"flex",gap:14},children:[S("div",{style:{flex:1.4,display:"flex",flexDirection:"column",gap:6},children:[c(A,{w:"60%",h:9,r:4,tone:"dark"}),c(A,{w:"90%",h:5,r:2,tone:"soft"}),c(A,{w:"70%",h:5,r:2,tone:"soft"})]}),[0,1].map(e=>S("div",{style:{flex:1,display:"flex",flexDirection:"column",gap:6},children:[c(A,{w:"50%",h:6,r:3,tone:"dark"}),c(A,{w:"80%",h:5,r:2,tone:"soft"}),c(A,{w:"66%",h:5,r:2,tone:"soft"})]},e))]}),c("div",{style:{height:1,background:Le.line}}),S("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[c(A,{w:"30%",h:5,r:2,tone:"soft"}),c(A,{w:"16%",h:5,r:2,tone:"soft"})]})]}),grid:c("div",{style:{...M,padding:14,display:"grid",gridTemplateColumns:"1fr 1fr",gridTemplateRows:"1fr 1fr",gap:9},children:Array.from({length:4}).map((e,o)=>c("div",{style:{borderRadius:6,background:Le.block}},o))}),blanksection:c("div",{style:{...M,padding:14,display:"flex"},children:S("div",{style:{flex:1,border:`1px dashed ${Le.line}`,borderRadius:7,display:"flex",alignItems:"center",justifyContent:"center",position:"relative"},children:[c(A,{w:14,h:2,r:1,tone:"tint"}),c(A,{w:2,h:14,r:1,tone:"tint",style:{position:"absolute"}})]})}),spacer:S("div",{style:{...M,padding:14,display:"flex",flexDirection:"column",justifyContent:"space-between"},children:[c(A,{w:"100%",h:6,r:3,tone:"soft"}),c(A,{w:16,h:22,r:3,tone:"block",style:{alignSelf:"center"}}),c(A,{w:"100%",h:6,r:3,tone:"soft"})]}),divider:c("div",{style:{...M,padding:14,display:"flex",alignItems:"center"},children:c(A,{w:"100%",h:3,r:2,tone:"dark"})}),customhtml:S("div",{style:{...M,display:"flex",alignItems:"center",justifyContent:"center",gap:8,background:Hd},children:[c(A,{w:5,h:16,r:2,tone:"dark",style:{transform:"skewX(-14deg)"}}),c(A,{w:16,h:10,r:3,tone:"accent"}),c(A,{w:5,h:16,r:2,tone:"dark",style:{transform:"skewX(14deg)"}})]}),heading:c("div",{style:{...M,padding:14,display:"flex",alignItems:"center"},children:c(A,{w:"64%",h:13,r:4,tone:"dark"})}),text:S("div",{style:{...M,padding:16,display:"flex",flexDirection:"column",justifyContent:"center",gap:7},children:[c(A,{w:"100%",h:6,r:3,tone:"soft"}),c(A,{w:"96%",h:6,r:3,tone:"soft"}),c(A,{w:"100%",h:6,r:3,tone:"soft"}),c(A,{w:"58%",h:6,r:3,tone:"soft"})]}),image:c("div",{style:{position:"absolute",inset:14,borderRadius:7,background:Hd}}),button:c("div",{style:{...M,display:"flex",alignItems:"center",justifyContent:"center"},children:c(A,{w:"34%",h:16,r:8,tone:"accent"})}),menu:S("div",{style:{...M,padding:"14px 22%",display:"flex",flexDirection:"column",justifyContent:"center",gap:7},children:[c(A,{w:"48%",h:7,r:3,tone:"dark"}),c(A,{w:"82%",h:5,r:2,tone:"soft"}),c(A,{w:"66%",h:5,r:2,tone:"soft"}),c(A,{w:"74%",h:5,r:2,tone:"soft"}),c(A,{w:"58%",h:5,r:2,tone:"soft"})]}),emailform:S("div",{style:{...M,padding:16,display:"flex",flexDirection:"column",justifyContent:"center",gap:9},children:[c(A,{w:"56%",h:8,r:3,tone:"dark"}),S("div",{style:{display:"flex",gap:6},children:[c("div",{style:{flex:1,height:16,borderRadius:5,border:`1px solid ${Le.line}`}}),c(A,{w:"30%",h:16,r:5,tone:"accent"})]})]}),sociallogos:c("div",{style:{...M,display:"flex",alignItems:"center",justifyContent:"center",gap:9},children:[0,1,2,3].map(e=>c(A,{w:16,h:16,r:8,tone:"dark"},e))}),search:c("div",{style:{...M,padding:"0 18%",display:"flex",alignItems:"center"},children:S("div",{style:{flex:1,height:22,borderRadius:11,border:`1px solid ${Le.line}`,display:"flex",alignItems:"center",gap:7,padding:"0 9px"},children:[c("div",{style:{width:9,height:9,borderRadius:5,border:`2px solid ${Le.dark}`}}),c(A,{w:"46%",h:5,r:2,tone:"soft"})]})}),cart:S("div",{style:{...M,display:"flex",alignItems:"center",justifyContent:"center",gap:7},children:[c("div",{style:{width:22,height:18,borderRadius:"3px 3px 6px 6px",border:`2px solid ${Le.dark}`}}),c("div",{style:{padding:"2px 6px",borderRadius:6,border:`1.5px solid ${Le.dark}`},children:c(A,{w:7,h:7,r:2,tone:"dark"})})]}),countryswitch:S("div",{style:{...M,padding:14,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:5},children:[S("div",{style:{display:"flex",alignItems:"center",gap:6,padding:"4px 8px",border:`1px solid ${Le.line}`},children:[c(A,{w:22,h:6,r:2,tone:"dark"}),c(A,{w:6,h:4,r:1,tone:"soft"})]}),S("div",{style:{width:"46%",display:"flex",flexDirection:"column",gap:4,padding:6,border:`1px solid ${Le.line}`},children:[c(A,{w:"80%",h:4,r:2,tone:"accent"}),c(A,{w:"64%",h:4,r:2,tone:"soft"}),c(A,{w:"72%",h:4,r:2,tone:"soft"})]})]}),legalline:S("div",{style:{...M,padding:16,display:"flex",flexDirection:"column",justifyContent:"center",gap:9},children:[c("div",{style:{height:1,background:Le.line}}),S("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[c(A,{w:"38%",h:5,r:2,tone:"soft"}),S("div",{style:{display:"flex",gap:5},children:[c(A,{w:14,h:5,r:2,tone:"soft"}),c(A,{w:14,h:5,r:2,tone:"soft"}),c(A,{w:14,h:5,r:2,tone:"soft"})]})]})]}),fallback:c("div",{style:{position:"absolute",inset:14,borderRadius:8,background:Le.block}})};function HS({type:e}){let o=r2[e]??"",t=a2[o]??NS[o]??NS.fallback;return c("div",{className:"sf-thumb","aria-hidden":"true",style:{position:"absolute",inset:0,background:"var(--sf-thumb-thumb-bg)",pointerEvents:"none",containerType:"inline-size"},children:t})}import{useScreenDocument as gu}from"efficient-easel/screen/components/ScreenDocumentContext";import{jsx as Pr,jsxs as n2}from"react/jsx-runtime";import l2 from"efficient-easel/screen/components/SidePanelHead";import{StylesIcon as s2}from"efficient-easel/rail";import{Tooltip as i2}from"efficient-shell/ui";function WS({tokenRef:e,siteId:o,onClose:t,onNotify:r,tab:a,onTabChange:n}){let s=pr();return n2("div",{className:"sf-styles",children:[Pr(l2,{icon:Pr(s2,{}),title:l("Site styles"),context:Pr(i2,{content:l("{name} \u2014 renamed in the Console: {place}.",{name:s,place:l("Storefront \u25B8 Sites \u25B8 Settings")}),className:"sf-name-tip",children:Pr("span",{className:"sf-name-text",children:s})}),onHide:t}),Pr("div",{className:"sf-insp-body es-insp-body sf-scroll",children:Pr(kl,{tokenRef:e,siteId:o,onNotify:r,tab:a,onTabChange:n})})]})}import{jsx as Oe,jsxs as Nt,Fragment as m2}from"react/jsx-runtime";import{Fragment as oC,useEffect as tC,useRef as Kd}from"react";import{useTreeDrag as rC}from"efficient-easel/drag";import{GlobeIcon as x2,ImageIcon as I2,LocationIcon as h2,MapIcon as g2,TextLinesIcon as b2,TrashIcon as aC}from"efficient-easel/icons";import{Subtree as nC,TreeRow as za,TreeRowAction as lC,TreeSeam as sC}from"efficient-easel/tree";import{useEaselStrings as y2}from"efficient-easel/strings";import{createPreviewSelectionContext as f2}from"efficient-easel/draw/client";var{Provider:qoe,useSelection:zS}=f2("selectedLocationPartId");function GS(e,o,t){return`${e}::${o}::${t}`}function US(e){if(!e)return null;let o=e.split("::");if(o.length<3)return null;let t=o[o.length-1];if(t!=="image"&&t!=="map")return null;let r=Number(o[o.length-2]);if(!Number.isInteger(r)||r<0)return null;let a=o.slice(0,-2).join("::");return a?{nodeId:a,index:r,part:t}:null}import{useSyncExternalStore as c2}from"react";var d2={level:"groups"},qS=d2,Gd=new Set;function Io(e){qS=e;for(let o of Gd)o()}function u2(e){return Gd.add(e),()=>{Gd.delete(e)}}var $S=()=>qS;function jS(){return c2(u2,$S,$S)}function KS(e,o,t){let r=[];return e.forEach((a,n)=>{let s=o(a),i=r.find(f=>f.key===s);i||(i={key:s,name:t(a),items:[]},r.push(i)),i.items.push({item:a,index:n})}),r}function Yoe(e){if(e<=1)return"grid-cols-1";if(e===2)return"grid-cols-2";if(e===3)return"grid-cols-3";if(e===4)return"grid-cols-4";let o=t=>e%t||t;return o(4)>=o(3)?"grid-cols-4":"grid-cols-3"}var Wa=e=>String(e?.group??""),Ud=new WeakMap,p2=0;function ws(e){let o=Ud.get(e);return o||(o=`loc${++p2}`,Ud.set(e,o)),o}var VS=(e,o)=>o||e||"Ungrouped",YS={photo:"",group:"",groupName:"",name:"City name",state:"State",country:"Country",timezone:"GMT \xB7 UTC +0",address:`Address line one
|
|
17
|
+
Address line two`,phone:"+00 000 0000",hours:"Mon\u2013Fri 9:00\u201318:00",lat:0,lng:0,mapsUrl:""};function Dt(e){return KS(e,Wa,o=>String(o?.groupName??"")).map(o=>({key:o.key,name:o.name,cards:o.items.map(t=>t.item)}))}var $d=e=>e.flatMap(o=>o.cards),XS=(e,o,t)=>Math.min(Math.max(e,o),t);function ks(e,o,t){let r=0;for(let a=0;a<e.length;a++)if(Wa(e[a])===o){if(r===t)return a;r++}return-1}function qd(e,o,t){let r=Dt(e);if(o<0||o>=r.length)return e;let[a]=r.splice(o,1),n=XS(o<t?t-1:t,0,r.length);return r.splice(n,0,a),$d(r)}function jd(e,o,t,r,a){let n=Dt(e),s=n.find(m=>m.key===o),i=n.find(m=>m.key===r);if(!s||!i||t<0||t>=s.cards.length)return e;let[f]=s.cards.splice(t,1),u=o===r?f:{...f,group:i.key,groupName:i.name};u!==f&&Ud.set(u,ws(f));let p=XS(s===i&&t<a?a-1:a,0,i.cards.length);return i.cards.splice(p,0,u),$d(n)}function ZS(e,o){let t=Dt(e),r=t.find(n=>n.key===o),a={...YS,group:o,groupName:r?.name??""};return r?(r.cards.push(a),$d(t)):[...e,a]}function QS(e){let o=new Set(Dt(e).map(a=>a.key)),t=o.size+1,r=`Group ${t}`;for(;o.has(r);)r=`Group ${++t}`;return{cards:[...e,{...YS,group:r,groupName:""}],key:r}}function JS(e,o){return e.filter(t=>Wa(t)!==o)}function eC(e,o,t){let r=ks(e,o,t);return r<0?e:e.filter((a,n)=>n!==r)}function Qoe(e,o,t){let r=e.flatMap((s,i)=>Wa(s)===o?[i]:[]),a=e.slice();r.forEach((s,i)=>{a[s]=t[i]});let n=t.slice(r.length);return[...a.filter(s=>s!==void 0),...n]}function Joe(e,o,t){return o.flatMap(r=>{let a=e.filter(n=>Wa(n)===r);return a.length?a:t(r)})}var Es="ContactLocations",Ts=e=>({parentId:`locations-${e}`,slot:"groups"}),Vd=(e,o)=>({parentId:`locations-${e}`,slot:`cities:${o}`});function iC(e,o){let{readOnly:t,selected:r}=o,a=y2().tree,n=o.data?.content??[],s=e.kind===PS.kind,i=Kd(null);tC(()=>{let g=r?.type===Es?String(r.props.id):null;g&&g!==i.current&&Io({level:"groups"}),i.current=g},[r?.props.id]);let{selectedLocationPartId:f,setSelectedLocationPartId:u,setSelectHandler:p}=zS(),m=jS(),x=(g,y)=>{let L=n[g];L&&o.replace(g,{type:L.type,props:{...L.props,locations:y}})},I=g=>{let y=n[g]?.props?.locations;return Array.isArray(y)?y:[]},b=rC({keyOf:g=>`group:${g.si}:${g.index}`,readOnly:!!t,canDrop:(g,y)=>y.parentId===Ts(g.si).parentId&&y.slot==="groups",onDrop:(g,y)=>{x(g.si,qd(I(g.si),g.index,y.index)),m.level==="city"&&Io({level:"groups"})},onStep:(g,y)=>{x(g.si,qd(I(g.si),g.index,y<0?g.index-1:g.index+2)),m.level==="city"&&Io({level:"groups"})}}),C=rC({keyOf:g=>`city:${g.si}:${g.group}:${g.index}`,readOnly:!!t,canDrop:(g,y)=>y.parentId===Ts(g.si).parentId&&y.slot.startsWith("cities:"),onDrop:(g,y)=>{let L=y.slot.slice(7);x(g.si,jd(I(g.si),g.group,g.index,L,y.index)),Io({level:"group",key:L})},onStep:(g,y)=>{x(g.si,jd(I(g.si),g.group,g.index,g.group,y<0?g.index-1:g.index+2)),m.level==="city"&&Io({level:"group",key:g.group})}}),w=Kd(n);w.current=n;let k=Kd(()=>{});tC(()=>{p(g=>{let y=US(g);if(!y)return;let L=w.current.findIndex(F=>F.props?.id===y.nodeId);L<0||k.current(L,{level:y.part,index:y.index})})},[p]);let v=(g,y)=>{i.current=n[g]?.props?.id??null,o.select(g),Io(y),e.reveal();let L=n[g]?.props?.id;typeof L=="string"&&(y.level==="image"||y.level==="map")?u(GS(L,y.index,y.level)):u(null),typeof L=="string"&&o.scrollTo(L)};return k.current=v,{renderLocationTree:(g,y,{rowClick:L,isCollapsed:F,toggleCollapse:O})=>{let E=I(y),D=Dt(E),G=String(g.props.id),B=s&&r?.props.id===G,R=_=>Oe(sC,{...t?{}:b.seam({place:{...Ts(y),index:_}})},`seam:${G}:groups:${_}`),H=(_,ae)=>Oe(sC,{...t?{}:C.seam({place:{...Vd(y,_),index:ae}})},`seam:${G}:cities:${_}:${ae}`);return Nt(m2,{children:[Oe(za,{icon:Oe(b2,{size:13}),name:l("Texts"),words:a,onSelect:()=>v(y,{level:"texts"}),selected:B&&m.level==="texts",rowProps:{onClick:L(()=>v(y,{level:"texts"}))}}),D.map((_,ae)=>{let se=`${G}::grp::${_.key}`,Ie=F(se),ro=B&&m.level==="group"&&m.key===_.key,Ye=_.name||_.key?VS(_.key,_.name):l("Ungrouped"),Fe={...Vd(y,_.key),index:_.cards.length},ao=C.row({item:{si:y,group:_.key,index:-1},place:Fe,into:Fe,canDrag:!1},{onClick:L(()=>v(y,{level:"group",key:_.key}))}),Me=b.row({item:{si:y,index:ae},place:{...Ts(y),index:ae}},ao.rowProps);return Nt(oC,{children:[ae===0&&R(0),Oe(za,{icon:Oe(x2,{size:13}),name:Ye,words:a,onSelect:()=>v(y,{level:"group",key:_.key}),selected:ro,draggable:Me.draggable,dragging:Me.dragging,drop:Me.drop??ao.drop,fold:{open:!Ie,label:l("group"),onToggle:()=>O(se)},actions:Oe(lC,{kind:"delete",label:so("Delete {label} group ({n} city)","Delete {label} group ({n} cities)",_.cards.length,{label:Ye}),onClick:()=>{x(y,JS(E,_.key)),Io({level:"groups"})},children:Oe(aC,{size:15})}),rowProps:Me.rowProps,children:Oe("span",{className:"es-group-count",children:_.cards.length})}),!Ie&&Nt(nC,{children:[_.cards.map((Re,ye)=>{let Ce=ks(E,_.key,ye),Xe=B&&m.level==="city"&&m.index===Ce,He=String(Re?.name??"")||l("City"),Ze=`${G}::city::${ws(Re)}`,Ae=F(Ze),{rowProps:P,...oe}=C.row({item:{si:y,group:_.key,index:ye},place:{...Vd(y,_.key),index:ye}},{onClick:L(()=>v(y,{level:"city",index:Ce}))});return Nt(oC,{children:[ye===0&&H(_.key,0),Oe(za,{icon:Oe(h2,{size:13}),name:He,words:a,onSelect:()=>v(y,{level:"city",index:Ce}),selected:Xe,...oe,fold:{open:!Ae,label:He,onToggle:()=>O(Ze)},actions:Oe(lC,{kind:"delete",label:l("Delete {name}",{name:He}),onClick:()=>{x(y,eC(E,_.key,ye)),Io({level:"group",key:_.key})},children:Oe(aC,{size:15})}),rowProps:P}),!Ae&&Nt(nC,{children:[Oe(za,{icon:Oe(I2,{size:13}),name:l("Image"),words:a,onSelect:()=>v(y,{level:"image",index:Ce}),selected:B&&m.level==="image"&&m.index===Ce,rowProps:{onClick:L(()=>v(y,{level:"image",index:Ce}))}}),Oe(za,{icon:Oe(g2,{size:13}),name:l("Map"),words:a,onSelect:()=>v(y,{level:"map",index:Ce}),selected:B&&m.level==="map"&&m.index===Ce,rowProps:{onClick:L(()=>v(y,{level:"map",index:Ce}))}})]}),H(_.key,ye+1)]},ws(Re))}),Nt("button",{type:"button",className:"sf-add-card",onClick:()=>{let Re=ZS(E,_.key);x(y,Re);let ye=Dt(Re).find(Ce=>Ce.key===_.key);Io(ye&&ye.cards.length?{level:"city",index:ks(Re,_.key,ye.cards.length-1)}:{level:"group",key:_.key})},children:[Oe("span",{className:"sf-plus sf-plus--sm",children:"+"}),l("Add city")]})]}),R(ae+1)]},se)}),Nt("button",{type:"button",className:"sf-add-card",onClick:()=>{let{cards:_,key:ae}=QS(E);x(y,_),v(y,{level:"group",key:ae})},children:[Oe("span",{className:"sf-plus sf-plus--sm",children:"+"}),l("Add group")]})]})},sectionPressed:g=>{g?.type===Es&&Io({level:"groups"})}}}import{useEffect as S2,useRef as C2}from"react";import{createNode as Yd,newId as Xd}from"efficient-easel/data";import{useEaselApi as v2}from"efficient-easel/easel";import{useScreenDocument as w2}from"efficient-easel/screen/components/ScreenDocumentContext";import{useEaselSession as k2}from"efficient-easel/screen/lib/session-context";import{ROOT_ZONE as Lr,missingPinnedTypes as T2,pinnedDuplicateIds as Zd}from"efficient-easel/draw";function fC(e){return!e.docId||e.saveStatus==="saving"?!1:e.seededDocId!==e.docId}function cC(e,o){let t=e.some(i=>i?.type===de),r=e[e.length-1],a=!t&&r?.type===me?r:null,n=e.filter(i=>i?.type===me&&i!==a).map(i=>String(i.props?.id??"")).filter(Boolean),s=o.hasChromeDoc&&!t&&!a;return{remove:n,seedHeader:!e.some(i=>i?.type===Ve),seedFooter:s,seedSiteHeader:s&&!e.some(i=>i?.type===xe)}}async function dC(e){let o=e.blocks?.seeds?.siteHeader;if(!o)return!1;let t;try{t=await o({make:e.make,id:e.id,siteId:e.siteId,token:e.token})}catch{return!1}if(!t||t.type!==xe||!e.stillOpen())return!1;let r=e.latest();return r.some(a=>a?.type===xe)?!1:(e.write(ms(r,t)),!0)}function uC(e,o){let{adapter:t,capabilities:r,currentSlug:a,docId:n,data:s,saveStatus:i,siteId:f,tokenRef:u}=w2(),p=k2(),{hasSiteSettings:m,hasPinnedChrome:x}=r,I=!!r.editsPinnedInPlace&&a!==jt,b=a===jt,C=v2().getState,w=C2(null);S2(()=>{if(!fC({docId:n,saveStatus:i,seededDocId:w.current})||(w.current=n,!x))return;let k=C().appState.data,v=k.content,g=s?.content??[],y=(E,D)=>E.some(G=>G?.type===D);if(!m){let E=new Set(Zd(v)),D=E.size?v.filter(B=>!E.has(B.props.id)):v;if(E.size&&e.setDocument({...k,content:D}),b)return;let G=T2(D,g);if(G.includes(me)){let B=D.length,R=e.insertSection(me,B);e.replaceComponent(Lr,B,{type:me,props:{id:R,blocks:ps()}})}G.includes(Ve)&&e.insertNode(Lr,0,us());return}if(b){let E=Er(v);if(E!==v&&e.setDocument({...k,content:[...E]}),!E.find(D=>D.type===me)&&!y(g,me)&&!y(E,de)&&!y(g,de)){let D=(B,R)=>Yd(o,B,R),G={type:me,props:{blocks:ps()}};e.insertNode(Lr,E.length,Ba(G,D,Xd(de)))}return}if(I){let E=!!t?.pinnedChrome?.state().docId,D=cC(v,{hasChromeDoc:E}),G=new Set([...D.remove,...Zd(v.filter(R=>!D.remove.includes(String(R.props.id))))]),B=G.size?v.filter(R=>!G.has(String(R.props.id))):v;if(B.length!==v.length&&e.setDocument({...k,content:B}),D.seedFooter&&!y(g,me)&&!y(g,de)){let R=(_,ae)=>Yd(o,_,ae),H={type:me,props:{blocks:ps()}};e.insertNode(Lr,B.length,Ba(H,R,Xd(de)))}if(D.seedHeader&&!y(g,Ve)){let R=B[0]?.type===xe?1:0;e.insertNode(Lr,R,us())}if(D.seedSiteHeader&&!y(g,xe)&&!y(g,me)&&!y(g,de)){let R=n;dC({blocks:vn(p),make:(H,_)=>Yd(o,H,_),id:Xd(xe),siteId:f??null,token:u.current,latest:()=>C().appState.data.content,stillOpen:()=>w.current===R,write:H=>{let _=C().appState.data;e.setDocument({..._,content:[...H]})}})}return}let L=v.filter(E=>E.type!==me),F=new Set(Zd(L)),O=F.size?L.filter(E=>!F.has(E.props.id)):L;O.length!==v.length&&e.setDocument({...k,content:O}),!y(O,Ve)&&!y(g,Ve)&&e.insertNode(Lr,0,us())},[n,i,s,C,e,m,x,b,I,t,p,f,u])}import{useEffect as xC,useState as IC}from"react";var Fs=new Map;async function E2(e,o){try{return(await We().site.get({siteId:o})).slug?.trim()||null}catch(t){return console.warn("[editor-site-slug] could not resolve the site slug",t),null}}function pC(e,o){let t=Fs.get(o);return t||(t=E2(e,o),Fs.set(o,t),t.catch(()=>{Fs.get(o)===t&&Fs.delete(o)})),t}var F2=/^(localhost|(?:[a-z0-9-]+\.)+localhost|127(?:\.\d{1,3}){3}|0\.0\.0\.0|\[::1\]|::1)$/i;function Qd(e){return!!e&&F2.test(e)}function mC(e){let{pageSlug:o,siteSlug:t,hostname:r}=e,a=o===Pn?"/":`/${encodeURIComponent(o)}`;if(!Qd(r))return a;let n=t?.trim();return n?`${a}?site=${encodeURIComponent(n)}`:a}function hC(e){let{pageSlug:o,siteId:t,token:r}=e,[a,n]=IC(null),[s,i]=IC(null),f=Ku();xC(()=>i(f?new URL(f).hostname:window.location.hostname),[f]),xC(()=>{if(!Qd(s)||!t||!r){n(null);return}let p=!1;return pC(r,t).then(m=>{p||n(m)}),()=>{p=!0}},[s,t,r]);let u=mC({pageSlug:o,siteSlug:a,hostname:s});return f?`${f}${u}`:u}import{jsx as Ga,jsxs as P2}from"react/jsx-runtime";import{ExternalIcon as gC}from"efficient-easel/icons";import{Button as L2,Tooltip as bC,buttonClasses as O2}from"efficient-shell/ui";function R2({pageId:e,liveHref:o,draftLink:t,win:r=window}){let a=r.open("","_blank");if(a)try{a.opener=null}catch{}let n=s=>{a&&!a.closed?a.location.href=s:r.open(s,"_blank","noopener,noreferrer")};return t(e).then(s=>n(s.url??o),()=>n(o))}function yC({liveHref:e,pageId:o,draftLink:t}){return t&&o?Ga(bC,{content:l("Open your saved draft in a new tab. Visitors don't see it."),children:Ga(L2,{variant:"secondary",onClick:()=>{R2({pageId:o,liveHref:e,draftLink:t})},rightIcon:Ga(gC,{size:15}),"aria-label":l("Preview your saved draft in a new tab"),children:l("Preview")})}):Ga(bC,{content:l("Preview the live site (opens in a new tab)"),children:P2("a",{className:O2({variant:"secondary"}),href:e,target:"_blank",rel:"noopener noreferrer","aria-label":l("Preview the live site in a new tab"),children:[l("Preview"),Ga(gC,{size:15})]})})}import{createElement as H2,useCallback as W2,useEffect as WC,useRef as zC,useState as z2}from"react";import{ClockIcon as G2}from"efficient-shell/icons/efficient";import{useScreenDocument as U2}from"efficient-easel/screen/components/ScreenDocumentContext";import{useSyncExternalStore as A2}from"react";import{useScreenDocument as B2}from"efficient-easel/screen/components/ScreenDocumentContext";var _2=()=>()=>{},SC=()=>null;function Ps(e){return A2(e?e.subscribe:_2,e?e.state:SC,e?e.state:SC)}function Ls(){let{adapter:e}=B2();return e?.pinnedChrome}import{useSyncExternalStore as wC}from"react";var Ua=!1,Or=null,Jd=new Set;function qa(){for(let e of Jd)e()}function kC(e){return Jd.add(e),()=>{Jd.delete(e)}}function TC(){Ua||(Ua=!0,qa())}function EC(){Ua&&(Ua=!1,qa())}function CC(){return Ua}function FC(){return wC(kC,CC,CC)}function vC(){return Or}function Os(){Or&&(Or=null,qa())}function PC(){return wC(kC,vC,vC)}var $a=class extends Error{constructor(){super("The editor's last changes could not be saved, so nothing was restored."),this.name="HeldEditsNotSaved"}};async function LC(e,o,t,{flushSave:r,reload:a}){if(!await r())throw new $a;let n=await e.restore(o,t);return km(n.liveState),a(),n}async function OC({access:e,version:o,page:t,...r}){let a=await LC(e,o.id,t?{page:t.id}:{},r);Or={title:D2(o,t??null),undo:a.undo},qa()}async function RC({access:e,...o}){let t=Or?.undo;t&&(await LC(e,t,{},o),Or=null,qa())}function AC(e){return e.name?e.name:e.kind==="draft_before_restore"?l("Draft before restore"):l("Version {n}",{n:e.number})}function D2(e,o){return e.kind==="draft_before_restore"?l("Your drafts from before the restore are back"):o?l("{page} from version {n} is now your draft",{page:o.name,n:e.number}):l("Version {n} is now your draft",{n:e.number})}function BC(e){let o=e.changes.filter(r=>r.kind==="page").length,t=[...o?[so("{n} page","{n} pages",o)]:[],...e.changes.filter(r=>r.kind!=="page").map(r=>r.name)];if(!t.length)return"";try{return new Intl.ListFormat(Zs(),{type:"conjunction"}).format(t)}catch{return t.join(", ")}}function _C(e){return e.change==="take_down"?l("{name} (taken down)",{name:e.name}):e.name}function DC(e,o=new Date){let t=new Date(e);if(Number.isNaN(t.getTime()))return"";let r=Zs(),a=new Intl.DateTimeFormat(r,{hour:"numeric",minute:"2-digit"}).format(t);if(t.toDateString()===o.toDateString())return l("Today, {time}",{time:a});let n=new Intl.DateTimeFormat(r,{day:"numeric",month:"short",...t.getFullYear()===o.getFullYear()?{}:{year:"numeric"}}).format(t);return l("{day}, {time}",{day:n,time:a})}import{useSyncExternalStore as N2}from"react";var Rr=new Map,eu=new Set;function ou(e,o){if(!(Rr.has(e)&&Rr.get(e)===o)){Rr.set(e,o);for(let t of eu)t()}}function are(e,o){ou(e,o)}function nre(e,o){let t=Rr.get(e);ou(e,o??(t==="live"?"changed":t))}function lre(e,o){ou(e,o??"live")}function sre(e){return Rr.get(e)}function M2(e){return eu.add(e),()=>{eu.delete(e)}}function NC(e){let o=()=>e?Rr.get(e):void 0;return N2(M2,o,o)}function MC(e,o){return e==="live"&&o?"changed":e}function tu({live:e,onPress:o,busy:t=!1,pinnedUnpublished:r=!1,goingLive:a}){let n=e==="live"&&!r,s=e==="changed"?l("Changes not live yet"):e==="never"?l("Never published"):r?l("Header and footer not live yet"):e==="live"?l("Everything is live"):null;return{label:l("Publish"),tooltip:e==="never"?l("Put this page on your site"):l("Put your changes on your site"),status:s,quiet:n?{label:l("Published"),reason:l("Everything is live")}:null,...a&&a.length?{goingLive:a}:{},onPress:o,busy:t}}function HC(e){return e.map(o=>o.change==="take_down"?l("{name} (taken down)",{name:o.name}):o.name)}function GC(e){let{docId:o,capabilities:t,hasUnsavedEdits:r,onPublish:a,adapter:n}=U2(),s=MC(NC(o??null),r),i=Ps(Ls()),f=n.siteLiveState;WC(()=>{if(f)return zi(f),Tn(0),()=>zi(null)},[f]);let u=En(),[p,m]=z2(!1),x=zC(e);x.current=e;let I=zC(!0);WC(()=>(I.current=!0,()=>{I.current=!1}),[]);let b=W2(()=>{m(!0),a(x.current).then(()=>{Os()}).finally(()=>{I.current&&m(!1)})},[a]);if(t.canPublish){if(f){let C=u===void 0?void 0:r||u.state==="changed"?"changed":"live",w=tu({live:C,onPress:b,busy:p,goingLive:HC(u?.changes??[])});return n.siteVersions?{...w,menuItems:$2()}:w}return tu({live:s,onPress:b,busy:p,pinnedUnpublished:i?.unpublished??!1})}}function $2(){return[{key:"version-history",label:l("Version history"),icon:H2(G2),onSelect:TC}]}import{jsx as W,jsxs as to,Fragment as Va}from"react/jsx-runtime";import{useCallback as q2,useEffect as j2,useId as qC,useRef as K2,useState as fo}from"react";import{Avatar as V2,Banner as ja,Button as Mt,ColoredBadge as ru,Dialog as jC,Drawer as Y2,DropdownMenu as X2,FormField as KC,iconButtonClasses as Z2,Inline as au,Input as Q2,ListRow as J2,Select as eH,SortableList as oH,Stack as Ka}from"efficient-shell/ui";import{EditIcon as tH,EyeIcon as UC,MenuIcon as rH,MoreIcon as aH,PageIcon as VC,RevertIcon as $C,StylesIcon as nH}from"efficient-shell/icons/efficient";import{useScreenDocument as YC}from"efficient-easel/screen/components/ScreenDocumentContext";var lH={page:VC,menu:rH};function sH(e,o){return e.pages.find(t=>t.id===o)??e.pages[0]??null}function iH(e,o){let t=window.open("","_blank");if(t)try{t.opener=null}catch{}return e.preview(o).then(({url:r})=>{t&&!t.closed?t.location.href=r:window.open(r,"_blank","noopener,noreferrer")},r=>{throw t?.close(),r})}function fH({version:e,page:o,waiting:t,busy:r,error:a,onCancel:n,onConfirm:s,onPage:i}){let f=qC();if(!e)return null;let u=e.kind==="draft_before_restore",p=e.number,m=BC(e),x=u?l("Put your drafts back?"):o?l("Restore {page} from version {n}?",{page:o.name,n:p}):l("Restore version {n}?",{n:p}),I=u?l("Your drafts go back to how they were before the restore."):o?l("{page} goes back to version {n} as a draft. Nothing else on your website changes.",{page:o.name,n:p}):m?l("The whole website goes back to version {n} as a draft: {what}.",{n:p,what:m}):l("The whole website goes back to version {n} as a draft.",{n:p}),b=e.deletedPictures??0;return W(jC,{open:!0,onClose:()=>{r||n()},size:"sm",title:x,footer:to(Va,{children:[W(Mt,{variant:"secondary",onClick:n,disabled:r,children:l("Cancel")}),W(Mt,{onClick:s,loading:r,disabled:r,children:l("Restore as draft")})]}),children:to(Ka,{gap:4,children:[o&&e.pages.length>1?W(KC,{label:l("Page"),htmlFor:f,children:W(eH,{id:f,value:o.id,options:e.pages.map(C=>({value:C.id,label:C.name})),onChange:i,disabled:r})}):null,W("p",{children:I}),W("p",{children:l("Your live website does not change until you press Publish.")}),b>0?W(ja,{tone:"warning",children:so("{n} picture in this version was deleted from the media library. It stays empty.","{n} pictures in this version were deleted from the media library. They stay empty.",b)}):null,t?W(ja,{tone:"info",title:l("Your unpublished changes are kept"),children:l("They are saved in Version history as \u201CDraft before restore\u201D, so you can get them back.")}):null,a?W(ja,{tone:"danger",children:a}):null]})})}function cH({version:e,onCancel:o,onSave:t}){let r=qC(),[a,n]=fo(null),[s,i]=fo(""),[f,u]=fo(!1),[p,m]=fo(null);if(e!==a&&(n(e),i(e?.name??""),m(null)),!e)return null;let x=s.trim()===e.name,I=async()=>{if(!(f||x)){u(!0),m(null);try{await t(s.trim())}catch{m(l("The name was not saved. Try again."))}finally{u(!1)}}};return W(jC,{open:!0,onClose:()=>{f||o()},size:"sm",title:l("Name this version"),footer:to(Va,{children:[W(Mt,{variant:"secondary",onClick:o,disabled:f,children:l("Cancel")}),W(Mt,{onClick:()=>{I()},loading:f,disabled:f||x,children:l("Save")})]}),children:W(KC,{label:l("Name"),htmlFor:r,hint:l("Named versions are always kept. Leave it empty to take the name away."),error:p??void 0,children:W(Q2,{id:r,value:s,invalid:!!p,onChange:b=>i(b.target.value),onKeyDown:b=>{b.key==="Enter"&&I()}})})})}function dH({version:e,expanded:o,onToggle:t,onPreview:r,onRestore:a,onRestorePage:n,onName:s}){let i=e.kind==="draft_before_restore",f=!e.live,u=e.changes.length,p=[...i?[]:[{key:"preview",label:l("Preview"),icon:W(UC,{}),onSelect:r}],...f?[{key:"restore",label:i?l("Put these drafts back"):l("Restore whole website"),icon:W($C,{}),onSelect:a}]:[],...f&&!i&&e.pages.length?[{key:"restore-page",label:l("Restore one page only"),icon:W(VC,{}),onSelect:n}]:[],...i?[]:[{type:"divider",key:"divider"},{key:"name",label:l("Name this version"),icon:W(tH,{}),onSelect:s}]];return W(J2,{title:to("span",{className:"sf-version-title",children:[W("span",{children:AC(e)}),e.live?W(ru,{tone:"success",size:"xs",children:l("Live")}):null,e.name?W(ru,{tone:"neutral",size:"xs",children:l("Version {n}",{n:e.number})}):null,i?W(ru,{tone:"warning",size:"xs",children:l("Not published")}):null]}),expanded:o,onToggle:t,actions:W(X2,{align:"end","aria-label":l("More"),items:p,triggerClassName:Z2({variant:"ghost",size:"sm"}),trigger:W(aH,{})}),below:to(Ka,{gap:3,children:[to(au,{gap:2,align:"center",wrap:!0,className:"sf-version-meta",children:[W(V2,{name:e.createdBy,size:"xs"}),W("span",{children:e.createdBy}),W("span",{"aria-hidden":"true",children:"\xB7"}),W("span",{children:DC(e.createdAt)}),u?to(Va,{children:[W("span",{"aria-hidden":"true",children:"\xB7"}),W("span",{children:so("{n} change","{n} changes",u)})]}):null]}),o?to(Ka,{gap:3,children:[u?W(Ka,{gap:2,children:e.changes.map(m=>{let x=lH[m.kind]??nH;return to(au,{gap:2,align:"center",children:[W(x,{size:16}),W("span",{children:_C(m)})]},`${m.kind}:${m.id}`)})}):null,to(au,{gap:2,children:[i?null:W(Mt,{variant:"secondary",size:"sm",leftIcon:W(UC,{}),onClick:r,children:l("Preview")}),f?W(Mt,{variant:"secondary",size:"sm",leftIcon:W($C,{}),onClick:a,children:l("Restore")}):null]})]}):null]})})}function uH({open:e,onClose:o,access:t,waiting:r}){let{flushSave:a,reloadFromServer:n,docId:s}=YC(),[i,f]=fo(null),[u,p]=fo(!1),[m,x]=fo(null),[I,b]=fo(null),[C,w]=fo(!1),[k,v]=fo(null),[g,y]=fo(null),[L,F]=fo(!1),O=K2(0),E=q2(()=>{let B=++O.current;p(!1),t.list().then(R=>{B===O.current&&f(R)},()=>{B===O.current&&p(!0)})},[t]);j2(()=>{e&&E()},[e,E]);let D=B=>{F(!1),iH(t,B.id).catch(()=>F(!0))},G=async()=>{if(!(!I||C)){w(!0),v(null);try{await OC({access:t,version:I.version,page:I.page,flushSave:a,reload:n}),b(null),o()}catch(B){v(B instanceof $a?l("Your last changes did not save, so nothing was restored. Try again."):l("The version was not restored. Nothing changed. Try again."))}finally{w(!1)}}};return to(Va,{children:[W(Y2,{open:e,onClose:o,side:"right",size:"md",title:l("Version history"),description:to(Va,{children:[l("Every Publish keeps a copy of the whole website: pages, menus and site styles.")," ",l("Products, prices and forms always show as they are now.")]}),footer:W("span",{className:"sf-version-foot",children:l("The newest 30 are kept. Named versions are always kept.")}),children:to(Ka,{gap:3,children:[L?W(ja,{tone:"danger",onDismiss:()=>F(!1),children:l("The preview did not open. Try again.")}):null,u?W(ja,{tone:"danger",action:W(Mt,{variant:"secondary",size:"sm",onClick:E,children:l("Try again")}),children:l("Version history did not load.")}):i===null?W("p",{className:"sf-version-foot",children:l("Loading versions")}):i.length===0?W("p",{className:"sf-version-foot",children:l("No versions yet. Every Publish from now on keeps one.")}):W(oH,{"aria-label":l("Versions"),spacing:"comfortable",children:i.map(B=>W(dH,{version:B,expanded:m===B.id,onToggle:()=>x(R=>R===B.id?null:B.id),onPreview:()=>D(B),onRestore:()=>{v(null),b({version:B,page:null})},onRestorePage:()=>{v(null),b({version:B,page:sH(B,s)})},onName:()=>y(B)},B.id))})]})}),W(fH,{version:I?.version??null,page:I?.page??null,waiting:r,busy:C,error:k,onCancel:()=>b(null),onConfirm:()=>{G()},onPage:B=>b(R=>R&&{...R,page:R.version.pages.find(H=>H.id===B)??R.page})}),W(cH,{version:g,onCancel:()=>y(null),onSave:async B=>{await t.name(g.id,B),y(null),E()}})]})}function XC(){let{adapter:e,hasUnsavedEdits:o}=YC(),t=e.siteVersions,r=FC(),a=En();return t?W(uH,{open:r,onClose:EC,access:t,waiting:o||a?.state==="changed"}):null}import{useEaselSession as G5}from"efficient-easel/screen/lib/session-context";import{buildPaletteSections as Nre,categoryLabel as Mre,paletteWithoutPinned as Hre,pinnedSection as Wre}from"efficient-easel/screen/lib/puck/palette-sections";var ZC=["general","commerce","service"],Ar=[{key:"openers",title:"Hero & intros",defaultExpanded:!0,templateable:!0,sections:[{type:"Hero",label:"Hero Slideshow",set:"general"},{type:"HeroSingle",label:"Hero",set:"general"},{type:"IntroBleed",label:"Scroll-Over Text",set:"general"}]},{key:"shop",title:"Shop & galleries",templateable:!0,sections:[{type:"Collections",label:"Collections",set:"commerce"},{type:"AlloyWheelsListing",label:"List",set:"commerce"},{type:"CatalogFilterBar",label:"Catalog Filter Bar",set:"commerce"},{type:"ProductGrid",label:"Product Grid",set:"commerce"},{type:"FitmentFinder",label:"Fitment Form",set:"commerce"},{type:"Gallery",label:"Tabbed Gallery",set:"commerce"},{type:"GalleryB",label:"Customer Photo Grid",set:"commerce"},{type:"SpecStrip",label:"Spec Strip",set:"general"}]},{key:"product",title:"Product page",templateable:!0,sections:[{type:"ProductHero",label:"Product Hero",set:"commerce"},{type:"SpecTable",label:"Spec Table",set:"commerce"},{type:"ProcessSteps",label:"Image & Text Columns",set:"general"},{type:"DetailRows",label:"Feature Rows",set:"commerce"},{type:"FitmentTable",label:"Fitment Table",set:"commerce"},{type:"TyreSizes",label:"Tyre Sizes",set:"commerce"},{type:"TyreFitment",label:"Tyre Fitment Form",set:"commerce"},{type:"EuTyreLabel",label:"EU Tyre Label",set:"commerce"},{type:"RelatedProducts",label:"Related Products",set:"commerce"},{type:"BundleOffer",label:"Bundle Products",set:"commerce"}]},{key:"checkout",title:"Checkout & ordering",templateable:!0,sections:[{type:"OrderSummary",label:"Order Table",set:"general"},{type:"DeliveryOptions",label:"Delivery Options",set:"commerce"},{type:"PaymentBadges",label:"Payment Methods",set:"general"},{type:"CheckoutCTA",label:"Ready-to-Order Banner",set:"commerce"}]},{key:"about",title:"About & brand story",templateable:!0,sections:[{type:"Manifesto",label:"Brand Text",set:"general"},{type:"Timeline",label:"Story Timeline",set:"general"},{type:"Footprint",label:"Locations Map",set:"general"}]},{key:"content",title:"Text & content",templateable:!0,sections:[{type:"Prose",label:"Editorial Text",set:"general"},{type:"ParagraphsA",label:"Lead Text",set:"general"},{type:"Split",label:"Image & Text Split",set:"general"},{type:"Cards",label:"Cards",set:"general"}]},{key:"proof",title:"Stats & social proof",templateable:!0,sections:[{type:"Stats",label:"Stats",set:"general"},{type:"StatsParagraph",label:"Stats with Text",set:"general"},{type:"Chart",label:"Chart",set:"general"},{type:"Mockup",label:"Mockup Card",set:"general"},{type:"Testimonials",label:"Testimonials",set:"general"},{type:"Reviews",label:"Reviews",set:"service"},{type:"Logos",label:"Logos",set:"general"}]},{key:"promo",title:"Promotions & sign-ups",templateable:!0,sections:[{type:"Banner",label:"Banner",set:"general"},{type:"TitleWithButtons",label:"Call-to-Action Heading",set:"general"},{type:"Ticker",label:"Scrolling Bar",set:"general"},{type:"Countdown",label:"Countdown",set:"general"},{type:"Subscribe",label:"Signup Form",set:"service"}]},{key:"blog",title:"Blog & journal",templateable:!0,sections:[{type:"Masthead",label:"Issue Header",set:"general"},{type:"FeaturedCover",label:"Feature Banner",set:"general"},{type:"LongRead",label:"Article Text",set:"general"},{type:"Series",label:"Recurring Columns",set:"general"},{type:"Events",label:"Latest Posts",set:"service"}]},{key:"navigation",title:"Navigation & wayfinding",templateable:!0,sections:[{type:"Breadcrumb",label:"Breadcrumb",set:"general"},{type:"CategoryBar",label:"Category Bar",set:"general"},{type:"DocTabs",label:"Document Tabs",set:"general"}]},{key:"legal",title:"Legal & documents",templateable:!0,sections:[{type:"DocMasthead",label:"Document Header",set:"general"},{type:"DocBody",label:"Document Text",set:"general"},{type:"DocMetaCards",label:"Document Detail Cards",set:"general"}]},{key:"contact",title:"Contact, FAQ & forms",templateable:!0,sections:[{type:"FAQ",label:"Q&A",set:"general"},{type:"ContactRouting",label:"Contact Form",set:"service"},{type:"ContactLocations",label:"Contact / Locations",set:"general"},{type:"SubmitBuild",label:"Photo Submission Form",set:"service"},{type:"ReviewForm",label:"Review Form",set:"service"},{type:"Form",label:"Form",set:"service"},{type:"AppointmentBooking",label:"Booking Form",set:"service"}]},{key:"structure",title:"Layout, structure & embeds",templateable:!1,sections:[{type:"SectionHeader",label:"Section Header",set:"general"},{type:"Flex",label:"Box",set:"general"},{type:"Spacer",label:"Spacer",set:"general"},{type:"Divider",label:"Divider",set:"general"},{type:"CustomHTML",label:"Custom HTML",set:"general"}]}];function Ere(){return Object.fromEntries(Ar.map(e=>[e.key,{title:e.title,components:e.sections.map(o=>o.type),...e.defaultExpanded?{defaultExpanded:!0}:{}}]))}var pH={Grid:'Lewis, 2026-09-14: Box and Grid duplicate each other and it feels confusing. 2026-09-15 he chose the order: give Box uneven widths FIRST, then merge Grid into Box. Shown three ways to pick the widths (mockup "Uneven Box Widths"), he chose A \u2014 shape pictures on the Box\'s `Block widths` row, the same "a row is a shape, pick a picture of it" rule he set for the photo wall on 2026-09-07.\n\nWHAT REPLACES IT: a Box set to One row, with `Block widths` at Equal or a shape (Big left, Big right, Bigger left, Bigger right) and its own `Columns on phone`. Measured on PRODUCTION 2026-09-16 ~09:28 AEST (database `efficient-system`, all 10 tenant schemas, 128 storefront pages, both `layout` and `published_layout` \u2014 256 documents): 2 Grid nodes, and they are ONE Grid counted twice \u2014 the 9DIEM homepage on 9diem.com (`xtreme_mudder` schema), once as draft and once as published. It is top-level, holds three `ImageBlock`s at `columns` 3 \u2014 equal thirds \u2014 and NO block sets `Positions`. A Box draws that with `Block widths` at Equal.\n\n\u26A0\uFE0F THE COUNT MOVES; THE RULE MUST NOT DEPEND ON IT. This entry has already carried three different readings. A local-clone snapshot said no Grid used `Positions`. A PRODUCTION reading on 2026-09-15 ~13:15 AEST found 6 nodes on two sites, 4 of them spanned \u2014 hartesmetal.com.au homepage and about, 4 columns, spans 1 + 3. That one was TRUE when it was taken and stopped being true the same day: those two pages were rebuilt on Box (`Block widths: Bigger right`), and on 2026-09-16 they hold zero Grid nodes and are built from `Flex`. \u26D4 So the rule is NOT "there are still N spanned Grids". NEVER delete the Grid component or its `gridSpan` handling, whatever a census says \u2014 Grid still renders, still edits, still drags, and a merchant may rebuild a page either way on any day. Re-run the census on production before anyone PROPOSES deleting either, and read any number written here as the reading of its own day, not as the state of the world.\n\nWHAT A MERCHANT LOSES: a new Grid, and with it a fixed "N per row" that wraps by itself past three across, and the per-block `Positions` number. Box wraps with `Wrap`, but by content width, not by a fixed count.\n\nTHE TYPE KEY STAYS AND SO DOES THE COMPONENT. Every page holding a Grid still renders through it and can still be edited, dragged and added to; no document is rewritten and NO MIGRATION RUNS \u2014 the owner redoes live sections himself.\n\n\u26A0\uFE0F AND IT STAYS DROPPABLE WHERE IT LIVES. The drop rule in lib/puck/config.tsx read the nestable containers off the catalogue\'s `structure` row, so leaving the catalogue would have made every open slot \u2014 a Box included \u2014 refuse a Grid already stored inside one. `scripts/test-retired-grid-stays-editable.tsx` \xA73 pins it.',CompatibleTyres:'Lewis, 2026-09-09: "Do not bother counting. Delete Compatible Tyres and use the new one. The new one needs complete settings \u2014 it must have every setting our cards have." Shown three ways to finish it, he chose C: retire from the menu now, and take styling the card text as its own card.\n\nWHAT REPLACES IT: `RelatedProducts` with its `Show` dropdown set to "Tyres that fit this product". That block is the GENERIC relationship section from card 1128 \u2014 it knows nothing about wheels or tyres, it asks the registry for a relationship by name. The two have rendered through the SAME renderer (`DynamicRelatedProducts`) since that card; this one is the pre-registry one-off that was never removed.\n\n\u26A0\uFE0F THE SWAP WAS NOT SAFE UNTIL #1305, AND SAYING SO IS THE POINT. The first old-versus-new table put in front of the owner was WRONG. `DynamicRelatedProducts` returns EARLY on a tyre answer and draws this component, so the seven card settings, the head split and the Width control all stopped at that call \u2014 nine settings, measured NO EFFECT, on precisely the relationship that replaces this block. #1283 gave the new block the card settings, #1299 the head split and its own Width, #1305 carried all of it onto the tyre branch. Only then was the claim true.\n\nWHAT WAS MEASURED BEFORE RETIRING, four ways, because the premise decides the card:\n \u2022 settable text kinds (SECTION_TEXT_KINDS): both blocks ABSENT \u2014 the map holds only TimelineTrack and Footprint, both AUTHORED lists\n \u2022 read-only text regions: neither `components/CompatibleTyres` nor `components/TyreCard` stamps one\n \u2022 panel rows through resolveFields: this block 31, `RelatedProducts` 42. This block\'s only style-ish key is `_sStyle`, the bucket HEADER, not a control\n \u2022 head text (num/title/description) is authored on both, so `_partStyles` reaches it identically\nSo on the CARD runs the two are zero against zero \u2014 neither can style them \u2014 and everywhere else the new block is ahead. Styling those runs needs a section-level prop family and a paint path for DERIVED text, which no section has yet: a part is anchored by matching an AUTHORED prop\'s string against the DOM, and `lib/puck/source-bound-parts` keeps hydrated copy unreachable on purpose so a merchant cannot type into a copy of a product name and lose it at the next sync. That is its own card, and `lib/sections/text-regions` is the read-only half that already ships.\n\nTHE TYPE KEY STAYS AND SO DOES THE COMPONENT, the same contract Subscribe, Split and SubscribeBlogs have. Every page holding a `CompatibleTyres` still renders through it, no published document is rewritten, and NO MIGRATION RUNS \u2014 the owner\'s standing ruling of 2026-09-05: he redoes live sections himself and deletes the old ones when he does. He also said explicitly not to count them first.\n\n\u26A0\uFE0F AND THIS COMPONENT IS LOAD-BEARING FOR ITS OWN REPLACEMENT: `DynamicRelatedProducts` draws it for EVERY tyre answer. Deleting it would blank the block that replaces it, not just the pages still holding this one.',TimelineTrack:"Lewis, 2026-10-09/10 (decisions.md ND, approved): the horizontal year rail and the Story Timeline do one job, so the rail becomes the Story Timeline's fourth Display, Track. Retired by card [MERGE] One Text Block And Click Through Parts (2026-10-22).\n\nWHAT REPLACES IT: a Story Timeline (`Timeline`) with Display set to Track. It draws this section's own component (`components/TimelineTrack`), so for the same words it draws the same bytes: the band colour (`Background color`, the same built-in), the padding, the CTA and each milestone's `Upcoming` switch (shown on each entry under Track only). An entry's `Body` is the rail's blurb. `scripts/test-timeline-track-display.tsx` \xA72 holds the bytes.\n\nWHAT A MERCHANT LOSES on a NEW rail, said plainly: (1) the head cannot move into a box of its own (`headPlacement`); the layered rebuild puts a head in one Box with its content anyway. (2) The year and title of every milestone are not one text kind: each run is styled on its own. (3) The Width rows follow the Story Timeline's family (`background`), not the rail's (`capped`).\n\nTHE TYPE KEY STAYS AND SO DOES THE COMPONENT. Every page holding a Milestone Timeline still renders through it and can still be edited; no document is rewritten and NO MIGRATION RUNS.",KeyFeatures:`Lewis, 2026-10-10 (section-merges.md group 4, approved): one Cards section holds Cards and Key Features; Key Features' diamond cells are the card style "Label only". Retired by card [MERGE] One Text Block And Click Through Parts (2026-10-22).
|
|
18
|
+
|
|
19
|
+
WHAT REPLACES IT: a Cards section with Card style set to Label only. It draws this section's own component (\`components/KeyFeatures\`), so for the same words it draws the same bytes: the pill eyebrow when no look is stored, the columns, each cell's link. A cell's words are the card's \`title\` (row "Feature label"), its link the card's \`href\` (row "Link"), both shown under Label only. \`scripts/test-cards-label-only.tsx\` \xA72 holds the bytes.
|
|
20
|
+
|
|
21
|
+
WHAT A MERCHANT LOSES on a NEW Label only section: nothing this section had. It GAINS the Cards head split (its head can move into a box of its own), which Key Features never had: that head draws the shared \`simple\` head, eyebrow ABOVE the heading, where Key Features drew it beside.
|
|
22
|
+
|
|
23
|
+
THE TYPE KEY STAYS AND SO DOES THE COMPONENT. Every page holding a Key Features still renders through it and can still be edited; no document is rewritten and NO MIGRATION RUNS.`,SubscribeBlogs:"card 66396 \u2014 folded into `Subscribe`, which now chooses its rail's content with a `Type` control (the newsletter's own issues, or live blog posts). The two shared 21 of their fields and rendered THE SAME BYTES from equivalent rows, so offering both asked a merchant to choose between two names for one section. The type key stays because it is stored on published pages, and the component stays because those pages still render through it."},Fre=["Grid"],Pre=Array.from(new Set([...Ar.flatMap(e=>e.sections.map(o=>o.type)),...Object.keys(pH)])),Lre=Object.fromEntries(Ar.flatMap(e=>e.sections.map(o=>[o.type,o.label]))),mH={Heading:"general",Text:"general",Eyebrow:"general",ImageBlock:"general",LogoBlock:"general",ButtonBlock:"general",PostCard:"general",HeroSlide:"general",HeroGroup:"general",Integrations:"general",Grid:"general",TimelineTrack:"general",KeyFeatures:"general",CollectionCard:"commerce",GalleryItem:"commerce",ProductRef:"commerce",CompatibleTyres:"commerce",Header:"commerce",SearchBlock:"commerce",CartBlock:"commerce",CountrySwitchBlock:"commerce",AccountBlock:"commerce",ThemeSwitchBlock:"commerce",SubmitBox:"service",BookingBox:"service",SubscribeBlogs:"service",Footer:"service",FooterLogo:"service",FooterMenu:"service",FooterDivider:"service",FooterGroup:"service",FooterText:"service",FooterEmailSignup:"service",FooterSocial:"service",MenuBlock:"service",EmailFormBlock:"service",SocialLogosBlock:"service",LegalLineBlock:"service",SiteHeader:"service",SiteFooter:"service"},Rs={...mH,...Object.fromEntries(Ar.flatMap(e=>e.sections.map(o=>[o.type,o.set])))};function QC(e){return Object.prototype.hasOwnProperty.call(Rs,e)?Rs[e]:void 0}function nu(e){return Object.keys(Rs).filter(o=>Rs[o]===e).sort()}var Ore=nu("general"),Rre=nu("commerce"),Are=nu("service"),lu="Flex",ft="Box",Bre=`${ft}es`;function xH(e){return e==="section"?"Blank section":ft}function su(e,o,t){return e===lu?xH(o):t}var IH={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 JC(e){return IH[e]?.label}var ev=lu;import{currentEaselSession as hH}from"efficient-easel/screen/lib/session";var gH={general:!0,commerce:!0,service:!0};function iu(e){let o=e?.sets;return o?Object.fromEntries(ZC.map(t=>[t,o.includes(t)])):gH}function qre(e=hH()){return iu(e.blocks)}import{currentEaselSession as iv}from"efficient-easel/screen/lib/session";var Br="content",Se="Flex",bH="Text & media",yH="Layout & structure",SH=[{type:"Eyebrow",label:"Eyebrow"},{type:"Heading",label:"Heading"},{type:"Text",label:"Text"},{type:"ImageBlock",label:"Image"},{type:"LogoBlock",label:"Logo"},{type:"ButtonBlock",label:"Button"},{type:"Form",label:"Form"},{type:"PostCard",label:"Post Card"},{type:"Stats",label:"Stats"},{type:"MenuBlock",label:"Menu"},{type:"EmailFormBlock",label:"Email Form"},{type:"SocialLogosBlock",label:"Social Logos"},{type:"LegalLineBlock",label:"Legal Line"},{type:"SearchBlock",label:"Search"},{type:"CartBlock",label:"Cart"},{type:"CountrySwitchBlock",label:"Country Switch"},{type:"AccountBlock",label:"Account"},{type:"ThemeSwitchBlock",label:"Theme Switch"}].map(e=>({...e,group:bH})),CH=(Ar.find(e=>e.key==="structure")?.sections??[]).map(e=>({type:e.type,label:e.label,group:yH})),ov=[...SH,...CH],fu=[{type:"Eyebrow",label:"Eyebrow"},{type:"Heading",label:"Heading"},{type:"Text",label:"Text"},{type:"ImageBlock",label:"Image"},{type:"LogoBlock",label:"Logo"},{type:"ButtonBlock",label:"Button"},{type:"HeroGroup",label:ft}],Vre=fu.map(e=>e.type),vH=1,wH=fu.filter(e=>e.type!=="HeroGroup");function kH(e){return e<vH?fu:wH}var TH={Flex:{slot:Br,choices:()=>ov},Grid:{slot:Br,choices:()=>ov},HeroGroup:{slot:Br,choices:kH}};function tv(e,o=0){let t=TH[e];return t?{slot:t.slot,choices:t.choices(o)}:null}function Ue(e,o,t,r={}){return{type:e,props:{...o(e),id:t(e),...r}}}function rv(e,o,t){return Ue(Se,e,o,{...t,sectionPaddingTop:void 0,sectionPaddingBottom:void 0})}var EH={Manifesto:(e,o)=>({type:Se,props:{...e(Se),id:o(Se),direction:"row",share:"equal",sectionHeightMode:"screen",name:"Brand Text",content:[Ue(Se,e,o,{direction:"column",justify:"center",blockSpacing:"gap",name:"Text",sectionPaddingTop:100,sectionPaddingBottom:100,sectionPaddingLeft:40,sectionPaddingRight:40,content:[Ue("Eyebrow",e,o,{eyebrowLook:"plain"}),Ue("Heading",e,o),Ue("Text",e,o),Ue("Stats",e,o)]}),rv(e,o,{direction:"column",name:"Picture",content:[]})]}}),Split:(e,o)=>({type:Se,props:{...e(Se),id:o(Se),direction:"row",share:"equal",sectionHeightMode:"screen",sectionHeightValue:70,name:"Image & Text Split",content:[Ue(Se,e,o,{direction:"column",justify:"center",blockSpacing:"gap",name:"Text",sectionPaddingTop:100,sectionPaddingBottom:100,sectionPaddingLeft:60,sectionPaddingRight:60,content:[Ue("Eyebrow",e,o,{eyebrowLook:"plain"}),Ue("Heading",e,o),Ue("Text",e,o),Ue("ButtonBlock",e,o)]}),rv(e,o,{direction:"column",name:"Image",content:[Ue("ImageBlock",e,o)]})]}}),Subscribe:(e,o)=>({type:Se,props:{...e(Se),id:o(Se),direction:"column",name:"Subscribe",content:[Ue("Heading",e,o),Ue("Text",e,o),Ue("Form",e,o)]}})};function As(e){return EH[e]??null}import{blockTypesIn as nv}from"efficient-easel/screen/lib/puck/block-types-in";import{newNodeId as av}from"efficient-easel/draw";var FH="ImageBlock",PH=3,Bs=(e,o,t={})=>({type:e,props:{...o?.(e)??{},id:av(e),...t}}),LH=e=>({...e?.(Se)??{},direction:"column",[Br]:[Bs(FH,e),Bs(Se,e,{direction:"column",[Br]:[Bs("Heading",e),Bs("Text",e)]})]}),Oo={Hero:{slot:"slides",childType:"HeroSlide",addLabel:"Add slide",slider:!0,seeds:()=>Db.map(e=>({...e}))},HeroSlide:{slot:"groups",childType:"HeroGroup",addLabel:`Add ${ft.toLowerCase()}`,seeds:()=>[],addBlocked:pn,notice:ci},HeroSingle:{slot:"boxes",childType:"HeroGroup",addLabel:`Add ${ft.toLowerCase()}`,seeds:()=>[],addBlocked:pn,notice:ci},ProcessSteps:{slot:"boxes",childType:Se,addLabel:`Add ${ft.toLowerCase()}`,seeds:e=>Array.from({length:PH},()=>LH(e)),skipSeed:e=>Array.isArray(e.steps)&&e.steps.length>0}};function rae(e){for(let[o,t]of Object.entries(e)){if(o in Oo&&Oo[o]!==t)throw new Error(`lib/puck/slot-specs: "${o}" already has a slot spec`);Oo[o]=t}}function aae(e,o){let t=Oo[e];return t?{slot:t.slot,children:t.seeds(o).map(r=>({type:t.childType,props:{id:av(t.childType),...r}}))}:null}var lv=()=>({}),sv=new Map;function OH(e){let o=sv.get(e);if(o)return o;let t=new Set,r=Oo[e];if(r)for(let s of r.seeds(lv))for(let i of nv({type:r.childType,props:s}))t.add(i);let a=As(e);if(a){let s=0;for(let i of nv(a(lv,f=>`${f}-${s+=1}`)))t.add(i)}t.delete(e);let n=[...t].sort();return sv.set(e,n),n}function RH(e){if(!e||!e.sets&&!e.allow&&!e.deny?.length)return null;let o=iu(e),t=e.allow?new Set(e.allow):null,r=new Set(e.deny??[]),a=new Set(Object.keys(e.host??{})),n=f=>{if(r.has(f))return!1;if(a.has(f))return!0;let u=QC(f);return!u||!o[u]?!1:t?t.has(f):!0},s=new Map,i=f=>{let u=s.get(f);if(u!==void 0)return u;s.set(f,!1);let p=n(f)&&OH(f).every(i);return s.set(f,p),p};return{sets:o,offers:i}}var AH="block-offer";function cu(e=iv()){return e.cache(AH,()=>RH(vn(e)))}function fv(e,o=iv()){let t=cu(o);return t?t.offers(e):!0}function cv(e,o=0){let t=_H(e,o),r=t?cu():null;return t&&r?BH(t,r):t}function BH(e,o){if(e.spec)return o.offers(e.spec.childType)?e:null;let t=e.choices??[],r=t.filter(a=>o.offers(a.type));return r.length===t.length?e:r.length>0?{...e,choices:r}:null}function _H(e,o){let t=Oo[e];if(t)return{source:"section",slot:t.slot,choices:null,spec:t};let r=tv(e,o);if(r)return{source:"container",slot:r.slot,choices:r.choices,spec:null};let a=$y(e);return a?{source:"footer",slot:Uy,choices:a,spec:null}:null}import{useSyncExternalStore as DH}from"react";var du=null,uu=new Set;function dv(e){if(du!==e){du=e;for(let o of uu)o()}}function NH(e){return uu.add(e),()=>{uu.delete(e)}}function Sae(){return DH(NH,()=>du,()=>null)}function uv(e){return $r(e)?.ownerId??null}function pv(e,o){let t=e.props;if(e.type==="FooterMenu"){let r=t.menu;return t.heading||r?.name||l("Menu")}if(e.type==="FooterText"){let r=typeof t.text=="string"?t.text.trim():"";return r?r.length>28?`${r.slice(0,28)}\u2026`:r:l("Text")}return e.type==="FooterEmailSignup"?t.heading||l("Email signup"):o(e.type)}var mv="sf-editor-left-view";function xv(){if(typeof window>"u")return"pages";try{let e=window.localStorage.getItem(mv);return e==="sections"||e==="styles"||e==="media"?e:"pages"}catch{return"pages"}}function Iv(e){if(!(typeof window>"u"))try{window.localStorage.setItem(mv,e)}catch{}}function hv(e,o,t=!1){return e==="styles"&&!o||e==="media"&&!t?"sections":e}function gv(e,o){return e?"sections":o}var bv="Footer",MH=[xe,bv,de],_r=e=>{let o=e?.content;return Array.isArray(o)?o:[]},Ht=e=>{let o=e?.zones;return o&&typeof o=="object"&&!Array.isArray(o)?o:null},Ya=e=>{let o=e?.props?.id;return typeof o=="string"?o:void 0},yv=e=>$r(e)?.ownerId??"";function Sv(e){let o=Er(_r(e)),t=o.some(r=>r?.type===de);return o.filter(r=>r?.type===xe||r?.type===de||r?.type===bv&&!t)}function pu(e,o){let t=new Set,r=a=>{if(Array.isArray(a)){for(let s of a)r(s);return}if(!a||typeof a!="object")return;let n=a;if(typeof n.type=="string"&&n.props&&typeof n.props=="object"){let s=Ya(n);s&&t.add(s)}for(let s of Object.values(a))r(s)};if(r(e),o){let a=!0,n=new Set;for(;a;){a=!1;for(let[s,i]of Object.entries(o))n.has(s)||!t.has(yv(s))||(n.add(s),r(i),a=!0)}}return t}function mu(e,o){let t={},r={};for(let[a,n]of Object.entries(e??{}))(o.has(yv(a))?t:r)[a]=n;return{owned:t,rest:r}}function Fae(e,o){if(!o)return e;let t=Sv(o);if(!t.length)return e;let r=t.filter(i=>i.type===xe),a=t.filter(i=>i.type!==xe),n={...e,content:[...r,..._r(e),...a]},{owned:s}=mu(Ht(o),pu(t,Ht(o)));return Object.keys(s).length&&(n.zones={...Ht(e)??{},...s}),n}function Pae(e,o){if(!o)return{page:e,chrome:null};let t=Sv(o),r=new Set(t.map(Ya).filter(v=>!!v)),a=[],n=[];for(let v of _r(e)){let g=Ya(v);g&&r.has(g)||Tr(v?.type)?n.push(v):a.push(v)}let s=new Map(n.map(v=>[Ya(v),v])),i=new Set,f=Er(_r(o)).flatMap(v=>{let g=Ya(v);if(!g||!r.has(g))return[v];let y=s.get(g);return y?(i.add(y),[y]):[]});for(let v of n)i.has(v)||f.some(g=>g?.type===v.type)||(f=v.type===xe?[v,...f]:[...f,v]);f=Er(f);let u=f.length===_r(o).length&&f.every((v,g)=>v===_r(o)[g]),p=Ht(e),m=pu(f,p),{owned:x,rest:I}=mu(p,m),b=mu(Ht(o),pu(t,Ht(o))).owned,C={...o,content:u?o.content:[...f]},w=Ht(o);if(w||Object.keys(x).length){let v={};for(let[g,y]of Object.entries(w??{}))g in b?g in x&&(v[g]=x[g]):v[g]=y;for(let[g,y]of Object.entries(x))g in v||(v[g]=y);C.zones=v,w&&HH(C.zones,w)&&(C.zones=w)}let k={...e,content:a};return p&&(Object.keys(I).length||!Object.keys(b).length?k.zones=I:delete k.zones),{page:k,chrome:C}}function HH(e,o){let t=Object.keys(e),r=Object.keys(o);return t.length===r.length&&t.every((a,n)=>a===r[n]&&e[a]===o[a])}function Cv(e,o){return t=>e(t)||t!==void 0&&MH.includes(t)&&o()}var _s=null;function Oae(e){_s=e}function vv(){return!!(_s&&_s.state().lockHolder)}function Wt(){return _s!==null}var WH=new Set(["BookingBox","SubmitBox"]);function zH(e){return typeof e=="string"&&WH.has(e)}var wv=Cv(zH,vv);import{scrollPreviewToSection as U5,scrollPreviewToTop as Kv}from"efficient-easel/screen/lib/puck/preview-dom";import{Fragment as Iu,jsx as Xa,jsxs as p5}from"react/jsx-runtime";import{useMemo as _v,useRef as Dv}from"react";import{EaselCanvas as m5,useEaselApi as x5}from"efficient-easel/easel";import{jsx as Pv,Fragment as XH,jsxs as ZH}from"react/jsx-runtime";import{useEffect as Lv,useLayoutEffect as QH}from"react";var Ds="data-theme",kv="light";function GH(e){return e.getAttribute(Ds)===kv?"light":"dark"}function UH(e,o){return GH(e)===o?!1:(o==="light"?e.setAttribute(Ds,kv):e.removeAttribute(Ds),!0)}function $H(e){return Xs(e).getItem(Us)}function Mae(e,o){Xs(e).setItem(Us,o)}function qH(e,o,t=new Date().getHours()){return ku({mode:o.mode,override:$H(e),switchShown:o.switchShown,hour:t})}function Tv(e,o){let t=e.documentElement;if(!t)return()=>{};let r=()=>UH(t,qH(e,o));r();let a=e.defaultView?.MutationObserver;if(!a)return()=>{};let n=new a(r);return n.observe(t,{attributes:!0,attributeFilter:[Ds]}),()=>n.disconnect()}var jH="style";function KH(e,o){let t=Au(o),r=!1;for(let a of Ru){let n=t[a]??"";e.style.getPropertyValue(a)!==n&&(n?e.style.setProperty(a,n):e.style.removeProperty(a),r=!0)}return r}function Ev(e,o){let t=e.body;if(!t)return()=>{};let r=()=>KH(t,o);r();let a=e.defaultView?.MutationObserver;if(!a)return()=>{};let n=new a(r);return n.observe(t,{attributes:!0,attributeFilter:[jH]}),()=>n.disconnect()}var VH=String.raw`(function (doc) {
|
|
24
|
+
if (doc.__sfFitWords) return;
|
|
25
|
+
var win = doc.defaultView;
|
|
26
|
+
var SELECTOR = "h1,h2,h3,h4,h5,h6,[class*='font-heading'],[class*='font-display']";
|
|
27
|
+
var MIN_SCALE = 0.3, MIN_PX = 16, SLACK = 1;
|
|
28
|
+
|
|
29
|
+
function measure(el) {
|
|
30
|
+
var widest = 0, current = 0, last = null, split = false, lastBlock = null;
|
|
31
|
+
function blockOf(n) {
|
|
32
|
+
for (var p = n.parentElement; p && p !== el; p = p.parentElement) {
|
|
33
|
+
var d = win.getComputedStyle(p).display;
|
|
34
|
+
if (d.indexOf("inline") !== 0 && d !== "contents") return p;
|
|
35
|
+
}
|
|
36
|
+
return el;
|
|
37
|
+
}
|
|
38
|
+
function close() { if (current > widest) widest = current; current = 0; last = null; }
|
|
39
|
+
var walker = doc.createTreeWalker(el, 5), range = doc.createRange(), node;
|
|
40
|
+
while ((node = walker.nextNode())) {
|
|
41
|
+
if (node.nodeType === 1) {
|
|
42
|
+
if (node.tagName === "BR" || node.tagName === "WBR") close();
|
|
43
|
+
continue;
|
|
44
|
+
}
|
|
45
|
+
var block = blockOf(node);
|
|
46
|
+
if (block !== lastBlock) close();
|
|
47
|
+
lastBlock = block;
|
|
48
|
+
var re = /(\S+)|(\s+)/g, m;
|
|
49
|
+
while ((m = re.exec(node.data))) {
|
|
50
|
+
if (m[2]) { close(); continue; }
|
|
51
|
+
range.setStart(node, m.index);
|
|
52
|
+
range.setEnd(node, m.index + m[0].length);
|
|
53
|
+
var rects = range.getClientRects();
|
|
54
|
+
for (var i = 0; i < rects.length; i++) {
|
|
55
|
+
var r = rects[i];
|
|
56
|
+
if (r.width <= 0) continue;
|
|
57
|
+
current += r.width;
|
|
58
|
+
if (last && r.top > last.top + last.height / 2) split = true;
|
|
59
|
+
last = r;
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
close();
|
|
64
|
+
return { widest: widest, split: split };
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
function lineWidth(el) {
|
|
68
|
+
var cs = win.getComputedStyle(el);
|
|
69
|
+
return el.getBoundingClientRect().width - parseFloat(cs.paddingLeft) - parseFloat(cs.paddingRight)
|
|
70
|
+
- parseFloat(cs.borderLeftWidth) - parseFloat(cs.borderRightWidth);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
// ⚠️ THE HEADING ELEMENT IS NEVER TOUCHED — no style="", no data-*. This
|
|
74
|
+
// runs before React hydrates, and React 19 in development reports ANY
|
|
75
|
+
// attribute that differs from what it rendered ("a tree hydrated but some
|
|
76
|
+
// attributes didn't match"): first our inline font-size on the hero (which
|
|
77
|
+
// React owns via --heading-size), then, when that moved to a data-sf-fit
|
|
78
|
+
// attribute, the attribute itself. So the fitted size lives only in this
|
|
79
|
+
// script's own stylesheet, in <head>, addressed to each heading by its
|
|
80
|
+
// POSITION (":root>*:nth-child(2)>…"). A position goes stale when the page's
|
|
81
|
+
// structure changes, so the rules are rewritten in the MutationObserver
|
|
82
|
+
// callback, which runs before the next paint. !important so the size also
|
|
83
|
+
// beats a part's own inline size.
|
|
84
|
+
var head = doc.head || doc.documentElement;
|
|
85
|
+
var fitEl = doc.createElement("style");
|
|
86
|
+
fitEl.id = "storefront-fit-words-sizes";
|
|
87
|
+
head.appendChild(fitEl);
|
|
88
|
+
var fitted = new Map(); // heading -> fitted size, e.g. "43.8px"
|
|
89
|
+
|
|
90
|
+
function pathOf(el) {
|
|
91
|
+
var parts = [];
|
|
92
|
+
for (var e = el; e && e.parentElement; e = e.parentElement) {
|
|
93
|
+
var i = 1, s = e;
|
|
94
|
+
while ((s = s.previousElementSibling)) i++;
|
|
95
|
+
parts.unshift("*:nth-child(" + i + ")");
|
|
96
|
+
}
|
|
97
|
+
return ":root>" + parts.join(">");
|
|
98
|
+
}
|
|
99
|
+
function writeRules() {
|
|
100
|
+
var css = "";
|
|
101
|
+
fitted.forEach(function (size, el) {
|
|
102
|
+
if (!el.isConnected) { fitted.delete(el); return; }
|
|
103
|
+
css += pathOf(el) + "{font-size:" + size + " !important}";
|
|
104
|
+
});
|
|
105
|
+
if (fitEl.textContent !== css) fitEl.textContent = css;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
function unfit(el) {
|
|
109
|
+
if (fitted.delete(el)) writeRules();
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
function fits(el) {
|
|
113
|
+
var m = measure(el);
|
|
114
|
+
return !m.split && m.widest <= lineWidth(el) + SLACK;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
function fit(el) {
|
|
118
|
+
unfit(el);
|
|
119
|
+
if (lineWidth(el) <= 0) return; // hidden, or not laid out yet
|
|
120
|
+
if (fits(el)) return;
|
|
121
|
+
var set = parseFloat(win.getComputedStyle(el).fontSize);
|
|
122
|
+
if (!set) return;
|
|
123
|
+
var floor = Math.max(set * MIN_SCALE, MIN_PX);
|
|
124
|
+
if (floor >= set) return;
|
|
125
|
+
function size(px) { return Math.floor(px * 10) / 10 + "px"; }
|
|
126
|
+
// The SEARCH tries sizes on the element's own style and then puts that
|
|
127
|
+
// attribute back byte for byte (or removes it, if it had none), so nothing
|
|
128
|
+
// is left for React to see. A trial in a stylesheet instead restyles the
|
|
129
|
+
// whole page per step: a full pass on the Hartes home took 75–160ms at 4x
|
|
130
|
+
// CPU that way.
|
|
131
|
+
var hadStyle = el.hasAttribute("style"), origStyle = el.getAttribute("style");
|
|
132
|
+
function attempt(px) { el.style.setProperty("font-size", size(px), "important"); }
|
|
133
|
+
function done() { if (hadStyle) el.setAttribute("style", origStyle); else el.removeAttribute("style"); }
|
|
134
|
+
attempt(floor);
|
|
135
|
+
if (!fits(el)) { done(); return; } // even the floor does not fit: leave it as set
|
|
136
|
+
var lo = floor, hi = set;
|
|
137
|
+
for (var i = 0; i < 8; i++) {
|
|
138
|
+
var mid = (lo + hi) / 2;
|
|
139
|
+
attempt(mid);
|
|
140
|
+
if (fits(el)) lo = mid; else hi = mid;
|
|
141
|
+
}
|
|
142
|
+
done();
|
|
143
|
+
fitted.set(el, size(lo));
|
|
144
|
+
writeRules();
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
// What each heading measured right after we last fitted it, so the
|
|
148
|
+
// ResizeObserver below can tell a real change (a font swap, a rotate, a
|
|
149
|
+
// container that moved) from the size change our own write just caused.
|
|
150
|
+
var seen = new WeakMap();
|
|
151
|
+
function remember(el) {
|
|
152
|
+
var b = el.getBoundingClientRect();
|
|
153
|
+
seen.set(el, b.width + "x" + b.height);
|
|
154
|
+
}
|
|
155
|
+
function fitAndRemember(el) { fit(el); remember(el); }
|
|
156
|
+
|
|
157
|
+
// ⚠️ A ResizeObserver, NOT fonts.ready or a resize event, and the reason is
|
|
158
|
+
// WHEN it runs: after layout, BEFORE paint. The web font arriving re-wraps a
|
|
159
|
+
// fitted heading, and fonts.ready resolves only after that frame is painted —
|
|
160
|
+
// measured on the Hartes hero: a 42px jump in 2 of 3 loads. A size change
|
|
161
|
+
// reported here is fitted in the same frame, so the broken state is never
|
|
162
|
+
// drawn. It also covers a container that resizes.
|
|
163
|
+
var ro = new win.ResizeObserver(function (entries) {
|
|
164
|
+
for (var i = 0; i < entries.length; i++) {
|
|
165
|
+
var el = entries[i].target;
|
|
166
|
+
var b = el.getBoundingClientRect();
|
|
167
|
+
if (seen.get(el) === b.width + "x" + b.height) continue; // our own write
|
|
168
|
+
fitAndRemember(el);
|
|
169
|
+
}
|
|
170
|
+
});
|
|
171
|
+
// Its own set, not seen: fitAndRemember has written seen by the
|
|
172
|
+
// time watch runs, so a seen test observed no heading at all, and a
|
|
173
|
+
// heading fitted in the fallback face was never fitted again when the web
|
|
174
|
+
// font arrived (hartesmetal.com.au, "FusionForge." with its "." alone).
|
|
175
|
+
var watched = new WeakSet();
|
|
176
|
+
function watch(el) { if (!watched.has(el)) { watched.add(el); ro.observe(el); } }
|
|
177
|
+
|
|
178
|
+
function fitAll() {
|
|
179
|
+
var els = doc.querySelectorAll(SELECTOR);
|
|
180
|
+
for (var i = 0; i < els.length; i++) { fitAndRemember(els[i]); watch(els[i]); }
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
var queued = 0, all = false, touched = new Set();
|
|
184
|
+
function run() {
|
|
185
|
+
queued = 0;
|
|
186
|
+
if (all) { all = false; touched.clear(); fitAll(); return; }
|
|
187
|
+
var els = Array.from(touched);
|
|
188
|
+
touched.clear();
|
|
189
|
+
for (var i = 0; i < els.length; i++) if (els[i].isConnected) { fitAndRemember(els[i]); watch(els[i]); }
|
|
190
|
+
}
|
|
191
|
+
function schedule() { if (!queued) queued = win.requestAnimationFrame(run); }
|
|
192
|
+
function scheduleAll() { all = true; schedule(); }
|
|
193
|
+
|
|
194
|
+
fitAll();
|
|
195
|
+
// A backstop only: a font that changes widths without changing any
|
|
196
|
+
// heading's box is not seen by the ResizeObserver.
|
|
197
|
+
if (doc.fonts && doc.fonts.ready) doc.fonts.ready.then(scheduleAll, function () {});
|
|
198
|
+
|
|
199
|
+
// …and the viewport WIDTH, which the ResizeObserver cannot stand in for: a
|
|
200
|
+
// heading sized to its own text (fit-content, a flex item) keeps the SAME box
|
|
201
|
+
// when the phone turns to 844, so nothing reports a change and it would stay
|
|
202
|
+
// shrunk. The probe's rotate check caught exactly that.
|
|
203
|
+
var lastWidth = win.innerWidth;
|
|
204
|
+
function onResize() {
|
|
205
|
+
if (win.innerWidth === lastWidth) return; // a phone's toolbar changing HEIGHT is not our business
|
|
206
|
+
lastWidth = win.innerWidth;
|
|
207
|
+
scheduleAll();
|
|
208
|
+
}
|
|
209
|
+
win.addEventListener("resize", onResize);
|
|
210
|
+
|
|
211
|
+
var mo = new win.MutationObserver(function (records) {
|
|
212
|
+
// Positions first: a node added or removed anywhere can shift the
|
|
213
|
+
// nth-child path of a fitted heading, and this callback runs before paint.
|
|
214
|
+
if (fitted.size) {
|
|
215
|
+
for (var q = 0; q < records.length; q++) if (records[q].type === "childList") { writeRules(); break; }
|
|
216
|
+
}
|
|
217
|
+
for (var i = 0; i < records.length; i++) {
|
|
218
|
+
var r = records[i];
|
|
219
|
+
var target = r.target.nodeType === 1 ? r.target : r.target.parentElement;
|
|
220
|
+
var own = target && target.closest(SELECTOR);
|
|
221
|
+
if (own) touched.add(own);
|
|
222
|
+
for (var j = 0; j < r.addedNodes.length; j++) {
|
|
223
|
+
var n = r.addedNodes[j];
|
|
224
|
+
if (n.nodeType !== 1) continue;
|
|
225
|
+
if (n.matches(SELECTOR)) touched.add(n);
|
|
226
|
+
var inner = n.querySelectorAll(SELECTOR);
|
|
227
|
+
for (var k = 0; k < inner.length; k++) touched.add(inner[k]);
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
if (touched.size) schedule();
|
|
231
|
+
});
|
|
232
|
+
mo.observe(doc.body, { childList: true, subtree: true, characterData: true });
|
|
233
|
+
|
|
234
|
+
doc.__sfFitWords = function stop() {
|
|
235
|
+
win.removeEventListener("resize", onResize);
|
|
236
|
+
ro.disconnect();
|
|
237
|
+
mo.disconnect();
|
|
238
|
+
if (queued) win.cancelAnimationFrame(queued);
|
|
239
|
+
fitted.clear();
|
|
240
|
+
fitEl.remove();
|
|
241
|
+
delete doc.__sfFitWords;
|
|
242
|
+
};
|
|
243
|
+
// For the probe and for debugging: which headings are fitted, at what size,
|
|
244
|
+
// and the sheet that holds it (disable it to read a heading's set size).
|
|
245
|
+
doc.__sfFitWords.fitted = fitted;
|
|
246
|
+
doc.__sfFitWords.sheet = fitEl;
|
|
247
|
+
})(document);`,YH="storefront-fit-words";function Fv(e){let o=e.createElement("script");return o.id=YH,o.textContent=VH,(e.head??e.documentElement).appendChild(o),()=>{e.__sfFitWords?.(),o.remove()}}var JH=`
|
|
248
|
+
[${mo}][${mo}] { cursor: text; }
|
|
249
|
+
[${Ke}][${Ke}][${Ke}] {
|
|
250
|
+
outline: 1px solid ${Ta.accent};
|
|
251
|
+
outline-offset: 2px;
|
|
252
|
+
}
|
|
253
|
+
[${Ke}][${Ke}]:has([${Ke}]),
|
|
254
|
+
[data-puck-overlay-portal][data-puck-overlay-portal]:has([${Ke}]) {
|
|
255
|
+
outline: none;
|
|
256
|
+
}
|
|
257
|
+
[${Ke}][${Ke}][${Ke}][data-es-typing],
|
|
258
|
+
[data-es-typing] [${Ke}][${Ke}][${Ke}] {
|
|
259
|
+
outline: none;
|
|
260
|
+
}
|
|
261
|
+
`;function Ov({children:e,document:o}){let{theme:t,themeMode:r,themeSwitchShown:a}=V(),n=Je(t);return Lv(()=>{if(o)return Tv(o,{mode:r,switchShown:a})},[o,r,a]),Lv(()=>{if(o)return Ev(o,n)},[o,n]),QH(()=>{if(o)return Fv(o)},[o]),ZH(XH,{children:[Pv(cp,{}),Pv("style",{children:JH}),e]})}import{jsx as xu}from"react/jsx-runtime";import{useEffect as e5,useState as o5}from"react";import{Banner as t5}from"efficient-shell/ui";var Ns={load:"The header and footer could not load. They are hidden for now and nothing in them is saved. Reload to try again.",lock:"{name} is editing the header and footer. Nothing you change in them here is saved.",conflict:"The header and footer were changed somewhere else. Nothing you change in them here is saved. Reload to get the latest.",save:"The header and footer did not save. They are sent again with your next change."},r5=Ns.load,a5=Ns.lock,n5=Ns.conflict,l5=Ns.save;function s5(e){return e?e.loadFailed?l(r5):e.lockHolder?l(a5,{name:e.lockHolder.name||l("Somebody else")}):e.conflict?l(n5):e.saveFailed?l(l5):null:null}function i5({report:e}){let o=s5(Ps(e)),[t,r]=o5(null);return e5(()=>{o||r(null)},[o]),!o||t===o?null:xu("aside",{className:"sf-canvas-notice",children:xu(t5,{tone:"warning",onDismiss:()=>r(o),children:o})})}function Rv(){return xu(i5,{report:Ls()})}import{jsx as Ms}from"react/jsx-runtime";import{useState as Av}from"react";import{Banner as f5,Button as c5}from"efficient-shell/ui";import{UndoIcon as d5}from"efficient-shell/icons/efficient";import{useScreenDocument as u5}from"efficient-easel/screen/components/ScreenDocumentContext";function Bv(){let e=PC(),{adapter:o,flushSave:t,reloadFromServer:r}=u5(),a=o.siteVersions,[n,s]=Av(!1),[i,f]=Av(!1);if(!e)return null;let u=async()=>{if(!(!a||n)){s(!0),f(!1);try{await RC({access:a,flushSave:t,reload:r})}catch{f(!0)}finally{s(!1)}}};return Ms("aside",{className:"sf-canvas-notice",children:Ms(f5,{tone:i?"danger":"info",title:e.title,onDismiss:Os,action:a&&e.undo?Ms(c5,{variant:"secondary",size:"sm",leftIcon:Ms(d5,{}),loading:n,disabled:n,onClick:()=>{u()},children:l("Undo")}):void 0,children:i?l("Undo did not work. Nothing changed. Try again."):l("Check it with Preview. Press Publish to put it live.")})})}import{usePreviewParts as Nv}from"efficient-easel/draw/client";import{useSectionOps as I5}from"efficient-easel/screen/lib/puck/use-section-ops";function h5({children:e,componentId:o}){let{selectedPartId:t}=Nv();return ih(t,o)?Xa(Iu,{}):Xa(Iu,{children:e})}function Mv(e){let{mirrorHostStyles:o}=ti(),t=up(),{sectionBackgroundWidth:r,sectionContentWidth:a,themeFromDocument:n}=V(),s=_v(()=>({...e.metadata??t??{},...Dx(n?null:r,n?null:a)}),[e.metadata,t,r,a,n]),i=Dv(null),f=g5(i),{onDocument:u}=e,p=m=>{i.current=m,u?.(m)};return p5(Iu,{children:[Xa(Bv,{}),Xa(Rv,{}),Xa(m5,{...e,onDocument:p,typing:f,metadata:s,height:"fill",mirrorStyles:o,frameWrapper:Ov,overlay:h5})]})}function g5(e){let o=x5(),t=I5(),r=Nv(),a=Dv({ops:t,parts:r});return a.current={ops:t,parts:r},_v(()=>{let n={getItemById:i=>o.getState().getItemById(i),getSelectorForId:i=>o.getState().getSelectorForId(i),get components(){return o.getState().config.components},replace:(i,f,u)=>a.current.ops.replaceComponent(i,f,u)},s=(i,f)=>{let u=my(i,n);if(!u)return null;let p=f,m=()=>(p=xy(p,p?.ownerDocument??e.current,i),p),x=m();return x?{element:m,value:u.value,rules:u.rules,multiline:u.multiline,write:u.write,toolbar:{offered:u.offered,colors:u.offered.length>0?ls(wy(x)):void 0}}:null};return{at:i=>{let f=i.closest(`[${mo}]`),u=f?.getAttribute(mo);return f&&u?s(u,f):null},atSelection:()=>{let i=a.current.parts.selectedPartId;return i?s(i,null):null},onChange:i=>{if(!i.typing){dd(null);return}let f=i.element.closest(`[${mo}]`)?.getAttribute(mo)??null;dd(f),f&&a.current.parts.selectedPartId!==f&&a.current.parts.select(f)}}},[o,e])}var Hv={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 b5="Save your page changes first";function Wv(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:b5}:{visible:!0,enabled:!0}:{visible:!1,hiddenReason:"no-site"}:{visible:!1,hiddenReason:"not-operator"}:{visible:!1,hiddenReason:"no-console"}}var zv="storefront-editor:save-as-template";var y5="plain",Gv=[{label:"Plain",value:"plain"},{label:"Filled",value:"filled"},{label:"Line",value:"line"}],S5="line",C5={KeyFeatures:"filled"};function Za(e){return C5[e]??y5}function Lne(e,o){return eo(Gv,Za(o),e)}function One(e){return eo(Gv,S5,e)}var v5="inline",w5=[{label:"In this section",value:"inline"},{label:"In its own box",value:"own-box"}];var ct={ProductGrid:{num:"num",title:"title",description:"description",headRows:["num","title","titleSize","description","linkText","linkHref"],renderer:"ProductGridSection",padKey:"padTop",linkProp:"link"},TyreSizes:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicTyreSizes"},FitmentFinder:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"FitmentFinder"},TyreFitment:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicTyreFitment"},BundleOffer:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicBundleOffer"},CompatibleTyres:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicRelatedProducts"},RelatedProducts:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicRelatedProducts"},SpecTable:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"SpecTable"},FAQ:{num:"num",title:"title",linkProp:"link",headRows:["num","title","linkText","linkHref"],renderer:"FAQ"},GalleryB:{num:"num",title:"title",headRows:["num","title","linkText","linkHref"],renderer:"GalleryGrid"},FitmentTable:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"FitmentTable"},Events:{num:"num",title:"title",linkProp:"link",headRows:["num","title","linkText","linkHref"],renderer:"Events"},ProcessSteps:{num:"num",title:"title",description:"description",headRows:["num","title","description"],headStyle:"editorial",renderer:"ProcessSteps",padKey:"padTop"},LongRead:{num:"headNum",title:"headTitle",description:"headDesc",headRows:["headNum","headTitle","headDesc"],headStyle:"editorial",renderer:"LongRead"},Series:{num:"headNum",title:"headTitle",description:"headDesc",headRows:["headNum","headTitle","headDesc"],headStyle:"editorial",renderer:"Series"},TimelineTrack:{num:"eyebrow",title:"title",description:"intro",headRows:["eyebrow","title","intro"],headStyle:"editorial",renderer:"TimelineTrack",padKey:"padTop"},StatsParagraph:{num:"eyebrow",title:"title",description:"desc",headRows:["eyebrow","title","desc"],headStyle:"editorial",renderer:"StatsParagraph"},Footprint:{num:"sectionNumber",title:"heading",description:"tagline",headRows:["sectionNumber","heading","tagline"],headStyle:"editorial",renderer:"Footprint",padKey:"padTop"},Collections:{num:"eyebrow",title:"heading",headRows:["eyebrow","heading"],renderer:"Collections"},Cards:{num:"eyebrow",title:"title",headRows:["eyebrow","eyebrowLook","title"],headStyle:"simple",renderer:"Cards"},Testimonials:{num:"eyebrow",title:"title",headRows:["eyebrow","eyebrowLook","title"],headStyle:"simple",renderer:"Testimonials"},Reviews:{num:"eyebrow",title:"title",headRows:["eyebrow","eyebrowLook","title"],headStyle:"simple",renderer:"Reviews"},Prose:{num:"eyebrow",title:"title",headRows:["eyebrow","title"],headStyle:"essay",renderer:"Prose"},ReviewForm:{num:"eyebrow",title:"title",headRows:["eyebrow","title"],headStyle:"simple",renderer:"ReviewForm"},DeliveryOptions:{num:"eyebrow",title:"title",description:"body",headRows:["eyebrow","title","body"],headStyle:"natural",headRowGap:"gap-3",headDescriptionSize:"text-[15px]",renderer:"DeliveryOptions"}},Dr="SectionHeader";function Uv(e){return e in ct}function _ne(e){return eo(w5,v5,e)}var $v=new Set(["Flex"]);function Dne(e){return!!e?.type&&$v.has(e.type)}var k5={not:{context:"parentType",in:[...$v]}};function Nne(e,o,t){return $l(e,t,k5)}var T5={not:{field:"headPlacement",is:"own-box"}};function Mne(e,o,t){return $l(e,t,T5)}function qv(e,{nodeDefaults:o,newNodeId:t,sectionLabel:r,blockIsOffered:a}){let n=As(e);return n?n(o,t):Uv(e)&&a(Se)&&a(Dr)?{type:Se,props:{...o(Se),id:t(Se),direction:"column",name:`${r(e)} section`,content:[{type:Dr,props:{...o(Dr),id:t(Dr),...ct[e]?.headStyle?{headStyle:ct[e].headStyle}:{},...ct[e]?.headRowGap?{rowGap:ct[e].headRowGap}:{},...ct[e]?.headDescriptionSize?{descriptionSize:ct[e].headDescriptionSize}:{},...Za(e)!==Za(Dr)?{eyebrowLook:Za(e)}:{}}},{type:e,props:{...o(e),id:t(e),headPlacement:"own-box"}}]}}:Oo[e]?.fixed===!0?{type:e,props:{...o(e),id:t(e),layout:"boxes"}}:null}import{useEffect as E5,useState as F5}from"react";import{useEaselSession as P5}from"efficient-easel/screen/lib/session-context";function jv(){let e=P5().chrome?.products?.list,[o,t]=F5(null);return E5(()=>{if(!e)return;let r=!1;return e().then(a=>{r||t(a)}),()=>{r=!0}},[e]),o}function Jv({mode:e,open:o}){let{setSelectedHeroId:t,setSelectHandler:r}=Wl(),a=Qv().tree,n=e,s=n.kind==="ticker"?n.heroId:null,i=Ja(f=>{f&&(o({kind:"ticker",heroId:f}),U5(f))},[o]);return Ro(()=>{t(s)},[s,t]),Ro(()=>{r(i)},[r,i]),{partRows:(f,{rowClick:u})=>{let p=String(f.props.id);return f.type==="Hero"&&ke(Zv,{icon:ke(Bt,{type:"ticker",size:13}),name:l(xa),onSelect:()=>i(p),selected:s===p,rowProps:{onClick:u(()=>i(p))},words:a})}}}function ew({mode:e,select:o}){let{setSelectedHeroPart:t,setSelectHandler:r}=zl(),a=Qv().tree,{appState:n}=W5(x=>x),s=n.data.content??[],i=L5(s);i.current=s;let f=e,u=Ia.find(x=>ha[x]===f.kind),p=u&&"nodeId"in f?ga(String(f.nodeId),u):null,m=Ja(x=>{let I=_g(x);if(!I)return;let b=i.current.findIndex(w=>String(w.props.id)===I.nodeId);if(b<0)return;let C={kind:ha[I.part],nodeId:I.nodeId};o({index:b},C)},[o]);return Ro(()=>{t(p)},[p,t]),Ro(()=>{r(m)},[r,m]),{partRows:(x,{rowClick:I})=>{let b=String(x.props.id),C=Bg(x);if(C.length===0)return null;let w=g=>{let y=ga(b,g.part);return ke(Zv,{icon:ke(Bt,{type:g.part==="media"?"heroMedia":"heroImage",size:13}),name:l(g.label),onSelect:()=>m(y),selected:p===y,rowProps:{onClick:I(()=>m(y))},words:a},y)},[k,...v]=C;return Qa(Xv,{children:[w(k),v.length>0&&ke(H5,{children:v.map(w)})]})}}}function ow(e,o){return{partRows:(t,r)=>Qa(Xv,{children:[e.partRows?.(t,r),o.partRows?.(t,r)]})}}function $5(e){let{adapter:o,capabilities:t,currentSlug:r,siteId:a,docId:n,hasUnsavedEdits:s,bridgeCapabilities:i,notifyParent:f,token:u}=gu(),{hasPreviewLink:p}=t,m=We(G5()).preview?.draftLink,x=GC(e.data),I=Wv({hasTrustedConsole:!!u,canCreatePlatformTemplate:i.canCreatePlatformTemplate,capabilities:t,siteId:a,hasUnsavedEdits:s}),b=Ja(()=>{!a||!r||f(zv,{siteId:a,slug:r})},[f,a,r]),C=hC({pageSlug:r,siteId:a,token:u}),w=o.previewHref?.(r)??C;return{barLead:()=>I.visible&&ke(A5,{side:"bottom",content:I.enabled?l("Save this website as a platform template"):l(I.disabledReason),children:ke("span",{className:"sf-tip-disabled",tabIndex:I.enabled?void 0:0,children:ke(R5,{variant:"secondary",disabled:!I.enabled,onClick:b,rightIcon:ke(M5,{size:15}),children:l("Save as Template")})})}),barTrail:()=>p&&r&&ke(yC,{liveHref:w,pageId:n??null,draftLink:m}),mainAction:x}}function q5(e,o){let{capabilities:t,templateId:r,siteId:a,tokenRef:n,navigate:s}=gu(),{hasSiteTheme:i,explainsSiteSettings:f}=t,u=k=>o.setView(k),[p,m]=O5(ur[0].id),{surface:x,setSurface:I}=Cg(),b=()=>{if(i){u("styles"),o.reveal(),Kv();return}e.show(Md),e.reveal(),Kv()},C={id:"pages",label:l("Pages"),icon:ke(_5,{}),panel:({onHide:k})=>ke(mg,{activeSurface:x,onPreviewSurface:I,onNavigate:v=>{I(null),s(r?{kind:"template",id:r,pageSlug:v}:{kind:"page",slug:v,siteId:a??void 0})},onClose:k})},w=[];return!i&&f&&w.push({id:"appearance",label:l("Appearance"),icon:ke(N5,{}),active:e.kind==="website",onSelect:b}),i&&w.push({id:"styles",label:l("Site styles"),icon:ke(D5,{}),panel:({onHide:k,notify:v})=>ke(WS,{tokenRef:n,siteId:a??void 0,onClose:k,onNotify:v,tab:p,onTabChange:m})}),{railLead:[C],railTrail:w,resolveLeftView:(k,v)=>hv(k,i,v),openSettings:b,openStyles:()=>{m(Kh),u("styles")}}}function j5(e,o,t,r){let{kind:a,open:n}=e,{selected:s,zoneOf:i}=o;Ro(()=>{dv(s?.type==="BookingBox"&&s.props.region==="confirm"?uv(i(String(s.props.id))):null)},[s?.props.id]);let f=iC(e,o),{capabilities:{hasSiteSettings:u}}=gu(),{setSelected:p,setSelectHandler:m}=V(),{chat:x,setChat:I,setSelected:b,setSelectHandler:C}=Hl(),w=a==="header";Ro(()=>{p(w)},[w,p]),Ro(()=>{m(()=>n(Nd))},[m,n]);let k=Ja(()=>n(LS),[n]),v=a==="chat";Ro(()=>{b(v)},[v,b]),Ro(()=>{C(k)},[C,k]);let{setOpenHandler:g}=ma(),y=Ja(()=>n(OS),[n]);Ro(()=>{g(y)},[g,y]);let L=ow(Jv(e),ew(e)),F=$5(o),O=q5(e,r),E=t.device;return{...L,...F,...O,hasOwnRows:D=>D.type===Es,ownRows:f.renderLocationTree,sectionPressed:f.sectionPressed,wrap:D=>ke(ri.Provider,{value:!0,children:Qa(z5.Provider,{value:E,children:[D,ke(XC,{})]})}),addPanelRow:D=>u?Qa("div",{className:"sf-addside-sitewide",children:[ke("span",{className:"sf-addside-sitewide-glyph","aria-hidden":"true",children:ke(Bt,{type:"chat",size:16})}),Qa("button",{type:"button",className:"sf-addside-sitewide-name",onClick:()=>{D(),k()},children:[l("Live chat"),ke("span",{className:"sf-addside-sitewide-desc",children:l("A chat bubble on every page")})]}),ke(B5,{checked:x.enabled,onChange:G=>I({enabled:G}),ariaLabel:l("Show the chat bubble on the whole site")})]}):void 0}}var Vv=null,hu=new WeakMap;function K5(e){let o=Zu();if(!e||!o)return e;Vv!==o&&(Vv=o,hu=new WeakMap);let t=hu.get(e);return t||(t={...e,choices:e.choices?e.choices.map(r=>({...r,label:l(r.label)})):null,spec:e.spec?{...e.spec,addLabel:l(e.spec.addLabel)}:null},hu.set(e,t)),t}var V5={isLockedBlock:wv,duplicateBlocked:xs,nestDepth:(e,o,t)=>o===mn?Lp(e,t):0,newSectionNode:qv,canAddTo:(e,o)=>K5(cv(e,o)),blockIsOffered:fv},Y5=new Proxy(Hv,{get:(e,o)=>{let t=Reflect.get(e,o);return typeof t=="string"?l(t):t}}),X5={labelAtLevel:(e,o,t)=>l(su(e,o,t)),descriptions:Y5,categoryLabel:e=>{let o=JC(e);return o===void 0?void 0:l(o)},firstSection:ev,blockRowName:pv,plainText:Ct,Icon:Bt,Thumbnail:HS,useProducts:jv},Z5={desktop:2e3,tablet:800,mobile:390},Yv="desktop",Q5={options:gg,initial:Yv,fluid:Yv,widths:Z5},J5={read:xv,write:e=>Iv(e),forSelection:(e,o)=>gv(e,o)},e3={first:Ve,last:me,firstGroup:xe,lastGroup:de,isSectionGroup:Tr,sectionGroupZone:qy,panelOf:e=>e===Ve?Nd:null,get sharedReach(){return Wt()?Cd:void 0},get groupTab(){return Wt()?Xy:void 0},get groupBadge(){return Wt()?Cd({type:de})??void 0:void 0},get changeNotice(){return Wt()?Zy():void 0},get band(){return Wt()?o3:void 0},get groupAccepts(){return Wt()?Vy:void 0}},o3={foldable:!0};function t3(e){return{...ow(Jv(e),ew(e)),openSettings:()=>e.show(Md)}}var Qle={useOwnerName:pr,useDocumentLabel:Jh,useBridges:j5,useStandaloneBridges:t3,useDocumentPass:uC,blockRules:V5,blockLook:X5,devices:Q5,leftView:J5,pinned:e3,Canvas:Mv,Inspector:AS};export{Ere as a,Fre as b,Pre as c,Lre as d,ft as e,iu as f,qre as g,We as h,vn as i,ov as j,Vre as k,NY as l,gb as m,UY as n,wb as o,$Y as p,kb as q,Eb as r,Lb as s,Ob as t,tX as u,rX as v,aX as w,nX as x,O_ as y,_p as z,xX as A,dn as B,sk as C,P4 as D,gt as E,L4 as F,O4 as G,mn as H,Lp as I,rae as J,aae as K,RH as L,Tp as M,rk as N,S4 as O,cn as P,Ep as Q,ak as R,nk as S,lk as T,w4 as U,k4 as V,T4 as W,E4 as X,bc as Y,dA as Z,uA as _,pA as $,$l as aa,ql as ba,zj as ca,xe as da,de as ea,RJ as fa,jy as ga,ms as ha,eo as ia,ct as ja,_ne as ka,Dne as la,Nne as ma,Mne as na,Df as oa,x6 as pa,I6 as qa,vi as ra,Ct as sa,Kr as ta,Il as ua,hl as va,mo as wa,Z8 as xa,Ke as ya,Q8 as za,iL as Aa,fL as Ba,J8 as Ca,lr as Da,eq as Ea,oq as Fa,jf as Ga,sr as Ha,ir as Ia,Sh as Ja,Cl as Ka,kh as La,Qf as Ma,yl as Na,iq as Oa,fq as Pa,cq as Qa,dq as Ra,YL as Sa,ba as Ta,rb as Ua,ab as Va,Xl as Wa,rY as Xa,aY as Ya,nY as Za,lY as _a,j3 as $a,X3 as ab,Z3 as bb,Q3 as cb,we as db,FE as eb,rf as fb,PE as gb,zG as hb,UG as ib,$G as jb,OE as kb,qG as lb,Lx as mb,lf as nb,sf as ob,JG as pb,oU as qb,tU as rb,rU as sb,aU as tb,Jt as ub,Mo as vb,uf as wb,Bx as xb,NE as yb,pf as zb,Gn as Ab,sU as Bb,ET as Cb,sW as Db,Pn as Eb,kt as Fb,Xr as Gb,Mm as Hb,_z as Ib,O0 as Jb,Dz as Kb,xn as Lb,Np as Mb,$4 as Nb,q4 as Ob,Lk as Pb,j4 as Qb,Y4 as Rb,Hp as Sb,X4 as Tb,Rk as Ub,Z4 as Vb,J0 as Wb,Rn as Xb,iG as Yb,Ki as Zb,fG as _b,lE as $b,cG as ac,uG as bc,pG as cc,vG as dc,wG as ec,kG as fc,Xm as gc,rG as hc,aG as ic,nG as jc,lG as kc,dE as lc,Bn as mc,xG as nc,nx as oc,r3 as pc,Q as qc,l as rc,so as sc,wy as tc,Yl as uc,iQ as vc,Cy as wc,km as xc,Tn as yc,Tm as zc,JW as Ac,S0 as Bc,yz as Cc,Am as Dc,x4 as Ec,b4 as Fc,ui as Gc,wk as Hc,W4 as Ic,e6 as Jc,Fi as Kc,Pi as Lc,eW as Mc,oW as Nc,fm as Oc,tW as Pc,rW as Qc,aW as Rc,xm as Sc,hm as Tc,Ez as Uc,_m as Vc,Be as Wc,ep as Xc,s3 as Yc,iw as Zc,i3 as _c,f3 as $c,tp as ad,u3 as bd,fw as cd,p3 as dd,m3 as ed,dw as fd,h3 as gd,uw as hd,g3 as id,jt as jd,y3 as kd,S3 as ld,C3 as md,v3 as nd,nn as od,w3 as pd,xw as qd,O3 as rd,sp as sd,hw as td,gw as ud,bw as vd,Sw as wd,Cw as xd,vw as yd,ei as zd,R3 as Ad,G0 as Bd,oG as Cd,hG as Dd,gG as Ed,bG as Fd,yG as Gd,SG as Hd,hx as Id,wE as Jd,EG as Kd,xx as Ld,Ix as Md,FG as Nd,Dn as Od,Nn as Pd,LG as Qd,Qt as Rd,Hn as Sd,AG as Td,BG as Ud,_G as Vd,Tx as Wd,NG as Xd,rt as Yd,zo as Zd,bf as _d,To as $d,h$ as ae,g$ as be,b$ as ce,y$ as de,w$ as ee,k$ as fe,e1 as ge,T$ as he,E$ as ie,F$ as je,n1 as ke,P$ as le,L$ as me,O$ as ne,De as oe,R$ as pe,i1 as qe,A$ as re,B$ as se,rr as te,_$ as ue,Vn as ve,er as we,D$ as xe,xI as ye,Zn as ze,Qn as Ae,N$ as Be,M$ as Ce,H$ as De,W$ as Ee,z$ as Fe,G$ as Ge,U$ as He,$$ as Ie,q$ as Je,j$ as Ke,K$ as Le,V$ as Me,Jn as Ne,Y$ as Oe,el as Pe,ol as Qe,vf as Re,tl as Se,X$ as Te,Ft as Ue,Z$ as Ve,Q$ as We,J$ as Xe,e7 as Ye,o7 as Ze,t7 as _e,r7 as $e,a7 as af,tt as bf,n7 as cf,l7 as df,rl as ef,s7 as ff,wf as gf,i7 as hf,f7 as if,kf as jf,c7 as kf,CI as lf,vI as mf,wI as nf,d7 as of,X1 as pf,u7 as qf,p7 as rf,bM as sf,iS as tf,oo as uf,_a as vf,CM as wf,pS as xf,xee as yf,Iee as zf,hee as Af,gee as Bf,bee as Cf,yee as Df,See as Ef,Cee as Ff,vee as Gf,wee as Hf,kee as If,Gl as Jf,JR as Kf,Pj as Lf,Lj as Mf,rA as Nf,nA as Of,vg as Pf,fA as Qf,_j as Rf,Dj as Sf,kg as Tf,Nj as Uf,Eg as Vf,Tg as Wf,Vj as Xf,Nl as Yf,xg as Zf,Ig as _f,Ml as $f,lj as ag,sj as bg,Hl as cg,qR as dg,hj as eg,ma as fg,Sj as gg,Cg as hg,are as ig,nre as jg,lre as kg,sre as lg,Fae as mg,Pae as ng,Oae as og,wj as pg,Ej as qg,zl as rg,qoe as sg,zS as tg,GS as ug,U3 as vg,Oh as wg,yq as xg,Sq as yg,Cq as zg,vq as Ag,cc as Bg,dc as Cg,Lg as Dg,Xj as Eg,Og as Fg,IA as Gg,yc as Hg,eK as Ig,oK as Jg,hA as Kg,tK as Lg,ga as Mg,_g as Ng,rK as Og,Dg as Pg,_V as Qg,Ug as Rg,jc as Sg,Kc as Tg,NB as Ug,MB as Vg,Vc as Wg,zB as Xg,Ca as Yg,Ql as Zg,pY as _g,Jc as $g,CY as ah,vY as bh,wY as ch,xb as dh,M_ as eh,H_ as fh,W_ as gh,CX as hh,vX as ih,K_ as jh,Y_ as kh,qb as lh,OX as mh,RX as nh,Qb as oh,MX as ph,Ta as qh,oy as rh,nd as sh,ty as th,ry as uh,UX as vh,ay as wh,cD as xh,$X as yh,qX as zh,jX as Ah,KX as Bh,dD as Ch,VX as Dh,YX as Eh,XX as Fh,pD as Gh,ZX as Hh,ID as Ih,QX as Jh,sd as Kh,SZ as Lh,Py as Mh,IQ as Nh,nN as Oh,lN as Ph,Oa as Qh,sN as Rh,iN as Sh,wQ as Th,By as Uh,me as Vh,ps as Wh,Io as Xh,jS as Yh,KS as Zh,Yoe as _h,Wa as $h,VS as ai,YS as bi,Qoe as ci,Joe as di,pC as ei,Qd as fi,mC as gi,cv as hi,Sae as ii,Ds as ji,GH as ki,UH as li,Mae as mi,D3 as ni,W3 as oi,y5 as pi,Gv as qi,S5 as ri,Za as si,Lne as ti,One as ui,Qle as vi};
|