efficient-web-builder 67.5.0 → 67.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. package/CHANGELOG.md +18 -0
  2. package/dist/editor/components/storefront-editor.css +3 -1
  3. package/dist/editor/lib/document/ColourControl.d.ts +2 -1
  4. package/dist/editor/lib/document/ColourControl.js +1 -1
  5. package/dist/editor/lib/document/blocks/general/Flex/fields.js +1 -1
  6. package/dist/editor/lib/document/blocks/general/HeroSlide/fields.js +1 -1
  7. package/dist/editor/lib/document/controls.js +1 -1
  8. package/dist/format/lib/content/box-background.d.ts +12 -0
  9. package/dist/format/lib/content/box-background.js +1 -1
  10. package/dist/format/lib/content/image-treatment.js +1 -1
  11. package/dist/format/lib/content/view-lines.d.ts +1 -0
  12. package/dist/format/lib/content/view-lines.js +1 -1
  13. package/dist/format/lib/document/seed-parts.d.ts +1 -1
  14. package/dist/format/lib/document/seed-parts.js +1 -1
  15. package/dist/format/lib/editor-words-catalogue.d.ts +4 -0
  16. package/dist/format/lib/editor-words-catalogue.js +3 -3
  17. package/dist/format/lib/hero-video.d.ts +1 -1
  18. package/dist/format/lib/hero-video.js +1 -1
  19. package/dist/render/components/Flex.d.ts +2 -1
  20. package/dist/render/components/Flex.js +1 -1
  21. package/dist/render/components/HeroPoster.d.ts +5 -1
  22. package/dist/render/components/HeroPoster.js +1 -1
  23. package/dist/render/components/HeroSlide.d.ts +5 -1
  24. package/dist/render/components/HeroSlide.js +1 -1
  25. package/dist/render/components/HeroVideoPlay.d.ts +4 -1
  26. package/dist/render/components/HeroVideoPlay.js +1 -1
  27. package/dist/render/components/SectionAnimation.d.ts +3 -0
  28. package/dist/render/components/SectionAnimation.js +1 -1
  29. package/dist/render/lib/document/blocks/general/Flex/render.js +1 -1
  30. package/dist/render/lib/document/blocks/general/HeroSlide/render.js +1 -1
  31. package/dist/render/lib/document/hero-media-parts.d.ts +2 -0
  32. package/dist/render/lib/document/hero-media-parts.js +1 -1
  33. package/dist/render/lib/media.d.ts +15 -0
  34. package/dist/render/lib/media.js +1 -1
  35. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,23 @@
1
1
  # Changelog
2
2
 
3
+ ## 67.6.0 - 2026-11-11
4
+
5
+ From main at `a2c1240e`: #721, #724, #722. A minor: no `!`, no export is removed, the peers stay `efficient-easel` `^34.1.0` and `efficient-shell` `^12.33.0`. New exports, one optional parameter and optional props only. No stored key or value moves.
6
+
7
+ **For hosts:**
8
+ - Nothing to change. Stored Hero slides draw the bytes they drew (#721). A caller of `markBoxProps` that passes a Fill gets the same props (#724). A Box with no fade keeps its flat Fill (#722).
9
+ - storefront: take this release to draw a Hero slide's phone video and phone poster (#721).
10
+ - storefront-blocks: `squareBox` can drop its cast now that the Fill is optional (#724).
11
+
12
+ ### Added
13
+
14
+ - **A Hero slide can carry its own phone video and phone poster** (#721): slide fields `mediaVideoPhone` and its own first frame `videoFramePhone`. The poster preloads per view; the AV1 source list is written only when there are two sources. New exports `EDGE_WIDE_MEDIA` (view-lines), `videoForView`, `videoSources`, `VideoFileSource`, `ViewVideoFiles` (media), `AV1_FILE_LABEL`, `AV1_FILE_PROMPT` (hero-media-parts) and `useViewWidthRead` (SectionAnimation); `loadingStill` takes an optional view argument; `HeroSlide`, `HeroPoster` and `HeroVideoPlayer` take optional phone and AV1 source props.
15
+ - **A Box's Fill can fade from the top down** (#722): the Fill takes Flat or Fade. New exports `BOX_FILL_FADES`, `BOX_FILL_FADE_PROP`, `boxFillFadeOf`, `boxFillFadeStyle` (lib/content/box-background); `InheritedColourRow` takes optional `children`; `Flex` reads the optional `fillFade` prop.
16
+
17
+ ### Changed
18
+
19
+ - **A Mark Box takes no Fill when a host gives none** (#724): `markBoxProps(size, fill?, look?)`. With no Fill, the props have no `fillColor` key.
20
+
3
21
  ## 67.5.0 - 2026-11-11
4
22
 
5
23
  From main at `bd876886`: #718, #719, #720. A minor: no `!`, no export is removed, the peers stay `efficient-easel` `^34.1.0` and `efficient-shell` `^12.33.0`. New exports, one widened type and optional props only. No stored key or value moves.
@@ -2873,8 +2873,10 @@
2873
2873
  color: var(--sf-muted);
2874
2874
  }
2875
2875
 
2876
+ /* Under the swatch and the hex, in the colour row's one column
2877
+ (lib/document/ColourControl `ColourRow`): the column's gap (8) is the
2878
+ space above it. */
2876
2879
  .sf-readability {
2877
- margin-top: var(--space-12);
2878
2880
  padding: var(--space-12) var(--space-12) var(--space-12);
2879
2881
  border: 1px solid var(--sf-divider);
2880
2882
  border-radius: var(--sf-row-radius);
@@ -25,7 +25,7 @@ export declare function ColourRow({ label, icon, changed, hint, onReset, resetTo
25
25
  resetTo?: string;
26
26
  children?: ReactNode;
27
27
  }): import("react").JSX.Element;
28
- export declare function InheritedColourRow({ label, icon, value, inherited, resetTo, onChange, onReset, hint, choices, }: {
28
+ export declare function InheritedColourRow({ label, icon, value, inherited, resetTo, onChange, onReset, hint, choices, children, }: {
29
29
  label: string;
30
30
  icon?: ReactElement;
31
31
  value: string;
@@ -35,4 +35,5 @@ export declare function InheritedColourRow({ label, icon, value, inherited, rese
35
35
  onReset: () => void;
36
36
  hint?: ReactNode;
37
37
  choices?: readonly ColourChoice[];
38
+ children?: ReactNode;
38
39
  }): import("react").JSX.Element;
@@ -1 +1 @@
1
- "use client";import{jsx as r,jsxs as m}from"react/jsx-runtime";import{useRef as C}from"react";import{ColorPicker as w,ColorPickerPanel as x,ColorSwatch as b,HexInput as S,Popover as N,Tooltip as P,colorFill as k,colorSwatchClasses as T,useShellStrings as E}from"efficient-shell/ui";import{SettingsDefaultReset as R,SettingsField as _}from"efficient-easel/panel";import{typedHex as p}from"efficient-easel/pick";import{usePreviewHeader as j}from"../../../render/components/PreviewHeaderContext.js";import{editorEaselWords as F,say as g}from"../../../format/lib/editor-words.js";import{themePresets as I}from"../../../format/lib/document/theme-slots.js";import{SITE_STYLE_UNSET_LABEL as L}from"../../../format/components/SiteStyleUnset.js";function y({value:e,onChange:i,label:o,id:a,caption:s,inherited:c,ariaLabel:t,choices:n}){return r(B,{value:e,onChange:i,label:g(t??o),id:a,caption:s,inherited:c,choices:n})}function z(){const{theme:e}=j();return I(e)}function B({value:e,onChange:i,label:o,id:a,caption:s,inherited:c,choices:t}){const n=z(),l=e?null:p(c??""),d=s!==void 0&&(!e||p(s)!==p(e))?s:null,f=h=>{h!==e&&i(h)};return m("div",{className:"sf-colour",children:[t?r(H,{id:a,value:e,onChange:i,label:o,presets:n,follows:l,choices:t}):r(w,{id:a,value:e,onChange:f,label:o,presets:n,fallback:l??void 0,size:"md",align:"start"}),d!==null?r("span",{className:"sf-colour-caption",children:d}):r("span",{className:"sf-colour-hexwrap",children:r(S,{value:e||l||"",onChange:f,label:g("{label} hex code",{label:o}),placeholder:e||l?void 0:g(L),className:l?"sf-colour-hex is-inherited":"sf-colour-hex",size:"md"})})]})}function H({value:e,onChange:i,label:o,id:a,presets:s,follows:c,choices:t}){const n=E().color,l=e||c||"",d=t.findIndex(u=>u.selected),f=d>=0,h=C(d);return f&&(h.current=d),r(N,{id:a,trigger:r("span",{"aria-hidden":"true",className:"absolute inset-0",style:k(l)}),triggerLabel:n.swatch(o,l.toUpperCase()||n.none),triggerClassName:T({size:"md"}),"aria-label":n.panel(o),align:"start",children:m("div",{className:"sf-colour-window",children:[r("div",{role:"group","aria-label":o,className:"sf-colour-choices",children:t.map(u=>r(P,{content:u.label,children:r(b,{color:u.color,"aria-label":u.label,selected:u.selected,onClick:()=>{u.selected||u.onPick()}})},u.label))}),r(x,{value:f?"":e,onChange:i,label:o,presets:s,fallback:(f?l:c)??void 0},h.current)]})})}function W({label:e,icon:i,changed:o,hint:a,onReset:s,resetTo:c,children:t,...n}){return m(_,{label:e,icon:i,htmlFor:n.id,changed:o,hint:a,action:s?r(R,{words:F()?.panel,label:e,changed:!!o,detail:c,onReset:s}):void 0,children:[y({...n,label:e}),t]})}function M({label:e,icon:i,value:o,inherited:a,resetTo:s,onChange:c,onReset:t,hint:n,choices:l}){const d=!!o;return r(W,{label:e,icon:i,value:o,inherited:d?void 0:a,onChange:c,changed:d,onReset:t,resetTo:s,hint:n,choices:l})}export{y as ColourControl,W as ColourRow,M as InheritedColourRow,z as useThemePresets};
1
+ "use client";import{jsx as r,jsxs as m}from"react/jsx-runtime";import{useRef as w}from"react";import{ColorPicker as x,ColorPickerPanel as b,ColorSwatch as N,HexInput as S,Popover as P,Tooltip as k,colorFill as T,colorSwatchClasses as E,useShellStrings as R}from"efficient-shell/ui";import{SettingsDefaultReset as _,SettingsField as j}from"efficient-easel/panel";import{typedHex as p}from"efficient-easel/pick";import{usePreviewHeader as F}from"../../../render/components/PreviewHeaderContext.js";import{editorEaselWords as I,say as g}from"../../../format/lib/editor-words.js";import{themePresets as L}from"../../../format/lib/document/theme-slots.js";import{SITE_STYLE_UNSET_LABEL as v}from"../../../format/components/SiteStyleUnset.js";function C({value:e,onChange:i,label:o,id:a,caption:s,inherited:c,ariaLabel:t,choices:n}){return r(z,{value:e,onChange:i,label:g(t??o),id:a,caption:s,inherited:c,choices:n})}function y(){const{theme:e}=F();return L(e)}function z({value:e,onChange:i,label:o,id:a,caption:s,inherited:c,choices:t}){const n=y(),l=e?null:p(c??""),f=s!==void 0&&(!e||p(s)!==p(e))?s:null,d=h=>{h!==e&&i(h)};return m("div",{className:"sf-colour",children:[t?r(B,{id:a,value:e,onChange:i,label:o,presets:n,follows:l,choices:t}):r(x,{id:a,value:e,onChange:d,label:o,presets:n,fallback:l??void 0,size:"md",align:"start"}),f!==null?r("span",{className:"sf-colour-caption",children:f}):r("span",{className:"sf-colour-hexwrap",children:r(S,{value:e||l||"",onChange:d,label:g("{label} hex code",{label:o}),placeholder:e||l?void 0:g(v),className:l?"sf-colour-hex is-inherited":"sf-colour-hex",size:"md"})})]})}function B({value:e,onChange:i,label:o,id:a,presets:s,follows:c,choices:t}){const n=R().color,l=e||c||"",f=t.findIndex(u=>u.selected),d=f>=0,h=w(f);return d&&(h.current=f),r(P,{id:a,trigger:r("span",{"aria-hidden":"true",className:"absolute inset-0",style:T(l)}),triggerLabel:n.swatch(o,l.toUpperCase()||n.none),triggerClassName:E({size:"md"}),"aria-label":n.panel(o),align:"start",children:m("div",{className:"sf-colour-window",children:[r("div",{role:"group","aria-label":o,className:"sf-colour-choices",children:t.map(u=>r(k,{content:u.label,children:r(N,{color:u.color,"aria-label":u.label,selected:u.selected,onClick:()=>{u.selected||u.onPick()}})},u.label))}),r(b,{value:d?"":e,onChange:i,label:o,presets:s,fallback:(d?l:c)??void 0},h.current)]})})}function H({label:e,icon:i,changed:o,hint:a,onReset:s,resetTo:c,children:t,...n}){return r(j,{label:e,icon:i,htmlFor:n.id,changed:o,hint:a,action:s?r(_,{words:I()?.panel,label:e,changed:!!o,detail:c,onReset:s}):void 0,children:t?m("div",{className:"es-width-stack",children:[C({...n,label:e}),t]}):C({...n,label:e})})}function M({label:e,icon:i,value:o,inherited:a,resetTo:s,onChange:c,onReset:t,hint:n,choices:l,children:f}){const d=!!o;return r(H,{label:e,icon:i,value:o,inherited:d?void 0:a,onChange:c,changed:d,onReset:t,resetTo:s,hint:n,choices:l,children:f})}export{C as ColourControl,H as ColourRow,M as InheritedColourRow,y as useThemePresets};
@@ -1 +1 @@
1
- import{jsx as r}from"react/jsx-runtime";import{phoneKey as i,tabletKey as l}from"efficient-easel/draw";import{BOX_CARD_PAD as E,BOX_SWATCH_PROP as ko,boxCardProps as Ho,boxIsCard as L}from"../../../../../../format/lib/content/box-background.js";import{BOX_IS_CARD_RULE as Fo,BOX_IS_NOT_CARD_RULE as Wo,BOX_ROW_IMAGE_PROP as yo}from"../../../../../../format/lib/content/box-card-rule.js";import{CARD_ROW_FACTS as Bo,cardRowField as M,cardRowFields as xo,cardRowLinkField as Uo,typedLinkField as Mo}from"../../../card-row-fields.js";import{CARD_ROW_LINK_PROP as Ko,cardCopyPlace as K,cardTemplateCardOwner as Xo}from"../../../../../../format/lib/content/card-template.js";import{BOX_SHOW_KEY as Go,HOVER_GROUP_KEY as Yo,HOVER_KEY as T}from"../../../../../../format/lib/animation/hover.js";import{BOX_HIGHLIGHT_ROW as vo,BOX_NEXT_PICTURE_ROW as jo}from"../../../../animation/hover-fields.js";import{darkenFields as Vo}from"../../../darken-fields.js";import{BOX_TAB_SHAPES as Jo,REEL_SHAPE_LABELS as zo}from"../../../../../../format/lib/reel.js";import{LAYOUT_CELL as X,CARD_LIST_STYLE_PICTURES as qo,TAB_SHAPE_PICTURES as Qo}from"../../../choice-pictures.js";import{CARD_STYLE_KEY as A,CARD_STYLE_POINTS as Zo,applyCardStyle as $o,isCardStyle as oe}from"../../../../../../render/lib/sections/card-list-style.js";import{deviceField as a}from"efficient-easel/screen/lib/document/device-fields";import{ChevronDownIcon as ee,ClockIcon as ne,CropIcon as G,GapIcon as te,MediaLayoutStackedIcon as Y,LineBetweenIcon as re,LineSolidIcon as ie,ListIcon as le,NumberedListIcon as v,ShadowIcon as ae,StylesIcon as j,TableIcon as V,TargetIcon as se,WrapIcon as J}from"efficient-easel/icons";import{boxBlockSpacingField as de,boxFillField as ce,boxColumnsFields as _e,boxShareField as pe,boxSharePhoneField as Oe,boxShareTabletField as Se,containerDirectionField as me,containerGapRows as fe,linkField as Re,plainText as he,swapPadding as z,toggle as c,upload as q,withPanelOnly as ue}from"../../../controls.js";import{BOX_STACK_LINE as g,BOX_STACK_RANGE as R,STACK_BELOW_PROP as N}from"../../../../../../render/lib/content/box-stack-line.js";import{BOX_SHAPES as Q,boxShapeOf as Ce}from"../../../../../../format/lib/content/box-shape.js";import{BOX_ANGLE_PROP as Ae}from"../../../../../../format/lib/content/box-angle.js";import{shapeLines as Z}from"../../../../../../format/lib/content/gallery-card-layout.js";import{shapePickerRow as $}from"../../../shape-picker.js";import{ACCORDION_COLUMN_COUNTS as we,ACCORDION_PHONE_COLUMN_COUNTS as Ee,BOX_COLUMNS_MAX as b,BOX_COLUMNS_MIN as P,boxPhoneRowOneLine as Te,boxWrapWordOf as oo}from"../../../../../../format/lib/content/box-layout.js";import{BOX_SEPARATOR_POINTS as eo}from"../../../../../../format/lib/content/box-separator.js";import{BOX_WRAP_LABEL as no,VIEW_KEY_ACCESS as s,group as h,phoneTwinFields as d}from"efficient-easel/screen/lib/document/box-fields";import{angleRow as Ne,boxAlignField as De,boxJustifyField as Ie,boxWrapField as D,iconPickerRow as k,placementField as Le,select as H,sidesPaddingFields as to,slider as ro}from"../../../box-fields.js";import{withRowRules as ge,withShowWhen as F}from"../../../../../../render/lib/document/show-when.js";import{separatorField as be}from"../../../separator-field.js";import{LOOP_SCROLLS as Pe}from"../../../../../../format/lib/animation/index.js";import{DEFAULT_TICKER_JOIN as ke,TICKER_JOIN_OPTIONS as He}from"../../../../../../format/lib/sections/ticker-join.js";import{NOT_HELD_BY_A_NODE as io}from"../../../../../../format/lib/document/passes/document-position.js";import{BOX_SIDE_SPACE_PROP as lo}from"../../../../../../format/lib/content/box-side-space.js";import{boxSideSpaceField as Fe}from"../../../box-side-space-field.js";import{accordionOnSet as We}from"../../../box-accordion-seed.js";import{ACCORDION_ROW_STYLE_POINTS as ye,ACCORDION_ROW_STYLE_PROP as I}from"../../../../../../format/lib/content/accordion-row-style.js";import{FlexSlots as ao}from"../../../../../../format/lib/document/blocks/general/Flex/meta.js";import{BOX_TYPE as Be,CONTAINER_BLOCKS_SLOT as xe}from"../../../../../../format/lib/document/container-blocks.js";import{boxPhoneOrderField as Ue}from"../../../box-phone-order-field.js";import{CARD_BOX_FACTS as Me,ON_A_CARD as so,ON_A_PICTURE_OR_CARD as Ke,cardDisplayField as W}from"../../../card-display-chips.js";import{MIRROR_CARDS_FACTS as Xe,MIRROR_CARDS_MIRRORS as Ge,mirrorCardsField as Ye}from"../../../mirror-cards-field.js";import{handedRowOf as co}from"../../../../../../format/lib/document/row-hand.js";import{SHOW_FOR_FACTS as ve,showForField as je,showForFields as Ve}from"../../../show-for-field.js";import{SHARED_COLUMNS_KEY as u,SHARED_COLUMNS_LABEL as _o,SHARED_COLUMNS_OFF as po,sharedColumnsDrawn as Oo,sharedColumnsFits as So,SHARED_COLUMNS_PHONE_POINTS as Je,SHARED_COLUMNS_POINTS as ze,sharedRowsDrawn as qe}from"../../../../../../render/lib/content/box-shared-columns.js";const mo=Fo,fo={all:[{field:"phoneRow",in:[2,3]},{not:{field:"direction",is:"accordion"}}]},Qe={field:"direction",is:"tabs"},Ze={field:"line",in:[!0,!1]},$e={field:"anchor",set:!0},y=["fixed","screen","fill"],on={not:{any:[{field:"sectionHeightMode",in:y},{field:"sectionHeightModeTablet",in:y},{field:"sectionHeightModePhone",in:y}]}},en={context:"parent.line",is:!0},_={not:{field:"direction",is:"accordion"}},Ro={field:"direction",is:"accordion"},ho={any:[_,{not:{field:I,in:["numbered","chevron"]}},{field:"columns",in:[...we]},{field:"phoneRow",in:[...Ee]}]},uo="notAccordionRow",nn={not:{context:uo,is:!0}},tn={[uo]:(o,e)=>e.parent?.props?.direction!=="accordion"},B={field:"direction",is:"row",default:"row"},p={not:Pe},O={all:[B,p,{not:{field:"separator",in:eo.map(o=>o.value)}},{not:{field:"line",is:!0}}]},rn={field:"direction",is:"column"},Co={all:[O,...["columns",l("columns")].map(o=>({not:{field:o,in:Array.from({length:b},(e,n)=>n+P)}}))]},ln={all:[p,{not:{all:[B,{field:"separator",in:eo.map(o=>o.value)}]}}]},x={not:{all:[O,{field:"columns",in:Array.from({length:b},(o,e)=>e+P)}]}},an="sharedColumnsFits",Ao="sharedColumnsMisfit",wo="sharedColumnsDraws",Eo="sharedColumnsPhoneDraws";function S(o,e){return Ho(o.props??{},K(e.appState,o.props?.id)?.inCopy!==!1)}const sn={[an]:(o,e)=>So(S(o,e)),[Ao]:(o,e)=>!So(S(o,e)),[wo]:(o,e)=>Oo(S(o,e)).desktop,[Eo]:(o,e)=>Oo(S(o,e)).phone};function To(o){return{all:[{not:{context:Ao,is:!0}},{any:[so,{field:o,set:!0}]}]}}const m={not:{context:wo,is:!0}},C={not:{context:Eo,is:!0}},No="sharedRowsDraws",dn={[No]:(o,e)=>qe(S(o,e))&&co(e.appState,o.props?.id)?.row===void 0},w={not:{context:No,is:!0}},cn={any:[m,C]},U=Wo,_n={not:{context:Ge,is:!0}},Do="rowHanded",pn={not:{context:Do,is:!0}},On={[Do]:(o,e)=>{const n=co(e.appState,o.props?.id);return n===void 0?void 0:n?.row!==void 0}},Io={all:[_,U,m,C,_n]},Sn={field:"direction",is:"row"},mn={field:"align",in:["start","center","end"]},fn={all:[{field:"darken",set:!0},{not:{field:"darken",in:[0,"0"]}}]};function Rn(){const{darken:o,darkenStyle:e}=Vo();return{...d("darken",o,s),...d("darkenStyle",e,s)}}const Lo={not:{all:[O,{field:l("columns"),in:Array.from({length:b},(o,e)=>e+P)}]}};function hn(){const o=c(no,!1,r(J,{})),e=n=>{const t=oo(n);return t===void 0?void 0:t==="wrap"};return{...D(),render:n=>o.render({...n,value:e(n.value),follows:e(n.follows)??!1,onChange:t=>n.onChange(t===void 0?void 0:t?"wrap":"nowrap")})}}function un(){const o=c(no,!0,r(J,{})),e=n=>{const t=oo(n);return t===void 0?void 0:t==="wrap"};return{...D(),render:n=>{const t=n.followsView==="tablet";return o.render({...n,value:e(n.value),follows:!Te(void 0,t?n.follows:void 0),followsNoView:!t,onChange:f=>n.onChange(f===void 0?void 0:f?"wrap":"nowrap")})}}}const go={hint:g},bo={all:[U,{any:[rn,{all:[O,Lo,{not:{all:[Co,{field:l("share"),set:!0}]}}]}]}]},Cn=F(a("desktop",ro("Narrows below",r(Y,{}),R.min,R.max,R.step,g,{kind:"breakpoint"},{clear:go,hint:"Under this screen width the side space narrows and the Phone Padding is used."})),bo);function An(o,e){const n=o;return!(N in n)||e.direction!=="column"?o:{...n,[N]:Cn}}const St={fields:ge({_gContent:h("Content"),rowTitle:ao.rowTitle,content:ao.content,_gCardDisplay:h("Display"),cardDisplay:W("desktop"),cardDisplayTablet:W("tablet"),cardDisplayPhone:W("mobile"),showFor:je(),_gLayout:h("Layout"),direction:me("Flex"),tabShape:k("Tab shape",r(j,{}),Jo.map(o=>({label:zo[o],value:o,picture:Qo[o]})),"tabs",{columns:2,cell:X}),mirrorCards:Ye(),[N]:a("desktop",ro("Stacks below",r(Y,{}),R.min,R.max,R.step,g,{kind:"breakpoint"},{clear:go,hint:"Under this screen width the blocks stand one under another, with the Phone Gap and Padding."})),[lo]:Fe(),startsOpen:a("desktop",c("Starts open",!1,r(ee,{}))),[I]:a("desktop",k("Row style",r(v,{}),ye.map(o=>({...o,picture:o.value==="numbered"?r(v,{}):r(le,{})})),"plain",{columns:2})),label:ue(he("Tab name")),...fe("Flex"),...d("justify",Ie(),s),...d("align",De(),s),...(()=>{const o=d("wrap",D(),s,{phoneRow:un()}),e=d("wrap",D(),s,{phoneRow:hn()});return{wrap:e.wrap,[l("wrap")]:e[l("wrap")],[i("wrap")]:o[i("wrap")]}})(),[i("order")]:Ue(),...d("boxShape",$("Box shape",r(G,{}),Z(Q),"shape","auto"),s,{phoneRow:$("Box shape",r(G,{}),Z(Q),"shape","auto",{phoneRest:o=>Ce(o)})}),[Ae]:a("desktop",Ne(0,{clear:{hint:0},hint:"Turns the box. 0° is straight."})),separator:be(r(re,{size:18}),"none"),[A]:a("desktop",k("Card style",r(j,{}),Zo.map(o=>({...o,picture:qo[o.value]})),"table",{columns:2,cell:X})),share:a("desktop",pe()),[l("share")]:Se(),[i("share")]:Oe(),[u]:a("desktop",H(_o,r(V,{}),[...ze],po)),[i(u)]:a("mobile",H(_o,r(V,{}),[...Je],po)),..._e(),...d("blockSpacing",de(),s),line:c("Line",!1,r(ie,{}),"A line across the blocks, with a dot on each."),upcoming:c("Upcoming",!1,r(ne,{}),"Still to come: a hollow dot, and the gold line stops before it."),join:H("Join",r(te,{}),He,ke),_gShadow:h("Shadow"),...d("shadow",c("Shadow",!1,r(ae,{})),s),...d("fillColor",ce(),s),[ko]:M("Fill content","colour"),_gBackground:h("Background image"),bgImage:a("desktop",q("Image","image/*")),bgImagePhone:a("mobile",q("Image","image/*")),[yo]:M("Image content","image",{content:!0}),...Rn(),placement:Le("Content position"),_gLink:h("Link"),link:Mo(Re("Link to")),[Ko]:Uo(),jumpHighlight:c("Highlight when a link jumps here",!1,r(se,{}),"When a link lands on this Box's anchor, the Box gets a main color outline and its first block turns the main color.")},[[["darken","darkenStyle","placement"],mo],[[i("share")],{all:[fo,C]}],[[u],To(u)],[[i(u)],To(i(u))],[[i("wrap")],{all:[fo,p,C,w]}],[[i("order")],{all:[O,C,m]}],[["phoneRow"],C],[[I],{all:[Ro,{not:{field:I,is:"chevron"}}]}],[["tabShape"],Qe],[["rowTitle","startsOpen"],nn],[["align","blockSpacing",l("blockSpacing"),i("blockSpacing")],_],[[l("justify"),i("justify")],{all:[p,Io,w]}],[[l("align"),i("align")],{all:[Sn,mn,Io]}],[[l("wrap")],{all:[p,x,Lo,m,_,w]}],[[l("shadow"),i("shadow")],U],[[l("darken"),i("darken"),l("darkenStyle"),i("darkenStyle")],{all:[mo,fn]}],[["separator"],B],[[A],{field:A,set:!0}],[["columns"],{any:[O,Ro]}],[[l("columns")],O],[[N],bo],[[l("gap")],{all:[ln,ho]}],[["gap",i("gap")],ho],[["justify"],{all:[p,cn,_,w]}],[["wrap"],{all:[p,x,m,_,w]}],[["share"],{all:[x,m,_]}],[[l("share")],{all:[Co,m]}],[["line"],Ze],[["upcoming"],en],[["jumpHighlight"],$e],[["boxShape",l("boxShape"),i("boxShape")],on],[["direction","share",i("order")],pn],[["join"],io],[[lo],io]]),resolveData:(o,e)=>{const n=o.props,t=n[A];return e.changed?.[A]===!0&&oe(t)?{...o,props:$o(n,t,Be,xe)}:n.direction==="accordion"&&(e.trigger==="insert"||e.changed?.direction===!0)?{...o,props:We(n)}:o},resolveFields:(o,e)=>{const n=K(e.appState,o.props?.id)?.inCopy===!0,t=n&&Xo(e.appState,o.props?.id)===null;return An(Tn(Nn(Ve(Dn(o,{...e,fields:xo(e.fields,o,e)}),o.props),S(o,e),n),t),o.props)},showWhenFacts:{...Bo,...Me,...Xe,...On,...sn,...dn,...ve,...tn}},wn=F(vo,so),En=["darken","darkenStyle",Yo,Go];function Tn(o,e){if(!e)return o;const n={...o};for(const t of En){if(!(t in n))continue;const{showWhen:f,...Po}=n[t];n[t]=Po}return n}function Nn(o,e,n=!1){const t=o;return T in t&&L(e)&&n?{...t,[T]:F(jo,Ke)}:!(T in t)||L(e)?o:{...t,[T]:wn}}function Dn(...[o,e]){const{fields:n}=e;{if(L(S(o,e))){const f=to({fallback:{top:E.desktop,bottom:E.desktop,left:E.side,right:E.side},tablet:!0,siteSide:!0});return z(n,f)}return o.props.padV2!==!0?z(n,to({fallback:{top:24,bottom:24},tablet:!0,siteSide:!0})):n}}export{St as FlexFields};
1
+ import{jsx as r}from"react/jsx-runtime";import{phoneKey as i,tabletKey as l}from"efficient-easel/draw";import{keptByRow as ko}from"efficient-easel/screen/lib/document/style-fields";import{BOX_CARD_PAD as E,BOX_FILL_FADE_PROP as Fo,BOX_SWATCH_PROP as Ho,boxCardProps as Wo,boxIsCard as I}from"../../../../../../format/lib/content/box-background.js";import{BOX_IS_CARD_RULE as yo,BOX_IS_NOT_CARD_RULE as Bo,BOX_ROW_IMAGE_PROP as xo}from"../../../../../../format/lib/content/box-card-rule.js";import{CARD_ROW_FACTS as Uo,cardRowField as M,cardRowFields as Mo,cardRowLinkField as Ko,typedLinkField as Xo}from"../../../card-row-fields.js";import{CARD_ROW_LINK_PROP as Go,cardCopyPlace as K,cardTemplateCardOwner as Yo}from"../../../../../../format/lib/content/card-template.js";import{BOX_SHOW_KEY as vo,HOVER_GROUP_KEY as jo,HOVER_KEY as T}from"../../../../../../format/lib/animation/hover.js";import{BOX_HIGHLIGHT_ROW as Vo,BOX_NEXT_PICTURE_ROW as Jo}from"../../../../animation/hover-fields.js";import{darkenFields as zo}from"../../../darken-fields.js";import{BOX_TAB_SHAPES as qo,REEL_SHAPE_LABELS as Qo}from"../../../../../../format/lib/reel.js";import{LAYOUT_CELL as X,CARD_LIST_STYLE_PICTURES as Zo,TAB_SHAPE_PICTURES as $o}from"../../../choice-pictures.js";import{CARD_STYLE_KEY as A,CARD_STYLE_POINTS as oe,applyCardStyle as ee,isCardStyle as ne}from"../../../../../../render/lib/sections/card-list-style.js";import{deviceField as a}from"efficient-easel/screen/lib/document/device-fields";import{ChevronDownIcon as te,ClockIcon as re,CropIcon as G,GapIcon as ie,MediaLayoutStackedIcon as Y,LineBetweenIcon as le,LineSolidIcon as ae,ListIcon as se,NumberedListIcon as v,ShadowIcon as de,StylesIcon as j,TableIcon as V,TargetIcon as ce,WrapIcon as J}from"efficient-easel/icons";import{boxBlockSpacingField as _e,boxFillField as pe,boxColumnsFields as Oe,boxShareField as Se,boxSharePhoneField as me,boxShareTabletField as fe,containerDirectionField as Re,containerGapRows as he,linkField as ue,plainText as Ce,swapPadding as z,toggle as c,upload as q,withPanelOnly as Ae}from"../../../controls.js";import{BOX_STACK_LINE as g,BOX_STACK_RANGE as R,STACK_BELOW_PROP as N}from"../../../../../../render/lib/content/box-stack-line.js";import{BOX_SHAPES as Q,boxShapeOf as we}from"../../../../../../format/lib/content/box-shape.js";import{BOX_ANGLE_PROP as Ee}from"../../../../../../format/lib/content/box-angle.js";import{shapeLines as Z}from"../../../../../../format/lib/content/gallery-card-layout.js";import{shapePickerRow as $}from"../../../shape-picker.js";import{ACCORDION_COLUMN_COUNTS as Te,ACCORDION_PHONE_COLUMN_COUNTS as Ne,BOX_COLUMNS_MAX as P,BOX_COLUMNS_MIN as b,boxPhoneRowOneLine as De,boxWrapWordOf as oo}from"../../../../../../format/lib/content/box-layout.js";import{BOX_SEPARATOR_POINTS as eo}from"../../../../../../format/lib/content/box-separator.js";import{BOX_WRAP_LABEL as no,VIEW_KEY_ACCESS as s,group as h,phoneTwinFields as d}from"efficient-easel/screen/lib/document/box-fields";import{angleRow as Le,boxAlignField as Ie,boxJustifyField as ge,boxWrapField as D,iconPickerRow as k,placementField as Pe,select as F,sidesPaddingFields as to,slider as ro}from"../../../box-fields.js";import{withRowRules as be,withShowWhen as H}from"../../../../../../render/lib/document/show-when.js";import{separatorField as ke}from"../../../separator-field.js";import{LOOP_SCROLLS as Fe}from"../../../../../../format/lib/animation/index.js";import{DEFAULT_TICKER_JOIN as He,TICKER_JOIN_OPTIONS as We}from"../../../../../../format/lib/sections/ticker-join.js";import{NOT_HELD_BY_A_NODE as io}from"../../../../../../format/lib/document/passes/document-position.js";import{BOX_SIDE_SPACE_PROP as lo}from"../../../../../../format/lib/content/box-side-space.js";import{boxSideSpaceField as ye}from"../../../box-side-space-field.js";import{accordionOnSet as Be}from"../../../box-accordion-seed.js";import{ACCORDION_ROW_STYLE_POINTS as xe,ACCORDION_ROW_STYLE_PROP as L}from"../../../../../../format/lib/content/accordion-row-style.js";import{FlexSlots as ao}from"../../../../../../format/lib/document/blocks/general/Flex/meta.js";import{BOX_TYPE as Ue,CONTAINER_BLOCKS_SLOT as Me}from"../../../../../../format/lib/document/container-blocks.js";import{boxPhoneOrderField as Ke}from"../../../box-phone-order-field.js";import{CARD_BOX_FACTS as Xe,ON_A_CARD as so,ON_A_PICTURE_OR_CARD as Ge,cardDisplayField as W}from"../../../card-display-chips.js";import{MIRROR_CARDS_FACTS as Ye,MIRROR_CARDS_MIRRORS as ve,mirrorCardsField as je}from"../../../mirror-cards-field.js";import{handedRowOf as co}from"../../../../../../format/lib/document/row-hand.js";import{SHOW_FOR_FACTS as Ve,showForField as Je,showForFields as ze}from"../../../show-for-field.js";import{SHARED_COLUMNS_KEY as u,SHARED_COLUMNS_LABEL as _o,SHARED_COLUMNS_OFF as po,sharedColumnsDrawn as Oo,sharedColumnsFits as So,SHARED_COLUMNS_PHONE_POINTS as qe,SHARED_COLUMNS_POINTS as Qe,sharedRowsDrawn as Ze}from"../../../../../../render/lib/content/box-shared-columns.js";const mo=yo,fo={all:[{field:"phoneRow",in:[2,3]},{not:{field:"direction",is:"accordion"}}]},$e={field:"direction",is:"tabs"},on={field:"line",in:[!0,!1]},en={field:"anchor",set:!0},y=["fixed","screen","fill"],nn={not:{any:[{field:"sectionHeightMode",in:y},{field:"sectionHeightModeTablet",in:y},{field:"sectionHeightModePhone",in:y}]}},tn={context:"parent.line",is:!0},_={not:{field:"direction",is:"accordion"}},Ro={field:"direction",is:"accordion"},ho={any:[_,{not:{field:L,in:["numbered","chevron"]}},{field:"columns",in:[...Te]},{field:"phoneRow",in:[...Ne]}]},uo="notAccordionRow",rn={not:{context:uo,is:!0}},ln={[uo]:(o,e)=>e.parent?.props?.direction!=="accordion"},B={field:"direction",is:"row",default:"row"},p={not:Fe},O={all:[B,p,{not:{field:"separator",in:eo.map(o=>o.value)}},{not:{field:"line",is:!0}}]},an={field:"direction",is:"column"},Co={all:[O,...["columns",l("columns")].map(o=>({not:{field:o,in:Array.from({length:P},(e,n)=>n+b)}}))]},sn={all:[p,{not:{all:[B,{field:"separator",in:eo.map(o=>o.value)}]}}]},x={not:{all:[O,{field:"columns",in:Array.from({length:P},(o,e)=>e+b)}]}},dn="sharedColumnsFits",Ao="sharedColumnsMisfit",wo="sharedColumnsDraws",Eo="sharedColumnsPhoneDraws";function S(o,e){return Wo(o.props??{},K(e.appState,o.props?.id)?.inCopy!==!1)}const cn={[dn]:(o,e)=>So(S(o,e)),[Ao]:(o,e)=>!So(S(o,e)),[wo]:(o,e)=>Oo(S(o,e)).desktop,[Eo]:(o,e)=>Oo(S(o,e)).phone};function To(o){return{all:[{not:{context:Ao,is:!0}},{any:[so,{field:o,set:!0}]}]}}const m={not:{context:wo,is:!0}},C={not:{context:Eo,is:!0}},No="sharedRowsDraws",_n={[No]:(o,e)=>Ze(S(o,e))&&co(e.appState,o.props?.id)?.row===void 0},w={not:{context:No,is:!0}},pn={any:[m,C]},U=Bo,On={not:{context:ve,is:!0}},Do="rowHanded",Sn={not:{context:Do,is:!0}},mn={[Do]:(o,e)=>{const n=co(e.appState,o.props?.id);return n===void 0?void 0:n?.row!==void 0}},Lo={all:[_,U,m,C,On]},fn={field:"direction",is:"row"},Rn={field:"align",in:["start","center","end"]},hn={all:[{field:"darken",set:!0},{not:{field:"darken",in:[0,"0"]}}]};function un(){const{darken:o,darkenStyle:e}=zo();return{...d("darken",o,s),...d("darkenStyle",e,s)}}const Io={not:{all:[O,{field:l("columns"),in:Array.from({length:P},(o,e)=>e+b)}]}};function Cn(){const o=c(no,!1,r(J,{})),e=n=>{const t=oo(n);return t===void 0?void 0:t==="wrap"};return{...D(),render:n=>o.render({...n,value:e(n.value),follows:e(n.follows)??!1,onChange:t=>n.onChange(t===void 0?void 0:t?"wrap":"nowrap")})}}function An(){const o=c(no,!0,r(J,{})),e=n=>{const t=oo(n);return t===void 0?void 0:t==="wrap"};return{...D(),render:n=>{const t=n.followsView==="tablet";return o.render({...n,value:e(n.value),follows:!De(void 0,t?n.follows:void 0),followsNoView:!t,onChange:f=>n.onChange(f===void 0?void 0:f?"wrap":"nowrap")})}}}const go={hint:g},Po={all:[U,{any:[an,{all:[O,Io,{not:{all:[Co,{field:l("share"),set:!0}]}}]}]}]},wn=H(a("desktop",ro("Narrows below",r(Y,{}),R.min,R.max,R.step,g,{kind:"breakpoint"},{clear:go,hint:"Under this screen width the side space narrows and the Phone Padding is used."})),Po);function En(o,e){const n=o;return!(N in n)||e.direction!=="column"?o:{...n,[N]:wn}}const Rt={fields:be({_gContent:h("Content"),rowTitle:ao.rowTitle,content:ao.content,_gCardDisplay:h("Display"),cardDisplay:W("desktop"),cardDisplayTablet:W("tablet"),cardDisplayPhone:W("mobile"),showFor:Je(),_gLayout:h("Layout"),direction:Re("Flex"),tabShape:k("Tab shape",r(j,{}),qo.map(o=>({label:Qo[o],value:o,picture:$o[o]})),"tabs",{columns:2,cell:X}),mirrorCards:je(),[N]:a("desktop",ro("Stacks below",r(Y,{}),R.min,R.max,R.step,g,{kind:"breakpoint"},{clear:go,hint:"Under this screen width the blocks stand one under another, with the Phone Gap and Padding."})),[lo]:ye(),startsOpen:a("desktop",c("Starts open",!1,r(te,{}))),[L]:a("desktop",k("Row style",r(v,{}),xe.map(o=>({...o,picture:o.value==="numbered"?r(v,{}):r(se,{})})),"plain",{columns:2})),label:Ae(Ce("Tab name")),...he("Flex"),...d("justify",ge(),s),...d("align",Ie(),s),...(()=>{const o=d("wrap",D(),s,{phoneRow:An()}),e=d("wrap",D(),s,{phoneRow:Cn()});return{wrap:e.wrap,[l("wrap")]:e[l("wrap")],[i("wrap")]:o[i("wrap")]}})(),[i("order")]:Ke(),...d("boxShape",$("Box shape",r(G,{}),Z(Q),"shape","auto"),s,{phoneRow:$("Box shape",r(G,{}),Z(Q),"shape","auto",{phoneRest:o=>we(o)})}),[Ee]:a("desktop",Le(0,{clear:{hint:0},hint:"Turns the box. 0° is straight."})),separator:ke(r(le,{size:18}),"none"),[A]:a("desktop",k("Card style",r(j,{}),oe.map(o=>({...o,picture:Zo[o.value]})),"table",{columns:2,cell:X})),share:a("desktop",Se()),[l("share")]:fe(),[i("share")]:me(),[u]:a("desktop",F(_o,r(V,{}),[...Qe],po)),[i(u)]:a("mobile",F(_o,r(V,{}),[...qe],po)),...Oe(),...d("blockSpacing",_e(),s),line:c("Line",!1,r(ae,{}),"A line across the blocks, with a dot on each."),upcoming:c("Upcoming",!1,r(re,{}),"Still to come: a hollow dot, and the gold line stops before it."),join:F("Join",r(ie,{}),We,He),_gShadow:h("Shadow"),...d("shadow",c("Shadow",!1,r(de,{})),s),...d("fillColor",pe(),s),[Ho]:M("Fill content","colour"),[Fo]:ko("fillColor"),_gBackground:h("Background image"),bgImage:a("desktop",q("Image","image/*")),bgImagePhone:a("mobile",q("Image","image/*")),[xo]:M("Image content","image",{content:!0}),...un(),placement:Pe("Content position"),_gLink:h("Link"),link:Xo(ue("Link to")),[Go]:Ko(),jumpHighlight:c("Highlight when a link jumps here",!1,r(ce,{}),"When a link lands on this Box's anchor, the Box gets a main color outline and its first block turns the main color.")},[[["darken","darkenStyle","placement"],mo],[[i("share")],{all:[fo,C]}],[[u],To(u)],[[i(u)],To(i(u))],[[i("wrap")],{all:[fo,p,C,w]}],[[i("order")],{all:[O,C,m]}],[["phoneRow"],C],[[L],{all:[Ro,{not:{field:L,is:"chevron"}}]}],[["tabShape"],$e],[["rowTitle","startsOpen"],rn],[["align","blockSpacing",l("blockSpacing"),i("blockSpacing")],_],[[l("justify"),i("justify")],{all:[p,Lo,w]}],[[l("align"),i("align")],{all:[fn,Rn,Lo]}],[[l("wrap")],{all:[p,x,Io,m,_,w]}],[[l("shadow"),i("shadow")],U],[[l("darken"),i("darken"),l("darkenStyle"),i("darkenStyle")],{all:[mo,hn]}],[["separator"],B],[[A],{field:A,set:!0}],[["columns"],{any:[O,Ro]}],[[l("columns")],O],[[N],Po],[[l("gap")],{all:[sn,ho]}],[["gap",i("gap")],ho],[["justify"],{all:[p,pn,_,w]}],[["wrap"],{all:[p,x,m,_,w]}],[["share"],{all:[x,m,_]}],[[l("share")],{all:[Co,m]}],[["line"],on],[["upcoming"],tn],[["jumpHighlight"],en],[["boxShape",l("boxShape"),i("boxShape")],nn],[["direction","share",i("order")],Sn],[["join"],io],[[lo],io]]),resolveData:(o,e)=>{const n=o.props,t=n[A];return e.changed?.[A]===!0&&ne(t)?{...o,props:ee(n,t,Ue,Me)}:n.direction==="accordion"&&(e.trigger==="insert"||e.changed?.direction===!0)?{...o,props:Be(n)}:o},resolveFields:(o,e)=>{const n=K(e.appState,o.props?.id)?.inCopy===!0,t=n&&Yo(e.appState,o.props?.id)===null;return En(Dn(Ln(ze(In(o,{...e,fields:Mo(e.fields,o,e)}),o.props),S(o,e),n),t),o.props)},showWhenFacts:{...Uo,...Xe,...Ye,...mn,...cn,..._n,...Ve,...ln}},Tn=H(Vo,so),Nn=["darken","darkenStyle",jo,vo];function Dn(o,e){if(!e)return o;const n={...o};for(const t of Nn){if(!(t in n))continue;const{showWhen:f,...bo}=n[t];n[t]=bo}return n}function Ln(o,e,n=!1){const t=o;return T in t&&I(e)&&n?{...t,[T]:H(Jo,Ge)}:!(T in t)||I(e)?o:{...t,[T]:Tn}}function In(...[o,e]){const{fields:n}=e;{if(I(S(o,e))){const f=to({fallback:{top:E.desktop,bottom:E.desktop,left:E.side,right:E.side},tablet:!0,siteSide:!0});return z(n,f)}return o.props.padV2!==!0?z(n,to({fallback:{top:24,bottom:24},tablet:!0,siteSide:!0})):n}}export{Rt as FlexFields};
@@ -1 +1 @@
1
- import{jsx as e}from"react/jsx-runtime";import{BlockVideoIcon as n,ClockIcon as g,ImageIcon as p,MediaIcon as s,OpacityIcon as u,PlayIcon as v}from"efficient-easel/icons";import{colorInput as f,focusKeptField as o,loadingShowsField as I,MEDIA_TYPE_OPTIONS as y,plainText as _,text as S,upload as a,withIdentifier as O,withPanelOnly as m}from"../../../controls.js";import{group as i}from"efficient-easel/screen/lib/document/box-fields";import{segmented as F,slider as t}from"../../../box-fields.js";import{LOADING_SHOWS_IMAGE as E,VIDEO_PLAYBACK_DEFAULT as T,VIDEO_SOURCE_DEFAULT as l}from"../../../../../../format/lib/hero-video.js";import{HERO_SLIDE_OVERLAY_ROWS as c,HERO_VIDEO_ROWS as d}from"../../hero-shared-fields.js";import{PH as P}from"../../../../../../format/lib/document/blocks/placeholders.js";import{slotNoticeField as b}from"../../shared-fields.js";import{forMediaType as L,heroMediaFields as D,VIDEO_FILE_LABEL as h,VIDEO_FILE_PROMPT as k}from"../../../../../../render/lib/document/hero-media-parts.js";import{DEFAULT_TINT as A}from"../../../../../../format/lib/content/tint.js";import{HeroSlideSlots as C}from"../../../../../../format/lib/document/blocks/general/HeroSlide/meta.js";const r=L("video","video"),G={fields:D({_gContent:i("Content"),name:m(O(_("Slide name",P.slideName))),process:m(S("Reel label","Label")),groupNotice:b("HeroSlide"),groups:C.groups,_gMedia:i("Media"),mediaType:F("Type",e(s,{}),y,"video"),videoSource:d.videoSource,mediaVideo:a(h,"video/*",k,{frame:"videoFrame"}),youtubeUrl:d.youtubeUrl,videoPlayback:d.videoPlayback,videoSpeed:t("Playback speed",e(v,{}),25,100,5,100,"%"),loadingShows:I("Show while loading",e(g,{}),{frame:e(n,{}),image:e(p,{})}),videoFrame:o(),mediaImage:a("Background image","image/*","Upload a background image",{focus:"imageFocal"}),imageFocal:o(),imageFocalTablet:o(),imageFocalPhone:o(),poster:a("Image","image/*","Choose an image"),_gTint:i("Image tint"),tintColor:f("Tint color",A),overlay:t("Tint",e(u,{}),0,100,5,0,"%"),_gOverlay:i("Overlay"),overlayColor:c.overlayColor,overlayPosition:c.overlayPosition},{onlyFor:{image:["mediaImage","imageFocal","imageFocalTablet","imageFocalPhone","_gTint","tintColor","overlay"],video:["videoSource","videoPlayback","loadingShows","videoFrame"]},fallback:"video",rules:{mediaVideo:{all:[r,{field:"videoSource",is:"upload",default:l}]},youtubeUrl:{all:[r,{field:"videoSource",is:"youtube",default:l}]},videoSpeed:{all:[r,{field:"videoSource",is:"upload",default:l},{field:"videoPlayback",is:"background",default:T}]},poster:{all:[{field:"mediaType",is:"video",default:"video"},E]}}})};export{G as HeroSlideFields};
1
+ import{jsx as o}from"react/jsx-runtime";import{BlockVideoIcon as g,ClockIcon as I,ImageIcon as _,MediaIcon as P,OpacityIcon as S,PlayIcon as y}from"efficient-easel/icons";import{colorInput as F,focusKeptField as l,loadingShowsField as E,MEDIA_TYPE_OPTIONS as O,plainText as T,text as h,upload as e,withIdentifier as b,withPanelOnly as t}from"../../../controls.js";import{group as r}from"efficient-easel/screen/lib/document/box-fields";import{segmented as V,slider as n}from"../../../box-fields.js";import{LOADING_SHOWS_IMAGE as p,VIDEO_PLAYBACK_DEFAULT as A,VIDEO_SOURCE_DEFAULT as i}from"../../../../../../format/lib/hero-video.js";import{HERO_SLIDE_OVERLAY_ROWS as v,HERO_VIDEO_ROWS as m}from"../../hero-shared-fields.js";import{PH as L}from"../../../../../../format/lib/document/blocks/placeholders.js";import{slotNoticeField as k}from"../../shared-fields.js";import{AV1_FILE_LABEL as c,AV1_FILE_PROMPT as s,forMediaType as D,heroMediaFields as C,VIDEO_FILE_LABEL as u,VIDEO_FILE_PROMPT as f}from"../../../../../../render/lib/document/hero-media-parts.js";import{deviceField as a}from"efficient-easel/screen/lib/document/device-fields";import{DEFAULT_TINT as M}from"../../../../../../format/lib/content/tint.js";import{HeroSlideSlots as R}from"../../../../../../format/lib/document/blocks/general/HeroSlide/meta.js";const d=D("video","video"),J={fields:C({_gContent:r("Content"),name:t(b(T("Slide name",L.slideName))),process:t(h("Reel label","Label")),groupNotice:k("HeroSlide"),groups:R.groups,_gMedia:r("Media"),mediaType:V("Type",o(P,{}),O,"video"),videoSource:m.videoSource,mediaVideo:a("desktop",e(u,"video/*",f,{frame:"videoFrame"})),mediaVideoPhone:a("mobile",e(u,"video/*",f,{frame:"videoFramePhone"})),videoFramePhone:l(),mediaVideoAv1:a("desktop",e(c,"video/mp4",s)),mediaVideoAv1Phone:a("mobile",e(c,"video/mp4",s)),youtubeUrl:m.youtubeUrl,videoPlayback:m.videoPlayback,videoSpeed:n("Playback speed",o(y,{}),25,100,5,100,"%"),loadingShows:E("Show while loading",o(I,{}),{frame:o(g,{}),image:o(_,{})}),videoFrame:l(),mediaImage:e("Background image","image/*","Upload a background image",{focus:"imageFocal"}),imageFocal:l(),imageFocalTablet:l(),imageFocalPhone:l(),poster:a("desktop",e("Image","image/*","Choose an image")),posterPhone:a("mobile",e("Image","image/*","Choose an image")),_gTint:r("Image tint"),tintColor:F("Tint color",M),overlay:n("Tint",o(S,{}),0,100,5,0,"%"),_gOverlay:r("Overlay"),overlayColor:v.overlayColor,overlayPosition:v.overlayPosition},{onlyFor:{image:["mediaImage","imageFocal","imageFocalTablet","imageFocalPhone","_gTint","tintColor","overlay"],video:["videoSource","videoPlayback","loadingShows","videoFrame"]},fallback:"video",rules:{mediaVideo:{all:[d,{field:"videoSource",is:"upload",default:i}]},mediaVideoPhone:{all:[d,{field:"videoSource",is:"upload",default:i}]},mediaVideoAv1:{all:[d,{field:"videoSource",is:"upload",default:i}]},mediaVideoAv1Phone:{all:[d,{field:"videoSource",is:"upload",default:i}]},youtubeUrl:{all:[d,{field:"videoSource",is:"youtube",default:i}]},videoSpeed:{all:[d,{field:"videoSource",is:"upload",default:i},{field:"videoPlayback",is:"background",default:A}]},poster:{all:[{field:"mediaType",is:"video",default:"video"},p]},posterPhone:{all:[{field:"mediaType",is:"video",default:"video"},p]}}})};export{J as HeroSlideFields};
@@ -1 +1 @@
1
- "use client";import{jsx as i,jsxs as k,Fragment as P}from"react/jsx-runtime";import{cloneElement as ge,createContext as wn,useContext as Qe,useEffect as Sn,useId as et,useRef as J,useState as Z}from"react";import{useEasel as oe,useSelectedHost as v}from"efficient-easel/easel";import{PIN_LENGTH as re,toDateKey as _n,fromDateKey as Cn}from"efficient-shell/format";import{say as a,editorEaselWords as C}from"../../../format/lib/editor-words.js";import{finiteNumber as $}from"../../../format/lib/finite-number.js";import{LOADING_SHOWS_LABELS as tt,firstFrameHint as yn,loadingShowsOf as xn,loadingStillHint as In}from"../../../format/lib/hero-video.js";import{pageFramesFor as On,usePageVideoFrames as Tn}from"../page-video-frames.js";import{ScreenDocumentContext as En}from"efficient-easel/screen/components/ScreenDocumentContext";import{readHidable as nt,hidableText as ot}from"efficient-easel/draw";import{FOLD_FIELD_MARKER as be,LINK_FIELD_MARKER as rt,MEDIA_FIELD_MARKER as it,SCAFFOLD_FIELD_MARKER as st,TEXT_FIELD_MARKER as R,foldMetaOf as we,textFieldIdentifier as Rn}from"efficient-easel/draw";import Nn from"../../components/ApplyCornersToSiblings.js";import{withShowWhen as lt}from"../../../render/lib/document/show-when.js";import{CARD_IMAGE_PX_ROW as kn,CARD_IMAGE_RADIUS_ROW as at,CARD_IMAGE_RADIUS_STEP as Pn,CORNER_RADIUS_MAX as Se,CORNER_RADIUS_MIN as A}from"../../../format/lib/content/card-image-shape.js";import{IMAGE_CORNER_STEP as An,IMAGE_CORNERS_LABEL as Ln,IMAGE_CORNERS_ROW as Fn}from"../../../format/lib/content/image-corners.js";import{GRID_MAX_COLUMNS as vn}from"../../../format/lib/content/grid-span.js";import{GALLERY_ACROSS_BUCKETS as Bn,GALLERY_LAYOUTS as _e,GALLERY_LAYOUT_KEYS as Dn,galleryChoices as ct,galleryLayoutRatio as Hn,galleryPictureCells as Gn}from"../../../format/lib/content/gallery-layout.js";import{shellGlyphOf as Mn}from"./shell-glyph.js";import{anchorSiblingsOf as Wn,placementPoints as Un}from"../../../format/lib/hero-group-placement.js";import Kn from"../../components/AnchorField.js";import $n from"../../components/SourceStatus.js";import{AdjustIcon as Xn,EyeIcon as Vn,AnimationIcon as jn,BackgroundIcon as ut,BorderAllIcon as zn,BlockSectionIcon as Yn,ColumnWidthsIcon as Ce,ColumnsIcon as dt,CornerIcon as pt,DirectionDownIcon as qn,DirectionLeftIcon as Jn,DirectionRightIcon as Zn,DirectionUpIcon as Qn,EditIcon as eo,GapIcon as to,GridIcon as no,GroundIcon as ye,HashIcon as oo,HeightIcon as ft,ImageIcon as ro,ListIcon as io,LocationIcon as ht,PaddingBottomIcon as mt,PaddingLeftIcon as gt,PaddingRightIcon as bt,PaddingTopIcon as xe,PageIcon as so,StickyIcon as wt,SearchIcon as lo,SquareIcon as ao,TypeIcon as co,WidthIcon as uo}from"efficient-easel/icons";import{FieldGlyph as St}from"../../components/FieldGlyph.js";import{resolvePageBackground as po}from"../../../format/lib/content/page-background.js";import{boxFillOf as fo,boxFillSlot as Ie}from"../../../format/lib/content/box-background.js";import{CORNER_SIDES as _t,CORNER_SIDE_POINTS as ho,SECTION_CORNERS_ROW as Ct,hasOwnSectionCorners as mo,normalizeCornerSides as yt}from"../../../format/lib/content/section-corners.js";import{CARD_CORNERS_ROW as xt}from"../../../format/lib/content/card-corners.js";import{enclosingPath as go,enclosingSection as bo}from"./enclosing-section.js";import{SettingsDefaultReset as y,SettingsDrill as wo,SettingsField as _,SettingsGroup as So,SettingsSegmented as _o,SettingsBorder as Co,SettingsSidesEach as yo,SettingsSwitch as Oe,borderSides as xo,borderStartEach as Io}from"efficient-easel/panel";import{ListField as Oo}from"efficient-easel/fields";import{DisplayChips as To}from"efficient-shell/ui";import{desktopDisplayChanged as Eo,partShownOnDesktop as Ro,partShownOnPhone as No,phoneDisplayChanged as ko,withDesktopPart as Po,withPhonePart as Ao}from"../../../format/lib/content/part-display.js";import{ColorSwatch as Lo,CornersInput as Fo,DatePicker as vo,DateTimePicker as Bo,FOCAL_DEFAULT as Do,IconPicker as It,COLUMN_COUNT_MAX as Ot,COLUMN_SHARE_MIN as Ho,COLUMN_SHARES_EQUAL as Go,resolveColumnShares as Tt,WidthsBar as Mo,useShellStrings as Wo,IconButton as Et,InputNumber as Rt,Slider as Uo,Tooltip as Te}from"efficient-shell/ui";import{LOOKUP_BUSY_NOTE as Ko}from"./geocode-resolve.js";import{ColourRow as ie,InheritedColourRow as Nt}from"./ColourControl.js";import{fillThemeColors as $o,slotFill as se}from"../../../format/lib/document/theme-slots.js";import{fillSlotNamed as Ee}from"../../../format/lib/document/part-inks.js";import{keptByRow as Re}from"efficient-easel/screen/lib/document/style-fields";import kt from"./MarkupToolbar.js";import{deviceField as T}from"efficient-easel/screen/lib/document/device-fields";import{NO_CONTROL_FIELD as Xo,NoControlMark as Vo,noControlField as Pt}from"efficient-easel/screen/lib/document/panel-no-control-mark";import{OWN_BOX_FIELD as jo}from"../../../format/lib/document/own-box.js";import{fieldPanelOnly as zo,PANEL_ONLY_FIELD as Yo}from"../../../format/lib/document/panel-only.js";import{PHONE_CLEAR as qo,resolvePhoneValue as Ne}from"../../../format/lib/document/phone-override.js";import{phoneKey as X,tabletKey as ke,viewKeyAt as Pe}from"efficient-easel/draw";import{viewKey as I}from"../../../format/lib/animation/views.js";import{viewRows as B}from"../animation/view-rows.js";import{SuppressibleText as Jo}from"./section-text-suppress.js";import{CARD_INDEX_OPTIONS as Zo,CARD_OUTLINE_OPTIONS as Qo,DEFAULT_CARD_INDEX_FORMAT as er,DEFAULT_CARD_OUTLINE as tr}from"../../../format/lib/sections/product-card-style.js";import{COVER_INDEX_OPTIONS as nr,DEFAULT_COVER_INDEX as or}from"../../../format/lib/sections/card-cover-index.js";import{SCALAR_TEXT_CONTROLS as rr}from"efficient-easel/draw";import ir from"../../components/MediaUploadField.js";import sr from"../../components/MultiSelectField.js";import lr from"../../components/SectionThemePicker.js";import ar from"../../components/SearchSelectField.js";import cr from"../../components/StorefrontLinkField.js";import{UiIcon as At}from"efficient-easel/draw/client";import{SECTION_PADDING as N}from"../../../render/lib/content/section-padding.js";import{buttonWordsSummary as ur}from"../../../render/lib/content/button-look.js";import{usePreviewParts as dr}from"efficient-easel/draw/client";import{encodePartId as pr}from"efficient-easel/draw";import{DEFAULT_EASEL_STRINGS as fr,useEaselStrings as hr}from"efficient-easel/strings";import{hasPhoneHeight as mr,hasTabletHeight as Ae,resolveSectionMinHeight as gr,resolveTabletHeight as br}from"../../../format/lib/content/section-min-height.js";import{INTRO_OLD_STICKY_PINS as wr,SECTION_PIN_ABOVE_HINT as Sr,SECTION_PIN_ABOVE_KEY as _r,SECTION_PIN_ABOVE_LABEL as Cr,SECTION_PIN_GROUP as yr,SECTION_PIN_LABEL as Lt,SECTION_PIN_SCREENS_KEY as Le,SECTION_PIN_SCREENS_LABEL as Ft,SECTION_PIN_STOP_DEFAULT as xr,SECTION_PIN_STOP_HINT as Ir,SECTION_PIN_STOP_KEY as Or,SECTION_PIN_STOP_LABEL as Tr,SECTION_PIN_STOP_OPTIONS as Er,SECTION_STICK_DISTANCE as D,SECTION_STICK_DISTANCE_ROW as Fe,SOME_VIEW_PINS as vt,hasPhoneStick as Rr,hasTabletStick as Nr,resolveSectionStick as le,sectionPinStopOf as kr,sectionPinStopWrite as Pr}from"../../../format/lib/content/section-sticky.js";import{cssLengthOf as Ar}from"../../../format/lib/content/css-length.js";import{SECTION_HEIGHT_MODES as Lr,SECTION_MIN_HEIGHT as Fr,SECTION_MIN_HEIGHT_GROUP_LABEL as Q,SECTION_SCREEN_PCT as vr}from"../../../format/lib/content/section-min-height.js";import{containerDirectionPoints as Br,resolveContainerDirection as Bt}from"../../../format/lib/content/container-direction.js";import{BOX_BLOCK_SPACING_LABEL as Dr,BOX_BLOCK_SPACING_POINTS as Dt,BOX_PHONE_ROW_LABEL as Ht,BOX_COLUMNS_MAX as Hr,BOX_COLUMNS_MIN as Gt,BOX_PHONE_ROW_MAX as Gr,BOX_PHONE_ROW_MIN as ve,BOX_SHARE_CHOICES as Mt,BOX_SHARE_LABEL as V,boxShareChoiceOf as Wt,boxShareWidthsOf as Be,BOX_SHARE_PHONE_DEFAULT as Mr,BOX_SHARE_PHONE_POINTS as Wr}from"../../../format/lib/content/box-layout.js";import{usePreviewHeader as H}from"../../../render/components/PreviewHeaderContext.js";import{BORDER_MAX as Ut,BORDER_SIDES as Ur,SECTION_BORDER_ROW as Kt,borderBySide as $t}from"../../../format/lib/content/borders.js";import{DEFAULT_SURFACES as Kr,normalizeTheme as Xt,normalizeThemeColors as $r,sectionBandTone as Xr,surfaceTwoTone as Vr}from"../../../format/lib/theme.js";import{CONTAINER_GAP as Vt,CONTAINER_GAP_BUILT_IN as jr,CONTAINER_GAP_PHONE as De,GAP_FIELD_CONTAINER as He,followsSitePhoneGap as zr,hasOwnContainerGap as Yr,hasOwnPhoneGap as Ge,resolveContainerGap as jt,resolvePhoneContainerGap as zt}from"../../../format/lib/content/container-gap.js";import{CARD_IMAGE_BG_INHERIT as qr,CARD_IMAGE_BG_OFF as Jr,CARD_IMAGE_BG_SWATCH_NAMES as Zr,CARD_IMAGE_BG_SWATCHES as Qr,isCardImageBackgroundInheriting as ei,cardImageBackgroundChoice as ti,THEME_CARD_IMAGE_BG as ni}from"../../../format/lib/content/card-image-background.js";import{SECTION_BG_INHERIT as oi,SECTION_BG_NO_FILL as ri,sectionBackgroundChoice as ii,THEME_SECTION_BG as Me,isSectionBackgroundEmpty as si,sectionBackgroundHex as Yt}from"../../../format/lib/content/section-background.js";import{SECTION_THEME_GROUP_LABEL as li,nestedAccentValue as qt,resolveSectionAccent as ae}from"../../../format/lib/content/section-surface.js";import{TYPE_SIZE_FIXED as ai,TYPE_SIZE_INHERIT as ci,isTypeSizeInheriting as ui}from"../../../format/lib/content/section-type-size.js";import{SECTION_WIDTH_CHOICES as di,WIDTH_CHOICE_LABEL as pi,WIDTH_INHERIT as fi}from"../../../format/lib/content/section-width.js";import{useEaselSession as hi}from"efficient-easel/screen/lib/session-context";import{backendOf as mi}from"../website-session.js";import{BOX_GAP as gi,describedAs as L,group as E,iconOf as j,sharedStyleKinds as ee}from"efficient-easel/screen/lib/document/box-fields";import{VIEW_KEY_ACCESS as Jt,onDesktopWords as G,phoneTwinFields as We,saidAlignmentGrid as bi,useLengthUnit as wi}from"efficient-easel/screen/lib/document/box-fields";import{LENGTH_UNITS_TABLE as Si,directionField as _i,gapField as Ue,iconPickerRow as Ci,lengthUnitFields as ce,pickerCellIcon as yi,pickerNoneIcon as xi,Segmented as Ke,select as z,slider as M}from"./box-fields.js";import{VIEW_ABOVE as $e}from"efficient-easel/screen/lib/content/length-units";import{tierOfView as Zt,viewOfTier as Ii}from"../../../format/lib/content/view-tier.js";import{ownEntry as Oi}from"../../../format/lib/own-entry.js";function ka({children:e}){return i("div",{className:"sf-field-label",children:typeof e=="string"?a(e):e})}function W(e,t){return a("{value} from {from}",{value:e,from:t})}function Ti(){const{blockGap:e}=H();return e===null?a("this container's own spacing"):W(`${e}px`,a("Styles"))}function Ei({inherited:e,onReset:t,label:n}){return i(y,{words:C()?.panel,label:a(n),changed:!e,detail:Ti(),onReset:t})}function Ri(e){return Ue({...gi,builtIn:jr[e],resolve:(t,n)=>jt(e,t,n?.siteGap),action:(t,n)=>i(Ei,{inherited:!Yr(e,t),onReset:()=>n(void 0),label:"Gap"}),mark:{[He]:e}})}function Ni(e){return lt(T("mobile",{[He]:e,type:"custom",render:t=>i(Ai,{container:e,...t})}),Qt)}function ki(e){return lt(T("tablet",{[He]:e,type:"custom",render:t=>i(Pi,{container:e,...t})}),Qt)}const Qt={not:{field:"gap",in:Array.from({length:-Vt.min},(e,t)=>Vt.min+t)}};function Pa(e){return{gap:T("desktop",Ri(e)),[ke("gap")]:ki(e),[X("gap")]:Ni(e)}}function Pi({container:e,...t}){const[n]=F("gap"),{siteGap:o}=t.field??{},r=Math.max(De.min,jt(e,n,o));return Ue({...De,builtIn:r,resolve:l=>Ge(l)?l:r,action:(l,c)=>i(y,{words:C()?.panel,label:a("Gap"),changed:Ge(l),detail:G(u=>a(u),`${r}px`),onReset:()=>c(void 0)})}).render(t)}function Ai({container:e,...t}){const[n]=F("gap"),{siteGap:o,siteGapPhone:r}=t.field??{},s=zt(e,void 0,n,o,r);return Ue({...De,builtIn:s,resolve:c=>zt(e,c,n,o,r),action:(c,u)=>i(y,{words:C()?.panel,label:a("Gap"),changed:Ge(c),detail:W(`${s}px`,zr(e,n,r)?a("Styles"):a("Desktop")),onReset:()=>u(void 0)})}).render(t)}function Aa(e){return _i({offered:Br(e),fallback:Bt(e,void 0),resolve:t=>Bt(e,t)})}function La(e,t){return Un(t?Wn(e,t):[],t)}function Li({inherited:e,onReset:t,label:n}){return i(y,{words:C()?.panel,label:a(n),changed:!e,detail:W(a("Full"),a("the page")),onReset:t})}function U({value:e,onChange:t,label:n,placeholder:o,hint:r,multiline:s,hideable:l=!0,markup:c=!0}){const{text:u,hidden:p}=nt(e),h=J(null),d=J(null),f=x=>t(l?{text:x,hidden:p}:x),m=()=>t({text:u,hidden:!p}),g=l&&p,b=et(),S=r?Hi(r)?i("span",{className:"sf-hint-while-typing",children:a(r)}):a(r):void 0,w=p?a("Show {label} on the slide",{label:a(n)}):a("Hide {label} on the slide",{label:a(n)});return i(_,{label:a(n),icon:i(co,{}),htmlFor:b,className:g?"is-hidden":void 0,hint:S,action:l?i(Te,{content:w,children:i(Et,{"aria-pressed":p,"aria-label":w,onClick:m,children:p?i(At,{name:"eye-off",size:14}):i(At,{name:"eye",size:14})})}):void 0,children:k("div",{className:"sf-copybox",children:[c&&i(kt,{target:s?d:h,value:u,onChange:f}),s?i("textarea",{id:b,ref:d,value:u,placeholder:o===void 0?void 0:a(o),onChange:x=>f(x.target.value)}):i("input",{id:b,ref:h,type:"text",value:u,placeholder:o===void 0?void 0:a(o),onChange:x=>f(x.target.value)})]})})}function Fa(e,t){return{...e,[st]:t}}function va(e){const t=e[R];if(!t)throw new Error("withOffPage: the field holds no authored text");return{...e,[R]:{...t,offPage:!0}}}function Ba(e){return!e||typeof e!="object"?!1:e[R]?.offPage===!0}function Da(e){if(!e[R])throw new Error("withPanelOnly: the field holds no authored text");return{...e,[Yo]:!0}}function Ha(e){return zo(e)}function Ga(e){const t=e[R];if(!t)throw new Error("withIdentifier: the field holds no authored text");return{...e,[R]:{...t,identifier:!0}}}import{TEXT_CONTROL_KINDS as Yc,SCALAR_TEXT_CONTROLS as qc}from"efficient-easel/draw";function Ma(e,t){if(!e[R])throw new Error("inOwnBox: the field holds no authored text");const{[Xo]:o,...r}=e;return{...r,[jo]:!0,render:t}}const Fi=new Set(rr),ue={type:"radio",options:[{value:!0},{value:!1}]},en={text:{type:"object",objectFields:{text:{type:"text"},hidden:ue}},textarea:{type:"object",objectFields:{text:{type:"textarea"},hidden:ue}},plainText:{type:"text"},copyText:{type:"text"},plainTextarea:{type:"textarea"},textList:{type:"array",arrayFields:{text:{type:"text"}}}},K=(e,t)=>{const n=L({...t,[R]:e},{...en[e.control],label:e.label});if(!Fi.has(e.control))return n;const o=t.render;return{...Pt(n,"authored-copy"),render:r=>i(Jo,{name:r.name,children:o(r)})}},Wa="Everything else on this block comes from the linked post. Unlink it to edit by hand.",vi={field:"source.slug",set:!0},Ua={not:vi},Bi="Select a word, then press the highlighter.",Di=new Set([Bi]),Hi=e=>Di.has(e);function Ka(e,t,n){return K({control:"text",label:e,placeholder:t,hint:n},{type:"custom",render:({value:o,onChange:r})=>i(U,{value:o,onChange:r,label:e,placeholder:t,hint:n})})}function $a(e,t,n){return K({control:"textarea",label:e,placeholder:t,hint:n},{type:"custom",render:({value:o,onChange:r})=>i(U,{value:o,onChange:r,label:e,placeholder:t,hint:n,multiline:!0})})}function Xa(e,t,n){return K({control:"plainText",label:e,placeholder:t,hint:n},{type:"custom",render:({value:o,onChange:r})=>i(U,{value:o,onChange:r,label:e,placeholder:t,hint:n,hideable:!1,markup:!1})})}function Va(e,t,n){return K({control:"copyText",label:e,placeholder:t,hint:n},{type:"custom",render:({value:o,onChange:r})=>i(U,{value:o,onChange:r,label:e,placeholder:t,hint:n,hideable:!1})})}function ja(e){return{type:"custom",[rt]:{label:e},...L({},{type:"text",label:e}),render:({value:t,onChange:n})=>i(cr,{value:ot(t),onChange:n,label:e})}}function za(e,t,n){return K({control:"plainTextarea",label:e,placeholder:t,hint:n},{type:"custom",render:({value:o,onChange:r})=>i(U,{value:o,onChange:r,label:e,placeholder:t,hint:n,multiline:!0,hideable:!1})})}const Ya={Design:Xn,Animation:jn};function qa(e){return{type:"custom",render:()=>i(Gi,{text:e})}}function Gi({text:e}){return i("p",{className:"sf-note",children:a(e)})}function Ja(e){return we(e)!==null&&e?.tabs!==void 0}const tn=new Map;function Za(e,t){const n=`${e}\0${t?t.join(""):""}`,o=tn.get(n)??{type:"custom",tabs:t,[be]:{label:e,level:1},bucket:e,marker:!0,render:()=>i(P,{})};return tn.set(n,o),o}const nn=new Map;function Qa(e){const t=nn.get(e)??{type:"custom",[be]:{label:e,level:1},designGroup:e,marker:!0,...e==="Content"?{}:{fold:e},render:()=>i(P,{})};return nn.set(e,t),t}function Mi(e){const t=e;return t?.marker===!0&&typeof t.fold=="string"?t.fold:null}function ec(e,t){return Mi(e)===t?e:{...e,marker:!0,fold:t,render:()=>i(P,{})}}function tc(e){const t=e;if(t.marker===!0&&t.fold===void 0)return e;const{fold:n,...o}=e;return{...o,marker:!0,render:()=>i(P,{})}}function nc({title:e,children:t}){const[n,o]=Z(()=>!Xe.has(e));return i(So,{title:e,open:n,onToggle:r=>{o(r),r?Xe.delete(e):Xe.add(e)},children:t})}const Xe=new Set;function Wi({swatches:e,current:t,onPick:n,names:o}){const r=e.find(c=>c.toLowerCase()===t.toLowerCase()),s=r?o?.[r]:void 0,l=s?a(s):t;return k("div",{className:"sf-swatches",children:[e.map(c=>{const u=o?.[c]?a(o[c]):c;return i(Te,{content:u,children:i(Lo,{color:c,selected:t.toLowerCase()===c.toLowerCase(),onClick:()=>n(c),"aria-label":u})},c)}),i("span",{className:"sf-swatch-hex",children:l})]})}function oc(e,t,n=!1){return{type:"custom",render:({value:o,onChange:r})=>i(Ui,{label:e,builtIn:t,followsBand:n,value:o,onChange:r})}}function Ui({label:e,builtIn:t,followsBand:n,value:o,onChange:r}){const s=typeof o=="string"?o:void 0,{colors:l,n:c}=qe(),u={background:l.background,surface:l.surface,surface2:Vr(l),band:Xr(l)},p=n?Me:t,h=si(s,t,p),d=Yt(void 0,p,u),f=n?oi:void 0,m=p===Me?a("the theme's section background"):a("Theme {n} background",{n:c}),g=Ki(s,t,l,c,u,r),b=W(d.toUpperCase(),m),S=Ee(s),w=S?se(S,l,c):null;return w?i(ie,{label:a(e),icon:i(ut,{}),value:w.hex,caption:w.words,onChange:r,changed:!0,onReset:()=>r(f),resetTo:b,choices:g}):i(Nt,{label:a(e),icon:i(ut,{}),value:h?"":Yt(s,t,u),inherited:d,resetTo:b,onChange:r,onReset:()=>r(f),choices:g})}function Ki(e,t,n,o,r,s){const l=ii(e,t);return[{label:a("No fill"),color:"",selected:l==="none",onPick:()=>s(ri)},{label:`${a("Section band")} · ${r.band.toUpperCase()}`,color:r.band,selected:l==="band",onPick:()=>s(Me)},...Ye(Ee(e)??"",n,o,s)]}function $i(e,t){return{type:"custom",render:({value:n,onChange:o})=>{const r=n,s=ei(r,t);return i(_,{label:a(e),icon:i(ye,{}),changed:!s,action:i(y,{words:C()?.panel,label:a(e),changed:!s,detail:a("the theme's image stage"),onReset:()=>o(qr)}),children:Wi({swatches:Qr,current:s?ni:ti(r,t),onPick:o,names:Zr})})}}}function rc(e=n=>n,t){return ee({_gSectionTheme:E(li),sectionAccent:{type:"custom",render:({value:n,onChange:o})=>i(lr,{value:e(n),onChange:o,followLabel:t})}})}function de(e){const t=O(),n=Zt(e?.view),o=l=>Pe(e.valueKey,l),r=e.numbersIn??(l=>$(t[o(l)])!==void 0),s=e.followsView??is(n,r);return wi({props:{value:void 0,onChange:()=>{},field:{}},row:e.valueKey?e.row:void 0,table:Si,label:a(e.label),grid:e.grid,hasOwn:r(n),view:{tier:n,numbersIn:r,followsView:s},convertTo:e.convertTo??(l=>{const c=$(t[o(n)]);return c===void 0?{}:{[o(n)]:l(c)}})})}function Y({min:e,max:t,step:n,value:o,onChange:r,suffix:s="",readout:l=!0,notch:c,ariaLabel:u,disabled:p=!1,placeholder:h,placeholderWord:d,onClear:f,units:m}){const g=c!==void 0&&Number.isFinite(c)&&c>=e&&c<=t;return i("div",{className:g?"sf-slider has-notch":"sf-slider",style:g?{"--sf-notch":(c-e)/(t-e)}:void 0,children:i(Uo,{min:e,max:t,step:n,value:o,...o===null&&h!==void 0?{placeholderValue:h}:{},...d?{emptyLabel:a(d)}:{},suffix:s||void 0,...m?{units:m}:{},showInput:l,label:u===void 0?void 0:a(u),disabled:p,size:"sm",boxSize:"md",className:"sf-slider-track",onChange:b=>{b===null?f?.():b!==o&&r(b)}})})}function Xi(e,t){const{min:n,max:o,step:r=1,unsetLabel:s,hint:l,restTrack:c,unsetMark:u,icon:p,unit:h="px"}=t;return{type:"custom",render:({value:d,onChange:f})=>{const m=typeof d=="number"?d:null,g=m===null;return i(_,{label:a(e),icon:p?j(p):void 0,value:g?u||s===void 0?void 0:a(s):`${m}${h}`,changed:!g,action:u?ge(u,{changed:!g,onReset:()=>f(null)}):i(y,{words:C()?.panel,label:a(e),changed:!g,onReset:()=>f(null)}),hint:typeof l=="string"?a(l):l,children:c?c({min:n,max:o,step:r,px:m,label:e,onChange:f}):Y({min:n,max:o,step:r,value:m??n,readout:!1,ariaLabel:e,onChange:f})})}}}const te="Corners",Vi={kind:"radius"};function Ve(e){return{type:"custom",render:t=>{const{value:n,onChange:o}=t,r=typeof n=="number"&&Number.isFinite(n)?n:null,s=r!==null;return i(_,{label:a(te),icon:i(pt,{}),changed:s,action:ge(e.mark,{changed:s,onReset:()=>o(null)}),hint:e.hint,children:i(ji,{tier:e,px:r,name:t.name,onRadius:o})})}}}function F(e){const t=v();return[t?.values?.[e],n=>t?.onChange(e,n)]}function on(){return Pt({type:"custom",render:()=>i(Vo,{})},"always")}function pe(){const e=v();return t=>e?.onChangeMany(t)}function ji({tier:e,px:t,name:n,onRadius:o}){const r=e.useFollowed(),[s,l]=F(e.sidesKey),c=pe(),u=de({row:e.row??Vi,label:te,grid:{min:A,max:Se,step:e.step??1},valueKey:n??"",view:"desktop"}),p=yt(s)??[..._t];return i(Fo,{label:a(te),value:p,corners:ho,onChange:h=>{const d=yt(h)??[];l(d.length===_t.length?null:d)},radius:t,onRadiusChange:u&&n?h=>c({[n]:h,...u.unitPatch(h===null)}):o,radiusMin:u?.grid.min??A,radiusMax:u?.grid.max??Se,radiusStep:u?.grid.step??e.step??1,radiusPlaceholder:u&&u.unit!=="px"?"–":String(r),...u?{radiusUnit:u.unit,units:u.units}:{}})}function rn(e,t){return ce(e,t)}function sn(){return on()}function zi({label:e,changed:t=!1,onReset:n=()=>{}}){const{cornerRadiusPx:o}=H(),r=typeof o=="number"?`${o}px`:a("not set");return i(y,{words:C()?.panel,label:a(e),changed:t,detail:o==null?a("the built-in corners"):W(r,a("Styles")),onReset:n})}function Yi(){const{cornerRadiusPx:e}=H();return typeof e=="number"?e:A}function qi(){return Ve({sidesKey:"sectionCornerSides",row:Ct,useFollowed:Yi,mark:i(zi,{label:te}),hint:Ji})}const Ji="Follows Styles ▸ Basics ▸ Corners until you set a number here.";function ic(){return ee({_gShape:E("Shape"),sectionCorners:qi(),...rn(Ct,"sectionCorners"),sectionCornerSides:sn(),...B("sectionBorder",rs),...ce(Kt,"sectionBorder",{tablet:!0,phone:!0})})}const Zi=()=>({width:a("Border width"),sides:{top:a("Border top"),right:a("Border right"),bottom:a("Border bottom"),left:a("Border left")},style:a("Border style"),styles:{solid:a("Solid"),dashed:a("Dashed"),dotted:a("Dotted")},color:a("Border color"),unit:"px"});function Qi(e){const t=Object.fromEntries(Object.entries(e).filter(([,n])=>n!=null&&n!==""));return Object.keys(t).length?t:void 0}function es(){let e;try{const t=Xt(H().theme);e=t.themes[t.selected]?.line}catch{e=void 0}return e||Kr.line}function ts({value:e,onChange:t,placeholder:n,presets:o,sides:r=!0,styles:s=!0,above:l={},length:c}){const u=e&&typeof e=="object"?e:{},[p,h]=Z(()=>r?Io(u,l):!1),d=Zi(),f=m=>Qi(r&&s?m:{width:m.width,color:m.color,...s?{style:m.style}:{}});return i(_,{label:a("Border"),icon:i(zn,{}),action:r?i(yo,{each:p,label:a("Each side"),onChange:h}):void 0,children:i(Co,{label:a("Border"),value:u,each:p,onChange:m=>t(f(m)),placeholder:n,presets:o,words:c?{...d,unit:c.unit}:d,styles:s,max:c?.grid.max??Ut,...c?{step:c.grid.step,units:c.units}:{}})})}function ns({value:e,onChange:t,view:n}){const[o]=F("sectionBorder"),[r]=F(ke("sectionBorder")),s=es(),l=f=>f&&typeof f=="object"?f:{},c=n==="phone"?{...$t(l(o)),...$t(l(r))}:n==="tablet"?l(o):{},u=O(),p=pe(),h=I("sectionBorder",n),d=de({row:Kt,label:"Border",grid:{min:0,max:Ut,step:1},valueKey:"sectionBorder",view:n,numbersIn:f=>je(u[Pe("sectionBorder",f)]),convertTo:f=>{const m=l(u[h]);return je(m)?{[h]:os(m,f)}:{}}});return i(ts,{value:e,length:d,onChange:d?f=>p({[h]:f,...d.unitPatch(!je(f))}):t,placeholder:{sides:xo(c),style:c.style??"solid",color:c.color||s},presets:[s],above:c})}const ln=["width",...Ur];function je(e){if(!e||typeof e!="object")return!1;const t=e;return ln.some(n=>$(t[n])!==void 0)}function os(e,t){const n={...e};for(const o of ln){const r=$(n[o]);r!==void 0&&(n[o]=t(r))}return n}function rs(e){return{type:"custom",render:({value:t,onChange:n})=>i(ns,{value:t,onChange:n,view:e})}}function is(e,t){let n=$e[e];for(;n&&$e[n]!==null&&!t(n);)n=$e[n];return n??e}function sc(e){return{type:"custom",render:()=>i(ss,{partKey:e})}}function ss({partKey:e}){const[t]=F("id"),[n]=F("_partStyles"),{textStyles:o}=H(),r=hr();let s=null;try{s=dr().select}catch{s=null}const l=n&&typeof n=="object"?n[e]:void 0,c=Array.isArray(o)?o:null;return i(wo,{name:a("Text"),preview:ur(l,c,{noStyle:a("No style"),styleName:r.textStyles.styleName,cases:(r.copy.panel??fr.copy.panel).cases}),onOpen:()=>{s&&typeof t=="string"&&s(pr(t,e))}})}function an(e){const{cornerRadiusPx:t}=H(),n=typeof t=="number"?t:e;let o=null;try{const{appState:s,selectedItem:l}=oe(u=>u),c=l?.props?.id?String(l.props.id):void 0;o=c?bo(s?.data,c)?.props??null:null}catch{o=null}if(!o)return n;const r=o.sectionCorners;return mo(r)?r:n}function ls({label:e,changed:t=!1,onReset:n=()=>{}}){const o=an(A);return i(y,{words:C()?.panel,label:a(e),changed:t,detail:W(`${o}px`,a("the section")),onReset:n})}function as(){return i(P,{children:a("Follows the section's Corners until you set a number here.")})}function cs(){return Ve({sidesKey:"cardCornerSides",row:xt,useFollowed:()=>an(A),mark:i(ls,{label:te}),hint:i(as,{})})}function us(){return{type:"custom",render:()=>i(Nn,{})}}function lc(){return{_gShape:E("Shape"),cardCorners:cs(),...rn(xt,"cardCorners"),cardCornerSides:sn(),cardCornersApplyAll:us()}}function ds(){return L({type:"custom",render:e=>i(fs,{...e})},{type:"select",label:V,options:[{value:"content",label:"Fit content"},{value:"equal",label:"Equal"},{value:[50],label:"Custom: the width of each block in %, the last block left out"}]})}function ps(e,t){const n=Wt(e);if(n!=="custom")return a(Mt.find(r=>r.value===n)?.label??"");const o=Tt(Be(e,t),t);return o?[...o,100-o.reduce((r,s)=>r+s,0)].join(" / "):a("Custom")}function fs(e){const{value:t,onChange:n}=e,[o]=F("content"),r=Array.isArray(o)?o.length:0,s="follows"in e,l=t!=null,c=l?t:s?e.follows:void 0,u=Wt(c),p=r>=2&&r<=Ot,h=()=>[...Go[r]??[]],d=J(null),f=w=>{const x=d.current;x&&JSON.stringify(w)===JSON.stringify(x.shares)?n(x.value):w&&n(w)},m=w=>{w===u||w==="custom"&&!p||n(w==="custom"?h():w)},g=a("The width bar works for 2 to {count} blocks.",{count:Ot}),b=l&&(s||t!=="content"),S=Wo().widths.hint(r,Ho);return i(_,{label:a(V),icon:i(Ce,{}),changed:b,hint:u!=="custom"?void 0:p?S:g,action:i(y,{words:C()?.panel,label:a(V),changed:b,disabled:e.readOnly===!0,detail:s?G(w=>a(w),ps(e.follows,r),e.followsView):a("Fit content"),onReset:()=>n(void 0)}),children:k("div",{className:"sf-share-row",children:[i("div",{className:"sf-share-pick",children:i(It,{label:a(V),value:u,options:Mt.map(w=>({value:w.value,label:w.value==="custom"&&!p?g:a(w.label),icon:yi(i("span",{className:"sf-gallery-pic sf-share-pic",children:cn(w.weights).map((x,q)=>i("i",{style:{gridColumn:`span ${x}`}},q))}),a(w.label),w.value==="custom"&&!p?g:a(w.label))})),onChange:m,columns:3,cell:un,tooltips:!1,disabled:e.readOnly===!0})}),u==="custom"&&p?i("div",{onFocus:()=>{d.current={value:t,shares:Tt(Be(c,r),r)}},onBlur:()=>{d.current=null},children:i(Mo,{label:a(V),count:r,value:Be(c,r),onChange:f,readOnly:e.readOnly===!0})}):null]})})}function cn(e){if(!e)return[3,4];const t=e.reduce((n,o)=>n+o,0);return e.map(n=>Math.round(n/t*12))}function ac(){return z(Dr,i(to,{}),Dt,Dt[0].value)}function cc(){return T("mobile",Ci(V,i(Ce,{}),Wr.map(e=>({label:e.label,value:e.value,picture:i("span",{className:"sf-gallery-pic sf-share-pic",children:cn(e.weights).map((t,n)=>i("i",{style:{gridColumn:`span ${t}`}},n))})})),Mr,{columns:2,cell:un}))}const un={width:"5.75rem",height:"3.25rem"};function uc(){return We("share",ds(),Jt)[ke("share")]}function hs(){return T("mobile",M(Ht,i(dt,{}),ve,Gr,1,ve,"",{clear:{phoneFollows:!1,hint:ve}}))}const dn={read:e=>e.phoneRow,write:(e,t,n)=>({phoneRow:n}),fieldKey:()=>"phoneRow",ownField:!0};function dc(){const e=M(Ht,i(dt,{}),Gt,Hr,1,Gt,"",{clear:{emptyLabel:"Auto"}}),t=We("columns",e,{...dn,tablet:Jt.tablet}),n=We("columns",e,dn,{phoneRow:hs()});return{...t,phoneRow:n.phoneRow}}function pc(e,t,n,o,r,s,l){return{type:"custom",render:({value:c,onChange:u,name:p})=>i(ms,{label:e,min:t,max:n,step:o,fallback:r,role:s,value:c,onChange:u,name:p??"",length:l})}}function ms({label:e,min:t,max:n,step:o,fallback:r,role:s,value:l,onChange:c,name:u,length:p}){const h=O(),d=pe(),f=Zt(p?.view),m=de({row:p?.row??{kind:"fontSize"},label:e,grid:{min:t,max:n,step:o},valueKey:p?u:"",view:p?.view??"desktop",numbersIn:b=>b===f&&typeof h[u]=="number",followsView:f,convertTo:b=>typeof h[u]=="number"?{[u]:b(h[u])}:{}}),g=b=>m?d({[u]:b,...m.unitPatch(typeof b!="number")}):c(b);return i(_,{label:a(e),icon:i(St,{noun:s}),action:i(y,{words:C()?.panel,label:a(e),changed:!ui(l),detail:a("the Text style in Styles"),onReset:()=>g(ci),defaultAction:{onPress:()=>g(ai),title:a("Keep this section's own built-in size"),icon:i(Yn,{})}}),children:Y({min:m?.grid.min??t,max:m?.grid.max??n,step:m?.grid.step??o,value:typeof l=="number"?l:r,...m?{suffix:m.unit,units:m.units}:{suffix:"px"},ariaLabel:e,onChange:g})})}function fc(){return{_gCellWidth:E("Cell width"),gridSpan:z("Positions",i(Ce,{}),[{label:"Auto",value:""},...Array.from({length:vn},(e,t)=>({label:t===0?"1 position":`${t+1} positions`,value:String(t+1)}))],"")}}function O(){let e=null,t=null;try{e=Qe(gs),t=oe(n=>n).selectedItem}catch{t=null}return e??t?.props??{}}const gs=wn(null);function bs({min:e,max:t,step:n,px:o,label:r,onChange:s,desktopKey:l,fallback:c}){const u=O()[l],p=Ne(void 0,u,c);return i(P,{children:Y({min:e,max:t,step:n,value:Ne(o,u,c),readout:!1,ariaLabel:r,notch:p,onChange:s})})}function ws({label:e,desktopKey:t,fallback:n,unit:o="px",changed:r=!1,onReset:s=()=>{}}){const l=O()[t],c=Ne(void 0,l,n);return i(y,{words:C()?.panel,label:a(e),changed:r,detail:G(u=>a(u),`${c}${o}`),onReset:s})}function Ss(e){return Xi(e.label,{icon:e.icon,min:e.min,max:e.max,step:e.step,unit:e.unit,unsetLabel:"Follows Desktop",unsetMark:i(ws,{label:e.label,desktopKey:e.desktopKey,fallback:e.fallback,unit:e.unit}),restTrack:t=>i(bs,{...t,desktopKey:e.desktopKey,fallback:e.fallback})})}const _s={Top:"Padding top",Bottom:"Padding bottom",Left:"Padding left",Right:"Padding right"},Cs={Top:xe,Bottom:mt,Left:gt,Right:bt},ys=e=>{const t=Cs[e];return i(t,{})};function hc(e={}){const t=e.keys?.top??"sectionPaddingTop",n=e.keys?.bottom??"sectionPaddingBottom",o=e.group!==!1,r=S=>_s[S],s=S=>M(r("Top"),i(xe,{}),N.min,N.max,N.step,S,"px"),l=(S,w,x,q=N)=>T("mobile",Ss({label:r(S),icon:ys(S),desktopKey:w,min:q.min,max:q.max,step:q.step,fallback:x})),c=e.top??N.min,u=e.bottom??N.min,p="sectionPaddingLeft",h="sectionPaddingRight",d=e.sideBounds??N,f=e.side??d.min,m=e.sidePhone??f,g=e.phone===!0,b=S=>g?T("desktop",S):S;return ee({...o?{_gSpacing:E("Padding")}:{},[t]:b(s(c)),...g?{[X(t)]:l("Top",t,c)}:{},...e.only==="top"?{}:{[n]:b(M(r("Bottom"),i(mt,{}),N.min,N.max,N.step,u,"px")),...g?{[X(n)]:l("Bottom",n,u)}:{}},...e.sides?{[p]:b(M(r("Left"),i(gt,{}),d.min,d.max,d.step,f,"px")),...g?{[X(p)]:l("Left",p,m,d)}:{},[h]:b(M(r("Right"),i(bt,{}),d.min,d.max,d.step,f,"px")),...g?{[X(h)]:l("Right",h,m,d)}:{}}:{}})}function mc(e,t){const n=Object.fromEntries(Object.entries(t).map(([s,l])=>[s,s in e&&we(l)?e[s]:l])),o={};let r=!1;for(const[s,l]of Object.entries(e)){if(s in t){r||Object.assign(o,n),r=!0;continue}o[s]=l}return r||Object.assign(o,n),o}const fe="Width";function gc(e,t=di,n=!0){const o=t.map(r=>({label:pi[r],value:r}));return ee({...n?{_gWidth:E(fe)}:{},widthMode:{type:"custom",render:({onChange:r,field:s})=>i(_,{label:a(fe),icon:i(uo,{}),action:n?i(Li,{inherited:s?.inherited??!1,onReset:()=>r(fi),label:fe}):void 0,children:Ke({options:o,value:s?.currentValue||e,onChange:r,ariaLabel:fe})})}})}function bc({fill:e=!1}={}){const t=(r,s)=>({type:"custom",render:({value:l,onChange:c})=>i(xs,{value:l,onChange:c,view:r,badge:s,fill:e})}),n=()=>Re("sectionHeightMode"),o=()=>Re("sectionHeightMode");return ee({_gHeight:E(Q),...B("sectionHeightMode",r=>r==="desktop"?t(r):t(r,s=>i(Es,{view:r,onClear:()=>s(void 0)}))),...B("sectionHeightValue",n),...B("sectionHeightUnit",o)})}function xs({value:e,onChange:t,view:n,badge:o,fill:r=!1}){const s=O(),{mode:l,number:c,unit:u}=Is(n,s,e);return i(_,{label:Q,icon:j(i(ft,{})),action:o?o(t):void 0,children:k("div",{className:"es-width-stack",children:[Ke({options:[{label:"Auto",value:"auto"},{label:"Fixed",value:"fixed"},{label:"Screen",value:"screen"},...r?[{label:"Fill",value:"fill"}]:[]],value:l,onChange:t,ariaLabel:Q}),c?i(Ts,{view:n,mode:l,menu:u}):null]})})}function pn(e,t){return e==="phone"&&Ae(t)?br(t):gr(t)}function he(e,t){return e==="desktop"||(e==="tablet"?Ae(t):mr(t))?null:pn(e,t)}function Is(e,t,n){const r=(s=>Lr.includes(s))(n)?n:he(e,t)?.mode??"auto";return{mode:r,number:r!=="auto"&&r!=="fill",unit:r==="fixed"}}function Os(e,t,n,o){const r=he(e,t);return!r||e==="desktop"?null:o===void 0?{}:{[I("sectionHeightMode",e)]:r.mode,...r.mode==="fixed"?{[I("sectionHeightUnit",e)]:r.unit}:{},...n==="sectionHeightUnit"?{[I("sectionHeightValue",e)]:r.value}:{},[I(n,e)]:o}}function fn(e,t,n){const o=v(),r=he(e,O());return!o||!r?{followed:null,write:n}:{followed:r,write:l=>o.onChangeMany(c=>{const u=Os(e,c,t,l);return u===null?{[I(t,e)]:l}:Object.keys(u).length?u:null})}}function Ts({view:e,mode:t,menu:n}){const o=v(),r=O(),s=I("sectionHeightValue",e),l=I("sectionHeightUnit",e),c=S=>w=>o?.onChangeMany(()=>({[S]:w})),{followed:u,write:p}=fn(e,"sectionHeightValue",c(s)),{write:h}=fn(e,"sectionHeightUnit",c(l)),d=t==="screen"?"%":r[l],f=(u?u.unit:d)==="%"?"%":"px",m=f==="%"?vr:Fr,g=r[s],b=n?{options:["px","%"],label:a("Unit"),onChange:S=>h(S)}:void 0;return Y({min:m.min,max:m.max,step:m.step,value:u?null:typeof g=="number"?g:m.fallback,...u?{placeholder:u.value}:{},suffix:f,...b?{units:b}:{},ariaLabel:Q,onChange:p})}function Es({view:e,onClear:t}){const n=O(),o=he(e,n)===null,r=e==="phone"&&Ae(n),s=pn(e,n),l=G(c=>a(c),s.mode==="auto"?a("Auto"):`${s.value}${s.unit}`,r?"tablet":"desktop");return i(y,{words:C()?.panel,label:a(Q),changed:o,detail:l,onReset:t})}function wc(e={}){const t=e.intro===!0,n=s=>({type:"custom",render:({value:l,onChange:c,id:u,name:p})=>i(Fs,{value:l,onChange:c,labelId:`${u??p??"stickTop"}-label`,view:s,intro:t})}),o=s=>({type:"custom",render:({value:l,onChange:c})=>i(Ps,{value:l,onChange:c,view:s,intro:t})}),r=s=>({type:"custom",render:({value:l,onChange:c})=>i(As,{value:l,onChange:c,view:s,intro:t})});return{_gStick:E(yr,{dot:t?ks:vt}),...B("stickTop",n),...B("stickTopDistance",o),...ce(Fe,"stickTopDistance",{tablet:!0,phone:!0}),...e.screens?B(Le,r):{},...t?{}:{[Or]:Rs()},...t||e.above===!1?{}:{[_r]:Ns()}}}function Rs(){const e=z(Tr,i(xe,{}),Er,xr);return T("desktop",{...e,render:t=>{const n=e.render({...t,value:kr(t.value),onChange:o=>t.onChange(Pr(o))});return ge(n,{hint:a(Ir)})}})}function Ns(){const e=gn(Cr,!1,i(wt,{}),Sr);return T("desktop",{...e,render:t=>e.render({...t,onChange:n=>t.onChange(n===!0?!0:void 0)})})}const ks={any:[vt,wr]};function hn(e,t,n,o,r){const s=v(),l=O(),c=e==="desktop"||ne(e,l)?null:ze(e,le(l,{intro:o}));return{followed:c,write:(c||r)&&s?p=>s.onChangeMany(h=>{const d=Ls(e,h,p,t,o),f=d===null?{[I(t,e)]:p}:d;return Object.keys(f).length?{...f,...r?.(p)??{}}:null}):n}}function Ps({value:e,onChange:t,view:n,intro:o}){const r=O(),s=le(r,{intro:o}),l=h=>{const d=Ii(h);return d==="desktop"||ne(d,r)},c=de({row:Fe,label:"Distance from top",grid:{min:D.min,max:D.max,step:D.step},valueKey:"stickTopDistance",view:n,numbersIn:h=>l(h)&&$(r[Pe("stickTopDistance",h)])!==void 0,followsView:n==="phone"&&s.ownTablet?"tablet":"desktop"}),{followed:u,write:p}=hn(n,"stickTopDistance",t,o,c?h=>c.unitPatch(h===void 0):void 0);return i("div",{className:"sf-field",children:Y({min:c?.grid.min??D.min,max:c?.grid.max??D.max,step:c?.grid.step??D.step,value:u?null:typeof e=="number"?e:D.fallback,...u?{placeholder:u.distance}:{},...c?{suffix:c.unit,units:c.units}:{suffix:"px"},ariaLabel:a("Distance from top"),onChange:p})})}function As({value:e,onChange:t,view:n,intro:o}){const{followed:r,write:s}=hn(n,Le,t,o);return i(_,{label:a(Ft),icon:j(i(ft,{})),children:Y({min:re.min,max:re.max,step:re.step,value:r?null:$(e)??re.default,...r?{placeholder:r.screens}:{},ariaLabel:a(Ft),onChange:s})})}function ne(e,t){return e==="tablet"?Nr(t):Rr(t)}function ze(e,t){return e==="phone"?{on:t.tablet,distance:t.tabletDistance,unit:t.tabletUnit,screens:t.tabletScreens}:{on:t.desktop,distance:t.desktopDistance,unit:t.desktopUnit,screens:t.desktopScreens}}function Ls(e,t,n,o="stickTopDistance",r=!1){if(e==="desktop"||ne(e,t))return null;if(n===void 0)return{};const s=ze(e,le(t,{intro:r})),l=e==="phone"&&ne("tablet",t)?h=>I(h,"tablet"):h=>h,c=(h,d)=>t[l(h)]==null?{}:{[I(h,e)]:d},u=Fe.unitKey,p=t[l(u)]==null?{}:{[I(u,e)]:s.unit};return{[I("stickTop",e)]:!0,...c("stickTopDistance",s.distance),...p,...c(Le,s.screens),[I(o,e)]:n}}function Fs({value:e,onChange:t,labelId:n,view:o,intro:r}){const s=O(),l=le(s,{intro:r}),c=o==="phone"?l.phone:o==="tablet"?l.tablet:r?l.desktop:e===!0,u=o==="phone"&&l.ownTablet,p=o==="desktop"?null:ze(o,l),h=p?.on?Ar(p.distance,p.unit):a("Off");return i(_,{label:a(Lt),labelId:n,icon:j(i(wt,{})),action:k(P,{children:[o!=="desktop"?i(y,{words:C()?.panel,label:a(Lt),changed:ne(o,s),detail:G(d=>a(d),h,u?"tablet":"desktop"),onReset:()=>t(void 0)}):null,i(Oe,{checked:c,onChange:t,ariaLabelledBy:n})]})})}const mn="e.g. about";function Sc(){return{_gAnchor:E("Anchor"),anchor:K({control:"plainText",label:"Name",placeholder:mn},{type:"custom",render:({value:e,onChange:t})=>i(Kn,{value:e,onChange:t,nameBox:(n,o)=>i(U,{value:n,onChange:o,label:"Name",placeholder:mn,hideable:!1,markup:!1})})})}}function _c(e,t,n){return{type:"custom",render:({value:o,onChange:r,id:s,name:l})=>{const c=`${s??l??e}-datetime`,u=Date.parse(typeof o=="string"?o:"");return i(_,{label:a(e),icon:t,htmlFor:c,hint:n===void 0?void 0:a(n),children:i(Bo,{id:c,value:Number.isFinite(u)?new Date(u):null,onChange:p=>r(p?p.toISOString():"")})})}}}function Cc(e,t,n){return{type:"custom",render:({value:o,onChange:r,id:s,name:l})=>{const c=`${s??l??e}-date`;return i(_,{label:a(e),icon:t,htmlFor:c,hint:n===void 0?void 0:a(n),children:i(vo,{id:c,value:Cn(typeof o=="string"?o:null),onChange:u=>r(u?_n(u):"")})})}}}function gn(e,t,n,o){return{type:"custom",...L({},{...ue,label:e}),render:r=>{const{value:s,onChange:l,id:c,name:u}=r,p="follows"in r,h=r,d=typeof s=="boolean",f=typeof h.follows=="boolean"?h.follows:t,m=d?s:p?f:t,g=`${c??u??e}-label`,b=h.readOnly===!0,S=i(Oe,{checked:m,onChange:l,disabled:b,ariaLabelledBy:g});return i(_,{label:a(e),labelId:g,icon:n,hint:o===void 0?void 0:a(o),action:p?k(P,{children:[i(y,{words:C()?.panel,label:a(e),changed:d,detail:h.followsNoView?a(f?"On":"Off"):G(w=>a(w),a(f?"On":"Off"),h.followsView),disabled:b,onReset:()=>l(void 0)}),S]}):S})}}}function yc(){return{type:"custom",render:({value:e,onChange:t,id:n,name:o})=>{const r=`${String(n??o??"pageBackground")}-colour`;return i(vs,{label:"Background",icon:i(so,{}),id:r,value:e,shown:po(e),onChange:t})}}}function xc(e,t,n){return{type:"custom",render:({value:o,onChange:r})=>i(ie,{label:a(e),icon:n,value:o||t,onChange:r})}}function vs({label:e,icon:t,id:n,value:o,shown:r,onChange:s}){const{colors:l,n:c}=qe(),u=Ee(o),p=u?se(u,l,c):null;return i(ie,{label:a(e),icon:t,id:n,value:p?p.hex:r,caption:p?.words,onChange:s,choices:Ye(u??"",l,c,s)})}function Ic(){return{type:"custom",render:e=>{const{value:t,onChange:n}=e,o=e;return i(Bs,{value:typeof t=="string"?t:"",onChange:n,twin:"follows"in e?{follows:o.follows,view:o.followsView}:void 0})}}}function Ye(e,t,n,o){const r=Ie(e);return $o(t,n).map(s=>({label:s.label,color:s.value,selected:r===s.name,onPick:()=>o(s.name)}))}function Bs({value:e,onChange:t,twin:n}){const{colors:o,n:r}=qe(),s=o.background,l=W(s.toUpperCase(),a("Theme {n} background",{n:r})),c=Ie(e),u=c?se(c,o,r):null,p=Ye(e,o,r,t),h=n?()=>t(void 0):()=>t("");let d=s,f=l;if(n){const m=Ie(n.follows),g=fo(n.follows),b=m?se(m,o,r):g?{hex:g,words:g.toUpperCase()}:null;d=b?.hex??s,f=G(S=>a(S),b?b.words:l,n.view)}return u?i(ie,{label:a("Fill"),icon:i(ye,{}),value:u.hex,caption:u.words,onChange:t,changed:!0,onReset:h,resetTo:f,choices:p}):i(Nt,{label:a("Fill"),icon:i(ye,{}),value:e,inherited:d,resetTo:f,onChange:t,onReset:h,choices:p})}function Ds(e,t,n){if((e?.content??[]).some(l=>l?.props?.id===t))return ae(n);const r=go(e,t);if(r.length===0)return null;const s=ae(qt(n));if(s!==null)return s;for(let l=r.length-1;l>0;l-=1){const c=ae(qt(r[l].sectionAccent));if(c!==null)return c}return ae(r[0].sectionAccent)}function qe(){const e=Xt(H().theme),[t]=F("sectionAccent");let n=null;try{const{appState:r,selectedItem:s}=oe(c=>c),l=s?.props?.id?String(s.props.id):void 0;n=l?Ds(r?.data,l,t):null}catch{n=null}const o=n!==null&&e.themes[n]?n:e.selected;return{colors:$r(e.themes[o]),n:o+1}}function Oc(){return on()}const Tc={top:i(Qn,{}),right:i(Zn,{}),bottom:i(qn,{}),left:i(Jn,{})};function Ec(e,t,n,o,r,s,l){const c=d=>t.find(f=>f.value===d),u=d=>({value:d,label:"",disabled:!0,title:o}),p=d=>{const f=t.find(g=>g.cell===d);if(!f)return u(`missing-${d}`);const m=s?.[d];return m?{value:f.value,label:f.label,icon:m}:{value:f.value,label:f.label}},h=[u("corner-top-left"),p("top"),u("corner-top-right"),p("left"),u("centre"),p("right"),u("corner-bottom-left"),p("bottom"),u("corner-bottom-right")];return{type:"custom",render:({value:d,onChange:f})=>{const m=t.some(g=>g.value===d)?d:n;return i(_,{label:a(e),icon:r,value:c(m)?.label?a(c(m).label):l?a(l):"",children:bi(a,{label:e,value:m,onChange:f,points:h})})}}}function Rc(e,t,n){return{type:"custom",options:t,render:({value:o,onChange:r,field:s})=>i(sr,{label:e,options:(s.options??t).map(l=>({...l,label:a(l.label)})),value:Array.isArray(o)?o:[],onChange:r,...n?{emptyLabel:a(n)}:{}})}}function Nc(e,t,n,o){return{type:"custom",options:t,fallback:n,...L({},{type:"select",label:e}),render:({value:r,onChange:s,field:l})=>i(ar,{label:e,options:(l.options??t).map(c=>({...c,label:a(c.label)})),fallback:l.fallback??n,value:r,onChange:s,placeholder:o===void 0?void 0:a(o)})}}function kc(e,t={}){return{type:"custom",render:({value:n,onChange:o})=>{const r={value:n,onChange:o,...t};return i(e,{...r})}}}const Pc=[{label:"Image",value:"image"},{label:"Video",value:"video"}];function Ac(e,t,n){const o=Object.keys(tt).map(r=>({label:tt[r],value:r,picture:n[r]}));return{type:"custom",...L({},{type:"radio",label:e,options:o.map(r=>({value:r.value,label:r.label}))}),render:({onChange:r})=>i(Gs,{label:e,icon:t,options:o,onChange:r})}}function Hs(e,t,n){const o=yn(e,t,n);if(o!==void 0)return o==="save-makes-frame"?a("A frame is made from this video when you save the page."):o==="starts-dark"?a("This video starts dark, so no frame was made. The slide shows its background colour while the video loads. Choose Image to show a picture."):o==="outside"?a("This video is on another website, so no frame can be made. The slide shows its background colour while the video loads. Choose Image to show a picture."):o==="unsupported"?a("This video's file type gives no frame. The slide shows its background colour while the video loads. Choose Image to show a picture."):o==="failed"?a("No frame could be made from this video. It is tried again the next time you save the page. The slide shows its background colour while the video loads."):o==="image-no-frame"?a("The slide shows your Image while the video loads, because this video has no frame."):void 0;const r=In(e);return r==="frame-missing-image"?a("This video has no frame yet. The slide shows its image until one is made."):r==="frame-missing-surface"?a("This video has no frame yet. The slide shows its background colour until one is made."):r==="image-missing-frame"?a("No image yet. The slide shows the video's frame until you choose one."):r==="image-missing-surface"?a("No image yet. The slide shows its background colour until you choose one."):void 0}function Gs({label:e,icon:t,options:n,onChange:o}){const r=v(),s=r?.values??{},l=xn(s),c=Qe(En),u=Tn(c?.docId??null);let p=null;try{p=oe(d=>d.appState.data)}catch{p=null}const h=On(r?.id,p,u);return i(_,{label:a(e),icon:j(t),hint:Hs(s,h,c?.hasUnsavedEdits??!1),children:Ke({options:n,value:l,onChange:o,ariaLabel:e})})}function Lc(e,t,n,o={}){const r={type:"custom",[it]:!0,render:({value:s,onChange:l,name:c})=>i(ir,{value:s||"",onChange:l,fieldKey:c,label:e,accept:t,placeholder:n,focusKey:o.focus,focusWhen:o.focusWhen,frameKey:o.frame}),...o.focus?{focusKey:o.focus}:{},...o.focusWhen?{focusWhen:o.focusWhen}:{}};return o.focus?T("each",r):r}const Fc={HeroSingle:["imageFocal"],HeroSlide:["videoFrame"],ContactLocations:["locations[].photo"],ProcessSteps:["steps[].image"]};function Ms(e){const t=a(e.status??"");return e.ok&&typeof e.lat=="number"&&typeof e.lng=="number"?`${t} · ${e.lat.toFixed(4)}, ${e.lng.toFixed(4)}`:t}function vc({value:e,onChange:t,label:n}){const o=e||{},r=v(),s=r?r.values!==r.node.props:!0,l=!!o.pending&&s,c=!!o.pending&&!s,u=!!mi(hi()).geocode,p=et(),h=(d,f)=>t({...o,[d]:f??void 0});return k(P,{children:[i(_,{label:a(n),icon:i(ht,{}),action:u?i(Te,{content:a("Find from the address (OpenStreetMap)"),children:i(Et,{"aria-label":a("Find from the address"),"aria-busy":l||void 0,disabled:l,onClick:()=>t({...o,pending:!0,ok:!1,status:"Finding…"}),children:i(lo,{})})}):void 0,children:u&&o.status?i($n,{compact:!0,oneLine:!0,spaced:!1,status:l?"busy":o.ok&&!c?"found":"notfound",statusText:l?a("Finding…"):c?a(Ko):a(o.status),hint:Ms(o)}):null}),i(_,{label:a("Enter by hand"),labelId:p,icon:i(eo,{}),action:i(Oe,{checked:!!o.manual,onChange:d=>t({...o,manual:d}),ariaLabelledBy:p})}),o.manual&&i(_,{label:a("Latitude, longitude"),icon:i(ht,{}),children:k("div",{style:{display:"grid",gridTemplateColumns:"1fr 1fr",gap:8,width:"100%",minWidth:0},children:[i(Rt,{value:typeof o.lat=="number"?o.lat:null,onChange:d=>h("lat",d),min:-90,max:90,step:1e-4,placeholder:a("Latitude")}),i(Rt,{value:typeof o.lng=="number"?o.lng:null,onChange:d=>h("lng",d),min:-180,max:180,step:1e-4,placeholder:a("Longitude")})]})})]})}function Ws(e,t){return t===null||t<0||t>=e.length?"":e[t]?.text??""}function Us(e,t,n){const o=e.map(r=>({text:r?.text??""}));return t===null||t<0||t>=e.length?o:o.map((r,s)=>s===t?{text:n}:r)}function Bc(e,t){return e===null?null:t>e?e:null}function Ks(e,t,n){if(n===null||n>=t.length)return null;for(let o=0;o<n;o+=1)if(e[o]!==t[o])return null;return e[n]!==t[n]&&t.includes(e[n])||e[n]!==t[n]&&t.length!==e.length?null:n}const Dc={label:"Ticker items",icon:i(io,{})};function Hc(e,t,n,o){return{type:"custom",[R]:{control:"textList",label:e,placeholder:n,itemKey:"text",rendering:o},...L({},{...en.textList,label:e}),render:({value:r,onChange:s})=>i($s,{label:e,icon:j(t),items:Array.isArray(r)?r:[],placeholder:n,onChange:s,markup:o==="markup"})}}function $s({label:e,icon:t,items:n,placeholder:o,onChange:r,markup:s=!1}){const l=J(null),[c,u]=Z(null),p=d=>d.map(f=>({text:f?.text??""})),h=d=>{const f=Ks(n,d,c);f===null&&(l.current=null),u(f),r(p(d))};return i(Oo,{label:a(e),icon:t,noun:a("item"),items:n,onChange:h,newItem:()=>({text:""}),open:null,onOpen:()=>{},renderItem:()=>null,above:s?i(kt,{target:l,value:Ws(n,c),onChange:d=>r(Us(n,c??-1,d)),disabled:c===null,label:c===null?a("Formatting — click a row first"):a("Formatting — row {n}",{n:c+1})}):void 0,renderRow:(d,f,m)=>i("input",{type:"text",className:s&&c===f?"sf-list-marking":void 0,value:d?.text??"",placeholder:a(o),"aria-label":a("{label} {n}",{label:a(e),n:f+1}),onChange:g=>m({text:g.target.value}),onFocus:g=>{l.current=g.currentTarget,u(f)}})})}function Gc(e,t){const n=`${e.label} — row ${t+1}`;return K({control:"plainText",label:n,placeholder:e.placeholder,offPage:e.offPage},{type:"custom",render:({value:o,onChange:r})=>i(U,{value:o,onChange:r,label:a("{label} — row {n}",{label:a(e.label),n:t+1}),placeholder:e.placeholder,hideable:!1,markup:e.rendering==="markup"})})}function Mc(e){return{_gCards:E("Cards"),coverIndex:z("Cover image",i(ro,{}),nr,String(or),e?.coverHint??"A card's opening picture — a card pinned to a finish keeps its own."),imageBackground:$i("Image background",Jr),cardImage:bn()}}function Wc(){return{outline:z("Card outline",i(ao,{}),Qo,tr),indexBadge:z("Card number",i(oo,{}),Zo,er),showBadge:gn("Product badge",!0,i(St,{noun:"tag"}))}}function Uc(e){const t=e?.defaults??{showCardSizes:!0,showCardBuy:!0,showCardPage:!0},n=r=>({...ue,label:me.find(s=>s.id===r).label}),o=r=>L(Re(Je),n(r));return{_gShowOnCard:E("Show on a card"),[Je]:L({type:"custom",render:()=>i(Xs,{rest:{showCardPrice:!0,showCardFinishes:!0,...t}})},n(Je)),showCardFinishes:o("showCardFinishes"),showCardSizes:o("showCardSizes"),showCardBuy:o("showCardBuy"),showCardPage:o("showCardPage")}}const Je="showCardPrice",me=[{id:"showCardPrice",label:"Price"},{id:"showCardFinishes",label:"Finish swatches"},{id:"showCardSizes",label:"Sizes"},{id:"showCardBuy",label:"Buy button"},{id:"showCardPage",label:"Page button"}];function Xs({rest:e}){const t=O(),n=pe(),o=l=>typeof t[l]=="boolean"?t[l]:void 0,r=l=>o(l)??e[l],s=me.some(({id:l})=>o(l)!==void 0&&o(l)!==e[l]);return i(Ze,{parts:me,changed:s,shown:r,onPress:(l,c)=>n({[l]:c}),onReset:()=>n(Object.fromEntries(me.map(({id:l})=>[l,void 0])))})}function Kc(e,t="display"){const n=X(t);return{[t]:T("desktop",{type:"custom",render:({value:o,onChange:r})=>i(Ze,{parts:e,changed:Eo(o),shown:s=>Ro(o,s),onPress:(s,l)=>r(Po(o,s,l)),onReset:()=>r(void 0)})}),[n]:T("mobile",{type:"custom",render:({value:o,onChange:r})=>i(Vs,{parts:e,desktopKey:t,value:o,onChange:r})})}}function Ze({parts:e,changed:t,shown:n,onPress:o,onReset:r,detail:s,disabledReason:l}){const c=a("Display");return i(_,{label:c,icon:i(Vn,{}),changed:t,action:i(y,{words:C()?.panel,label:c,changed:t,detail:s,onReset:r}),children:i(To,{label:c,items:e.map(u=>({id:u.id,label:a(u.label),shown:n(u.id),...l?{disabled:!0,disabledReason:a(l)}:{}})),onChange:o})})}function Vs({parts:e,desktopKey:t,value:n,onChange:o}){const r=O()[t];return i(Ze,{parts:e,changed:ko(n),shown:s=>No(r,n,s),onPress:(s,l)=>o(Ao(n,s,l)),onReset:()=>o(qo),detail:a("the same as Desktop")})}function bn(e=kn){return M("Card image",i(pt,{}),A,Se,Pn,A,e,{clear:{hint:A},hint:"Rounds the picture. The card's own corner is in Styles."})}function js(){return ce(at,"cardImage")}function $c(){return{cardImage:bn(at),...js()}}function Xc(){return Ve({sidesKey:"cornerSides",row:Fn,step:An,useFollowed:()=>A,mark:i(zs,{label:Ln}),hint:a("Rounds the picture. Left alone it stays square.")})}function zs({label:e,changed:t=!1,onReset:n=()=>{}}){return i(y,{words:C()?.panel,label:a(e),changed:t,onReset:n})}function Vc(){return{type:"custom",render:({value:e,onChange:t})=>i(Zs,{value:typeof e=="string"?e:"",onChange:t})}}function Ys({layout:e,width:t}){const n=Hn(e),o=n?`${n[0]}/${n[1]}`:void 0;return i("span",{"aria-hidden":"true",style:{display:"grid",width:t,gridTemplateColumns:"repeat(12, minmax(0, 1fr))",gridAutoRows:o?"auto":6,gridAutoFlow:"row dense",gap:2},children:Gn(e).map(([r,s],l)=>i("i",{className:"block rounded-xs bg-current opacity-60",style:{gridColumn:`span ${r}`,gridRow:`span ${s}`,aspectRatio:o}},l))})}const qs={width:"3.5rem",height:"2.5rem"},Js=200;function Zs({value:e,onChange:t}){const[n,o]=Z(null),[r,s]=Z(4),l=J(null);Sn(()=>{const m=l.current;if(!m||typeof ResizeObserver!="function")return;const g=()=>s(m.getBoundingClientRect().width>=Js?4:3);g();const b=new ResizeObserver(g);return b.observe(m),()=>b.disconnect()},[]);const c=e?Oi(_e,e):void 0,u=c?e:"",p=ct(n,u),h=ct(n,"").length,d=Mn("no-symbol"),f=[{value:"",label:a("Not chosen"),icon:xi(d,a("Not chosen"))},...p.map(m=>({value:m,label:a(_e[m].label),icon:i(Ys,{layout:_e[m],width:40})}))];return i(_,{label:a("Layout"),icon:i(no,{}),value:c?a(c.label):void 0,children:i("div",{ref:l,style:{flex:"1 1 auto",minWidth:0},children:i(It,{label:a("Layout"),value:u,options:f,onChange:t,columns:r,cell:qs,header:k("div",{className:"mb-2 flex flex-col gap-1",style:{minWidth:"11rem"},children:[i("span",{className:"text-2xs text-ink-faint",children:a("Photos in a row")}),i(_o,{options:[{id:"all",label:a("All")},...Bn.map(m=>({id:String(m),label:String(m)}))],value:n===null?"all":String(n),ariaLabel:a("Photos in a row"),onChange:m=>o(m==="all"?null:Number(m))}),i("span",{className:"text-2xs text-ink-faint",children:a("{n} of {total} layouts",{n:h,total:Dn.length})})]})})})})}export{vi as BOUND_TO_POST,Wa as BOUND_TO_POST_NOTE,Ya as BUCKET_ICONS,Fc as CUSTOM_FIELD_MEDIA,vc as CoordsField,Qt as DESKTOP_GAP_NOT_OVERLAP,Ze as DisplayRow,Tc as EDGE_ARROWS,Do as FOCAL_DEFAULT,be as FOLD_FIELD_MARKER,Bi as HIGHLIGHT_HINT,U as HidableTextField,rt as LINK_FIELD_MARKER,ka as Label,it as MEDIA_FIELD_MARKER,Pc as MEDIA_TYPE_OPTIONS,Ua as NOT_BOUND_TO_POST,nc as PanelBand,Gi as PanelNoteLine,gs as RowPropsContext,st as SCAFFOLD_FIELD_MARKER,qc as SCALAR_TEXT_CONTROLS,Ei as SiteGapDefaultReset,Y as Slider,Wi as Swatches,Yc as TEXT_CONTROL_KINDS,R as TEXT_FIELD_MARKER,Dc as TICKER_ITEMS_ROW,$s as TextListField,vs as ThemeFillRow,fe as WIDTH_LABEL,Li as WidthDefaultReset,Ks as aimAfterListChange,Sc as anchorFields,W as backTo,oc as backgroundField,ac as boxBlockSpacingField,dc as boxColumnsFields,Ic as boxFillField,hs as boxPhoneRowField,ds as boxShareField,cc as boxSharePhoneField,uc as boxShareTabletField,Ds as boxThemeIndexOf,Za as bucketHeader,sc as buttonWordsEntryField,cs as cardCornersField,$i as cardImageBackgroundField,bn as cardImageField,$c as cardImageFields,Mc as cardMediaFields,lc as cardShapeFields,Uc as cardShowFields,Wc as cardStyleFields,fc as cellWidthFields,xc as colorInput,Aa as containerDirectionField,Ri as containerGapField,Ni as containerGapPhoneField,Pa as containerGapRows,ki as containerGapTabletField,Ms as coordsResultTip,Va as copyText,sn as cornerSidesField,Ve as cornersRowField,rn as cornersUnitFields,Cc as date,_c as dateTime,Qa as designGroupHeader,Kc as displayFields,Ec as edgePad,Ye as fillSlotChoices,Bc as focusAfterRemove,Oc as focusKeptField,ec as foldMarker,we as foldMetaOf,Mi as foldTitleOf,Os as followedHeightPatch,Ls as followedStickPatch,Vc as galleryLayoutField,bc as heightFields,he as heightFollowedBy,Is as heightLayersAt,La as heroGroupPlacementPoints,ot as hidableText,Hi as hintIsWhileTyping,Xc as imageCornersField,Ma as inOwnBox,Ja as isBucketHeader,on as keptBy,ja as linkField,Hs as loadingRowHint,Ac as loadingShowsField,Rc as multiSelect,yc as pageBackgroundField,qa as panelNote,Ss as phoneOverrideField,Xa as plainText,za as plainTextarea,Xi as pxField,tc as quietMarker,nt as readHidable,Ws as rowText,Nc as searchSelect,Ki as sectionBandChoices,qi as sectionCornersField,ic as sectionShapeFields,rc as sectionThemeFields,Us as setRowText,pc as sizeField,kc as sourceField,hc as spacingFields,wc as stickFields,mc as swapPadding,Ka as text,Rn as textFieldIdentifier,Ba as textFieldOffPage,Ha as textFieldPanelOnly,Hc as textList,Gc as textListRowField,$a as textarea,gn as toggle,Lc as upload,de as useLengthRow,pe as useSelectedPatch,O as useSelectedProps,F as useSelectedSibling,Ti as useSiteGapDetail,gc as widthField,Ga as withIdentifier,va as withOffPage,Da as withPanelOnly,Fa as withScaffold};
1
+ "use client";import{jsx as i,jsxs as P,Fragment as F}from"react/jsx-runtime";import{cloneElement as _e,createContext as xn,useContext as nt,useEffect as On,useId as ot,useRef as J,useState as Z}from"react";import{useEasel as re,useSelectedHost as B}from"efficient-easel/easel";import{PIN_LENGTH as ie,toDateKey as In,fromDateKey as En}from"efficient-shell/format";import{say as a,editorEaselWords as y}from"../../../format/lib/editor-words.js";import{finiteNumber as $}from"../../../format/lib/finite-number.js";import{LOADING_SHOWS_LABELS as rt,firstFrameHint as Tn,loadingShowsOf as Rn,loadingStillHint as Nn}from"../../../format/lib/hero-video.js";import{pageFramesFor as kn,usePageVideoFrames as Pn}from"../page-video-frames.js";import{ScreenDocumentContext as Fn}from"efficient-easel/screen/components/ScreenDocumentContext";import{readHidable as it,hidableText as st}from"efficient-easel/draw";import{FOLD_FIELD_MARKER as Ce,LINK_FIELD_MARKER as lt,MEDIA_FIELD_MARKER as at,SCAFFOLD_FIELD_MARKER as ct,TEXT_FIELD_MARKER as N,foldMetaOf as ye,textFieldIdentifier as An}from"efficient-easel/draw";import Ln from"../../components/ApplyCornersToSiblings.js";import{withShowWhen as ut}from"../../../render/lib/document/show-when.js";import{CARD_IMAGE_PX_ROW as vn,CARD_IMAGE_RADIUS_ROW as dt,CARD_IMAGE_RADIUS_STEP as Bn,CORNER_RADIUS_MAX as xe,CORNER_RADIUS_MIN as A}from"../../../format/lib/content/card-image-shape.js";import{IMAGE_CORNER_STEP as Dn,IMAGE_CORNERS_LABEL as Hn,IMAGE_CORNERS_ROW as Gn}from"../../../format/lib/content/image-corners.js";import{GRID_MAX_COLUMNS as Mn}from"../../../format/lib/content/grid-span.js";import{GALLERY_ACROSS_BUCKETS as Wn,GALLERY_LAYOUTS as Oe,GALLERY_LAYOUT_KEYS as Un,galleryChoices as pt,galleryLayoutRatio as Kn,galleryPictureCells as Xn}from"../../../format/lib/content/gallery-layout.js";import{shellGlyphOf as $n}from"./shell-glyph.js";import{anchorSiblingsOf as Vn,placementPoints as jn}from"../../../format/lib/hero-group-placement.js";import zn from"../../components/AnchorField.js";import Yn from"../../components/SourceStatus.js";import{AdjustIcon as qn,EyeIcon as Jn,AnimationIcon as Zn,BackgroundIcon as ft,BorderAllIcon as Qn,BlockSectionIcon as eo,ColumnWidthsIcon as Ie,ColumnsIcon as ht,CornerIcon as mt,DirectionDownIcon as to,DirectionLeftIcon as no,DirectionRightIcon as oo,DirectionUpIcon as ro,EditIcon as io,GapIcon as so,GridIcon as lo,GroundIcon as Ee,HashIcon as ao,HeightIcon as gt,ImageIcon as co,ListIcon as uo,LocationIcon as bt,PaddingBottomIcon as wt,PaddingLeftIcon as St,PaddingRightIcon as _t,PaddingTopIcon as Te,PageIcon as po,StickyIcon as Ct,SearchIcon as fo,SquareIcon as ho,TypeIcon as mo,WidthIcon as go}from"efficient-easel/icons";import{FieldGlyph as yt}from"../../components/FieldGlyph.js";import{resolvePageBackground as bo}from"../../../format/lib/content/page-background.js";import{BOX_FILL_FADE_PROP as wo,BOX_FILL_FADES as So,BOX_SWATCH_PROP as _o,boxFillFadeOf as xt,boxFillOf as Co,boxFillSlot as Re,boxPaintOf as yo}from"../../../format/lib/content/box-background.js";import{CORNER_SIDES as Ot,CORNER_SIDE_POINTS as xo,SECTION_CORNERS_ROW as It,hasOwnSectionCorners as Oo,normalizeCornerSides as Et}from"../../../format/lib/content/section-corners.js";import{CARD_CORNERS_ROW as Tt}from"../../../format/lib/content/card-corners.js";import{enclosingPath as Io,enclosingSection as Eo}from"./enclosing-section.js";import{SettingsDefaultReset as x,SettingsDrill as To,SettingsField as _,SettingsGroup as Ro,SettingsSegmented as No,SettingsBorder as ko,SettingsSidesEach as Po,SettingsSwitch as Ne,borderSides as Fo,borderStartEach as Ao}from"efficient-easel/panel";import{ListField as Lo}from"efficient-easel/fields";import{DisplayChips as vo}from"efficient-shell/ui";import{desktopDisplayChanged as Bo,partShownOnDesktop as Do,partShownOnPhone as Ho,phoneDisplayChanged as Go,withDesktopPart as Mo,withPhonePart as Wo}from"../../../format/lib/content/part-display.js";import{ColorSwatch as Uo,CornersInput as Ko,DatePicker as Xo,DateTimePicker as $o,FOCAL_DEFAULT as Vo,IconPicker as Rt,COLUMN_COUNT_MAX as Nt,COLUMN_SHARE_MIN as jo,COLUMN_SHARES_EQUAL as zo,resolveColumnShares as kt,WidthsBar as Yo,useShellStrings as qo,IconButton as Pt,InputNumber as Ft,Slider as Jo,Tooltip as ke}from"efficient-shell/ui";import{LOOKUP_BUSY_NOTE as Zo}from"./geocode-resolve.js";import{ColourRow as se,InheritedColourRow as At}from"./ColourControl.js";import{fillThemeColors as Qo,slotFill as le}from"../../../format/lib/document/theme-slots.js";import{fillSlotNamed as Pe}from"../../../format/lib/document/part-inks.js";import{keptByRow as Fe}from"efficient-easel/screen/lib/document/style-fields";import Lt from"./MarkupToolbar.js";import{deviceField as E}from"efficient-easel/screen/lib/document/device-fields";import{NO_CONTROL_FIELD as er,NoControlMark as tr,noControlField as vt}from"efficient-easel/screen/lib/document/panel-no-control-mark";import{OWN_BOX_FIELD as nr}from"../../../format/lib/document/own-box.js";import{fieldPanelOnly as or,PANEL_ONLY_FIELD as rr}from"../../../format/lib/document/panel-only.js";import{PHONE_CLEAR as ir,resolvePhoneValue as Ae}from"../../../format/lib/document/phone-override.js";import{phoneKey as V,tabletKey as Le,viewKeyAt as ve}from"efficient-easel/draw";import{viewKey as O}from"../../../format/lib/animation/views.js";import{viewRows as D}from"../animation/view-rows.js";import{SuppressibleText as sr}from"./section-text-suppress.js";import{CARD_INDEX_OPTIONS as lr,CARD_OUTLINE_OPTIONS as ar,DEFAULT_CARD_INDEX_FORMAT as cr,DEFAULT_CARD_OUTLINE as ur}from"../../../format/lib/sections/product-card-style.js";import{COVER_INDEX_OPTIONS as dr,DEFAULT_COVER_INDEX as pr}from"../../../format/lib/sections/card-cover-index.js";import{SCALAR_TEXT_CONTROLS as fr}from"efficient-easel/draw";import hr from"../../components/MediaUploadField.js";import mr from"../../components/MultiSelectField.js";import gr from"../../components/SectionThemePicker.js";import br from"../../components/SearchSelectField.js";import wr from"../../components/StorefrontLinkField.js";import{UiIcon as Bt}from"efficient-easel/draw/client";import{SECTION_PADDING as k}from"../../../render/lib/content/section-padding.js";import{buttonWordsSummary as Sr}from"../../../render/lib/content/button-look.js";import{usePreviewParts as _r}from"efficient-easel/draw/client";import{encodePartId as Cr}from"efficient-easel/draw";import{DEFAULT_EASEL_STRINGS as yr,useEaselStrings as xr}from"efficient-easel/strings";import{hasPhoneHeight as Or,hasTabletHeight as Be,resolveSectionMinHeight as Ir,resolveTabletHeight as Er}from"../../../format/lib/content/section-min-height.js";import{INTRO_OLD_STICKY_PINS as Tr,SECTION_PIN_ABOVE_HINT as Rr,SECTION_PIN_ABOVE_KEY as Nr,SECTION_PIN_ABOVE_LABEL as kr,SECTION_PIN_GROUP as Pr,SECTION_PIN_LABEL as Dt,SECTION_PIN_SCREENS_KEY as De,SECTION_PIN_SCREENS_LABEL as Ht,SECTION_PIN_STOP_DEFAULT as Fr,SECTION_PIN_STOP_HINT as Ar,SECTION_PIN_STOP_KEY as Lr,SECTION_PIN_STOP_LABEL as vr,SECTION_PIN_STOP_OPTIONS as Br,SECTION_STICK_DISTANCE as H,SECTION_STICK_DISTANCE_ROW as He,SOME_VIEW_PINS as Gt,hasPhoneStick as Dr,hasTabletStick as Hr,resolveSectionStick as ae,sectionPinStopOf as Gr,sectionPinStopWrite as Mr}from"../../../format/lib/content/section-sticky.js";import{cssLengthOf as Wr}from"../../../format/lib/content/css-length.js";import{SECTION_HEIGHT_MODES as Ur,SECTION_MIN_HEIGHT as Kr,SECTION_MIN_HEIGHT_GROUP_LABEL as Q,SECTION_SCREEN_PCT as Xr}from"../../../format/lib/content/section-min-height.js";import{containerDirectionPoints as $r,resolveContainerDirection as Mt}from"../../../format/lib/content/container-direction.js";import{BOX_BLOCK_SPACING_LABEL as Vr,BOX_BLOCK_SPACING_POINTS as Wt,BOX_PHONE_ROW_LABEL as Ut,BOX_COLUMNS_MAX as jr,BOX_COLUMNS_MIN as Kt,BOX_PHONE_ROW_MAX as zr,BOX_PHONE_ROW_MIN as Ge,BOX_SHARE_CHOICES as Xt,BOX_SHARE_LABEL as j,boxShareChoiceOf as $t,boxShareWidthsOf as Me,BOX_SHARE_PHONE_DEFAULT as Yr,BOX_SHARE_PHONE_POINTS as qr}from"../../../format/lib/content/box-layout.js";import{usePreviewHeader as G}from"../../../render/components/PreviewHeaderContext.js";import{BORDER_MAX as Vt,BORDER_SIDES as Jr,SECTION_BORDER_ROW as jt,borderBySide as zt}from"../../../format/lib/content/borders.js";import{DEFAULT_SURFACES as Zr,normalizeTheme as Yt,normalizeThemeColors as Qr,sectionBandTone as ei,surfaceTwoTone as ti}from"../../../format/lib/theme.js";import{CONTAINER_GAP as qt,CONTAINER_GAP_BUILT_IN as ni,CONTAINER_GAP_PHONE as We,GAP_FIELD_CONTAINER as Ue,followsSitePhoneGap as oi,hasOwnContainerGap as ri,hasOwnPhoneGap as Ke,resolveContainerGap as Jt,resolvePhoneContainerGap as Zt}from"../../../format/lib/content/container-gap.js";import{CARD_IMAGE_BG_INHERIT as ii,CARD_IMAGE_BG_OFF as si,CARD_IMAGE_BG_SWATCH_NAMES as li,CARD_IMAGE_BG_SWATCHES as ai,isCardImageBackgroundInheriting as ci,cardImageBackgroundChoice as ui,THEME_CARD_IMAGE_BG as di}from"../../../format/lib/content/card-image-background.js";import{SECTION_BG_INHERIT as pi,SECTION_BG_NO_FILL as fi,sectionBackgroundChoice as hi,THEME_SECTION_BG as Xe,isSectionBackgroundEmpty as mi,sectionBackgroundHex as Qt}from"../../../format/lib/content/section-background.js";import{SECTION_THEME_GROUP_LABEL as gi,nestedAccentValue as en,resolveSectionAccent as ce}from"../../../format/lib/content/section-surface.js";import{TYPE_SIZE_FIXED as bi,TYPE_SIZE_INHERIT as wi,isTypeSizeInheriting as Si}from"../../../format/lib/content/section-type-size.js";import{SECTION_WIDTH_CHOICES as _i,WIDTH_CHOICE_LABEL as Ci,WIDTH_INHERIT as yi}from"../../../format/lib/content/section-width.js";import{useEaselSession as xi}from"efficient-easel/screen/lib/session-context";import{backendOf as Oi}from"../website-session.js";import{BOX_GAP as Ii,describedAs as L,group as T,iconOf as z,sharedStyleKinds as ee}from"efficient-easel/screen/lib/document/box-fields";import{VIEW_KEY_ACCESS as tn,onDesktopWords as M,phoneTwinFields as $e,saidAlignmentGrid as Ei,useLengthUnit as Ti}from"efficient-easel/screen/lib/document/box-fields";import{LENGTH_UNITS_TABLE as Ri,directionField as Ni,gapField as Ve,iconPickerRow as ki,lengthUnitFields as ue,pickerCellIcon as Pi,pickerNoneIcon as Fi,Segmented as de,select as Y,slider as W}from"./box-fields.js";import{VIEW_ABOVE as je}from"efficient-easel/screen/lib/content/length-units";import{tierOfView as nn,viewOfTier as Ai}from"../../../format/lib/content/view-tier.js";import{ownEntry as Li}from"../../../format/lib/own-entry.js";function Ma({children:e}){return i("div",{className:"sf-field-label",children:typeof e=="string"?a(e):e})}function U(e,t){return a("{value} from {from}",{value:e,from:t})}function vi(){const{blockGap:e}=G();return e===null?a("this container's own spacing"):U(`${e}px`,a("Styles"))}function Bi({inherited:e,onReset:t,label:n}){return i(x,{words:y()?.panel,label:a(n),changed:!e,detail:vi(),onReset:t})}function Di(e){return Ve({...Ii,builtIn:ni[e],resolve:(t,n)=>Jt(e,t,n?.siteGap),action:(t,n)=>i(Bi,{inherited:!ri(e,t),onReset:()=>n(void 0),label:"Gap"}),mark:{[Ue]:e}})}function Hi(e){return ut(E("mobile",{[Ue]:e,type:"custom",render:t=>i(Wi,{container:e,...t})}),on)}function Gi(e){return ut(E("tablet",{[Ue]:e,type:"custom",render:t=>i(Mi,{container:e,...t})}),on)}const on={not:{field:"gap",in:Array.from({length:-qt.min},(e,t)=>qt.min+t)}};function Wa(e){return{gap:E("desktop",Di(e)),[Le("gap")]:Gi(e),[V("gap")]:Hi(e)}}function Mi({container:e,...t}){const[n]=R("gap"),{siteGap:o}=t.field??{},r=Math.max(We.min,Jt(e,n,o));return Ve({...We,builtIn:r,resolve:l=>Ke(l)?l:r,action:(l,c)=>i(x,{words:y()?.panel,label:a("Gap"),changed:Ke(l),detail:M(u=>a(u),`${r}px`),onReset:()=>c(void 0)})}).render(t)}function Wi({container:e,...t}){const[n]=R("gap"),{siteGap:o,siteGapPhone:r}=t.field??{},s=Zt(e,void 0,n,o,r);return Ve({...We,builtIn:s,resolve:c=>Zt(e,c,n,o,r),action:(c,u)=>i(x,{words:y()?.panel,label:a("Gap"),changed:Ke(c),detail:U(`${s}px`,oi(e,n,r)?a("Styles"):a("Desktop")),onReset:()=>u(void 0)})}).render(t)}function Ua(e){return Ni({offered:$r(e),fallback:Mt(e,void 0),resolve:t=>Mt(e,t)})}function Ka(e,t){return jn(t?Vn(e,t):[],t)}function Ui({inherited:e,onReset:t,label:n}){return i(x,{words:y()?.panel,label:a(n),changed:!e,detail:U(a("Full"),a("the page")),onReset:t})}function K({value:e,onChange:t,label:n,placeholder:o,hint:r,multiline:s,hideable:l=!0,markup:c=!0}){const{text:u,hidden:d}=it(e),h=J(null),p=J(null),f=C=>t(l?{text:C,hidden:d}:C),m=()=>t({text:u,hidden:!d}),g=l&&d,b=ot(),S=r?ji(r)?i("span",{className:"sf-hint-while-typing",children:a(r)}):a(r):void 0,w=d?a("Show {label} on the slide",{label:a(n)}):a("Hide {label} on the slide",{label:a(n)});return i(_,{label:a(n),icon:i(mo,{}),htmlFor:b,className:g?"is-hidden":void 0,hint:S,action:l?i(ke,{content:w,children:i(Pt,{"aria-pressed":d,"aria-label":w,onClick:m,children:d?i(Bt,{name:"eye-off",size:14}):i(Bt,{name:"eye",size:14})})}):void 0,children:P("div",{className:"sf-copybox",children:[c&&i(Lt,{target:s?p:h,value:u,onChange:f}),s?i("textarea",{id:b,ref:p,value:u,placeholder:o===void 0?void 0:a(o),onChange:C=>f(C.target.value)}):i("input",{id:b,ref:h,type:"text",value:u,placeholder:o===void 0?void 0:a(o),onChange:C=>f(C.target.value)})]})})}function Xa(e,t){return{...e,[ct]:t}}function $a(e){const t=e[N];if(!t)throw new Error("withOffPage: the field holds no authored text");return{...e,[N]:{...t,offPage:!0}}}function Va(e){return!e||typeof e!="object"?!1:e[N]?.offPage===!0}function ja(e){if(!e[N])throw new Error("withPanelOnly: the field holds no authored text");return{...e,[rr]:!0}}function za(e){return or(e)}function Ya(e){const t=e[N];if(!t)throw new Error("withIdentifier: the field holds no authored text");return{...e,[N]:{...t,identifier:!0}}}import{TEXT_CONTROL_KINDS as iu,SCALAR_TEXT_CONTROLS as su}from"efficient-easel/draw";function qa(e,t){if(!e[N])throw new Error("inOwnBox: the field holds no authored text");const{[er]:o,...r}=e;return{...r,[nr]:!0,render:t}}const Ki=new Set(fr),pe={type:"radio",options:[{value:!0},{value:!1}]},rn={text:{type:"object",objectFields:{text:{type:"text"},hidden:pe}},textarea:{type:"object",objectFields:{text:{type:"textarea"},hidden:pe}},plainText:{type:"text"},copyText:{type:"text"},plainTextarea:{type:"textarea"},textList:{type:"array",arrayFields:{text:{type:"text"}}}},X=(e,t)=>{const n=L({...t,[N]:e},{...rn[e.control],label:e.label});if(!Ki.has(e.control))return n;const o=t.render;return{...vt(n,"authored-copy"),render:r=>i(sr,{name:r.name,children:o(r)})}},Ja="Everything else on this block comes from the linked post. Unlink it to edit by hand.",Xi={field:"source.slug",set:!0},Za={not:Xi},$i="Select a word, then press the highlighter.",Vi=new Set([$i]),ji=e=>Vi.has(e);function Qa(e,t,n){return X({control:"text",label:e,placeholder:t,hint:n},{type:"custom",render:({value:o,onChange:r})=>i(K,{value:o,onChange:r,label:e,placeholder:t,hint:n})})}function ec(e,t,n){return X({control:"textarea",label:e,placeholder:t,hint:n},{type:"custom",render:({value:o,onChange:r})=>i(K,{value:o,onChange:r,label:e,placeholder:t,hint:n,multiline:!0})})}function tc(e,t,n){return X({control:"plainText",label:e,placeholder:t,hint:n},{type:"custom",render:({value:o,onChange:r})=>i(K,{value:o,onChange:r,label:e,placeholder:t,hint:n,hideable:!1,markup:!1})})}function nc(e,t,n){return X({control:"copyText",label:e,placeholder:t,hint:n},{type:"custom",render:({value:o,onChange:r})=>i(K,{value:o,onChange:r,label:e,placeholder:t,hint:n,hideable:!1})})}function oc(e){return{type:"custom",[lt]:{label:e},...L({},{type:"text",label:e}),render:({value:t,onChange:n})=>i(wr,{value:st(t),onChange:n,label:e})}}function rc(e,t,n){return X({control:"plainTextarea",label:e,placeholder:t,hint:n},{type:"custom",render:({value:o,onChange:r})=>i(K,{value:o,onChange:r,label:e,placeholder:t,hint:n,multiline:!0,hideable:!1})})}const ic={Design:qn,Animation:Zn};function sc(e){return{type:"custom",render:()=>i(zi,{text:e})}}function zi({text:e}){return i("p",{className:"sf-note",children:a(e)})}function lc(e){return ye(e)!==null&&e?.tabs!==void 0}const sn=new Map;function ac(e,t){const n=`${e}\0${t?t.join(""):""}`,o=sn.get(n)??{type:"custom",tabs:t,[Ce]:{label:e,level:1},bucket:e,marker:!0,render:()=>i(F,{})};return sn.set(n,o),o}const ln=new Map;function cc(e){const t=ln.get(e)??{type:"custom",[Ce]:{label:e,level:1},designGroup:e,marker:!0,...e==="Content"?{}:{fold:e},render:()=>i(F,{})};return ln.set(e,t),t}function Yi(e){const t=e;return t?.marker===!0&&typeof t.fold=="string"?t.fold:null}function uc(e,t){return Yi(e)===t?e:{...e,marker:!0,fold:t,render:()=>i(F,{})}}function dc(e){const t=e;if(t.marker===!0&&t.fold===void 0)return e;const{fold:n,...o}=e;return{...o,marker:!0,render:()=>i(F,{})}}function pc({title:e,children:t}){const[n,o]=Z(()=>!ze.has(e));return i(Ro,{title:e,open:n,onToggle:r=>{o(r),r?ze.delete(e):ze.add(e)},children:t})}const ze=new Set;function qi({swatches:e,current:t,onPick:n,names:o}){const r=e.find(c=>c.toLowerCase()===t.toLowerCase()),s=r?o?.[r]:void 0,l=s?a(s):t;return P("div",{className:"sf-swatches",children:[e.map(c=>{const u=o?.[c]?a(o[c]):c;return i(ke,{content:u,children:i(Uo,{color:c,selected:t.toLowerCase()===c.toLowerCase(),onClick:()=>n(c),"aria-label":u})},c)}),i("span",{className:"sf-swatch-hex",children:l})]})}function fc(e,t,n=!1){return{type:"custom",render:({value:o,onChange:r})=>i(Ji,{label:e,builtIn:t,followsBand:n,value:o,onChange:r})}}function Ji({label:e,builtIn:t,followsBand:n,value:o,onChange:r}){const s=typeof o=="string"?o:void 0,{colors:l,n:c}=Qe(),u={background:l.background,surface:l.surface,surface2:ti(l),band:ei(l)},d=n?Xe:t,h=mi(s,t,d),p=Qt(void 0,d,u),f=n?pi:void 0,m=d===Xe?a("the theme's section background"):a("Theme {n} background",{n:c}),g=Zi(s,t,l,c,u,r),b=U(p.toUpperCase(),m),S=Pe(s),w=S?le(S,l,c):null;return w?i(se,{label:a(e),icon:i(ft,{}),value:w.hex,caption:w.words,onChange:r,changed:!0,onReset:()=>r(f),resetTo:b,choices:g}):i(At,{label:a(e),icon:i(ft,{}),value:h?"":Qt(s,t,u),inherited:p,resetTo:b,onChange:r,onReset:()=>r(f),choices:g})}function Zi(e,t,n,o,r,s){const l=hi(e,t);return[{label:a("No fill"),color:"",selected:l==="none",onPick:()=>s(fi)},{label:`${a("Section band")} · ${r.band.toUpperCase()}`,color:r.band,selected:l==="band",onPick:()=>s(Xe)},...Ze(Pe(e)??"",n,o,s)]}function Qi(e,t){return{type:"custom",render:({value:n,onChange:o})=>{const r=n,s=ci(r,t);return i(_,{label:a(e),icon:i(Ee,{}),changed:!s,action:i(x,{words:y()?.panel,label:a(e),changed:!s,detail:a("the theme's image stage"),onReset:()=>o(ii)}),children:qi({swatches:ai,current:s?di:ui(r,t),onPick:o,names:li})})}}}function hc(e=n=>n,t){return ee({_gSectionTheme:T(gi),sectionAccent:{type:"custom",render:({value:n,onChange:o})=>i(gr,{value:e(n),onChange:o,followLabel:t})}})}function fe(e){const t=I(),n=nn(e?.view),o=l=>ve(e.valueKey,l),r=e.numbersIn??(l=>$(t[o(l)])!==void 0),s=e.followsView??hs(n,r);return Ti({props:{value:void 0,onChange:()=>{},field:{}},row:e.valueKey?e.row:void 0,table:Ri,label:a(e.label),grid:e.grid,hasOwn:r(n),view:{tier:n,numbersIn:r,followsView:s},convertTo:e.convertTo??(l=>{const c=$(t[o(n)]);return c===void 0?{}:{[o(n)]:l(c)}})})}function q({min:e,max:t,step:n,value:o,onChange:r,suffix:s="",readout:l=!0,notch:c,ariaLabel:u,disabled:d=!1,placeholder:h,placeholderWord:p,onClear:f,units:m}){const g=c!==void 0&&Number.isFinite(c)&&c>=e&&c<=t;return i("div",{className:g?"sf-slider has-notch":"sf-slider",style:g?{"--sf-notch":(c-e)/(t-e)}:void 0,children:i(Jo,{min:e,max:t,step:n,value:o,...o===null&&h!==void 0?{placeholderValue:h}:{},...p?{emptyLabel:a(p)}:{},suffix:s||void 0,...m?{units:m}:{},showInput:l,label:u===void 0?void 0:a(u),disabled:d,size:"sm",boxSize:"md",className:"sf-slider-track",onChange:b=>{b===null?f?.():b!==o&&r(b)}})})}function es(e,t){const{min:n,max:o,step:r=1,unsetLabel:s,hint:l,restTrack:c,unsetMark:u,icon:d,unit:h="px"}=t;return{type:"custom",render:({value:p,onChange:f})=>{const m=typeof p=="number"?p:null,g=m===null;return i(_,{label:a(e),icon:d?z(d):void 0,value:g?u||s===void 0?void 0:a(s):`${m}${h}`,changed:!g,action:u?_e(u,{changed:!g,onReset:()=>f(null)}):i(x,{words:y()?.panel,label:a(e),changed:!g,onReset:()=>f(null)}),hint:typeof l=="string"?a(l):l,children:c?c({min:n,max:o,step:r,px:m,label:e,onChange:f}):q({min:n,max:o,step:r,value:m??n,readout:!1,ariaLabel:e,onChange:f})})}}}const te="Corners",ts={kind:"radius"};function Ye(e){return{type:"custom",render:t=>{const{value:n,onChange:o}=t,r=typeof n=="number"&&Number.isFinite(n)?n:null,s=r!==null;return i(_,{label:a(te),icon:i(mt,{}),changed:s,action:_e(e.mark,{changed:s,onReset:()=>o(null)}),hint:e.hint,children:i(ns,{tier:e,px:r,name:t.name,onRadius:o})})}}}function R(e){const t=B();return[t?.values?.[e],n=>t?.onChange(e,n)]}function an(){return vt({type:"custom",render:()=>i(tr,{})},"always")}function he(){const e=B();return t=>e?.onChangeMany(t)}function ns({tier:e,px:t,name:n,onRadius:o}){const r=e.useFollowed(),[s,l]=R(e.sidesKey),c=he(),u=fe({row:e.row??ts,label:te,grid:{min:A,max:xe,step:e.step??1},valueKey:n??"",view:"desktop"}),d=Et(s)??[...Ot];return i(Ko,{label:a(te),value:d,corners:xo,onChange:h=>{const p=Et(h)??[];l(p.length===Ot.length?null:p)},radius:t,onRadiusChange:u&&n?h=>c({[n]:h,...u.unitPatch(h===null)}):o,radiusMin:u?.grid.min??A,radiusMax:u?.grid.max??xe,radiusStep:u?.grid.step??e.step??1,radiusPlaceholder:u&&u.unit!=="px"?"–":String(r),...u?{radiusUnit:u.unit,units:u.units}:{}})}function cn(e,t){return ue(e,t)}function un(){return an()}function os({label:e,changed:t=!1,onReset:n=()=>{}}){const{cornerRadiusPx:o}=G(),r=typeof o=="number"?`${o}px`:a("not set");return i(x,{words:y()?.panel,label:a(e),changed:t,detail:o==null?a("the built-in corners"):U(r,a("Styles")),onReset:n})}function rs(){const{cornerRadiusPx:e}=G();return typeof e=="number"?e:A}function is(){return Ye({sidesKey:"sectionCornerSides",row:It,useFollowed:rs,mark:i(os,{label:te}),hint:ss})}const ss="Follows Styles ▸ Basics ▸ Corners until you set a number here.";function mc(){return ee({_gShape:T("Shape"),sectionCorners:is(),...cn(It,"sectionCorners"),sectionCornerSides:un(),...D("sectionBorder",fs),...ue(jt,"sectionBorder",{tablet:!0,phone:!0})})}const ls=()=>({width:a("Border width"),sides:{top:a("Border top"),right:a("Border right"),bottom:a("Border bottom"),left:a("Border left")},style:a("Border style"),styles:{solid:a("Solid"),dashed:a("Dashed"),dotted:a("Dotted")},color:a("Border color"),unit:"px"});function as(e){const t=Object.fromEntries(Object.entries(e).filter(([,n])=>n!=null&&n!==""));return Object.keys(t).length?t:void 0}function cs(){let e;try{const t=Yt(G().theme);e=t.themes[t.selected]?.line}catch{e=void 0}return e||Zr.line}function us({value:e,onChange:t,placeholder:n,presets:o,sides:r=!0,styles:s=!0,above:l={},length:c}){const u=e&&typeof e=="object"?e:{},[d,h]=Z(()=>r?Ao(u,l):!1),p=ls(),f=m=>as(r&&s?m:{width:m.width,color:m.color,...s?{style:m.style}:{}});return i(_,{label:a("Border"),icon:i(Qn,{}),action:r?i(Po,{each:d,label:a("Each side"),onChange:h}):void 0,children:i(ko,{label:a("Border"),value:u,each:d,onChange:m=>t(f(m)),placeholder:n,presets:o,words:c?{...p,unit:c.unit}:p,styles:s,max:c?.grid.max??Vt,...c?{step:c.grid.step,units:c.units}:{}})})}function ds({value:e,onChange:t,view:n}){const[o]=R("sectionBorder"),[r]=R(Le("sectionBorder")),s=cs(),l=f=>f&&typeof f=="object"?f:{},c=n==="phone"?{...zt(l(o)),...zt(l(r))}:n==="tablet"?l(o):{},u=I(),d=he(),h=O("sectionBorder",n),p=fe({row:jt,label:"Border",grid:{min:0,max:Vt,step:1},valueKey:"sectionBorder",view:n,numbersIn:f=>qe(u[ve("sectionBorder",f)]),convertTo:f=>{const m=l(u[h]);return qe(m)?{[h]:ps(m,f)}:{}}});return i(us,{value:e,length:p,onChange:p?f=>d({[h]:f,...p.unitPatch(!qe(f))}):t,placeholder:{sides:Fo(c),style:c.style??"solid",color:c.color||s},presets:[s],above:c})}const dn=["width",...Jr];function qe(e){if(!e||typeof e!="object")return!1;const t=e;return dn.some(n=>$(t[n])!==void 0)}function ps(e,t){const n={...e};for(const o of dn){const r=$(n[o]);r!==void 0&&(n[o]=t(r))}return n}function fs(e){return{type:"custom",render:({value:t,onChange:n})=>i(ds,{value:t,onChange:n,view:e})}}function hs(e,t){let n=je[e];for(;n&&je[n]!==null&&!t(n);)n=je[n];return n??e}function gc(e){return{type:"custom",render:()=>i(ms,{partKey:e})}}function ms({partKey:e}){const[t]=R("id"),[n]=R("_partStyles"),{textStyles:o}=G(),r=xr();let s=null;try{s=_r().select}catch{s=null}const l=n&&typeof n=="object"?n[e]:void 0,c=Array.isArray(o)?o:null;return i(To,{name:a("Text"),preview:Sr(l,c,{noStyle:a("No style"),styleName:r.textStyles.styleName,cases:(r.copy.panel??yr.copy.panel).cases}),onOpen:()=>{s&&typeof t=="string"&&s(Cr(t,e))}})}function pn(e){const{cornerRadiusPx:t}=G(),n=typeof t=="number"?t:e;let o=null;try{const{appState:s,selectedItem:l}=re(u=>u),c=l?.props?.id?String(l.props.id):void 0;o=c?Eo(s?.data,c)?.props??null:null}catch{o=null}if(!o)return n;const r=o.sectionCorners;return Oo(r)?r:n}function gs({label:e,changed:t=!1,onReset:n=()=>{}}){const o=pn(A);return i(x,{words:y()?.panel,label:a(e),changed:t,detail:U(`${o}px`,a("the section")),onReset:n})}function bs(){return i(F,{children:a("Follows the section's Corners until you set a number here.")})}function ws(){return Ye({sidesKey:"cardCornerSides",row:Tt,useFollowed:()=>pn(A),mark:i(gs,{label:te}),hint:i(bs,{})})}function Ss(){return{type:"custom",render:()=>i(Ln,{})}}function bc(){return{_gShape:T("Shape"),cardCorners:ws(),...cn(Tt,"cardCorners"),cardCornerSides:un(),cardCornersApplyAll:Ss()}}function _s(){return L({type:"custom",render:e=>i(ys,{...e})},{type:"select",label:j,options:[{value:"content",label:"Fit content"},{value:"equal",label:"Equal"},{value:[50],label:"Custom: the width of each block in %, the last block left out"}]})}function Cs(e,t){const n=$t(e);if(n!=="custom")return a(Xt.find(r=>r.value===n)?.label??"");const o=kt(Me(e,t),t);return o?[...o,100-o.reduce((r,s)=>r+s,0)].join(" / "):a("Custom")}function ys(e){const{value:t,onChange:n}=e,[o]=R("content"),r=Array.isArray(o)?o.length:0,s="follows"in e,l=t!=null,c=l?t:s?e.follows:void 0,u=$t(c),d=r>=2&&r<=Nt,h=()=>[...zo[r]??[]],p=J(null),f=w=>{const C=p.current;C&&JSON.stringify(w)===JSON.stringify(C.shares)?n(C.value):w&&n(w)},m=w=>{w===u||w==="custom"&&!d||n(w==="custom"?h():w)},g=a("The width bar works for 2 to {count} blocks.",{count:Nt}),b=l&&(s||t!=="content"),S=qo().widths.hint(r,jo);return i(_,{label:a(j),icon:i(Ie,{}),changed:b,hint:u!=="custom"?void 0:d?S:g,action:i(x,{words:y()?.panel,label:a(j),changed:b,disabled:e.readOnly===!0,detail:s?M(w=>a(w),Cs(e.follows,r),e.followsView):a("Fit content"),onReset:()=>n(void 0)}),children:P("div",{className:"sf-share-row",children:[i("div",{className:"sf-share-pick",children:i(Rt,{label:a(j),value:u,options:Xt.map(w=>({value:w.value,label:w.value==="custom"&&!d?g:a(w.label),icon:Pi(i("span",{className:"sf-gallery-pic sf-share-pic",children:fn(w.weights).map((C,v)=>i("i",{style:{gridColumn:`span ${C}`}},v))}),a(w.label),w.value==="custom"&&!d?g:a(w.label))})),onChange:m,columns:3,cell:hn,tooltips:!1,disabled:e.readOnly===!0})}),u==="custom"&&d?i("div",{onFocus:()=>{p.current={value:t,shares:kt(Me(c,r),r)}},onBlur:()=>{p.current=null},children:i(Yo,{label:a(j),count:r,value:Me(c,r),onChange:f,readOnly:e.readOnly===!0})}):null]})})}function fn(e){if(!e)return[3,4];const t=e.reduce((n,o)=>n+o,0);return e.map(n=>Math.round(n/t*12))}function wc(){return Y(Vr,i(so,{}),Wt,Wt[0].value)}function Sc(){return E("mobile",ki(j,i(Ie,{}),qr.map(e=>({label:e.label,value:e.value,picture:i("span",{className:"sf-gallery-pic sf-share-pic",children:fn(e.weights).map((t,n)=>i("i",{style:{gridColumn:`span ${t}`}},n))})})),Yr,{columns:2,cell:hn}))}const hn={width:"5.75rem",height:"3.25rem"};function _c(){return $e("share",_s(),tn)[Le("share")]}function xs(){return E("mobile",W(Ut,i(ht,{}),Ge,zr,1,Ge,"",{clear:{phoneFollows:!1,hint:Ge}}))}const mn={read:e=>e.phoneRow,write:(e,t,n)=>({phoneRow:n}),fieldKey:()=>"phoneRow",ownField:!0};function Cc(){const e=W(Ut,i(ht,{}),Kt,jr,1,Kt,"",{clear:{emptyLabel:"Auto"}}),t=$e("columns",e,{...mn,tablet:tn.tablet}),n=$e("columns",e,mn,{phoneRow:xs()});return{...t,phoneRow:n.phoneRow}}function yc(e,t,n,o,r,s,l){return{type:"custom",render:({value:c,onChange:u,name:d})=>i(Os,{label:e,min:t,max:n,step:o,fallback:r,role:s,value:c,onChange:u,name:d??"",length:l})}}function Os({label:e,min:t,max:n,step:o,fallback:r,role:s,value:l,onChange:c,name:u,length:d}){const h=I(),p=he(),f=nn(d?.view),m=fe({row:d?.row??{kind:"fontSize"},label:e,grid:{min:t,max:n,step:o},valueKey:d?u:"",view:d?.view??"desktop",numbersIn:b=>b===f&&typeof h[u]=="number",followsView:f,convertTo:b=>typeof h[u]=="number"?{[u]:b(h[u])}:{}}),g=b=>m?p({[u]:b,...m.unitPatch(typeof b!="number")}):c(b);return i(_,{label:a(e),icon:i(yt,{noun:s}),action:i(x,{words:y()?.panel,label:a(e),changed:!Si(l),detail:a("the Text style in Styles"),onReset:()=>g(wi),defaultAction:{onPress:()=>g(bi),title:a("Keep this section's own built-in size"),icon:i(eo,{})}}),children:q({min:m?.grid.min??t,max:m?.grid.max??n,step:m?.grid.step??o,value:typeof l=="number"?l:r,...m?{suffix:m.unit,units:m.units}:{suffix:"px"},ariaLabel:e,onChange:g})})}function xc(){return{_gCellWidth:T("Cell width"),gridSpan:Y("Positions",i(Ie,{}),[{label:"Auto",value:""},...Array.from({length:Mn},(e,t)=>({label:t===0?"1 position":`${t+1} positions`,value:String(t+1)}))],"")}}function I(){let e=null,t=null;try{e=nt(Is),t=re(n=>n).selectedItem}catch{t=null}return e??t?.props??{}}const Is=xn(null);function Es({min:e,max:t,step:n,px:o,label:r,onChange:s,desktopKey:l,fallback:c}){const u=I()[l],d=Ae(void 0,u,c);return i(F,{children:q({min:e,max:t,step:n,value:Ae(o,u,c),readout:!1,ariaLabel:r,notch:d,onChange:s})})}function Ts({label:e,desktopKey:t,fallback:n,unit:o="px",changed:r=!1,onReset:s=()=>{}}){const l=I()[t],c=Ae(void 0,l,n);return i(x,{words:y()?.panel,label:a(e),changed:r,detail:M(u=>a(u),`${c}${o}`),onReset:s})}function Rs(e){return es(e.label,{icon:e.icon,min:e.min,max:e.max,step:e.step,unit:e.unit,unsetLabel:"Follows Desktop",unsetMark:i(Ts,{label:e.label,desktopKey:e.desktopKey,fallback:e.fallback,unit:e.unit}),restTrack:t=>i(Es,{...t,desktopKey:e.desktopKey,fallback:e.fallback})})}const Ns={Top:"Padding top",Bottom:"Padding bottom",Left:"Padding left",Right:"Padding right"},ks={Top:Te,Bottom:wt,Left:St,Right:_t},Ps=e=>{const t=ks[e];return i(t,{})};function Oc(e={}){const t=e.keys?.top??"sectionPaddingTop",n=e.keys?.bottom??"sectionPaddingBottom",o=e.group!==!1,r=S=>Ns[S],s=S=>W(r("Top"),i(Te,{}),k.min,k.max,k.step,S,"px"),l=(S,w,C,v=k)=>E("mobile",Rs({label:r(S),icon:Ps(S),desktopKey:w,min:v.min,max:v.max,step:v.step,fallback:C})),c=e.top??k.min,u=e.bottom??k.min,d="sectionPaddingLeft",h="sectionPaddingRight",p=e.sideBounds??k,f=e.side??p.min,m=e.sidePhone??f,g=e.phone===!0,b=S=>g?E("desktop",S):S;return ee({...o?{_gSpacing:T("Padding")}:{},[t]:b(s(c)),...g?{[V(t)]:l("Top",t,c)}:{},...e.only==="top"?{}:{[n]:b(W(r("Bottom"),i(wt,{}),k.min,k.max,k.step,u,"px")),...g?{[V(n)]:l("Bottom",n,u)}:{}},...e.sides?{[d]:b(W(r("Left"),i(St,{}),p.min,p.max,p.step,f,"px")),...g?{[V(d)]:l("Left",d,m,p)}:{},[h]:b(W(r("Right"),i(_t,{}),p.min,p.max,p.step,f,"px")),...g?{[V(h)]:l("Right",h,m,p)}:{}}:{}})}function Ic(e,t){const n=Object.fromEntries(Object.entries(t).map(([s,l])=>[s,s in e&&ye(l)?e[s]:l])),o={};let r=!1;for(const[s,l]of Object.entries(e)){if(s in t){r||Object.assign(o,n),r=!0;continue}o[s]=l}return r||Object.assign(o,n),o}const me="Width";function Ec(e,t=_i,n=!0){const o=t.map(r=>({label:Ci[r],value:r}));return ee({...n?{_gWidth:T(me)}:{},widthMode:{type:"custom",render:({onChange:r,field:s})=>i(_,{label:a(me),icon:i(go,{}),action:n?i(Ui,{inherited:s?.inherited??!1,onReset:()=>r(yi),label:me}):void 0,children:de({options:o,value:s?.currentValue||e,onChange:r,ariaLabel:me})})}})}function Tc({fill:e=!1}={}){const t=(r,s)=>({type:"custom",render:({value:l,onChange:c})=>i(Fs,{value:l,onChange:c,view:r,badge:s,fill:e})}),n=()=>Fe("sectionHeightMode"),o=()=>Fe("sectionHeightMode");return ee({_gHeight:T(Q),...D("sectionHeightMode",r=>r==="desktop"?t(r):t(r,s=>i(Bs,{view:r,onClear:()=>s(void 0)}))),...D("sectionHeightValue",n),...D("sectionHeightUnit",o)})}function Fs({value:e,onChange:t,view:n,badge:o,fill:r=!1}){const s=I(),{mode:l,number:c,unit:u}=As(n,s,e);return i(_,{label:Q,icon:z(i(gt,{})),action:o?o(t):void 0,children:P("div",{className:"es-width-stack",children:[de({options:[{label:"Auto",value:"auto"},{label:"Fixed",value:"fixed"},{label:"Screen",value:"screen"},...r?[{label:"Fill",value:"fill"}]:[]],value:l,onChange:t,ariaLabel:Q}),c?i(vs,{view:n,mode:l,menu:u}):null]})})}function gn(e,t){return e==="phone"&&Be(t)?Er(t):Ir(t)}function ge(e,t){return e==="desktop"||(e==="tablet"?Be(t):Or(t))?null:gn(e,t)}function As(e,t,n){const r=(s=>Ur.includes(s))(n)?n:ge(e,t)?.mode??"auto";return{mode:r,number:r!=="auto"&&r!=="fill",unit:r==="fixed"}}function Ls(e,t,n,o){const r=ge(e,t);return!r||e==="desktop"?null:o===void 0?{}:{[O("sectionHeightMode",e)]:r.mode,...r.mode==="fixed"?{[O("sectionHeightUnit",e)]:r.unit}:{},...n==="sectionHeightUnit"?{[O("sectionHeightValue",e)]:r.value}:{},[O(n,e)]:o}}function bn(e,t,n){const o=B(),r=ge(e,I());return!o||!r?{followed:null,write:n}:{followed:r,write:l=>o.onChangeMany(c=>{const u=Ls(e,c,t,l);return u===null?{[O(t,e)]:l}:Object.keys(u).length?u:null})}}function vs({view:e,mode:t,menu:n}){const o=B(),r=I(),s=O("sectionHeightValue",e),l=O("sectionHeightUnit",e),c=S=>w=>o?.onChangeMany(()=>({[S]:w})),{followed:u,write:d}=bn(e,"sectionHeightValue",c(s)),{write:h}=bn(e,"sectionHeightUnit",c(l)),p=t==="screen"?"%":r[l],f=(u?u.unit:p)==="%"?"%":"px",m=f==="%"?Xr:Kr,g=r[s],b=n?{options:["px","%"],label:a("Unit"),onChange:S=>h(S)}:void 0;return q({min:m.min,max:m.max,step:m.step,value:u?null:typeof g=="number"?g:m.fallback,...u?{placeholder:u.value}:{},suffix:f,...b?{units:b}:{},ariaLabel:Q,onChange:d})}function Bs({view:e,onClear:t}){const n=I(),o=ge(e,n)===null,r=e==="phone"&&Be(n),s=gn(e,n),l=M(c=>a(c),s.mode==="auto"?a("Auto"):`${s.value}${s.unit}`,r?"tablet":"desktop");return i(x,{words:y()?.panel,label:a(Q),changed:o,detail:l,onReset:t})}function Rc(e={}){const t=e.intro===!0,n=s=>({type:"custom",render:({value:l,onChange:c,id:u,name:d})=>i(Ks,{value:l,onChange:c,labelId:`${u??d??"stickTop"}-label`,view:s,intro:t})}),o=s=>({type:"custom",render:({value:l,onChange:c})=>i(Ms,{value:l,onChange:c,view:s,intro:t})}),r=s=>({type:"custom",render:({value:l,onChange:c})=>i(Ws,{value:l,onChange:c,view:s,intro:t})});return{_gStick:T(Pr,{dot:t?Gs:Gt}),...D("stickTop",n),...D("stickTopDistance",o),...ue(He,"stickTopDistance",{tablet:!0,phone:!0}),...e.screens?D(De,r):{},...t?{}:{[Lr]:Ds()},...t||e.above===!1?{}:{[Nr]:Hs()}}}function Ds(){const e=Y(vr,i(Te,{}),Br,Fr);return E("desktop",{...e,render:t=>{const n=e.render({...t,value:Gr(t.value),onChange:o=>t.onChange(Mr(o))});return _e(n,{hint:a(Ar)})}})}function Hs(){const e=_n(kr,!1,i(Ct,{}),Rr);return E("desktop",{...e,render:t=>e.render({...t,onChange:n=>t.onChange(n===!0?!0:void 0)})})}const Gs={any:[Gt,Tr]};function wn(e,t,n,o,r){const s=B(),l=I(),c=e==="desktop"||ne(e,l)?null:Je(e,ae(l,{intro:o}));return{followed:c,write:(c||r)&&s?d=>s.onChangeMany(h=>{const p=Us(e,h,d,t,o),f=p===null?{[O(t,e)]:d}:p;return Object.keys(f).length?{...f,...r?.(d)??{}}:null}):n}}function Ms({value:e,onChange:t,view:n,intro:o}){const r=I(),s=ae(r,{intro:o}),l=h=>{const p=Ai(h);return p==="desktop"||ne(p,r)},c=fe({row:He,label:"Distance from top",grid:{min:H.min,max:H.max,step:H.step},valueKey:"stickTopDistance",view:n,numbersIn:h=>l(h)&&$(r[ve("stickTopDistance",h)])!==void 0,followsView:n==="phone"&&s.ownTablet?"tablet":"desktop"}),{followed:u,write:d}=wn(n,"stickTopDistance",t,o,c?h=>c.unitPatch(h===void 0):void 0);return i("div",{className:"sf-field",children:q({min:c?.grid.min??H.min,max:c?.grid.max??H.max,step:c?.grid.step??H.step,value:u?null:typeof e=="number"?e:H.fallback,...u?{placeholder:u.distance}:{},...c?{suffix:c.unit,units:c.units}:{suffix:"px"},ariaLabel:a("Distance from top"),onChange:d})})}function Ws({value:e,onChange:t,view:n,intro:o}){const{followed:r,write:s}=wn(n,De,t,o);return i(_,{label:a(Ht),icon:z(i(gt,{})),children:q({min:ie.min,max:ie.max,step:ie.step,value:r?null:$(e)??ie.default,...r?{placeholder:r.screens}:{},ariaLabel:a(Ht),onChange:s})})}function ne(e,t){return e==="tablet"?Hr(t):Dr(t)}function Je(e,t){return e==="phone"?{on:t.tablet,distance:t.tabletDistance,unit:t.tabletUnit,screens:t.tabletScreens}:{on:t.desktop,distance:t.desktopDistance,unit:t.desktopUnit,screens:t.desktopScreens}}function Us(e,t,n,o="stickTopDistance",r=!1){if(e==="desktop"||ne(e,t))return null;if(n===void 0)return{};const s=Je(e,ae(t,{intro:r})),l=e==="phone"&&ne("tablet",t)?h=>O(h,"tablet"):h=>h,c=(h,p)=>t[l(h)]==null?{}:{[O(h,e)]:p},u=He.unitKey,d=t[l(u)]==null?{}:{[O(u,e)]:s.unit};return{[O("stickTop",e)]:!0,...c("stickTopDistance",s.distance),...d,...c(De,s.screens),[O(o,e)]:n}}function Ks({value:e,onChange:t,labelId:n,view:o,intro:r}){const s=I(),l=ae(s,{intro:r}),c=o==="phone"?l.phone:o==="tablet"?l.tablet:r?l.desktop:e===!0,u=o==="phone"&&l.ownTablet,d=o==="desktop"?null:Je(o,l),h=d?.on?Wr(d.distance,d.unit):a("Off");return i(_,{label:a(Dt),labelId:n,icon:z(i(Ct,{})),action:P(F,{children:[o!=="desktop"?i(x,{words:y()?.panel,label:a(Dt),changed:ne(o,s),detail:M(p=>a(p),h,u?"tablet":"desktop"),onReset:()=>t(void 0)}):null,i(Ne,{checked:c,onChange:t,ariaLabelledBy:n})]})})}const Sn="e.g. about";function Nc(){return{_gAnchor:T("Anchor"),anchor:X({control:"plainText",label:"Name",placeholder:Sn},{type:"custom",render:({value:e,onChange:t})=>i(zn,{value:e,onChange:t,nameBox:(n,o)=>i(K,{value:n,onChange:o,label:"Name",placeholder:Sn,hideable:!1,markup:!1})})})}}function kc(e,t,n){return{type:"custom",render:({value:o,onChange:r,id:s,name:l})=>{const c=`${s??l??e}-datetime`,u=Date.parse(typeof o=="string"?o:"");return i(_,{label:a(e),icon:t,htmlFor:c,hint:n===void 0?void 0:a(n),children:i($o,{id:c,value:Number.isFinite(u)?new Date(u):null,onChange:d=>r(d?d.toISOString():"")})})}}}function Pc(e,t,n){return{type:"custom",render:({value:o,onChange:r,id:s,name:l})=>{const c=`${s??l??e}-date`;return i(_,{label:a(e),icon:t,htmlFor:c,hint:n===void 0?void 0:a(n),children:i(Xo,{id:c,value:En(typeof o=="string"?o:null),onChange:u=>r(u?In(u):"")})})}}}function _n(e,t,n,o){return{type:"custom",...L({},{...pe,label:e}),render:r=>{const{value:s,onChange:l,id:c,name:u}=r,d="follows"in r,h=r,p=typeof s=="boolean",f=typeof h.follows=="boolean"?h.follows:t,m=p?s:d?f:t,g=`${c??u??e}-label`,b=h.readOnly===!0,S=i(Ne,{checked:m,onChange:l,disabled:b,ariaLabelledBy:g});return i(_,{label:a(e),labelId:g,icon:n,hint:o===void 0?void 0:a(o),action:d?P(F,{children:[i(x,{words:y()?.panel,label:a(e),changed:p,detail:h.followsNoView?a(f?"On":"Off"):M(w=>a(w),a(f?"On":"Off"),h.followsView),disabled:b,onReset:()=>l(void 0)}),S]}):S})}}}function Fc(){return{type:"custom",render:({value:e,onChange:t,id:n,name:o})=>{const r=`${String(n??o??"pageBackground")}-colour`;return i(Xs,{label:"Background",icon:i(po,{}),id:r,value:e,shown:bo(e),onChange:t})}}}function Ac(e,t,n){return{type:"custom",render:({value:o,onChange:r})=>i(se,{label:a(e),icon:n,value:o||t,onChange:r})}}function Xs({label:e,icon:t,id:n,value:o,shown:r,onChange:s}){const{colors:l,n:c}=Qe(),u=Pe(o),d=u?le(u,l,c):null;return i(se,{label:a(e),icon:t,id:n,value:d?d.hex:r,caption:d?.words,onChange:s,choices:Ze(u??"",l,c,s)})}function Lc(){return{type:"custom",render:e=>{const{value:t,onChange:n}=e,o=e;return i($s,{value:typeof t=="string"?t:"",onChange:n,twin:"follows"in e?{follows:o.follows,view:o.followsView}:void 0})}}}function Ze(e,t,n,o){const r=Re(e);return Qo(t,n).map(s=>({label:s.label,color:s.value,selected:r===s.name,onPick:()=>o(s.name)}))}function $s({value:e,onChange:t,twin:n}){const{colors:o,n:r}=Qe(),s=o.background,l=U(s.toUpperCase(),a("Theme {n} background",{n:r})),[c,u]=R(wo),[d]=R(_o),h=typeof d=="string"&&d.trim()!=="",p=xt(c),f=oe=>u(xt(oe)||void 0),m=Re(e),g=m?le(m,o,r):null,b=Ze(e,o,r,t),S=n?()=>t(void 0):()=>t("");let w=s,C=l;if(n){const oe=Re(n.follows),we=Co(n.follows),Se=oe?le(oe,o,r):we?{hex:we,words:we.toUpperCase()}:null;w=Se?.hex??s,C=M(yn=>a(yn),Se?Se.words:l,n.view)}const v=!n&&(yo(e)||h)?i(Vs,{value:p,onChange:f}):null;return g?i(se,{label:a("Fill"),icon:i(Ee,{}),value:g.hex,caption:g.words,onChange:t,changed:!0,onReset:S,resetTo:C,choices:b,children:v}):i(At,{label:a("Fill"),icon:i(Ee,{}),value:e,inherited:w,resetTo:C,onChange:t,onReset:S,choices:b,children:v})}function Vs({value:e,onChange:t}){return de({options:So.map(n=>({label:n.label,value:n.value,hint:n.hint})),value:e,onChange:t,ariaLabel:a("Fill")})}function js(e,t,n){if((e?.content??[]).some(l=>l?.props?.id===t))return ce(n);const r=Io(e,t);if(r.length===0)return null;const s=ce(en(n));if(s!==null)return s;for(let l=r.length-1;l>0;l-=1){const c=ce(en(r[l].sectionAccent));if(c!==null)return c}return ce(r[0].sectionAccent)}function Qe(){const e=Yt(G().theme),[t]=R("sectionAccent");let n=null;try{const{appState:r,selectedItem:s}=re(c=>c),l=s?.props?.id?String(s.props.id):void 0;n=l?js(r?.data,l,t):null}catch{n=null}const o=n!==null&&e.themes[n]?n:e.selected;return{colors:Qr(e.themes[o]),n:o+1}}function vc(){return an()}const Bc={top:i(ro,{}),right:i(oo,{}),bottom:i(to,{}),left:i(no,{})};function Dc(e,t,n,o,r,s,l){const c=p=>t.find(f=>f.value===p),u=p=>({value:p,label:"",disabled:!0,title:o}),d=p=>{const f=t.find(g=>g.cell===p);if(!f)return u(`missing-${p}`);const m=s?.[p];return m?{value:f.value,label:f.label,icon:m}:{value:f.value,label:f.label}},h=[u("corner-top-left"),d("top"),u("corner-top-right"),d("left"),u("centre"),d("right"),u("corner-bottom-left"),d("bottom"),u("corner-bottom-right")];return{type:"custom",render:({value:p,onChange:f})=>{const m=t.some(g=>g.value===p)?p:n;return i(_,{label:a(e),icon:r,value:c(m)?.label?a(c(m).label):l?a(l):"",children:Ei(a,{label:e,value:m,onChange:f,points:h})})}}}function Hc(e,t,n){return{type:"custom",options:t,render:({value:o,onChange:r,field:s})=>i(mr,{label:e,options:(s.options??t).map(l=>({...l,label:a(l.label)})),value:Array.isArray(o)?o:[],onChange:r,...n?{emptyLabel:a(n)}:{}})}}function Gc(e,t,n,o){return{type:"custom",options:t,fallback:n,...L({},{type:"select",label:e}),render:({value:r,onChange:s,field:l})=>i(br,{label:e,options:(l.options??t).map(c=>({...c,label:a(c.label)})),fallback:l.fallback??n,value:r,onChange:s,placeholder:o===void 0?void 0:a(o)})}}function Mc(e,t={}){return{type:"custom",render:({value:n,onChange:o})=>{const r={value:n,onChange:o,...t};return i(e,{...r})}}}const Wc=[{label:"Image",value:"image"},{label:"Video",value:"video"}];function Uc(e,t,n){const o=Object.keys(rt).map(r=>({label:rt[r],value:r,picture:n[r]}));return{type:"custom",...L({},{type:"radio",label:e,options:o.map(r=>({value:r.value,label:r.label}))}),render:({onChange:r})=>i(Ys,{label:e,icon:t,options:o,onChange:r})}}function zs(e,t,n){const o=Tn(e,t,n);if(o!==void 0)return o==="save-makes-frame"?a("A frame is made from this video when you save the page."):o==="starts-dark"?a("This video starts dark, so no frame was made. The slide shows its background colour while the video loads. Choose Image to show a picture."):o==="outside"?a("This video is on another website, so no frame can be made. The slide shows its background colour while the video loads. Choose Image to show a picture."):o==="unsupported"?a("This video's file type gives no frame. The slide shows its background colour while the video loads. Choose Image to show a picture."):o==="failed"?a("No frame could be made from this video. It is tried again the next time you save the page. The slide shows its background colour while the video loads."):o==="image-no-frame"?a("The slide shows your Image while the video loads, because this video has no frame."):void 0;const r=Nn(e);return r==="frame-missing-image"?a("This video has no frame yet. The slide shows its image until one is made."):r==="frame-missing-surface"?a("This video has no frame yet. The slide shows its background colour until one is made."):r==="image-missing-frame"?a("No image yet. The slide shows the video's frame until you choose one."):r==="image-missing-surface"?a("No image yet. The slide shows its background colour until you choose one."):void 0}function Ys({label:e,icon:t,options:n,onChange:o}){const r=B(),s=r?.values??{},l=Rn(s),c=nt(Fn),u=Pn(c?.docId??null);let d=null;try{d=re(p=>p.appState.data)}catch{d=null}const h=kn(r?.id,d,u);return i(_,{label:a(e),icon:z(t),hint:zs(s,h,c?.hasUnsavedEdits??!1),children:de({options:n,value:l,onChange:o,ariaLabel:e})})}function Kc(e,t,n,o={}){const r={type:"custom",[at]:!0,render:({value:s,onChange:l,name:c})=>i(hr,{value:s||"",onChange:l,fieldKey:c,label:e,accept:t,placeholder:n,focusKey:o.focus,focusWhen:o.focusWhen,frameKey:o.frame}),...o.focus?{focusKey:o.focus}:{},...o.focusWhen?{focusWhen:o.focusWhen}:{}};return o.focus?E("each",r):r}const Xc={HeroSingle:["imageFocal"],HeroSlide:["videoFrame","videoFramePhone"],ContactLocations:["locations[].photo"],ProcessSteps:["steps[].image"]};function qs(e){const t=a(e.status??"");return e.ok&&typeof e.lat=="number"&&typeof e.lng=="number"?`${t} · ${e.lat.toFixed(4)}, ${e.lng.toFixed(4)}`:t}function $c({value:e,onChange:t,label:n}){const o=e||{},r=B(),s=r?r.values!==r.node.props:!0,l=!!o.pending&&s,c=!!o.pending&&!s,u=!!Oi(xi()).geocode,d=ot(),h=(p,f)=>t({...o,[p]:f??void 0});return P(F,{children:[i(_,{label:a(n),icon:i(bt,{}),action:u?i(ke,{content:a("Find from the address (OpenStreetMap)"),children:i(Pt,{"aria-label":a("Find from the address"),"aria-busy":l||void 0,disabled:l,onClick:()=>t({...o,pending:!0,ok:!1,status:"Finding…"}),children:i(fo,{})})}):void 0,children:u&&o.status?i(Yn,{compact:!0,oneLine:!0,spaced:!1,status:l?"busy":o.ok&&!c?"found":"notfound",statusText:l?a("Finding…"):c?a(Zo):a(o.status),hint:qs(o)}):null}),i(_,{label:a("Enter by hand"),labelId:d,icon:i(io,{}),action:i(Ne,{checked:!!o.manual,onChange:p=>t({...o,manual:p}),ariaLabelledBy:d})}),o.manual&&i(_,{label:a("Latitude, longitude"),icon:i(bt,{}),children:P("div",{style:{display:"grid",gridTemplateColumns:"1fr 1fr",gap:8,width:"100%",minWidth:0},children:[i(Ft,{value:typeof o.lat=="number"?o.lat:null,onChange:p=>h("lat",p),min:-90,max:90,step:1e-4,placeholder:a("Latitude")}),i(Ft,{value:typeof o.lng=="number"?o.lng:null,onChange:p=>h("lng",p),min:-180,max:180,step:1e-4,placeholder:a("Longitude")})]})})]})}function Js(e,t){return t===null||t<0||t>=e.length?"":e[t]?.text??""}function Zs(e,t,n){const o=e.map(r=>({text:r?.text??""}));return t===null||t<0||t>=e.length?o:o.map((r,s)=>s===t?{text:n}:r)}function Vc(e,t){return e===null?null:t>e?e:null}function Qs(e,t,n){if(n===null||n>=t.length)return null;for(let o=0;o<n;o+=1)if(e[o]!==t[o])return null;return e[n]!==t[n]&&t.includes(e[n])||e[n]!==t[n]&&t.length!==e.length?null:n}const jc={label:"Ticker items",icon:i(uo,{})};function zc(e,t,n,o){return{type:"custom",[N]:{control:"textList",label:e,placeholder:n,itemKey:"text",rendering:o},...L({},{...rn.textList,label:e}),render:({value:r,onChange:s})=>i(el,{label:e,icon:z(t),items:Array.isArray(r)?r:[],placeholder:n,onChange:s,markup:o==="markup"})}}function el({label:e,icon:t,items:n,placeholder:o,onChange:r,markup:s=!1}){const l=J(null),[c,u]=Z(null),d=p=>p.map(f=>({text:f?.text??""})),h=p=>{const f=Qs(n,p,c);f===null&&(l.current=null),u(f),r(d(p))};return i(Lo,{label:a(e),icon:t,noun:a("item"),items:n,onChange:h,newItem:()=>({text:""}),open:null,onOpen:()=>{},renderItem:()=>null,above:s?i(Lt,{target:l,value:Js(n,c),onChange:p=>r(Zs(n,c??-1,p)),disabled:c===null,label:c===null?a("Formatting — click a row first"):a("Formatting — row {n}",{n:c+1})}):void 0,renderRow:(p,f,m)=>i("input",{type:"text",className:s&&c===f?"sf-list-marking":void 0,value:p?.text??"",placeholder:a(o),"aria-label":a("{label} {n}",{label:a(e),n:f+1}),onChange:g=>m({text:g.target.value}),onFocus:g=>{l.current=g.currentTarget,u(f)}})})}function Yc(e,t){const n=`${e.label} — row ${t+1}`;return X({control:"plainText",label:n,placeholder:e.placeholder,offPage:e.offPage},{type:"custom",render:({value:o,onChange:r})=>i(K,{value:o,onChange:r,label:a("{label} — row {n}",{label:a(e.label),n:t+1}),placeholder:e.placeholder,hideable:!1,markup:e.rendering==="markup"})})}function qc(e){return{_gCards:T("Cards"),coverIndex:Y("Cover image",i(co,{}),dr,String(pr),e?.coverHint??"A card's opening picture — a card pinned to a finish keeps its own."),imageBackground:Qi("Image background",si),cardImage:Cn()}}function Jc(){return{outline:Y("Card outline",i(ho,{}),ar,ur),indexBadge:Y("Card number",i(ao,{}),lr,cr),showBadge:_n("Product badge",!0,i(yt,{noun:"tag"}))}}function Zc(e){const t=e?.defaults??{showCardSizes:!0,showCardBuy:!0,showCardPage:!0},n=r=>({...pe,label:be.find(s=>s.id===r).label}),o=r=>L(Fe(et),n(r));return{_gShowOnCard:T("Show on a card"),[et]:L({type:"custom",render:()=>i(tl,{rest:{showCardPrice:!0,showCardFinishes:!0,...t}})},n(et)),showCardFinishes:o("showCardFinishes"),showCardSizes:o("showCardSizes"),showCardBuy:o("showCardBuy"),showCardPage:o("showCardPage")}}const et="showCardPrice",be=[{id:"showCardPrice",label:"Price"},{id:"showCardFinishes",label:"Finish swatches"},{id:"showCardSizes",label:"Sizes"},{id:"showCardBuy",label:"Buy button"},{id:"showCardPage",label:"Page button"}];function tl({rest:e}){const t=I(),n=he(),o=l=>typeof t[l]=="boolean"?t[l]:void 0,r=l=>o(l)??e[l],s=be.some(({id:l})=>o(l)!==void 0&&o(l)!==e[l]);return i(tt,{parts:be,changed:s,shown:r,onPress:(l,c)=>n({[l]:c}),onReset:()=>n(Object.fromEntries(be.map(({id:l})=>[l,void 0])))})}function Qc(e,t="display"){const n=V(t);return{[t]:E("desktop",{type:"custom",render:({value:o,onChange:r})=>i(tt,{parts:e,changed:Bo(o),shown:s=>Do(o,s),onPress:(s,l)=>r(Mo(o,s,l)),onReset:()=>r(void 0)})}),[n]:E("mobile",{type:"custom",render:({value:o,onChange:r})=>i(nl,{parts:e,desktopKey:t,value:o,onChange:r})})}}function tt({parts:e,changed:t,shown:n,onPress:o,onReset:r,detail:s,disabledReason:l}){const c=a("Display");return i(_,{label:c,icon:i(Jn,{}),changed:t,action:i(x,{words:y()?.panel,label:c,changed:t,detail:s,onReset:r}),children:i(vo,{label:c,items:e.map(u=>({id:u.id,label:a(u.label),shown:n(u.id),...l?{disabled:!0,disabledReason:a(l)}:{}})),onChange:o})})}function nl({parts:e,desktopKey:t,value:n,onChange:o}){const r=I()[t];return i(tt,{parts:e,changed:Go(n),shown:s=>Ho(r,n,s),onPress:(s,l)=>o(Wo(n,s,l)),onReset:()=>o(ir),detail:a("the same as Desktop")})}function Cn(e=vn){return W("Card image",i(mt,{}),A,xe,Bn,A,e,{clear:{hint:A},hint:"Rounds the picture. The card's own corner is in Styles."})}function ol(){return ue(dt,"cardImage")}function eu(){return{cardImage:Cn(dt),...ol()}}function tu(){return Ye({sidesKey:"cornerSides",row:Gn,step:Dn,useFollowed:()=>A,mark:i(rl,{label:Hn}),hint:a("Rounds the picture. Left alone it stays square.")})}function rl({label:e,changed:t=!1,onReset:n=()=>{}}){return i(x,{words:y()?.panel,label:a(e),changed:t,onReset:n})}function nu(){return{type:"custom",render:({value:e,onChange:t})=>i(al,{value:typeof e=="string"?e:"",onChange:t})}}function il({layout:e,width:t}){const n=Kn(e),o=n?`${n[0]}/${n[1]}`:void 0;return i("span",{"aria-hidden":"true",style:{display:"grid",width:t,gridTemplateColumns:"repeat(12, minmax(0, 1fr))",gridAutoRows:o?"auto":6,gridAutoFlow:"row dense",gap:2},children:Xn(e).map(([r,s],l)=>i("i",{className:"block rounded-xs bg-current opacity-60",style:{gridColumn:`span ${r}`,gridRow:`span ${s}`,aspectRatio:o}},l))})}const sl={width:"3.5rem",height:"2.5rem"},ll=200;function al({value:e,onChange:t}){const[n,o]=Z(null),[r,s]=Z(4),l=J(null);On(()=>{const m=l.current;if(!m||typeof ResizeObserver!="function")return;const g=()=>s(m.getBoundingClientRect().width>=ll?4:3);g();const b=new ResizeObserver(g);return b.observe(m),()=>b.disconnect()},[]);const c=e?Li(Oe,e):void 0,u=c?e:"",d=pt(n,u),h=pt(n,"").length,p=$n("no-symbol"),f=[{value:"",label:a("Not chosen"),icon:Fi(p,a("Not chosen"))},...d.map(m=>({value:m,label:a(Oe[m].label),icon:i(il,{layout:Oe[m],width:40})}))];return i(_,{label:a("Layout"),icon:i(lo,{}),value:c?a(c.label):void 0,children:i("div",{ref:l,style:{flex:"1 1 auto",minWidth:0},children:i(Rt,{label:a("Layout"),value:u,options:f,onChange:t,columns:r,cell:sl,header:P("div",{className:"mb-2 flex flex-col gap-1",style:{minWidth:"11rem"},children:[i("span",{className:"text-2xs text-ink-faint",children:a("Photos in a row")}),i(No,{options:[{id:"all",label:a("All")},...Wn.map(m=>({id:String(m),label:String(m)}))],value:n===null?"all":String(n),ariaLabel:a("Photos in a row"),onChange:m=>o(m==="all"?null:Number(m))}),i("span",{className:"text-2xs text-ink-faint",children:a("{n} of {total} layouts",{n:h,total:Un.length})})]})})})})}export{Xi as BOUND_TO_POST,Ja as BOUND_TO_POST_NOTE,ic as BUCKET_ICONS,Xc as CUSTOM_FIELD_MEDIA,$c as CoordsField,on as DESKTOP_GAP_NOT_OVERLAP,tt as DisplayRow,Bc as EDGE_ARROWS,Vo as FOCAL_DEFAULT,Ce as FOLD_FIELD_MARKER,$i as HIGHLIGHT_HINT,K as HidableTextField,lt as LINK_FIELD_MARKER,Ma as Label,at as MEDIA_FIELD_MARKER,Wc as MEDIA_TYPE_OPTIONS,Za as NOT_BOUND_TO_POST,pc as PanelBand,zi as PanelNoteLine,Is as RowPropsContext,ct as SCAFFOLD_FIELD_MARKER,su as SCALAR_TEXT_CONTROLS,Bi as SiteGapDefaultReset,q as Slider,qi as Swatches,iu as TEXT_CONTROL_KINDS,N as TEXT_FIELD_MARKER,jc as TICKER_ITEMS_ROW,el as TextListField,Xs as ThemeFillRow,me as WIDTH_LABEL,Ui as WidthDefaultReset,Qs as aimAfterListChange,Nc as anchorFields,U as backTo,fc as backgroundField,wc as boxBlockSpacingField,Cc as boxColumnsFields,Lc as boxFillField,xs as boxPhoneRowField,_s as boxShareField,Sc as boxSharePhoneField,_c as boxShareTabletField,js as boxThemeIndexOf,ac as bucketHeader,gc as buttonWordsEntryField,ws as cardCornersField,Qi as cardImageBackgroundField,Cn as cardImageField,eu as cardImageFields,qc as cardMediaFields,bc as cardShapeFields,Zc as cardShowFields,Jc as cardStyleFields,xc as cellWidthFields,Ac as colorInput,Ua as containerDirectionField,Di as containerGapField,Hi as containerGapPhoneField,Wa as containerGapRows,Gi as containerGapTabletField,qs as coordsResultTip,nc as copyText,un as cornerSidesField,Ye as cornersRowField,cn as cornersUnitFields,Pc as date,kc as dateTime,cc as designGroupHeader,Qc as displayFields,Dc as edgePad,Ze as fillSlotChoices,Vc as focusAfterRemove,vc as focusKeptField,uc as foldMarker,ye as foldMetaOf,Yi as foldTitleOf,Ls as followedHeightPatch,Us as followedStickPatch,nu as galleryLayoutField,Tc as heightFields,ge as heightFollowedBy,As as heightLayersAt,Ka as heroGroupPlacementPoints,st as hidableText,ji as hintIsWhileTyping,tu as imageCornersField,qa as inOwnBox,lc as isBucketHeader,an as keptBy,oc as linkField,zs as loadingRowHint,Uc as loadingShowsField,Hc as multiSelect,Fc as pageBackgroundField,sc as panelNote,Rs as phoneOverrideField,tc as plainText,rc as plainTextarea,es as pxField,dc as quietMarker,it as readHidable,Js as rowText,Gc as searchSelect,Zi as sectionBandChoices,is as sectionCornersField,mc as sectionShapeFields,hc as sectionThemeFields,Zs as setRowText,yc as sizeField,Mc as sourceField,Oc as spacingFields,Rc as stickFields,Ic as swapPadding,Qa as text,An as textFieldIdentifier,Va as textFieldOffPage,za as textFieldPanelOnly,zc as textList,Yc as textListRowField,ec as textarea,_n as toggle,Kc as upload,fe as useLengthRow,he as useSelectedPatch,I as useSelectedProps,R as useSelectedSibling,vi as useSiteGapDetail,Ec as widthField,Ya as withIdentifier,$a as withOffPage,ja as withPanelOnly,Xa as withScaffold};
@@ -39,6 +39,18 @@ export declare function boxNamesRowPicture(props: object | null | undefined): bo
39
39
  export declare function boxCardProps<P extends object>(props: P, inCopy: boolean): P;
40
40
  export declare function boxRowPicture(props: Record<string, unknown> | null | undefined, row: SourceRow | null | undefined): string | null;
41
41
  export declare function boxDarkenStyle(darken: unknown, style?: unknown): CSSProperties | null;
42
+ export declare const BOX_FILL_FADES: readonly [{
43
+ readonly label: "Flat";
44
+ readonly value: "";
45
+ readonly hint: "One colour from top to bottom";
46
+ }, {
47
+ readonly label: "Fade";
48
+ readonly value: "down";
49
+ readonly hint: "The colour fades into the page colour at the bottom";
50
+ }];
51
+ export declare const BOX_FILL_FADE_PROP = "fillFade";
52
+ export declare const boxFillFadeOf: (value: unknown) => (typeof BOX_FILL_FADES)[number]["value"];
53
+ export declare function boxFillFadeStyle(fade: unknown): CSSProperties | null;
42
54
  export declare const boxFillOf: (value: unknown) => string | null;
43
55
  export declare const boxPaintOf: (value: unknown) => string | null;
44
56
  export declare const boxFillSlot: (value: unknown) => FillColorSlot | null;
@@ -1 +1 @@
1
- import{parseHexColor as y}from"efficient-shell/format";import{fillColorRole as C}from"efficient-shell/markup";import{BOX_ROW_IMAGE_PROP as f}from"./box-card-rule.js";import{namedRowField as m,rowFieldText as S}from"./card-template.js";import{fillInkCss as P,fillSlotNamed as A,inkTokenOf as F,partColourName as N}from"../document/part-inks.js";import{scrim as p}from"./scrim.js";import{viewVarSplit as h}from"./view-var-split.js";const H="sf-card",g={min:0,max:100,step:5,fallback:0,unit:"%"},T=[{label:"Even",value:"even"},{label:"From the bottom",value:"bottom"}],B="68%",j={desktop:20,phone:20,side:40,sidePhone:24},K="sf-box-sides",Y={min:0,max:200,step:10};function D(t){return typeof t=="string"&&t.trim()!==""}function z(t){return D(typeof t?.bgImage=="string"?t.bgImage:null)||_(t)}function _(t){return m(t,f)!==""}function G(t,e){return e||!_(t)?t:{...t,[f]:""}}function J(t,e){const o=S(e,m(t,f))?.trim();return o||null}function k(t,e){const n=typeof t=="number"?t:Number.parseFloat(String(t??""));if(!Number.isFinite(n)||n<=0)return null;const s=(Math.min(g.max,Math.max(g.min,n))/100).toFixed(2);return e!=="bottom"?{background:p(Number(s))}:{background:`linear-gradient(0deg, ${p(Number(s))} 0%, ${p(0)} ${B})`}}const O=t=>typeof t=="string"?y(t.trim()):null,d=t=>{const e=O(t);if(e!==null||typeof t!="string")return e;const n=t.trim();return n&&!n.startsWith("#")&&P(n)||null},U=t=>{if(typeof t!="string")return null;const e=C(N(t.trim()));return e?.kind==="slot"?e.slot:null},E="swatch";function q(t,e){if(!e)return null;const n=S(e,m(t,E)),o=A(n);return O(n)??(o&&F(o)||null)}const I={tabletClass:"sf-fill-tablet",tabletVar:"--sf-fill-tablet",phoneClass:"sf-fill-phone",phoneVar:"--sf-fill-phone"};function Q(t,e,n){return h(I,d(t),d(e),d(n))}const R={tabletClass:"sf-wash-tablet",tabletVar:"--sf-wash-tablet",phoneClass:"sf-wash-phone",phoneVar:"--sf-wash-phone"};function Z(t){const e=k(t.darken,t.darkenStyle);if(!e)return{className:"",style:{}};const n=(r,u)=>String(k(r,u)?.background??"none"),o=r=>(typeof r=="number"||typeof r=="string"&&r.trim()!=="")&&Number.isFinite(Number(r))?r:void 0,s=r=>T.some(u=>u.value===r)?r:void 0,[l,i,a,c]=[o(t.darkenTablet),s(t.darkenStyleTablet),o(t.darkenPhone),s(t.darkenStylePhone)],b=l??t.darken,x=i??t.darkenStyle;return h(R,String(e.background),l!==void 0||i!==void 0?n(b,x):null,a!==void 0||c!==void 0?n(a??b,c??x):null)}function v(t,e){const n={"top-left":["start","start"],"top-center":["center","start"],"top-right":["end","start"],left:["start","center"],center:["center","center"],right:["end","center"],"bottom-left":["start","end"],"bottom-center":["center","end"],"bottom-right":["end","end"]},[o,s]=n[t]??n.center,[l,i]=e==="column"?[s,o]:[o,s],a={start:"justify-start",center:"justify-center",end:"justify-end"},c={start:"items-start",center:"items-center",end:"items-end"};return`${a[l]} ${c[i]}`}export{j as BOX_CARD_PAD,Y as BOX_CARD_SIDE,g as BOX_DARKEN,T as BOX_DARKEN_STYLES,I as BOX_FILL_VIEWS,K as BOX_OWNS_SIDES_CLASS,E as BOX_SWATCH_PROP,R as BOX_WASH_VIEWS,H as CARD_SHADOW_CLASS,G as boxCardProps,k as boxDarkenStyle,O as boxFillOf,U as boxFillSlot,Q as boxFillViews,z as boxIsCard,_ as boxNamesRowPicture,d as boxPaintOf,v as boxPlacementClasses,J as boxRowPicture,q as boxSwatchFill,Z as boxWashViews,D as isBackgroundBox};
1
+ import{parseHexColor as P}from"efficient-shell/format";import{fillColorRole as A}from"efficient-shell/markup";import{BOX_ROW_IMAGE_PROP as f}from"./box-card-rule.js";import{namedRowField as m,rowFieldText as h}from"./card-template.js";import{fillInkCss as C,fillSlotNamed as D,inkTokenOf as I,partColourName as E}from"../document/part-inks.js";import{scrim as p}from"./scrim.js";import{viewVarSplit as _}from"./view-var-split.js";const z="sf-card",g={min:0,max:100,step:5,fallback:0,unit:"%"},T=[{label:"Even",value:"even"},{label:"From the bottom",value:"bottom"}],B="68%",G={desktop:20,phone:20,side:40,sidePhone:24},J="sf-box-sides",U={min:0,max:200,step:10};function N(t){return typeof t=="string"&&t.trim()!==""}function q(t){return N(typeof t?.bgImage=="string"?t.bgImage:null)||F(t)}function F(t){return m(t,f)!==""}function Q(t,e){return e||!F(t)?t:{...t,[f]:""}}function Z(t,e){const o=h(e,m(t,f))?.trim();return o||null}function O(t,e){const n=typeof t=="number"?t:Number.parseFloat(String(t??""));if(!Number.isFinite(n)||n<=0)return null;const l=(Math.min(g.max,Math.max(g.min,n))/100).toFixed(2);return e!=="bottom"?{background:p(Number(l))}:{background:`linear-gradient(0deg, ${p(Number(l))} 0%, ${p(0)} ${B})`}}const k=[{label:"Flat",value:"",hint:"One colour from top to bottom"},{label:"Fade",value:"down",hint:"The colour fades into the page colour at the bottom"}],v="fillFade",d=k[1].value,L=t=>t===d?d:k[0].value,R=[{mix:"12%",at:"50%"},{mix:"19%",at:"70%"},{mix:"50%",at:"95%"}];function tt(t){return L(t)!==d?null:{backgroundImage:`linear-gradient(to bottom, transparent, ${R.map(n=>`color-mix(in srgb, var(--bg) ${n.mix}, transparent) ${n.at}`).join(", ")})`}}const y=t=>typeof t=="string"?P(t.trim()):null,x=t=>{const e=y(t);if(e!==null||typeof t!="string")return e;const n=t.trim();return n&&!n.startsWith("#")&&C(n)||null},et=t=>{if(typeof t!="string")return null;const e=A(E(t.trim()));return e?.kind==="slot"?e.slot:null},X="swatch";function nt(t,e){if(!e)return null;const n=h(e,m(t,X)),o=D(n);return y(n)??(o&&I(o)||null)}const W={tabletClass:"sf-fill-tablet",tabletVar:"--sf-fill-tablet",phoneClass:"sf-fill-phone",phoneVar:"--sf-fill-phone"};function ot(t,e,n){return _(W,x(t),x(e),x(n))}const V={tabletClass:"sf-wash-tablet",tabletVar:"--sf-wash-tablet",phoneClass:"sf-wash-phone",phoneVar:"--sf-wash-phone"};function rt(t){const e=O(t.darken,t.darkenStyle);if(!e)return{className:"",style:{}};const n=(r,u)=>String(O(r,u)?.background??"none"),o=r=>(typeof r=="number"||typeof r=="string"&&r.trim()!=="")&&Number.isFinite(Number(r))?r:void 0,l=r=>T.some(u=>u.value===r)?r:void 0,[s,a,i,c]=[o(t.darkenTablet),l(t.darkenStyleTablet),o(t.darkenPhone),l(t.darkenStylePhone)],b=s??t.darken,S=a??t.darkenStyle;return _(V,String(e.background),s!==void 0||a!==void 0?n(b,S):null,i!==void 0||c!==void 0?n(i??b,c??S):null)}function lt(t,e){const n={"top-left":["start","start"],"top-center":["center","start"],"top-right":["end","start"],left:["start","center"],center:["center","center"],right:["end","center"],"bottom-left":["start","end"],"bottom-center":["center","end"],"bottom-right":["end","end"]},[o,l]=n[t]??n.center,[s,a]=e==="column"?[l,o]:[o,l],i={start:"justify-start",center:"justify-center",end:"justify-end"},c={start:"items-start",center:"items-center",end:"items-end"};return`${i[s]} ${c[a]}`}export{G as BOX_CARD_PAD,U as BOX_CARD_SIDE,g as BOX_DARKEN,T as BOX_DARKEN_STYLES,k as BOX_FILL_FADES,v as BOX_FILL_FADE_PROP,W as BOX_FILL_VIEWS,J as BOX_OWNS_SIDES_CLASS,X as BOX_SWATCH_PROP,V as BOX_WASH_VIEWS,z as CARD_SHADOW_CLASS,Q as boxCardProps,O as boxDarkenStyle,L as boxFillFadeOf,tt as boxFillFadeStyle,y as boxFillOf,et as boxFillSlot,ot as boxFillViews,q as boxIsCard,F as boxNamesRowPicture,x as boxPaintOf,lt as boxPlacementClasses,Z as boxRowPicture,nt as boxSwatchFill,rt as boxWashViews,N as isBackgroundBox};
@@ -1 +1 @@
1
- import{MOTION_TIMING as O}from"efficient-shell/format";import{PHONE_EDGE as T}from"./view-lines.js";const f="grayscale(1) contrast(1.03)",g="Black and white";function A(o){return o===!0?{filter:f}:{}}function x(o){const{filter:e}=A(o);return e?{style:{filter:e}}:{}}const t="sf-photo-grayscale",y="data-sf-photo-host",$={duration:"--sf-photo-hover-duration",delay:"--sf-photo-hover-delay"},u=`@media (hover:hover){.${t}{filter:${f};transition:filter var(--sf-photo-hover-duration,var(--page-motion-hover-duration)) var(--page-ease-media) var(--sf-photo-hover-delay,var(--page-motion-hover-delay))}.${t}:hover,[data-sf-photo-host]:hover .${t}{filter:none}}@media (hover:hover) and (prefers-reduced-motion:reduce){.${t}{transition:none}}`;function _(o){const e=O.hover,r={...o.duration!==e.duration.default?{[$.duration]:`${o.duration}s`}:{},...o.delay!==e.delay.default?{[$.delay]:`${o.delay}s`}:{}};return Object.keys(r).length?r:void 0}function H(o,e,r){if(o===!0)return x(!0);if(r?.kind==="mono"){const d=_(r);return{className:t,sheet:u,...d?{style:d}:{}}}return o===!1?{}:e===!0?{className:t}:{}}const m="data-sf-repeat",p="sf-photo-zoom",R="--sf-photo-zoom",V="sf-photo-wash",a="sf-photo-wash-rest",n="sf-photo-wash-hover",s="sf-photo-frame",v=(o,e)=>`:not([${m}]:not(${e}) .${o})`,c=(o,e)=>`[${m}]${e} .${o}${v(o,e)}`,h=(o,e)=>`${e},${c(o,":hover")},[${y}]:hover .${o}${v(o,":hover")}`,E=o=>`${o} var(--sf-photo-hover-duration,var(--page-motion-hover-duration)) var(--page-ease-media) var(--sf-photo-hover-delay,var(--page-motion-hover-delay))`,C=`.${n}{opacity:0}@media (hover:hover){.${a},.${n}{transition:${E("opacity")}}${h(n,`.${s}:hover .${n}`)}{opacity:1}${h(a,`.${s}:hover .${a}`)}{opacity:0}}@media (hover:hover) and (prefers-reduced-motion:no-preference){.${p}{transition:${E("transform")}}${h(p,`.${s}:hover .${p}`)}{transform:scale(var(${R}))}}@media (hover:hover) and (prefers-reduced-motion:reduce){.${a},.${n}{transition:none}}`,M="sf-photo-move";function B(o){if(!o||!o.zoom&&!o.darken)return null;const e=_(o);return{className:s,sheet:C,...e?{style:e}:{}}}function U(o){return o===!0?{[t]:u}:{}}const i="sf-box-reveal",w="sf-box-reveal",I=8,S=.3,l=`(min-width:${T}px)`,N=`@media ${l}{.${i}{opacity:0;transform:translateY(${I}px);transition:opacity ${S}s ease-out,transform ${S}s ease-out}${c(i,":hover")},${c(i,":focus-within")}{opacity:1;transform:none}}@media ${l} and (prefers-reduced-motion:reduce){.${i}{transition:none;transform:none}}`;export{i as BOX_REVEAL_CLASS,N as BOX_REVEAL_CSS,w as BOX_REVEAL_SHEET,m as CARD_COPY_ATTR,f as IMAGE_GRAYSCALE_FILTER,g as IMAGE_GRAYSCALE_LABEL,y as PHOTO_HOST_ATTR,$ as PHOTO_HOVER_VARS,s as PICTURE_FRAME_CLASS,C as PICTURE_MOVE_CSS,M as PICTURE_MOVE_SHEET,V as PICTURE_WASH_CLASS,n as PICTURE_WASH_HOVER_CLASS,a as PICTURE_WASH_REST_CLASS,p as PICTURE_ZOOM_CLASS,R as PICTURE_ZOOM_VAR,t as SITE_PHOTO_CLASS,u as SITE_PHOTO_CSS,x as imageTreatmentProps,A as imageTreatmentStyle,H as resolveImageTreatment,B as resolvePictureMove,U as sitePhotographyTokens};
1
+ import{MOTION_TIMING as T}from"efficient-shell/format";import{EDGE_WIDE_MEDIA as f}from"./view-lines.js";const u="grayscale(1) contrast(1.03)",P="Black and white";function A(o){return o===!0?{filter:u}:{}}function O(o){const{filter:e}=A(o);return e?{style:{filter:e}}:{}}const t="sf-photo-grayscale",y="data-sf-photo-host",$={duration:"--sf-photo-hover-duration",delay:"--sf-photo-hover-delay"},_=`@media (hover:hover){.${t}{filter:${u};transition:filter var(--sf-photo-hover-duration,var(--page-motion-hover-duration)) var(--page-ease-media) var(--sf-photo-hover-delay,var(--page-motion-hover-delay))}.${t}:hover,[data-sf-photo-host]:hover .${t}{filter:none}}@media (hover:hover) and (prefers-reduced-motion:reduce){.${t}{transition:none}}`;function v(o){const e=T.hover,r={...o.duration!==e.duration.default?{[$.duration]:`${o.duration}s`}:{},...o.delay!==e.delay.default?{[$.delay]:`${o.delay}s`}:{}};return Object.keys(r).length?r:void 0}function g(o,e,r){if(o===!0)return O(!0);if(r?.kind==="mono"){const d=v(r);return{className:t,sheet:_,...d?{style:d}:{}}}return o===!1?{}:e===!0?{className:t}:{}}const m="data-sf-repeat",p="sf-photo-zoom",x="--sf-photo-zoom",H="sf-photo-wash",a="sf-photo-wash-rest",n="sf-photo-wash-hover",s="sf-photo-frame",E=(o,e)=>`:not([${m}]:not(${e}) .${o})`,c=(o,e)=>`[${m}]${e} .${o}${E(o,e)}`,h=(o,e)=>`${e},${c(o,":hover")},[${y}]:hover .${o}${E(o,":hover")}`,S=o=>`${o} var(--sf-photo-hover-duration,var(--page-motion-hover-duration)) var(--page-ease-media) var(--sf-photo-hover-delay,var(--page-motion-hover-delay))`,R=`.${n}{opacity:0}@media (hover:hover){.${a},.${n}{transition:${S("opacity")}}${h(n,`.${s}:hover .${n}`)}{opacity:1}${h(a,`.${s}:hover .${a}`)}{opacity:0}}@media (hover:hover) and (prefers-reduced-motion:no-preference){.${p}{transition:${S("transform")}}${h(p,`.${s}:hover .${p}`)}{transform:scale(var(${x}))}}@media (hover:hover) and (prefers-reduced-motion:reduce){.${a},.${n}{transition:none}}`,M="sf-photo-move";function V(o){if(!o||!o.zoom&&!o.darken)return null;const e=v(o);return{className:s,sheet:R,...e?{style:e}:{}}}function U(o){return o===!0?{[t]:_}:{}}const i="sf-box-reveal",B="sf-box-reveal",C=8,l=.3,w=`@media ${f}{.${i}{opacity:0;transform:translateY(${C}px);transition:opacity ${l}s ease-out,transform ${l}s ease-out}${c(i,":hover")},${c(i,":focus-within")}{opacity:1;transform:none}}@media ${f} and (prefers-reduced-motion:reduce){.${i}{transition:none;transform:none}}`;export{i as BOX_REVEAL_CLASS,w as BOX_REVEAL_CSS,B as BOX_REVEAL_SHEET,m as CARD_COPY_ATTR,u as IMAGE_GRAYSCALE_FILTER,P as IMAGE_GRAYSCALE_LABEL,y as PHOTO_HOST_ATTR,$ as PHOTO_HOVER_VARS,s as PICTURE_FRAME_CLASS,R as PICTURE_MOVE_CSS,M as PICTURE_MOVE_SHEET,H as PICTURE_WASH_CLASS,n as PICTURE_WASH_HOVER_CLASS,a as PICTURE_WASH_REST_CLASS,p as PICTURE_ZOOM_CLASS,x as PICTURE_ZOOM_VAR,t as SITE_PHOTO_CLASS,_ as SITE_PHOTO_CSS,O as imageTreatmentProps,A as imageTreatmentStyle,g as resolveImageTreatment,V as resolvePictureMove,U as sitePhotographyTokens};
@@ -10,3 +10,4 @@ export declare function breakpointOf(variant: string): {
10
10
  px: number;
11
11
  max: boolean;
12
12
  } | undefined;
13
+ export declare const EDGE_WIDE_MEDIA = "(min-width: 800px)";
@@ -1 +1 @@
1
- import{VIEW_DESKTOP_MIN as E,VIEW_TABLET_MIN as i}from"efficient-easel/screen/lib/content/view-tiers";const s="v1",p=800,x={"view-tablet":i,"view-desktop":E,"view-wide":p};function c(e){const o=e.startsWith("max-"),n=o?e.slice(4):e;if(n in x)return{px:x[n],max:o};const t=/^(max|min)-\[(\d+)px\]$/.exec(e);return t?{px:Number(t[2]),max:t[1]==="max"}:void 0}export{p as PHONE_EDGE,s as RESPONSIVE_RULES,x as VIEW_LINE_PX,c as breakpointOf};
1
+ import{VIEW_DESKTOP_MIN as i,VIEW_TABLET_MIN as p}from"efficient-easel/screen/lib/content/view-tiers";const s="v1",E=800,x={"view-tablet":p,"view-desktop":i,"view-wide":E};function c(e){const o=e.startsWith("max-"),n=o?e.slice(4):e;if(n in x)return{px:x[n],max:o};const t=/^(max|min)-\[(\d+)px\]$/.exec(e);return t?{px:Number(t[2]),max:t[1]==="max"}:void 0}const m=`(min-width: ${E}px)`;export{m as EDGE_WIDE_MEDIA,E as PHONE_EDGE,s as RESPONSIVE_RULES,x as VIEW_LINE_PX,c as breakpointOf};
@@ -6,7 +6,7 @@ export declare const BOX: Props;
6
6
  export declare const INNER_BOX: Props;
7
7
  export declare const boxPadding: (y: number, x?: number, yPhone?: number, xPhone?: number) => Props;
8
8
  export declare const fillSlot: (slot: FillColorSlot) => Props;
9
- export declare const markBoxProps: (size: number, fill: FillColorSlot, look?: Props) => Props;
9
+ export declare const markBoxProps: (size: number, fill?: FillColorSlot, look?: Props) => Props;
10
10
  export declare const token: (step: string, px: number, pxPhone?: number, stepPhone?: string) => Props;
11
11
  export declare const LABEL_FACE: Readonly<Props>;
12
12
  export declare const labelLook: (px: number, pxPhone?: number) => Props;
@@ -1 +1 @@
1
- import{NESTED_BOX_PADDING as a}from"../content/box-layout.js";import{TextMeta as l}from"./blocks/general/Text/meta.js";const{text:L,tag:T,...g}=l.defaultProps,x=g,_={...x,tone:"dim"},f={justify:"start",align:"stretch",wrap:!1,blockSpacing:"gap",padV2:!0},P={...f,direction:"column",...a},k=(t,o=t,e=t,n=o)=>({sectionPaddingTop:t,sectionPaddingRight:o,sectionPaddingBottom:t,sectionPaddingLeft:o,sectionPaddingTopPhone:e,sectionPaddingRightPhone:n,sectionPaddingBottomPhone:e,sectionPaddingLeftPhone:n}),m=t=>({fillColor:t}),A=(t,o,e={})=>({...P,widthFit:"fixed",width:t,minWidth:t,sectionHeightMode:"fixed",sectionHeightValue:t,sectionHeightUnit:"px",...m(o),...e}),h=(t,o,e,n)=>({sizeToken:{step:t,px:o,...n?{stepPhone:n}:{},...e?{pxPhone:e}:{}}}),c={case:"upper"},u={textStyle:"body-5",...c},S=(t,o)=>({...h("label",t,o),letterSpacing:.2,...c}),N=(t,o)=>({...u,...S(t,o)});function B(t,o,e=""){return t.map((n,i)=>{const r=e?`${e}.${i}`:String(i),s={...n.props??{}};for(const[p,d]of Object.entries(n.slots??{}))s[p]=B(d,o,r);return{type:n.type,props:{...s,id:o(n.type,r)}}})}export{f as BOX,_ as DIM,P as INNER_BOX,u as LABEL_FACE,x as TEXT,k as boxPadding,m as fillSlot,S as labelLook,N as labelStyle,A as markBoxProps,B as seedNodes,h as token};
1
+ import{NESTED_BOX_PADDING as a}from"../content/box-layout.js";import{TextMeta as l}from"./blocks/general/Text/meta.js";const{text:L,tag:T,...g}=l.defaultProps,x=g,_={...x,tone:"dim"},f={justify:"start",align:"stretch",wrap:!1,blockSpacing:"gap",padV2:!0},P={...f,direction:"column",...a},k=(t,o=t,e=t,n=o)=>({sectionPaddingTop:t,sectionPaddingRight:o,sectionPaddingBottom:t,sectionPaddingLeft:o,sectionPaddingTopPhone:e,sectionPaddingRightPhone:n,sectionPaddingBottomPhone:e,sectionPaddingLeftPhone:n}),m=t=>({fillColor:t}),A=(t,o,e={})=>({...P,widthFit:"fixed",width:t,minWidth:t,sectionHeightMode:"fixed",sectionHeightValue:t,sectionHeightUnit:"px",...o?m(o):{},...e}),h=(t,o,e,n)=>({sizeToken:{step:t,px:o,...n?{stepPhone:n}:{},...e?{pxPhone:e}:{}}}),c={case:"upper"},u={textStyle:"body-5",...c},S=(t,o)=>({...h("label",t,o),letterSpacing:.2,...c}),N=(t,o)=>({...u,...S(t,o)});function B(t,o,e=""){return t.map((n,i)=>{const r=e?`${e}.${i}`:String(i),s={...n.props??{}};for(const[p,d]of Object.entries(n.slots??{}))s[p]=B(d,o,r);return{type:n.type,props:{...s,id:o(n.type,r)}}})}export{f as BOX,_ as DIM,P as INNER_BOX,u as LABEL_FACE,x as TEXT,k as boxPadding,m as fillSlot,S as labelLook,N as labelStyle,A as markBoxProps,B as seedNodes,h as token};