efficient-web-builder 64.0.0 → 66.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.
- package/CHANGELOG.md +94 -0
- package/dist/editor/components/AnchorField.js +1 -1
- package/dist/editor/components/CardShadowField.js +1 -1
- package/dist/editor/components/PagesPanel.js +1 -1
- package/dist/editor/components/SectionEditor.js +1 -1
- package/dist/editor/components/WebsitePreviewButton.js +1 -1
- package/dist/editor/components/storefront-editor.css +16 -24
- package/dist/editor/components/usePreviewHref.js +1 -1
- package/dist/editor/lib/animation/entrance-fields.js +1 -1
- package/dist/editor/lib/animation/scroll-fields.js +1 -1
- package/dist/editor/lib/animation/view-rows.d.ts +20 -0
- package/dist/editor/lib/animation/view-rows.js +1 -0
- package/dist/editor/lib/document/blocks/general/Banner/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/ButtonBlock/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Divider/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/FAQ/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Flex/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Footprint/fields.d.ts +0 -1
- package/dist/editor/lib/document/blocks/general/Footprint/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/HeroGroup/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/ImageBlock/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/LogoBlock/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/ProcessSteps/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/SectionHeader/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/Text/fields.js +1 -1
- package/dist/editor/lib/document/blocks/general/index.d.ts +2 -2
- package/dist/editor/lib/document/box-fields.d.ts +2 -1
- package/dist/editor/lib/document/box-fields.js +1 -1
- package/dist/editor/lib/document/card-row-fields.d.ts +3 -0
- package/dist/editor/lib/document/card-row-fields.js +1 -1
- package/dist/editor/lib/document/controls.d.ts +12 -10
- package/dist/editor/lib/document/controls.js +1 -1
- package/dist/editor/lib/document/field-groups.d.ts +0 -3
- package/dist/editor/lib/document/field-groups.js +1 -1
- package/dist/editor/lib/document/part-motion-canvas.d.ts +2 -2
- package/dist/editor/lib/document/part-motion-canvas.js +1 -1
- package/dist/editor/lib/document/passes/inspector.js +1 -1
- package/dist/editor/lib/sections/section-dry-run.d.ts +1 -20
- package/dist/editor/lib/sections/section-dry-run.js +2 -2
- package/dist/editor/lib/sections/text-layouts.js +1 -1
- package/dist/format/lib/animation/entrance-keys.d.ts +8 -0
- package/dist/format/lib/animation/entrance-keys.js +1 -0
- package/dist/format/lib/animation/scroll.d.ts +5 -6
- package/dist/format/lib/animation/scroll.js +1 -1
- package/dist/format/lib/animation/views.d.ts +6 -0
- package/dist/format/lib/animation/views.js +1 -0
- package/dist/format/lib/content/block-sources.d.ts +3 -0
- package/dist/format/lib/content/block-sources.js +1 -1
- package/dist/format/lib/content/box-background.d.ts +1 -0
- package/dist/format/lib/content/box-background.js +1 -1
- package/dist/format/lib/content/box-link.d.ts +11 -0
- package/dist/format/lib/content/box-link.js +8 -8
- package/dist/format/lib/content/box-phone-place.d.ts +0 -2
- package/dist/format/lib/content/box-phone-place.js +1 -1
- package/dist/format/lib/content/box-side-space.js +1 -1
- package/dist/format/lib/content/card-image-shape.d.ts +5 -1
- package/dist/format/lib/content/card-image-shape.js +1 -1
- package/dist/format/lib/content/card-template.d.ts +1 -0
- package/dist/format/lib/content/card-template.js +1 -1
- package/dist/format/lib/content/contact.d.ts +0 -1
- package/dist/format/lib/content/contact.js +2 -2
- package/dist/format/lib/content/css-length.d.ts +1 -0
- package/dist/format/lib/content/css-length.js +1 -0
- package/dist/format/lib/content/page-width.d.ts +17 -1
- package/dist/format/lib/content/page-width.js +1 -1
- package/dist/format/lib/content/section-sticky.d.ts +28 -0
- package/dist/format/lib/content/section-sticky.js +1 -1
- package/dist/format/lib/document/blocks/general/Banner/meta.d.ts +5 -0
- package/dist/format/lib/document/blocks/general/Banner/meta.js +1 -1
- package/dist/format/lib/document/blocks/general/Footprint/card-seed.d.ts +2 -0
- package/dist/format/lib/document/blocks/general/Footprint/card-seed.js +1 -1
- package/dist/format/lib/document/blocks/general/Footprint/meta.js +2 -2
- package/dist/format/lib/document/blocks/general/ProcessSteps/column-seed.d.ts +5 -0
- package/dist/format/lib/document/blocks/general/ProcessSteps/column-seed.js +1 -0
- package/dist/format/lib/document/blocks/general/ProcessSteps/meta.js +1 -1
- package/dist/format/lib/document/blocks/general/SectionHeader/meta.d.ts +6 -0
- package/dist/format/lib/document/blocks/general/SectionHeader/meta.js +1 -1
- package/dist/format/lib/document/blocks/general/TitleWithButtons/meta.d.ts +2 -0
- package/dist/format/lib/document/blocks/general/TitleWithButtons/meta.js +2 -2
- package/dist/format/lib/document/media-drop.js +1 -1
- package/dist/format/lib/document/one-h1.d.ts +2 -0
- package/dist/format/lib/document/one-h1.js +1 -1
- package/dist/format/lib/document/passes/types.d.ts +2 -0
- package/dist/format/lib/document/renamed-props.d.ts +1 -0
- package/dist/format/lib/document/renamed-props.js +1 -1
- package/dist/format/lib/document/section-catalog.js +10 -2
- package/dist/format/lib/document/section-descriptions.js +1 -1
- package/dist/format/lib/editor-words-catalogue.d.ts +16 -0
- package/dist/format/lib/editor-words-catalogue.js +4 -4
- package/dist/format/lib/editor-words-kept.js +1 -1
- package/dist/format/lib/fit-words.js +4 -1
- package/dist/format/lib/links/page-link-rules.d.ts +0 -1
- package/dist/format/lib/links/page-link-rules.js +1 -1
- package/dist/format/lib/markup.d.ts +1 -0
- package/dist/format/lib/markup.js +2 -2
- package/dist/format/lib/sections/hero-single-to-hero.js +1 -1
- package/dist/format/lib/sections/section-presets.js +1 -1
- package/dist/format/lib/sections/timeline-year-shape.js +1 -1
- package/dist/format/lib/source-rules/editor-words.js +1 -1
- package/dist/format/lib/source-rules/motion-vars-from-the-shell.d.ts +6 -0
- package/dist/format/lib/source-rules/motion-vars-from-the-shell.js +4 -0
- package/dist/format/lib/source-rules/one-length-control.d.ts +18 -0
- package/dist/format/lib/source-rules/one-length-control.js +16 -0
- package/dist/format/lib/source-rules/support/label-extraction.js +3 -3
- package/dist/format/lib/theme.d.ts +0 -1
- package/dist/format/lib/theme.js +3 -3
- package/dist/format/lib/web-runtime.d.ts +2 -0
- package/dist/format/lib/web-runtime.js +1 -1
- package/dist/render/components/BlockFrame.d.ts +3 -3
- package/dist/render/components/BlockFrame.js +1 -1
- package/dist/render/components/Breadcrumb.js +1 -1
- package/dist/render/components/Btn.js +1 -1
- package/dist/render/components/CardRowContext.d.ts +7 -1
- package/dist/render/components/CardRowContext.js +1 -1
- package/dist/render/components/CategoryBar.js +1 -1
- package/dist/render/components/ContactLocations.js +2 -2
- package/dist/render/components/DealerFinder.d.ts +4 -1
- package/dist/render/components/DealerFinder.js +1 -1
- package/dist/render/components/Divider.js +1 -1
- package/dist/render/components/DocMasthead.js +1 -1
- package/dist/render/components/DocTabs.js +1 -1
- package/dist/render/components/FeaturedCover.js +1 -1
- package/dist/render/components/Flex.js +1 -1
- package/dist/render/components/Footprint.d.ts +5 -3
- package/dist/render/components/Footprint.js +1 -1
- package/dist/render/components/Heading.d.ts +0 -1
- package/dist/render/components/Heading.js +1 -1
- package/dist/render/components/HeroPictures.d.ts +2 -5
- package/dist/render/components/HeroPictures.js +1 -1
- package/dist/render/components/ImageBlock.js +1 -1
- package/dist/render/components/KeyFeatures.js +1 -1
- package/dist/render/components/LocationMap.js +1 -1
- package/dist/render/components/LogoBlock.js +1 -1
- package/dist/render/components/Logos.d.ts +1 -2
- package/dist/render/components/Logos.js +1 -1
- package/dist/render/components/LongRead.js +1 -1
- package/dist/render/components/PictureZoom.js +1 -1
- package/dist/render/components/PostCard.js +1 -1
- package/dist/render/components/ProcessSteps.d.ts +2 -1
- package/dist/render/components/ProcessSteps.js +1 -1
- package/dist/render/components/PublishedPartStylesContext.js +1 -1
- package/dist/render/components/SectionAnimation.d.ts +8 -16
- package/dist/render/components/SectionAnimation.js +1 -1
- package/dist/render/components/SectionHeader.js +1 -1
- package/dist/render/components/SideListLayout.d.ts +4 -1
- package/dist/render/components/SideListLayout.js +1 -1
- package/dist/render/components/Split.js +1 -1
- package/dist/render/components/Text.d.ts +2 -1
- package/dist/render/components/Text.js +1 -1
- package/dist/render/components/Timeline.js +1 -1
- package/dist/render/components/TimelineRail.d.ts +11 -3
- package/dist/render/components/TimelineRail.js +1 -1
- package/dist/render/components/TimelineTrack.js +1 -1
- package/dist/render/components/TitleWithButtons.js +1 -1
- package/dist/render/components/goldPhrases.js +3 -3
- package/dist/render/lib/animation/entrance.d.ts +6 -14
- package/dist/render/lib/animation/entrance.js +1 -1
- package/dist/render/lib/animation/part-motion.js +2 -2
- package/dist/render/lib/content/block-size.d.ts +5 -1
- package/dist/render/lib/content/block-size.js +1 -1
- package/dist/render/lib/content/box-stack-line.d.ts +1 -1
- package/dist/render/lib/content/box-stack-line.js +1 -1
- package/dist/render/lib/content/button-look.d.ts +2 -0
- package/dist/render/lib/content/button-look.js +1 -1
- package/dist/render/lib/content/section-edge.js +1 -1
- package/dist/render/lib/content/section-padding.d.ts +5 -2
- package/dist/render/lib/content/section-padding.js +1 -1
- package/dist/render/lib/dealer-source.d.ts +6 -2
- package/dist/render/lib/dealer-source.js +1 -1
- package/dist/render/lib/document/blocks/general/Banner/render.js +1 -1
- package/dist/render/lib/document/blocks/general/CardList/render.js +1 -1
- package/dist/render/lib/document/blocks/general/Footprint/render.js +1 -1
- package/dist/render/lib/document/blocks/general/ImageBlock/render.js +1 -1
- package/dist/render/lib/document/blocks/general/SectionHeader/render.js +1 -1
- package/dist/render/lib/document/blocks/general/Text/render.js +1 -1
- package/dist/render/lib/document/blocks/general/TitleWithButtons/render.js +1 -1
- package/dist/render/lib/document/blocks/general/section-head-looks.d.ts +2 -0
- package/dist/render/lib/document/blocks/general/section-head-looks.js +2 -2
- package/dist/render/lib/document/blocks/general/section-to-box-row-parts.js +1 -1
- package/dist/render/lib/document/blocks/general/section-to-box-rows-cards.js +1 -1
- package/dist/render/lib/document/blocks/general/section-to-box-rows-editorial.js +1 -1
- package/dist/render/lib/document/blocks/general/section-to-box-rows-head.d.ts +2 -2
- package/dist/render/lib/document/blocks/general/section-to-box-rows-head.js +1 -1
- package/dist/render/lib/document/blocks/general/section-to-box-rows-locations.js +1 -1
- package/dist/render/lib/document/blocks/general/section-to-box-rows-pageheader.js +1 -1
- package/dist/render/lib/document/blocks/general/section-to-box-rows-stats.js +1 -1
- package/dist/render/lib/document/blocks/general/section-to-box-rows-tabbar.d.ts +3 -0
- package/dist/render/lib/document/blocks/general/section-to-box-rows-tabbar.js +1 -0
- package/dist/render/lib/document/blocks/general/section-to-box-rows-timeline.js +2 -2
- package/dist/render/lib/document/blocks/general/section-to-box-rows.d.ts +3 -0
- package/dist/render/lib/document/blocks/general/section-to-box-rows.js +1 -1
- package/dist/render/lib/document/card-press-titles.d.ts +10 -0
- package/dist/render/lib/document/card-press-titles.js +1 -0
- package/dist/render/lib/document/part-styles.d.ts +1 -0
- package/dist/render/lib/document/passes/section-animation.js +1 -1
- package/dist/render/lib/document/passes/section-height.js +1 -1
- package/dist/render/lib/document/passes/section-padding.js +1 -1
- package/dist/render/lib/document/passes/section-sticky.js +1 -1
- package/dist/render/lib/document/published-passes.js +1 -1
- package/dist/render/lib/document/slot-specs.js +1 -1
- package/dist/render/lib/sections/section-to-box.d.ts +0 -15
- package/dist/render/lib/sections/section-to-box.js +1 -1
- package/dist/render/lib/site-runtime.d.ts +4 -1
- package/dist/render/lib/site-runtime.js +1 -1
- package/dist/render/lib/text-styles/site-text-styles.js +2 -2
- package/package.json +5 -5
- package/dist/editor/components/TemplateFieldRow.d.ts +0 -11
- package/dist/editor/components/TemplateFieldRow.js +0 -1
- package/dist/editor/lib/document/panel-heading-scope.d.ts +0 -8
- package/dist/editor/lib/document/panel-heading-scope.js +0 -1
- package/dist/editor/lib/document/template-field.d.ts +0 -13
- package/dist/editor/lib/document/template-field.js +0 -1
- package/dist/format/lib/canvas-accent.d.ts +0 -1
- package/dist/format/lib/canvas-accent.js +0 -1
- package/dist/format/lib/source-rules/padding-units-declared.d.ts +0 -2
- package/dist/format/lib/source-rules/padding-units-declared.js +0 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,99 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 66.0.0 - 2026-11-10
|
|
4
|
+
|
|
5
|
+
From main at `a7a035c9`: #668, #673, #674, #676, #669, #678, #677, #679, #680, #681, #682, #432, #683, #685, #684, #687, #686. A MAJOR: #668, #674, #677, #679, #682, #684, #685 and #686 have `!` (removed exports, removed props, narrowed peers). Peers move: `efficient-easel` `^30.1.0` -> `^33.0.0` (#668 to `^31.3.0`, then #682), `efficient-shell` `^12.22.0` -> `^12.30.0` (#682). One stored key is moved on read: the Locations Map's `source` (#679). No stored page needs a data move.
|
|
6
|
+
|
|
7
|
+
**BREAKING (#668):** the peer `efficient-easel` moves to `^31.3.0` (was `^30.1.0`): the length unit table (`LENGTH_KIND_UNITS`) is new in easel 31.3.0. Removed: `PADDING_UNITS` (`editor/lib/document/box-fields`; the table is now `LENGTH_UNITS_TABLE`, read from easel) and the module `format/lib/source-rules/padding-units-declared` (replaced by `format/lib/source-rules/one-length-control`).
|
|
8
|
+
|
|
9
|
+
**BREAKING (#674):** removed `normalizeShadowColor` (`format/lib/theme`; use `pictureShadowColor` from `efficient-easel/screen/lib/document/shadow-values`) and the whole module `format/lib/canvas-accent` (`CANVAS_ACCENT`; write `var(--es-accent)`). `DEFAULT_SHADOW_COLOR` stays.
|
|
10
|
+
|
|
11
|
+
**BREAKING (#677):** removed `bodyStyleRows`, `BodyStyleRow`, `nearestTextStyle`, `BODY_STYLE_PX_AT_DEFAULTS` and the `restyled` field of `DryRunNode` (`editor/lib/sections/section-dry-run`); `Restyled`, the `restyled` field of `SectionConversion` and `was` on a text `PartRow` (`lib/sections/section-to-box`); `headingDefaultPx` (`components/Heading`).
|
|
12
|
+
|
|
13
|
+
**BREAKING (#679):** removed `footprintBlockSource` (editor `lib/document/blocks/general/Footprint/fields`), `FootprintSource` and `parseFootprintSource` (render `lib/dealer-source`). The `Footprint` component no longer takes `source`; it takes `dealers?: boolean`. A stored `source` moves to `dataSource` on read (`SOURCE_PROPS_MOVED`): `"dealers"` or a source key fills an empty `dataSource`; `"typed"` and any other value read as Manual; `source` is dropped.
|
|
14
|
+
|
|
15
|
+
**BREAKING (#682):** the peers narrow: `efficient-easel` `^31.3.0` -> `^33.0.0`, `efficient-shell` `^12.22.0` -> `^12.30.0` (easel 33.0.0 holds `SITE_SIDE` and needs shell 12.30.0). Removed `SITE_COLUMN_EDGE_NARROW` (`format/lib/content/page-width`). `WEBSITE_MEDIA_DROP` answers easel's `pictureOf` + `kinds`, not `takes` + `replace` (easel 32 removed them). Behaviour: a file dropped on an empty Box, Hero or Hero slide with no picture now lands between its blocks, not on the node.
|
|
16
|
+
|
|
17
|
+
**BREAKING (#685):** removed from `editor/lib/document/controls`: `checkbox`, `sectionBorderField`, `templateField`. Removed modules `editor/components/TemplateFieldRow` and `editor/lib/document/template-field` (`planTemplateRow`, `templateWrite`, types `TemplateRender`, `TemplateSelector`, `TemplatePlan`). Removed `slugifyAnchor` (`editor/lib/links/page-link-rules`; use `slugify` from `efficient-shell/format`). The `.sf-checkbox` style is gone.
|
|
18
|
+
|
|
19
|
+
**BREAKING (#684):** removed `BOX_PHONE_PAD_LINE` (`lib/content/box-stack-line`; read `BOX_PHONE_PAD_AT_EDGE`), `BOX_PHONE_PLACE_CANVAS_TABLET_CLASS` and the `tabletKeepsRow` option of `boxPhoneCell` (`lib/content/box-phone-place`; use `BOX_PHONE_PLACE_CANVAS_CLASS`), `BOUND_CARD_MEDIA_FIELD_KEYS` and `CARD_STYLE_FIELD_KEYS` (`lib/document/field-groups`; use `CARD_MEDIA_FIELD_KEYS` / the keys of `cardStyleFields()`), and the `mark` prop of `LogoWallMark` (`components/Logos`; pass `kind`).
|
|
20
|
+
|
|
21
|
+
**BREAKING (#686):** removed `slugifyGroupId` (`format/lib/content/contact`; use `slugify` from `efficient-shell/format`), `GroupLabel` (`editor/lib/document/controls`; use `PanelBand`), the whole module `editor/lib/document/panel-heading-scope` (`useFoldHeadingLevel`, `FoldHeadingScope`, `PANEL_NAME_LEVEL`, `FOLD_TOP_LEVEL`) and `foldTopTier` (`editor/lib/document/field-groups`). Every `@deprecated` note now gives a delete day.
|
|
22
|
+
|
|
23
|
+
**For hosts:**
|
|
24
|
+
- Install efficient-easel 33.0.0 or later and efficient-shell 12.30.0 or later with this release (#668, #682).
|
|
25
|
+
- efficient-storefront: merge eff-erp/efficient-storefront#1943 (merged as `1acc1656`) before it takes this release. Its `scripts/test-editor-heading-levels.tsx` imported `panel-heading-scope` (#686).
|
|
26
|
+
- efficient-storefront: `scripts/test-section-presets.tsx:456-462` pins the Manifesto words Box sides at 40; it must expect `"site"` (#682).
|
|
27
|
+
- The Tab Bar's tabs look needs efficient-storefront-blocks 0.95.0 or later in the host (#673).
|
|
28
|
+
- A host with a block allow list must also allow Box, Text, ButtonBlock and ImageBlock to keep the Section Header, Call-to-Action Heading, Editorial Text, Lead Text and Banner presses (#677).
|
|
29
|
+
- storefront-blocks, in its bump to this release:
|
|
30
|
+
- `scripts/test-block-sets.tsx` §4 and §5 name the blocks the five text presses lay down and their new Layouts group (#677).
|
|
31
|
+
- Delete `Footprint.source` from `scripts/test-segmented-controls.tsx`, `scripts/section-style-baseline.tsx` and `scripts/test-animation-tab.tsx:490`. Run `scripts/test-editor-offerings.ts`: `blockSources()` now also holds the builder's own `dealers` source (#679).
|
|
32
|
+
- Re-record, on purpose, the stored-bytes fixtures that hold a markup web link: such a link now draws through the site link (`href` after `class`, `target`/`rel` added) (#678).
|
|
33
|
+
- `scripts/test-listing-section-to-box.tsx` test 9 must assert that a fresh "List" press reaches the Box row. Keep the listing's inline head branch: 2 stored listings still draw through it. Import `pageTitleTag` / `pageTitleDemoted` from `format/lib/document/one-h1` in place of its two private copies (#676).
|
|
34
|
+
- `globals.css:3300-3304`: rewrite the stale comment about side padding (no CSS change) (#682).
|
|
35
|
+
- A block that calls `CardTemplateRows` with `actions` hands `pressTitles`, or it keeps the whole-copy name (#687).
|
|
36
|
+
- efficient-admin-portal: nothing on main. Its paused media drag branch must port `EMAIL_MEDIA_DROP` to `pictureOf` + `kinds` when it resumes (#682).
|
|
37
|
+
|
|
38
|
+
### Added
|
|
39
|
+
|
|
40
|
+
- **Every length row takes its kind** (#668): Fixed width, Min width, Content width (px, % or vw, per view), Min font size (px or vw), Button Border and Corners (px or vw), and Card image get the unit menu inside their number box, from easel's one unit table. Section height is one row (the separate Unit row is gone). New: `lengthUnitFields`, `LENGTH_UNITS_TABLE`, `heightLayersAt`, `cardImageFields`, `CARD_IMAGE_UNIT_KEY`, `BLOCK_LENGTH_KEYS`, `blockLengthUnitKey`, `cssLengthOf` (`format/lib/content/css-length`), `Slider` `units?`. A number with no unit key is px, so stored pages draw the same.
|
|
41
|
+
- **Tab Bar** (#673): "Document Tabs" becomes the Layouts row Tab Bar, pressed as a pinned Box (Stays above on) that holds one Menu block in Tabs style. Category Bar is retired into it: set the Menu's content to Blog categories. New `BLOG_CATEGORIES_SOURCE`.
|
|
42
|
+
- **The product listing presses through its host Box row** (#676): `AlloyWheelsListing` joins `HOST_PRESS_TYPES`. New `pageTitleTag(level)` and `pageTitleDemoted(props)` (`lib/document/one-h1`), the one title level rule.
|
|
43
|
+
- **Dealer rows draw through the card list action** (#669): the Locations Map in dealers mode draws each dealer as a card template copy, with the site-wide picked look. Text and Image get "Link from"; Text gets an `href` prop. New `footprintDealerCardSeed`, `withFootprintListTemplate`, `dealerCardRow`, `dealerPressLabel`, `cardRowLinkField`, `linkOpensElsewhere`, `linkTargetAttrs`.
|
|
44
|
+
- **The five text sections press as Boxes** (#677): Section Header, Call-to-Action Heading, Editorial Text, Lead Text and Banner. The last four move to the Layouts group. Stored nodes still draw through their old components.
|
|
45
|
+
- **Office content on the Locations Map** (#679): the map reads its rows from `dataSource` (Manual, Group offices, Dealers), and "Shows" offers only the fields of that source. The builder declares `dealers` itself (`DEALERS_BLOCK_SOURCE`). New `DEALERS_SOURCE`, `DEALER_FIELDS`, `SOURCE_PROPS_MOVED`, `isBlockSourceKey`.
|
|
46
|
+
- **Image & Text Columns press lays down a Box** (#680): the head as Text parts over three column Boxes (Image, heading, body) in the `boxes` slot. New `ProcessSteps/column-seed` (`processColumnSeed`, `processColumnSeeds`, `PROCESS_STEPS_SEED_COUNT`, `PROCESS_COLUMNS_SLOT`) and `withAccentItalic`.
|
|
47
|
+
- **Logo "Link from" in card templates** (#681). New `rowLinkText`, the one reading of a row link.
|
|
48
|
+
- **A padding side can follow the site Side space** (#682): a Left or Right side may store `"site"` (easel `SITE_SIDE`). Fresh presses and the Manifesto preset write it. New `siteSideRoom` (`page-width`) and `padSideValue` (`section-padding`); `padSideAttrs` takes an optional `sideSpace`.
|
|
49
|
+
- **A dropped file is refused where it would not show** (#432): a video, and a picture drawn from row data (a card Box or a card-template Image), refuse a drop from the Media Library. New `boxNamesRowPicture` (`format/lib/content/box-background`).
|
|
50
|
+
- New source guards: `scripts/test-deprecated-has-date.ts` refuses a `@deprecated` note with no delete day (#686); the shell ui-check `colour` kind now reads `.css` too (#674).
|
|
51
|
+
|
|
52
|
+
### Changed
|
|
53
|
+
|
|
54
|
+
- **One new-tab rule for every link** (#678): `SiteLink` takes `newTab?: "auto" | true`. A link to another website now opens in a new tab on Button, Image, Box, Logo, Text inline links and the sections that draw a typed link; a link to the shop's own host stays in the same tab after hydration. New `useSiteHost`, `SiteLinkNewTab`, `NEW_TAB_ATTRS`, `siteLinkDraws`, `isWebAddress`, `shopOrigin`, `shopHost`.
|
|
55
|
+
- The Card shadow row takes its miniatures from easel's `SHADOW_PREVIEW` (#674).
|
|
56
|
+
- A "Link from" row with nothing to choose is not drawn (#681).
|
|
57
|
+
- Every remaining `@deprecated` note gives a delete day (#684, #686).
|
|
58
|
+
|
|
59
|
+
### Removed
|
|
60
|
+
|
|
61
|
+
- The exports, props and modules named under BREAKING above (#668, #674, #677, #679, #682, #684, #685, #686).
|
|
62
|
+
- The Section height Unit row (#668) and the Locations Map's own Source row (#679).
|
|
63
|
+
|
|
64
|
+
### Fixed
|
|
65
|
+
|
|
66
|
+
- **A press button is named by its row title part** (#687): a screen reader no longer reads a link inside the copy twice. A Card list item or a Locations Map office button gets `aria-labelledby` its title Text. New module `lib/document/card-press-titles` (`markCardPressTitles`, `cardPressTitlesOf`, `CARD_PRESS_TITLES_PROP`, `CARD_PRESS_TITLE_PROP`, `CardPressTitle`), `CardPressTitled`, optional `pressTitles` on `CardTemplateRows` and `Footprint`.
|
|
67
|
+
- **Fresh editorial presses change at 1100** like the old sections (#683): the press stores `stackBelow` at 1100 on its outer Box and head rows; the Milestone Timeline's years stack with a left rail below 1100. New `BOX_DESKTOP_LINE`, `EDITORIAL_LINE`, `BoxRail` `desktopLine?`.
|
|
68
|
+
|
|
69
|
+
## 65.0.0 - 2026-11-09
|
|
70
|
+
|
|
71
|
+
From main at `8a7ac743`: #667, #666, #671, #670. A MAJOR: #667 removes exports and #671 narrows the `efficient-shell` peer (#670 also has `!`; its own change is additive). `efficient-easel` `^30.1.0` does not change. No stored key or value moves.
|
|
72
|
+
|
|
73
|
+
**BREAKING (#671):** the peer `efficient-shell` moves to `^12.22.0` (was `^12.18.0`): the per-view stick form (`pinStickVars`, `PIN_STICK_VAR`, `PIN_TRACK_POSITION_VAR`) is new in 12.22.0.
|
|
74
|
+
|
|
75
|
+
**BREAKING (#667):** removed exports (vs 64.0.0): `usePhoneWidth` (`render/components/SectionAnimation`), `EntranceView` (`render/lib/animation/entrance`), `scrollViewKey` and `ScrollView` (`format/lib/animation/scroll`; use `viewKey` and `MotionView` from `lib/animation/views`). Changed signatures: `SectionAnimation` props `desktop`/`phone` -> `views: EntranceViews`; `entranceReplay.seed(views)` and `.next(seen, views, view)`; `SeenEntrance` gains `tablet`; `entranceDrawn` returns `EntranceViews | null` with `tablet`; `entranceOf(props, MotionView)`; `PublishedPartMotion.entrance` gains `tablet`; `useViewWidth` returns `MotionView`; `paintPartMotion` takes `MotionView | boolean`; `heroPartEntrance` returns `Readonly<Record<MotionView, EntranceValue>> | null` (was `{ desktop; phone }`).
|
|
76
|
+
|
|
77
|
+
**For hosts:**
|
|
78
|
+
- Install efficient-shell 12.22.0 or later with this release (#671).
|
|
79
|
+
- The Entrance has tablet keys: `entranceTablet`, `entranceFromTablet`, `entranceDurationTablet`, `entranceDelayTablet` (#667). 0 stored pages need a move; an empty tablet follows the desktop.
|
|
80
|
+
- storefront-blocks: map `--sf-pin-stick` and `--sf-pin-track-position` in the `[data-motion-pin]` rule (base, tablet, phone; phone falls back to desktop; no default), as `--sf-pin-on` / `--sf-pin-length` are mapped (#671). Until then a page draws as on 64.
|
|
81
|
+
- storefront-blocks: its bump to this release updates `scripts/test-mockup-variant-fields.ts:107` to spread `ENTRANCE_STORE_KEYS` (#667).
|
|
82
|
+
- storefront-blocks: `scripts/section-style-baseline.tsx` reads `Object.keys(stickFields())`, which now also holds `stickAbove`: re-run that baseline in the bump PR (#670).
|
|
83
|
+
- The storefront keeps the #651 hold (the `ThemeLightInkProvider` mount).
|
|
84
|
+
|
|
85
|
+
### Added
|
|
86
|
+
|
|
87
|
+
- **Pin stops at** (#666): a pinned section or card can stop at the screen top (`stickTopStop: "screen"`) or under the header (unset, default). One key for every view. New `SECTION_PIN_KEYS`, the one list of pin keys a conversion carries.
|
|
88
|
+
- **The Entrance has a tablet value** (#667), on the same view machinery as Scroll: new modules `lib/animation/views` (`MOTION_VIEWS`, `MotionView`, `viewKey`, `viewStoreKeys`, `followViews`, `followedIn`), `lib/animation/view-rows` (`viewTileRows`, `followedViewRows`, `viewRows`) and `lib/animation/entrance-keys` (`ENTRANCE_STORE_KEYS`); `entranceViews`, `EntranceViews`.
|
|
89
|
+
- **A view with Screens 0 draws the stick look in a track** (#671): `SECTION_PIN_VARS` gets `stick` and `trackPosition`. New source rule `format/lib/source-rules/motion-vars-from-the-shell` fails any `--motion-` name typed in web-builder code.
|
|
90
|
+
|
|
91
|
+
- **Stays above** (#670): a pinned Box or section (not a card) can stay painted above the sections after it. New key `stickAbove` (`SECTION_PIN_ABOVE_KEY`; only `true` is stored; one value for every view), in `SECTION_PIN_KEYS`. On, the pin draws the shell's stick form with `pinAttrs(value, "stick", { above: true })` (efficient-shell 12.22.0 holds the mark and its z rule) and the Screens rows hide. 0 stored nodes move.
|
|
92
|
+
|
|
93
|
+
### Changed
|
|
94
|
+
|
|
95
|
+
- The Entrance and Scroll rows share one builder (#667, #671); `PictureZoom` reads `SCROLL_ZOOM_VAR` from the shell (#671).
|
|
96
|
+
|
|
3
97
|
## 64.0.0 - 2026-11-09
|
|
4
98
|
|
|
5
99
|
From main at `283356c0`: #598, #661, #663. A MAJOR: #598 has `!` (8 exports removed, one prop removed). Peers do not move: `efficient-easel` `^30.1.0`, `efficient-shell` `^12.18.0` (every shell name these PRs import is in 12.18.0). No stored key or value moves.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{jsx as n,Fragment as
|
|
1
|
+
"use client";import{jsx as n,Fragment as p,jsxs as m}from"react/jsx-runtime";import{useContext as d,useEffect as u,useId as g,useState as h}from"react";import{SettingsField as x,SettingsSwitch as S}from"efficient-easel/panel";import{AnchorIcon as k}from"efficient-easel/icons";import{ScreenDocumentContext as b}from"efficient-easel/screen/components/ScreenDocumentContext";import{Snippet as I}from"efficient-shell/ui";import{say as f}from"../../format/lib/editor-words.js";import{slugify as j}from"efficient-shell/format";import{anchorPath as A}from"../../format/lib/links/page-link-rules.js";import{shopOrigin as F}from"../../format/lib/web-runtime.js";import{readHidable as N}from"efficient-easel/draw";function O({value:i,onChange:o,nameBox:c}){const r=N(i).text,[l,a]=h(!1),e=l||r.trim()!=="",t=g();return m(p,{children:[n(x,{label:f("Add an anchor"),labelId:t,icon:n(k,{}),action:n(S,{checked:e,ariaLabelledBy:t,onChange:s=>{a(s),!s&&r!==""&&o("")}})}),e&&c(i,o),e&&n(y,{name:r})]})}function y({name:i}){const o=d(b),c=o?.templateId?"":o?.currentSlug??"",[r,l]=h("");u(()=>l(F()),[]);const a=j(i);if(!a||!c)return null;const e=`${r}${A(c,a)}`,t=e.replace(/^https?:\/\//,""),s=t.lastIndexOf("#");return n("div",{className:"sf-anchor-link",children:n(I,{value:e,label:f("link"),size:"sm",children:m("span",{className:"sf-anchor-link-text",children:[n("span",{className:"sf-anchor-link-path",children:t.slice(0,s)}),n("span",{className:"sf-anchor-link-hash",children:t.slice(s)})]})})})}export{O as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{jsx as o}from"react/jsx-runtime";import{SettingsDefaultReset as i,SettingsField as
|
|
1
|
+
"use client";import{jsx as o}from"react/jsx-runtime";import{SettingsDefaultReset as i,SettingsField as c}from"efficient-easel/panel";import{IconPicker as f}from"efficient-shell/ui";import{ShadowIcon as m}from"efficient-easel/icons";import{SHADOW_PREVIEW as p}from"efficient-easel/screen/lib/document/shadow-values";import{say as e,editorEaselWords as h}from"../../format/lib/editor-words.js";import{CARD_SHADOWS as u,DEFAULT_CARD_SHADOW as l}from"../../format/lib/theme.js";const a={none:"None",soft:"Soft",lifted:"Lifted"},S="Applies to cards — products, brands, journal entries and filter cells. Round things like swatches and status dots are never shadowed.";function w({value:s,onChange:r}){const n=s===null,d=s??l;return o(c,{label:e("Card shadow"),icon:o(m,{}),value:e(a[d]),changed:!n,action:o(i,{words:h()?.panel,label:e("Card shadow"),changed:!n,detail:e(a[l]),onReset:()=>r(null)}),hint:e(S),children:o(f,{label:e("Card shadow"),value:d,options:u.map(t=>({value:t,label:e(a[t]),icon:o("span",{className:"sf-shadow-chip border border-line bg-surface",style:{boxShadow:p[t]}})})),onChange:r})})}export{w as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{jsx as
|
|
1
|
+
"use client";import{jsx as n,Fragment as ne,jsxs as S}from"react/jsx-runtime";import{Fragment as Re,useEffect as De,useId as xe,useMemo as oe,useRef as Ne,useState as c}from"react";import{useScreenDocument as ae}from"efficient-easel/screen/components/ScreenDocumentContext";import{UiIcon as j}from"efficient-easel/draw/client";import ve from"efficient-easel/screen/components/SidePanelHead";import{useWebsiteName as Ee}from"./WebsiteSettingsPanel.js";import{InspectorIconButton as Oe}from"efficient-easel/chrome";import{Button as se,Dialog as Le,FormField as Be,Input as le,PopupMenu as Fe,PopupMenuItem as ie,toast as re}from"efficient-shell/ui";import{LayersTree as Me,TreeGroupLabel as _e,TreeRow as de,TreeRowAction as O}from"efficient-easel/tree";import{AddIcon as ze,DuplicateIcon as Ge,PageIcon as He,SettingsIcon as Te}from"efficient-easel/icons";import{PagesIcon as Ue}from"efficient-easel/rail";import{useEaselHost as We}from"efficient-easel/screen/lib/host";import{bucketEditorPageRows as je,DYNAMIC_PAGES_GROUP_KEY as qe,isDynamicPageRow as Ke,isPopupPageRow as Ye,MAIN_PAGES_GROUP as Je}from"../../format/lib/editor-page-rows.js";import{useEaselSession as ce}from"efficient-easel/screen/lib/session-context";import{holdPageRow as q,usePageRows as Qe}from"../lib/page-rows.js";import{say as t,sayCount as Ve}from"../../format/lib/editor-words.js";import{canDuplicatePage as Xe,DuplicatePageDialog as Ze,uniqueSlug as ue}from"efficient-easel/page-copy";import{backendOf as $e}from"../lib/website-session.js";import{shopHost as et}from"../../format/lib/web-runtime.js";import{newPopupPage as tt}from"../../format/lib/popup/new-popup.js";const pe="sf-editor-pages-collapsed-groups";function nt(){const i=ce(),{siteId:L,templateId:k}=ae(),I=$e(i).pages;if(!(!I.duplicate||k))return(p,A)=>I.duplicate(p.id,{...A,...L?{siteId:L}:{}})}function ot({onNavigate:i,onClose:L,activeSurface:k,onPreviewSurface:I}){const p=ce().chrome?.pageRows,A=We(),{adapter:m,capabilities:g,ready:B,currentSlug:K}=ae(),me=Ee(),{rows:u,reload:F,setRows:Y,getRows:ge}=Qe(),[M,fe]=c(""),[r,R]=c(!1),[D,f]=c(null),[J,x]=c(!1),[h,_]=c(""),Q=xe(),z=nt(),[b,G]=c(null),[H,he]=c(()=>{if(typeof window>"u")return new Set;try{const e=window.localStorage.getItem(pe);return new Set(e?JSON.parse(e):[])}catch{return new Set}});De(()=>{try{window.localStorage.setItem(pe,JSON.stringify([...H]))}catch{}},[H]);const be=e=>he(a=>{const o=new Set(a);return o.has(e)?o.delete(e):o.add(e),o}),Pe=oe(()=>je(u??[]),[u]),T=M.trim().toLowerCase(),V=e=>!T||e.toLowerCase().includes(T),ye=e=>T?!0:!H.has(e),N=oe(()=>new Set((u??[]).map(e=>e.slug)),[u]),X=()=>{if(g.pageCreationInAdminForm){A.send("storefront-editor:new-page");return}_(""),f(null),x(!0)},Z=async()=>{const e=h.trim();if(!(!e||!B||r||!m.createPage)){R(!0),f(null);try{const a=await m.createPage({slug:ue(e,N),title:e,layout:{}});await F(),x(!1),_(""),i(a.slug)}catch{f(t("Couldn’t add the page — please retry."))}finally{R(!1)}}},v=g.hasSiteSettings&&!!m.createPage,we=async()=>{if(!(!B||r||!m.createPage)){R(!0),f(null);try{const e=await m.createPage(tt(t("New popup"),N));await F(),i(e.slug)}catch{f(t("Couldn’t add the popup — please retry."))}finally{R(!1)}}},$=Ne(null),[P,y]=c(null),Ce=()=>{if(!v)return X();if(P)return y(null);const e=$.current?.getBoundingClientRect();e&&y({top:e.bottom+6,right:Math.max(8,window.innerWidth-e.right)})},Se=e=>{const a=u??[],o=m.deletePage;if(!B||r||!o||a.length<=1)return;const l=a.findIndex(s=>s.id===e.id),d=a.filter(s=>s.id!==e.id),w=e.slug===K;q(e.id,!0),Y(d),f(null),w&&d[0]&&i(d[0].slug);const E=()=>{q(e.id,!1);const s=ge()??[];if(s.some(Ae=>Ae.id===e.id))return;const C=[...s];C.splice(Math.max(0,Math.min(l,C.length)),0,e),Y(C)};re.undoable(t("Deleted “{name}”",{name:e.label}),{actionLabel:t("Undo"),commit:async s=>{await o(e.id,s),q(e.id,!1)},undo:()=>{E(),w&&i(e.slug)},onFail:()=>{E(),re.error(t("Couldn’t delete the page — please retry."))}})},ke=e=>A.send("storefront-editor:open-page",{slug:e}),Ie=e=>{if(!V(e.label))return null;const a=!k&&e.slug===K,o=g.canDeletePagesInline&&(u??[]).length>1,l=Ke(e),d=Ye(e),w=[...l?[{label:t("Dynamic"),tone:"info"}]:[],...d?[{label:t("Lightbox"),tone:"success"}]:[],...e.draft?[{label:t("draft"),tone:"draft"}]:[]],E=w.length>0?w:void 0,s=!!z&&Xe(e),C=s||g.pageCreationInAdminForm||o?S(ne,{children:[s&&n(O,{kind:"plain",label:t("Duplicate “{name}”",{name:e.label}),disabled:r,onClick:()=>G(e),children:n(Ge,{size:13})}),g.pageCreationInAdminForm&&n(O,{kind:"plain",label:t("Page settings for “{name}”",{name:e.label}),onClick:()=>ke(e.slug),children:n(Te,{size:13})}),o&&n(O,{kind:"delete",label:t("Delete “{name}”",{name:e.label}),disabled:r,onClick:()=>Se(e),children:n(j,{name:"trash",size:13,strokeWidth:1.7,rounded:!0})})]}):void 0;return n(de,{icon:n(He,{size:14}),name:e.label,selected:a,onSelect:()=>i(e.slug),badge:E,actions:C,rowProps:{"data-page-slug":e.slug}},e.id)},U=(e,a,o)=>{const l=o.filter(Boolean);if(l.length===0)return null;const d=ye(e);return S(Re,{children:[n(_e,{count:l.length,countLabel:Ve("{n} page","{n} pages",l.length),expanded:d,onToggle:()=>be(e),children:a}),d&&l]},e)},ee=(p?.rows??[]).filter(e=>V(e.label)).map(e=>{const a=k===e.key;return n(de,{icon:e.icon,name:e.label,selected:a,onSelect:()=>I(e.key),badge:{label:t("Preview"),tone:"warning"},actions:n(O,{kind:"plain",label:t("Open the {name} in a new tab",{name:e.label}),onClick:()=>window.open(e.href,"_blank","noopener,noreferrer"),children:n(j,{name:"external-link",size:13,strokeWidth:1.7,rounded:!0})}),rowProps:{"data-shop-surface":e.key}},e.key)}),te=g.hasSiteSettings&&!!p,W=(()=>{if(u===null)return null;const e=[];let a=!1;for(const o of Pe){te&&!a&&o.key.startsWith("system:")&&(e.push(U("shop",p.title,ee)),a=!0);const l=o.key===qe||o.label===Je?t(o.label):o.label;e.push(U(o.key,l,o.rows.map(Ie)))}return te&&!a&&e.push(U("shop",p.title,ee)),e})();return S("div",{className:"sf-pages",children:[n(ve,{icon:n(Ue,{}),title:t("Pages"),context:me,actions:n(Oe,{buttonRef:$,label:v?t("Add"):t("New page"),hasPopup:v?"menu":void 0,expanded:v?P!==null:void 0,onClick:Ce,children:n(ze,{size:15})})}),P&&n(Fe,{portal:!0,style:{top:P.top,right:P.right},onClose:()=>y(null),children:S("div",{role:"menu","aria-label":t("Add"),children:[n(ie,{role:"menuitem",onClick:()=>{y(null),X()},children:t("Page")}),n(ie,{role:"menuitem",disabled:r,onClick:()=>{y(null),we()},children:t("Popup")})]})}),n("div",{className:"sf-pages-find",children:n(le,{type:"search",leftIcon:n(j,{name:"search",size:14,rounded:!0}),placeholder:t("Search all pages…"),value:M,onChange:e=>fe(e.target.value),"aria-label":t("Search all pages")})}),D&&!J&&n("div",{className:"sf-note sf-note--error",role:"alert",children:D}),W===null?n("div",{className:"sf-note",children:t("Loading…")}):W.some(Boolean)?n(Me,{ariaLabel:t("Pages"),className:"sf-scroll",children:W}):n("div",{className:"sf-note",children:M.trim()?t("No pages match your search"):t("No pages yet. Add one with + above.")}),z&&b&&n(Ze,{source:{title:b.label,slug:b.slug},taken:N,host:et(),duplicate:e=>z(b,e),onClose:()=>G(null),onDuplicated:e=>{G(null),F(),i(e.slug)}},b.id),n(Le,{open:J,onClose:()=>x(!1),size:"sm",title:t("Add a page"),description:t("Give the new template page a name. It starts blank — add sections once it opens."),footer:S(ne,{children:[n(se,{variant:"secondary",onClick:()=>x(!1),children:t("Cancel")}),n(se,{onClick:()=>{Z()},disabled:r||!h.trim(),loading:r,children:t("Add page")})]}),children:n(Be,{label:t("Page name"),htmlFor:Q,hint:h.trim()?t("URL: /{slug}",{slug:ue(h,N)}):void 0,error:D??void 0,children:n(le,{id:Q,value:h,invalid:!!D,onChange:e=>_(e.target.value),onKeyDown:e=>{e.key==="Enter"&&Z()},placeholder:t("e.g. About")})})})]})}export{ot as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{jsx as o,jsxs as m,Fragment as W}from"react/jsx-runtime";import{useEasel as we,useRootFields as ge}from"efficient-easel/easel";import{Button as Ee,EmptyState as ke}from"efficient-shell/ui";import{PAGE_STYLE_FIELDS as z}from"../lib/document/page-root-fields.js";import{rootPanelHead as Pe}from"../../format/lib/document/root-panel.js";import{headWords as j,InspectorHead as ve,InspectorIconButton as G}from"efficient-easel/chrome";import{DuplicateIcon as Ie,TrashIcon as Le}from"efficient-easel/icons";import{panelFieldsOf as ye}from"efficient-easel/screen/lib/document/panel-fields";import{TICKER_PART_LABEL as Y}from"../../render/components/PreviewTickerContext.js";import Te from"./SectionIcon.js";import{PanelHideButton as U}from"efficient-easel/screen/components/SidePanelHead";import{useEaselSession as Oe}from"efficient-easel/screen/lib/session-context";import{say as n}from"../../format/lib/editor-words.js";import Ne,{SITE_STYLES_BASICS_TAB as _e}from"./WebsiteSettingsPanel.js";import He from"./ChatSettingsPanel.js";import Re from"./SocialLinksPanel.js";import Ae from"./TickerSettingsPanel.js";import De,{PartSourceNote as Ce}from"./PartSettingsPanel.js";import{regionsForSection as Be}from"../../format/lib/sections/section-text-regions.js";import{TEXT_KIND_LABELS as Fe}from"../../format/lib/sections/section-text-kinds.js";import{textRegionOfPartKey as xe}from"../../format/lib/sections/text-regions.js";import Me from"./DuplicateToPageMenu.js";import{usePageRows as Ke}from"../lib/page-rows.js";import{useScreenDocument as We}from"efficient-easel/screen/components/ScreenDocumentContext";import{usePreviewHeader as ze}from"../../render/components/PreviewHeaderContext.js";import{useSectionOps as je}from"efficient-easel/screen/lib/document/use-section-ops";import{SELECTION_MODE as Ge,isSelectionMode as I}from"efficient-easel/screen/lib/screen-parts";import{usePreviewParts as Ye}from"efficient-easel/draw/client";import{entryPartsOf as Ue,SectionTextEntries as Xe}from"./SectionTextEntries.js";import{SectionTextSuppressProvider as Ze}from"../lib/document/section-text-suppress.js";import{HEADER_TYPE as $e,ROOT_ZONE as X}from"efficient-easel/draw";import{websiteDuplicateBlocked as qe}from"../lib/document/every-page.js";import{FOOTER_TYPE as L}from"../lib/document/footer-blocks.js";import Je from"./SwitchToBoxFooter.js";import{SiteFields as Z}from"./SiteFields.js";import Qe from"./HeroPartPanel.js";import{HERO_MEDIA_PART_LABELS as Ve,HERO_PART_MODE as et,heroPartLabel as tt}from"../../render/lib/document/hero-media-parts.js";import{HintsToggle as nt,SettingsSwitch as ot,hintsFoldClass as rt}from"efficient-easel/panel";import{useHints as it}from"efficient-easel/screen/lib/hints";import{foldTopTier as st}from"../lib/document/field-groups.js";import{FoldHeadingScope as at}from"../lib/document/panel-heading-scope.js";import{partRowField as lt}from"../lib/document/part-row-field.js";import{decodePartKey as ct,partRowHeadLabel as dt}from"../../render/lib/document/part-rows.js";import{encodePartId as pt,partHeadLabel as mt,partLabel as ft,sectionTextParts as ut}from"../../render/lib/document/text-parts.js";import{partSourceOf as ht,sourceMenuIdOf as St,sourceSlugOf as bt}from"../../format/lib/document/source-bound-parts.js";const wn=Ge,gn={kind:"header"},En={kind:"website"},kn={kind:"website",tab:_e,revealPageGroup:!0},Pn={kind:"chat"},vn={kind:"social"},w="Part";function wt(e){return n("Part of {name}",{name:n(e)})}function gt(e,r,i){const s=e.describeNode(r);return{name:i,kindLabel:s?wt(s.label):n(w)}}function Et(e){switch(e){case"Header":return{title:n("Header settings belong to a website."),own:n("Each website created from this template sets its own header afterwards.")};case"Appearance":return{title:n("Appearance settings belong to a website."),own:n("Each website created from this template sets its own appearance afterwards.")};case"Live chat":return{title:n("Live chat settings belong to a website."),own:n("Each website created from this template sets its own live chat afterwards.")};case"Social link":return{title:n("Social link settings belong to a website."),own:n("Each website created from this template sets its own social link afterwards.")};default:return{title:n("{what} settings belong to a website.",{what:e}),own:n("Each website created from this template sets its own {what} afterwards.",{what:e.toLowerCase()})}}}function $({what:e}){const r=Et(e);return m("div",{className:"sf-note",children:[o("p",{children:o("strong",{children:r.title})}),m("p",{children:[n("A template is a blueprint — it has no website of its own, so there is nothing here to change.")," ",r.own]})]})}function y(e){const r=et[e];return{name:Ve[e],kindLabel:w,icon:r,head:(i,s)=>{if(i.kind!==r)return null;const d=s.describeNode(i.nodeId);if(!d)return null;const S=j({name:n(tt(e,d.props)),tier:"part",of:n(d.label)},{partOf:({name:p})=>n("Part of {name}",{name:p})});return{name:S.name,kindLabel:S.kind}},render:(i,s)=>i.kind===r?o(Qe,{nodeId:i.nodeId,part:e,sectionName:s.describeNode(i.nodeId)?.label??"Hero",onUpToSection:()=>s.onSelectNode(i.nodeId)}):null}}const kt={header:{name:"Header",kindLabel:"Site settings",icon:"header",render:(e,r)=>{const i=r.hostPanels?.header;return i?o(i,{placeholderMode:r.capabilities.placeholderFrames,tokenRef:r.tokenRef,siteId:r.siteId,websiteName:r.websiteName,onOpenWebsiteSettings:r.onOpenWebsiteSettings,onAuthExpired:()=>r.notifyParent("storefront-editor:auth-expired")}):null}},website:{name:"Appearance",kindLabel:"Site settings",icon:"website",render:(e,r)=>o(Ne,{initialTab:e.tab,revealPageGroup:e.revealPageGroup,themeFromDocument:!r.capabilities.hasSiteTheme,tokenRef:r.tokenRef,siteId:r.siteId,onNotify:r.onNotify},e.tab??"")},chat:{name:"Live chat",kindLabel:"Site settings",icon:"chat",render:()=>o(He,{})},social:{name:"Social links",kindLabel:"Site settings",icon:"social",render:()=>o(Re,{unavailable:o($,{what:"Social link"})})},ticker:{name:Y,kindLabel:w,icon:"ticker",head:(e,r)=>e.kind==="ticker"?gt(r,e.heroId,n(Y)):null,render:e=>o(Ae,{heroId:e.kind==="ticker"?e.heroId:""})},heroMedia:y("media"),heroImage:y("image"),heroImage2:y("image2"),part:{name:w,kindLabel:w,icon:"Text",head:(e,r)=>{if(e.kind!=="part")return null;const i=r.describeNode(e.nodeId);if(!i)return null;const{key:s,row:d}=ct(e.propKey),S=d?lt(i.fields[s],d):i.fields[s],p=Be(i.type),f=p?xe(p,e.propKey):null,u=p&&f?p[f].label:Fe[e.propKey],g=u?n(u):dt(n(mt(ft(S??{},s))),d),E=j({name:g,tier:"part",of:n(i.label)},{partOf:({name:k})=>n("Part of {name}",{name:k})});return{name:E.name,kindLabel:E.kind}},render:(e,r)=>e.kind==="part"?o(De,{nodeId:e.nodeId,propKey:e.propKey,onBack:()=>r.onSelectNode(e.nodeId),onEditStyle:r.onOpenSiteStyles}):null}},Pt=new Set(["header","website","chat"]);function vt(e,r){if(e==="selection")return null;const i=kt[e];return Pt.has(e)&&!r.hasSiteSettings?{...i,kindLabel:"Not part of a template",render:()=>o($,{what:i.name})}:i}function It({mode:e,onOpenWebsiteSettings:r,onOpenSiteStyles:i,onOpenPageStyles:s,onSelectNode:d,hideNodeActions:S=!1,onNotify:p,onHidePanel:f}){const{capabilities:u,tokenRef:g,notifyParent:E,currentSlug:k,siteId:T,runAuthed:q,readOnly:J,navigate:Lt}=We(),{rows:Q}=Ke(),O=Q?.find(l=>l.slug===k)??null,V=ge(),N=Object.keys(V.fields).some(l=>!l.startsWith("_")&&!z.includes(l)),{websiteName:ee}=ze(),P=je({readOnly:J}),{select:te}=Ye(),{selectedItem:t,getItemById:ne,getSelectorForId:oe,config:h,appState:re}=we(l=>l),ie=ye(h,t?{type:t.type,props:t.props}:null),_=t?ut(ie??h.components[t.type]?.fields,t.props):[],se=l=>h.components[l]?.label??l,a=t?oe(t.props.id):void 0,c=vt(e.kind,u),ae=Oe(),H={capabilities:u,tokenRef:g,hostPanels:ae.chrome?.panels,describeNode:l=>{const b=ne(l);if(!b)return null;const K=h.components[b.type];return{type:b.type,label:K?.label??b.type,fields:K?.fields??{},props:b.props??{}}},siteId:T,websiteName:ee??null,notifyParent:E,onNotify:p,onOpenWebsiteSettings:r,onOpenSiteStyles:i,onSelectNode:d},R=c?.head?.(e,H)??null,A=Pe({kind:O?.kind,pageName:O?.label}),D=R?.name??(c?n(c.name):t?n(se(t.type)):A.name),le=R?.kindLabel??(c?n(c.kindLabel):t?a&&a.zone!==X?n("Block"):n("Section"):A.kindLabel),ce=c?c.icon:t?t.type:"page",C=c?null:t?h.components[t.type]?.fields??null:h.root?.fields??null,de=C?st(C):2,B=I(e)&&t?ht(t.type):null,pe=!!t&&!!a&&a.zone===X&&t.type!==L&&t.type!==$e,v=qe(re?.data,t),me=()=>{v||a&&P.duplicateComponent(a.zone,a.index)},fe=()=>{a&&(P.removeComponent(a.zone,a.index),P.select(null))},ue=t?h.components[t.type]?.defaultProps?.previewHover:void 0,F=I(e)&&!!t&&!!a&&ue!==void 0,x=F&&t.props.previewHover===!0,he=()=>{!t||!a||P.replaceComponent(a.zone,a.index,{...t,props:{...t.props,previewHover:!x}})},{shown:M,setShown:Se}=it(),be=!!(c||t||N);return m("div",{className:`es-sidepanel es-sidepanel--right sf-panel sf-panel--right ${rt(M)}`.trim(),children:[o(ve,{icon:o(Te,{type:ce,size:15}),name:D,kind:le,actions:!S&&I(e)&&t&&t.type!==L?m(W,{children:[o(G,{label:n("Duplicate section"),title:v??void 0,disabled:v!==null,onClick:me,children:o(Ie,{size:15})}),pe&&u.hasSiteSettings&&o(Me,{node:t,currentSlug:k,siteId:T??void 0,tokenRef:g,runAuthed:q,onNotify:p}),o(G,{label:n("Remove section"),danger:!0,onClick:fe,children:o(Le,{size:15})}),f?o(U,{side:"right",onHide:f,divider:!0}):null]}):f?o(U,{side:"right",onHide:f}):void 0}),F&&m("div",{className:"sf-preview-pin",children:[m("div",{className:"sf-preview-pin-text",children:[o("span",{className:"sf-preview-pin-label",children:n("Preview hover state")}),o("span",{className:"sf-preview-pin-hint",children:n("not shown live")})]}),o(ot,{checked:x,onChange:he,ariaLabel:n("Preview hover state")})]}),o(at,{tier:de,children:m("div",{className:"sf-insp-body es-insp-body sf-scroll",children:[c?c.render(e,H):t?m(W,{children:[t.type===L&&u.hasSiteSettings&&o(Je,{}),o(Ze,{children:o(Z,{entries:o(Xe,{parts:_,heading:!1,onOpen:l=>te(pt(t.props.id,l))}),entryCount:Ue(_).length,itemWord:D})}),B&&o(Ce,{source:B,slug:bt(t?.props),menuId:St(t?.props)})]}):N?o(Z,{omit:z}):o(ke,{variant:"none",icon:!1,message:n("Select a section or block to edit it."),children:s&&o(Ee,{variant:"secondary",onClick:s,children:n("This page")})}),be&&o(nt,{shown:M,onChange:Se,label:n("Show hints")})]})})]})}export{Pn as CHAT_MODE,gn as HEADER_MODE,wn as SELECTION_MODE,vn as SOCIAL_MODE,En as WEBSITE_MODE,kn as WEBSITE_PAGE_MODE,It as default,vt as resolvePanel};
|
|
1
|
+
"use client";import{jsx as r,jsxs as m,Fragment as K}from"react/jsx-runtime";import{useEasel as Se,useRootFields as be}from"efficient-easel/easel";import{Button as we,EmptyState as ge}from"efficient-shell/ui";import{PAGE_STYLE_FIELDS as W}from"../lib/document/page-root-fields.js";import{rootPanelHead as Ee}from"../../format/lib/document/root-panel.js";import{headWords as z,InspectorHead as ke,InspectorIconButton as j}from"efficient-easel/chrome";import{DuplicateIcon as Pe,TrashIcon as ve}from"efficient-easel/icons";import{panelFieldsOf as Ie}from"efficient-easel/screen/lib/document/panel-fields";import{TICKER_PART_LABEL as G}from"../../render/components/PreviewTickerContext.js";import Le from"./SectionIcon.js";import{PanelHideButton as Y}from"efficient-easel/screen/components/SidePanelHead";import{useEaselSession as ye}from"efficient-easel/screen/lib/session-context";import{say as n}from"../../format/lib/editor-words.js";import Oe,{SITE_STYLES_BASICS_TAB as Te}from"./WebsiteSettingsPanel.js";import Ne from"./ChatSettingsPanel.js";import _e from"./SocialLinksPanel.js";import He from"./TickerSettingsPanel.js";import Re,{PartSourceNote as Ae}from"./PartSettingsPanel.js";import{regionsForSection as De}from"../../format/lib/sections/section-text-regions.js";import{TEXT_KIND_LABELS as Ce}from"../../format/lib/sections/section-text-kinds.js";import{textRegionOfPartKey as Be}from"../../format/lib/sections/text-regions.js";import Fe from"./DuplicateToPageMenu.js";import{usePageRows as xe}from"../lib/page-rows.js";import{useScreenDocument as Me}from"efficient-easel/screen/components/ScreenDocumentContext";import{usePreviewHeader as Ke}from"../../render/components/PreviewHeaderContext.js";import{useSectionOps as We}from"efficient-easel/screen/lib/document/use-section-ops";import{SELECTION_MODE as ze,isSelectionMode as I}from"efficient-easel/screen/lib/screen-parts";import{usePreviewParts as je}from"efficient-easel/draw/client";import{entryPartsOf as Ge,SectionTextEntries as Ye}from"./SectionTextEntries.js";import{SectionTextSuppressProvider as Ue}from"../lib/document/section-text-suppress.js";import{HEADER_TYPE as Xe,ROOT_ZONE as U}from"efficient-easel/draw";import{websiteDuplicateBlocked as Ze}from"../lib/document/every-page.js";import{FOOTER_TYPE as L}from"../lib/document/footer-blocks.js";import $e from"./SwitchToBoxFooter.js";import{SiteFields as X}from"./SiteFields.js";import qe from"./HeroPartPanel.js";import{HERO_MEDIA_PART_LABELS as Je,HERO_PART_MODE as Qe,heroPartLabel as Ve}from"../../render/lib/document/hero-media-parts.js";import{HintsToggle as et,SettingsSwitch as tt,hintsFoldClass as nt}from"efficient-easel/panel";import{useHints as ot}from"efficient-easel/screen/lib/hints";import{partRowField as rt}from"../lib/document/part-row-field.js";import{decodePartKey as it,partRowHeadLabel as st}from"../../render/lib/document/part-rows.js";import{encodePartId as at,partHeadLabel as lt,partLabel as ct,sectionTextParts as dt}from"../../render/lib/document/text-parts.js";import{partSourceOf as pt,sourceMenuIdOf as mt,sourceSlugOf as ft}from"../../format/lib/document/source-bound-parts.js";const mn=ze,fn={kind:"header"},un={kind:"website"},hn={kind:"website",tab:Te,revealPageGroup:!0},Sn={kind:"chat"},bn={kind:"social"},w="Part";function ut(e){return n("Part of {name}",{name:n(e)})}function ht(e,o,i){const s=e.describeNode(o);return{name:i,kindLabel:s?ut(s.label):n(w)}}function St(e){switch(e){case"Header":return{title:n("Header settings belong to a website."),own:n("Each website created from this template sets its own header afterwards.")};case"Appearance":return{title:n("Appearance settings belong to a website."),own:n("Each website created from this template sets its own appearance afterwards.")};case"Live chat":return{title:n("Live chat settings belong to a website."),own:n("Each website created from this template sets its own live chat afterwards.")};case"Social link":return{title:n("Social link settings belong to a website."),own:n("Each website created from this template sets its own social link afterwards.")};default:return{title:n("{what} settings belong to a website.",{what:e}),own:n("Each website created from this template sets its own {what} afterwards.",{what:e.toLowerCase()})}}}function Z({what:e}){const o=St(e);return m("div",{className:"sf-note",children:[r("p",{children:r("strong",{children:o.title})}),m("p",{children:[n("A template is a blueprint — it has no website of its own, so there is nothing here to change.")," ",o.own]})]})}function y(e){const o=Qe[e];return{name:Je[e],kindLabel:w,icon:o,head:(i,s)=>{if(i.kind!==o)return null;const d=s.describeNode(i.nodeId);if(!d)return null;const h=z({name:n(Ve(e,d.props)),tier:"part",of:n(d.label)},{partOf:({name:p})=>n("Part of {name}",{name:p})});return{name:h.name,kindLabel:h.kind}},render:(i,s)=>i.kind===o?r(qe,{nodeId:i.nodeId,part:e,sectionName:s.describeNode(i.nodeId)?.label??"Hero",onUpToSection:()=>s.onSelectNode(i.nodeId)}):null}}const bt={header:{name:"Header",kindLabel:"Site settings",icon:"header",render:(e,o)=>{const i=o.hostPanels?.header;return i?r(i,{placeholderMode:o.capabilities.placeholderFrames,tokenRef:o.tokenRef,siteId:o.siteId,websiteName:o.websiteName,onOpenWebsiteSettings:o.onOpenWebsiteSettings,onAuthExpired:()=>o.notifyParent("storefront-editor:auth-expired")}):null}},website:{name:"Appearance",kindLabel:"Site settings",icon:"website",render:(e,o)=>r(Oe,{initialTab:e.tab,revealPageGroup:e.revealPageGroup,themeFromDocument:!o.capabilities.hasSiteTheme,tokenRef:o.tokenRef,siteId:o.siteId,onNotify:o.onNotify},e.tab??"")},chat:{name:"Live chat",kindLabel:"Site settings",icon:"chat",render:()=>r(Ne,{})},social:{name:"Social links",kindLabel:"Site settings",icon:"social",render:()=>r(_e,{unavailable:r(Z,{what:"Social link"})})},ticker:{name:G,kindLabel:w,icon:"ticker",head:(e,o)=>e.kind==="ticker"?ht(o,e.heroId,n(G)):null,render:e=>r(He,{heroId:e.kind==="ticker"?e.heroId:""})},heroMedia:y("media"),heroImage:y("image"),heroImage2:y("image2"),part:{name:w,kindLabel:w,icon:"Text",head:(e,o)=>{if(e.kind!=="part")return null;const i=o.describeNode(e.nodeId);if(!i)return null;const{key:s,row:d}=it(e.propKey),h=d?rt(i.fields[s],d):i.fields[s],p=De(i.type),f=p?Be(p,e.propKey):null,u=p&&f?p[f].label:Ce[e.propKey],g=u?n(u):st(n(lt(ct(h??{},s))),d),E=z({name:g,tier:"part",of:n(i.label)},{partOf:({name:k})=>n("Part of {name}",{name:k})});return{name:E.name,kindLabel:E.kind}},render:(e,o)=>e.kind==="part"?r(Re,{nodeId:e.nodeId,propKey:e.propKey,onBack:()=>o.onSelectNode(e.nodeId),onEditStyle:o.onOpenSiteStyles}):null}},wt=new Set(["header","website","chat"]);function gt(e,o){if(e==="selection")return null;const i=bt[e];return wt.has(e)&&!o.hasSiteSettings?{...i,kindLabel:"Not part of a template",render:()=>r(Z,{what:i.name})}:i}function Et({mode:e,onOpenWebsiteSettings:o,onOpenSiteStyles:i,onOpenPageStyles:s,onSelectNode:d,hideNodeActions:h=!1,onNotify:p,onHidePanel:f}){const{capabilities:u,tokenRef:g,notifyParent:E,currentSlug:k,siteId:O,runAuthed:$,readOnly:q,navigate:kt}=Me(),{rows:J}=xe(),T=J?.find(l=>l.slug===k)??null,Q=be(),N=Object.keys(Q.fields).some(l=>!l.startsWith("_")&&!W.includes(l)),{websiteName:V}=Ke(),P=We({readOnly:q}),{select:ee}=je(),{selectedItem:t,getItemById:te,getSelectorForId:ne,config:S,appState:oe}=Se(l=>l),re=Ie(S,t?{type:t.type,props:t.props}:null),_=t?dt(re??S.components[t.type]?.fields,t.props):[],ie=l=>S.components[l]?.label??l,a=t?ne(t.props.id):void 0,c=gt(e.kind,u),se=ye(),H={capabilities:u,tokenRef:g,hostPanels:se.chrome?.panels,describeNode:l=>{const b=te(l);if(!b)return null;const M=S.components[b.type];return{type:b.type,label:M?.label??b.type,fields:M?.fields??{},props:b.props??{}}},siteId:O,websiteName:V??null,notifyParent:E,onNotify:p,onOpenWebsiteSettings:o,onOpenSiteStyles:i,onSelectNode:d},R=c?.head?.(e,H)??null,A=Ee({kind:T?.kind,pageName:T?.label}),D=R?.name??(c?n(c.name):t?n(ie(t.type)):A.name),ae=R?.kindLabel??(c?n(c.kindLabel):t?a&&a.zone!==U?n("Block"):n("Section"):A.kindLabel),le=c?c.icon:t?t.type:"page",C=I(e)&&t?pt(t.type):null,ce=!!t&&!!a&&a.zone===U&&t.type!==L&&t.type!==Xe,v=Ze(oe?.data,t),de=()=>{v||a&&P.duplicateComponent(a.zone,a.index)},pe=()=>{a&&(P.removeComponent(a.zone,a.index),P.select(null))},me=t?S.components[t.type]?.defaultProps?.previewHover:void 0,B=I(e)&&!!t&&!!a&&me!==void 0,F=B&&t.props.previewHover===!0,fe=()=>{!t||!a||P.replaceComponent(a.zone,a.index,{...t,props:{...t.props,previewHover:!F}})},{shown:x,setShown:ue}=ot(),he=!!(c||t||N);return m("div",{className:`es-sidepanel es-sidepanel--right sf-panel sf-panel--right ${nt(x)}`.trim(),children:[r(ke,{icon:r(Le,{type:le,size:15}),name:D,kind:ae,actions:!h&&I(e)&&t&&t.type!==L?m(K,{children:[r(j,{label:n("Duplicate section"),title:v??void 0,disabled:v!==null,onClick:de,children:r(Pe,{size:15})}),ce&&u.hasSiteSettings&&r(Fe,{node:t,currentSlug:k,siteId:O??void 0,tokenRef:g,runAuthed:$,onNotify:p}),r(j,{label:n("Remove section"),danger:!0,onClick:pe,children:r(ve,{size:15})}),f?r(Y,{side:"right",onHide:f,divider:!0}):null]}):f?r(Y,{side:"right",onHide:f}):void 0}),B&&m("div",{className:"sf-preview-pin",children:[m("div",{className:"sf-preview-pin-text",children:[r("span",{className:"sf-preview-pin-label",children:n("Preview hover state")}),r("span",{className:"sf-preview-pin-hint",children:n("not shown live")})]}),r(tt,{checked:F,onChange:fe,ariaLabel:n("Preview hover state")})]}),m("div",{className:"sf-insp-body es-insp-body sf-scroll",children:[c?c.render(e,H):t?m(K,{children:[t.type===L&&u.hasSiteSettings&&r($e,{}),r(Ue,{children:r(X,{entries:r(Ye,{parts:_,heading:!1,onOpen:l=>ee(at(t.props.id,l))}),entryCount:Ge(_).length,itemWord:D})}),C&&r(Ae,{source:C,slug:ft(t?.props),menuId:mt(t?.props)})]}):N?r(X,{omit:W}):r(ge,{variant:"none",icon:!1,message:n("Select a section or block to edit it."),children:s&&r(we,{variant:"secondary",onClick:s,children:n("This page")})}),he&&r(et,{shown:x,onChange:ue,label:n("Show hints")})]})]})}export{Sn as CHAT_MODE,fn as HEADER_MODE,mn as SELECTION_MODE,bn as SOCIAL_MODE,un as WEBSITE_MODE,hn as WEBSITE_PAGE_MODE,Et as default,gt as resolvePanel};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{jsx as
|
|
1
|
+
"use client";import{jsx as i}from"react/jsx-runtime";import{NEW_TAB_ATTRS as h}from"../../format/lib/content/box-link.js";import{useEffect as v,useRef as p,useState as y}from"react";import{ExternalIcon as m}from"efficient-easel/icons";import{EaselIconButton as P}from"efficient-easel/chrome";import{Tooltip as S,iconButtonClasses as x}from"efficient-shell/ui";import{useSettledPress as _}from"efficient-easel/easel";import{useScreenDocument as g}from"efficient-easel/screen/components/ScreenDocumentContext";import{say as l}from"../../format/lib/editor-words.js";async function B({pageId:s,liveHref:n,draftLink:a,ready:c=async()=>!0,win:r=window}){const e=r.open("","_blank");if(e)try{e.opener=null}catch{}const o=t=>{e&&!e.closed?e.location.href=t:r.open(t,"_blank","noopener,noreferrer")};try{await c()}catch{}return a(s).then(t=>o(t.url??n),()=>o(n))}function R({liveHref:s,pageId:n,draftLink:a}){const{flushSave:c}=g(),r=p(c);r.current=c;const e=_(),[o,t]=y(!1),u=p(null);if(v(()=>()=>u.current?.(),[]),a&&n){const d=()=>new Promise((f,b)=>{u.current=()=>f(!1),e.run(()=>{u.current=null,r.current().then(f,b)})}),w=()=>{o||e.waiting||(t(!0),B({pageId:n,liveHref:s,draftLink:a,ready:d}).finally(()=>t(!1)))};return i(P,{label:l("Preview your saved draft in a new tab"),tip:l("Open your saved draft in a new tab. Visitors don't see it."),disabled:o||e.waiting,onClick:w,children:i(m,{})})}return i(S,{content:l("Preview the live site (opens in a new tab)"),side:"bottom",children:i("a",{className:x({className:"es-iconbtn"}),href:s,...h,"aria-label":l("Preview the live site in a new tab"),children:i(m,{})})})}export{R as WebsitePreviewButton,B as openDraftPreview};
|
|
@@ -716,21 +716,21 @@
|
|
|
716
716
|
outline: none;
|
|
717
717
|
}
|
|
718
718
|
|
|
719
|
-
/*
|
|
720
|
-
|
|
721
|
-
root
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
719
|
+
/* THE COLOUR BELOW IS A TOKEN WITH NO FALLBACK, AND THAT IS ON PURPOSE.
|
|
720
|
+
This rule paints inside the canvas FRAME, a document with no `.es-editor`
|
|
721
|
+
root. efficient-easel copies the chrome's accent tokens, `--es-accent-line`
|
|
722
|
+
among them, onto the frame's `:root` (`canvas/host-tokens`), so the token
|
|
723
|
+
resolves there; easel's own empty-cell outline reads `--es-accent` the same
|
|
724
|
+
way. A literal fallback would be a second copy of the shell's accent
|
|
725
|
+
(owner ruling 2026-10-23: a colour value is written once). Until blueprint
|
|
726
|
+
5.5 these rules leaned on the old editor library's `--old-azure-*` ramp,
|
|
727
|
+
and a bare `var()` of a token the frame did not carry drew no outline at
|
|
728
|
+
all: the empty slot stopped answering when pointed at, silently. */
|
|
729
729
|
|
|
730
730
|
/* B · …except an EMPTY one, which has no block to carry the line for it. */
|
|
731
731
|
[data-easel-entry]
|
|
732
732
|
.es-zone:empty:is(.is-area-selected, .is-hovering-area:not(.is-root)) {
|
|
733
|
-
outline: 1px solid var(--es-accent-line
|
|
733
|
+
outline: 1px solid var(--es-accent-line);
|
|
734
734
|
}
|
|
735
735
|
|
|
736
736
|
/* C, D, E · RETIRED 2026-10-26: no line on the words, ever, and the engine's
|
|
@@ -900,7 +900,7 @@
|
|
|
900
900
|
}
|
|
901
901
|
|
|
902
902
|
/* 2026-10-20: THE INSET IS EASEL'S, 16 AND 12 UNDER 260 (efficient-easel
|
|
903
|
-
14.1.0,
|
|
903
|
+
14.1.0, option A). The 8px under a 284px panel that the notes below
|
|
904
904
|
measured is gone: one side inset for every head and body, one home.
|
|
905
905
|
The history stays, because the overflow sweep is still how a width is
|
|
906
906
|
judged.
|
|
@@ -1536,7 +1536,7 @@
|
|
|
1536
1536
|
filled pill) and `SettingsGroupSub` (the quiet tier, added in 0.25.0 for this).
|
|
1537
1537
|
Nothing in this repo renders either class any more — the four panels that
|
|
1538
1538
|
inlined `.sf-field-group` as a bare div (HeroText, Ticker, HeroMedia, Chat)
|
|
1539
|
-
call
|
|
1539
|
+
call easel's quiet tier in the same card, because leaving them behind would have put
|
|
1540
1540
|
the hairline back in four panels and given the editor two answers to "what does
|
|
1541
1541
|
a group heading look like" — which is the fault the conversion is fixing.
|
|
1542
1542
|
Deleted rather than left dead: a rule nobody renders is a rule the next person
|
|
@@ -1580,8 +1580,8 @@
|
|
|
1580
1580
|
|
|
1581
1581
|
the nearest scrolling ancestor is `.sf-insp-body` (`overflow-y: auto`
|
|
1582
1582
|
above); the Inspector's own `.es-insp` / `.es-insp-rows` carry NO
|
|
1583
|
-
overflow, and `SectionTextSuppressProvider`
|
|
1584
|
-
context only and
|
|
1583
|
+
overflow, and `SectionTextSuppressProvider` is
|
|
1584
|
+
context only and draws no element — so nothing between the wrapper and the
|
|
1585
1585
|
scroll box clips it. Checked, not assumed: a sticky that does not stick
|
|
1586
1586
|
reports nothing at all.
|
|
1587
1587
|
|
|
@@ -2849,14 +2849,6 @@
|
|
|
2849
2849
|
color: var(--sf-text);
|
|
2850
2850
|
}
|
|
2851
2851
|
|
|
2852
|
-
/* Checkbox — a literal tick box. The row is easel's SettingsField with the box
|
|
2853
|
-
in its `action` slot (label left, box right); the label points at the box, so
|
|
2854
|
-
the text is clickable. The box is efficient-shell's `Checkbox` (harness
|
|
2855
|
-
UI-24), drawn and focus-ringed by the shell, so no rule here reaches it. */
|
|
2856
|
-
.sf-checkbox {
|
|
2857
|
-
cursor: pointer;
|
|
2858
|
-
}
|
|
2859
|
-
|
|
2860
2852
|
/* A field group greyed out because a higher-level setting overrides it — e.g. the
|
|
2861
2853
|
manual ProductPicker (Category + Product) when the Product Grid's Products
|
|
2862
2854
|
source is set to All wheels / a collection. */
|
|
@@ -3841,7 +3833,7 @@ input.sf-list-marking {
|
|
|
3841
3833
|
z-index: 1;
|
|
3842
3834
|
}
|
|
3843
3835
|
|
|
3844
|
-
/* Site styles › Text: the Accent group (SiteAccentField,
|
|
3836
|
+
/* Site styles › Text: the Accent group (SiteAccentField, ruling (b)
|
|
3845
3837
|
2026-10-16) is easel's `TextStylesGroup`, drawn AFTER the list rather than
|
|
3846
3838
|
inside it, so easel's own `.es-ts-section + .es-ts-section` gap cannot
|
|
3847
3839
|
reach it. The same gap, on the panel's rhythm token, so Accent sits under Body
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{useEffect as
|
|
1
|
+
"use client";import{useEffect as l,useState as a}from"react";import{loadEditorSiteSlug as g}from"../lib/editor-site-slug.js";import{editorPreviewHref as S,originIsSiteAmbiguous as h}from"../../format/lib/editor/preview-href.js";import{shopOrigin as d,shopRouteBase as v}from"../../format/lib/web-runtime.js";function I(c){const{pageSlug:f,siteId:e,token:t}=c,[m,n]=a(null),[o,i]=a(null),r=v();l(()=>{try{i(new URL(d()).hostname)}catch{i(null)}},[r]),l(()=>{if(!h(o)||!e||!t){n(null);return}let u=!1;return g(t,e).then(p=>{u||n(p)}),()=>{u=!0}},[o,e,t]);const s=S({pageSlug:f,siteSlug:m,hostname:o});return r?`${r}${s}`:s}export{I as usePreviewHref};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as
|
|
1
|
+
import{jsx as e}from"react/jsx-runtime";import{DirectionDownIcon as u,DirectionIcon as _,DirectionLeftIcon as O,DirectionRightIcon as A,DirectionUpIcon as F,EntranceBounceIcon as T,EntranceFadeIcon as D,EntranceFlipIcon as S,EntranceGlideIcon as y,EntranceRevealIcon as K,EntranceRiseIcon as L,EntranceScaleIcon as w,EntranceSpinIcon as C,NoSymbolIcon as M}from"efficient-easel/icons";import{NoControlMark as g,noControlField as b}from"efficient-easel/screen/lib/document/panel-no-control-mark";import{customize as h,group as k}from"efficient-easel/screen/lib/document/box-fields";import{ENTRANCE_FROM as G,ENTRANCE_FROM_DEFAULT as s,ENTRANCE_KINDS as d,ENTRANCE_KINDS_WITH_FROM as v,entranceAttrs as B,playEntrance as U,readEntrance as P}from"efficient-shell/format";import{segmented as W}from"../document/box-fields.js";import{shownByUsedValue as Y,withRowRules as x}from"../../../format/lib/document/show-when-attach.js";import{animationDelayField as H,animationDurationField as V}from"./AnimationDurationRow.js";import{ENTRANCE_KEYS as r,LEGACY_ENTRANCE_KEY as f,entranceOf as m}from"../../../render/lib/animation/entrance.js";import{ENTRANCE_GROUP_KEY as j}from"../../../format/lib/animation/index.js";import{followedViewRows as $,viewTileRows as q}from"./view-rows.js";import{MOTION_VIEWS as c,viewKey as i}from"../../../format/lib/animation/views.js";const z={none:"None",fade:"Fade",rise:"Rise",scale:"Scale",glide:"Glide",bounce:"Bounce",flip:"Flip",reveal:"Reveal",spin:"Spin"},J={top:"Top",bottom:"Bottom",left:"Left",right:"Right"},Q={top:()=>e(u,{}),bottom:()=>e(F,{}),left:()=>e(A,{}),right:()=>e(O,{})},p="Entrance",a=d.filter(n=>n!=="none"),E=n=>({any:[{field:r.kind,in:n},{all:[{field:r.kind,set:!1},{field:f,in:n}]}]}),R=(n,t)=>Y(c.slice(0,c.indexOf(n)+1).reverse().map(o=>i(r.kind,o)),o=>({field:o,set:!0}),o=>o===r.kind?E(t):{field:o,in:t}),X={any:[E(a),...c.slice(1).map(n=>({field:i(r.kind,n),in:a}))]},Z=c.flatMap(n=>[[[i(r.from,n)],R(n,v)],[[i(r.duration,n),i(r.delay,n)],R(n,a)]]),nn={none:()=>e(M,{}),fade:()=>e(D,{}),rise:()=>e(L,{}),scale:()=>e(w,{}),glide:()=>e(y,{}),bounce:()=>e(T,{}),flip:()=>e(S,{}),reveal:()=>e(K,{}),spin:()=>e(C,{})},N="data-entrance-tile";function en({kind:n}){const{attrs:t}=B(P(n,s));return e("span",{className:"sf-entrance-stage",[N]:n,children:e("i",{...t,children:nn[n]()})})}const on=(n,t)=>{const o=n.querySelector(`[${N}="${t}"] > i`);o&&U(o)},tn="Effect",rn=()=>q(r.kind,{label:p,tileWord:tn,values:d,fallback:"none",word:n=>z[n],picture:n=>e(en,{kind:n}),read:(n,t)=>m(n,t).kind,preview:on}),l=(n,t)=>$(r[n],t,(o,I)=>m(o,I)[n]),cn=G.map(n=>({label:J[n],value:n,picture:Q[n]()}));function _n(){const n={[j]:k(p,{dot:X}),...rn(),[f]:b({type:"custom",render:()=>e(g,{})},"always"),_cEntrance:h(),...l("from",W("From",e(_,{}),cn,s)),...l("duration",V("entrance")),...l("delay",H("entrance"))};return x(n,Z)}export{_n as entranceFields};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as e
|
|
1
|
+
import{jsx as e}from"react/jsx-runtime";import{EntranceRevealIcon as R,NoSymbolIcon as u,PercentIcon as f,ScrollFadeInIcon as I,ScrollFadeOutIcon as _,ScrollMoveDownIcon as C,ScrollMoveUpIcon as F,ScrollParallaxIcon as w,ScrollZoomInIcon as v,ScrollZoomOutIcon as T,ZoomInIcon as x}from"efficient-easel/icons";import{customize as M,group as Z}from"efficient-easel/screen/lib/document/box-fields";import{SCROLL_EFFECTS as s,SCROLL_EFFECTS_WITH_ZOOM as z,SCROLL_END as N,SCROLL_START as P,SCROLL_ZOOM as U}from"efficient-shell/format";import{slider as y}from"../document/box-fields.js";import{shownByUsedValue as G,withRowRules as K}from"../../../format/lib/document/show-when-attach.js";import{SCROLL_CUSTOMIZE_KEY as V,SCROLL_GROUP_KEY as W,SCROLL_KEYS as t,scrollOf as i}from"../../../format/lib/animation/scroll.js";import{followedViewRows as Y,viewTileRows as b}from"./view-rows.js";import{MOTION_VIEWS as m,viewKey as r}from"../../../format/lib/animation/views.js";const d="Scroll",A={none:"None","zoom-in":"Zoom in","zoom-out":"Zoom out","fade-in":"Fade in","fade-out":"Fade out","move-up":"Move up","move-down":"Move down",reveal:"Reveal",parallax:"Parallax"},B={none:()=>e(u,{}),"zoom-in":()=>e(v,{}),"zoom-out":()=>e(T,{}),"fade-in":()=>e(I,{}),"fade-out":()=>e(_,{}),"move-up":()=>e(F,{}),"move-down":()=>e(C,{}),reveal:()=>e(R,{}),parallax:()=>e(w,{})},H="Effect",S=s.filter(o=>o!=="none"),O=(o,l)=>G(m.slice(0,m.indexOf(o)+1).reverse().map(n=>r(t.effect,n)),n=>({field:n,set:!0}),n=>({field:n,in:l})),h={any:m.map(o=>({field:r(t.effect,o),in:S}))},j=m.flatMap(o=>[[[r(t.zoom,o)],O(o,z)],[[r(t.start,o),r(t.end,o)],O(o,S)]]),D=()=>b(t.effect,{label:d,tileWord:H,values:s,fallback:"none",word:o=>A[o],picture:o=>B[o](),read:(o,l)=>i(o,l).effect}),a=(o,l,n,p,c)=>Y(o,y(n,p,c.min,c.max,c.step,c.default,"%"),(L,E)=>i(L,E)[l]);function to(){const o={[W]:Z(d,{dot:h}),...D(),[V]:M(),...a(t.zoom,"zoom","Zoom",e(x,{}),U),...a(t.start,"start","Start",e(f,{}),P),...a(t.end,"end","End",e(f,{}),N)};return K(o,j)}export{h as SCROLL_CHOSEN,to as scrollFields};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { type ReactElement } from "react";
|
|
2
|
+
import { type MotionView } from "../../../format/lib/animation/views.js";
|
|
3
|
+
export type ReadView<V = unknown> = (record: Readonly<Record<string, unknown>>, view: MotionView) => V;
|
|
4
|
+
type Row = {
|
|
5
|
+
render?: unknown;
|
|
6
|
+
};
|
|
7
|
+
export declare function viewRows<F>(key: string, rowFor: (view: MotionView) => F): Record<string, F>;
|
|
8
|
+
export declare function followedViewRows<F extends Row>(key: string, row: F, read: ReadView): Record<string, F>;
|
|
9
|
+
export type TileSpec<V extends string> = {
|
|
10
|
+
label: string;
|
|
11
|
+
tileWord: string;
|
|
12
|
+
values: readonly V[];
|
|
13
|
+
fallback: V;
|
|
14
|
+
word: (value: V) => string;
|
|
15
|
+
picture: (value: V) => ReactElement;
|
|
16
|
+
read: ReadView<V>;
|
|
17
|
+
preview?: (row: HTMLElement, value: V) => void;
|
|
18
|
+
};
|
|
19
|
+
export declare function viewTileRows<V extends string>(key: string, spec: TileSpec<V>): Record<string, unknown>;
|
|
20
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{jsx as a,Fragment as h,jsxs as v}from"react/jsx-runtime";import{useRef as x}from"react";import{SettingsDefaultReset as g}from"efficient-easel/panel";import{effectTiles as R}from"efficient-easel/screen/lib/document/effect-tiles";import{VIEW_KEY_ACCESS as u,describedAs as k,onDesktopWords as E,phoneTwinFields as c}from"efficient-easel/screen/lib/document/box-fields";import{useSelectedProps as m}from"../document/controls.js";import{editorEaselWords as V,say as i}from"../../../format/lib/editor-words.js";import{MOTION_VIEWS as _,viewKey as j}from"../../../format/lib/animation/views.js";function y({row:e,read:o,...n}){const t=o(m(),n.followsView??"desktop");return e({...n,follows:t})}function C(e,o){return Object.fromEntries(_.map(n=>{const t=j(e,n);return[t,c(e,o(n),u)[t]]}))}function P(e,o,n){const t=o.render,s={...o,render:l=>a(y,{...l,row:t,read:n})};return C(e,l=>l==="desktop"?o:s)}function S({spec:e,...o}){const n=e.values.includes(o.value),t="follows"in o,s=e.read(m(),o.followsView??"desktop"),l=n?o.value:s,d=x(null),{preview:w}=e,b=R({label:i(e.label),options:e.values.map(r=>({value:r,label:i(e.word(r)),picture:e.picture(r)})),fallback:e.fallback,onPreview:w?r=>d.current&&w(d.current,r):void 0}).render,f=b({value:l,onChange:r=>o.onChange(r??e.fallback)});return v(h,{children:[w?a("div",{ref:d,style:{display:"contents"},children:f}):f,t&&n&&a(g,{words:V()?.panel,label:i(e.tileWord),changed:!0,detail:E(r=>i(r),i(e.word(s)),o.followsView),onReset:()=>o.onChange(void 0)})]})}function M(e,o){const n=k({type:"custom",render:t=>a(S,{...t,spec:o})},{type:"select",label:o.label,options:o.values.map(t=>({value:t,label:o.word(t)}))});return c(e,n,u)}export{P as followedViewRows,C as viewRows,M as viewTileRows};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as
|
|
1
|
+
import{jsx as e}from"react/jsx-runtime";import{OpacityIcon as a}from"efficient-easel/icons";import{text as i,textarea as r,upload as m}from"../../../controls.js";import{group as o}from"efficient-easel/screen/lib/document/box-fields";import{slider as n}from"../../../box-fields.js";import{ctaField as g}from"../../shared-fields.js";import{BANNER_PH as t}from"../../../../../../format/lib/document/blocks/general/Banner/meta.js";const s={fields:{_gContent:o("Content"),eyebrow:i("Eyebrow",t.eyebrow),title:r("Heading",t.title),body:r("Body",t.body),_gBackground:o("Background image"),imageSrc:m("Image","image/*"),overlay:n("Overlay",e(a,{}),0,100,5,60,"%"),_gButton:o("Button"),...g,_gLayout:o("Layout")}};export{s as BannerFields};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as
|
|
1
|
+
import{jsx as t,jsxs as S}from"react/jsx-runtime";import{ButtonIcon as B,ButtonIconIcon as C,IconAfterTextIcon as _,IconBeforeTextIcon as w}from"efficient-easel/icons";import{SettingsField as O}from"efficient-easel/panel";import{useSelectedFields as m}from"efficient-easel/easel";import{buttonFieldSet as k}from"efficient-easel/screen/lib/document/button-fields";import{VIEW_KEY_ACCESS as F}from"efficient-easel/screen/lib/document/box-fields";import{IconPicker as v,Segmented as N}from"efficient-shell/ui";import{shellGlyphOf as R}from"../../../shell-glyph.js";import{StorefrontTextLinkField as P}from"../../../../../components/StorefrontLinkField.js";import{usePreviewHeader as a}from"../../../../../../render/components/PreviewHeaderContext.js";import{BUTTON_ICONS as W,buttonIconChoice as L,buttonIconSide as E,buttonWidth as A}from"../../../../../../format/lib/content/button-icon.js";import{BUTTON_PAD_BUILT_IN as j,buttonLook as u}from"../../../../../../render/lib/content/button-look.js";import{nonEmptyString as U}from"../../../../../../format/lib/non-empty-string.js";import{selectedThemeColors as z,siteButtonPaint as p,siteButtonRadiusPx as D}from"../../../../../../format/lib/theme.js";import{say as r}from"../../../../../../format/lib/editor-words.js";import{backTo as K,buttonWordsEntryField as G,hidableText as H,inOwnBox as V,linkField as Y,plainText as q,useSelectedSibling as f}from"../../../controls.js";import{useThemePresets as J}from"../../../ColourControl.js";import{keptByRow as c}from"efficient-easel/screen/lib/document/style-fields";import{group as h}from"efficient-easel/screen/lib/document/box-fields";import{LENGTH_UNITS_TABLE as M,pickerNoneIcon as Q,rowSay as X,ShellIconWord as b}from"../../../box-fields.js";import{CARD_ROW_FACTS as Z,cardRowField as $,cardRowFields as ee,cardRowLinkField as oe,typedLinkField as te}from"../../../card-row-fields.js";import{CARD_ROW_LINK_PROP as ne}from"../../../../../../format/lib/content/card-template.js";import{consentWordsKept as ie,withConsentWordsRow as re}from"../../../consent-words-field.js";const d=e=>R(e==="none"?"no-symbol":e),se=W.map(e=>({value:e,icon:e==="none"?Q(d(e),t(b,{value:e})):d(e)})),I=q("Button");function le({value:e,onChange:n}){const o=m(),i=o.values.href,s=typeof e=="string"?e:e&&typeof e=="object"&&"text"in e?String(e.text??""):"";return o.fields&&"href"in o.fields?t(P,{label:"Button",icon:t(B,{size:18}),text:s,onTextChange:n,link:typeof i=="string"?i:"",onLinkChange:l=>o.onChange("href",l)}):I.render({value:s,field:{label:"Button"},onChange:l=>n(H(l))})}function ce({value:e,onChange:n}){const o=m(),i=L(e,o.values.arrow),s=E(o.values.iconPosition),l=A(o.values.widthFit)==="fill",g=d("icon-at-end");return t(O,{label:r("Icon"),icon:t(C,{size:18}),value:i==="none"?void 0:t(b,{value:i}),children:S("div",{className:"flex items-center gap-2",children:[t(v,{label:r("Icon"),value:i,options:se,onChange:n}),i!=="none"&&t(N,{size:"sm",block:!0,label:r("Icon position"),value:s==="end"&&!l?"after":s,onChange:y=>o.onChange("iconPosition",y),options:[{value:"before",icon:t(w,{size:16}),label:t("span",{className:"sr-only",children:r("Icon before text")}),title:r("Icon before text")},{value:"after",icon:t(_,{size:16}),label:t("span",{className:"sr-only",children:r("Icon after text")}),title:r("Icon after text")},...l?[{value:"end",icon:g,label:t("span",{className:"sr-only",children:r("Icon at the far end")}),title:r("Icon at the far end")}]:[]]})]})})}const x=()=>p(a().theme),T=k({lengthUnits:M,follows:{useFill:()=>x().fill,useText:()=>x().ink,useBorder:()=>{const[e]=f("variant"),[n]=f("buttonColor"),{theme:o}=a(),i=u({variant:e,buttonColor:n}).border.width,s=U(n)??(e==="ghost"?z(o).text:p(o).fill);return{width:i,color:s}},useCorners:()=>D(a().cornerRadiusPx),useFillOpacity:()=>u({variant:f("variant")[0]}).fillOpacity},usePresets:J,resetTo:e=>K(e,r("Styles")),padding:{fallback:j,tablet:!0},phone:F,say:X});function ae(e,n){const o=Object.keys(e);return Object.fromEntries(o.slice(0,o.indexOf(n)+1).map(i=>[i,e[i]]))}const Pe={fields:{label:V(I,e=>t(le,{value:e.value,onChange:e.onChange})),labelText:G("label"),href:te({...Y("Button link"),...c("label")}),consentWords:ie("label"),_gButton:h("Button"),rowField:$("Shows","text"),[ne]:oe(),...ae(T,"_dDesign"),_gStyle:h("Style"),variant:c("buttonColor"),icon:{type:"custom",render:e=>t(ce,{value:e.value,onChange:e.onChange})},iconPosition:c("icon"),arrow:c("icon"),...T},resolveFields:(e,n)=>re(ee(n.fields,e,n),e.props,"label",["href"]),showWhenFacts:Z};export{Pe as ButtonBlockFields};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as i}from"react/jsx-runtime";import{StylesIcon as l,WeightIcon as c,WidthIcon as p}from"efficient-easel/icons";import{swapPadding as d}from"../../../controls.js";import{keptByRow as m}from"efficient-easel/screen/lib/document/style-fields";import{iconPickerRow as a,sidesPaddingFields as f,slider as s}from"../../../box-fields.js";import{LAYOUT_CELL as I,dividerPicture as _}from"../../../choice-pictures.js";import{DEFAULT_DIVIDER_STYLE as o,DIVIDER_SPACE_PX as g,DIVIDER_STYLE_OPTIONS as D,parseDividerSpacing as E}from"../../../../../../format/lib/sections/divider-style.js";import{withRowRules as P}from"../../../../../../render/lib/document/show-when.js";const
|
|
1
|
+
import{jsx as i}from"react/jsx-runtime";import{StylesIcon as l,WeightIcon as c,WidthIcon as p}from"efficient-easel/icons";import{swapPadding as d}from"../../../controls.js";import{keptByRow as m}from"efficient-easel/screen/lib/document/style-fields";import{iconPickerRow as a,sidesPaddingFields as f,slider as s}from"../../../box-fields.js";import{LAYOUT_CELL as I,dividerPicture as _}from"../../../choice-pictures.js";import{DEFAULT_DIVIDER_STYLE as o,DIVIDER_SPACE_PX as g,DIVIDER_STYLE_OPTIONS as D,parseDividerSpacing as E}from"../../../../../../format/lib/sections/divider-style.js";import{withRowRules as P}from"../../../../../../render/lib/document/show-when.js";const S={any:[{field:"style",set:!1},{field:"style",is:o}]},h={not:{field:"style",is:"none"}},w={fields:P({style:a("Style",i(l,{}),D.map(e=>({...e,picture:_(e.value)})),o,{columns:3,cell:I}),spacing:m("sectionPaddingTop"),thickness:s("Thickness",i(c,{}),1,8,1,1,"px"),lengthPct:s("Length",i(p,{}),10,100,1,100,"%")},[[["thickness"],S],[["lengthPct"],h]]),resolveFields:(e,{fields:r})=>{const t=g[E(e.props.spacing)],n=f({fallback:{top:t,bottom:t},tablet:!0,siteSide:!0});return d(r,n)}};export{w as DividerFields};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as a}from"react/jsx-runtime";import{ChevronIcon as l}from"efficient-easel/icons";import{copyText as m,linkField as p,plainTextarea as u,text as
|
|
1
|
+
import{jsx as a}from"react/jsx-runtime";import{ChevronIcon as l}from"efficient-easel/icons";import{copyText as m,linkField as p,plainTextarea as u,text as r,textarea as c,toggle as T}from"../../../controls.js";import{group as o}from"efficient-easel/screen/lib/document/box-fields";import{SPLITTABLE_SECTIONS as f,headFieldsForPlacement as d}from"../../../../../../format/lib/sections/section-head-placement.js";import{withRowsShownWhen as h}from"../../../../../../format/lib/document/show-when-attach.js";import{ENTRANCE_STORE_KEYS as E,LEGACY_ENTRANCE_KEY as A}from"../../../../../../render/lib/animation/entrance.js";import{drawsCopiesInTheBox as _}from"../../../../../../format/lib/content/copies-in-box.js";import{FAQ_PH as n,FAQSlots as F}from"../../../../../../format/lib/document/blocks/general/FAQ/meta.js";const i="faqOnTemplate",w={not:{context:i,is:!0}},x={[i]:t=>_("FAQ",t.props??{})},N=new Set([A,...E]);function Q(t){return Object.keys(t).filter(e=>["num","title","linkText","linkHref","anchor"].includes(e)||e.startsWith("sectionPadding")||e.startsWith("sectionHeight")||N.has(e))}const H={fields:{_gContent:o("Content"),num:r("Number",n.num),title:c("Heading",n.title),linkText:r("Button",n.link),linkHref:p("Link"),_gQuestions:o("Questions"),items:{type:"array",label:"Questions",arrayFields:{question:m("Question"),answer:u("Answer")},getItemSummary:t=>t.question||"Question"},_gLayout:o("Layout"),defaultOpen:T("Open first answer",!0,a(l,{})),...F},resolveFields:(t,{fields:e})=>{const s=d(e,t.props.headPlacement,f.FAQ.headRows);return h(s,Q(s),w)},showWhenFacts:x};export{H as FAQFields};
|