efficient-easel 0.99.1 → 0.100.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 +281 -36
- package/dist/autosave/index.d.ts +12 -6
- package/dist/blocks/index.d.ts +2 -2
- package/dist/canvas/index.d.ts +3 -3
- package/dist/canvas/index.js +1 -1
- package/dist/chrome/chrome.css +96 -29
- package/dist/chrome/index.d.ts +72 -19
- package/dist/chrome/index.js +17 -21
- package/dist/chunk-3EDSDPIP.js +1 -0
- package/dist/chunk-67GNT6PF.js +1 -0
- package/dist/{chunk-PI26YXYD.js → chunk-6EIVTKZZ.js} +21 -14
- package/dist/chunk-A5UK76FC.js +6 -0
- package/dist/chunk-AZT7V4UM.js +10 -0
- package/dist/chunk-DICUMYMG.js +12 -0
- package/dist/chunk-HDVD27VB.js +1 -0
- package/dist/chunk-JQM3V7XQ.js +1 -0
- package/dist/{chunk-TDA4HH54.js → chunk-JUQ6YJCG.js} +1 -1
- package/dist/chunk-LA54QLP5.js +1 -0
- package/dist/chunk-LGKQXSKO.js +16 -0
- package/dist/chunk-M6F6LS3H.js +1 -0
- package/dist/chunk-MH5GUZFQ.js +9 -0
- package/dist/chunk-P6O363EE.js +6 -0
- package/dist/chunk-PAELDYYS.js +1 -0
- package/dist/{chunk-JYPOOHII.js → chunk-QKVR3K73.js} +3 -3
- package/dist/chunk-SAJUCHOX.js +1 -0
- package/dist/chunk-TRVZ7C23.js +1 -0
- package/dist/chunk-V7GIIXFB.js +16 -0
- package/dist/{chunk-IBOFSS56.js → chunk-WZ7TGAAT.js} +1 -1
- package/dist/chunk-ZJEBF4NB.js +1 -0
- package/dist/copy/copy.css +388 -5
- package/dist/copy/index.d.ts +271 -8
- package/dist/copy/index.js +31 -10
- package/dist/data/index.d.ts +4 -4
- package/dist/drag/drag.css +10 -1
- package/dist/drag/index.d.ts +102 -11
- package/dist/drag/index.js +18 -17
- package/dist/{editor/editor.css → easel/easel.css} +16 -1
- package/dist/{editor → easel}/index.d.ts +146 -51
- package/dist/easel/index.js +9 -0
- package/dist/edit-lock/index.d.ts +3 -3
- package/dist/edit-lock/index.js +1 -1
- package/dist/fields/fields.css +103 -26
- package/dist/fields/index.d.ts +51 -13
- package/dist/fields/index.js +30 -46
- package/dist/gold/index.js +1 -1
- package/dist/icons/index.d.ts +10 -1
- package/dist/icons/index.js +1 -1
- package/dist/index.d.ts +3 -3
- package/dist/index.js +1 -1
- package/dist/markup/index.d.ts +94 -10
- package/dist/markup/index.js +1 -1
- package/dist/menu/index.d.ts +61 -6
- package/dist/menu/index.js +15 -15
- package/dist/menu/menu.css +17 -6
- package/dist/node-ops/index.d.ts +9 -9
- package/dist/node-ops/index.js +1 -1
- package/dist/panel/index.d.ts +73 -5
- package/dist/panel/index.js +18 -16
- package/dist/panel/panel.css +56 -1
- package/dist/pick/index.d.ts +42 -4
- package/dist/pick/index.js +7 -14
- package/dist/pick/pick.css +14 -0
- package/dist/rail/index.d.ts +6 -6
- package/dist/rail/index.js +1 -1
- package/dist/rail/rail.css +1 -1
- package/dist/strings/catalogue.d.ts +24 -40
- package/dist/strings/catalogue.js +1 -1
- package/dist/strings/index.d.ts +25 -23
- package/dist/strings/index.js +2 -2
- package/dist/style-clipboard/index.d.ts +5 -5
- package/dist/style-clipboard/index.js +1 -1
- package/dist/text-styles/index.d.ts +328 -0
- package/dist/text-styles/index.js +38 -0
- package/dist/text-styles/text-styles.css +309 -0
- package/dist/tree/index.d.ts +44 -3
- package/dist/tree/index.js +1 -1
- package/dist/tree/tree.css +71 -0
- package/dist/{types-CnRzp9oc.d.ts → types-DGcCsxs8.d.ts} +79 -12
- package/dist/{types-DNrn_w4V.d.ts → types-DWS-s9z-.d.ts} +10 -10
- package/dist/{types-pGBXevBU.d.ts → types-Djdq6Xkd.d.ts} +15 -8
- package/dist/{types-Dy6oR6Z2.d.ts → types-E3HrTPg2.d.ts} +20 -14
- package/dist/{types-C7HFvdtk.d.ts → types-VqL6t5HH.d.ts} +82 -5
- package/dist/{watch-DmasQA61.d.ts → watch-BTYOJpQU.d.ts} +19 -2
- package/dist/{wordFit-9B9nqyf3.d.ts → wordFit-D4S36PvB.d.ts} +1 -1
- package/dist/{words-DagJdwIA.d.ts → words-AHHfiaRY.d.ts} +31 -2
- package/dist/{words-D9ChvbNC.d.ts → words-BDignMl_.d.ts} +1 -1
- package/dist/{words-Cqmyey0s.d.ts → words-BMzV04b1.d.ts} +2 -2
- package/dist/words-CJjUKcV5.d.ts +37 -0
- package/dist/words-CRYvAiHX.d.ts +105 -0
- package/dist/{words-B2YLaKEr.d.ts → words-CnnHb9jo.d.ts} +1 -1
- package/dist/{words-CD3WADyb.d.ts → words-CzoyDNHm.d.ts} +4 -0
- package/dist/{words-bOMsUJk9.d.ts → words-DBq7vfHy.d.ts} +59 -6
- package/dist/{words-DOhF-4D4.d.ts → words-DMG4dYq2.d.ts} +1 -1
- package/dist/{words-BK-npta-.d.ts → words-DgHcY5qB.d.ts} +10 -4
- package/dist/{words-B87GIFWH.d.ts → words-is_Vy6hn.d.ts} +1 -1
- package/package.json +14 -8
- package/dist/chunk-66CKSTXP.js +0 -14
- package/dist/chunk-67VZRQLG.js +0 -13
- package/dist/chunk-6PS6STGA.js +0 -1
- package/dist/chunk-7A7O2JWQ.js +0 -1
- package/dist/chunk-H4B72XCJ.js +0 -1
- package/dist/chunk-JE63JHKO.js +0 -1
- package/dist/chunk-KDIVA6WD.js +0 -1
- package/dist/chunk-MCLBHENY.js +0 -1
- package/dist/chunk-QB3BZIRA.js +0 -5
- package/dist/chunk-SJQG5ENJ.js +0 -1
- package/dist/chunk-SUO5627P.js +0 -1
- package/dist/chunk-ZT7M24XD.js +0 -1
- package/dist/editor/index.js +0 -9
- /package/dist/{chunk-GGTPNGFJ.js → chunk-AELNNAFM.js} +0 -0
package/dist/fields/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ReactNode, KeyboardEvent } from 'react';
|
|
3
3
|
import { S as SettingsBucket } from '../buckets-CuLM47h9.js';
|
|
4
|
-
import { I as InspectorFields, a as InspectorFieldDef, F as FieldRenderer, b as FieldTextProps, c as FieldNumberProps, d as FieldSliderProps, e as
|
|
5
|
-
export { A as ArrayFieldDef, C as CustomFieldDef,
|
|
4
|
+
import { I as InspectorFields, a as InspectorFieldDef, F as FieldRenderer, b as FieldTextProps, c as FieldNumberProps, d as FieldSliderProps, e as FieldSelectManyProps, f as FieldSelectOneProps, g as FieldOption } from '../types-VqL6t5HH.js';
|
|
5
|
+
export { A as ArrayFieldDef, C as CustomFieldDef, h as CustomFieldRenderProps, i as FieldSelectProps, N as NumberFieldDef, O as ObjectFieldDef, R as RadioFieldDef, S as SelectFieldDef, j as SlotFieldDef, T as TextFieldDef, k as TextareaFieldDef } from '../types-VqL6t5HH.js';
|
|
6
6
|
import { R as ResolvableItem } from '../resolve-D68pb3Bx.js';
|
|
7
|
-
export { F as FieldsWords } from '../words-
|
|
7
|
+
export { F as FieldsWords } from '../words-CzoyDNHm.js';
|
|
8
8
|
import '../types-41704JE4.js';
|
|
9
9
|
|
|
10
10
|
interface InspectorProps {
|
|
@@ -28,7 +28,7 @@ interface InspectorProps {
|
|
|
28
28
|
renderers?: Partial<Record<InspectorFieldDef['type'], FieldRenderer>>;
|
|
29
29
|
/** Unique per panel, e.g. the selected node's id: every field id starts with it. */
|
|
30
30
|
idPrefix?: string;
|
|
31
|
-
/** The tab strip's name. Default "Settings" (`
|
|
31
|
+
/** The tab strip's name. Default "Settings" (`EaselStrings.panel.settings`). */
|
|
32
32
|
ariaLabel?: string;
|
|
33
33
|
/** Drawn after the rows, on every tab (an app's own trailing rows). */
|
|
34
34
|
children?: ReactNode;
|
|
@@ -49,7 +49,7 @@ interface InspectorProps {
|
|
|
49
49
|
* - THE SPACING IS THE PANEL'S (panel.css `--es-rhythm-*`): a row adds none of
|
|
50
50
|
* its own, so the rhythm is defined once for both editors.
|
|
51
51
|
* - A TAB'S KEY IS NOT ITS WORD. `bucket: 'Style'` names the tab; what the tab
|
|
52
|
-
* says is `
|
|
52
|
+
* says is `EaselStrings.panel.buckets.Style`, from the strings provider.
|
|
53
53
|
*/
|
|
54
54
|
declare function Inspector({ fields, values, onChange, readOnly, context, tab, onTab, tabs, tabIcons, renderers, idPrefix, ariaLabel, children, }: InspectorProps): react.JSX.Element;
|
|
55
55
|
|
|
@@ -98,7 +98,14 @@ interface PlannedRow {
|
|
|
98
98
|
bucket: SettingsBucket;
|
|
99
99
|
}
|
|
100
100
|
interface FieldPlan {
|
|
101
|
-
/**
|
|
101
|
+
/**
|
|
102
|
+
* Every field that is not a marker and not hidden, in the order declared.
|
|
103
|
+
*
|
|
104
|
+
* ⚠️ A `slot` field is among them and draws NOTHING: it is here so its name
|
|
105
|
+
* has a bucket (`bucketsOf`), and `Inspector` leaves it mounted but empty.
|
|
106
|
+
* A host that draws rows of its own, or counts them ("3 settings"), filters
|
|
107
|
+
* `row.field.type !== 'slot'` first. `buckets` already leaves slots out.
|
|
108
|
+
*/
|
|
102
109
|
rows: PlannedRow[];
|
|
103
110
|
/** The tabs to offer: the buckets that hold a row, in the owner's order. */
|
|
104
111
|
buckets: SettingsBucket[];
|
|
@@ -187,14 +194,14 @@ declare function useResolvedFields({ id, node, block, parent, appState }: Resolv
|
|
|
187
194
|
* so an editor can keep the open item across a re-render of the panel.
|
|
188
195
|
*
|
|
189
196
|
* Its words ("Add slide", "2 of 5", the rows' drag hint) are the strings
|
|
190
|
-
* provider's — `
|
|
197
|
+
* provider's — `EaselStrings.fields.list` and `.tree` — English with none.
|
|
191
198
|
*/
|
|
192
199
|
interface ListFieldProps<T> {
|
|
193
|
-
/** The list's name, e.g. "Slides". Also the back
|
|
200
|
+
/** The list's name, e.g. "Slides". Also the way back's word: "← Slides" (`InspectorUpLevel`). */
|
|
194
201
|
label: string;
|
|
195
202
|
/** A glyph before the name, as a settings row wears one. */
|
|
196
203
|
icon?: ReactNode;
|
|
197
|
-
/** One item's word, lower case, e.g. "slide": "Add slide", "Delete slide". Default "item" (`
|
|
204
|
+
/** One item's word, lower case, e.g. "slide": "Add slide", "Delete slide". Default "item" (`EaselStrings.fields.list.item`). */
|
|
198
205
|
noun?: string;
|
|
199
206
|
items: readonly T[];
|
|
200
207
|
onChange: (next: T[]) => void;
|
|
@@ -290,7 +297,7 @@ declare function useNumberEntry({ value, onChange, min, max, step, shiftStep, st
|
|
|
290
297
|
* small stacked arrows. What the typing, the keys and the arrows do is
|
|
291
298
|
* {@link useNumberEntry}'s.
|
|
292
299
|
*/
|
|
293
|
-
declare function FieldNumber({ id, value, onChange, min, max, step, shiftStep, styleValue, icon, unit, steppers, placeholder, readOnly, ariaLabel, ariaLabelledBy, }: FieldNumberProps): react.JSX.Element;
|
|
300
|
+
declare function FieldNumber({ id, value, onChange, min, max, step, shiftStep, styleValue, icon, unit, steppers, placeholder, readOnly, ariaLabel, ariaLabelledBy, title, }: FieldNumberProps): react.JSX.Element;
|
|
294
301
|
|
|
295
302
|
/**
|
|
296
303
|
* A slider row (plan step E4), for Site styles and Email styles: the name on
|
|
@@ -300,8 +307,14 @@ declare function FieldNumber({ id, value, onChange, min, max, step, shiftStep, s
|
|
|
300
307
|
* cell does — it is the same {@link useNumberEntry} — and may go past the
|
|
301
308
|
* slider's own travel (`sliderMin` / `sliderMax`); only `min` / `max` hold it.
|
|
302
309
|
* The slider then rests at its end. A grey value follows the style.
|
|
310
|
+
*
|
|
311
|
+
* `auto` (plan step E6, Site styles) is the word for "no number: each section
|
|
312
|
+
* draws its own". The design puts it ON the slider: one spot left of its
|
|
313
|
+
* travel is Auto, and the value reads the word, grey, with no unit. Dragged there, the row
|
|
314
|
+
* writes `undefined`; ↑ from Auto starts at `sliderMin` (one more than Auto is
|
|
315
|
+
* the slider's first number, not `min`), ↓ stays; an emptied box is Auto too.
|
|
303
316
|
*/
|
|
304
|
-
declare function FieldSlider({ id, label, value, onChange, min, max, step, shiftStep, styleValue, unit, sliderMin, sliderMax, readOnly, }: FieldSliderProps): react.JSX.Element;
|
|
317
|
+
declare function FieldSlider({ id, label, value, onChange, min, max, step, shiftStep, styleValue, unit, sliderMin, sliderMax, auto, readOnly, }: FieldSliderProps): react.JSX.Element;
|
|
305
318
|
|
|
306
319
|
/** The option a stored value names: equal by `Object.is`, so `0`, `false` and `''` are values too. */
|
|
307
320
|
declare function optionFor<V>(options: readonly FieldOption<V>[], value: V | undefined): FieldOption<V> | undefined;
|
|
@@ -315,7 +328,32 @@ declare function optionFor<V>(options: readonly FieldOption<V>[], value: V | und
|
|
|
315
328
|
* button its focus back, a letter jumps to the next option that starts with it.
|
|
316
329
|
* A click outside closes it (a CLICK, not a pointerdown: closing early moves the
|
|
317
330
|
* row and loses the press — the colour row learned that in 4.6).
|
|
331
|
+
*
|
|
332
|
+
* Options may sit under headings (`FieldOption.group`, `<optgroup>`'s job): a
|
|
333
|
+
* heading is a `role="group"`'s name, never an option, so the keys and a click
|
|
334
|
+
* pass it by. Without groups the list is exactly the flat one it always was.
|
|
335
|
+
*
|
|
336
|
+
* THE EDITOR'S ONE POP-UP LIST (card [MERGE] One Pop-up List For Editor And One
|
|
337
|
+
* For Shoppers, 2026-10-06). What the website editor's own lists did is here,
|
|
338
|
+
* each optional, and a list that asks for none draws what it always drew:
|
|
339
|
+
*
|
|
340
|
+
* searchable a search box at the top of the open list. It has the focus;
|
|
341
|
+
* letters go into it (no letter jump), ↓ ↑ walk what is left,
|
|
342
|
+
* Enter chooses, Escape closes. Home and End stay the box's.
|
|
343
|
+
* multiple several values. Enter, Space or a click ticks one and the list
|
|
344
|
+
* STAYS open; the save is in the options' order.
|
|
345
|
+
* thumb, meta a picture column and a quiet fact on the option.
|
|
346
|
+
* groupCount a heading says how many of its options are showing.
|
|
347
|
+
* renderOption / renderValue the host draws a row's or the button's content.
|
|
348
|
+
* inline the list opens in flow, for a panel that scrolls.
|
|
349
|
+
*
|
|
350
|
+
* THE OPEN LIST ALWAYS HAS A NAME (second host, 2026-10-07): the host's
|
|
351
|
+
* `ariaLabelledBy`, else its `ariaLabel`, else the BUTTON that opened it —
|
|
352
|
+
* which the row's `<label for>` names. Until then a list given neither was a
|
|
353
|
+
* `role="listbox"` with no accessible name (axe `aria-input-field-name`), and
|
|
354
|
+
* the engine's own settings row gave neither.
|
|
318
355
|
*/
|
|
319
|
-
declare function FieldSelect<V>(
|
|
356
|
+
declare function FieldSelect<V>(props: FieldSelectManyProps<V>): ReactNode;
|
|
357
|
+
declare function FieldSelect<V>(props: FieldSelectOneProps<V>): ReactNode;
|
|
320
358
|
|
|
321
|
-
export { FieldNumber, FieldNumberProps, FieldOption, type FieldPlan, FieldRenderer, FieldSelect,
|
|
359
|
+
export { FieldNumber, FieldNumberProps, FieldOption, type FieldPlan, FieldRenderer, FieldSelect, FieldSelectManyProps, FieldSelectOneProps, FieldSlider, FieldSliderProps, FieldText, FieldTextProps, type FieldsBlock, Inspector, InspectorField, InspectorFieldDef, type InspectorFieldProps, InspectorFields, type InspectorProps, ListField, type ListFieldProps, type NumberEntryOptions, type PlannedRow, type ResolvedFieldsInput, SettingsBucket, bucketsOf, clampNumber, copyItem, insertAt, labelOf, moveTo, optionFor, parseTyped, planFields, removeAt, useNumberEntry, useResolvedFields };
|
package/dist/fields/index.js
CHANGED
|
@@ -1,53 +1,37 @@
|
|
|
1
|
-
import{
|
|
2
|
-
return
|
|
3
|
-
return g("div",{className:`es-fnum${u?" es-fnum--arrows":""}${w?" is-style":""}${h?" is-readonly":""}`,children:[c?/* @__PURE__ */k("span",{className:"es-fnum-icon","aria-hidden":"true",children:c}):null,
|
|
4
|
-
/* @__PURE__ */k("input",{id:e,type:"text",inputMode:"decimal",className:"es-fnum-box","aria-label":f,"aria-labelledby":b,...y,placeholder:y.placeholder??p}),d?/* @__PURE__ */k("span",{className:"es-fnum-unit",children:d}):null,u?/* @__PURE__ */g("span",{className:"es-fnum-arrows",children:[
|
|
5
|
-
/* @__PURE__ */k(S,{dir:1,label:v.more,disabled:h,nudge:x}),
|
|
6
|
-
/* @__PURE__ */k(S,{dir:-1,label:v.less,disabled:h,nudge:x})]}):null]})}function I(e,n){return e.find(e=>Object.is(e.value,n))}function L({id:e,value:n,options:t,onChange:r,placeholder:l,readOnly:a=!1,ariaLabel:i,ariaLabelledBy:s}){const c=m("fields",o),d=y(),[u,p]=f(!1),[h,x]=f(0),w=b(null),N=b(null),C=b(null),O=I(t,n),S=O?t.indexOf(O):-1,$=()=>{a||0===t.length||(x(S>=0?S:0),p(!0))},L=e=>{p(!1),e&&N.current?.focus()},j=e=>{const l=t[e];l&&!l.disabled&&(Object.is(l.value,n)||r(l.value),L(!0))};v(()=>{if(!u)return;C.current?.focus();const e=w.current?.ownerDocument;if(!e)return;const n=e=>{w.current&&!w.current.contains(e.target)&&p(!1)};return e.addEventListener("click",n,!0),()=>e.removeEventListener("click",n,!0)},[u]);const D=e=>{const n=t.length;if(0===n)return;let r=(e%n+n)%n;for(let l=0;l<n&&t[r]?.disabled;l++)r=(r+(e>=h?1:-1)+n)%n;x(r)};/* @__PURE__ */
|
|
7
|
-
return g("div",{className:"es-fsel",ref:w,children:[
|
|
8
|
-
/* @__PURE__ */g("button",{ref:N,id:e,type:"button",className:"es-fin es-fsel-button","aria-haspopup":"listbox","aria-expanded":u,"aria-controls":u?d:void 0,"aria-label":i,"aria-labelledby":s,disabled:a,onClick:()=>u?L(!1):$(),onKeyDown:e=>{"ArrowDown"!==e.key&&"ArrowUp"!==e.key||(e.preventDefault(),$())},children:[
|
|
9
|
-
/* @__PURE__ */k("span",{className:O?"es-fsel-value":"es-fsel-value is-empty",children:O?O.label:l??c.choose}),
|
|
10
|
-
/* @__PURE__ */k("span",{className:"es-fsel-chev","aria-hidden":"true"})]}),u?/* @__PURE__ */k("ul",{ref:C,id:d,role:"listbox",tabIndex:-1,className:"es-fsel-list","aria-activedescendant":`${d}-${h}`,"aria-labelledby":s,"aria-label":s?void 0:i,onKeyDown:e=>{switch(e.key){case"ArrowDown":return e.preventDefault(),void D(h+1);case"ArrowUp":return e.preventDefault(),void D(h-1);case"Home":return e.preventDefault(),void D(0);case"End":return e.preventDefault(),void D(t.length-1);case"Enter":case" ":return e.preventDefault(),void j(h);case"Escape":return e.preventDefault(),e.stopPropagation(),void L(!0);case"Tab":return void L(!1);default:if(1===e.key.length&&/\S/.test(e.key)){const n=e.key.toLowerCase(),r=t.length;for(let e=1;e<=r;e++){const l=(h+e)%r;if(!t[l]?.disabled&&t[l]?.label.toLowerCase().startsWith(n))return void x(l)}}}},children:t.map((e,n)=>/* @__PURE__ */k("li",{id:`${d}-${n}`,role:"option","aria-selected":n===S,"aria-disabled":e.disabled||void 0,className:`es-fsel-option${n===h?" is-active":""}${n===S?" is-chosen":""}`,onMouseEnter:()=>x(n),onClick:()=>j(n),children:e.label},`${n}-${String(e.value)}`))}):null]})}function j({id:e,value:n,onChange:t,placeholder:r,multiline:l=!1,rows:a=3,readOnly:i=!1,ariaLabel:s,ariaLabelledBy:o}){const c=n??"";return l?/* @__PURE__ */k("textarea",{id:e,className:"es-fin es-fin--area",value:c,rows:a,placeholder:r,readOnly:i,"aria-label":s,"aria-labelledby":o,onChange:e=>t(e.target.value)}):/* @__PURE__ */k("input",{id:e,type:"text",className:"es-fin",value:c,placeholder:r,readOnly:i,"aria-label":s,"aria-labelledby":o,onChange:e=>t(e.target.value)})}function D(e,n,t){const r=e.slice();return r.splice(Math.max(0,Math.min(n,r.length)),0,t),r}function M(e,n,t){const r=e.slice(),[l]=r.splice(n,1);return r.splice(Math.max(0,Math.min(t,r.length)),0,l),r}function P(e,n){return e.filter((e,t)=>t!==n)}function A(e){return null===e||"object"!=typeof e?e:JSON.parse(JSON.stringify(e))}function B(){/* @__PURE__ */
|
|
11
|
-
return g("svg",{width:"12",height:"12",viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",children:[
|
|
1
|
+
import{FieldSelect as e}from"../chunk-LGKQXSKO.js";export{FieldSelect,FieldSlider,optionFor}from"../chunk-LGKQXSKO.js";import{LayersTree as n,TreeSeam as l,TreeRow as t,TreeRowAction as r}from"../chunk-V7GIIXFB.js";import{SettingsField as i,SETTINGS_BUCKETS as a,SettingsTabs as o,SettingsGroup as s}from"../chunk-DICUMYMG.js";import{DEFAULT_TREE_WORDS as c}from"../chunk-3EDSDPIP.js";import{DEFAULT_PANEL_WORDS as d}from"../chunk-TRVZ7C23.js";export{useResolvedFields}from"../chunk-YRLPFZW3.js";import{InspectorUpLevel as u}from"../chunk-MH5GUZFQ.js";import"../chunk-ZJEBF4NB.js";import{FieldNumber as m}from"../chunk-A5UK76FC.js";export{FieldNumber,clampNumber,parseTyped,useNumberEntry}from"../chunk-A5UK76FC.js";import{SettingsSegmented as h}from"../chunk-P6O363EE.js";import{DEFAULT_FIELDS_WORDS as p}from"../chunk-LA54QLP5.js";import{useWords as b}from"../chunk-MFIRYGHW.js";import"../chunk-BZ5ASXOL.js";import{useTreeDrag as f,gapToMoveIndex as g}from"../chunk-67GNT6PF.js";import"../chunk-6EIVTKZZ.js";import"../chunk-KRXQM65X.js";import"../chunk-NKB3KVAB.js";import{useId as v,useState as y}from"react";import{jsx as k,jsxs as x,Fragment as N}from"react/jsx-runtime";function O({id:e,value:n,onChange:l,placeholder:t,multiline:r=!1,rows:i=3,readOnly:a=!1,ariaLabel:o,ariaLabelledBy:s}){const c=n??"";return r?/* @__PURE__ */k("textarea",{id:e,className:"es-fin es-fin--area",value:c,rows:i,placeholder:t,readOnly:a,"aria-label":o,"aria-labelledby":s,onChange:e=>l(e.target.value)}):/* @__PURE__ */k("input",{id:e,type:"text",className:"es-fin",value:c,placeholder:t,readOnly:a,"aria-label":o,"aria-labelledby":s,onChange:e=>l(e.target.value)})}function C(e,n,l){const t=e.slice();return t.splice(Math.max(0,Math.min(n,t.length)),0,l),t}function j(e,n,l){const t=e.slice(),[r]=t.splice(n,1);return t.splice(Math.max(0,Math.min(l,t.length)),0,r),t}function w(e,n){return e.filter((e,l)=>l!==n)}function I(e){return null===e||"object"!=typeof e?e:JSON.parse(JSON.stringify(e))}function F(){/* @__PURE__ */
|
|
2
|
+
return x("svg",{width:"12",height:"12",viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",children:[
|
|
12
3
|
/* @__PURE__ */k("circle",{cx:"9",cy:"6",r:"1.6"}),
|
|
13
4
|
/* @__PURE__ */k("circle",{cx:"15",cy:"6",r:"1.6"}),
|
|
14
5
|
/* @__PURE__ */k("circle",{cx:"9",cy:"12",r:"1.6"}),
|
|
15
6
|
/* @__PURE__ */k("circle",{cx:"15",cy:"12",r:"1.6"}),
|
|
16
7
|
/* @__PURE__ */k("circle",{cx:"9",cy:"18",r:"1.6"}),
|
|
17
|
-
/* @__PURE__ */k("circle",{cx:"15",cy:"18",r:"1.6"})]})}var
|
|
18
|
-
return
|
|
19
|
-
/* @__PURE__ */
|
|
20
|
-
/* @__PURE__ */
|
|
21
|
-
/* @__PURE__ */
|
|
22
|
-
/* @__PURE__ */k("span",{className:"es-list-
|
|
23
|
-
/* @__PURE__ */k("
|
|
24
|
-
/* @__PURE__ */k("
|
|
25
|
-
/* @__PURE__ */k("button",{type:"button",className:"es-fbtn",disabled:!
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
/* @__PURE__ */
|
|
29
|
-
/* @__PURE__ */
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
/* @__PURE__ */k(
|
|
33
|
-
/* @__PURE__ */k(r,{kind:"plain",label:$.duplicateItem({noun:L}),disabled:!j,onClick:()=>R(l),children:/* @__PURE__ */g("svg",{width:"13",height:"13",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[
|
|
8
|
+
/* @__PURE__ */k("circle",{cx:"15",cy:"18",r:"1.6"})]})}var $={parentId:"list",slot:"items"};function S({label:e,icon:i,noun:a,items:o,onChange:s,newItem:d,summary:m,itemName:h,thumb:v,min:y=0,max:O,readOnly:S=!1,open:L,onOpen:M,renderItem:P}){const B=b("fields",p).list,K=b("tree",c),A=a??B.item,G=!S&&("number"!=typeof O||o.length<O),Z=!S&&o.length>y,E=(e,n)=>h?h(e,n):B.itemName({noun:A,n:n+1}),T=f({keyOf:e=>String(e),canDrop:(e,n)=>n.parentId===$.parentId&&n.slot===$.slot,onDrop:(e,n)=>{const l=g({...$,index:e},n);l!==e&&s(j(o,e,l))},onStep:(e,n)=>s(j(o,e,e+n)),canStep:(e,n)=>e+n>=0&&e+n<o.length,readOnly:S}),V=e=>{G&&s(C(o,e,d()))},X=e=>{G&&s(C(o,e+1,I(o[e])))},D=e=>{Z&&(s(w(o,e)),null!==L&&M(null))};if(null!==L&&L>=0&&L<o.length){const n=o[L];/* @__PURE__ */
|
|
9
|
+
return x("div",{className:"es-list is-open",children:[
|
|
10
|
+
/* @__PURE__ */k(u,{inline:!0,name:e,onSelect:()=>M(null)}),
|
|
11
|
+
/* @__PURE__ */x("div",{className:"es-list-title",children:[
|
|
12
|
+
/* @__PURE__ */k("span",{className:"es-list-name",children:E(n,L)}),
|
|
13
|
+
/* @__PURE__ */k("span",{className:"es-list-count",children:B.position({n:L+1,total:o.length})})]}),
|
|
14
|
+
/* @__PURE__ */k("div",{className:"es-list-item",children:P(n,L,e=>{const n=o.slice();n[L]=e,s(n)})}),S?null:/* @__PURE__ */x("div",{className:"es-list-item-actions",children:[
|
|
15
|
+
/* @__PURE__ */k("button",{type:"button",className:"es-fbtn",disabled:!G,onClick:()=>X(L),children:B.duplicate}),
|
|
16
|
+
/* @__PURE__ */k("button",{type:"button",className:"es-fbtn es-fbtn--danger",disabled:!Z,onClick:()=>D(L),children:B.deleteItem({noun:A})})]})]})}/* @__PURE__ */
|
|
17
|
+
return x("div",{className:"es-list",children:[
|
|
18
|
+
/* @__PURE__ */x("div",{className:"es-list-head",children:[
|
|
19
|
+
/* @__PURE__ */x("span",{className:"es-list-label",children:[i?/* @__PURE__ */k("span",{className:"es-field-icon","aria-hidden":"true",children:i}):null,e]}),
|
|
20
|
+
/* @__PURE__ */k("span",{className:"es-list-count",children:o.length})]}),o.length?/* @__PURE__ */x(n,{className:"es-list-tree",rootProps:T.rootProps(),children:[o.map((e,n)=>{const i={...$,index:n},a=T.row({item:n,place:i});/* @__PURE__ */
|
|
21
|
+
return x("div",{className:"es-list-entry",children:[n>0?/* @__PURE__ */k(l,{...T.seam({place:i}),onAdd:G?()=>V(n):void 0,label:B.addHere({noun:A})}):null,
|
|
22
|
+
/* @__PURE__ */k(t,{icon:v?v(e,n):/* @__PURE__ */k(F,{}),name:E(e,n),preview:m?m(e,n):void 0,draggable:a.draggable,dragging:a.dragging,drop:a.drop,rowProps:a.rowProps,words:K,onSelect:()=>M(n),actions:S?void 0:/* @__PURE__ */x(N,{children:[
|
|
23
|
+
/* @__PURE__ */k(r,{kind:"plain",label:B.duplicateItem({noun:A}),disabled:!G,onClick:()=>X(n),children:/* @__PURE__ */x("svg",{width:"13",height:"13",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[
|
|
34
24
|
/* @__PURE__ */k("rect",{x:"9",y:"9",width:"11",height:"11",rx:"2"}),
|
|
35
25
|
/* @__PURE__ */k("path",{d:"M5 15V6a2 2 0 0 1 2-2h9"})]})}),
|
|
36
|
-
/* @__PURE__ */k(r,{kind:"delete",label
|
|
37
|
-
/* @__PURE__ */k(
|
|
38
|
-
return k(s,{id:`${
|
|
39
|
-
return k(
|
|
40
|
-
return k(
|
|
41
|
-
return k(
|
|
42
|
-
return k(
|
|
43
|
-
return k(
|
|
44
|
-
return k(
|
|
45
|
-
return k(
|
|
46
|
-
return
|
|
47
|
-
/* @__PURE__ */
|
|
48
|
-
return g("div",{className:"es-fslider"+(v?" is-style":""),children:[
|
|
49
|
-
/* @__PURE__ */g("div",{className:"es-fslider-top",children:[
|
|
50
|
-
/* @__PURE__ */k("label",{className:"es-fslider-name",htmlFor:h,children:n}),
|
|
51
|
-
/* @__PURE__ */g("span",{className:"es-fslider-read",children:[
|
|
52
|
-
/* @__PURE__ */k("input",{id:h,type:"text",inputMode:"decimal",className:"es-fslider-value",...f}),c?/* @__PURE__ */k("span",{className:"es-fslider-unit",children:c}):null]})]}),
|
|
53
|
-
/* @__PURE__ */k("input",{type:"range",className:"es-fslider-range",min:d,max:u,step:i,value:w(x,d,u),disabled:m,"aria-label":n,onChange:e=>b(Number(e.target.value))})]})}export{$ as FieldNumber,L as FieldSelect,J as FieldSlider,j as FieldText,H as Inspector,R as InspectorField,F as ListField,U as bucketsOf,w as clampNumber,A as copyItem,D as insertAt,K as labelOf,M as moveTo,I as optionFor,N as parseTyped,X as planFields,P as removeAt,O as useNumberEntry};
|
|
26
|
+
/* @__PURE__ */k(r,{kind:"delete",label:B.deleteItem({noun:A}),disabled:!Z,onClick:()=>D(n),children:/* @__PURE__ */k("svg",{width:"13",height:"13",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round","aria-hidden":"true",children:/* @__PURE__ */k("path",{d:"M4 7h16M10 11v6M14 11v6M6 7l1 12a2 2 0 0 0 2 2h6a2 2 0 0 0 2-2l1-12M9 7V4h6v3"})})})]})})]},n)}),
|
|
27
|
+
/* @__PURE__ */k(l,{...T.seam({place:{...$,index:o.length}})})]}):null,S?null:/* @__PURE__ */k("button",{type:"button",className:"es-list-add",disabled:!G,onClick:()=>V(o.length),children:B.add({noun:A})})]})}var L=(e,n)=>"string"==typeof e.label&&e.label?e.label:n;function M({field:e,name:n,id:l,value:t,onChange:r,readOnly:i,context:a,renderers:o}){const[c,d]=y(!0),u=t&&"object"==typeof t?t:{};/* @__PURE__ */
|
|
28
|
+
return k(s,{id:`${l}-group`,title:L(e,n),open:c,onToggle:d,children:Object.entries(e.objectFields).map(([e,t])=>/* @__PURE__ */k(B,{field:t,name:`${n}.${e}`,id:`${l}-${e}`,value:u[e],onChange:n=>r({...u,[e]:n}),readOnly:i,context:a,renderers:o},e))})}function P({field:e,name:n,id:l,value:t,onChange:r,readOnly:i,context:a,renderers:o,openItem:s,onOpenItem:c}){const[d,u]=y(null),m=c?s??null:d,h=c??u,p=Array.isArray(t)?t:[],b=e.getItemSummary;/* @__PURE__ */
|
|
29
|
+
return k(S,{label:L(e,n),icon:e.icon,noun:"string"==typeof e.noun?e.noun:void 0,items:p,onChange:r,newItem:()=>I({...e.defaultItemProps??{}}),summary:b?(e,n)=>b(e,n):void 0,min:e.min,max:e.max,readOnly:i,open:m,onOpen:h,renderItem:(t,r,s)=>Object.entries(e.arrayFields).map(([e,c])=>/* @__PURE__ */k(B,{field:c,name:`${n}[${r}].${e}`,id:`${l}-${r}-${e}`,value:t?.[e],onChange:n=>s({...t,[e]:n}),readOnly:i,context:a,renderers:o},e))})}function B(n){const{field:l,name:t,id:r,value:a,onChange:o,readOnly:s,context:c,renderers:d}=n;if(!l||l.marker||!1===l.visible)return null;const u=d?.[l.type];if(u)return u({field:l,name:t,id:r,value:a,onChange:o,readOnly:s});switch(l.type){case"custom":{const e={...c,field:l,name:t,id:r,value:a,onChange:o,readOnly:s};return l.render(e)}case"text":case"textarea":/* @__PURE__ */
|
|
30
|
+
return k(i,{label:L(l,t),htmlFor:r,icon:l.icon,hint:l.hint,children:/* @__PURE__ */k(O,{id:r,value:"string"==typeof a?a:null==a?"":String(a),onChange:o,placeholder:l.placeholder,multiline:"textarea"===l.type,readOnly:s})});case"number":/* @__PURE__ */
|
|
31
|
+
return k(i,{label:L(l,t),htmlFor:r,icon:l.icon,hint:l.hint,children:/* @__PURE__ */k(m,{id:r,value:"number"==typeof a?a:void 0,onChange:o,min:l.min,max:l.max,step:l.step,placeholder:l.placeholder,readOnly:s})});case"select":{const n=`${r}-label`;/* @__PURE__ */
|
|
32
|
+
return k(i,{label:L(l,t),labelId:n,htmlFor:r,icon:l.icon,hint:l.hint,children:/* @__PURE__ */k(e,{id:r,value:a,options:l.options,onChange:o,readOnly:s,ariaLabelledBy:n})})}case"radio":/* @__PURE__ */
|
|
33
|
+
return k(i,{label:L(l,t),icon:l.icon,hint:l.hint,children:/* @__PURE__ */k(h,{ariaLabel:L(l,t),value:a,options:l.options.map(e=>({id:e.value,label:e.label,icon:e.icon,disabled:e.disabled||s})),onChange:e=>{s||o(e)}})});case"object":/* @__PURE__ */
|
|
34
|
+
return k(M,{...n,field:l});case"array":/* @__PURE__ */
|
|
35
|
+
return k(P,{...n,field:l});case"slot":return null}}var K=e=>a.includes(e);function A(e){let n=a[0];const l=[],t=/* @__PURE__ */new Set;for(const[r,i]of Object.entries(e))i&&(K(i.bucket)&&(n=i.bucket),i.marker||!1===i.visible||(l.push({name:r,field:i,bucket:n}),"slot"!==i.type&&t.add(n)));return{rows:l,buckets:a.filter(e=>t.has(e))}}function G(e){return new Map(A(e).rows.map(e=>[e.name,e.bucket]))}function Z({fields:e,values:n,onChange:l,readOnly:t=!1,context:r,tab:i,onTab:a,tabs:s=!0,tabIcons:c,renderers:u,idPrefix:m,ariaLabel:h,children:p}){const f=b("panel",d),g=v(),N=m??`es-insp${g.replace(/:/g,"")}`,O=A(e),[C,j]=y(void 0),w=i??C,I=w&&O.buckets.includes(w)?w:O.buckets[0],[F,$]=y(null),S=F&&F.panel===N&&O.rows.some(e=>e.name===F.name)?F:null,L=s&&O.buckets.length>1&&!S,M=`${N}-rows`,P=e=>`${N}-tab-${e.toLowerCase()}`;/* @__PURE__ */
|
|
36
|
+
return x("div",{className:"es-insp",children:[L?/* @__PURE__ */k("div",{className:"es-insp-tabs",children:/* @__PURE__ */k(o,{ariaLabel:h??f.settings,activeId:I,onSelect:e=>{const n=e;void 0===i&&j(n),a?.(n)},items:O.buckets.map(e=>({id:e,label:f.buckets[e],icon:c?.[e],htmlId:P(e),panelId:M}))})}):null,
|
|
37
|
+
/* @__PURE__ */x("div",{className:"es-insp-rows",id:M,role:L?"tabpanel":void 0,"aria-labelledby":L&&I?P(I):void 0,children:[O.rows.map(({name:e,field:i,bucket:a})=>/* @__PURE__ */k("div",{className:"es-insp-row","data-field":e,"data-bucket":a,hidden:!!(S?S.name!==e:L&&a!==I)||void 0,children:/* @__PURE__ */k(B,{field:i,name:e,id:`${N}-${e}`,value:n[e],onChange:n=>l(e,n),readOnly:t,context:r,renderers:u,openItem:S&&S.name===e?S.index:null,onOpenItem:n=>$(null===n?null:{panel:N,name:e,index:n})})},e)),S?null:p]})]})}export{O as FieldText,Z as Inspector,B as InspectorField,S as ListField,G as bucketsOf,I as copyItem,C as insertAt,L as labelOf,j as moveTo,A as planFields,w as removeAt};
|
package/dist/gold/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{GoldLayer,GoldTextInput,goldSegments}from"../chunk-
|
|
1
|
+
export{GoldLayer,GoldTextInput,goldSegments}from"../chunk-QKVR3K73.js";import"../chunk-HDVD27VB.js";var e={accent:"var(--gold, #c9a461)",quiet:"var(--es-muted, #6b7280)",caret:"var(--es-text, #111827)",placeholder:"var(--es-field-placeholder, #9ca3af)",delimiterOpacity:"0.35",delimiterRestingOpacity:"0.25",boldShadow:"0 0 0.4px currentColor",italicDecoration:"underline dotted",strikeDecoration:"line-through",pad:"0"},t={accent:"--es-gold-accent",quiet:"--es-gold-quiet",caret:"--es-gold-caret",placeholder:"--es-gold-placeholder",delimiterOpacity:"--es-gold-delim-opacity",delimiterRestingOpacity:"--es-gold-delim-resting-opacity",boldShadow:"--es-gold-bold-shadow",italicDecoration:"--es-gold-italic-decoration",strikeDecoration:"--es-gold-strike-decoration",pad:"--es-gold-pad"};export{t as goldCssVars,e as goldTokens};
|
package/dist/icons/index.d.ts
CHANGED
|
@@ -167,6 +167,9 @@ declare const iconMeanings: {
|
|
|
167
167
|
readonly "case-normal": "letter case LEFT AS TYPED — `Aa`, the `Normal` option of the Letter case buttons (Normal / Uppercase / Lowercase) on the campaign editor's Text block, and of the storefront part panel's Case strip. The plan calls it sentence case; it changes nothing the merchant typed. A capital A beside a one-storey a. Decided 2026-10-06.";
|
|
168
168
|
readonly "case-upper": "letter case ALL CAPITALS — `AA`, the `Uppercase` option of the Letter case buttons on the campaign editor's Text block, and of the storefront part panel's Case strip. Two capital A's. Decided 2026-10-06.";
|
|
169
169
|
readonly "case-lower": "letter case ALL SMALL LETTERS — `aa`, the `Lowercase` option of the Letter case buttons on the campaign editor's Text block, and of the storefront part panel's Case strip. Two one-storey a's. Decided 2026-10-06.";
|
|
170
|
+
readonly "align-justify": "JUSTIFY — text whose rows run edge to edge. Worn by the Justify button on the final text box's second toolbar row, beside Left, Center and Right, and by the Justify chip of the alignment strip. Three full-width rows on the same three heights the other alignment glyphs use. Decided 2026-10-06 (the design was made final that day).";
|
|
171
|
+
readonly "panel-left": "the LEFT SIDE PANEL itself — worn by the Hide panel button at the end of a left panel's head (`MediaPanelHead`, both editors' SidePanelHeads) and by the Show panel button in the strip a hidden left panel leaves. One control, so one drawing: hiding and showing the panel wear the same glyph. A frame with its left column ruled off. ⛔ NOT an ✕: an ✕ closes a dialog, and a panel head has none (owner, 2026-10-04).";
|
|
172
|
+
readonly "panel-right": "the RIGHT SIDE PANEL itself — the twin of `panel-left` for the settings panel: its head's Hide panel button and the strip a hidden right panel leaves. A frame with its right column ruled off.";
|
|
170
173
|
};
|
|
171
174
|
type IconName = keyof typeof iconMeanings;
|
|
172
175
|
/** Delete · keep · efficient-shop · components/UiIcon.tsx:99 */
|
|
@@ -491,5 +494,11 @@ declare function CaseNormalIcon({ size, ...rest }: IconProps): react.JSX.Element
|
|
|
491
494
|
declare function CaseUpperIcon({ size, ...rest }: IconProps): react.JSX.Element;
|
|
492
495
|
/** letter case ALL SMALL LETTERS — `aa`, the `Lowercase` option of the Letter case buttons on the campaign editor's Text block, and of the storefront part panel's Case strip. Two one-storey a's. Decided 2026-10-06. · picked · efficient-easel · [ADD] Text Box Icons For The Final Design, 2026-10-06 (step E2 of the campaign-editor plan Lewis approved that day). Final design: https://claude.ai/artifact/Mpzgvi2sZmTCmciZW36w5H. The Text block's toolbar is two rows of 32px glyph buttons with the names only in the tooltip and the aria-label; the number row is Font size · Line spacing · Letter spacing · Paragraph spacing. Checked at 16px beside every neighbour named here before it was committed. MOVED FROM THE STOREFRONT: efficient-storefront `components/PartGlyphs.tsx` `CaseGlyph` (`aa`, live text); the set is the one source now. ⛔ NOT `case-normal`, a capital A beside the a. ⛔ NOT `quiet`, ONE small a drawn under the set's box, which is the quiet mark on a phrase. ⛔ NOT `case`, the row's T + a. A 3-unit channel between the first stem and the second bowl keeps them two letters at 16px. */
|
|
493
496
|
declare function CaseLowerIcon({ size, ...rest }: IconProps): react.JSX.Element;
|
|
497
|
+
/** JUSTIFY — text whose rows run edge to edge. Worn by the Justify button on the final text box's second toolbar row, beside Left, Center and Right, and by the Justify chip of the alignment strip. Three full-width rows on the same three heights the other alignment glyphs use. Decided 2026-10-06 (the design was made final that day). · new · efficient-easel · E5b, the final text box, design final 2026-10-06: https://claude.ai/artifact/Mpzgvi2sZmTCmciZW36w5H — its toolbar draws Justify as `M4 6.5h16M4 12h16M4 17.5h16`, and this is that drawing. ⛔ NOT `align-separate`, whose own entry says "NOT `justify`": it opens a channel down the middle of each row, which is where rows SIT, not how text runs. The package drew Justify with it until now; that was a borrowed meaning. ⛔ NOT `text-lines`, three rules with a short last one, which is a paragraph of body copy. ⛔ NOT `align-left`, whose rows are of three lengths. */
|
|
498
|
+
declare function AlignJustifyIcon({ size, ...rest }: IconProps): react.JSX.Element;
|
|
499
|
+
/** the LEFT SIDE PANEL itself — worn by the Hide panel button at the end of a left panel's head (`MediaPanelHead`, both editors' SidePanelHeads) and by the Show panel button in the strip a hidden left panel leaves. One control, so one drawing: hiding and showing the panel wear the same glyph. A frame with its left column ruled off. ⛔ NOT an ✕: an ✕ closes a dialog, and a panel head has none (owner, 2026-10-04). · new · efficient-easel · card [MERGE] One Media Panel Head For Both Editors, 2026-10-06 — the drawing both editors already carried twice: efficient-storefront components/PanelToggleIcon.tsx and efficient-admin-portal src/components/email/CampaignTopBar.tsx `PanelToggleGlyph`. */
|
|
500
|
+
declare function PanelLeftIcon({ size, ...rest }: IconProps): react.JSX.Element;
|
|
501
|
+
/** the RIGHT SIDE PANEL itself — the twin of `panel-left` for the settings panel: its head's Hide panel button and the strip a hidden right panel leaves. A frame with its right column ruled off. · new · efficient-easel · card [MERGE] One Media Panel Head For Both Editors, 2026-10-06 — the drawing both editors already carried twice: efficient-storefront components/PanelToggleIcon.tsx and efficient-admin-portal src/components/email/CampaignTopBar.tsx `PanelToggleGlyph`. */
|
|
502
|
+
declare function PanelRightIcon({ size, ...rest }: IconProps): react.JSX.Element;
|
|
494
503
|
|
|
495
|
-
export { AccentIcon, AccountIcon, AddIcon, AlignCenterIcon, AlignLeftIcon, AlignRightIcon, AlignSeparateIcon, AnchorIcon, AnimationIcon, BackgroundIcon, BellIcon, BlackAndWhiteIcon, BlockBadgeIcon, BlockBannerIcon, BlockBoxIcon, BlockButtonIcon, BlockColumnIcon, BlockCouponIcon, BlockDividerIcon, BlockFooterIcon, BlockHeadingIcon, BlockIncludedListIcon, BlockLayeredImagesIcon, BlockProductIcon, BlockSectionIcon, BlockSocialIcon, BlockSpacerIcon, BlockTextIcon, BlockVideoIcon, BlogPostIcon, BoldIcon, BreadcrumbIcon, ButtonArrowIcon, ButtonIcon, CarIcon, CartIcon, CaseIcon, CaseLowerIcon, CaseNormalIcon, CaseUpperIcon, CategoryIcon, ChatIcon, CheckIcon, ChevronIcon, ClearMarksIcon, ClockIcon, CloseIcon, ColumnGapIcon, ColumnWidthsIcon, ColumnsIcon, ContrastIcon, CopyIcon, CopyStyleIcon, CopyToPageIcon, CornerIcon, DesktopIcon, DiagramIcon, DirectionDownIcon, DirectionIcon, DirectionLeftIcon, DirectionRightIcon, DirectionUpIcon, DollarIcon, DragIcon, DropIcon, DuplicateIcon, EmphasisIcon, ExternalIcon, EyeIcon, EyeOffIcon, FinishIcon, FullWidthIcon, GapIcon, GlobeIcon, GridIcon, GroundIcon, HashIcon, HeadquartersIcon, HeightIcon, HoverIcon, type IconName, type IconProps, ImageIcon, ItalicIcon, LayersIcon, LayoutIcon, LetterSpacingIcon, LineBetweenIcon, LineStyleIcon, LinkIcon, ListIcon, LocationIcon, LockIcon, LogoIcon, MediaIcon, MenuIcon, MetaIcon, MoveDownIcon, MoveUpIcon, NoteIcon, NudgeIcon, NumberedListIcon, OpacityIcon, OwnTextIcon, PaddingBottomIcon, PaddingLeftIcon, PaddingRightIcon, PaddingTopIcon, PaddingXIcon, PaddingYIcon, PageIcon, ParagraphSpacingIcon, PasteIcon, PasteStyleIcon, PhoneIcon, PlacementIcon, PlayIcon, PlusMinusIcon, ProductFieldIcon, ProductSizeIcon, QuietIcon, RadiusIcon, RedoIcon, RenameIcon, RevertIcon, RotateIcon, ScrollPointIcon, SearchIcon, SendIcon, SettingsIcon, ShadowIcon, SitemapIcon, SortIcon, SpecTableIcon, SquareIcon, StateIcon, StickyIcon, StrikeIcon, StylesIcon, SubscriptIcon, SuperscriptIcon, TabletIcon, TabsIcon, TagIcon, TemplateIcon, TextColorIcon, TextLinesIcon, TextSizeIcon, TextSmallIcon, ThemeIcon, TitleIcon, TrashIcon, TriggerIcon, TypeIcon, UnderlineIcon, UndoIcon, VAlignIcon, WarningIcon, WeightIcon, WheelIcon, WidthIcon, WordsFromIcon, WrapIcon, iconMeanings };
|
|
504
|
+
export { AccentIcon, AccountIcon, AddIcon, AlignCenterIcon, AlignJustifyIcon, AlignLeftIcon, AlignRightIcon, AlignSeparateIcon, AnchorIcon, AnimationIcon, BackgroundIcon, BellIcon, BlackAndWhiteIcon, BlockBadgeIcon, BlockBannerIcon, BlockBoxIcon, BlockButtonIcon, BlockColumnIcon, BlockCouponIcon, BlockDividerIcon, BlockFooterIcon, BlockHeadingIcon, BlockIncludedListIcon, BlockLayeredImagesIcon, BlockProductIcon, BlockSectionIcon, BlockSocialIcon, BlockSpacerIcon, BlockTextIcon, BlockVideoIcon, BlogPostIcon, BoldIcon, BreadcrumbIcon, ButtonArrowIcon, ButtonIcon, CarIcon, CartIcon, CaseIcon, CaseLowerIcon, CaseNormalIcon, CaseUpperIcon, CategoryIcon, ChatIcon, CheckIcon, ChevronIcon, ClearMarksIcon, ClockIcon, CloseIcon, ColumnGapIcon, ColumnWidthsIcon, ColumnsIcon, ContrastIcon, CopyIcon, CopyStyleIcon, CopyToPageIcon, CornerIcon, DesktopIcon, DiagramIcon, DirectionDownIcon, DirectionIcon, DirectionLeftIcon, DirectionRightIcon, DirectionUpIcon, DollarIcon, DragIcon, DropIcon, DuplicateIcon, EmphasisIcon, ExternalIcon, EyeIcon, EyeOffIcon, FinishIcon, FullWidthIcon, GapIcon, GlobeIcon, GridIcon, GroundIcon, HashIcon, HeadquartersIcon, HeightIcon, HoverIcon, type IconName, type IconProps, ImageIcon, ItalicIcon, LayersIcon, LayoutIcon, LetterSpacingIcon, LineBetweenIcon, LineStyleIcon, LinkIcon, ListIcon, LocationIcon, LockIcon, LogoIcon, MediaIcon, MenuIcon, MetaIcon, MoveDownIcon, MoveUpIcon, NoteIcon, NudgeIcon, NumberedListIcon, OpacityIcon, OwnTextIcon, PaddingBottomIcon, PaddingLeftIcon, PaddingRightIcon, PaddingTopIcon, PaddingXIcon, PaddingYIcon, PageIcon, PanelLeftIcon, PanelRightIcon, ParagraphSpacingIcon, PasteIcon, PasteStyleIcon, PhoneIcon, PlacementIcon, PlayIcon, PlusMinusIcon, ProductFieldIcon, ProductSizeIcon, QuietIcon, RadiusIcon, RedoIcon, RenameIcon, RevertIcon, RotateIcon, ScrollPointIcon, SearchIcon, SendIcon, SettingsIcon, ShadowIcon, SitemapIcon, SortIcon, SpecTableIcon, SquareIcon, StateIcon, StickyIcon, StrikeIcon, StylesIcon, SubscriptIcon, SuperscriptIcon, TabletIcon, TabsIcon, TagIcon, TemplateIcon, TextColorIcon, TextLinesIcon, TextSizeIcon, TextSmallIcon, ThemeIcon, TitleIcon, TrashIcon, TriggerIcon, TypeIcon, UnderlineIcon, UndoIcon, VAlignIcon, WarningIcon, WeightIcon, WheelIcon, WidthIcon, WordsFromIcon, WrapIcon, iconMeanings };
|
package/dist/icons/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{AccentIcon,AccountIcon,AddIcon,AlignCenterIcon,AlignLeftIcon,AlignRightIcon,AlignSeparateIcon,AnchorIcon,AnimationIcon,BackgroundIcon,BellIcon,BlackAndWhiteIcon,BlockBadgeIcon,BlockBannerIcon,BlockBoxIcon,BlockButtonIcon,BlockColumnIcon,BlockCouponIcon,BlockDividerIcon,BlockFooterIcon,BlockHeadingIcon,BlockIncludedListIcon,BlockLayeredImagesIcon,BlockProductIcon,BlockSectionIcon,BlockSocialIcon,BlockSpacerIcon,BlockTextIcon,BlockVideoIcon,BlogPostIcon,BoldIcon,BreadcrumbIcon,ButtonArrowIcon,ButtonIcon,CarIcon,CartIcon,CaseIcon,CaseLowerIcon,CaseNormalIcon,CaseUpperIcon,CategoryIcon,ChatIcon,CheckIcon,ChevronIcon,ClearMarksIcon,ClockIcon,CloseIcon,ColumnGapIcon,ColumnWidthsIcon,ColumnsIcon,ContrastIcon,CopyIcon,CopyStyleIcon,CopyToPageIcon,CornerIcon,DesktopIcon,DiagramIcon,DirectionDownIcon,DirectionIcon,DirectionLeftIcon,DirectionRightIcon,DirectionUpIcon,DollarIcon,DragIcon,DropIcon,DuplicateIcon,EmphasisIcon,ExternalIcon,EyeIcon,EyeOffIcon,FinishIcon,FullWidthIcon,GapIcon,GlobeIcon,GridIcon,GroundIcon,HashIcon,HeadquartersIcon,HeightIcon,HoverIcon,ImageIcon,ItalicIcon,LayersIcon,LayoutIcon,LetterSpacingIcon,LineBetweenIcon,LineStyleIcon,LinkIcon,ListIcon,LocationIcon,LockIcon,LogoIcon,MediaIcon,MenuIcon,MetaIcon,MoveDownIcon,MoveUpIcon,NoteIcon,NudgeIcon,NumberedListIcon,OpacityIcon,OwnTextIcon,PaddingBottomIcon,PaddingLeftIcon,PaddingRightIcon,PaddingTopIcon,PaddingXIcon,PaddingYIcon,PageIcon,ParagraphSpacingIcon,PasteIcon,PasteStyleIcon,PhoneIcon,PlacementIcon,PlayIcon,PlusMinusIcon,ProductFieldIcon,ProductSizeIcon,QuietIcon,RadiusIcon,RedoIcon,RenameIcon,RevertIcon,RotateIcon,ScrollPointIcon,SearchIcon,SendIcon,SettingsIcon,ShadowIcon,SitemapIcon,SortIcon,SpecTableIcon,SquareIcon,StateIcon,StickyIcon,StrikeIcon,StylesIcon,SubscriptIcon,SuperscriptIcon,TabletIcon,TabsIcon,TagIcon,TemplateIcon,TextColorIcon,TextLinesIcon,TextSizeIcon,TextSmallIcon,ThemeIcon,TitleIcon,TrashIcon,TriggerIcon,TypeIcon,UnderlineIcon,UndoIcon,VAlignIcon,WarningIcon,WeightIcon,WheelIcon,WidthIcon,WordsFromIcon,WrapIcon,iconMeanings}from"../chunk-
|
|
1
|
+
export{AccentIcon,AccountIcon,AddIcon,AlignCenterIcon,AlignJustifyIcon,AlignLeftIcon,AlignRightIcon,AlignSeparateIcon,AnchorIcon,AnimationIcon,BackgroundIcon,BellIcon,BlackAndWhiteIcon,BlockBadgeIcon,BlockBannerIcon,BlockBoxIcon,BlockButtonIcon,BlockColumnIcon,BlockCouponIcon,BlockDividerIcon,BlockFooterIcon,BlockHeadingIcon,BlockIncludedListIcon,BlockLayeredImagesIcon,BlockProductIcon,BlockSectionIcon,BlockSocialIcon,BlockSpacerIcon,BlockTextIcon,BlockVideoIcon,BlogPostIcon,BoldIcon,BreadcrumbIcon,ButtonArrowIcon,ButtonIcon,CarIcon,CartIcon,CaseIcon,CaseLowerIcon,CaseNormalIcon,CaseUpperIcon,CategoryIcon,ChatIcon,CheckIcon,ChevronIcon,ClearMarksIcon,ClockIcon,CloseIcon,ColumnGapIcon,ColumnWidthsIcon,ColumnsIcon,ContrastIcon,CopyIcon,CopyStyleIcon,CopyToPageIcon,CornerIcon,DesktopIcon,DiagramIcon,DirectionDownIcon,DirectionIcon,DirectionLeftIcon,DirectionRightIcon,DirectionUpIcon,DollarIcon,DragIcon,DropIcon,DuplicateIcon,EmphasisIcon,ExternalIcon,EyeIcon,EyeOffIcon,FinishIcon,FullWidthIcon,GapIcon,GlobeIcon,GridIcon,GroundIcon,HashIcon,HeadquartersIcon,HeightIcon,HoverIcon,ImageIcon,ItalicIcon,LayersIcon,LayoutIcon,LetterSpacingIcon,LineBetweenIcon,LineStyleIcon,LinkIcon,ListIcon,LocationIcon,LockIcon,LogoIcon,MediaIcon,MenuIcon,MetaIcon,MoveDownIcon,MoveUpIcon,NoteIcon,NudgeIcon,NumberedListIcon,OpacityIcon,OwnTextIcon,PaddingBottomIcon,PaddingLeftIcon,PaddingRightIcon,PaddingTopIcon,PaddingXIcon,PaddingYIcon,PageIcon,PanelLeftIcon,PanelRightIcon,ParagraphSpacingIcon,PasteIcon,PasteStyleIcon,PhoneIcon,PlacementIcon,PlayIcon,PlusMinusIcon,ProductFieldIcon,ProductSizeIcon,QuietIcon,RadiusIcon,RedoIcon,RenameIcon,RevertIcon,RotateIcon,ScrollPointIcon,SearchIcon,SendIcon,SettingsIcon,ShadowIcon,SitemapIcon,SortIcon,SpecTableIcon,SquareIcon,StateIcon,StickyIcon,StrikeIcon,StylesIcon,SubscriptIcon,SuperscriptIcon,TabletIcon,TabsIcon,TagIcon,TemplateIcon,TextColorIcon,TextLinesIcon,TextSizeIcon,TextSmallIcon,ThemeIcon,TitleIcon,TrashIcon,TriggerIcon,TypeIcon,UnderlineIcon,UndoIcon,VAlignIcon,WarningIcon,WeightIcon,WheelIcon,WidthIcon,WordsFromIcon,WrapIcon,iconMeanings}from"../chunk-6EIVTKZZ.js";
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { EaselRail, EaselRailButton, RailTokens, railCssVars, railTokens } from './rail/index.js';
|
|
2
2
|
export { AddIcon, LayersIcon, MediaIcon, PageIcon as PagesIcon, IconProps as RailIconProps, SitemapIcon, StylesIcon } from './icons/index.js';
|
|
3
|
-
export { W as WordFit } from './wordFit-
|
|
4
|
-
export { E as
|
|
3
|
+
export { W as WordFit } from './wordFit-D4S36PvB.js';
|
|
4
|
+
export { E as EaselRailButtonProps, a as EaselRailItem, b as EaselRailOrientation, c as EaselRailProps } from './types-DWS-s9z-.js';
|
|
5
5
|
export { SPACING_SCALE, ShellTokens, shellCssVars, shellTokens } from './shell/index.js';
|
|
6
6
|
import 'react';
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./chunk-OWBO4WKA.js";export{SPACING_SCALE,shellCssVars,shellTokens}from"./chunk-2UX75JDP.js";export{
|
|
1
|
+
import"./chunk-OWBO4WKA.js";export{SPACING_SCALE,shellCssVars,shellTokens}from"./chunk-2UX75JDP.js";export{EaselRail,EaselRailButton,railCssVars,railTokens}from"./chunk-WZ7TGAAT.js";import"./chunk-2OAZYSWJ.js";import"./chunk-BZ5ASXOL.js";export{AddIcon,LayersIcon,MediaIcon,PageIcon as PagesIcon,SitemapIcon,StylesIcon}from"./chunk-6EIVTKZZ.js";
|
package/dist/markup/index.d.ts
CHANGED
|
@@ -50,11 +50,12 @@
|
|
|
50
50
|
* [words]{sup} superscript
|
|
51
51
|
* [words]{sub} subscript
|
|
52
52
|
* [words]{color=name} a theme colour, by NAME ({@link isColorName})
|
|
53
|
+
* [words]{color=#rrggbb} any colour, six hex digits ({@link isColorValue})
|
|
53
54
|
*
|
|
54
55
|
* THE SPANS AND THE NUMBERED LINE (plan step E1, approved by GG 2026-10-06)
|
|
55
56
|
* are the final text box's marks. One shape for all four, so one reading rule:
|
|
56
57
|
* `[`, words, `]`, then EXACTLY one of those blocks. Anything else after the
|
|
57
|
-
* `]` — `{foo}`, `{color=#
|
|
58
|
+
* `]` — `{foo}`, `{color=#f00}`, a merge tag's `{{` — is not a span, and the
|
|
58
59
|
* whole thing stays as typed. Two marks on the same words nest
|
|
59
60
|
* (`[[x]{sup}]{color=accent}`); one block never holds two.
|
|
60
61
|
*
|
|
@@ -132,9 +133,18 @@ type SpanKind = 'underline' | 'sup' | 'sub' | 'color';
|
|
|
132
133
|
* from one to the other invisible. */
|
|
133
134
|
type InlineKind = 'text' | 'bold' | 'italic' | 'strike' | 'code' | 'highlight' | 'accent' | 'quiet';
|
|
134
135
|
/** A theme colour's name as a span saves it: lowercase letters, digits and
|
|
135
|
-
* `-`, starting with a letter (`accent`, `brand-2`).
|
|
136
|
-
*
|
|
136
|
+
* `-`, starting with a letter (`accent`, `brand-2`). A name is the theme's,
|
|
137
|
+
* so changing the theme recolours the words. Never a hex — that is the other
|
|
138
|
+
* kind of colour value ({@link isColorValue}). */
|
|
137
139
|
declare function isColorName(name: string): boolean;
|
|
140
|
+
/** A colour a span may carry: a theme NAME ({@link isColorName}), or "any
|
|
141
|
+
* colour" as EXACTLY six hex digits after a `#` (`#0b5cff`). Either case
|
|
142
|
+
* reads; the writers save lowercase ({@link colorValue}). Nothing else —
|
|
143
|
+
* `#f00`, `rgb()`, a typo — is a colour, so it stays plain text.
|
|
144
|
+
*
|
|
145
|
+
* WIDENS E1 (GG 2026-10-06): the final design draws "Any color", and a
|
|
146
|
+
* feature is never cut to fit. A hex does not follow the theme; a name does. */
|
|
147
|
+
declare function isColorValue(value: string): boolean;
|
|
138
148
|
/**
|
|
139
149
|
* The words a press WRITES when nothing is selected — `**bold text**`, left
|
|
140
150
|
* selected so the next keystroke replaces it. English unless the caller of
|
|
@@ -160,11 +170,12 @@ interface WrapResult {
|
|
|
160
170
|
*/
|
|
161
171
|
declare function applyMark(text: string, start: number, end: number, style: MarkStyle, rules?: readonly InlineRule[], placeholders?: MarkPlaceholders): WrapResult;
|
|
162
172
|
/**
|
|
163
|
-
* Colour `text[start:end]` with
|
|
173
|
+
* Colour `text[start:end]` with `name` — a theme colour name or a 6-digit hex
|
|
174
|
+
* ({@link isColorValue}; a hex is saved lowercase) — writing
|
|
164
175
|
* `[words]{color=name}` and leaving the words selected. On words that are
|
|
165
|
-
* already exactly one colour span it changes the
|
|
166
|
-
* off. A
|
|
167
|
-
* never saved as a block the reader would print as text.
|
|
176
|
+
* already exactly one colour span it changes the colour; `null` takes it
|
|
177
|
+
* off. A value {@link isColorValue} refuses changes nothing — `#f00` or a typo
|
|
178
|
+
* is never saved as a block the reader would print as text.
|
|
168
179
|
*
|
|
169
180
|
* Separate from {@link applyMark} because a colour carries a value, as a link
|
|
170
181
|
* does ({@link writeLink}).
|
|
@@ -298,6 +309,14 @@ interface InlineRule {
|
|
|
298
309
|
* what actually does the work.
|
|
299
310
|
*/
|
|
300
311
|
declare const STANDARD_MARKUP: readonly InlineRule[];
|
|
312
|
+
/**
|
|
313
|
+
* Marks the copy box no longer OFFERS (E5a, 2026-10-06: Lewis dropped
|
|
314
|
+
* Emphasis `==` and Quiet `^^` from the final design). They are still read,
|
|
315
|
+
* drawn and written back byte for byte — saved copy wears them — but no bar
|
|
316
|
+
* button writes them, and `CopyBox` draws none for them even when a host asks.
|
|
317
|
+
* Declared before {@link COPY_FIELD_TOOLS} reads it at module load.
|
|
318
|
+
*/
|
|
319
|
+
declare const RETIRED_MARKS: readonly MarkStyle[];
|
|
301
320
|
/**
|
|
302
321
|
* The buttons a COPY FIELD offers — a storefront section's copy box and a
|
|
303
322
|
* campaign block's copy box show exactly these, so a merchant meets one toolbar
|
|
@@ -458,8 +477,8 @@ interface MarkSpan {
|
|
|
458
477
|
}
|
|
459
478
|
/**
|
|
460
479
|
* A NEW run, as the toolbar writes it: `**` for bold, `_` for italic, and so on
|
|
461
|
-
* ({@link applyMark}'s own fences), a link to `value`, or a colour span
|
|
462
|
-
* `value` ({@link
|
|
480
|
+
* ({@link applyMark}'s own fences), a link to `value`, or a colour span of
|
|
481
|
+
* `value` — a theme name or a 6-digit hex, saved lowercase ({@link isColorValue}). Null for a style that writes no run (a line
|
|
463
482
|
* prefix, clear) and for a link or colour with no usable value. A paste filter
|
|
464
483
|
* or an editor making a run asks here, so no delimiter is spelled outside this
|
|
465
484
|
* module (E8).
|
|
@@ -524,5 +543,70 @@ declare function sameMarks(a: readonly MarkedLine[], b: readonly MarkedLine[]):
|
|
|
524
543
|
* literal underscore. And if even that would not read back, nothing changes.
|
|
525
544
|
*/
|
|
526
545
|
declare function clearMarks(text: string, start: number, end: number, rules?: readonly InlineRule[]): WrapResult;
|
|
546
|
+
/**
|
|
547
|
+
* Press `style` on the WORDS in `text[start:end]`, whichever runs they sit in —
|
|
548
|
+
* what a view that hides the delimiters needs, where `applyMark` (which wraps
|
|
549
|
+
* exactly the characters selected) would cross or strand a delimiter.
|
|
550
|
+
*
|
|
551
|
+
* - Every selected word already wears the mark: it comes off them. Part of a
|
|
552
|
+
* run is split off; the rest keeps the mark.
|
|
553
|
+
* - Otherwise the mark goes on, as ONE run over the words and any run of the
|
|
554
|
+
* same mark they touch (`**half** off` → `**half off**`).
|
|
555
|
+
* - Nothing is written that would not read back: a third level of nesting,
|
|
556
|
+
* or `_` inside a word, leaves the text as it was.
|
|
557
|
+
* - With nothing selected it is {@link applyMark}: a selected placeholder.
|
|
558
|
+
*
|
|
559
|
+
* Offsets are the saved string's, before and after.
|
|
560
|
+
*/
|
|
561
|
+
declare function toggleMark(text: string, start: number, end: number, style: MarkStyle, rules?: readonly InlineRule[]): WrapResult;
|
|
562
|
+
/**
|
|
563
|
+
* The marks every word in `text[start:end]` wears — `bold`, `link`, a legacy
|
|
564
|
+
* `accent` … — or, with nothing selected, the marks of the word just before the
|
|
565
|
+
* caret on its line: what typing there would continue. What a toolbar draws
|
|
566
|
+
* as pressed in a view without delimiters.
|
|
567
|
+
*/
|
|
568
|
+
declare function marksIn(text: string, start: number, end: number, rules?: readonly InlineRule[]): Set<string>;
|
|
569
|
+
/**
|
|
570
|
+
* Link the WORDS in `text[start:end]` to `href`, nesting with any run they
|
|
571
|
+
* sit in rather than crossing it: words inside a bold run become a link inside
|
|
572
|
+
* it (`**Book [a fitting](/book)**`), a whole bold run goes inside the link.
|
|
573
|
+
*
|
|
574
|
+
* With nothing selected, inside a link it re-points that link; anywhere else
|
|
575
|
+
* it writes the address as its own words ({@link writeLink}). The caret lands
|
|
576
|
+
* after the link. ⚠️ The address is the caller's to check ({@link isSafeLinkHref}).
|
|
577
|
+
*/
|
|
578
|
+
declare function linkOver(text: string, start: number, end: number, href: string, rules?: readonly InlineRule[]): WrapResult;
|
|
579
|
+
/** Take off the link the caret or selection touches, keeping its words —
|
|
580
|
+
* selected, so a second press of the link button puts it straight back. */
|
|
581
|
+
declare function unlinkAt(text: string, start: number, end: number, rules?: readonly InlineRule[]): WrapResult;
|
|
582
|
+
/**
|
|
583
|
+
* Colour the WORDS in `text[start:end]` with `name` — a theme colour name or
|
|
584
|
+
* a 6-digit hex, saved lowercase (`[words]{color=name}`), nesting with any run they sit in rather than
|
|
585
|
+
* crossing it — the colour window's write, as {@link linkOver} is the link
|
|
586
|
+
* window's. A colour the words already wear is replaced; `null` takes the
|
|
587
|
+
* colour off them, splitting a run that only partly covers them.
|
|
588
|
+
*
|
|
589
|
+
* A value {@link isColorValue} refuses (`#f00`, a word with a space) changes
|
|
590
|
+
* nothing: a block the reader would print as text is never written. With
|
|
591
|
+
* nothing selected nothing changes either — the box keeps a pending colour
|
|
592
|
+
* for the words typed next instead.
|
|
593
|
+
*/
|
|
594
|
+
declare function colorOver(text: string, start: number, end: number, name: string | null, rules?: readonly InlineRule[]): WrapResult;
|
|
595
|
+
/** The ONE colour every word in `text[start:end]` wears — or, with nothing
|
|
596
|
+
* selected, the word before the caret on its line — or null. What the colour
|
|
597
|
+
* window draws as chosen, and the colour under the A. */
|
|
598
|
+
declare function colorIn(text: string, start: number, end: number, rules?: readonly InlineRule[]): string | null;
|
|
599
|
+
/**
|
|
600
|
+
* Make every line `text[start:end]` touches (the caret's line, with nothing
|
|
601
|
+
* selected) a bulleted list, a numbered list, or — `null` — no list. The
|
|
602
|
+
* words and their marks keep their bytes; only the line prefixes change. A
|
|
603
|
+
* numbered list counts on from a numbered line just above it, else from 1.
|
|
604
|
+
* An empty line becomes an empty list line (`- `), which the rich view draws
|
|
605
|
+
* as a bullet with nothing after it yet. The selection keeps its words.
|
|
606
|
+
*/
|
|
607
|
+
declare function setList(text: string, start: number, end: number, kind: 'bullet' | 'number' | null, rules?: readonly InlineRule[]): WrapResult;
|
|
608
|
+
/** `bullet` or `number` when every line `text[start:end]` touches is that
|
|
609
|
+
* kind of list line, else null — what the list buttons draw as pressed. */
|
|
610
|
+
declare function listIn(text: string, start: number, end: number, rules?: readonly InlineRule[]): 'bullet' | 'number' | null;
|
|
527
611
|
|
|
528
|
-
export { CAMPAIGN_MARKUP, COPY_FIELD_TOOLS, type InlineKind, type InlineRule, type InlineToken, type LinkSpan, MARKUP_TOOLS, MARK_NAMES, MARK_PLACEHOLDERS, type MarkPlaceholders, type MarkSpan, type MarkStyle, type MarkedChar, type MarkedLine, type MarkupLine, type MarkupLink, type MarkupNode, type MarkupRun, type MarkupText, type MarkupTool, STANDARD_MARKUP, STOREFRONT_MARKUP, type SpanKind, type WrapResult, applyColor, applyMark, clearMarks, findLink, isColorName, isSafeLinkHref, markedAt, markedLines, markupTools, parseMarkup, removeLink, sameMarks, serializeMarkup, spanFor, stripInline, tokenizeInline, writeLink, writeMarkedLines };
|
|
612
|
+
export { CAMPAIGN_MARKUP, COPY_FIELD_TOOLS, type InlineKind, type InlineRule, type InlineToken, type LinkSpan, MARKUP_TOOLS, MARK_NAMES, MARK_PLACEHOLDERS, type MarkPlaceholders, type MarkSpan, type MarkStyle, type MarkedChar, type MarkedLine, type MarkupLine, type MarkupLink, type MarkupNode, type MarkupRun, type MarkupText, type MarkupTool, RETIRED_MARKS, STANDARD_MARKUP, STOREFRONT_MARKUP, type SpanKind, type WrapResult, applyColor, applyMark, clearMarks, colorIn, colorOver, findLink, isColorName, isColorValue, isSafeLinkHref, linkOver, listIn, markedAt, markedLines, marksIn, markupTools, parseMarkup, removeLink, sameMarks, serializeMarkup, setList, spanFor, stripInline, toggleMark, tokenizeInline, unlinkAt, writeLink, writeMarkedLines };
|
package/dist/markup/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{CAMPAIGN_MARKUP,COPY_FIELD_TOOLS,MARKUP_TOOLS,MARK_NAMES,MARK_PLACEHOLDERS,STANDARD_MARKUP,STOREFRONT_MARKUP,applyColor,applyMark,clearMarks,findLink,isColorName,isSafeLinkHref,markedAt,markedLines,markupTools,parseMarkup,removeLink,sameMarks,serializeMarkup,spanFor,stripInline,tokenizeInline,writeLink,writeMarkedLines}from"../chunk-
|
|
1
|
+
export{CAMPAIGN_MARKUP,COPY_FIELD_TOOLS,MARKUP_TOOLS,MARK_NAMES,MARK_PLACEHOLDERS,RETIRED_MARKS,STANDARD_MARKUP,STOREFRONT_MARKUP,applyColor,applyMark,clearMarks,colorIn,colorOver,findLink,isColorName,isColorValue,isSafeLinkHref,linkOver,listIn,markedAt,markedLines,marksIn,markupTools,parseMarkup,removeLink,sameMarks,serializeMarkup,setList,spanFor,stripInline,toggleMark,tokenizeInline,unlinkAt,writeLink,writeMarkedLines}from"../chunk-HDVD27VB.js";
|