efficient-web-builder 70.0.0 → 70.1.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 (46) hide show
  1. package/CHANGELOG.md +22 -1
  2. package/dist/editor/components/AddPageWindow.d.ts +7 -0
  3. package/dist/editor/components/AddPageWindow.js +1 -0
  4. package/dist/editor/components/PageStarterCard.d.ts +9 -0
  5. package/dist/editor/components/PageStarterCard.js +1 -0
  6. package/dist/editor/components/PagesPanel.js +1 -1
  7. package/dist/editor/components/StorefrontEditor.js +1 -1
  8. package/dist/editor/components/storefront-editor.css +71 -0
  9. package/dist/editor/lib/document/blocks/general/index.d.ts +2 -2
  10. package/dist/editor/lib/document/box-fields.d.ts +1 -1
  11. package/dist/editor/lib/document/field-groups.js +1 -1
  12. package/dist/editor/lib/document/host-config.d.ts +2 -0
  13. package/dist/editor/lib/document/host-config.js +1 -0
  14. package/dist/editor/lib/document/overrides.d.ts +1 -0
  15. package/dist/editor/lib/document/overrides.js +1 -1
  16. package/dist/editor/lib/document/page-root.d.ts +12 -0
  17. package/dist/editor/lib/document/page-root.js +2 -2
  18. package/dist/format/lib/content/box-shape.d.ts +1 -1
  19. package/dist/format/lib/content/card-row-keys.d.ts +1 -1
  20. package/dist/format/lib/content/section-sticky.d.ts +3 -3
  21. package/dist/format/lib/document/blocks/general/CardList/meta.js +1 -1
  22. package/dist/format/lib/document/blocks/general/Cards/meta.js +1 -1
  23. package/dist/format/lib/document/blocks/general/FAQ/meta.js +1 -1
  24. package/dist/format/lib/document/blocks/general/Flex/meta.js +1 -1
  25. package/dist/format/lib/document/blocks/general/Footprint/meta.js +2 -2
  26. package/dist/format/lib/document/blocks/general/Grid/meta.js +1 -1
  27. package/dist/format/lib/document/blocks/general/Hero/meta.js +1 -1
  28. package/dist/format/lib/document/blocks/general/HeroGroup/meta.d.ts +1 -1
  29. package/dist/format/lib/document/blocks/general/HeroGroup/meta.js +1 -1
  30. package/dist/format/lib/document/blocks/general/HeroSingle/meta.js +1 -1
  31. package/dist/format/lib/document/blocks/general/HeroSlide/meta.js +1 -1
  32. package/dist/format/lib/document/blocks/general/Logos/meta.js +1 -1
  33. package/dist/format/lib/document/blocks/general/OrderSummary/meta.js +1 -1
  34. package/dist/format/lib/document/blocks/general/ProcessSteps/column-seed.d.ts +1 -1
  35. package/dist/format/lib/document/blocks/general/ProcessSteps/column-seed.js +1 -1
  36. package/dist/format/lib/document/blocks/general/ProcessSteps/meta.js +1 -1
  37. package/dist/format/lib/document/blocks/general/slots.d.ts +93 -0
  38. package/dist/format/lib/document/blocks/general/slots.js +1 -0
  39. package/dist/format/lib/document/node-lists.js +1 -1
  40. package/dist/format/lib/editor-words-catalogue.d.ts +9 -0
  41. package/dist/format/lib/editor-words-catalogue.js +3 -3
  42. package/dist/format/lib/editor-words-kept.js +1 -1
  43. package/dist/format/lib/page-starters.d.ts +14 -0
  44. package/dist/format/lib/page-starters.js +1 -0
  45. package/dist/format/lib/web-backend.d.ts +9 -0
  46. package/package.json +2 -2
package/CHANGELOG.md CHANGED
@@ -1,13 +1,34 @@
1
1
  # Changelog
2
2
 
3
+ ## 70.1.0 - 2026-11-17
4
+
5
+ From main at `74cb8eb0`: #776, #777, #778. A minor: no `!`, no export is removed, no export changes its type, the peers stay `efficient-easel` `^35.0.0` and `efficient-shell` `^13.17.0`. New exports only. No stored key or value moves.
6
+
7
+ **For hosts:**
8
+ - efficient-storefront-blocks adds `general/slots.js` and `content/card-row-keys.js` to its `links` entry sources (eff-erp/efficient-storefront-blocks#591 does it): a page walk no longer loads every general block meta.
9
+ - The Add page window reads the new optional backend members `WebsitePages.starters` and `createFromStarter`. A host that does not pass them gets the window with **+ Blank page** only. No step is required.
10
+
11
+ ### Added
12
+
13
+ - **The Add page window** (#776): the Pages panel's **+** opens one window (the shell `Dialog`, size `full`). **+ Blank page** makes an empty draft page at a free URL handle. A list on the left (All pages, About, Contact, FAQ, Gallery, Store locator, Policies, and From your template when the site's template has pages) filters cards that draw each starter page's first section live at 1440 x 1080 in the site's theme, scaled by the shell `FitFrame`. **Add page** copies the starter into a new draft page. New `AddPageWindow`, `PageStarterCard`, `PageStarter`, `StarterGroup`, `PAGE_LIBRARY_GROUPS`, `ALL_STARTERS`, `TEMPLATE_STARTERS`, `libraryStarters`, `templateStarters`, `shownLibraryGroups`, `startersIn`, `firstSectionOf`, `useHostConfig`, `useSiteWidthsMetadata` and `SiteThemeCarrier`.
14
+ - **The general slot table** (#778): new `lib/document/blocks/general/slots` (`GENERAL_SLOTS`, the 13 general blocks' slot declarations in declaration order; it imports only `lib/content/card-row-keys`). `PROCESS_COLUMNS_SLOT` moves there; `ProcessSteps/column-seed` still exports it. Every `XSlots` export stays on its meta, read from the table. `lib/document/node-lists` builds its slots from the table and no longer imports the metas.
15
+
16
+ ### Changed
17
+
18
+ - **LongRead's link rows are in the Link group** (#777): Button, Link, Image and Image label move from the top of the Design tab into the Link group, just before Anchor, where the Box's "Link to" stands.
19
+
3
20
  ## 70.0.0 - 2026-11-17
4
21
 
5
- From main at `92b8eb71`: #767, #771. A major: both PRs are `!`. The peers rise to `efficient-easel` `^35.0.0` and `efficient-shell` `^13.17.0`. The module `lib/document/panel-bands` is removed. No stored key or value moves.
22
+ From main at `1d0a2e1c`: #767, #771, #774. A major: #767 and #771 are `!`. The peers rise to `efficient-easel` `^35.0.0` and `efficient-shell` `^13.17.0`. The module `lib/document/panel-bands` is removed. No stored key or value moves.
6
23
 
7
24
  **For hosts:**
8
25
  - Install efficient-easel 35.0.0 or later and efficient-shell 13.17.0 or later with this release.
9
26
  - A host that imports `efficient-web-builder/format/lib/document/panel-bands` (`bandIsDropped`, `droppedBands`, `loneDesignBand`, `withoutBands`, `sameKeys`, `BandRow`, `DrawnBand`, `TEXT_BAND_KEY`, `TEXT_BAND_TITLE`) stops compiling. The one-row band rule is efficient-easel 35's Inspector; the text box band key is `LEAD_BAND_KEY` from `efficient-easel/fields`. efficient-storefront-blocks `scripts/test-single-row-group-headings.tsx` imports `bandIsDropped` and is re-pointed in its bump (eff-erp/efficient-storefront-blocks#591).
10
27
 
28
+ ### Added
29
+
30
+ - **One import reader** (#774; it merged before the 70.0.0 release PR and was first left out of this section): new `importsOf(ts, fileName, text)`, `importIsTypeOnly`, `exportIsTypeOnly` and `packageNameOf` in `format/lib/build/module-specifiers`. `importsOf(ts, file)` in `lib/source-rules/support/panel-select-cascade` stays as a `@deprecated` call to it (delete by 2026-12-18). No export removed.
31
+
11
32
  ### Changed
12
33
 
13
34
  - **BREAKING: walks over a node's lists read the declared slot order** (#767). A node's declared slots come first, in draw order, then any other node list in efficient-easel `storedKeyOrder`, so the editor and the shop give the same answer (before, the editor read insertion order and the shop jsonb order). One helper in `lib/document/node-lists`. `CARD_TEMPLATE_BLOCKS`, `cardTemplateSlot`, `CARD_LIST_ITEM_BLOCKS` and `cardListItemSlot` move to the leaf `lib/content/card-row-keys`, and `BOX_DARKEN_STYLES` to the new leaf `lib/content/box-darken-styles`; `card-template` and `box-background` still export them.
@@ -0,0 +1,7 @@
1
+ import type { EditorPageRow } from "../lib/editor-document-adapter.js";
2
+ export default function AddPageWindow({ open, onClose, takenSlugs, onCreated, }: {
3
+ open: boolean;
4
+ onClose: () => void;
5
+ takenSlugs: ReadonlySet<string>;
6
+ onCreated: (row: EditorPageRow) => void;
7
+ }): import("react").JSX.Element;
@@ -0,0 +1 @@
1
+ "use client";import{jsx as a,jsxs as g}from"react/jsx-runtime";import{useEffect as D,useMemo as G,useRef as W,useState as h}from"react";import{useScreenDocument as q}from"efficient-easel/screen/components/ScreenDocumentContext";import{useEaselSession as z}from"efficient-easel/screen/lib/session-context";import{uniqueSlug as E}from"efficient-easel/page-copy";import{AddIcon as H}from"efficient-easel/icons";import{Dialog as O,EmptyState as V,Grid as J,SidebarActionButton as K,SidebarLayout as Q,SidebarNavItem as S,toast as P}from"efficient-shell/ui";import U from"./PageStarterCard.js";import{useHostConfig as X}from"../lib/document/host-config.js";import{useSiteWidthsMetadata as Y}from"../lib/document/overrides.js";import{say as t}from"../../format/lib/editor-words.js";import{ALL_STARTERS as i,TEMPLATE_STARTERS as w,shownLibraryGroups as Z,startersIn as $,templateStarters as ee}from"../../format/lib/page-starters.js";import{backendOf as te}from"../lib/website-session.js";function ae({open:l,onClose:x,takenSlugs:b,onCreated:T}){const I=z(),{adapter:d,siteId:c,templateId:L}=q(),r=te(I).pages,y=!L&&!!(r.starters&&r.createFromStarter),m=G(()=>c?{siteId:c}:{},[c]),R=X(),j=Y(),[k,s]=h(null),[o,n]=h(i),[u,v]=h(null),C=W(null);D(()=>{if(!l)return;if(n(i),!y){s([]);return}let e=!0;return s(null),r.starters(m).then(f=>e&&s(f),()=>{e&&(s([]),P.error(t("Couldn’t load the pages — please retry.")))}),()=>{e=!1}},[l,y,r,m]);const A=async(e,f)=>{if(!u){v(e);try{T(await f())}catch{P.error(t("Couldn’t add the page — please retry."))}finally{v(null)}}},B=()=>{if(!d.createPage)return;const e=t("New page");A("blank",()=>d.createPage({slug:E(e,b),title:e,layout:{}}))},F=e=>{A(e.id,()=>r.createFromStarter(e.id,{title:e.title,slug:E(e.slug,b),...m}))},p=k??[],M=Z(p),N=$(o,p),_=g("nav",{"aria-label":t("Pages"),className:"sf-add-page-nav",children:[a(S,{label:t("All pages"),active:o===i,onClick:()=>n(i)}),M.map(e=>a(S,{label:t(e.label),active:o===e.key,onClick:()=>n(e.key)},e.key)),ee(p).length>0?a("div",{className:"sf-add-page-group",children:a(S,{label:t("From your template"),active:o===w,onClick:()=>n(w)})}):null]});return a(O,{open:l,onClose:x,size:"full",title:t("Add page"),initialFocus:C,children:a(Q,{sidebarTop:g(K,{onClick:B,disabled:!d.createPage||u!==null,children:[a(H,{"aria-hidden":!0}),t("Blank page")]}),sidebar:_,children:g("div",{className:"sf-add-page",children:[a("h3",{ref:C,tabIndex:-1,className:"sf-add-page-title",children:t("Pages for your site")}),a("p",{className:"sf-add-page-sub",children:t("Choose a page and change the text, images and more.")}),k===null?a("p",{className:"sf-add-page-sub",children:t("Loading…")}):N.length===0?a(V,{title:t("No pages to start from"),description:t("Start with a blank page, then add sections.")}):a(J,{cols:1,smCols:2,lgCols:3,gap:8,children:N.map(e=>a(U,{starter:e,config:R,metadata:j,busy:u===e.id,onAdd:F},e.id))})]})})})}export{ae as default};
@@ -0,0 +1,9 @@
1
+ import type { Config } from "efficient-easel/blocks";
2
+ import type { PageStarter } from "../../format/lib/web-backend.js";
3
+ export default function PageStarterCard({ starter, config, metadata, busy, onAdd, }: {
4
+ starter: PageStarter;
5
+ config: Config;
6
+ metadata: Record<string, unknown>;
7
+ busy: boolean;
8
+ onAdd: (starter: PageStarter) => void;
9
+ }): import("react").JSX.Element;
@@ -0,0 +1 @@
1
+ "use client";import{jsx as e,jsxs as o}from"react/jsx-runtime";import{useMemo as p,useState as h}from"react";import{CanvasFrame as v}from"efficient-easel/easel";import{Button as g,FitFrame as y}from"efficient-shell/ui";import C from"./PreviewThemeFrame.js";import N from"../../render/lib/document/page-render.js";import{SiteThemeCarrier as S,suppressPreviewNav as D}from"../lib/document/page-root.js";import{useEditorCanvasStyles as x}from"../lib/editor-canvas-styles.js";import{say as i}from"../../format/lib/editor-words.js";import{firstSectionOf as F}from"../../format/lib/page-starters.js";const b=1440,j=1080;function A({starter:t,config:a,metadata:s,busy:n,onAdd:m}){const{mirrorHostStyles:d}=x(),[l,c]=h(null),f=p(()=>{const r=F(t.layout),u=t.layout.zones;return{root:{props:{}},content:r?[r]:[],zones:u??{}}},[t.layout]);return o("div",{className:"sf-starter",children:[o("div",{className:"sf-starter-picture",children:[e("div",{inert:!0,className:"sf-starter-frame",children:e(y,{width:b,height:j,children:e(v,{id:`page-starter-${t.id}`,title:t.title,mirrorStyles:d,onDocument:c,height:"fill",children:e(C,{document:l??void 0,children:e(S,{onClickCapture:D,body:r=>e("div",{className:"sf-themed-content",style:r,children:e("div",{style:{background:"var(--bg)"},children:e(N,{config:a,data:f,metadata:s})})})})})})})}),e("div",{className:"sf-starter-add",children:e(g,{onClick:()=>m(t),loading:n,"aria-label":i("Add “{name}”",{name:t.title}),children:i("Add page")})})]}),e("span",{className:"sf-starter-name",children:t.title})]})}export{A as default};
@@ -1 +1 @@
1
- "use client";import{jsx as n,Fragment as ne,jsxs as S}from"react/jsx-runtime";import{Fragment as Re,useEffect as De,useId as xe,useMemo as oe,useRef as Ne,useState as c}from"react";import{useScreenDocument as ae}from"efficient-easel/screen/components/ScreenDocumentContext";import{UiIcon as j}from"efficient-easel/draw/client";import ve from"efficient-easel/screen/components/SidePanelHead";import{useWebsiteName as Ee}from"./WebsiteSettingsPanel.js";import{InspectorIconButton as Oe}from"efficient-easel/chrome";import{Button as se,Dialog as Le,FormField as Be,Input as le,PopupMenu as Fe,PopupMenuItem as ie,toast as re}from"efficient-shell/ui";import{LayersTree as Me,TreeGroupLabel as _e,TreeRow as de,TreeRowAction as O}from"efficient-easel/tree";import{AddIcon as ze,DuplicateIcon as Ge,PageIcon as He,SettingsIcon as Te}from"efficient-easel/icons";import{PagesIcon as Ue}from"efficient-easel/rail";import{useEaselHost as We}from"efficient-easel/screen/lib/host";import{bucketEditorPageRows as je,DYNAMIC_PAGES_GROUP_KEY as qe,isDynamicPageRow as Ke,isPopupPageRow as Ye,MAIN_PAGES_GROUP as Je}from"../../format/lib/editor-page-rows.js";import{useEaselSession as ce}from"efficient-easel/screen/lib/session-context";import{holdPageRow as q,usePageRows as Qe}from"../lib/page-rows.js";import{say as t,sayCount as Ve}from"../../format/lib/editor-words.js";import{canDuplicatePage as Xe,DuplicatePageDialog as Ze,uniqueSlug as ue}from"efficient-easel/page-copy";import{backendOf as $e}from"../lib/website-session.js";import{shopHost as et}from"../../format/lib/web-runtime.js";import{newPopupPage as tt}from"../../format/lib/popup/new-popup.js";const pe="sf-editor-pages-collapsed-groups";function nt(){const i=ce(),{siteId:L,templateId:k}=ae(),I=$e(i).pages;if(!(!I.duplicate||k))return(p,A)=>I.duplicate(p.id,{...A,...L?{siteId:L}:{}})}function ot({onNavigate:i,onClose:L,activeSurface:k,onPreviewSurface:I}){const p=ce().chrome?.pageRows,A=We(),{adapter:m,capabilities:g,ready:B,currentSlug:K}=ae(),me=Ee(),{rows:u,reload:F,setRows:Y,getRows:ge}=Qe(),[M,fe]=c(""),[r,R]=c(!1),[D,f]=c(null),[J,x]=c(!1),[h,_]=c(""),Q=xe(),z=nt(),[b,G]=c(null),[H,he]=c(()=>{if(typeof window>"u")return new Set;try{const e=window.localStorage.getItem(pe);return new Set(e?JSON.parse(e):[])}catch{return new Set}});De(()=>{try{window.localStorage.setItem(pe,JSON.stringify([...H]))}catch{}},[H]);const be=e=>he(a=>{const o=new Set(a);return o.has(e)?o.delete(e):o.add(e),o}),Pe=oe(()=>je(u??[]),[u]),T=M.trim().toLowerCase(),V=e=>!T||e.toLowerCase().includes(T),ye=e=>T?!0:!H.has(e),N=oe(()=>new Set((u??[]).map(e=>e.slug)),[u]),X=()=>{if(g.pageCreationInAdminForm){A.send("storefront-editor:new-page");return}_(""),f(null),x(!0)},Z=async()=>{const e=h.trim();if(!(!e||!B||r||!m.createPage)){R(!0),f(null);try{const a=await m.createPage({slug:ue(e,N),title:e,layout:{}});await F(),x(!1),_(""),i(a.slug)}catch{f(t("Couldn’t add the page — please retry."))}finally{R(!1)}}},v=g.hasSiteSettings&&!!m.createPage,we=async()=>{if(!(!B||r||!m.createPage)){R(!0),f(null);try{const e=await m.createPage(tt(t("New popup"),N));await F(),i(e.slug)}catch{f(t("Couldn’t add the popup — please retry."))}finally{R(!1)}}},$=Ne(null),[P,y]=c(null),Ce=()=>{if(!v)return X();if(P)return y(null);const e=$.current?.getBoundingClientRect();e&&y({top:e.bottom+6,right:Math.max(8,window.innerWidth-e.right)})},Se=e=>{const a=u??[],o=m.deletePage;if(!B||r||!o||a.length<=1)return;const l=a.findIndex(s=>s.id===e.id),d=a.filter(s=>s.id!==e.id),w=e.slug===K;q(e.id,!0),Y(d),f(null),w&&d[0]&&i(d[0].slug);const E=()=>{q(e.id,!1);const s=ge()??[];if(s.some(Ae=>Ae.id===e.id))return;const C=[...s];C.splice(Math.max(0,Math.min(l,C.length)),0,e),Y(C)};re.undoable(t("Deleted “{name}”",{name:e.label}),{actionLabel:t("Undo"),commit:async s=>{await o(e.id,s),q(e.id,!1)},undo:()=>{E(),w&&i(e.slug)},onFail:()=>{E(),re.error(t("Couldn’t delete the page — please retry."))}})},ke=e=>A.send("storefront-editor:open-page",{slug:e}),Ie=e=>{if(!V(e.label))return null;const a=!k&&e.slug===K,o=g.canDeletePagesInline&&(u??[]).length>1,l=Ke(e),d=Ye(e),w=[...l?[{label:t("Dynamic"),tone:"info"}]:[],...d?[{label:t("Lightbox"),tone:"success"}]:[],...e.draft?[{label:t("draft"),tone:"draft"}]:[]],E=w.length>0?w:void 0,s=!!z&&Xe(e),C=s||g.pageCreationInAdminForm||o?S(ne,{children:[s&&n(O,{kind:"plain",label:t("Duplicate “{name}”",{name:e.label}),disabled:r,onClick:()=>G(e),children:n(Ge,{size:13})}),g.pageCreationInAdminForm&&n(O,{kind:"plain",label:t("Page settings for “{name}”",{name:e.label}),onClick:()=>ke(e.slug),children:n(Te,{size:13})}),o&&n(O,{kind:"delete",label:t("Delete “{name}”",{name:e.label}),disabled:r,onClick:()=>Se(e),children:n(j,{name:"trash",size:13,strokeWidth:1.7,rounded:!0})})]}):void 0;return n(de,{icon:n(He,{size:14}),name:e.label,selected:a,onSelect:()=>i(e.slug),badge:E,actions:C,rowProps:{"data-page-slug":e.slug}},e.id)},U=(e,a,o)=>{const l=o.filter(Boolean);if(l.length===0)return null;const d=ye(e);return S(Re,{children:[n(_e,{count:l.length,countLabel:Ve("{n} page","{n} pages",l.length),expanded:d,onToggle:()=>be(e),children:a}),d&&l]},e)},ee=(p?.rows??[]).filter(e=>V(e.label)).map(e=>{const a=k===e.key;return n(de,{icon:e.icon,name:e.label,selected:a,onSelect:()=>I(e.key),badge:{label:t("Preview"),tone:"warning"},actions:n(O,{kind:"plain",label:t("Open the {name} in a new tab",{name:e.label}),onClick:()=>window.open(e.href,"_blank","noopener,noreferrer"),children:n(j,{name:"external-link",size:13,strokeWidth:1.7,rounded:!0})}),rowProps:{"data-shop-surface":e.key}},e.key)}),te=g.hasSiteSettings&&!!p,W=(()=>{if(u===null)return null;const e=[];let a=!1;for(const o of Pe){te&&!a&&o.key.startsWith("system:")&&(e.push(U("shop",p.title,ee)),a=!0);const l=o.key===qe||o.label===Je?t(o.label):o.label;e.push(U(o.key,l,o.rows.map(Ie)))}return te&&!a&&e.push(U("shop",p.title,ee)),e})();return S("div",{className:"sf-pages",children:[n(ve,{icon:n(Ue,{}),title:t("Pages"),context:me,actions:n(Oe,{buttonRef:$,label:v?t("Add"):t("New page"),hasPopup:v?"menu":void 0,expanded:v?P!==null:void 0,onClick:Ce,children:n(ze,{size:15})})}),P&&n(Fe,{portal:!0,style:{top:P.top,right:P.right},onClose:()=>y(null),children:S("div",{role:"menu","aria-label":t("Add"),children:[n(ie,{role:"menuitem",onClick:()=>{y(null),X()},children:t("Page")}),n(ie,{role:"menuitem",disabled:r,onClick:()=>{y(null),we()},children:t("Popup")})]})}),n("div",{className:"sf-pages-find",children:n(le,{type:"search",leftIcon:n(j,{name:"search",size:14,rounded:!0}),placeholder:t("Search all pages…"),value:M,onChange:e=>fe(e.target.value),"aria-label":t("Search all pages")})}),D&&!J&&n("div",{className:"sf-note sf-note--error",role:"alert",children:D}),W===null?n("div",{className:"sf-note",children:t("Loading…")}):W.some(Boolean)?n(Me,{ariaLabel:t("Pages"),className:"sf-scroll",children:W}):n("div",{className:"sf-note",children:M.trim()?t("No pages match your search"):t("No pages yet. Add one with + above.")}),z&&b&&n(Ze,{source:{title:b.label,slug:b.slug},taken:N,host:et(),duplicate:e=>z(b,e),onClose:()=>G(null),onDuplicated:e=>{G(null),F(),i(e.slug)}},b.id),n(Le,{open:J,onClose:()=>x(!1),size:"sm",title:t("Add a page"),description:t("Give the new template page a name. It starts blank — add sections once it opens."),footer:S(ne,{children:[n(se,{variant:"secondary",onClick:()=>x(!1),children:t("Cancel")}),n(se,{onClick:()=>{Z()},disabled:r||!h.trim(),loading:r,children:t("Add page")})]}),children:n(Be,{label:t("Page name"),htmlFor:Q,hint:h.trim()?t("URL: /{slug}",{slug:ue(h,N)}):void 0,error:D??void 0,children:n(le,{id:Q,value:h,invalid:!!D,onChange:e=>_(e.target.value),onKeyDown:e=>{e.key==="Enter"&&Z()},placeholder:t("e.g. About")})})})]})}export{ot as default};
1
+ "use client";import{jsx as t,Fragment as we,jsxs as A}from"react/jsx-runtime";import{Fragment as ye,useEffect as ke,useMemo as $,useRef as Ce,useState as d}from"react";import{useScreenDocument as ee}from"efficient-easel/screen/components/ScreenDocumentContext";import{UiIcon as G}from"efficient-easel/draw/client";import Ie from"efficient-easel/screen/components/SidePanelHead";import{useWebsiteName as Re}from"./WebsiteSettingsPanel.js";import{InspectorIconButton as Ae}from"efficient-easel/chrome";import{Input as De,PopupMenu as xe,PopupMenuItem as te,toast as ne}from"efficient-shell/ui";import{LayersTree as Oe,TreeGroupLabel as Ee,TreeRow as oe,TreeRowAction as D}from"efficient-easel/tree";import{AddIcon as Ne,DuplicateIcon as Le,PageIcon as Be,SettingsIcon as Me}from"efficient-easel/icons";import{PagesIcon as _e}from"efficient-easel/rail";import{useEaselHost as Fe}from"efficient-easel/screen/lib/host";import{bucketEditorPageRows as ve,DYNAMIC_PAGES_GROUP_KEY as ze,isDynamicPageRow as Ge,isPopupPageRow as He,MAIN_PAGES_GROUP as We}from"../../format/lib/editor-page-rows.js";import{useEaselSession as H}from"efficient-easel/screen/lib/session-context";import{holdPageRow as W,usePageRows as Te}from"../lib/page-rows.js";import{say as n,sayCount as je}from"../../format/lib/editor-words.js";import{canDuplicatePage as Ue,DuplicatePageDialog as Ye}from"efficient-easel/page-copy";import qe from"./AddPageWindow.js";import{backendOf as se}from"../lib/website-session.js";import{shopHost as Je}from"../../format/lib/web-runtime.js";import{newPopupPage as Ke}from"../../format/lib/popup/new-popup.js";const ae="sf-editor-pages-collapsed-groups";function Qe(){const r=H(),{siteId:x,templateId:S}=ee(),w=se(r).pages;if(!(!w.duplicate||S))return(u,y)=>w.duplicate(u.id,{...y,...x?{siteId:x}:{}})}function Ve({onNavigate:r,onClose:x,activeSurface:S,onPreviewSurface:w}){const u=H().chrome?.pageRows,y=Fe(),{adapter:k,capabilities:p,ready:T,currentSlug:j}=ee(),le=Re(),{rows:c,reload:O,setRows:U,getRows:re}=Te(),[E,ie]=d(""),[m,Y]=d(!1),[q,C]=d(null),[J,N]=d(!1),ce=!!se(H()).pages.createFromStarter,L=Qe(),[g,B]=d(null),[M,de]=d(()=>{if(typeof window>"u")return new Set;try{const e=window.localStorage.getItem(ae);return new Set(e?JSON.parse(e):[])}catch{return new Set}});ke(()=>{try{window.localStorage.setItem(ae,JSON.stringify([...M]))}catch{}},[M]);const ue=e=>de(s=>{const o=new Set(s);return o.has(e)?o.delete(e):o.add(e),o}),pe=$(()=>ve(c??[]),[c]),_=E.trim().toLowerCase(),K=e=>!_||e.toLowerCase().includes(_),me=e=>_?!0:!M.has(e),F=$(()=>new Set((c??[]).map(e=>e.slug)),[c]),Q=()=>{if(p.pageCreationInAdminForm&&!ce){y.send("storefront-editor:new-page");return}C(null),N(!0)},I=p.hasSiteSettings&&!!k.createPage,ge=async()=>{if(!(!T||m||!k.createPage)){Y(!0),C(null);try{const e=await k.createPage(Ke(n("New popup"),F));await O(),r(e.slug)}catch{C(n("Couldn’t add the popup — please retry."))}finally{Y(!1)}}},V=Ce(null),[f,h]=d(null),fe=()=>{if(!I)return Q();if(f)return h(null);const e=V.current?.getBoundingClientRect();e&&h({top:e.bottom+6,right:Math.max(8,window.innerWidth-e.right)})},he=e=>{const s=c??[],o=k.deletePage;if(!T||m||!o||s.length<=1)return;const l=s.findIndex(a=>a.id===e.id),i=s.filter(a=>a.id!==e.id),b=e.slug===j;W(e.id,!0),U(i),C(null),b&&i[0]&&r(i[0].slug);const R=()=>{W(e.id,!1);const a=re()??[];if(a.some(Se=>Se.id===e.id))return;const P=[...a];P.splice(Math.max(0,Math.min(l,P.length)),0,e),U(P)};ne.undoable(n("Deleted “{name}”",{name:e.label}),{actionLabel:n("Undo"),commit:async a=>{await o(e.id,a),W(e.id,!1)},undo:()=>{R(),b&&r(e.slug)},onFail:()=>{R(),ne.error(n("Couldn’t delete the page — please retry."))}})},be=e=>y.send("storefront-editor:open-page",{slug:e}),Pe=e=>{if(!K(e.label))return null;const s=!S&&e.slug===j,o=p.canDeletePagesInline&&(c??[]).length>1,l=Ge(e),i=He(e),b=[...l?[{label:n("Dynamic"),tone:"info"}]:[],...i?[{label:n("Lightbox"),tone:"success"}]:[],...e.draft?[{label:n("draft"),tone:"draft"}]:[]],R=b.length>0?b:void 0,a=!!L&&Ue(e),P=a||p.pageCreationInAdminForm||o?A(we,{children:[a&&t(D,{kind:"plain",label:n("Duplicate “{name}”",{name:e.label}),disabled:m,onClick:()=>B(e),children:t(Le,{size:13})}),p.pageCreationInAdminForm&&t(D,{kind:"plain",label:n("Page settings for “{name}”",{name:e.label}),onClick:()=>be(e.slug),children:t(Me,{size:13})}),o&&t(D,{kind:"delete",label:n("Delete “{name}”",{name:e.label}),disabled:m,onClick:()=>he(e),children:t(G,{name:"trash",size:13,strokeWidth:1.7,rounded:!0})})]}):void 0;return t(oe,{icon:t(Be,{size:14}),name:e.label,selected:s,onSelect:()=>r(e.slug),badge:R,actions:P,rowProps:{"data-page-slug":e.slug}},e.id)},v=(e,s,o)=>{const l=o.filter(Boolean);if(l.length===0)return null;const i=me(e);return A(ye,{children:[t(Ee,{count:l.length,countLabel:je("{n} page","{n} pages",l.length),expanded:i,onToggle:()=>ue(e),children:s}),i&&l]},e)},X=(u?.rows??[]).filter(e=>K(e.label)).map(e=>{const s=S===e.key;return t(oe,{icon:e.icon,name:e.label,selected:s,onSelect:()=>w(e.key),badge:{label:n("Preview"),tone:"warning"},actions:t(D,{kind:"plain",label:n("Open the {name} in a new tab",{name:e.label}),onClick:()=>window.open(e.href,"_blank","noopener,noreferrer"),children:t(G,{name:"external-link",size:13,strokeWidth:1.7,rounded:!0})}),rowProps:{"data-shop-surface":e.key}},e.key)}),Z=p.hasSiteSettings&&!!u,z=(()=>{if(c===null)return null;const e=[];let s=!1;for(const o of pe){Z&&!s&&o.key.startsWith("system:")&&(e.push(v("shop",u.title,X)),s=!0);const l=o.key===ze||o.label===We?n(o.label):o.label;e.push(v(o.key,l,o.rows.map(Pe)))}return Z&&!s&&e.push(v("shop",u.title,X)),e})();return A("div",{className:"sf-pages",children:[t(Ie,{icon:t(_e,{}),title:n("Pages"),context:le,actions:t(Ae,{buttonRef:V,label:I?n("Add"):n("New page"),hasPopup:I?"menu":void 0,expanded:I?f!==null:void 0,onClick:fe,children:t(Ne,{size:15})})}),f&&t(xe,{portal:!0,style:{top:f.top,right:f.right},onClose:()=>h(null),children:A("div",{role:"menu","aria-label":n("Add"),children:[t(te,{role:"menuitem",onClick:()=>{h(null),Q()},children:n("Page")}),t(te,{role:"menuitem",disabled:m,onClick:()=>{h(null),ge()},children:n("Popup")})]})}),t("div",{className:"sf-pages-find",children:t(De,{type:"search",leftIcon:t(G,{name:"search",size:14,rounded:!0}),placeholder:n("Search all pages…"),value:E,onChange:e=>ie(e.target.value),"aria-label":n("Search all pages")})}),q&&!J&&t("div",{className:"sf-note sf-note--error",role:"alert",children:q}),z===null?t("div",{className:"sf-note",children:n("Loading…")}):z.some(Boolean)?t(Oe,{ariaLabel:n("Pages"),className:"sf-scroll",children:z}):t("div",{className:"sf-note",children:E.trim()?n("No pages match your search"):n("No pages yet. Add one with + above.")}),L&&g&&t(Ye,{source:{title:g.label,slug:g.slug},taken:F,host:Je(),duplicate:e=>L(g,e),onClose:()=>B(null),onDuplicated:e=>{B(null),O(),r(e.slug)}},g.id),J?t(qe,{open:!0,onClose:()=>N(!1),takenSlugs:F,onCreated:e=>{N(!1),O(),r(e.slug)}}):null]})}export{Ve as default};
@@ -1 +1 @@
1
- "use client";import{jsx as c,jsxs as Ct}from"react/jsx-runtime";import{useCallback as o,useEffect as f,useMemo as he,useRef as g,useState as r}from"react";import"efficient-easel/easel.css";import"efficient-easel/shell.css";import"efficient-easel/rail.css";import"efficient-easel/panel.css";import"efficient-easel/fields.css";import"efficient-easel/pick.css";import"efficient-easel/copy.css";import"efficient-easel/gold.css";import"efficient-easel/text-styles.css";import"efficient-easel/menu.css";import"efficient-easel/chrome.css";import"efficient-easel/tree.css";import"efficient-easel/drag.css";import"efficient-easel/screen.css";import"./storefront-editor.css";import{buildConfig as _t}from"../lib/document/build-config.js";import{ChromeWrap as Pt}from"efficient-easel/screen/lib/host-chrome";import{sessionRegistry as Tt}from"efficient-easel/screen/lib/session";import{refreshSiteLiveState as Et}from"../lib/site-live-state.js";import{holdSiteWrites as yt}from"../../format/lib/site-writes.js";import{backendOf as H,blocksOf as Gt}from"../lib/website-session.js";import{useEaselSession as vt}from"efficient-easel/screen/lib/session-context";import{withSiteBlockGapFields as kt}from"../../format/lib/document/site-gap-fields.js";import{withTemplateMediaPlaceholders as Wt}from"../../format/lib/document/templateFields.js";import{setEditorPage as ue}from"../../format/lib/document/editor-page-context.js";import{EditorPagePathProvider as Ht}from"./EditorPagePathProvider.js";import{resolveSiteName as Rt}from"../../format/lib/content/site-name.js";import{normalizeSiteGutter as Bt,normalizeSiteGutterPhone as Ft,normalizeSiteWidth as It}from"../../format/lib/content/page-width.js";import{siteLengthNumber as w,siteLengthUnitsOfRow as bt}from"../../format/lib/content/css-length.js";import{normalizeSiteBackground as le}from"../../format/lib/content/section-width.js";import{normalizeSiteBlockGap as me}from"../../format/lib/content/container-gap.js";import Dt,{DocumentScreen as Mt}from"efficient-easel/screen/components/ScreenMount";import Nt from"./WebsiteHintsProvider.js";import{useScreenDocument as Ot}from"efficient-easel/screen/components/ScreenDocumentContext";import{PreviewHeaderProvider as xt,siteThemeRow as Ut,themeEdited as At,themeSeeded as Lt}from"../../render/components/PreviewHeaderContext.js";import{PreviewFooterProvider as zt}from"./PreviewFooterContext.js";import{PreviewChatProvider as Yt,DEFAULT_CHAT_PREVIEW as jt}from"./PreviewChatContext.js";import{PreviewSocialProvider as Kt}from"../../render/components/PreviewSocialContext.js";import{useSocialSettings as Vt}from"./useSocialSettings.js";import{PreviewSurfaceProvider as Xt}from"./PreviewSurfaceContext.js";import{WEBSITE_ADDRESSING as Zt}from"../lib/website-document-addressing.js";import{PreviewTickerProvider as qt}from"../../render/components/PreviewTickerContext.js";import{PreviewHeroPartProvider as Jt}from"../../render/components/PreviewHeroPartContext.js";import{PreviewPartsProvider as Qt}from"efficient-easel/draw/client";import{CanvasPartsBridge as $t}from"./CanvasPartsBridge.js";import{PreviewLocationPartProvider as er}from"../../render/components/PreviewLocationPartContext.js";import{PreviewPartStyleProvider as tr}from"./PreviewPartStyleContext.js";import{CORNER_STYLE_TO_PX as rr,DEFAULT_HEADING_COMPRESSION as or,DEFAULT_HEADING_TYPOGRAPHY as nr,DEFAULT_SWITCH_SHOWN as R,DEFAULT_SIZES as ir,DEFAULT_THEME_MODE as T,normalizeCornerRadius as ar,normalizeCornerStyle as cr,normalizeCardShadow as sr,normalizeCardGap as dr,normalizeHoverEffect as hr,IDENTITY_CARD_GAP as pe,IDENTITY_CARD_SHADOW as ur,IDENTITY_HOVER_EFFECT as lr,THEME_MODE_KEY as Se,THEME_STORAGE_KEY as mr,THEME_SWITCH_HIDE as fe,THEME_SWITCH_KEY as B}from"../../format/lib/theme.js";import{pictureShadowColor as pr}from"efficient-easel/screen/lib/document/shadow-values";import{DEFAULT_FONTS as Sr}from"../../format/lib/fonts.js";import{WEBSITE_SCREEN as fr}from"./WebsiteScreenParts.js";import{routeWebsiteHostMessage as gr}from"../../format/lib/website-host-inbound.js";import{siteTextFromRow as wr}from"../../render/lib/text-styles/site-text-styles.js";import{wordStylesFromRow as Cr}from"../../format/lib/word-styles.js";import{chatPreviewFrom as _r}from"./PreviewChatContext.js";const Pr=()=>{if(typeof window>"u")return T;try{const s=window.localStorage.getItem(Se);return s==="light"||s==="dark"||s==="auto"?s:T}catch{return T}},ge=s=>{if(!(typeof window>"u"))try{window.localStorage.setItem(Se,s)}catch{}},Tr=()=>{if(typeof window>"u")return R;try{return window.localStorage.getItem(B)!==fe}catch{return R}},Er=()=>{if(!(typeof window>"u"))try{window.localStorage.removeItem(mr)}catch{}},we=s=>{if(!(typeof window>"u"))try{s?window.localStorage.removeItem(B):window.localStorage.setItem(B,fe)}catch{}};function yr(){const{adapter:s,capabilities:d,templateId:F,ready:_,token:u,siteId:a,currentSlug:I,currentKind:b}=Ot();f(()=>(ue(I,b),()=>ue(null,null)),[I,b]);const E=d.placeholderFrames,[Ce,D]=r(null),[_e,M]=r("");f(()=>{const e=s.templateName;if(!_||!F||!e){M("");return}let i=!1;return e().then(l=>!i&&M(l??"")).catch(()=>{}),()=>{i=!0}},[_,u,F,s]);const[Pe,y]=r(T),[Te,G]=r(R),[N,O]=r({value:{selected:0,themes:[]},readFor:null}),Ee=N.value,[ye,x]=r(Sr),[Ge,U]=r(ir),[ve,A]=r(null),[ke,L]=r(or),[We,z]=r(null),[He,Y]=r(null),[Re,j]=r(pe),[Be,K]=r(null),[Fe,V]=r(null),[Ie,X]=r(null),[be,Z]=r(null),[v,q]=r(null),[k,J]=r(null),[De,Q]=r({}),Me=o(e=>Q(i=>({...i,...e})),[]),h=vt(),$=he(()=>_t(Tt(h),Gt(h)),[h]),Ne=he(()=>kt(Wt($,E),v,k),[$,E,v,k]),[Oe,ee]=r(nr),[xe,te]=r(null),[Ue,re]=r(null),[Ae,oe]=r(null),[Le,ne]=r(null),[ze,ie]=r(null),ae=g(null),n=g(!1);f(()=>{y(Pr()),G(Tr())},[]);const Ye=o(e=>{n.current=!0,Er(),ge(e),y(e)},[]),je=o(e=>{n.current=!0,we(e),G(e)},[]),Ke=o(e=>{n.current=!0,O(i=>At(i,e,a??""))},[a]),Ve=o(e=>{n.current=!0,x(e)},[]),Xe=o(e=>{n.current=!0,U(e)},[]),Ze=o(e=>{n.current=!0,A(e)},[]),qe=o(e=>{n.current=!0,L(e)},[]),Je=o(e=>{n.current=!0,z(e)},[]),Qe=o(e=>{n.current=!0,Y(e)},[]),$e=o(e=>{n.current=!0,j(e)},[]),et=o(e=>{n.current=!0,K(e)},[]),tt=o(e=>{n.current=!0,ee(e)},[]),[rt,ce]=r(null),[ot,nt]=r(null),it=o(e=>{n.current=!0,ce(e)},[]),at=o(e=>{n.current=!0,V(e)},[]),ct=o(e=>{n.current=!0,X(e)},[]),st=o(e=>{n.current=!0,Z(e)},[]),dt=o(e=>{n.current=!0,q(e)},[]),ht=o(e=>{n.current=!0,J(e)},[]),ut=o(e=>{n.current=!0,te(e)},[]),lt=o(e=>{n.current=!0,re(e)},[]),mt=o(e=>{n.current=!0,oe(e)},[]),pt=o(e=>{n.current=!0,ne(e)},[]),St=o(e=>{n.current=!0,ie(e)},[]);f(()=>{const e=H(h).theme;if(!u||!d.hasSiteTheme||!e)return;const i=a??"";ae.current!==i&&(ae.current=i,n.current=!1);let l=!1;return e.get(a?{siteId:a}:void 0).then(t=>{if(l||n.current)return;ge(t.default_mode),we(t.show_theme_switch),y(t.default_mode),G(t.show_theme_switch),O(Lt({selected:t.selected_preset,themes:t.theme_presets},i));const C=wr(t);x(C.fonts),U(C.sizes);const S=bt(t);Q(S),A(t.corner_radius_px===void 0?rr[cr(t.corner_style)]:w(t.corner_radius_px,S.cornerRadiusUnit,ar)),L(C.compression),z(t.card_shadow==null?ur:sr(t.card_shadow)),j(t.card_gap==null?pe:dr(t.card_gap)),K(t.hover_effect==null?lr:hr(t.hover_effect)),Y(pr(t.shadow_color)),V(w(t.site_width,S.siteWidthUnit,It)),X(w(t.site_gutter,S.siteGutterUnit,Bt)),Z(w(t.site_gutter_phone,S.siteGutterPhoneUnit,Ft)),q(w(t.block_gap,S.blockGapUnit,me)),J(w(t.block_gap_phone,S.blockGapPhoneUnit,me)),ee(C.typography),ce(C.textStyles),nt(Cr(t)),te(t.hero_background_follows_width===!0),re(le(t.section_background_width)),oe(le(t.section_content_width)),ne(t.photography_grayscale===!0),ie(t.share_button_on_posts===!0)}).catch(()=>{}),()=>{l=!0}},[u,a,d.hasSiteTheme,h]);const ft=Vt({token:u,siteId:a,enabled:d.hasSiteSettings}),[gt,se]=r(jt),de=g(null),W=g(!1),m=g(null),p=g({}),P=o(async()=>{m.current&&clearTimeout(m.current),m.current=null;const e=p.current;p.current={};try{await H(h).chat?.update(e,a?{siteId:a}:void 0),Et()}catch(i){throw p.current={...e,...p.current},i}},[h,a]);f(()=>yt(()=>m.current||Object.keys(p.current).length>0?P():void 0),[P]);const wt=o(e=>{W.current=!0,se(i=>({...i,...e})),!(!d.hasSiteSettings||!u)&&(p.current={...p.current,...e},m.current&&clearTimeout(m.current),m.current=setTimeout(()=>{P().catch(()=>{})},500))},[d.hasSiteSettings,u,P]);return f(()=>{if(!u||!d.hasSiteSettings)return;const e=a??"";de.current!==e&&(de.current=e,W.current=!1);let i=!1;const l=H(h).chat;if(l)return l.get(a?{siteId:a}:void 0).then(t=>{i||W.current||se(_r(t))}).catch(()=>{}),()=>{i=!0}},[u,a,d.hasSiteSettings,h]),f(()=>{const e=s.site;if(!_||!d.hasSiteRecord||!e){D(null);return}let i=!1;return e().then(l=>{i||D(Rt(l.name))}).catch(()=>{}),()=>{i=!0}},[_,u,d.hasSiteRecord,a,s]),c(Mt,{config:Ne,parts:fr,wrap:(e,i)=>c(xt,{websiteName:Ce,templateChrome:E,templateName:_e||null,themeMode:Pe,onThemeModeChange:Ye,themeSwitchShown:Te,onThemeSwitchShownChange:je,theme:Ee,themeRow:Ut(d.hasSiteTheme,N.readFor,a??""),onThemeChange:Ke,fonts:ye,onFontsChange:Ve,cornerRadiusPx:ve,onCornerRadiusPxChange:Ze,cardShadow:We,onCardShadowChange:Je,shadowColor:He,onShadowColorChange:Qe,cardGap:Re,onCardGapChange:$e,hoverEffect:Be,onHoverEffectChange:et,headingCompression:ke,onHeadingCompressionChange:qe,headingTypography:Oe,onHeadingTypographyChange:tt,textStyles:rt,onTextStylesChange:it,wordStyles:ot,sizes:Ge,onSizesChange:Xe,siteWidth:Fe,onSiteWidthChange:at,siteGutter:Ie,onSiteGutterChange:ct,siteGutterPhone:be,onSiteGutterPhoneChange:st,blockGap:v,onBlockGapChange:dt,blockGapPhone:k,onBlockGapPhoneChange:ht,siteLengthUnits:De,onSiteLengthUnitsChange:Me,heroBackgroundFollowsWidth:xe,onHeroBackgroundFollowsWidthChange:ut,sectionBackgroundWidth:Ue,onSectionBackgroundWidthChange:lt,sectionContentWidth:Ae,onSectionContentWidthChange:mt,photographyGrayscale:Le,onPhotographyGrayscaleChange:pt,shareButtonOnPosts:ze,onShareButtonOnPostsChange:St,themeFromDocument:!d.hasSiteTheme,children:c(zt,{children:c(Pt,{wrap:h.chrome?.wrap,surface:"page",children:c(qt,{children:c(Jt,{children:c(Qt,{children:c(er,{children:c($t,{children:Ct(tr,{children:[c(Yt,{chat:gt,onChatChange:wt,children:c(Kt,{value:ft,children:c(Xt,{children:c(Ht,{children:c(Nt,{children:e})})})})}),i]})})})})})})})})})})}function Gr({target:s}){return c(Dt,{target:s,addressing:Zt,onHostMessage:gr,children:c(yr,{})})}export{Gr as default};
1
+ "use client";import{jsx as c,jsxs as wt}from"react/jsx-runtime";import{useCallback as o,useEffect as f,useMemo as Ct,useRef as g,useState as r}from"react";import"efficient-easel/easel.css";import"efficient-easel/shell.css";import"efficient-easel/rail.css";import"efficient-easel/panel.css";import"efficient-easel/fields.css";import"efficient-easel/pick.css";import"efficient-easel/copy.css";import"efficient-easel/gold.css";import"efficient-easel/text-styles.css";import"efficient-easel/menu.css";import"efficient-easel/chrome.css";import"efficient-easel/tree.css";import"efficient-easel/drag.css";import"efficient-easel/screen.css";import"./storefront-editor.css";import{useHostConfig as _t}from"../lib/document/host-config.js";import{ChromeWrap as Pt}from"efficient-easel/screen/lib/host-chrome";import{refreshSiteLiveState as Tt}from"../lib/site-live-state.js";import{holdSiteWrites as Et}from"../../format/lib/site-writes.js";import{backendOf as W}from"../lib/website-session.js";import{useEaselSession as yt}from"efficient-easel/screen/lib/session-context";import{withSiteBlockGapFields as Gt}from"../../format/lib/document/site-gap-fields.js";import{withTemplateMediaPlaceholders as vt}from"../../format/lib/document/templateFields.js";import{setEditorPage as he}from"../../format/lib/document/editor-page-context.js";import{EditorPagePathProvider as kt}from"./EditorPagePathProvider.js";import{resolveSiteName as Ht}from"../../format/lib/content/site-name.js";import{normalizeSiteGutter as Wt,normalizeSiteGutterPhone as Bt,normalizeSiteWidth as Rt}from"../../format/lib/content/page-width.js";import{siteLengthNumber as w,siteLengthUnitsOfRow as Ft}from"../../format/lib/content/css-length.js";import{normalizeSiteBackground as ue}from"../../format/lib/content/section-width.js";import{normalizeSiteBlockGap as le}from"../../format/lib/content/container-gap.js";import It,{DocumentScreen as Dt}from"efficient-easel/screen/components/ScreenMount";import bt from"./WebsiteHintsProvider.js";import{useScreenDocument as Mt}from"efficient-easel/screen/components/ScreenDocumentContext";import{PreviewHeaderProvider as Nt,siteThemeRow as xt,themeEdited as Ot,themeSeeded as Ut}from"../../render/components/PreviewHeaderContext.js";import{PreviewFooterProvider as At}from"./PreviewFooterContext.js";import{PreviewChatProvider as Lt,DEFAULT_CHAT_PREVIEW as zt}from"./PreviewChatContext.js";import{PreviewSocialProvider as Yt}from"../../render/components/PreviewSocialContext.js";import{useSocialSettings as jt}from"./useSocialSettings.js";import{PreviewSurfaceProvider as Kt}from"./PreviewSurfaceContext.js";import{WEBSITE_ADDRESSING as Vt}from"../lib/website-document-addressing.js";import{PreviewTickerProvider as Xt}from"../../render/components/PreviewTickerContext.js";import{PreviewHeroPartProvider as Zt}from"../../render/components/PreviewHeroPartContext.js";import{PreviewPartsProvider as qt}from"efficient-easel/draw/client";import{CanvasPartsBridge as Jt}from"./CanvasPartsBridge.js";import{PreviewLocationPartProvider as Qt}from"../../render/components/PreviewLocationPartContext.js";import{PreviewPartStyleProvider as $t}from"./PreviewPartStyleContext.js";import{CORNER_STYLE_TO_PX as er,DEFAULT_HEADING_COMPRESSION as tr,DEFAULT_HEADING_TYPOGRAPHY as rr,DEFAULT_SWITCH_SHOWN as B,DEFAULT_SIZES as or,DEFAULT_THEME_MODE as T,normalizeCornerRadius as nr,normalizeCornerStyle as ir,normalizeCardShadow as ar,normalizeCardGap as cr,normalizeHoverEffect as sr,IDENTITY_CARD_GAP as me,IDENTITY_CARD_SHADOW as dr,IDENTITY_HOVER_EFFECT as hr,THEME_MODE_KEY as pe,THEME_STORAGE_KEY as ur,THEME_SWITCH_HIDE as Se,THEME_SWITCH_KEY as R}from"../../format/lib/theme.js";import{pictureShadowColor as lr}from"efficient-easel/screen/lib/document/shadow-values";import{DEFAULT_FONTS as mr}from"../../format/lib/fonts.js";import{WEBSITE_SCREEN as pr}from"./WebsiteScreenParts.js";import{routeWebsiteHostMessage as Sr}from"../../format/lib/website-host-inbound.js";import{siteTextFromRow as fr}from"../../render/lib/text-styles/site-text-styles.js";import{wordStylesFromRow as gr}from"../../format/lib/word-styles.js";import{chatPreviewFrom as wr}from"./PreviewChatContext.js";const Cr=()=>{if(typeof window>"u")return T;try{const s=window.localStorage.getItem(pe);return s==="light"||s==="dark"||s==="auto"?s:T}catch{return T}},fe=s=>{if(!(typeof window>"u"))try{window.localStorage.setItem(pe,s)}catch{}},_r=()=>{if(typeof window>"u")return B;try{return window.localStorage.getItem(R)!==Se}catch{return B}},Pr=()=>{if(!(typeof window>"u"))try{window.localStorage.removeItem(ur)}catch{}},ge=s=>{if(!(typeof window>"u"))try{s?window.localStorage.removeItem(R):window.localStorage.setItem(R,Se)}catch{}};function Tr(){const{adapter:s,capabilities:d,templateId:F,ready:_,token:h,siteId:a,currentSlug:I,currentKind:D}=Mt();f(()=>(he(I,D),()=>he(null,null)),[I,D]);const E=d.placeholderFrames,[we,b]=r(null),[Ce,M]=r("");f(()=>{const e=s.templateName;if(!_||!F||!e){M("");return}let i=!1;return e().then(u=>!i&&M(u??"")).catch(()=>{}),()=>{i=!0}},[_,h,F,s]);const[_e,y]=r(T),[Pe,G]=r(B),[N,x]=r({value:{selected:0,themes:[]},readFor:null}),Te=N.value,[Ee,O]=r(mr),[ye,U]=r(or),[Ge,A]=r(null),[ve,L]=r(tr),[ke,z]=r(null),[He,Y]=r(null),[We,j]=r(me),[Be,K]=r(null),[Re,V]=r(null),[Fe,X]=r(null),[Ie,Z]=r(null),[v,q]=r(null),[k,J]=r(null),[De,Q]=r({}),be=o(e=>Q(i=>({...i,...e})),[]),l=yt(),$=_t(),Me=Ct(()=>Gt(vt($,E),v,k),[$,E,v,k]),[Ne,ee]=r(rr),[xe,te]=r(null),[Oe,re]=r(null),[Ue,oe]=r(null),[Ae,ne]=r(null),[Le,ie]=r(null),ae=g(null),n=g(!1);f(()=>{y(Cr()),G(_r())},[]);const ze=o(e=>{n.current=!0,Pr(),fe(e),y(e)},[]),Ye=o(e=>{n.current=!0,ge(e),G(e)},[]),je=o(e=>{n.current=!0,x(i=>Ot(i,e,a??""))},[a]),Ke=o(e=>{n.current=!0,O(e)},[]),Ve=o(e=>{n.current=!0,U(e)},[]),Xe=o(e=>{n.current=!0,A(e)},[]),Ze=o(e=>{n.current=!0,L(e)},[]),qe=o(e=>{n.current=!0,z(e)},[]),Je=o(e=>{n.current=!0,Y(e)},[]),Qe=o(e=>{n.current=!0,j(e)},[]),$e=o(e=>{n.current=!0,K(e)},[]),et=o(e=>{n.current=!0,ee(e)},[]),[tt,ce]=r(null),[rt,ot]=r(null),nt=o(e=>{n.current=!0,ce(e)},[]),it=o(e=>{n.current=!0,V(e)},[]),at=o(e=>{n.current=!0,X(e)},[]),ct=o(e=>{n.current=!0,Z(e)},[]),st=o(e=>{n.current=!0,q(e)},[]),dt=o(e=>{n.current=!0,J(e)},[]),ht=o(e=>{n.current=!0,te(e)},[]),ut=o(e=>{n.current=!0,re(e)},[]),lt=o(e=>{n.current=!0,oe(e)},[]),mt=o(e=>{n.current=!0,ne(e)},[]),pt=o(e=>{n.current=!0,ie(e)},[]);f(()=>{const e=W(l).theme;if(!h||!d.hasSiteTheme||!e)return;const i=a??"";ae.current!==i&&(ae.current=i,n.current=!1);let u=!1;return e.get(a?{siteId:a}:void 0).then(t=>{if(u||n.current)return;fe(t.default_mode),ge(t.show_theme_switch),y(t.default_mode),G(t.show_theme_switch),x(Ut({selected:t.selected_preset,themes:t.theme_presets},i));const C=fr(t);O(C.fonts),U(C.sizes);const S=Ft(t);Q(S),A(t.corner_radius_px===void 0?er[ir(t.corner_style)]:w(t.corner_radius_px,S.cornerRadiusUnit,nr)),L(C.compression),z(t.card_shadow==null?dr:ar(t.card_shadow)),j(t.card_gap==null?me:cr(t.card_gap)),K(t.hover_effect==null?hr:sr(t.hover_effect)),Y(lr(t.shadow_color)),V(w(t.site_width,S.siteWidthUnit,Rt)),X(w(t.site_gutter,S.siteGutterUnit,Wt)),Z(w(t.site_gutter_phone,S.siteGutterPhoneUnit,Bt)),q(w(t.block_gap,S.blockGapUnit,le)),J(w(t.block_gap_phone,S.blockGapPhoneUnit,le)),ee(C.typography),ce(C.textStyles),ot(gr(t)),te(t.hero_background_follows_width===!0),re(ue(t.section_background_width)),oe(ue(t.section_content_width)),ne(t.photography_grayscale===!0),ie(t.share_button_on_posts===!0)}).catch(()=>{}),()=>{u=!0}},[h,a,d.hasSiteTheme,l]);const St=jt({token:h,siteId:a,enabled:d.hasSiteSettings}),[ft,se]=r(zt),de=g(null),H=g(!1),m=g(null),p=g({}),P=o(async()=>{m.current&&clearTimeout(m.current),m.current=null;const e=p.current;p.current={};try{await W(l).chat?.update(e,a?{siteId:a}:void 0),Tt()}catch(i){throw p.current={...e,...p.current},i}},[l,a]);f(()=>Et(()=>m.current||Object.keys(p.current).length>0?P():void 0),[P]);const gt=o(e=>{H.current=!0,se(i=>({...i,...e})),!(!d.hasSiteSettings||!h)&&(p.current={...p.current,...e},m.current&&clearTimeout(m.current),m.current=setTimeout(()=>{P().catch(()=>{})},500))},[d.hasSiteSettings,h,P]);return f(()=>{if(!h||!d.hasSiteSettings)return;const e=a??"";de.current!==e&&(de.current=e,H.current=!1);let i=!1;const u=W(l).chat;if(u)return u.get(a?{siteId:a}:void 0).then(t=>{i||H.current||se(wr(t))}).catch(()=>{}),()=>{i=!0}},[h,a,d.hasSiteSettings,l]),f(()=>{const e=s.site;if(!_||!d.hasSiteRecord||!e){b(null);return}let i=!1;return e().then(u=>{i||b(Ht(u.name))}).catch(()=>{}),()=>{i=!0}},[_,h,d.hasSiteRecord,a,s]),c(Dt,{config:Me,parts:pr,wrap:(e,i)=>c(Nt,{websiteName:we,templateChrome:E,templateName:Ce||null,themeMode:_e,onThemeModeChange:ze,themeSwitchShown:Pe,onThemeSwitchShownChange:Ye,theme:Te,themeRow:xt(d.hasSiteTheme,N.readFor,a??""),onThemeChange:je,fonts:Ee,onFontsChange:Ke,cornerRadiusPx:Ge,onCornerRadiusPxChange:Xe,cardShadow:ke,onCardShadowChange:qe,shadowColor:He,onShadowColorChange:Je,cardGap:We,onCardGapChange:Qe,hoverEffect:Be,onHoverEffectChange:$e,headingCompression:ve,onHeadingCompressionChange:Ze,headingTypography:Ne,onHeadingTypographyChange:et,textStyles:tt,onTextStylesChange:nt,wordStyles:rt,sizes:ye,onSizesChange:Ve,siteWidth:Re,onSiteWidthChange:it,siteGutter:Fe,onSiteGutterChange:at,siteGutterPhone:Ie,onSiteGutterPhoneChange:ct,blockGap:v,onBlockGapChange:st,blockGapPhone:k,onBlockGapPhoneChange:dt,siteLengthUnits:De,onSiteLengthUnitsChange:be,heroBackgroundFollowsWidth:xe,onHeroBackgroundFollowsWidthChange:ht,sectionBackgroundWidth:Oe,onSectionBackgroundWidthChange:ut,sectionContentWidth:Ue,onSectionContentWidthChange:lt,photographyGrayscale:Ae,onPhotographyGrayscaleChange:mt,shareButtonOnPosts:Le,onShareButtonOnPostsChange:pt,themeFromDocument:!d.hasSiteTheme,children:c(At,{children:c(Pt,{wrap:l.chrome?.wrap,surface:"page",children:c(Xt,{children:c(Zt,{children:c(qt,{children:c(Qt,{children:c(Jt,{children:wt($t,{children:[c(Lt,{chat:ft,onChatChange:gt,children:c(Yt,{value:St,children:c(Kt,{children:c(kt,{children:c(bt,{children:e})})})})}),i]})})})})})})})})})})}function Er({target:s}){return c(It,{target:s,addressing:Vt,onHostMessage:Sr,children:c(Tr,{})})}export{Er as default};
@@ -1685,6 +1685,77 @@
1685
1685
  .sf-pages > .sf-note--error {
1686
1686
  margin-top: var(--space-4);
1687
1687
  }
1688
+ /* ── The Add page window (components/AddPageWindow) ─────────────────────────
1689
+ The window, its head, the list down the left and the grid are the shell's
1690
+ (Dialog `full`, SidebarLayout, Grid); what is left is the main area's inset,
1691
+ its two lines of words, the gap above "From your template", and the card.
1692
+ The window is portalled to <body>, outside the screen's `.sf-editor` scope,
1693
+ so it reads the shell's own root tokens (`--ink*`, `--line`). */
1694
+ .sf-add-page {
1695
+ padding: var(--space-32) var(--space-48);
1696
+ }
1697
+ .sf-add-page-title {
1698
+ margin: 0;
1699
+ font-size: var(--text-xl);
1700
+ font-weight: 600;
1701
+ color: var(--ink-strongest);
1702
+ }
1703
+ /* The heading takes the window's first focus (initialFocus), so a mouse open
1704
+ draws no ring on "+ Blank page". It is not a control: no ring of its own. */
1705
+ .sf-add-page-title:focus {
1706
+ outline: none;
1707
+ }
1708
+ /* The list's rows on the same side gutter as "+ Blank page" above them, so the
1709
+ selected row's fill and the button line up. */
1710
+ .sf-add-page-nav {
1711
+ padding: 0 var(--space-8);
1712
+ }
1713
+ .sf-add-page-sub {
1714
+ margin: var(--space-8) 0 var(--space-32);
1715
+ font-size: var(--text-sm);
1716
+ color: var(--ink);
1717
+ }
1718
+ .sf-add-page-group {
1719
+ margin-top: var(--space-32);
1720
+ }
1721
+ /* One card: the picture, then its name. The picture is a live drawing in its
1722
+ own frame, inert; "Add page" lies over it on hover or keyboard focus. */
1723
+ .sf-starter {
1724
+ display: flex;
1725
+ flex-direction: column;
1726
+ gap: var(--space-12);
1727
+ }
1728
+ .sf-starter-picture {
1729
+ position: relative;
1730
+ overflow: hidden;
1731
+ border: 1px solid var(--line);
1732
+ border-radius: var(--radius-sm);
1733
+ }
1734
+ .sf-starter-frame {
1735
+ pointer-events: none;
1736
+ }
1737
+ /* The card's frame is a picture inside a bordered card: no floating shadow of
1738
+ the canvas's own (efficient-easel `.es-canvas-frame`). */
1739
+ .sf-starter-frame .es-canvas-frame {
1740
+ box-shadow: none;
1741
+ }
1742
+ .sf-starter-add {
1743
+ position: absolute;
1744
+ inset: 0;
1745
+ display: flex;
1746
+ align-items: center;
1747
+ justify-content: center;
1748
+ opacity: 0;
1749
+ transition: opacity 0.12s;
1750
+ }
1751
+ .sf-starter:hover .sf-starter-add,
1752
+ .sf-starter:focus-within .sf-starter-add {
1753
+ opacity: 1;
1754
+ }
1755
+ .sf-starter-name {
1756
+ font-size: var(--text-sm);
1757
+ color: var(--ink-strongest);
1758
+ }
1688
1759
  /* `.sf-pgroup*` and `.sf-prow` WERE HERE: the Pages headings are the shell's
1689
1760
  `TreeGroupLabel` (its count pill and fold), its rows the shell's `TreeRow`. */
1690
1761
  /* `.sf-page-draft`, `.sf-badge-dynamic` and `.sf-badge-lightbox` WERE HERE: a
@@ -1,2 +1,2 @@
1
- export declare const assembleGeneralBlocks: () => Record<"Hero" | "IntroBleed" | "ProcessSteps" | "OrderSummary" | "Footprint" | "Cards" | "Stats" | "Chart" | "Mockup" | "Countdown" | "FeaturedCover" | "LongRead" | "Breadcrumb" | "DocBody" | "FAQ" | "SectionHeader" | "Flex" | "Divider" | "CustomHTML" | "Manifesto" | "Split" | "Ticker" | "SpecStrip" | "TimelineTrack" | "Timeline" | "Logos" | "DocMasthead" | "DocTabs" | "Prose" | "ParagraphsA" | "TitleWithButtons" | "Banner" | "CategoryBar" | "Masthead" | "Grid" | "Spacer" | "KeyFeatures" | "Series" | "DocMetaCards" | "StatsParagraph" | "Testimonials" | "Integrations" | "HeroSingle" | "ContactLocations" | "PaymentBadges" | "Heading" | "Text" | "Eyebrow" | "ImageBlock" | "LogoBlock" | "LocationMap" | "Contents" | "ListSearch" | "ButtonBlock" | "CardList" | "HostPart" | "PostCard" | "HeroSlide" | "HeroGroup", import("efficient-easel/blocks").ComponentConfig<any, any, Omit<import("efficient-easel/blocks").ComponentData<any, string, Record<string, import("efficient-easel/blocks").DefaultComponentProps>>, "type">>>;
2
- export declare const generalBlocks: Record<"Hero" | "IntroBleed" | "ProcessSteps" | "OrderSummary" | "Footprint" | "Cards" | "Stats" | "Chart" | "Mockup" | "Countdown" | "FeaturedCover" | "LongRead" | "Breadcrumb" | "DocBody" | "FAQ" | "SectionHeader" | "Flex" | "Divider" | "CustomHTML" | "Manifesto" | "Split" | "Ticker" | "SpecStrip" | "TimelineTrack" | "Timeline" | "Logos" | "DocMasthead" | "DocTabs" | "Prose" | "ParagraphsA" | "TitleWithButtons" | "Banner" | "CategoryBar" | "Masthead" | "Grid" | "Spacer" | "KeyFeatures" | "Series" | "DocMetaCards" | "StatsParagraph" | "Testimonials" | "Integrations" | "HeroSingle" | "ContactLocations" | "PaymentBadges" | "Heading" | "Text" | "Eyebrow" | "ImageBlock" | "LogoBlock" | "LocationMap" | "Contents" | "ListSearch" | "ButtonBlock" | "CardList" | "HostPart" | "PostCard" | "HeroSlide" | "HeroGroup", import("efficient-easel/blocks").ComponentConfig<any, any, Omit<import("efficient-easel/blocks").ComponentData<any, string, Record<string, import("efficient-easel/blocks").DefaultComponentProps>>, "type">>>;
1
+ export declare const assembleGeneralBlocks: () => Record<"CardList" | "Text" | "ImageBlock" | "ButtonBlock" | "Flex" | "Cards" | "FAQ" | "Footprint" | "Grid" | "Hero" | "HeroGroup" | "HeroSingle" | "HeroSlide" | "Logos" | "LogoBlock" | "OrderSummary" | "ProcessSteps" | "IntroBleed" | "Stats" | "Chart" | "Mockup" | "Countdown" | "FeaturedCover" | "LongRead" | "Breadcrumb" | "DocBody" | "SectionHeader" | "Divider" | "CustomHTML" | "Manifesto" | "Split" | "Ticker" | "SpecStrip" | "TimelineTrack" | "Timeline" | "DocMasthead" | "DocTabs" | "Prose" | "ParagraphsA" | "TitleWithButtons" | "Banner" | "CategoryBar" | "Masthead" | "Spacer" | "KeyFeatures" | "Series" | "DocMetaCards" | "StatsParagraph" | "Testimonials" | "Integrations" | "ContactLocations" | "PaymentBadges" | "Heading" | "Eyebrow" | "LocationMap" | "Contents" | "ListSearch" | "HostPart" | "PostCard", import("efficient-easel/blocks").ComponentConfig<any, any, Omit<import("efficient-easel/blocks").ComponentData<any, string, Record<string, import("efficient-easel/blocks").DefaultComponentProps>>, "type">>>;
2
+ export declare const generalBlocks: Record<"CardList" | "Text" | "ImageBlock" | "ButtonBlock" | "Flex" | "Cards" | "FAQ" | "Footprint" | "Grid" | "Hero" | "HeroGroup" | "HeroSingle" | "HeroSlide" | "Logos" | "LogoBlock" | "OrderSummary" | "ProcessSteps" | "IntroBleed" | "Stats" | "Chart" | "Mockup" | "Countdown" | "FeaturedCover" | "LongRead" | "Breadcrumb" | "DocBody" | "SectionHeader" | "Divider" | "CustomHTML" | "Manifesto" | "Split" | "Ticker" | "SpecStrip" | "TimelineTrack" | "Timeline" | "DocMasthead" | "DocTabs" | "Prose" | "ParagraphsA" | "TitleWithButtons" | "Banner" | "CategoryBar" | "Masthead" | "Spacer" | "KeyFeatures" | "Series" | "DocMetaCards" | "StatsParagraph" | "Testimonials" | "Integrations" | "ContactLocations" | "PaymentBadges" | "Heading" | "Eyebrow" | "LocationMap" | "Contents" | "ListSearch" | "HostPart" | "PostCard", import("efficient-easel/blocks").ComponentConfig<any, any, Omit<import("efficient-easel/blocks").ComponentData<any, string, Record<string, import("efficient-easel/blocks").DefaultComponentProps>>, "type">>>;
@@ -3,7 +3,7 @@ import { boxFieldBuilders, type BoxFieldSay } from "efficient-easel/screen/lib/d
3
3
  import type { ShowWhenRule } from "efficient-shell/format";
4
4
  type Rows = ReturnType<typeof boxFieldBuilders>;
5
5
  export declare const rowSay: BoxFieldSay;
6
- export declare const LENGTH_UNITS_TABLE: Readonly<Record<"border" | "spacing" | "gap" | "size" | "radius" | "fontSize" | "letterSpacing" | "position" | "height" | "breakpoint", readonly ("%" | "px" | "vw")[]>>;
6
+ export declare const LENGTH_UNITS_TABLE: Readonly<Record<"size" | "spacing" | "gap" | "radius" | "fontSize" | "letterSpacing" | "position" | "border" | "height" | "breakpoint", readonly ("px" | "%" | "vw")[]>>;
7
7
  export declare const slider: Rows["slider"];
8
8
  export declare const select: Rows["select"];
9
9
  export declare const Segmented: Rows["Segmented"];
@@ -1 +1 @@
1
- import{anchorFields as E,bucketHeader as w,cardMediaFields as W,cardShowFields as z,designGroupHeader as $,foldMarker as J,foldMetaOf as C,quietMarker as q,heightFields as O,sectionShapeFields as D,sectionThemeFields as T,stickFields as H,widthField as B}from"./controls.js";import{group as Q}from"efficient-easel/screen/lib/document/box-fields";import{sidesPaddingFields as A}from"./box-fields.js";import{deviceField as V,deviceMetaOf as K}from"efficient-easel/screen/lib/document/device-fields";import{entranceFields as F}from"../animation/entrance-fields.js";import{DESIGN_GROUPS as _,SETTINGS_BUCKETS as X}from"efficient-easel/panel";import{BUCKET_KEY as l,DESIGN_GROUP_KEY as g}from"efficient-easel/screen/lib/document/field-buckets";import{ownEntry as p,hasOwnEntry as M}from"../../../format/lib/own-entry.js";const R=X;function Z(n){return n==="Animation"?"Animation":"Design"}const ee="Editor only — not shown live",x={"Archive link":"Content",Article:"Content",Blocks:"Content","Blog posts":"Content","Browser mock":"Content",Button:"Content","Call to action":"Content","Car prompt":"Content","Card link":"Content","Card list":"Content",Cards:"Content","Claims bars":"Content","Contact info":"Content",Content:"Content",Display:"Content","Content source":"Content",Contents:"Content",Filters:"Content","Show on a card":"Content",Footnote:"Content",Form:"Content",Founders:"Content","Gallery A":"Content","Gallery B":"Content","Gallery link":"Content",Header:"Content","Header link":"Content","Image caption":"Content","In this issue":"Content",Items:"Content","Kanban columns":"Content",Lead:"Content","Left panel":"Content",Link:"Content",Links:"Content",List:"Content","Message form":"Content",Metadata:"Content",Milestones:"Content","Mockup card":"Content","Newsletter panel":"Content",Offices:"Content",Options:"Content","Others gallery":"Content","Overlay button":"Content",Product:"Content","Product page":"Content",Products:"Content","Pull quote":"Content",Questions:"Content","Recent issues":"Content","Recent posts":"Content",Reviews:"Content","Right panel · actions":"Content","Right panel · choices":"Content","Right panel · form":"Content","Routing groups":"Content",Rows:"Content",Section:"Content","Section header":"Content",Sections:"Content","Signup form":"Content",Source:"Content","Source product":"Content","Stat & note":"Content",Stats:"Content","Submit button":"Content","Success state":"Content",Wheel:"Content",Terminal:"Content",Text:"Content","Text column":"Content","Timeline entries":"Content","Top row":"Content",Total:"Content","Trailing note":"Content","“Other” reason":"Content","Background images":"Design",Gallery:"Content",Image:"Content","Image column":"Content",Images:"Content",Logo:"Content",Map:"Content",Media:"Content","Background image":"Design",Color:"Design","Image tint":"Design",Style:"Design",Shape:"Design",Shadow:"Design",Texture:"Design",Overlay:"Design","Text style":"Design",Entrance:"Animation",Hover:"Animation",Loop:"Animation",Scroll:"Animation",Anchor:"Anchor",Arrangement:"Layout","Auto-slide":"Layout",Bar:"Layout","Cell size":"Size",Behavior:"Layout",Schedule:"Layout",Controls:"Layout",Diagram:"Layout",[ee]:"Layout","Filters shown":"Layout","Slide picker":"Layout",Arrows:"Layout","On a phone":"Layout",Placement:"Position",Nudge:"Position","Stick to top":"Position","Image gallery":"Layout",Grid:"Layout",Layout:"Layout",Padding:"Layout",Price:"Layout",Preview:"Layout",Setup:"Layout","Show / hide elements":"Layout","Show in the buy box":"Layout",Visibility:"Layout",Width:"Size",Size:"Size",Height:"Size"},j={"AlloyWheelsListing._gCards":"Design","Flex._gLink":"Link"},N={"Text._gSpacing":"Size","Heading._gSpacing":"Size"};function I(n,e,o){const i=`${n}.${e}`;return p(N,i)??p(j,i)??p(x,o)}function pe(n,e,o){const i=I(n,e,o);return i?Z(i):void 0}function te(n){return n==="Animation"?[l.Animation]:[l.Design,g[n]]}function v(...n){const e=[];for(const o of n)for(const i of Object.values(o)){const s=K(i),h=C(s?s.inner:i),u=h?p(x,h.label):void 0;if(u)for(const y of te(u))e.includes(y)||e.push(y)}return e}const ye=[...v(A({tablet:!0,siteSide:!0}),B("full"),O(),E(),H()),...Object.keys(A({tablet:!0,siteSide:!0})),...Object.keys(B("full")),...Object.keys(O()),...Object.keys(E()),...Object.keys(H())],ke=[...v(T()),...Object.keys(T())],Se=[...v(D()),...Object.keys(D())],_e=[...v(F()),...Object.keys(F())],ve=Object.keys(W()),fe=Object.keys(z()),ne={"ImageBlock._gStyle":"duplicated the Style bucket header above it (2026-09-04)","ButtonBlock._gStyle":"duplicated the Style bucket header above it (2026-09-04)","HeroGroup._gContent":"duplicated the Content bucket header above it (2026-09-04)","HeroGroup._gLayout":"duplicated the Layout bucket header above it (2026-09-04)","Footer._gLayout":"duplicated the Layout bucket header above it (2026-09-04)","FooterLogo._gContent":"duplicated the Content bucket header above it (2026-09-04)","FooterLogo._gStyle":"duplicated the Style bucket header above it (2026-09-04)","FooterMenu._gContent":"duplicated the Content bucket header above it (2026-09-04)","FooterMenu._gStyle":"duplicated the Style bucket header above it (2026-09-04)","FooterGroup._gLayout":"duplicated the Layout bucket header above it (2026-09-04)","FooterText._gContent":"duplicated the Content bucket header above it (2026-09-04)","FooterText._gStyle":"duplicated the Style bucket header above it (2026-09-04)","FooterSocial._gStyle":"duplicated the Style bucket header above it (born tabbed, 2026-09-17)","FooterSocial._gLayout":"duplicated the Layout bucket header above it (born tabbed, 2026-09-17)","MenuBlock._gContent":"duplicated the Content bucket header above it (born tabbed, H.1)","MenuBlock._gStyle":"duplicated the Style bucket header above it (born tabbed, H.1)","SocialLogosBlock._gStyle":"duplicated the Style bucket header above it (born tabbed, H.1)","SocialLogosBlock._gLayout":"duplicated the Layout bucket header above it (born tabbed, H.1)","SearchBlock._gStyle":"duplicated the Style bucket header above it (born tabbed, H.2)","CartBlock._gStyle":"duplicated the Style bucket header above it (born tabbed, H.2)","CountrySwitchBlock._gStyle":"duplicated the Style bucket header above it (born tabbed with its Show as, 2026-10-17)","Split._gContent":"duplicated the Content bucket header above it (2026-09-04)","Gallery._gVehicleContent":"duplicated the Content bucket header above it (2026-09-04)","Gallery._gWheelContent":"duplicated the Content bucket header above it (2026-09-04)","Gallery._gOthersContent":"duplicated the Content bucket header above it (2026-09-04)","Subscribe._gHeadCopy":"duplicated the Content bucket header above it (2026-09-04)","Subscribe._gLeftCopy":"duplicated the Content bucket header above it (2026-09-04)","Subscribe._gRightCopy":"duplicated the Content bucket header above it (2026-09-04)","CollectionCard._gContent":"duplicated the Content bucket header above it (A Card Sets Its Own Corners)","HeroSlide._gContent":"duplicated the Content bucket header above it (Hero Slide Tabs And Theme)","KeyFeatures._gContent":"duplicated the Content bucket header above it (66049)","KeyFeatures._gStyle":"duplicated the Style bucket header above it (66049)","ParagraphsA._gContent":"duplicated the Content bucket header above it (66049)","Chart._gContent":"duplicated the Content bucket header above it (66049)","Chart._gStyle":"duplicated the Style bucket header above it (66049)","Logos._gContent":"duplicated the Content bucket header above it (66049)","Logos._gStyle":"duplicated the Style bucket header above it (66049)","Mockup._gContent":"duplicated the Content bucket header above it (66049)","Mockup._gStyle":"duplicated the Style bucket header above it (66049)","Stats._gContent":"duplicated the Content bucket header above it (66049)","Stats._gStyle":"duplicated the Style bucket header above it (66049)","StatsParagraph._gContent":"duplicated the Content bucket header above it (66049)","StatsParagraph._gStyle":"duplicated the Style bucket header above it (66049)","Testimonials._gContent":"duplicated the Content bucket header above it (66049)","Testimonials._gStyle":"duplicated the Style bucket header above it (66049)","AppointmentBooking._gContent":"duplicated the Content bucket header above it (66050)","BookingBox._gContent":"duplicated the Content bucket header above it ([SPLIT] Booking Form Into Three Boxes) — the same fault its own section retired in 66050, one level down","FAQ._gContent":"duplicated the Content bucket header above it (66050, family sweep)","FAQ._gLayout":"duplicated the Layout bucket header above it (66050, family sweep)","Form._gContent":"duplicated the Content bucket header above it (66050)","ReviewForm._gContent":"duplicated the Content bucket header above it (66050)","SubmitBuild._gContent":"duplicated the Content bucket header above it (66050)","SubmitBox._gContent":"duplicated the Content bucket header above it ([SPLIT] SubmitBuild Keeps Its Two Columns) — the same fault its own section retired in 66050, one level down","CheckoutCTA._gContent":"duplicated the Content bucket header above it (66051)","CheckoutCTA._gLayout":"duplicated the Layout bucket header above it (66051)","DeliveryOptions._gContent":"duplicated the Content bucket header above it (66051)","DeliveryOptions._gLayout":"duplicated the Layout bucket header above it (66051)","OrderSummary._gContent":"duplicated the Content bucket header above it (66051)","OrderSummary._gLayout":"duplicated the Layout bucket header above it (66051)","PaymentBadges._gContent":"duplicated the Content bucket header above it (66051)","PaymentBadges._gLayout":"duplicated the Layout bucket header above it (66051)","Collections._gContent":"duplicated the Content bucket header above it (66052)","Collections._gLayout":"duplicated the Layout bucket header above it (66052)","DocMasthead._gContent":"duplicated the Content bucket header above it (66053)","Events._gContent":"duplicated the Content bucket header above it (66054)","Events._gLayout":"duplicated the Layout bucket header above it (66054)","FeaturedCover._gContent":"duplicated the Content bucket header above it (66054)","Series._gStyle":"duplicated the Style bucket header above it (66054)","Flex._gContent":"duplicated the Content bucket header above it (66055)","Flex._gLayout":"duplicated the Layout bucket header above it (66055)","Flex._gLink":"repeated the Link group heading above it (owner 2026-11-17)","Flex._gJump":"repeated the Anchor group heading above it (owner 2026-11-17)","SectionHeader._gContent":"duplicated the Content bucket header above it (66055)","Breadcrumb._gContent":"duplicated the Content bucket header above it (66056)","CategoryBar._gStyle":"duplicated the Style bucket header above it (66056)","Hero._gContent":"duplicated the Content bucket header above it (66056)","Hero._gStyle":"duplicated the Style bucket header above it (66056)","HeroSingle._gStyle":"duplicated the Style bucket header above it (66056)","IntroBleed._gContent":"duplicated the Content bucket header above it (66056)","IntroBleed._gLayout":"duplicated the Layout bucket header above it (66056)","BundleOffer._gLayout":"duplicated the Layout bucket header above it (66059)","ProcessSteps._gContent":"duplicated the Content bucket header above it (66059)","Banner._gContent":"duplicated the Content bucket header above it (66060.1)","Banner._gLayout":"duplicated the Layout bucket header above it, and governed no controls (66060.1)","Manifesto._gContent":"duplicated the Content bucket header above it (66060.1)","SubscribeBlogs._gHeadCopy":"duplicated the Content bucket header above it (66060.1)","SubscribeBlogs._gLeftCopy":"duplicated the Content bucket header above it (66060.1)","SubscribeBlogs._gRightCopy":"duplicated the Content bucket header above it (66060.1)","Ticker._gContent":"duplicated the Content bucket header above it (66060.1)","Ticker._gStyle":"duplicated the Style bucket header above it (66060.1)","Timeline._gContent":"duplicated the Content bucket header above it (66060.1)","TitleWithButtons._gContent":"duplicated the Content bucket header above it (66060.1)","TitleWithButtons._gStyle":"duplicated the Style bucket header above it (66060.1)","Cards._gContent":"duplicated the Content bucket header above it (66218)","Cards._gStyle":"duplicated the Style bucket header above it (66218)","Prose._gContent":"duplicated the Content bucket header above it (66218)","Reviews._gContent":"duplicated the Content bucket header above it (66218)","Reviews._gStyle":"duplicated the Style bucket header above it (66218)"},Y={Content:["Content"],Size:["Size"],Design:["Design","Style"],Layout:["Layout"],Position:["Position"],Link:["Link"],Anchor:["Anchor"],Animation:["Animation"]},P={_gAnchor:"repeated the Anchor group heading above it (two tabs, 11.0.0)"};{const n={...A({tablet:!0,siteSide:!0}),...B("full"),...O(),...E(),...T(),...D(),...F()};for(const e of Object.keys(P)){const o=C(n[e]),i=o?p(x,o.label):void 0;if(!o||o.level!==2||!i||!Y[i].includes(o.label))throw new Error(`INJECTED_RETIRED (lib/document/field-groups.ts) lists "${e}", but no uniform builder makes a level-2 heading by that key whose label repeats its place's word. The heading was renamed, moved or removed and the row is stale — a list that quietly matches nothing is worse than no list.`)}}const oe=new Set(["_sContent","_sStyle","_sLayout","_sMedia"]),ae=new Map([[l.Design,"Content"],[l.Animation,"Animation"],..._.map(n=>[g[n],n])]);function ie(n){const e=`${n}.`;return Object.keys(ne).filter(o=>o.startsWith(e)).map(o=>o.slice(e.length))}function re(n,e){const o=K(n),i=Q(e);return o?V(o.tier,i):i}function de(n,e){const o=C(e);return o?n==="Content"||n==="Animation"?J(e,o.label):q(e):e}function U(n){return n==="Design"?_:["Animation"]}function me(n,e){const o=[],i=new Set(ie(e)),s=new Set;let h=!1,u=null;for(const[t,d]of Object.entries(n)){const a=C(d);if(oe.has(t))throw new Error(`${e}.${t}: that key was a tab header until efficient-web-builder 11.0.0, when the panel moved to two tabs (Design · Animation). Its tab is gone, so the key may not come back. Give the heading a key of the section's own (\`_g…\`), or open a Design group with its own key from efficient-easel's DESIGN_GROUP_KEY (\`[DESIGN_GROUP_KEY.Design]: section("Design")\`).`);const c=ae.get(t);if(c!==void 0){if(a?.level!==1)throw new Error(`${e}.${t}: that key is reserved for the ${c} heading of the settings panel, but this field is ${a?`a level-${a.level} "${a.label}" header`:"not a header"}, so it cannot serve as one. Rename the section's own field.`);(t===l.Design||t===l.Animation)&&(h=!0),o.push(u={place:c,entries:[],adopted:!0});continue}if(!a){u||o.push(u={place:"Content",entries:[]}),u.entries.push([t,d]);continue}if(i.has(t)||M(P,t)){const r=I(e,t,a.label);if(a.level!==2||!r||!Y[r].includes(a.label))throw new Error(`${e}.${t}: ${i.has(t)?"RETIRED":"INJECTED_RETIRED"} (lib/document/field-groups.ts) lists this sub-heading as one whose name repeats the place it sits in, but it is a level-${a.level} "${a.label}" header in the ${r??"(unclassified)"} place. Only a level-2 header whose label is one of its place's words (PLACE_WORDS) may be retired — anything else is a heading a merchant reads for its own sake. Fix the row or drop it.`);i.has(t)&&s.add(t),o.push(u={place:r,entries:[],uniform:M(P,t)});continue}const b=I(e,t,a.label);if(!b)throw new Error(`${e}.${t}: the inspector group "${a.label}" is not classified in LABEL_GROUP (lib/document/field-groups.ts), so there is no way to say which of ${[..._,"Animation"].join(" / ")} its controls belong under. Classify it — an unclassified group silently lands wherever it was declared, which is the whole bug.`);o.push(u={place:b,entries:[[t,a.level===2?d:re(d,a.label)]]})}const y=new Set(Object.entries(n).filter(([,t])=>C(t)).map(([t])=>t));for(const[t,d]of[["BLOCK_KEY_GROUP",N],["KEY_GROUP",j]]){const a=Object.keys(d).filter(c=>c.startsWith(`${e}.`)).filter(c=>!y.has(c.slice(e.length+1))&&!i.has(c.slice(e.length+1)));if(a.length)throw new Error(`${e}: ${t} (lib/document/field-groups.ts) lists ${JSON.stringify(a)}, but no fold header by that key is in this section's panel. Either the heading was renamed or removed and the row is stale, or the row names the wrong key — an override that quietly matches nothing is worse than no override.`)}const f=h?[]:[...i].filter(t=>!s.has(t));if(f.length)throw new Error(`${e}: RETIRED (lib/document/field-groups.ts) lists ${JSON.stringify(f)}, but this section has no such fold header${f.length>1?"s":""}. Either the heading was renamed or removed and the row is stale, or the row names the wrong section — a list that quietly matches nothing is worse than no list.`);const G=new Set(o.filter(t=>t.entries.length>0).map(t=>t.place)),m=R.filter(t=>U(t).some(d=>G.has(d))),k={};for(const t of m){k[l[t]]=w(t,t===m[0]?m:null);for(const d of U(t)){if(!G.has(d))continue;const a=o.filter(r=>r.place===d),c=a.findIndex(r=>r.adopted);c>0&&a.unshift(...a.splice(c,1));const b=a.filter(r=>r.uniform);if(b.length>0){const r=a.filter(L=>!L.uniform),S=a[0]?.adopted?1:0;a.splice(0,a.length,...r.slice(0,S),...b,...r.slice(S))}t==="Design"&&(k[g[d]]=$(d));for(const r of a)for(const[S,L]of r.entries)k[S]=de(d,L)}}return k}function Le(n){return l.Design in n?n:{[l.Design]:w("Design",null),[g.Content]:$("Content"),...n}}function Ee(n){return R.some(e=>l[e]in n)}function we(n){const e=R.filter(i=>l[i]in n);if(e.length===0)return n;const o={...n};for(const i of e)o[l[i]]=w(i,i===e[0]?e:null);return o}export{N as BLOCK_KEY_GROUP,R as BUCKETS,l as BUCKET_KEY,ve as CARD_MEDIA_FIELD_KEYS,fe as CARD_SHOW_FIELD_KEYS,_ as DESIGN_GROUPS,g as DESIGN_GROUP_KEY,ee as EDITOR_ONLY_GROUP,P as INJECTED_RETIRED,j as KEY_GROUP,x as LABEL_GROUP,ye as LAYOUT_FIELD_KEYS,Y as PLACE_WORDS,ne as RETIRED,_e as SECTION_ANIM_FIELD_KEYS,Se as SECTION_SHAPE_FIELD_KEYS,ke as SECTION_THEME_FIELD_KEYS,me as assignSectionGroups,pe as bucketOf,Z as bucketOfPlace,Ee as hasBucketTabs,v as headerKeysOf,te as headerKeysOfPlace,I as placeOf,we as reseatBucketTabs,ie as retiredHeadings,Le as seatDesignBucket};
1
+ import{anchorFields as E,bucketHeader as w,cardMediaFields as W,cardShowFields as z,designGroupHeader as $,foldMarker as J,foldMetaOf as C,quietMarker as q,heightFields as O,sectionShapeFields as D,sectionThemeFields as T,stickFields as H,widthField as B}from"./controls.js";import{group as Q}from"efficient-easel/screen/lib/document/box-fields";import{sidesPaddingFields as A}from"./box-fields.js";import{deviceField as V,deviceMetaOf as K}from"efficient-easel/screen/lib/document/device-fields";import{entranceFields as R}from"../animation/entrance-fields.js";import{DESIGN_GROUPS as _,SETTINGS_BUCKETS as X}from"efficient-easel/panel";import{BUCKET_KEY as l,DESIGN_GROUP_KEY as g}from"efficient-easel/screen/lib/document/field-buckets";import{ownEntry as p,hasOwnEntry as M}from"../../../format/lib/own-entry.js";const F=X;function Z(n){return n==="Animation"?"Animation":"Design"}const ee="Editor only — not shown live",x={"Archive link":"Content",Article:"Content",Blocks:"Content","Blog posts":"Content","Browser mock":"Content",Button:"Content","Call to action":"Content","Car prompt":"Content","Card link":"Content","Card list":"Content",Cards:"Content","Claims bars":"Content","Contact info":"Content",Content:"Content",Display:"Content","Content source":"Content",Contents:"Content",Filters:"Content","Show on a card":"Content",Footnote:"Content",Form:"Content",Founders:"Content","Gallery A":"Content","Gallery B":"Content","Gallery link":"Content",Header:"Content","Header link":"Content","Image caption":"Content","In this issue":"Content",Items:"Content","Kanban columns":"Content",Lead:"Content","Left panel":"Content",Link:"Content",Links:"Content",List:"Content","Message form":"Content",Metadata:"Content",Milestones:"Content","Mockup card":"Content","Newsletter panel":"Content",Offices:"Content",Options:"Content","Others gallery":"Content","Overlay button":"Content",Product:"Content","Product page":"Content",Products:"Content","Pull quote":"Content",Questions:"Content","Recent issues":"Content","Recent posts":"Content",Reviews:"Content","Right panel · actions":"Content","Right panel · choices":"Content","Right panel · form":"Content","Routing groups":"Content",Rows:"Content",Section:"Content","Section header":"Content",Sections:"Content","Signup form":"Content",Source:"Content","Source product":"Content","Stat & note":"Content",Stats:"Content","Submit button":"Content","Success state":"Content",Wheel:"Content",Terminal:"Content",Text:"Content","Text column":"Content","Timeline entries":"Content","Top row":"Content",Total:"Content","Trailing note":"Content","“Other” reason":"Content","Background images":"Design",Gallery:"Content",Image:"Content","Image column":"Content",Images:"Content",Logo:"Content",Map:"Content",Media:"Content","Background image":"Design",Color:"Design","Image tint":"Design",Style:"Design",Shape:"Design",Shadow:"Design",Texture:"Design",Overlay:"Design","Text style":"Design",Entrance:"Animation",Hover:"Animation",Loop:"Animation",Scroll:"Animation",Anchor:"Anchor",Arrangement:"Layout","Auto-slide":"Layout",Bar:"Layout","Cell size":"Size",Behavior:"Layout",Schedule:"Layout",Controls:"Layout",Diagram:"Layout",[ee]:"Layout","Filters shown":"Layout","Slide picker":"Layout",Arrows:"Layout","On a phone":"Layout",Placement:"Position",Nudge:"Position","Stick to top":"Position","Image gallery":"Layout",Grid:"Layout",Layout:"Layout",Padding:"Layout",Price:"Layout",Preview:"Layout",Setup:"Layout","Show / hide elements":"Layout","Show in the buy box":"Layout",Visibility:"Layout",Width:"Size",Size:"Size",Height:"Size"},j={"AlloyWheelsListing._gCards":"Design","Flex._gLink":"Link","LongRead._gLink":"Link"},N={"Text._gSpacing":"Size","Heading._gSpacing":"Size"};function I(n,e,o){const i=`${n}.${e}`;return p(N,i)??p(j,i)??p(x,o)}function pe(n,e,o){const i=I(n,e,o);return i?Z(i):void 0}function te(n){return n==="Animation"?[l.Animation]:[l.Design,g[n]]}function v(...n){const e=[];for(const o of n)for(const i of Object.values(o)){const s=K(i),h=C(s?s.inner:i),u=h?p(x,h.label):void 0;if(u)for(const y of te(u))e.includes(y)||e.push(y)}return e}const ye=[...v(A({tablet:!0,siteSide:!0}),B("full"),O(),E(),H()),...Object.keys(A({tablet:!0,siteSide:!0})),...Object.keys(B("full")),...Object.keys(O()),...Object.keys(E()),...Object.keys(H())],ke=[...v(T()),...Object.keys(T())],Se=[...v(D()),...Object.keys(D())],_e=[...v(R()),...Object.keys(R())],ve=Object.keys(W()),fe=Object.keys(z()),ne={"ImageBlock._gStyle":"duplicated the Style bucket header above it (2026-09-04)","ButtonBlock._gStyle":"duplicated the Style bucket header above it (2026-09-04)","HeroGroup._gContent":"duplicated the Content bucket header above it (2026-09-04)","HeroGroup._gLayout":"duplicated the Layout bucket header above it (2026-09-04)","Footer._gLayout":"duplicated the Layout bucket header above it (2026-09-04)","FooterLogo._gContent":"duplicated the Content bucket header above it (2026-09-04)","FooterLogo._gStyle":"duplicated the Style bucket header above it (2026-09-04)","FooterMenu._gContent":"duplicated the Content bucket header above it (2026-09-04)","FooterMenu._gStyle":"duplicated the Style bucket header above it (2026-09-04)","FooterGroup._gLayout":"duplicated the Layout bucket header above it (2026-09-04)","FooterText._gContent":"duplicated the Content bucket header above it (2026-09-04)","FooterText._gStyle":"duplicated the Style bucket header above it (2026-09-04)","FooterSocial._gStyle":"duplicated the Style bucket header above it (born tabbed, 2026-09-17)","FooterSocial._gLayout":"duplicated the Layout bucket header above it (born tabbed, 2026-09-17)","MenuBlock._gContent":"duplicated the Content bucket header above it (born tabbed, H.1)","MenuBlock._gStyle":"duplicated the Style bucket header above it (born tabbed, H.1)","SocialLogosBlock._gStyle":"duplicated the Style bucket header above it (born tabbed, H.1)","SocialLogosBlock._gLayout":"duplicated the Layout bucket header above it (born tabbed, H.1)","SearchBlock._gStyle":"duplicated the Style bucket header above it (born tabbed, H.2)","CartBlock._gStyle":"duplicated the Style bucket header above it (born tabbed, H.2)","CountrySwitchBlock._gStyle":"duplicated the Style bucket header above it (born tabbed with its Show as, 2026-10-17)","Split._gContent":"duplicated the Content bucket header above it (2026-09-04)","Gallery._gVehicleContent":"duplicated the Content bucket header above it (2026-09-04)","Gallery._gWheelContent":"duplicated the Content bucket header above it (2026-09-04)","Gallery._gOthersContent":"duplicated the Content bucket header above it (2026-09-04)","Subscribe._gHeadCopy":"duplicated the Content bucket header above it (2026-09-04)","Subscribe._gLeftCopy":"duplicated the Content bucket header above it (2026-09-04)","Subscribe._gRightCopy":"duplicated the Content bucket header above it (2026-09-04)","CollectionCard._gContent":"duplicated the Content bucket header above it (A Card Sets Its Own Corners)","HeroSlide._gContent":"duplicated the Content bucket header above it (Hero Slide Tabs And Theme)","KeyFeatures._gContent":"duplicated the Content bucket header above it (66049)","KeyFeatures._gStyle":"duplicated the Style bucket header above it (66049)","ParagraphsA._gContent":"duplicated the Content bucket header above it (66049)","Chart._gContent":"duplicated the Content bucket header above it (66049)","Chart._gStyle":"duplicated the Style bucket header above it (66049)","Logos._gContent":"duplicated the Content bucket header above it (66049)","Logos._gStyle":"duplicated the Style bucket header above it (66049)","Mockup._gContent":"duplicated the Content bucket header above it (66049)","Mockup._gStyle":"duplicated the Style bucket header above it (66049)","Stats._gContent":"duplicated the Content bucket header above it (66049)","Stats._gStyle":"duplicated the Style bucket header above it (66049)","StatsParagraph._gContent":"duplicated the Content bucket header above it (66049)","StatsParagraph._gStyle":"duplicated the Style bucket header above it (66049)","Testimonials._gContent":"duplicated the Content bucket header above it (66049)","Testimonials._gStyle":"duplicated the Style bucket header above it (66049)","AppointmentBooking._gContent":"duplicated the Content bucket header above it (66050)","BookingBox._gContent":"duplicated the Content bucket header above it ([SPLIT] Booking Form Into Three Boxes) — the same fault its own section retired in 66050, one level down","FAQ._gContent":"duplicated the Content bucket header above it (66050, family sweep)","FAQ._gLayout":"duplicated the Layout bucket header above it (66050, family sweep)","Form._gContent":"duplicated the Content bucket header above it (66050)","ReviewForm._gContent":"duplicated the Content bucket header above it (66050)","SubmitBuild._gContent":"duplicated the Content bucket header above it (66050)","SubmitBox._gContent":"duplicated the Content bucket header above it ([SPLIT] SubmitBuild Keeps Its Two Columns) — the same fault its own section retired in 66050, one level down","CheckoutCTA._gContent":"duplicated the Content bucket header above it (66051)","CheckoutCTA._gLayout":"duplicated the Layout bucket header above it (66051)","DeliveryOptions._gContent":"duplicated the Content bucket header above it (66051)","DeliveryOptions._gLayout":"duplicated the Layout bucket header above it (66051)","OrderSummary._gContent":"duplicated the Content bucket header above it (66051)","OrderSummary._gLayout":"duplicated the Layout bucket header above it (66051)","PaymentBadges._gContent":"duplicated the Content bucket header above it (66051)","PaymentBadges._gLayout":"duplicated the Layout bucket header above it (66051)","Collections._gContent":"duplicated the Content bucket header above it (66052)","Collections._gLayout":"duplicated the Layout bucket header above it (66052)","DocMasthead._gContent":"duplicated the Content bucket header above it (66053)","Events._gContent":"duplicated the Content bucket header above it (66054)","Events._gLayout":"duplicated the Layout bucket header above it (66054)","FeaturedCover._gContent":"duplicated the Content bucket header above it (66054)","Series._gStyle":"duplicated the Style bucket header above it (66054)","Flex._gContent":"duplicated the Content bucket header above it (66055)","Flex._gLayout":"duplicated the Layout bucket header above it (66055)","Flex._gLink":"repeated the Link group heading above it (owner 2026-11-17)","LongRead._gLink":"repeated the Link group heading above it (decided 2026-11-17)","Flex._gJump":"repeated the Anchor group heading above it (owner 2026-11-17)","SectionHeader._gContent":"duplicated the Content bucket header above it (66055)","Breadcrumb._gContent":"duplicated the Content bucket header above it (66056)","CategoryBar._gStyle":"duplicated the Style bucket header above it (66056)","Hero._gContent":"duplicated the Content bucket header above it (66056)","Hero._gStyle":"duplicated the Style bucket header above it (66056)","HeroSingle._gStyle":"duplicated the Style bucket header above it (66056)","IntroBleed._gContent":"duplicated the Content bucket header above it (66056)","IntroBleed._gLayout":"duplicated the Layout bucket header above it (66056)","BundleOffer._gLayout":"duplicated the Layout bucket header above it (66059)","ProcessSteps._gContent":"duplicated the Content bucket header above it (66059)","Banner._gContent":"duplicated the Content bucket header above it (66060.1)","Banner._gLayout":"duplicated the Layout bucket header above it, and governed no controls (66060.1)","Manifesto._gContent":"duplicated the Content bucket header above it (66060.1)","SubscribeBlogs._gHeadCopy":"duplicated the Content bucket header above it (66060.1)","SubscribeBlogs._gLeftCopy":"duplicated the Content bucket header above it (66060.1)","SubscribeBlogs._gRightCopy":"duplicated the Content bucket header above it (66060.1)","Ticker._gContent":"duplicated the Content bucket header above it (66060.1)","Ticker._gStyle":"duplicated the Style bucket header above it (66060.1)","Timeline._gContent":"duplicated the Content bucket header above it (66060.1)","TitleWithButtons._gContent":"duplicated the Content bucket header above it (66060.1)","TitleWithButtons._gStyle":"duplicated the Style bucket header above it (66060.1)","Cards._gContent":"duplicated the Content bucket header above it (66218)","Cards._gStyle":"duplicated the Style bucket header above it (66218)","Prose._gContent":"duplicated the Content bucket header above it (66218)","Reviews._gContent":"duplicated the Content bucket header above it (66218)","Reviews._gStyle":"duplicated the Style bucket header above it (66218)"},Y={Content:["Content"],Size:["Size"],Design:["Design","Style"],Layout:["Layout"],Position:["Position"],Link:["Link"],Anchor:["Anchor"],Animation:["Animation"]},P={_gAnchor:"repeated the Anchor group heading above it (two tabs, 11.0.0)"};{const n={...A({tablet:!0,siteSide:!0}),...B("full"),...O(),...E(),...T(),...D(),...R()};for(const e of Object.keys(P)){const o=C(n[e]),i=o?p(x,o.label):void 0;if(!o||o.level!==2||!i||!Y[i].includes(o.label))throw new Error(`INJECTED_RETIRED (lib/document/field-groups.ts) lists "${e}", but no uniform builder makes a level-2 heading by that key whose label repeats its place's word. The heading was renamed, moved or removed and the row is stale — a list that quietly matches nothing is worse than no list.`)}}const oe=new Set(["_sContent","_sStyle","_sLayout","_sMedia"]),ae=new Map([[l.Design,"Content"],[l.Animation,"Animation"],..._.map(n=>[g[n],n])]);function ie(n){const e=`${n}.`;return Object.keys(ne).filter(o=>o.startsWith(e)).map(o=>o.slice(e.length))}function re(n,e){const o=K(n),i=Q(e);return o?V(o.tier,i):i}function de(n,e){const o=C(e);return o?n==="Content"||n==="Animation"?J(e,o.label):q(e):e}function U(n){return n==="Design"?_:["Animation"]}function me(n,e){const o=[],i=new Set(ie(e)),s=new Set;let h=!1,u=null;for(const[t,d]of Object.entries(n)){const a=C(d);if(oe.has(t))throw new Error(`${e}.${t}: that key was a tab header until efficient-web-builder 11.0.0, when the panel moved to two tabs (Design · Animation). Its tab is gone, so the key may not come back. Give the heading a key of the section's own (\`_g…\`), or open a Design group with its own key from efficient-easel's DESIGN_GROUP_KEY (\`[DESIGN_GROUP_KEY.Design]: section("Design")\`).`);const c=ae.get(t);if(c!==void 0){if(a?.level!==1)throw new Error(`${e}.${t}: that key is reserved for the ${c} heading of the settings panel, but this field is ${a?`a level-${a.level} "${a.label}" header`:"not a header"}, so it cannot serve as one. Rename the section's own field.`);(t===l.Design||t===l.Animation)&&(h=!0),o.push(u={place:c,entries:[],adopted:!0});continue}if(!a){u||o.push(u={place:"Content",entries:[]}),u.entries.push([t,d]);continue}if(i.has(t)||M(P,t)){const r=I(e,t,a.label);if(a.level!==2||!r||!Y[r].includes(a.label))throw new Error(`${e}.${t}: ${i.has(t)?"RETIRED":"INJECTED_RETIRED"} (lib/document/field-groups.ts) lists this sub-heading as one whose name repeats the place it sits in, but it is a level-${a.level} "${a.label}" header in the ${r??"(unclassified)"} place. Only a level-2 header whose label is one of its place's words (PLACE_WORDS) may be retired — anything else is a heading a merchant reads for its own sake. Fix the row or drop it.`);i.has(t)&&s.add(t),o.push(u={place:r,entries:[],uniform:M(P,t)});continue}const b=I(e,t,a.label);if(!b)throw new Error(`${e}.${t}: the inspector group "${a.label}" is not classified in LABEL_GROUP (lib/document/field-groups.ts), so there is no way to say which of ${[..._,"Animation"].join(" / ")} its controls belong under. Classify it — an unclassified group silently lands wherever it was declared, which is the whole bug.`);o.push(u={place:b,entries:[[t,a.level===2?d:re(d,a.label)]]})}const y=new Set(Object.entries(n).filter(([,t])=>C(t)).map(([t])=>t));for(const[t,d]of[["BLOCK_KEY_GROUP",N],["KEY_GROUP",j]]){const a=Object.keys(d).filter(c=>c.startsWith(`${e}.`)).filter(c=>!y.has(c.slice(e.length+1))&&!i.has(c.slice(e.length+1)));if(a.length)throw new Error(`${e}: ${t} (lib/document/field-groups.ts) lists ${JSON.stringify(a)}, but no fold header by that key is in this section's panel. Either the heading was renamed or removed and the row is stale, or the row names the wrong key — an override that quietly matches nothing is worse than no override.`)}const f=h?[]:[...i].filter(t=>!s.has(t));if(f.length)throw new Error(`${e}: RETIRED (lib/document/field-groups.ts) lists ${JSON.stringify(f)}, but this section has no such fold header${f.length>1?"s":""}. Either the heading was renamed or removed and the row is stale, or the row names the wrong section — a list that quietly matches nothing is worse than no list.`);const G=new Set(o.filter(t=>t.entries.length>0).map(t=>t.place)),m=F.filter(t=>U(t).some(d=>G.has(d))),k={};for(const t of m){k[l[t]]=w(t,t===m[0]?m:null);for(const d of U(t)){if(!G.has(d))continue;const a=o.filter(r=>r.place===d),c=a.findIndex(r=>r.adopted);c>0&&a.unshift(...a.splice(c,1));const b=a.filter(r=>r.uniform);if(b.length>0){const r=a.filter(L=>!L.uniform),S=a[0]?.adopted?1:0;a.splice(0,a.length,...r.slice(0,S),...b,...r.slice(S))}t==="Design"&&(k[g[d]]=$(d));for(const r of a)for(const[S,L]of r.entries)k[S]=de(d,L)}}return k}function Le(n){return l.Design in n?n:{[l.Design]:w("Design",null),[g.Content]:$("Content"),...n}}function Ee(n){return F.some(e=>l[e]in n)}function we(n){const e=F.filter(i=>l[i]in n);if(e.length===0)return n;const o={...n};for(const i of e)o[l[i]]=w(i,i===e[0]?e:null);return o}export{N as BLOCK_KEY_GROUP,F as BUCKETS,l as BUCKET_KEY,ve as CARD_MEDIA_FIELD_KEYS,fe as CARD_SHOW_FIELD_KEYS,_ as DESIGN_GROUPS,g as DESIGN_GROUP_KEY,ee as EDITOR_ONLY_GROUP,P as INJECTED_RETIRED,j as KEY_GROUP,x as LABEL_GROUP,ye as LAYOUT_FIELD_KEYS,Y as PLACE_WORDS,ne as RETIRED,_e as SECTION_ANIM_FIELD_KEYS,Se as SECTION_SHAPE_FIELD_KEYS,ke as SECTION_THEME_FIELD_KEYS,me as assignSectionGroups,pe as bucketOf,Z as bucketOfPlace,Ee as hasBucketTabs,v as headerKeysOf,te as headerKeysOfPlace,I as placeOf,we as reseatBucketTabs,ie as retiredHeadings,Le as seatDesignBucket};
@@ -0,0 +1,2 @@
1
+ import type { Config } from "efficient-easel/blocks";
2
+ export declare function useHostConfig(): Config;
@@ -0,0 +1 @@
1
+ "use client";import{useMemo as s}from"react";import{sessionRegistry as i}from"efficient-easel/screen/lib/session";import{useEaselSession as e}from"efficient-easel/screen/lib/session-context";import{buildConfig as r}from"./build-config.js";import{blocksOf as t}from"../website-session.js";function c(){const o=e();return s(()=>r(i(o),t(o)),[o])}export{c as useHostConfig};
@@ -1,2 +1,3 @@
1
1
  import { type EaselCanvasProps } from "efficient-easel/easel";
2
2
  export declare function SiteCanvas(props: Omit<EaselCanvasProps, "frameWrapper" | "overlay" | "height" | "mirrorStyles">): import("react").JSX.Element;
3
+ export declare function useSiteWidthsMetadata(): Record<string, unknown>;
@@ -1 +1 @@
1
- "use client";import{jsx as h,Fragment as x,jsxs as D}from"react/jsx-runtime";import{useContext as F,useEffect as k,useMemo as P,useRef as w}from"react";import{EaselCanvas as $,repeatCopyAt as M,useEasel as N}from"efficient-easel/easel";import _ from"../../components/PreviewThemeFrame.js";import{OpenDocumentChromeLoadNotice as W}from"../../components/PinnedChromeLoadNotice.js";import{SiteRestoreNotice as b}from"../../components/SiteRestoreNotice.js";import{decodePartId as j,REPEAT_ATTRIBUTE as S,REPEAT_INDEX_ATTRIBUTE as v}from"efficient-easel/draw";import{usePreviewParts as B}from"efficient-easel/draw/client";import{cssString as E,partElement as A,partTypingTarget as K,setCanvasTypingPart as I}from"./canvas-typing.js";import{usePartTypingDeps as O}from"../../components/usePartTypingDeps.js";import{copyRowTarget as V,copyRowValue as H,writeCopyText as L}from"./card-copy-rows.js";import{partColourName as U,partThemeColors as q,readInks as J}from"../../../format/lib/document/part-inks.js";import{PART_ATTR as C}from"../../../render/lib/document/text-parts.js";import{useBlockMetadata as X}from"../editor-block-metadata.js";import{usePreviewHeader as z,useSiteContentWidth as G}from"../../../render/components/PreviewHeaderContext.js";import{setEditorSiteContentWidth as R}from"../../../format/lib/document/editor-site-widths.js";import{siteWidthsMetadata as Q}from"../../../format/lib/content/section-width.js";import{useEditorCanvasStyles as Y}from"../editor-canvas-styles.js";import{usePageVideoFrames as Z,videoFramesMetadata as ee}from"../page-video-frames.js";import{ScreenDocumentContext as te}from"efficient-easel/screen/components/ScreenDocumentContext";function we(o){const{mirrorHostStyles:s}=Y(),p=X(),{sectionBackgroundWidth:a,themeFromDocument:d}=z(),e=G(),r=F(te),t=Z(r?.docId??null),f=N(c=>c.appState.data),l=ee(t,f),n=JSON.stringify(l),m=P(()=>l,[n]),u=P(()=>({...o.metadata??p??{},...Q(d?null:a,e),...m}),[o.metadata,p,a,e,d,m]);k(()=>(R(e),()=>R(null)),[e]);const i=w(null),g=re(i),{onDocument:y}=o,T=c=>{i.current=c,y?.(c)};return D(x,{children:[h(b,{}),h(W,{}),h($,{...o,onDocument:T,typing:g,metadata:u,height:"fill",mirrorStyles:s,frameWrapper:_})]})}function re(o){const s=O(),p=B(),a=w({parts:p});return a.current={parts:p},P(()=>{const d=(e,r)=>{let t=K(e,s),f,l=null;const n=r??(t?null:A(null,o.current,e)),m=!t&&n?M(n):null,u=m?j(e):null;if(m&&n&&u?.propKey){t=V({...m,nodeId:u.nodeId,key:u.propKey},s),f=u.propKey;const T=n.closest(`[${S}][${v}]`),c=`[${S}="${E(T?.getAttribute(S)??"")}"][${v}="${E(T?.getAttribute(v)??"")}"]`;l=()=>(n.ownerDocument??o.current)?.querySelector(c)??null}if(!t)return null;let i=n;const g=()=>(i=A(i,l?l():i?.ownerDocument??o.current,e),i),y=g();return y?{element:g,value:t.value,rules:t.rules,multiline:t.multiline,skip:t.skip,write:t.write,key:f,toolbar:{offered:t.offered,colors:t.offered.length>0?q(J(y)):void 0,colorNameOf:U}}:null};return{at:e=>{const r=e.closest(`[${C}]`),t=r?.getAttribute(C);return r&&t?d(t,r):null},atSelection:()=>{const e=a.current.parts.selectedPartId;return e?d(e,null):null},onCopyText:e=>L(e,s),copyValue:e=>H(e,s),onChange:e=>{if(!e.typing){I(null);return}const r=e.element.closest(`[${C}]`)?.getAttribute(C)??null;I(r),r&&a.current.parts.selectedPartId!==r&&a.current.parts.select(r)}}},[s,o])}export{we as SiteCanvas};
1
+ "use client";import{jsx as h,Fragment as D,jsxs as F}from"react/jsx-runtime";import{useContext as k,useEffect as M,useMemo as T,useRef as v}from"react";import{EaselCanvas as W,repeatCopyAt as $,useEasel as N}from"efficient-easel/easel";import _ from"../../components/PreviewThemeFrame.js";import{OpenDocumentChromeLoadNotice as b}from"../../components/PinnedChromeLoadNotice.js";import{SiteRestoreNotice as j}from"../../components/SiteRestoreNotice.js";import{decodePartId as B,REPEAT_ATTRIBUTE as S,REPEAT_INDEX_ATTRIBUTE as P}from"efficient-easel/draw";import{usePreviewParts as K}from"efficient-easel/draw/client";import{cssString as w,partElement as E,partTypingTarget as O,setCanvasTypingPart as A}from"./canvas-typing.js";import{usePartTypingDeps as V}from"../../components/usePartTypingDeps.js";import{copyRowTarget as H,copyRowValue as L,writeCopyText as U}from"./card-copy-rows.js";import{partColourName as q,partThemeColors as J,readInks as X}from"../../../format/lib/document/part-inks.js";import{PART_ATTR as C}from"../../../render/lib/document/text-parts.js";import{useBlockMetadata as z}from"../editor-block-metadata.js";import{usePreviewHeader as G,useSiteContentWidth as x}from"../../../render/components/PreviewHeaderContext.js";import{setEditorSiteContentWidth as I}from"../../../format/lib/document/editor-site-widths.js";import{siteWidthsMetadata as Q}from"../../../format/lib/content/section-width.js";import{useEditorCanvasStyles as Y}from"../editor-canvas-styles.js";import{usePageVideoFrames as Z,videoFramesMetadata as tt}from"../page-video-frames.js";import{ScreenDocumentContext as et}from"efficient-easel/screen/components/ScreenDocumentContext";function Et(r){const{mirrorHostStyles:n}=Y(),a=z(),i=rt(),m=x(),t=k(et),o=Z(t?.docId??null),e=N(u=>u.appState.data),p=tt(o,e),d=JSON.stringify(p),s=T(()=>p,[d]),f=T(()=>({...r.metadata??a??{},...i,...s}),[r.metadata,a,i,s]);M(()=>(I(m),()=>I(null)),[m]);const l=v(null),c=ot(l),{onDocument:g}=r,y=u=>{l.current=u,g?.(u)};return F(D,{children:[h(j,{}),h(b,{}),h(W,{...r,onDocument:y,typing:c,metadata:f,height:"fill",mirrorStyles:n,frameWrapper:_})]})}function rt(){const{sectionBackgroundWidth:r,themeFromDocument:n}=G(),a=x();return T(()=>Q(n?null:r,a),[r,a,n])}function ot(r){const n=V(),a=K(),i=v({parts:a});return i.current={parts:a},T(()=>{const m=(t,o)=>{let e=O(t,n),p,d=null;const s=o??(e?null:E(null,r.current,t)),f=!e&&s?$(s):null,l=f?B(t):null;if(f&&s&&l?.propKey){e=H({...f,nodeId:l.nodeId,key:l.propKey},n),p=l.propKey;const u=s.closest(`[${S}][${P}]`),R=`[${S}="${w(u?.getAttribute(S)??"")}"][${P}="${w(u?.getAttribute(P)??"")}"]`;d=()=>(s.ownerDocument??r.current)?.querySelector(R)??null}if(!e)return null;let c=s;const g=()=>(c=E(c,d?d():c?.ownerDocument??r.current,t),c),y=g();return y?{element:g,value:e.value,rules:e.rules,multiline:e.multiline,skip:e.skip,write:e.write,key:p,toolbar:{offered:e.offered,colors:e.offered.length>0?J(X(y)):void 0,colorNameOf:q}}:null};return{at:t=>{const o=t.closest(`[${C}]`),e=o?.getAttribute(C);return o&&e?m(e,o):null},atSelection:()=>{const t=i.current.parts.selectedPartId;return t?m(t,null):null},onCopyText:t=>U(t,n),copyValue:t=>L(t,n),onChange:t=>{if(!t.typing){A(null);return}const o=t.element.closest(`[${C}]`)?.getAttribute(C)??null;A(o),o&&i.current.parts.selectedPartId!==o&&i.current.parts.select(o)}}},[n,r])}export{Et as SiteCanvas,rt as useSiteWidthsMetadata};
@@ -24,4 +24,16 @@ export declare function EditorThemedBody({ propsTheme, propsFonts, propsCornerSt
24
24
  overlay?: ReactNode;
25
25
  children?: ReactNode;
26
26
  }): import("react").JSX.Element;
27
+ export declare function SiteThemeCarrier({ propsTheme, propsFonts, propsCornerStyle, propsCornerRadiusPx, propsHeadingCompression, propsHeadingTypography, pageBackground, chromeInheritsSiteBackground, onClickCapture, body, }: {
28
+ propsTheme?: ThemeValue;
29
+ propsFonts?: FontsValue;
30
+ propsCornerStyle?: string;
31
+ propsCornerRadiusPx?: number | null;
32
+ propsHeadingCompression?: string;
33
+ propsHeadingTypography?: HeadingTypographyValue;
34
+ pageBackground?: string;
35
+ chromeInheritsSiteBackground?: boolean;
36
+ onClickCapture?: (e: MouseEvent<HTMLDivElement>) => void;
37
+ body: (contentStyle: CSSProperties) => ReactNode;
38
+ }): import("react").JSX.Element;
27
39
  export declare const suppressPreviewNav: (e: MouseEvent<HTMLDivElement>) => void;
@@ -1,2 +1,2 @@
1
- import{jsx as o,jsxs as C}from"react/jsx-runtime";import{accentItalicCss as K,storedTextStyles as X,textStylesCss as Y}from"../../../render/lib/text-styles/site-text-styles.js";import{pageWidthMarker as q,PAGE_WIDTH_ATTR as J,siteWidthTokens as Q,siteGutterTokens as Z,siteGutterPhoneClass as ee,siteGutterPhoneTokens as te,heroBackgroundTokens as oe}from"../../../format/lib/content/page-width.js";import{siteBlockGapPhoneClass as ne,siteBlockGapPhoneTokens as re,siteBlockGapTokens as ie}from"../../../format/lib/content/container-gap.js";import{usePreviewHeader as se}from"../../../render/components/PreviewHeaderContext.js";import{SitePhotographyProvider as ae}from"../../../render/components/SitePhotographyContext.js";import{ThemeLightInkProvider as de}from"../../../render/components/ThemeLightInkContext.js";import{CORNER_STYLE_TO_PX as ce,normalizeCornerStyle as le,normalizeCornerRadius as he,themeColorStyle as pe,themeLightInk as me,typeSizesStyle as fe,headingTypographyStyle as ue,normalizeHeadingTypography as ge,themeAccentStyle as Se,themeButtonStyle as ye,themePresetAccentVars as xe,themeSurfaceStyle as Te,siteCornerRadiusTokens as ke,shadowColorTokens as Pe,headingCompressionAttr as Ce,cardShadowAttr as Ge,cardGapAttr as Ee,hoverEffectAttr as Ae}from"../../../format/lib/theme.js";import{fontRoleStyle as ve}from"../../../format/lib/fonts.js";import{wordStyleTokens as _e}from"../../../format/lib/word-styles.js";import{isStandaloneSectionDocument as Be,pageHasHeaderSection as G,pageTakesTopSpace as Re,topSpaceMarker as we,TOP_SPACE_ATTR as Ie,HEADER_CLEARANCE_CLASS as We}from"../../../render/lib/document/header-clearance.js";import{leadSectionInk as He,HEADER_INK_ATTR as be}from"../../../render/lib/document/header-ink.js";import{useEasel as Ne}from"efficient-easel/easel";import{useCardContentSwitchPass as De}from"../../components/useCardContentSwitchPass.js";import{pageBackgroundVars as Le}from"../../../format/lib/content/page-background.js";import{pageWidthTokens as Ue}from"../../../render/lib/document/page-frame.js";import{EditingBridgesProvider as ze}from"../../../render/lib/document/editing-bridges.js";import je from"../../components/SectionTextPartBridge.js";import{PageContentsFromDocument as E}from"../../../render/components/PageContentsContext.js";const Fe={SectionTextParts:je};import{PageWidthWrapper as ut,PublishedPageFrame as gt,pageWidthTokens as St}from"../../../render/lib/document/page-frame.js";const Ve="color-mix(in oklab, var(--bg) 40%, #ffffff)",Oe="12vh";function Me({style:n,children:a}){const{appState:d}=Ne(g=>g),t=d.data.content,s=d.data.root;if(Be(t))return o("div",{className:"sf-themed-content",style:{...n,background:Ve,minHeight:"100vh",paddingBottom:Oe},children:o("div",{style:{background:"var(--bg)"},children:o(E,{content:t,children:a})})});const c=G(t)&&Re(s,t),l=G(t)?we(s,t):null,m=l?{[Ie]:l}:null,h=q(s?.widthChoice),f=h?{[J]:h}:null,p=c?null:He(t),u=p?{[be]:p}:null;return o("div",{className:`sf-themed-content${c?` ${We}`:""}`,style:n,...u,...m,...f,children:o("div",{style:{background:"var(--bg)",minHeight:"100%"},children:o(E,{content:t,children:a})})})}function ht({propsTheme:n,propsFonts:a,propsCornerStyle:d,propsCornerRadiusPx:t,propsHeadingCompression:s,propsHeadingTypography:c,pageBackground:l,chromeInheritsSiteBackground:m,suppressPreviewNav:h,footer:f,overlay:p,children:u}){const{theme:g,fonts:A,sizes:v,cornerRadiusPx:_,cardShadow:S,shadowColor:B,cardGap:R,hoverEffect:y,headingCompression:w,siteWidth:I,siteGutter:W,siteGutterPhone:x,blockGap:H,blockGapPhone:T,siteLengthUnits:b,headingTypography:N,heroBackgroundFollowsWidth:D,photographyGrayscale:L,textStyles:U,wordStyles:z,themeFromDocument:e}=se();De();const r=e?n:g,j=e?a:A,F=e?void 0:v,V=e?t===void 0?ce[le(d)]:he(t):_,i=e?{}:b,O=e?s:w,k=e?c:N,P=[Y(X(e?void 0:U)),K(ge(k).italicStrong)].filter(Boolean).join(`
2
- `),M=Ue(),$={...pe(r),...fe(F),...ue(k),...M.style,...m?{}:Le(l)};return C("div",{className:`sf-theme-surfaces sf-theme-accent ${[ee(e?void 0:x),ne(e?void 0:T)].filter(Boolean).join(" ")}`.trim(),style:{...ve(j),..._e(e?null:z),...Se(r),...ye(r),...xe(r),...Te(r),...ke(V,i.cornerRadiusUnit),...Pe(e?void 0:S,e?void 0:B,e?void 0:y),...Q(e?void 0:I,i.siteWidthUnit),...Z(e?void 0:W,i.siteGutterUnit),...te(e?void 0:x,i.siteGutterPhoneUnit),...ie(e?void 0:H,i.blockGapUnit),...re(e?void 0:T,i.blockGapPhoneUnit),...oe(e?void 0:D)},"data-sf-headings":Ce(O),"data-sf-card-shadow":e?void 0:Ge(S),"data-sf-card-gap":e?void 0:Ee(R),"data-sf-card-hover":e?void 0:Ae(y),onClickCapture:h,children:[P?o("style",{"data-sf-text-styles":"",dangerouslySetInnerHTML:{__html:P}}):null,o(ae,{grayscale:e?void 0:L,children:o(ze,{value:Fe,children:C(de,{ink:me(r),children:[o(Me,{style:$,children:u}),f,p]})})})]})}const pt=n=>{n.target?.closest?.("a")&&n.preventDefault()};export{Fe as EDITING_BRIDGES,Me as EditorPageBody,ht as EditorThemedBody,ut as PageWidthWrapper,gt as PublishedPageFrame,Ve as SECTION_PREVIEW_CANVAS,Oe as SECTION_PREVIEW_CANVAS_TAIL,St as pageWidthTokens,pt as suppressPreviewNav};
1
+ import{jsx as o,Fragment as M,jsxs as P}from"react/jsx-runtime";import{accentItalicCss as $,storedTextStyles as K,textStylesCss as X}from"../../../render/lib/text-styles/site-text-styles.js";import{pageWidthMarker as Y,PAGE_WIDTH_ATTR as q,siteWidthTokens as J,siteGutterTokens as Q,siteGutterPhoneClass as Z,siteGutterPhoneTokens as ee,heroBackgroundTokens as te}from"../../../format/lib/content/page-width.js";import{siteBlockGapPhoneClass as oe,siteBlockGapPhoneTokens as ne,siteBlockGapTokens as re}from"../../../format/lib/content/container-gap.js";import{usePreviewHeader as ie}from"../../../render/components/PreviewHeaderContext.js";import{SitePhotographyProvider as se}from"../../../render/components/SitePhotographyContext.js";import{ThemeLightInkProvider as ae}from"../../../render/components/ThemeLightInkContext.js";import{CORNER_STYLE_TO_PX as de,normalizeCornerStyle as ce,normalizeCornerRadius as le,themeColorStyle as pe,themeLightInk as he,typeSizesStyle as me,headingTypographyStyle as ue,normalizeHeadingTypography as fe,themeAccentStyle as ge,themeButtonStyle as Se,themePresetAccentVars as ye,themeSurfaceStyle as xe,siteCornerRadiusTokens as Te,shadowColorTokens as ke,headingCompressionAttr as Ce,cardShadowAttr as Pe,cardGapAttr as Ge,hoverEffectAttr as Ee}from"../../../format/lib/theme.js";import{fontRoleStyle as Ae}from"../../../format/lib/fonts.js";import{wordStyleTokens as ve}from"../../../format/lib/word-styles.js";import{isStandaloneSectionDocument as _e,pageHasHeaderSection as G,pageTakesTopSpace as Be,topSpaceMarker as Re,TOP_SPACE_ATTR as Ie,HEADER_CLEARANCE_CLASS as we}from"../../../render/lib/document/header-clearance.js";import{leadSectionInk as He,HEADER_INK_ATTR as We}from"../../../render/lib/document/header-ink.js";import{useEasel as be}from"efficient-easel/easel";import{useCardContentSwitchPass as Ne}from"../../components/useCardContentSwitchPass.js";import{pageBackgroundVars as De}from"../../../format/lib/content/page-background.js";import{pageWidthTokens as Fe}from"../../../render/lib/document/page-frame.js";import{EditingBridgesProvider as Le}from"../../../render/lib/document/editing-bridges.js";import Ue from"../../components/SectionTextPartBridge.js";import{PageContentsFromDocument as E}from"../../../render/components/PageContentsContext.js";const ze={SectionTextParts:Ue};import{PageWidthWrapper as ft,PublishedPageFrame as gt,pageWidthTokens as St}from"../../../render/lib/document/page-frame.js";const je="color-mix(in oklab, var(--bg) 40%, #ffffff)",Ve="12vh";function Oe({style:n,children:i}){const{appState:s}=be(g=>g),t=s.data.content,r=s.data.root;if(_e(t))return o("div",{className:"sf-themed-content",style:{...n,background:je,minHeight:"100vh",paddingBottom:Ve},children:o("div",{style:{background:"var(--bg)"},children:o(E,{content:t,children:i})})});const a=G(t)&&Be(r,t),d=G(t)?Re(r,t):null,m=d?{[Ie]:d}:null,c=Y(r?.widthChoice),u=c?{[q]:c}:null,l=a?null:He(t),f=l?{[We]:l}:null;return o("div",{className:`sf-themed-content${a?` ${we}`:""}`,style:n,...f,...m,...u,children:o("div",{style:{background:"var(--bg)",minHeight:"100%"},children:o(E,{content:t,children:i})})})}function pt({propsTheme:n,propsFonts:i,propsCornerStyle:s,propsCornerRadiusPx:t,propsHeadingCompression:r,propsHeadingTypography:a,pageBackground:d,chromeInheritsSiteBackground:m,suppressPreviewNav:c,footer:u,overlay:l,children:f}){return Ne(),o(Me,{propsTheme:n,propsFonts:i,propsCornerStyle:s,propsCornerRadiusPx:t,propsHeadingCompression:r,propsHeadingTypography:a,pageBackground:d,chromeInheritsSiteBackground:m,onClickCapture:c,body:g=>P(M,{children:[o(Oe,{style:g,children:f}),u,l]})})}function Me({propsTheme:n,propsFonts:i,propsCornerStyle:s,propsCornerRadiusPx:t,propsHeadingCompression:r,propsHeadingTypography:a,pageBackground:d,chromeInheritsSiteBackground:m,onClickCapture:c,body:u}){const{theme:l,fonts:f,sizes:g,cornerRadiusPx:A,cardShadow:S,shadowColor:v,cardGap:_,hoverEffect:y,headingCompression:B,siteWidth:R,siteGutter:I,siteGutterPhone:x,blockGap:w,blockGapPhone:T,siteLengthUnits:H,headingTypography:W,heroBackgroundFollowsWidth:b,photographyGrayscale:N,textStyles:D,wordStyles:F,themeFromDocument:e}=ie(),p=e?n:l,L=e?i:f,U=e?void 0:g,z=e?t===void 0?de[ce(s)]:le(t):A,h=e?{}:H,j=e?r:B,k=e?a:W,C=[X(K(e?void 0:D)),$(fe(k).italicStrong)].filter(Boolean).join(`
2
+ `),V=Fe(),O={...pe(p),...me(U),...ue(k),...V.style,...m?{}:De(d)};return P("div",{className:`sf-theme-surfaces sf-theme-accent ${[Z(e?void 0:x),oe(e?void 0:T)].filter(Boolean).join(" ")}`.trim(),style:{...Ae(L),...ve(e?null:F),...ge(p),...Se(p),...ye(p),...xe(p),...Te(z,h.cornerRadiusUnit),...ke(e?void 0:S,e?void 0:v,e?void 0:y),...J(e?void 0:R,h.siteWidthUnit),...Q(e?void 0:I,h.siteGutterUnit),...ee(e?void 0:x,h.siteGutterPhoneUnit),...re(e?void 0:w,h.blockGapUnit),...ne(e?void 0:T,h.blockGapPhoneUnit),...te(e?void 0:b)},"data-sf-headings":Ce(j),"data-sf-card-shadow":e?void 0:Pe(S),"data-sf-card-gap":e?void 0:Ge(_),"data-sf-card-hover":e?void 0:Ee(y),onClickCapture:c,children:[C?o("style",{"data-sf-text-styles":"",dangerouslySetInnerHTML:{__html:C}}):null,o(se,{grayscale:e?void 0:N,children:o(Le,{value:ze,children:o(ae,{ink:he(p),children:u(O)})})})]})}const ht=n=>{n.target?.closest?.("a")&&n.preventDefault()};export{ze as EDITING_BRIDGES,Oe as EditorPageBody,pt as EditorThemedBody,ft as PageWidthWrapper,gt as PublishedPageFrame,je as SECTION_PREVIEW_CANVAS,Ve as SECTION_PREVIEW_CANVAS_TAIL,Me as SiteThemeCarrier,St as pageWidthTokens,ht as suppressPreviewNav};
@@ -1,4 +1,4 @@
1
- export declare const BOX_SHAPES: ("auto" | "tall" | "square" | "wide" | "landscape" | "portrait" | "video" | "panorama" | "story" | "poster" | "screen")[];
1
+ export declare const BOX_SHAPES: ("auto" | "square" | "video" | "screen" | "tall" | "wide" | "landscape" | "portrait" | "panorama" | "story" | "poster")[];
2
2
  export type BoxShape = (typeof BOX_SHAPES)[number];
3
3
  export declare function boxShapeOf(value: unknown): BoxShape;
4
4
  export declare function boxShapeClass(value: unknown): string;
@@ -8,7 +8,7 @@ export declare function cardTemplateSlot(): {
8
8
  type: "slot";
9
9
  allow: string[];
10
10
  };
11
- export declare const CARD_LIST_ITEM_BLOCKS: ("Flex" | "Text" | "ImageBlock")[];
11
+ export declare const CARD_LIST_ITEM_BLOCKS: ("Text" | "ImageBlock" | "Flex")[];
12
12
  export declare function cardListItemSlot(): {
13
13
  type: "slot";
14
14
  allow: string[];
@@ -70,16 +70,16 @@ export declare function resolveSectionStick(props: SectionStickProps, opts?: {
70
70
  }): {
71
71
  desktop: boolean;
72
72
  desktopDistance: number;
73
- desktopUnit: "%" | "px" | "vw";
73
+ desktopUnit: "px" | "%" | "vw";
74
74
  desktopScreens: number;
75
75
  tablet: boolean;
76
76
  tabletDistance: number;
77
- tabletUnit: "%" | "px" | "vw";
77
+ tabletUnit: "px" | "%" | "vw";
78
78
  tabletScreens: number;
79
79
  ownTablet: boolean;
80
80
  phone: boolean;
81
81
  phoneDistance: number;
82
- phoneUnit: "%" | "px" | "vw";
82
+ phoneUnit: "px" | "%" | "vw";
83
83
  phoneScreens: number;
84
84
  ownPhone: boolean;
85
85
  };
@@ -1 +1 @@
1
- import{cardListItemSlot as t}from"../../../../content/card-row-keys.js";const e={template:t()},l={label:"Card list",inline:!0,fields:e,defaultProps:{rowField:""}};export{l as CardListMeta,e as CardListSlots};
1
+ import{GENERAL_SLOTS as t}from"../slots.js";const r=t.CardList,i={label:"Card list",inline:!0,fields:r,defaultProps:{rowField:""}};export{i as CardListMeta,r as CardListSlots};
@@ -1 +1 @@
1
- import{cardTemplateSlot as e}from"../../../../content/card-row-keys.js";const l={eyebrow:"Label",title:"Section *heading.*"},t={template:e()},r={label:"Cards",fields:t,defaultProps:{eyebrow:"",title:"",items:[],columns:3}};export{l as CARDS_PH,r as CardsMeta,t as CardsSlots};
1
+ import{GENERAL_SLOTS as e}from"../slots.js";const r={eyebrow:"Label",title:"Section *heading.*"},t=e.Cards,s={label:"Cards",fields:t,defaultProps:{eyebrow:"",title:"",items:[],columns:3}};export{r as CARDS_PH,s as CardsMeta,t as CardsSlots};
@@ -1 +1 @@
1
- import{PH as e}from"../../placeholders.js";import{cardTemplateSlot as t}from"../../../../content/card-row-keys.js";const n={num:e.sectionNumber,title:"Frequently *asked.*",link:"View all questions"},l={template:t()},r={label:"Q&A",inline:!0,fields:l,defaultProps:{num:"",title:"",linkText:"",linkHref:"/faq",defaultOpen:!0,items:[]}};export{r as FAQMeta,l as FAQSlots,n as FAQ_PH};
1
+ import{PH as e}from"../../placeholders.js";import{GENERAL_SLOTS as t}from"../slots.js";const o={num:e.sectionNumber,title:"Frequently *asked.*",link:"View all questions"},l=t.FAQ,r={label:"Q&A",inline:!0,fields:l,defaultProps:{num:"",title:"",linkText:"",linkHref:"/faq",defaultOpen:!0,items:[]}};export{r as FAQMeta,l as FAQSlots,o as FAQ_PH};
@@ -1 +1 @@
1
- import{phoneKey as t}from"efficient-easel/screen/lib/content/view-tiers";const o={rowTitle:{type:"slot",allow:["Text"]},content:{type:"slot"}},r={label:"Box",fields:o,phoneOrder:{prop:t("order"),slot:"content"},defaultProps:{direction:"row",justify:"start",align:"stretch",wrap:!0,content:[],share:"equal",blockSpacing:"gap",padV2:!0,sectionPaddingTop:24,sectionPaddingBottom:24}};export{r as FlexMeta,o as FlexSlots};
1
+ import{phoneKey as o}from"efficient-easel/screen/lib/content/view-tiers";import{GENERAL_SLOTS as t}from"../slots.js";const e=t.Flex,p={label:"Box",fields:e,phoneOrder:{prop:o("order"),slot:"content"},defaultProps:{direction:"row",justify:"start",align:"stretch",wrap:!0,content:[],share:"equal",blockSpacing:"gap",padV2:!0,sectionPaddingTop:24,sectionPaddingBottom:24}};export{p as FlexMeta,e as FlexSlots};