efficient-web-builder 5.4.0 → 6.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +272 -0
- package/README.md +44 -0
- package/dist/components/ApplyCornersToSiblings.js +1 -1
- package/dist/components/Banner.js +1 -1
- package/dist/components/BlockGapField.js +1 -1
- package/dist/components/BlogPostSource.js +1 -1
- package/dist/components/Breadcrumb.js +1 -1
- package/dist/components/CardShadowField.js +1 -1
- package/dist/components/CategoryBar.js +1 -1
- package/dist/components/ChatSettingsPanel.js +1 -1
- package/dist/components/ClearColoursDialog.js +1 -1
- package/dist/components/CornersField.js +1 -1
- package/dist/components/DocBody.js +5 -5
- package/dist/components/DuplicateToPageMenu.js +1 -1
- package/dist/components/FAQ.js +1 -1
- package/dist/components/Flex.js +1 -1
- package/dist/components/Footprint.js +3 -3
- package/dist/components/HeadingAudit.js +1 -1
- package/dist/components/HeroImageField.js +1 -1
- package/dist/components/HeroSection.js +2 -2
- package/dist/components/HeroSingle.js +1 -1
- package/dist/components/HeroSlide.js +1 -1
- package/dist/components/HoverEffectField.js +1 -1
- package/dist/components/ImageFocusRow.js +1 -1
- package/dist/components/IntegrationsSection.js +1 -1
- package/dist/components/IntroBleed.js +1 -1
- package/dist/components/KeyFeatures.js +1 -1
- package/dist/components/LocationsGroupedField.js +1 -1
- package/dist/components/MediaUploadField.js +1 -1
- package/dist/components/MultiSelectField.js +1 -1
- package/dist/components/PagesPanel.js +1 -1
- package/dist/components/PartInkControl.js +1 -1
- package/dist/components/PartResetDot.js +1 -1
- package/dist/components/PartSettingsPanel.js +1 -1
- package/dist/components/PartTextBox.js +1 -1
- package/dist/components/PhotographyField.js +1 -1
- package/dist/components/ProcessSteps.js +1 -1
- package/dist/components/SearchSelectField.d.ts +1 -1
- package/dist/components/SearchSelectField.js +1 -1
- package/dist/components/SectionEditor.js +1 -1
- package/dist/components/SectionTextEntries.js +1 -1
- package/dist/components/SectionThemePicker.js +1 -1
- package/dist/components/Series.js +1 -1
- package/dist/components/ShadowColourField.js +1 -1
- package/dist/components/SideSpaceField.js +1 -1
- package/dist/components/SiteFields.js +1 -1
- package/dist/components/SiteWidthField.js +1 -1
- package/dist/components/SlotChildRows.js +1 -1
- package/dist/components/SocialLinksPanel.js +1 -1
- package/dist/components/SourceStatus.js +1 -1
- package/dist/components/SpecStrip.js +1 -1
- package/dist/components/Split.js +1 -1
- package/dist/components/StandaloneSectionEditor.js +1 -1
- package/dist/components/StatsParagraph.js +1 -1
- package/dist/components/StorefrontLinkField.js +1 -1
- package/dist/components/StylesPanel.js +1 -1
- package/dist/components/SwitchToBoxFooter.js +1 -1
- package/dist/components/Testimonials.js +1 -1
- package/dist/components/TextStyleRow.js +1 -1
- package/dist/components/TextStylesField.js +1 -1
- package/dist/components/ThemeCard.js +1 -1
- package/dist/components/ThemeColourField.js +1 -1
- package/dist/components/ThemeField.js +1 -1
- package/dist/components/TickerSection.js +1 -1
- package/dist/components/TickerSettingsPanel.js +1 -1
- package/dist/components/TitleWithButtons.js +1 -1
- package/dist/components/WebsiteScreenParts.js +1 -1
- package/dist/components/WebsiteSettingsPanel.js +1 -1
- package/dist/components/WidthFollowField.js +1 -1
- package/dist/components/preview-devices.js +1 -1
- package/dist/components/socialIcons.js +1 -1
- package/dist/components/storefront-editor.css +61 -157
- package/dist/components/useLocationsTree.js +1 -1
- package/dist/components/useSocialSettings.d.ts +2 -2
- package/dist/lib/content/block-sources.d.ts +20 -0
- package/dist/lib/content/block-sources.js +1 -0
- package/dist/lib/content/ink.d.ts +36 -0
- package/dist/lib/content/ink.js +1 -0
- package/dist/lib/content/product-page.js +1 -1
- package/dist/lib/content/record-types.d.ts +21 -0
- package/dist/lib/content/record-types.js +1 -0
- package/dist/lib/content/section-surface.js +1 -1
- package/dist/lib/content/social-links.d.ts +1 -1
- package/dist/lib/content/social-links.js +1 -1
- package/dist/lib/editor-words-catalogue.d.ts +1184 -0
- package/dist/lib/editor-words-catalogue.js +11 -0
- package/dist/lib/editor-words.d.ts +15 -0
- package/dist/lib/editor-words.js +1 -0
- package/dist/lib/links/link-picker-setup.d.ts +1 -1
- package/dist/lib/links/link-picker-setup.js +1 -1
- package/dist/lib/links/page-link-rules.d.ts +0 -1
- package/dist/lib/links/page-link-rules.js +1 -1
- package/dist/lib/puck/ColourControl.js +1 -1
- package/dist/lib/puck/MarkupToolbar.js +1 -1
- package/dist/lib/puck/apply-card-corners.js +1 -1
- package/dist/lib/puck/block-source-fields.d.ts +5 -0
- package/dist/lib/puck/block-source-fields.js +1 -0
- package/dist/lib/puck/blocks/general/Breadcrumb/render.js +1 -1
- package/dist/lib/puck/blocks/general/Cards/render.js +1 -1
- package/dist/lib/puck/blocks/general/CategoryBar/render.js +1 -1
- package/dist/lib/puck/blocks/general/Chart/render.js +2 -2
- package/dist/lib/puck/blocks/general/DocBody/render.js +1 -1
- package/dist/lib/puck/blocks/general/DocMasthead/render.js +1 -1
- package/dist/lib/puck/blocks/general/DocTabs/render.js +1 -1
- package/dist/lib/puck/blocks/general/FAQ/render.js +1 -1
- package/dist/lib/puck/blocks/general/Footprint/render.js +2 -2
- package/dist/lib/puck/blocks/general/HeroSingle/render.js +1 -1
- package/dist/lib/puck/blocks/general/HeroSlide/render.js +1 -1
- package/dist/lib/puck/blocks/general/KeyFeatures/render.js +1 -1
- package/dist/lib/puck/blocks/general/Logos/render.js +1 -1
- package/dist/lib/puck/blocks/general/Masthead/render.js +1 -1
- package/dist/lib/puck/blocks/general/OrderSummary/fields.js +1 -1
- package/dist/lib/puck/blocks/general/OrderSummary/render.js +1 -1
- package/dist/lib/puck/blocks/general/PaymentBadges/render.js +1 -1
- package/dist/lib/puck/blocks/general/ProcessSteps/render.js +1 -1
- package/dist/lib/puck/blocks/general/Series/render.js +1 -1
- package/dist/lib/puck/blocks/general/StatsParagraph/render.js +1 -1
- package/dist/lib/puck/blocks/general/Testimonials/render.js +1 -1
- package/dist/lib/puck/blocks/general/Timeline/render.js +2 -2
- package/dist/lib/puck/blocks/general/TimelineTrack/render.js +1 -1
- package/dist/lib/puck/blocks/scaffold.js +1 -1
- package/dist/lib/puck/controls.d.ts +1 -1
- package/dist/lib/puck/controls.js +1 -1
- package/dist/lib/puck/editor-page-context.d.ts +1 -0
- package/dist/lib/puck/editor-page-context.js +1 -1
- package/dist/lib/puck/footer-block-row-name.js +1 -1
- package/dist/lib/puck/page-root-fields.d.ts +4 -1
- package/dist/lib/puck/page-root-fields.js +1 -1
- package/dist/lib/puck/registry.js +1 -1
- package/dist/lib/puck/theme-swatches.js +1 -1
- package/dist/lib/source-rules/editor-chrome-note.js +1 -1
- package/dist/lib/source-rules/editor-words.d.ts +26 -0
- package/dist/lib/source-rules/editor-words.js +3 -0
- package/dist/lib/source-rules/mirrored-rows-agree.js +1 -1
- package/dist/lib/source-rules/part-style-naming.js +1 -1
- package/dist/lib/source-rules/social-icons-import.js +4 -4
- package/dist/lib/source-rules/support/label-extraction.js +2 -2
- package/dist/lib/theme-save-message.js +1 -1
- package/package.json +7 -6
- package/dist/lib/image-focus.d.ts +0 -16
- package/dist/lib/image-focus.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{jsx as
|
|
1
|
+
"use client";import{jsx as r}from"react/jsx-runtime";import b from"./Ticker.js";import{TICKER_JOIN_BOX_CLASS as x,tickerJoinSide as h,tickerJoinStripClass as S}from"../lib/sections/ticker-join.js";import{say as k}from"../lib/editor-words.js";const v=()=>k("item");function y({items:s,durationSec:l=50,tone:a="scrim",borders:c=!0,size:d,separator:m,scroll:p,join:f,editing:u}){const t=(s??[]).map(n=>n?.text?.trim()?n.text:u?v():"").filter(Boolean);if(t.length===0)return null;const i=a!=="plain",e=h(f),o=r("div",{className:[e?`absolute inset-x-0 ${S(e)}`:"relative z-[2]","py-3.5 max-[800px]:py-3",i?"bg-bg":"",c?"border-y border-line":""].filter(Boolean).join(" "),children:r(b,{items:t,durationSec:l,size:d,separator:m,scroll:p,backdrop:i?"themed-band":"themed-section"})});return e?r("div",{className:x,children:o}):o}export{y as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{jsx as o,jsxs as
|
|
1
|
+
"use client";import{jsx as o,jsxs as f}from"react/jsx-runtime";import{useId as T,useMemo as I}from"react";import{useEasel as k}from"efficient-easel/easel";import{SettingsField as x,SettingsSwitch as b}from"efficient-easel/panel";import{EyeIcon as E}from"efficient-easel/icons";import{DEFAULT_TICKER_ITEMS as S}from"./HeroSection.js";import{GroupLabel as g,TextListField as w,TICKER_ITEMS_ROW as a}from"../lib/puck/controls.js";import{say as c}from"../lib/editor-words.js";const _="root:default-zone";function y({heroId:p}){const{appState:l,dispatch:m}=k(e=>e),s=l.data.content??[],r=s.findIndex(e=>e.props.id===p),t=r>=0?s[r]:null,d=t?t.props.showTicker??!0:!0,h=I(()=>{const e=t?.props.tickerItems;return Array.isArray(e)?e:S.map(u=>({text:u}))},[t]),n=T();if(!t)return o("p",{className:"sf-note",children:c("This ticker’s hero is no longer on the page.")});const i=e=>m({type:"replace",destinationZone:_,destinationIndex:r,data:{...t,props:{...t.props,...e}}});return f("div",{children:[o(g,{label:"Ticker"}),o(x,{label:c("Show ticker"),labelId:n,icon:o(E,{}),action:o(b,{checked:d,onChange:e=>i({showTicker:e}),ariaLabelledBy:n})}),o(w,{label:a.label,icon:a.icon,items:h,placeholder:"item",onChange:e=>i({tickerItems:e}),markup:!0})]})}export{y as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as t,jsxs as l}from"react/jsx-runtime";import{SiteLink as b}from"../lib/site-runtime.js";import{renderHeadline as v}from"./goldPhrases.js";function
|
|
1
|
+
import{jsx as t,jsxs as l}from"react/jsx-runtime";import{SiteLink as b}from"../lib/site-runtime.js";import{renderHeadline as v}from"./goldPhrases.js";import{say as w}from"../lib/editor-words.js";function y({title:n,buttons:m,padTop:x,padBottom:o,buttonsAlign:a,editing:p=!1}={}){const d=typeof x=="number"?x:140,c=typeof o=="number"?o:140,r=(m??[]).filter(e=>p||(e.label??"").trim()),i=!!(n??"").trim(),s=!i&&(a==="center"||a==="left")?a:null;return!p&&!i&&r.length===0?null:t("section",{className:"relative z-[2] bg-bg",children:l("div",{className:s==="center"?"mx-auto grid max-w-[var(--sf-site-width,1600px)] grid-cols-1 items-center justify-items-center gap-[60px] border-b border-line px-[var(--sf-site-gutter,40px)] max-[1100px]:px-[min(24px,var(--sf-site-gutter,40px))]":s==="left"?"mx-auto grid max-w-[var(--sf-site-width,1600px)] grid-cols-1 items-center justify-items-start gap-[60px] border-b border-line px-[var(--sf-site-gutter,40px)] max-[1100px]:px-[min(24px,var(--sf-site-gutter,40px))]":"mx-auto grid max-w-[var(--sf-site-width,1600px)] grid-cols-[1fr_auto] items-center gap-[60px] border-b border-line px-[var(--sf-site-gutter,40px)] max-[1100px]:grid-cols-1 max-[1100px]:px-[min(24px,var(--sf-site-gutter,40px))]",style:{paddingTop:d,paddingBottom:c},children:[s===null&&!i&&r.length>0&&t("div",{"aria-hidden":!0,className:"max-[1100px]:hidden"}),i&&t("h2",{className:"max-w-[1000px] font-display text-[length:min(var(--size-headingLarge,clamp(48px,7vw,108px)),var(--sf-heading-max,9999px))] [font-weight:var(--sf-heading-weight,500)] [text-transform:var(--sf-heading-case,uppercase)] [&_em]:[font-weight:var(--sf-heading-weight-strong,inherit)] leading-[0.94] tracking-[-0.035em] text-fg",children:v(n??"")}),r.length>0&&t("div",{className:"flex min-w-[280px] flex-col gap-3.5 max-[1100px]:min-w-0",children:r.map((e,f)=>{const g=(e.label??"").trim()||w("Button label"),h=e.href||"#",u=e.variant==="primary";return l(b,{href:h,className:["flex items-center justify-between gap-6 px-7 py-5","font-mono text-[length:var(--size-label,14px)] uppercase tracking-[0.3em] transition-colors",u?"border border-btn bg-btn text-btn-ink hover:border-fg hover:bg-fg":"border border-line text-fg hover:border-accent hover:text-accent"].join(" "),children:[g," ",t("span",{"aria-hidden":!0,children:"→"})]},f)})})]})})}export{y as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{jsx as
|
|
1
|
+
"use client";import{jsx as r,jsxs as k}from"react/jsx-runtime";import{useCallback as I,useEffect as S,useState as j}from"react";import{ExternalIcon as z}from"efficient-easel/icons";import{Button as K,Tooltip as A,buttonClasses as U}from"efficient-shell/ui";import{SettingsSwitch as Z}from"efficient-easel/panel";import{PagesIcon as q,StylesIcon as X}from"efficient-easel/rail";import{TreeRow as J}from"efficient-easel/tree";import{useEaselStrings as Q}from"efficient-easel/strings";import $ from"./HeadingAudit.js";import{LocationsTreeContext as ee}from"./LocationsTreeContext.js";import te from"./PagesPanel.js";import{usePreviewChat as oe}from"./PreviewChatContext.js";import{PREVIEW_DEVICES as re}from"./preview-devices.js";import{PreviewDeviceContext as ie}from"./PreviewDeviceContext.js";import{usePreviewHeader as se}from"./PreviewHeaderContext.js";import{usePreviewSocial as ne}from"./PreviewSocialContext.js";import{usePreviewSurface as ae}from"./PreviewSurfaceContext.js";import{TICKER_PART_LABEL as ce,usePreviewTicker as le}from"./PreviewTickerContext.js";import de,{CHAT_MODE as pe,HEADER_MODE as B,SOCIAL_MODE as me,WEBSITE_MODE as N}from"./SectionEditor.js";import C from"./SectionIcon.js";import fe from"./SectionThumbnail.js";import{useStorefrontDocument as g}from"./StorefrontDocumentContext.js";import ue from"./StylesPanel.js";import Se from"./TemplateGlyph.js";import{useFooterFocus as Te}from"./useFooterFocus.js";import{LOCATIONS_TYPE as Ee,useLocationsTree as he}from"./useLocationsTree.js";import{usePinnedChromeSeed as we}from"./usePinnedChromeSeed.js";import{usePreviewHref as be}from"./usePreviewHref.js";import{SITE_STYLES_TABS as Pe,SITE_STYLES_TEXT_TAB as ve,useWebsiteName as ke}from"./WebsiteSettingsPanel.js";import{HERO_GROUP_TYPE as Ie,duplicateBlocked as Ce,heroGroupNestDepth as ge}from"../lib/hero-group-placement.js";import{stripMarkup as _e}from"../lib/markup.js";import{categoryShortLabel as Le,PINNED_SECTION_TYPE as ye}from"../lib/puck/add-palette.js";import{canAddTo as Oe}from"../lib/puck/add-target.js";import{blockIsOffered as Ae}from"../lib/puck/block-offer.js";import{sectionIdOfBoxZone as Be,setBookingPreview as Ne}from"../lib/puck/booking-preview.js";import{footerBlockRowName as Re}from"../lib/puck/footer-block-row-name.js";import{FOOTER_TYPE as He,HEADER_TYPE as R}from"../lib/puck/footer-blocks.js";import{leftViewForSelection as De,readLeftView as We,resolveLeftView as xe,writeLeftView as Ve}from"../lib/puck/left-view.js";import{isLockedBlock as Me}from"../lib/puck/locked-blocks.js";import{scrollPreviewToSection as Fe,scrollPreviewToTop as H}from"../lib/puck/preview-dom.js";import{SiteCanvas as Ye}from"../lib/puck/overrides.js";import{labelAtLevel as Ge}from"../lib/puck/section-catalog.js";import{editorWords as je,say as i}from"../lib/editor-words.js";import{SECTION_DESCRIPTIONS as ze}from"../lib/puck/section-descriptions.js";import{isSectionGroupType as Ke,sectionGroupZone as Ue,SITE_FOOTER_TYPE as Ze,SITE_HEADER_TYPE as qe}from"../lib/puck/section-groups.js";import{resolveSaveAsTemplateAction as Xe,SAVE_AS_TEMPLATE_EVENT as Je}from"../lib/save-as-template-action.js";import{newSectionNode as Qe}from"../lib/sections/new-section-node.js";import{useHostProducts as $e}from"../lib/use-host-products.js";function D({mode:e,open:t}){const{setSelectedHeroId:o,setSelectHandler:s}=le(),f=Q().tree,c=e,l=c.kind==="ticker"?c.heroId:null,n=I(d=>{if(!d)return;t({kind:"ticker",heroId:d}),Fe(d)},[t]);return S(()=>{o(l)},[l,o]),S(()=>{s(n)},[s,n]),{partRows:(d,{rowClick:a})=>{const u=String(d.props.id);return d.type==="Hero"&&r(J,{icon:r(C,{type:"ticker",size:13}),name:i(ce),onSelect:()=>n(u),selected:l===u,rowProps:{onClick:a(()=>n(u))},words:f})}}}function et(){const{adapter:e,capabilities:t,currentSlug:o,siteId:s,hasUnsavedEdits:f,bridgeCapabilities:c,notifyParent:l,token:n}=g(),{hasPreviewLink:d}=t,a=Xe({hasTrustedConsole:!!n,canCreatePlatformTemplate:c.canCreatePlatformTemplate,capabilities:t,siteId:s,hasUnsavedEdits:f}),u=I(()=>{!s||!o||l(Je,{siteId:s,slug:o})},[l,s,o]),T=be({pageSlug:o,siteId:s,token:n}),E=e.previewHref?.(o)??T;return{barLead:()=>a.visible&&r(A,{side:"bottom",content:a.enabled?i("Save this website as a platform template"):i(a.disabledReason),children:r("span",{className:"sf-tip-disabled",tabIndex:a.enabled?void 0:0,children:r(K,{variant:"secondary",disabled:!a.enabled,onClick:u,rightIcon:r(Se,{}),children:i("Save as Template")})})}),barTrail:()=>d&&o&&r(A,{content:i("Preview the live site (opens in a new tab)"),children:k("a",{className:U({variant:"secondary"}),href:E,target:"_blank",rel:"noopener noreferrer","aria-label":i("Preview the live site in a new tab"),children:[i("Preview"),r(z,{size:15})]})})}}function tt(){return k("svg",{width:"17",height:"17",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:1.7,strokeLinecap:"round",strokeLinejoin:"round",children:[r("path",{d:"M12 3a9 9 0 0 0 0 18 2.3 2.3 0 0 0 2.3-2.3c0-.55-.22-1.05-.57-1.42-.34-.37-.56-.87-.56-1.43A2.35 2.35 0 0 1 15.6 13.5H18a3 3 0 0 0 3-3c0-4.14-4-7.5-9-7.5z"}),r("circle",{cx:"7.7",cy:"11.3",r:"1.05",fill:"currentColor",stroke:"none"}),r("circle",{cx:"12",cy:"8",r:"1.05",fill:"currentColor",stroke:"none"}),r("circle",{cx:"16",cy:"11",r:"1.05",fill:"currentColor",stroke:"none"})]})}function ot(e,t){const{capabilities:o,templateId:s,siteId:f,tokenRef:c,navigate:l}=g(),{hasSiteTheme:n,explainsSiteSettings:d}=o,a=p=>t.setView(p),[u,T]=j(Pe[0].id),{surface:E,setSurface:b}=ae(),P=()=>{if(n){a("styles"),t.reveal(),H();return}e.show(N),e.reveal(),H()},v={id:"pages",label:i("Pages"),icon:r(q,{}),panel:({onHide:p})=>r(te,{activeSurface:E,onPreviewSurface:b,onNavigate:m=>{b(null),l(s?{kind:"template",id:s,pageSlug:m}:{kind:"page",slug:m,siteId:f??void 0})},onClose:p})},h=[];return!n&&d&&h.push({id:"appearance",label:i("Appearance"),icon:r(tt,{}),active:e.kind==="website",onSelect:P}),n&&h.push({id:"styles",label:i("Site styles"),icon:r(X,{}),panel:({onHide:p,notify:m})=>r(ue,{tokenRef:c,siteId:f??void 0,onClose:p,onNotify:m,tab:u,onTabChange:T})}),{railLead:[v],railTrail:h,resolveLeftView:(p,m)=>xe(p,n,m),openSettings:P,openStyles:()=>{T(ve),a("styles")}}}function rt(e,t,o,s){const{kind:f,open:c}=e,{selected:l,zoneOf:n}=t,d=Te(t,o);S(()=>{Ne(l?.type==="BookingBox"&&l.props.region==="confirm"?Be(n(String(l.props.id))):null)},[l?.props.id]);const a=he(e,t),{capabilities:{hasSiteSettings:u}}=g(),{setSelected:T,setSelectHandler:E}=se(),{chat:b,setChat:P,setSelected:v,setSelectHandler:h}=oe(),p=f==="header";S(()=>{T(p)},[p,T]),S(()=>{E(()=>c(B))},[E,c]);const m=I(()=>c(pe),[c]),L=f==="chat";S(()=>{v(L)},[L,v]),S(()=>{h(m)},[h,m]);const{setOpenHandler:y}=ne(),O=I(()=>c(me),[c]);S(()=>{y(O)},[y,O]);const V=D(e),M=et(),F=ot(e,s),Y=o.device;return{...d,...V,...M,...F,treeFoot:()=>r("div",{className:"sf-tree-tool",children:r($,{})}),hasOwnRows:w=>w.type===Ee,ownRows:a.renderLocationTree,sectionPressed:a.sectionPressed,wrap:w=>r(ee.Provider,{value:!0,children:r(ie.Provider,{value:Y,children:w})}),addPanelRow:w=>u?k("div",{className:"sf-addside-sitewide",children:[r("span",{className:"sf-addside-sitewide-glyph","aria-hidden":"true",children:r(C,{type:"chat",size:16})}),k("button",{type:"button",className:"sf-addside-sitewide-name",onClick:()=>{w(),m()},children:[i("Live chat"),r("span",{className:"sf-addside-sitewide-desc",children:i("A chat bubble on every page")})]}),r(Z,{checked:b.enabled,onChange:G=>P({enabled:G}),ariaLabel:i("Show the chat bubble on the whole site")})]}):void 0}}let W=null,_=new WeakMap;function it(e){const t=je();if(!e||!t)return e;W!==t&&(W=t,_=new WeakMap);let o=_.get(e);return o||(o={...e,choices:e.choices?e.choices.map(s=>({...s,label:i(s.label)})):null,spec:e.spec?{...e.spec,addLabel:i(e.spec.addLabel)}:null},_.set(e,o)),o}const st={isLockedBlock:Me,duplicateBlocked:Ce,nestDepth:(e,t,o)=>t===Ie?ge(e,o):0,newSectionNode:Qe,canAddTo:(e,t)=>it(Oe(e,t)),blockIsOffered:Ae},nt=new Proxy(ze,{get:(e,t)=>{const o=Reflect.get(e,t);return typeof o=="string"?i(o):o}}),at={labelAtLevel:(e,t,o)=>i(Ge(e,t,o)),descriptions:nt,categoryLabel:e=>{const t=Le(e);return t===void 0?void 0:i(t)},firstSection:ye,blockRowName:Re,plainText:_e,Icon:C,Thumbnail:fe,useProducts:$e},ct={desktop:2e3,tablet:800,mobile:390},x="desktop",lt={options:re,initial:x,fluid:x,widths:ct},dt={read:We,write:e=>Ve(e),forSelection:(e,t)=>De(e,t)},pt={first:R,last:He,firstGroup:qe,lastGroup:Ze,isSectionGroup:Ke,sectionGroupZone:Ue,panelOf:e=>e===R?B:null};function mt(e){return{...D(e),openSettings:()=>e.show(N)}}const ao={useOwnerName:ke,useBridges:rt,useStandaloneBridges:mt,useDocumentPass:we,blockRules:st,blockLook:at,devices:lt,leftView:dt,pinned:pt,Canvas:Ye,Inspector:de};export{ao as WEBSITE_SCREEN};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{jsx as n,jsxs as y,Fragment as w}from"react/jsx-runtime";import{useEasel as
|
|
1
|
+
"use client";import{jsx as n,jsxs as y,Fragment as w}from"react/jsx-runtime";import{useEasel as E}from"efficient-easel/easel";import{useEffect as k,useRef as L,useState as b}from"react";import B from"./ThemeField.js";import W from"./CornersField.js";import v from"./CardShadowField.js";import A from"./ShadowColourField.js";import O from"./BlockGapField.js";import j from"./HoverEffectField.js";import Y from"./HeroImageField.js";import U from"./PhotographyField.js";import X from"./SideSpaceField.js";import M from"./SiteWidthField.js";import q from"./TextStylesField.js";import{usePreviewHeader as m}from"./PreviewHeaderContext.js";import{SettingsTabs as J}from"efficient-easel/panel";import{Tooltip as Z,tabButtonId as $,tabPanelId as K}from"efficient-shell/ui";import{ContrastIcon as Q,NoteIcon as V,SettingsIcon as D,TypeIcon as ee}from"efficient-easel/icons";import{useThemeRowPersist as oe}from"../lib/theme-row-persist.js";import{themeSaveNotice as te}from"../lib/theme-save-message.js";import{say as T}from"../lib/editor-words.js";import{NEUTRAL_SITE_NAME as ne}from"../lib/content/site-name.js";import{normalizeFonts as re}from"../lib/fonts.js";import{previewFrame as se}from"../lib/puck/preview-dom.js";import{CORNER_STYLE_TO_PX as ie,normalizeCornerRadius as ae,normalizeCornerStyle as ce,normalizeShadowColor as le,headingTypographyToRow as pe,normalizeHeadingCompression as de,normalizeHeadingTypography as he,DEFAULT_SIZES as ue}from"../lib/theme.js";const F="sf-site-styles",ge="sf-site-styles-tabpanel",fe=!1,me="Show hints";function Se({shown:e,onChange:o}){return n("div",{className:"sf-hints",children:y("button",{type:"button","aria-pressed":e,onClick:()=>o(!e),className:`sf-rung sf-hints-toggle${e?" is-active":""}`,children:[n(V,{size:13}),T(me)]})})}const So="text",R=[{id:"basics",label:"Basics",icon:n(D,{})},{id:"theme",label:"Theme",icon:n(Q,{})},{id:"text",label:"Text",icon:n(ee,{})}];function Ce({themeFromDocument:e,persist:o}){const{appState:s,dispatch:r}=E(u=>u),{theme:a,setTheme:t}=m(),c=s.data,h=c.root?.props??{},i=u=>{if(e){const f={...h,theme:u};r({type:"replaceRoot",root:{...c.root,props:f},recordHistory:!0})}else t(u);o({selected_preset:u.selected,theme_presets:u.themes})};return n(B,{value:e?h.theme:a,onChange:i})}function ye(e,o){const[s,r]=b(null),a=L(null),t=JSON.stringify(e),c=L(o);return c.current=o,k(()=>{if(a.current===null){a.current=t;return}if(a.current===t)return;a.current=t;const h=window.setTimeout(()=>r(c.current),700),i=window.setTimeout(()=>r(null),2200);return()=>{window.clearTimeout(h),window.clearTimeout(i)}},[t]),s}function _e({themeFromDocument:e,persist:o}){const{appState:s,dispatch:r}=E(p=>p),[a,t]=b(null),{fonts:c,setFonts:h,sizes:i,setSizes:u,headingCompression:f,setHeadingCompression:_,headingTypography:C,setHeadingTypography:l}=m(),x=s.data,g=x.root?.props??{},S=e?re(g.fonts):c,z=e?ue:i,I=e?de(g.headingCompression):f,N=e?he(g.headingTypography):C,H=p=>r({type:"replaceRoot",root:{...x.root,props:{...g,...p}},recordHistory:!0}),G=ye({curFonts:S,curCompression:I,curTypography:N},a);return n(q,{fonts:S,sizes:z,compression:I,headingTypography:N,openRole:a,onOpenRole:t,onFontChange:(p,P)=>{const d={...S,[p]:P};e?H({fonts:d}):h(d),o({heading_font:d.heading,body_font:d.body,accent_font:d.accent,label_font:d.label})},onSizeChange:e?void 0:(p,P)=>{const d={...z,[p]:P};u(d),o({heading_size_large_px:d.headingLarge,heading_size_medium_px:d.headingMedium,heading_size_small_px:d.headingSmall,accent_size_px:d.accent,body_size_px:d.body,label_size_px:d.label})},onCompressionChange:p=>{e?H({headingCompression:p}):_(p),o({heading_compression:p})},onHeadingTypographyChange:p=>{e?H({headingTypography:p}):l(p),o(pe(p))},livePx:Te,savedRole:G})}const we={heading:"main h1, main h2",heading2:"main h1, main h2",heading3:"main h1, main h2",accent:"main h1 em, main h2 em",body:"main p",label:"main .mono-eyebrow"};function Te(e){if(typeof document>"u")return null;const s=(se()?.contentDocument??document).querySelector(we[e]);if(!s)return null;const r=parseFloat(getComputedStyle(s).fontSize);return Number.isFinite(r)?r:null}function xe({themeFromDocument:e,persist:o,showHint:s}){const{appState:r,dispatch:a}=E(l=>l),{cornerRadiusPx:t,setCornerRadiusPx:c}=m(),h=r.data,i=h.root?.props??{},u=i.cornerRadiusPx===void 0?ie[ce(i.cornerStyle)]:ae(i.cornerRadiusPx),f=e?u:t,_=l=>a({type:"replaceRoot",root:{...h.root,props:{...i,...l}},recordHistory:!0});return n(W,{value:f,onChange:l=>{e?_({cornerRadiusPx:l}):c(l),o({corner_radius_px:l})},showHint:s})}function be(e){return{site_width:e}}function Re({persist:e,showHint:o}){const{siteWidth:s,setSiteWidth:r}=m();return n(M,{value:s,onChange:t=>{r(t),e(be(t),t===null)},showHint:o})}function He(e){return{block_gap:e}}function Pe(e){return{site_gutter:e}}function Ee({persist:e,showHint:o}){const{siteGutter:s,setSiteGutter:r}=m();return n(X,{value:s,onChange:t=>{r(t),e(Pe(t),t===null)},showHint:o})}function Fe({persist:e,showHint:o}){const{blockGap:s,setBlockGap:r}=m();return n(O,{value:s,onChange:t=>{r(t),e(He(t),t===null)},showHint:o})}function ze({persist:e,showHint:o}){const{heroBackgroundFollowsWidth:s,setHeroBackgroundFollowsWidth:r}=m();return n(Y,{value:s,onChange:t=>{r(t),e({hero_background_follows_width:t},!0)},showHint:o})}function Ie({persist:e,showHint:o=!0}){return y(w,{children:[n(Re,{persist:e,showHint:o}),n(Ee,{persist:e,showHint:o}),n(Fe,{persist:e,showHint:o}),n(ze,{persist:e,showHint:o})]})}function Ne(e){return{card_shadow:e}}function Le(e){return e===null?{shadow_color:null}:{shadow_color:le(e)}}function Ge(e){return{hover_effect:e}}function ke({persist:e,showHint:o=!0}){const{cardShadow:s,setCardShadow:r,shadowColor:a,setShadowColor:t,hoverEffect:c,setHoverEffect:h}=m();return y(w,{children:[n(v,{value:s,onChange:i=>{r(i),e(Ne(i),!0)},showHint:o}),n(A,{value:a,onChange:i=>{t(i),e(Le(i),i===null)},showHint:o}),n(j,{value:c,onChange:i=>{h(i),e(Ge(i),!0)},showHint:o})]})}function Be(e){return{photography_grayscale:e}}function We({persist:e,showHint:o}){const{photographyGrayscale:s,setPhotographyGrayscale:r}=m();return n(U,{value:s,onChange:t=>{r(t),e(Be(t),!0)},showHint:o})}function ve({persist:e,showHint:o=!0}){return n(w,{children:n(We,{persist:e,showHint:o})})}function Ae(){const{websiteName:e}=m();return e?.trim()||ne}function Co(){const e=Ae();return n(Z,{content:T("{name} — renamed in the Console: {place}.",{name:e,place:T("Storefront ▸ Sites ▸ Settings")}),className:"sf-name-tip",children:n("span",{className:"sf-panel-site",children:e})})}function Oe({themeFromDocument:e=!1,tokenRef:o,siteId:s,onNotify:r,tab:a,onTabChange:t}){const{persist:c}=oe({themeFromDocument:e,tokenRef:o,siteId:s,onResult:g=>{const S=te(g);S&&r?.(S.msg,S.tone)}}),[h,i]=b(R[0].id),u=a!==void 0,f=u?a:h,_=u?t??(()=>{}):i,C=R.find(g=>g.id===f)??R[0],[l,x]=b(fe);return y(w,{children:[n(J,{items:R.map(g=>({...g,label:T(g.label)})),activeId:C.id,onSelect:_,ariaLabel:T("Site styles"),idPrefix:F}),y("div",{id:K(F,C.id),className:ge,role:"tabpanel","aria-labelledby":$(F,C.id),children:[f==="basics"&&y(w,{children:[n(xe,{themeFromDocument:e,persist:c,showHint:l}),!e&&n(ke,{persist:c,showHint:l}),!e&&n(Ie,{persist:c,showHint:l}),!e&&n(ve,{persist:c,showHint:l}),n(Se,{shown:l,onChange:x})]}),f==="theme"&&n(Ce,{themeFromDocument:e,persist:c}),f==="text"&&n(_e,{themeFromDocument:e,persist:c})]})]})}export{ke as CardLookFields,Se as HintsToggle,Ie as PageGroupFields,ve as PhotographyGroupFields,fe as SHOW_HINTS_DEFAULT,F as SITE_STYLES_ID_PREFIX,R as SITE_STYLES_TABS,So as SITE_STYLES_TEXT_TAB,ge as TABPANEL_CLASS,Co as WebsiteNameReadonly,He as blockGapPatch,Ne as cardShadowPatch,Oe as default,Ge as hoverEffectPatch,Be as photographyPatch,Le as shadowColourPatch,Pe as siteGutterPatch,be as siteWidthPatch,Ae as useWebsiteName};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{jsx as t}from"react/jsx-runtime";import{SettingsDefaultReset as
|
|
1
|
+
"use client";import{jsx as t}from"react/jsx-runtime";import{SettingsDefaultReset as u,SettingsField as p,SettingsSegmented as h}from"efficient-easel/panel";import{WidthIcon as g}from"efficient-easel/icons";import{say as o,editorEaselWords as b}from"../lib/editor-words.js";import{WIDTH_CHOICE_LABEL as d}from"../lib/content/section-width.js";function W({value:l,resolved:a,onChange:i,label:s="Width",labelId:r,followsLabel:f,hint:c}){const e=l===void 0,m=e?a:l,n=o(s);return t(p,{label:n,labelId:r,icon:t(g,{}),value:e?f:void 0,changed:!e,action:t(u,{words:b()?.panel,label:n,changed:!e,onReset:()=>i(void 0)}),hint:c,children:t(h,{options:[{label:o(d.page),id:"content"},{label:o(d.full),id:"full"}],value:m,ariaLabel:n,onChange:i})})}export{W as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{jsx as
|
|
1
|
+
"use client";import{jsx as t}from"react/jsx-runtime";import{DesktopIcon as E,PhoneIcon as I,TabletIcon as e}from"efficient-easel/icons";import{say as m}from"../lib/editor-words.js";import{VIEW_TIERS as n,VIEW_TIER_LABEL as r}from"../lib/content/view-tiers.js";const s={desktop:t(E,{}),tablet:t(e,{}),mobile:t(I,{})},l=n.map(o=>({id:o,get label(){return m(r[o])},icon:s[o]}));export{l as PREVIEW_DEVICES};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as
|
|
1
|
+
import{jsx as d}from"react/jsx-runtime";import{IconBrandFacebook as t,IconBrandFacebookFilled as c,IconBrandInstagram as r,IconBrandInstagramFilled as s,IconBrandLine as I,IconBrandLinkedin as u,IconBrandLinkedinFilled as B,IconBrandPinterest as p,IconBrandPinterestFilled as k,IconBrandTelegram as h,IconBrandTiktok as M,IconBrandTiktokFilled as F,IconBrandWechat as f,IconBrandWhatsapp as z,IconBrandWhatsappFilled as m,IconBrandX as S,IconBrandXFilled as b,IconBrandYoutube as j,IconBrandYoutubeFilled as E,createReactComponent as n}from"@tabler/icons-react";const v="outline",L={fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},T={},o={fillRule:"evenodd"},g=[["path",{...L,d:"M21 4L3 11L7 13L9 19L12 15L17 20z"}],["path",{...o,d:"M21 4L3 11L7 13L9 19L12 15L17 20zM15.212 8.939 10.576 13.576 11.424 14.424 16.061 9.788z"}]],A=[["path",{...L,d:["M21 10.663c0 -4.224 -4.041 -7.663 -9 -7.663s-9 3.439 -9 7.663","c0 3.783 3.201 6.958 7.527 7.56c1.053 .239 .932 .644 .696 2.133","c-.039 .238 -.184 .932 .777 .512c.96 -.42 5.18 -3.201 7.073 -5.48","c1.304 -1.504 1.927 -3.029 1.927 -4.715v-.01z"].join("")}],["path",{...T,d:["M21 10.663c0 -4.224 -4.041 -7.663 -9 -7.663s-9 3.439 -9 7.663","c0 3.783 3.201 6.958 7.527 7.56c1.053 .239 .932 .644 .696 2.133","c-.039 .238 -.184 .932 .777 .512c.96 -.42 5.18 -3.201 7.073 -5.48","c1.304 -1.504 1.927 -3.029 1.927 -4.715v-.01z"].join("")}]],W=[["path",{...L,d:["M16.5 10c3.038 0 5.5 2.015 5.5 4.5c0 1.397 -.778 2.645 -2 3.47l0 2.03l-1.964 -1.178","a6.649 6.649 0 0 1 -1.536 .178c-3.038 0 -5.5 -2.015 -5.5 -4.5s2.462 -4.5 5.5 -4.5z"].join("")}],["path",{...L,d:["M8.319 15.972L7.84 15.918L7.349 15.832L6.865 15.715L6.388 15.568L4 17L4 14.199","L3.559 13.775L3.197 13.356L2.877 12.91L2.603 12.439L2.376 11.946L2.201 11.433","L2.079 10.902L2.016 10.405L2.001 9.897L2.036 9.386L2.12 8.889L2.25 8.405L2.425 7.937","L2.642 7.486L2.9 7.055L3.195 6.645L3.459 6.333L3.744 6.037L4.05 5.757L4.377 5.495","L4.723 5.25L5.086 5.025L5.467 4.819L5.864 4.634L6.275 4.471L6.701 4.331L7.139 4.214","L7.589 4.122L8.05 4.055L8.521 4.014L9.352 4.007L9.815 4.04L10.269 4.098L10.713 4.181","L11.146 4.287L11.567 4.416L11.975 4.567L12.369 4.739L12.748 4.932L13.112 5.143","L13.459 5.374L13.788 5.622L14.172 5.956L14.458 6.241L14.722 6.542L14.965 6.856","L15.217 7.237A8.35 7.35 0 0 0 8.319 15.972z"].join("")}],["path",{...o,d:["M8.319 15.972L7.84 15.918L7.349 15.832L6.865 15.715L6.388 15.568L4 17L4 14.199","L3.559 13.775L3.197 13.356L2.877 12.91L2.603 12.439L2.376 11.946L2.201 11.433","L2.079 10.902L2.016 10.405L2.001 9.897L2.036 9.386L2.12 8.889L2.25 8.405L2.425 7.937","L2.642 7.486L2.9 7.055L3.195 6.645L3.459 6.333L3.744 6.037L4.05 5.757L4.377 5.495","L4.723 5.25L5.086 5.025L5.467 4.819L5.864 4.634L6.275 4.471L6.701 4.331L7.139 4.214","L7.589 4.122L8.05 4.055L8.521 4.014L9.352 4.007L9.815 4.04L10.269 4.098L10.713 4.181","L11.146 4.287L11.567 4.416L11.975 4.567L12.369 4.739L12.748 4.932L13.112 5.143","L13.459 5.374L13.788 5.622L14.172 5.956L14.458 6.241L14.722 6.542L14.965 6.856","L15.217 7.237A8.35 7.35 0 0 0 8.319 15.972zM5.25 7.9a0.85 0.85 0 1 0 1.7 0","a0.85 0.85 0 1 0 -1.7 0zM8.25 7.9a0.85 0.85 0 1 0 1.7 0a0.85 0.85 0 1 0 -1.7 0z"].join("")}],["path",{...o,d:["M16.5 10c3.038 0 5.5 2.015 5.5 4.5c0 1.397 -.778 2.645 -2 3.47l0 2.03l-1.964 -1.178","a6.649 6.649 0 0 1 -1.536 .178c-3.038 0 -5.5 -2.015 -5.5 -4.5s2.462 -4.5 5.5 -4.5z","M14.15 14a0.85 0.85 0 1 0 1.7 0a0.85 0.85 0 1 0 -1.7 0zM17.15 14","a0.85 0.85 0 1 0 1.7 0a0.85 0.85 0 1 0 -1.7 0z"].join("")}]],_=n("filled","brand-telegram-filled","BrandTelegramFilled",g),O=n("filled","brand-line-filled","BrandLineFilled",A),x=n("filled","brand-wechat-filled","BrandWechatFilled",W),C={instagram:{outline:r,solid:s},facebook:{outline:t,solid:c},tiktok:{outline:M,solid:F},youtube:{outline:j,solid:E},x:{outline:S,solid:b},linkedin:{outline:u,solid:B},pinterest:{outline:p,solid:k},whatsapp:{outline:z,solid:m},telegram:{outline:h,solid:_},line:{outline:I,solid:O},wechat:{outline:f,solid:x}};function w({platform:e,iconStyle:a,size:l}){const i=C[e][a];return d(i,{size:l,stroke:1.75,"aria-hidden":"true",focusable:"false"})}export{v as DEFAULT_SOCIAL_ICON_STYLE,w as SocialMark};
|