efficient-web-builder 51.0.0 → 52.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (77) hide show
  1. package/CHANGELOG.md +33 -0
  2. package/dist/editor/components/PartTextBox.js +1 -1
  3. package/dist/editor/components/PreviewPartStyleContext.d.ts +2 -2
  4. package/dist/editor/components/SiteTextStylesField.d.ts +2 -1
  5. package/dist/editor/components/SiteTextStylesField.js +1 -1
  6. package/dist/editor/components/WebsiteSettingsPanel.js +1 -1
  7. package/dist/editor/components/storefront-editor.css +12 -44
  8. package/dist/editor/lib/document/ColourControl.d.ts +11 -8
  9. package/dist/editor/lib/document/ColourControl.js +1 -1
  10. package/dist/editor/lib/document/blocks/general/Flex/fields.js +1 -1
  11. package/dist/editor/lib/document/blocks/general/Series/fields.js +1 -1
  12. package/dist/editor/lib/document/blocks/general/StatsParagraph/fields.js +1 -1
  13. package/dist/editor/lib/document/blocks/general/index.d.ts +2 -2
  14. package/dist/editor/lib/document/controls.d.ts +14 -4
  15. package/dist/editor/lib/document/controls.js +1 -1
  16. package/dist/editor/lib/document/overrides.js +1 -1
  17. package/dist/editor/lib/document/passes/inspector.js +1 -1
  18. package/dist/format/lib/content/borders.d.ts +4 -2
  19. package/dist/format/lib/content/borders.js +1 -1
  20. package/dist/format/lib/content/button-icon.d.ts +1 -1
  21. package/dist/format/lib/content/button-icon.js +1 -1
  22. package/dist/format/lib/content/card-state.d.ts +8 -0
  23. package/dist/format/lib/content/card-state.js +1 -0
  24. package/dist/format/lib/content/section-background.d.ts +10 -3
  25. package/dist/format/lib/content/section-background.js +1 -1
  26. package/dist/format/lib/content/section-min-height.d.ts +17 -1
  27. package/dist/format/lib/content/section-min-height.js +1 -1
  28. package/dist/format/lib/content/section-sticky.d.ts +9 -0
  29. package/dist/format/lib/content/section-sticky.js +1 -1
  30. package/dist/format/lib/document/card-template-layers.d.ts +1 -1
  31. package/dist/format/lib/document/card-template-layers.js +1 -1
  32. package/dist/format/lib/document/part-inks.d.ts +5 -10
  33. package/dist/format/lib/document/part-inks.js +1 -1
  34. package/dist/format/lib/document/passes/types.d.ts +1 -0
  35. package/dist/format/lib/document/show-when-attach.d.ts +2 -1
  36. package/dist/format/lib/document/show-when-attach.js +1 -1
  37. package/dist/format/lib/editor-words-catalogue.d.ts +0 -3
  38. package/dist/format/lib/editor-words-catalogue.js +2 -2
  39. package/dist/format/lib/sections/hero-single-to-hero.js +1 -1
  40. package/dist/format/lib/source-rules/panel-rows-use-the-shared-row.d.ts +4 -0
  41. package/dist/format/lib/source-rules/panel-rows-use-the-shared-row.js +37 -20
  42. package/dist/format/lib/source-rules/support/part-slider-call-sites.d.ts +0 -1
  43. package/dist/format/lib/source-rules/support/part-slider-call-sites.js +6 -6
  44. package/dist/format/lib/text-styles/site-text-colours.d.ts +11 -0
  45. package/dist/format/lib/text-styles/site-text-colours.js +1 -0
  46. package/dist/format/lib/theme.d.ts +1 -0
  47. package/dist/format/lib/theme.js +3 -3
  48. package/dist/format/lib/word-styles.d.ts +0 -1
  49. package/dist/format/lib/word-styles.js +1 -1
  50. package/dist/render/components/ButtonBlock.d.ts +1 -0
  51. package/dist/render/components/ButtonBlock.js +1 -1
  52. package/dist/render/components/CardRowContext.d.ts +5 -2
  53. package/dist/render/components/CardRowContext.js +1 -1
  54. package/dist/render/components/Flex.d.ts +2 -1
  55. package/dist/render/components/Flex.js +1 -1
  56. package/dist/render/components/goldPhrases.js +2 -2
  57. package/dist/render/lib/content/block-size.d.ts +1 -0
  58. package/dist/render/lib/content/block-size.js +1 -1
  59. package/dist/render/lib/content/box-shared-columns.js +1 -1
  60. package/dist/render/lib/document/blocks/general/Cards/render.js +1 -1
  61. package/dist/render/lib/document/blocks/general/Flex/render.js +1 -1
  62. package/dist/render/lib/document/blocks/general/section-to-box-row-parts.d.ts +2 -0
  63. package/dist/render/lib/document/blocks/general/section-to-box-row-parts.js +1 -1
  64. package/dist/render/lib/document/blocks/general/section-to-box-rows-cards.js +1 -1
  65. package/dist/render/lib/document/blocks/general/section-to-box-rows-stats.js +1 -1
  66. package/dist/render/lib/document/blocks/general/section-to-box-rows-timeline.js +2 -2
  67. package/dist/render/lib/document/part-styles.js +2 -2
  68. package/dist/render/lib/document/passes/block-size.js +1 -1
  69. package/dist/render/lib/document/passes/borders.js +1 -1
  70. package/dist/render/lib/document/passes/section-height.js +1 -1
  71. package/dist/render/lib/document/passes/section-sticky.js +1 -1
  72. package/dist/render/lib/document/show-when.d.ts +1 -1
  73. package/dist/render/lib/document/show-when.js +1 -1
  74. package/dist/render/lib/text-styles/site-text-styles.js +2 -2
  75. package/package.json +1 -1
  76. package/dist/editor/components/PartInkControl.d.ts +0 -7
  77. package/dist/editor/components/PartInkControl.js +0 -1
@@ -1 +1 @@
1
- import{FONT_OPTIONS as a}from"./fonts.js";const i=["highlight","strong","quiet"],Y={highlight:"Highlight",strong:"Bold",quiet:"Quiet"},O={highlight:{kind:"wordHighlight",delimiter:"@@"},strong:{kind:"wordStrong",delimiter:"++"},quiet:{kind:"wordQuiet",delimiter:"^^"}},G=Object.fromEntries(i.map(t=>[O[t].kind,t])),N="data-sf-ws",T=["accent","text","labels"],A={accent:"Accent",text:"Text",labels:"Labels"},E={accent:"var(--accent)",text:"var(--fg)",labels:"var(--fg-dim)"},g=80,h=120,m=100,L=900,R=.5,w=3,W=-.1,D=.5,b=3,c={font:null,size:null,weight:null,bold:null,italic:null,lineGap:null,textGap:null,colour:null},_={highlight:{...c},strong:{...c},quiet:{...c}};function f(t,e,o){return typeof t!="number"||!Number.isFinite(t)?null:Math.round(Math.min(Math.max(t,e),o))}function p(t,e,o){if(typeof t!="number"||!Number.isFinite(t))return null;const l=10**b;return Math.round(Math.min(Math.max(t,e),o)*l)/l}function S(t){return typeof t=="boolean"?t:null}function d(t){const e=typeof t?.font=="string"&&a.some(l=>l.key===t.font)?t.font:null,o=typeof t?.colour=="string"&&T.includes(t.colour)?t.colour:null;return{font:e,size:f(t?.size,g,h),weight:f(t?.weight,m,L),bold:S(t?.bold),italic:S(t?.italic),lineGap:p(t?.lineGap,R,w),textGap:p(t?.textGap,W,D),colour:o}}function s(t){const e={};for(const o of i)e[o]=t&&o in t&&t[o]?d(t[o]):{..._[o]};return e}function I(t,e){const o=d(e),l=_[t];return Object.keys(l).every(n=>o[n]===l[n])}function M(t){const e=s(t),o={};for(const l of i){const n=e[l],r=`--sf-ws-${l}`;if(n.font){const u=a.find(x=>x.key===n.font);u&&(o[`${r}-font`]=`var(${u.cssVar})`)}n.size!==null&&(o[`${r}-size`]=`${n.size/100}em`),n.weight!==null&&(o[`${r}-weight`]=String(n.weight)),n.bold!==null&&(o[`${r}-weight-bold`]=n.bold?"700":"400"),n.italic!==null&&(o[`${r}-style`]=n.italic?"italic":"normal"),n.lineGap!==null&&(o[`${r}-line`]=String(n.lineGap)),n.textGap!==null&&(o[`${r}-track`]=`${n.textGap}em`),n.colour!==null&&(o[`${r}-color`]=E[n.colour])}return o}function $(t){const e=t?.word_styles??void 0,o={};for(const l of i)e&&l in e&&(o[l]=e[l]??null);return s(o)}function k(t){return{word_styles:s(t)}}export{E as COLOUR_TOKEN,_ as DEFAULT_WORD_STYLES,i as WORD_STYLES,N as WORD_STYLE_ATTR,G as WORD_STYLE_BY_KIND,T as WORD_STYLE_COLOURS,A as WORD_STYLE_COLOUR_LABELS,b as WORD_STYLE_GAP_PRECISION,Y as WORD_STYLE_LABELS,w as WORD_STYLE_LINE_GAP_MAX,R as WORD_STYLE_LINE_GAP_MIN,O as WORD_STYLE_MARKS,h as WORD_STYLE_SIZE_MAX,g as WORD_STYLE_SIZE_MIN,D as WORD_STYLE_TEXT_GAP_MAX,W as WORD_STYLE_TEXT_GAP_MIN,L as WORD_STYLE_WEIGHT_MAX,m as WORD_STYLE_WEIGHT_MIN,d as normalizeWordStyle,s as normalizeWordStyles,I as wordStyleIsDefault,M as wordStyleTokens,$ as wordStylesFromRow,k as wordStylesToRow};
1
+ import{FONT_OPTIONS as a}from"./fonts.js";const i=["highlight","strong","quiet"],G={highlight:"Highlight",strong:"Bold",quiet:"Quiet"},T={highlight:{kind:"wordHighlight",delimiter:"@@"},strong:{kind:"wordStrong",delimiter:"++"},quiet:{kind:"wordQuiet",delimiter:"^^"}},N=Object.fromEntries(i.map(t=>[T[t].kind,t])),Y="data-sf-ws",g=["accent","text","labels"],E={accent:"var(--accent)",text:"var(--fg)",labels:"var(--fg-dim)"},O=80,h=120,m=100,L=900,R=.5,w=3,W=-.1,y=.5,D=3,s={font:null,size:null,weight:null,bold:null,italic:null,lineGap:null,textGap:null,colour:null},f={highlight:{...s},strong:{...s},quiet:{...s}};function _(t,e,o){return typeof t!="number"||!Number.isFinite(t)?null:Math.round(Math.min(Math.max(t,e),o))}function p(t,e,o){if(typeof t!="number"||!Number.isFinite(t))return null;const l=10**D;return Math.round(Math.min(Math.max(t,e),o)*l)/l}function d(t){return typeof t=="boolean"?t:null}function S(t){const e=typeof t?.font=="string"&&a.some(l=>l.key===t.font)?t.font:null,o=typeof t?.colour=="string"&&g.includes(t.colour)?t.colour:null;return{font:e,size:_(t?.size,O,h),weight:_(t?.weight,m,L),bold:d(t?.bold),italic:d(t?.italic),lineGap:p(t?.lineGap,R,w),textGap:p(t?.textGap,W,y),colour:o}}function c(t){const e={};for(const o of i)e[o]=t&&o in t&&t[o]?S(t[o]):{...f[o]};return e}function I(t,e){const o=S(e),l=f[t];return Object.keys(l).every(n=>o[n]===l[n])}function M(t){const e=c(t),o={};for(const l of i){const n=e[l],r=`--sf-ws-${l}`;if(n.font){const u=a.find(x=>x.key===n.font);u&&(o[`${r}-font`]=`var(${u.cssVar})`)}n.size!==null&&(o[`${r}-size`]=`${n.size/100}em`),n.weight!==null&&(o[`${r}-weight`]=String(n.weight)),n.bold!==null&&(o[`${r}-weight-bold`]=n.bold?"700":"400"),n.italic!==null&&(o[`${r}-style`]=n.italic?"italic":"normal"),n.lineGap!==null&&(o[`${r}-line`]=String(n.lineGap)),n.textGap!==null&&(o[`${r}-track`]=`${n.textGap}em`),n.colour!==null&&(o[`${r}-color`]=E[n.colour])}return o}function A(t){const e=t?.word_styles??void 0,o={};for(const l of i)e&&l in e&&(o[l]=e[l]??null);return c(o)}function $(t){return{word_styles:c(t)}}export{E as COLOUR_TOKEN,f as DEFAULT_WORD_STYLES,i as WORD_STYLES,Y as WORD_STYLE_ATTR,N as WORD_STYLE_BY_KIND,g as WORD_STYLE_COLOURS,D as WORD_STYLE_GAP_PRECISION,G as WORD_STYLE_LABELS,w as WORD_STYLE_LINE_GAP_MAX,R as WORD_STYLE_LINE_GAP_MIN,T as WORD_STYLE_MARKS,h as WORD_STYLE_SIZE_MAX,O as WORD_STYLE_SIZE_MIN,y as WORD_STYLE_TEXT_GAP_MAX,W as WORD_STYLE_TEXT_GAP_MIN,L as WORD_STYLE_WEIGHT_MAX,m as WORD_STYLE_WEIGHT_MIN,S as normalizeWordStyle,c as normalizeWordStyles,I as wordStyleIsDefault,M as wordStyleTokens,A as wordStylesFromRow,$ as wordStylesToRow};
@@ -14,6 +14,7 @@ interface ButtonBlockProps {
14
14
  iconPosition?: string;
15
15
  widthFit?: string;
16
16
  widthFitPhone?: string;
17
+ widthFitTablet?: string;
17
18
  buttonColor?: string;
18
19
  buttonTextColor?: string;
19
20
  buttonFillOpacity?: number;
@@ -1 +1 @@
1
- import{jsx as a}from"react/jsx-runtime";import{buttonArrowShown as L}from"../../format/lib/content/button-arrow.js";import{buttonIconAtEnd as N,buttonIconSide as T,buttonWidthClass as j,storedButtonIcon as _}from"../../format/lib/content/button-icon.js";import{buttonCornersStyle as v,buttonPadAttrs as O,buttonPaint as R}from"../lib/content/button-look.js";import{ArrowLongRightIcon as $,ArrowRightIcon as F,ArrowUpRightIcon as G,BagIcon as U,CarIcon as E,CartIcon as K,ChevronRightIcon as Y,DownloadIcon as z,EmailIcon as D,ExternalIcon as H,LocationIcon as J,PlayIcon as W,SearchIcon as q,TagIcon as M}from"efficient-shell/icons/efficient";import Q from"./BlockFrame.js";import V from"./Btn.js";import{renderGold as X}from"./goldPhrases.js";import{alignPhoneClass as b,BLOCK_ALIGN_JUSTIFY as Z}from"../../format/lib/content/block-align.js";const oo="sf-button-block",to={"arrow-right":F,"arrow-long-right":$,"arrow-up-right":G,"chevron-right":Y,external:H,cart:K,bag:U,tag:M,email:D,location:J,play:W,download:z,search:q,car:E};function no(o){const{label:p,href:c,variant:i,align:t,alignPhone:s,contained:I,arrow:C,icon:y,iconPosition:l,widthFit:d,widthFitPhone:B,buttonColor:n,buttonTextColor:h,hrefRewrite:m}=o,r=_(y),u=r&&r!=="none"?to[r]:void 0,P=r===void 0?L(C)?{}:{arrow:null}:u?{arrow:a(u,{size:16}),...T(l)==="before"?{glyphBefore:!0}:{}}:{arrow:null},f=O(o),g=[j(d,B),f?.className??""].filter(Boolean).join(" "),x=g?{className:g}:{},A=N(l,d)?{spread:!0}:{},e=R(o),S=e?e.background==="transparent"?"ghost":"primary":i,w={...e??(n?i==="ghost"?{borderColor:n}:{background:n,borderColor:n}:{}),...h?{color:h}:{},...f?.style??{},...v(o)??{}},k=Object.keys(w).length?{style:w}:{};return a(Q,{contained:I,className:`${oo} py-4`,children:a("div",{className:`flex${t?` ${Z[t]}`:""}${b("justify",t,s)?` ${b("justify",t,s)}`:""}`,children:a(V,{href:c||"#",variant:S,...x,...A,...P,...k,...c&&m?{hrefRewrite:m}:{},children:X(p)})})})}export{oo as BUTTON_BLOCK_CLASS,no as default};
1
+ import{jsx as a}from"react/jsx-runtime";import{buttonArrowShown as L}from"../../format/lib/content/button-arrow.js";import{buttonIconAtEnd as N,buttonIconSide as j,buttonWidthClass as _,storedButtonIcon as v}from"../../format/lib/content/button-icon.js";import{buttonCornersStyle as F,buttonPadAttrs as O,buttonPaint as R}from"../lib/content/button-look.js";import{ArrowLongRightIcon as $,ArrowRightIcon as G,ArrowUpRightIcon as U,BagIcon as E,CarIcon as K,CartIcon as Y,ChevronRightIcon as z,DownloadIcon as D,EmailIcon as H,ExternalIcon as J,LocationIcon as W,PlayIcon as q,SearchIcon as M,TagIcon as Q}from"efficient-shell/icons/efficient";import V from"./BlockFrame.js";import X from"./Btn.js";import{renderGold as Z}from"./goldPhrases.js";import{alignPhoneClass as b,BLOCK_ALIGN_JUSTIFY as oo}from"../../format/lib/content/block-align.js";const to="sf-button-block",no={"arrow-right":G,"arrow-long-right":$,"arrow-up-right":U,"chevron-right":z,external:J,cart:Y,bag:E,tag:Q,email:H,location:W,play:q,download:D,search:M,car:K};function ro(o){const{label:p,href:c,variant:i,align:t,alignPhone:l,contained:I,arrow:C,icon:y,iconPosition:s,widthFit:d,widthFitPhone:B,widthFitTablet:P,buttonColor:n,buttonTextColor:h,hrefRewrite:m}=o,r=v(y),u=r&&r!=="none"?no[r]:void 0,x=r===void 0?L(C)?{}:{arrow:null}:u?{arrow:a(u,{size:16}),...j(s)==="before"?{glyphBefore:!0}:{}}:{arrow:null},f=O(o),g=[_(d,B,P),f?.className??""].filter(Boolean).join(" "),A=g?{className:g}:{},S=N(s,d)?{spread:!0}:{},e=R(o),T=e?e.background==="transparent"?"ghost":"primary":i,w={...e??(n?i==="ghost"?{borderColor:n}:{background:n,borderColor:n}:{}),...h?{color:h}:{},...f?.style??{},...F(o)??{}},k=Object.keys(w).length?{style:w}:{};return a(V,{contained:I,className:`${to} py-4`,children:a("div",{className:`flex${t?` ${oo[t]}`:""}${b("justify",t,l)?` ${b("justify",t,l)}`:""}`,children:a(X,{href:c||"#",variant:T,...A,...S,...x,...k,...c&&m?{hrefRewrite:m}:{},children:Z(p)})})})}export{to as BUTTON_BLOCK_CLASS,ro as default};
@@ -1,12 +1,15 @@
1
1
  import { type ReactNode } from "react";
2
2
  import type { SlotComponent } from "efficient-easel/blocks";
3
+ import { type CardRowState } from "../../format/lib/content/card-state.js";
3
4
  import type { SourceRow } from "../../format/lib/content/block-sources.js";
5
+ export type { CardRowState } from "../../format/lib/content/card-state.js";
4
6
  export type CardRow = {
5
7
  row: SourceRow;
6
8
  index: number;
7
9
  ownerType?: string;
8
10
  item?: unknown;
9
11
  nested?: boolean;
12
+ state?: CardRowState;
10
13
  };
11
14
  export declare const CardRowContext: import("react").Context<CardRow | null>;
12
15
  export declare function useCardRow(): CardRow | null;
@@ -21,9 +24,9 @@ type CardTemplateRowsProps = {
21
24
  Template: SlotComponent | undefined;
22
25
  rows: readonly SourceRow[];
23
26
  items?: readonly unknown[];
27
+ states?: readonly (CardRowState | undefined)[];
24
28
  fallback: ReactNode;
25
29
  wrapCopy?: (copy: ReactNode, row: CardRow) => ReactNode;
26
30
  children: (cards: ReactNode) => ReactNode;
27
31
  };
28
- export declare function CardTemplateRows({ ownerId, ownerType, Template, rows, items, fallback, wrapCopy, children }: CardTemplateRowsProps): import("react").JSX.Element;
29
- export {};
32
+ export declare function CardTemplateRows({ ownerId, ownerType, Template, rows, items, states, fallback, wrapCopy, children }: CardTemplateRowsProps): import("react").JSX.Element;
@@ -1 +1 @@
1
- "use client";import{Fragment as u,jsx as r}from"react/jsx-runtime";import{createContext as _,useContext as i}from"react";import{REPEAT_ATTRIBUTE as w,REPEAT_INDEX_ATTRIBUTE as x}from"efficient-easel/draw";import{CARD_TEMPLATE_SLOT as A,rowFilledProps as h}from"../../format/lib/content/card-template.js";const e=_(null);function I(){return i(e)}function g({type:c,props:s,children:t}){const o=i(e);return r(u,{children:t(h(c,s,o?.row),o)})}function j({ownerId:c,ownerType:s,Template:t,rows:o,items:m,fallback:T,wrapCopy:a,children:E}){const R=i(e);if(!t||(t.blockCount??0)<=0)return r(u,{children:T});const f=R!==null,p=o.map((C,n)=>{const l={row:C,index:n,ownerType:s,item:m?.[n],nested:f},d=r("div",{[w]:`${c}:${A}`,[x]:n,children:r(t,{})});return r(e.Provider,{value:l,children:a?a(d,l):d},n)});return r(u,{children:E(p)})}export{e as CardRowContext,g as CardRowDrawn,j as CardTemplateRows,I as useCardRow};
1
+ "use client";import{Fragment as s,jsx as r,jsxs as h}from"react/jsx-runtime";import{createContext as x,useContext as i}from"react";import{REPEAT_ATTRIBUTE as w,REPEAT_INDEX_ATTRIBUTE as S}from"efficient-easel/draw";import{CARD_TEMPLATE_SLOT as P,rowFilledProps as j}from"../../format/lib/content/card-template.js";import{CARD_STATE_LINE_CLASS as D,cardStateAttrs as I,cardStateValue as L}from"../../format/lib/content/card-state.js";const c=x(null);function U(){return i(c)}function $({type:a,props:u,children:t}){const n=i(c);return r(s,{children:t(j(a,u,n?.row),n)})}function b({ownerId:a,ownerType:u,Template:t,rows:n,items:E,states:T,fallback:_,wrapCopy:l,children:A}){const C=i(c);if(!t||(t.blockCount??0)<=0)return r(s,{children:_});const R=C!==null,f=n.map((p,o)=>{const e=T?.[o],d={row:p,index:o,ownerType:u,item:E?.[o],nested:R,...e?{state:e}:null},m=r("div",{[w]:`${a}:${P}`,[S]:o,...I(e),children:L(e)?h(s,{children:[r(t,{}),r("span",{"aria-hidden":"true",className:D})]}):r(t,{})});return r(c.Provider,{value:d,children:l?l(m,d):m},o)});return r(s,{children:A(f)})}export{c as CardRowContext,$ as CardRowDrawn,b as CardTemplateRows,U as useCardRow};
@@ -9,6 +9,7 @@ type AlignItems = "start" | "center" | "end" | "stretch";
9
9
  interface FlexProps {
10
10
  padV2?: boolean;
11
11
  border?: unknown;
12
+ borderTablet?: unknown;
12
13
  borderPhone?: unknown;
13
14
  direction: Direction;
14
15
  label?: string;
@@ -60,5 +61,5 @@ interface FlexProps {
60
61
  mirrorCards?: unknown;
61
62
  content: SlotComponent;
62
63
  }
63
- export default function Flex({ direction, label, tabShape, gap, gapPhone, gapTablet, justify, align, wrap, share, sharePhone, shareTablet, wrapPhone, phoneRow, columns, columnsTablet, separator, blockSpacing, bgImage, bgImagePhone, pictureHover, darken, darkenStyle, placement, padV2, border, borderPhone, pad, contained, fillHeight, shadow, loop, scrollDirection, loopSeconds, loopDelay, editing, fillColor, line, upcoming, link, boxShape, boxShapePhone, boxShapeTablet, jumpHighlight, anchor, sharedSides, boxId, mirrorCards, content: Content, }: FlexProps): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | import("react").JSX.Element | null | undefined;
64
+ export default function Flex({ direction, label, tabShape, gap, gapPhone, gapTablet, justify, align, wrap, share, sharePhone, shareTablet, wrapPhone, phoneRow, columns, columnsTablet, separator, blockSpacing, bgImage, bgImagePhone, pictureHover, darken, darkenStyle, placement, padV2, border, borderTablet, borderPhone, pad, contained, fillHeight, shadow, loop, scrollDirection, loopSeconds, loopDelay, editing, fillColor, line, upcoming, link, boxShape, boxShapePhone, boxShapeTablet, jumpHighlight, anchor, sharedSides, boxId, mirrorCards, content: Content, }: FlexProps): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | import("react").JSX.Element | null | undefined;
64
65
  export {};
@@ -1 +1 @@
1
- import{Fragment as g,jsx as s,jsxs as eo}from"react/jsx-runtime";import{useId as Ie}from"react";import{parseHexColor as Me}from"efficient-shell/format";import We from"./BoxTabs.js";import{BoxTabPaneContext as je,useIsTabPane as He}from"./BoxTabPaneContext.js";import{CellFillContext as Ue,InBoxContext as Xe,useCellOfStretchedRow as Ge,useFillsCell as ze}from"./InBoxContext.js";import Je,{InsideSiteColumn as Jo,useInsideSiteGutter as Ke,useSectionRoot as Ye}from"./SiteGutterFrame.js";import{BoxSurfaceProvider as qe}from"./BoxSurfaceContext.js";import Qe from"./PictureWash.js";import{BoxCellWidthContext as Ve}from"./BoxCellWidthContext.js";import{useInSiteHeader as Ze}from"./PhoneMenuTools.js";import{useCardRow as os}from"./CardRowContext.js";import{framesItsCards as es}from"../../format/lib/content/card-place.js";import{MirrorContext as ss,useMirroredCopy as ts,useUnderCardBox as rs}from"./MirrorContext.js";import{isMirroredCopy as ns,mirrorCardsActs as ls,mirroredBoxClass as as,MIRROR_ROW_CLASS as cs,ownsCard as ms}from"../../format/lib/content/mirror-cards.js";import{FRAME_BASE as so,FRAME_GUTTER as to}from"./BlockFrame.js";import{containerGapProps as is}from"../../format/lib/content/container-gap.js";import{boxLayoutClasses as us,boxBlockSpacingClass as ds,boxFitContentClass as fs,boxRowColumnsClass as Cs,boxRowTabletColumnsClass as ps,boxRowTabletShareClass as Ss,boxPhoneRowClasses as L,boxPhoneRowFits as bs,boxShareClasses as F,boxWrapClass as xs}from"../../format/lib/content/box-layout.js";import{boxSeparatorClasses as hs,boxSeparatorSeamClass as $s,boxSeparatorStyle as _s,isStripBox as Ps}from"../../format/lib/content/box-separator.js";import{DEFAULT_LOOP_DELAY as Rs,DEFAULT_LOOP_DIRECTION as ys,DEFAULT_LOOP_SECONDS as Ls,isVerticalLoop as As}from"../../format/lib/animation/index.js";import{LoopTrack as ws}from"../lib/animation/LoopTrack.js";import{BOX_CARD_PAD as m,BOX_OWNS_SIDES_CLASS as Os,boxDarkenStyle as Bs,boxPlacementClasses as Ts,CARD_SHADOW_CLASS as vs,isBackgroundBox as Ko}from"../../format/lib/content/box-background.js";import{boxShadowAttrs as Yo}from"../../format/lib/content/box-shadow.js";import{boxRunsEdgeToEdge as Ns,drawsSiteGutter as Es}from"../../format/lib/content/site-gutter.js";import{boxShapeClass as ks,boxShapeClasses as gs}from"../../format/lib/content/box-shape.js";import{BOX_JUMP_ATTR as Fs,BOX_LINK_ATTR as qo,BOX_LINK_CLASS as Qo,BOX_LINKED_CLASS as Ds,boxJumpBlocksClass as Is,boxJumpCss as Ms,boxJumpSlug as Ws,boxLinkOf as js}from"../../format/lib/content/box-link.js";import{SiteLink as Hs}from"../lib/site-runtime.js";import{sectionBorderStyle as Vo}from"../../format/lib/content/borders.js";import{finiteNumber as i}from"../../format/lib/finite-number.js";import{sectionPadAttrs as Us}from"../lib/content/section-padding.js";import{SECTION_FILL_CLASS as D}from"../../format/lib/content/section-min-height.js";import{ON_MEDIA_INK_STYLE as Xs}from"../../format/lib/content/ink.js";import{sizedBackground as ro}from"../../format/lib/sized-image.js";import{PHOTO_HOST_ATTR as Gs,resolveImageTreatment as zs}from"../../format/lib/content/image-treatment.js";import{BoxRail as Js,BoxRailStop as Ks,RAIL_STOPS_CLASS as Ys,useTimelineRail as qs}from"./TimelineRail.js";import{SHARED_PLAIN_ATTR as Qs,sharedColumnsClasses as Vs,sharedColumnsCss as Zs}from"../lib/content/box-shared-columns.js";import ot from"./PhotoHoverSheet.js";const no={"--sf-site-gutter":"0px"},et={overflowX:"clip",overflowY:"visible"},st={desktop:!1,phone:!1},Zo="bg-cover bg-center bg-[image:var(--sf-box-bg)] max-view-tablet:bg-[image:var(--sf-box-bg-p)]",lo=o=>o==null||o==="",ao=o=>!lo(o)&&Number(o)===0;function tt({children:o}){return s(g,{children:o(Ie())})}function rt({direction:o,label:oe,tabShape:ee,gap:co,gapPhone:se,gapTablet:I,justify:A,align:C,wrap:mo,share:p,sharePhone:M,shareTablet:io,wrapPhone:te,phoneRow:w,columns:O,columnsTablet:W,separator:n,blockSpacing:re,bgImage:h,bgImagePhone:uo,pictureHover:ne,darken:le,darkenStyle:ae,placement:ce,padV2:fo=!1,border:Co,borderPhone:po,pad:r={},contained:j=!0,fillHeight:u=!1,shadow:So,loop:S,scrollDirection:H=ys,loopSeconds:me=Ls,loopDelay:ie=Rs,editing:bo=!1,fillColor:xo,line:$,upcoming:ue,link:de,boxShape:ho,boxShapePhone:fe,boxShapeTablet:Ce,jumpHighlight:pe,anchor:Se,sharedSides:B=st,boxId:$o,mirrorCards:be,content:_}){const b=bo?"":js(de),l=u?"":gs(ho,fe,Ce),xe=!u&&ks(ho)!=="",d=Ws(pe,Se),U=typeof xo=="string"?Me(xo.trim()):null,_o=U?{backgroundColor:U}:void 0,Po=qs(),X=$===!0&&o!=="tabs",t=Ko(h),T=Ze(),he=Ye(),Ro=He(),G=ze(),$e=Ge(),v=Ps(o,n),a=S==="scroll"&&o!=="tabs",x=os(),_e=ts(),Pe=rs(),N=ms({inCopy:x!==null,nestedCopy:x?.nested===!0,underBox:Pe}),z=N&&es(x?.ownerType),yo=ls({direction:o,separator:n,loop:S,line:$,bgImage:h,columns:O,columnsTablet:W,share:p,wrap:mo},N,B.desktop)&&ns(be,x?.index),Lo=t||N?"":as(_e,o,a?void 0:A,C),E=Cs({direction:o,separator:n,loop:S,line:$,columns:O}),J=ps({direction:o,separator:n,loop:S,line:$,columnsTablet:W}),Ao=Ss({direction:o,separator:n,loop:S,line:$,columns:O,columnsTablet:W,share:p,shareTablet:io}),Re=Ke(),k=Vs(B,_.blockCount??0),ye=k&&(!x||x.index===0)?Zs(B,_.blockCount??0):"",wo=[F(p),o==="row"?fs(p):"",E,J,Ao,ds(re),hs(o,n)].filter(Boolean).join(" "),Le=wo?` ${wo}`:"",Oo=["flex",o==="row"?v||a?"flex-row":`flex-row ${L(w,M,te)}`:"flex-col",xs(a?!1:mo),t?Ts(ce??"center",o):us(a?void 0:A,C)+(Lo?` ${Lo}`:"")].join(" ")+Le,P=u||t||l||G?` ${D}`:"",K=xe?` ${l}`:l?`${P} ${l}`:P,Bo=$e&&o==="column"&&!t&&!a&&F(p)===""&&typeof A=="string"&&A!=="start",To=P||(Bo?` ${D}`:""),Y=b?` ${Ds}`:"",q=t||T||fo?"":" py-6",Ae=`${so}${q} ${to}${K}${Y}`,we=T?`${K}${Y}`.trim():`w-full${q}${K}${Y}`,R=is("Flex",co,o==="row"?"inline":"block",se,v||a?void 0:I),Oe=v?{...R.style,..._s(o,n)}:R.style,vo=(e="")=>s(_,{className:`${Oo}${yo?` ${cs}`:""}${R.className}${To}${e?` ${e}`:""}${X?` ${Ys}`:""}${d?` ${Is(d)}`:""}${k}`,style:Oe,minEmptyHeight:120}),No=As(H)?"":$s(o,n),Eo=a?s(ws,{direction:H,seconds:me,delay:ie,editing:bo,copy:e=>vo(e&&No?`${e} ${No}`:e)}):vo(),ko=o==="tabs"?s(We,{className:`${Oo}${R.className}${G&&!u&&!t&&!l?"":P}`,style:R.style,shape:ee,children:Eo}):Eo,go=Ro?s(je.Provider,{value:!1,children:ko}):ko,Be={stretchedRow:o==="row"&&!t&&(C===void 0||C==="stretch"),fillingColumn:o==="column"&&(G||Bo),columnsRow:E!==""||J!==""||k!=="",...$o?{id:$o}:null},Fo=s(Xe.Provider,{value:Be,children:s(Ue.Provider,{value:!1,children:N?s(ss.Provider,{value:yo,children:go}):go})}),Q=X?s(Js,{row:o==="row",stops:_.blockCount??0,children:Fo}):Fo,Te=oe?.trim()||(Ro?"":void 0),ve={values:r,frame:q?24:0},Ne=e=>Po?s(Ks,{on:Po,future:ue===!0,children:e}):e,Ee=e=>b.startsWith("/")?s(Hs,{href:b,className:Qo,"aria-labelledby":e,[qo]:""}):s("a",{href:b,className:Qo,"aria-labelledby":e,[qo]:""}),Do=(d?Ms(d):"")+ye,Io=Do?s("style",{dangerouslySetInnerHTML:{__html:Do}}):null,y=Ns({loop:S,direction:o,scrollDirection:H,bgImage:h}),ke=B.desktop&&k!==""&&!U&&!Vo(Co,po)&&Object.keys(Yo(So)).length===0&&!b&&!l&&!u&&!d&&!Es(j&&!y,Re)&&ao(co)&&(lo(I)||ao(I))&&fo&&Object.values(r).every(e=>lo(e)||ao(e)),ge=e=>({...ke?{[Qs]:""}:null,...t?null:Yo(So),...d?{[Fs]:d}:null,...e?{id:e}:null}),Mo=E!==""?Number(O):0,Fe=L(w,M)===L(void 0),De=(o==="column"||o==="row"&&!v&&!a&&(Mo===1&&Fe||Mo===0&&_.blockCount===1))&&!t&&!X&&!T,Wo=t&&he&&!T,jo=(e,c)=>Ne(s(Je,{contained:j&&!y,style:y?no:void 0,framedClass:Ae,fillClass:we,columnClass:`${so} ${to}${To}`,tabLabel:Te,pad:t?void 0:ve,border:Vo(Co,po),outerAttrs:ge(c),box:!0,edge:De,outerStyle:t?void 0:_o,bleed:Wo,children:Io||c?eo(g,{children:[Io,c?Ee(c):null,y?s(Jo,{children:e}):e]}):y?s(Jo,{children:e}):e})),Ho=e=>b?s(tt,{children:c=>jo(e,c)}):jo(e);if(!t){const e=C===void 0||C==="stretch",c=(F(p)!==""||E!==""||J!=="")&&!bs(w,M)&&!(Ao!==""&&F(io)==="")&&(e||L(w)!==L(void 0));return Ho((o==="row"?c:o==="column"&&e)?s(Ve.Provider,{value:!0,children:Q}):Q)}const V=Bs(le,ae),Z=Ko(uo),Uo=Z?{"--sf-box-bg":ro(h??""),"--sf-box-bg-p":ro(uo??"")}:{backgroundImage:ro(h??""),backgroundSize:"cover",backgroundPosition:"center"},Xo=zs(void 0,void 0,ne),f=Xo.className?Xo:null,oo=Us({...r,top:i(r.top)??m.desktop,bottom:i(r.bottom)??m.desktop,topPhone:i(r.topPhone)??m.phone,bottomPhone:i(r.bottomPhone)??m.phone,left:i(r.left)??m.side,right:i(r.right)??m.side,leftPhone:i(r.leftPhone)??m.sidePhone,rightPhone:i(r.rightPhone)??m.sidePhone}),Go=s("div",{className:`relative z-[1] ${Os} ${oo?.className??""}${u||l?` ${D}`:""}`.trimEnd(),style:V?{...oo?.style,...no,...Xs}:{...oo?.style,...no},children:Q}),zo=Wo&&j?s("div",{className:`${so} ${to}${u||l?` ${D}`:""}`,children:Go}):Go;return Ho(s(g,{children:eo("div",{className:`relative isolate overflow-hidden ${vs}${P}${Z&&!f?` ${Zo}`:""}`,style:{...z?et:{},..._o,...f?{}:Uo},...f?{[Gs]:""}:{},children:[f&&eo(g,{children:[s(ot,{sheet:f.sheet}),s("div",{"aria-hidden":!0,className:`absolute inset-0${z?" rounded-[inherit]":""}${Z?` ${Zo}`:""} ${f.className}`,style:{...Uo,...f.style??{}}})]}),s(Qe,{wash:V,...z?{className:"rounded-[inherit]"}:{}}),V?s(qe,{children:zo}):zo]})}))}export{rt as default};
1
+ import{Fragment as g,jsx as s,jsxs as eo}from"react/jsx-runtime";import{useId as Me}from"react";import{parseHexColor as We}from"efficient-shell/format";import je from"./BoxTabs.js";import{BoxTabPaneContext as He,useIsTabPane as Ue}from"./BoxTabPaneContext.js";import{CellFillContext as Xe,InBoxContext as Ge,useCellOfStretchedRow as ze,useFillsCell as Je}from"./InBoxContext.js";import Ke,{InsideSiteColumn as Ko,useInsideSiteGutter as Ye,useSectionRoot as qe}from"./SiteGutterFrame.js";import{BoxSurfaceProvider as Qe}from"./BoxSurfaceContext.js";import Ve from"./PictureWash.js";import{BoxCellWidthContext as Ze}from"./BoxCellWidthContext.js";import{useInSiteHeader as os}from"./PhoneMenuTools.js";import{useCardRow as es}from"./CardRowContext.js";import{framesItsCards as ss}from"../../format/lib/content/card-place.js";import{MirrorContext as ts,useMirroredCopy as rs,useUnderCardBox as ns}from"./MirrorContext.js";import{isMirroredCopy as ls,mirrorCardsActs as as,mirroredBoxClass as cs,MIRROR_ROW_CLASS as ms,ownsCard as is}from"../../format/lib/content/mirror-cards.js";import{FRAME_BASE as so,FRAME_GUTTER as to}from"./BlockFrame.js";import{containerGapProps as us}from"../../format/lib/content/container-gap.js";import{boxLayoutClasses as ds,boxBlockSpacingClass as fs,boxFitContentClass as Cs,boxRowColumnsClass as ps,boxRowTabletColumnsClass as Ss,boxRowTabletShareClass as xs,boxPhoneRowClasses as L,boxPhoneRowFits as bs,boxShareClasses as F,boxWrapClass as hs}from"../../format/lib/content/box-layout.js";import{boxSeparatorClasses as $s,boxSeparatorSeamClass as _s,boxSeparatorStyle as Ps,isStripBox as Rs}from"../../format/lib/content/box-separator.js";import{DEFAULT_LOOP_DELAY as ys,DEFAULT_LOOP_DIRECTION as Ls,DEFAULT_LOOP_SECONDS as As,isVerticalLoop as ws}from"../../format/lib/animation/index.js";import{LoopTrack as Os}from"../lib/animation/LoopTrack.js";import{BOX_CARD_PAD as m,BOX_OWNS_SIDES_CLASS as Bs,boxDarkenStyle as Ts,boxPlacementClasses as vs,CARD_SHADOW_CLASS as Ns,isBackgroundBox as Yo}from"../../format/lib/content/box-background.js";import{boxShadowAttrs as qo}from"../../format/lib/content/box-shadow.js";import{boxRunsEdgeToEdge as Es,drawsSiteGutter as ks}from"../../format/lib/content/site-gutter.js";import{boxShapeClass as gs,boxShapeClasses as Fs}from"../../format/lib/content/box-shape.js";import{BOX_JUMP_ATTR as Ds,BOX_LINK_ATTR as Qo,BOX_LINK_CLASS as Vo,BOX_LINKED_CLASS as Is,boxJumpBlocksClass as Ms,boxJumpCss as Ws,boxJumpSlug as js,boxLinkOf as Hs}from"../../format/lib/content/box-link.js";import{SiteLink as Us}from"../lib/site-runtime.js";import{sectionBorderStyle as Zo}from"../../format/lib/content/borders.js";import{finiteNumber as i}from"../../format/lib/finite-number.js";import{sectionPadAttrs as Xs}from"../lib/content/section-padding.js";import{SECTION_FILL_CLASS as D}from"../../format/lib/content/section-min-height.js";import{ON_MEDIA_INK_STYLE as Gs}from"../../format/lib/content/ink.js";import{sizedBackground as ro}from"../../format/lib/sized-image.js";import{PHOTO_HOST_ATTR as zs,resolveImageTreatment as Js}from"../../format/lib/content/image-treatment.js";import{BoxRail as Ks,BoxRailStop as Ys,RAIL_STOPS_CLASS as qs,useTimelineRail as Qs}from"./TimelineRail.js";import{SHARED_PLAIN_ATTR as Vs,sharedColumnsClasses as Zs,sharedColumnsCss as ot}from"../lib/content/box-shared-columns.js";import et from"./PhotoHoverSheet.js";const no={"--sf-site-gutter":"0px"},st={overflowX:"clip",overflowY:"visible"},tt={desktop:!1,phone:!1},oe="bg-cover bg-center bg-[image:var(--sf-box-bg)] max-view-tablet:bg-[image:var(--sf-box-bg-p)]",lo=o=>o==null||o==="",ao=o=>!lo(o)&&Number(o)===0;function rt({children:o}){return s(g,{children:o(Me())})}function nt({direction:o,label:ee,tabShape:se,gap:co,gapPhone:te,gapTablet:I,justify:A,align:C,wrap:mo,share:p,sharePhone:M,shareTablet:io,wrapPhone:re,phoneRow:w,columns:O,columnsTablet:W,separator:n,blockSpacing:ne,bgImage:h,bgImagePhone:uo,pictureHover:le,darken:ae,darkenStyle:ce,placement:me,padV2:fo=!1,border:Co,borderTablet:po,borderPhone:So,pad:r={},contained:j=!0,fillHeight:u=!1,shadow:xo,loop:S,scrollDirection:H=Ls,loopSeconds:ie=As,loopDelay:ue=ys,editing:bo=!1,fillColor:ho,line:$,upcoming:de,link:fe,boxShape:$o,boxShapePhone:Ce,boxShapeTablet:pe,jumpHighlight:Se,anchor:xe,sharedSides:B=tt,boxId:_o,mirrorCards:be,content:_}){const x=bo?"":Hs(fe),l=u?"":Fs($o,Ce,pe),he=!u&&gs($o)!=="",d=js(Se,xe),U=typeof ho=="string"?We(ho.trim()):null,Po=U?{backgroundColor:U}:void 0,Ro=Qs(),X=$===!0&&o!=="tabs",t=Yo(h),T=os(),$e=qe(),yo=Ue(),G=Je(),_e=ze(),v=Rs(o,n),a=S==="scroll"&&o!=="tabs",b=es(),Pe=rs(),Re=ns(),N=is({inCopy:b!==null,nestedCopy:b?.nested===!0,underBox:Re}),z=N&&ss(b?.ownerType),Lo=as({direction:o,separator:n,loop:S,line:$,bgImage:h,columns:O,columnsTablet:W,share:p,wrap:mo},N,B.desktop)&&ls(be,b?.index),Ao=t||N?"":cs(Pe,o,a?void 0:A,C),E=ps({direction:o,separator:n,loop:S,line:$,columns:O}),J=Ss({direction:o,separator:n,loop:S,line:$,columnsTablet:W}),wo=xs({direction:o,separator:n,loop:S,line:$,columns:O,columnsTablet:W,share:p,shareTablet:io}),ye=Ye(),k=Zs(B,_.blockCount??0),Le=k&&(!b||b.index===0)?ot(B,_.blockCount??0):"",Oo=[F(p),o==="row"?Cs(p):"",E,J,wo,fs(ne),$s(o,n)].filter(Boolean).join(" "),Ae=Oo?` ${Oo}`:"",Bo=["flex",o==="row"?v||a?"flex-row":`flex-row ${L(w,M,re)}`:"flex-col",hs(a?!1:mo),t?vs(me??"center",o):ds(a?void 0:A,C)+(Ao?` ${Ao}`:"")].join(" ")+Ae,P=u||t||l||G?` ${D}`:"",K=he?` ${l}`:l?`${P} ${l}`:P,To=_e&&o==="column"&&!t&&!a&&F(p)===""&&typeof A=="string"&&A!=="start",vo=P||(To?` ${D}`:""),Y=x?` ${Is}`:"",q=t||T||fo?"":" py-6",we=`${so}${q} ${to}${K}${Y}`,Oe=T?`${K}${Y}`.trim():`w-full${q}${K}${Y}`,R=us("Flex",co,o==="row"?"inline":"block",te,v||a?void 0:I),Be=v?{...R.style,...Ps(o,n)}:R.style,No=(e="")=>s(_,{className:`${Bo}${Lo?` ${ms}`:""}${R.className}${vo}${e?` ${e}`:""}${X?` ${qs}`:""}${d?` ${Ms(d)}`:""}${k}`,style:Be,minEmptyHeight:120}),Eo=ws(H)?"":_s(o,n),ko=a?s(Os,{direction:H,seconds:ie,delay:ue,editing:bo,copy:e=>No(e&&Eo?`${e} ${Eo}`:e)}):No(),go=o==="tabs"?s(je,{className:`${Bo}${R.className}${G&&!u&&!t&&!l?"":P}`,style:R.style,shape:se,children:ko}):ko,Fo=yo?s(He.Provider,{value:!1,children:go}):go,Te={stretchedRow:o==="row"&&!t&&(C===void 0||C==="stretch"),fillingColumn:o==="column"&&(G||To),columnsRow:E!==""||J!==""||k!=="",..._o?{id:_o}:null},Do=s(Ge.Provider,{value:Te,children:s(Xe.Provider,{value:!1,children:N?s(ts.Provider,{value:Lo,children:Fo}):Fo})}),Q=X?s(Ks,{row:o==="row",stops:_.blockCount??0,children:Do}):Do,ve=ee?.trim()||(yo?"":void 0),Ne={values:r,frame:q?24:0},Ee=e=>Ro?s(Ys,{on:Ro,future:de===!0,children:e}):e,ke=e=>x.startsWith("/")?s(Us,{href:x,className:Vo,"aria-labelledby":e,[Qo]:""}):s("a",{href:x,className:Vo,"aria-labelledby":e,[Qo]:""}),Io=(d?Ws(d):"")+Le,Mo=Io?s("style",{dangerouslySetInnerHTML:{__html:Io}}):null,y=Es({loop:S,direction:o,scrollDirection:H,bgImage:h}),ge=B.desktop&&k!==""&&!U&&!Zo(Co,So,po)&&Object.keys(qo(xo)).length===0&&!x&&!l&&!u&&!d&&!ks(j&&!y,ye)&&ao(co)&&(lo(I)||ao(I))&&fo&&Object.values(r).every(e=>lo(e)||ao(e)),Fe=e=>({...ge?{[Vs]:""}:null,...t?null:qo(xo),...d?{[Ds]:d}:null,...e?{id:e}:null}),Wo=E!==""?Number(O):0,De=L(w,M)===L(void 0),Ie=(o==="column"||o==="row"&&!v&&!a&&(Wo===1&&De||Wo===0&&_.blockCount===1))&&!t&&!X&&!T,jo=t&&$e&&!T,Ho=(e,c)=>Ee(s(Ke,{contained:j&&!y,style:y?no:void 0,framedClass:we,fillClass:Oe,columnClass:`${so} ${to}${vo}`,tabLabel:ve,pad:t?void 0:Ne,border:Zo(Co,So,po),outerAttrs:Fe(c),box:!0,edge:Ie,outerStyle:t?void 0:Po,bleed:jo,children:Mo||c?eo(g,{children:[Mo,c?ke(c):null,y?s(Ko,{children:e}):e]}):y?s(Ko,{children:e}):e})),Uo=e=>x?s(rt,{children:c=>Ho(e,c)}):Ho(e);if(!t){const e=C===void 0||C==="stretch",c=(F(p)!==""||E!==""||J!=="")&&!bs(w,M)&&!(wo!==""&&F(io)==="")&&(e||L(w)!==L(void 0));return Uo((o==="row"?c:o==="column"&&e)?s(Ze.Provider,{value:!0,children:Q}):Q)}const V=Ts(ae,ce),Z=Yo(uo),Xo=Z?{"--sf-box-bg":ro(h??""),"--sf-box-bg-p":ro(uo??"")}:{backgroundImage:ro(h??""),backgroundSize:"cover",backgroundPosition:"center"},Go=Js(void 0,void 0,le),f=Go.className?Go:null,oo=Xs({...r,top:i(r.top)??m.desktop,bottom:i(r.bottom)??m.desktop,topPhone:i(r.topPhone)??m.phone,bottomPhone:i(r.bottomPhone)??m.phone,left:i(r.left)??m.side,right:i(r.right)??m.side,leftPhone:i(r.leftPhone)??m.sidePhone,rightPhone:i(r.rightPhone)??m.sidePhone}),zo=s("div",{className:`relative z-[1] ${Bs} ${oo?.className??""}${u||l?` ${D}`:""}`.trimEnd(),style:V?{...oo?.style,...no,...Gs}:{...oo?.style,...no},children:Q}),Jo=jo&&j?s("div",{className:`${so} ${to}${u||l?` ${D}`:""}`,children:zo}):zo;return Uo(s(g,{children:eo("div",{className:`relative isolate overflow-hidden ${Ns}${P}${Z&&!f?` ${oe}`:""}`,style:{...z?st:{},...Po,...f?{}:Xo},...f?{[zs]:""}:{},children:[f&&eo(g,{children:[s(et,{sheet:f.sheet}),s("div",{"aria-hidden":!0,className:`absolute inset-0${z?" rounded-[inherit]":""}${Z?` ${oe}`:""} ${f.className}`,style:{...Xo,...f.style??{}}})]}),s(Ve,{wash:V,...z?{className:"rounded-[inherit]"}:{}}),V?s(Qe,{children:Jo}):Jo]})}))}export{nt as default};
@@ -1,2 +1,2 @@
1
- import{jsxs as a,jsx as t}from"react/jsx-runtime";import{Fragment as h}from"react";import{parseHexColor as N}from"efficient-shell/format";import{linePrefix as _,storefrontLines as S}from"../../format/lib/markup.js";import{COLOUR_TOKEN as p,WORD_STYLE_ATTR as g,WORD_STYLE_BY_KIND as E}from"../../format/lib/word-styles.js";import f from"./PartStyledText.js";import{withRMark as d}from"./RMark.js";function T(e,n=!1,s){const r=x(n),c=S(e);if(c.length===1){const[o]=c,l=_(o),L=l?A(l,o.children):o.children;return a(f,{value:e,children:[s,u(L,r)]})}const i=[];return c.forEach((o,l)=>{if(o.bullet){i.push(t("span",{"data-sf-bullet":"",className:C,children:u(o.children,r)},l));return}if(o.number!=null){i.push(a("span",{"data-sf-number":o.number,className:R,children:[a("span",{className:k,children:[o.number,"."]}),u(o.children,r)]},l));return}l>0&&!w(c[l-1])&&i.push(t("br",{},`br${l}`)),i.push(t(h,{children:u(o.children,r)},l))}),a(f,{value:e,children:[s,i]})}const C="relative block pl-6 before:absolute before:left-1.5 before:font-bold before:text-accent before:content-['·']",R="relative block pl-[2em]",k="absolute left-0 w-[1.6em] text-right tabular-nums";function w(e){return e.bullet||e.number!=null}const O="text-accent underline underline-offset-[0.18em]";function A(e,n){const[s,...r]=n;return s?.kind==="text"?[{kind:"text",text:`${e}${s.text}`},...r]:[{kind:"text",text:e},...n]}function B(e){if(e)return N(e)===e.toLowerCase()?e:Object.hasOwn(p,e)?p[e]:void 0}function u(e,n){const s=[];let r=!1;return e.forEach((c,i)=>{if(c.kind==="text"){s.push(t("span",{children:d(c.text)},i)),r=!0;return}r||s.push(t("span",{},`e${i}`)),s.push(b(c,i,n)),r=!1}),r||s.push(t("span",{},"end")),s}function m(e,n){return e.length===1&&e[0].kind==="text"?d(e[0].text):e.map((s,r)=>s.kind==="text"?t(h,{children:d(s.text)},r):b(s,r,n))}function D(e,n=!1){return u(e,x(n))}function x(e){return e?"font-normal italic text-accent":"not-italic text-accent"}function P(e){return t(f,{value:e,children:t("span",{children:e})})}function b(e,n,s){if(e.kind==="link")return t("a",{href:e.href,className:O,children:m(e.children,s)},n);const r=m(e.children,s),c=E[e.kind];if(c)return t("span",{[g]:c,children:r},n);switch(e.kind){case"underline":return t("u",{children:r},n);case"sup":return t("sup",{children:r},n);case"sub":return t("sub",{children:r},n);case"color":{const i=B(e.color);return i?t("span",{style:{color:i},children:r},n):t("span",{children:r},n)}case"accent":case"highlight":return t("em",{className:s,children:r},n);case"bold":return t("strong",{className:"font-semibold",children:r},n);case"italic":return t("em",{className:"italic",children:r},n);case"strike":return t("s",{className:"line-through",children:r},n);default:return t("span",{children:r},n)}}function Y(e,n=!0){const s=e.split(`
2
- `);return t(f,{value:e,children:s.map((r,c)=>a("span",{children:[T(r,n),c<s.length-1?t("br",{}):null]},c))})}function H(e){return e.split(/\n\s*\n/).map(n=>n.trim()).filter(Boolean)}export{P as renderChrome,T as renderGold,Y as renderHeadline,D as renderMarkupNodes,H as splitParagraphs};
1
+ import{jsxs as a,jsx as t}from"react/jsx-runtime";import{Fragment as h}from"react";import{linePrefix as N,storefrontLines as L}from"../../format/lib/markup.js";import{WORD_STYLE_ATTR as _,WORD_STYLE_BY_KIND as S}from"../../format/lib/word-styles.js";import{partInkCss as g}from"../../format/lib/document/part-inks.js";import f from"./PartStyledText.js";import{withRMark as d}from"./RMark.js";function E(e,n=!1,s){const r=m(n),c=L(e);if(c.length===1){const[i]=c,o=N(i),b=o?C(o,i.children):i.children;return a(f,{value:e,children:[s,u(b,r)]})}const l=[];return c.forEach((i,o)=>{if(i.bullet){l.push(t("span",{"data-sf-bullet":"",className:k,children:u(i.children,r)},o));return}if(i.number!=null){l.push(a("span",{"data-sf-number":i.number,className:T,children:[a("span",{className:R,children:[i.number,"."]}),u(i.children,r)]},o));return}o>0&&!A(c[o-1])&&l.push(t("br",{},`br${o}`)),l.push(t(h,{children:u(i.children,r)},o))}),a(f,{value:e,children:[s,l]})}const k="relative block pl-6 before:absolute before:left-1.5 before:font-bold before:text-accent before:content-['·']",T="relative block pl-[2em]",R="absolute left-0 w-[1.6em] text-right tabular-nums";function A(e){return e.bullet||e.number!=null}const B="text-accent underline underline-offset-[0.18em]";function C(e,n){const[s,...r]=n;return s?.kind==="text"?[{kind:"text",text:`${e}${s.text}`},...r]:[{kind:"text",text:e},...n]}function I(e){return g(e)||void 0}function u(e,n){const s=[];let r=!1;return e.forEach((c,l)=>{if(c.kind==="text"){s.push(t("span",{children:d(c.text)},l)),r=!0;return}r||s.push(t("span",{},`e${l}`)),s.push(x(c,l,n)),r=!1}),r||s.push(t("span",{},"end")),s}function p(e,n){return e.length===1&&e[0].kind==="text"?d(e[0].text):e.map((s,r)=>s.kind==="text"?t(h,{children:d(s.text)},r):x(s,r,n))}function P(e,n=!1){return u(e,m(n))}function m(e){return e?"font-normal italic text-accent":"not-italic text-accent"}function U(e){return t(f,{value:e,children:t("span",{children:e})})}function x(e,n,s){if(e.kind==="link")return t("a",{href:e.href,className:B,children:p(e.children,s)},n);const r=p(e.children,s),c=S[e.kind];if(c)return t("span",{[_]:c,children:r},n);switch(e.kind){case"underline":return t("u",{children:r},n);case"sup":return t("sup",{children:r},n);case"sub":return t("sub",{children:r},n);case"color":{const l=I(e.color);return l?t("span",{style:{color:l},children:r},n):t("span",{children:r},n)}case"accent":case"highlight":return t("em",{className:s,children:r},n);case"bold":return t("strong",{className:"font-semibold",children:r},n);case"italic":return t("em",{className:"italic",children:r},n);case"strike":return t("s",{className:"line-through",children:r},n);default:return t("span",{children:r},n)}}function Y(e,n=!0){const s=e.split(`
2
+ `);return t(f,{value:e,children:s.map((r,c)=>a("span",{children:[E(r,n),c<s.length-1?t("br",{}):null]},c))})}function v(e){return e.split(/\n\s*\n/).map(n=>n.trim()).filter(Boolean)}export{U as renderChrome,E as renderGold,Y as renderHeadline,P as renderMarkupNodes,v as splitParagraphs};
@@ -8,6 +8,7 @@ export declare const TEXT_FIT_ATTR: {
8
8
  };
9
9
  export type BlockSizeTwin = {
10
10
  desktop?: unknown;
11
+ tablet?: unknown;
11
12
  phone?: unknown;
12
13
  };
13
14
  export type BlockSizeValues = Partial<Record<BlockSizeKey, BlockSizeTwin>>;
@@ -1 +1 @@
1
- import{BLOCK_FIXED_WIDTH as W,BLOCK_SIZE_KEYS as I,parseBlockWidthFit as m,phoneKey as T,parseTextFit as b}from"efficient-easel/draw";const L="sf-block-size",p={fit:"data-fit",fitPhone:"data-fit-phone",min:"data-fit-min",minPhone:"data-fit-min-phone"},s=e=>typeof e=="number"&&Number.isFinite(e)&&e>=0?e:void 0,g={desktop:{fill:"view-wide:w-full view-wide:[.flex-row>&]:grow",fixed:"view-wide:w-[min(var(--sf-bw),100%)] view-wide:basis-auto! view-wide:grow-0! view-wide:shrink-0"},phone:{fill:"max-view-wide:w-full",fixed:"max-view-wide:w-[min(var(--sf-bw-p),100%)] max-view-wide:basis-auto! max-view-wide:grow-0! max-view-wide:shrink-0"}},E={desktop:"--sf-bw",phone:"--sf-bw-p"},O={minWidth:{desktop:["--sf-bmin","view-wide:min-w-[var(--sf-bmin)]!"],phone:["--sf-bmin-p","max-view-wide:min-w-[var(--sf-bmin-p)]!"]},maxWidth:{desktop:["--sf-bmax","view-wide:max-w-[var(--sf-bmax)]"],phone:["--sf-bmax-p","max-view-wide:max-w-[var(--sf-bmax-p)]"]}},u={desktop:"view-wide:whitespace-nowrap view-wide:[&_*]:whitespace-nowrap!",phone:"max-view-wide:whitespace-nowrap max-view-wide:[&_*]:whitespace-nowrap!"};function C(e){const i=[],n={},t={},f=m(e.widthFit?.desktop),l=m(e.widthFit?.phone)??f,r=s(e.width?.desktop),v=s(e.width?.phone)??r;for(const[d,o,c]of[["desktop",f,r],["phone",l,v]])!o||o==="fit"||(i.push(g[d][o]),o==="fixed"&&(n[E[d]]=`${c??W.fallback}px`));for(const d of["minWidth","maxWidth"]){const o=s(e[d]?.desktop),c=s(e[d]?.phone)??o;for(const[S,k]of[["desktop",o],["phone",c]]){if(k===void 0)continue;const[_,F]=O[d][S];n[_]=`${k}px`,i.push(F)}}const w=b(e.textFit?.desktop),h=b(e.textFit?.phone),a=s(e.minFont?.desktop),x=s(e.minFont?.phone);return w==="line"&&i.push(u.desktop),(h??w)==="line"&&i.push(u.phone),w&&(t[p.fit]=w),h&&(t[p.fitPhone]=h),a!==void 0&&(t[p.min]=String(a)),x!==void 0&&(t[p.minPhone]=String(x)),i.length===0&&Object.keys(t).length===0?null:{className:[L,...i].join(" "),style:n,attrs:t}}function P(e){if(s(e.maxWidth?.desktop)!==void 0)return!0;const i=m(e.widthFit?.desktop);return i==="fill"||i==="fixed"}function A(e){const i={};for(const n of I){const t=e[n],f=e[T(n)];(t!==void 0||f!==void 0)&&(i[n]={desktop:t,phone:f})}return i}export{L as BLOCK_SIZE_CLASS,p as TEXT_FIT_ATTR,P as blockSetsItsWidth,C as blockSizeOf,A as blockSizeValuesOf};
1
+ import{BLOCK_FIXED_WIDTH as I,BLOCK_SIZE_KEYS as T,parseBlockWidthFit as l,phoneKey as F,parseTextFit as v,tabletKey as g}from"efficient-easel/draw";const L="sf-block-size",b={fit:"data-fit",fitPhone:"data-fit-phone",min:"data-fit-min",minPhone:"data-fit-min-phone"},d=e=>typeof e=="number"&&Number.isFinite(e)&&e>=0?e:void 0,E={desktop:{fill:"view-wide:w-full view-wide:[.flex-row>&]:grow",fixed:"view-wide:w-[min(var(--sf-bw),100%)] view-wide:basis-auto! view-wide:grow-0! view-wide:shrink-0"},phone:{fill:"max-view-wide:w-full",fixed:"max-view-wide:w-[min(var(--sf-bw-p),100%)] max-view-wide:basis-auto! max-view-wide:grow-0! max-view-wide:shrink-0"}},A={desktop:{fill:"view-desktop:w-full view-desktop:[.flex-row>&]:grow",fixed:"view-desktop:w-[min(var(--sf-bw),100%)] view-desktop:basis-auto! view-desktop:grow-0! view-desktop:shrink-0"},tablet:{fill:"view-tablet:max-view-desktop:w-full view-wide:max-view-desktop:[.flex-row>&]:grow",fixed:"view-tablet:max-view-desktop:w-[min(var(--sf-bw-t),100%)] view-tablet:max-view-desktop:basis-auto! view-tablet:max-view-desktop:grow-0! view-tablet:max-view-desktop:shrink-0"},phone:{fill:"max-view-tablet:w-full",fixed:"max-view-tablet:w-[min(var(--sf-bw-p),100%)] max-view-tablet:basis-auto! max-view-tablet:grow-0! max-view-tablet:shrink-0"}},C={desktop:"--sf-bw",tablet:"--sf-bw-t",phone:"--sf-bw-p"},K={minWidth:{desktop:["--sf-bmin","view-wide:min-w-[var(--sf-bmin)]!"],phone:["--sf-bmin-p","max-view-wide:min-w-[var(--sf-bmin-p)]!"]},maxWidth:{desktop:["--sf-bmax","view-wide:max-w-[var(--sf-bmax)]"],phone:["--sf-bmax-p","max-view-wide:max-w-[var(--sf-bmax-p)]"]}},O={minWidth:{desktop:["--sf-bmin","view-desktop:min-w-[var(--sf-bmin)]!"],tablet:["--sf-bmin-t","view-tablet:max-view-desktop:min-w-[var(--sf-bmin-t)]!"],phone:["--sf-bmin-p","max-view-tablet:min-w-[var(--sf-bmin-p)]!"]},maxWidth:{desktop:["--sf-bmax","view-desktop:max-w-[var(--sf-bmax)]"],tablet:["--sf-bmax-t","view-tablet:max-view-desktop:max-w-[var(--sf-bmax-t)]"],phone:["--sf-bmax-p","max-view-tablet:max-w-[var(--sf-bmax-p)]"]}},y=["widthFit","width","minWidth","maxWidth"],k={desktop:"view-wide:whitespace-nowrap view-wide:[&_*]:whitespace-nowrap!",phone:"max-view-wide:whitespace-nowrap max-view-wide:[&_*]:whitespace-nowrap!"};function P(e){const n=[],s={},o={},w=y.some(t=>{const i=e[t]?.tablet;return t==="widthFit"?l(i)!==void 0:d(i)!==void 0}),f=w?["desktop","tablet","phone"]:["desktop","phone"],r=(t,i)=>{const a=t(i?.desktop),m=w?t(i?.tablet)??a:a;return{desktop:a,tablet:m,phone:t(i?.phone)??m}},u=r(l,e.widthFit),_=r(d,e.width);for(const t of f){const i=u[t];!i||i==="fit"||(n.push(w?A[t][i]:E[t][i]),i==="fixed"&&(s[C[t]]=`${_[t]??I.fallback}px`))}for(const t of["minWidth","maxWidth"]){const i=r(d,e[t]);for(const a of f){const m=i[a];if(m===void 0)continue;const[S,W]=w?O[t][a]:K[t][a];s[S]=`${m}px`,n.push(W)}}const p=v(e.textFit?.desktop),x=v(e.textFit?.phone),h=d(e.minFont?.desktop),c=d(e.minFont?.phone);return p==="line"&&n.push(k.desktop),(x??p)==="line"&&n.push(k.phone),p&&(o[b.fit]=p),x&&(o[b.fitPhone]=x),h!==void 0&&(o[b.min]=String(h)),c!==void 0&&(o[b.minPhone]=String(c)),n.length===0&&Object.keys(o).length===0?null:{className:[L,...n].join(" "),style:s,attrs:o}}function B(e){if(d(e.maxWidth?.desktop)!==void 0)return!0;const n=l(e.widthFit?.desktop);return n==="fill"||n==="fixed"}function H(e){const n={};for(const s of T){const o=e[s],w=e[g(s)],f=e[F(s)];(o!==void 0||w!==void 0||f!==void 0)&&(n[s]={desktop:o,tablet:w,phone:f})}return n}export{L as BLOCK_SIZE_CLASS,b as TEXT_FIT_ATTR,B as blockSetsItsWidth,P as blockSizeOf,H as blockSizeValuesOf};
@@ -1 +1 @@
1
- import{REPEAT_ATTRIBUTE as l,phoneKey as f,tabletKey as b}from"efficient-easel/draw";import{parseLoop as C}from"../../../format/lib/animation/loop.js";import{finiteNumber as S}from"../../../format/lib/finite-number.js";import{isBackgroundBox as _}from"../../../format/lib/content/box-background.js";import{isStripBox as g}from"../../../format/lib/content/box-separator.js";import{BOX_ALIGN_CLASS as r,boxRowColumnsClass as x,boxRowTabletColumnsClass as E}from"../../../format/lib/content/box-layout.js";const i="sharedColumns",c="shared",$="own",u="scroll",U="Row columns",M=[{value:$,label:"Each row"},{value:c,label:"Shared"}],B=[{value:$,label:"Each row"},{value:u,label:"Shared, scroll"}],O="(width >= 800px)",N="(width < 800px)";function A(t){const o={direction:t.direction,separator:t.separator,loop:C(t.loop),line:t.line};return o.direction==="row"&&!g(o.direction,o.separator)&&o.loop!=="scroll"&&o.line!==!0&&!_(typeof t.bgImage=="string"?t.bgImage:void 0)&&x({...o,columns:t.columns})===""&&E({...o,columnsTablet:t[b("columns")]})===""}function R(t){return Array.isArray(t)?t.filter(o=>typeof o?.type=="string").length:S(t?.blockCount)??0}function K(t){return A(t)&&a(R(t.content))>0?y(t[i],t[f(i)]):{desktop:!1,phone:!1}}const a=t=>Number.isInteger(t)&&t>0?t:0,d=t=>`sf-shared-cols-${t}`,m=t=>`sf-shared-cols-phone-${t}`;function y(t,o){return{desktop:t===c,phone:o===u}}function F(t,o){const n=a(o);return n?`${t.desktop?` ${d(n)}`:""}${t.phone?` ${m(n)}`:""}`:""}function p(t){const o=`[${l}]`;return`:has(> ${o} ${t}):not(:has(> ${o} ${o} ${t}))`}function h(t,o,n=""){const e=p(t);return`${e}{display:grid;grid-template-columns:${o};column-gap:0${n}}${e}>:not(:has(${t})):not(${t}){grid-column:1/-1}${e} :has(${t}),${e} ${t}{display:grid;grid-template-columns:subgrid;grid-column:1/-1;min-width:0}`}const L="data-sf-shared-plain";function H(t){const o=`[${l}]`,n=`[${L}]`,e=p(t)+`:not(:has(> :not(${o}) > :not(${n}) ${t})):not(:has(> ${o} > * > :not(${n}) ${t})):not(:has(:not(${n}) > :not(${n}) > ${t}))`,s=`${e}>:not(style):not(:has(${t})):not(${t})`;return`${e}{display:table;width:100%;border-collapse:collapse}${e}>:has(${t}),${e}>${o}>:has(${t}),${e} ${n}:has(${t}),${e} ${n}>:has(${t}){display:contents}${e} ${t}{display:table-row}${e} ${t}>*{display:table-cell;width:auto;vertical-align:top}${e} ${t}.${r.center}>*{vertical-align:middle}${e} ${t}.${r.end}>*{vertical-align:bottom}${s}{display:table-caption;caption-side:bottom}${s}:has(~ ${o}){caption-side:top}`}function w(t,o){const n=a(o);if(!n)return"";let e="";if(t.desktop){const s=`.${d(n)}`;e+=`@media ${O}{${h(s,`repeat(${n},auto)`)}${H(s)}}`}return t.phone&&(e+=`@media ${N}{${h(`.${m(n)}`,`repeat(${n},minmax(max-content,auto))`,";overflow-x:auto")}}`),e}export{i as SHARED_COLUMNS_KEY,U as SHARED_COLUMNS_LABEL,$ as SHARED_COLUMNS_OFF,B as SHARED_COLUMNS_PHONE_POINTS,M as SHARED_COLUMNS_POINTS,L as SHARED_PLAIN_ATTR,F as sharedColumnsClasses,w as sharedColumnsCss,K as sharedColumnsDrawn,A as sharedColumnsFits};
1
+ import{REPEAT_ATTRIBUTE as l,phoneKey as f,tabletKey as b}from"efficient-easel/draw";import{parseLoop as C}from"../../../format/lib/animation/loop.js";import{finiteNumber as S}from"../../../format/lib/finite-number.js";import{isBackgroundBox as _}from"../../../format/lib/content/box-background.js";import{isStripBox as g}from"../../../format/lib/content/box-separator.js";import{CARD_STATE_ATTR as A}from"../../../format/lib/content/card-state.js";import{BOX_ALIGN_CLASS as r,boxRowColumnsClass as E,boxRowTabletColumnsClass as x}from"../../../format/lib/content/box-layout.js";const i="sharedColumns",$="shared",c="own",u="scroll",B="Row columns",K=[{value:c,label:"Each row"},{value:$,label:"Shared"}],F=[{value:c,label:"Each row"},{value:u,label:"Shared, scroll"}],O="(width >= 800px)",R="(width < 800px)";function N(t){const o={direction:t.direction,separator:t.separator,loop:C(t.loop),line:t.line};return o.direction==="row"&&!g(o.direction,o.separator)&&o.loop!=="scroll"&&o.line!==!0&&!_(typeof t.bgImage=="string"?t.bgImage:void 0)&&E({...o,columns:t.columns})===""&&x({...o,columnsTablet:t[b("columns")]})===""}function y(t){return Array.isArray(t)?t.filter(o=>typeof o?.type=="string").length:S(t?.blockCount)??0}function w(t){return N(t)&&a(y(t.content))>0?T(t[i],t[f(i)]):{desktop:!1,phone:!1}}const a=t=>Number.isInteger(t)&&t>0?t:0,d=t=>`sf-shared-cols-${t}`,m=t=>`sf-shared-cols-phone-${t}`;function T(t,o){return{desktop:t===$,phone:o===u}}function G(t,o){const n=a(o);return n?`${t.desktop?` ${d(n)}`:""}${t.phone?` ${m(n)}`:""}`:""}function p(t){const o=`[${l}]`;return`:has(> ${o} ${t}):not(:has(> ${o} ${o} ${t}))`}function h(t,o,n=""){const e=p(t);return`${e}{display:grid;grid-template-columns:${o};column-gap:0${n}}${e}>:not(:has(${t})):not(${t}){grid-column:1/-1}${e} :has(${t}),${e} ${t}{display:grid;grid-template-columns:subgrid;grid-column:1/-1;min-width:0}`}const L="data-sf-shared-plain";function D(t){const o=`[${l}]`,n=`[${L}]`,e=p(t)+`:not(:has(> :not(${o}) > :not(${n}) ${t})):not(:has(> ${o} > * > :not(${n}) ${t})):not(:has(:not(${n}) > :not(${n}) > ${t})):not(:has(> ${o}[${A}]))`,s=`${e}>:not(style):not(:has(${t})):not(${t})`;return`${e}{display:table;width:100%;border-collapse:collapse}${e}>:has(${t}),${e}>${o}>:has(${t}),${e} ${n}:has(${t}),${e} ${n}>:has(${t}){display:contents}${e} ${t}{display:table-row}${e} ${t}>*{display:table-cell;width:auto;vertical-align:top}${e} ${t}.${r.center}>*{vertical-align:middle}${e} ${t}.${r.end}>*{vertical-align:bottom}${s}{display:table-caption;caption-side:bottom}${s}:has(~ ${o}){caption-side:top}`}function X(t,o){const n=a(o);if(!n)return"";let e="";if(t.desktop){const s=`.${d(n)}`;e+=`@media ${O}{${h(s,`repeat(${n},auto)`)}${D(s)}}`}return t.phone&&(e+=`@media ${R}{${h(`.${m(n)}`,`repeat(${n},minmax(max-content,auto))`,";overflow-x:auto")}}`),e}export{i as SHARED_COLUMNS_KEY,B as SHARED_COLUMNS_LABEL,c as SHARED_COLUMNS_OFF,F as SHARED_COLUMNS_PHONE_POINTS,K as SHARED_COLUMNS_POINTS,L as SHARED_PLAIN_ATTR,G as sharedColumnsClasses,X as sharedColumnsCss,w as sharedColumnsDrawn,N as sharedColumnsFits};
@@ -1 +1 @@
1
- import{jsx as s,jsxs as j,Fragment as u}from"react/jsx-runtime";import v,{cardGridCornerClasses as H}from"../../../../../components/Cards.js";import{CardTemplateRows as I}from"../../../../../components/CardRowContext.js";import{cardKeyOf as K,cardRow as T}from"../../../../../../format/lib/content/card-template.js";import B from"../../../../../components/KeyFeatures.js";import{hidableText as D}from"efficient-easel/draw";import{declaredBlockSource as w,sourceChoices as L,sourcedRows as C}from"../../../../../../format/lib/content/block-sources.js";import{KEY_FEATURES_PH as k,keyFeaturesScaffoldItems as N}from"../../../../../../format/lib/document/blocks/general/KeyFeatures/meta.js";import{parseSectionHeadPlacement as P}from"../../../../../../format/lib/sections/section-head-placement.js";import{parseSectionEyebrowLook as S}from"../../../../../../format/lib/sections/section-eyebrow-look.js";import{phRows as E,phHide as y}from"../../scaffold.js";import{say as m}from"../../../../../../format/lib/editor-words.js";import{SERVED_CARD_FIELDS as h}from"../../../../../../format/lib/document/blocks/general/Cards/card-seed.js";import{CardsMeta as O,CARDS_PH as R}from"../../../../../../format/lib/document/blocks/general/Cards/meta.js";const x=()=>[{title:m("Card title one"),body:m("A short line about this card.")},{title:m("Card title two"),body:m("A short line about this card.")},{title:m("Card title three"),body:m("A short line about this card.")}],A=()=>x().map(e=>({[h.title]:e.title??"",[h.body]:e.body??""}));function W(e){return w(e)?C(e,e.editor?.isEditing===!0,A()).rows.filter(i=>i[h.title]||i[h.body]).map(i=>({title:i[h.title]??"",body:i[h.body]??""})):null}const G=e=>typeof e.highlightedCard=="string"?e.highlightedCard.trim():"",_=e=>Object.entries(e).some(([i,r])=>i!=="key"&&i!=="badge"&&typeof r=="string"&&r.trim()!==""),F=new WeakSet;function M(e){const i=e.editor?.isEditing===!0,r=w(e),d=G(e),n=typeof e.highlightBadge=="string"?e.highlightBadge:"",c=(t,g=[])=>t.map((l,f)=>({...l,key:l.key||g[f]?.key||K(l,f)})),a=t=>{const g=d?t.findIndex(l=>l.key===d):-1;return t.map((l,f)=>{const b={...l,badge:f===g?n:""};return f===g&&F.add(b),b})};if(r){const t=C(e,i,A());return a(c(t.rows,t.sample?L(r):[]).filter(_))}const o=E(e.items,x(),e.editor).map(T);return a(c(o).filter(t=>i||_(t)))}function U(e,i,r){const d=r?`relative bg-bg ${r}`:"relative bg-bg";return F.has(i)?j("div",{className:d,"data-sf-card-highlighted":"",children:[e,s("span",{"aria-hidden":"true",className:"pointer-events-none absolute inset-0 border border-accent"})]}):s("div",{className:d,children:e})}const oe={...O,render:e=>{const i=P(e.headPlacement)==="own-box",r=o=>i?void 0:o,d=(e.template?.blockCount??0)>0,n=W(e);if((!d||e.cardStyle==="label-only")&&n&&!n.length)return s(u,{});if(e.cardStyle==="label-only"){const o=n?n.map(t=>({label:t.title??"",href:void 0})):Array.isArray(e.items)?e.items.map(t=>({label:D(t.title)??"",href:typeof t.href=="string"?t.href:void 0})):[];return s(B,{look:S(e.eyebrowLook,"KeyFeatures"),eyebrow:r(y(e.eyebrow,k.eyebrow,e.editor)),title:r(y(e.title,k.title,e.editor)),items:n?o:E(o,N(),e.editor),columns:e.columns,editing:e.editor?.isEditing})}const c=o=>s(v,{look:S(e.eyebrowLook,"Cards"),eyebrow:r(y(e.eyebrow,R.eyebrow,e.editor)),title:r(y(e.title,R.title,e.editor)),omitHead:i,editing:e.editor?.isEditing,cards:o}),a=d?M(e):[];return d&&n&&!a.length?s(u,{}):s(I,{ownerId:String(e.id??""),ownerType:"Cards",Template:e.template,rows:a,fallback:c(),wrapCopy:(o,t)=>U(o,t.row,H(t.index,a.length,e.columns)),children:o=>a.length?c(o):c()})}};export{oe as CardsRender};
1
+ import{jsx as m,Fragment as b}from"react/jsx-runtime";import{SECTION_GRID_COLUMN_CLASS as I}from"../../../../../../format/lib/content/section-min-height.js";import T,{cardGridCornerClasses as x}from"../../../../../components/Cards.js";import{CardTemplateRows as H}from"../../../../../components/CardRowContext.js";import{cardKeyOf as F,cardRow as L}from"../../../../../../format/lib/content/card-template.js";import D from"../../../../../components/KeyFeatures.js";import{hidableText as K}from"efficient-easel/draw";import{declaredBlockSource as u,sourceChoices as O,sourcedRows as C}from"../../../../../../format/lib/content/block-sources.js";import{KEY_FEATURES_PH as w,keyFeaturesScaffoldItems as B}from"../../../../../../format/lib/document/blocks/general/KeyFeatures/meta.js";import{parseSectionHeadPlacement as G}from"../../../../../../format/lib/sections/section-head-placement.js";import{parseSectionEyebrowLook as S}from"../../../../../../format/lib/sections/section-eyebrow-look.js";import{phRows as k,phHide as g}from"../../scaffold.js";import{say as h}from"../../../../../../format/lib/editor-words.js";import{SERVED_CARD_FIELDS as f}from"../../../../../../format/lib/document/blocks/general/Cards/card-seed.js";import{CardsMeta as N,CARDS_PH as E}from"../../../../../../format/lib/document/blocks/general/Cards/meta.js";const _=()=>[{title:h("Card title one"),body:h("A short line about this card.")},{title:h("Card title two"),body:h("A short line about this card.")},{title:h("Card title three"),body:h("A short line about this card.")}],R=()=>_().map(e=>({[f.title]:e.title??"",[f.body]:e.body??""}));function P(e){return u(e)?C(e,e.editor?.isEditing===!0,R()).rows.filter(i=>i[f.title]||i[f.body]).map(i=>({title:i[f.title]??"",body:i[f.body]??""})):null}const j=e=>typeof e.highlightedCard=="string"?e.highlightedCard.trim():"",A=e=>Object.entries(e).some(([i,o])=>i!=="key"&&i!=="badge"&&typeof o=="string"&&o.trim()!=="");function v(e){const i=e.editor?.isEditing===!0,o=u(e),d=j(e),n=typeof e.highlightBadge=="string"?e.highlightBadge:"",s=(t,r=[])=>t.map((a,c)=>({...a,key:a.key||r[c]?.key||F(a,c)})),l=t=>{const r=d?t.findIndex(a=>a.key===d):-1;return{rows:t.map((a,c)=>({...a,badge:c===r?n:""})),states:t.map((a,c)=>c===r?$:M)}};if(o){const t=C(e,i,R());return l(s(t.rows,t.sample?O(o):[]).filter(A))}const y=k(e.items,_(),e.editor).map(L);return l(s(y).filter(t=>i||A(t)))}const $={highlighted:!0},M={};function U(e,i,o){const d=o?`relative grid ${I} bg-bg`:"relative bg-bg";return m("div",{className:i?`${d} ${i}`:d,children:e})}const de={...N,render:e=>{const i=G(e.headPlacement)==="own-box",o=t=>i?void 0:t,d=(e.template?.blockCount??0)>0,n=P(e);if((!d||e.cardStyle==="label-only")&&n&&!n.length)return m(b,{});if(e.cardStyle==="label-only"){const t=n?n.map(r=>({label:r.title??"",href:void 0})):Array.isArray(e.items)?e.items.map(r=>({label:K(r.title)??"",href:typeof r.href=="string"?r.href:void 0})):[];return m(D,{look:S(e.eyebrowLook,"KeyFeatures"),eyebrow:o(g(e.eyebrow,w.eyebrow,e.editor)),title:o(g(e.title,w.title,e.editor)),items:n?t:k(t,B(),e.editor),columns:e.columns,editing:e.editor?.isEditing})}const s=t=>m(T,{look:S(e.eyebrowLook,"Cards"),eyebrow:o(g(e.eyebrow,E.eyebrow,e.editor)),title:o(g(e.title,E.title,e.editor)),omitHead:i,editing:e.editor?.isEditing,cards:t}),{rows:l,states:y}=d?v(e):{rows:[],states:[]};return d&&n&&!l.length?m(b,{}):m(H,{ownerId:String(e.id??""),ownerType:"Cards",Template:e.template,rows:l,states:y,fallback:s(),wrapCopy:(t,r)=>U(t,x(r.index,l.length,e.columns),r.state?.highlighted===!0),children:t=>l.length?s(t):s()})}};export{de as CardsRender};
@@ -1 +1 @@
1
- import{jsx as i}from"react/jsx-runtime";import{phoneKey as a,tabletKey as o}from"efficient-easel/draw";import{sharedColumnsDrawn as r}from"../../../../content/box-shared-columns.js";import{CountRowsContext as c,NO_COUNTS as d}from"../../../../../components/CountRowsContext.js";import m from"../../../../../components/Flex.js";import{loopDelayOf as h,loopSecondsOf as g,parseLoop as b,parseLoopDirection as u}from"../../../../../../format/lib/animation/index.js";import{COUNTS_SOURCE as f,declaredBlockSource as S,servedRows as x}from"../../../../../../format/lib/content/block-sources.js";import{padValuesOf as w}from"../../../../content/section-padding.js";import{sectionFillsHeight as y}from"../../../../../../format/lib/content/section-min-height.js";import{pictureHoverOf as C}from"../../../../../../format/lib/animation/hover.js";import{FlexMeta as D}from"../../../../../../format/lib/document/blocks/general/Flex/meta.js";const N={...D,render:e=>{const l=i(m,{direction:e.direction,label:e.label,tabShape:e.tabShape,gap:e.gap,gapPhone:e[a("gap")],gapTablet:e[o("gap")],justify:e.justify,align:e.align,wrap:e.wrap,share:e.share,sharePhone:e[a("share")],shareTablet:e[o("share")],wrapPhone:e[a("wrap")],phoneRow:e.phoneRow,columns:e.columns,columnsTablet:e[o("columns")],separator:e.separator,blockSpacing:e.blockSpacing,bgImage:e.bgImage,bgImagePhone:e.bgImagePhone,pictureHover:C(e),darken:e.darken,darkenStyle:e.darkenStyle,placement:e.placement,padV2:e.padV2===!0,border:e.sectionBorder,borderPhone:e.sectionBorderPhone,pad:w(e),contained:e.contained,fillHeight:y(e),shadow:e.shadow,loop:b(e.loop),scrollDirection:u(e.scrollDirection),loopSeconds:g({loopDuration:e.loopDuration}),loopDelay:h({loopDelay:e.loopDelay}),editing:!!e.editor?.isEditing,fillColor:e.fillColor,line:e.line,upcoming:e.upcoming,link:e.link,boxShape:e.boxShape,boxShapePhone:e[a("boxShape")],boxShapeTablet:e[o("boxShape")],jumpHighlight:e.jumpHighlight,anchor:e.anchor,sharedSides:r(e),boxId:typeof e.id=="string"?e.id:void 0,mirrorCards:e.mirrorCards,content:e.content}),n=S(e),t=n?n===f?x(e):d:null;return i(c.Provider,{value:t,children:l})}};export{N as FlexRender};
1
+ import{jsx as l}from"react/jsx-runtime";import{phoneKey as a,tabletKey as o}from"efficient-easel/draw";import{sharedColumnsDrawn as r}from"../../../../content/box-shared-columns.js";import{CountRowsContext as c,NO_COUNTS as d}from"../../../../../components/CountRowsContext.js";import m from"../../../../../components/Flex.js";import{loopDelayOf as h,loopSecondsOf as g,parseLoop as b,parseLoopDirection as u}from"../../../../../../format/lib/animation/index.js";import{COUNTS_SOURCE as f,declaredBlockSource as S,servedRows as x}from"../../../../../../format/lib/content/block-sources.js";import{padValuesOf as w}from"../../../../content/section-padding.js";import{sectionFillsHeight as y}from"../../../../../../format/lib/content/section-min-height.js";import{pictureHoverOf as C}from"../../../../../../format/lib/animation/hover.js";import{FlexMeta as D}from"../../../../../../format/lib/document/blocks/general/Flex/meta.js";const N={...D,render:e=>{const t=l(m,{direction:e.direction,label:e.label,tabShape:e.tabShape,gap:e.gap,gapPhone:e[a("gap")],gapTablet:e[o("gap")],justify:e.justify,align:e.align,wrap:e.wrap,share:e.share,sharePhone:e[a("share")],shareTablet:e[o("share")],wrapPhone:e[a("wrap")],phoneRow:e.phoneRow,columns:e.columns,columnsTablet:e[o("columns")],separator:e.separator,blockSpacing:e.blockSpacing,bgImage:e.bgImage,bgImagePhone:e.bgImagePhone,pictureHover:C(e),darken:e.darken,darkenStyle:e.darkenStyle,placement:e.placement,padV2:e.padV2===!0,border:e.sectionBorder,borderTablet:e.sectionBorderTablet,borderPhone:e.sectionBorderPhone,pad:w(e),contained:e.contained,fillHeight:y(e),shadow:e.shadow,loop:b(e.loop),scrollDirection:u(e.scrollDirection),loopSeconds:g({loopDuration:e.loopDuration}),loopDelay:h({loopDelay:e.loopDelay}),editing:!!e.editor?.isEditing,fillColor:e.fillColor,line:e.line,upcoming:e.upcoming,link:e.link,boxShape:e.boxShape,boxShapePhone:e[a("boxShape")],boxShapeTablet:e[o("boxShape")],jumpHighlight:e.jumpHighlight,anchor:e.anchor,sharedSides:r(e),boxId:typeof e.id=="string"?e.id:void 0,mirrorCards:e.mirrorCards,content:e.content}),n=S(e),i=n?n===f?x(e):d:null;return l(c.Provider,{value:i,children:t})}};export{N as FlexRender};
@@ -31,6 +31,8 @@ export declare const leadLine: (lead: string, rest: string, run: Props, own?: Pr
31
31
  export declare const bandPage: (stored: unknown, ctx: ConvertContext) => number;
32
32
  export declare const sectionPage: (p: Props, ctx: ConvertContext) => import("../../../../../format/lib/theme.js").ThemeColors | undefined;
33
33
  export declare const fillFrom: (colour: "surface" | "background") => (p: Props, ctx: ConvertContext) => Props;
34
+ export declare const ownFill: (painted: string | undefined, p: Props, ctx: ConvertContext) => Props;
35
+ export declare const fillNoBoxHolds: (painted: string | undefined) => string | undefined;
34
36
  export declare const lineBorder: (p: Props, ctx: ConvertContext) => Props;
35
37
  export declare const bandIndex: (p: Props, ctx: ConvertContext) => number;
36
38
  export declare const bandAccent: (stored: unknown, p: Props, ctx: ConvertContext) => unknown;
@@ -1 +1 @@
1
- import{phoneKey as u}from"efficient-easel/draw";import{BOX as T,INNER_BOX as f,TEXT as h}from"../../../../../format/lib/document/seed-parts.js";import{ENTRANCE_KEYS as x}from"../../../animation/entrance.js";import{CARD_HOVER_KEYS as a}from"../../../../../format/lib/animation/hover.js";import{COUNT_KEY_PROP as B}from"../../../../../format/lib/content/block-sources.js";import{normalizeSiteGutter as _}from"../../../../../format/lib/content/page-width.js";import{resolveSectionPadding as E}from"../../../content/section-padding.js";import{ButtonBlockMeta as O}from"../../../../../format/lib/document/blocks/general/ButtonBlock/meta.js";import{SECTION_PAD_INNER_DEFAULTS as S}from"../../passes/section-padding.js";import{finiteNumber as s}from"../../../../../format/lib/finite-number.js";import{convertTheme as p,hasWords as N}from"../../../sections/section-to-box.js";import{bandPresetIndex as R}from"../../../../../format/lib/theme.js";import{BOX as bt,DIM as ut,INNER_BOX as Tt,TEXT as ft}from"../../../../../format/lib/document/seed-parts.js";const A={...h,[B]:""},{label:V,href:J,...y}=O.defaultProps,z=y,q={buttonFillOpacity:0,buttonBorder:{width:0},buttonPaddingTop:0,buttonPaddingRight:0,buttonPaddingBottom:0,buttonPaddingLeft:0},Q={...T,sectionAccent:0},Z=["gridSpan","sectionHeightMode","sectionHeightValue","sectionHeightUnit","sectionHeightModePhone","sectionHeightValuePhone","sectionHeightUnitPhone","sectionCorners","sectionCornerSides","sectionBorder","sectionBorderPhone","sectionAccent","stickTop","stickTopDistance","stickTopPhone","stickTopDistancePhone","anchor","sectionAnimation","_hidden",...Object.values(x).flatMap(t=>[t,u(t)]),"widthFit","widthFitPhone","width","widthPhone","minWidth","minWidthPhone","maxWidth","maxWidthPhone"],r="a section width key, ignored since efficient-web-builder 45 (every section, and a section's root Box, follows Site styles only; Lewis 2026-10-29), so dropping it changes nothing",tt={sectionSurface:"read by nothing in src/ (searched 2026-10-24): a retired theme key that draws nothing today, so dropping it changes nothing",widthMode:r,fullWidth:r,pageWidth:r,backgroundWidth:r,contentWidth:r,contentMax:r},ot=Object.fromEntries(["sectionPaddingLeft","sectionPaddingRight","sectionPaddingLeftTablet","sectionPaddingRightTablet","sectionPaddingLeftPhone","sectionPaddingRightPhone"].map(t=>[t,"needs Box side padding outside its gutter: the old section added it outside its frame, a Box's side padding replaces the gutter. 0 live nodes store it (JJ's read-only export, 2026-10-24)"]));function I(t,o){const e=s(t.sectionPaddingTop)??0,n=s(t.sectionPaddingBottom)??0,i=s(t.sectionPaddingTopTablet),d=s(t.sectionPaddingBottomTablet);return{sectionPaddingTop:e+o.top,sectionPaddingBottom:n+o.bottom,...i===void 0?{}:{sectionPaddingTopTablet:i+o.top},...d===void 0?{}:{sectionPaddingBottomTablet:d+o.bottom},sectionPaddingTopPhone:(s(t.sectionPaddingTopPhone)??i??e)+o.topPhone,sectionPaddingBottomPhone:(s(t.sectionPaddingBottomPhone)??d??n)+o.bottomPhone}}const et=t=>["sectionPaddingTop","sectionPaddingBottom","sectionPaddingTopTablet","sectionPaddingBottomTablet","sectionPaddingTopPhone","sectionPaddingBottomPhone"].map(o=>[o,o,(e,n)=>I(n,typeof t=="function"?t(n):t)[o]]);function c(t,o){const e=E(t,S[o]);return{sectionPaddingTop:e.top,sectionPaddingBottom:e.bottom}}const nt=t=>[["padTop","sectionPaddingTop",(o,e)=>c(e,t).sectionPaddingTop],["padBottom","sectionPaddingBottom",(o,e)=>c(e,t).sectionPaddingBottom],["sectionPaddingTop","sectionPaddingTop",(o,e)=>c(e,t).sectionPaddingTop],["sectionPaddingBottom","sectionPaddingBottom",(o,e)=>c(e,t).sectionPaddingBottom]],D={kind:"heading-case-upper",styles:["heading-1","heading-2","heading-3"]},it=t=>o=>N(o.props[t])?[D]:[],dt=(t,o)=>({kind:"text",key:t,role:"eyebrow",props:h,...o?{style:o}:{}}),m=t=>t.background!=="transparent",k=(t,o)=>{const[e,n]=[t,o].map(i=>typeof i=="string"?i.trim():"");return e?n?`[${e} ]{color=text}${n}`:`[${e}]{color=text}`:n},l={align:"right",alignPhone:"left"},C=(t,o,e)=>{const n=i=>k(i[t],i[o]);return{kind:"block",type:"Text",when:(i,d)=>d!==void 0&&n(d)!=="",box:[[t,"text",(i,d)=>n(d)],[o,"text",(i,d)=>n(d)]],props:e}},st=(t,o,e,n={})=>C(t,o,{...A,...l,...n,_partStyles:{text:{textStyle:"body-5",color:"labels",...e,case:"upper",...l}}}),g=(t,o)=>typeof t=="number"&&Number.isInteger(t)&&t>=0?t:p(o)?.selected??0,b=(t,o)=>p(o)?.themes[g(t.sectionAccent??0,o)],v=t=>(o,e)=>{const n=b(o,e)?.[t];return n?{fillColor:n}:{}},rt=(t,o)=>{const e=b(t,o)?.line;return e?{buttonBorder:{width:1,color:e}}:{}},P=(t,o)=>{const e=p(o)?.themes;return e&&m(t)?R(e,g(t.sectionAccent,o)):-1},ct=(t,o,e)=>{const n=P(o,e);return n>=0?n:t},at=(t,o)=>{const e=P(t,o);return e>=0?{sectionAccent:e}:{}},pt=(t,o)=>m(t.props)&&P(t.props,o)<0?[{kind:"band-preset",page:g(t.props.sectionAccent,o)}]:[],gt=t=>_(t.site?.siteGutter),W=Object.fromEntries(["Top","Right","Bottom","Left","TopPhone","RightPhone","BottomPhone","LeftPhone"].map(t=>[`sectionPadding${t}`,0])),Pt=t=>({top:0,right:0,bottom:0,left:0,...t}),ht=(t,o,e,n=[])=>({kind:"group",name:t,keepEmpty:!0,props:(i,d)=>({...f,...W,...v("surface")(i,d),...typeof e=="function"?e(i,d):e}),box:[[o,"bgImage"],a.kind,a.duration,a.delay],parts:n});export{bt as BOX,z as BUTTON,ut as DIM,tt as DROP_COMMON,ot as DROP_SIDE_PADDING,D as HEADING_CASE_UPPER,Tt as INNER_BOX,W as NO_PAD,A as NUMBER_TEXT,l as RIGHT_WORDS,Z as SAME_KEYS,Q as SECTION_BOX,q as SH_LINK,ft as TEXT,ct as bandAccent,P as bandIndex,g as bandPage,at as bandProps,pt as bandWrites,v as fillFrom,it as headingCaseOf,c as innerPad,nt as innerPadKeys,st as leadLine,C as leadText,rt as lineBorder,Pt as lineSides,k as numberAndUnit,ht as pictureCell,b as sectionPage,gt as siteGutterOf,dt as smallText,I as wrapperPad,et as wrapperPadKeys};
1
+ import{phoneKey as B}from"efficient-easel/draw";import{BOX as _,INNER_BOX as E,TEXT as P}from"../../../../../format/lib/document/seed-parts.js";import{ENTRANCE_KEYS as S}from"../../../animation/entrance.js";import{CARD_HOVER_KEYS as a}from"../../../../../format/lib/animation/hover.js";import{COUNT_KEY_PROP as O}from"../../../../../format/lib/content/block-sources.js";import{normalizeSiteGutter as N}from"../../../../../format/lib/content/page-width.js";import{resolveSectionPadding as R}from"../../../content/section-padding.js";import{ButtonBlockMeta as A}from"../../../../../format/lib/document/blocks/general/ButtonBlock/meta.js";import{SECTION_PAD_INNER_DEFAULTS as C}from"../../passes/section-padding.js";import{finiteNumber as r}from"../../../../../format/lib/finite-number.js";import{convertTheme as p,hasWords as I}from"../../../sections/section-to-box.js";import{THEME_SECTION_BG as H}from"../../../../../format/lib/content/section-background.js";import{parseHexColor as y}from"efficient-shell/format";import{bandPresetIndex as D,surfaceTwoTone as k}from"../../../../../format/lib/theme.js";import{BOX as Nt,DIM as Rt,INNER_BOX as At,TEXT as Ct}from"../../../../../format/lib/document/seed-parts.js";const w={...P,[O]:""},{label:et,href:nt,...W}=A.defaultProps,it=W,st={buttonFillOpacity:0,buttonBorder:{width:0},buttonPaddingTop:0,buttonPaddingRight:0,buttonPaddingBottom:0,buttonPaddingLeft:0},rt={..._,sectionAccent:0},dt=["gridSpan","sectionHeightMode","sectionHeightValue","sectionHeightUnit","sectionHeightModeTablet","sectionHeightValueTablet","sectionHeightUnitTablet","sectionHeightModePhone","sectionHeightValuePhone","sectionHeightUnitPhone","sectionCorners","sectionCornerSides","sectionBorder","sectionBorderTablet","sectionBorderPhone","sectionAccent","stickTop","stickTopDistance","stickTopTablet","stickTopDistanceTablet","stickTopPhone","stickTopDistancePhone","anchor","sectionAnimation","_hidden",...Object.values(S).flatMap(t=>[t,B(t)]),"widthFit","widthFitTablet","widthFitPhone","width","widthTablet","widthPhone","minWidth","minWidthTablet","minWidthPhone","maxWidth","maxWidthTablet","maxWidthPhone"],d="a section width key, ignored since efficient-web-builder 45 (every section, and a section's root Box, follows Site styles only; Lewis 2026-10-29), so dropping it changes nothing",ct={sectionSurface:"read by nothing in src/ (searched 2026-10-24): a retired theme key that draws nothing today, so dropping it changes nothing",widthMode:d,fullWidth:d,pageWidth:d,backgroundWidth:d,contentWidth:d,contentMax:d},at=Object.fromEntries(["sectionPaddingLeft","sectionPaddingRight","sectionPaddingLeftTablet","sectionPaddingRightTablet","sectionPaddingLeftPhone","sectionPaddingRightPhone"].map(t=>[t,"needs Box side padding outside its gutter: the old section added it outside its frame, a Box's side padding replaces the gutter. 0 live nodes store it (JJ's read-only export, 2026-10-24)"]));function v(t,o){const e=r(t.sectionPaddingTop)??0,n=r(t.sectionPaddingBottom)??0,i=r(t.sectionPaddingTopTablet),s=r(t.sectionPaddingBottomTablet);return{sectionPaddingTop:e+o.top,sectionPaddingBottom:n+o.bottom,...i===void 0?{}:{sectionPaddingTopTablet:i+o.top},...s===void 0?{}:{sectionPaddingBottomTablet:s+o.bottom},sectionPaddingTopPhone:(r(t.sectionPaddingTopPhone)??i??e)+o.topPhone,sectionPaddingBottomPhone:(r(t.sectionPaddingBottomPhone)??s??n)+o.bottomPhone}}const pt=t=>["sectionPaddingTop","sectionPaddingBottom","sectionPaddingTopTablet","sectionPaddingBottomTablet","sectionPaddingTopPhone","sectionPaddingBottomPhone"].map(o=>[o,o,(e,n)=>v(n,typeof t=="function"?t(n):t)[o]]);function c(t,o){const e=R(t,C[o]);return{sectionPaddingTop:e.top,sectionPaddingBottom:e.bottom}}const lt=t=>[["padTop","sectionPaddingTop",(o,e)=>c(e,t).sectionPaddingTop],["padBottom","sectionPaddingBottom",(o,e)=>c(e,t).sectionPaddingBottom],["sectionPaddingTop","sectionPaddingTop",(o,e)=>c(e,t).sectionPaddingTop],["sectionPaddingBottom","sectionPaddingBottom",(o,e)=>c(e,t).sectionPaddingBottom]],M={kind:"heading-case-upper",styles:["heading-1","heading-2","heading-3"]},gt=t=>o=>I(o.props[t])?[M]:[],ht=(t,o)=>({kind:"text",key:t,role:"eyebrow",props:P,...o?{style:o}:{}}),m=t=>t.background!=="transparent",L=(t,o)=>{const[e,n]=[t,o].map(i=>typeof i=="string"?i.trim():"");return e?n?`[${e} ]{color=text}${n}`:`[${e}]{color=text}`:n},T={align:"right",alignPhone:"left"},U=(t,o,e)=>{const n=i=>L(i[t],i[o]);return{kind:"block",type:"Text",when:(i,s)=>s!==void 0&&n(s)!=="",box:[[t,"text",(i,s)=>n(s)],[o,"text",(i,s)=>n(s)]],props:e}},Pt=(t,o,e,n={})=>U(t,o,{...w,...T,...n,_partStyles:{text:{textStyle:"body-5",color:"labels",...e,case:"upper",...T}}}),l=(t,o)=>typeof t=="number"&&Number.isInteger(t)&&t>=0?t:p(o)?.selected??0,u="var(--site-surface)",b="var(--site-surface-2)",g=(t,o)=>p(o)?.themes[l(t.sectionAccent??0,o)],f=t=>(o,e)=>{const n=g(o,e)?.[t];return n?{fillColor:n}:{}},x=t=>t.startsWith("#")&&y(t)!==null,mt=(t,o,e)=>{const n=t?.trim();if(n&&x(n))return{fillColor:n};if(n===u)return f("surface")(o,e);const i=n===b?g(o,e):void 0;return i?{fillColor:k(i)}:{}},Tt=t=>{const o=t?.trim();return!o||o==="transparent"||o===H||o===u||o===b||x(o)?void 0:"it paints a colour that no Box Fill can hold"},ut=(t,o)=>{const e=g(t,o)?.line;return e?{buttonBorder:{width:1,color:e}}:{}},h=(t,o)=>{const e=p(o)?.themes;return e&&m(t)?D(e,l(t.sectionAccent,o)):-1},bt=(t,o,e)=>{const n=h(o,e);return n>=0?n:t},ft=(t,o)=>{const e=h(t,o);return e>=0?{sectionAccent:e}:{}},xt=(t,o)=>m(t.props)&&h(t.props,o)<0?[{kind:"band-preset",page:l(t.props.sectionAccent,o)}]:[],Bt=t=>N(t.site?.siteGutter),F=Object.fromEntries(["Top","Right","Bottom","Left","TopPhone","RightPhone","BottomPhone","LeftPhone"].map(t=>[`sectionPadding${t}`,0])),_t=t=>({top:0,right:0,bottom:0,left:0,...t}),Et=(t,o,e,n=[])=>({kind:"group",name:t,keepEmpty:!0,props:(i,s)=>({...E,...F,...f("surface")(i,s),...typeof e=="function"?e(i,s):e}),box:[[o,"bgImage"],a.kind,a.duration,a.delay],parts:n});export{Nt as BOX,it as BUTTON,Rt as DIM,ct as DROP_COMMON,at as DROP_SIDE_PADDING,M as HEADING_CASE_UPPER,At as INNER_BOX,F as NO_PAD,w as NUMBER_TEXT,T as RIGHT_WORDS,dt as SAME_KEYS,rt as SECTION_BOX,st as SH_LINK,Ct as TEXT,bt as bandAccent,h as bandIndex,l as bandPage,ft as bandProps,xt as bandWrites,f as fillFrom,Tt as fillNoBoxHolds,gt as headingCaseOf,c as innerPad,lt as innerPadKeys,Pt as leadLine,U as leadText,ut as lineBorder,_t as lineSides,L as numberAndUnit,mt as ownFill,Et as pictureCell,g as sectionPage,Bt as siteGutterOf,ht as smallText,v as wrapperPad,pt as wrapperPadKeys};
@@ -1 +1 @@
1
- import{phoneKey as M,readHidable as f}from"efficient-easel/draw";import{parseHexColor as X}from"efficient-shell/format";import{cardColumns as j}from"../../../../components/Cards.js";import{resolveSectionBackground as G,THEME_SECTION_BG as S}from"../../../../../format/lib/content/section-background.js";import{CardsMeta as J}from"../../../../../format/lib/document/blocks/general/Cards/meta.js";import{KeyFeaturesMeta as q}from"../../../../../format/lib/document/blocks/general/KeyFeatures/meta.js";import{finiteNumber as x}from"../../../../../format/lib/finite-number.js";import{nonEmptyString as U}from"../../../../../format/lib/non-empty-string.js";import{parseSectionHeadPlacement as V}from"../../../../../format/lib/sections/section-head-placement.js";import{hasWords as Y}from"../../../sections/section-to-box.js";import{BOX_TYPE as l,CONTAINER_BLOCKS_SLOT as p}from"../../../../../format/lib/document/container-blocks.js";import{labelTextSeed as z}from"../../../../../format/lib/document/text-seeds.js";import{CARDS_BODY_LOOK as Q,CARDS_CARD as Z,CARDS_TITLE_LOOK as $,rowFieldTextSeed as a}from"../../../../../format/lib/document/blocks/general/Cards/card-seed.js";import{bandAccent as ee,bandProps as oe,bandWrites as te,BUTTON as re,DIM as h,DROP_COMMON as m,DROP_SIDE_PADDING as g,INNER_BOX as t,SAME_KEYS as w,SECTION_BOX as u,fillFrom as c,SH_LINK as ne,TEXT as n,smallText as se,wrapperPad as y,wrapperPadKeys as b}from"./section-to-box-row-parts.js";import{headTree as k,token as i}from"./section-head-looks.js";import{boxPadding as ae}from"../../../../../format/lib/document/seed-parts.js";import{SECTION_BG_BUILT_IN as ie}from"../../../../../format/lib/document/blocks/general/section-bg-built-in.js";const d=(e,o,r,W)=>({sectionBorder:{top:e,right:o,bottom:r,left:W}}),O=e=>o=>j(x(o.columns)??x(e.columns)),_=e=>({kind:"group",name:"Grid",props:{...t,gap:0,...d(1,0,0,1)},parts:[e]}),C={...t,direction:"row",gap:0,share:"equal"},R="its head sits in a Box of its own above it (own-box): the row draws the head inline",T=e=>V(e.headPlacement)==="own-box",E="inline is the head the row draws; an own-box node is skipped (`skip`)",de=e=>({kind:"group",name:"Heading",props:e,parts:[se("eyebrow"),{kind:"text",key:"title",role:"heading",props:n,style:{textStyle:"heading-3",case:"upper"},was:{size:44}}]}),B={top:72,bottom:72,topPhone:72,bottomPhone:72},le={...Z,...d(0,1,1,0)},pe={name:"Cards",boxProps:(e,o)=>({...u,direction:"column",gap:36,gapPhone:28,...c("surface")(e,o),...y(e,B)}),box:[...w,...b(B)],skip:e=>T(e)?R:typeof e.dataSource=="string"&&e.dataSource?"its cards come from a source: they are drawn from the card template on Cards":e.template!==void 0?"its cards are drawn from its own card template (an emptied one draws none): the shape the other rows land on":e.cardStyle==="label-only"?"Label only is Key Features' look: no live node holds it, so it has no row of its own yet":void 0,parts:[k("Cards"),_({kind:"list",key:"items",name:"Card",perRow:O(J.defaultProps),rowName:"Row",rowProps:C,props:(e,o)=>({...le,...c("background")(e,o)}),parts:[{kind:"text",key:"title",props:n,style:$},{kind:"text",key:"body",props:h,style:Q}]})],drop:{...m,...g,columns:"the rows of N: one Row Box per `columns` cards, which the Box draws as N equal blocks",cardStyle:"the standard card is what the row draws; a Label only node is skipped (0 live nodes)",dataSource:"an empty source is typed cards, what the row draws; a sourced node is skipped (0 live nodes)",dataSourceOptions:"read only with a source; a sourced node is skipped (0 live nodes)",template:"an empty card template is typed cards, what the row draws; a node with a template is skipped",highlightedCard:"read only with a card template; a node with a template is skipped",highlightBadge:"read only with a card template; a node with a template is skipped",headPlacement:E,eyebrowLook:"needs the eyebrow's Filled look on a Text block: Plain is the eyebrow start look the row draws; 2 of 62 live nodes store it (JJ's export, 2026-10-24)"}},N={top:76,bottom:76,topPhone:76,bottomPhone:76},ce={...t,direction:"row",align:"center",gap:16,sectionPaddingTop:32,sectionPaddingRight:28,sectionPaddingBottom:32,sectionPaddingLeft:28,...d(0,1,1,0)},L={textStyle:"body-1",color:"text"},A=(e,o)=>typeof o?.href=="string"&&o.href.trim()!=="",he={name:"Key Features",boxProps:e=>({...u,direction:"column",gap:44,...d(1,0,1,0),...y(e,N)}),box:[...w,...b(N)],parts:[de({...t,direction:"row",align:"end",gap:20,wrap:!0,share:"content"}),_({kind:"list",key:"items",name:"Feature",perRow:O(q.defaultProps),rowName:"Row",rowProps:C,props:ce,parts:[{kind:"button",key:"label",href:"href",when:A,variant:"ghost",props:{...re,...ne,icon:"none"},style:L},{kind:"text",key:"label",when:(e,o)=>!A(e,o),props:n,style:L,was:{size:17}}]})],drop:{...m,...g,columns:"the rows of N: one Row Box per `columns` cells, which the Box draws as N equal blocks",eyebrowLook:"needs the eyebrow's Filled look on a Text block: Filled is Key Features' own default (lib/sections/section-eyebrow-look), so 20 of 21 published nodes draw it with nothing stored; the row draws the Plain start look (JJ's export, 2026-10-24)"}},D={top:120,bottom:120,topPhone:80,bottomPhone:80},F=e=>{const o=G(typeof e.background=="string"?e.background:void 0,ie.Series);return o&&o!=="transparent"?o:void 0},P=e=>F(e)===S,me=(e,o)=>{const r=F(e);return!r||r===S?{}:r==="var(--site-surface)"?c("surface")(e,o):X(r.trim())?{fillColor:r.trim()}:{}},ge={...t,justify:"between",gap:16,gapPhone:16,sectionHeightMode:"fixed",sectionHeightValue:340,sectionHeightUnit:"px",sectionPaddingTop:36,sectionPaddingRight:28,sectionPaddingBottom:32,sectionPaddingLeft:28,sectionPaddingTopPhone:36,sectionPaddingRightPhone:28,sectionPaddingBottomPhone:32,sectionPaddingLeftPhone:28},I={...t,direction:"row",justify:"between",gap:12,share:"content",phoneRow:2,[M("share")]:"content"},v={textStyle:"body-5",...i("label",12),letterSpacing:.22,case:"upper",lineHeight:1.5},we=e=>Y(e.viewLabel)&&!f(e.viewLabel).hidden,s=e=>f(e).text?.trim?.()??"",H=e=>Object.fromEntries(Object.entries(e).filter(([,o])=>U(o)!==void 0)),ue={name:"Recurring Columns",boxProps:(e,o)=>({...u,direction:"column",gap:60,gapPhone:60,...d(0,0,1,0),...P(e)?oe(e,o):{},...me(e,o),...y(e,D)}),box:[...w.filter(e=>e!=="sectionAccent"),["sectionAccent","sectionAccent",(e,o,r)=>P(o)?ee(e,o,r):e],...b(D)],skip:e=>T(e)?R:void 0,site:(e,o)=>P(e.props)?te(e,o):[],parts:[k("Series"),{kind:"core",as:"Cards",keep:[],props:{columns:4},derive:{reads:["cards"],props:e=>({items:(Array.isArray(e.cards)?e.cards:[]).map(o=>H({num:s(o.num),since:s(o.since),title:s(o.title),body:s(o.desc),count:[s(o.entries),s(o.entriesLabel)].filter(Boolean).join(" ")}))})},slots:(e,o)=>({template:[{type:l,props:{...ge,...c("background")(e,o),name:"Card"},slots:{[p]:[{type:l,props:{...t,name:"Words",gap:16,gapPhone:16},slots:{[p]:[{type:l,props:{...I,name:"Top"},slots:{[p]:[a("num",n,i("label",13),!0),a("since",n,i("label",13),!0)]}},a("title",{...n,tag:"h3"},{textStyle:"heading-3",...i("headingSmall",28),weight:500,case:"upper",lineHeight:1.04,letterSpacing:-.02}),a("body",h,{textStyle:"body-5",fontRole:"heading",...i("body",14),lineHeight:1.6})]}},{type:l,props:{...I,name:"Footer",align:"center",gap:0,gapPhone:0,sectionPaddingTop:16,sectionPaddingTopPhone:16,...d(1,0,0,0)},slots:{[p]:[a("count",h,v),...we(e)?[{type:l,props:{...t,name:"View",maxWidthPhone:266},slots:{[p]:[{type:"Text",props:{...n,text:f(e.viewLabel).text,_partStyles:{text:{...z()._partStyles.text,...v}}}}]}}]:[]]}}]}}]})}],reads:{viewLabel:"a Text typed once in the card template: the far end of every card's footer",background:"the Box's theme (the band preset) or its Fill"},drop:{...m,...g,headPlacement:E}},K={top:60,bottom:60,topPhone:40,bottomPhone:40},ye={...t,gap:8,gapPhone:8,...ae(24),...d(1,1,1,1)},be={name:"Document Detail Cards",boxProps:e=>({...u,direction:"column",gap:40,gapPhone:16,...d(0,0,1,0),...y(e,K)}),box:[...w,...b(K)],parts:[{kind:"core",as:"Cards",keep:[],props:{columns:3},derive:{reads:["cards"],props:e=>({items:(Array.isArray(e.cards)?e.cards:[]).map(o=>H({label:s(o.label),value:s(o.value),body:s(o.desc)}))})},slots:(e,o)=>({template:[{type:l,props:{...ye,...c("surface")(e,o),name:"Card"},slots:{[p]:[a("label",n,{...i("label",12),lineHeight:1.5},!0),{type:l,props:{...t,name:"Words",gap:14,gapPhone:14},slots:{[p]:[a("value",n,{textStyle:"heading-3",...i("headingSmall",20),weight:500,letterSpacing:-.015,lineHeight:1.5}),a("body",h,{textStyle:"body-5",fontRole:"accent",...i("body",14),italic:!0,lineHeight:1.5})]}}]}}]})}],drop:{...m,...g}},Ie={Cards:pe,KeyFeatures:he,Series:ue,DocMetaCards:be};export{Ie as CARDS_SECTION_TO_BOX};
1
+ import{phoneKey as W,readHidable as f}from"efficient-easel/draw";import{cardColumns as M}from"../../../../components/Cards.js";import{resolveSectionBackground as X,THEME_SECTION_BG as j}from"../../../../../format/lib/content/section-background.js";import{CardsMeta as G}from"../../../../../format/lib/document/blocks/general/Cards/meta.js";import{KeyFeaturesMeta as J}from"../../../../../format/lib/document/blocks/general/KeyFeatures/meta.js";import{finiteNumber as x}from"../../../../../format/lib/finite-number.js";import{nonEmptyString as q}from"../../../../../format/lib/non-empty-string.js";import{parseSectionHeadPlacement as U}from"../../../../../format/lib/sections/section-head-placement.js";import{hasWords as V}from"../../../sections/section-to-box.js";import{BOX_TYPE as d,CONTAINER_BLOCKS_SLOT as l}from"../../../../../format/lib/document/container-blocks.js";import{labelTextSeed as Y}from"../../../../../format/lib/document/text-seeds.js";import{CARDS_BODY_LOOK as z,CARDS_CARD as Q,CARDS_TITLE_LOOK as Z,rowFieldTextSeed as a}from"../../../../../format/lib/document/blocks/general/Cards/card-seed.js";import{bandAccent as $,bandProps as ee,bandWrites as oe,BUTTON as te,DIM as p,DROP_COMMON as c,DROP_SIDE_PADDING as h,INNER_BOX as t,SAME_KEYS as m,SECTION_BOX as g,fillFrom as w,fillNoBoxHolds as ne,ownFill as se,SH_LINK as ae,TEXT as n,smallText as re,wrapperPad as y,wrapperPadKeys as b}from"./section-to-box-row-parts.js";import{headTree as k,token as r}from"./section-head-looks.js";import{boxPadding as ie}from"../../../../../format/lib/document/seed-parts.js";import{SECTION_BG_BUILT_IN as de}from"../../../../../format/lib/document/blocks/general/section-bg-built-in.js";const i=(e,o,u,K)=>({sectionBorder:{top:e,right:o,bottom:u,left:K}}),O=e=>o=>M(x(o.columns)??x(e.columns)),_=e=>({kind:"group",name:"Grid",props:{...t,gap:0,...i(1,0,0,1)},parts:[e]}),C={...t,direction:"row",gap:0,share:"equal"},R="its head sits in a Box of its own above it (own-box): the row draws the head inline",T=e=>U(e.headPlacement)==="own-box",E="inline is the head the row draws; an own-box node is skipped (`skip`)",le=e=>({kind:"group",name:"Heading",props:e,parts:[re("eyebrow"),{kind:"text",key:"title",role:"heading",props:n,style:{textStyle:"heading-3",case:"upper"},was:{size:44}}]}),B={top:72,bottom:72,topPhone:72,bottomPhone:72},pe={...Q,...i(0,1,1,0)},ce={name:"Cards",boxProps:(e,o)=>({...g,direction:"column",gap:36,gapPhone:28,...w("surface")(e,o),...y(e,B)}),box:[...m,...b(B)],skip:e=>T(e)?R:typeof e.dataSource=="string"&&e.dataSource?"its cards come from a source: they are drawn from the card template on Cards":e.template!==void 0?"its cards are drawn from its own card template (an emptied one draws none): the shape the other rows land on":e.cardStyle==="label-only"?"Label only is Key Features' look: no live node holds it, so it has no row of its own yet":void 0,parts:[k("Cards"),_({kind:"list",key:"items",name:"Card",perRow:O(G.defaultProps),rowName:"Row",rowProps:C,props:(e,o)=>({...pe,...w("background")(e,o)}),parts:[{kind:"text",key:"title",props:n,style:Z},{kind:"text",key:"body",props:p,style:z}]})],drop:{...c,...h,columns:"the rows of N: one Row Box per `columns` cards, which the Box draws as N equal blocks",cardStyle:"the standard card is what the row draws; a Label only node is skipped (0 live nodes)",dataSource:"an empty source is typed cards, what the row draws; a sourced node is skipped (0 live nodes)",dataSourceOptions:"read only with a source; a sourced node is skipped (0 live nodes)",template:"an empty card template is typed cards, what the row draws; a node with a template is skipped",highlightedCard:"read only with a card template; a node with a template is skipped",highlightBadge:"read only with a card template; a node with a template is skipped",headPlacement:E,eyebrowLook:"needs the eyebrow's Filled look on a Text block: Plain is the eyebrow start look the row draws; 2 of 62 live nodes store it (JJ's export, 2026-10-24)"}},N={top:76,bottom:76,topPhone:76,bottomPhone:76},he={...t,direction:"row",align:"center",gap:16,sectionPaddingTop:32,sectionPaddingRight:28,sectionPaddingBottom:32,sectionPaddingLeft:28,...i(0,1,1,0)},L={textStyle:"body-1",color:"text"},A=(e,o)=>typeof o?.href=="string"&&o.href.trim()!=="",me={name:"Key Features",boxProps:e=>({...g,direction:"column",gap:44,...i(1,0,1,0),...y(e,N)}),box:[...m,...b(N)],parts:[le({...t,direction:"row",align:"end",gap:20,wrap:!0,share:"content"}),_({kind:"list",key:"items",name:"Feature",perRow:O(J.defaultProps),rowName:"Row",rowProps:C,props:he,parts:[{kind:"button",key:"label",href:"href",when:A,variant:"ghost",props:{...te,...ae,icon:"none"},style:L},{kind:"text",key:"label",when:(e,o)=>!A(e,o),props:n,style:L,was:{size:17}}]})],drop:{...c,...h,columns:"the rows of N: one Row Box per `columns` cells, which the Box draws as N equal blocks",eyebrowLook:"needs the eyebrow's Filled look on a Text block: Filled is Key Features' own default (lib/sections/section-eyebrow-look), so 20 of 21 published nodes draw it with nothing stored; the row draws the Plain start look (JJ's export, 2026-10-24)"}},D={top:120,bottom:120,topPhone:80,bottomPhone:80},P=e=>{const o=X(typeof e.background=="string"?e.background:void 0,de.Series);return o&&o!=="transparent"?o:void 0},S=e=>P(e)===j,ge={...t,justify:"between",gap:16,gapPhone:16,sectionHeightMode:"fixed",sectionHeightValue:340,sectionHeightUnit:"px",sectionPaddingTop:36,sectionPaddingRight:28,sectionPaddingBottom:32,sectionPaddingLeft:28,sectionPaddingTopPhone:36,sectionPaddingRightPhone:28,sectionPaddingBottomPhone:32,sectionPaddingLeftPhone:28},F={...t,direction:"row",justify:"between",gap:12,share:"content",phoneRow:2,[W("share")]:"content"},I={textStyle:"body-5",...r("label",12),letterSpacing:.22,case:"upper",lineHeight:1.5},we=e=>V(e.viewLabel)&&!f(e.viewLabel).hidden,s=e=>f(e).text?.trim?.()??"",v=e=>Object.fromEntries(Object.entries(e).filter(([,o])=>q(o)!==void 0)),ye={name:"Recurring Columns",boxProps:(e,o)=>({...g,direction:"column",gap:60,gapPhone:60,...i(0,0,1,0),...S(e)?ee(e,o):{},...se(P(e),e,o),...y(e,D)}),box:[...m.filter(e=>e!=="sectionAccent"),["sectionAccent","sectionAccent",(e,o,u)=>S(o)?$(e,o,u):e],...b(D)],skip:e=>ne(P(e))??(T(e)?R:void 0),site:(e,o)=>S(e.props)?oe(e,o):[],parts:[k("Series"),{kind:"core",as:"Cards",keep:[],props:{columns:4},derive:{reads:["cards"],props:e=>({items:(Array.isArray(e.cards)?e.cards:[]).map(o=>v({num:s(o.num),since:s(o.since),title:s(o.title),body:s(o.desc),count:[s(o.entries),s(o.entriesLabel)].filter(Boolean).join(" ")}))})},slots:(e,o)=>({template:[{type:d,props:{...ge,...w("background")(e,o),name:"Card"},slots:{[l]:[{type:d,props:{...t,name:"Words",gap:16,gapPhone:16},slots:{[l]:[{type:d,props:{...F,name:"Top"},slots:{[l]:[a("num",n,r("label",13),!0),a("since",n,r("label",13),!0)]}},a("title",{...n,tag:"h3"},{textStyle:"heading-3",...r("headingSmall",28),weight:500,case:"upper",lineHeight:1.04,letterSpacing:-.02}),a("body",p,{textStyle:"body-5",fontRole:"heading",...r("body",14),lineHeight:1.6})]}},{type:d,props:{...F,name:"Footer",align:"center",gap:0,gapPhone:0,sectionPaddingTop:16,sectionPaddingTopPhone:16,...i(1,0,0,0)},slots:{[l]:[a("count",p,I),...we(e)?[{type:d,props:{...t,name:"View",maxWidthPhone:266},slots:{[l]:[{type:"Text",props:{...n,text:f(e.viewLabel).text,_partStyles:{text:{...Y()._partStyles.text,...I}}}}]}}]:[]]}}]}}]})}],reads:{viewLabel:"a Text typed once in the card template: the far end of every card's footer",background:"the Box's theme (the band preset) or its Fill"},drop:{...c,...h,headPlacement:E}},H={top:60,bottom:60,topPhone:40,bottomPhone:40},be={...t,gap:8,gapPhone:8,...ie(24),...i(1,1,1,1)},ue={name:"Document Detail Cards",boxProps:e=>({...g,direction:"column",gap:40,gapPhone:16,...i(0,0,1,0),...y(e,H)}),box:[...m,...b(H)],parts:[{kind:"core",as:"Cards",keep:[],props:{columns:3},derive:{reads:["cards"],props:e=>({items:(Array.isArray(e.cards)?e.cards:[]).map(o=>v({label:s(o.label),value:s(o.value),body:s(o.desc)}))})},slots:(e,o)=>({template:[{type:d,props:{...be,...w("surface")(e,o),name:"Card"},slots:{[l]:[a("label",n,{...r("label",12),lineHeight:1.5},!0),{type:d,props:{...t,name:"Words",gap:14,gapPhone:14},slots:{[l]:[a("value",n,{textStyle:"heading-3",...r("headingSmall",20),weight:500,letterSpacing:-.015,lineHeight:1.5}),a("body",p,{textStyle:"body-5",fontRole:"accent",...r("body",14),italic:!0,lineHeight:1.5})]}}]}}]})}],drop:{...c,...h}},Fe={Cards:ce,KeyFeatures:me,Series:ye,DocMetaCards:ue};export{Fe as CARDS_SECTION_TO_BOX};
@@ -1 +1 @@
1
- import{phoneKey as l}from"efficient-easel/draw";import{COUNT_KEY_PROP as g}from"../../../../../format/lib/content/block-sources.js";import{resolveSectionBackground as k,THEME_SECTION_BG as _}from"../../../../../format/lib/content/section-background.js";import{finiteNumber as T}from"../../../../../format/lib/finite-number.js";import{hasWords as s}from"../../../sections/section-to-box.js";import{DROP_COMMON as u,DROP_SIDE_PADDING as m,INNER_BOX as o,NUMBER_TEXT as f,SAME_KEYS as w,SECTION_BOX as S,TEXT as b,bandAccent as B,bandProps as O,bandWrites as A,fillFrom as E,innerPad as N,innerPadKeys as R,smallText as i,wrapperPad as H,wrapperPadKeys as I}from"./section-to-box-row-parts.js";import{fluidToken as M,headTree as v,token as n}from"./section-head-looks.js";import{SECTION_BG_BUILT_IN as C}from"../../../../../format/lib/document/blocks/general/section-bg-built-in.js";const p=e=>typeof e=="string"?e.trim():"";function y(e){const t=`${p(e.prefix)}${p(e.value)}`,a=p(e.suffix);return e.emphasizeAll===!0?t?`==_${t}_==`:"":`${t}${a?`==_${a}_==`:""}`}const d={kind:"block",type:"Text",props:{...f,_partStyles:{text:{textStyle:"heading-2",...M("headingMedium",56,7,96),weight:500,case:"none",lineHeight:.9,letterSpacing:-.04}}},box:[["value","text",(e,t)=>y(t)]],when:(e,t)=>t!==void 0&&typeof t.value=="string"&&y(t)!==""},P=e=>s(e?.supSuffix),c=e=>k(e.background,C.StatsParagraph),r=e=>c(e)===_,h=e=>({...e,sectionAccent:e.sectionAccent??0}),D=(e,t)=>r(e)?E("background")(e,t):{},F={name:"Stats with Text",skip:e=>c(e)&&c(e)!=="transparent"&&!r(e)?"it paints a colour of its own, not the section band":void 0,boxProps:(e,t)=>({...S,direction:"column",gap:60,gapPhone:60,sectionBorder:{bottom:1},...N(e,"StatsParagraph"),...r(e)?O(h(e),t):{}}),box:[...w.filter(e=>e!=="sectionAccent"),["sectionAccent","sectionAccent",(e,t,a)=>r(t)?B(e,h(t),a):e],...R("StatsParagraph")],site:(e,t)=>r(e.props)?A({props:h(e.props)},t):[],parts:[v("StatsParagraph"),{kind:"group",name:"Stats",props:{...o,gap:0},parts:[{kind:"list",key:"stats",name:"Stat",perRow:()=>4,rowName:"Stats row",rowProps:{...o,direction:"row",gap:0,share:"equal",phoneRow:2,[l("share")]:"content"},props:(e,t)=>({...o,justify:"between",gap:12,gapPhone:12,sectionHeightMode:"fixed",sectionHeightValue:242,sectionHeightUnit:"px",widthFitPhone:"fixed",widthPhone:800,sectionPaddingTop:48,sectionPaddingBottom:48,sectionPaddingLeft:32,sectionPaddingRight:32,sectionBorder:{top:1,right:1,bottom:1,left:1},...D(e,t)}),parts:[{...d,when:(e,t)=>!P(t)&&d.when(e,t)},{kind:"group",name:"Figure",props:{...o,direction:"row",align:"start",gap:32,gapPhone:32,share:"content",phoneRow:2,[l("share")]:"content"},when:(e,t)=>P(t),parts:[d,{kind:"text",key:"supSuffix",props:b,style:{textStyle:"body-5",...n("label",13),weight:500,color:"accent",letterSpacing:.18,lineHeight:1,padding:12}}]},{kind:"group",name:"Words",props:{...o,gap:4,gapPhone:4},parts:[{kind:"text",key:"label",props:b,style:{textStyle:"body-1",fontRole:"heading",...n("body",16),lineHeight:1.5,letterSpacing:-.01}},i("sub",{color:"labels",...n("label",12),lineHeight:1.5,letterSpacing:.24})]}]}]}],drop:{...u,...m,background:"the band is the Box's theme: the site's band preset (`sectionAccent`), or a declared band-preset write; none paints nothing, and any other colour is skipped",headPlacement:"needs a row per head placement: an own-box Stats with Text draws no head (its words sit in a Section Header above it), the row always draws the head"}},K=new Set(["value","label",g]),x={top:48,bottom:48,topPhone:48,bottomPhone:48},U={name:"Stats",skip:e=>s(e.dataSource)?"its figures come from a source":Array.isArray(e.items)&&e.items.some(t=>s(t?.[g]))?"a figure names a count, and each figure Text here is typed by hand until it is linked":Array.isArray(e.items)&&e.items.some(t=>Object.keys(t??{}).some(a=>!K.has(a)))?"a figure has a key no part here reads":Object.keys(e._partStyles??{}).some(t=>t!=="heading")?"a figure or a name has a style of its own, kept by kind, which no part here reads":void 0,boxProps:e=>({...S,direction:"column",gap:24,gapPhone:24,...H(e,x)}),box:[...w,...I(x)],parts:[i("heading",{color:"labels",...n("label",12),letterSpacing:.2}),{kind:"group",name:"Stats",props:{...o,gap:32,gapPhone:32},parts:[{kind:"list",key:"items",name:"Stat",perRow:e=>T(e.columns)??4,rowName:"Stats row",rowProps:{...o,direction:"row",gap:32,gapPhone:32,share:"equal",phoneRow:2},props:{...o,gap:8,gapPhone:8,sectionBorder:{top:1},sectionPaddingTop:20},parts:[{kind:"text",key:"value",props:f,style:{textStyle:"heading-2",...n("headingMedium",48,36),weight:500,case:"none",lineHeight:1,letterSpacing:-.03}},i("label",{color:"labels",...n("label",12),letterSpacing:.2})]}]}],drop:{...u,...m,columns:"the rows of N: one row Box per `columns` figures, which the Box draws",dataSource:"an empty source is typed figures, what the row draws; a sourced node is skipped (0 Hartes nodes)",dataSourceOptions:"read only with a source; a sourced node is skipped (0 Hartes nodes)",contained:"the Box draws the site frame now; each figure fills the Box's column",background:"needs a Box fill: a Box paints only its theme's page colour. 0 Hartes nodes store it (read-only, 2026-11-02)"}},z={StatsParagraph:F,Stats:U};export{z as STATS_SECTION_TO_BOX,y as figureWords};
1
+ import{phoneKey as h}from"efficient-easel/draw";import{COUNT_KEY_PROP as g}from"../../../../../format/lib/content/block-sources.js";import{resolveSectionBackground as u,THEME_SECTION_BG as T}from"../../../../../format/lib/content/section-background.js";import{finiteNumber as B}from"../../../../../format/lib/finite-number.js";import{hasWords as s}from"../../../sections/section-to-box.js";import{DROP_COMMON as m,DROP_SIDE_PADDING as f,INNER_BOX as o,NUMBER_TEXT as w,SAME_KEYS as S,SECTION_BOX as b,TEXT as y,bandAccent as O,bandProps as A,bandWrites as E,fillFrom as N,innerPad as R,innerPadKeys as H,smallText as i,wrapperPad as I,wrapperPadKeys as v}from"./section-to-box-row-parts.js";import{fluidToken as M,headTree as F,token as n}from"./section-head-looks.js";import{SECTION_BG_BUILT_IN as P}from"../../../../../format/lib/document/blocks/general/section-bg-built-in.js";const p=e=>typeof e=="string"?e.trim():"";function k(e){const t=`${p(e.prefix)}${p(e.value)}`,a=p(e.suffix);return e.emphasizeAll===!0?t?`==_${t}_==`:"":`${t}${a?`==_${a}_==`:""}`}const d={kind:"block",type:"Text",props:{...w,_partStyles:{text:{textStyle:"heading-2",...M("headingMedium",56,7,96),weight:500,case:"none",lineHeight:.9,letterSpacing:-.04}}},box:[["value","text",(e,t)=>k(t)]],when:(e,t)=>t!==void 0&&typeof t.value=="string"&&k(t)!==""},x=e=>s(e?.supSuffix),c=e=>u(e.background,P.StatsParagraph),r=e=>c(e)===T,l=e=>({...e,sectionAccent:e.sectionAccent??0}),C=(e,t)=>r(e)?N("background")(e,t):{},D={name:"Stats with Text",skip:e=>c(e)&&c(e)!=="transparent"&&!r(e)?"it paints a colour of its own, not the section band":void 0,boxProps:(e,t)=>({...b,direction:"column",gap:60,gapPhone:60,sectionBorder:{bottom:1},...R(e,"StatsParagraph"),...r(e)?A(l(e),t):{}}),box:[...S.filter(e=>e!=="sectionAccent"),["sectionAccent","sectionAccent",(e,t,a)=>r(t)?O(e,l(t),a):e],...H("StatsParagraph")],site:(e,t)=>r(e.props)?E({props:l(e.props)},t):[],parts:[F("StatsParagraph"),{kind:"group",name:"Stats",props:{...o,gap:0},parts:[{kind:"list",key:"stats",name:"Stat",perRow:()=>4,rowName:"Stats row",rowProps:{...o,direction:"row",gap:0,share:"equal",phoneRow:2,[h("share")]:"content"},props:(e,t)=>({...o,justify:"between",gap:12,gapPhone:12,sectionHeightMode:"fixed",sectionHeightValue:242,sectionHeightUnit:"px",widthFitPhone:"fixed",widthPhone:800,sectionPaddingTop:48,sectionPaddingBottom:48,sectionPaddingLeft:32,sectionPaddingRight:32,sectionBorder:{top:1,right:1,bottom:1,left:1},...C(e,t)}),parts:[{...d,when:(e,t)=>!x(t)&&d.when(e,t)},{kind:"group",name:"Figure",props:{...o,direction:"row",align:"start",gap:32,gapPhone:32,share:"content",phoneRow:2,[h("share")]:"content"},when:(e,t)=>x(t),parts:[d,{kind:"text",key:"supSuffix",props:y,style:{textStyle:"body-5",...n("label",13),weight:500,color:"accent",letterSpacing:.18,lineHeight:1,padding:12}}]},{kind:"group",name:"Words",props:{...o,gap:4,gapPhone:4},parts:[{kind:"text",key:"label",props:y,style:{textStyle:"body-1",fontRole:"heading",...n("body",16),lineHeight:1.5,letterSpacing:-.01}},i("sub",{color:"labels",...n("label",12),lineHeight:1.5,letterSpacing:.24})]}]}]}],drop:{...m,...f,background:"the band is the Box's theme: the site's band preset (`sectionAccent`), or a declared band-preset write; none paints nothing, and any other colour is skipped",headPlacement:"needs a row per head placement: an own-box Stats with Text draws no head (its words sit in a Section Header above it), the row always draws the head"}},K=new Set(["value","label",g]),_={top:48,bottom:48,topPhone:48,bottomPhone:48},U=e=>{const t=u(typeof e.background=="string"?e.background:void 0,P.Stats);return!!t&&t!=="transparent"},$={name:"Stats",skip:e=>U(e)?"it paints a colour inside its padding, and a Box paints its Fill over the padding too":s(e.dataSource)?"its figures come from a source":Array.isArray(e.items)&&e.items.some(t=>s(t?.[g]))?"a figure names a count, and each figure Text here is typed by hand until it is linked":Array.isArray(e.items)&&e.items.some(t=>Object.keys(t??{}).some(a=>!K.has(a)))?"a figure has a key no part here reads":Object.keys(e._partStyles??{}).some(t=>t!=="heading")?"a figure or a name has a style of its own, kept by kind, which no part here reads":void 0,boxProps:e=>({...b,direction:"column",gap:24,gapPhone:24,...I(e,_)}),box:[...S,...v(_)],parts:[i("heading",{color:"labels",...n("label",12),letterSpacing:.2}),{kind:"group",name:"Stats",props:{...o,gap:32,gapPhone:32},parts:[{kind:"list",key:"items",name:"Stat",perRow:e=>B(e.columns)??4,rowName:"Stats row",rowProps:{...o,direction:"row",gap:32,gapPhone:32,share:"equal",phoneRow:2},props:{...o,gap:8,gapPhone:8,sectionBorder:{top:1},sectionPaddingTop:20},parts:[{kind:"text",key:"value",props:w,style:{textStyle:"heading-2",...n("headingMedium",48,36),weight:500,case:"none",lineHeight:1,letterSpacing:-.03}},i("label",{color:"labels",...n("label",12),letterSpacing:.2})]}]}],drop:{...m,...f,columns:"the rows of N: one row Box per `columns` figures, which the Box draws",dataSource:"an empty source is typed figures, what the row draws; a sourced node is skipped (0 Hartes nodes)",dataSourceOptions:"read only with a source; a sourced node is skipped (0 Hartes nodes)",contained:"the Box draws the site frame now; each figure fills the Box's column",background:"only no fill reaches here: a node that paints a colour is skipped"}},V={StatsParagraph:D,Stats:$};export{V as STATS_SECTION_TO_BOX,k as figureWords};
@@ -1,3 +1,3 @@
1
- import{BUTTON as g,DIM as s,bandAccent as S,bandIndex as _,bandWrites as P,DROP_COMMON as h,DROP_SIDE_PADDING as m,INNER_BOX as o,SAME_KEYS as b,SECTION_BOX as y,lineBorder as u,TEXT as l,innerPad as x,innerPadKeys as k}from"./section-to-box-row-parts.js";import{splitParagraphs as E}from"../../../../components/goldPhrases.js";import{TIMELINE_YEAR_BOX as I,TIMELINE_YEAR_HEAD as w}from"../../../../../format/lib/sections/timeline-year-shape.js";import{boxPadding as O}from"../../../../../format/lib/document/seed-parts.js";const A="jetbrains-mono",T="space-grotesk",i=(e,t,r={})=>({textStyle:"body-5",font:A,size:e,sizePhone:e,letterSpacing:t,lineHeight:1.5,weight:400,...r}),p=(e,t,r,d)=>({font:T,size:e,sizePhone:t,case:"upper",weight:500,letterSpacing:r,lineHeight:d}),a=(e,t,r,d={})=>({textStyle:"body-1",font:T,size:e,sizePhone:t,weight:400,case:"none",lineHeight:r,...d}),n=(e,t,r={})=>({kind:"text",key:e,props:l,style:t,...r}),f=(e,t)=>t?.future===!0,c=e=>E(typeof e?.body=="string"?e.body:""),H={name:"Milestone Timeline",boxProps:(e,t)=>{const r=_(e,t);return{...y,direction:"column",gap:60,sectionBorder:{bottom:1},...x(e,"TimelineTrack"),...r>=0?{sectionAccent:r}:{}}},box:[...b.filter(e=>e!=="sectionAccent"),["sectionAccent","sectionAccent",S],...k("TimelineTrack")],parts:[{kind:"group",name:"Heading",props:{...o,direction:"row",align:"end",justify:"between",gap:40,share:"content",sectionPaddingBottom:32,sectionBorder:{bottom:1}},parts:[{kind:"group",name:"Title",props:{...o,direction:"row",align:"end",gap:40,share:"content"},parts:[n("eyebrow",i(13,.3,{case:"upper",color:"accent",padding:8}),{role:"eyebrow"}),n("title",{textStyle:"heading-2",...p(79,40,-.03,1)},{role:"heading"})]},n("intro",a(14,14,1.5),{props:{...s,align:"right",maxWidth:360}})]},{kind:"group",name:"Years",props:{...o,direction:"row",share:"equal",gap:0,line:!0},parts:[{kind:"list",key:"entries",name:"Year",props:{...o,...I},item:e=>({props:e.future===!0?{upcoming:!0}:{}}),parts:[{kind:"group",name:w.name,props:{...o,...w},parts:[n("date",i(13,.22,{color:"accent"}),{when:(e,t)=>!f(e,t)}),n("date",i(13,.22,{color:"labels"}),{when:f}),n("title",{textStyle:"heading-3",...p(20,20,-.02,1.1)},{role:"heading"})]},n("blurb",a(13,13,1.55),{props:s})]}]},{kind:"button",key:"ctaText",href:"ctaHref",variant:"ghost",props:(e,t)=>({...g,align:"right",...u(e,t)}),style:i(13,.3,{case:"upper"})}],site:P,drop:{...h,...m,background:"the band is the Box's theme: the site's band preset (`sectionAccent`), or a declared band-preset write (`lib/theme` `bandPresetIndex`)",headPlacement:"needs a row per head placement: an own-box Milestone Timeline draws no head (its words sit in a Section Header above it), the row always draws the head"}},M={name:"Story Timeline",skip:e=>{const t=typeof e.layout=="string"?e.layout:"split";return t==="split"?void 0:`display "${t}": not converted (0 live pages; Spine and Alternating are not offered, a Track story is not stored anywhere)`},boxProps:e=>({...y,direction:"row",share:"twoThree",gap:80,align:"start",...x(e,"Timeline")}),box:[...b,...k("Timeline")],parts:[{kind:"group",name:"Heading",props:{...o,gap:24},parts:[n("eyebrow",i(12,.3,{case:"upper",color:"accent"}),{role:"eyebrow"}),n("title",{textStyle:"heading-2",...p(72,40,-.03,.94)},{role:"heading"}),n("intro",a(14,14,1.6),{props:{...s,maxWidth:360}}),{kind:"group",name:"Picture",keepEmpty:!0,box:[["imageSrc","bgImage"]],props:{...o,sectionBorder:{top:1,right:1,bottom:1,left:1},darken:75,darkenStyle:"bottom",placement:"bottom-center",sectionHeightMode:"fixed",sectionHeightValue:667,sectionHeightUnit:"px",sectionHeightModePhone:"fixed",sectionHeightValuePhone:419,sectionHeightUnitPhone:"px",...O(12,16)},when:e=>typeof e.imageSrc=="string"&&e.imageSrc.trim()!=="",parts:[{kind:"group",name:"Caption",props:{...o,direction:"row",justify:"between",align:"center",gap:12,share:"content",phoneRow:2},parts:[n("imageCaption",i(11,.24,{case:"upper",color:"text"})),n("imageMeta",i(11,.24,{case:"upper",color:"accent"}),{props:{...l,align:"right"}})]}]},{kind:"button",key:"ctaText",href:"ctaHref",variant:"ghost",props:(e,t)=>({...g,...u(e,t)}),style:i(13,.3,{case:"upper"})}]},{kind:"group",name:"Chapters",props:{...o,gap:48,line:!1},parts:[{kind:"list",key:"entries",name:"Chapter",props:{...o,direction:"row",gap:24,share:"biggerRight",align:"start"},parts:[n("date",i(13,.24,{color:"accent"})),{kind:"group",name:"Words",props:{...o,gap:14},parts:[n("title",{textStyle:"heading-3",...p(24,20,-.02,1.5)},{role:"heading"}),{kind:"block",type:"Text",props:{...l,_partStyles:{text:a(17,16,1.6)}},box:[["body","text",(e,t)=>c(t)[0]??""]],when:(e,t)=>c(t).length>0},{kind:"block",type:"Text",props:{...s,_partStyles:{text:a(17,16,1.6,{paragraphSpacing:14})}},box:[["body","text",(e,t)=>c(t).slice(1).join(`
1
+ import{resolveSectionBackground as E,THEME_SECTION_BG as I}from"../../../../../format/lib/content/section-background.js";import{SECTION_BG_BUILT_IN as P}from"../../../../../format/lib/document/blocks/general/section-bg-built-in.js";import{BUTTON as m,DIM as s,bandAccent as B,bandIndex as N,bandWrites as O,fillNoBoxHolds as H,ownFill as M,DROP_COMMON as b,DROP_SIDE_PADDING as u,INNER_BOX as r,SAME_KEYS as y,SECTION_BOX as k,lineBorder as x,TEXT as l,innerPad as T,innerPadKeys as w}from"./section-to-box-row-parts.js";import{splitParagraphs as A}from"../../../../components/goldPhrases.js";import{TIMELINE_YEAR_BOX as C,TIMELINE_YEAR_HEAD as f}from"../../../../../format/lib/sections/timeline-year-shape.js";import{boxPadding as v}from"../../../../../format/lib/document/seed-parts.js";const D="jetbrains-mono",S="space-grotesk",i=(e,t,n={})=>({textStyle:"body-5",font:D,size:e,sizePhone:e,letterSpacing:t,lineHeight:1.5,weight:400,...n}),p=(e,t,n,d)=>({font:S,size:e,sizePhone:t,case:"upper",weight:500,letterSpacing:n,lineHeight:d}),a=(e,t,n,d={})=>({textStyle:"body-1",font:S,size:e,sizePhone:t,weight:400,case:"none",lineHeight:n,...d}),o=(e,t,n={})=>({kind:"text",key:e,props:l,style:t,...n}),_=(e,t)=>t?.future===!0,c=e=>A(typeof e?.body=="string"?e.body:""),g=e=>E(typeof e.background=="string"?e.background:void 0,P.TimelineTrack),h=e=>g(e)===I?e:{...e,background:"transparent"},R={name:"Milestone Timeline",skip:e=>H(g(e)),boxProps:(e,t)=>{const n=N(h(e),t);return{...k,direction:"column",gap:60,sectionBorder:{bottom:1},...T(e,"TimelineTrack"),...M(g(e),e,t),...n>=0?{sectionAccent:n}:{}}},box:[...y.filter(e=>e!=="sectionAccent"),["sectionAccent","sectionAccent",(e,t,n)=>B(e,h(t),n)],...w("TimelineTrack")],parts:[{kind:"group",name:"Heading",props:{...r,direction:"row",align:"end",justify:"between",gap:40,share:"content",sectionPaddingBottom:32,sectionBorder:{bottom:1}},parts:[{kind:"group",name:"Title",props:{...r,direction:"row",align:"end",gap:40,share:"content"},parts:[o("eyebrow",i(13,.3,{case:"upper",color:"accent",padding:8}),{role:"eyebrow"}),o("title",{textStyle:"heading-2",...p(79,40,-.03,1)},{role:"heading"})]},o("intro",a(14,14,1.5),{props:{...s,align:"right",maxWidth:360}})]},{kind:"group",name:"Years",props:{...r,direction:"row",share:"equal",gap:0,line:!0},parts:[{kind:"list",key:"entries",name:"Year",props:{...r,...C},item:e=>({props:e.future===!0?{upcoming:!0}:{}}),parts:[{kind:"group",name:f.name,props:{...r,...f},parts:[o("date",i(13,.22,{color:"accent"}),{when:(e,t)=>!_(e,t)}),o("date",i(13,.22,{color:"labels"}),{when:_}),o("title",{textStyle:"heading-3",...p(20,20,-.02,1.1)},{role:"heading"})]},o("blurb",a(13,13,1.55),{props:s})]}]},{kind:"button",key:"ctaText",href:"ctaHref",variant:"ghost",props:(e,t)=>({...m,align:"right",...x(e,t)}),style:i(13,.3,{case:"upper"})}],site:(e,t)=>O({props:h(e.props)},t),drop:{...b,...u,background:"another colour is the Box's Fill, or a skip if no Fill holds it; the band is the Box's theme: the site's band preset (`sectionAccent`), or a declared band-preset write (`lib/theme` `bandPresetIndex`)",headPlacement:"needs a row per head placement: an own-box Milestone Timeline draws no head (its words sit in a Section Header above it), the row always draws the head"}},Y={name:"Story Timeline",skip:e=>{const t=typeof e.layout=="string"?e.layout:"split";return t==="split"?void 0:`display "${t}": not converted (0 live pages; Spine and Alternating are not offered, a Track story is not stored anywhere)`},boxProps:e=>({...k,direction:"row",share:"twoThree",gap:80,align:"start",...T(e,"Timeline")}),box:[...y,...w("Timeline")],parts:[{kind:"group",name:"Heading",props:{...r,gap:24},parts:[o("eyebrow",i(12,.3,{case:"upper",color:"accent"}),{role:"eyebrow"}),o("title",{textStyle:"heading-2",...p(72,40,-.03,.94)},{role:"heading"}),o("intro",a(14,14,1.6),{props:{...s,maxWidth:360}}),{kind:"group",name:"Picture",keepEmpty:!0,box:[["imageSrc","bgImage"]],props:{...r,sectionBorder:{top:1,right:1,bottom:1,left:1},darken:75,darkenStyle:"bottom",placement:"bottom-center",sectionHeightMode:"fixed",sectionHeightValue:667,sectionHeightUnit:"px",sectionHeightModePhone:"fixed",sectionHeightValuePhone:419,sectionHeightUnitPhone:"px",...v(12,16)},when:e=>typeof e.imageSrc=="string"&&e.imageSrc.trim()!=="",parts:[{kind:"group",name:"Caption",props:{...r,direction:"row",justify:"between",align:"center",gap:12,share:"content",phoneRow:2},parts:[o("imageCaption",i(11,.24,{case:"upper",color:"text"})),o("imageMeta",i(11,.24,{case:"upper",color:"accent"}),{props:{...l,align:"right"}})]}]},{kind:"button",key:"ctaText",href:"ctaHref",variant:"ghost",props:(e,t)=>({...m,...x(e,t)}),style:i(13,.3,{case:"upper"})}]},{kind:"group",name:"Chapters",props:{...r,gap:48,line:!1},parts:[{kind:"list",key:"entries",name:"Chapter",props:{...r,direction:"row",gap:24,share:"biggerRight",align:"start"},parts:[o("date",i(13,.24,{color:"accent"})),{kind:"group",name:"Words",props:{...r,gap:14},parts:[o("title",{textStyle:"heading-3",...p(24,20,-.02,1.5)},{role:"heading"}),{kind:"block",type:"Text",props:{...l,_partStyles:{text:a(17,16,1.6)}},box:[["body","text",(e,t)=>c(t)[0]??""]],when:(e,t)=>c(t).length>0},{kind:"block",type:"Text",props:{...s,_partStyles:{text:a(17,16,1.6,{paragraphSpacing:14})}},box:[["body","text",(e,t)=>c(t).slice(1).join(`
2
2
 
3
- `)]],when:(e,t)=>c(t).length>1}]}]}]}],drop:{...h,...m,layout:"Split is the only display converted (see skip); the Box's own arrangement replaces it"}},D={TimelineTrack:H,Timeline:M};export{D as TIMELINE_SECTION_TO_BOX};
3
+ `)]],when:(e,t)=>c(t).length>1}]}]}]}],drop:{...b,...u,layout:"Split is the only display converted (see skip); the Box's own arrangement replaces it"}},G={TimelineTrack:R,Timeline:Y};export{G as TIMELINE_SECTION_TO_BOX};