efficient-easel 11.8.0 → 12.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/README.md +24 -0
- package/dist/{chunk-4ES5JGGX.js → chunk-3Z2MVLCD.js} +1 -1
- package/dist/{chunk-HRUMNRYI.js → chunk-4EI6UGGH.js} +1 -1
- package/dist/chunk-5AIA5VIP.js +1 -0
- package/dist/chunk-6OA4UXKZ.js +2 -0
- package/dist/{chunk-UBAYMWCX.js → chunk-BPZQ7S2Z.js} +12 -12
- package/dist/chunk-DWIOHQG7.js +1 -0
- package/dist/{chunk-6TJ2CIMY.js → chunk-ENXLPJ77.js} +1 -1
- package/dist/chunk-FZ3Y3QTQ.js +5 -0
- package/dist/chunk-GYNIDJKN.js +57 -0
- package/dist/chunk-H5QI34FV.js +1 -0
- package/dist/{chunk-URC5Y5G2.js → chunk-J2JDC3EZ.js} +1 -1
- package/dist/{chunk-7BRKNQF7.js → chunk-J54OXLQF.js} +1 -1
- package/dist/chunk-M4CNCPHA.js +1 -0
- package/dist/{chunk-FHLYUIJJ.js → chunk-NBDMTIU2.js} +2 -2
- package/dist/{chunk-KEWQZYUF.js → chunk-NQXFINT2.js} +3 -3
- package/dist/{chunk-EC2I7SIY.js → chunk-O5XI3WAQ.js} +1 -1
- package/dist/chunk-PIND6KE7.js +1 -0
- package/dist/{chunk-5IUS6PM6.js → chunk-PVAIOBBE.js} +5 -5
- package/dist/{chunk-ATF2T5CI.js → chunk-S2MMPHKD.js} +1 -1
- package/dist/{chunk-6IT5H37Y.js → chunk-TLDRFVD2.js} +1 -1
- package/dist/chunk-WUSJ6SSF.js +5 -0
- package/dist/{chunk-PS5BWS4I.js → chunk-ZIFDZGY7.js} +1 -1
- package/dist/copy/index.js +1 -1
- package/dist/draw/client.d.ts +6 -0
- package/dist/draw/client.js +1 -0
- package/dist/draw/index.d.ts +8 -0
- package/dist/draw/index.js +1 -0
- package/dist/easel/index.js +1 -1
- package/dist/fields/index.js +1 -1
- package/dist/index.js +1 -1
- package/dist/pick/index.d.ts +30 -8
- package/dist/pick/index.js +3 -7
- package/dist/pick/pick.css +6 -80
- package/dist/screen/components/AddBlockRow.js +1 -1
- package/dist/screen/components/AddSidePanel.js +1 -1
- package/dist/screen/components/MediaSidePanel.js +1 -1
- package/dist/screen/components/NodeContextMenu.js +1 -1
- package/dist/screen/components/PageEditGuardNotices.js +1 -1
- package/dist/screen/components/ScreenChrome.js +1 -1
- package/dist/screen/components/ScreenDocumentContext.js +1 -1
- package/dist/screen/components/ScreenMount.js +1 -1
- package/dist/screen/components/ScreenStoreProvider.js +1 -1
- package/dist/screen/components/SectionScreenShell.js +16 -16
- package/dist/screen/components/UiIcon.js +1 -2
- package/dist/screen/components/usePartBridge.js +1 -1
- package/dist/screen/index.js +1 -1
- package/dist/screen/lib/content/view-tiers.js +1 -1
- package/dist/screen/lib/key-scope.js +1 -1
- package/dist/screen/lib/puck/device-fields.js +1 -1
- package/dist/screen/lib/puck/preview-dom.js +1 -1
- package/dist/screen/lib/puck/style-clipboard.js +1 -1
- package/dist/screen/lib/puck/text-control-kinds.js +1 -1
- package/dist/screen/lib/puck/use-section-ops.js +1 -1
- package/dist/screen/lib/screen-parts.js +1 -1
- package/dist/strings/catalogue.js +1 -1
- package/dist/strings/index.js +1 -1
- package/dist/text-styles/index.d.ts +12 -4
- package/dist/text-styles/index.js +36 -35
- package/dist/text-styles/model.d.ts +9 -1
- package/package.json +13 -3
- package/dist/chunk-A6PY6C3C.js +0 -1
- package/dist/chunk-DE35IQ4T.js +0 -57
- package/dist/chunk-H6IXH4A3.js +0 -1
- package/dist/chunk-JHYKRGRA.js +0 -5
- package/dist/chunk-JRRYFSCY.js +0 -5
- package/dist/chunk-LZS7JZK5.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
export{ScreenChrome as default}from"../../chunk-
|
|
1
|
+
export{ScreenChrome as default}from"../../chunk-GYNIDJKN.js";import"../../chunk-M4CNCPHA.js";import"../../chunk-FGNR22NY.js";import"../../chunk-2GVCAIPX.js";import"../../chunk-26OOWIJJ.js";import"../../chunk-NBDMTIU2.js";import"../../chunk-MQNBD6AB.js";import"../../chunk-ZE7I3PLX.js";import"../../chunk-7F52SZOI.js";import"../../chunk-W4U4SHKW.js";import"../../chunk-RKTF5XLP.js";import"../../chunk-3Z2MVLCD.js";import"../../chunk-4EI6UGGH.js";import"../../chunk-TZIIRGVY.js";import"../../chunk-H5QI34FV.js";import"../../chunk-S2MMPHKD.js";import"../../chunk-KCBEE2MC.js";import"../../chunk-5545A3PC.js";import"../../chunk-WUSJ6SSF.js";import"../../chunk-PA3PNTVV.js";import"../../chunk-5ZBY24K7.js";import"../../chunk-BVN33R76.js";import"../../chunk-62VPYC7F.js";import"../../chunk-J2JDC3EZ.js";import"../../chunk-O5XI3WAQ.js";import"../../chunk-ENXLPJ77.js";import"../../chunk-ZIFDZGY7.js";import"../../chunk-ERR437B5.js";import"../../chunk-GMCZXMOV.js";import"../../chunk-HNKB2ZYR.js";import"../../chunk-CLOS6SSX.js";import"../../chunk-S4AWJX4Q.js";import"../../chunk-KG7RJWOK.js";import"../../chunk-VPFNZ7TB.js";import"../../chunk-LOMEH6DG.js";import"../../chunk-RLBXE4EU.js";import"../../chunk-KCOBHPN6.js";import"../../chunk-O7Q4DDJT.js";import"../../chunk-RSCMJIWS.js";import"../../chunk-UMDQ6CLQ.js";import"../../chunk-V7U33NF2.js";import"../../chunk-6WY6ZXJG.js";import"../../chunk-HQ4VVRIC.js";import"../../chunk-FZ3Y3QTQ.js";import"../../chunk-R6WTQWAC.js";import"../../chunk-U3JP4VGF.js";import"../../chunk-BXMXTO36.js";import"../../chunk-OSPUG6S6.js";import"../../chunk-WK3AFPXY.js";import"../../chunk-VVPZMWJE.js";import"../../chunk-BSPCSC45.js";import"../../chunk-I54UCYOU.js";import"../../chunk-GOTN2KY4.js";import"../../chunk-R5L2E7JX.js";import"../../chunk-IQ5TA7AM.js";import"../../chunk-TBF5CVPA.js";import"../../chunk-DUVRZ456.js";import"../../chunk-6W7WLPZH.js";import"../../chunk-IYT6NN2J.js";import"../../chunk-PLVEGYK6.js";import"../../chunk-PVAIOBBE.js";import"../../chunk-TBY3DFKS.js";import"../../chunk-ECM5F6JJ.js";import"../../chunk-BPZQ7S2Z.js";import"../../chunk-XWFH2NHZ.js";import"../../chunk-4JSBIW5H.js";import"../../chunk-K56YDHYQ.js";import"../../chunk-EA2HTX37.js";import"../../chunk-RC25EGHD.js";import"../../chunk-KFV7N2DJ.js";import"../../chunk-YRLPFZW3.js";import"../../chunk-4VJATVVR.js";import"../../chunk-NDRZP6YR.js";import"../../chunk-H6DDIBQ4.js";import"../../chunk-IE55HNMA.js";import"../../chunk-Z6PVRXVY.js";import"../../chunk-THWO5YVZ.js";import"../../chunk-RE4LP46F.js";import"../../chunk-MJM6SFD3.js";import"../../chunk-2OAZYSWJ.js";import"../../chunk-NY7HHUGB.js";import"../../chunk-33C6ALT5.js";import"../../chunk-2XMHLXMA.js";import"../../chunk-G3GWAP5R.js";import"../../chunk-WRFD4EXD.js";import"../../chunk-36LVP5WD.js";import"../../chunk-MFIRYGHW.js";import"../../chunk-QFVRMARS.js";import"../../chunk-AYWN5NRH.js";import"../../chunk-67GNT6PF.js";import"../../chunk-P2VEMZH5.js";import"../../chunk-ILXP5VX5.js";import"../../chunk-KRXQM65X.js";import"../../chunk-NKB3KVAB.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{ScreenDocumentContext,ScreenDocumentProvider,useScreenDocument}from"../../chunk-
|
|
1
|
+
export{ScreenDocumentContext,ScreenDocumentProvider,useScreenDocument}from"../../chunk-ZIFDZGY7.js";import"../../chunk-ERR437B5.js";import"../../chunk-GMCZXMOV.js";import"../../chunk-HNKB2ZYR.js";import"../../chunk-CLOS6SSX.js";import"../../chunk-S4AWJX4Q.js";import"../../chunk-KG7RJWOK.js";import"../../chunk-VPFNZ7TB.js";import"../../chunk-LOMEH6DG.js";import"../../chunk-RLBXE4EU.js";import"../../chunk-KCOBHPN6.js";import"../../chunk-O7Q4DDJT.js";import"../../chunk-RSCMJIWS.js";import"../../chunk-R6WTQWAC.js";import"../../chunk-U3JP4VGF.js";import"../../chunk-VVPZMWJE.js";import"../../chunk-NDRZP6YR.js";import"../../chunk-H6DDIBQ4.js";import"../../chunk-THWO5YVZ.js";import"../../chunk-RE4LP46F.js";import"../../chunk-MFIRYGHW.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{DocumentScreen,ScreenMount as default}from"../../chunk-
|
|
1
|
+
export{DocumentScreen,ScreenMount as default}from"../../chunk-NQXFINT2.js";import"../../chunk-GXQCZJOP.js";import"../../chunk-GYNIDJKN.js";import"../../chunk-M4CNCPHA.js";import"../../chunk-FGNR22NY.js";import"../../chunk-2GVCAIPX.js";import"../../chunk-26OOWIJJ.js";import"../../chunk-NBDMTIU2.js";import"../../chunk-MQNBD6AB.js";import"../../chunk-ZE7I3PLX.js";import"../../chunk-7F52SZOI.js";import"../../chunk-W4U4SHKW.js";import"../../chunk-RKTF5XLP.js";import"../../chunk-J54OXLQF.js";import"../../chunk-3Z2MVLCD.js";import"../../chunk-4EI6UGGH.js";import"../../chunk-TZIIRGVY.js";import"../../chunk-H5QI34FV.js";import"../../chunk-S2MMPHKD.js";import"../../chunk-KCBEE2MC.js";import"../../chunk-5545A3PC.js";import"../../chunk-WUSJ6SSF.js";import"../../chunk-PA3PNTVV.js";import"../../chunk-5ZBY24K7.js";import"../../chunk-BVN33R76.js";import"../../chunk-62VPYC7F.js";import"../../chunk-J2JDC3EZ.js";import"../../chunk-O5XI3WAQ.js";import"../../chunk-ENXLPJ77.js";import"../../chunk-ZIFDZGY7.js";import"../../chunk-ERR437B5.js";import"../../chunk-GMCZXMOV.js";import"../../chunk-HNKB2ZYR.js";import"../../chunk-CLOS6SSX.js";import"../../chunk-S4AWJX4Q.js";import"../../chunk-KG7RJWOK.js";import"../../chunk-VPFNZ7TB.js";import"../../chunk-LOMEH6DG.js";import"../../chunk-RLBXE4EU.js";import"../../chunk-KCOBHPN6.js";import"../../chunk-O7Q4DDJT.js";import"../../chunk-RSCMJIWS.js";import"../../chunk-UMDQ6CLQ.js";import"../../chunk-V7U33NF2.js";import"../../chunk-6WY6ZXJG.js";import"../../chunk-HQ4VVRIC.js";import"../../chunk-FZ3Y3QTQ.js";import"../../chunk-R6WTQWAC.js";import"../../chunk-U3JP4VGF.js";import"../../chunk-BXMXTO36.js";import"../../chunk-OSPUG6S6.js";import"../../chunk-WK3AFPXY.js";import"../../chunk-VVPZMWJE.js";import"../../chunk-BSPCSC45.js";import"../../chunk-I54UCYOU.js";import"../../chunk-GOTN2KY4.js";import"../../chunk-R5L2E7JX.js";import"../../chunk-IQ5TA7AM.js";import"../../chunk-TBF5CVPA.js";import"../../chunk-DUVRZ456.js";import"../../chunk-6W7WLPZH.js";import"../../chunk-IYT6NN2J.js";import"../../chunk-PLVEGYK6.js";import"../../chunk-PVAIOBBE.js";import"../../chunk-TBY3DFKS.js";import"../../chunk-ECM5F6JJ.js";import"../../chunk-BPZQ7S2Z.js";import"../../chunk-XWFH2NHZ.js";import"../../chunk-4JSBIW5H.js";import"../../chunk-K56YDHYQ.js";import"../../chunk-EA2HTX37.js";import"../../chunk-RC25EGHD.js";import"../../chunk-KFV7N2DJ.js";import"../../chunk-YRLPFZW3.js";import"../../chunk-4VJATVVR.js";import"../../chunk-NDRZP6YR.js";import"../../chunk-H6DDIBQ4.js";import"../../chunk-IE55HNMA.js";import"../../chunk-Z6PVRXVY.js";import"../../chunk-THWO5YVZ.js";import"../../chunk-RE4LP46F.js";import"../../chunk-MJM6SFD3.js";import"../../chunk-2OAZYSWJ.js";import"../../chunk-NY7HHUGB.js";import"../../chunk-33C6ALT5.js";import"../../chunk-2XMHLXMA.js";import"../../chunk-G3GWAP5R.js";import"../../chunk-WRFD4EXD.js";import"../../chunk-36LVP5WD.js";import"../../chunk-MFIRYGHW.js";import"../../chunk-QFVRMARS.js";import"../../chunk-AYWN5NRH.js";import"../../chunk-67GNT6PF.js";import"../../chunk-P2VEMZH5.js";import"../../chunk-ILXP5VX5.js";import"../../chunk-KRXQM65X.js";import"../../chunk-NKB3KVAB.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{ScreenStoreProvider as default}from"../../chunk-
|
|
1
|
+
export{ScreenStoreProvider as default}from"../../chunk-J54OXLQF.js";import"../../chunk-FZ3Y3QTQ.js";import"../../chunk-R6WTQWAC.js";import"../../chunk-U3JP4VGF.js";import"../../chunk-PLVEGYK6.js";import"../../chunk-PVAIOBBE.js";import"../../chunk-TBY3DFKS.js";import"../../chunk-ECM5F6JJ.js";import"../../chunk-BPZQ7S2Z.js";import"../../chunk-XWFH2NHZ.js";import"../../chunk-4JSBIW5H.js";import"../../chunk-K56YDHYQ.js";import"../../chunk-EA2HTX37.js";import"../../chunk-RC25EGHD.js";import"../../chunk-KFV7N2DJ.js";import"../../chunk-YRLPFZW3.js";import"../../chunk-NY7HHUGB.js";import"../../chunk-33C6ALT5.js";import"../../chunk-2XMHLXMA.js";import"../../chunk-G3GWAP5R.js";import"../../chunk-WRFD4EXD.js";import"../../chunk-36LVP5WD.js";import"../../chunk-MFIRYGHW.js";import"../../chunk-67GNT6PF.js";import"../../chunk-P2VEMZH5.js";import"../../chunk-ILXP5VX5.js";import"../../chunk-KRXQM65X.js";import"../../chunk-NKB3KVAB.js";
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import{AddBlockRow as e}from"../../chunk-
|
|
2
|
-
return
|
|
3
|
-
return
|
|
4
|
-
/* @__PURE__
|
|
5
|
-
return
|
|
6
|
-
/* @__PURE__
|
|
7
|
-
/* @__PURE__
|
|
8
|
-
/* @__PURE__
|
|
9
|
-
/* @__PURE__
|
|
10
|
-
/* @__PURE__
|
|
11
|
-
return
|
|
12
|
-
/* @__PURE__
|
|
13
|
-
/* @__PURE__
|
|
14
|
-
/* @__PURE__
|
|
15
|
-
/* @__PURE__
|
|
16
|
-
/* @__PURE__
|
|
1
|
+
import{AddBlockRow as e}from"../../chunk-TLDRFVD2.js";import{scrollPreviewToSection as n,gotoPreviewSlide as o}from"../../chunk-3Z2MVLCD.js";import{useEaselUndoKeys as r}from"../../chunk-4EI6UGGH.js";import{DEFAULT_PANEL_W as t}from"../../chunk-TZIIRGVY.js";import{usePartBridge as s}from"../../chunk-H5QI34FV.js";import{useSectionOps as i}from"../../chunk-S2MMPHKD.js";import{SlotChildActionsProvider as c}from"../../chunk-KCBEE2MC.js";import{MediaSidePanel as p}from"../../chunk-J2JDC3EZ.js";import{useScreenDocument as l}from"../../chunk-ZIFDZGY7.js";import"../../chunk-ERR437B5.js";import"../../chunk-GMCZXMOV.js";import"../../chunk-HNKB2ZYR.js";import"../../chunk-CLOS6SSX.js";import"../../chunk-S4AWJX4Q.js";import"../../chunk-KG7RJWOK.js";import"../../chunk-VPFNZ7TB.js";import"../../chunk-LOMEH6DG.js";import"../../chunk-RLBXE4EU.js";import"../../chunk-KCOBHPN6.js";import"../../chunk-O7Q4DDJT.js";import"../../chunk-RSCMJIWS.js";import"../../chunk-HQ4VVRIC.js";import{SELECTION_MODE as m,useScreenPinned as d,useScreenCanvasFrame as a,useScreenInspectorPanel as u,useScreenPickFollowsSelection as h,sameInspectorMode as k,useStandaloneScreenBridges as f,useScreenBlockLook as j,useScreenBlockRules as y}from"../../chunk-FZ3Y3QTQ.js";import{useMediaPanel as N,usePanelPick as S,useCancelPanelPick as C}from"../../chunk-R6WTQWAC.js";import{useHostEscape as R}from"../../chunk-U3JP4VGF.js";import{DEFAULT_SCREEN_WORDS as P}from"../../chunk-VVPZMWJE.js";import"../../chunk-I54UCYOU.js";import"../../chunk-GOTN2KY4.js";import"../../chunk-R5L2E7JX.js";import"../../chunk-IQ5TA7AM.js";import{slotChildRowName as x}from"../../chunk-TBF5CVPA.js";import"../../chunk-DUVRZ456.js";import"../../chunk-6W7WLPZH.js";import"../../chunk-IYT6NN2J.js";import{slotFieldsOf as A,nestsInTree as H}from"../../chunk-PLVEGYK6.js";import{useEasel as M}from"../../chunk-PVAIOBBE.js";import"../../chunk-TBY3DFKS.js";import"../../chunk-ECM5F6JJ.js";import"../../chunk-BPZQ7S2Z.js";import"../../chunk-XWFH2NHZ.js";import{LayersTree as V,Subtree as v,TreeRow as D,TreeRowAction as E,TreeSeam as g}from"../../chunk-4JSBIW5H.js";import{DEFAULT_TREE_WORDS as B}from"../../chunk-K56YDHYQ.js";import"../../chunk-EA2HTX37.js";import"../../chunk-RC25EGHD.js";import"../../chunk-KFV7N2DJ.js";import"../../chunk-YRLPFZW3.js";import"../../chunk-NDRZP6YR.js";import{DEFAULT_SAVE_WORDS as Z,saveIndicator as w}from"../../chunk-H6DDIBQ4.js";import{SaveState as z,panelWidthVars as F}from"../../chunk-IE55HNMA.js";import"../../chunk-Z6PVRXVY.js";import"../../chunk-THWO5YVZ.js";import"../../chunk-RE4LP46F.js";import"../../chunk-MJM6SFD3.js";import"../../chunk-2OAZYSWJ.js";import"../../chunk-NY7HHUGB.js";import"../../chunk-33C6ALT5.js";import"../../chunk-2XMHLXMA.js";import"../../chunk-G3GWAP5R.js";import"../../chunk-WRFD4EXD.js";import"../../chunk-36LVP5WD.js";import{useWords as b}from"../../chunk-MFIRYGHW.js";import"../../chunk-QFVRMARS.js";import"../../chunk-AYWN5NRH.js";import{useTreeDrag as I}from"../../chunk-67GNT6PF.js";import"../../chunk-P2VEMZH5.js";import"../../chunk-ILXP5VX5.js";import{zoneKey as W,parseZoneKey as Y}from"../../chunk-KRXQM65X.js";import"../../chunk-NKB3KVAB.js";import{useState as L,useRef as O,useEffect as T,useCallback as G,Fragment as J}from"react";import{Tooltip as X}from"efficient-shell/ui";import{TrashIcon as K}from"efficient-shell/icons/efficient";import{jsxs as Q,jsx as $,Fragment as U}from"react/jsx-runtime";var q=e=>n=>{n.target.closest("button, input")||e()},_={rowClick:q};function ee(){const{saveState:ee,readOnly:ne,readOnlyReason:oe=null}=l(),re=i(),{appState:te,selectedItem:se,config:ie}=M(e=>e),[ce,pe]=L(m),le=b("screen",P),me=b("tree",B),de=b("save",Z),{first:ae,last:ue,panelOf:he}=d(),ke=he(ae),fe=a(),je=u(),ye=te.data.content?.[0]??null,Ne=ye?.props.id??null,Se=ye?.type===ae,Ce=ye?.type===ue,Re=O(null),Pe=O(null);r(Pe);const xe=N(),Ae=S(),He=C();h(se?.props.id),T(()=>{const e=Pe.current;if(!Ae||!e)return;const n=e=>{"Escape"===e.key&&He()};return e.addEventListener("keydown",n),()=>e.removeEventListener("keydown",n)},[Ae]),R(null!==Ae,()=>He()),T(()=>{Ne&&Re.current!==Ne&&(Re.current=Ne,Se?pe(ke??m):se||re.select({index:0}))},[Ne,se,re,Se]);const Me=G(e=>pe(n=>k(n,e)?n:e),[]),Ve=f({kind:ce.kind,mode:ce,open:Me,show:e=>pe(e),reveal:()=>{},select:(e,n)=>{pe(e=>k(e,n)?e:n),re.select(e)}}),{selectNode:ve}=s({mode:ce,setMode:pe,onOpenPart:n}),De=j(),{labelAtLevel:Ee,Icon:ge}=De,{canAddTo:Be}=y(),Ze=e=>Ee(e,"block",ie.components[e]?.label??e),we=e=>Ee(e,"section",Ze(e)),ze=!Se&&"puck"===ce.kind&&se?.props.id===Ne,Fe=ye?Be(ye.type)?.spec??null:null,be=ye&&Fe?`${ye.props.id}:${Fe.slot}`:null,Ie=ye&&Fe&&Array.isArray(ye.props[Fe.slot])?ye.props[Fe.slot]:[],We=e=>x(e,Ze,De.plainText),Ye=(e,r)=>{ye&&Fe&&be&&(pe(m),Fe.slider?(o(String(ye.props.id),e),re.select({index:e,zone:be}),n(String(ye.props.id))):(re.select({index:e,zone:be}),n(r)))},Le=()=>{if(!ye||!Fe||!be)return;const e=Ie.length;re.insertComponent(be,Fe.childType,e),pe(m),Fe.slider?requestAnimationFrame(()=>{o(String(ye.props.id),e),re.select({index:e,zone:be})}):re.select({index:e,zone:be})},Oe=e=>A(ie,e),Te=e=>{const{parentId:n,slot:o}=Y(e),r=e=>{if(!e)return null;if(String(e.props.id)===n)return e;for(const n of Oe(e.type)){const o=Array.isArray(e.props[n])?e.props[n]:[];for(const e of o){const n=r(e);if(n)return n}}return null},t=r(ye)?.props[o];return Array.isArray(t)?t.length:0},Ge=(e,n,o)=>{const r=Math.min(Math.max(o,0),Te(e)),t=n<r?r-1:r;t!==n&&(re.reorderComponent(e,n,t),pe(m),re.select({index:t,zone:e}))},Je=I({keyOf:e=>e.id,readOnly:Boolean(ne),canDrop:(e,n)=>W(n)===e.zone&&n.index>=0&&n.index<=Te(e.zone),onDrop:(e,n)=>Ge(e.zone,e.index,n.index),onStep:(e,n)=>Ge(e.zone,e.index,n<0?e.index-1:e.index+2)}),Xe=(e,n)=>/* @__PURE__ */$(g,{...ne?{}:Je.seam({place:{...Y(e),index:n}})},`seam:${e}:${n}`),Ke=e=>De.blockRowName(e,Ze),Qe=(e,o,r)=>{pe(m),re.select({index:o,zone:e}),n(r)},$e=(e,n,o)=>{re.insertComponent(e,n,o),pe(m),re.select({index:o,zone:e})},Ue=(n,o,r)=>/* @__PURE__ */$(e,{choices:r,onPick:e=>$e(n,e,o)}),qe=(e,n)=>{const o=Oe((r=e).type).flatMap(e=>(Array.isArray(r.props[e])?r.props[e]:[]).map((n,o)=>({child:n,zone:`${r.props.id}:${e}`,index:o})));var r;const t=Be(e.type),s=t?.choices??null,i="footer"===t?.source?Ke:We;/* @__PURE__ */
|
|
2
|
+
return Q(U,{children:[o.map(({child:e,zone:o,index:r})=>{const t=se?.props.id===e.props.id,s=H(ie,e.type,n),c=i(e),p=String(e.props.id),l=()=>Qe(o,r,p),{rowProps:d,...a}=Je.row({item:{id:p,zone:o,index:r},place:{...Y(o),index:r}},{onClick:q(l)});/* @__PURE__ */
|
|
3
|
+
return Q(J,{children:[0===r&&Xe(o,0),
|
|
4
|
+
/* @__PURE__ */$(D,{words:me,icon:/* @__PURE__ */$(ge,{type:e.type,size:13}),name:c,selected:t,onSelect:l,...a,actions:/* @__PURE__ */$(E,{kind:"delete",label:le.deleteNamed({name:c}),onClick:()=>{return e=o,n=r,re.removeComponent(e,n),pe(m),void re.select(null);var e,n},children:/* @__PURE__ */$(K,{size:13})}),rowProps:d}),s&&/* @__PURE__ */$(v,{children:qe(e,n+1)}),Xe(o,r+1)]},String(e.props.id??`${o}-${r}`))}),t&&s?Ue(`${e.props.id}:${t.slot}`,o.length,s):null]})},_e="HeroSingle"===ye?.type,en=Boolean(ye)&&(Boolean(Be(ye.type))||Oe(ye.type).length>0),nn=Boolean(ye)&&(Boolean(Fe)||Ce||Se||_e||en);/* @__PURE__ */
|
|
5
|
+
return Q("div",{ref:Pe,className:"sf-editor es-editor",style:F(t),children:[
|
|
6
|
+
/* @__PURE__ */$("div",{className:"sf-section-bar",children:/* @__PURE__ */$(z,null!==oe?{tone:"off",label:oe,role:"status"}:{...w(ee,de),role:"status"})}),
|
|
7
|
+
/* @__PURE__ */Q("div",{className:"sf-body",children:[Ae&&xe?/* @__PURE__ */$("aside",{className:"es-sidepanel es-sidepanel--left sf-panel sf-panel--left",children:/* @__PURE__ */$(p,{panel:xe,pick:Ae})}):nn&&ye&&/* @__PURE__ */Q("aside",{className:"es-sidepanel es-sidepanel--left sf-panel sf-panel--left",children:[
|
|
8
|
+
/* @__PURE__ */$("div",{className:"sf-panel-head",children:/* @__PURE__ */$(X,{content:Se?le.headerSettings:le.sectionSettings({name:we(ye.type)}),side:"bottom",children:/* @__PURE__ */$("button",{type:"button",className:"sf-panel-title sf-panel-title--btn "+(ze?"is-selected":""),"aria-pressed":ze,onClick:()=>{Se?pe(ke??m):(pe(m),re.select({index:0}))},children:we(ye.type)})})}),
|
|
9
|
+
/* @__PURE__ */$(V,{className:"sf-tree sf-scroll",rootProps:Je.rootProps(),words:me,children:/* @__PURE__ */$(v,{children:Se?
|
|
10
|
+
/* @__PURE__ */$(D,{words:me,icon:/* @__PURE__ */$(ge,{type:"header",size:13}),name:le.headerSettings,selected:ce.kind===ke?.kind,onSelect:()=>pe(ke??m),rowProps:{onClick:q(()=>pe(ke??m))}}):Fe?/* @__PURE__ */Q(U,{children:[Ie.map((e,n)=>{const o=se?.props.id===e.props.id,r=We(e),t=String(e.props.id),s=()=>Ye(n,t),{rowProps:i,...c}=Je.row({item:{id:t,zone:be,index:n},place:{...Y(be),index:n}},{onClick:q(s)});/* @__PURE__ */
|
|
11
|
+
return Q(J,{children:[0===n&&Xe(be,0),
|
|
12
|
+
/* @__PURE__ */$(D,{words:me,icon:/* @__PURE__ */$(ge,{type:e.type,size:13}),name:r,selected:o,onSelect:s,...c,actions:/* @__PURE__ */$(E,{kind:"delete",label:le.deleteNamed({name:r}),onClick:()=>{return e=n,void(be&&(re.removeComponent(be,e),pe(m),re.select(null)));var e},children:/* @__PURE__ */$(K,{size:13})}),rowProps:i}),Xe(be,n+1)]},String(e.props.id??n))}),
|
|
13
|
+
/* @__PURE__ */Q("button",{type:"button",className:"sf-add-card",onClick:Le,children:[
|
|
14
|
+
/* @__PURE__ */$("span",{className:"sf-plus sf-plus--sm",children:"+"}),Fe.addLabel]}),Ne?Ve.partRows?.(ye,_):null]}):qe(ye,1)})})]}),
|
|
15
|
+
/* @__PURE__ */$("div",{className:"sf-center",children:/* @__PURE__ */$("div",{className:"sf-preview-host",children:/* @__PURE__ */$(fe,{})})}),
|
|
16
|
+
/* @__PURE__ */$(c,{value:{selectChild:(e,n,o,r)=>"section"===Be(r)?.source?Ye(n,o):Qe(e,n,o),addChild:(e,n,o,r,t)=>"section"===Be(t)?.source?Le():$e(`${e}:${n}`,o,r),childRowName:We,blockRowName:Ke},children:/* @__PURE__ */$(je,{mode:ce,onOpenWebsiteSettings:Ve.openSettings??(()=>{}),onSelectNode:ve,hideNodeActions:!0})})]})]})}export{ee as default};
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
return a(c[e],{size:r,strokeWidth:i,strokeLinecap:t?"round":void 0,strokeLinejoin:t?"round":void 0,className:o,style:n})}export{f as default};
|
|
1
|
+
export{UiIcon as default}from"../../chunk-6OA4UXKZ.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{usePartBridge}from"../../chunk-
|
|
1
|
+
export{usePartBridge}from"../../chunk-H5QI34FV.js";import"../../chunk-S2MMPHKD.js";import"../../chunk-FZ3Y3QTQ.js";import"../../chunk-R6WTQWAC.js";import"../../chunk-U3JP4VGF.js";import"../../chunk-I54UCYOU.js";import"../../chunk-GOTN2KY4.js";import"../../chunk-R5L2E7JX.js";import"../../chunk-IYT6NN2J.js";import"../../chunk-PLVEGYK6.js";import"../../chunk-PVAIOBBE.js";import"../../chunk-TBY3DFKS.js";import"../../chunk-ECM5F6JJ.js";import"../../chunk-BPZQ7S2Z.js";import"../../chunk-XWFH2NHZ.js";import"../../chunk-4JSBIW5H.js";import"../../chunk-K56YDHYQ.js";import"../../chunk-EA2HTX37.js";import"../../chunk-RC25EGHD.js";import"../../chunk-KFV7N2DJ.js";import"../../chunk-YRLPFZW3.js";import"../../chunk-NY7HHUGB.js";import"../../chunk-33C6ALT5.js";import"../../chunk-2XMHLXMA.js";import"../../chunk-G3GWAP5R.js";import"../../chunk-WRFD4EXD.js";import"../../chunk-36LVP5WD.js";import"../../chunk-MFIRYGHW.js";import"../../chunk-67GNT6PF.js";import"../../chunk-P2VEMZH5.js";import"../../chunk-ILXP5VX5.js";import"../../chunk-KRXQM65X.js";import"../../chunk-NKB3KVAB.js";
|
package/dist/screen/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import"../chunk-GZO72N3Q.js";export{DocumentScreen,ScreenMount}from"../chunk-
|
|
1
|
+
import"../chunk-GZO72N3Q.js";export{DocumentScreen,ScreenMount}from"../chunk-NQXFINT2.js";import"../chunk-GXQCZJOP.js";import"../chunk-GYNIDJKN.js";import"../chunk-M4CNCPHA.js";import"../chunk-FGNR22NY.js";import"../chunk-2GVCAIPX.js";import"../chunk-26OOWIJJ.js";import"../chunk-NBDMTIU2.js";import"../chunk-MQNBD6AB.js";import"../chunk-ZE7I3PLX.js";import"../chunk-7F52SZOI.js";import"../chunk-W4U4SHKW.js";import"../chunk-RKTF5XLP.js";export{ScreenStoreProvider}from"../chunk-J54OXLQF.js";import"../chunk-3Z2MVLCD.js";import"../chunk-4EI6UGGH.js";import"../chunk-TZIIRGVY.js";import"../chunk-H5QI34FV.js";import"../chunk-S2MMPHKD.js";import"../chunk-KCBEE2MC.js";import"../chunk-5545A3PC.js";import"../chunk-WUSJ6SSF.js";import"../chunk-PA3PNTVV.js";import"../chunk-5ZBY24K7.js";import"../chunk-BVN33R76.js";import"../chunk-62VPYC7F.js";import"../chunk-J2JDC3EZ.js";import"../chunk-O5XI3WAQ.js";import"../chunk-ENXLPJ77.js";import"../chunk-ZIFDZGY7.js";import"../chunk-ERR437B5.js";import"../chunk-GMCZXMOV.js";import"../chunk-HNKB2ZYR.js";import"../chunk-CLOS6SSX.js";import"../chunk-S4AWJX4Q.js";import"../chunk-KG7RJWOK.js";import"../chunk-VPFNZ7TB.js";import"../chunk-LOMEH6DG.js";export{NO_DOCUMENT_ADDRESSING}from"../chunk-RLBXE4EU.js";import"../chunk-KCOBHPN6.js";export{EaselSessionProvider,useEaselSession}from"../chunk-O7Q4DDJT.js";export{EFFICIENT_BACKEND,activateEaselSession,backendOf,createEaselSession,currentEaselSession,deactivateEaselSession,efficientClientOpen,isEfficientBackend,provideDefaultBackend,resetAmbientEaselSession,sessionRegistry,setSessionBridgedSite,setSessionDocumentSite}from"../chunk-RSCMJIWS.js";import"../chunk-UMDQ6CLQ.js";import"../chunk-V7U33NF2.js";import"../chunk-6WY6ZXJG.js";import"../chunk-HQ4VVRIC.js";export{SELECTION_MODE,ScreenCanvasTargetProvider,ScreenPartsProvider,isPinnedFirst,isPinnedLast,isSlotMode,sameInspectorMode,screenSlotsOf,useScreenBlockLook,useScreenBlockRules,useScreenBridges,useScreenCanvasDrag,useScreenCanvasFrame,useScreenCanvasHead,useScreenCanvasTarget,useScreenDevices,useScreenDocumentLabel,useScreenDocumentPass,useScreenInspectorPanel,useScreenLeftView,useScreenNodeKeys,useScreenNotify,useScreenOwnerName,useScreenParts,useScreenPickFollowsSelection,useScreenPinned,useScreenSaveSwitch,useScreenStorageNamespace,useScreenStyleClipboard,useStandaloneScreenBridges}from"../chunk-FZ3Y3QTQ.js";import"../chunk-R6WTQWAC.js";export{DETACHED_EASEL_HOST,EaselHostContext,EaselHostProvider,createEaselHost,useEaselHost,useHostEscape}from"../chunk-U3JP4VGF.js";import"../chunk-BXMXTO36.js";import"../chunk-OSPUG6S6.js";import"../chunk-WK3AFPXY.js";import"../chunk-VVPZMWJE.js";import"../chunk-BSPCSC45.js";import"../chunk-I54UCYOU.js";import"../chunk-GOTN2KY4.js";import"../chunk-R5L2E7JX.js";import"../chunk-IQ5TA7AM.js";import"../chunk-TBF5CVPA.js";import"../chunk-DUVRZ456.js";import"../chunk-6W7WLPZH.js";import"../chunk-IYT6NN2J.js";import"../chunk-PLVEGYK6.js";import"../chunk-PVAIOBBE.js";import"../chunk-TBY3DFKS.js";import"../chunk-ECM5F6JJ.js";import"../chunk-BPZQ7S2Z.js";import"../chunk-XWFH2NHZ.js";import"../chunk-4JSBIW5H.js";import"../chunk-K56YDHYQ.js";import"../chunk-EA2HTX37.js";import"../chunk-RC25EGHD.js";import"../chunk-KFV7N2DJ.js";import"../chunk-YRLPFZW3.js";import"../chunk-4VJATVVR.js";import"../chunk-NDRZP6YR.js";import"../chunk-H6DDIBQ4.js";import"../chunk-IE55HNMA.js";import"../chunk-Z6PVRXVY.js";import"../chunk-THWO5YVZ.js";import"../chunk-RE4LP46F.js";import"../chunk-MJM6SFD3.js";import"../chunk-2OAZYSWJ.js";import"../chunk-NY7HHUGB.js";import"../chunk-33C6ALT5.js";import"../chunk-2XMHLXMA.js";import"../chunk-G3GWAP5R.js";import"../chunk-WRFD4EXD.js";import"../chunk-36LVP5WD.js";import"../chunk-MFIRYGHW.js";import"../chunk-QFVRMARS.js";import"../chunk-AYWN5NRH.js";import"../chunk-67GNT6PF.js";import"../chunk-P2VEMZH5.js";import"../chunk-ILXP5VX5.js";import"../chunk-KRXQM65X.js";import"../chunk-NKB3KVAB.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
export{VIEW_DESKTOP_MIN,VIEW_TABLET_MIN,VIEW_TIERS,VIEW_TIER_LABEL,viewTierForWidth}from"../../../chunk-DWIOHQG7.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{editorRootFocus,isSaveShortcut,useEaselKeyTarget,useEaselSaveKey,useEaselUndoKeys}from"../../chunk-
|
|
1
|
+
export{editorRootFocus,isSaveShortcut,useEaselKeyTarget,useEaselSaveKey,useEaselUndoKeys}from"../../chunk-4EI6UGGH.js";import"../../chunk-U3JP4VGF.js";import"../../chunk-PVAIOBBE.js";import"../../chunk-TBY3DFKS.js";import"../../chunk-ECM5F6JJ.js";import"../../chunk-YRLPFZW3.js";import"../../chunk-NY7HHUGB.js";import"../../chunk-33C6ALT5.js";import"../../chunk-MFIRYGHW.js";import"../../chunk-ILXP5VX5.js";import"../../chunk-KRXQM65X.js";import"../../chunk-NKB3KVAB.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{DEVICE_FIELD_MARKER,DEVICE_HIDDEN_ATTR,DEVICE_NOTE,deviceField,deviceMetaOf,deviceNote,shownTier,withoutDeviceGate}from"../../../chunk-
|
|
1
|
+
export{DEVICE_FIELD_MARKER,DEVICE_HIDDEN_ATTR,DEVICE_NOTE,deviceField,deviceMetaOf,deviceNote,shownTier,withoutDeviceGate}from"../../../chunk-NBDMTIU2.js";import"../../../chunk-7F52SZOI.js";import"../../../chunk-VVPZMWJE.js";import"../../../chunk-BSPCSC45.js";import"../../../chunk-MFIRYGHW.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{gotoPreviewSlide,pinPreviewToBottom,pinPreviewToSection,previewFrame,scrollPreviewToSection,scrollPreviewToTop}from"../../../chunk-
|
|
1
|
+
export{gotoPreviewSlide,pinPreviewToBottom,pinPreviewToSection,previewFrame,scrollPreviewToSection,scrollPreviewToTop}from"../../../chunk-3Z2MVLCD.js";import"../../../chunk-R5L2E7JX.js";import"../../../chunk-IQ5TA7AM.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{copyNodeStyle,nodeStyleRows,planNodePaste,shopFieldKind,siteStyleScope,styleClipboardOf}from"../../../chunk-
|
|
1
|
+
export{copyNodeStyle,nodeStyleRows,planNodePaste,shopFieldKind,siteStyleScope,styleClipboardOf}from"../../../chunk-M4CNCPHA.js";import"../../../chunk-NBDMTIU2.js";import"../../../chunk-MQNBD6AB.js";import"../../../chunk-ZE7I3PLX.js";import"../../../chunk-7F52SZOI.js";import"../../../chunk-V7U33NF2.js";import"../../../chunk-6WY6ZXJG.js";import"../../../chunk-VVPZMWJE.js";import"../../../chunk-BSPCSC45.js";import"../../../chunk-DUVRZ456.js";import"../../../chunk-MFIRYGHW.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
export{SCALAR_TEXT_CONTROLS,TEXT_CONTROL_KINDS}from"../../../chunk-PIND6KE7.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{useSectionOps}from"../../../chunk-
|
|
1
|
+
export{useSectionOps}from"../../../chunk-S2MMPHKD.js";import"../../../chunk-FZ3Y3QTQ.js";import"../../../chunk-R6WTQWAC.js";import"../../../chunk-U3JP4VGF.js";import"../../../chunk-PLVEGYK6.js";import"../../../chunk-PVAIOBBE.js";import"../../../chunk-TBY3DFKS.js";import"../../../chunk-ECM5F6JJ.js";import"../../../chunk-BPZQ7S2Z.js";import"../../../chunk-XWFH2NHZ.js";import"../../../chunk-4JSBIW5H.js";import"../../../chunk-K56YDHYQ.js";import"../../../chunk-EA2HTX37.js";import"../../../chunk-RC25EGHD.js";import"../../../chunk-KFV7N2DJ.js";import"../../../chunk-YRLPFZW3.js";import"../../../chunk-NY7HHUGB.js";import"../../../chunk-33C6ALT5.js";import"../../../chunk-2XMHLXMA.js";import"../../../chunk-G3GWAP5R.js";import"../../../chunk-WRFD4EXD.js";import"../../../chunk-36LVP5WD.js";import"../../../chunk-MFIRYGHW.js";import"../../../chunk-67GNT6PF.js";import"../../../chunk-P2VEMZH5.js";import"../../../chunk-ILXP5VX5.js";import"../../../chunk-KRXQM65X.js";import"../../../chunk-NKB3KVAB.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{SELECTION_MODE,ScreenCanvasTargetProvider,ScreenPartsProvider,isPinnedFirst,isPinnedLast,isSlotMode,sameInspectorMode,screenSlotsOf,useScreenBlockLook,useScreenBlockRules,useScreenBridges,useScreenCanvasDrag,useScreenCanvasFrame,useScreenCanvasHead,useScreenCanvasTarget,useScreenDevices,useScreenDocumentLabel,useScreenDocumentPass,useScreenInspectorPanel,useScreenLeftView,useScreenNodeKeys,useScreenNotify,useScreenOwnerName,useScreenParts,useScreenPickFollowsSelection,useScreenPinned,useScreenSaveSwitch,useScreenStorageNamespace,useScreenStyleClipboard,useStandaloneScreenBridges}from"../../chunk-
|
|
1
|
+
export{SELECTION_MODE,ScreenCanvasTargetProvider,ScreenPartsProvider,isPinnedFirst,isPinnedLast,isSlotMode,sameInspectorMode,screenSlotsOf,useScreenBlockLook,useScreenBlockRules,useScreenBridges,useScreenCanvasDrag,useScreenCanvasFrame,useScreenCanvasHead,useScreenCanvasTarget,useScreenDevices,useScreenDocumentLabel,useScreenDocumentPass,useScreenInspectorPanel,useScreenLeftView,useScreenNodeKeys,useScreenNotify,useScreenOwnerName,useScreenParts,useScreenPickFollowsSelection,useScreenPinned,useScreenSaveSwitch,useScreenStorageNamespace,useScreenStyleClipboard,useStandaloneScreenBridges}from"../../chunk-FZ3Y3QTQ.js";import"../../chunk-R6WTQWAC.js";import"../../chunk-U3JP4VGF.js";import"../../chunk-PLVEGYK6.js";import"../../chunk-PVAIOBBE.js";import"../../chunk-TBY3DFKS.js";import"../../chunk-ECM5F6JJ.js";import"../../chunk-BPZQ7S2Z.js";import"../../chunk-XWFH2NHZ.js";import"../../chunk-4JSBIW5H.js";import"../../chunk-K56YDHYQ.js";import"../../chunk-EA2HTX37.js";import"../../chunk-RC25EGHD.js";import"../../chunk-KFV7N2DJ.js";import"../../chunk-YRLPFZW3.js";import"../../chunk-NY7HHUGB.js";import"../../chunk-33C6ALT5.js";import"../../chunk-2XMHLXMA.js";import"../../chunk-G3GWAP5R.js";import"../../chunk-WRFD4EXD.js";import"../../chunk-36LVP5WD.js";import"../../chunk-MFIRYGHW.js";import"../../chunk-67GNT6PF.js";import"../../chunk-P2VEMZH5.js";import"../../chunk-ILXP5VX5.js";import"../../chunk-KRXQM65X.js";import"../../chunk-NKB3KVAB.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{DEFAULT_EASEL_STRINGS,mergeEaselStrings}from"../chunk-
|
|
1
|
+
export{DEFAULT_EASEL_STRINGS,mergeEaselStrings}from"../chunk-5AIA5VIP.js";import"../chunk-OGH6CC3E.js";import"../chunk-643PVCEG.js";import"../chunk-6WY6ZXJG.js";import"../chunk-WK3AFPXY.js";import"../chunk-VVPZMWJE.js";import"../chunk-TBY3DFKS.js";import"../chunk-K56YDHYQ.js";import"../chunk-KFV7N2DJ.js";import"../chunk-H6DDIBQ4.js";import"../chunk-Z6PVRXVY.js";import"../chunk-RE4LP46F.js";import"../chunk-2OAZYSWJ.js";import"../chunk-33C6ALT5.js";import"../chunk-WRFD4EXD.js";import"../chunk-AYWN5NRH.js";
|
package/dist/strings/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{DEFAULT_EASEL_STRINGS as r,mergeEaselStrings as n}from"../chunk-
|
|
1
|
+
import{DEFAULT_EASEL_STRINGS as r,mergeEaselStrings as n}from"../chunk-5AIA5VIP.js";export{DEFAULT_EASEL_STRINGS,mergeEaselStrings}from"../chunk-5AIA5VIP.js";import"../chunk-OGH6CC3E.js";import"../chunk-643PVCEG.js";import"../chunk-6WY6ZXJG.js";import"../chunk-WK3AFPXY.js";import"../chunk-VVPZMWJE.js";import"../chunk-TBY3DFKS.js";import"../chunk-K56YDHYQ.js";import"../chunk-KFV7N2DJ.js";import"../chunk-H6DDIBQ4.js";import"../chunk-Z6PVRXVY.js";import"../chunk-RE4LP46F.js";import"../chunk-2OAZYSWJ.js";import"../chunk-33C6ALT5.js";import"../chunk-WRFD4EXD.js";import{stringsContext as o}from"../chunk-MFIRYGHW.js";import"../chunk-AYWN5NRH.js";import{useContext as t,useMemo as c}from"react";import{jsx as i}from"react/jsx-runtime";function s({value:s,locale:u,children:m}){const e=o(),p=t(e),h=p?.strings??r,j=u??p?.locale??"en",k=c(()=>({strings:n(h,s),locale:j}),[h,s,j]);/* @__PURE__ */
|
|
2
2
|
return i(e.Provider,{value:k,children:m})}function u(){return t(o())?.strings??r}function m(){return t(o())?.locale??"en"}export{s as EaselStringsProvider,m as useEaselLocale,u as useEaselStrings};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
-
import { TextStyle, TextStyleFont, TextStyleColour, TextStyleSetting, TextStyleAuto, TextStyleValues, TextStyleKind } from './model.js';
|
|
3
|
+
import { TextStyle, TextStyleFont, TextStyleColour, TextStyleSetting, TextStyleAuto, TextStyleValues, TextStyleDevice, TextStyleKind } from './model.js';
|
|
4
4
|
export { CAMPAIGN_TEXT_STYLE_SETTINGS, TEXT_STYLE_CASES, TEXT_STYLE_CASE_CSS, TEXT_STYLE_DEFAULT_COUNT, TEXT_STYLE_KINDS, TEXT_STYLE_MAX, TEXT_STYLE_RANGES, TEXT_STYLE_SETTINGS, TextStyleCase, TextStyleCaseCss, TextStyleNumber, TextStyleRange, addTextStyle, canAddTextStyle, defaultTextStyles, describeTextStyle, isDefaultTextStyle, isTextStyleCase, removeTextStyle, resolveTextStyle, textStyleCaseCss, textStyleCaseOfCss, textStyleRowSize, updateTextStyle, weightWord } from './model.js';
|
|
5
5
|
export { D as DEFAULT_TEXT_STYLES_WORDS, T as TextStylesWords } from '../words-gIDCeRv3.js';
|
|
6
6
|
|
|
@@ -48,6 +48,12 @@ interface TextStylesListProps {
|
|
|
48
48
|
onRemove?: (removed: TextStyle) => void;
|
|
49
49
|
/** At most this many of each kind. */
|
|
50
50
|
max?: number;
|
|
51
|
+
/**
|
|
52
|
+
* The view the host's editor is in. In `phone`, the Size row edits the
|
|
53
|
+
* style's phone size (`sizePhone`): the desktop size shows grey behind it,
|
|
54
|
+
* and an emptied box goes back to it. Left out: `desktop`, as before.
|
|
55
|
+
*/
|
|
56
|
+
device?: TextStyleDevice;
|
|
51
57
|
readOnly?: boolean;
|
|
52
58
|
}
|
|
53
59
|
/**
|
|
@@ -68,7 +74,7 @@ interface TextStylesListProps {
|
|
|
68
74
|
* The data and the words are the host's. The list does not know where an
|
|
69
75
|
* email or a storefront keeps its styles, nor what they were once called.
|
|
70
76
|
*/
|
|
71
|
-
declare function TextStylesList({ styles, onChange, fonts, colours, settings, auto, fallback, sample, openId, defaultOpenId, onOpenChange, onAdd, rowActions, onRemove, max, readOnly, }: TextStylesListProps): react.JSX.Element;
|
|
77
|
+
declare function TextStylesList({ styles, onChange, fonts, colours, settings, auto, fallback, sample, openId, defaultOpenId, onOpenChange, onAdd, rowActions, onRemove, max, device, readOnly, }: TextStylesListProps): react.JSX.Element;
|
|
72
78
|
interface TextStylesGroupProps {
|
|
73
79
|
/** The group's name: "Headings", "Body", or a host's own ("Accent"). */
|
|
74
80
|
label: ReactNode;
|
|
@@ -93,6 +99,8 @@ interface TextStyleItemProps {
|
|
|
93
99
|
onChange: (next: TextStyle) => void;
|
|
94
100
|
/** Buttons at the end of the row, outside the button that opens it. */
|
|
95
101
|
actions?: ReactNode;
|
|
102
|
+
/** The editor's view: `phone` draws and edits the phone size. */
|
|
103
|
+
device?: TextStyleDevice;
|
|
96
104
|
readOnly?: boolean;
|
|
97
105
|
}
|
|
98
106
|
/**
|
|
@@ -102,7 +110,7 @@ interface TextStyleItemProps {
|
|
|
102
110
|
* so a host's style that is not in the list (the website's Accent) looks and
|
|
103
111
|
* works the same, with no second copy.
|
|
104
112
|
*/
|
|
105
|
-
declare function TextStyleItem({ style, fonts, colours, settings, auto, fallback, sample, open, onOpenChange, onChange, actions, readOnly, }: TextStyleItemProps): react.JSX.Element;
|
|
113
|
+
declare function TextStyleItem({ style, fonts, colours, settings, auto, fallback, sample, open, onOpenChange, onChange, actions, device, readOnly, }: TextStyleItemProps): react.JSX.Element;
|
|
106
114
|
|
|
107
115
|
interface ColourSwatchRowProps {
|
|
108
116
|
/** The stored colour: a theme colour's `key`, a `#rrggbb`, or `undefined` for none of its own. */
|
|
@@ -141,4 +149,4 @@ interface ColourSwatchRowProps {
|
|
|
141
149
|
*/
|
|
142
150
|
declare function ColourSwatchRow({ value, hex, colours, label, followsWord, anyWord, onChange, readOnly }: ColourSwatchRowProps): react.JSX.Element;
|
|
143
151
|
|
|
144
|
-
export { ColourSwatchRow, type ColourSwatchRowProps, TextStyle, TextStyleAuto, TextStyleColour, TextStyleFont, TextStyleItem, type TextStyleItemProps, TextStyleKind, TextStyleSetting, TextStyleValues, TextStylesGroup, type TextStylesGroupProps, TextStylesList, type TextStylesListProps };
|
|
152
|
+
export { ColourSwatchRow, type ColourSwatchRowProps, TextStyle, TextStyleAuto, TextStyleColour, TextStyleDevice, TextStyleFont, TextStyleItem, type TextStyleItemProps, TextStyleKind, TextStyleSetting, TextStyleValues, TextStylesGroup, type TextStylesGroupProps, TextStylesList, type TextStylesListProps };
|
|
@@ -1,35 +1,36 @@
|
|
|
1
|
-
import{
|
|
2
|
-
/* @__PURE__ */
|
|
3
|
-
/* @__PURE__ */
|
|
4
|
-
/* @__PURE__ */
|
|
5
|
-
/* @__PURE__ */
|
|
6
|
-
/* @__PURE__ */
|
|
7
|
-
return
|
|
8
|
-
return
|
|
9
|
-
return
|
|
10
|
-
/* @__PURE__ */
|
|
11
|
-
/* @__PURE__ */
|
|
12
|
-
return
|
|
13
|
-
/* @__PURE__ */
|
|
14
|
-
return
|
|
15
|
-
/* @__PURE__ */
|
|
16
|
-
/* @__PURE__ */
|
|
17
|
-
/* @__PURE__ */
|
|
18
|
-
/* @__PURE__ */
|
|
19
|
-
/* @__PURE__ */
|
|
20
|
-
return
|
|
21
|
-
return
|
|
22
|
-
/* @__PURE__ */
|
|
23
|
-
return
|
|
24
|
-
return
|
|
25
|
-
return
|
|
26
|
-
/* @__PURE__ */
|
|
27
|
-
/* @__PURE__ */
|
|
28
|
-
return
|
|
29
|
-
return G("div",{className:"es-ts-
|
|
30
|
-
|
|
31
|
-
/* @__PURE__ */
|
|
32
|
-
|
|
33
|
-
return G(
|
|
34
|
-
|
|
35
|
-
/* @__PURE__ */
|
|
1
|
+
import{DEFAULT_TEXT_STYLES_WORDS as e}from"../chunk-OGH6CC3E.js";export{DEFAULT_TEXT_STYLES_WORDS}from"../chunk-OGH6CC3E.js";import{hexReadout as s,ColourWindow as t,typedHex as a}from"../chunk-5XUMLKQF.js";import"../chunk-643PVCEG.js";import{FieldSlider as n}from"../chunk-XWFH2NHZ.js";import{TEXT_STYLE_KINDS as l,canAddTextStyle as i,TEXT_STYLE_MAX as r,isDefaultTextStyle as o,CAMPAIGN_TEXT_STYLE_SETTINGS as d,TEXT_STYLE_SETTINGS as c,textStyleRowSize as u,describeTextStyle as m,updateTextStyle as h,textStyleCaseCss as f,TEXT_STYLE_CASES as p,addTextStyle as v,removeTextStyle as y,TEXT_STYLE_RANGES as S}from"../chunk-YHZSBL2N.js";export{CAMPAIGN_TEXT_STYLE_SETTINGS,TEXT_STYLE_CASES,TEXT_STYLE_CASE_CSS,TEXT_STYLE_DEFAULT_COUNT,TEXT_STYLE_KINDS,TEXT_STYLE_MAX,TEXT_STYLE_RANGES,TEXT_STYLE_SETTINGS,addTextStyle,canAddTextStyle,defaultTextStyles,describeTextStyle,isDefaultTextStyle,isTextStyleCase,removeTextStyle,resolveTextStyle,textStyleCaseCss,textStyleCaseOfCss,textStyleRowSize,updateTextStyle,weightWord}from"../chunk-YHZSBL2N.js";import{FieldSelect as g}from"../chunk-G3GWAP5R.js";import"../chunk-WRFD4EXD.js";import{useWords as b}from"../chunk-MFIRYGHW.js";import{withTip as k}from"../chunk-P2VEMZH5.js";import{hsvToHex as N,Tooltip as C,ColorSwatch as x,IconButton as T}from"efficient-shell/ui";import{useState as w,useRef as E,useId as z,useEffect as O,Fragment as _}from"react";import{TrashIcon as L,ChevronIcon as A,BoldIcon as M,ItalicIcon as j,CaseLowerIcon as X,CaseCapitalizedIcon as $,CaseUpperIcon as W,CaseNormalIcon as Y}from"efficient-shell/icons/efficient";import{jsxs as D,jsx as G,Fragment as I}from"react/jsx-runtime";var P=`conic-gradient(${[0,60,120,180,240,300,0].map(e=>N({h:e,s:1,v:1})).join(", ")})`;function F({value:e,hex:a,colours:n,label:l,followsWord:i,anyWord:r,onChange:o,readOnly:d=!1}){const[c,u]=w(!1),m=E(null),h=E(null),f=z(),p=void 0!==e&&n.some(s=>s.key===e),v=void 0!==e&&!p;return O(()=>{if(!c)return;const e=m.current?.ownerDocument;if(!e)return;const s=e=>{m.current&&!m.current.contains(e.target)&&u(!1)};return e.addEventListener("click",s,!0),()=>e.removeEventListener("click",s,!0)},[c]),/* @__PURE__ */D("div",{ref:m,className:"es-ts-set","data-ts-setting":"color",children:[
|
|
2
|
+
/* @__PURE__ */D("div",{className:"es-ts-top",children:[
|
|
3
|
+
/* @__PURE__ */G("span",{className:"es-ts-sub",children:l}),
|
|
4
|
+
/* @__PURE__ */G("span",{className:"es-ts-colour-read",children:a?s(a):i})]}),
|
|
5
|
+
/* @__PURE__ */D("div",{className:"es-ts-swatches",role:"group","aria-label":l,children:[n.map(t=>/* @__PURE__ */G(C,{content:`${t.name} · ${s(t.value)}`,children:/* @__PURE__ */G(x,{color:t.value,size:"sm",className:"es-ts-swatch","aria-label":t.name,selected:e===t.key,disabled:d,onClick:()=>o(t.key)})},t.key)),
|
|
6
|
+
/* @__PURE__ */G(C,{content:r,children:/* @__PURE__ */G(x,{ref:h,color:P,size:"sm",className:"es-ts-swatch es-ts-swatch--any","aria-label":r,selected:v,"aria-expanded":c,"aria-controls":c?f:void 0,disabled:d,onClick:()=>u(e=>!e)})})]}),c?/* @__PURE__ */G(t,{id:f,value:a??"",onChange:e=>o(e),label:l,readOnly:d,onClose:()=>{u(!1),h.current?.focus()}}):null]})}function H({styles:s,onChange:t,fonts:a,colours:n=[],settings:c=d,auto:u=[],fallback:m,sample:h,openId:f,defaultOpenId:p=null,onOpenChange:S,onAdd:g,rowActions:N,onRemove:C,max:x=r,device:T="desktop",readOnly:_=!1}){const A=b("textStyles",e),M=z(),[j,X]=w(p),$=void 0!==f?f:j,W=e=>{void 0===f&&X(e),S?.(e)},Y=E(null),[P,F]=w(null);O(()=>{if(!P||!Y.current)return;const e=[...Y.current.querySelectorAll(".es-ts-item")].find(e=>e.dataset.tsId===P.id),s=e?e.querySelector(".es-ts-row"):Y.current.querySelector(`.es-ts-add[data-ts-kind="${P.kind}"]`);s?.focus(),F(null)},[P]);/* @__PURE__ */
|
|
7
|
+
return G("div",{className:"es-ts",ref:Y,children:l.map(e=>{const l=s.filter(s=>s.kind===e),r=!i(s,e,x),d=!_&&!r;/* @__PURE__ */
|
|
8
|
+
return D(R,{label:A.groups[e],children:[l.map(e=>{const l=N?.(e),i=null!=l&&!1!==l,r=Boolean(C)&&!_&&!o(e);/* @__PURE__ */
|
|
9
|
+
return G(B,{style:e,fonts:a,colours:n,settings:c,auto:u,fallback:m,sample:h,device:T,readOnly:_,open:$===e.id,onOpenChange:s=>W(s?e.id:null),onChange:e=>t(s.map(s=>s.id===e.id?e:s)),actions:r||i?/* @__PURE__ */D(I,{children:[r?k(A.remove,/* @__PURE__ */G("button",{type:"button",className:"es-ts-del","aria-label":A.removeNamed({name:e.name}),onClick:()=>(e=>{if(_||!C)return;const a=y(s,e.id,{name:A.styleName});if(!a)return;const n=s.filter(s=>s.kind===e.kind),l=n[n.indexOf(e)+1];$===e.id&&W(null),t(a.styles),C(a.removed),F({id:l?.id??null,kind:e.kind})})(e),children:/* @__PURE__ */G(L,{size:14,"aria-hidden":"true"})})):null,i?l:null]}):null},e.id)}),k(!_&&r?A.full({kind:e,max:x}):void 0,/* @__PURE__ */D("button",{type:"button",className:"es-ts-add","data-ts-kind":e,disabled:_,"aria-disabled":!(_||!r)||void 0,"aria-describedby":!_&&r?`${M}-full-${e}`:void 0,onClick:()=>{d&&(e=>{if(_)return;const a=v(s,e,{max:x,name:A.styleName,make:g});a&&t(a.styles)})(e)},children:[
|
|
10
|
+
/* @__PURE__ */G("span",{className:"es-ts-add-word",children:A.add[e]}),
|
|
11
|
+
/* @__PURE__ */G("span",{className:"es-ts-count",children:A.count({n:l.length,max:x})})]})),_||!r?null:/* @__PURE__ */G("span",{id:`${M}-full-${e}`,className:"es-vh",children:A.full({kind:e,max:x})})]},e)})})}function R({label:e,children:s}){const t=z();/* @__PURE__ */
|
|
12
|
+
return D("section",{className:"es-ts-section","aria-labelledby":t,children:[
|
|
13
|
+
/* @__PURE__ */G("div",{className:"es-ts-group",id:t,children:e}),s]})}function B({style:s,fonts:t,colours:a=[],settings:n=d,auto:l=[],fallback:i,sample:r,open:o,onOpenChange:f,onChange:p,actions:v,device:y="desktop",readOnly:S=!1}){const g=b("textStyles",e),k=`${z()}-open-${s.id}`,N=new Set(l),C=c.filter(e=>n.includes(e)),x={...i?.(s)??{},...s.values},T="phone"===y,w=T&&void 0!==s.values.sizePhone?{...x,size:s.values.sizePhone}:x,E=t.find(e=>e.value===x.font),O={fontFamily:E?.family,fontSize:`${u(w.size??16)}px`,fontWeight:x.weight,fontStyle:x.italic?"italic":void 0};/* @__PURE__ */
|
|
14
|
+
return D(_,{children:[
|
|
15
|
+
/* @__PURE__ */D("div",{className:"es-ts-item","data-ts-id":s.id,children:[
|
|
16
|
+
/* @__PURE__ */D("button",{type:"button",className:"es-ts-row","aria-expanded":o,"aria-controls":o?k:void 0,onClick:()=>f(!o),children:[
|
|
17
|
+
/* @__PURE__ */G("span",{className:"es-ts-chev","aria-hidden":"true",children:/* @__PURE__ */G(A,{size:12})}),
|
|
18
|
+
/* @__PURE__ */G("span",{className:"es-ts-name",style:O,children:s.name}),
|
|
19
|
+
/* @__PURE__ */G("span",{className:"es-ts-meta",children:m(w,t,g,{autoSize:N.has("size")&&w===x&&void 0===s.values.size})})]}),v?/* @__PURE__ */G("div",{className:"es-ts-actions",children:v}):null]}),o?/* @__PURE__ */G("div",{className:"es-ts-open",id:k,children:/* @__PURE__ */G(V,{style:s,values:x,fonts:t,colours:a,settings:C,autoSet:N,sample:r??g.sample,words:g,phone:T,readOnly:S,set:e=>p(h([s],s.id,e)[0])})}):null]})}var U={none:Y,upper:W,capitalize:$,lower:X};function V({style:e,values:s,fonts:t,colours:l,settings:i,autoSet:r,sample:o,words:d,phone:c,readOnly:u,set:m}){const h=e.values,p=t.find(e=>e.value===s.font),v=function(e,s){return e?s.find(s=>s.key===e)?.value??a(e)??void 0:void 0}(s.color,l),y=e=>"largestSize"===e||r.has(e),g=e=>y(e)?h[e]:s[e],b=g("size"),N=c&&void 0!==h.sizePhone?h.sizePhone:b,C=g("lineSpacing"),x=g("letterSpacing"),w=y("letterCase")?h.letterCase:s.letterCase,E={fontFamily:p?.family,fontSize:void 0===N?void 0:`${N}px`,fontWeight:s.weight,fontStyle:s.italic?"italic":void 0,lineHeight:void 0===C?void 0:String(C/100),letterSpacing:void 0===x?void 0:`${x}px`,color:v,textTransform:f(w)},z=e=>{const t=S[e],a=y(e);/* @__PURE__ */
|
|
20
|
+
return G("div",{className:"es-ts-slider","data-ts-setting":e,children:/* @__PURE__ */G(n,{label:d.settings[e],value:h[e],onChange:s=>m({[e]:s}),min:t.min,max:t.max,step:t.step,shiftStep:t.shiftStep,sliderMin:t.sliderMin,sliderMax:t.sliderMax,unit:t.unit||void 0,styleValue:a?void 0:s[e],auto:a?d.auto:void 0,readOnly:u})},e)};/* @__PURE__ */
|
|
21
|
+
return D(I,{children:[
|
|
22
|
+
/* @__PURE__ */G("div",{className:"es-ts-preview",style:E,"aria-label":d.preview,children:o}),i.map(a=>{switch(a){case"font":/* @__PURE__ */
|
|
23
|
+
return G(Z,{value:h.font,fonts:t,words:d,readOnly:u,set:m},a);case"color":/* @__PURE__ */
|
|
24
|
+
return G(q,{value:h.color,hex:v,colours:l,words:d,readOnly:u,set:m},a);case"emphasis":{const e=(s.weight??400)>=600,t=!1!==p?.italic;/* @__PURE__ */
|
|
25
|
+
return D("div",{className:"es-ts-set","data-ts-setting":a,children:[
|
|
26
|
+
/* @__PURE__ */G("span",{className:"es-ts-sub",children:d.settings.emphasis}),
|
|
27
|
+
/* @__PURE__ */D("div",{className:"es-ts-icons",children:[k(d.bold,/* @__PURE__ */G(T,{className:"es-ts-icon","aria-label":d.bold,"aria-pressed":e,disabled:u,onClick:()=>m({weight:e?400:700}),children:/* @__PURE__ */G(M,{size:16})})),u||t?k(d.italic,/* @__PURE__ */G(T,{className:"es-ts-icon","aria-label":d.italic,"aria-pressed":Boolean(s.italic),disabled:u,onClick:()=>m({italic:!s.italic||void 0}),children:/* @__PURE__ */G(j,{size:16})})):/* @__PURE__ */G(T,{className:"es-ts-icon","aria-label":d.italic,"aria-pressed":Boolean(s.italic),"aria-disabled":!0,disabledReason:d.italicMissing,children:/* @__PURE__ */G(j,{size:16})})]})]},a)}case"letterCase":/* @__PURE__ */
|
|
28
|
+
return G(K,{value:h.letterCase??s.letterCase,auto:y("letterCase"),words:d,readOnly:u,set:m},a);case"largestSize":return"heading"===e.kind?z(a):null;case"size":return c?(()=>{const e=S.size;/* @__PURE__ */
|
|
29
|
+
return G("div",{className:"es-ts-slider","data-ts-setting":"size","data-ts-device":"phone",children:/* @__PURE__ */G(n,{label:d.settings.size,value:h.sizePhone,onChange:e=>m({sizePhone:e}),min:e.min,max:e.max,step:e.step,shiftStep:e.shiftStep,sliderMin:e.sliderMin,sliderMax:e.sliderMax,unit:e.unit||void 0,styleValue:b,readOnly:u})},"size")})():z(a);default:return z(a)}})]})}function Z({value:e,fonts:s,words:t,readOnly:a,set:n}){const l=z();/* @__PURE__ */
|
|
30
|
+
return D("div",{className:"es-ts-set","data-ts-setting":"font",children:[
|
|
31
|
+
/* @__PURE__ */G("span",{className:"es-ts-sub",id:l,children:t.settings.font}),
|
|
32
|
+
/* @__PURE__ */G(g,{value:e,options:s.map(e=>({label:e.label,value:e.value})),onChange:e=>n({font:e}),ariaLabelledBy:l,readOnly:a})]})}function q({value:e,hex:s,colours:t,words:a,readOnly:n,set:l}){/* @__PURE__ */
|
|
33
|
+
return G(F,{value:e,hex:s,colours:t,label:a.settings.color,followsWord:a.colour.follows,anyWord:a.colour.any,readOnly:n,onChange:e=>l({color:e})})}function K({value:e,auto:s,words:t,readOnly:a,set:n}){const l=s?["auto",...p]:p,i=e??(s?"auto":"none"),r=E([]),o=e=>n({letterCase:"auto"===e?void 0:e});/* @__PURE__ */
|
|
34
|
+
return D("div",{className:"es-ts-set","data-ts-setting":"letterCase",children:[
|
|
35
|
+
/* @__PURE__ */G("span",{className:"es-ts-sub",children:t.settings.letterCase}),
|
|
36
|
+
/* @__PURE__ */G("div",{className:"es-ts-icons",role:"radiogroup","aria-label":t.settings.letterCase,onKeyDown:e=>{const s="ArrowRight"===e.key||"ArrowDown"===e.key?1:"ArrowLeft"===e.key||"ArrowUp"===e.key?-1:0;if(!s||a)return;e.preventDefault();const t=(l.indexOf(i)+s+l.length)%l.length;o(l[t]),r.current[t]?.focus()},children:l.map((e,s)=>{const n=e===i;if("auto"===e)return k(t.case.autoTitle,/* @__PURE__ */G(T,{ref:e=>{r.current[s]=e},role:"radio",pressed:n,className:"es-ts-icon es-ts-icon--word","aria-checked":n,"aria-label":t.case.auto,tabIndex:n?0:-1,disabled:a,onClick:()=>o(e),children:t.case.auto},e));const l=U[e];return k(t.case[e],/* @__PURE__ */G(T,{ref:e=>{r.current[s]=e},role:"radio",pressed:n,className:"es-ts-icon","aria-checked":n,"aria-label":t.case[e],tabIndex:n?0:-1,disabled:a,onClick:()=>o(e),children:/* @__PURE__ */G(l,{size:16})},e))})})]})}export{F as ColourSwatchRow,B as TextStyleItem,R as TextStylesGroup,H as TextStylesList};
|
|
@@ -67,7 +67,15 @@ interface TextStyleValues {
|
|
|
67
67
|
letterCase?: TextStyleCase;
|
|
68
68
|
/** px; headings only — the largest a heading is drawn anywhere on the site. */
|
|
69
69
|
largestSize?: number;
|
|
70
|
+
/**
|
|
71
|
+
* px; the size on a PHONE (Lewis 2026-10-19: Heading 1 at 106 px on a 390 px
|
|
72
|
+
* screen). Absent = the phone draws `size`. Edited on the Size row itself,
|
|
73
|
+
* in the phone view (`TextStylesList`'s `device`), never as a row of its own.
|
|
74
|
+
*/
|
|
75
|
+
sizePhone?: number;
|
|
70
76
|
}
|
|
77
|
+
/** Which view the list edits: the phone view's Size row writes `sizePhone`. */
|
|
78
|
+
type TextStyleDevice = 'desktop' | 'phone';
|
|
71
79
|
interface TextStyle {
|
|
72
80
|
/** The host's, stable: the list never renames an id. */
|
|
73
81
|
id: string;
|
|
@@ -256,4 +264,4 @@ declare function describeTextStyle(values: TextStyleValues, fonts: readonly Text
|
|
|
256
264
|
autoSize?: boolean;
|
|
257
265
|
}): string;
|
|
258
266
|
|
|
259
|
-
export { CAMPAIGN_TEXT_STYLE_SETTINGS, TEXT_STYLE_CASES, TEXT_STYLE_CASE_CSS, TEXT_STYLE_DEFAULT_COUNT, TEXT_STYLE_KINDS, TEXT_STYLE_MAX, TEXT_STYLE_RANGES, TEXT_STYLE_SETTINGS, type TextStyle, type TextStyleAuto, type TextStyleCase, type TextStyleCaseCss, type TextStyleColour, type TextStyleFont, type TextStyleKind, type TextStyleNumber, type TextStyleRange, type TextStyleSetting, type TextStyleValues, addTextStyle, canAddTextStyle, defaultTextStyles, describeTextStyle, isDefaultTextStyle, isTextStyleCase, removeTextStyle, resolveTextStyle, textStyleCaseCss, textStyleCaseOfCss, textStyleRowSize, updateTextStyle, weightWord };
|
|
267
|
+
export { CAMPAIGN_TEXT_STYLE_SETTINGS, TEXT_STYLE_CASES, TEXT_STYLE_CASE_CSS, TEXT_STYLE_DEFAULT_COUNT, TEXT_STYLE_KINDS, TEXT_STYLE_MAX, TEXT_STYLE_RANGES, TEXT_STYLE_SETTINGS, type TextStyle, type TextStyleAuto, type TextStyleCase, type TextStyleCaseCss, type TextStyleColour, type TextStyleDevice, type TextStyleFont, type TextStyleKind, type TextStyleNumber, type TextStyleRange, type TextStyleSetting, type TextStyleValues, addTextStyle, canAddTextStyle, defaultTextStyles, describeTextStyle, isDefaultTextStyle, isTextStyleCase, removeTextStyle, resolveTextStyle, textStyleCaseCss, textStyleCaseOfCss, textStyleRowSize, updateTextStyle, weightWord };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "efficient-easel",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "12.1.0",
|
|
4
4
|
"description": "Efficient Easel: the EFFICIENT editors' shared engine and chrome: the saved document as pure functions, the published renderer, and the editor frame, panels, Layers tree, text grammar and type-in-place box. Published as editor-shell up to 0.66.0 and as efficient-editor up to 0.95.0.",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"author": "Efficient Pty Ltd",
|
|
@@ -135,6 +135,16 @@
|
|
|
135
135
|
"import": "./dist/render/index.js",
|
|
136
136
|
"default": "./dist/render/index.js"
|
|
137
137
|
},
|
|
138
|
+
"./draw": {
|
|
139
|
+
"types": "./dist/draw/index.d.ts",
|
|
140
|
+
"import": "./dist/draw/index.js",
|
|
141
|
+
"default": "./dist/draw/index.js"
|
|
142
|
+
},
|
|
143
|
+
"./draw/client": {
|
|
144
|
+
"types": "./dist/draw/client.d.ts",
|
|
145
|
+
"import": "./dist/draw/client.js",
|
|
146
|
+
"default": "./dist/draw/client.js"
|
|
147
|
+
},
|
|
138
148
|
"./edit-lock": {
|
|
139
149
|
"types": "./dist/edit-lock/index.d.ts",
|
|
140
150
|
"import": "./dist/edit-lock/index.js",
|
|
@@ -532,7 +542,7 @@
|
|
|
532
542
|
"dist"
|
|
533
543
|
],
|
|
534
544
|
"peerDependencies": {
|
|
535
|
-
"efficient-shell": "^7.
|
|
545
|
+
"efficient-shell": "^7.69.1",
|
|
536
546
|
"react": ">=18",
|
|
537
547
|
"react-dom": ">=18"
|
|
538
548
|
},
|
|
@@ -542,7 +552,7 @@
|
|
|
542
552
|
"@types/node": "^22.0.0",
|
|
543
553
|
"@types/react": "^18.2.0",
|
|
544
554
|
"@types/react-dom": "^18.2.0",
|
|
545
|
-
"efficient-shell": "^7.
|
|
555
|
+
"efficient-shell": "^7.69.1",
|
|
546
556
|
"esbuild": "^0.27.0",
|
|
547
557
|
"jsdom": "^26.1.0",
|
|
548
558
|
"react": "^18.2.0",
|
package/dist/chunk-A6PY6C3C.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{DEFAULT_TEXT_STYLES_WORDS as o}from"./chunk-OGH6CC3E.js";import{DEFAULT_PICK_WORDS as r}from"./chunk-643PVCEG.js";import{DEFAULT_STYLE_CLIPBOARD_WORDS as t}from"./chunk-6WY6ZXJG.js";import{DEFAULT_SCREEN_WORDS as m}from"./chunk-VVPZMWJE.js";import{DEFAULT_CANVAS_WORDS as n}from"./chunk-TBY3DFKS.js";import{DEFAULT_TREE_WORDS as c}from"./chunk-K56YDHYQ.js";import{DEFAULT_PANEL_WORDS as s}from"./chunk-KFV7N2DJ.js";import{DEFAULT_NODE_MENU_WORDS as f}from"./chunk-WK3AFPXY.js";import{DEFAULT_SAVE_WORDS as p}from"./chunk-H6DDIBQ4.js";import{DEFAULT_COPY_WORDS as e}from"./chunk-33C6ALT5.js";import{DEFAULT_FIELDS_WORDS as i}from"./chunk-WRFD4EXD.js";import{DEFAULT_CHROME_WORDS as u,DEFAULT_NOTICE_WORDS as k}from"./chunk-Z6PVRXVY.js";import{DEFAULT_LOCK_WORDS as j}from"./chunk-RE4LP46F.js";import{DEFAULT_RAIL_WORDS as h}from"./chunk-2OAZYSWJ.js";import{DEFAULT_DRAG_WORDS as l}from"./chunk-AYWN5NRH.js";var a={notice:k,lock:j,save:p,chrome:u,rail:h,tree:c,panel:s,fields:i,pick:r,drag:l,menu:f,styleClipboard:t,copy:e,canvas:n,textStyles:o,screen:m},Y=o=>"object"==typeof o&&null!==o;function y(o,r){const t={};for(const m of Object.keys(o)){const n=o[m],c=r[m];null==c?t[m]=n:Y(n)?t[m]=Y(c)?y(n,c):n:t[m]=typeof c==typeof n?c:n}return t}function D(o,r){return r?y(o,r):o}export{a as DEFAULT_EASEL_STRINGS,D as mergeEaselStrings};
|