@graphysdk/react-renderer 1.9.0-beta.1789573335651 → 1.9.0-beta.1789582064893

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.
@@ -553,7 +553,7 @@ declare type DotNotation<T> = T extends object ? {
553
553
  *
554
554
  * @example
555
555
  * ```tsx
556
- * <GraphProvider input={input} data={data}>
556
+ * <GraphProvider spec={input} data={data}>
557
557
  * <EditableGraphRenderer mode={isEditing ? 'editable' : 'readonly'} />
558
558
  * </GraphProvider>
559
559
  * ```
@@ -741,12 +741,12 @@ declare interface GraphCommands {
741
741
  /** Applies a command to the provider's live spec. */
742
742
  dispatch: (command: Command, options?: DispatchOptions) => void;
743
743
  /**
744
- * Closes a run of `{ transient: true }` dispatches and fires `onChange` once for it. Call it when
744
+ * Closes a run of `{ transient: true }` dispatches and fires `onSpecChange` once for it. Call it when
745
745
  * the gesture ends — pointer up, blur. Forgetting only delays the notification rather than
746
746
  * corrupting undo: the run covers one {@link EditTarget}, and the next committed dispatch, undo,
747
747
  * redo or external change closes it.
748
748
  */
749
- seal: () => void;
749
+ commit: () => void;
750
750
  }
751
751
 
752
752
  /**
@@ -838,7 +838,7 @@ declare type GraphSizing = {
838
838
  };
839
839
 
840
840
  /**
841
- * Region overrides for `GraphRenderer`. A slot replaces how one region paints; the viz-engine `Spec`
841
+ * Region overrides for `GraphRenderer`. A slot replaces how one region paints; the viz-engine `ResolvedSpec`
842
842
  * still owns whether a region exists and what data it receives, and an override gets the same
843
843
  * render-ready props as its default.
844
844
  *
@@ -1330,7 +1330,7 @@ declare type TextDirection = 'ltr' | 'rtl';
1330
1330
  * A line of text.
1331
1331
  *
1332
1332
  * Typing fires `onChange` per keystroke and blur fires `onCommit`, so a burst of typing dispatches
1333
- * transiently and seals into one undo entry when the field is left.
1333
+ * transiently and commits into one undo entry when the field is left.
1334
1334
  */
1335
1335
  export declare const TextField: ({ value, onChange, onCommit, placeholder, isDisabled, hasError, ariaLabel, ariaLabelledBy, id, }: TextFieldControlProps) => JSX.Element;
1336
1336
 
@@ -1371,7 +1371,7 @@ declare interface ToggledSectionProps extends Omit<SectionProps, 'layout' | 'acc
1371
1371
  * behaviour of a radio group while announcing itself as something else.
1372
1372
  *
1373
1373
  * That makes this the picture grid in different clothes: same primitive, same contract, same
1374
- * transient run sealed on key up. Only the layout differs — a row of words here, a grid of pictures
1374
+ * transient run committed on key up. Only the layout differs — a row of words here, a grid of pictures
1375
1375
  * there — which is the whole of why they are two controls.
1376
1376
  */
1377
1377
  export declare const ToggleGroup: ({ options, value, onChange, onCommit, itemLayout, isDisabled, ariaLabel, ariaLabelledBy, id, }: ToggleGroupControlProps) => JSX.Element;
package/dist/editable.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { A as go, B as $, Bt as Jn, D as Qn, Dt as vo, E as fo, Ft as bo, G as Nt, H as nn, It as yo, J as rt, K as er, Kt as _, L as So, Lt as Co, O as xo, Ot as tr, P as wo, Pt as nr, Q as To, R as Ao, Rt as ko, S as rr, St as j, T as Lo, U as G, Ut as Po, V as Io, W as Rt, Wt as H, X as ar, Y as Eo, Z as Mo, _ as Oo, _t as No, b as ye, d as Ro, dt as Do, et as zo, f as _o, g as Fo, gt as Ho, h as at, ht as Bo, i as Vo, it as te, j as A, k as Go, l as $o, lt as Uo, m as or, n as le, nt as rn, o as Wo, ot, p as ir, pt as Se, q as Dt, r as W, rt as Ko, t as qo, tt as Zo, u as Xo, ut as I, v as lr, vt as se, w as ge, x as zt, xt as De, y as sr, z as X } from "./history-chords-FqjF3hMF.js";
1
+ import { A as go, B as $, Bt as Jn, D as Qn, Dt as vo, E as fo, Ft as bo, G as Nt, H as nn, It as yo, J as rt, K as er, Kt as _, L as So, Lt as Co, O as xo, Ot as tr, P as wo, Pt as nr, Q as To, R as Ao, Rt as ko, S as rr, St as j, T as Lo, U as G, Ut as Po, V as Io, W as Rt, Wt as H, X as ar, Y as Eo, Z as Mo, _ as Oo, _t as No, b as ye, d as Ro, dt as Do, et as zo, f as _o, g as Fo, gt as Ho, h as at, ht as Bo, i as Vo, it as te, j as A, k as Go, l as $o, lt as Uo, m as or, n as le, nt as rn, o as Wo, ot, p as ir, pt as Se, q as Dt, r as W, rt as Ko, t as qo, tt as Zo, u as Xo, ut as I, v as lr, vt as se, w as ge, x as zt, xt as De, y as sr, z as X } from "./history-chords-S1G_f-FU.js";
2
2
  import { n as ce, t as cr } from "./theme.contract.css-DaZ5UPN0.js";
3
3
  import { ARROW_DEFAULTS as jo, ARROW_STICKER_DECLARATIONS as Yo, ARROW_STROKE_WIDTHS as ft, AddAnnotationCommand as pe, AddHighlightCommand as Jo, BORDER_RADIUS_TOKENS as an, COMBO_TYPES as on, CONSTANT_VARIABLES as Qo, DEFAULT_BAR_BORDER_RADIUS as ei, DEFAULT_POINT_SIZE as ti, DEFAULT_STROKE_WIDTH as ni, DIFFERENCE_ARROW_DEFAULTS as dr, DIFFERENCE_ARROW_SIZE_DECLARATIONS as ln, InternalError as ri, MAX_BAR_WIDTH as ai, MIN_BAR_WIDTH as oi, MoveAnnotationCommand as ii, RESTING_HOVER_STATE as _t, RemoveAnnotationCommand as Pe, RemoveHighlightCommand as li, SHAPE_DEFAULTS as si, SetAxisLabelCommand as ci, SetAxisPositionCommand as di, SetAxisTickModeCommand as ui, SetAxisTicksVisibilityCommand as hi, SetAxisVisibilityCommand as pi, SetBarBorderRadiusCommand as mi, SetBarWidthCommand as gi, SetChartTypeCommand as ur, SetContentCaptionCommand as hr, SetContentSourceCommand as vi, SetContentSubtitleCommand as pr, SetContentTitleCommand as mr, SetDataLabelsFormatCommand as fi, SetDifferenceArrowStyleCommand as bi, SetGridLineStyleCommand as yi, SetGridLineWidthCommand as Si, SetGridVisibilityCommand as Ci, SetHeadlineCompareWithCommand as xi, SetHeadlinePositionCommand as wi, SetHeadlineShowCommand as sn, SetHeadlineSizeCommand as Ti, SetHighlightDimStyleCommand as Ai, SetLayerYScaleTypeCommand as ki, SetLegendAlignCommand as Li, SetLegendDisplayCommand as Pi, SetLegendPositionCommand as Ii, SetLineInterpolationCommand as Ei, SetLineMissingValuesCommand as Mi, SetLineWidthCommand as cn, SetMappingCommand as Oi, SetNumberFormatAbbreviationCommand as Ni, SetNumberFormatDecimalsCommand as dn, SetPointSizeCommand as Ri, SetPolarInnerRadiusCommand as Di, SetPolarStartAngleCommand as zi, SetRuleLabelCommand as _i, SetRuleValueCommand as Fi, SetScaleDomainCommand as Ge, SetScaleReverseCommand as Hi, SetScaleTransformCommand as Bi, SetScaleZeroCommand as un, SetStatLineCommand as Vi, SetStyleRuleCommand as Ie, TEXT_ANNOTATION_DEFAULTS as Gi, TEXT_ANNOTATION_FADE_ALPHA as $i, ToggleCategoryLabelsCommand as Ui, ToggleContentVisibilityCommand as it, ToggleDataLabelsCommand as Wi, ToggleGoalLineCommand as Ki, ToggleLineFillCommand as qi, ToggleLinePointsVisibilityCommand as Zi, ToggleStackTotalsCommand as Xi, UpdateAnnotationCommand as ae, alignUnitFractions as ji, areAnchorsEqual as gr, areEndpointsComparable as Yi, buildEditMenuTriggerRegion as Ji, buildLayerStyleAddress as Qi, buildObservationPredicate as vr, buildObservationsTarget as fr, canAnchorDirectLabels as el, canBecomeCombo as tl, canBecomeHeatmap as nl, canPlaceDataLabels as rl, clampAnnotationTranslation as al, computeArrow as br, createObservationAnchorBuilder as ol, createObservationAnchorParser as il, createStyleResolver as lt, createValueFormatter as ll, extractConstantValue as sl, extractVariableName as cl, filterLayersByGeoms as Ct, findAnnotation as dl, findAverageLineLayer as ul, findGoalLineLayer as hl, findHighlightsAtObservation as pl, findKindStyleDeclarations as ml, findLayerByGeom as yr, findObservationAttachment as gl, findStyleRule as be, findTrendLineLayer as vl, formatDifferenceLabel as fl, hasMultipleGroups as bl, inferDefaultDifferenceArrowEndpoints as yl, inferDifferenceArrowEndpoints as Sl, isComboChartType as fe, isCompanionLayer as Sr, isObservationAttachmentKind as Cl, isPointWithinEditMenuTrigger as Ft, isSafeUrl as xl, projectAnchorToPanel as Ze, readBroadestObservationsScope as wl, readChartType as Cr, readComboLineLayerId as Tl, readHighlightDimStyle as Al, readMappableAesthetics as kl, readMappedVariable as Ll, readObservationIndex as xr, resolveBarBandFraction as Pl, resolveComparisonBasis as Il, resolveGridLineStyle as El, resolveObservationPoint as wr, resolveShapeAnnotationStyle as Ml, stepDifferenceArrowEndpoint as Ol, toPanelCursor as st } from "@graphysdk/viz-engine";
4
4
  import { createContext as ze, useCallback as ne, useContext as Ee, useEffect as D, useId as Le, useMemo as z, useRef as ee, useState as Q } from "react";
@@ -4464,12 +4464,12 @@ var vd = (e) => {
4464
4464
  Separator: q.Separator
4465
4465
  }, uu = { kind: "chrome-popup" }, ut = () => {
4466
4466
  const { commands: e } = _(), t = $(), [r, a] = Q(null);
4467
- D(() => () => e.seal(), [e]), D(() => {
4467
+ D(() => () => e.commit(), [e]), D(() => {
4468
4468
  const { claimInteraction: i, releaseInteraction: l } = t.getState();
4469
4469
  return r === null ? l("chrome-popup") : i(uu), () => l("chrome-popup");
4470
4470
  }, [t, r]);
4471
4471
  const o = () => {
4472
- a(null), e.seal();
4472
+ a(null), e.commit();
4473
4473
  };
4474
4474
  return {
4475
4475
  bind: (i) => ({
@@ -7805,7 +7805,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
7805
7805
  children: /* @__PURE__ */ n(u, {
7806
7806
  value: g.label ?? "",
7807
7807
  onChange: ro,
7808
- onCommit: o.commands.seal
7808
+ onCommit: o.commands.commit
7809
7809
  })
7810
7810
  }), /* @__PURE__ */ n(w, {
7811
7811
  label: l("editor.axesPanel.controls.ticks"),
@@ -7859,7 +7859,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
7859
7859
  children: /* @__PURE__ */ n(s, {
7860
7860
  value: f.domainMin ?? null,
7861
7861
  onChange: so,
7862
- onCommit: o.commands.seal
7862
+ onCommit: o.commands.commit
7863
7863
  })
7864
7864
  })] }),
7865
7865
  /* @__PURE__ */ n(w, {
@@ -7875,7 +7875,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
7875
7875
  children: /* @__PURE__ */ n(s, {
7876
7876
  value: y,
7877
7877
  onChange: co,
7878
- onCommit: o.commands.seal
7878
+ onCommit: o.commands.commit
7879
7879
  })
7880
7880
  })
7881
7881
  ] })
@@ -7891,7 +7891,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
7891
7891
  children: /* @__PURE__ */ n(o, {
7892
7892
  value: typeof e == "string" ? e : "",
7893
7893
  onChange: l,
7894
- onCommit: r.commands.seal,
7894
+ onCommit: r.commands.commit,
7895
7895
  isDisabled: i
7896
7896
  })
7897
7897
  });
@@ -7951,7 +7951,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
7951
7951
  c !== "" && !Gn.test(c) && o({
7952
7952
  ...e,
7953
7953
  url: `https://${c}`
7954
- }), t.commands.seal();
7954
+ }), t.commands.commit();
7955
7955
  }, l = (c) => o({
7956
7956
  ...e,
7957
7957
  url: c
@@ -7972,7 +7972,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
7972
7972
  children: /* @__PURE__ */ n(a, {
7973
7973
  value: e.label ?? "",
7974
7974
  onChange: s,
7975
- onCommit: t.commands.seal
7975
+ onCommit: t.commands.commit
7976
7976
  })
7977
7977
  })] });
7978
7978
  }, a2 = ({ title: e, layout: t = "collapsible", preview: r }) => {
@@ -8118,7 +8118,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
8118
8118
  step: 1,
8119
8119
  formatValue: mt,
8120
8120
  onChange: h,
8121
- onCommit: a.commands.seal
8121
+ onCommit: a.commands.commit
8122
8122
  })
8123
8123
  }), /* @__PURE__ */ n(w, {
8124
8124
  label: i("editor.colorPanel.appearanceSection.highlightStyle"),
@@ -8170,7 +8170,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
8170
8170
  step: h2,
8171
8171
  formatValue: Za,
8172
8172
  onChange: d,
8173
- onCommit: a.commands.seal
8173
+ onCommit: a.commands.commit
8174
8174
  })
8175
8175
  }), /* @__PURE__ */ n(w, {
8176
8176
  label: i("editor.graphPanel.barSection.rounding"),
@@ -8423,7 +8423,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
8423
8423
  value: s?.params.label ?? "",
8424
8424
  placeholder: o("editor.annotationsPanel.goalSection.labelPlaceholder"),
8425
8425
  onChange: g,
8426
- onCommit: r.commands.seal,
8426
+ onCommit: r.commands.commit,
8427
8427
  ariaLabel: o("editor.annotationsPanel.goalSection.labelAriaLabel")
8428
8428
  })
8429
8429
  }), /* @__PURE__ */ n(w, {
@@ -8432,7 +8432,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
8432
8432
  value: d,
8433
8433
  placeholder: o("editor.powerUpPanel.valueInput.numberPlaceholder"),
8434
8434
  onChange: m,
8435
- onCommit: r.commands.seal,
8435
+ onCommit: r.commands.commit,
8436
8436
  ariaLabel: o("editor.annotationsPanel.goalSection.valueAriaLabel")
8437
8437
  })
8438
8438
  })] })
@@ -9363,7 +9363,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
9363
9363
  step: 0.5,
9364
9364
  formatValue: mt,
9365
9365
  onChange: P,
9366
- onCommit: a.commands.seal
9366
+ onCommit: a.commands.commit
9367
9367
  })
9368
9368
  })] })] })
9369
9369
  });
@@ -9554,7 +9554,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
9554
9554
  step: sm,
9555
9555
  formatValue: mt,
9556
9556
  onChange: i,
9557
- onCommit: t.commands.seal
9557
+ onCommit: t.commands.commit
9558
9558
  });
9559
9559
  }, cm = 1, dm = 10, um = 0.1, hm = [
9560
9560
  "gap",
@@ -9649,7 +9649,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
9649
9649
  step: um,
9650
9650
  formatValue: mt,
9651
9651
  onChange: E,
9652
- onCommit: a.commands.seal
9652
+ onCommit: a.commands.commit
9653
9653
  })
9654
9654
  }),
9655
9655
  !m && v.length > 1 && /* @__PURE__ */ n(w, {
@@ -9804,7 +9804,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
9804
9804
  min: Cm,
9805
9805
  max: xm,
9806
9806
  onChange: S,
9807
- onCommit: a.commands.seal
9807
+ onCommit: a.commands.commit
9808
9808
  })
9809
9809
  })
9810
9810
  ] })
@@ -9846,7 +9846,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
9846
9846
  step: Pm,
9847
9847
  formatValue: Za,
9848
9848
  onChange: u,
9849
- onCommit: a.commands.seal
9849
+ onCommit: a.commands.commit
9850
9850
  })
9851
9851
  }), /* @__PURE__ */ n(w, {
9852
9852
  label: i("editor.graphPanel.polarSection.startAngle"),
@@ -9857,7 +9857,7 @@ var Kp = "_40zvwv8", K = ({ title: e, layout: t = "fixed", preview: r, accessory
9857
9857
  step: Im,
9858
9858
  formatValue: c2,
9859
9859
  onChange: d,
9860
- onCommit: a.commands.seal
9860
+ onCommit: a.commands.commit
9861
9861
  })
9862
9862
  })] })
9863
9863
  });
@@ -23,7 +23,7 @@ import './history-chords.css';var Pr = Object.defineProperty, ls = (e, t) => {
23
23
  });
24
24
  return t || Pr(r, Symbol.toStringTag, { value: "Module" }), r;
25
25
  };
26
- typeof window < "u" && (window.__GRAPHY_SDK__ ??= {}, window.__GRAPHY_SDK__.reactRenderer = "1.9.0-beta.1789573335651");
26
+ typeof window < "u" && (window.__GRAPHY_SDK__ ??= {}, window.__GRAPHY_SDK__.reactRenderer = "1.9.0-beta.1789582064893");
27
27
  function ds(e) {
28
28
  for (const t of e) (t.severity === "error" ? console.error : console.warn)(`[graphy] ${t.code}: ${t.message}`, t);
29
29
  }