efficient-web-builder 55.3.1 → 57.0.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 (155) hide show
  1. package/CHANGELOG.md +66 -0
  2. package/dist/editor/components/BlockGapField.d.ts +1 -2
  3. package/dist/editor/components/BlockGapField.js +1 -1
  4. package/dist/editor/components/CardShadowField.d.ts +1 -2
  5. package/dist/editor/components/CardShadowField.js +1 -1
  6. package/dist/editor/components/ChatSettingsPanel.js +1 -1
  7. package/dist/editor/components/CornersField.d.ts +1 -2
  8. package/dist/editor/components/CornersField.js +1 -1
  9. package/dist/editor/components/HeroPartPanel.js +1 -1
  10. package/dist/editor/components/HoverEffectField.d.ts +1 -2
  11. package/dist/editor/components/HoverEffectField.js +1 -1
  12. package/dist/editor/components/PartSettingsPanel.js +1 -1
  13. package/dist/editor/components/PhotographyField.d.ts +1 -2
  14. package/dist/editor/components/PhotographyField.js +1 -1
  15. package/dist/editor/components/SectionEditor.js +1 -1
  16. package/dist/editor/components/SectionThumbnail.js +1 -1
  17. package/dist/editor/components/ShadowColourField.d.ts +1 -2
  18. package/dist/editor/components/ShadowColourField.js +1 -1
  19. package/dist/editor/components/ShareButtonField.d.ts +1 -2
  20. package/dist/editor/components/ShareButtonField.js +1 -1
  21. package/dist/editor/components/SideSpaceField.d.ts +1 -2
  22. package/dist/editor/components/SideSpaceField.js +1 -1
  23. package/dist/editor/components/SiteFields.d.ts +2 -1
  24. package/dist/editor/components/SiteFields.js +1 -1
  25. package/dist/editor/components/SocialLinksPanel.js +1 -1
  26. package/dist/editor/components/SourceStatus.d.ts +2 -1
  27. package/dist/editor/components/SourceStatus.js +1 -1
  28. package/dist/editor/components/StandaloneSectionEditor.js +1 -1
  29. package/dist/editor/components/StorefrontEditor.js +1 -1
  30. package/dist/editor/components/StylesPanel.js +1 -1
  31. package/dist/editor/components/WebsiteHintsProvider.d.ts +8 -0
  32. package/dist/editor/components/WebsiteHintsProvider.js +1 -0
  33. package/dist/editor/components/WebsiteSettingsPanel.d.ts +6 -17
  34. package/dist/editor/components/WebsiteSettingsPanel.js +1 -1
  35. package/dist/editor/components/storefront-editor.css +40 -39
  36. package/dist/editor/components/useHostDocumentBridge.js +1 -1
  37. package/dist/editor/components/useSectionToBoxPass.js +1 -1
  38. package/dist/editor/lib/animation/entrance-fields.d.ts +0 -3
  39. package/dist/editor/lib/animation/entrance-fields.js +1 -1
  40. package/dist/editor/lib/animation/fields.js +1 -1
  41. package/dist/editor/lib/animation/hover-fields.js +1 -1
  42. package/dist/editor/lib/animation/loop-fields.d.ts +2 -0
  43. package/dist/editor/lib/animation/loop-fields.js +1 -1
  44. package/dist/editor/lib/document/blocks/general/Flex/fields.js +1 -1
  45. package/dist/editor/lib/document/controls.d.ts +2 -1
  46. package/dist/editor/lib/document/controls.js +1 -1
  47. package/dist/editor/lib/document/field-groups.js +1 -1
  48. package/dist/editor/lib/document/overrides.js +1 -1
  49. package/dist/editor/lib/editor-document-adapter.js +1 -1
  50. package/dist/editor/lib/host-document-bridge.d.ts +2 -1
  51. package/dist/editor/lib/host-document-bridge.js +1 -1
  52. package/dist/editor/lib/keyed-store.d.ts +7 -0
  53. package/dist/editor/lib/keyed-store.js +1 -0
  54. package/dist/editor/lib/page-live-state.js +1 -1
  55. package/dist/editor/lib/page-video-frames.d.ts +11 -0
  56. package/dist/editor/lib/page-video-frames.js +1 -0
  57. package/dist/editor/lib/pinned-chrome-doc.d.ts +1 -0
  58. package/dist/editor/lib/pinned-chrome-doc.js +1 -1
  59. package/dist/editor/lib/sections/new-section-node.js +1 -1
  60. package/dist/editor/lib/sections/text-layouts.js +1 -1
  61. package/dist/format/lib/animation/hover.d.ts +2 -3
  62. package/dist/format/lib/animation/hover.js +1 -1
  63. package/dist/format/lib/animation/loop.js +1 -1
  64. package/dist/format/lib/content/box-layout.d.ts +5 -3
  65. package/dist/format/lib/content/box-layout.js +1 -1
  66. package/dist/format/lib/content/card-template.js +1 -1
  67. package/dist/format/lib/content/cell-picture-sizes.d.ts +31 -0
  68. package/dist/format/lib/content/cell-picture-sizes.js +1 -0
  69. package/dist/format/lib/content/image-aspect.d.ts +1 -0
  70. package/dist/format/lib/content/image-aspect.js +1 -1
  71. package/dist/format/lib/content/mirror-cards.d.ts +1 -1
  72. package/dist/format/lib/content/mirror-cards.js +1 -1
  73. package/dist/format/lib/document/article-body-seed.d.ts +10 -0
  74. package/dist/format/lib/document/article-body-seed.js +1 -0
  75. package/dist/format/lib/document/blocks/general/Timeline/meta.d.ts +2 -1
  76. package/dist/format/lib/document/blocks/general/Timeline/meta.js +2 -2
  77. package/dist/format/lib/document/blocks/placeholders.d.ts +1 -0
  78. package/dist/format/lib/document/blocks/placeholders.js +1 -1
  79. package/dist/format/lib/document/easel-row-words.d.ts +1 -1
  80. package/dist/format/lib/document/easel-row-words.js +1 -1
  81. package/dist/format/lib/document/passes/settings-groups.js +1 -1
  82. package/dist/format/lib/document/section-catalog.js +6 -2
  83. package/dist/format/lib/editor-words-catalogue.d.ts +13 -2
  84. package/dist/format/lib/editor-words-catalogue.js +5 -5
  85. package/dist/format/lib/editor-words-kept.js +1 -1
  86. package/dist/format/lib/fit-words.js +2 -2
  87. package/dist/format/lib/hero-video.d.ts +12 -0
  88. package/dist/format/lib/hero-video.js +1 -1
  89. package/dist/format/lib/sections/active-press-context.d.ts +4 -0
  90. package/dist/format/lib/sections/active-press-context.js +1 -0
  91. package/dist/format/lib/sections/section-head-placement.js +1 -1
  92. package/dist/format/lib/sections/section-presets.d.ts +5 -1
  93. package/dist/format/lib/sections/section-presets.js +1 -1
  94. package/dist/format/lib/sections/timeline-year-shape.js +1 -1
  95. package/dist/format/lib/sized-image.d.ts +1 -0
  96. package/dist/format/lib/sized-image.js +1 -1
  97. package/dist/format/lib/source-rules/page-picture-place.d.ts +6 -0
  98. package/dist/format/lib/source-rules/page-picture-place.js +4 -0
  99. package/dist/format/lib/source-rules/part-style-naming.js +2 -2
  100. package/dist/format/lib/theme.d.ts +2 -1
  101. package/dist/format/lib/theme.js +2 -2
  102. package/dist/format/lib/web-backend.d.ts +17 -0
  103. package/dist/render/components/Banner.js +1 -1
  104. package/dist/render/components/BoxCellContext.d.ts +14 -0
  105. package/dist/render/components/BoxCellContext.js +1 -0
  106. package/dist/render/components/Flex.d.ts +2 -1
  107. package/dist/render/components/Flex.js +1 -1
  108. package/dist/render/components/HeroPictures.d.ts +2 -1
  109. package/dist/render/components/HeroPictures.js +1 -1
  110. package/dist/render/components/HeroPoster.d.ts +4 -1
  111. package/dist/render/components/HeroPoster.js +1 -1
  112. package/dist/render/components/HeroSection.js +1 -1
  113. package/dist/render/components/HeroSlide.d.ts +3 -1
  114. package/dist/render/components/HeroSlide.js +1 -1
  115. package/dist/render/components/HeroVideoPlay.js +1 -1
  116. package/dist/render/components/ImageBlock.js +1 -1
  117. package/dist/render/components/LogoBlock.js +1 -1
  118. package/dist/render/components/Logos.js +1 -1
  119. package/dist/render/components/Manifesto.js +1 -1
  120. package/dist/render/components/Placeholder.d.ts +2 -1
  121. package/dist/render/components/Placeholder.js +1 -1
  122. package/dist/render/components/SectionHeader.js +1 -1
  123. package/dist/render/components/Split.js +1 -1
  124. package/dist/render/lib/content/block-size.d.ts +1 -0
  125. package/dist/render/lib/content/block-size.js +1 -1
  126. package/dist/render/lib/content/box-cell-bound.d.ts +17 -0
  127. package/dist/render/lib/content/box-cell-bound.js +1 -0
  128. package/dist/render/lib/document/blocks/general/Flex/render.js +1 -1
  129. package/dist/render/lib/document/blocks/general/HeroSingle/render.js +1 -1
  130. package/dist/render/lib/document/blocks/general/HeroSlide/render.js +1 -1
  131. package/dist/render/lib/document/blocks/general/Timeline/render.js +1 -1
  132. package/dist/render/lib/document/blocks/general/section-head-looks.d.ts +1 -0
  133. package/dist/render/lib/document/blocks/general/section-head-looks.js +2 -2
  134. package/dist/render/lib/document/blocks/general/section-to-box-row-parts.d.ts +0 -1
  135. package/dist/render/lib/document/blocks/general/section-to-box-row-parts.js +1 -1
  136. package/dist/render/lib/document/blocks/general/section-to-box-rows-pageheader.js +1 -1
  137. package/dist/render/lib/document/blocks/general/section-to-box-rows-strip.js +1 -1
  138. package/dist/render/lib/document/blocks/general/section-to-box-rows-timeline.d.ts +2 -0
  139. package/dist/render/lib/document/blocks/general/section-to-box-rows-timeline.js +2 -2
  140. package/dist/render/lib/document/blocks/general/section-to-box-rows.js +1 -1
  141. package/dist/render/lib/document/page-render.js +1 -1
  142. package/dist/render/lib/document/passes/block-size.js +1 -1
  143. package/dist/render/lib/document/sanitize.d.ts +1 -0
  144. package/dist/render/lib/document/sanitize.js +1 -1
  145. package/dist/render/lib/document/slot-counts.d.ts +8 -0
  146. package/dist/render/lib/document/slot-counts.js +1 -0
  147. package/dist/render/lib/first-screen.d.ts +28 -0
  148. package/dist/render/lib/first-screen.js +1 -0
  149. package/dist/render/lib/sections/section-to-box.js +1 -1
  150. package/dist/render/lib/site-runtime.d.ts +1 -0
  151. package/package.json +5 -5
  152. package/dist/editor/components/KeepHint.d.ts +0 -5
  153. package/dist/editor/components/KeepHint.js +0 -1
  154. package/dist/render/components/BoxCellWidthContext.d.ts +0 -2
  155. package/dist/render/components/BoxCellWidthContext.js +0 -1
@@ -1 +1 @@
1
- import{parseOption as n}from"../parse-option.js";import{withRowsShownWhen as o}from"../document/show-when-attach.js";import{nonEmptyString as d}from"../non-empty-string.js";const l="inline",a=[{label:"In this section",value:"inline"},{label:"In its own box",value:"own-box"}];function h(e){return[e.num,e.title,e.description,e.linkProp].filter(t=>d(t)!==void 0)}const s={ProductGrid:{num:"num",title:"title",description:"description",headRows:["num","title","titleSize","description","linkText","linkHref"],renderer:"ProductGridSection",padKey:"padTop",linkProp:"link"},TyreSizes:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicTyreSizes"},FitmentFinder:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"FitmentFinder"},TyreFitment:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicTyreFitment"},BundleOffer:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicBundleOffer"},CompatibleTyres:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicRelatedProducts"},RelatedProducts:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicRelatedProducts"},SpecTable:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"SpecTable"},FAQ:{num:"num",title:"title",linkProp:"link",headRows:["num","title","linkText","linkHref"],renderer:"FAQ"},GalleryB:{num:"num",title:"title",headRows:["num","title","linkText","linkHref"],renderer:"GalleryGrid"},FitmentTable:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"FitmentTable"},Events:{num:"num",title:"title",linkProp:"link",headRows:["num","title","linkText","linkHref"],renderer:"Events"},ProcessSteps:{num:"num",title:"title",description:"description",headRows:["num","title","description"],headStyle:"editorial",renderer:"ProcessSteps",padKey:"padTop"},LongRead:{num:"headNum",title:"headTitle",description:"headDesc",headRows:["headNum","headTitle","headDesc"],headStyle:"editorial",renderer:"LongRead"},Series:{num:"headNum",title:"headTitle",description:"headDesc",headRows:["headNum","headTitle","headDesc"],headStyle:"editorial",renderer:"Series"},TimelineTrack:{num:"eyebrow",title:"title",description:"intro",headRows:["eyebrow","title","intro"],headStyle:"editorial",renderer:"TimelineTrack",padKey:"padTop"},StatsParagraph:{num:"eyebrow",title:"title",description:"desc",headRows:["eyebrow","title","desc"],headStyle:"editorial",renderer:"StatsParagraph"},Footprint:{num:"sectionNumber",title:"heading",description:"tagline",headRows:["sectionNumber","heading","tagline"],headStyle:"editorial",renderer:"Footprint",padKey:"padTop"},Collections:{num:"eyebrow",title:"heading",headRows:["eyebrow","heading"],renderer:"Collections"},Cards:{num:"eyebrow",title:"title",headRows:["eyebrow","eyebrowLook","title"],headStyle:"simple",renderer:"Cards"},Testimonials:{num:"eyebrow",title:"title",headRows:["eyebrow","eyebrowLook","title"],headStyle:"simple",renderer:"Testimonials"},Reviews:{num:"eyebrow",title:"title",headRows:["eyebrow","eyebrowLook","title"],headStyle:"simple",renderer:"Reviews"},Prose:{num:"eyebrow",title:"title",headRows:["eyebrow","title"],headStyle:"essay",renderer:"Prose"},ReviewForm:{num:"eyebrow",title:"title",headRows:["eyebrow","title"],headStyle:"simple",renderer:"ReviewForm"},DeliveryOptions:{num:"eyebrow",title:"title",description:"body",headRows:["eyebrow","title","body"],headStyle:"natural",headRowGap:"gap-3",headDescriptionSize:"text-[15px]",renderer:"DeliveryOptions"}},w="SectionHeader";function y(e){return e in s}function S(e){return n(a,l,e)}const p=new Set(["Flex"]);function R(e){return!!e?.type&&p.has(e.type)}const i={not:{field:"headPlacement",is:"own-box"}},T={not:i};function b(e,t,r){return o(e,r,i)}export{l as DEFAULT_SECTION_HEAD_PLACEMENT,i as HEAD_ROWS_SHOW_WHEN,T as OWN_BOX_ROWS_SHOW_WHEN,a as SECTION_HEAD_PLACEMENT_OPTIONS,w as SECTION_HEAD_TYPE,s as SPLITTABLE_SECTIONS,y as canSplitHead,b as headFieldsForPlacement,h as headRoleProps,R as parentCapsWidth,S as parseSectionHeadPlacement};
1
+ import{parseOption as n}from"../parse-option.js";import{withRowsShownWhen as o}from"../document/show-when-attach.js";import{nonEmptyString as d}from"../non-empty-string.js";const l="inline",a=[{label:"In this section",value:"inline"},{label:"In its own box",value:"own-box"}];function h(e){return[e.num,e.title,e.description,e.linkProp].filter(t=>d(t)!==void 0)}const s={ProductGrid:{num:"num",title:"title",description:"description",headRows:["num","title","titleSize","description","linkText","linkHref"],renderer:"ProductGridSection",padKey:"padTop",linkProp:"link"},TyreSizes:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicTyreSizes"},FitmentFinder:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"FitmentFinder"},TyreFitment:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicTyreFitment"},BundleOffer:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicRelatedProducts"},CompatibleTyres:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicRelatedProducts"},RelatedProducts:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"DynamicRelatedProducts"},SpecTable:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"SpecTable"},FAQ:{num:"num",title:"title",linkProp:"link",headRows:["num","title","linkText","linkHref"],renderer:"FAQ"},GalleryB:{num:"num",title:"title",headRows:["num","title","linkText","linkHref"],renderer:"GalleryGrid"},FitmentTable:{num:"num",title:"title",description:"description",headRows:["num","title","description"],renderer:"FitmentTable"},Events:{num:"num",title:"title",linkProp:"link",headRows:["num","title","linkText","linkHref"],renderer:"Events"},ProcessSteps:{num:"num",title:"title",description:"description",headRows:["num","title","description"],headStyle:"editorial",renderer:"ProcessSteps",padKey:"padTop"},LongRead:{num:"headNum",title:"headTitle",description:"headDesc",headRows:["headNum","headTitle","headDesc"],headStyle:"editorial",renderer:"LongRead"},Series:{num:"headNum",title:"headTitle",description:"headDesc",headRows:["headNum","headTitle","headDesc"],headStyle:"editorial",renderer:"Series"},TimelineTrack:{num:"eyebrow",title:"title",description:"intro",headRows:["eyebrow","title","intro"],headStyle:"editorial",renderer:"TimelineTrack",padKey:"padTop"},StatsParagraph:{num:"eyebrow",title:"title",description:"desc",headRows:["eyebrow","title","desc"],headStyle:"editorial",renderer:"StatsParagraph"},Footprint:{num:"sectionNumber",title:"heading",description:"tagline",headRows:["sectionNumber","heading","tagline"],headStyle:"editorial",renderer:"Footprint",padKey:"padTop"},Collections:{num:"eyebrow",title:"heading",headRows:["eyebrow","heading"],renderer:"Collections"},Cards:{num:"eyebrow",title:"title",headRows:["eyebrow","eyebrowLook","title"],headStyle:"simple",renderer:"Cards"},Testimonials:{num:"eyebrow",title:"title",headRows:["eyebrow","eyebrowLook","title"],headStyle:"simple",renderer:"Testimonials"},Reviews:{num:"eyebrow",title:"title",headRows:["eyebrow","eyebrowLook","title"],headStyle:"simple",renderer:"Reviews"},Prose:{num:"eyebrow",title:"title",headRows:["eyebrow","title"],headStyle:"essay",renderer:"Prose"},ReviewForm:{num:"eyebrow",title:"title",headRows:["eyebrow","title"],headStyle:"simple",renderer:"ReviewForm"},DeliveryOptions:{num:"eyebrow",title:"title",description:"body",headRows:["eyebrow","title","body"],headStyle:"natural",headRowGap:"gap-3",headDescriptionSize:"text-[15px]",renderer:"DeliveryOptions"}},w="SectionHeader";function y(e){return e in s}function S(e){return n(a,l,e)}const p=new Set(["Flex"]);function R(e){return!!e?.type&&p.has(e.type)}const i={not:{field:"headPlacement",is:"own-box"}},T={not:i};function b(e,t,r){return o(e,r,i)}export{l as DEFAULT_SECTION_HEAD_PLACEMENT,i as HEAD_ROWS_SHOW_WHEN,T as OWN_BOX_ROWS_SHOW_WHEN,a as SECTION_HEAD_PLACEMENT_OPTIONS,w as SECTION_HEAD_TYPE,s as SPLITTABLE_SECTIONS,y as canSplitHead,b as headFieldsForPlacement,h as headRoleProps,R as parentCapsWidth,S as parseSectionHeadPlacement};
@@ -1,9 +1,13 @@
1
+ import { type ThemeValue } from "../theme.js";
1
2
  export type NodeDefaults = (type: string) => Record<string, unknown>;
2
3
  export type NewNodeId = (type: string) => string;
3
4
  export interface PresetNode {
4
5
  type: string;
5
6
  props: Record<string, unknown>;
6
7
  }
7
- export type SectionPreset = (defaultsFor: NodeDefaults, newId: NewNodeId) => PresetNode;
8
+ export type PressContext = {
9
+ theme?: ThemeValue;
10
+ };
11
+ export type SectionPreset = (defaultsFor: NodeDefaults, newId: NewNodeId, ctx?: PressContext) => PresetNode;
8
12
  export declare const SECTION_PRESETS: Readonly<Record<string, SectionPreset>>;
9
13
  export declare function presetFor(type: string): SectionPreset | null;
@@ -1 +1 @@
1
- import{BOX_TYPE as i}from"../document/container-blocks.js";import{headingTextSeed as c,labelTextSeed as p}from"../document/text-seeds.js";import{TICKER_SCAFFOLD_ITEMS as P}from"../document/blocks/general/Ticker/meta.js";import{specStripScaffold as S}from"../document/blocks/general/SpecStrip/meta.js";import{TIMELINE_YEAR_BOX as B,TIMELINE_YEAR_HEAD as s}from"./timeline-year-shape.js";import{SPEC_PAD as E,SPEC_STRIP as h,SPEC_TEXT as _,STRIP_BOX as y,TICKER_PAD as R,TICKER_SMALL as b,TICKER_STRIP as C}from"./strip-shape.js";function e(t,n,o,m={}){return{type:t,props:{...n(t),id:o(t),...m}}}function a(t,n,o){return e(i,t,n,{...o,sectionPaddingTop:void 0,sectionPaddingBottom:void 0})}const k={Manifesto:(t,n)=>({type:i,props:{...t(i),id:n(i),direction:"row",share:"equal",sectionHeightMode:"screen",name:"Brand Text",content:[e(i,t,n,{direction:"column",justify:"center",blockSpacing:"gap",name:"Text",sectionPaddingTop:100,sectionPaddingBottom:100,sectionPaddingLeft:40,sectionPaddingRight:40,content:[e("Text",t,n,p()),e("Text",t,n,c()),e("Text",t,n),e("Stats",t,n)]}),a(t,n,{direction:"column",name:"Picture",content:[]})]}}),Split:(t,n)=>({type:i,props:{...t(i),id:n(i),direction:"row",share:"equal",sectionHeightMode:"screen",sectionHeightValue:70,name:"Image & Text Split",content:[e(i,t,n,{direction:"column",justify:"center",blockSpacing:"gap",name:"Text",sectionPaddingTop:100,sectionPaddingBottom:100,sectionPaddingLeft:60,sectionPaddingRight:60,content:[e("Text",t,n,p()),e("Text",t,n,c()),e("Text",t,n),e("ButtonBlock",t,n)]}),a(t,n,{direction:"column",name:"Image",content:[e("ImageBlock",t,n)]})]}}),Subscribe:(t,n)=>({type:i,props:{...t(i),id:n(i),direction:"column",name:"Subscribe",content:[e("Text",t,n,c()),e("Text",t,n),e("Form",t,n)]}}),Ticker:(t,n)=>x("Scrolling Bar",C,R,P.map(o=>({text:o.text,style:b,muted:!0})),t,n),SpecStrip:(t,n)=>x("Spec Strip",{...h,sectionBorder:{top:1}},E,S().map(o=>({text:o.text??"",style:_,muted:o.tone==="muted"})),t,n),TimelineTrack:(t,n)=>{const o=m=>e(i,t,n,{...B,name:"Year",sectionPaddingTop:0,sectionPaddingBottom:0,...m?{upcoming:!0}:{},content:[e(i,t,n,{...s,sectionPaddingTop:0,sectionPaddingBottom:0,content:[e("Text",t,n,p()),e("Text",t,n,c())]}),e("Text",t,n)]});return{type:i,props:{...t(i),id:n(i),direction:"column",gap:48,name:"Milestone Timeline",content:[e(i,t,n,{direction:"row",align:"end",justify:"between",share:"content",name:"Heading",content:[e("Text",t,n,p()),e("Text",t,n,c()),e("Text",t,n)]}),e(i,t,n,{direction:"row",share:"equal",gap:0,line:!0,name:"Years",content:[o(!1),o(!1),o(!0)]}),e("ButtonBlock",t,n)]}}},Timeline:(t,n)=>{const o=()=>e(i,t,n,{direction:"row",share:[25],gap:24,name:"Chapter",content:[e("Text",t,n,p()),e(i,t,n,{direction:"column",gap:12,name:"Words",content:[e("Text",t,n,c()),e("Text",t,n)]})]});return{type:i,props:{...t(i),id:n(i),direction:"row",share:[33],gap:48,name:"Story Timeline",content:[e(i,t,n,{direction:"column",gap:24,name:"Heading",content:[e("Text",t,n,p()),e("Text",t,n,c()),e("Text",t,n),e("ImageBlock",t,n),e("ButtonBlock",t,n)]}),e(i,t,n,{direction:"column",gap:48,line:!1,name:"Chapters",content:[o(),o(),o()]})]}}}};function x(t,n,o,m,T,g){return e(i,T,g,{...y,...n,blockSpacing:"gap",padV2:!0,name:t,sectionPaddingTop:o.top,sectionPaddingBottom:o.bottom,sectionPaddingTopPhone:o.topPhone,sectionPaddingBottomPhone:o.bottomPhone,content:m.map(r=>e("Text",T,g,{text:r.text,...r.muted?{tone:"dim"}:{},_partStyles:{text:r.style}}))})}function Y(t){return k[t]??null}export{k as SECTION_PRESETS,Y as presetFor};
1
+ import{BOX_TYPE as i}from"../document/container-blocks.js";import{headingTextSeed as m,labelTextSeed as a}from"../document/text-seeds.js";import{TICKER_SCAFFOLD_ITEMS as x}from"../document/blocks/general/Ticker/meta.js";import{specStripScaffold as d}from"../document/blocks/general/SpecStrip/meta.js";import{darkBandIndex as s,normalizeTheme as h}from"../theme.js";import{SPEC_PAD as u,SPEC_STRIP as g,SPEC_TEXT as B,STRIP_BOX as E,TICKER_PAD as _,TICKER_SMALL as b,TICKER_STRIP as R}from"./strip-shape.js";function n(t,e,o,c={}){return{type:t,props:{...e(t),id:o(t),...c}}}function S(t,e,o){return n(i,t,e,{...o,sectionPaddingTop:void 0,sectionPaddingBottom:void 0})}const C={Manifesto:(t,e)=>({type:i,props:{...t(i),id:e(i),direction:"row",share:"equal",sectionHeightMode:"screen",name:"Brand Text",content:[n(i,t,e,{direction:"column",justify:"center",blockSpacing:"gap",name:"Text",sectionPaddingTop:100,sectionPaddingBottom:100,sectionPaddingLeft:40,sectionPaddingRight:40,content:[n("Text",t,e,a()),n("Text",t,e,m()),n("Text",t,e),n("Stats",t,e)]}),S(t,e,{direction:"column",name:"Picture",content:[]})]}}),Split:(t,e)=>({type:i,props:{...t(i),id:e(i),direction:"row",share:"equal",sectionHeightMode:"screen",sectionHeightValue:70,name:"Image & Text Split",content:[n(i,t,e,{direction:"column",justify:"center",blockSpacing:"gap",name:"Text",sectionPaddingTop:100,sectionPaddingBottom:100,sectionPaddingLeft:60,sectionPaddingRight:60,content:[n("Text",t,e,a()),n("Text",t,e,m()),n("Text",t,e),n("ButtonBlock",t,e)]}),S(t,e,{direction:"column",name:"Image",content:[n("ImageBlock",t,e)]})]}}),Subscribe:(t,e)=>({type:i,props:{...t(i),id:e(i),direction:"column",name:"Subscribe",content:[n("Text",t,e,m()),n("Text",t,e),n("Form",t,e)]}}),Ticker:(t,e)=>P("Scrolling Bar",R,_,x.map(o=>({text:o.text,style:b,muted:!0})),t,e),SpecStrip:(t,e,o)=>P("Spec Strip",o?.theme?{...g,sectionAccent:s(h(o.theme))}:{...g,sectionBorder:{top:1}},u,d().map(c=>({text:c.text??"",style:B,muted:c.tone==="muted"})),t,e)};function P(t,e,o,c,p,T){return n(i,p,T,{...E,...e,blockSpacing:"gap",padV2:!0,name:t,sectionPaddingTop:o.top,sectionPaddingBottom:o.bottom,sectionPaddingTopPhone:o.topPhone,sectionPaddingBottomPhone:o.bottomPhone,content:c.map(r=>n("Text",p,T,{text:r.text,...r.muted?{tone:"dim"}:{},_partStyles:{text:r.style}}))})}function K(t){return C[t]??null}export{C as SECTION_PRESETS,K as presetFor};
@@ -1 +1 @@
1
- const e={direction:"column",justify:"between",gap:14,sectionPaddingLeft:14,sectionPaddingRight:14,sectionPaddingLeftPhone:0,sectionHeightMode:"fixed",sectionHeightValue:280,sectionHeightUnit:"px",sectionHeightModePhone:"auto"},t={name:"Year and title",direction:"column",gap:14};export{e as TIMELINE_YEAR_BOX,t as TIMELINE_YEAR_HEAD};
1
+ const e={direction:"column",justify:"between",gap:14,gapPhone:14,sectionPaddingLeft:14,sectionPaddingRight:14,sectionPaddingLeftPhone:0,sectionHeightMode:"fixed",sectionHeightValue:280,sectionHeightUnit:"px",sectionHeightModePhone:"auto"},t={name:"Year and title",direction:"column",gap:14,gapPhone:14};export{e as TIMELINE_YEAR_BOX,t as TIMELINE_YEAR_HEAD};
@@ -4,6 +4,7 @@ export interface SizedImage {
4
4
  srcSet?: string;
5
5
  }
6
6
  export declare const CONTENT_SIZES = "(max-width: 800px) 100vw, min(100vw, 1600px)";
7
+ export declare const HALF_SIZES = "(max-width: 960px) 100vw, 50vw";
7
8
  export declare function sizedImage(src: string, { fallbackWidth, maxWidth }?: {
8
9
  fallbackWidth?: number;
9
10
  maxWidth?: number;
@@ -1 +1 @@
1
- import{imageCopyUrl as s,imageSrcSet as u}from"efficient-shell/image-copies";let o;function c(t){o=t}function n(){return o===void 0?{}:{host:o}}const f="(max-width: 800px) 100vw, min(100vw, 1600px)";function d(t,{fallbackWidth:e=1280,maxWidth:r}={}){const i=u(t,{...n(),...r===void 0?{}:{maxWidth:r}});return i?{src:s(t,e,n()),srcSet:i}:{src:t}}function m(t){const e=s(t,1920,n());return e===t?`url(${t})`:`url("${e}")`}export{f as CONTENT_SIZES,c as __setImageCopiesHostForTests,m as sizedBackground,d as sizedImage};
1
+ import{imageCopyUrl as s,imageSrcSet as p}from"efficient-shell/image-copies";let o;function c(t){o=t}function n(){return o===void 0?{}:{host:o}}const x="(max-width: 800px) 100vw, min(100vw, 1600px)",d="(max-width: 960px) 100vw, 50vw";function f(t,{fallbackWidth:e=1280,maxWidth:r}={}){const i=p(t,{...n(),...r===void 0?{}:{maxWidth:r}});return i?{src:s(t,e,n()),srcSet:i}:{src:t}}function m(t){const e=s(t,1920,n());return e===t?`url(${t})`:`url("${e}")`}export{x as CONTENT_SIZES,d as HALF_SIZES,c as __setImageCopiesHostForTests,m as sizedBackground,f as sizedImage};
@@ -0,0 +1,6 @@
1
+ import { type RuleReport, type SourceFile } from "./rule.js";
2
+ export type PagePicturePlaceOptions = {
3
+ readonly allowed?: Readonly<Record<string, string>>;
4
+ readonly minFiles: number;
5
+ };
6
+ export declare function pagePicturePlace(files: readonly SourceFile[], options: PagePicturePlaceOptions): RuleReport;
@@ -0,0 +1,4 @@
1
+ import{ruleChecks as y}from"./rule.js";const h="<img",l="<Image",$=/createElement\(\s*["']img["']/g,b=/(^|\s)loading=(?:"lazy"|\{(?!\s*["'`]eager))|\{\s*loading:\s*"lazy"/,w=/\.\.\.\s*\(?\s*(?:deferred\b|useDeferredPicture\b)/,k=/\spriority(?=[\s/>]|=\{true\})|\sloading=(?:"eager"|\{\s*["'`]eager)/;function u(r,t){const s=[];let a=r.indexOf(t);for(;a!==-1;){const i=r[a+t.length];if(i===void 0||/\s|\/|>/.test(i)){let o=0,n=a;for(;n<r.length;n+=1)if(r[n]==="{")o+=1;else if(r[n]==="}")o-=1;else if(r[n]===">"&&o===0)break;s.push(r.slice(a,n+1))}a=r.indexOf(t,a+1)}return s}function g(r){const t=r.replace(/\/\*[\s\S]*?\*\/|(^|\s)\/\/.*$/gm,"$1"),s=/\buseDeferredPicture\(/.test(t);return[...u(t,h).filter(a=>!b.test(a)&&!(s&&w.test(a))),...u(t,l).filter(a=>k.test(a)),...t.match($)??[]]}function E(r,t){const{check:s,report:a}=y("page picture place"),i=t.allowed??{};{const e=c=>`${h} ${c} />`,d=[["a bare tag",e('src={a} alt=""')],["a tag with an arrow in a handler",e("src={a} onError={() => fail()}")],["an eager tag",e('src={a} loading="eager"')],["an eager tag in braces",e('src={a} loading={"eager"}')],["a look-alike attribute",e('src={a} data-loading="x"')],["the word in a handler",e("src={a} onLoad={() => { state.loading = false; }}")],["a spread of `deferred` from anywhere",e("src={a} {...deferred}")],["a created tag",'createElement("img", { src: a })'],["a next image asked first",`${l} src={a} priority />`],["a next image made eager",`${l} src={a} loading="eager" />`],["a next image made eager in braces",`${l} src={a} loading={"eager"} />`]];for(const[c,f]of d)s(`the reader finds ${c}`,g(f).length===1);const p=[["a lazy tag",e('src={a} loading="lazy"')],["a lazy tag in braces",e('src={a} loading={"lazy"}')],["a loading chosen in code",e('src={a} loading={far ? "lazy" : "eager"}')],["a conditional lazy tag",e('src={a} {...(far ? { loading: "lazy" as const } : {})}')],["a spread from the page's place",`const deferred = useDeferredPicture(); ${e("src={a} {...deferred}")}`],["a next image",`${l} src={a} />`],["a next image chosen by place",`${l} src={a} {...(far ? {} : { priority: true })} />`],["a lookalike block",`${l}Block src={a} priority />`],["another element that starts the same",`${h}Row src={a} />`]];for(const[c,f]of p)s(`…and leaves ${c} alone`,g(f).length===0)}const o=r.filter(e=>e.path.endsWith(".tsx"));s(`read the source (${o.length} .tsx files, at least ${t.minFiles})`,o.length>=t.minFiles,"fewer means the walk broke, and every check below is vacuous");const n=o.filter(e=>!(e.path in i)).flatMap(e=>g(e.text).map(()=>e.path));s("every plain picture says how it loads",n.length===0,`
2
+ ${n.join(`
3
+ `)}
4
+ Draw a PagePicture, or spread useDeferredPicture (lib/first-screen).`);const m=Object.keys(i).filter(e=>!o.some(d=>d.path===e&&g(d.text).length>0));return s("every exemption still draws a silent picture",m.length===0,`drop these from \`allowed\`: ${m.join(", ")}`),a()}export{E as pagePicturePlace};
@@ -1,2 +1,2 @@
1
- import{fontRoleOfClassName as y,FONT_ROLE_LABELS as x}from"../fonts.js";import{inlineTextSizes as w,isRuleSource as E,ruleChecks as N}from"./rule.js";import{enclosingLiteral as R}from"./heading-ceiling-sweep.js";import{stripComments as b}from"./support/ts-source.js";import{typeScaleGroupOfClassName as u}from"../theme.js";const T=["app/","components/","lib/"],p={"font-display":"heading","font-heading2":"heading2","font-heading3":"heading3","font-body":"body","font-serif":"accent","font-mono":"label"},k={heading:"--font-role-heading",heading2:"--font-role-heading2",heading3:"--font-role-heading3",body:"--font-role-body",accent:"--font-role-accent",label:"--font-role-label"},$=[];function L(m){const n=[],t=new Set;for(const d of m){const c=b(w(d.text)),l=/\bfont-(?:display|body|serif|mono)\b/g;let r;for(;r=l.exec(c);){const i=R(c,r.index);if(!i)continue;const o=c.slice(0,r.index).split(`
2
- `).length,h=`${d.path}:${o}:${i}`;if(t.has(h))continue;t.add(h);const g=i.split(/\s+/).filter(a=>!a.slice(0,a.lastIndexOf(":")+1).includes("&")).map(a=>a.slice(a.lastIndexOf(":")+1)),f=Object.keys(p).filter(a=>g.includes(a));f.length!==0&&n.push({file:d.path,line:o,className:i,utilities:f})}}return n}function I(m,n){const{check:t,report:d}=N("part style naming"),c=m.filter(e=>/\.tsx?$/.test(e.path)&&!E(e.path)&&T.some(s=>e.path.startsWith(s))),l=L(c),r=new Map(m.map(e=>[e.path,e]));t(`read the source (${c.length} .ts/.tsx files)`,c.length>0,"found no source to sweep — this rule is not measuring anything"),t(`the scanner finds face-tagged class lists at all (${l.length}, at least ${n.minSites})`,l.length>=n.minSites);const i=l.filter(e=>u(e.className)!==null),o=l.filter(e=>u(e.className)===null);t(`…both taggings are represented, so neither branch below is untested (${i.length} with a scale token, at least ${n.minWithScale})`,i.length>=n.minWithScale&&i.length>0),t(`…and the face-without-a-size-knob population is real, not an artefact (${o.length}, at least ${n.minWithoutScale})`,o.length>=n.minWithoutScale&&o.length>0,`${o.length} class lists carry a face utility and no matching scale token`);const h=l.filter(e=>y(e.className)!==p[e.utilities[0]]);if(t("every class list in the census reads back as its own utility's role",h.length===0,h.slice(0,5).map(e=>`${e.file}:${e.line} has ${e.utilities[0]} but reads ${y(e.className)}`).join("; ")),n.roleSheet!==void 0){const e=r.get(n.roleSheet),s=Object.values(k).filter(O=>!e||!e.text.includes(O));t(`…and every role named here is a custom property ${n.roleSheet} defines`,!!e&&s.length===0,e?s.join(", "):"the sheet was not read")}const g=Object.values(p).filter(e=>!(e in x));t("every face utility names a role the panel offers",g.length===0,g.join(", "));const f=Object.keys(x).filter(e=>!Object.values(p).includes(e));t("…and the roles no utility can name are exactly the ones decided to have none",f.join()===$.join(),`no utility reaches: [${f}] — expected [${$}]`);const a=o.filter(e=>u(e.className)!==null);t("no class list without a scale token claims a size group",a.length===0,a.slice(0,5).map(e=>`${e.file}:${e.line}`).join("; ")),t("the reported case: a `font-display text-[22px]` heading is Headings, size group none",y("font-display text-[22px] font-medium")==="heading"&&u("font-display text-[22px] font-medium")===null),t("…and genuinely body-tagged copy still reads as the body size group",u("text-[var(--size-body,16px)]")==="body");const S=l.filter(e=>e.utilities.length>1);if(t("every class list names at most one face",S.length===0,S.slice(0,5).map(e=>`${e.file}:${e.line} — ${e.utilities.join(" + ")}`).join("; ")),n.panel!==void 0){const e=r.get(n.panel),s=e?b(e.text):"";t(`read the part panel ${n.panel}`,!!e),t("the box's name comes from the FACE, not from a size group",s.includes("FONT_ROLE_LABELS[face.role]")&&!s.includes("TYPE_GROUP_LABELS[")),t("…a face the page does not draw as its declared role is called Custom",/return\s*"Custom"/.test(s)&&s.includes('kind: "custom"')),t("…and a part no size knob reaches says so under the text box",/sizeGroup === null(?: && shows\("fixedSizeHint"\))? && \(\s*<p className="es-field-hint sf-hint-keep">(?:\{say\(")?Fixed size/.test(s))}if(n.bridge!==void 0){const e=r.get(n.bridge),s=e?b(e.text):"";t(`read the preview's part bridge ${n.bridge}`,!!e),t("the preview publishes BOTH tags, each walked up to its own nearest declarer",s.includes("fontRoleOfClassName")&&s.includes("typeScaleGroupOfClassName")&&s.includes("el.parentElement")),t("…and the element it reads from is one that declares EITHER tag",/partStyleSource\([\s\S]{0,200}fontRoleOfClassName[\s\S]{0,120}typeScaleGroupOfClassName/.test(s))}return d()}export{I as partStyleNaming};
1
+ import{fontRoleOfClassName as y,FONT_ROLE_LABELS as x}from"../fonts.js";import{inlineTextSizes as w,isRuleSource as E,ruleChecks as N}from"./rule.js";import{enclosingLiteral as R}from"./heading-ceiling-sweep.js";import{stripComments as b}from"./support/ts-source.js";import{typeScaleGroupOfClassName as u}from"../theme.js";const T=["app/","components/","lib/"],p={"font-display":"heading","font-heading2":"heading2","font-heading3":"heading3","font-body":"body","font-serif":"accent","font-mono":"label"},L={heading:"--font-role-heading",heading2:"--font-role-heading2",heading3:"--font-role-heading3",body:"--font-role-body",accent:"--font-role-accent",label:"--font-role-label"},$=[];function j(m){const n=[],t=new Set;for(const d of m){const c=b(w(d.text)),l=/\bfont-(?:display|body|serif|mono)\b/g;let r;for(;r=l.exec(c);){const i=R(c,r.index);if(!i)continue;const o=c.slice(0,r.index).split(`
2
+ `).length,h=`${d.path}:${o}:${i}`;if(t.has(h))continue;t.add(h);const g=i.split(/\s+/).filter(a=>!a.slice(0,a.lastIndexOf(":")+1).includes("&")).map(a=>a.slice(a.lastIndexOf(":")+1)),f=Object.keys(p).filter(a=>g.includes(a));f.length!==0&&n.push({file:d.path,line:o,className:i,utilities:f})}}return n}function I(m,n){const{check:t,report:d}=N("part style naming"),c=m.filter(e=>/\.tsx?$/.test(e.path)&&!E(e.path)&&T.some(s=>e.path.startsWith(s))),l=j(c),r=new Map(m.map(e=>[e.path,e]));t(`read the source (${c.length} .ts/.tsx files)`,c.length>0,"found no source to sweep — this rule is not measuring anything"),t(`the scanner finds face-tagged class lists at all (${l.length}, at least ${n.minSites})`,l.length>=n.minSites);const i=l.filter(e=>u(e.className)!==null),o=l.filter(e=>u(e.className)===null);t(`…both taggings are represented, so neither branch below is untested (${i.length} with a scale token, at least ${n.minWithScale})`,i.length>=n.minWithScale&&i.length>0),t(`…and the face-without-a-size-knob population is real, not an artefact (${o.length}, at least ${n.minWithoutScale})`,o.length>=n.minWithoutScale&&o.length>0,`${o.length} class lists carry a face utility and no matching scale token`);const h=l.filter(e=>y(e.className)!==p[e.utilities[0]]);if(t("every class list in the census reads back as its own utility's role",h.length===0,h.slice(0,5).map(e=>`${e.file}:${e.line} has ${e.utilities[0]} but reads ${y(e.className)}`).join("; ")),n.roleSheet!==void 0){const e=r.get(n.roleSheet),s=Object.values(L).filter(O=>!e||!e.text.includes(O));t(`…and every role named here is a custom property ${n.roleSheet} defines`,!!e&&s.length===0,e?s.join(", "):"the sheet was not read")}const g=Object.values(p).filter(e=>!(e in x));t("every face utility names a role the panel offers",g.length===0,g.join(", "));const f=Object.keys(x).filter(e=>!Object.values(p).includes(e));t("…and the roles no utility can name are exactly the ones decided to have none",f.join()===$.join(),`no utility reaches: [${f}] — expected [${$}]`);const a=o.filter(e=>u(e.className)!==null);t("no class list without a scale token claims a size group",a.length===0,a.slice(0,5).map(e=>`${e.file}:${e.line}`).join("; ")),t("the reported case: a `font-display text-[22px]` heading is Headings, size group none",y("font-display text-[22px] font-medium")==="heading"&&u("font-display text-[22px] font-medium")===null),t("…and genuinely body-tagged copy still reads as the body size group",u("text-[var(--size-body,16px)]")==="body");const S=l.filter(e=>e.utilities.length>1);if(t("every class list names at most one face",S.length===0,S.slice(0,5).map(e=>`${e.file}:${e.line} — ${e.utilities.join(" + ")}`).join("; ")),n.panel!==void 0){const e=r.get(n.panel),s=e?b(e.text):"";t(`read the part panel ${n.panel}`,!!e),t("the box's name comes from the FACE, not from a size group",s.includes("FONT_ROLE_LABELS[face.role]")&&!s.includes("TYPE_GROUP_LABELS[")),t("…a face the page does not draw as its declared role is called Custom",/return\s*"Custom"/.test(s)&&s.includes('kind: "custom"')),t("…and a part no size knob reaches says so under the text box",/sizeGroup === null(?: && shows\("fixedSizeHint"\))? && \(\s*<InertHint>(?:\{say\(")?Fixed size/.test(s))}if(n.bridge!==void 0){const e=r.get(n.bridge),s=e?b(e.text):"";t(`read the preview's part bridge ${n.bridge}`,!!e),t("the preview publishes BOTH tags, each walked up to its own nearest declarer",s.includes("fontRoleOfClassName")&&s.includes("typeScaleGroupOfClassName")&&s.includes("el.parentElement")),t("…and the element it reads from is one that declares EITHER tag",/partStyleSource\([\s\S]{0,200}fontRoleOfClassName[\s\S]{0,120}typeScaleGroupOfClassName/.test(s))}return d()}export{I as partStyleNaming};
@@ -73,7 +73,8 @@ export declare function surfaceTwoTone(preset: ThemeColors): string;
73
73
  export declare function sectionBandTone(preset: ThemeColors): string;
74
74
  export declare function bandPresetFor(preset: ThemeColors): ThemeColors;
75
75
  export declare function bandPresetIndex(presets: readonly ThemeColors[], page: number): number;
76
- export declare function darkPresetIndex(presets: readonly ThemeColors[] | null | undefined): number;
76
+ export declare function darkPresetIndex(presets: readonly ThemeColors[] | null | undefined, page?: number): number;
77
+ export declare function darkBandIndex(theme: ThemeValue | null | undefined): number;
77
78
  export declare const THEME_SURFACE_KEYS: readonly ["--theme-bg", "--theme-surface", "--theme-surface-2", "--theme-line", "--theme-muted"];
78
79
  export declare function themeSurfaceStyle(v?: ThemeValue | null): Record<string, string>;
79
80
  export declare const TYPE_GROUPS: readonly ["heading", "body", "label"];
@@ -1,4 +1,4 @@
1
- import{contrastRatio as j,hexToRgb as h,parseHexColor as f,readableInk as V,relativeLuminance as x}from"efficient-shell/format";const Z="storefront-theme",Le="sf:theme-mode",ke="sf:theme-switch",Pe="hide",$e="light",Fe=!1,R=7,D=18;function q(e){return e>=R&&e<D}function Ue(e){const{mode:t,override:n,switchShown:r,hour:o}=e;return r&&(n==="light"||n==="dark")?n:t==="auto"?q(o)?"light":"dark":t==="light"?"light":"dark"}function Ge(e){const{mode:t,switchShown:n}=e;return`
1
+ import{contrastRatio as j,hexToRgb as h,parseHexColor as f,readableInk as V,relativeLuminance as x}from"efficient-shell/format";const Z="storefront-theme",Le="sf:theme-mode",Pe="sf:theme-switch",$e="hide",Fe="light",Ue=!1,R=7,D=18;function q(e){return e>=R&&e<D}function Ge(e){const{mode:t,override:n,switchShown:r,hour:o}=e;return r&&(n==="light"||n==="dark")?n:t==="auto"?q(o)?"light":"dark":t==="light"?"light":"dark"}function Ye(e){const{mode:t,switchShown:n}=e;return`
2
2
  try {
3
3
  var mode = ${JSON.stringify(t)};
4
4
  var shown = ${n?"true":"false"};
@@ -15,4 +15,4 @@ import{contrastRatio as j,hexToRgb as h,parseHexColor as f,readableInk as V,rela
15
15
  if (theme === 'light') document.documentElement.setAttribute('data-theme', 'light');
16
16
  else document.documentElement.removeAttribute('data-theme');
17
17
  } catch (e) {}
18
- `}const s={background:"#0a0a0a",surface:"#131313",line:"#2a2a2a",muted:"#9a9388"},J=[{text:"#2e2e2e",accent:"#2e2e2e",background:"#ffffff",surface:"#f7f7f7",line:"#e0e0e0",muted:"#5c5c5c"},{text:"#f7f7f7",accent:"#f7f7f7",background:"#0a0a0a",surface:"#1b1b1b",line:"#363636",muted:"#a3a3a3"},{text:"#ffffff",accent:"#ffffff",background:"#2e2e2e",surface:"#3d3d3d",line:"#545454",muted:"#b0b0b0"},{text:"#0a0a0a",accent:"#0a0a0a",background:"#f7f7f7",surface:"#ffffff",line:"#d9d9d9",muted:"#5c5c5c"}],Q={selected:0,themes:J};function H(e){return!e||!Array.isArray(e.themes)||e.themes.length===0?{...Q}:{selected:Math.min(Math.max(0,e.selected??0),e.themes.length-1),themes:e.themes}}function p(e,t,n){const r=h(e),o=h(t);if(r===null||o===null)return e;const c=(i,a)=>Math.max(0,Math.min(255,Math.round(i+(a-i)*n))).toString(16).padStart(2,"0");return`#${c(r.r,o.r)}${c(r.g,o.g)}${c(r.b,o.b)}`}const v={light:"#ffffff",dark:"#0a0a0a"},Ye=["light","dark"];function ze(e,t){const n=v[t],r=t==="light"?"#ffffff":"#000000";return{text:n,accent:n,background:e,surface:p(e,r,.1),line:p(e,r,.22),muted:p(n,e,.35),brandInk:t}}function u(e){const t=H(e);return t.themes[t.selected]}function l(e){return{text:e.text,accent:e.accent,background:e.background||s.background,surface:e.surface||s.surface,line:e.line||s.line,muted:e.muted||s.muted}}function Be(e){return{fill:l(e).background,accent:e.accent}}const ee=.4,te=4.5,ne=3,Xe={good:"Good","large-only":"Large text only",hard:"Hard to read"};function We(e){return e>=te?"good":e>=ne?"large-only":"hard"}const re=["#000000","#ffffff"];function d(e){return V(e,re)}const oe=[.25,.4,.55];function Ke(e){const t=h(e);return t===null?[]:oe.map(n=>"#"+[t.r,t.g,t.b].map(r=>Math.round(r*(1-n)).toString(16).padStart(2,"0")).join(""))}function je(e){const t=u(e),n={"--theme-fg":t.text},r=x(t.text);return(r===null||r>=ee)&&(n["--overlay-fg"]=t.text),n}const ce=82;function _(e){return`color-mix(in srgb, ${e} ${ce}%, #000)`}function Ve(e){const t=u(e);return{"--theme-accent":t.accent,"--theme-accent-2":_(t.accent),"--theme-accent-ink":d(t.accent)}}function E(e){const t=e?.button;return t&&f(t)===t.toLowerCase()?t.toLowerCase():null}function Ze(e){const t=u(e),n=E(t),r=N(t);if(n===null&&r===null)return{};const o={};return n!==null&&(o["--theme-btn"]=n,o["--theme-btn-2"]=_(n)),o["--theme-btn-ink"]=r??d(n),o}function N(e){const t=e?.buttonInk;return t&&f(t)===t.toLowerCase()?t.toLowerCase():null}function ie(e,t){return N(e)??d(E(e)??t)}function qe(e){const t=u(e);return{fill:E(t)??t.accent.toLowerCase(),ink:ie(t,t.accent)}}function Je(e){const t={};return H(e).themes.forEach((n,r)=>{const o=l(n);t[`--theme-preset-${r}-accent`]=o.accent,t[`--theme-preset-${r}-accent-2`]=_(o.accent),t[`--theme-preset-${r}-accent-ink`]=d(o.accent),t[`--theme-preset-${r}-bg`]=o.background,t[`--theme-preset-${r}-fg`]=o.text,t[`--theme-preset-${r}-surface`]=o.surface,t[`--theme-preset-${r}-surface-2`]=`color-mix(in srgb, ${o.surface} 60%, ${o.line})`,t[`--theme-preset-${r}-line`]=o.line,t[`--theme-preset-${r}-muted`]=o.muted}),t}const S=e=>{const t=e/255;return t<=.04045?t/12.92:((t+.055)/1.055)**2.4},A=e=>255*(e<=.0031308?12.92*e:1.055*e**(1/2.4)-.055);function O([e,t,n]){const[r,o,c]=[S(e),S(t),S(n)],i=Math.cbrt(.4122214708*r+.5363325363*o+.0514459929*c),a=Math.cbrt(.2119034982*r+.6806995451*o+.1073969566*c),m=Math.cbrt(.0883024619*r+.2817188376*o+.6299787005*c);return[.2104542553*i+.793617785*a-.0040720468*m,1.9779984951*i-2.428592205*a+.4505937099*m,.0259040371*i+.7827717662*a-.808675766*m]}function se([e,t,n]){const r=(e+.3963377774*t+.2158037573*n)**3,o=(e-.1055613458*t-.0638541728*n)**3,c=(e-.0894841775*t-1.291485548*n)**3;return[A(4.0767416621*r-3.3077115913*o+.2309699292*c),A(-1.2684380046*r+2.6097574011*o-.3413193965*c),A(-.0041960863*r-.7034186147*o+1.707614701*c)]}const T=e=>{const t=h(e);return t===null?[0,0,0]:[t.r,t.g,t.b]},L=(e,t,n)=>[e[0]*n+t[0]*(1-n),e[1]*n+t[1]*(1-n),e[2]*n+t[2]*(1-n)],k=e=>`#${e.map(t=>Math.max(0,Math.min(255,Math.round(t))).toString(16).padStart(2,"0")).join("")}`,P=e=>L(T(e.surface),T(e.line),.6);function Qe(e){return k(P(l(e)))}function $(e){const t=l(e);return k(se(L(O(P(t)),O(T(t.text)),.92)))}function ve(e){return{...e,background:$(e)}}function et(e,t){const n=e[t];if(!n)return-1;const r=$(n);return e.findIndex((o,c)=>c!==t&&f(o.background??"")===r)}const ae=1;function tt(e){const t=(e??[]).findIndex(n=>{const r=x(n.background??""),o=x(n.text??"");return r!==null&&o!==null&&r<o});return t>=0?t:ae}const nt=["--theme-bg","--theme-surface","--theme-surface-2","--theme-line","--theme-muted"];function rt(e){const t=l(u(e)),n=`color-mix(in srgb, ${t.surface} 60%, ${t.line})`,r={"--theme-bg":t.background,"--theme-surface":t.surface,"--theme-line":t.line,"--theme-muted":t.muted};return(t.surface!==s.surface||t.line!==s.line)&&(r["--theme-surface-2"]=n),r}const ue=["heading","body","label"],ot={heading:"Headings",body:"Body",label:"Labels"};function ct(e){if(!e)return null;for(const t of ue)if(e.includes(`--size-${t}`))return t;return/--size-heading(Large|Medium|Small)/.test(e)?"heading":null}const F=["headingLarge","headingMedium","headingSmall","accent","body","label"],it={headingLarge:"heading",headingMedium:"heading",headingSmall:"heading",accent:"heading",body:"body",label:"label"},st={headingLarge:null,headingMedium:null,headingSmall:null,accent:null,body:null,label:null},le=8,he=200;function fe(e){if(typeof e!="number"||!Number.isFinite(e))return null;const t=Math.round(e);return t>=le&&t<=he?t:null}function de(e){const t={};for(const n of F)t[n]=fe(e?.[n]);return t}function at(e){const t=de(e),n={};for(const r of F){const o=t[r];o!==null&&(n[`--size-${r}`]=`${o}px`)}return n}const ge=["square","small","large"],me="small";function xe(e){return ge.includes(e??"")?e:me}function ut(e){return G(_e[xe(e)])}const b=0,pe=40,_e={square:0,small:null,large:16},U={"--sf-card-radius":1,"--sf-button-radius":.5,"--site-radius":.5,"--site-radius-xs":.25,"--site-radius-sm":.5,"--site-radius-md":.75,"--site-radius-lg":1,"--site-radius-xl":1.25,"--site-radius-2xl":1.5,"--site-radius-3xl":2,"--site-radius-4xl":2.5};function C(e){if(e==null||typeof e=="string"&&e.trim()==="")return null;const t=typeof e=="string"?Number(e):e;return Number.isFinite(t)?Math.min(pe,Math.max(b,Math.round(t))):null}function G(e){const t=C(e);return t===null?{}:Object.fromEntries(Object.entries(U).map(([n,r])=>{const o=t*r/16;return[n,o===0?"0":`${o}rem`]}))}function lt(e){return(C(e)??b)*U["--sf-button-radius"]}function ht(e){return G(C(e)??b)}const Ee=["none","soft","lifted"],Se="soft",Y="none",Ae=["tight","normal","roomy"],Te="normal",be="normal",Ce=["none","lift","highlight"],Ie="lift",we="highlight",z="#141416";function B(e){return Ee.includes(e??"")?e:Se}function ye(e){return Ae.includes(e??"")?e:Te}function X(e){return Ce.includes(e??"")?e:Ie}function Me(e){return e&&f(e)===e.toLowerCase()?e.toLowerCase():z}function ft(e){const t=B(e);return t===Y?void 0:t}function dt(e){const t=ye(e);return t===be?void 0:t}function gt(e){const t=X(e);return t===we?void 0:t}function mt(e,t,n){const r=Me(t);return r===z?{}:B(e)!==Y||X(n)==="lift"?{"--sf-shadow-color":r}:{}}const Re=["normal","tight","compressed"],W="normal";function K(e){return Re.includes(e??"")?e:W}function xt(e){const t=K(e);return t===W?void 0:t}function pt(e){switch(K(e)){case"tight":return{lineHeight:.95,letterSpacing:-.01};case"compressed":return{lineHeight:.86,letterSpacing:-.01};default:return{}}}const _t=["authored","sentence"],Et={case:"authored",weight:null,weightStrong:null,italicStrong:null,maxPx:null,weight2:null,weight3:null,case2:"authored",case3:"authored"},I=100,w=900,De=24,He=200;function g(e,t,n){return typeof e!="number"||!Number.isFinite(e)?null:Math.round(Math.min(Math.max(e,t),n))}function y(e){const t=g(e?.weight,I,w),n=e?.case==="sentence"?"sentence":"authored",r=c=>c==null?t:g(c,I,w),o=c=>c==="sentence"?"sentence":c==="authored"?"authored":n;return{case:n,weight:t,weightStrong:g(e?.weightStrong,I,w),italicStrong:typeof e?.italicStrong=="boolean"?e.italicStrong:null,maxPx:g(e?.maxPx,De,He),weight2:r(e?.weight2),weight3:r(e?.weight3),case2:o(e?.case2),case3:o(e?.case3)}}function St(e){const t=y(e),n={};return t.case==="sentence"&&(n["--sf-heading-case"]="none"),t.weight!==null&&(n["--sf-heading-weight"]=String(t.weight)),t.weightStrong!==null&&(n["--sf-heading-weight-strong"]=String(t.weightStrong)),t.maxPx!==null&&(n["--sf-heading-max"]=`${t.maxPx}px`),t.weight2!==null&&t.weight2!==t.weight&&(n["--sf-heading-2-weight"]=String(t.weight2)),t.weight3!==null&&t.weight3!==t.weight&&(n["--sf-heading-3-weight"]=String(t.weight3)),t.case2!==t.case&&(n["--sf-heading-2-case"]=t.case2==="sentence"?"none":"uppercase"),t.case3!==t.case&&(n["--sf-heading-3-case"]=t.case3==="sentence"?"none":"uppercase"),n}function At(e){return y({case:e?.heading_case??void 0,weight:e?.heading_weight,weightStrong:e?.heading_weight_strong,italicStrong:e?.accent_italic,maxPx:e?.heading_max_px,weight2:e?.heading_2_weight??void 0,weight3:e?.heading_3_weight??void 0,case2:e?.heading_2_case??void 0,case3:e?.heading_3_case??void 0})}function Tt(e){const t=y(e);return{heading_case:t.case,heading_weight:t.weight,heading_weight_strong:t.weightStrong,heading_max_px:t.maxPx,heading_2_weight:t.weight2,heading_3_weight:t.weight3,heading_2_case:t.case2,heading_3_case:t.case3}}const M="siteTheme";function Ne(e){const t=e;if(!t||typeof t!="object"||!Array.isArray(t.themes)||!t.themes.every(r=>!!r&&typeof r=="object"))return{};const n=typeof t.selected=="number"&&Number.isInteger(t.selected)&&t.selected>=0?t.selected:0;return{[M]:{selected:n,themes:t.themes}}}function bt(e){return Ne(e?.[M])[M]}export{oe as ACCENT_DARKEN_STEPS,Ye as BRAND_INKS,Ae as CARD_GAPS,Ee as CARD_SHADOWS,pe as CORNER_RADIUS_MAX,b as CORNER_RADIUS_MIN,ge as CORNER_STYLES,_e as CORNER_STYLE_TO_PX,Te as DEFAULT_CARD_GAP,Se as DEFAULT_CARD_SHADOW,me as DEFAULT_CORNER_STYLE,W as DEFAULT_HEADING_COMPRESSION,Et as DEFAULT_HEADING_TYPOGRAPHY,Ie as DEFAULT_HOVER_EFFECT,z as DEFAULT_SHADOW_COLOR,st as DEFAULT_SIZES,s as DEFAULT_SURFACES,Fe as DEFAULT_SWITCH_SHOWN,J as DEFAULT_THEMES,$e as DEFAULT_THEME_MODE,Q as DEFAULT_THEME_VALUE,Xe as GRADE_LABEL,_t as HEADING_CASES,Re as HEADING_COMPRESSIONS,He as HEADING_MAX_PX_MAX,De as HEADING_MAX_PX_MIN,w as HEADING_WEIGHT_MAX,I as HEADING_WEIGHT_MIN,Ce as HOVER_EFFECTS,be as IDENTITY_CARD_GAP,Y as IDENTITY_CARD_SHADOW,we as IDENTITY_HOVER_EFFECT,te as READABILITY_AA,ne as READABILITY_AA_LARGE,it as SCALE_OF_STEP,M as SITE_THEME_KEY,F as SIZE_STEPS,he as TEXT_SIZE_MAX,le as TEXT_SIZE_MIN,D as THEME_DAY_END_HOUR,R as THEME_DAY_START_HOUR,Le as THEME_MODE_KEY,Z as THEME_STORAGE_KEY,nt as THEME_SURFACE_KEYS,Pe as THEME_SWITCH_HIDE,ke as THEME_SWITCH_KEY,ue as TYPE_GROUPS,ot as TYPE_GROUP_LABELS,d as accentInk,ve as bandPresetFor,et as bandPresetIndex,ze as brandTheme,Ge as buildThemeBootScript,dt as cardGapAttr,ft as cardShadowAttr,pt as compressionMetrics,j as contrastRatio,G as cornerRadiusTokens,ut as cornerStyleTokens,tt as darkPresetIndex,Ke as darkerAccents,We as gradeContrast,xt as headingCompressionAttr,At as headingTypographyFromRow,St as headingTypographyStyle,Tt as headingTypographyToRow,gt as hoverEffectAttr,q as isDayHour,ye as normalizeCardGap,B as normalizeCardShadow,C as normalizeCornerRadius,xe as normalizeCornerStyle,K as normalizeHeadingCompression,y as normalizeHeadingTypography,X as normalizeHoverEffect,Me as normalizeShadowColor,fe as normalizeSize,de as normalizeSizes,H as normalizeTheme,l as normalizeThemeColors,Ue as resolveTheme,ie as resolvedButtonInk,$ as sectionBandTone,u as selectedThemeColors,mt as shadowColorTokens,qe as siteButtonPaint,lt as siteButtonRadiusPx,ht as siteCornerRadiusTokens,Ne as siteThemeMetadata,bt as siteThemeOf,Qe as surfaceTwoTone,Ve as themeAccentStyle,E as themeButtonColour,N as themeButtonInk,Ze as themeButtonStyle,je as themeColorStyle,Je as themePresetAccentVars,rt as themeSurfaceStyle,Be as themeSwatchColors,ct as typeScaleGroupOfClassName,at as typeSizesStyle};
18
+ `}const s={background:"#0a0a0a",surface:"#131313",line:"#2a2a2a",muted:"#9a9388"},J=[{text:"#2e2e2e",accent:"#2e2e2e",background:"#ffffff",surface:"#f7f7f7",line:"#e0e0e0",muted:"#5c5c5c"},{text:"#f7f7f7",accent:"#f7f7f7",background:"#0a0a0a",surface:"#1b1b1b",line:"#363636",muted:"#a3a3a3"},{text:"#ffffff",accent:"#ffffff",background:"#2e2e2e",surface:"#3d3d3d",line:"#545454",muted:"#b0b0b0"},{text:"#0a0a0a",accent:"#0a0a0a",background:"#f7f7f7",surface:"#ffffff",line:"#d9d9d9",muted:"#5c5c5c"}],Q={selected:0,themes:J};function H(e){return!e||!Array.isArray(e.themes)||e.themes.length===0?{...Q}:{selected:Math.min(Math.max(0,e.selected??0),e.themes.length-1),themes:e.themes}}function p(e,t,n){const r=h(e),o=h(t);if(r===null||o===null)return e;const c=(i,a)=>Math.max(0,Math.min(255,Math.round(i+(a-i)*n))).toString(16).padStart(2,"0");return`#${c(r.r,o.r)}${c(r.g,o.g)}${c(r.b,o.b)}`}const v={light:"#ffffff",dark:"#0a0a0a"},ze=["light","dark"];function Be(e,t){const n=v[t],r=t==="light"?"#ffffff":"#000000";return{text:n,accent:n,background:e,surface:p(e,r,.1),line:p(e,r,.22),muted:p(n,e,.35),brandInk:t}}function u(e){const t=H(e);return t.themes[t.selected]}function l(e){return{text:e.text,accent:e.accent,background:e.background||s.background,surface:e.surface||s.surface,line:e.line||s.line,muted:e.muted||s.muted}}function Xe(e){return{fill:l(e).background,accent:e.accent}}const ee=.4,te=4.5,ne=3,We={good:"Good","large-only":"Large text only",hard:"Hard to read"};function Ke(e){return e>=te?"good":e>=ne?"large-only":"hard"}const re=["#000000","#ffffff"];function d(e){return V(e,re)}const oe=[.25,.4,.55];function je(e){const t=h(e);return t===null?[]:oe.map(n=>"#"+[t.r,t.g,t.b].map(r=>Math.round(r*(1-n)).toString(16).padStart(2,"0")).join(""))}function Ve(e){const t=u(e),n={"--theme-fg":t.text},r=x(t.text);return(r===null||r>=ee)&&(n["--overlay-fg"]=t.text),n}const ce=82;function _(e){return`color-mix(in srgb, ${e} ${ce}%, #000)`}function Ze(e){const t=u(e);return{"--theme-accent":t.accent,"--theme-accent-2":_(t.accent),"--theme-accent-ink":d(t.accent)}}function E(e){const t=e?.button;return t&&f(t)===t.toLowerCase()?t.toLowerCase():null}function qe(e){const t=u(e),n=E(t),r=N(t);if(n===null&&r===null)return{};const o={};return n!==null&&(o["--theme-btn"]=n,o["--theme-btn-2"]=_(n)),o["--theme-btn-ink"]=r??d(n),o}function N(e){const t=e?.buttonInk;return t&&f(t)===t.toLowerCase()?t.toLowerCase():null}function ie(e,t){return N(e)??d(E(e)??t)}function Je(e){const t=u(e);return{fill:E(t)??t.accent.toLowerCase(),ink:ie(t,t.accent)}}function Qe(e){const t={};return H(e).themes.forEach((n,r)=>{const o=l(n);t[`--theme-preset-${r}-accent`]=o.accent,t[`--theme-preset-${r}-accent-2`]=_(o.accent),t[`--theme-preset-${r}-accent-ink`]=d(o.accent),t[`--theme-preset-${r}-bg`]=o.background,t[`--theme-preset-${r}-fg`]=o.text,t[`--theme-preset-${r}-surface`]=o.surface,t[`--theme-preset-${r}-surface-2`]=`color-mix(in srgb, ${o.surface} 60%, ${o.line})`,t[`--theme-preset-${r}-line`]=o.line,t[`--theme-preset-${r}-muted`]=o.muted}),t}const S=e=>{const t=e/255;return t<=.04045?t/12.92:((t+.055)/1.055)**2.4},A=e=>255*(e<=.0031308?12.92*e:1.055*e**(1/2.4)-.055);function O([e,t,n]){const[r,o,c]=[S(e),S(t),S(n)],i=Math.cbrt(.4122214708*r+.5363325363*o+.0514459929*c),a=Math.cbrt(.2119034982*r+.6806995451*o+.1073969566*c),m=Math.cbrt(.0883024619*r+.2817188376*o+.6299787005*c);return[.2104542553*i+.793617785*a-.0040720468*m,1.9779984951*i-2.428592205*a+.4505937099*m,.0259040371*i+.7827717662*a-.808675766*m]}function se([e,t,n]){const r=(e+.3963377774*t+.2158037573*n)**3,o=(e-.1055613458*t-.0638541728*n)**3,c=(e-.0894841775*t-1.291485548*n)**3;return[A(4.0767416621*r-3.3077115913*o+.2309699292*c),A(-1.2684380046*r+2.6097574011*o-.3413193965*c),A(-.0041960863*r-.7034186147*o+1.707614701*c)]}const T=e=>{const t=h(e);return t===null?[0,0,0]:[t.r,t.g,t.b]},k=(e,t,n)=>[e[0]*n+t[0]*(1-n),e[1]*n+t[1]*(1-n),e[2]*n+t[2]*(1-n)],L=e=>`#${e.map(t=>Math.max(0,Math.min(255,Math.round(t))).toString(16).padStart(2,"0")).join("")}`,P=e=>k(T(e.surface),T(e.line),.6);function ve(e){return L(P(l(e)))}function $(e){const t=l(e);return L(se(k(O(P(t)),O(T(t.text)),.92)))}function et(e){return{...e,background:$(e)}}function tt(e,t){const n=e[t];if(!n)return-1;const r=$(n);return e.findIndex((o,c)=>c!==t&&f(o.background??"")===r)}const ae=1;function ue(e,t){const n=(e??[]).flatMap((r,o)=>{const c=x(r.background??""),i=x(r.text??"");return c!==null&&i!==null&&c<i?[o]:[]});return n.find(r=>r!==t)??n[0]??ae}function nt(e){return ue(e?.themes,e?.selected)}const rt=["--theme-bg","--theme-surface","--theme-surface-2","--theme-line","--theme-muted"];function ot(e){const t=l(u(e)),n=`color-mix(in srgb, ${t.surface} 60%, ${t.line})`,r={"--theme-bg":t.background,"--theme-surface":t.surface,"--theme-line":t.line,"--theme-muted":t.muted};return(t.surface!==s.surface||t.line!==s.line)&&(r["--theme-surface-2"]=n),r}const le=["heading","body","label"],ct={heading:"Headings",body:"Body",label:"Labels"};function it(e){if(!e)return null;for(const t of le)if(e.includes(`--size-${t}`))return t;return/--size-heading(Large|Medium|Small)/.test(e)?"heading":null}const F=["headingLarge","headingMedium","headingSmall","accent","body","label"],st={headingLarge:"heading",headingMedium:"heading",headingSmall:"heading",accent:"heading",body:"body",label:"label"},at={headingLarge:null,headingMedium:null,headingSmall:null,accent:null,body:null,label:null},he=8,fe=200;function de(e){if(typeof e!="number"||!Number.isFinite(e))return null;const t=Math.round(e);return t>=he&&t<=fe?t:null}function ge(e){const t={};for(const n of F)t[n]=de(e?.[n]);return t}function ut(e){const t=ge(e),n={};for(const r of F){const o=t[r];o!==null&&(n[`--size-${r}`]=`${o}px`)}return n}const me=["square","small","large"],xe="small";function pe(e){return me.includes(e??"")?e:xe}function lt(e){return G(Ee[pe(e)])}const b=0,_e=40,Ee={square:0,small:null,large:16},U={"--sf-card-radius":1,"--sf-button-radius":.5,"--site-radius":.5,"--site-radius-xs":.25,"--site-radius-sm":.5,"--site-radius-md":.75,"--site-radius-lg":1,"--site-radius-xl":1.25,"--site-radius-2xl":1.5,"--site-radius-3xl":2,"--site-radius-4xl":2.5};function C(e){if(e==null||typeof e=="string"&&e.trim()==="")return null;const t=typeof e=="string"?Number(e):e;return Number.isFinite(t)?Math.min(_e,Math.max(b,Math.round(t))):null}function G(e){const t=C(e);return t===null?{}:Object.fromEntries(Object.entries(U).map(([n,r])=>{const o=t*r/16;return[n,o===0?"0":`${o}rem`]}))}function ht(e){return(C(e)??b)*U["--sf-button-radius"]}function ft(e){return G(C(e)??b)}const Se=["none","soft","lifted"],Ae="soft",Y="none",Te=["tight","normal","roomy"],be="normal",Ce="normal",Ie=["none","lift","highlight"],we="lift",Me="highlight",z="#141416";function B(e){return Se.includes(e??"")?e:Ae}function ye(e){return Te.includes(e??"")?e:be}function X(e){return Ie.includes(e??"")?e:we}function Re(e){return e&&f(e)===e.toLowerCase()?e.toLowerCase():z}function dt(e){const t=B(e);return t===Y?void 0:t}function gt(e){const t=ye(e);return t===Ce?void 0:t}function mt(e){const t=X(e);return t===Me?void 0:t}function xt(e,t,n){const r=Re(t);return r===z?{}:B(e)!==Y||X(n)==="lift"?{"--sf-shadow-color":r}:{}}const De=["normal","tight","compressed"],W="normal";function K(e){return De.includes(e??"")?e:W}function pt(e){const t=K(e);return t===W?void 0:t}function _t(e){switch(K(e)){case"tight":return{lineHeight:.95,letterSpacing:-.01};case"compressed":return{lineHeight:.86,letterSpacing:-.01};default:return{}}}const Et=["authored","sentence"],St={case:"authored",weight:null,weightStrong:null,italicStrong:null,maxPx:null,weight2:null,weight3:null,case2:"authored",case3:"authored"},I=100,w=900,He=24,Ne=200;function g(e,t,n){return typeof e!="number"||!Number.isFinite(e)?null:Math.round(Math.min(Math.max(e,t),n))}function M(e){const t=g(e?.weight,I,w),n=e?.case==="sentence"?"sentence":"authored",r=c=>c==null?t:g(c,I,w),o=c=>c==="sentence"?"sentence":c==="authored"?"authored":n;return{case:n,weight:t,weightStrong:g(e?.weightStrong,I,w),italicStrong:typeof e?.italicStrong=="boolean"?e.italicStrong:null,maxPx:g(e?.maxPx,He,Ne),weight2:r(e?.weight2),weight3:r(e?.weight3),case2:o(e?.case2),case3:o(e?.case3)}}function At(e){const t=M(e),n={};return t.case==="sentence"&&(n["--sf-heading-case"]="none"),t.weight!==null&&(n["--sf-heading-weight"]=String(t.weight)),t.weightStrong!==null&&(n["--sf-heading-weight-strong"]=String(t.weightStrong)),t.maxPx!==null&&(n["--sf-heading-max"]=`${t.maxPx}px`),t.weight2!==null&&t.weight2!==t.weight&&(n["--sf-heading-2-weight"]=String(t.weight2)),t.weight3!==null&&t.weight3!==t.weight&&(n["--sf-heading-3-weight"]=String(t.weight3)),t.case2!==t.case&&(n["--sf-heading-2-case"]=t.case2==="sentence"?"none":"uppercase"),t.case3!==t.case&&(n["--sf-heading-3-case"]=t.case3==="sentence"?"none":"uppercase"),n}function Tt(e){return M({case:e?.heading_case??void 0,weight:e?.heading_weight,weightStrong:e?.heading_weight_strong,italicStrong:e?.accent_italic,maxPx:e?.heading_max_px,weight2:e?.heading_2_weight??void 0,weight3:e?.heading_3_weight??void 0,case2:e?.heading_2_case??void 0,case3:e?.heading_3_case??void 0})}function bt(e){const t=M(e);return{heading_case:t.case,heading_weight:t.weight,heading_weight_strong:t.weightStrong,heading_max_px:t.maxPx,heading_2_weight:t.weight2,heading_3_weight:t.weight3,heading_2_case:t.case2,heading_3_case:t.case3}}const y="siteTheme";function Oe(e){const t=e;if(!t||typeof t!="object"||!Array.isArray(t.themes)||!t.themes.every(r=>!!r&&typeof r=="object"))return{};const n=typeof t.selected=="number"&&Number.isInteger(t.selected)&&t.selected>=0?t.selected:0;return{[y]:{selected:n,themes:t.themes}}}function Ct(e){return Oe(e?.[y])[y]}export{oe as ACCENT_DARKEN_STEPS,ze as BRAND_INKS,Te as CARD_GAPS,Se as CARD_SHADOWS,_e as CORNER_RADIUS_MAX,b as CORNER_RADIUS_MIN,me as CORNER_STYLES,Ee as CORNER_STYLE_TO_PX,be as DEFAULT_CARD_GAP,Ae as DEFAULT_CARD_SHADOW,xe as DEFAULT_CORNER_STYLE,W as DEFAULT_HEADING_COMPRESSION,St as DEFAULT_HEADING_TYPOGRAPHY,we as DEFAULT_HOVER_EFFECT,z as DEFAULT_SHADOW_COLOR,at as DEFAULT_SIZES,s as DEFAULT_SURFACES,Ue as DEFAULT_SWITCH_SHOWN,J as DEFAULT_THEMES,Fe as DEFAULT_THEME_MODE,Q as DEFAULT_THEME_VALUE,We as GRADE_LABEL,Et as HEADING_CASES,De as HEADING_COMPRESSIONS,Ne as HEADING_MAX_PX_MAX,He as HEADING_MAX_PX_MIN,w as HEADING_WEIGHT_MAX,I as HEADING_WEIGHT_MIN,Ie as HOVER_EFFECTS,Ce as IDENTITY_CARD_GAP,Y as IDENTITY_CARD_SHADOW,Me as IDENTITY_HOVER_EFFECT,te as READABILITY_AA,ne as READABILITY_AA_LARGE,st as SCALE_OF_STEP,y as SITE_THEME_KEY,F as SIZE_STEPS,fe as TEXT_SIZE_MAX,he as TEXT_SIZE_MIN,D as THEME_DAY_END_HOUR,R as THEME_DAY_START_HOUR,Le as THEME_MODE_KEY,Z as THEME_STORAGE_KEY,rt as THEME_SURFACE_KEYS,$e as THEME_SWITCH_HIDE,Pe as THEME_SWITCH_KEY,le as TYPE_GROUPS,ct as TYPE_GROUP_LABELS,d as accentInk,et as bandPresetFor,tt as bandPresetIndex,Be as brandTheme,Ye as buildThemeBootScript,gt as cardGapAttr,dt as cardShadowAttr,_t as compressionMetrics,j as contrastRatio,G as cornerRadiusTokens,lt as cornerStyleTokens,nt as darkBandIndex,ue as darkPresetIndex,je as darkerAccents,Ke as gradeContrast,pt as headingCompressionAttr,Tt as headingTypographyFromRow,At as headingTypographyStyle,bt as headingTypographyToRow,mt as hoverEffectAttr,q as isDayHour,ye as normalizeCardGap,B as normalizeCardShadow,C as normalizeCornerRadius,pe as normalizeCornerStyle,K as normalizeHeadingCompression,M as normalizeHeadingTypography,X as normalizeHoverEffect,Re as normalizeShadowColor,de as normalizeSize,ge as normalizeSizes,H as normalizeTheme,l as normalizeThemeColors,Ge as resolveTheme,ie as resolvedButtonInk,$ as sectionBandTone,u as selectedThemeColors,xt as shadowColorTokens,Je as siteButtonPaint,ht as siteButtonRadiusPx,ft as siteCornerRadiusTokens,Oe as siteThemeMetadata,Ct as siteThemeOf,ve as surfaceTwoTone,Ze as themeAccentStyle,E as themeButtonColour,N as themeButtonInk,qe as themeButtonStyle,Ve as themeColorStyle,Qe as themePresetAccentVars,ot as themeSurfaceStyle,Xe as themeSwatchColors,it as typeScaleGroupOfClassName,ut as typeSizesStyle};
@@ -18,8 +18,16 @@ export type PageDocument = PageBundle & {
18
18
  version: string | null;
19
19
  kind?: string | null;
20
20
  live?: PageLiveState;
21
+ videoFrames?: VideoFrames;
21
22
  };
22
23
  export type PageLiveState = "live" | "changed" | "never";
24
+ export type VideoFrameState = "ready" | "dark" | "pending" | "unsupported" | "outside" | "failed";
25
+ export type VideoFrame = {
26
+ frame: string | null;
27
+ state: VideoFrameState;
28
+ stale: boolean;
29
+ };
30
+ export type VideoFrames = Readonly<Record<string, VideoFrame>>;
23
31
  export type SiteScope = {
24
32
  siteId?: string;
25
33
  };
@@ -54,6 +62,7 @@ export interface WebsitePages {
54
62
  save(id: string, doc: PageBundle, expect: SaveExpectation): Promise<{
55
63
  version: string | null;
56
64
  live?: PageLiveState;
65
+ videoFrames?: VideoFrames;
57
66
  }>;
58
67
  version?(id: string): Promise<string | null>;
59
68
  publish?(id: string, expect?: {
@@ -188,6 +197,13 @@ export interface WebsiteSocial {
188
197
  get(scope?: SiteScope): Promise<SocialLinkSettings>;
189
198
  update(patch: SocialLinkSettings, scope?: SiteScope): Promise<SocialLinkSettings>;
190
199
  }
200
+ export interface WebsitePreferences {
201
+ get(): Promise<EditorPreferences>;
202
+ update(patch: EditorPreferences): Promise<void>;
203
+ }
204
+ export type EditorPreferences = {
205
+ showHints?: boolean;
206
+ };
191
207
  export interface GeocodeResult {
192
208
  lat: number;
193
209
  lng: number;
@@ -210,6 +226,7 @@ export interface WebsiteBackend {
210
226
  blog?: WebsiteBlog;
211
227
  chat?: WebsiteChat;
212
228
  social?: WebsiteSocial;
229
+ preferences?: WebsitePreferences;
213
230
  theme?: WebsiteTheme;
214
231
  geocode?: WebsiteGeocoder;
215
232
  }
@@ -1 +1 @@
1
- import{jsx as e,jsxs as s}from"react/jsx-runtime";import x from"./BlockFrame.js";import g from"./Btn.js";import{media as u}from"../lib/media.js";import{CONTENT_SIZES as v,sizedImage as N}from"../../format/lib/sized-image.js";import w from"./SectionEyebrow.js";import{renderGold as t,renderHeadline as b,splitParagraphs as y}from"./goldPhrases.js";import{ON_MEDIA_INK_STYLE as M}from"../../format/lib/content/ink.js";import{scrim as z}from"../../format/lib/content/scrim.js";const n={headingMediumUpTo800:"max-view-wide:text-[length:min(var(--size-headingMedium,32px),var(--sf-heading-max,9999px))]",headingMedium:"text-[length:min(var(--size-headingMedium,44px),var(--sf-heading-max,9999px))]",body:"text-[length:var(--size-body,16px)]"};function E({eyebrow:i,title:a,body:d,ctaText:m,ctaHref:o,imageSrc:r,contained:l,overlay:c=60}){const p=Math.min(Math.max(c,0),100)/100;return e(x,{contained:l,className:"py-6",children:s("div",{className:"sf-card relative overflow-hidden border border-line bg-surface px-10 py-16 max-view-wide:px-6 max-view-wide:py-10",children:[r&&s("div",{className:"absolute inset-0","aria-hidden":!0,children:[e(_,{src:u(r)}),e("div",{className:"absolute inset-0",style:{background:z(p)}})]}),s("div",{className:"relative z-[1] flex max-w-[680px] flex-col gap-5",style:r?M:void 0,children:[i&&e(w,{text:i}),a&&e("h2",{className:`font-heading2 ${n.headingMedium} font-medium leading-[1.05] tracking-[-0.03em] ${n.headingMediumUpTo800}`,children:b(a,!1)}),d&&y(d).map((h,f)=>e("p",{className:`${n.body} leading-[1.6] opacity-85`,children:t(h)},f)),m&&e("div",{className:"mt-2 self-start",children:e(g,{href:o||"#",variant:"primary",children:t(m)})})]})]})})}function _({src:i}){const a=N(i);return e("img",{src:a.src,...a.srcSet?{srcSet:a.srcSet,sizes:v}:{},alt:"",className:"h-full w-full object-cover"})}export{E as default};
1
+ import{jsx as e,jsxs as s}from"react/jsx-runtime";import{PagePicture as x}from"../lib/first-screen.js";import u from"./BlockFrame.js";import g from"./Btn.js";import{media as v}from"../lib/media.js";import{CONTENT_SIZES as N,sizedImage as w}from"../../format/lib/sized-image.js";import b from"./SectionEyebrow.js";import{renderGold as m,renderHeadline as y,splitParagraphs as M}from"./goldPhrases.js";import{ON_MEDIA_INK_STYLE as z}from"../../format/lib/content/ink.js";import{scrim as E}from"../../format/lib/content/scrim.js";const n={headingMediumUpTo800:"max-view-wide:text-[length:min(var(--size-headingMedium,32px),var(--sf-heading-max,9999px))]",headingMedium:"text-[length:min(var(--size-headingMedium,44px),var(--sf-heading-max,9999px))]",body:"text-[length:var(--size-body,16px)]"};function _({eyebrow:i,title:a,body:d,ctaText:t,ctaHref:o,imageSrc:r,contained:l,overlay:c=60}){const p=Math.min(Math.max(c,0),100)/100;return e(u,{contained:l,className:"py-6",children:s("div",{className:"sf-card relative overflow-hidden border border-line bg-surface px-10 py-16 max-view-wide:px-6 max-view-wide:py-10",children:[r&&s("div",{className:"absolute inset-0","aria-hidden":!0,children:[e(I,{src:v(r)}),e("div",{className:"absolute inset-0",style:{background:E(p)}})]}),s("div",{className:"relative z-[1] flex max-w-[680px] flex-col gap-5",style:r?z:void 0,children:[i&&e(b,{text:i}),a&&e("h2",{className:`font-heading2 ${n.headingMedium} font-medium leading-[1.05] tracking-[-0.03em] ${n.headingMediumUpTo800}`,children:y(a,!1)}),d&&M(d).map((h,f)=>e("p",{className:`${n.body} leading-[1.6] opacity-85`,children:m(h)},f)),t&&e("div",{className:"mt-2 self-start",children:e(g,{href:o||"#",variant:"primary",children:m(t)})})]})]})})}function I({src:i}){const a=w(i);return e(x,{src:a.src,...a.srcSet?{srcSet:a.srcSet,sizes:N}:{},alt:"",className:"h-full w-full object-cover"})}export{_ as default};
@@ -0,0 +1,14 @@
1
+ import { type ReactNode } from "react";
2
+ import { type ViewBound } from "../../format/lib/content/cell-picture-sizes.js";
3
+ export type { ViewBound } from "../../format/lib/content/cell-picture-sizes.js";
4
+ export interface BoxCellValue {
5
+ hasWidth: boolean;
6
+ bound?: ViewBound;
7
+ }
8
+ export declare const BoxCellContext: import("react").Context<BoxCellValue>;
9
+ export declare function useBoxCellHasWidth(): boolean;
10
+ export declare function useCellPictureSizes(fallback: string): string;
11
+ export declare function useSizesWithinCell(own: string): string;
12
+ export declare function NoCellBound({ children }: {
13
+ children: ReactNode;
14
+ }): import("react").JSX.Element;
@@ -0,0 +1 @@
1
+ "use client";import{jsx as r,Fragment as i}from"react/jsx-runtime";import{createContext as u,useContext as n}from"react";import{cellPictureSizesOf as s,narrowerSizes as l}from"../../format/lib/content/cell-picture-sizes.js";const c={hasWidth:!1},o=u(c);function h(){return n(o).hasWidth}function f(t){const{bound:e}=n(o);return e&&s(e)||t}function C(t){const{bound:e}=n(o);return l(t,e&&s(e))}function m({children:t}){const e=n(o);return e.bound?r(o.Provider,{value:{hasWidth:e.hasWidth},children:t}):r(i,{children:t})}export{o as BoxCellContext,m as NoCellBound,h as useBoxCellHasWidth,f as useCellPictureSizes,C as useSizesWithinCell};
@@ -77,10 +77,11 @@ interface FlexProps {
77
77
  };
78
78
  sharedRows?: boolean;
79
79
  boxId?: string;
80
+ slotCount?: number;
80
81
  mirrorCards?: unknown;
81
82
  content: SlotComponent;
82
83
  rowTitle?: SlotComponent;
83
84
  startsOpen?: unknown;
84
85
  }
85
- export default function Flex({ direction: storedDirection, label, tabShape, gap, gapPhone, gapTablet, justify, align, wrap, share: storedShare, sharePhone, shareTablet, wrapPhone, orderPhone: storedOrderPhone, phoneRow, columns, columnsTablet, separator, stackBelow, blockSpacing, bgImage, bgImagePhone, pictureHover, darken, darkenStyle, darkenTablet, darkenPhone, darkenStyleTablet, darkenStylePhone, placement, padV2, border, borderTablet, borderPhone, pad, contained, fillHeight, shadow, shadowTablet, shadowPhone, justifyTablet, justifyPhone, alignTablet, alignPhone, wrapTablet, blockSpacingTablet, blockSpacingPhone, loop, scrollDirection, loopSeconds, loopDelay, editing, fillColor, fillColorTablet, fillColorPhone, swatch, line, upcoming, link, boxShape, boxShapePhone, boxShapeTablet, jumpHighlight, anchor, sharedSides, sharedRows, boxId, mirrorCards, content: Content, rowTitle: RowTitle, startsOpen, }: FlexProps): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | import("react").JSX.Element | null | undefined;
86
+ export default function Flex({ direction: storedDirection, label, tabShape, gap, gapPhone, gapTablet, justify, align, wrap, share: storedShare, sharePhone, shareTablet, wrapPhone, orderPhone: storedOrderPhone, phoneRow, columns, columnsTablet, separator, stackBelow, blockSpacing, bgImage, bgImagePhone, pictureHover, darken, darkenStyle, darkenTablet, darkenPhone, darkenStyleTablet, darkenStylePhone, placement, padV2, border, borderTablet, borderPhone, pad, contained, fillHeight, shadow, shadowTablet, shadowPhone, justifyTablet, justifyPhone, alignTablet, alignPhone, wrapTablet, blockSpacingTablet, blockSpacingPhone, loop, scrollDirection, loopSeconds, loopDelay, editing, fillColor, fillColorTablet, fillColorPhone, swatch, line, upcoming, link, boxShape, boxShapePhone, boxShapeTablet, jumpHighlight, anchor, sharedSides, sharedRows, boxId, slotCount, mirrorCards, content: Content, rowTitle: RowTitle, startsOpen, }: FlexProps): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | import("react").JSX.Element | null | undefined;
86
87
  export {};
@@ -1 +1 @@
1
- import{Fragment as so,jsx as e,jsxs as vo}from"react/jsx-runtime";import{useId as Zs}from"react";import ot from"./BoxTabs.js";import{BoxTabPaneContext as Ao,useBoxPaneKind as et,useIsTabPane as st}from"./BoxTabPaneContext.js";import tt from"./BoxAccordionRow.js";import{boxPhoneCell as nt,boxPhoneOrder as rt}from"../../format/lib/content/box-phone-place.js";import{CellFillContext as Fe,InBoxContext as Te,useCellOfStretchedRow as lt,useFillsCell as it}from"./InBoxContext.js";import ct,{InsideSiteColumn as De,useInsideSiteGutter as at,useSectionRoot as dt}from"./SiteGutterFrame.js";import{BoxSurfaceProvider as ut}from"./BoxSurfaceContext.js";import mt from"./PictureWash.js";import{BoxCellWidthContext as ft}from"./BoxCellWidthContext.js";import{useInSiteHeader as Ct}from"./PhoneMenuTools.js";import{useCardRow as ht}from"./CardRowContext.js";import{framesItsCards as bt}from"../../format/lib/content/card-place.js";import{HandedMirrorContext as xt,MirrorContext as pt,RowHandContext as Ie,boxPlace as wt,useHandedMirrorAbove as St,useHandedRows as $t,useMirroredCopy as Pt,useUnderCardBox as Rt}from"./MirrorContext.js";import{boxChildrenHand as _t,isMirroredCopy as vt,mirrorCardsActs as ge,mirrorCardsOf as At,mirroredBoxClass as Lt,MIRROR_ROW_CLASS as yt,ownsCard as kt}from"../../format/lib/content/mirror-cards.js";import{FRAME_BASE as Lo,FRAME_GUTTER as yo}from"./BlockFrame.js";import{containerGapProps as Ot}from"../../format/lib/content/container-gap.js";import{boxLayoutClasses as Nt,boxAlignViewClasses as Bt,boxBlockSpacingClass as Et,boxBlockSpacingViewClasses as Ft,boxJustifyViewClasses as Tt,boxWrapTabletClass as Dt,boxFitContentClass as It,boxRowColumnsClass as gt,boxRowTabletColumnsClass as Mt,boxRowTabletShareClass as Vt,boxPhoneCellsShareLine as Ht,boxPhoneRowClasses as U,boxPhoneRowFits as Wt,boxShareClasses as I,boxShareVars as Gt,boxWrapClass as Xt,BOX_GAP_ONLY_CLASS as jt}from"../../format/lib/content/box-layout.js";import{boxSeparatorClasses as Ut,boxSeparatorSeamClass as Kt,boxSeparatorStyle as Jt,isStripBox as zt}from"../../format/lib/content/box-separator.js";import{DEFAULT_LOOP_DELAY as Yt,DEFAULT_LOOP_DIRECTION as qt,DEFAULT_LOOP_SECONDS as Qt,isVerticalLoop as Zt}from"../../format/lib/animation/index.js";import{LoopTrack as on}from"../lib/animation/LoopTrack.js";import{BOX_CARD_PAD as S,BOX_OWNS_SIDES_CLASS as en,boxDarkenStyle as sn,boxFillOf as tn,boxFillViews as nn,boxPlacementClasses as rn,boxSwatchFill as ln,boxWashViews as cn,CARD_SHADOW_CLASS as an,isBackgroundBox as Me}from"../../format/lib/content/box-background.js";import{boxShadowAttrs as dn,boxShadowOnAnyView as un,boxShadowViewAttrs as mn}from"../../format/lib/content/box-shadow.js";import{boxRunsEdgeToEdge as fn,drawsSiteGutter as Cn}from"../../format/lib/content/site-gutter.js";import{boxShapeClass as hn,boxShapeClasses as bn}from"../../format/lib/content/box-shape.js";import{BOX_JUMP_ATTR as xn,BOX_LINK_ATTR as Ve,BOX_LINK_CLASS as He,BOX_LINKED_CLASS as pn,boxJumpBlocksClass as wn,boxJumpCss as Sn,boxJumpSlug as $n,boxLinkOf as Pn}from"../../format/lib/content/box-link.js";import{SiteLink as Rn}from"../lib/site-runtime.js";import{sectionBorderStyle as We}from"../../format/lib/content/borders.js";import{finiteNumber as $}from"../../format/lib/finite-number.js";import{padDefaultIn as P,sectionPadAttrs as _n}from"../lib/content/section-padding.js";import{SECTION_FILL_CLASS as to}from"../../format/lib/content/section-min-height.js";import{ON_MEDIA_INK_STYLE as vn}from"../../format/lib/content/ink.js";import{sizedBackground as ko}from"../../format/lib/sized-image.js";import{PHOTO_HOST_ATTR as An,resolveImageTreatment as Ln}from"../../format/lib/content/image-treatment.js";import{BoxRail as yn,BoxRailStop as kn,RAIL_STOPS_CLASS as On,useTimelineRail as Nn}from"./TimelineRail.js";import{SHARED_PLAIN_ATTR as Bn,sharedColumnsClasses as En,sharedColumnsCss as Fn,sharedRowsClasses as Tn,sharedRowsCss as Dn}from"../lib/content/box-shared-columns.js";import In from"./PhotoHoverSheet.js";import{stackGutterClass as gn,stackLineCss as Mn,stackOuterClass as Vn,stackRowClass as Hn,storedStackLine as Wn}from"../lib/content/box-stack-line.js";const Oo={"--sf-site-gutter":"0px"},Gn={overflowX:"clip",overflowY:"visible"},Xn={stretchedRow:!1,fillingColumn:!1,columnsRow:!1},jn={desktop:!1,phone:!1},Ge="bg-cover bg-center bg-[image:var(--sf-box-bg)] max-view-tablet:bg-[image:var(--sf-box-bg-p)]",No=a=>a==null||a==="",Bo=a=>!No(a)&&Number(a)===0;function Un({children:a}){return e(so,{children:a(Zs())})}function Kn({direction:a,label:Xe,tabShape:je,gap:Eo,gapPhone:Ue,gapTablet:no,justify:g,align:R,wrap:K,share:Ke,sharePhone:J,shareTablet:M,wrapPhone:Je,orderPhone:ze,phoneRow:V,columns:_,columnsTablet:O,separator:f,stackBelow:Ye,blockSpacing:Fo,bgImage:v,bgImagePhone:To,pictureHover:qe,darken:Do,darkenStyle:Io,darkenTablet:Qe,darkenPhone:Ze,darkenStyleTablet:os,darkenStylePhone:es,placement:ss,padV2:go=!1,border:Mo,borderTablet:Vo,borderPhone:Ho,pad:t={},contained:ro=!0,fillHeight:A=!1,shadow:lo,shadowTablet:Wo,shadowPhone:Go,justifyTablet:ts,justifyPhone:ns,alignTablet:rs,alignPhone:ls,wrapTablet:is,blockSpacingTablet:cs,blockSpacingPhone:as,loop:h,scrollDirection:io=qt,loopSeconds:ds=Qt,loopDelay:us=Yt,editing:N=!1,fillColor:Xo,fillColorTablet:ms,fillColorPhone:fs,swatch:Cs,line:L,upcoming:hs,link:bs,boxShape:jo,boxShapePhone:xs,boxShapeTablet:ps,jumpHighlight:ws,anchor:Ss,sharedSides:d=jn,sharedRows:$s=!1,boxId:B,mirrorCards:Uo,content:l,rowTitle:co,startsOpen:Ps}){const r=ht(),Rs=St(),Ko=Rt()&&!(Rs&&r!==null),b=$t(),z=kt({inCopy:r!==null,nestedCopy:r?.nested===!0,underBox:Ko}),Jo=r===null&&!Ko&&b?.ids&&B?b.ids.indexOf(B):-1,Y=Jo>=0&&b&&B?wt(b,B,Jo):-1,C=Y>=0?b?.hand??null:z&&b?.copies===!0?b.hand:null,o=C?.row?"row":a,u=C?.row?C.row.share:Ke,_s=C?.row?C.row.phoneReverse?[...l.blockIds??[]].reverse():void 0:ze,ao=$s&&!C?.row,E=N?"":Pn(bs),x=A?"":bn(jo,xs,ps),vs=!A&&hn(jo)!=="",y=$n(ws,Ss),zo=ln({swatch:Cs},r?.row),q=zo??tn(Xo),F=zo?{className:"",style:{}}:nn(Xo,ms,fs),Yo=q||F.className?{...q?{backgroundColor:q}:{},...F.style}:void 0,qo=Nn(),Q=L===!0&&o!=="tabs"&&o!=="accordion",n=Me(v),Z=Ct(),As=dt(),Ls=st(),Qo=et(),c=o==="accordion",uo=it(),ys=lt(),T=zt(o,f),i=h==="scroll"&&o!=="tabs"&&!c,ks=Pt(),oo=z||Y>=0&&C!==null,Zo=C?C.mirror:Uo,Os=Y>=0?Y:r?.index,mo=z&&bt(r?.ownerType),oe=ge({direction:o,separator:f,loop:h,line:L,bgImage:v,columns:_,columnsTablet:O,share:u,wrap:K},oo,d.desktop)&&vt(Zo,Os),ee=n||oo?"":Lt(ks,o,i?void 0:g,R),Ns=ge({direction:o,separator:f,loop:h,line:L,bgImage:v,columns:_,columnsTablet:O,share:u,wrap:K},oo,d.desktop)&&At(Zo)!==null,D=gt({direction:o,separator:f,loop:h,line:L,columns:_}),p=Mt({direction:o,separator:f,loop:h,line:L,columnsTablet:O}),H=Vt({direction:o,separator:f,loop:h,line:L,columns:_,columnsTablet:O,share:u,shareTablet:M}),m=o==="row"&&!n&&!T&&!i&&!Q&&p===""&&H===""?Wn(Ye):void 0,Bs=at(),eo=En(d,l.blockCount??0,m),Es=(eo&&(!r||r.index===0)?Fn(d,l.blockCount??0,m):"")+(ao&&(!r||r.index===0)?Dn(ao,l.blockCount??0):""),se=Tn(ao,l.blockCount??0),te=p!==""?Number(O)>=2:H===""||I(M)!=="",fo=p!==""||H!=="",Fs=fo&&!(p!==""&&Number(O)<2),ne=o==="row"&&!T&&!i&&L!==!0,Co=ne&&!d.phone&&!d.desktop?nt(rt(_s,l.blockIds??[]),{tabletKeepsRow:Fs,editing:N}):void 0,re=Co!==void 0&&!N,Ts=D!==""?Number(_)>=2:I(u)!=="",le=!n&&!c&&!Ns&&!d.desktop&&!d.phone,ie=le&&!i?Tt(g,ts,ns):"",Ds=le&&o==="row"?Bt(R,rs,ls):"",Is=!i&&!c&&D===""&&p===""&&!d.desktop?Dt(K,is):"",ce=[c?"":I(u),o==="row"?It(u):"",D,p,H,Et(c?"gap":Fo),Ut(o,f),c?"border-t border-line":"",ie,Ds,Is,c?"":Ft(Fo,cs,as)].filter(Boolean).join(" "),gs=ce?` ${ce}`:"",ae=["flex",o==="row"?T||i?"flex-row":`flex-row ${U(V,J,Je)}`:"flex-col",Xt(i||c?!1:K),n?rn(ss??"center",o):Nt(i||c?void 0:g,c?void 0:R)+(ee?` ${ee}`:"")].join(" ")+gs,W=A||n||x||uo?` ${to}`:"",ho=vs?` ${x}`:x?`${W} ${x}`:W,de=ys&&o==="column"&&!n&&!i&&I(u)===""&&(typeof g=="string"&&g!=="start"||ie!==""),ue=W||(de?` ${to}`:""),bo=E?` ${pn}`:"",xo=n||Z||go?"":" py-6",Ms=m===void 0?"":` ${Hn(m)}`,me=m===void 0?"":` ${gn(m)}`,po=m===void 0?"":` ${Vn(m)}`,Vs=`${Lo}${xo} ${yo}${ho}${bo}${me}${po}`,Hs=Z?`${ho}${bo}${po}`.trim():`w-full${xo}${ho}${bo}${po}`,G=Ot("Flex",Eo,o==="row"?"inline":"block",Ue,T||i?void 0:no),fe=Gt(u,M,o==="row"?l.blockCount??0:0),Ce=T?{...G.style,...Jt(o,f)}:G.style,Ws=fe?{...Ce,...fe}:Ce,he=(s="")=>e(l,{className:`${ae}${oe?` ${yt}`:""}${G.className}${ue}${Ms}${s?` ${s}`:""}${Q?` ${On}`:""}${y?` ${wn(y)}`:""}${eo}${se}`,style:Ws,minEmptyHeight:120,...Co?{cell:Co}:null}),be=Zt(io)?"":Kt(o,f),xe=i?e(on,{direction:io,seconds:ds,delay:us,editing:N,copy:s=>he(s&&be?`${s} ${be}`:s)}):he(),wo=o==="tabs"?e(ot,{className:`${ae}${G.className}${uo&&!A&&!n&&!x?"":W}`,style:G.style,shape:je,children:xe}):xe,So=c?e(Ao.Provider,{value:"accordion",children:wo}):Qo?e(Ao.Provider,{value:!1,children:wo}):wo,pe=o==="row"&&!n&&(R===void 0||R==="stretch"),Gs={stretchedRow:pe,fillingColumn:o==="column"&&(uo||de),columnsRow:D!==""||p!==""||eo!==""||se!==""||o==="row"&&(Array.isArray(u)||Array.isArray(M))||re,...re?{phoneCells:!0}:null,...pe&&ne&&(l.blockCount??0)>=2&&Ts?{picturesFillRow:!0}:null,...fo?{fillFrom:te?"tablet":"desktop"}:null,...Ht(V,J)&&(!fo||te)?{phoneRowFills:!0}:null,...B?{id:B}:null},we=r===null?_t({direction:o,loop:h,bgImage:v,columns:_,mirrorCards:Uo},!1):null,Se=we?e(Ie.Provider,{value:{hand:we,ids:l.blockIds??[],boxes:[]},children:So}):b?e(Ie.Provider,{value:null,children:So}):So,$e=e(Te.Provider,{value:Gs,children:e(Fe.Provider,{value:!1,children:oo?e(pt.Provider,{value:oe,children:e(xt.Provider,{value:!z,children:Se})}):Se})}),Xs=co?.blockCount??0,Pe=Qo==="accordion"&&!!co&&(N||Xs>0)?e(tt,{startsOpen:Ps===!0,editing:N,title:e(Te.Provider,{value:Xn,children:e(Fe.Provider,{value:!1,children:e(Ao.Provider,{value:!1,children:e(co,{className:`min-w-0 flex-1 ${jt}`,minEmptyHeight:24})})})}),children:$e}):$e,$o=Q?e(yn,{row:o==="row",stops:l.blockCount??0,children:Pe}):Pe,js=Xe?.trim()||(Ls?"":void 0),Us={values:t,frame:xo?24:0},Ks=s=>qo?e(kn,{on:qo,future:hs===!0,children:s}):s,Js=s=>E.startsWith("/")?e(Rn,{href:E,className:He,"aria-labelledby":s,[Ve]:""}):e("a",{href:E,className:He,"aria-labelledby":s,[Ve]:""}),Re=(y?Sn(y):"")+Es+(m===void 0||r&&r.index!==0?"":Mn(m)),_e=Re?e("style",{dangerouslySetInnerHTML:{__html:Re}}):null,X=fn({loop:h,direction:o,scrollDirection:io,bgImage:v}),zs=d.desktop&&eo!==""&&!q&&!F.className&&!We(Mo,Ho,Vo)&&!un(lo,Wo,Go)&&!E&&!x&&!A&&!y&&!Cn(ro&&!X,Bs)&&Bo(Eo)&&(No(no)||Bo(no))&&go&&Object.values(t).every(s=>No(s)||Bo(s)),Ys=s=>({...zs?{[Bn]:""}:null,...n?null:{...dn(lo),...mn(lo,Wo,Go)},...y?{[xn]:y}:null,...s?{id:s}:null}),ve=D!==""?Number(_):0,qs=U(V,J)===U(void 0),Qs=(o==="column"||o==="row"&&!T&&!i&&(ve===1&&qs||ve===0&&l.blockCount===1))&&!n&&!Q&&!Z,Ae=n&&As&&!Z,Le=(s,w)=>Ks(e(ct,{contained:ro&&!X,style:X?Oo:void 0,framedClass:Vs,fillClass:Hs,columnClass:`${Lo} ${yo}${ue}${me}`,tabLabel:js,pad:n?void 0:Us,border:We(Mo,Ho,Vo),outerAttrs:Ys(w),box:!0,edge:Qs,outerStyle:n?void 0:Yo,outerClass:n?void 0:F.className||void 0,bleed:Ae,children:_e||w?vo(so,{children:[_e,w?Js(w):null,X?e(De,{children:s}):s]}):X?e(De,{children:s}):s})),ye=s=>E?e(Un,{children:w=>Le(s,w)}):Le(s);if(!n){const s=R===void 0||R==="stretch",w=(I(u)!==""||D!==""||p!=="")&&!Wt(V,J)&&!(H!==""&&I(M)==="")&&(s||U(V)!==U(void 0));return ye((o==="row"?w:o==="column"&&s)?e(ft.Provider,{value:!0,children:$o}):$o)}const j=sn(Do,Io),Po=cn({darken:Do,darkenStyle:Io,darkenTablet:Qe,darkenStyleTablet:os,darkenPhone:Ze,darkenStylePhone:es}),ke=[mo?"rounded-[inherit]":"",Po.className].filter(Boolean).join(" "),Ro=Me(To),Oe=Ro?{"--sf-box-bg":ko(v??""),"--sf-box-bg-p":ko(To??"")}:{backgroundImage:ko(v??""),backgroundSize:"cover",backgroundPosition:"center"},Ne=Ln(void 0,void 0,qe),k=Ne.className?Ne:null,_o=_n({...t,top:$(t.top)??P(S.desktop,t.unit,"desktop"),bottom:$(t.bottom)??P(S.desktop,t.unit,"desktop"),topPhone:$(t.topPhone)??P(S.phone,t.unitPhone,"mobile"),bottomPhone:$(t.bottomPhone)??P(S.phone,t.unitPhone,"mobile"),left:$(t.left)??P(S.side,t.unit,"desktop"),right:$(t.right)??P(S.side,t.unit,"desktop"),leftPhone:$(t.leftPhone)??P(S.sidePhone,t.unitPhone,"mobile"),rightPhone:$(t.rightPhone)??P(S.sidePhone,t.unitPhone,"mobile")}),Be=e("div",{className:`relative z-[1] ${en} ${_o?.className??""}${A||x?` ${to}`:""}`.trimEnd(),style:j?{..._o?.style,...Oo,...vn}:{..._o?.style,...Oo},children:$o}),Ee=Ae&&ro?e("div",{className:`${Lo} ${yo}${A||x?` ${to}`:""}`,children:Be}):Be;return ye(e(so,{children:vo("div",{className:`relative isolate overflow-hidden ${an}${W}${Ro&&!k?` ${Ge}`:""}${F.className?` ${F.className}`:""}`,style:{...mo?Gn:{},...Yo,...k?{}:Oe},...k?{[An]:""}:{},children:[k&&vo(so,{children:[e(In,{sheet:k.sheet}),e("div",{"aria-hidden":!0,className:`absolute inset-0${mo?" rounded-[inherit]":""}${Ro?` ${Ge}`:""} ${k.className}`,style:{...Oe,...k.style??{}}})]}),e(mt,{wash:j&&Po.className?{...j,...Po.style}:j,...ke?{className:ke}:{}}),j?e(ut,{children:Ee}):Ee]})}))}export{Kn as default};
1
+ import{Fragment as to,jsx as e,jsxs as Lo}from"react/jsx-runtime";import{useContext as rt,useId as lt}from"react";import it from"./BoxTabs.js";import{BoxTabPaneContext as yo,useBoxPaneKind as ct,useIsTabPane as at}from"./BoxTabPaneContext.js";import dt from"./BoxAccordionRow.js";import{boxPhoneCell as ut,boxPhoneOrder as mt}from"../../format/lib/content/box-phone-place.js";import{CellFillContext as Ve,InBoxContext as He,useCellOfStretchedRow as ft,useFillsCell as Ct}from"./InBoxContext.js";import ht,{InsideSiteColumn as We,useInsideSiteGutter as bt,useSectionRoot as xt}from"./SiteGutterFrame.js";import{BoxSurfaceProvider as pt}from"./BoxSurfaceContext.js";import wt from"./PictureWash.js";import{BoxCellContext as Ge,NoCellBound as St}from"./BoxCellContext.js";import{boxCellFractions as $t}from"../lib/content/box-cell-bound.js";import{boundOf as Pt}from"../../format/lib/content/cell-picture-sizes.js";import{useInSiteHeader as Rt}from"./PhoneMenuTools.js";import{useCardRow as _t}from"./CardRowContext.js";import{framesItsCards as vt}from"../../format/lib/content/card-place.js";import{HandedMirrorContext as At,MirrorContext as Lt,RowHandContext as Xe,boxPlace as yt,useHandedMirrorAbove as kt,useHandedRows as Ot,useMirroredCopy as Nt,useUnderCardBox as Bt}from"./MirrorContext.js";import{boxChildrenHand as Et,isMirroredCopy as Ft,mirrorCardsActs as Ue,mirrorCardsOf as Tt,mirroredBoxClass as Dt,MIRROR_ROW_CLASS as It,ownsCard as gt}from"../../format/lib/content/mirror-cards.js";import{FRAME_BASE as ko,FRAME_GUTTER as Oo}from"./BlockFrame.js";import{containerGapProps as Mt}from"../../format/lib/content/container-gap.js";import{boxLayoutClasses as Vt,boxAlignViewClasses as Ht,boxBlockSpacingClass as Wt,boxBlockSpacingViewClasses as Gt,boxJustifyViewClasses as Xt,boxWrapTabletClass as Ut,boxFitContentClass as jt,boxRowColumnsClass as Kt,boxRowTabletColumnsClass as Jt,boxRowTabletShareClass as zt,boxPhoneCellsShareLine as Yt,boxPhoneRowClasses as K,boxPhoneRowFits as qt,boxShareClasses as M,boxShareVars as Qt,boxWrapClass as Zt,BOX_GAP_ONLY_CLASS as on}from"../../format/lib/content/box-layout.js";import{boxSeparatorClasses as en,boxSeparatorSeamClass as sn,boxSeparatorStyle as tn,isStripBox as nn}from"../../format/lib/content/box-separator.js";import{DEFAULT_LOOP_DELAY as rn,DEFAULT_LOOP_DIRECTION as ln,DEFAULT_LOOP_SECONDS as cn,isVerticalLoop as an}from"../../format/lib/animation/index.js";import{LoopTrack as dn}from"../lib/animation/LoopTrack.js";import{BOX_CARD_PAD as P,BOX_OWNS_SIDES_CLASS as un,boxDarkenStyle as mn,boxFillOf as fn,boxFillViews as Cn,boxPlacementClasses as hn,boxSwatchFill as bn,boxWashViews as xn,CARD_SHADOW_CLASS as pn,isBackgroundBox as je}from"../../format/lib/content/box-background.js";import{boxShadowAttrs as wn,boxShadowOnAnyView as Sn,boxShadowViewAttrs as $n}from"../../format/lib/content/box-shadow.js";import{boxRunsEdgeToEdge as Pn,drawsSiteGutter as Rn}from"../../format/lib/content/site-gutter.js";import{boxShapeClass as _n,boxShapeClasses as vn}from"../../format/lib/content/box-shape.js";import{BOX_JUMP_ATTR as An,BOX_LINK_ATTR as Ke,BOX_LINK_CLASS as Je,BOX_LINKED_CLASS as Ln,boxJumpBlocksClass as yn,boxJumpCss as kn,boxJumpSlug as On,boxLinkOf as Nn}from"../../format/lib/content/box-link.js";import{SiteLink as Bn}from"../lib/site-runtime.js";import{sectionBorderStyle as ze}from"../../format/lib/content/borders.js";import{finiteNumber as R}from"../../format/lib/finite-number.js";import{padDefaultIn as _,sectionPadAttrs as En}from"../lib/content/section-padding.js";import{SECTION_FILL_CLASS as no}from"../../format/lib/content/section-min-height.js";import{ON_MEDIA_INK_STYLE as Fn}from"../../format/lib/content/ink.js";import{sizedBackground as No}from"../../format/lib/sized-image.js";import{PHOTO_HOST_ATTR as Tn,resolveImageTreatment as Dn}from"../../format/lib/content/image-treatment.js";import{BoxRail as In,BoxRailStop as gn,RAIL_STOPS_CLASS as Mn,useTimelineRail as Vn}from"./TimelineRail.js";import{SHARED_PLAIN_ATTR as Hn,sharedColumnsClasses as Wn,sharedColumnsCss as Gn,sharedRowsClasses as Xn,sharedRowsCss as Un}from"../lib/content/box-shared-columns.js";import jn from"./PhotoHoverSheet.js";import{stackGutterClass as Kn,stackLineCss as Jn,stackOuterClass as zn,stackRowClass as Yn,storedStackLine as qn}from"../lib/content/box-stack-line.js";const Bo={"--sf-site-gutter":"0px"},Qn={overflowX:"clip",overflowY:"visible"},Zn={stretchedRow:!1,fillingColumn:!1,columnsRow:!1},or={desktop:!1,phone:!1},Ye="bg-cover bg-center bg-[image:var(--sf-box-bg)] max-view-tablet:bg-[image:var(--sf-box-bg-p)]",Eo=u=>u==null||u==="",Fo=u=>!Eo(u)&&Number(u)===0;function er({children:u}){return e(to,{children:u(lt())})}function sr({direction:u,label:qe,tabShape:Qe,gap:To,gapPhone:Ze,gapTablet:ro,justify:V,align:v,wrap:J,share:os,sharePhone:H,shareTablet:N,wrapPhone:es,orderPhone:ss,phoneRow:B,columns:b,columnsTablet:A,separator:m,stackBelow:Do,blockSpacing:Io,bgImage:L,bgImagePhone:go,pictureHover:ts,darken:Mo,darkenStyle:Vo,darkenTablet:ns,darkenPhone:rs,darkenStyleTablet:ls,darkenStylePhone:is,placement:cs,padV2:Ho=!1,border:Wo,borderTablet:Go,borderPhone:Xo,pad:t={},contained:lo=!0,fillHeight:y=!1,shadow:io,shadowTablet:Uo,shadowPhone:jo,justifyTablet:Ko,justifyPhone:as,alignTablet:ds,alignPhone:us,wrapTablet:Jo,blockSpacingTablet:ms,blockSpacingPhone:fs,loop:C,scrollDirection:co=ln,loopSeconds:Cs=cn,loopDelay:hs=rn,editing:E=!1,fillColor:zo,fillColorTablet:bs,fillColorPhone:xs,swatch:ps,line:x,upcoming:ws,link:Ss,boxShape:Yo,boxShapePhone:$s,boxShapeTablet:Ps,jumpHighlight:Rs,anchor:_s,sharedSides:l=or,sharedRows:vs=!1,boxId:F,slotCount:As,mirrorCards:qo,content:i,rowTitle:ao,startsOpen:Ls}){const r=_t(),Qo=rt(Ge),ys=kt(),Zo=Bt()&&!(ys&&r!==null),p=Ot(),z=gt({inCopy:r!==null,nestedCopy:r?.nested===!0,underBox:Zo}),oe=r===null&&!Zo&&p?.ids&&F?p.ids.indexOf(F):-1,Y=oe>=0&&p&&F?yt(p,F,oe):-1,h=Y>=0?p?.hand??null:z&&p?.copies===!0?p.hand:null,o=h?.row?"row":u,a=h?.row?h.row.share:os,ks=h?.row?h.row.phoneReverse?[...i.blockIds??[]].reverse():void 0:ss,q=vs&&!h?.row,T=E?"":Nn(Ss),w=y?"":vn(Yo,$s,Ps),Os=!y&&_n(Yo)!=="",k=On(Rs,_s),ee=bn({swatch:ps},r?.row),Q=ee??fn(zo),D=ee?{className:"",style:{}}:Cn(zo,bs,xs),se=Q||D.className?{...Q?{backgroundColor:Q}:{},...D.style}:void 0,te=Vn(),Z=x===!0&&o!=="tabs"&&o!=="accordion",n=je(L),oo=Rt(),Ns=xt(),Bs=at(),ne=ct(),d=o==="accordion",uo=Ct(),Es=ft(),I=nn(o,m),c=C==="scroll"&&o!=="tabs"&&!d,Fs=Nt(),eo=z||Y>=0&&h!==null,re=h?h.mirror:qo,Ts=Y>=0?Y:r?.index,mo=z&&vt(r?.ownerType),le=Ue({direction:o,separator:m,loop:C,line:x,bgImage:L,columns:b,columnsTablet:A,share:a,wrap:J},eo,l.desktop)&&Ft(re,Ts),Ds=Ue({direction:o,separator:m,loop:C,line:x,bgImage:L,columns:b,columnsTablet:A,share:a,wrap:J},eo,l.desktop)&&Tt(re)!==null,g=Kt({direction:o,separator:m,loop:C,line:x,columns:b}),S=Jt({direction:o,separator:m,loop:C,line:x,columnsTablet:A}),W=zt({direction:o,separator:m,loop:C,line:x,columns:b,columnsTablet:A,share:a,shareTablet:N}),f=o==="row"&&!n&&!I&&!c&&!Z&&S===""&&W===""?qn(Do):void 0,Is=bt(),so=Wn(l,i.blockCount??0,f),gs=(so&&(!r||r.index===0)?Gn(l,i.blockCount??0,f):"")+(q&&(!r||r.index===0)?Un(q,i.blockCount??0):""),ie=Xn(q,i.blockCount??0),ce=S!==""?Number(A)>=2:W===""||M(N)!=="",fo=S!==""||W!=="",Ms=fo&&!(S!==""&&Number(A)<2),ae=o==="row"&&!I&&!c&&x!==!0,Co=ae&&!l.phone&&!l.desktop?ut(mt(ks,i.blockIds??[]),{tabletKeepsRow:Ms,editing:E}):void 0,de=Co!==void 0&&!E,Vs=g!==""?Number(b)>=2:M(a)!=="",ue=!n&&!d&&!Ds&&!l.desktop&&!l.phone,ho=ue&&!c?Xt(V,Ko,as):"",me=n||eo?"":Dt(Fs,o,c?void 0:V,v,ho?Ko:void 0),Hs=ue&&o==="row"?Ht(v,ds,us):"",Ws=!c&&!d&&g===""&&S===""&&!l.desktop?Ut(J,Jo):"",fe=[d?"":M(a),o==="row"?jt(a):"",g,S,W,Wt(d?"gap":Io),en(o,m),d?"border-t border-line":"",ho,Hs,Ws,d?"":Gt(Io,ms,fs)].filter(Boolean).join(" "),Gs=fe?` ${fe}`:"",Ce=["flex",o==="row"?I||c?"flex-row":`flex-row ${K(B,H,es,Jo)}`:"flex-col",Zt(c||d?!1:J),n?hn(cs??"center",o):Vt(c||d?void 0:V,d?void 0:v)+(me?` ${me}`:"")].join(" ")+Gs,G=y||n||w||uo?` ${no}`:"",bo=Os?` ${w}`:w?`${G} ${w}`:G,he=Es&&o==="column"&&!n&&!c&&M(a)===""&&(typeof V=="string"&&V!=="start"||ho!==""),be=G||(he?` ${no}`:""),xo=T?` ${Ln}`:"",po=n||oo||Ho?"":" py-6",Xs=f===void 0?"":` ${Yn(f)}`,xe=f===void 0?"":` ${Kn(f)}`,wo=f===void 0?"":` ${zn(f)}`,Us=`${ko}${po} ${Oo}${bo}${xo}${xe}${wo}`,js=oo?`${bo}${xo}${wo}`.trim():`w-full${po}${bo}${xo}${wo}`,X=Mt("Flex",To,o==="row"?"inline":"block",Ze,I||c?void 0:ro),pe=Qt(a,N,o==="row"?i.blockCount??0:0),we=I?{...X.style,...tn(o,m)}:X.style,Ks=pe?{...we,...pe}:we,Se=(s="")=>e(i,{className:`${Ce}${le?` ${It}`:""}${X.className}${be}${Xs}${s?` ${s}`:""}${Z?` ${Mn}`:""}${k?` ${yn(k)}`:""}${so}${ie}`,style:Ks,minEmptyHeight:120,...Co?{cell:Co}:null}),$e=an(co)?"":sn(o,m),Pe=c?e(dn,{direction:co,seconds:Cs,delay:hs,editing:E,copy:s=>Se(s&&$e?`${s} ${$e}`:s)}):Se(),So=o==="tabs"?e(it,{className:`${Ce}${X.className}${uo&&!y&&!n&&!w?"":G}`,style:X.style,shape:Qe,children:Pe}):Pe,$o=d?e(yo.Provider,{value:"accordion",children:So}):ne?e(yo.Provider,{value:!1,children:So}):So,Re=o==="row"&&!n&&(v===void 0||v==="stretch"),Js={stretchedRow:Re,fillingColumn:o==="column"&&(uo||he),columnsRow:g!==""||S!==""||so!==""||ie!==""||o==="row"&&(Array.isArray(a)||Array.isArray(N))||de,...de?{phoneCells:!0}:null,...Re&&ae&&(i.blockCount??0)>=2&&Vs?{picturesFillRow:!0}:null,...fo?{fillFrom:ce?"tablet":"desktop"}:null,...Yt(B,H)&&(!fo||ce)?{phoneRowFills:!0}:null,...F?{id:F}:null},_e=r===null?Et({direction:o,loop:C,bgImage:L,columns:b,mirrorCards:qo},!1):null,ve=_e?e(Xe.Provider,{value:{hand:_e,ids:i.blockIds??[],boxes:[]},children:$o}):p?e(Xe.Provider,{value:null,children:$o}):$o,Ae=e(He.Provider,{value:Js,children:e(Ve.Provider,{value:!1,children:eo?e(Lt.Provider,{value:le,children:e(At.Provider,{value:!z,children:ve})}):ve})}),zs=ao?.blockCount??0,Le=ne==="accordion"&&!!ao&&(E||zs>0)?e(dt,{startsOpen:Ls===!0,editing:E,title:e(He.Provider,{value:Zn,children:e(Ve.Provider,{value:!1,children:e(yo.Provider,{value:!1,children:e(ao,{className:`min-w-0 flex-1 ${on}`,minEmptyHeight:24})})})}),children:Ae}):Ae,Po=Z?e(In,{row:o==="row",stops:i.blockCount??0,children:Le}):Le,Ys=qe?.trim()||(Bs?"":void 0),qs={values:t,frame:po?24:0},Qs=s=>te?e(gn,{on:te,future:ws===!0,children:s}):s,Zs=s=>T.startsWith("/")?e(Bn,{href:T,className:Je,"aria-labelledby":s,[Ke]:""}):e("a",{href:T,className:Je,"aria-labelledby":s,[Ke]:""}),ye=(k?kn(k):"")+gs+(f===void 0||r&&r.index!==0?"":Jn(f)),ke=ye?e("style",{dangerouslySetInnerHTML:{__html:ye}}):null,U=Pn({loop:C,direction:o,scrollDirection:co,bgImage:L}),ot=l.desktop&&so!==""&&!Q&&!D.className&&!ze(Wo,Xo,Go)&&!Sn(io,Uo,jo)&&!T&&!w&&!y&&!k&&!Rn(lo&&!U,Is)&&Fo(To)&&(Eo(ro)||Fo(ro))&&Ho&&Object.values(t).every(s=>Eo(s)||Fo(s)),et=s=>({...ot?{[Hn]:""}:null,...n?null:{...wn(io),...$n(io,Uo,jo)},...k?{[An]:k}:null,...s?{id:s}:null}),Oe=g!==""?Number(b):0,st=K(B,H)===K(void 0),tt=(o==="column"||o==="row"&&!I&&!c&&(Oe===1&&st||Oe===0&&i.blockCount===1))&&!n&&!Z&&!oo,Ne=n&&Ns&&!oo,Be=(s,$)=>Qs(e(ht,{contained:lo&&!U,style:U?Bo:void 0,framedClass:Us,fillClass:js,columnClass:`${ko} ${Oo}${be}${xe}`,tabLabel:Ys,pad:n?void 0:qs,border:ze(Wo,Xo,Go),outerAttrs:et($),box:!0,edge:tt,outerStyle:n?void 0:se,outerClass:n?void 0:D.className||void 0,bleed:Ne,children:ke||$?Lo(to,{children:[ke,$?Zs($):null,U?e(We,{children:s}):s]}):U?e(We,{children:s}):s})),Ro=s=>T?e(er,{children:$=>Be(s,$)}):Be(s),Ee=s=>Qo.bound?e(St,{children:s}):s;if(!n){const s=v===void 0||v==="stretch",$=(M(a)!==""||g!==""||S!=="")&&!qt(B,H)&&!(W!==""&&M(N)==="")&&(s||K(B)!==K(void 0));if(!(o==="row"?$:o==="column"&&s))return Ro(Ee(Po));const Me=$t({direction:o,separator:m,loop:C,line:x,share:a,shareTablet:N,sharePhone:H,phoneRow:B,columns:b,columnsTablet:A,stackBelow:Do,shared:l.desktop||l.phone||q,count:As}),nt={hasWidth:!0,...Me?{bound:Pt(Me,Qo.bound)}:null};return Ro(e(Ge.Provider,{value:nt,children:Po}))}const j=mn(Mo,Vo),_o=xn({darken:Mo,darkenStyle:Vo,darkenTablet:ns,darkenStyleTablet:ls,darkenPhone:rs,darkenStylePhone:is}),Fe=[mo?"rounded-[inherit]":"",_o.className].filter(Boolean).join(" "),vo=je(go),Te=vo?{"--sf-box-bg":No(L??""),"--sf-box-bg-p":No(go??"")}:{backgroundImage:No(L??""),backgroundSize:"cover",backgroundPosition:"center"},De=Dn(void 0,void 0,ts),O=De.className?De:null,Ao=En({...t,top:R(t.top)??_(P.desktop,t.unit,"desktop"),bottom:R(t.bottom)??_(P.desktop,t.unit,"desktop"),topPhone:R(t.topPhone)??_(P.phone,t.unitPhone,"mobile"),bottomPhone:R(t.bottomPhone)??_(P.phone,t.unitPhone,"mobile"),left:R(t.left)??_(P.side,t.unit,"desktop"),right:R(t.right)??_(P.side,t.unit,"desktop"),leftPhone:R(t.leftPhone)??_(P.sidePhone,t.unitPhone,"mobile"),rightPhone:R(t.rightPhone)??_(P.sidePhone,t.unitPhone,"mobile")}),Ie=e("div",{className:`relative z-[1] ${un} ${Ao?.className??""}${y||w?` ${no}`:""}`.trimEnd(),style:j?{...Ao?.style,...Bo,...Fn}:{...Ao?.style,...Bo},children:Ee(Po)}),ge=Ne&&lo?e("div",{className:`${ko} ${Oo}${y||w?` ${no}`:""}`,children:Ie}):Ie;return Ro(e(to,{children:Lo("div",{className:`relative isolate overflow-hidden ${pn}${G}${vo&&!O?` ${Ye}`:""}${D.className?` ${D.className}`:""}`,style:{...mo?Qn:{},...se,...O?{}:Te},...O?{[Tn]:""}:{},children:[O&&Lo(to,{children:[e(jn,{sheet:O.sheet}),e("div",{"aria-hidden":!0,className:`absolute inset-0${mo?" rounded-[inherit]":""}${vo?` ${Ye}`:""} ${O.className}`,style:{...Te,...O.style??{}}})]}),e(wt,{wash:j&&_o.className?{...j,..._o.style}:j,...Fe?{className:Fe}:{}}),j?e(pt,{children:ge}):ge]})}))}export{sr as default};
@@ -50,7 +50,8 @@ export declare function HeroMediaLayer({ partMotion, editing, children, }: {
50
50
  editing: boolean;
51
51
  children: ReactNode;
52
52
  }): import("react").JSX.Element;
53
- export declare function HeroTwoPictures({ desktopLayout, phoneLayout, editing, marked, partMotion, first, second, }: {
53
+ export declare function HeroTwoPictures({ desktopLayout, phoneLayout, editing, marked, partMotion, first, second, laterSlide, }: {
54
+ laterSlide?: boolean;
54
55
  desktopLayout: MediaLayout;
55
56
  phoneLayout: MediaLayout;
56
57
  editing: boolean;
@@ -1 +1 @@
1
- "use client";import{Fragment as m,jsx as r,jsxs as l}from"react/jsx-runtime";import u from"./HeroPoster.js";import{SectionAnimation as b}from"./SectionAnimation.js";import{resolveMedia as h}from"../lib/media.js";import{HERO_MEDIA_PARTS as g,HERO_PART_ATTR as v}from"../lib/document/hero-media-parts.js";import{entranceDrawn as y}from"../lib/animation/entrance.js";import{readPartMotion as P}from"../lib/animation/part-motion.js";import{pictureHoverOf as T}from"../../format/lib/animation/hover.js";import{PHOTO_HOST_ATTR as w,SITE_PHOTO_CSS as j,resolveImageTreatment as H}from"../../format/lib/content/image-treatment.js";import{heroPictureCount as _,normaliseMediaLayout as k,resolvePhoneLayout as N}from"../../format/lib/hero-media-layout.js";import{normaliseVideoPlayback as O,normaliseVideoSource as S,parseYouTubeId as A}from"../../format/lib/hero-video.js";import{hidableText as R}from"efficient-easel/draw";const V={one:"max-[719px]:grid-cols-1 max-[719px]:grid-rows-1",side:"max-[719px]:grid-cols-2 max-[719px]:grid-rows-1",stacked:"max-[719px]:grid-cols-1 max-[719px]:grid-rows-2"},C={one:"view-tablet:grid-cols-1 view-tablet:grid-rows-1",side:"view-tablet:grid-cols-2 view-tablet:grid-rows-1",stacked:"view-tablet:grid-cols-1 view-tablet:grid-rows-2"};function q(e){const o=e.isVideo&&S(e.videoSource)==="youtube",i=e.isVideo&&O(e.videoPlayback)==="click",n=o?A(R(e.youtubeUrl)):null,t=k(e.mediaLayout);return{fromYouTube:o,onClick:i,youTubeId:n,backgroundFile:e.isVideo&&!o&&!i,desktopLayout:t,phoneLayout:N(e.mediaLayoutPhone,t),twoPictures:!e.isVideo&&_(e)>1}}function d(e,o){return y(P({_partMotion:e},o))}function c(e,o){return H(void 0,void 0,T(P({_partMotion:e},o)))}function B(e){return g.some(i=>c(e,i).className)?{hostAttrs:{[w]:""},sheet:j}:{}}function p({treatment:e,children:o}){return e.className?r("div",{className:`absolute inset-0 ${e.className}`,...e.style?{style:e.style}:{},children:o}):r(m,{children:o})}function x({color:e,opacity:o,passClicks:i=!0}){return o>0?r("div",{className:i?"pointer-events-none absolute inset-0 z-[2]":"absolute inset-0 z-[2]",style:{background:e,opacity:Math.min(Math.max(o,0),100)/100}}):null}function f({part:e,editing:o,marked:i=!0,entrance:n,className:t,children:a}){const s=o&&i?{[v]:e}:void 0;return n?r(b,{desktop:n.desktop,phone:n.phone,editing:o,boxClass:t,boxAttrs:s,children:a}):r("div",{className:t,...s,children:a})}function J({partMotion:e,editing:o,children:i}){const n=d(e,"media"),t=c(e,"media"),a=t.className?r("div",{className:`absolute inset-0 z-[1] ${t.className}`,...t.style?{style:t.style}:{},children:i}):i;return n?r(b,{desktop:n.desktop,phone:n.phone,editing:o,boxClass:"absolute inset-0 z-[1]",children:a}):r(m,{children:a})}function Q({desktopLayout:e,phoneLayout:o,editing:i,marked:n=!0,partMotion:t,first:a,second:s}){return l("div",{className:`absolute inset-0 z-[1] grid ${V[o]} ${C[e]}`,"data-hero-layout":e,"data-hero-layout-phone":o,children:[r(f,{part:"image",editing:i,marked:n,entrance:d(t,"image"),className:"relative overflow-hidden",children:l(p,{treatment:c(t,"image"),children:[r(u,{posterSrc:h(a.src),showVideo:!1,objectPosition:a.objectPosition,objectPositionPhone:a.objectPositionPhone,objectPositionTablet:a.objectPositionTablet}),r(x,{color:a.tintColor,opacity:a.tintOpacity})]})}),r(f,{part:"image2",editing:i,marked:n,entrance:d(t,"image2"),className:`relative overflow-hidden${o==="one"?" max-[719px]:hidden":""}${e==="one"?" view-tablet:hidden":""}`,children:l(p,{treatment:c(t,"image2"),children:[r(u,{posterSrc:h(s.src),showVideo:!1,objectPosition:s.objectPosition,objectPositionPhone:s.objectPositionPhone,objectPositionTablet:s.objectPositionTablet}),r(x,{color:s.tintColor,opacity:s.tintOpacity})]})})]})}export{J as HeroMediaLayer,f as HeroPickArea,p as HeroPictureHover,x as HeroTint,Q as HeroTwoPictures,q as heroMediaReading,d as heroPartEntrance,c as heroPartHover,B as heroPicturesHover};
1
+ "use client";import{Fragment as u,jsx as r,jsxs as c}from"react/jsx-runtime";import b from"./HeroPoster.js";import{SectionAnimation as h}from"./SectionAnimation.js";import{resolveMedia as P}from"../lib/media.js";import{HERO_MEDIA_PARTS as v,HERO_PART_ATTR as y}from"../lib/document/hero-media-parts.js";import{entranceDrawn as T}from"../lib/animation/entrance.js";import{readPartMotion as p}from"../lib/animation/part-motion.js";import{pictureHoverOf as w}from"../../format/lib/animation/hover.js";import{PHOTO_HOST_ATTR as j,SITE_PHOTO_CSS as H,resolveImageTreatment as _}from"../../format/lib/content/image-treatment.js";import{heroPictureCount as k,normaliseMediaLayout as N,resolvePhoneLayout as O}from"../../format/lib/hero-media-layout.js";import{normaliseVideoPlayback as S,normaliseVideoSource as A,parseYouTubeId as R}from"../../format/lib/hero-video.js";import{hidableText as V}from"efficient-easel/draw";const C={one:"max-[719px]:grid-cols-1 max-[719px]:grid-rows-1",side:"max-[719px]:grid-cols-2 max-[719px]:grid-rows-1",stacked:"max-[719px]:grid-cols-1 max-[719px]:grid-rows-2"},E={one:"view-tablet:grid-cols-1 view-tablet:grid-rows-1",side:"view-tablet:grid-cols-2 view-tablet:grid-rows-1",stacked:"view-tablet:grid-cols-1 view-tablet:grid-rows-2"};function B(e){const o=e.isVideo&&A(e.videoSource)==="youtube",i=e.isVideo&&S(e.videoPlayback)==="click",n=o?R(V(e.youtubeUrl)):null,t=N(e.mediaLayout);return{fromYouTube:o,onClick:i,youTubeId:n,backgroundFile:e.isVideo&&!o&&!i,desktopLayout:t,phoneLayout:O(e.mediaLayoutPhone,t),twoPictures:!e.isVideo&&k(e)>1}}function d(e,o){return T(p({_partMotion:e},o))}function l(e,o){return _(void 0,void 0,w(p({_partMotion:e},o)))}function J(e){return v.some(i=>l(e,i).className)?{hostAttrs:{[j]:""},sheet:H}:{}}function x({treatment:e,children:o}){return e.className?r("div",{className:`absolute inset-0 ${e.className}`,...e.style?{style:e.style}:{},children:o}):r(u,{children:o})}function f({color:e,opacity:o,passClicks:i=!0}){return o>0?r("div",{className:i?"pointer-events-none absolute inset-0 z-[2]":"absolute inset-0 z-[2]",style:{background:e,opacity:Math.min(Math.max(o,0),100)/100}}):null}function g({part:e,editing:o,marked:i=!0,entrance:n,className:t,children:a}){const s=o&&i?{[y]:e}:void 0;return n?r(h,{desktop:n.desktop,phone:n.phone,editing:o,boxClass:t,boxAttrs:s,children:a}):r("div",{className:t,...s,children:a})}function Q({partMotion:e,editing:o,children:i}){const n=d(e,"media"),t=l(e,"media"),a=t.className?r("div",{className:`absolute inset-0 z-[1] ${t.className}`,...t.style?{style:t.style}:{},children:i}):i;return n?r(h,{desktop:n.desktop,phone:n.phone,editing:o,boxClass:"absolute inset-0 z-[1]",children:a}):r(u,{children:a})}function W({desktopLayout:e,phoneLayout:o,editing:i,marked:n=!0,partMotion:t,first:a,second:s,laterSlide:m=!1}){return c("div",{className:`absolute inset-0 z-[1] grid ${C[o]} ${E[e]}`,"data-hero-layout":e,"data-hero-layout-phone":o,children:[r(g,{part:"image",editing:i,marked:n,entrance:d(t,"image"),className:"relative overflow-hidden",children:c(x,{treatment:l(t,"image"),children:[r(b,{posterSrc:P(a.src),showVideo:!1,laterSlide:m,objectPosition:a.objectPosition,objectPositionPhone:a.objectPositionPhone,objectPositionTablet:a.objectPositionTablet}),r(f,{color:a.tintColor,opacity:a.tintOpacity})]})}),r(g,{part:"image2",editing:i,marked:n,entrance:d(t,"image2"),className:`relative overflow-hidden${o==="one"?" max-[719px]:hidden":""}${e==="one"?" view-tablet:hidden":""}`,children:c(x,{treatment:l(t,"image2"),children:[r(b,{posterSrc:P(s.src),showVideo:!1,laterSlide:m,objectPosition:s.objectPosition,objectPositionPhone:s.objectPositionPhone,objectPositionTablet:s.objectPositionTablet}),r(f,{color:s.tintColor,opacity:s.tintOpacity})]})})]})}export{Q as HeroMediaLayer,g as HeroPickArea,x as HeroPictureHover,f as HeroTint,W as HeroTwoPictures,B as heroMediaReading,d as heroPartEntrance,l as heroPartHover,J as heroPicturesHover};
@@ -7,6 +7,9 @@ interface HeroPosterProps {
7
7
  objectPositionPhone?: string;
8
8
  objectPositionTablet?: string;
9
9
  quiet?: boolean;
10
+ slideShown?: boolean;
11
+ laterSlide?: boolean;
12
+ laterOfLead?: boolean;
10
13
  }
11
- export default function HeroPoster({ videoSrc, posterSrc, showVideo, playbackRate, objectPosition, objectPositionPhone, objectPositionTablet, quiet, }: HeroPosterProps): import("react").JSX.Element;
14
+ export default function HeroPoster({ videoSrc, posterSrc, showVideo, playbackRate, objectPosition, objectPositionPhone, objectPositionTablet, quiet, slideShown, laterSlide, laterOfLead, }: HeroPosterProps): import("react").JSX.Element;
12
15
  export {};
@@ -1 +1 @@
1
- "use client";import{jsx as o,jsxs as N}from"react/jsx-runtime";import{useEffect as m,useRef as L,useState as a}from"react";import{SiteImage as P}from"../lib/site-runtime.js";import R from"./HeroHeldFrame.js";import{hasAv1Variant as A,isExternalMediaUrl as H}from"../lib/media.js";import{sizedImage as S}from"../../format/lib/sized-image.js";import{phoneFocus as _}from"../../format/lib/content/phone-focus.js";const $=.5;function M({videoSrc:d,posterSrc:f,showVideo:p=!0,playbackRate:v=$,objectPosition:l="50% 50%",objectPositionPhone:I,objectPositionTablet:g,quiet:y=!1}){const n=_(I,g),e=f||"",t=d||"",[c,u]=a(!1),[j,w]=a(!1),[k,F]=a(!1),[C,E]=a(!1),[b,h]=a(!1),z=L(null);m(()=>{u(!1),w(!1),F(!1),E(!1)},[d,f]),m(()=>{if(typeof window>"u")return;const s=()=>{const r=window;r.requestIdleCallback?r.requestIdleCallback(()=>h(!0),{timeout:2e3}):setTimeout(()=>h(!0),800)};if(document.readyState==="complete"){s();return}return window.addEventListener("load",s,{once:!0}),()=>window.removeEventListener("load",s)},[]),m(()=>{const s=z.current;if(!s)return;const r=()=>{s.playbackRate=v};return r(),s.addEventListener("loadedmetadata",r),()=>s.removeEventListener("loadedmetadata",r)},[d,v]);const x=H(e),i=e&&x&&!j?S(e):{src:e};return N("div",{className:"absolute inset-0 z-[1]",children:[o("div",{className:"absolute inset-0",style:{background:"var(--site-surface)"}}),e&&(x?o("img",{src:i.src,...i.srcSet?{srcSet:i.srcSet,sizes:"100vw"}:{},alt:"",className:`absolute inset-0 z-[2] h-full w-full object-cover ${n.className}`.trim(),style:{display:c?"none":"block",objectPosition:l,...n.style},onError:()=>i.srcSet?w(!0):u(!0)},e):o(P,{src:e,alt:"",fill:!0,priority:!0,sizes:"100vw",className:`z-[2] object-cover ${n.className}`.trim(),style:{display:c?"none":"block",objectPosition:l,...n.style},onError:()=>u(!0)},e)),p&&!y&&t&&b&&!k&&N("video",{ref:z,autoPlay:!0,loop:!0,muted:!0,playsInline:!0,preload:"metadata",className:"absolute inset-0 z-[3] h-full w-full object-cover",style:{objectPosition:l},onError:()=>F(!0),children:[A(t)&&o("source",{src:t.replace(/\.mp4$/,".av1.mp4"),type:'video/mp4; codecs="av01.0.08M.10"'}),o("source",{src:t,type:"video/mp4"})]},t),p&&y&&t&&b&&!C&&(!e||c)&&o(R,{src:t,objectPosition:l,onError:()=>E(!0)},t)]})}export{M as default};
1
+ "use client";import{jsx as a,jsxs as S}from"react/jsx-runtime";import{useEffect as l,useRef as K,useState as r}from"react";import{SiteImage as U}from"../lib/site-runtime.js";import V from"./HeroHeldFrame.js";import{hasAv1Variant as Y,isExternalMediaUrl as D}from"../lib/media.js";import{sizedImage as G}from"../../format/lib/sized-image.js";import{phoneFocus as J}from"../../format/lib/content/phone-focus.js";import{useFirstScreenPlace as O}from"../lib/first-screen.js";const Q=.5;function X({videoSrc:f,posterSrc:h,showVideo:b=!0,playbackRate:g=Q,objectPosition:i="50% 50%",objectPositionPhone:j,objectPositionTablet:A,quiet:E=!1,slideShown:H,laterSlide:z=!1,laterOfLead:R=!1}){const d=J(j,A),p=O(),[P,T]=r(!1),L=p==="below"&&!P,_=p==="first",t=h||"",s=f||"",[v,y]=r(!1),[$,x]=r(!1),[M,I]=r(!1),[W,N]=r(!1),u=H??!0,[w,q]=r(!1),o=p!=="first"&&!R,[n,k]=r(!1),F=K(null);l(()=>{if(!o)return;if(document.readyState==="complete"){k(!0);return}const e=()=>k(!0);return window.addEventListener("load",e,{once:!0}),()=>window.removeEventListener("load",e)},[o]),l(()=>{y(!1),x(!1),I(!1),N(!1)},[f,h]),l(()=>{u&&q(!0)},[u]),l(()=>{const e=F.current;e&&(u?e.play()?.catch(()=>{}):e.pause())},[u,w,n]),l(()=>{if(!z||o&&!n)return;const e=()=>T(!0);if(typeof window.requestIdleCallback=="function"){const B=window.requestIdleCallback(e,{timeout:2e3});return()=>window.cancelIdleCallback(B)}const c=setTimeout(e,800);return()=>clearTimeout(c)},[z,o,n]),l(()=>{const e=F.current;if(!e)return;const c=()=>{e.playbackRate=g};return c(),e.addEventListener("loadedmetadata",c),()=>e.removeEventListener("loadedmetadata",c)},[f,g]);const C=D(t),m=t&&C&&!$?G(t):{src:t};return S("div",{className:"absolute inset-0 z-[1]",children:[a("div",{className:"absolute inset-0",style:{background:"var(--site-surface)"}}),t&&(C?a("img",{src:m.src,...m.srcSet?{srcSet:m.srcSet,sizes:"100vw"}:{},alt:"",...L?{loading:"lazy"}:{},..._?{fetchPriority:"high"}:{},className:`absolute inset-0 z-[2] h-full w-full object-cover ${d.className}`.trim(),style:{display:v?"none":"block",objectPosition:i,...d.style},onError:()=>m.srcSet?x(!0):y(!0)},t):a(U,{src:t,alt:"",fill:!0,...L?{}:P?{loading:"eager"}:{priority:!0},sizes:"100vw",className:`z-[2] object-cover ${d.className}`.trim(),style:{display:v?"none":"block",objectPosition:i,...d.style},onError:()=>y(!0)},t)),b&&!E&&s&&w&&(!o||n)&&!M&&S("video",{ref:F,autoPlay:!0,loop:!0,muted:!0,playsInline:!0,preload:"metadata",className:"absolute inset-0 z-[3] h-full w-full object-cover",style:{objectPosition:i},onError:()=>I(!0),children:[Y(s)&&a("source",{src:s.replace(/\.mp4$/,".av1.mp4"),type:'video/mp4; codecs="av01.0.08M.10"'}),a("source",{src:s,type:"video/mp4"})]},s),b&&E&&s&&w&&(!o||n)&&!W&&(!t||v)&&a(V,{src:s,objectPosition:i,onError:()=>N(!0)},s)]})}export{X as default};
@@ -1 +1 @@
1
- "use client";import{jsx as n,jsxs as D}from"react/jsx-runtime";import{useCallback as v,useEffect as w,useId as Ce,useRef as d,useState as k}from"react";import{markOverlayPortal as ee}from"../../format/lib/document/overlay-portal.js";import Pe from"./Ticker.js";import{HeroSlideStyleContext as De}from"./HeroSlide.js";import Ie from"./HeroArrows.js";import Ve from"./Reel.js";import{TICKER_PART_ATTR as $e}from"./PreviewTickerContext.js";import{useReducedMotion as ze}from"./useReducedMotion.js";import{heroHeightBox as Be,heroStoresRatio as Xe}from"../../format/lib/content/section-height.js";import{HEADER_HEIGHT_CSS as Ge}from"../lib/document/header-clearance.js";import{nextReel as Ye,normaliseHeroReelShape as je,reelShown as qe}from"../../format/lib/reel.js";import{arrowsShown as Ke,arrowStep as Fe}from"../../format/lib/hero-arrows.js";import{swipeEnabled as Je,swipeStep as Qe}from"../../format/lib/hero-swipe.js";import{videoControlShown as Ue,videoHeld as We}from"../../format/lib/hero-video-control.js";import{HERO_SLIDER_GOTO_EVENT as I}from"efficient-easel/draw";import{say as te}from"../../format/lib/editor-words.js";import{markedChildren as re}from"../../format/lib/marked-children.js";import{legacyTickerDrawn as Ze,TICKER_MOTION_PART as et}from"../../format/lib/hero-ticker.js";import{ON_MEDIA_INK_STYLE as tt}from"../../format/lib/content/ink.js";import{SectionAnimation as rt}from"./SectionAnimation.js";import{entranceDrawn as ot}from"../lib/animation/entrance.js";import{readPartMotion as nt}from"../lib/animation/part-motion.js";import{scrim as oe}from"../../format/lib/content/scrim.js";const st="Play video",ct="Hold video",at="flex h-7 cursor-pointer items-center gap-1.5 rounded-full border border-overlay-chrome/25 bg-overlay-scrim/80 px-[11px] font-mono text-[11px] leading-none tracking-[0.05em] text-overlay-fg",lt=()=>te("item"),ne=new Map;function it(m,a){const l=m?.ownerDocument?.defaultView;if(l)return l.addEventListener(I,a),()=>l.removeEventListener(I,a)}function ut({slides:m,strip:a,alignment:l,textureOpacity:y,showTexture:E,textureColor:g,phoneUpDown:se,phoneSideways:ce,autoplay:V,autoplayInterval:S,showTicker:ae,tickerItems:$,heightDesktop:le,heightTablet:ie,heightMobile:ue,heightFixed:de,heightFixedTablet:me,heightFixedMobile:fe,showPicker:he,pickerShape:pe,pickerPlacement:ve,showArrows:be,arrowsShape:xe,arrowsPlacement:we,editing:s,partMotion:ke}){const z=Be({heightDesktop:le,heightTablet:ie,heightMobile:ue,heightFixed:de,heightFixedTablet:me,heightFixedMobile:fe}),{className:ye,style:Ee}=z,N=Xe(z),B=(a?.blockCount??0)>0,ge=!B&&Ze({showTicker:ae,tickerItems:$}),X=($??[]).map(e=>e?.text?.trim()?e.text:s?lt():"").filter(Boolean),_e=ot(nt({_partMotion:ke},et)),f=d(null),G=d(null),Y=d(null),j=d(null),q=Ce(),A=d(q),[_,Re]=k([]),[Te,K]=k(0),b=d(0),[F,J]=k(!1),[Oe,Q]=k(null),[R,Se]=k(!1),H=ze(),T=v(()=>f.current?.querySelector(".hero-track")??null,[]),i=v((e,t=!1)=>{K(e),Q(o=>o===e?o:null),b.current=e,ne.set(A.current,e);const r=f.current?.querySelector(".hero-track");if(r)if(t){const o=r.style.transition;r.style.transition="none",r.style.transform=`translateX(-${Math.max(0,e)*100}%)`,r.offsetHeight,r.style.transition=o}else r.style.transform=`translateX(-${Math.max(0,e)*100}%)`},[]);w(()=>{const e=f.current,t=e?.getAttribute("data-easel-block")||e?.closest("[data-easel-block]")?.getAttribute("data-easel-block")||q;A.current=t;const r=ne.get(t);typeof r=="number"&&(K(r),b.current=r)},[]),w(()=>{const e=T();if(!e)return;const t=()=>{Re(o=>Ye(o,re(e,"data-slide-name")))};t();const r=new MutationObserver(t);return r.observe(e,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["data-slide-name","data-slide-process","data-slide-media"]}),()=>{r.disconnect()}},[T]),w(()=>{if(!s)return;const e=t=>{const r=t.detail;if(!r||typeof r.index!="number")return;const o=f.current,p=o?.getAttribute("data-easel-block")||o?.closest("[data-easel-block]")?.getAttribute("data-easel-block")||A.current;r.id&&r.id!==p||i(r.index,!0)};return it(f.current,e)},[s,i]);const c=_.length,u=Math.min(Math.max(Te,0),Math.max(0,c-1)),M=Oe===u,L=qe({shown:he,count:c}),U=Ke({shown:be,count:c}),W=Ue({editing:s,shown:u,slides:_}),Ne=We({editing:s,playing:R,controlShown:W}),O=Je({count:c,editing:s}),h=d(null),x=d(null),Ae=v(e=>{if(h.current=null,x.current=null,!O||e.touches.length!==1)return;const t=e.touches[0];h.current={x:t.clientX,y:t.clientY},x.current={x:t.clientX,y:t.clientY}},[O]),He=v(e=>{if(!h.current)return;if(e.touches.length!==1){h.current=null;return}const t=e.touches[0];x.current={x:t.clientX,y:t.clientY}},[]),Me=v(()=>{const e=h.current,t=x.current;if(h.current=null,x.current=null,!O||!e||!t)return;const r=Qe(t.x-e.x,t.y-e.y,b.current,c);r!==b.current&&i(r)},[O,c,i]);w(()=>{if(s||!V||F||M||H||c<=1)return;const t=Math.max(1,typeof S=="number"?S:6)*1e3,r=window.setTimeout(()=>i((u+1)%c),t);return()=>window.clearTimeout(r)},[s,V,S,F,M,H,c,u,i]),w(()=>{const e=[G.current,Y.current,j.current].filter(Boolean),t=e.map(o=>ee(o)),r=o=>{const p=o.target,C=p.closest("[data-hero-nav]"),Z=C??p.closest("[data-idx]");if(!Z)return;o.stopPropagation(),o.preventDefault();const P=C?Fe(C.dataset.heroNav,b.current,c):Number(Z.dataset.idx);Number.isNaN(P)||(i(P,s),re(T(),"data-slide-name")[P]?.click())};return e.forEach(o=>o.addEventListener("click",r,{capture:!0})),()=>{t.forEach(o=>o?.()),e.forEach(o=>o.removeEventListener("click",r,{capture:!0}))}},[c,i,T,s]);const Le=v(e=>{if(!e)return;const t=ee(e),r=o=>{o.stopPropagation(),o.preventDefault(),Se(p=>!p)};return e.addEventListener("click",r,{capture:!0}),()=>{t?.(),e.removeEventListener("click",r,{capture:!0})}},[]);return n(De.Provider,{value:{alignment:l,textureOpacity:y,textureOn:E,textureColor:g,quietVideo:Ne,phoneUpDown:se,phoneSideways:ce,holdReel:()=>Q(u),reelHeld:M,ratioMin:N},children:D("div",{ref:f,className:`relative mx-[var(--sf-hero-bleed-m,calc(50%_-_50vw))] w-[var(--sf-hero-bleed-w,100vw)] ${ye} max-w-[var(--sf-hero-cap,none)] ${N?"overflow-clip":"overflow-hidden"}`,style:Ee,onMouseEnter:()=>J(!0),onMouseLeave:()=>J(!1),onTouchStart:Ae,onTouchMove:He,onTouchEnd:Me,children:[n(m,{className:N?"hero-track flex min-h-full [&>*]:min-h-full [&>*]:min-w-full [&>*]:shrink-0 [&>*]:basis-full":"hero-track flex h-full [&>*]:h-full [&>*]:min-w-full [&>*]:shrink-0 [&>*]:basis-full",style:{transform:`translateX(-${u*100}%)`,transition:H?"none":"transform 600ms cubic-bezier(.22,.61,.36,1)"},minEmptyHeight:400}),W&&n("div",{ref:Le,"data-hero-video-control":R?"playing":"held",className:"sf-hero-video-control absolute left-6 z-[7]",style:{top:`calc(${Ge} + 16px)`},children:D("button",{type:"button",className:at,children:[n("span",{"aria-hidden":"true",children:R?"❚❚":"▶"}),te(R?ct:st)]})}),(L||U)&&D("div",{className:"pointer-events-none absolute inset-y-0 left-[var(--sf-hero-chrome-x,var(--sf-site-gutter,40px))] right-[var(--sf-hero-chrome-x,var(--sf-site-gutter,40px))] z-[6] mx-auto max-w-[var(--sf-hero-chrome-cap,calc(var(--sf-site-width,1600px)_-_var(--sf-site-gutter,40px)*2))]",children:[L&&n(Ve,{ref:G,slides:_,active:u,shape:je(pe),placement:ve}),U&&n(Ie,{ref:j,shape:xe,placement:we})]}),L&&n("div",{ref:Y,className:"sf-hero-phone-dots absolute bottom-[80px] left-1/2 z-[6] hidden -translate-x-1/2 items-center gap-2",children:_.map((e,t)=>n("button",{type:"button","data-idx":t,"aria-label":`Go to slide ${t+1}`,className:`h-2 rounded-full transition-all motion-reduce:transition-none ${t===u?"w-5 bg-accent":"w-2 bg-white/45 hover:bg-white/70"}`},t))}),B&&a&&n("div",{className:"sf-hero-strip absolute inset-x-0 bottom-0 z-[5] border-t border-overlay-chrome/10",style:{background:oe(.55),...tt},children:n(a,{})}),ge&&X.length>0&&n(dt,{editing:!!s,entrance:_e,children:n(Pe,{items:X,backdrop:"dark-media"})})]})})}function dt({editing:m,entrance:a,children:l}){const y="sf-hero-ticker absolute inset-x-0 bottom-0 z-[5] border-t border-overlay-chrome/10 py-3.5",E=m?{[$e]:""}:void 0,g={background:oe(.55)};return a?n(rt,{desktop:a.desktop,phone:a.phone,editing:m,boxClass:y,boxAttrs:E,boxStyle:g,children:l}):n("div",{className:y,...E,style:g,children:l})}export{I as HERO_SLIDER_GOTO_EVENT,ct as HERO_VIDEO_HOLD_LABEL,st as HERO_VIDEO_PLAY_LABEL,ut as default,it as subscribeSliderGoto};
1
+ "use client";import{jsx as n,jsxs as D}from"react/jsx-runtime";import{useCallback as v,useEffect as w,useId as Ce,useRef as d,useState as k}from"react";import{markOverlayPortal as ee}from"../../format/lib/document/overlay-portal.js";import Pe from"./Ticker.js";import{HeroSlideStyleContext as De}from"./HeroSlide.js";import Ie from"./HeroArrows.js";import Ve from"./Reel.js";import{TICKER_PART_ATTR as $e}from"./PreviewTickerContext.js";import{useReducedMotion as ze}from"./useReducedMotion.js";import{heroHeightBox as Be,heroStoresRatio as Xe}from"../../format/lib/content/section-height.js";import{HEADER_HEIGHT_CSS as Ge}from"../lib/document/header-clearance.js";import{nextReel as Ye,normaliseHeroReelShape as je,reelShown as qe}from"../../format/lib/reel.js";import{arrowsShown as Ke,arrowStep as Fe}from"../../format/lib/hero-arrows.js";import{swipeEnabled as Je,swipeStep as Qe}from"../../format/lib/hero-swipe.js";import{videoControlShown as Ue,videoHeld as We}from"../../format/lib/hero-video-control.js";import{HERO_SLIDER_GOTO_EVENT as I}from"efficient-easel/draw";import{say as te}from"../../format/lib/editor-words.js";import{markedChildren as re}from"../../format/lib/marked-children.js";import{legacyTickerDrawn as Ze,TICKER_MOTION_PART as et}from"../../format/lib/hero-ticker.js";import{ON_MEDIA_INK_STYLE as tt}from"../../format/lib/content/ink.js";import{SectionAnimation as rt}from"./SectionAnimation.js";import{entranceDrawn as ot}from"../lib/animation/entrance.js";import{readPartMotion as nt}from"../lib/animation/part-motion.js";import{scrim as oe}from"../../format/lib/content/scrim.js";const st="Play video",ct="Hold video",at="flex h-7 cursor-pointer items-center gap-1.5 rounded-full border border-overlay-chrome/25 bg-overlay-scrim/80 px-[11px] font-mono text-[11px] leading-none tracking-[0.05em] text-overlay-fg",lt=()=>te("item"),ne=new Map;function it(m,a){const i=m?.ownerDocument?.defaultView;if(i)return i.addEventListener(I,a),()=>i.removeEventListener(I,a)}function ut({slides:m,strip:a,alignment:i,textureOpacity:y,showTexture:E,textureColor:g,phoneUpDown:se,phoneSideways:ce,autoplay:V,autoplayInterval:O,showTicker:ae,tickerItems:$,heightDesktop:le,heightTablet:ie,heightMobile:ue,heightFixed:de,heightFixedTablet:me,heightFixedMobile:fe,showPicker:he,pickerShape:pe,pickerPlacement:ve,showArrows:be,arrowsShape:xe,arrowsPlacement:we,editing:s,partMotion:ke}){const z=Be({heightDesktop:le,heightTablet:ie,heightMobile:ue,heightFixed:de,heightFixedTablet:me,heightFixedMobile:fe}),{className:ye,style:Ee}=z,N=Xe(z),B=(a?.blockCount??0)>0,ge=!B&&Ze({showTicker:ae,tickerItems:$}),X=($??[]).map(e=>e?.text?.trim()?e.text:s?lt():"").filter(Boolean),_e=ot(nt({_partMotion:ke},et)),f=d(null),G=d(null),Y=d(null),j=d(null),q=Ce(),A=d(q),[_,Re]=k([]),[Se,K]=k(0),b=d(0),[F,J]=k(!1),[Te,Q]=k(null),[R,Oe]=k(!1),H=ze(),S=v(()=>f.current?.querySelector(".hero-track")??null,[]),u=v((e,t=!1)=>{K(e),Q(o=>o===e?o:null),b.current=e,ne.set(A.current,e);const r=f.current?.querySelector(".hero-track");if(r)if(t){const o=r.style.transition;r.style.transition="none",r.style.transform=`translateX(-${Math.max(0,e)*100}%)`,r.offsetHeight,r.style.transition=o}else r.style.transform=`translateX(-${Math.max(0,e)*100}%)`},[]);w(()=>{const e=f.current,t=e?.getAttribute("data-easel-block")||e?.closest("[data-easel-block]")?.getAttribute("data-easel-block")||q;A.current=t;const r=ne.get(t);typeof r=="number"&&(K(r),b.current=r)},[]),w(()=>{const e=S();if(!e)return;const t=()=>{Re(o=>Ye(o,re(e,"data-slide-name")))};t();const r=new MutationObserver(t);return r.observe(e,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["data-slide-name","data-slide-process","data-slide-media"]}),()=>{r.disconnect()}},[S]),w(()=>{if(!s)return;const e=t=>{const r=t.detail;if(!r||typeof r.index!="number")return;const o=f.current,p=o?.getAttribute("data-easel-block")||o?.closest("[data-easel-block]")?.getAttribute("data-easel-block")||A.current;r.id&&r.id!==p||u(r.index,!0)};return it(f.current,e)},[s,u]);const c=_.length,l=Math.min(Math.max(Se,0),Math.max(0,c-1)),M=Te===l,L=qe({shown:he,count:c}),U=Ke({shown:be,count:c}),W=Ue({editing:s,shown:l,slides:_}),Ne=We({editing:s,playing:R,controlShown:W}),T=Je({count:c,editing:s}),h=d(null),x=d(null),Ae=v(e=>{if(h.current=null,x.current=null,!T||e.touches.length!==1)return;const t=e.touches[0];h.current={x:t.clientX,y:t.clientY},x.current={x:t.clientX,y:t.clientY}},[T]),He=v(e=>{if(!h.current)return;if(e.touches.length!==1){h.current=null;return}const t=e.touches[0];x.current={x:t.clientX,y:t.clientY}},[]),Me=v(()=>{const e=h.current,t=x.current;if(h.current=null,x.current=null,!T||!e||!t)return;const r=Qe(t.x-e.x,t.y-e.y,b.current,c);r!==b.current&&u(r)},[T,c,u]);w(()=>{if(s||!V||F||M||H||c<=1)return;const t=Math.max(1,typeof O=="number"?O:6)*1e3,r=window.setTimeout(()=>u((l+1)%c),t);return()=>window.clearTimeout(r)},[s,V,O,F,M,H,c,l,u]),w(()=>{const e=[G.current,Y.current,j.current].filter(Boolean),t=e.map(o=>ee(o)),r=o=>{const p=o.target,C=p.closest("[data-hero-nav]"),Z=C??p.closest("[data-idx]");if(!Z)return;o.stopPropagation(),o.preventDefault();const P=C?Fe(C.dataset.heroNav,b.current,c):Number(Z.dataset.idx);Number.isNaN(P)||(u(P,s),re(S(),"data-slide-name")[P]?.click())};return e.forEach(o=>o.addEventListener("click",r,{capture:!0})),()=>{t.forEach(o=>o?.()),e.forEach(o=>o.removeEventListener("click",r,{capture:!0}))}},[c,u,S,s]);const Le=v(e=>{if(!e)return;const t=ee(e),r=o=>{o.stopPropagation(),o.preventDefault(),Oe(p=>!p)};return e.addEventListener("click",r,{capture:!0}),()=>{t?.(),e.removeEventListener("click",r,{capture:!0})}},[]);return n(De.Provider,{value:{alignment:i,textureOpacity:y,textureOn:E,textureColor:g,quietVideo:Ne,phoneUpDown:se,phoneSideways:ce,holdReel:()=>Q(l),reelHeld:M,shownSlide:l,ratioMin:N},children:D("div",{ref:f,className:`relative mx-[var(--sf-hero-bleed-m,calc(50%_-_50vw))] w-[var(--sf-hero-bleed-w,100vw)] ${ye} max-w-[var(--sf-hero-cap,none)] ${N?"overflow-clip":"overflow-hidden"}`,style:Ee,onMouseEnter:()=>J(!0),onMouseLeave:()=>J(!1),onTouchStart:Ae,onTouchMove:He,onTouchEnd:Me,children:[n(m,{className:N?"hero-track flex min-h-full [&>*]:min-h-full [&>*]:min-w-full [&>*]:shrink-0 [&>*]:basis-full":"hero-track flex h-full [&>*]:h-full [&>*]:min-w-full [&>*]:shrink-0 [&>*]:basis-full",style:{transform:`translateX(-${l*100}%)`,transition:H?"none":"transform 600ms cubic-bezier(.22,.61,.36,1)"},minEmptyHeight:400}),W&&n("div",{ref:Le,"data-hero-video-control":R?"playing":"held",className:"sf-hero-video-control absolute left-6 z-[7]",style:{top:`calc(${Ge} + 16px)`},children:D("button",{type:"button",className:at,children:[n("span",{"aria-hidden":"true",children:R?"❚❚":"▶"}),te(R?ct:st)]})}),(L||U)&&D("div",{className:"pointer-events-none absolute inset-y-0 left-[var(--sf-hero-chrome-x,var(--sf-site-gutter,40px))] right-[var(--sf-hero-chrome-x,var(--sf-site-gutter,40px))] z-[6] mx-auto max-w-[var(--sf-hero-chrome-cap,calc(var(--sf-site-width,1600px)_-_var(--sf-site-gutter,40px)*2))]",children:[L&&n(Ve,{ref:G,slides:_,active:l,shape:je(pe),placement:ve}),U&&n(Ie,{ref:j,shape:xe,placement:we})]}),L&&n("div",{ref:Y,className:"sf-hero-phone-dots absolute bottom-[80px] left-1/2 z-[6] hidden -translate-x-1/2 items-center gap-2",children:_.map((e,t)=>n("button",{type:"button","data-idx":t,"aria-label":`Go to slide ${t+1}`,className:`h-2 rounded-full transition-all motion-reduce:transition-none ${t===l?"w-5 bg-accent":"w-2 bg-white/45 hover:bg-white/70"}`},t))}),B&&a&&n("div",{className:"sf-hero-strip absolute inset-x-0 bottom-0 z-[5] border-t border-overlay-chrome/10",style:{background:oe(.55),...tt},children:n(a,{})}),ge&&X.length>0&&n(dt,{editing:!!s,entrance:_e,children:n(Pe,{items:X,backdrop:"dark-media"})})]})})}function dt({editing:m,entrance:a,children:i}){const y="sf-hero-ticker absolute inset-x-0 bottom-0 z-[5] border-t border-overlay-chrome/10 py-3.5",E=m?{[$e]:""}:void 0,g={background:oe(.55)};return a?n(rt,{desktop:a.desktop,phone:a.phone,editing:m,boxClass:y,boxAttrs:E,boxStyle:g,children:i}):n("div",{className:y,...E,style:g,children:i})}export{I as HERO_SLIDER_GOTO_EVENT,ct as HERO_VIDEO_HOLD_LABEL,st as HERO_VIDEO_PLAY_LABEL,ut as default,it as subscribeSliderGoto};
@@ -11,6 +11,7 @@ export interface HeroSlideStyle {
11
11
  quietVideo?: boolean;
12
12
  holdReel?: () => void;
13
13
  reelHeld?: boolean;
14
+ shownSlide?: number;
14
15
  ratioMin?: boolean;
15
16
  }
16
17
  export declare const HeroSlideStyleContext: import("react").Context<HeroSlideStyle>;
@@ -44,6 +45,7 @@ export interface HeroSlideProps {
44
45
  youtubeUrl?: string;
45
46
  videoPlayback?: string;
46
47
  partMotion?: Record<string, unknown>;
48
+ laterSlide?: boolean;
47
49
  }
48
- export default function HeroSlide({ name, process, mediaType, mediaSrc, videoSpeed, poster, objectPosition, objectPositionPhone, objectPositionTablet, tintColor, tintOpacity, groups: Groups, editing, themeClassName, themeStyle, overlayColor, overlayPosition, mediaLayout, mediaLayoutPhone, mediaImage2, objectPosition2, objectPosition2Phone, objectPosition2Tablet, tintColor2, tintOpacity2, videoSource, youtubeUrl, videoPlayback, partMotion, }: HeroSlideProps): import("react").JSX.Element;
50
+ export default function HeroSlide({ name, process, mediaType, mediaSrc, videoSpeed, poster, objectPosition, objectPositionPhone, objectPositionTablet, tintColor, tintOpacity, groups: Groups, editing, themeClassName, themeStyle, overlayColor, overlayPosition, mediaLayout, mediaLayoutPhone, mediaImage2, objectPosition2, objectPosition2Phone, objectPosition2Tablet, tintColor2, tintOpacity2, videoSource, youtubeUrl, videoPlayback, partMotion, laterSlide, }: HeroSlideProps): import("react").JSX.Element;
49
51
  export declare const HERO_SLIDE_SEEDS: Record<string, unknown>[];