efficient-web-builder 67.5.0 → 67.7.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 (84) hide show
  1. package/CHANGELOG.md +41 -0
  2. package/dist/editor/components/storefront-editor.css +3 -1
  3. package/dist/editor/lib/document/ColourControl.d.ts +2 -1
  4. package/dist/editor/lib/document/ColourControl.js +1 -1
  5. package/dist/editor/lib/document/blocks/general/Flex/fields.js +1 -1
  6. package/dist/editor/lib/document/blocks/general/HeroSlide/fields.js +1 -1
  7. package/dist/editor/lib/document/blocks/general/HostPart/fields.d.ts +2 -0
  8. package/dist/editor/lib/document/blocks/general/HostPart/fields.js +1 -0
  9. package/dist/editor/lib/document/blocks/general/index.d.ts +2 -2
  10. package/dist/editor/lib/document/blocks/general/index.js +1 -1
  11. package/dist/editor/lib/document/blocks/shared-fields.js +1 -1
  12. package/dist/editor/lib/document/build-config.js +1 -1
  13. package/dist/editor/lib/document/controls.d.ts +5 -2
  14. package/dist/editor/lib/document/controls.js +1 -1
  15. package/dist/editor/lib/sections/text-layouts.js +1 -1
  16. package/dist/format/lib/content/box-background.d.ts +13 -0
  17. package/dist/format/lib/content/box-background.js +1 -1
  18. package/dist/format/lib/content/button-icon.d.ts +1 -1
  19. package/dist/format/lib/content/button-icon.js +1 -1
  20. package/dist/format/lib/content/card-template.d.ts +1 -0
  21. package/dist/format/lib/content/card-template.js +1 -1
  22. package/dist/format/lib/content/count-numbers.js +1 -1
  23. package/dist/format/lib/content/gallery-layout.d.ts +11 -2
  24. package/dist/format/lib/content/gallery-layout.js +1 -1
  25. package/dist/format/lib/content/image-treatment.js +1 -1
  26. package/dist/format/lib/content/view-lines.d.ts +1 -0
  27. package/dist/format/lib/content/view-lines.js +1 -1
  28. package/dist/format/lib/document/blocks/block-types.d.ts +4 -0
  29. package/dist/format/lib/document/blocks/general/HostPart/meta.d.ts +2 -0
  30. package/dist/format/lib/document/blocks/general/HostPart/meta.js +1 -0
  31. package/dist/format/lib/document/blocks/general/metas.d.ts +1 -0
  32. package/dist/format/lib/document/blocks/general/metas.js +1 -1
  33. package/dist/format/lib/document/cap-hero-groups.js +1 -1
  34. package/dist/format/lib/document/general-order.d.ts +1 -1
  35. package/dist/format/lib/document/general-order.js +1 -1
  36. package/dist/format/lib/document/list-search-scopes.js +1 -1
  37. package/dist/format/lib/document/node-lists.d.ts +9 -0
  38. package/dist/format/lib/document/node-lists.js +1 -0
  39. package/dist/format/lib/document/passes/types.d.ts +4 -0
  40. package/dist/format/lib/document/renamed-props.js +1 -1
  41. package/dist/format/lib/document/section-catalog.js +1 -1
  42. package/dist/format/lib/document/seed-parts.d.ts +1 -1
  43. package/dist/format/lib/document/seed-parts.js +1 -1
  44. package/dist/format/lib/editor-words-catalogue.d.ts +9 -0
  45. package/dist/format/lib/editor-words-catalogue.js +3 -3
  46. package/dist/format/lib/hero-video.d.ts +1 -1
  47. package/dist/format/lib/hero-video.js +1 -1
  48. package/dist/format/lib/source-rules/no-hard-coded-option-rows.js +1 -1
  49. package/dist/format/lib/source-rules/own-key-reads.d.ts +5 -0
  50. package/dist/format/lib/source-rules/own-key-reads.js +9 -7
  51. package/dist/format/lib/source-rules/support/ts-program.d.ts +1 -0
  52. package/dist/format/lib/source-rules/support/ts-program.js +2 -2
  53. package/dist/render/components/ButtonBlock.js +1 -1
  54. package/dist/render/components/CardRowContext.d.ts +9 -1
  55. package/dist/render/components/CardRowContext.js +1 -1
  56. package/dist/render/components/Flex.d.ts +2 -1
  57. package/dist/render/components/Flex.js +1 -1
  58. package/dist/render/components/HeroPoster.d.ts +5 -1
  59. package/dist/render/components/HeroPoster.js +1 -1
  60. package/dist/render/components/HeroSlide.d.ts +5 -1
  61. package/dist/render/components/HeroSlide.js +1 -1
  62. package/dist/render/components/HeroVideoPlay.d.ts +4 -1
  63. package/dist/render/components/HeroVideoPlay.js +1 -1
  64. package/dist/render/components/SectionAnimation.d.ts +3 -0
  65. package/dist/render/components/SectionAnimation.js +1 -1
  66. package/dist/render/lib/animation/entrance.js +1 -1
  67. package/dist/render/lib/content/page-contents.js +1 -1
  68. package/dist/render/lib/document/blocks/general/Flex/render.js +1 -1
  69. package/dist/render/lib/document/blocks/general/HeroSlide/render.js +1 -1
  70. package/dist/render/lib/document/blocks/general/HostPart/render.d.ts +2 -0
  71. package/dist/render/lib/document/blocks/general/HostPart/render.js +1 -0
  72. package/dist/render/lib/document/blocks/general/renders.d.ts +1 -0
  73. package/dist/render/lib/document/blocks/general/renders.js +1 -1
  74. package/dist/render/lib/document/card-press-titles.js +1 -1
  75. package/dist/render/lib/document/head-core-boxes.js +1 -1
  76. package/dist/render/lib/document/hero-media-parts.d.ts +2 -0
  77. package/dist/render/lib/document/hero-media-parts.js +1 -1
  78. package/dist/render/lib/document/passes/clickable-parts.js +1 -1
  79. package/dist/render/lib/document/passes/section-padding.d.ts +5 -2
  80. package/dist/render/lib/document/passes/section-padding.js +1 -1
  81. package/dist/render/lib/document/wall-labels.js +1 -1
  82. package/dist/render/lib/media.d.ts +15 -0
  83. package/dist/render/lib/media.js +1 -1
  84. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,46 @@
1
1
  # Changelog
2
2
 
3
+ ## 67.7.0 - 2026-11-12
4
+
5
+ From main at `2e8ecc58`: #727, #728, #725, #730, #731, #732, #733, #734. A minor: no `!`, no export is removed, the peers stay `efficient-easel` `^34.1.0` and `efficient-shell` `^12.33.0`. New exports, new icon values, one new block and optional fields, props and arguments only. No stored key or value moves.
6
+
7
+ **For hosts:**
8
+ - Nothing to change. A block that declares no inner padding keeps its old default (#728). Existing Button icons draw as before (#727).
9
+ - storefront-blocks: DetailRows, ProductGrid, Events and GalleryB can declare `innerPadding` (#728); `mapDocumentNodes` can move onto `node-lists` (#725).
10
+ - storefront-blocks: a lazy draw table keyed by `GeneralBlockType` (`src/render/lib/document/lazy-draws.tsx`) must add one line for `HostPart/render`, or `tsc` fails (#731). Do it in the PR that takes this release.
11
+
12
+ ### Added
13
+
14
+ - **Eight more Button icons** (#727): `BUTTON_ICONS` gains `phone`, `wheel`, `chat`, `chevron-left`, `package`, `truck`, `shield-check`, `receipt-refund`.
15
+ - **A block declares its inner padding default** (#728): optional `BlockRender.innerPadding` and `PassBlock.innerPadding`; new export `ownPairDefault`.
16
+ - **One node-list walker** (#725): new format module `lib/document/node-lists` with `mapEachNode`, `mapNodeLists`, `mapPageContent` and `ListNode`. The published passes walk node lists through it.
17
+ - **A card part inside a copy takes no hover lift** (#730): new export `CARD_NO_LIFT_CLASS` (lib/content/box-background).
18
+ - **A host part a host answers inside a copy** (#731): new block `HostPart` (type `HOST_PART_TYPE` in lib/content/card-template; not offered to a merchant); optional prop `CardTemplateRows.hostParts`. A host seeds `{ type: "HostPart", props: { name, label } }` in its template and passes `hostParts`. New exports `HostParts`, `HostPartsContext`, `HostPartDrawn`, `HostPartMeta`, `HostPartRender`, `HostPartFields`; `panelNote` and `PanelNoteLine` take optional word `values`; `GENERAL_REGISTRATION_ORDER` gains a last entry.
19
+ - **A gallery layout has a phone value** (#734): One across on a phone. New exports `GALLERY_PHONE_LAYOUTS`, `resolveGalleryPhoneLayout`, `galleryLayoutPhoneField`; `galleryLayoutClass` and `galleryLayoutCss` take an optional phone argument.
20
+ - **Source rules pin an own-key exemption to one function** (#733): `OwnKeyExemption` gains optional `within`, `OwnKeyPlace` optional `fn`; new export `enclosingFunctionName` (`support/ts-program`).
21
+
22
+ ### Fixed
23
+
24
+ - **A card template that names HostPart is refused when it registers** (#732), the same rule `buildConfig` applies. 0 hosts do this.
25
+
26
+ ## 67.6.0 - 2026-11-11
27
+
28
+ From main at `a2c1240e`: #721, #724, #722. A minor: no `!`, no export is removed, the peers stay `efficient-easel` `^34.1.0` and `efficient-shell` `^12.33.0`. New exports, one optional parameter and optional props only. No stored key or value moves.
29
+
30
+ **For hosts:**
31
+ - Nothing to change. Stored Hero slides draw the bytes they drew (#721). A caller of `markBoxProps` that passes a Fill gets the same props (#724). A Box with no fade keeps its flat Fill (#722).
32
+ - storefront: take this release to draw a Hero slide's phone video and phone poster (#721).
33
+ - storefront-blocks: `squareBox` can drop its cast now that the Fill is optional (#724).
34
+
35
+ ### Added
36
+
37
+ - **A Hero slide can carry its own phone video and phone poster** (#721): slide fields `mediaVideoPhone` and its own first frame `videoFramePhone`. The poster preloads per view; the AV1 source list is written only when there are two sources. New exports `EDGE_WIDE_MEDIA` (view-lines), `videoForView`, `videoSources`, `VideoFileSource`, `ViewVideoFiles` (media), `AV1_FILE_LABEL`, `AV1_FILE_PROMPT` (hero-media-parts) and `useViewWidthRead` (SectionAnimation); `loadingStill` takes an optional view argument; `HeroSlide`, `HeroPoster` and `HeroVideoPlayer` take optional phone and AV1 source props.
38
+ - **A Box's Fill can fade from the top down** (#722): the Fill takes Flat or Fade. New exports `BOX_FILL_FADES`, `BOX_FILL_FADE_PROP`, `boxFillFadeOf`, `boxFillFadeStyle` (lib/content/box-background); `InheritedColourRow` takes optional `children`; `Flex` reads the optional `fillFade` prop.
39
+
40
+ ### Changed
41
+
42
+ - **A Mark Box takes no Fill when a host gives none** (#724): `markBoxProps(size, fill?, look?)`. With no Fill, the props have no `fillColor` key.
43
+
3
44
  ## 67.5.0 - 2026-11-11
4
45
 
5
46
  From main at `bd876886`: #718, #719, #720. A minor: no `!`, no export is removed, the peers stay `efficient-easel` `^34.1.0` and `efficient-shell` `^12.33.0`. New exports, one widened type and optional props only. No stored key or value moves.
@@ -2873,8 +2873,10 @@
2873
2873
  color: var(--sf-muted);
2874
2874
  }
2875
2875
 
2876
+ /* Under the swatch and the hex, in the colour row's one column
2877
+ (lib/document/ColourControl `ColourRow`): the column's gap (8) is the
2878
+ space above it. */
2876
2879
  .sf-readability {
2877
- margin-top: var(--space-12);
2878
2880
  padding: var(--space-12) var(--space-12) var(--space-12);
2879
2881
  border: 1px solid var(--sf-divider);
2880
2882
  border-radius: var(--sf-row-radius);
@@ -25,7 +25,7 @@ export declare function ColourRow({ label, icon, changed, hint, onReset, resetTo
25
25
  resetTo?: string;
26
26
  children?: ReactNode;
27
27
  }): import("react").JSX.Element;
28
- export declare function InheritedColourRow({ label, icon, value, inherited, resetTo, onChange, onReset, hint, choices, }: {
28
+ export declare function InheritedColourRow({ label, icon, value, inherited, resetTo, onChange, onReset, hint, choices, children, }: {
29
29
  label: string;
30
30
  icon?: ReactElement;
31
31
  value: string;
@@ -35,4 +35,5 @@ export declare function InheritedColourRow({ label, icon, value, inherited, rese
35
35
  onReset: () => void;
36
36
  hint?: ReactNode;
37
37
  choices?: readonly ColourChoice[];
38
+ children?: ReactNode;
38
39
  }): import("react").JSX.Element;
@@ -1 +1 @@
1
- "use client";import{jsx as r,jsxs as m}from"react/jsx-runtime";import{useRef as C}from"react";import{ColorPicker as w,ColorPickerPanel as x,ColorSwatch as b,HexInput as S,Popover as N,Tooltip as P,colorFill as k,colorSwatchClasses as T,useShellStrings as E}from"efficient-shell/ui";import{SettingsDefaultReset as R,SettingsField as _}from"efficient-easel/panel";import{typedHex as p}from"efficient-easel/pick";import{usePreviewHeader as j}from"../../../render/components/PreviewHeaderContext.js";import{editorEaselWords as F,say as g}from"../../../format/lib/editor-words.js";import{themePresets as I}from"../../../format/lib/document/theme-slots.js";import{SITE_STYLE_UNSET_LABEL as L}from"../../../format/components/SiteStyleUnset.js";function y({value:e,onChange:i,label:o,id:a,caption:s,inherited:c,ariaLabel:t,choices:n}){return r(B,{value:e,onChange:i,label:g(t??o),id:a,caption:s,inherited:c,choices:n})}function z(){const{theme:e}=j();return I(e)}function B({value:e,onChange:i,label:o,id:a,caption:s,inherited:c,choices:t}){const n=z(),l=e?null:p(c??""),d=s!==void 0&&(!e||p(s)!==p(e))?s:null,f=h=>{h!==e&&i(h)};return m("div",{className:"sf-colour",children:[t?r(H,{id:a,value:e,onChange:i,label:o,presets:n,follows:l,choices:t}):r(w,{id:a,value:e,onChange:f,label:o,presets:n,fallback:l??void 0,size:"md",align:"start"}),d!==null?r("span",{className:"sf-colour-caption",children:d}):r("span",{className:"sf-colour-hexwrap",children:r(S,{value:e||l||"",onChange:f,label:g("{label} hex code",{label:o}),placeholder:e||l?void 0:g(L),className:l?"sf-colour-hex is-inherited":"sf-colour-hex",size:"md"})})]})}function H({value:e,onChange:i,label:o,id:a,presets:s,follows:c,choices:t}){const n=E().color,l=e||c||"",d=t.findIndex(u=>u.selected),f=d>=0,h=C(d);return f&&(h.current=d),r(N,{id:a,trigger:r("span",{"aria-hidden":"true",className:"absolute inset-0",style:k(l)}),triggerLabel:n.swatch(o,l.toUpperCase()||n.none),triggerClassName:T({size:"md"}),"aria-label":n.panel(o),align:"start",children:m("div",{className:"sf-colour-window",children:[r("div",{role:"group","aria-label":o,className:"sf-colour-choices",children:t.map(u=>r(P,{content:u.label,children:r(b,{color:u.color,"aria-label":u.label,selected:u.selected,onClick:()=>{u.selected||u.onPick()}})},u.label))}),r(x,{value:f?"":e,onChange:i,label:o,presets:s,fallback:(f?l:c)??void 0},h.current)]})})}function W({label:e,icon:i,changed:o,hint:a,onReset:s,resetTo:c,children:t,...n}){return m(_,{label:e,icon:i,htmlFor:n.id,changed:o,hint:a,action:s?r(R,{words:F()?.panel,label:e,changed:!!o,detail:c,onReset:s}):void 0,children:[y({...n,label:e}),t]})}function M({label:e,icon:i,value:o,inherited:a,resetTo:s,onChange:c,onReset:t,hint:n,choices:l}){const d=!!o;return r(W,{label:e,icon:i,value:o,inherited:d?void 0:a,onChange:c,changed:d,onReset:t,resetTo:s,hint:n,choices:l})}export{y as ColourControl,W as ColourRow,M as InheritedColourRow,z as useThemePresets};
1
+ "use client";import{jsx as r,jsxs as m}from"react/jsx-runtime";import{useRef as w}from"react";import{ColorPicker as x,ColorPickerPanel as b,ColorSwatch as N,HexInput as S,Popover as P,Tooltip as k,colorFill as T,colorSwatchClasses as E,useShellStrings as R}from"efficient-shell/ui";import{SettingsDefaultReset as _,SettingsField as j}from"efficient-easel/panel";import{typedHex as p}from"efficient-easel/pick";import{usePreviewHeader as F}from"../../../render/components/PreviewHeaderContext.js";import{editorEaselWords as I,say as g}from"../../../format/lib/editor-words.js";import{themePresets as L}from"../../../format/lib/document/theme-slots.js";import{SITE_STYLE_UNSET_LABEL as v}from"../../../format/components/SiteStyleUnset.js";function C({value:e,onChange:i,label:o,id:a,caption:s,inherited:c,ariaLabel:t,choices:n}){return r(z,{value:e,onChange:i,label:g(t??o),id:a,caption:s,inherited:c,choices:n})}function y(){const{theme:e}=F();return L(e)}function z({value:e,onChange:i,label:o,id:a,caption:s,inherited:c,choices:t}){const n=y(),l=e?null:p(c??""),f=s!==void 0&&(!e||p(s)!==p(e))?s:null,d=h=>{h!==e&&i(h)};return m("div",{className:"sf-colour",children:[t?r(B,{id:a,value:e,onChange:i,label:o,presets:n,follows:l,choices:t}):r(x,{id:a,value:e,onChange:d,label:o,presets:n,fallback:l??void 0,size:"md",align:"start"}),f!==null?r("span",{className:"sf-colour-caption",children:f}):r("span",{className:"sf-colour-hexwrap",children:r(S,{value:e||l||"",onChange:d,label:g("{label} hex code",{label:o}),placeholder:e||l?void 0:g(v),className:l?"sf-colour-hex is-inherited":"sf-colour-hex",size:"md"})})]})}function B({value:e,onChange:i,label:o,id:a,presets:s,follows:c,choices:t}){const n=R().color,l=e||c||"",f=t.findIndex(u=>u.selected),d=f>=0,h=w(f);return d&&(h.current=f),r(P,{id:a,trigger:r("span",{"aria-hidden":"true",className:"absolute inset-0",style:T(l)}),triggerLabel:n.swatch(o,l.toUpperCase()||n.none),triggerClassName:E({size:"md"}),"aria-label":n.panel(o),align:"start",children:m("div",{className:"sf-colour-window",children:[r("div",{role:"group","aria-label":o,className:"sf-colour-choices",children:t.map(u=>r(k,{content:u.label,children:r(N,{color:u.color,"aria-label":u.label,selected:u.selected,onClick:()=>{u.selected||u.onPick()}})},u.label))}),r(b,{value:d?"":e,onChange:i,label:o,presets:s,fallback:(d?l:c)??void 0},h.current)]})})}function H({label:e,icon:i,changed:o,hint:a,onReset:s,resetTo:c,children:t,...n}){return r(j,{label:e,icon:i,htmlFor:n.id,changed:o,hint:a,action:s?r(_,{words:I()?.panel,label:e,changed:!!o,detail:c,onReset:s}):void 0,children:t?m("div",{className:"es-width-stack",children:[C({...n,label:e}),t]}):C({...n,label:e})})}function M({label:e,icon:i,value:o,inherited:a,resetTo:s,onChange:c,onReset:t,hint:n,choices:l,children:f}){const d=!!o;return r(H,{label:e,icon:i,value:o,inherited:d?void 0:a,onChange:c,changed:d,onReset:t,resetTo:s,hint:n,choices:l,children:f})}export{C as ColourControl,H as ColourRow,M as InheritedColourRow,y as useThemePresets};
@@ -1 +1 @@
1
- import{jsx as r}from"react/jsx-runtime";import{phoneKey as i,tabletKey as l}from"efficient-easel/draw";import{BOX_CARD_PAD as E,BOX_SWATCH_PROP as ko,boxCardProps as Ho,boxIsCard as L}from"../../../../../../format/lib/content/box-background.js";import{BOX_IS_CARD_RULE as Fo,BOX_IS_NOT_CARD_RULE as Wo,BOX_ROW_IMAGE_PROP as yo}from"../../../../../../format/lib/content/box-card-rule.js";import{CARD_ROW_FACTS as Bo,cardRowField as M,cardRowFields as xo,cardRowLinkField as Uo,typedLinkField as Mo}from"../../../card-row-fields.js";import{CARD_ROW_LINK_PROP as Ko,cardCopyPlace as K,cardTemplateCardOwner as Xo}from"../../../../../../format/lib/content/card-template.js";import{BOX_SHOW_KEY as Go,HOVER_GROUP_KEY as Yo,HOVER_KEY as T}from"../../../../../../format/lib/animation/hover.js";import{BOX_HIGHLIGHT_ROW as vo,BOX_NEXT_PICTURE_ROW as jo}from"../../../../animation/hover-fields.js";import{darkenFields as Vo}from"../../../darken-fields.js";import{BOX_TAB_SHAPES as Jo,REEL_SHAPE_LABELS as zo}from"../../../../../../format/lib/reel.js";import{LAYOUT_CELL as X,CARD_LIST_STYLE_PICTURES as qo,TAB_SHAPE_PICTURES as Qo}from"../../../choice-pictures.js";import{CARD_STYLE_KEY as A,CARD_STYLE_POINTS as Zo,applyCardStyle as $o,isCardStyle as oe}from"../../../../../../render/lib/sections/card-list-style.js";import{deviceField as a}from"efficient-easel/screen/lib/document/device-fields";import{ChevronDownIcon as ee,ClockIcon as ne,CropIcon as G,GapIcon as te,MediaLayoutStackedIcon as Y,LineBetweenIcon as re,LineSolidIcon as ie,ListIcon as le,NumberedListIcon as v,ShadowIcon as ae,StylesIcon as j,TableIcon as V,TargetIcon as se,WrapIcon as J}from"efficient-easel/icons";import{boxBlockSpacingField as de,boxFillField as ce,boxColumnsFields as _e,boxShareField as pe,boxSharePhoneField as Oe,boxShareTabletField as Se,containerDirectionField as me,containerGapRows as fe,linkField as Re,plainText as he,swapPadding as z,toggle as c,upload as q,withPanelOnly as ue}from"../../../controls.js";import{BOX_STACK_LINE as g,BOX_STACK_RANGE as R,STACK_BELOW_PROP as N}from"../../../../../../render/lib/content/box-stack-line.js";import{BOX_SHAPES as Q,boxShapeOf as Ce}from"../../../../../../format/lib/content/box-shape.js";import{BOX_ANGLE_PROP as Ae}from"../../../../../../format/lib/content/box-angle.js";import{shapeLines as Z}from"../../../../../../format/lib/content/gallery-card-layout.js";import{shapePickerRow as $}from"../../../shape-picker.js";import{ACCORDION_COLUMN_COUNTS as we,ACCORDION_PHONE_COLUMN_COUNTS as Ee,BOX_COLUMNS_MAX as b,BOX_COLUMNS_MIN as P,boxPhoneRowOneLine as Te,boxWrapWordOf as oo}from"../../../../../../format/lib/content/box-layout.js";import{BOX_SEPARATOR_POINTS as eo}from"../../../../../../format/lib/content/box-separator.js";import{BOX_WRAP_LABEL as no,VIEW_KEY_ACCESS as s,group as h,phoneTwinFields as d}from"efficient-easel/screen/lib/document/box-fields";import{angleRow as Ne,boxAlignField as De,boxJustifyField as Ie,boxWrapField as D,iconPickerRow as k,placementField as Le,select as H,sidesPaddingFields as to,slider as ro}from"../../../box-fields.js";import{withRowRules as ge,withShowWhen as F}from"../../../../../../render/lib/document/show-when.js";import{separatorField as be}from"../../../separator-field.js";import{LOOP_SCROLLS as Pe}from"../../../../../../format/lib/animation/index.js";import{DEFAULT_TICKER_JOIN as ke,TICKER_JOIN_OPTIONS as He}from"../../../../../../format/lib/sections/ticker-join.js";import{NOT_HELD_BY_A_NODE as io}from"../../../../../../format/lib/document/passes/document-position.js";import{BOX_SIDE_SPACE_PROP as lo}from"../../../../../../format/lib/content/box-side-space.js";import{boxSideSpaceField as Fe}from"../../../box-side-space-field.js";import{accordionOnSet as We}from"../../../box-accordion-seed.js";import{ACCORDION_ROW_STYLE_POINTS as ye,ACCORDION_ROW_STYLE_PROP as I}from"../../../../../../format/lib/content/accordion-row-style.js";import{FlexSlots as ao}from"../../../../../../format/lib/document/blocks/general/Flex/meta.js";import{BOX_TYPE as Be,CONTAINER_BLOCKS_SLOT as xe}from"../../../../../../format/lib/document/container-blocks.js";import{boxPhoneOrderField as Ue}from"../../../box-phone-order-field.js";import{CARD_BOX_FACTS as Me,ON_A_CARD as so,ON_A_PICTURE_OR_CARD as Ke,cardDisplayField as W}from"../../../card-display-chips.js";import{MIRROR_CARDS_FACTS as Xe,MIRROR_CARDS_MIRRORS as Ge,mirrorCardsField as Ye}from"../../../mirror-cards-field.js";import{handedRowOf as co}from"../../../../../../format/lib/document/row-hand.js";import{SHOW_FOR_FACTS as ve,showForField as je,showForFields as Ve}from"../../../show-for-field.js";import{SHARED_COLUMNS_KEY as u,SHARED_COLUMNS_LABEL as _o,SHARED_COLUMNS_OFF as po,sharedColumnsDrawn as Oo,sharedColumnsFits as So,SHARED_COLUMNS_PHONE_POINTS as Je,SHARED_COLUMNS_POINTS as ze,sharedRowsDrawn as qe}from"../../../../../../render/lib/content/box-shared-columns.js";const mo=Fo,fo={all:[{field:"phoneRow",in:[2,3]},{not:{field:"direction",is:"accordion"}}]},Qe={field:"direction",is:"tabs"},Ze={field:"line",in:[!0,!1]},$e={field:"anchor",set:!0},y=["fixed","screen","fill"],on={not:{any:[{field:"sectionHeightMode",in:y},{field:"sectionHeightModeTablet",in:y},{field:"sectionHeightModePhone",in:y}]}},en={context:"parent.line",is:!0},_={not:{field:"direction",is:"accordion"}},Ro={field:"direction",is:"accordion"},ho={any:[_,{not:{field:I,in:["numbered","chevron"]}},{field:"columns",in:[...we]},{field:"phoneRow",in:[...Ee]}]},uo="notAccordionRow",nn={not:{context:uo,is:!0}},tn={[uo]:(o,e)=>e.parent?.props?.direction!=="accordion"},B={field:"direction",is:"row",default:"row"},p={not:Pe},O={all:[B,p,{not:{field:"separator",in:eo.map(o=>o.value)}},{not:{field:"line",is:!0}}]},rn={field:"direction",is:"column"},Co={all:[O,...["columns",l("columns")].map(o=>({not:{field:o,in:Array.from({length:b},(e,n)=>n+P)}}))]},ln={all:[p,{not:{all:[B,{field:"separator",in:eo.map(o=>o.value)}]}}]},x={not:{all:[O,{field:"columns",in:Array.from({length:b},(o,e)=>e+P)}]}},an="sharedColumnsFits",Ao="sharedColumnsMisfit",wo="sharedColumnsDraws",Eo="sharedColumnsPhoneDraws";function S(o,e){return Ho(o.props??{},K(e.appState,o.props?.id)?.inCopy!==!1)}const sn={[an]:(o,e)=>So(S(o,e)),[Ao]:(o,e)=>!So(S(o,e)),[wo]:(o,e)=>Oo(S(o,e)).desktop,[Eo]:(o,e)=>Oo(S(o,e)).phone};function To(o){return{all:[{not:{context:Ao,is:!0}},{any:[so,{field:o,set:!0}]}]}}const m={not:{context:wo,is:!0}},C={not:{context:Eo,is:!0}},No="sharedRowsDraws",dn={[No]:(o,e)=>qe(S(o,e))&&co(e.appState,o.props?.id)?.row===void 0},w={not:{context:No,is:!0}},cn={any:[m,C]},U=Wo,_n={not:{context:Ge,is:!0}},Do="rowHanded",pn={not:{context:Do,is:!0}},On={[Do]:(o,e)=>{const n=co(e.appState,o.props?.id);return n===void 0?void 0:n?.row!==void 0}},Io={all:[_,U,m,C,_n]},Sn={field:"direction",is:"row"},mn={field:"align",in:["start","center","end"]},fn={all:[{field:"darken",set:!0},{not:{field:"darken",in:[0,"0"]}}]};function Rn(){const{darken:o,darkenStyle:e}=Vo();return{...d("darken",o,s),...d("darkenStyle",e,s)}}const Lo={not:{all:[O,{field:l("columns"),in:Array.from({length:b},(o,e)=>e+P)}]}};function hn(){const o=c(no,!1,r(J,{})),e=n=>{const t=oo(n);return t===void 0?void 0:t==="wrap"};return{...D(),render:n=>o.render({...n,value:e(n.value),follows:e(n.follows)??!1,onChange:t=>n.onChange(t===void 0?void 0:t?"wrap":"nowrap")})}}function un(){const o=c(no,!0,r(J,{})),e=n=>{const t=oo(n);return t===void 0?void 0:t==="wrap"};return{...D(),render:n=>{const t=n.followsView==="tablet";return o.render({...n,value:e(n.value),follows:!Te(void 0,t?n.follows:void 0),followsNoView:!t,onChange:f=>n.onChange(f===void 0?void 0:f?"wrap":"nowrap")})}}}const go={hint:g},bo={all:[U,{any:[rn,{all:[O,Lo,{not:{all:[Co,{field:l("share"),set:!0}]}}]}]}]},Cn=F(a("desktop",ro("Narrows below",r(Y,{}),R.min,R.max,R.step,g,{kind:"breakpoint"},{clear:go,hint:"Under this screen width the side space narrows and the Phone Padding is used."})),bo);function An(o,e){const n=o;return!(N in n)||e.direction!=="column"?o:{...n,[N]:Cn}}const St={fields:ge({_gContent:h("Content"),rowTitle:ao.rowTitle,content:ao.content,_gCardDisplay:h("Display"),cardDisplay:W("desktop"),cardDisplayTablet:W("tablet"),cardDisplayPhone:W("mobile"),showFor:je(),_gLayout:h("Layout"),direction:me("Flex"),tabShape:k("Tab shape",r(j,{}),Jo.map(o=>({label:zo[o],value:o,picture:Qo[o]})),"tabs",{columns:2,cell:X}),mirrorCards:Ye(),[N]:a("desktop",ro("Stacks below",r(Y,{}),R.min,R.max,R.step,g,{kind:"breakpoint"},{clear:go,hint:"Under this screen width the blocks stand one under another, with the Phone Gap and Padding."})),[lo]:Fe(),startsOpen:a("desktop",c("Starts open",!1,r(ee,{}))),[I]:a("desktop",k("Row style",r(v,{}),ye.map(o=>({...o,picture:o.value==="numbered"?r(v,{}):r(le,{})})),"plain",{columns:2})),label:ue(he("Tab name")),...fe("Flex"),...d("justify",Ie(),s),...d("align",De(),s),...(()=>{const o=d("wrap",D(),s,{phoneRow:un()}),e=d("wrap",D(),s,{phoneRow:hn()});return{wrap:e.wrap,[l("wrap")]:e[l("wrap")],[i("wrap")]:o[i("wrap")]}})(),[i("order")]:Ue(),...d("boxShape",$("Box shape",r(G,{}),Z(Q),"shape","auto"),s,{phoneRow:$("Box shape",r(G,{}),Z(Q),"shape","auto",{phoneRest:o=>Ce(o)})}),[Ae]:a("desktop",Ne(0,{clear:{hint:0},hint:"Turns the box. 0° is straight."})),separator:be(r(re,{size:18}),"none"),[A]:a("desktop",k("Card style",r(j,{}),Zo.map(o=>({...o,picture:qo[o.value]})),"table",{columns:2,cell:X})),share:a("desktop",pe()),[l("share")]:Se(),[i("share")]:Oe(),[u]:a("desktop",H(_o,r(V,{}),[...ze],po)),[i(u)]:a("mobile",H(_o,r(V,{}),[...Je],po)),..._e(),...d("blockSpacing",de(),s),line:c("Line",!1,r(ie,{}),"A line across the blocks, with a dot on each."),upcoming:c("Upcoming",!1,r(ne,{}),"Still to come: a hollow dot, and the gold line stops before it."),join:H("Join",r(te,{}),He,ke),_gShadow:h("Shadow"),...d("shadow",c("Shadow",!1,r(ae,{})),s),...d("fillColor",ce(),s),[ko]:M("Fill content","colour"),_gBackground:h("Background image"),bgImage:a("desktop",q("Image","image/*")),bgImagePhone:a("mobile",q("Image","image/*")),[yo]:M("Image content","image",{content:!0}),...Rn(),placement:Le("Content position"),_gLink:h("Link"),link:Mo(Re("Link to")),[Ko]:Uo(),jumpHighlight:c("Highlight when a link jumps here",!1,r(se,{}),"When a link lands on this Box's anchor, the Box gets a main color outline and its first block turns the main color.")},[[["darken","darkenStyle","placement"],mo],[[i("share")],{all:[fo,C]}],[[u],To(u)],[[i(u)],To(i(u))],[[i("wrap")],{all:[fo,p,C,w]}],[[i("order")],{all:[O,C,m]}],[["phoneRow"],C],[[I],{all:[Ro,{not:{field:I,is:"chevron"}}]}],[["tabShape"],Qe],[["rowTitle","startsOpen"],nn],[["align","blockSpacing",l("blockSpacing"),i("blockSpacing")],_],[[l("justify"),i("justify")],{all:[p,Io,w]}],[[l("align"),i("align")],{all:[Sn,mn,Io]}],[[l("wrap")],{all:[p,x,Lo,m,_,w]}],[[l("shadow"),i("shadow")],U],[[l("darken"),i("darken"),l("darkenStyle"),i("darkenStyle")],{all:[mo,fn]}],[["separator"],B],[[A],{field:A,set:!0}],[["columns"],{any:[O,Ro]}],[[l("columns")],O],[[N],bo],[[l("gap")],{all:[ln,ho]}],[["gap",i("gap")],ho],[["justify"],{all:[p,cn,_,w]}],[["wrap"],{all:[p,x,m,_,w]}],[["share"],{all:[x,m,_]}],[[l("share")],{all:[Co,m]}],[["line"],Ze],[["upcoming"],en],[["jumpHighlight"],$e],[["boxShape",l("boxShape"),i("boxShape")],on],[["direction","share",i("order")],pn],[["join"],io],[[lo],io]]),resolveData:(o,e)=>{const n=o.props,t=n[A];return e.changed?.[A]===!0&&oe(t)?{...o,props:$o(n,t,Be,xe)}:n.direction==="accordion"&&(e.trigger==="insert"||e.changed?.direction===!0)?{...o,props:We(n)}:o},resolveFields:(o,e)=>{const n=K(e.appState,o.props?.id)?.inCopy===!0,t=n&&Xo(e.appState,o.props?.id)===null;return An(Tn(Nn(Ve(Dn(o,{...e,fields:xo(e.fields,o,e)}),o.props),S(o,e),n),t),o.props)},showWhenFacts:{...Bo,...Me,...Xe,...On,...sn,...dn,...ve,...tn}},wn=F(vo,so),En=["darken","darkenStyle",Yo,Go];function Tn(o,e){if(!e)return o;const n={...o};for(const t of En){if(!(t in n))continue;const{showWhen:f,...Po}=n[t];n[t]=Po}return n}function Nn(o,e,n=!1){const t=o;return T in t&&L(e)&&n?{...t,[T]:F(jo,Ke)}:!(T in t)||L(e)?o:{...t,[T]:wn}}function Dn(...[o,e]){const{fields:n}=e;{if(L(S(o,e))){const f=to({fallback:{top:E.desktop,bottom:E.desktop,left:E.side,right:E.side},tablet:!0,siteSide:!0});return z(n,f)}return o.props.padV2!==!0?z(n,to({fallback:{top:24,bottom:24},tablet:!0,siteSide:!0})):n}}export{St as FlexFields};
1
+ import{jsx as r}from"react/jsx-runtime";import{phoneKey as i,tabletKey as l}from"efficient-easel/draw";import{keptByRow as ko}from"efficient-easel/screen/lib/document/style-fields";import{BOX_CARD_PAD as E,BOX_FILL_FADE_PROP as Fo,BOX_SWATCH_PROP as Ho,boxCardProps as Wo,boxIsCard as I}from"../../../../../../format/lib/content/box-background.js";import{BOX_IS_CARD_RULE as yo,BOX_IS_NOT_CARD_RULE as Bo,BOX_ROW_IMAGE_PROP as xo}from"../../../../../../format/lib/content/box-card-rule.js";import{CARD_ROW_FACTS as Uo,cardRowField as M,cardRowFields as Mo,cardRowLinkField as Ko,typedLinkField as Xo}from"../../../card-row-fields.js";import{CARD_ROW_LINK_PROP as Go,cardCopyPlace as K,cardTemplateCardOwner as Yo}from"../../../../../../format/lib/content/card-template.js";import{BOX_SHOW_KEY as vo,HOVER_GROUP_KEY as jo,HOVER_KEY as T}from"../../../../../../format/lib/animation/hover.js";import{BOX_HIGHLIGHT_ROW as Vo,BOX_NEXT_PICTURE_ROW as Jo}from"../../../../animation/hover-fields.js";import{darkenFields as zo}from"../../../darken-fields.js";import{BOX_TAB_SHAPES as qo,REEL_SHAPE_LABELS as Qo}from"../../../../../../format/lib/reel.js";import{LAYOUT_CELL as X,CARD_LIST_STYLE_PICTURES as Zo,TAB_SHAPE_PICTURES as $o}from"../../../choice-pictures.js";import{CARD_STYLE_KEY as A,CARD_STYLE_POINTS as oe,applyCardStyle as ee,isCardStyle as ne}from"../../../../../../render/lib/sections/card-list-style.js";import{deviceField as a}from"efficient-easel/screen/lib/document/device-fields";import{ChevronDownIcon as te,ClockIcon as re,CropIcon as G,GapIcon as ie,MediaLayoutStackedIcon as Y,LineBetweenIcon as le,LineSolidIcon as ae,ListIcon as se,NumberedListIcon as v,ShadowIcon as de,StylesIcon as j,TableIcon as V,TargetIcon as ce,WrapIcon as J}from"efficient-easel/icons";import{boxBlockSpacingField as _e,boxFillField as pe,boxColumnsFields as Oe,boxShareField as Se,boxSharePhoneField as me,boxShareTabletField as fe,containerDirectionField as Re,containerGapRows as he,linkField as ue,plainText as Ce,swapPadding as z,toggle as c,upload as q,withPanelOnly as Ae}from"../../../controls.js";import{BOX_STACK_LINE as g,BOX_STACK_RANGE as R,STACK_BELOW_PROP as N}from"../../../../../../render/lib/content/box-stack-line.js";import{BOX_SHAPES as Q,boxShapeOf as we}from"../../../../../../format/lib/content/box-shape.js";import{BOX_ANGLE_PROP as Ee}from"../../../../../../format/lib/content/box-angle.js";import{shapeLines as Z}from"../../../../../../format/lib/content/gallery-card-layout.js";import{shapePickerRow as $}from"../../../shape-picker.js";import{ACCORDION_COLUMN_COUNTS as Te,ACCORDION_PHONE_COLUMN_COUNTS as Ne,BOX_COLUMNS_MAX as P,BOX_COLUMNS_MIN as b,boxPhoneRowOneLine as De,boxWrapWordOf as oo}from"../../../../../../format/lib/content/box-layout.js";import{BOX_SEPARATOR_POINTS as eo}from"../../../../../../format/lib/content/box-separator.js";import{BOX_WRAP_LABEL as no,VIEW_KEY_ACCESS as s,group as h,phoneTwinFields as d}from"efficient-easel/screen/lib/document/box-fields";import{angleRow as Le,boxAlignField as Ie,boxJustifyField as ge,boxWrapField as D,iconPickerRow as k,placementField as Pe,select as F,sidesPaddingFields as to,slider as ro}from"../../../box-fields.js";import{withRowRules as be,withShowWhen as H}from"../../../../../../render/lib/document/show-when.js";import{separatorField as ke}from"../../../separator-field.js";import{LOOP_SCROLLS as Fe}from"../../../../../../format/lib/animation/index.js";import{DEFAULT_TICKER_JOIN as He,TICKER_JOIN_OPTIONS as We}from"../../../../../../format/lib/sections/ticker-join.js";import{NOT_HELD_BY_A_NODE as io}from"../../../../../../format/lib/document/passes/document-position.js";import{BOX_SIDE_SPACE_PROP as lo}from"../../../../../../format/lib/content/box-side-space.js";import{boxSideSpaceField as ye}from"../../../box-side-space-field.js";import{accordionOnSet as Be}from"../../../box-accordion-seed.js";import{ACCORDION_ROW_STYLE_POINTS as xe,ACCORDION_ROW_STYLE_PROP as L}from"../../../../../../format/lib/content/accordion-row-style.js";import{FlexSlots as ao}from"../../../../../../format/lib/document/blocks/general/Flex/meta.js";import{BOX_TYPE as Ue,CONTAINER_BLOCKS_SLOT as Me}from"../../../../../../format/lib/document/container-blocks.js";import{boxPhoneOrderField as Ke}from"../../../box-phone-order-field.js";import{CARD_BOX_FACTS as Xe,ON_A_CARD as so,ON_A_PICTURE_OR_CARD as Ge,cardDisplayField as W}from"../../../card-display-chips.js";import{MIRROR_CARDS_FACTS as Ye,MIRROR_CARDS_MIRRORS as ve,mirrorCardsField as je}from"../../../mirror-cards-field.js";import{handedRowOf as co}from"../../../../../../format/lib/document/row-hand.js";import{SHOW_FOR_FACTS as Ve,showForField as Je,showForFields as ze}from"../../../show-for-field.js";import{SHARED_COLUMNS_KEY as u,SHARED_COLUMNS_LABEL as _o,SHARED_COLUMNS_OFF as po,sharedColumnsDrawn as Oo,sharedColumnsFits as So,SHARED_COLUMNS_PHONE_POINTS as qe,SHARED_COLUMNS_POINTS as Qe,sharedRowsDrawn as Ze}from"../../../../../../render/lib/content/box-shared-columns.js";const mo=yo,fo={all:[{field:"phoneRow",in:[2,3]},{not:{field:"direction",is:"accordion"}}]},$e={field:"direction",is:"tabs"},on={field:"line",in:[!0,!1]},en={field:"anchor",set:!0},y=["fixed","screen","fill"],nn={not:{any:[{field:"sectionHeightMode",in:y},{field:"sectionHeightModeTablet",in:y},{field:"sectionHeightModePhone",in:y}]}},tn={context:"parent.line",is:!0},_={not:{field:"direction",is:"accordion"}},Ro={field:"direction",is:"accordion"},ho={any:[_,{not:{field:L,in:["numbered","chevron"]}},{field:"columns",in:[...Te]},{field:"phoneRow",in:[...Ne]}]},uo="notAccordionRow",rn={not:{context:uo,is:!0}},ln={[uo]:(o,e)=>e.parent?.props?.direction!=="accordion"},B={field:"direction",is:"row",default:"row"},p={not:Fe},O={all:[B,p,{not:{field:"separator",in:eo.map(o=>o.value)}},{not:{field:"line",is:!0}}]},an={field:"direction",is:"column"},Co={all:[O,...["columns",l("columns")].map(o=>({not:{field:o,in:Array.from({length:P},(e,n)=>n+b)}}))]},sn={all:[p,{not:{all:[B,{field:"separator",in:eo.map(o=>o.value)}]}}]},x={not:{all:[O,{field:"columns",in:Array.from({length:P},(o,e)=>e+b)}]}},dn="sharedColumnsFits",Ao="sharedColumnsMisfit",wo="sharedColumnsDraws",Eo="sharedColumnsPhoneDraws";function S(o,e){return Wo(o.props??{},K(e.appState,o.props?.id)?.inCopy!==!1)}const cn={[dn]:(o,e)=>So(S(o,e)),[Ao]:(o,e)=>!So(S(o,e)),[wo]:(o,e)=>Oo(S(o,e)).desktop,[Eo]:(o,e)=>Oo(S(o,e)).phone};function To(o){return{all:[{not:{context:Ao,is:!0}},{any:[so,{field:o,set:!0}]}]}}const m={not:{context:wo,is:!0}},C={not:{context:Eo,is:!0}},No="sharedRowsDraws",_n={[No]:(o,e)=>Ze(S(o,e))&&co(e.appState,o.props?.id)?.row===void 0},w={not:{context:No,is:!0}},pn={any:[m,C]},U=Bo,On={not:{context:ve,is:!0}},Do="rowHanded",Sn={not:{context:Do,is:!0}},mn={[Do]:(o,e)=>{const n=co(e.appState,o.props?.id);return n===void 0?void 0:n?.row!==void 0}},Lo={all:[_,U,m,C,On]},fn={field:"direction",is:"row"},Rn={field:"align",in:["start","center","end"]},hn={all:[{field:"darken",set:!0},{not:{field:"darken",in:[0,"0"]}}]};function un(){const{darken:o,darkenStyle:e}=zo();return{...d("darken",o,s),...d("darkenStyle",e,s)}}const Io={not:{all:[O,{field:l("columns"),in:Array.from({length:P},(o,e)=>e+b)}]}};function Cn(){const o=c(no,!1,r(J,{})),e=n=>{const t=oo(n);return t===void 0?void 0:t==="wrap"};return{...D(),render:n=>o.render({...n,value:e(n.value),follows:e(n.follows)??!1,onChange:t=>n.onChange(t===void 0?void 0:t?"wrap":"nowrap")})}}function An(){const o=c(no,!0,r(J,{})),e=n=>{const t=oo(n);return t===void 0?void 0:t==="wrap"};return{...D(),render:n=>{const t=n.followsView==="tablet";return o.render({...n,value:e(n.value),follows:!De(void 0,t?n.follows:void 0),followsNoView:!t,onChange:f=>n.onChange(f===void 0?void 0:f?"wrap":"nowrap")})}}}const go={hint:g},Po={all:[U,{any:[an,{all:[O,Io,{not:{all:[Co,{field:l("share"),set:!0}]}}]}]}]},wn=H(a("desktop",ro("Narrows below",r(Y,{}),R.min,R.max,R.step,g,{kind:"breakpoint"},{clear:go,hint:"Under this screen width the side space narrows and the Phone Padding is used."})),Po);function En(o,e){const n=o;return!(N in n)||e.direction!=="column"?o:{...n,[N]:wn}}const Rt={fields:be({_gContent:h("Content"),rowTitle:ao.rowTitle,content:ao.content,_gCardDisplay:h("Display"),cardDisplay:W("desktop"),cardDisplayTablet:W("tablet"),cardDisplayPhone:W("mobile"),showFor:Je(),_gLayout:h("Layout"),direction:Re("Flex"),tabShape:k("Tab shape",r(j,{}),qo.map(o=>({label:Qo[o],value:o,picture:$o[o]})),"tabs",{columns:2,cell:X}),mirrorCards:je(),[N]:a("desktop",ro("Stacks below",r(Y,{}),R.min,R.max,R.step,g,{kind:"breakpoint"},{clear:go,hint:"Under this screen width the blocks stand one under another, with the Phone Gap and Padding."})),[lo]:ye(),startsOpen:a("desktop",c("Starts open",!1,r(te,{}))),[L]:a("desktop",k("Row style",r(v,{}),xe.map(o=>({...o,picture:o.value==="numbered"?r(v,{}):r(se,{})})),"plain",{columns:2})),label:Ae(Ce("Tab name")),...he("Flex"),...d("justify",ge(),s),...d("align",Ie(),s),...(()=>{const o=d("wrap",D(),s,{phoneRow:An()}),e=d("wrap",D(),s,{phoneRow:Cn()});return{wrap:e.wrap,[l("wrap")]:e[l("wrap")],[i("wrap")]:o[i("wrap")]}})(),[i("order")]:Ke(),...d("boxShape",$("Box shape",r(G,{}),Z(Q),"shape","auto"),s,{phoneRow:$("Box shape",r(G,{}),Z(Q),"shape","auto",{phoneRest:o=>we(o)})}),[Ee]:a("desktop",Le(0,{clear:{hint:0},hint:"Turns the box. 0° is straight."})),separator:ke(r(le,{size:18}),"none"),[A]:a("desktop",k("Card style",r(j,{}),oe.map(o=>({...o,picture:Zo[o.value]})),"table",{columns:2,cell:X})),share:a("desktop",Se()),[l("share")]:fe(),[i("share")]:me(),[u]:a("desktop",F(_o,r(V,{}),[...Qe],po)),[i(u)]:a("mobile",F(_o,r(V,{}),[...qe],po)),...Oe(),...d("blockSpacing",_e(),s),line:c("Line",!1,r(ae,{}),"A line across the blocks, with a dot on each."),upcoming:c("Upcoming",!1,r(re,{}),"Still to come: a hollow dot, and the gold line stops before it."),join:F("Join",r(ie,{}),We,He),_gShadow:h("Shadow"),...d("shadow",c("Shadow",!1,r(de,{})),s),...d("fillColor",pe(),s),[Ho]:M("Fill content","colour"),[Fo]:ko("fillColor"),_gBackground:h("Background image"),bgImage:a("desktop",q("Image","image/*")),bgImagePhone:a("mobile",q("Image","image/*")),[xo]:M("Image content","image",{content:!0}),...un(),placement:Pe("Content position"),_gLink:h("Link"),link:Xo(ue("Link to")),[Go]:Ko(),jumpHighlight:c("Highlight when a link jumps here",!1,r(ce,{}),"When a link lands on this Box's anchor, the Box gets a main color outline and its first block turns the main color.")},[[["darken","darkenStyle","placement"],mo],[[i("share")],{all:[fo,C]}],[[u],To(u)],[[i(u)],To(i(u))],[[i("wrap")],{all:[fo,p,C,w]}],[[i("order")],{all:[O,C,m]}],[["phoneRow"],C],[[L],{all:[Ro,{not:{field:L,is:"chevron"}}]}],[["tabShape"],$e],[["rowTitle","startsOpen"],rn],[["align","blockSpacing",l("blockSpacing"),i("blockSpacing")],_],[[l("justify"),i("justify")],{all:[p,Lo,w]}],[[l("align"),i("align")],{all:[fn,Rn,Lo]}],[[l("wrap")],{all:[p,x,Io,m,_,w]}],[[l("shadow"),i("shadow")],U],[[l("darken"),i("darken"),l("darkenStyle"),i("darkenStyle")],{all:[mo,hn]}],[["separator"],B],[[A],{field:A,set:!0}],[["columns"],{any:[O,Ro]}],[[l("columns")],O],[[N],Po],[[l("gap")],{all:[sn,ho]}],[["gap",i("gap")],ho],[["justify"],{all:[p,pn,_,w]}],[["wrap"],{all:[p,x,m,_,w]}],[["share"],{all:[x,m,_]}],[[l("share")],{all:[Co,m]}],[["line"],on],[["upcoming"],tn],[["jumpHighlight"],en],[["boxShape",l("boxShape"),i("boxShape")],nn],[["direction","share",i("order")],Sn],[["join"],io],[[lo],io]]),resolveData:(o,e)=>{const n=o.props,t=n[A];return e.changed?.[A]===!0&&ne(t)?{...o,props:ee(n,t,Ue,Me)}:n.direction==="accordion"&&(e.trigger==="insert"||e.changed?.direction===!0)?{...o,props:Be(n)}:o},resolveFields:(o,e)=>{const n=K(e.appState,o.props?.id)?.inCopy===!0,t=n&&Yo(e.appState,o.props?.id)===null;return En(Dn(Ln(ze(In(o,{...e,fields:Mo(e.fields,o,e)}),o.props),S(o,e),n),t),o.props)},showWhenFacts:{...Uo,...Xe,...Ye,...mn,...cn,..._n,...Ve,...ln}},Tn=H(Vo,so),Nn=["darken","darkenStyle",jo,vo];function Dn(o,e){if(!e)return o;const n={...o};for(const t of Nn){if(!(t in n))continue;const{showWhen:f,...bo}=n[t];n[t]=bo}return n}function Ln(o,e,n=!1){const t=o;return T in t&&I(e)&&n?{...t,[T]:H(Jo,Ge)}:!(T in t)||I(e)?o:{...t,[T]:Tn}}function In(...[o,e]){const{fields:n}=e;{if(I(S(o,e))){const f=to({fallback:{top:E.desktop,bottom:E.desktop,left:E.side,right:E.side},tablet:!0,siteSide:!0});return z(n,f)}return o.props.padV2!==!0?z(n,to({fallback:{top:24,bottom:24},tablet:!0,siteSide:!0})):n}}export{Rt as FlexFields};
@@ -1 +1 @@
1
- import{jsx as e}from"react/jsx-runtime";import{BlockVideoIcon as n,ClockIcon as g,ImageIcon as p,MediaIcon as s,OpacityIcon as u,PlayIcon as v}from"efficient-easel/icons";import{colorInput as f,focusKeptField as o,loadingShowsField as I,MEDIA_TYPE_OPTIONS as y,plainText as _,text as S,upload as a,withIdentifier as O,withPanelOnly as m}from"../../../controls.js";import{group as i}from"efficient-easel/screen/lib/document/box-fields";import{segmented as F,slider as t}from"../../../box-fields.js";import{LOADING_SHOWS_IMAGE as E,VIDEO_PLAYBACK_DEFAULT as T,VIDEO_SOURCE_DEFAULT as l}from"../../../../../../format/lib/hero-video.js";import{HERO_SLIDE_OVERLAY_ROWS as c,HERO_VIDEO_ROWS as d}from"../../hero-shared-fields.js";import{PH as P}from"../../../../../../format/lib/document/blocks/placeholders.js";import{slotNoticeField as b}from"../../shared-fields.js";import{forMediaType as L,heroMediaFields as D,VIDEO_FILE_LABEL as h,VIDEO_FILE_PROMPT as k}from"../../../../../../render/lib/document/hero-media-parts.js";import{DEFAULT_TINT as A}from"../../../../../../format/lib/content/tint.js";import{HeroSlideSlots as C}from"../../../../../../format/lib/document/blocks/general/HeroSlide/meta.js";const r=L("video","video"),G={fields:D({_gContent:i("Content"),name:m(O(_("Slide name",P.slideName))),process:m(S("Reel label","Label")),groupNotice:b("HeroSlide"),groups:C.groups,_gMedia:i("Media"),mediaType:F("Type",e(s,{}),y,"video"),videoSource:d.videoSource,mediaVideo:a(h,"video/*",k,{frame:"videoFrame"}),youtubeUrl:d.youtubeUrl,videoPlayback:d.videoPlayback,videoSpeed:t("Playback speed",e(v,{}),25,100,5,100,"%"),loadingShows:I("Show while loading",e(g,{}),{frame:e(n,{}),image:e(p,{})}),videoFrame:o(),mediaImage:a("Background image","image/*","Upload a background image",{focus:"imageFocal"}),imageFocal:o(),imageFocalTablet:o(),imageFocalPhone:o(),poster:a("Image","image/*","Choose an image"),_gTint:i("Image tint"),tintColor:f("Tint color",A),overlay:t("Tint",e(u,{}),0,100,5,0,"%"),_gOverlay:i("Overlay"),overlayColor:c.overlayColor,overlayPosition:c.overlayPosition},{onlyFor:{image:["mediaImage","imageFocal","imageFocalTablet","imageFocalPhone","_gTint","tintColor","overlay"],video:["videoSource","videoPlayback","loadingShows","videoFrame"]},fallback:"video",rules:{mediaVideo:{all:[r,{field:"videoSource",is:"upload",default:l}]},youtubeUrl:{all:[r,{field:"videoSource",is:"youtube",default:l}]},videoSpeed:{all:[r,{field:"videoSource",is:"upload",default:l},{field:"videoPlayback",is:"background",default:T}]},poster:{all:[{field:"mediaType",is:"video",default:"video"},E]}}})};export{G as HeroSlideFields};
1
+ import{jsx as o}from"react/jsx-runtime";import{BlockVideoIcon as g,ClockIcon as I,ImageIcon as _,MediaIcon as P,OpacityIcon as S,PlayIcon as y}from"efficient-easel/icons";import{colorInput as F,focusKeptField as l,loadingShowsField as E,MEDIA_TYPE_OPTIONS as O,plainText as T,text as h,upload as e,withIdentifier as b,withPanelOnly as t}from"../../../controls.js";import{group as r}from"efficient-easel/screen/lib/document/box-fields";import{segmented as V,slider as n}from"../../../box-fields.js";import{LOADING_SHOWS_IMAGE as p,VIDEO_PLAYBACK_DEFAULT as A,VIDEO_SOURCE_DEFAULT as i}from"../../../../../../format/lib/hero-video.js";import{HERO_SLIDE_OVERLAY_ROWS as v,HERO_VIDEO_ROWS as m}from"../../hero-shared-fields.js";import{PH as L}from"../../../../../../format/lib/document/blocks/placeholders.js";import{slotNoticeField as k}from"../../shared-fields.js";import{AV1_FILE_LABEL as c,AV1_FILE_PROMPT as s,forMediaType as D,heroMediaFields as C,VIDEO_FILE_LABEL as u,VIDEO_FILE_PROMPT as f}from"../../../../../../render/lib/document/hero-media-parts.js";import{deviceField as a}from"efficient-easel/screen/lib/document/device-fields";import{DEFAULT_TINT as M}from"../../../../../../format/lib/content/tint.js";import{HeroSlideSlots as R}from"../../../../../../format/lib/document/blocks/general/HeroSlide/meta.js";const d=D("video","video"),J={fields:C({_gContent:r("Content"),name:t(b(T("Slide name",L.slideName))),process:t(h("Reel label","Label")),groupNotice:k("HeroSlide"),groups:R.groups,_gMedia:r("Media"),mediaType:V("Type",o(P,{}),O,"video"),videoSource:m.videoSource,mediaVideo:a("desktop",e(u,"video/*",f,{frame:"videoFrame"})),mediaVideoPhone:a("mobile",e(u,"video/*",f,{frame:"videoFramePhone"})),videoFramePhone:l(),mediaVideoAv1:a("desktop",e(c,"video/mp4",s)),mediaVideoAv1Phone:a("mobile",e(c,"video/mp4",s)),youtubeUrl:m.youtubeUrl,videoPlayback:m.videoPlayback,videoSpeed:n("Playback speed",o(y,{}),25,100,5,100,"%"),loadingShows:E("Show while loading",o(I,{}),{frame:o(g,{}),image:o(_,{})}),videoFrame:l(),mediaImage:e("Background image","image/*","Upload a background image",{focus:"imageFocal"}),imageFocal:l(),imageFocalTablet:l(),imageFocalPhone:l(),poster:a("desktop",e("Image","image/*","Choose an image")),posterPhone:a("mobile",e("Image","image/*","Choose an image")),_gTint:r("Image tint"),tintColor:F("Tint color",M),overlay:n("Tint",o(S,{}),0,100,5,0,"%"),_gOverlay:r("Overlay"),overlayColor:v.overlayColor,overlayPosition:v.overlayPosition},{onlyFor:{image:["mediaImage","imageFocal","imageFocalTablet","imageFocalPhone","_gTint","tintColor","overlay"],video:["videoSource","videoPlayback","loadingShows","videoFrame"]},fallback:"video",rules:{mediaVideo:{all:[d,{field:"videoSource",is:"upload",default:i}]},mediaVideoPhone:{all:[d,{field:"videoSource",is:"upload",default:i}]},mediaVideoAv1:{all:[d,{field:"videoSource",is:"upload",default:i}]},mediaVideoAv1Phone:{all:[d,{field:"videoSource",is:"upload",default:i}]},youtubeUrl:{all:[d,{field:"videoSource",is:"youtube",default:i}]},videoSpeed:{all:[d,{field:"videoSource",is:"upload",default:i},{field:"videoPlayback",is:"background",default:A}]},poster:{all:[{field:"mediaType",is:"video",default:"video"},p]},posterPhone:{all:[{field:"mediaType",is:"video",default:"video"},p]}}})};export{J as HeroSlideFields};
@@ -0,0 +1,2 @@
1
+ import type { BlockFields } from "../../../../../../format/lib/document/blocks/block-types.js";
2
+ export declare const HostPartFields: BlockFields;
@@ -0,0 +1 @@
1
+ import{panelNote as r}from"../../../controls.js";function a(e){const t=typeof e?.label=="string"?e.label.trim():"",n=typeof e?.name=="string"?e.name.trim():"";return t||n}const s={fields:{},resolveFields:e=>({_nHostPart:r("The section draws {what} here, in every card.",{what:a(e.props)})})};export{s as HostPartFields};
@@ -1,2 +1,2 @@
1
- export declare const assembleGeneralBlocks: () => Record<"Hero" | "HeroSingle" | "IntroBleed" | "ProcessSteps" | "OrderSummary" | "Footprint" | "Cards" | "Stats" | "Chart" | "Mockup" | "Countdown" | "FeaturedCover" | "LongRead" | "Breadcrumb" | "DocBody" | "FAQ" | "ContactLocations" | "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" | "PaymentBadges" | "Heading" | "Text" | "Eyebrow" | "ImageBlock" | "LogoBlock" | "LocationMap" | "Contents" | "ListSearch" | "ButtonBlock" | "CardList" | "PostCard" | "HeroSlide" | "HeroGroup" | "Integrations", 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" | "HeroSingle" | "IntroBleed" | "ProcessSteps" | "OrderSummary" | "Footprint" | "Cards" | "Stats" | "Chart" | "Mockup" | "Countdown" | "FeaturedCover" | "LongRead" | "Breadcrumb" | "DocBody" | "FAQ" | "ContactLocations" | "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" | "PaymentBadges" | "Heading" | "Text" | "Eyebrow" | "ImageBlock" | "LogoBlock" | "LocationMap" | "Contents" | "ListSearch" | "ButtonBlock" | "CardList" | "PostCard" | "HeroSlide" | "HeroGroup" | "Integrations", 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<"Hero" | "HeroSingle" | "IntroBleed" | "ProcessSteps" | "OrderSummary" | "Footprint" | "Cards" | "Stats" | "Chart" | "Mockup" | "Countdown" | "FeaturedCover" | "LongRead" | "Breadcrumb" | "DocBody" | "FAQ" | "ContactLocations" | "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" | "PaymentBadges" | "Heading" | "Text" | "Eyebrow" | "ImageBlock" | "LogoBlock" | "LocationMap" | "Contents" | "ListSearch" | "ButtonBlock" | "CardList" | "HostPart" | "PostCard" | "HeroSlide" | "HeroGroup" | "Integrations", 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" | "HeroSingle" | "IntroBleed" | "ProcessSteps" | "OrderSummary" | "Footprint" | "Cards" | "Stats" | "Chart" | "Mockup" | "Countdown" | "FeaturedCover" | "LongRead" | "Breadcrumb" | "DocBody" | "FAQ" | "ContactLocations" | "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" | "PaymentBadges" | "Heading" | "Text" | "Eyebrow" | "ImageBlock" | "LogoBlock" | "LocationMap" | "Contents" | "ListSearch" | "ButtonBlock" | "CardList" | "HostPart" | "PostCard" | "HeroSlide" | "HeroGroup" | "Integrations", import("efficient-easel/blocks").ComponentConfig<any, any, Omit<import("efficient-easel/blocks").ComponentData<any, string, Record<string, import("efficient-easel/blocks").DefaultComponentProps>>, "type">>>;
@@ -1 +1 @@
1
- import{assembleBlocks as o}from"../../../../../format/lib/document/blocks/block-types.js";import{registerGeneralSectionRows as r}from"../../../../../render/lib/document/blocks/general/section-to-box-rows.js";import{BannerFields as e}from"./Banner/fields.js";import{BreadcrumbFields as i}from"./Breadcrumb/fields.js";import{ButtonBlockFields as t}from"./ButtonBlock/fields.js";import{CardsFields as m}from"./Cards/fields.js";import{CategoryBarFields as s}from"./CategoryBar/fields.js";import{ChartFields as d}from"./Chart/fields.js";import{ContactLocationsFields as l}from"./ContactLocations/fields.js";import{CountdownFields as a}from"./Countdown/fields.js";import{CustomHTMLFields as p}from"../../../../../format/lib/document/blocks/general/CustomHTML/fields.js";import{DividerFields as F}from"./Divider/fields.js";import{ContentsFields as f}from"./Contents/fields.js";import{ListSearchFields as n}from"./ListSearch/fields.js";import{DocBodyFields as c}from"./DocBody/fields.js";import{DocMastheadFields as S}from"./DocMasthead/fields.js";import{DocMetaCardsFields as B}from"./DocMetaCards/fields.js";import{DocTabsFields as g}from"./DocTabs/fields.js";import{EyebrowFields as C}from"./Eyebrow/fields.js";import{FAQFields as u}from"./FAQ/fields.js";import{FeaturedCoverFields as L}from"./FeaturedCover/fields.js";import{FlexFields as T}from"./Flex/fields.js";import{FootprintFields as k}from"./Footprint/fields.js";import{GridFields as h}from"./Grid/fields.js";import{HeadingFields as H}from"./Heading/fields.js";import{HeroFields as M}from"./Hero/fields.js";import{HeroGroupFields as y}from"./HeroGroup/fields.js";import{HeroSingleFields as D}from"./HeroSingle/fields.js";import{HeroSlideFields as P}from"./HeroSlide/fields.js";import{ImageBlockFields as E}from"./ImageBlock/fields.js";import{IntegrationsFields as b}from"./Integrations/fields.js";import{IntroBleedFields as G}from"./IntroBleed/fields.js";import{KeyFeaturesFields as I}from"./KeyFeatures/fields.js";import{LocationMapFields as R}from"./LocationMap/fields.js";import{LogoBlockFields as x}from"./LogoBlock/fields.js";import{LogosFields as A}from"./Logos/fields.js";import{LongReadFields as w}from"./LongRead/fields.js";import{ManifestoFields as v}from"./Manifesto/fields.js";import{MastheadFields as N}from"./Masthead/fields.js";import{MockupFields as K}from"./Mockup/fields.js";import{OrderSummaryFields as O}from"./OrderSummary/fields.js";import{CardListFields as Q}from"./CardList/fields.js";import{ParagraphsAFields as W}from"./ParagraphsA/fields.js";import{PaymentBadgesFields as _}from"./PaymentBadges/fields.js";import{PostCardFields as j}from"./PostCard/fields.js";import{ProcessStepsFields as q}from"./ProcessSteps/fields.js";import{ProseFields as z}from"./Prose/fields.js";import{SectionHeaderFields as J}from"./SectionHeader/fields.js";import{SeriesFields as U}from"./Series/fields.js";import{SpacerFields as V}from"../../../../../format/lib/document/blocks/general/Spacer/fields.js";import{SpecStripFields as X}from"./SpecStrip/fields.js";import{SplitFields as Y}from"./Split/fields.js";import{StatsFields as Z}from"./Stats/fields.js";import{StatsParagraphFields as $}from"./StatsParagraph/fields.js";import{TestimonialsFields as oo}from"./Testimonials/fields.js";import{TextFields as ro}from"./Text/fields.js";import{TickerFields as eo}from"./Ticker/fields.js";import{TimelineFields as io}from"./Timeline/fields.js";import{TimelineTrackFields as to}from"./TimelineTrack/fields.js";import{TitleWithButtonsFields as mo}from"./TitleWithButtons/fields.js";import{GENERAL_RENDERS as so}from"../../../../../render/lib/document/blocks/general/renders.js";const lo={Banner:e,Breadcrumb:i,ButtonBlock:t,Cards:m,CategoryBar:s,Chart:d,ContactLocations:l,Countdown:a,CustomHTML:p,Divider:F,Contents:f,ListSearch:n,DocBody:c,DocMasthead:S,DocMetaCards:B,DocTabs:g,Eyebrow:C,FAQ:u,FeaturedCover:L,Flex:T,Footprint:k,Grid:h,Heading:H,Hero:M,HeroGroup:y,HeroSingle:D,HeroSlide:P,ImageBlock:E,Integrations:b,IntroBleed:G,KeyFeatures:I,LocationMap:R,LogoBlock:x,Logos:A,LongRead:w,Manifesto:v,Masthead:N,Mockup:K,OrderSummary:O,CardList:Q,ParagraphsA:W,PaymentBadges:_,PostCard:j,ProcessSteps:q,Prose:z,SectionHeader:J,Series:U,Spacer:V,SpecStrip:X,Split:Y,Stats:Z,StatsParagraph:$,Testimonials:oo,Text:ro,Ticker:eo,Timeline:io,TimelineTrack:to,TitleWithButtons:mo},ao=()=>(r(),o(so,lo)),gr=ao();export{ao as assembleGeneralBlocks,gr as generalBlocks};
1
+ import{assembleBlocks as o}from"../../../../../format/lib/document/blocks/block-types.js";import{registerGeneralSectionRows as r}from"../../../../../render/lib/document/blocks/general/section-to-box-rows.js";import{BannerFields as e}from"./Banner/fields.js";import{BreadcrumbFields as i}from"./Breadcrumb/fields.js";import{ButtonBlockFields as t}from"./ButtonBlock/fields.js";import{CardsFields as m}from"./Cards/fields.js";import{CategoryBarFields as s}from"./CategoryBar/fields.js";import{ChartFields as d}from"./Chart/fields.js";import{ContactLocationsFields as a}from"./ContactLocations/fields.js";import{CountdownFields as l}from"./Countdown/fields.js";import{CustomHTMLFields as p}from"../../../../../format/lib/document/blocks/general/CustomHTML/fields.js";import{DividerFields as F}from"./Divider/fields.js";import{ContentsFields as f}from"./Contents/fields.js";import{ListSearchFields as n}from"./ListSearch/fields.js";import{DocBodyFields as c}from"./DocBody/fields.js";import{DocMastheadFields as S}from"./DocMasthead/fields.js";import{DocMetaCardsFields as B}from"./DocMetaCards/fields.js";import{DocTabsFields as g}from"./DocTabs/fields.js";import{EyebrowFields as C}from"./Eyebrow/fields.js";import{FAQFields as u}from"./FAQ/fields.js";import{FeaturedCoverFields as L}from"./FeaturedCover/fields.js";import{FlexFields as T}from"./Flex/fields.js";import{FootprintFields as H}from"./Footprint/fields.js";import{GridFields as k}from"./Grid/fields.js";import{HeadingFields as h}from"./Heading/fields.js";import{HeroFields as M}from"./Hero/fields.js";import{HeroGroupFields as P}from"./HeroGroup/fields.js";import{HeroSingleFields as y}from"./HeroSingle/fields.js";import{HeroSlideFields as D}from"./HeroSlide/fields.js";import{ImageBlockFields as E}from"./ImageBlock/fields.js";import{IntegrationsFields as b}from"./Integrations/fields.js";import{IntroBleedFields as G}from"./IntroBleed/fields.js";import{KeyFeaturesFields as I}from"./KeyFeatures/fields.js";import{LocationMapFields as R}from"./LocationMap/fields.js";import{LogoBlockFields as x}from"./LogoBlock/fields.js";import{LogosFields as A}from"./Logos/fields.js";import{LongReadFields as w}from"./LongRead/fields.js";import{ManifestoFields as v}from"./Manifesto/fields.js";import{MastheadFields as N}from"./Masthead/fields.js";import{MockupFields as K}from"./Mockup/fields.js";import{OrderSummaryFields as O}from"./OrderSummary/fields.js";import{CardListFields as Q}from"./CardList/fields.js";import{HostPartFields as W}from"./HostPart/fields.js";import{ParagraphsAFields as _}from"./ParagraphsA/fields.js";import{PaymentBadgesFields as j}from"./PaymentBadges/fields.js";import{PostCardFields as q}from"./PostCard/fields.js";import{ProcessStepsFields as z}from"./ProcessSteps/fields.js";import{ProseFields as J}from"./Prose/fields.js";import{SectionHeaderFields as U}from"./SectionHeader/fields.js";import{SeriesFields as V}from"./Series/fields.js";import{SpacerFields as X}from"../../../../../format/lib/document/blocks/general/Spacer/fields.js";import{SpecStripFields as Y}from"./SpecStrip/fields.js";import{SplitFields as Z}from"./Split/fields.js";import{StatsFields as $}from"./Stats/fields.js";import{StatsParagraphFields as oo}from"./StatsParagraph/fields.js";import{TestimonialsFields as ro}from"./Testimonials/fields.js";import{TextFields as eo}from"./Text/fields.js";import{TickerFields as io}from"./Ticker/fields.js";import{TimelineFields as to}from"./Timeline/fields.js";import{TimelineTrackFields as mo}from"./TimelineTrack/fields.js";import{TitleWithButtonsFields as so}from"./TitleWithButtons/fields.js";import{GENERAL_RENDERS as ao}from"../../../../../render/lib/document/blocks/general/renders.js";const lo={Banner:e,Breadcrumb:i,ButtonBlock:t,Cards:m,CategoryBar:s,Chart:d,ContactLocations:a,Countdown:l,CustomHTML:p,Divider:F,Contents:f,ListSearch:n,DocBody:c,DocMasthead:S,DocMetaCards:B,DocTabs:g,Eyebrow:C,FAQ:u,FeaturedCover:L,Flex:T,Footprint:H,Grid:k,Heading:h,Hero:M,HeroGroup:P,HeroSingle:y,HeroSlide:D,ImageBlock:E,Integrations:b,IntroBleed:G,KeyFeatures:I,LocationMap:R,LogoBlock:x,Logos:A,LongRead:w,Manifesto:v,Masthead:N,Mockup:K,OrderSummary:O,CardList:Q,HostPart:W,ParagraphsA:_,PaymentBadges:j,PostCard:q,ProcessSteps:z,Prose:J,SectionHeader:U,Series:V,Spacer:X,SpecStrip:Y,Split:Z,Stats:$,StatsParagraph:oo,Testimonials:ro,Text:eo,Ticker:io,Timeline:to,TimelineTrack:mo,TitleWithButtons:so},po=()=>(r(),o(ao,lo)),ur=po();export{po as assembleGeneralBlocks,ur as generalBlocks};
@@ -1 +1 @@
1
- import{jsx as t}from"react/jsx-runtime";import{SECTION_PAD_INNER_DEFAULTS as i}from"../../../../render/lib/document/passes/section-padding.js";import n,{SlotNoticeField as p}from"../../../components/SlotChildRows.js";import{SECTION_HEIGHT as r}from"../../../../format/lib/content/section-height.js";import{usePreviewHeader as l}from"../../../../render/components/PreviewHeaderContext.js";import{IMAGE_GRAYSCALE_LABEL as m}from"../../../../format/lib/content/image-treatment.js";import{BlackAndWhiteIcon as d,ContrastIcon as s,HeightIcon as a,TypeIcon as c}from"efficient-easel/icons";import{linkField as f,spacingFields as u,text as g,toggle as h}from"../controls.js";import{segmented as x,slider as y}from"../box-fields.js";import{deviceField as F}from"efficient-easel/screen/lib/document/device-fields";import{FieldGlyph as T}from"../../../components/FieldGlyph.js";import{fieldNoun as E}from"../../../../format/lib/document/field-noun.js";import{CTA_PH as I}from"../../../../format/lib/document/blocks/placeholders.js";import{ownEntry as A}from"../../../../format/lib/own-entry.js";const H=o=>y("Height",t(a,{}),r.min,r.max,r.step,r.fallback,r.unit,o),M=o=>F(o,H());import{heroHeightFields as V}from"./hero-shared-fields.js";const O={ctaText:g("Button",I.text),ctaHref:f("Button link")},K=()=>x("Tone",t(s,{}),[{label:"Default",value:"default"},{label:"Muted",value:"dim"}],"default"),U=o=>u({...A(i,o),keys:{top:"padTop",bottom:"padBottom"},group:!1}),W=(o,e)=>({type:"custom",render:()=>t(n,{parentType:o,label:e})}),Y=o=>({type:"custom",render:()=>t(p,{parentType:o})});function _(o){const{photographyGrayscale:e}=l();return h(m,e===!0,t(d,{})).render(o)}function q(){return{type:"custom",render:o=>t(_,{...o})}}function z(o){const e=E(o);return e?t(T,{noun:e}):t(c,{})}export{O as ctaField,M as heightField,V as heroHeightFields,U as innerSpacingFields,q as photographyToggle,Y as slotNoticeField,W as slotRowsField,z as textKindGlyph,K as toneField};
1
+ import{jsx as o}from"react/jsx-runtime";import{ownPairDefault as i}from"../../../../render/lib/document/passes/section-padding.js";import n,{SlotNoticeField as p}from"../../../components/SlotChildRows.js";import{SECTION_HEIGHT as r}from"../../../../format/lib/content/section-height.js";import{usePreviewHeader as l}from"../../../../render/components/PreviewHeaderContext.js";import{IMAGE_GRAYSCALE_LABEL as m}from"../../../../format/lib/content/image-treatment.js";import{BlackAndWhiteIcon as a,ContrastIcon as d,HeightIcon as s,TypeIcon as c}from"efficient-easel/icons";import{linkField as f,spacingFields as u,text as g,toggle as h}from"../controls.js";import{segmented as x,slider as y}from"../box-fields.js";import{deviceField as F}from"efficient-easel/screen/lib/document/device-fields";import{FieldGlyph as T}from"../../../components/FieldGlyph.js";import{fieldNoun as H}from"../../../../format/lib/document/field-noun.js";import{CTA_PH as I}from"../../../../format/lib/document/blocks/placeholders.js";const w=t=>y("Height",o(s,{}),r.min,r.max,r.step,r.fallback,r.unit,t),j=t=>F(t,w());import{heroHeightFields as Q}from"./hero-shared-fields.js";const D={ctaText:g("Button",I.text),ctaHref:f("Button link")},M=()=>x("Tone",o(d,{}),[{label:"Default",value:"default"},{label:"Muted",value:"dim"}],"default"),K=t=>u({...i(t),keys:{top:"padTop",bottom:"padBottom"},group:!1}),O=(t,e)=>({type:"custom",render:()=>o(n,{parentType:t,label:e})}),W=t=>({type:"custom",render:()=>o(p,{parentType:t})});function A(t){const{photographyGrayscale:e}=l();return h(m,e===!0,o(a,{})).render(t)}function Y(){return{type:"custom",render:t=>o(A,{...t})}}function q(t){const e=H(t);return e?o(T,{noun:e}):o(c,{})}export{D as ctaField,j as heightField,Q as heroHeightFields,K as innerSpacingFields,Y as photographyToggle,W as slotNoticeField,O as slotRowsField,q as textKindGlyph,M as toneField};
@@ -1 +1 @@
1
- import{cardTemplateBlocks as w,hasCardTemplate as j,isCardTemplateBlock as O}from"../../../format/lib/content/card-template.js";import{resolveBlockOffer as $}from"./block-offer.js";import{applyBlockPasses as B,registryPassContext as C}from"../../../render/lib/document/passes/index.js";import{PASS_INSPECTOR as F}from"./passes/inspector.js";function k(n,a,c){if(!n)return n;let l=!1;const d={};for(const[s,e]of Object.entries(n)){let o=e;if(e&&typeof e=="object")if(e.type==="slot")if(e.allow){const r=e.allow.filter(a);r.length!==e.allow.length&&(o={...e,allow:r})}else{const r=new Set(e.disallow??[]),p=c.filter(m=>!r.has(m));p.length>0&&(o={...e,disallow:[...e.disallow??[],...p]})}else{const r=k(e.arrayFields,a,c),p=k(e.objectFields,a,c);(r!==e.arrayFields||p!==e.objectFields)&&(o={...e,...r?{arrayFields:r}:null,...p?{objectFields:p}:null})}o!==e&&(l=!0),d[s]=o}return l?d:n}function S(n,a,c){const l={};for(const[o,r]of Object.entries(a.fields??{}))l[o]=r&&typeof r=="object"&&r.type==="slot"?{...r}:r;const d={...a,...a.fields?{fields:l}:null},s=B(n,d,c),e=Object.keys(l).filter(o=>s.fields?.[o]!==l[o]);if(e.length>0)throw new Error(`efficient-web-builder: blocks.host["${n}"] declares ${e.map(o=>`"${o}"`).join(", ")}, ${e.length===1?"a name":"names"} the editor gives every section a setting under. Give the block's own field another name.`);return s}function v(n,a,c){const l=new Set([...Object.keys(n.components??{}),...a]),d=[...Object.entries(n.categories??{}).map(([s,e])=>({key:s,components:e?.components??[]})),...c];for(const s of d){const e=s.components.filter(O);if(e.length>0)throw new Error(`efficient-web-builder: the category "${s.key}" lists ${e.map(o=>`"${o}"`).join(", ")}, a block a card template declares. A card's block is added in its card only; take it out of the category.`)}for(const s of l){if(!j(s))continue;const e=w(s).filter(o=>!l.has(o.type)).map(o=>`"${o.type}"`);if(e.length>0)throw new Error(`efficient-web-builder: the card template of "${s}" declares ${e.join(", ")}, which the editor does not register. Register it in the registry or in blocks.host.`)}}function A(n,a){const c=Object.entries(a?.host??{}),l=a?.categories??[],d=$(a);if(v(n,c.map(([t])=>t),l),!d&&c.length===0&&l.length===0)return n;const s=n.components,e=c.map(([t])=>t).filter(t=>t in s);if(e.length>0)throw new Error(`efficient-web-builder: blocks.host registers ${e.map(t=>`"${t}"`).join(", ")}, which ${e.length===1?"is already a block":"are already blocks"} of the editor. Give a host's block a type of its own.`);const o=t=>d?d.offers(t):!0,r=Object.keys(s).filter(t=>!o(t)),p={};for(const[t,i]of Object.entries(s)){const h=d?k(i?.fields,o,r):i?.fields;p[t]=h===i?.fields?i:{...i,fields:h}}if(c.length>0){const t=new Set(c.map(([y])=>y)),i=n.categories?.structure?.components??[],g={...C(Object.keys(s),i,t),isHostBlock:y=>t.has(y),inspector:F};for(const[y,f]of c){const b=S(y,f,g),u=k(b.fields,o,r);p[y]=u===b.fields?b:{...b,fields:u}}}const m=[];for(const[t,i]of Object.entries(n.categories??{})){const h=i?.components??[],g=h.filter(o);g.length===h.length?m.push([t,i]):g.length>0&&m.push([t,{...i,components:g}])}for(const t of l){const i=t.components.filter(f=>f in p&&o(f));if(i.length===0)continue;const h=m.find(([f])=>f===t.key);if(h){const[,f]=h,b=new Set(f.components??[]);h[1]={...f,components:[...f.components??[],...i.filter(u=>!b.has(u))]};continue}const g=[t.key,{title:t.title,components:i}],y=t.before?m.findIndex(([f])=>f===t.before):-1;y===-1?m.push(g):m.splice(y,0,g)}return{...n,components:p,categories:Object.fromEntries(m)}}export{A as buildConfig};
1
+ import{HOST_PART_TYPE as k,cardTemplateBlocks as $,hasCardTemplate as O,isCardTemplateBlock as T}from"../../../format/lib/content/card-template.js";import{resolveBlockOffer as F}from"./block-offer.js";import{applyBlockPasses as E,registryPassContext as S}from"../../../render/lib/document/passes/index.js";import{PASS_INSPECTOR as v}from"./passes/inspector.js";function w(s,r,l){if(!s)return s;let i=!1;const a={};for(const[t,e]of Object.entries(s)){let o=e;if(e&&typeof e=="object")if(e.type==="slot")if(e.allow){const c=e.allow.filter(r);c.length!==e.allow.length&&(o={...e,allow:c})}else{const c=new Set(e.disallow??[]),p=l.filter(m=>!c.has(m));p.length>0&&(o={...e,disallow:[...e.disallow??[],...p]})}else{const c=w(e.arrayFields,r,l),p=w(e.objectFields,r,l);(c!==e.arrayFields||p!==e.objectFields)&&(o={...e,...c?{arrayFields:c}:null,...p?{objectFields:p}:null})}o!==e&&(i=!0),a[t]=o}return i?a:s}function C(s,r,l){const i={};for(const[o,c]of Object.entries(r.fields??{}))i[o]=c&&typeof c=="object"&&c.type==="slot"?{...c}:c;const a={...r,...r.fields?{fields:i}:null},t=E(s,a,l),e=Object.keys(i).filter(o=>t.fields?.[o]!==i[o]);if(e.length>0)throw new Error(`efficient-web-builder: blocks.host["${s}"] declares ${e.map(o=>`"${o}"`).join(", ")}, ${e.length===1?"a name":"names"} the editor gives every section a setting under. Give the block's own field another name.`);return t}function P(s,r,l){const i=new Set([...Object.keys(s.components??{}),...r.map(([t])=>t)]),a=[...Object.entries(s.categories??{}).map(([t,e])=>({key:t,components:e?.components??[]})),...l];x(s,r,a);for(const t of a){const e=t.components.filter(T);if(e.length>0)throw new Error(`efficient-web-builder: the category "${t.key}" lists ${e.map(o=>`"${o}"`).join(", ")}, a block a card template declares. A card's block is added in its card only; take it out of the category.`)}for(const t of i){if(!O(t))continue;const e=$(t).filter(o=>!i.has(o.type)).map(o=>`"${o.type}"`);if(e.length>0)throw new Error(`efficient-web-builder: the card template of "${t}" declares ${e.join(", ")}, which the editor does not register. Register it in the registry or in blocks.host.`)}}function j(s,r,l,i=""){const a=[];for(const[t,e]of Object.entries(l??{})){if(!e||typeof e!="object")continue;const o=`${i}${t}`;e.type==="slot"&&e.allow?.includes(s)&&a.push(`${r}.${o}`),a.push(...j(s,r,e.arrayFields,`${o}.`),...j(s,r,e.objectFields,`${o}.`))}return a}function x(s,r,l){const i=t=>{throw new Error(`efficient-web-builder: ${t} names "${k}". Only a host's seed puts a host part in a card template; a merchant never adds one. Take it out.`)};for(const t of l)t.components.includes(k)&&i(`the category "${t.key}"`);const a=[...Object.entries(s.components??{}),...r.map(([t,e])=>[t,e])];for(const[t,e]of a){const o=j(k,t,e?.fields);o.length>0&&i(`the slot ${o.map(c=>`"${c}"`).join(", ")}, whose allow list`)}}function _(s,r){const l=Object.entries(r?.host??{}),i=r?.categories??[],a=F(r);if(P(s,l,i),!a&&l.length===0&&i.length===0)return s;const t=s.components,e=l.map(([n])=>n).filter(n=>n in t);if(e.length>0)throw new Error(`efficient-web-builder: blocks.host registers ${e.map(n=>`"${n}"`).join(", ")}, which ${e.length===1?"is already a block":"are already blocks"} of the editor. Give a host's block a type of its own.`);const o=n=>a?a.offers(n):!0,c=Object.keys(t).filter(n=>!o(n)),p={};for(const[n,f]of Object.entries(t)){const h=a?w(f?.fields,o,c):f?.fields;p[n]=h===f?.fields?f:{...f,fields:h}}if(l.length>0){const n=new Set(l.map(([u])=>u)),f=s.categories?.structure?.components??[],y={...S(Object.keys(t),f,n),isHostBlock:u=>n.has(u),inspector:v};for(const[u,d]of l){const b=C(u,d,y),g=w(b.fields,o,c);p[u]=g===b.fields?b:{...b,fields:g}}}const m=[];for(const[n,f]of Object.entries(s.categories??{})){const h=f?.components??[],y=h.filter(o);y.length===h.length?m.push([n,f]):y.length>0&&m.push([n,{...f,components:y}])}for(const n of i){const f=n.components.filter(d=>d in p&&o(d));if(f.length===0)continue;const h=m.find(([d])=>d===n.key);if(h){const[,d]=h,b=new Set(d.components??[]);h[1]={...d,components:[...d.components??[],...f.filter(g=>!b.has(g))]};continue}const y=[n.key,{title:n.title,components:f}],u=n.before?m.findIndex(([d])=>d===n.before):-1;u===-1?m.push(y):m.splice(u,0,y)}return{...s,components:p,categories:Object.fromEntries(m)}}export{_ as buildConfig};
@@ -1,5 +1,6 @@
1
1
  import { type ReactElement, type ReactNode } from "react";
2
2
  import { type FieldsPatch } from "efficient-easel/easel";
3
+ import { type WordValues } from "../../../format/lib/editor-words.js";
3
4
  import { type MediaValue } from "../../../format/lib/media-value.js";
4
5
  import { type KnownVideoFrame, type LoadingShows } from "../../../format/lib/hero-video.js";
5
6
  import { readHidable, hidableText, type HidableValue } from "efficient-easel/draw";
@@ -122,9 +123,10 @@ export declare function plainTextarea(label: string, placeholder?: string, hint?
122
123
  export declare const BUCKET_ICONS: Record<Bucket, (props: {
123
124
  size?: number;
124
125
  }) => ReactElement>;
125
- export declare function panelNote(text: string): CustomField<undefined>;
126
- export declare function PanelNoteLine({ text }: {
126
+ export declare function panelNote(text: string, values?: WordValues): CustomField<undefined>;
127
+ export declare function PanelNoteLine({ text, values }: {
127
128
  text: string;
129
+ values?: WordValues;
128
130
  }): import("react").JSX.Element;
129
131
  export declare function isBucketHeader(field: unknown): boolean;
130
132
  export declare function bucketHeader(bucket: Bucket, tabs: readonly Bucket[] | null): CustomField<undefined>;
@@ -409,3 +411,4 @@ export declare function cardImageField(row?: typeof CARD_IMAGE_RADIUS_ROW): Cust
409
411
  export declare function cardImageFields(): Record<string, CustomField<unknown>>;
410
412
  export declare function imageCornersField(): CustomField<number | null>;
411
413
  export declare function galleryLayoutField(): CustomField<string>;
414
+ export declare function galleryLayoutPhoneField(): CustomField<string>;