@graphysdk/react-renderer 1.9.0-beta.1788892166977 → 1.9.0-beta.1788895125792

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/dist/editable.mjs CHANGED
@@ -1,44 +1,44 @@
1
- import { $ as oo, A as io, At as lo, B as qn, C as Zn, D as x, Dt as so, E as co, Et as Xn, F as X, Ft as G, G as uo, H as et, I as U, J as ho, K as jn, L as V, N as po, Nt as _, Ot as mo, P as go, Q as Qt, R as Et, S as vo, T as fo, U as bo, V as Mt, W as Yn, X as Co, Z as yo, _ as Jn, at as So, b as Nt, c as xo, d as wo, dt as To, et as ee, f as Qn, ft as le, g as Ao, gt as J, h as ko, ht as Ot, i as Lo, kt as Po, l as Io, lt as Eo, m as tt, n as se, nt, o as Mo, ot as k, p as er, q as No, r as $, st as Oo, t as Ro, u as Do, ut as zo, v as tr, w as _o, x as Fo, y as fe, z as Rt } from "./history-chords--ylRa7hp.js";
1
+ import { $ as oo, A as io, At as lo, B as qn, C as Zn, D as x, Dt as so, E as co, Et as Xn, F as X, Ft as G, G as uo, H as tt, I as U, J as ho, K as jn, L as V, N as po, Nt as _, Ot as mo, P as go, Q as Qt, R as Et, S as vo, T as fo, U as bo, V as Mt, W as Yn, X as Co, Z as yo, _ as Jn, at as So, b as Nt, c as xo, d as wo, dt as To, et as ee, f as Qn, ft as le, g as Ao, gt as J, h as ko, ht as Ot, i as Lo, kt as Po, l as Io, lt as Eo, m as nt, n as se, nt as rt, o as Mo, ot as k, p as er, q as No, r as $, st as Oo, t as Ro, u as Do, ut as zo, v as tr, w as _o, x as Fo, y as be, z as Rt } from "./history-chords-DmCZaCLl.js";
2
2
  import { d as ce, n as nr, u as rr } from "./dev.utils-DT-z_GBs.js";
3
- import { ARROW_DEFAULTS as Ho, ARROW_STICKER_DECLARATIONS as Bo, ARROW_STROKE_WIDTHS as pt, AddAnnotationCommand as pe, AddHighlightCommand as Vo, BORDER_RADIUS_TOKENS as en, COMBO_TYPES as tn, CONSTANT_VARIABLES as Go, DEFAULT_BAR_BORDER_RADIUS as $o, DEFAULT_POINT_SIZE as Uo, DEFAULT_STROKE_WIDTH as Wo, DIFFERENCE_ARROW_DEFAULTS as ar, DIFFERENCE_ARROW_SIZE_DECLARATIONS as nn, MAX_BAR_WIDTH as Ko, MIN_BAR_WIDTH as qo, MoveAnnotationCommand as Zo, RESTING_HOVER_STATE as or, RemoveAnnotationCommand as ke, RemoveHighlightCommand as Xo, SHAPE_DEFAULTS as jo, SetAppearanceTextScaleCommand as Yo, SetAxisLabelCommand as Jo, SetAxisPositionCommand as Qo, SetAxisTickModeCommand as ei, SetAxisTicksVisibilityCommand as ti, SetAxisVisibilityCommand as ni, SetBarBorderRadiusCommand as ri, SetBarWidthCommand as ai, SetChartTypeCommand as ir, SetContentCaptionCommand as lr, SetContentSourceCommand as oi, SetContentSubtitleCommand as sr, SetContentTitleCommand as cr, SetDataLabelsFormatCommand as ii, SetDifferenceArrowStyleCommand as li, SetGridLineStyleCommand as si, SetGridLineWidthCommand as ci, SetGridVisibilityCommand as di, SetHeadlineCompareWithCommand as ui, SetHeadlinePositionCommand as hi, SetHeadlineShowCommand as rn, SetHeadlineSizeCommand as pi, SetHighlightDimStyleCommand as mi, SetLayerYScaleTypeCommand as gi, SetLegendAlignCommand as vi, SetLegendDisplayCommand as fi, SetLegendPositionCommand as bi, SetLineInterpolationCommand as Ci, SetLineMissingValuesCommand as yi, SetLineWidthCommand as an, SetMappingCommand as Si, SetNumberFormatAbbreviationCommand as xi, SetNumberFormatDecimalsCommand as on, SetPointSizeCommand as wi, SetPolarInnerRadiusCommand as Ti, SetPolarStartAngleCommand as Ai, SetRuleLabelCommand as ki, SetRuleValueCommand as Li, SetScaleDomainCommand as He, SetScaleReverseCommand as Pi, SetScaleTransformCommand as Ii, SetScaleZeroCommand as ln, SetStatLineCommand as Ei, SetStyleRuleCommand as Ne, TEXT_ANNOTATION_DEFAULTS as Mi, TEXT_ANNOTATION_FADE_ALPHA as Ni, ToggleCategoryLabelsCommand as Oi, ToggleContentVisibilityCommand as rt, ToggleDataLabelsCommand as Ri, ToggleGoalLineCommand as Di, ToggleLineFillCommand as zi, ToggleLinePointsVisibilityCommand as _i, ToggleStackTotalsCommand as Fi, UpdateAnnotationCommand as re, alignUnitFractions as Hi, areAnchorsEqual as dr, areEndpointsComparable as Bi, buildEditMenuTriggerRegion as Vi, buildLayerStyleAddress as Gi, buildObservationPredicate as $i, canAnchorDirectLabels as Ui, canBecomeCombo as Wi, canBecomeHeatmap as Ki, canPlaceDataLabels as qi, clampAnnotationTranslation as Zi, computeArrow as ur, createObservationAnchorBuilder as Xi, createObservationAnchorParser as ji, createStyleResolver as at, createValueFormatter as Yi, extractConstantValue as Ji, extractVariableName as Qi, filterLayersByGeoms as bt, findAnnotation as el, findAverageLineLayer as tl, findGoalLineLayer as nl, findHighlightsAtObservation as rl, findKindStyleDeclarations as al, findLayerByGeom as hr, findObservationAttachment as ol, findStyleRule as Te, findTrendLineLayer as il, formatDifferenceLabel as ll, hasMultipleGroups as sl, inferDefaultDifferenceArrowEndpoints as cl, inferDifferenceArrowEndpoints as dl, isComboChartType as ve, isCompanionLayer as pr, isObservationAttachmentKind as ul, isPointWithinEditMenuTrigger as mr, isSafeUrl as hl, projectAnchorToPanel as Ue, readChartType as gr, readComboLineLayerId as pl, readHighlightDimStyle as ml, readMappableAesthetics as gl, readMappedVariable as vl, readObservationIndex as fl, resolveBarBandFraction as bl, resolveComparisonBasis as Cl, resolveGridLineStyle as yl, resolveObservationPoint as vr, resolveShapeAnnotationStyle as Sl, stepDifferenceArrowEndpoint as xl, toPanelCursor as Dt } from "@graphysdk/viz-engine";
4
- import { createContext as Oe, useCallback as ie, useContext as Le, useEffect as O, useId as Ae, useMemo as M, useRef as te, useState as Q } from "react";
3
+ import { ARROW_DEFAULTS as Ho, ARROW_STICKER_DECLARATIONS as Bo, ARROW_STROKE_WIDTHS as pt, AddAnnotationCommand as pe, AddHighlightCommand as Vo, BORDER_RADIUS_TOKENS as en, COMBO_TYPES as tn, CONSTANT_VARIABLES as Go, DEFAULT_BAR_BORDER_RADIUS as $o, DEFAULT_POINT_SIZE as Uo, DEFAULT_STROKE_WIDTH as Wo, DIFFERENCE_ARROW_DEFAULTS as ar, DIFFERENCE_ARROW_SIZE_DECLARATIONS as nn, MAX_BAR_WIDTH as Ko, MIN_BAR_WIDTH as qo, MoveAnnotationCommand as Zo, RESTING_HOVER_STATE as or, RemoveAnnotationCommand as ke, RemoveHighlightCommand as Xo, SHAPE_DEFAULTS as jo, SetAxisLabelCommand as Yo, SetAxisPositionCommand as Jo, SetAxisTickModeCommand as Qo, SetAxisTicksVisibilityCommand as ei, SetAxisVisibilityCommand as ti, SetBarBorderRadiusCommand as ni, SetBarWidthCommand as ri, SetChartTypeCommand as ir, SetContentCaptionCommand as lr, SetContentSourceCommand as ai, SetContentSubtitleCommand as sr, SetContentTitleCommand as cr, SetDataLabelsFormatCommand as oi, SetDifferenceArrowStyleCommand as ii, SetGridLineStyleCommand as li, SetGridLineWidthCommand as si, SetGridVisibilityCommand as ci, SetHeadlineCompareWithCommand as di, SetHeadlinePositionCommand as ui, SetHeadlineShowCommand as rn, SetHeadlineSizeCommand as hi, SetHighlightDimStyleCommand as pi, SetLayerYScaleTypeCommand as mi, SetLegendAlignCommand as gi, SetLegendDisplayCommand as vi, SetLegendPositionCommand as fi, SetLineInterpolationCommand as bi, SetLineMissingValuesCommand as Ci, SetLineWidthCommand as an, SetMappingCommand as yi, SetNumberFormatAbbreviationCommand as Si, SetNumberFormatDecimalsCommand as on, SetPointSizeCommand as xi, SetPolarInnerRadiusCommand as wi, SetPolarStartAngleCommand as Ti, SetRuleLabelCommand as Ai, SetRuleValueCommand as ki, SetScaleDomainCommand as Be, SetScaleReverseCommand as Li, SetScaleTransformCommand as Pi, SetScaleZeroCommand as ln, SetStatLineCommand as Ii, SetStyleRuleCommand as Le, TEXT_ANNOTATION_DEFAULTS as Ei, TEXT_ANNOTATION_FADE_ALPHA as Mi, ToggleCategoryLabelsCommand as Ni, ToggleContentVisibilityCommand as at, ToggleDataLabelsCommand as Oi, ToggleGoalLineCommand as Ri, ToggleLineFillCommand as Di, ToggleLinePointsVisibilityCommand as zi, ToggleStackTotalsCommand as _i, UpdateAnnotationCommand as re, alignUnitFractions as Fi, areAnchorsEqual as dr, areEndpointsComparable as Hi, buildEditMenuTriggerRegion as Bi, buildLayerStyleAddress as Vi, buildObservationPredicate as Gi, canAnchorDirectLabels as $i, canBecomeCombo as Ui, canBecomeHeatmap as Wi, canPlaceDataLabels as Ki, clampAnnotationTranslation as qi, computeArrow as ur, createObservationAnchorBuilder as Zi, createObservationAnchorParser as Xi, createStyleResolver as Oe, createValueFormatter as ji, extractConstantValue as Yi, extractVariableName as Ji, filterLayersByGeoms as bt, findAnnotation as Qi, findAverageLineLayer as el, findGoalLineLayer as tl, findHighlightsAtObservation as nl, findKindStyleDeclarations as rl, findLayerByGeom as hr, findObservationAttachment as al, findStyleRule as fe, findTrendLineLayer as ol, formatDifferenceLabel as il, hasMultipleGroups as ll, inferDefaultDifferenceArrowEndpoints as sl, inferDifferenceArrowEndpoints as cl, isComboChartType as ve, isCompanionLayer as pr, isObservationAttachmentKind as dl, isPointWithinEditMenuTrigger as mr, isSafeUrl as ul, projectAnchorToPanel as We, readChartType as gr, readComboLineLayerId as hl, readHighlightDimStyle as pl, readMappableAesthetics as ml, readMappedVariable as gl, readObservationIndex as vl, resolveBarBandFraction as fl, resolveComparisonBasis as bl, resolveGridLineStyle as Cl, resolveObservationPoint as vr, resolveShapeAnnotationStyle as yl, stepDifferenceArrowEndpoint as Sl, toPanelCursor as Dt } from "@graphysdk/viz-engine";
4
+ import { createContext as Re, useCallback as ie, useContext as Pe, useEffect as O, useId as Ae, useMemo as M, useRef as te, useState as Q } from "react";
5
5
  import { Fragment as j, jsx as n, jsxs as m } from "react/jsx-runtime";
6
- import { useShallow as Pe } from "zustand/react/shallow";
6
+ import { useShallow as Ie } from "zustand/react/shallow";
7
7
  import { createPortal as fr } from "react-dom";
8
8
  import de from "clsx";
9
- import { autoUpdate as wl, flip as Tl, offset as Al, shift as kl, useFloating as Ll } from "@floating-ui/react-dom";
9
+ import { autoUpdate as xl, flip as wl, offset as Tl, shift as Al, useFloating as kl } from "@floating-ui/react-dom";
10
10
  import { assignInlineVars as br } from "@vanilla-extract/dynamic";
11
11
  import { Extension as Cr } from "@tiptap/core";
12
- import { Bold as Pl } from "@tiptap/extension-bold";
13
- import { Document as We } from "@tiptap/extension-document";
14
- import { HardBreak as Il } from "@tiptap/extension-hard-break";
15
- import { Heading as El } from "@tiptap/extension-heading";
16
- import { Italic as Ml } from "@tiptap/extension-italic";
17
- import { Link as Nl } from "@tiptap/extension-link";
18
- import { Text as Ol } from "@tiptap/extension-text";
19
- import { TextAlign as Rl } from "@tiptap/extension-text-align";
20
- import { Color as Dl, FontFamily as yr, TextStyle as zl } from "@tiptap/extension-text-style";
21
- import { Underline as _l } from "@tiptap/extension-underline";
22
- import { Placeholder as zt, UndoRedo as Fl } from "@tiptap/extensions";
12
+ import { Bold as Ll } from "@tiptap/extension-bold";
13
+ import { Document as Ke } from "@tiptap/extension-document";
14
+ import { HardBreak as Pl } from "@tiptap/extension-hard-break";
15
+ import { Heading as Il } from "@tiptap/extension-heading";
16
+ import { Italic as El } from "@tiptap/extension-italic";
17
+ import { Link as Ml } from "@tiptap/extension-link";
18
+ import { Text as Nl } from "@tiptap/extension-text";
19
+ import { TextAlign as Ol } from "@tiptap/extension-text-align";
20
+ import { Color as Rl, FontFamily as yr, TextStyle as Dl } from "@tiptap/extension-text-style";
21
+ import { Underline as zl } from "@tiptap/extension-underline";
22
+ import { Placeholder as zt, UndoRedo as _l } from "@tiptap/extensions";
23
23
  import { Paragraph as Sr } from "@tiptap/extension-paragraph";
24
- import { EditorContent as xr, useEditor as Hl, useEditorState as Bl } from "@tiptap/react";
24
+ import { EditorContent as xr, useEditor as Fl, useEditorState as Hl } from "@tiptap/react";
25
25
  import { Toolbar as ue } from "@base-ui/react/toolbar";
26
- import { Tooltip as xe } from "@base-ui/react/tooltip";
26
+ import { Tooltip as we } from "@base-ui/react/tooltip";
27
27
  import { Popover as Y } from "@base-ui/react/popover";
28
- import { HexColorInput as Vl, HexColorPicker as Gl } from "react-colorful";
28
+ import { HexColorInput as Bl, HexColorPicker as Vl } from "react-colorful";
29
29
  import { Slider as oe } from "@base-ui/react/slider";
30
30
  import { Menu as z } from "@base-ui/react/menu";
31
- import { Toggle as $l } from "@base-ui/react/toggle";
31
+ import { Toggle as Gl } from "@base-ui/react/toggle";
32
32
  import { Menu as me } from "@base-ui/react";
33
- import Ke from "lodash-es/clamp";
34
- import { Accordion as Ee } from "@base-ui/react/accordion";
33
+ import qe from "lodash-es/clamp";
34
+ import { Accordion as Me } from "@base-ui/react/accordion";
35
35
  import { NumberField as sn } from "@base-ui/react/number-field";
36
36
  import { Radio as wr } from "@base-ui/react/radio";
37
37
  import { RadioGroup as Tr } from "@base-ui/react/radio-group";
38
38
  import { Select as ae } from "@base-ui/react/select";
39
39
  import { Switch as cn } from "@base-ui/react/switch";
40
- import { Input as Ul } from "@base-ui/react/input";
41
- import './editable.css';var Wl = {
40
+ import { Input as $l } from "@base-ui/react/input";
41
+ import './editable.css';var Ul = {
42
42
  save: "حفظ",
43
43
  cancel: "إلغاء",
44
44
  confirm: "تأكيد",
@@ -49,7 +49,7 @@ import './editable.css';var Wl = {
49
49
  millions: "مليون",
50
50
  billions: "مليار"
51
51
  }
52
- }, Kl = {
52
+ }, Wl = {
53
53
  title: "محرر Graphy",
54
54
  description: "قم بتحرير المحتوى الخاص بك هنا",
55
55
  graphTypes: {
@@ -563,7 +563,7 @@ import './editable.css';var Wl = {
563
563
  light: "فاتح",
564
564
  dark: "داكن"
565
565
  } }
566
- }, ql = {
566
+ }, Kl = {
567
567
  titleEditor: {
568
568
  titlePlaceholder: "بدون عنوان",
569
569
  subtitlePlaceholder: "إضافة عنوان فرعي"
@@ -803,11 +803,11 @@ import './editable.css';var Wl = {
803
803
  }
804
804
  }
805
805
  }
806
+ }, ql = {
807
+ common: Ul,
808
+ editor: Wl,
809
+ graph: Kl
806
810
  }, Zl = {
807
- common: Wl,
808
- editor: Kl,
809
- graph: ql
810
- }, Xl = {
811
811
  save: "Save",
812
812
  cancel: "Cancel",
813
813
  confirm: "Confirm",
@@ -818,7 +818,7 @@ import './editable.css';var Wl = {
818
818
  millions: "m",
819
819
  billions: "b"
820
820
  }
821
- }, jl = {
821
+ }, Xl = {
822
822
  title: "Graphy Editor",
823
823
  description: "Edit your content here",
824
824
  graphTypes: {
@@ -1334,7 +1334,7 @@ import './editable.css';var Wl = {
1334
1334
  light: "Light",
1335
1335
  dark: "Dark"
1336
1336
  } }
1337
- }, Yl = {
1337
+ }, jl = {
1338
1338
  titleEditor: {
1339
1339
  titlePlaceholder: "Untitled",
1340
1340
  subtitlePlaceholder: "Add a subtitle"
@@ -1574,17 +1574,17 @@ import './editable.css';var Wl = {
1574
1574
  }
1575
1575
  }
1576
1576
  }
1577
+ }, Yl = {
1578
+ common: Zl,
1579
+ editor: Xl,
1580
+ graph: jl
1577
1581
  }, Jl = {
1578
- common: Xl,
1579
- editor: jl,
1580
- graph: Yl
1581
- }, Ql = {
1582
1582
  colorPanel: {
1583
1583
  backgroundSection: { grey: "Gray" },
1584
1584
  borderType: { grey: "Gray" }
1585
1585
  },
1586
1586
  highlighting: { highlightStyle: { grey: "Gray" } }
1587
- }, es = { editor: Ql }, ts = {
1587
+ }, Ql = { editor: Jl }, es = {
1588
1588
  save: "Guardar",
1589
1589
  cancel: "Cancelar",
1590
1590
  confirm: "Confirmar",
@@ -1595,7 +1595,7 @@ import './editable.css';var Wl = {
1595
1595
  millions: "M",
1596
1596
  billions: "MM"
1597
1597
  }
1598
- }, ns = {
1598
+ }, ts = {
1599
1599
  title: "Editor Graphy",
1600
1600
  description: "Edite o seu conteúdo aqui",
1601
1601
  graphTypes: {
@@ -2110,7 +2110,7 @@ import './editable.css';var Wl = {
2110
2110
  light: "Claro",
2111
2111
  dark: "Escuro"
2112
2112
  } }
2113
- }, rs = {
2113
+ }, ns = {
2114
2114
  titleEditor: {
2115
2115
  titlePlaceholder: "Sem título",
2116
2116
  subtitlePlaceholder: "Adicionar subtítulo"
@@ -2350,26 +2350,26 @@ import './editable.css';var Wl = {
2350
2350
  }
2351
2351
  }
2352
2352
  }
2353
+ }, rs = {
2354
+ common: es,
2355
+ editor: ts,
2356
+ graph: ns
2353
2357
  }, as = {
2354
- common: ts,
2355
- editor: ns,
2356
- graph: rs
2357
- }, os = {
2358
- "en-GB": Jl,
2359
- "en-US": es,
2360
- ar: Zl,
2361
- "pt-PT": as
2362
- }, is = [os, Oo], ls = ({ children: e, ...t }) => /* @__PURE__ */ n(So, {
2363
- dictionaries: is,
2358
+ "en-GB": Yl,
2359
+ "en-US": Ql,
2360
+ ar: ql,
2361
+ "pt-PT": rs
2362
+ }, os = [as, Oo], is = ({ children: e, ...t }) => /* @__PURE__ */ n(So, {
2363
+ dictionaries: os,
2364
2364
  ...t,
2365
2365
  children: e
2366
- }), ss = "data-variant", Ar = Sr.extend({ addAttributes() {
2366
+ }), ls = "data-variant", Ar = Sr.extend({ addAttributes() {
2367
2367
  return { variant: {
2368
2368
  default: null,
2369
2369
  parseHTML: (e) => e.getAttribute("data-variant") ?? null,
2370
- renderHTML: (e) => e.variant ? { [ss]: e.variant } : {}
2370
+ renderHTML: (e) => e.variant ? { [ls]: e.variant } : {}
2371
2371
  } };
2372
- } }), cs = Cr.create({
2372
+ } }), ss = Cr.create({
2373
2373
  name: "preventBackspaceAcrossTitleBoundary",
2374
2374
  addOptions() {
2375
2375
  return { isTitleVisible: !0 };
@@ -2384,33 +2384,33 @@ import './editable.css';var Wl = {
2384
2384
  } };
2385
2385
  }
2386
2386
  }), _t = () => [
2387
- Ol,
2388
- Fl,
2389
- El.configure({ levels: [
2387
+ Nl,
2388
+ _l,
2389
+ Il.configure({ levels: [
2390
2390
  1,
2391
2391
  2,
2392
2392
  3
2393
2393
  ] }),
2394
- Pl,
2395
- Ml,
2396
- _l,
2397
- Rl.configure({ types: ["heading", "paragraph"] }),
2398
- Nl.configure({
2394
+ Ll,
2395
+ El,
2396
+ zl,
2397
+ Ol.configure({ types: ["heading", "paragraph"] }),
2398
+ Ml.configure({
2399
2399
  openOnClick: !1,
2400
2400
  autolink: !0
2401
2401
  }),
2402
- zl,
2403
2402
  Dl,
2404
- Il
2405
- ], ds = ({ titlePlaceholder: e, subtitlePlaceholder: t, isTitleVisible: r, isSubtitleVisible: a }) => [
2406
- hs({
2403
+ Rl,
2404
+ Pl
2405
+ ], cs = ({ titlePlaceholder: e, subtitlePlaceholder: t, isTitleVisible: r, isSubtitleVisible: a }) => [
2406
+ us({
2407
2407
  isTitleVisible: r,
2408
2408
  isSubtitleVisible: a
2409
2409
  }),
2410
2410
  Ar,
2411
2411
  ..._t(),
2412
2412
  yr,
2413
- cs.configure({ isTitleVisible: r }),
2413
+ ss.configure({ isTitleVisible: r }),
2414
2414
  zt.configure({
2415
2415
  showOnlyCurrent: !1,
2416
2416
  placeholder: ({ pos: o, editor: i }) => {
@@ -2419,8 +2419,8 @@ import './editable.css';var Wl = {
2419
2419
  return a && o === l ? t : "";
2420
2420
  }
2421
2421
  })
2422
- ], us = ({ placeholder: e }) => [
2423
- We,
2422
+ ], ds = ({ placeholder: e }) => [
2423
+ Ke,
2424
2424
  Ar,
2425
2425
  ..._t(),
2426
2426
  yr,
@@ -2428,26 +2428,26 @@ import './editable.css';var Wl = {
2428
2428
  showOnlyCurrent: !1,
2429
2429
  placeholder: ({ pos: t }) => t === 0 ? e : ""
2430
2430
  })
2431
- ], hs = ({ isTitleVisible: e, isSubtitleVisible: t }) => e && t ? We.extend({ content: "block{2,}" }) : We, kr = "linear-gradient(to top right, transparent calc(50% - 1px), var(--graphy-alert) calc(50% - 1px), var(--graphy-alert) calc(50% + 1px), transparent calc(50% + 1px))", ps = "d0bl00";
2432
- var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", vs = "d0bl08", Ir = "d0bl09", fs = "d0bl0a", bs = "d0bl0b", Cs = "d0bl0c", ys = "d0bl0d", Ss = "d0bl0e", xs = "owf1yg0", ws = "owf1yg1", Ts = "owf1yg2", As = "owf1yg3", ks = "owf1yg4", Ls = 0.01, Ps = ({ value: e, onChange: t, label: r }) => /* @__PURE__ */ n(oe.Root, {
2433
- className: xs,
2431
+ ], us = ({ isTitleVisible: e, isSubtitleVisible: t }) => e && t ? Ke.extend({ content: "block{2,}" }) : Ke, kr = "linear-gradient(to top right, transparent calc(50% - 1px), var(--graphy-alert) calc(50% - 1px), var(--graphy-alert) calc(50% + 1px), transparent calc(50% + 1px))", hs = "d0bl00";
2432
+ var Lr = "d0bl03", ps = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", ms = "d0bl07", gs = "d0bl08", Ir = "d0bl09", vs = "d0bl0a", fs = "d0bl0b", bs = "d0bl0c", Cs = "d0bl0d", ys = "d0bl0e", Ss = "owf1yg0", xs = "owf1yg1", ws = "owf1yg2", Ts = "owf1yg3", As = "owf1yg4", ks = 0.01, Ls = ({ value: e, onChange: t, label: r }) => /* @__PURE__ */ n(oe.Root, {
2433
+ className: Ss,
2434
2434
  value: e,
2435
2435
  onValueChange: (a) => t(a),
2436
2436
  min: 0,
2437
2437
  max: 1,
2438
- step: Ls,
2438
+ step: ks,
2439
2439
  children: /* @__PURE__ */ n(oe.Control, {
2440
- className: ws,
2440
+ className: xs,
2441
2441
  children: /* @__PURE__ */ m(oe.Track, {
2442
- className: Ts,
2443
- children: [/* @__PURE__ */ n(oe.Indicator, { className: As }), /* @__PURE__ */ n(oe.Thumb, {
2444
- className: ks,
2442
+ className: ws,
2443
+ children: [/* @__PURE__ */ n(oe.Indicator, { className: Ts }), /* @__PURE__ */ n(oe.Thumb, {
2444
+ className: As,
2445
2445
  "aria-label": r
2446
2446
  })]
2447
2447
  })
2448
2448
  })
2449
- }), Er = "transparent", yt = rr.map((e) => ce[e]), Is = Object.fromEntries(rr.map((e) => [ce[e], e])), Es = (e) => yt.some((t) => Nr(t, e)), Ms = ({ color: e, onChange: t, isOpen: r, onOpenChange: a, children: o, label: i, popupAttributes: l, opacity: s, onOpacityChange: c, hasTransparentOption: u = !1 }) => {
2450
- const d = k(), h = Os(), v = u ? [Er, ...yt] : yt, p = (g) => {
2449
+ }), Er = "transparent", yt = rr.map((e) => ce[e]), Ps = Object.fromEntries(rr.map((e) => [ce[e], e])), Is = (e) => yt.some((t) => Nr(t, e)), Es = ({ color: e, onChange: t, isOpen: r, onOpenChange: a, children: o, label: i, popupAttributes: l, opacity: s, onOpacityChange: c, hasTransparentOption: u = !1 }) => {
2450
+ const d = k(), h = Ns(), v = u ? [Er, ...yt] : yt, p = (g) => {
2451
2451
  t(g), a(!1);
2452
2452
  };
2453
2453
  return /* @__PURE__ */ m(Y.Root, {
@@ -2456,7 +2456,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2456
2456
  children: [/* @__PURE__ */ n(Y.Trigger, {
2457
2457
  render: /* @__PURE__ */ n(ue.Button, {}),
2458
2458
  "aria-label": i ?? d("graph.toolbar.color.label"),
2459
- className: ps,
2459
+ className: hs,
2460
2460
  onMouseDown: (g) => g.preventDefault(),
2461
2461
  children: o ?? /* @__PURE__ */ n("span", {
2462
2462
  className: "d0bl01",
@@ -2469,7 +2469,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2469
2469
  align: "start",
2470
2470
  className: Lr,
2471
2471
  children: /* @__PURE__ */ m(Y.Popup, {
2472
- className: ms,
2472
+ className: ps,
2473
2473
  onMouseDown: (g) => g.preventDefault(),
2474
2474
  ...l,
2475
2475
  children: [
@@ -2485,7 +2485,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2485
2485
  currentColor: e,
2486
2486
  onPick: p
2487
2487
  }),
2488
- /* @__PURE__ */ n(Ns, {
2488
+ /* @__PURE__ */ n(Ms, {
2489
2489
  value: e ?? "#000000",
2490
2490
  onChange: t,
2491
2491
  popupAttributes: l
@@ -2495,7 +2495,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2495
2495
  children: [/* @__PURE__ */ n("div", {
2496
2496
  className: "d0bl06",
2497
2497
  children: d("graph.colorDropdown.opacity")
2498
- }), /* @__PURE__ */ n(Ps, {
2498
+ }), /* @__PURE__ */ n(Ls, {
2499
2499
  value: s,
2500
2500
  onChange: c,
2501
2501
  label: d("graph.colorDropdown.opacity")
@@ -2514,11 +2514,11 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2514
2514
  className: Ct,
2515
2515
  children: e
2516
2516
  }), /* @__PURE__ */ n("div", {
2517
- className: gs,
2517
+ className: ms,
2518
2518
  children: t.map((i) => /* @__PURE__ */ n("button", {
2519
2519
  type: "button",
2520
2520
  "aria-label": i === "transparent" ? o("graph.colorDropdown.transparent") : i,
2521
- className: vs,
2521
+ className: gs,
2522
2522
  "data-active": Nr(i, r),
2523
2523
  onMouseDown: (l) => l.preventDefault(),
2524
2524
  onClick: () => a(i),
@@ -2529,8 +2529,8 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2529
2529
  }, i))
2530
2530
  })]
2531
2531
  });
2532
- }, Ns = ({ value: e, onChange: t, popupAttributes: r }) => {
2533
- const a = k(), [o, i] = Q(!1), l = lo(e) ? e : "#000000", s = Rs(l);
2532
+ }, Ms = ({ value: e, onChange: t, popupAttributes: r }) => {
2533
+ const a = k(), [o, i] = Q(!1), l = lo(e) ? e : "#000000", s = Os(l);
2534
2534
  return /* @__PURE__ */ m(Y.Root, {
2535
2535
  open: o,
2536
2536
  onOpenChange: i,
@@ -2540,14 +2540,14 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2540
2540
  className: Ct,
2541
2541
  children: a("graph.colorDropdown.custom")
2542
2542
  }), /* @__PURE__ */ m(Y.Trigger, {
2543
- className: fs,
2543
+ className: vs,
2544
2544
  onMouseDown: (c) => c.preventDefault(),
2545
2545
  "aria-label": a("graph.colorDropdown.pickCustom"),
2546
2546
  children: [/* @__PURE__ */ n("span", {
2547
2547
  className: Ir,
2548
2548
  style: Mr(l)
2549
2549
  }), /* @__PURE__ */ n("span", {
2550
- className: bs,
2550
+ className: fs,
2551
2551
  children: s
2552
2552
  })]
2553
2553
  })]
@@ -2559,7 +2559,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2559
2559
  sideOffset: 18,
2560
2560
  className: Lr,
2561
2561
  children: /* @__PURE__ */ m(Y.Popup, {
2562
- className: Cs,
2562
+ className: bs,
2563
2563
  onMouseDown: (c) => c.preventDefault(),
2564
2564
  ...r,
2565
2565
  children: [
@@ -2567,16 +2567,16 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2567
2567
  className: Ct,
2568
2568
  children: a("graph.colorDropdown.pickColor")
2569
2569
  }),
2570
- /* @__PURE__ */ n(Gl, {
2570
+ /* @__PURE__ */ n(Vl, {
2571
2571
  color: s,
2572
2572
  onChange: t,
2573
- className: ys
2573
+ className: Cs
2574
2574
  }),
2575
- /* @__PURE__ */ n(Vl, {
2575
+ /* @__PURE__ */ n(Bl, {
2576
2576
  color: s,
2577
2577
  onChange: t,
2578
2578
  prefixed: !0,
2579
- className: Ss,
2579
+ className: ys,
2580
2580
  onMouseDown: (c) => c.stopPropagation()
2581
2581
  })
2582
2582
  ]
@@ -2584,7 +2584,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2584
2584
  }) })
2585
2585
  })]
2586
2586
  });
2587
- }, Os = () => {
2587
+ }, Ns = () => {
2588
2588
  const e = _((t) => t.scales.color);
2589
2589
  return M(() => {
2590
2590
  if (!e || e.kind !== "visual") return [];
@@ -2601,53 +2601,53 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2601
2601
  } : {
2602
2602
  background: e,
2603
2603
  border: `1px solid ${mo(e, 0.1)}`
2604
- }, Rs = (e) => {
2605
- const { themeValues: t } = nt();
2604
+ }, Os = (e) => {
2605
+ const { themeValues: t } = rt();
2606
2606
  if (Po(e)) return e.toUpperCase();
2607
- const r = Is[e];
2607
+ const r = Ps[e];
2608
2608
  return r ? t[r].toUpperCase() : "#000000";
2609
- }, Nr = (e, t) => t === null ? !1 : e.toLowerCase() === t.toLowerCase(), Ds = "l9kff0", zs = "l9kff1", _s = "l9kff2", Fs = "xn24px0", Hs = "xn24px1", Bs = "xn24px2", Vs = ({ children: e, popupAttributes: t }) => /* @__PURE__ */ n(z.Portal, {
2609
+ }, Nr = (e, t) => t === null ? !1 : e.toLowerCase() === t.toLowerCase(), Rs = "l9kff0", Ds = "l9kff1", zs = "l9kff2", _s = "xn24px0", Fs = "xn24px1", Hs = "xn24px2", Bs = ({ children: e, popupAttributes: t }) => /* @__PURE__ */ n(z.Portal, {
2610
2610
  container: le(),
2611
2611
  children: /* @__PURE__ */ n(ee, { children: /* @__PURE__ */ n(z.Positioner, {
2612
2612
  side: "bottom",
2613
2613
  align: "start",
2614
2614
  sideOffset: 6,
2615
- className: Fs,
2615
+ className: _s,
2616
2616
  children: /* @__PURE__ */ n(z.Popup, {
2617
- className: Hs,
2617
+ className: Fs,
2618
2618
  onMouseDown: (r) => r.preventDefault(),
2619
2619
  ...t,
2620
2620
  children: e
2621
2621
  })
2622
2622
  }) })
2623
- }), Gs = ({ children: e, isSelected: t = !1, isDisabled: r = !1, onClick: a }) => /* @__PURE__ */ n(z.Item, {
2624
- className: Bs,
2623
+ }), Vs = ({ children: e, isSelected: t = !1, isDisabled: r = !1, onClick: a }) => /* @__PURE__ */ n(z.Item, {
2624
+ className: Hs,
2625
2625
  "data-selected": t,
2626
2626
  disabled: r,
2627
2627
  onClick: a,
2628
2628
  children: e
2629
- }), $s = ({ className: e, ...t }) => /* @__PURE__ */ n(xe.Provider, { children: /* @__PURE__ */ n(ue.Root, {
2629
+ }), Gs = ({ className: e, ...t }) => /* @__PURE__ */ n(we.Provider, { children: /* @__PURE__ */ n(ue.Root, {
2630
+ ...t,
2631
+ className: de(Rs, e)
2632
+ }) }), $s = ({ className: e, ...t }) => /* @__PURE__ */ n(ue.Group, {
2630
2633
  ...t,
2631
2634
  className: de(Ds, e)
2632
- }) }), Us = ({ className: e, ...t }) => /* @__PURE__ */ n(ue.Group, {
2635
+ }), Us = ({ className: e, ...t }) => /* @__PURE__ */ n(ue.Separator, {
2633
2636
  ...t,
2634
2637
  className: de(zs, e)
2635
- }), Ws = ({ className: e, ...t }) => /* @__PURE__ */ n(ue.Separator, {
2636
- ...t,
2637
- className: de(_s, e)
2638
- }), Ks = ({ children: e }) => {
2638
+ }), Ws = ({ children: e }) => {
2639
2639
  const t = le();
2640
2640
  return t === null ? null : fr(/* @__PURE__ */ n(ee, { children: e }), t);
2641
2641
  }, K = {
2642
- Portal: Ks,
2643
- Root: $s,
2644
- Group: Us,
2645
- Separator: Ws,
2642
+ Portal: Ws,
2643
+ Root: Gs,
2644
+ Group: $s,
2645
+ Separator: Us,
2646
2646
  Button: ue.Button,
2647
- ColorPicker: Ms,
2648
- MenuPopup: Vs,
2649
- MenuItem: Gs
2650
- }, Re = (e) => /* @__PURE__ */ n(x, {
2647
+ ColorPicker: Es,
2648
+ MenuPopup: Bs,
2649
+ MenuItem: Vs
2650
+ }, De = (e) => /* @__PURE__ */ n(x, {
2651
2651
  ...e,
2652
2652
  children: /* @__PURE__ */ n("g", {
2653
2653
  stroke: "currentColor",
@@ -2656,7 +2656,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2656
2656
  strokeLinejoin: "round",
2657
2657
  children: /* @__PURE__ */ n("path", { d: "m6 9 6 6 6-6" })
2658
2658
  })
2659
- }), qs = "'Noto Serif', Georgia, 'Times New Roman', serif, 'Apple Color Emoji', 'NotoColorEmoji'", Zs = `'Aeonik', 'Aeonik Fallback', ${nr}`, Xs = "'PT Mono', 'Courier New', monospace, 'Apple Color Emoji', 'NotoColorEmoji'", js = "'Intruding Cat', cursive, 'Apple Color Emoji', 'NotoColorEmoji'", St = [
2659
+ }), Ks = "'Noto Serif', Georgia, 'Times New Roman', serif, 'Apple Color Emoji', 'NotoColorEmoji'", qs = `'Aeonik', 'Aeonik Fallback', ${nr}`, Zs = "'PT Mono', 'Courier New', monospace, 'Apple Color Emoji', 'NotoColorEmoji'", Xs = "'Intruding Cat', cursive, 'Apple Color Emoji', 'NotoColorEmoji'", St = [
2660
2660
  {
2661
2661
  id: "modern",
2662
2662
  label: "Modern",
@@ -2667,28 +2667,28 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2667
2667
  id: "fresh",
2668
2668
  label: "Fresh",
2669
2669
  preview: "Aa",
2670
- fontFamily: Zs
2670
+ fontFamily: qs
2671
2671
  },
2672
2672
  {
2673
2673
  id: "timeless",
2674
2674
  label: "Timeless",
2675
2675
  preview: "Aa",
2676
- fontFamily: qs
2676
+ fontFamily: Ks
2677
2677
  },
2678
2678
  {
2679
2679
  id: "technical",
2680
2680
  label: "Technical",
2681
2681
  preview: "00",
2682
- fontFamily: Xs
2682
+ fontFamily: Zs
2683
2683
  },
2684
2684
  {
2685
2685
  id: "fineliner",
2686
2686
  label: "Fineliner",
2687
2687
  preview: "Aa",
2688
- fontFamily: js
2688
+ fontFamily: Xs
2689
2689
  }
2690
- ], Ys = (e) => e ? St.find((t) => t.fontFamily === e) ?? null : null, Or = "_70l3rt0", Rr = "_70l3rt1", Dr = "_70l3rt3", zr = "_70l3rt4", _r = "_70l3rt5", Js = ({ editor: e, currentFontFamily: t, isOpen: r, onOpenChange: a }) => {
2691
- const o = k(), i = Ys(t) ?? St[0], l = (s) => {
2690
+ ], js = (e) => e ? St.find((t) => t.fontFamily === e) ?? null : null, Or = "_70l3rt0", Rr = "_70l3rt1", Dr = "_70l3rt3", zr = "_70l3rt4", _r = "_70l3rt5", Ys = ({ editor: e, currentFontFamily: t, isOpen: r, onOpenChange: a }) => {
2691
+ const o = k(), i = js(t) ?? St[0], l = (s) => {
2692
2692
  e.chain().focus().setFontFamily(s.fontFamily).run();
2693
2693
  };
2694
2694
  return /* @__PURE__ */ m(z.Root, {
@@ -2703,7 +2703,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2703
2703
  className: Rr,
2704
2704
  style: { fontFamily: i?.fontFamily },
2705
2705
  children: i?.preview
2706
- }), /* @__PURE__ */ n(Re, { size: "sm" })]
2706
+ }), /* @__PURE__ */ n(De, { size: "sm" })]
2707
2707
  }), /* @__PURE__ */ n(z.Portal, {
2708
2708
  container: le(),
2709
2709
  children: /* @__PURE__ */ n(ee, { children: /* @__PURE__ */ n(z.Positioner, {
@@ -2753,7 +2753,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2753
2753
  translationKey: "graph.toolbar.heading.heading1",
2754
2754
  previewFont: ce.fontTextEditorH1
2755
2755
  }
2756
- ], Qs = ({ editor: e, activeStyle: t, isOpen: r, onOpenChange: a }) => {
2756
+ ], Js = ({ editor: e, activeStyle: t, isOpen: r, onOpenChange: a }) => {
2757
2757
  const o = k(), i = un.find((l) => l.id === t) ?? Fr;
2758
2758
  return /* @__PURE__ */ m(z.Root, {
2759
2759
  open: r,
@@ -2766,7 +2766,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2766
2766
  children: [/* @__PURE__ */ n("span", {
2767
2767
  className: Rr,
2768
2768
  children: o(i.translationKey)
2769
- }), /* @__PURE__ */ n(Re, { size: "sm" })]
2769
+ }), /* @__PURE__ */ n(De, { size: "sm" })]
2770
2770
  }), /* @__PURE__ */ n(z.Portal, {
2771
2771
  container: le(),
2772
2772
  children: /* @__PURE__ */ n(ee, { children: /* @__PURE__ */ n(z.Positioner, {
@@ -2780,8 +2780,8 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2780
2780
  children: un.map((l) => /* @__PURE__ */ n(z.Item, {
2781
2781
  className: _r,
2782
2782
  "data-selected": l.id === i.id,
2783
- onClick: () => ec(e, l.id),
2784
- children: /* @__PURE__ */ n(tc, {
2783
+ onClick: () => Qs(e, l.id),
2784
+ children: /* @__PURE__ */ n(ec, {
2785
2785
  font: l.previewFont,
2786
2786
  children: o(l.translationKey)
2787
2787
  })
@@ -2790,7 +2790,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2790
2790
  }) })
2791
2791
  })]
2792
2792
  });
2793
- }, ec = (e, t) => {
2793
+ }, Qs = (e, t) => {
2794
2794
  switch (t) {
2795
2795
  case "caption":
2796
2796
  e.chain().focus().setNode("paragraph", { variant: "caption" }).run();
@@ -2807,7 +2807,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2807
2807
  case "h3":
2808
2808
  e.chain().focus().setHeading({ level: 3 }).run();
2809
2809
  }
2810
- }, tc = ({ font: e, children: t }) => /* @__PURE__ */ n("span", {
2810
+ }, ec = ({ font: e, children: t }) => /* @__PURE__ */ n("span", {
2811
2811
  style: {
2812
2812
  font: e,
2813
2813
  margin: 0
@@ -2822,7 +2822,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2822
2822
  strokeLinejoin: "round",
2823
2823
  children: /* @__PURE__ */ n("path", { d: "M20 6 9 17l-5-5" })
2824
2824
  })
2825
- }), nc = (e) => /* @__PURE__ */ n(x, {
2825
+ }), tc = (e) => /* @__PURE__ */ n(x, {
2826
2826
  ...e,
2827
2827
  children: /* @__PURE__ */ m("g", {
2828
2828
  stroke: "currentColor",
@@ -2831,7 +2831,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2831
2831
  strokeLinejoin: "round",
2832
2832
  children: [/* @__PURE__ */ n("path", { d: "M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71" }), /* @__PURE__ */ n("path", { d: "M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71" })]
2833
2833
  })
2834
- }), rc = (e) => /* @__PURE__ */ n(x, {
2834
+ }), nc = (e) => /* @__PURE__ */ n(x, {
2835
2835
  ...e,
2836
2836
  children: /* @__PURE__ */ m("g", {
2837
2837
  stroke: "currentColor",
@@ -2840,7 +2840,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2840
2840
  strokeLinejoin: "round",
2841
2841
  children: [/* @__PURE__ */ n("path", { d: "M18 6 6 18" }), /* @__PURE__ */ n("path", { d: "m6 6 12 12" })]
2842
2842
  })
2843
- }), ac = (e) => !e.content || e.content.length === 0 ? !0 : e.content.every((t) => !t.content || t.content.length === 0), oc = (e) => {
2843
+ }), rc = (e) => !e.content || e.content.length === 0 ? !0 : e.content.every((t) => !t.content || t.content.length === 0), ac = (e) => {
2844
2844
  const { $from: t } = e.state.selection, r = t.parent.textContent, a = t.parentOffset, o = t.start();
2845
2845
  let i = a;
2846
2846
  for (; i > 0 && hn(r[i - 1]); ) i -= 1;
@@ -2850,13 +2850,13 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2850
2850
  from: o + i,
2851
2851
  to: o + l
2852
2852
  };
2853
- }, hn = (e) => e !== void 0 && /\S/.test(e), ic = "fop13s0", lc = "fop13s1", sc = "fop13s2", cc = "fop13s3", pn = "fop13s4", dc = ({ editor: e, currentUrl: t, isActive: r, isOpen: a, onOpenChange: o }) => {
2853
+ }, hn = (e) => e !== void 0 && /\S/.test(e), oc = "fop13s0", ic = "fop13s1", lc = "fop13s2", sc = "fop13s3", pn = "fop13s4", cc = ({ editor: e, currentUrl: t, isActive: r, isOpen: a, onOpenChange: o }) => {
2854
2854
  const i = k(), [l, s] = Q(""), c = te(null);
2855
2855
  O(() => {
2856
2856
  a && s(t ?? "");
2857
2857
  }, [a, t]);
2858
2858
  const u = () => {
2859
- uc(e, l), o(!1);
2859
+ dc(e, l), o(!1);
2860
2860
  }, d = () => {
2861
2861
  s(""), o(!1);
2862
2862
  }, h = (p) => {
@@ -2871,17 +2871,17 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2871
2871
  render: /* @__PURE__ */ n(ue.Button, {}),
2872
2872
  "aria-label": i("graph.toolbar.formatting.link"),
2873
2873
  "data-active": r,
2874
- className: ic,
2874
+ className: oc,
2875
2875
  onMouseDown: (p) => p.preventDefault(),
2876
- children: /* @__PURE__ */ n(nc, {})
2876
+ children: /* @__PURE__ */ n(tc, {})
2877
2877
  }), /* @__PURE__ */ n(Y.Portal, {
2878
2878
  container: le(),
2879
2879
  children: /* @__PURE__ */ n(ee, { children: /* @__PURE__ */ n(Y.Positioner, {
2880
2880
  sideOffset: 6,
2881
2881
  align: "end",
2882
- className: lc,
2882
+ className: ic,
2883
2883
  children: /* @__PURE__ */ m(Y.Popup, {
2884
- className: sc,
2884
+ className: lc,
2885
2885
  initialFocus: c,
2886
2886
  onMouseDown: (p) => p.preventDefault(),
2887
2887
  children: [
@@ -2891,7 +2891,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2891
2891
  value: l,
2892
2892
  placeholder: i("graph.toolbar.link.placeholder"),
2893
2893
  "aria-label": i("graph.toolbar.link.urlLabel"),
2894
- className: cc,
2894
+ className: sc,
2895
2895
  onMouseDown: (p) => p.stopPropagation(),
2896
2896
  onChange: h,
2897
2897
  onKeyDown: v
@@ -2901,7 +2901,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2901
2901
  "aria-label": i("common.cancel"),
2902
2902
  className: pn,
2903
2903
  onClick: d,
2904
- children: /* @__PURE__ */ n(rc, {})
2904
+ children: /* @__PURE__ */ n(nc, {})
2905
2905
  }),
2906
2906
  /* @__PURE__ */ n("button", {
2907
2907
  type: "button",
@@ -2915,7 +2915,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2915
2915
  }) })
2916
2916
  })]
2917
2917
  });
2918
- }, uc = (e, t) => {
2918
+ }, dc = (e, t) => {
2919
2919
  const r = t.trim(), { selection: a } = e.state;
2920
2920
  if (!r) {
2921
2921
  e.chain().focus().extendMarkRange("link").unsetLink().run();
@@ -2929,7 +2929,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2929
2929
  e.chain().focus().extendMarkRange("link").setLink({ href: r }).run();
2930
2930
  return;
2931
2931
  }
2932
- const o = oc(e);
2932
+ const o = ac(e);
2933
2933
  e.chain().focus().setTextSelection(o).setLink({ href: r }).run();
2934
2934
  }, Br = (e) => /* @__PURE__ */ n(x, {
2935
2935
  ...e,
@@ -2970,51 +2970,51 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
2970
2970
  /* @__PURE__ */ n("path", { d: "M17 19H3" })
2971
2971
  ]
2972
2972
  })
2973
- }), hc = "_1d66w570", pc = "_1d66w571", mc = 6, we = ({ label: e, isActive: t, onToggle: r, children: a }) => {
2973
+ }), uc = "_1d66w570", hc = "_1d66w571", pc = 6, Te = ({ label: e, isActive: t, onToggle: r, children: a }) => {
2974
2974
  const o = (i) => i.preventDefault();
2975
- return /* @__PURE__ */ m(xe.Root, { children: [/* @__PURE__ */ n(xe.Trigger, {
2976
- render: /* @__PURE__ */ n($l, {
2975
+ return /* @__PURE__ */ m(we.Root, { children: [/* @__PURE__ */ n(we.Trigger, {
2976
+ render: /* @__PURE__ */ n(Gl, {
2977
2977
  render: /* @__PURE__ */ n(ue.Button, {}),
2978
2978
  pressed: t,
2979
2979
  onPressedChange: () => r()
2980
2980
  }),
2981
2981
  "aria-label": e,
2982
- className: hc,
2982
+ className: uc,
2983
2983
  onMouseDown: o,
2984
2984
  children: a
2985
- }), /* @__PURE__ */ n(xe.Portal, {
2985
+ }), /* @__PURE__ */ n(we.Portal, {
2986
2986
  container: le(),
2987
- children: /* @__PURE__ */ n(ee, { children: /* @__PURE__ */ n(xe.Positioner, {
2988
- sideOffset: mc,
2989
- children: /* @__PURE__ */ n(xe.Popup, {
2990
- className: pc,
2987
+ children: /* @__PURE__ */ n(ee, { children: /* @__PURE__ */ n(we.Positioner, {
2988
+ sideOffset: pc,
2989
+ children: /* @__PURE__ */ n(we.Popup, {
2990
+ className: hc,
2991
2991
  children: e
2992
2992
  })
2993
2993
  }) })
2994
2994
  })] });
2995
- }, gc = ({ editor: e, activeAlignment: t = "left" }) => {
2995
+ }, mc = ({ editor: e, activeAlignment: t = "left" }) => {
2996
2996
  const r = k();
2997
2997
  return /* @__PURE__ */ m(j, { children: [
2998
- /* @__PURE__ */ n(we, {
2998
+ /* @__PURE__ */ n(Te, {
2999
2999
  label: r("graph.toolbar.textAlign.left"),
3000
3000
  isActive: t === "left",
3001
3001
  onToggle: () => e.chain().focus().setTextAlign("left").run(),
3002
3002
  children: /* @__PURE__ */ n(Gr, {})
3003
3003
  }),
3004
- /* @__PURE__ */ n(we, {
3004
+ /* @__PURE__ */ n(Te, {
3005
3005
  label: r("graph.toolbar.textAlign.center"),
3006
3006
  isActive: t === "center",
3007
3007
  onToggle: () => e.chain().focus().setTextAlign("center").run(),
3008
3008
  children: /* @__PURE__ */ n(Br, {})
3009
3009
  }),
3010
- /* @__PURE__ */ n(we, {
3010
+ /* @__PURE__ */ n(Te, {
3011
3011
  label: r("graph.toolbar.textAlign.right"),
3012
3012
  isActive: t === "right",
3013
3013
  onToggle: () => e.chain().focus().setTextAlign("right").run(),
3014
3014
  children: /* @__PURE__ */ n(Vr, {})
3015
3015
  })
3016
3016
  ] });
3017
- }, vc = "_1u34vl40", fc = ({ editor: e }) => ({
3017
+ }, gc = "_1u34vl40", vc = ({ editor: e }) => ({
3018
3018
  isBold: e?.isActive("bold") ?? !1,
3019
3019
  isItalic: e?.isActive("italic") ?? !1,
3020
3020
  isUnderline: e?.isActive("underline") ?? !1,
@@ -3022,23 +3022,23 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3022
3022
  linkUrl: e?.getAttributes("link").href ?? null,
3023
3023
  color: e?.getAttributes("textStyle").color ?? null,
3024
3024
  fontFamily: e?.getAttributes("textStyle").fontFamily ?? null,
3025
- fontSize: bc(e),
3026
- textAlign: Cc(e)
3027
- }), bc = (e) => e ? e.isActive("heading", { level: 1 }) ? "h1" : e.isActive("heading", { level: 2 }) ? "h2" : e.isActive("heading", { level: 3 }) ? "h3" : e.isActive("paragraph", { variant: "caption" }) ? "caption" : "text" : "text", Cc = (e) => e ? e.isActive({ textAlign: "center" }) ? "center" : e.isActive({ textAlign: "right" }) ? "right" : "left" : "left", yc = 8, Sc = 8, xc = ({ editor: e }) => {
3025
+ fontSize: fc(e),
3026
+ textAlign: bc(e)
3027
+ }), fc = (e) => e ? e.isActive("heading", { level: 1 }) ? "h1" : e.isActive("heading", { level: 2 }) ? "h2" : e.isActive("heading", { level: 3 }) ? "h3" : e.isActive("paragraph", { variant: "caption" }) ? "caption" : "text" : "text", bc = (e) => e ? e.isActive({ textAlign: "center" }) ? "center" : e.isActive({ textAlign: "right" }) ? "right" : "left" : "left", Cc = 8, yc = 8, Sc = ({ editor: e }) => {
3028
3028
  const t = k(), [r, a] = Q(!1), [o, i] = Q(null), l = o !== null, s = (p) => (g) => {
3029
3029
  i(g ? p : null);
3030
- }, { refs: c, floatingStyles: u } = Ll({
3030
+ }, { refs: c, floatingStyles: u } = kl({
3031
3031
  placement: "top-start",
3032
3032
  strategy: "fixed",
3033
3033
  middleware: [
3034
- Al(yc),
3035
- Tl(),
3036
- kl({ padding: Sc })
3034
+ Tl(Cc),
3035
+ wl(),
3036
+ Al({ padding: yc })
3037
3037
  ],
3038
- whileElementsMounted: wl
3039
- }), d = te(null), h = Bl({
3038
+ whileElementsMounted: xl
3039
+ }), d = te(null), h = Hl({
3040
3040
  editor: e,
3041
- selector: fc
3041
+ selector: vc
3042
3042
  }), v = ie((p) => {
3043
3043
  d.current = p, c.setFloating(p);
3044
3044
  }, [c]);
@@ -3055,7 +3055,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3055
3055
  };
3056
3056
  }, [e]), !e || !r && !l ? null : /* @__PURE__ */ n(K.Portal, { children: /* @__PURE__ */ m(K.Root, {
3057
3057
  ref: v,
3058
- className: vc,
3058
+ className: gc,
3059
3059
  style: u,
3060
3060
  children: [
3061
3061
  /* @__PURE__ */ m(K.Group, { children: [/* @__PURE__ */ n(K.ColorPicker, {
@@ -3063,14 +3063,14 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3063
3063
  onChange: (p) => e.chain().setColor(p).run(),
3064
3064
  isOpen: o === "color",
3065
3065
  onOpenChange: s("color")
3066
- }), /* @__PURE__ */ n(Js, {
3066
+ }), /* @__PURE__ */ n(Ys, {
3067
3067
  editor: e,
3068
3068
  currentFontFamily: h?.fontFamily ?? null,
3069
3069
  isOpen: o === "fontFamily",
3070
3070
  onOpenChange: s("fontFamily")
3071
3071
  })] }),
3072
3072
  /* @__PURE__ */ n(K.Separator, {}),
3073
- /* @__PURE__ */ n(K.Group, { children: /* @__PURE__ */ n(Qs, {
3073
+ /* @__PURE__ */ n(K.Group, { children: /* @__PURE__ */ n(Js, {
3074
3074
  editor: e,
3075
3075
  activeStyle: h?.fontSize ?? "text",
3076
3076
  isOpen: o === "fontSize",
@@ -3078,19 +3078,19 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3078
3078
  }) }),
3079
3079
  /* @__PURE__ */ n(K.Separator, {}),
3080
3080
  /* @__PURE__ */ m(K.Group, { children: [
3081
- /* @__PURE__ */ n(we, {
3081
+ /* @__PURE__ */ n(Te, {
3082
3082
  label: t("graph.toolbar.formatting.bold"),
3083
3083
  isActive: h?.isBold ?? !1,
3084
3084
  onToggle: () => e.chain().focus().toggleBold().run(),
3085
3085
  children: /* @__PURE__ */ n("strong", { children: "B" })
3086
3086
  }),
3087
- /* @__PURE__ */ n(we, {
3087
+ /* @__PURE__ */ n(Te, {
3088
3088
  label: t("graph.toolbar.formatting.italic"),
3089
3089
  isActive: h?.isItalic ?? !1,
3090
3090
  onToggle: () => e.chain().focus().toggleItalic().run(),
3091
3091
  children: /* @__PURE__ */ n("em", { children: "I" })
3092
3092
  }),
3093
- /* @__PURE__ */ n(we, {
3093
+ /* @__PURE__ */ n(Te, {
3094
3094
  label: t("graph.toolbar.formatting.underline"),
3095
3095
  isActive: h?.isUnderline ?? !1,
3096
3096
  onToggle: () => e.chain().focus().toggleUnderline().run(),
@@ -3098,12 +3098,12 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3098
3098
  })
3099
3099
  ] }),
3100
3100
  /* @__PURE__ */ n(K.Separator, {}),
3101
- /* @__PURE__ */ n(K.Group, { children: /* @__PURE__ */ n(gc, {
3101
+ /* @__PURE__ */ n(K.Group, { children: /* @__PURE__ */ n(mc, {
3102
3102
  editor: e,
3103
3103
  activeAlignment: h?.textAlign
3104
3104
  }) }),
3105
3105
  /* @__PURE__ */ n(K.Separator, {}),
3106
- /* @__PURE__ */ n(K.Group, { children: /* @__PURE__ */ n(dc, {
3106
+ /* @__PURE__ */ n(K.Group, { children: /* @__PURE__ */ n(cc, {
3107
3107
  editor: e,
3108
3108
  currentUrl: h?.linkUrl ?? null,
3109
3109
  isActive: h?.isLink ?? !1,
@@ -3112,16 +3112,16 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3112
3112
  }) })
3113
3113
  ]
3114
3114
  }) });
3115
- }, wc = "_1uy50v30", $r = ({ editor: e, ariaLabel: t }) => /* @__PURE__ */ m("div", {
3116
- className: wc,
3117
- children: [/* @__PURE__ */ n(xc, { editor: e }), /* @__PURE__ */ n(xr, {
3115
+ }, xc = "_1uy50v30", $r = ({ editor: e, ariaLabel: t }) => /* @__PURE__ */ m("div", {
3116
+ className: xc,
3117
+ children: [/* @__PURE__ */ n(Sc, { editor: e }), /* @__PURE__ */ n(xr, {
3118
3118
  editor: e,
3119
3119
  "aria-label": t
3120
3120
  })]
3121
- }), Tc = 200, Ft = ({ content: e, extensions: t, isEditable: r, onUpdate: a, updateDebounceMs: o = Tc }) => {
3121
+ }), wc = 200, Ft = ({ content: e, extensions: t, isEditable: r, onUpdate: a, updateDebounceMs: o = wc }) => {
3122
3122
  const i = te(mn(e)), l = te(i.current), s = zo((u) => {
3123
3123
  l.current = u, a?.(u);
3124
- }, o), c = Hl({
3124
+ }, o), c = Fl({
3125
3125
  extensions: t,
3126
3126
  content: i.current,
3127
3127
  editable: r,
@@ -3137,7 +3137,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3137
3137
  }, [c, r]), O(() => {
3138
3138
  if (!c) return;
3139
3139
  const u = mn(e);
3140
- mt(l.current, u) || (l.current = u, !mt(c.getJSON(), u) && (s.cancel(), Ac(c, u)));
3140
+ mt(l.current, u) || (l.current = u, !mt(c.getJSON(), u) && (s.cancel(), Tc(c, u)));
3141
3141
  }, [
3142
3142
  c,
3143
3143
  e,
@@ -3155,7 +3155,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3155
3155
  text: e
3156
3156
  }] : []
3157
3157
  }]
3158
- } : e, Ac = (e, t) => {
3158
+ } : e, Tc = (e, t) => {
3159
3159
  const { from: r, to: a } = e.state.selection;
3160
3160
  e.commands.setContent(t, { emitUpdate: !1 });
3161
3161
  const o = e.state.doc.content.size;
@@ -3163,31 +3163,31 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3163
3163
  from: Math.min(r, o),
3164
3164
  to: Math.min(a, o)
3165
3165
  });
3166
- }, mt = (e, t) => JSON.stringify(qe(e)) === JSON.stringify(qe(t)), qe = (e) => Array.isArray(e) ? e.map(qe) : e === null || typeof e != "object" ? e : Object.fromEntries(Object.entries(e).map(([t, r]) => [t, qe(r)]).filter(([, t]) => !kc(t)).sort(([t], [r]) => String(t).localeCompare(String(r)))), kc = (e) => e == null || typeof e == "object" && Object.keys(e).length === 0, Lc = ({ caption: e }) => {
3166
+ }, mt = (e, t) => JSON.stringify(Ze(e)) === JSON.stringify(Ze(t)), Ze = (e) => Array.isArray(e) ? e.map(Ze) : e === null || typeof e != "object" ? e : Object.fromEntries(Object.entries(e).map(([t, r]) => [t, Ze(r)]).filter(([, t]) => !Ac(t)).sort(([t], [r]) => String(t).localeCompare(String(r)))), Ac = (e) => e == null || typeof e == "object" && Object.keys(e).length === 0, kc = ({ caption: e }) => {
3167
3167
  const { dispatch: t } = se();
3168
3168
  return /* @__PURE__ */ n($r, {
3169
3169
  editor: Ft({
3170
3170
  content: e,
3171
- extensions: M(() => us({ placeholder: "Add caption" }), []),
3171
+ extensions: M(() => ds({ placeholder: "Add caption" }), []),
3172
3172
  isEditable: !0,
3173
3173
  onUpdate: (r) => {
3174
- const a = ac(r) ? null : r;
3174
+ const a = rc(r) ? null : r;
3175
3175
  t(new lr({ caption: a }));
3176
3176
  }
3177
3177
  }),
3178
3178
  ariaLabel: "Chart caption"
3179
3179
  });
3180
- }, Pc = (e) => [
3181
- We,
3180
+ }, Lc = (e) => [
3181
+ Ke,
3182
3182
  Sr,
3183
3183
  ..._t(),
3184
- Ec,
3184
+ Ic,
3185
3185
  zt.configure({
3186
3186
  showOnlyCurrent: !1,
3187
3187
  placeholder: ({ pos: t }) => t === 0 ? e : ""
3188
3188
  })
3189
- ], Ic = ({ annotation: e }) => {
3190
- const t = k(), { dispatch: r } = se(), a = U(), o = M(() => Pc(t("graph.annotations.text.placeholder")), [t]), i = Ft({
3189
+ ], Pc = ({ annotation: e }) => {
3190
+ const t = k(), { dispatch: r } = se(), a = U(), o = M(() => Lc(t("graph.annotations.text.placeholder")), [t]), i = Ft({
3191
3191
  content: e.content,
3192
3192
  extensions: o,
3193
3193
  isEditable: !0,
@@ -3213,7 +3213,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3213
3213
  }, gn = (e) => {
3214
3214
  const t = oo(e);
3215
3215
  return t === void 0 ? {} : { style: `font-family: ${t}` };
3216
- }, Ec = Cr.create({
3216
+ }, Ic = Cr.create({
3217
3217
  name: "annotationTextStyleAttributes",
3218
3218
  addGlobalAttributes() {
3219
3219
  return [{
@@ -3234,21 +3234,21 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3234
3234
  }
3235
3235
  }];
3236
3236
  }
3237
- }), Mc = 3, Nc = ({ title: e, isTitleVisible: t, subtitle: r, isSubtitleVisible: a }) => {
3237
+ }), Ec = 3, Mc = ({ title: e, isTitleVisible: t, subtitle: r, isSubtitleVisible: a }) => {
3238
3238
  const o = [];
3239
3239
  return t && o.push({
3240
3240
  type: "heading",
3241
- attrs: { level: Mc },
3242
- content: Rc(e)
3243
- }), a && o.push(...Dc(r)), {
3241
+ attrs: { level: Ec },
3242
+ content: Oc(e)
3243
+ }), a && o.push(...Rc(r)), {
3244
3244
  type: "doc",
3245
3245
  content: o
3246
3246
  };
3247
- }, Oc = (e) => {
3247
+ }, Nc = (e) => {
3248
3248
  const [t, ...r] = e.content ?? [];
3249
3249
  return {
3250
- title: zc(t?.content ?? []),
3251
- subtitle: _c(r)
3250
+ title: Dc(t?.content ?? []),
3251
+ subtitle: zc(r)
3252
3252
  };
3253
3253
  }, Ht = (e) => ({
3254
3254
  type: e.type ?? "text",
@@ -3256,10 +3256,10 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3256
3256
  ...e.text !== void 0 ? { text: e.text } : {},
3257
3257
  ...e.marks !== void 0 ? { marks: e.marks } : {},
3258
3258
  ...e.attrs !== void 0 ? { attrs: e.attrs } : {}
3259
- }), Rc = (e) => e === null ? [] : typeof e == "string" ? e === "" ? [] : [{
3259
+ }), Oc = (e) => e === null ? [] : typeof e == "string" ? e === "" ? [] : [{
3260
3260
  type: "text",
3261
3261
  text: e
3262
- }] : e.type === "doc" && e.content ? e.content.flatMap((t) => t.content ?? []) : e.type === "text" || e.type === "hardBreak" ? [e] : e.content ?? [], Dc = (e) => e === null ? [{ type: "paragraph" }] : typeof e == "string" ? e === "" ? [{ type: "paragraph" }] : [{
3262
+ }] : e.type === "doc" && e.content ? e.content.flatMap((t) => t.content ?? []) : e.type === "text" || e.type === "hardBreak" ? [e] : e.content ?? [], Rc = (e) => e === null ? [{ type: "paragraph" }] : typeof e == "string" ? e === "" ? [{ type: "paragraph" }] : [{
3263
3263
  type: "paragraph",
3264
3264
  content: [{
3265
3265
  type: "text",
@@ -3268,14 +3268,14 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3268
3268
  }] : e.type === "doc" && e.content ? e.content.length === 0 ? [{ type: "paragraph" }] : e.content.map(vn) : [vn(e)], vn = (e) => e.type === "paragraph" ? e : {
3269
3269
  type: "paragraph",
3270
3270
  content: e.content ?? [e]
3271
- }, zc = (e) => {
3271
+ }, Dc = (e) => {
3272
3272
  if (e.length === 0) return null;
3273
3273
  const [t] = e;
3274
3274
  return t && e.length === 1 && t.type === "text" && (!t.marks || t.marks.length === 0) ? t.text ?? null : {
3275
3275
  type: "paragraph",
3276
3276
  content: e.map(Ht)
3277
3277
  };
3278
- }, _c = (e) => {
3278
+ }, zc = (e) => {
3279
3279
  const t = e.filter((a) => (a.content ?? []).length > 0);
3280
3280
  if (t.length === 0) return null;
3281
3281
  const [r] = t;
@@ -3287,8 +3287,8 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3287
3287
  type: "doc",
3288
3288
  content: t.map(Ht)
3289
3289
  };
3290
- }, Fc = ({ title: e, isTitleVisible: t, isSubtitleVisible: r, subtitle: a }) => {
3291
- const { dispatch: o } = se(), i = M(() => ds({
3290
+ }, _c = ({ title: e, isTitleVisible: t, isSubtitleVisible: r, subtitle: a }) => {
3291
+ const { dispatch: o } = se(), i = M(() => cs({
3292
3292
  titlePlaceholder: "Untitled",
3293
3293
  subtitlePlaceholder: "Untitled",
3294
3294
  isTitleVisible: t,
@@ -3296,7 +3296,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3296
3296
  }), [t, r]);
3297
3297
  return /* @__PURE__ */ n($r, {
3298
3298
  editor: Ft({
3299
- content: M(() => Nc({
3299
+ content: M(() => Mc({
3300
3300
  title: e,
3301
3301
  isTitleVisible: t,
3302
3302
  subtitle: a,
@@ -3310,30 +3310,30 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3310
3310
  extensions: i,
3311
3311
  isEditable: !0,
3312
3312
  onUpdate: (l) => {
3313
- const s = Oc(l);
3313
+ const s = Nc(l);
3314
3314
  t && o(new cr({ title: s.title })), r && o(new sr({ subtitle: s.subtitle }));
3315
3315
  }
3316
3316
  }),
3317
3317
  ariaLabel: "Chart title and subtitle"
3318
3318
  });
3319
- }, Hc = {
3320
- Title: Fc,
3321
- Caption: Lc,
3322
- TextAnnotation: Ic
3323
- }, Bc = "data-graphy-chart-chrome", Vc = "data-graphy-chart-menu", Ur = { [Vc]: "" }, ot = (e) => ({ [Bc]: e }), $e = (e, t) => e instanceof Element && e.closest(`[data-graphy-chart-chrome="${CSS.escape(t)}"]`) !== null, Gc = (e) => e instanceof Element && e.closest("[data-graphy-chart-menu]") !== null, xt = (e) => e instanceof Element && e.closest("[data-graphy-chart-chrome]") !== null, Wr = (e, t, r) => r !== null && mr({
3319
+ }, Fc = {
3320
+ Title: _c,
3321
+ Caption: kc,
3322
+ TextAnnotation: Pc
3323
+ }, Hc = "data-graphy-chart-chrome", Bc = "data-graphy-chart-menu", Ur = { [Bc]: "" }, ot = (e) => ({ [Hc]: e }), Ue = (e, t) => e instanceof Element && e.closest(`[data-graphy-chart-chrome="${CSS.escape(t)}"]`) !== null, Vc = (e) => e instanceof Element && e.closest("[data-graphy-chart-menu]") !== null, xt = (e) => e instanceof Element && e.closest("[data-graphy-chart-chrome]") !== null, Wr = (e, t, r) => r !== null && mr({
3324
3324
  x: e.clientX - t.x,
3325
3325
  y: e.clientY - t.y
3326
- }, r), Me = (e, t, r) => e instanceof Node && (t.contains(e) || $e(e, r)), $c = "cml7ha0", Kr = Oe(null), Uc = ({ children: e }) => {
3326
+ }, r), Ne = (e, t, r) => e instanceof Node && (t.contains(e) || Ue(e, r)), Gc = "cml7ha0", Kr = Re(null), $c = ({ children: e }) => {
3327
3327
  const { chartId: t } = G(), [r] = Q(le), [a, o] = Q(null);
3328
3328
  return r === null ? null : /* @__PURE__ */ m(j, { children: [fr(/* @__PURE__ */ n("div", {
3329
3329
  ref: o,
3330
- className: $c,
3330
+ className: Gc,
3331
3331
  ...ot(t)
3332
3332
  }), r), /* @__PURE__ */ n(Kr.Provider, {
3333
3333
  value: a,
3334
3334
  children: e
3335
3335
  })] });
3336
- }, Bt = () => Le(Kr), qr = (e) => /* @__PURE__ */ m(x, {
3336
+ }, Bt = () => Pe(Kr), qr = (e) => /* @__PURE__ */ m(x, {
3337
3337
  viewBox: "0 0 16 16",
3338
3338
  ...e,
3339
3339
  children: [
@@ -3359,7 +3359,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
3359
3359
  })
3360
3360
  ]
3361
3361
  });
3362
- var Zr = "efjmb40", Xr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb44", Kc = "efjmb45", qc = /* @__PURE__ */ new Set([
3362
+ var Zr = "efjmb40", Xr = "efjmb41", Ce = "efjmb42", ye = "efjmb43", Uc = "efjmb44", Wc = "efjmb45", Kc = /* @__PURE__ */ new Set([
3363
3363
  "item-press",
3364
3364
  "escape-key",
3365
3365
  "outside-press",
@@ -3368,12 +3368,12 @@ var Zr = "efjmb40", Xr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb4
3368
3368
  "trigger-press"
3369
3369
  ]), Vt = ({ label: e, icon: t, onOpened: r, children: a }) => {
3370
3370
  const o = Bt(), [i, l] = Q(!1), s = (c, u) => {
3371
- c ? (l(!0), r?.()) : qc.has(u.reason) && l(!1);
3371
+ c ? (l(!0), r?.()) : Kc.has(u.reason) && l(!1);
3372
3372
  };
3373
3373
  return /* @__PURE__ */ m(me.SubmenuRoot, {
3374
3374
  open: i,
3375
3375
  onOpenChange: s,
3376
- children: [/* @__PURE__ */ n(Zc, {
3376
+ children: [/* @__PURE__ */ n(qc, {
3377
3377
  label: e,
3378
3378
  icon: t
3379
3379
  }), /* @__PURE__ */ n(me.Portal, {
@@ -3391,27 +3391,27 @@ var Zr = "efjmb40", Xr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb4
3391
3391
  }) })
3392
3392
  })]
3393
3393
  });
3394
- }, Zc = ({ label: e, icon: t }) => /* @__PURE__ */ m(me.SubmenuTrigger, {
3395
- className: be,
3394
+ }, qc = ({ label: e, icon: t }) => /* @__PURE__ */ m(me.SubmenuTrigger, {
3395
+ className: Ce,
3396
3396
  openOnHover: !1,
3397
3397
  children: [
3398
3398
  t,
3399
3399
  /* @__PURE__ */ n("span", {
3400
- className: Ce,
3400
+ className: ye,
3401
3401
  children: e
3402
3402
  }),
3403
3403
  /* @__PURE__ */ n("span", {
3404
- className: Kc,
3405
- children: /* @__PURE__ */ n(Re, { size: "sm" })
3404
+ className: Wc,
3405
+ children: /* @__PURE__ */ n(De, { size: "sm" })
3406
3406
  })
3407
3407
  ]
3408
- }), Xc = "_1qe7q450", jc = "_1qe7q451", Yc = "_1qe7q452", Jc = ({ label: e, placeholder: t, addLabel: r, at: a, onRequestClose: o }) => {
3408
+ }), Zc = "_1qe7q450", Xc = "_1qe7q451", jc = "_1qe7q452", Yc = ({ label: e, placeholder: t, addLabel: r, at: a, onRequestClose: o }) => {
3409
3409
  const i = te(null), [l, s] = Q(""), { dispatch: c } = se(), u = l.trim(), d = () => {
3410
3410
  u.length !== 0 && (c(new pe({
3411
3411
  kind: "comment",
3412
3412
  annotation: {
3413
3413
  at: a,
3414
- content: Qc(u)
3414
+ content: Jc(u)
3415
3415
  }
3416
3416
  })), o());
3417
3417
  };
@@ -3422,10 +3422,10 @@ var Zr = "efjmb40", Xr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb4
3422
3422
  requestAnimationFrame(() => i.current?.focus());
3423
3423
  },
3424
3424
  children: /* @__PURE__ */ m("div", {
3425
- className: Xc,
3425
+ className: Zc,
3426
3426
  children: [/* @__PURE__ */ n("input", {
3427
3427
  ref: i,
3428
- className: jc,
3428
+ className: Xc,
3429
3429
  value: l,
3430
3430
  placeholder: t,
3431
3431
  onChange: (g) => {
@@ -3436,14 +3436,14 @@ var Zr = "efjmb40", Xr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb4
3436
3436
  }
3437
3437
  }), /* @__PURE__ */ n("button", {
3438
3438
  type: "button",
3439
- className: Yc,
3439
+ className: jc,
3440
3440
  disabled: u.length === 0,
3441
3441
  onClick: d,
3442
3442
  children: r
3443
3443
  })]
3444
3444
  })
3445
3445
  });
3446
- }, Qc = (e) => ({
3446
+ }, Jc = (e) => ({
3447
3447
  type: "doc",
3448
3448
  content: [{
3449
3449
  type: "paragraph",
@@ -3452,7 +3452,7 @@ var Zr = "efjmb40", Xr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb4
3452
3452
  text: e
3453
3453
  }]
3454
3454
  }]
3455
- }), ed = (e) => /* @__PURE__ */ n(x, {
3455
+ }), Qc = (e) => /* @__PURE__ */ n(x, {
3456
3456
  viewBox: "0 0 15 14",
3457
3457
  ...e,
3458
3458
  children: /* @__PURE__ */ n("path", {
@@ -3460,8 +3460,8 @@ var Zr = "efjmb40", Xr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb4
3460
3460
  fill: "currentColor",
3461
3461
  fillOpacity: "0.8"
3462
3462
  })
3463
- }), td = "relative-difference", nd = ({ label: e, layer: t, at: r, onRequestClose: a }) => {
3464
- const { dispatch: o } = se(), i = _((c) => c.coordSystem), l = M(() => dl({
3463
+ }), ed = "relative-difference", td = ({ label: e, layer: t, at: r, onRequestClose: a }) => {
3464
+ const { dispatch: o } = se(), i = _((c) => c.coordSystem), l = M(() => cl({
3465
3465
  layer: t,
3466
3466
  at: r,
3467
3467
  coordSystem: i
@@ -3477,25 +3477,25 @@ var Zr = "efjmb40", Xr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb4
3477
3477
  annotation: {
3478
3478
  ...ar,
3479
3479
  ...l,
3480
- label: td
3480
+ label: ed
3481
3481
  }
3482
3482
  })), a();
3483
3483
  };
3484
3484
  return /* @__PURE__ */ m(z.Item, {
3485
- className: be,
3485
+ className: Ce,
3486
3486
  onClick: s,
3487
- children: [/* @__PURE__ */ n(ed, {}), /* @__PURE__ */ n("span", {
3488
- className: Ce,
3487
+ children: [/* @__PURE__ */ n(Qc, {}), /* @__PURE__ */ n("span", {
3488
+ className: ye,
3489
3489
  children: e
3490
3490
  })]
3491
3491
  });
3492
3492
  };
3493
- function rd(e, t) {
3494
- if (e.type === "polar" && !ad(t)) return [{
3493
+ function nd(e, t) {
3494
+ if (e.type === "polar" && !rd(t)) return [{
3495
3495
  scope: "series",
3496
3496
  labelKey: "pieSlice"
3497
3497
  }];
3498
- const r = sl(t.data, t.mapping);
3498
+ const r = ll(t.data, t.mapping);
3499
3499
  switch (t.geom) {
3500
3500
  case "bar": {
3501
3501
  const a = [{
@@ -3539,10 +3539,10 @@ function rd(e, t) {
3539
3539
  return [];
3540
3540
  }
3541
3541
  }
3542
- var ad = (e) => {
3543
- const t = Qi(e.mapping.x);
3542
+ var rd = (e) => {
3543
+ const t = Ji(e.mapping.x);
3544
3544
  return t !== null && t !== Go.x;
3545
- }, od = (e) => /* @__PURE__ */ m(x, {
3545
+ }, ad = (e) => /* @__PURE__ */ m(x, {
3546
3546
  viewBox: "0 0 16 16",
3547
3547
  ...e,
3548
3548
  children: [
@@ -3581,7 +3581,7 @@ var ad = (e) => {
3581
3581
  rx: ".533"
3582
3582
  })
3583
3583
  ]
3584
- }), id = (e) => /* @__PURE__ */ m(x, {
3584
+ }), od = (e) => /* @__PURE__ */ m(x, {
3585
3585
  viewBox: "0 0 16 16",
3586
3586
  ...e,
3587
3587
  children: [
@@ -3620,7 +3620,7 @@ var ad = (e) => {
3620
3620
  rx: ".533"
3621
3621
  })
3622
3622
  ]
3623
- }), ld = (e) => /* @__PURE__ */ m(x, {
3623
+ }), id = (e) => /* @__PURE__ */ m(x, {
3624
3624
  viewBox: "0 0 16 16",
3625
3625
  ...e,
3626
3626
  children: [
@@ -3659,7 +3659,7 @@ var ad = (e) => {
3659
3659
  rx: ".533"
3660
3660
  })
3661
3661
  ]
3662
- }), sd = (e) => /* @__PURE__ */ m(x, {
3662
+ }), ld = (e) => /* @__PURE__ */ m(x, {
3663
3663
  viewBox: "0 0 16 16",
3664
3664
  ...e,
3665
3665
  children: [
@@ -3679,7 +3679,7 @@ var ad = (e) => {
3679
3679
  d: "M11.733 10.074H16v5.408a.52.52 0 0 1-.518.518h-3.23a.52.52 0 0 1-.519-.518zM11.733 9.481H16V.52A.52.52 0 0 0 15.482 0h-3.23a.52.52 0 0 0-.519.519z"
3680
3680
  })
3681
3681
  ]
3682
- }), cd = (e) => /* @__PURE__ */ m(x, {
3682
+ }), sd = (e) => /* @__PURE__ */ m(x, {
3683
3683
  viewBox: "0 0 16 16",
3684
3684
  ...e,
3685
3685
  children: [
@@ -3713,7 +3713,7 @@ var ad = (e) => {
3713
3713
  d: "M5.29 6.62a1.3 1.3 0 0 1-.424-.075 1 1 0 0 1-.373-.244 1.2 1.2 0 0 1-.262-.45 2.1 2.1 0 0 1-.096-.699q0-.389.082-.693.083-.304.238-.514a1.05 1.05 0 0 1 .374-.322q.22-.11.492-.11.285 0 .505.112a.973.973 0 0 1 .526.744h-.54a.5.5 0 0 0-.17-.277.5.5 0 0 0-.321-.105.54.54 0 0 0-.485.273q-.168.273-.17.75h.021a.8.8 0 0 1 .188-.223.92.92 0 0 1 .569-.195.91.91 0 0 1 .813.477q.125.222.123.509 0 .297-.136.536a1 1 0 0 1-.383.372 1.15 1.15 0 0 1-.571.134m-.003-.443a.54.54 0 0 0 .288-.078.57.57 0 0 0 .2-.211.6.6 0 0 0 .073-.299.6.6 0 0 0-.07-.294.54.54 0 0 0-.484-.285.55.55 0 0 0-.403.173.596.596 0 0 0 .108.914.53.53 0 0 0 .288.08M6.88 6.579v-.396l1.05-1.03q.15-.15.25-.27a1 1 0 0 0 .151-.229.6.6 0 0 0 .05-.236.432.432 0 0 0-.244-.405.6.6 0 0 0-.258-.056q-.15 0-.261.062a.43.43 0 0 0-.175.173.56.56 0 0 0-.06.267H6.86q0-.288.132-.5a.9.9 0 0 1 .362-.33q.231-.117.532-.117.303 0 .534.114.23.114.358.312a.8.8 0 0 1 .128.452.9.9 0 0 1-.065.334q-.065.164-.229.363-.162.2-.456.483l-.522.53v.021h1.318v.458zM10.57 6.62a1.3 1.3 0 0 1-.423-.075 1 1 0 0 1-.373-.244 1.2 1.2 0 0 1-.263-.45 2.1 2.1 0 0 1-.096-.699q0-.389.083-.693t.238-.514a1.05 1.05 0 0 1 .374-.322q.219-.11.492-.11.285 0 .505.112a.973.973 0 0 1 .526.744h-.54a.5.5 0 0 0-.17-.277.5.5 0 0 0-.322-.105.54.54 0 0 0-.484.273q-.168.273-.17.75h.02a.8.8 0 0 1 .188-.223.92.92 0 0 1 .569-.195.91.91 0 0 1 .814.477q.125.222.123.509 0 .297-.136.536a1 1 0 0 1-.383.372 1.15 1.15 0 0 1-.572.134m-.002-.443a.54.54 0 0 0 .288-.078.57.57 0 0 0 .2-.211.6.6 0 0 0 .073-.299.6.6 0 0 0-.071-.294.54.54 0 0 0-.483-.285.54.54 0 0 0-.403.173.597.597 0 0 0 .107.914.53.53 0 0 0 .289.08"
3714
3714
  })
3715
3715
  ]
3716
- }), dd = (e) => /* @__PURE__ */ m(x, {
3716
+ }), cd = (e) => /* @__PURE__ */ m(x, {
3717
3717
  viewBox: "0 0 16 16",
3718
3718
  ...e,
3719
3719
  children: [
@@ -3754,7 +3754,7 @@ var ad = (e) => {
3754
3754
  fillOpacity: "0.8"
3755
3755
  })
3756
3756
  ]
3757
- }), ud = (e) => /* @__PURE__ */ m(x, {
3757
+ }), dd = (e) => /* @__PURE__ */ m(x, {
3758
3758
  viewBox: "0 0 16 16",
3759
3759
  ...e,
3760
3760
  children: [
@@ -3776,7 +3776,7 @@ var ad = (e) => {
3776
3776
  d: "M15.999 8a8 8 0 0 1-7.588 7.989l-.412.01V8z"
3777
3777
  })
3778
3778
  ]
3779
- }), hd = (e) => /* @__PURE__ */ m(x, {
3779
+ }), ud = (e) => /* @__PURE__ */ m(x, {
3780
3780
  viewBox: "0 0 16 16",
3781
3781
  ...e,
3782
3782
  children: [
@@ -3837,7 +3837,7 @@ var ad = (e) => {
3837
3837
  transform: "matrix(-1 0 0 1 15.933 .533)"
3838
3838
  })
3839
3839
  ]
3840
- }), pd = (e) => /* @__PURE__ */ m(x, {
3840
+ }), hd = (e) => /* @__PURE__ */ m(x, {
3841
3841
  viewBox: "0 0 16 16",
3842
3842
  ...e,
3843
3843
  children: [
@@ -3898,18 +3898,18 @@ var ad = (e) => {
3898
3898
  transform: "matrix(-1 0 0 1 15.933 .533)"
3899
3899
  })
3900
3900
  ]
3901
- }), md = {
3902
- bar: od,
3903
- barGroup: id,
3904
- barStack: sd,
3905
- barSeries: ld,
3906
- linePoint: cd,
3907
- lineSeries: dd,
3908
- scatterPoint: hd,
3909
- scatterSeries: pd,
3910
- pieSlice: ud
3901
+ }), pd = {
3902
+ bar: ad,
3903
+ barGroup: od,
3904
+ barStack: ld,
3905
+ barSeries: id,
3906
+ linePoint: sd,
3907
+ lineSeries: cd,
3908
+ scatterPoint: ud,
3909
+ scatterSeries: hd,
3910
+ pieSlice: dd
3911
3911
  }, jr = ({ labelKey: e }) => {
3912
- const t = md[e];
3912
+ const t = pd[e];
3913
3913
  return /* @__PURE__ */ n(t, {});
3914
3914
  }, Yr = (e) => /* @__PURE__ */ m(x, {
3915
3915
  viewBox: "0 0 16 16",
@@ -3924,22 +3924,22 @@ var ad = (e) => {
3924
3924
  fill: "currentColor",
3925
3925
  fillOpacity: "0.8"
3926
3926
  })]
3927
- }), gd = ({ label: e, options: t, onSelect: r }) => {
3927
+ }), md = ({ label: e, options: t, onSelect: r }) => {
3928
3928
  const a = k();
3929
3929
  return /* @__PURE__ */ n(Vt, {
3930
3930
  label: e,
3931
3931
  icon: /* @__PURE__ */ n(Yr, {}),
3932
3932
  children: t.map((o) => /* @__PURE__ */ m(me.Item, {
3933
- className: be,
3933
+ className: Ce,
3934
3934
  onClick: () => r(o.scope),
3935
3935
  children: [/* @__PURE__ */ n(jr, { labelKey: o.labelKey }), /* @__PURE__ */ n("span", {
3936
- className: Ce,
3936
+ className: ye,
3937
3937
  children: a(`graph.annotations.highlights.labels.${o.labelKey}`)
3938
3938
  })]
3939
3939
  }, o.scope))
3940
3940
  });
3941
- }, vd = ({ label: e, layer: t, observation: r, highlights: a, onRequestClose: o }) => {
3942
- const i = k(), { dispatch: l } = se(), s = _((p) => p.coordSystem), c = M(() => $i(t, r), [t, r]), u = M(() => rd(s, t), [s, t]), d = M(() => {
3941
+ }, gd = ({ label: e, layer: t, observation: r, highlights: a, onRequestClose: o }) => {
3942
+ const i = k(), { dispatch: l } = se(), s = _((p) => p.coordSystem), c = M(() => Gi(t, r), [t, r]), u = M(() => nd(s, t), [s, t]), d = M(() => {
3943
3943
  const p = new Set(a.map((g) => g.scope));
3944
3944
  return u.filter((g) => !p.has(g.scope));
3945
3945
  }, [u, a]), [h] = d;
@@ -3954,40 +3954,40 @@ var ad = (e) => {
3954
3954
  if (d.length === 1) {
3955
3955
  const p = u.length === 1 ? e : i("graph.annotations.baseMenu.highlightWithLabel", { label: i(`graph.annotations.highlights.labels.${h.labelKey}`) });
3956
3956
  return /* @__PURE__ */ m(me.Item, {
3957
- className: be,
3957
+ className: Ce,
3958
3958
  onClick: () => v(h.scope),
3959
3959
  children: [/* @__PURE__ */ n(jr, { labelKey: h.labelKey }), /* @__PURE__ */ n("span", {
3960
- className: Ce,
3960
+ className: ye,
3961
3961
  children: p
3962
3962
  })]
3963
3963
  });
3964
3964
  }
3965
- return /* @__PURE__ */ n(gd, {
3965
+ return /* @__PURE__ */ n(md, {
3966
3966
  label: e,
3967
3967
  options: d,
3968
3968
  onSelect: v
3969
3969
  });
3970
- }, fd = "_1aafi1g0", bd = "_1aafi1g1", Jr = ({ children: e }) => /* @__PURE__ */ m("span", {
3971
- className: fd,
3970
+ }, vd = "_1aafi1g0", fd = "_1aafi1g1", Jr = ({ children: e }) => /* @__PURE__ */ m("span", {
3971
+ className: vd,
3972
3972
  "aria-hidden": "true",
3973
- children: [e, /* @__PURE__ */ n("span", { className: bd })]
3974
- }), Cd = ({ label: e, highlights: t, onRequestClose: r }) => {
3973
+ children: [e, /* @__PURE__ */ n("span", { className: fd })]
3974
+ }), bd = ({ label: e, highlights: t, onRequestClose: r }) => {
3975
3975
  const { dispatch: a } = se(), o = t.at(-1);
3976
3976
  if (o === void 0) return null;
3977
3977
  const i = () => {
3978
3978
  a(new Xo({ id: o.id })), r();
3979
3979
  };
3980
3980
  return /* @__PURE__ */ m(z.Item, {
3981
- className: be,
3981
+ className: Ce,
3982
3982
  onClick: i,
3983
3983
  children: [/* @__PURE__ */ n(Jr, { children: /* @__PURE__ */ n(Yr, {}) }), /* @__PURE__ */ n("span", {
3984
- className: Ce,
3984
+ className: ye,
3985
3985
  children: e
3986
3986
  })]
3987
3987
  });
3988
- }, yd = (e, t) => {
3988
+ }, Cd = (e, t) => {
3989
3989
  const r = _((o) => o.spec.highlights), a = _((o) => o.config.parsingLocale);
3990
- return M(() => rl({
3990
+ return M(() => nl({
3991
3991
  layer: e,
3992
3992
  highlights: r,
3993
3993
  observation: t,
@@ -4021,7 +4021,7 @@ var ad = (e) => {
4021
4021
  fillOpacity: "0.8"
4022
4022
  })
4023
4023
  ]
4024
- }), Sd = ({ label: e, at: t, onRequestClose: r }) => {
4024
+ }), yd = ({ label: e, at: t, onRequestClose: r }) => {
4025
4025
  const { dispatch: a } = se(), o = () => {
4026
4026
  a(new pe({
4027
4027
  kind: "pinnedNumber",
@@ -4029,10 +4029,10 @@ var ad = (e) => {
4029
4029
  })), r();
4030
4030
  };
4031
4031
  return /* @__PURE__ */ m(z.Item, {
4032
- className: be,
4032
+ className: Ce,
4033
4033
  onClick: o,
4034
4034
  children: [/* @__PURE__ */ n(Qr, {}), /* @__PURE__ */ n("span", {
4035
- className: Ce,
4035
+ className: ye,
4036
4036
  children: e
4037
4037
  })]
4038
4038
  });
@@ -4083,19 +4083,19 @@ var ad = (e) => {
4083
4083
  labelKey: "graph.annotations.baseMenu.removeSticker"
4084
4084
  },
4085
4085
  image: null
4086
- }, xd = (e) => ul(e.kind) && ta[e.kind] !== null, wd = ({ attachment: e, onRequestClose: t }) => {
4086
+ }, Sd = (e) => dl(e.kind) && ta[e.kind] !== null, xd = ({ attachment: e, onRequestClose: t }) => {
4087
4087
  const r = k(), { dispatch: a } = se(), { icon: o, labelKey: i } = ta[e.kind], l = () => {
4088
4088
  a(new ke({ id: e.annotation.id })), t();
4089
4089
  };
4090
4090
  return /* @__PURE__ */ m(z.Item, {
4091
- className: be,
4091
+ className: Ce,
4092
4092
  onClick: l,
4093
4093
  children: [/* @__PURE__ */ n(Jr, { children: /* @__PURE__ */ n(o, {}) }), /* @__PURE__ */ n("span", {
4094
- className: Ce,
4094
+ className: ye,
4095
4095
  children: r(i)
4096
4096
  })]
4097
4097
  });
4098
- }, Td = "ceeojg0", Ad = "ceeojg1", kd = "ceeojg2", Ld = ({ label: e, at: t, onRequestClose: r }) => {
4098
+ }, wd = "ceeojg0", Td = "ceeojg1", Ad = "ceeojg2", kd = ({ label: e, at: t, onRequestClose: r }) => {
4099
4099
  const { dispatch: a } = se(), o = (i) => {
4100
4100
  a(new pe({
4101
4101
  kind: "sticker",
@@ -4112,26 +4112,26 @@ var ad = (e) => {
4112
4112
  label: e,
4113
4113
  icon: /* @__PURE__ */ n(ea, {}),
4114
4114
  children: /* @__PURE__ */ n("div", {
4115
- className: Td,
4115
+ className: wd,
4116
4116
  children: Object.entries(xo).map(([i, l]) => /* @__PURE__ */ n(me.Item, {
4117
- className: Ad,
4117
+ className: Td,
4118
4118
  "aria-label": i,
4119
4119
  onClick: () => o(i),
4120
4120
  children: /* @__PURE__ */ n("img", {
4121
- className: kd,
4121
+ className: Ad,
4122
4122
  src: l.src,
4123
4123
  alt: i
4124
4124
  })
4125
4125
  }, i))
4126
4126
  })
4127
4127
  });
4128
- }, Pd = ({ interaction: e, panelOrigin: t }) => {
4128
+ }, Ld = ({ interaction: e, panelOrigin: t }) => {
4129
4129
  const r = U(), a = X((i) => i.menuTrigger);
4130
4130
  if (e.kind !== "menu" || a === null) return null;
4131
4131
  const o = () => {
4132
4132
  r.getState().releaseInteraction("menu");
4133
4133
  };
4134
- return /* @__PURE__ */ n(Id, {
4134
+ return /* @__PURE__ */ n(Pd, {
4135
4135
  trigger: {
4136
4136
  x: t.x + a.center.x,
4137
4137
  y: t.y + a.center.y,
@@ -4142,13 +4142,13 @@ var ad = (e) => {
4142
4142
  observation: e.anchor.observation,
4143
4143
  onClose: o
4144
4144
  });
4145
- }, Id = ({ trigger: e, layer: t, at: r, observation: a, onClose: o }) => {
4146
- const i = k(), l = Bt(), s = _((C) => C.spec.annotations), c = _((C) => C.config.parsingLocale), u = Md(), { x: d, y: h, radius: v } = e, p = M(() => Ed(d, h, v), [
4145
+ }, Pd = ({ trigger: e, layer: t, at: r, observation: a, onClose: o }) => {
4146
+ const i = k(), l = Bt(), s = _((C) => C.spec.annotations), c = _((C) => C.config.parsingLocale), u = Ed(), { x: d, y: h, radius: v } = e, p = M(() => Id(d, h, v), [
4147
4147
  d,
4148
4148
  h,
4149
4149
  v
4150
- ]), g = ol(s, r, M(() => ji(t, c), [t, c])), f = g !== null && xd(g) ? g : null, y = yd(t, a), P = (C, A) => {
4151
- !C && Nd(A.reason) && o();
4150
+ ]), g = al(s, r, M(() => Xi(t, c), [t, c])), f = g !== null && Sd(g) ? g : null, y = Cd(t, a), P = (C, A) => {
4151
+ !C && Md(A.reason) && o();
4152
4152
  };
4153
4153
  return /* @__PURE__ */ n(z.Root, {
4154
4154
  open: u,
@@ -4167,43 +4167,43 @@ var ad = (e) => {
4167
4167
  className: Xr,
4168
4168
  "data-testid": "observation-menu",
4169
4169
  children: [
4170
- f !== null && /* @__PURE__ */ n(wd, {
4170
+ f !== null && /* @__PURE__ */ n(xd, {
4171
4171
  attachment: f,
4172
4172
  onRequestClose: o
4173
4173
  }),
4174
- /* @__PURE__ */ n(Cd, {
4174
+ /* @__PURE__ */ n(bd, {
4175
4175
  label: i("graph.annotations.baseMenu.removeHighlight"),
4176
4176
  highlights: y,
4177
4177
  onRequestClose: o
4178
4178
  }),
4179
- /* @__PURE__ */ n(z.Separator, { className: Wc }),
4179
+ /* @__PURE__ */ n(z.Separator, { className: Uc }),
4180
4180
  f === null && /* @__PURE__ */ m(j, { children: [
4181
- /* @__PURE__ */ n(Sd, {
4181
+ /* @__PURE__ */ n(yd, {
4182
4182
  label: i("graph.annotations.baseMenu.pinNumber"),
4183
4183
  at: r,
4184
4184
  onRequestClose: o
4185
4185
  }),
4186
- /* @__PURE__ */ n(Jc, {
4186
+ /* @__PURE__ */ n(Yc, {
4187
4187
  label: i("graph.annotations.baseMenu.annotate"),
4188
4188
  placeholder: i("graph.annotations.textMenu.placeholder"),
4189
4189
  addLabel: i("graph.annotations.textMenu.addButton"),
4190
4190
  at: r,
4191
4191
  onRequestClose: o
4192
4192
  }),
4193
- /* @__PURE__ */ n(Ld, {
4193
+ /* @__PURE__ */ n(kd, {
4194
4194
  label: i("graph.annotations.baseMenu.addSticker"),
4195
4195
  at: r,
4196
4196
  onRequestClose: o
4197
4197
  })
4198
4198
  ] }),
4199
- t.highlight !== null && /* @__PURE__ */ n(vd, {
4199
+ t.highlight !== null && /* @__PURE__ */ n(gd, {
4200
4200
  label: i("graph.annotations.baseMenu.highlight"),
4201
4201
  layer: t,
4202
4202
  observation: a,
4203
4203
  highlights: y,
4204
4204
  onRequestClose: o
4205
4205
  }),
4206
- /* @__PURE__ */ n(nd, {
4206
+ /* @__PURE__ */ n(td, {
4207
4207
  label: i("graph.annotations.baseMenu.differenceArrow"),
4208
4208
  layer: t,
4209
4209
  at: r,
@@ -4214,12 +4214,12 @@ var ad = (e) => {
4214
4214
  }) })
4215
4215
  })
4216
4216
  });
4217
- }, Ed = (e, t, r) => ({ getBoundingClientRect: () => new DOMRect(e - r, t - r, r * 2, r * 2) }), Md = () => {
4217
+ }, Id = (e, t, r) => ({ getBoundingClientRect: () => new DOMRect(e - r, t - r, r * 2, r * 2) }), Ed = () => {
4218
4218
  const [e, t] = Q(!1);
4219
4219
  return O(() => {
4220
4220
  t(!0);
4221
4221
  }, []), e;
4222
- }, Nd = (e) => e === "outside-press" || e === "escape-key" || e === "item-press", Gt = "l8tsqe0", na = ["start", "end"], ra = ({ anchor: e, point: t, delta: r }) => {
4222
+ }, Md = (e) => e === "outside-press" || e === "escape-key" || e === "item-press", Gt = "l8tsqe0", na = ["start", "end"], ra = ({ anchor: e, point: t, delta: r }) => {
4223
4223
  const a = {
4224
4224
  x: fn(t.x, r.x),
4225
4225
  y: fn(1 - t.y, r.y)
@@ -4241,22 +4241,22 @@ var ad = (e) => {
4241
4241
  ...e[t.endpoint],
4242
4242
  ...t.point
4243
4243
  }
4244
- }), aa = (e, t) => e.x === t.x && e.y === t.y, Od = (e, t) => {
4245
- const r = Ue(e, t);
4244
+ }), aa = (e, t) => e.x === t.x && e.y === t.y, Nd = (e, t) => {
4245
+ const r = We(e, t);
4246
4246
  return {
4247
4247
  x: t.x + r.x,
4248
4248
  y: t.y + r.y
4249
4249
  };
4250
- }, Rd = (e, t, r) => {
4251
- const a = Ue(e, r), o = Ue(t, r);
4250
+ }, Od = (e, t, r) => {
4251
+ const a = We(e, r), o = We(t, r);
4252
4252
  return {
4253
4253
  x: Math.min(a.x, o.x),
4254
4254
  y: Math.min(a.y, o.y),
4255
4255
  width: Math.abs(o.x - a.x),
4256
4256
  height: Math.abs(o.y - a.y)
4257
4257
  };
4258
- }, fn = (e, t) => !Number.isFinite(t) || !Number.isFinite(e) ? 0 : Ke(t, Math.min(-e, 0), Math.max(1 - e, 0)), Dd = ({ panelRect: e }) => {
4259
- const t = X((s) => V(s, "arrow-endpoint-drag")), r = fe(e).arrows, a = Nt();
4258
+ }, fn = (e, t) => !Number.isFinite(t) || !Number.isFinite(e) ? 0 : qe(t, Math.min(-e, 0), Math.max(1 - e, 0)), Rd = ({ panelRect: e }) => {
4259
+ const t = X((s) => V(s, "arrow-endpoint-drag")), r = be(e).arrows, a = Nt();
4260
4260
  if (t === null) return null;
4261
4261
  const o = r.find((s) => s.id === t.annotationId);
4262
4262
  if (o === void 0) return null;
@@ -4283,14 +4283,14 @@ var ad = (e) => {
4283
4283
  isAddressable: !1
4284
4284
  })
4285
4285
  });
4286
- }, De = () => {
4286
+ }, ze = () => {
4287
4287
  const e = Jn();
4288
4288
  return wt(e);
4289
4289
  }, wt = (e) => {
4290
4290
  if (e.length !== 1) return null;
4291
4291
  const [t] = e;
4292
4292
  return t?.kind === "annotation" ? t.id : null;
4293
- }, zd = (e) => /* @__PURE__ */ n(x, {
4293
+ }, Dd = (e) => /* @__PURE__ */ n(x, {
4294
4294
  ...e,
4295
4295
  children: /* @__PURE__ */ m("g", {
4296
4296
  stroke: "currentColor",
@@ -4308,7 +4308,7 @@ var ad = (e) => {
4308
4308
  strokeLinejoin: "round",
4309
4309
  children: [/* @__PURE__ */ n("path", { d: "M5 12h14" }), /* @__PURE__ */ n("path", { d: "m12 5 7 7-7 7" })]
4310
4310
  })
4311
- }), _d = (e) => /* @__PURE__ */ n(x, {
4311
+ }), zd = (e) => /* @__PURE__ */ n(x, {
4312
4312
  ...e,
4313
4313
  children: /* @__PURE__ */ m("g", {
4314
4314
  stroke: "currentColor",
@@ -4359,23 +4359,23 @@ var ad = (e) => {
4359
4359
  /* @__PURE__ */ n("path", { d: "M9 7V5a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v2" })
4360
4360
  ]
4361
4361
  })
4362
- }), Fd = "var(--pvjfpx0)", Hd = "var(--pvjfpx1)", Bd = "pvjfpx2", Vd = "pvjfpx3", Gd = "pvjfpx4", $d = "pvjfpx6 pvjfpx5", Ud = "pvjfpx7 pvjfpx6 pvjfpx5", Wd = "pvjfpx8 pvjfpx5", Ie = 8, Kd = ({ anchorBox: e, panelRect: t, frameWidth: r, frameHeight: a }) => {
4363
- const o = t.y + e.y, i = o + e.height, l = o - 8 - 36, s = i + 8, c = Ke(l >= Ie ? l : s, Ie, a - Ie - 36), u = Ie;
4362
+ }), _d = "var(--pvjfpx0)", Fd = "var(--pvjfpx1)", Hd = "pvjfpx2", Bd = "pvjfpx3", Vd = "pvjfpx4", Gd = "pvjfpx6 pvjfpx5", $d = "pvjfpx7 pvjfpx6 pvjfpx5", Ud = "pvjfpx8 pvjfpx5", Ee = 8, Wd = ({ anchorBox: e, panelRect: t, frameWidth: r, frameHeight: a }) => {
4363
+ const o = t.y + e.y, i = o + e.height, l = o - 8 - 36, s = i + 8, c = qe(l >= Ee ? l : s, Ee, a - Ee - 36), u = Ee;
4364
4364
  return {
4365
4365
  top: c,
4366
4366
  left: u,
4367
- available: Math.max(0, r - Ie * 2),
4367
+ available: Math.max(0, r - Ee * 2),
4368
4368
  centre: t.x + e.x + e.width / 2 - u
4369
4369
  };
4370
- }, qd = ({ anchorBox: e, panelRect: t, frameWidth: r, frameHeight: a, label: o, testId: i, children: l }) => {
4371
- const { chartId: s } = G(), c = Kd({
4370
+ }, Kd = ({ anchorBox: e, panelRect: t, frameWidth: r, frameHeight: a, label: o, testId: i, children: l }) => {
4371
+ const { chartId: s } = G(), c = Wd({
4372
4372
  anchorBox: e,
4373
4373
  panelRect: t,
4374
4374
  frameWidth: r,
4375
4375
  frameHeight: a
4376
4376
  });
4377
4377
  return /* @__PURE__ */ n("div", {
4378
- className: Bd,
4378
+ className: Hd,
4379
4379
  style: {
4380
4380
  top: c.top,
4381
4381
  left: c.left,
@@ -4383,17 +4383,17 @@ var ad = (e) => {
4383
4383
  },
4384
4384
  children: /* @__PURE__ */ n(K.Root, {
4385
4385
  "aria-label": o,
4386
- className: Vd,
4386
+ className: Bd,
4387
4387
  "data-testid": i,
4388
4388
  ...ot(s),
4389
4389
  style: br({
4390
- [Fd]: `${c.centre}px`,
4391
- [Hd]: `${c.available}px`
4390
+ [_d]: `${c.centre}px`,
4391
+ [Fd]: `${c.available}px`
4392
4392
  }),
4393
4393
  children: l
4394
4394
  })
4395
4395
  });
4396
- }, Zd = ({ label: e, trigger: t, isOpen: r, onOpenChange: a, isDisabled: o = !1, children: i }) => {
4396
+ }, qd = ({ label: e, trigger: t, isOpen: r, onOpenChange: a, isDisabled: o = !1, children: i }) => {
4397
4397
  const { chartId: l } = G();
4398
4398
  return /* @__PURE__ */ m(z.Root, {
4399
4399
  open: r,
@@ -4402,53 +4402,53 @@ var ad = (e) => {
4402
4402
  children: [/* @__PURE__ */ m(z.Trigger, {
4403
4403
  render: /* @__PURE__ */ n(K.Button, {}),
4404
4404
  "aria-label": e,
4405
- className: Wd,
4405
+ className: Ud,
4406
4406
  disabled: o,
4407
4407
  onMouseDown: (s) => s.preventDefault(),
4408
- children: [t, /* @__PURE__ */ n(Re, { size: "sm" })]
4408
+ children: [t, /* @__PURE__ */ n(De, { size: "sm" })]
4409
4409
  }), /* @__PURE__ */ n(K.MenuPopup, {
4410
4410
  popupAttributes: ot(l),
4411
4411
  children: i
4412
4412
  })]
4413
4413
  });
4414
- }, Xd = (e) => {
4414
+ }, Zd = (e) => {
4415
4415
  const { chartId: t } = G();
4416
4416
  return /* @__PURE__ */ n(K.ColorPicker, {
4417
4417
  ...e,
4418
4418
  popupAttributes: ot(t)
4419
4419
  });
4420
- }, jd = ({ color: e, opacity: t }) => /* @__PURE__ */ n("span", {
4421
- className: Gd,
4420
+ }, Xd = ({ color: e, opacity: t }) => /* @__PURE__ */ n("span", {
4421
+ className: Vd,
4422
4422
  style: {
4423
4423
  background: e,
4424
4424
  opacity: t
4425
4425
  }
4426
- }), Yd = ({ label: e, onClick: t, children: r }) => /* @__PURE__ */ n(K.Button, {
4426
+ }), jd = ({ label: e, onClick: t, children: r }) => /* @__PURE__ */ n(K.Button, {
4427
4427
  "aria-label": e,
4428
- className: $d,
4428
+ className: Gd,
4429
4429
  onClick: t,
4430
4430
  children: r
4431
- }), Jd = ({ label: e, isPressed: t, onClick: r, children: a }) => /* @__PURE__ */ n(K.Button, {
4431
+ }), Yd = ({ label: e, isPressed: t, onClick: r, children: a }) => /* @__PURE__ */ n(K.Button, {
4432
4432
  "aria-label": e,
4433
4433
  "aria-pressed": t,
4434
- className: Ud,
4434
+ className: $d,
4435
4435
  onClick: r,
4436
4436
  children: a
4437
4437
  }), I = {
4438
- Root: qd,
4439
- Dropdown: Zd,
4438
+ Root: Kd,
4439
+ Dropdown: qd,
4440
4440
  MenuItem: K.MenuItem,
4441
- ColorPicker: Xd,
4442
- Swatch: jd,
4443
- IconButton: Yd,
4444
- ToggleButton: Jd,
4441
+ ColorPicker: Zd,
4442
+ Swatch: Xd,
4443
+ IconButton: jd,
4444
+ ToggleButton: Yd,
4445
4445
  Button: K.Button,
4446
4446
  Separator: K.Separator
4447
- }, Qd = { kind: "chrome-popup" }, lt = () => {
4447
+ }, Jd = { kind: "chrome-popup" }, lt = () => {
4448
4448
  const { commands: e } = G(), t = U(), [r, a] = Q(null);
4449
4449
  O(() => () => e.seal(), [e]), O(() => {
4450
4450
  const { claimInteraction: i, releaseInteraction: l } = t.getState();
4451
- return r === null ? l("chrome-popup") : i(Qd), () => l("chrome-popup");
4451
+ return r === null ? l("chrome-popup") : i(Jd), () => l("chrome-popup");
4452
4452
  }, [t, r]);
4453
4453
  const o = () => {
4454
4454
  a(null), e.seal();
@@ -4460,7 +4460,7 @@ var ad = (e) => {
4460
4460
  }),
4461
4461
  close: o
4462
4462
  };
4463
- }, eu = (e) => /* @__PURE__ */ n(x, {
4463
+ }, Qd = (e) => /* @__PURE__ */ n(x, {
4464
4464
  ...e,
4465
4465
  children: /* @__PURE__ */ m("g", {
4466
4466
  stroke: "currentColor",
@@ -4472,7 +4472,7 @@ var ad = (e) => {
4472
4472
  /* @__PURE__ */ n("path", { d: "M16 8 19 5" })
4473
4473
  ]
4474
4474
  })
4475
- }), tu = (e) => /* @__PURE__ */ n(x, {
4475
+ }), eu = (e) => /* @__PURE__ */ n(x, {
4476
4476
  ...e,
4477
4477
  children: /* @__PURE__ */ m("g", {
4478
4478
  stroke: "currentColor",
@@ -4486,7 +4486,7 @@ var ad = (e) => {
4486
4486
  /* @__PURE__ */ n("path", { d: "M19 5h0" })
4487
4487
  ]
4488
4488
  })
4489
- }), nu = (e) => /* @__PURE__ */ n(x, {
4489
+ }), tu = (e) => /* @__PURE__ */ n(x, {
4490
4490
  ...e,
4491
4491
  children: /* @__PURE__ */ n("path", {
4492
4492
  d: "M5 19 19 5",
@@ -4494,7 +4494,7 @@ var ad = (e) => {
4494
4494
  strokeWidth: 2,
4495
4495
  strokeLinecap: "round"
4496
4496
  })
4497
- }), ru = [
4497
+ }), nu = [
4498
4498
  {
4499
4499
  value: pt.thin,
4500
4500
  key: "graph.annotations.arrowToolbar.thickness.thin"
@@ -4519,27 +4519,27 @@ var ad = (e) => {
4519
4519
  {
4520
4520
  value: "solid",
4521
4521
  key: "graph.annotations.arrowToolbar.lineStyle.solid",
4522
- Icon: nu
4522
+ Icon: tu
4523
4523
  },
4524
4524
  {
4525
4525
  value: "dashed",
4526
4526
  key: "graph.annotations.arrowToolbar.lineStyle.dashed",
4527
- Icon: eu
4527
+ Icon: Qd
4528
4528
  },
4529
4529
  {
4530
4530
  value: "dotted",
4531
4531
  key: "graph.annotations.arrowToolbar.lineStyle.dotted",
4532
- Icon: tu
4532
+ Icon: eu
4533
4533
  }
4534
- ], au = (e, t) => e.find((r) => r.value === t) ?? e[0];
4535
- var ou = ({ arrow: e, arrowBox: t, panelRect: r, frameWidth: a, frameHeight: o, frameElement: i }) => {
4536
- const l = k(), { commands: s } = G(), c = _((E) => E.spec.styles.overrides), u = lt(), d = Nt()(e.id), h = au(Cn, d.lineType), v = d.borderWidth > 0 || d.shadow !== "none", p = M(() => ({
4534
+ ], ru = (e, t) => e.find((r) => r.value === t) ?? e[0];
4535
+ var au = ({ arrow: e, arrowBox: t, panelRect: r, frameWidth: a, frameHeight: o, frameElement: i }) => {
4536
+ const l = k(), { commands: s } = G(), c = _((E) => E.spec.styles.overrides), u = lt(), d = Nt()(e.id), h = ru(Cn, d.lineType), v = d.borderWidth > 0 || d.shadow !== "none", p = M(() => ({
4537
4537
  target: "annotation",
4538
4538
  kind: "arrow",
4539
4539
  annotation: e.id
4540
4540
  }), [e.id]), g = (E, N) => {
4541
- const T = Te(c, { select: p })?.declarations ?? {};
4542
- s.dispatch(new Ne({
4541
+ const T = fe(c, { select: p })?.declarations ?? {};
4542
+ s.dispatch(new Le({
4543
4543
  list: "overrides",
4544
4544
  rule: {
4545
4545
  select: p,
@@ -4585,20 +4585,20 @@ var ou = ({ arrow: e, arrowBox: t, panelRect: r, frameWidth: a, frameHeight: o,
4585
4585
  title: ""
4586
4586
  }),
4587
4587
  ...u.bind("thickness"),
4588
- children: /* @__PURE__ */ n(Be, {
4589
- options: ru,
4588
+ children: /* @__PURE__ */ n(Ve, {
4589
+ options: nu,
4590
4590
  current: d.strokeWidth,
4591
4591
  onPick: A
4592
4592
  })
4593
4593
  }),
4594
4594
  /* @__PURE__ */ n(I.Dropdown, {
4595
4595
  label: l("graph.annotations.arrowToolbar.startArrowhead"),
4596
- trigger: /* @__PURE__ */ n(zd, {
4596
+ trigger: /* @__PURE__ */ n(Dd, {
4597
4597
  size: "sm",
4598
4598
  title: ""
4599
4599
  }),
4600
4600
  ...u.bind("startArrowhead"),
4601
- children: /* @__PURE__ */ n(Be, {
4601
+ children: /* @__PURE__ */ n(Ve, {
4602
4602
  options: bn,
4603
4603
  current: e.startArrowheadStyle,
4604
4604
  onPick: L
@@ -4611,7 +4611,7 @@ var ou = ({ arrow: e, arrowBox: t, panelRect: r, frameWidth: a, frameHeight: o,
4611
4611
  title: ""
4612
4612
  }),
4613
4613
  ...u.bind("lineStyle"),
4614
- children: /* @__PURE__ */ n(Be, {
4614
+ children: /* @__PURE__ */ n(Ve, {
4615
4615
  options: Cn,
4616
4616
  current: d.lineType,
4617
4617
  onPick: R
@@ -4624,7 +4624,7 @@ var ou = ({ arrow: e, arrowBox: t, panelRect: r, frameWidth: a, frameHeight: o,
4624
4624
  title: ""
4625
4625
  }),
4626
4626
  ...u.bind("endArrowhead"),
4627
- children: /* @__PURE__ */ n(Be, {
4627
+ children: /* @__PURE__ */ n(Ve, {
4628
4628
  options: bn,
4629
4629
  current: e.endArrowheadStyle,
4630
4630
  onPick: F
@@ -4634,7 +4634,7 @@ var ou = ({ arrow: e, arrowBox: t, panelRect: r, frameWidth: a, frameHeight: o,
4634
4634
  label: l("graph.annotations.arrowToolbar.sticker"),
4635
4635
  isPressed: v,
4636
4636
  onClick: D,
4637
- children: /* @__PURE__ */ n(_d, {
4637
+ children: /* @__PURE__ */ n(zd, {
4638
4638
  size: "sm",
4639
4639
  title: ""
4640
4640
  })
@@ -4650,7 +4650,7 @@ var ou = ({ arrow: e, arrowBox: t, panelRect: r, frameWidth: a, frameHeight: o,
4650
4650
  })
4651
4651
  ]
4652
4652
  });
4653
- }, Be = ({ options: e, current: t, onPick: r }) => {
4653
+ }, Ve = ({ options: e, current: t, onPick: r }) => {
4654
4654
  const a = k(), o = (i) => () => r(i);
4655
4655
  return /* @__PURE__ */ n(j, { children: e.map((i) => /* @__PURE__ */ m(I.MenuItem, {
4656
4656
  isSelected: i.value === t,
@@ -4663,14 +4663,14 @@ var ou = ({ arrow: e, arrowBox: t, panelRect: r, frameWidth: a, frameHeight: o,
4663
4663
  })
4664
4664
  })]
4665
4665
  }, String(i.value))) });
4666
- }, iu = "_1me29t10", ne = (e, t) => t > 0 ? e / t : 0, st = (e, t, r) => ({
4666
+ }, ou = "_1me29t10", ne = (e, t) => t > 0 ? e / t : 0, st = (e, t, r) => ({
4667
4667
  x: ne(t.x - e.x, r.width),
4668
4668
  y: ne(t.y - e.y, r.height)
4669
- }), lu = (e) => e.x !== 0 || e.y !== 0, la = (e, t) => ({
4669
+ }), iu = (e) => e.x !== 0 || e.y !== 0, la = (e, t) => ({
4670
4670
  x: e.x * t.width,
4671
4671
  y: e.y * t.height
4672
4672
  });
4673
- var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4673
+ var lu = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, _e = class {
4674
4674
  constructor(e) {
4675
4675
  this.params = e, this.listeners = new AbortController(), this.pendingEvent = null, this.scheduledFrame = null, this.hasMoved = !1, this.hasPublished = !1, this.handleMove = (t) => {
4676
4676
  t.pointerId === this.params.pointerId && (this.pendingEvent = t, this.hasMoved = !0, this.scheduledFrame === null && (this.scheduledFrame = requestAnimationFrame(this.runFrame)));
@@ -4706,7 +4706,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4706
4706
  }
4707
4707
  }
4708
4708
  isDragConfirmed(e, t) {
4709
- return su(e, t);
4709
+ return lu(e, t);
4710
4710
  }
4711
4711
  settle(e) {
4712
4712
  this.pendingEvent = null;
@@ -4716,12 +4716,12 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4716
4716
  cancelFrame() {
4717
4717
  this.scheduledFrame !== null && (cancelAnimationFrame(this.scheduledFrame), this.scheduledFrame = null);
4718
4718
  }
4719
- }, Ze = (e, t, r) => {
4719
+ }, Xe = (e, t, r) => {
4720
4720
  const a = e.arrows.find((i) => i.id === t);
4721
4721
  if (a === void 0) return null;
4722
4722
  const o = a[r];
4723
4723
  return o.anchorType === "panel" ? o : null;
4724
- }, sa = (e, t) => e === "start" ? { start: t } : { end: t }, cu = class extends ze {
4724
+ }, sa = (e, t) => e === "start" ? { start: t } : { end: t }, su = class extends _e {
4725
4725
  constructor(...e) {
4726
4726
  super(...e), this.kind = "arrow-endpoint-drag";
4727
4727
  }
@@ -4730,7 +4730,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4730
4730
  return Mt(V(e, "arrow-endpoint-drag"), t, r);
4731
4731
  }
4732
4732
  resolvePreview(e) {
4733
- const { annotationId: t, endpoint: r, press: a, readInputs: o } = this.params, { annotations: i, arrow: l, panelRect: s } = o(), c = Ze(i, t, r);
4733
+ const { annotationId: t, endpoint: r, press: a, readInputs: o } = this.params, { annotations: i, arrow: l, panelRect: s } = o(), c = Xe(i, t, r);
4734
4734
  return c === null ? null : {
4735
4735
  kind: "arrow-endpoint-drag",
4736
4736
  annotationId: t,
@@ -4743,14 +4743,14 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4743
4743
  };
4744
4744
  }
4745
4745
  commit({ anchor: e }) {
4746
- const { annotationId: t, endpoint: r, dispatch: a, readInputs: o } = this.params, i = Ze(o().annotations, t, r);
4746
+ const { annotationId: t, endpoint: r, dispatch: a, readInputs: o } = this.params, i = Xe(o().annotations, t, r);
4747
4747
  i === null || aa(i, e) || a(new re({
4748
4748
  kind: "arrow",
4749
4749
  id: t,
4750
4750
  patch: sa(r, e)
4751
4751
  }));
4752
4752
  }
4753
- }, du = ({ annotationId: e, arrow: t, panelRect: r }) => {
4753
+ }, cu = ({ annotationId: e, arrow: t, panelRect: r }) => {
4754
4754
  const { commands: a } = G(), o = U(), i = J({
4755
4755
  annotations: _((s) => s.spec.annotations),
4756
4756
  arrow: t,
@@ -4763,7 +4763,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4763
4763
  } catch {
4764
4764
  return;
4765
4765
  }
4766
- c.currentTarget.focus({ preventScroll: !0 }), c.preventDefault(), l.current = new cu({
4766
+ c.currentTarget.focus({ preventScroll: !0 }), c.preventDefault(), l.current = new su({
4767
4767
  handle: c.currentTarget,
4768
4768
  pointerId: c.pointerId,
4769
4769
  annotationId: e,
@@ -4786,7 +4786,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4786
4786
  o,
4787
4787
  a
4788
4788
  ]);
4789
- }, uu = [" ", "Enter"], yn = 4, hu = ({ annotationId: e, arrow: t, panelRect: r }) => {
4789
+ }, du = [" ", "Enter"], yn = 4, uu = ({ annotationId: e, arrow: t, panelRect: r }) => {
4790
4790
  const { commands: a } = G(), o = U(), i = _((c) => c.spec.annotations), l = J(i), s = J(a.dispatch);
4791
4791
  return O(() => () => {
4792
4792
  for (const c of na) Sn({
@@ -4804,7 +4804,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4804
4804
  ]), ie((c) => ({ onKeyDown: (u) => {
4805
4805
  if (u.altKey || u.ctrlKey || u.metaKey || u.shiftKey) return;
4806
4806
  const d = o.getState(), h = Mt(V(d, "arrow-endpoint-drag"), e, c);
4807
- if (uu.includes(u.key)) {
4807
+ if (du.includes(u.key)) {
4808
4808
  if (u.preventDefault(), u.repeat) return;
4809
4809
  if (h !== null) {
4810
4810
  Sn({
@@ -4816,7 +4816,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4816
4816
  });
4817
4817
  return;
4818
4818
  }
4819
- const p = Ze(i, e, c);
4819
+ const p = Xe(i, e, c);
4820
4820
  if (p === null) return;
4821
4821
  d.claimInteraction({
4822
4822
  kind: "arrow-endpoint-drag",
@@ -4828,7 +4828,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4828
4828
  return;
4829
4829
  }
4830
4830
  if (h === null) return;
4831
- const v = pu(u.key, r);
4831
+ const v = hu(u.key, r);
4832
4832
  v !== null && (u.preventDefault(), d.claimInteraction({
4833
4833
  kind: "arrow-endpoint-drag",
4834
4834
  annotationId: e,
@@ -4851,13 +4851,13 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4851
4851
  const i = e.getState(), l = Mt(V(i, "arrow-endpoint-drag"), t, r);
4852
4852
  if (l === null) return;
4853
4853
  i.releaseInteraction("arrow-endpoint-drag");
4854
- const s = Ze(a, t, r);
4854
+ const s = Xe(a, t, r);
4855
4855
  s === null || aa(s, l.anchor) || o(new re({
4856
4856
  kind: "arrow",
4857
4857
  id: t,
4858
4858
  patch: sa(r, l.anchor)
4859
4859
  }));
4860
- }, pu = (e, t) => {
4860
+ }, hu = (e, t) => {
4861
4861
  const r = ne(yn, t.width), a = ne(yn, t.height);
4862
4862
  switch (e) {
4863
4863
  case "ArrowLeft":
@@ -4883,11 +4883,11 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4883
4883
  default:
4884
4884
  return null;
4885
4885
  }
4886
- }, mu = (e) => {
4887
- const t = De(), r = fu(t), a = bu(e.panelRect, t), o = Cu(t);
4886
+ }, pu = (e) => {
4887
+ const t = ze(), r = vu(t), a = fu(e.panelRect, t), o = bu(t);
4888
4888
  if (r === null || a === null) return null;
4889
4889
  const i = o.dragged === null ? a : $t(a, o.dragged);
4890
- return /* @__PURE__ */ n(gu, {
4890
+ return /* @__PURE__ */ n(mu, {
4891
4891
  arrow: r,
4892
4892
  committed: a,
4893
4893
  painted: i,
@@ -4895,12 +4895,12 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4895
4895
  isMoved: o.isMoved,
4896
4896
  ...e
4897
4897
  });
4898
- }, gu = ({ arrow: e, committed: t, painted: r, isSettled: a, isMoved: o, panelRect: i, frameRect: l, frameElement: s }) => {
4899
- const c = k(), u = du({
4898
+ }, mu = ({ arrow: e, committed: t, painted: r, isSettled: a, isMoved: o, panelRect: i, frameRect: l, frameElement: s }) => {
4899
+ const c = k(), u = cu({
4900
4900
  annotationId: e.id,
4901
4901
  arrow: t,
4902
4902
  panelRect: i
4903
- }), d = hu({
4903
+ }), d = uu({
4904
4904
  annotationId: e.id,
4905
4905
  arrow: t,
4906
4906
  panelRect: i
@@ -4908,24 +4908,24 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4908
4908
  return /* @__PURE__ */ m("div", {
4909
4909
  "data-testid": "arrow-selection",
4910
4910
  "data-annotation-id": e.id,
4911
- children: [a && /* @__PURE__ */ n(ou, {
4911
+ children: [a && /* @__PURE__ */ n(au, {
4912
4912
  arrow: e,
4913
- arrowBox: Rd(t.start, t.end, i),
4913
+ arrowBox: Od(t.start, t.end, i),
4914
4914
  panelRect: i,
4915
4915
  frameWidth: l.width,
4916
4916
  frameHeight: l.height,
4917
4917
  frameElement: s
4918
- }), !o && na.filter((h) => e[h].anchorType === "panel").map((h) => /* @__PURE__ */ n(vu, {
4918
+ }), !o && na.filter((h) => e[h].anchorType === "panel").map((h) => /* @__PURE__ */ n(gu, {
4919
4919
  endpoint: h,
4920
- point: Od(r[h], i),
4920
+ point: Nd(r[h], i),
4921
4921
  label: c(`graph.annotations.arrowToolbar.moveEndpoint.${h}`),
4922
4922
  dragHandlers: u(h),
4923
4923
  keyboardHandlers: d(h)
4924
4924
  }, h))]
4925
4925
  });
4926
- }, vu = ({ endpoint: e, point: t, label: r, dragHandlers: a, keyboardHandlers: o }) => /* @__PURE__ */ n("div", {
4926
+ }, gu = ({ endpoint: e, point: t, label: r, dragHandlers: a, keyboardHandlers: o }) => /* @__PURE__ */ n("div", {
4927
4927
  "aria-label": r,
4928
- className: iu,
4928
+ className: ou,
4929
4929
  "data-testid": "arrow-endpoint-handle",
4930
4930
  "data-endpoint": e,
4931
4931
  role: "button",
@@ -4936,13 +4936,13 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4936
4936
  tabIndex: 0,
4937
4937
  ...a,
4938
4938
  ...o
4939
- }), fu = (e) => {
4939
+ }), vu = (e) => {
4940
4940
  const t = _((r) => r.spec.annotations.arrows);
4941
4941
  return e === null ? null : t.find((r) => r.id === e) ?? null;
4942
- }, bu = (e, t) => {
4943
- const r = fe(e).arrows;
4942
+ }, fu = (e, t) => {
4943
+ const r = be(e).arrows;
4944
4944
  return t === null ? null : r.find((a) => a.id === t) ?? null;
4945
- }, Cu = (e) => X(Pe((t) => {
4945
+ }, bu = (e) => X(Ie((t) => {
4946
4946
  if (e === null) return {
4947
4947
  dragged: null,
4948
4948
  isMoved: !1
@@ -4950,9 +4950,9 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4950
4950
  const r = V(t, "arrow-endpoint-drag");
4951
4951
  return {
4952
4952
  dragged: r?.annotationId === e ? r : null,
4953
- isMoved: et(V(t, "move-drag"), e) !== null
4953
+ isMoved: tt(V(t, "move-drag"), e) !== null
4954
4954
  };
4955
- })), yu = (e) => /* @__PURE__ */ n(x, {
4955
+ })), Cu = (e) => /* @__PURE__ */ n(x, {
4956
4956
  ...e,
4957
4957
  children: /* @__PURE__ */ m("g", {
4958
4958
  stroke: "currentColor",
@@ -4961,23 +4961,23 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
4961
4961
  strokeLinejoin: "round",
4962
4962
  children: [/* @__PURE__ */ n("path", { d: "M4 9h16m-4-4 4 4" }), /* @__PURE__ */ n("path", { d: "M20 15H4m4 4-4-4" })]
4963
4963
  })
4964
- }), Su = "q7gcrz0", xu = "q7gcrz1", wu = "q7gcrz2";
4965
- var Tu = [
4964
+ }), yu = "q7gcrz0", Su = "q7gcrz1", xu = "q7gcrz2";
4965
+ var wu = [
4966
4966
  "absolute-difference",
4967
4967
  "relative-difference",
4968
4968
  "proportion"
4969
- ], xn = ["absolute-difference", "relative-difference"], Au = ["relative-difference", "proportion"], ku = {
4969
+ ], xn = ["absolute-difference", "relative-difference"], Tu = ["relative-difference", "proportion"], Au = {
4970
4970
  "absolute-difference": "graph.annotations.differenceArrowToolbar.labelKind.absoluteDifference",
4971
4971
  "relative-difference": "graph.annotations.differenceArrowToolbar.labelKind.relativeDifference",
4972
4972
  proportion: "graph.annotations.differenceArrowToolbar.labelKind.proportion"
4973
- }, Lu = (e) => {
4973
+ }, ku = (e) => {
4974
4974
  const { formattingLocale: t } = G(), r = _((o) => o.config.parsingLocale), a = t ?? r;
4975
4975
  return M(() => {
4976
- const o = Bi(e.start, e.end);
4977
- return Tu.filter((i) => o || !xn.includes(i) || i === e.label).map((i) => ({
4976
+ const o = Hi(e.start, e.end);
4977
+ return wu.filter((i) => o || !xn.includes(i) || i === e.label).map((i) => ({
4978
4978
  kind: i,
4979
- key: ku[i],
4980
- preview: ll({
4979
+ key: Au[i],
4980
+ preview: il({
4981
4981
  locale: a,
4982
4982
  kind: i,
4983
4983
  startValue: e.start.measurementValue,
@@ -4985,7 +4985,7 @@ var Tu = [
4985
4985
  valueFormat: e.start.valueFormat
4986
4986
  }),
4987
4987
  isPickable: o || !xn.includes(i),
4988
- isSuspect: Au.includes(i) && e.start.measurementValue === 0
4988
+ isSuspect: Tu.includes(i) && e.start.measurementValue === 0
4989
4989
  }));
4990
4990
  }, [e, a]);
4991
4991
  }, wn = [
@@ -5001,8 +5001,8 @@ var Tu = [
5001
5001
  id: "large",
5002
5002
  key: "graph.annotations.differenceArrowToolbar.size.large"
5003
5003
  }
5004
- ], Pu = ({ arrow: e, color: t, labelBox: r, panelRect: a, frameWidth: o, frameHeight: i, frameElement: l }) => {
5005
- const s = k(), { commands: c } = G(), u = _((b) => b.spec.styles.overrides), d = lt(), h = Lu(e), v = ho()(e.id), p = M(() => ({
5004
+ ], Lu = ({ arrow: e, color: t, labelBox: r, panelRect: a, frameWidth: o, frameHeight: i, frameElement: l }) => {
5005
+ const s = k(), { commands: c } = G(), u = _((b) => b.spec.styles.overrides), d = lt(), h = ku(e), v = ho()(e.id), p = M(() => ({
5006
5006
  target: "annotation",
5007
5007
  kind: "differenceArrow",
5008
5008
  annotation: e.id
@@ -5016,16 +5016,16 @@ var Tu = [
5016
5016
  patch: b
5017
5017
  }), Z);
5018
5018
  }, A = (b) => ({
5019
- ...Te(u, { select: p })?.declarations,
5019
+ ...fe(u, { select: p })?.declarations,
5020
5020
  ...b
5021
5021
  }), L = (b) => ({
5022
- ...Te(u, { select: g })?.declarations,
5022
+ ...fe(u, { select: g })?.declarations,
5023
5023
  ...b
5024
5024
  }), R = (b) => {
5025
5025
  C(b), d.close();
5026
5026
  }, F = () => {
5027
5027
  c.dispatch(new ke({ id: e.id })), l.focus({ preventScroll: !0 });
5028
- }, D = (b) => c.dispatch(new Ne({
5028
+ }, D = (b) => c.dispatch(new Le({
5029
5029
  list: "overrides",
5030
5030
  rule: {
5031
5031
  select: p,
@@ -5036,7 +5036,7 @@ var Tu = [
5036
5036
  end: e.start.anchor
5037
5037
  }), N = (b) => () => R({ label: b }), T = (b) => () => {
5038
5038
  const Z = nn[b];
5039
- c.dispatch(new li({
5039
+ c.dispatch(new ii({
5040
5040
  annotationId: e.id,
5041
5041
  arrow: A(Z.arrow),
5042
5042
  label: L(Z.label)
@@ -5052,7 +5052,7 @@ var Tu = [
5052
5052
  children: [
5053
5053
  /* @__PURE__ */ n(I.Dropdown, {
5054
5054
  label: s("graph.annotations.differenceArrowToolbar.labelKind.ariaLabel"),
5055
- trigger: /* @__PURE__ */ n(Iu, { option: f }),
5055
+ trigger: /* @__PURE__ */ n(Pu, { option: f }),
5056
5056
  isDisabled: !y,
5057
5057
  ...d.bind("labelKind"),
5058
5058
  children: h.map((b) => /* @__PURE__ */ m(I.MenuItem, {
@@ -5068,7 +5068,7 @@ var Tu = [
5068
5068
  children: "⚠"
5069
5069
  }),
5070
5070
  /* @__PURE__ */ n("span", {
5071
- className: wu,
5071
+ className: xu,
5072
5072
  children: b.preview
5073
5073
  })
5074
5074
  ]
@@ -5096,7 +5096,7 @@ var Tu = [
5096
5096
  /* @__PURE__ */ n(I.IconButton, {
5097
5097
  label: s("graph.annotations.differenceArrowToolbar.swap"),
5098
5098
  onClick: E,
5099
- children: /* @__PURE__ */ n(yu, {
5099
+ children: /* @__PURE__ */ n(Cu, {
5100
5100
  size: "sm",
5101
5101
  title: ""
5102
5102
  })
@@ -5111,13 +5111,13 @@ var Tu = [
5111
5111
  })
5112
5112
  ]
5113
5113
  });
5114
- }, Iu = ({ option: e }) => {
5114
+ }, Pu = ({ option: e }) => {
5115
5115
  const t = k();
5116
5116
  return e === void 0 ? null : /* @__PURE__ */ m(j, { children: [/* @__PURE__ */ n("span", {
5117
- className: xu,
5117
+ className: Su,
5118
5118
  children: t(e.key)
5119
5119
  }), /* @__PURE__ */ m("span", {
5120
- className: Su,
5120
+ className: yu,
5121
5121
  children: [
5122
5122
  "(",
5123
5123
  e.preview,
@@ -5125,8 +5125,8 @@ var Tu = [
5125
5125
  ]
5126
5126
  })] });
5127
5127
  };
5128
- var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, panelOrigin: t, panelRect: r, engine: a, layers: o, coordSystem: i, resolver: l, fixedAnchor: s, align: c }) => {
5129
- const u = Ru({
5128
+ var Iu = "ydgo3h0", Eu = "ydgo3h1", Mu = "ydgo3h2", Nu = ({ clientPoint: e, panelOrigin: t, panelRect: r, engine: a, layers: o, coordSystem: i, resolver: l, fixedAnchor: s, align: c }) => {
5129
+ const u = Ou({
5130
5130
  x: e.x - t.x,
5131
5131
  y: e.y - t.y
5132
5132
  }, r), { primary: d } = a.query(Dt(u, r));
@@ -5137,12 +5137,12 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5137
5137
  resolver: l,
5138
5138
  layer: h,
5139
5139
  observation: d.observation,
5140
- observationIndex: fl(d),
5140
+ observationIndex: vl(d),
5141
5141
  coordSystem: i,
5142
5142
  align: c
5143
5143
  });
5144
5144
  return v === null || dr(v.anchor, s) ? null : v;
5145
- }, Ru = (e, t) => ({
5145
+ }, Ou = (e, t) => ({
5146
5146
  x: Math.max(0, Math.min(e.x, t.width)),
5147
5147
  y: Math.max(0, Math.min(e.y, t.height))
5148
5148
  }), ca = (e) => e === "start" ? "end" : "start", da = ({ dispatch: e, arrow: t, endpoint: r, anchor: a }) => {
@@ -5151,7 +5151,7 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5151
5151
  id: t.id,
5152
5152
  patch: { [r]: a }
5153
5153
  }));
5154
- }, Du = class extends ze {
5154
+ }, Ru = class extends _e {
5155
5155
  constructor(...e) {
5156
5156
  super(...e), this.kind = "difference-arrow-endpoint-drag";
5157
5157
  }
@@ -5163,7 +5163,7 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5163
5163
  return qn(V(e, "difference-arrow-endpoint-drag"), r().arrow.id, t);
5164
5164
  }
5165
5165
  resolvePreview(e) {
5166
- const { endpoint: t, readInputs: r, engine: a, anchorResolver: o } = this.params, { arrow: i, panelOrigin: l, panelRect: s, layers: c, coordSystem: u } = r(), d = Ou({
5166
+ const { endpoint: t, readInputs: r, engine: a, anchorResolver: o } = this.params, { arrow: i, panelOrigin: l, panelRect: s, layers: c, coordSystem: u } = r(), d = Nu({
5167
5167
  clientPoint: e,
5168
5168
  panelOrigin: l,
5169
5169
  panelRect: s,
@@ -5190,12 +5190,12 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5190
5190
  anchor: e.anchor
5191
5191
  });
5192
5192
  }
5193
- }, zu = ({ arrow: e, panelOrigin: t, panelRect: r }) => {
5193
+ }, Du = ({ arrow: e, panelOrigin: t, panelRect: r }) => {
5194
5194
  const { commands: a, anchorResolver: o } = G(), { engine: i } = Ot(), l = U(), s = J({
5195
5195
  arrow: e,
5196
5196
  panelOrigin: t,
5197
5197
  panelRect: r,
5198
- ..._(Pe((u) => ({
5198
+ ..._(Ie((u) => ({
5199
5199
  layers: u.layers,
5200
5200
  coordSystem: u.coordSystem
5201
5201
  })))
@@ -5207,7 +5207,7 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5207
5207
  } catch {
5208
5208
  return;
5209
5209
  }
5210
- d.currentTarget.focus({ preventScroll: !0 }), d.preventDefault(), c.current = new Du({
5210
+ d.currentTarget.focus({ preventScroll: !0 }), d.preventDefault(), c.current = new Ru({
5211
5211
  handle: d.currentTarget,
5212
5212
  pointerId: d.pointerId,
5213
5213
  press: {
@@ -5232,8 +5232,8 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5232
5232
  o,
5233
5233
  a
5234
5234
  ]);
5235
- }, _u = [" ", "Enter"], Fu = ({ arrow: e }) => {
5236
- const { commands: t, anchorResolver: r } = G(), a = U(), { layers: o, coordSystem: i, mainAxis: l } = _(Pe((c) => ({
5235
+ }, zu = [" ", "Enter"], _u = ({ arrow: e }) => {
5236
+ const { commands: t, anchorResolver: r } = G(), a = U(), { layers: o, coordSystem: i, mainAxis: l } = _(Ie((c) => ({
5237
5237
  layers: c.layers,
5238
5238
  coordSystem: c.coordSystem,
5239
5239
  mainAxis: c.coordSystem.type === "cartesian" ? c.coordSystem.mainAxis : "x"
@@ -5244,7 +5244,7 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5244
5244
  }, [a, s]), ie((c) => ({ onKeyDown: (u) => {
5245
5245
  if (u.altKey || u.ctrlKey || u.metaKey || u.shiftKey) return;
5246
5246
  const d = a.getState(), h = qn(V(d, "difference-arrow-endpoint-drag"), e.id, c);
5247
- if (_u.includes(u.key)) {
5247
+ if (zu.includes(u.key)) {
5248
5248
  if (u.preventDefault(), u.repeat) return;
5249
5249
  if (h === null) return d.claimInteraction({
5250
5250
  kind: "difference-arrow-endpoint-drag",
@@ -5261,10 +5261,10 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5261
5261
  return;
5262
5262
  }
5263
5263
  if (h === null) return;
5264
- const v = Hu(u.key, l);
5264
+ const v = Fu(u.key, l);
5265
5265
  if (v === null) return;
5266
5266
  u.preventDefault();
5267
- const p = Bu({
5267
+ const p = Hu({
5268
5268
  arrow: e,
5269
5269
  endpoint: c,
5270
5270
  from: h.point.anchor,
@@ -5288,19 +5288,19 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5288
5288
  i,
5289
5289
  l
5290
5290
  ]);
5291
- }, Hu = (e, t) => {
5291
+ }, Fu = (e, t) => {
5292
5292
  const r = e === "ArrowUp" || e === "ArrowDown";
5293
5293
  return !r && !(e === "ArrowLeft" || e === "ArrowRight") ? null : {
5294
5294
  axis: t === "x" === r ? "cross" : "main",
5295
5295
  step: e === "ArrowDown" || e === "ArrowRight" ? 1 : -1
5296
5296
  };
5297
- }, Bu = ({ arrow: e, endpoint: t, from: r, move: a, layers: o, coordSystem: i, resolver: l }) => {
5297
+ }, Hu = ({ arrow: e, endpoint: t, from: r, move: a, layers: o, coordSystem: i, resolver: l }) => {
5298
5298
  const s = o.find((d) => d.id === r.layerId);
5299
5299
  if (s === void 0) return null;
5300
5300
  const c = l.createLayerMeasurement(s);
5301
5301
  if (c === null) return null;
5302
5302
  const { align: u } = e[t].anchor;
5303
- return xl({
5303
+ return Sl({
5304
5304
  layer: s,
5305
5305
  from: r,
5306
5306
  partner: e[ca(t)].anchor,
@@ -5316,15 +5316,15 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5316
5316
  measurement: c
5317
5317
  })
5318
5318
  })?.point ?? null;
5319
- }, Vu = (e) => {
5320
- const t = De();
5321
- return t === null ? null : /* @__PURE__ */ n(Gu, {
5319
+ }, Bu = (e) => {
5320
+ const t = ze();
5321
+ return t === null ? null : /* @__PURE__ */ n(Vu, {
5322
5322
  annotationId: t,
5323
5323
  ...e
5324
5324
  });
5325
- }, Gu = ({ annotationId: e, ...t }) => {
5325
+ }, Vu = ({ annotationId: e, ...t }) => {
5326
5326
  const r = po(), a = M(() => r.find((o) => o.id === e), [r, e]);
5327
- return a === void 0 ? null : /* @__PURE__ */ n($u, {
5327
+ return a === void 0 ? null : /* @__PURE__ */ n(Gu, {
5328
5328
  committedArrow: a.committedArrow,
5329
5329
  color: a.color,
5330
5330
  labelCornerRadius: a.style.label.borderRadius,
@@ -5335,16 +5335,16 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5335
5335
  isDragged: a.isDragged,
5336
5336
  ...t
5337
5337
  });
5338
- }, $u = ({ committedArrow: e, color: t, labelCornerRadius: r, committedLabelBox: a, labelBox: o, start: i, end: l, panelRect: s, panelOrigin: c, frameRect: u, frameElement: d, isDragged: h }) => {
5339
- const v = zu({
5338
+ }, Gu = ({ committedArrow: e, color: t, labelCornerRadius: r, committedLabelBox: a, labelBox: o, start: i, end: l, panelRect: s, panelOrigin: c, frameRect: u, frameElement: d, isDragged: h }) => {
5339
+ const v = Du({
5340
5340
  arrow: e,
5341
5341
  panelOrigin: c,
5342
5342
  panelRect: s
5343
- }), p = Fu({ arrow: e });
5343
+ }), p = _u({ arrow: e });
5344
5344
  return /* @__PURE__ */ m("div", {
5345
5345
  "data-testid": "difference-arrow-selection",
5346
5346
  children: [
5347
- !h && /* @__PURE__ */ n(Pu, {
5347
+ !h && /* @__PURE__ */ n(Lu, {
5348
5348
  arrow: e,
5349
5349
  color: t,
5350
5350
  labelBox: a,
@@ -5355,7 +5355,7 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5355
5355
  }),
5356
5356
  /* @__PURE__ */ n("div", {
5357
5357
  "aria-hidden": "true",
5358
- className: Nu,
5358
+ className: Mu,
5359
5359
  "data-testid": "difference-arrow-selection-label",
5360
5360
  style: {
5361
5361
  left: s.x + o.x - 2,
@@ -5382,7 +5382,7 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5382
5382
  ]
5383
5383
  });
5384
5384
  }, Tn = ({ endpoint: e, point: t, panelRect: r, dragHandlers: a, keyboardHandlers: o }) => /* @__PURE__ */ n("div", {
5385
- className: Eu,
5385
+ className: Iu,
5386
5386
  "data-testid": "difference-arrow-selection-handle",
5387
5387
  "data-endpoint": e,
5388
5388
  role: "button",
@@ -5395,7 +5395,7 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5395
5395
  ...o,
5396
5396
  children: /* @__PURE__ */ n("span", {
5397
5397
  "aria-hidden": "true",
5398
- className: Mu
5398
+ className: Eu
5399
5399
  })
5400
5400
  }), Tt = ({ start: e, extent: t, isStartMoving: r, delta: a, minExtent: o }) => {
5401
5401
  if (!Number.isFinite(a)) return {
@@ -5404,7 +5404,7 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5404
5404
  };
5405
5405
  const i = e + t, l = Math.min(o, t);
5406
5406
  if (r) {
5407
- const u = Math.min(0, e), d = Math.min(Math.max(1, e), i - l), h = Ke(e + a, u, d);
5407
+ const u = Math.min(0, e), d = Math.min(Math.max(1, e), i - l), h = qe(e + a, u, d);
5408
5408
  return {
5409
5409
  start: h,
5410
5410
  extent: i - h
@@ -5413,9 +5413,9 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5413
5413
  const s = Math.max(Math.min(0, i), e + l), c = Math.max(1, i);
5414
5414
  return {
5415
5415
  start: e,
5416
- extent: Ke(i + a, s, c) - e
5416
+ extent: qe(i + a, s, c) - e
5417
5417
  };
5418
- }, Uu = [
5418
+ }, $u = [
5419
5419
  "top-left",
5420
5420
  "top-right",
5421
5421
  "bottom-right",
@@ -5424,7 +5424,7 @@ var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, pane
5424
5424
  var ua = ({ width: e, height: t }) => ({
5425
5425
  x: ne(16, e),
5426
5426
  y: ne(16, t)
5427
- }), Wu = (e, t) => ({
5427
+ }), Uu = (e, t) => ({
5428
5428
  x: ma(t) ? e.x : e.x + e.width,
5429
5429
  y: ga(t) ? e.y : e.y + e.height
5430
5430
  }), Ut = (e) => ({
@@ -5457,14 +5457,14 @@ var ua = ({ width: e, height: t }) => ({
5457
5457
  const o = e.textAnnotations.find((i) => i.id === t);
5458
5458
  return o === void 0 ? null : _o(Io(o, r), a);
5459
5459
  };
5460
- var Ku = {
5460
+ var Wu = {
5461
5461
  hovered: "_1ee8fau1 _1ee8fau0",
5462
5462
  selected: "_1ee8fau2 _1ee8fau0"
5463
- }, qu = {
5463
+ }, Ku = {
5464
5464
  hovered: "_1ee8fau4 _1ee8fau3",
5465
5465
  selected: "_1ee8fau5 _1ee8fau3"
5466
- }, Zu = ({ panelRect: e }) => {
5467
- const t = fe(e), r = jn(), a = Xn(), o = De(), i = X((f) => V(f, "move-drag")), l = X((f) => V(f, "shape-resize-drag")), s = X((f) => V(f, "arrow-endpoint-drag")), c = X((f) => V(f, "text-resize-drag")), u = X((f) => {
5466
+ }, qu = ({ panelRect: e }) => {
5467
+ const t = be(e), r = jn(), a = Xn(), o = ze(), i = X((f) => V(f, "move-drag")), l = X((f) => V(f, "shape-resize-drag")), s = X((f) => V(f, "arrow-endpoint-drag")), c = X((f) => V(f, "text-resize-drag")), u = X((f) => {
5468
5468
  const y = f.editTargetUnderPointer;
5469
5469
  return y?.kind === "annotation" ? y.id : null;
5470
5470
  }), d = M(() => ({
@@ -5482,7 +5482,7 @@ var Ku = {
5482
5482
  ]), h = An(t, o, d), v = An(t, u === o ? null : u, d), p = (f) => {
5483
5483
  if (l?.annotationId === f.id) {
5484
5484
  const y = t.shapes.find((P) => P.id === f.id);
5485
- return y === void 0 ? f.geometry : Zn(Ut(l.region), Sl(a, y.id).borderWidth, d.panel);
5485
+ return y === void 0 ? f.geometry : Zn(Ut(l.region), yl(a, y.id).borderWidth, d.panel);
5486
5486
  }
5487
5487
  if (s?.annotationId === f.id) {
5488
5488
  const y = t.arrows.find((P) => P.id === f.id);
@@ -5531,7 +5531,7 @@ var Ku = {
5531
5531
  })]
5532
5532
  }) : /* @__PURE__ */ n("div", {
5533
5533
  "aria-hidden": "true",
5534
- className: Ku[r],
5534
+ className: Wu[r],
5535
5535
  "data-testid": "annotation-chrome",
5536
5536
  "data-annotation-id": e,
5537
5537
  "data-state": r,
@@ -5542,13 +5542,13 @@ var Ku = {
5542
5542
  height: t.rect.height + 4
5543
5543
  }
5544
5544
  }), Ln = ({ point: e, state: t, origin: r }) => /* @__PURE__ */ n("span", {
5545
- className: qu[t],
5545
+ className: Ku[t],
5546
5546
  style: {
5547
5547
  left: r.x + e.x,
5548
5548
  top: r.y + e.y
5549
5549
  }
5550
- }), Xu = ({ panelRect: e }) => {
5551
- const t = X((o) => V(o, "move-drag")), r = fe(e);
5550
+ }), Zu = ({ panelRect: e }) => {
5551
+ const t = X((o) => V(o, "move-drag")), r = be(e);
5552
5552
  if (t === null) return null;
5553
5553
  const a = la(t.translation, e);
5554
5554
  return /* @__PURE__ */ n("svg", {
@@ -5562,9 +5562,9 @@ var Ku = {
5562
5562
  },
5563
5563
  "data-testid": "annotation-preview",
5564
5564
  "data-annotation-id": t.annotationId,
5565
- children: Ju(r, t.annotationId, e)
5565
+ children: Yu(r, t.annotationId, e)
5566
5566
  });
5567
- }, ju = ({ annotation: e, panel: t }) => {
5567
+ }, Xu = ({ annotation: e, panel: t }) => {
5568
5568
  const r = uo(e.id);
5569
5569
  return /* @__PURE__ */ n(Do, {
5570
5570
  annotation: e,
@@ -5572,33 +5572,33 @@ var Ku = {
5572
5572
  style: Qn()(e.id),
5573
5573
  blockRef: r
5574
5574
  });
5575
- }, Ve = (e, t, r) => {
5575
+ }, Ge = (e, t, r) => {
5576
5576
  const a = e.find((o) => o.id === t);
5577
5577
  return a === void 0 ? null : r(a);
5578
- }, Yu = {
5579
- text: (e, t, r) => Ve(e.textAnnotations, t, (a) => /* @__PURE__ */ n(ju, {
5578
+ }, ju = {
5579
+ text: (e, t, r) => Ge(e.textAnnotations, t, (a) => /* @__PURE__ */ n(Xu, {
5580
5580
  annotation: a,
5581
5581
  panel: r
5582
5582
  })),
5583
- shape: (e, t, r) => Ve(e.shapes, t, (a) => /* @__PURE__ */ n(eh, {
5583
+ shape: (e, t, r) => Ge(e.shapes, t, (a) => /* @__PURE__ */ n(Qu, {
5584
5584
  shape: a,
5585
5585
  panelSize: r
5586
5586
  })),
5587
- image: (e, t, r) => Ve(e.images, t, (a) => /* @__PURE__ */ n(th, {
5587
+ image: (e, t, r) => Ge(e.images, t, (a) => /* @__PURE__ */ n(eh, {
5588
5588
  image: a,
5589
5589
  panelSize: r
5590
5590
  })),
5591
- arrow: (e, t, r) => Ve(e.arrows, t, (a) => /* @__PURE__ */ n(Qu, {
5591
+ arrow: (e, t, r) => Ge(e.arrows, t, (a) => /* @__PURE__ */ n(Ju, {
5592
5592
  arrow: a,
5593
5593
  panelSize: r
5594
5594
  }))
5595
- }, Ju = (e, t, r) => {
5596
- for (const a of Object.values(Yu)) {
5595
+ }, Yu = (e, t, r) => {
5596
+ for (const a of Object.values(ju)) {
5597
5597
  const o = a(e, t, r);
5598
5598
  if (o !== null) return o;
5599
5599
  }
5600
5600
  return null;
5601
- }, Qu = ({ arrow: e, panelSize: t }) => {
5601
+ }, Ju = ({ arrow: e, panelSize: t }) => {
5602
5602
  const r = Nt()(e.id), a = ur({
5603
5603
  arrow: e,
5604
5604
  style: r,
@@ -5610,16 +5610,16 @@ var Ku = {
5610
5610
  style: r,
5611
5611
  isAddressable: !1
5612
5612
  });
5613
- }, eh = ({ shape: e, panelSize: t }) => /* @__PURE__ */ n(er, {
5613
+ }, Qu = ({ shape: e, panelSize: t }) => /* @__PURE__ */ n(er, {
5614
5614
  shape: e,
5615
- style: tt()(e.id),
5615
+ style: nt()(e.id),
5616
5616
  panel: t
5617
- }), th = ({ image: e, panelSize: t }) => /* @__PURE__ */ n(ko, {
5617
+ }), eh = ({ image: e, panelSize: t }) => /* @__PURE__ */ n(ko, {
5618
5618
  image: e,
5619
5619
  panel: t,
5620
5620
  style: Ao()(e.id)
5621
- }), nh = ({ panelRect: e }) => {
5622
- const t = X((i) => V(i, "shape-resize-drag")), r = fe(e).shapes, a = tt();
5621
+ }), th = ({ panelRect: e }) => {
5622
+ const t = X((i) => V(i, "shape-resize-drag")), r = be(e).shapes, a = nt();
5623
5623
  if (t === null) return null;
5624
5624
  const o = r.find((i) => i.id === t.annotationId);
5625
5625
  return o === void 0 ? null : /* @__PURE__ */ n("svg", {
@@ -5642,16 +5642,16 @@ var Ku = {
5642
5642
  panel: e
5643
5643
  })
5644
5644
  });
5645
- }, rh = {
5645
+ }, nh = {
5646
5646
  sm: "o49ib40",
5647
5647
  md: "o49ib41"
5648
- }, ah = {
5648
+ }, rh = {
5649
5649
  horizontal: "o49ib42",
5650
5650
  diagonalDown: "o49ib43",
5651
5651
  diagonalUp: "o49ib44"
5652
5652
  }, fa = ({ point: e, label: t, pull: r, size: a, attributes: o, dragHandlers: i, keyboardHandlers: l }) => /* @__PURE__ */ n("div", {
5653
5653
  "aria-label": t,
5654
- className: ah[r],
5654
+ className: rh[r],
5655
5655
  role: "button",
5656
5656
  style: {
5657
5657
  left: e.x,
@@ -5663,7 +5663,7 @@ var Ku = {
5663
5663
  ...l,
5664
5664
  children: /* @__PURE__ */ n("span", {
5665
5665
  "aria-hidden": "true",
5666
- className: rh[a]
5666
+ className: nh[a]
5667
5667
  })
5668
5668
  }), At = [
5669
5669
  {
@@ -5682,14 +5682,14 @@ var Ku = {
5682
5682
  width: 16,
5683
5683
  key: "graph.annotations.shapeToolbar.border.thick"
5684
5684
  }
5685
- ], oh = (e) => [...At].reverse().find((t) => t.width <= e) ?? At[0], ih = ({ shape: e, shapeBox: t, panelRect: r, frameWidth: a, frameHeight: o, frameElement: i }) => {
5686
- const l = k(), { commands: s } = G(), c = _((C) => C.spec.styles.overrides), u = lt(), d = tt()(e.id), h = oh(d.borderWidth), v = M(() => ({
5685
+ ], ah = (e) => [...At].reverse().find((t) => t.width <= e) ?? At[0], oh = ({ shape: e, shapeBox: t, panelRect: r, frameWidth: a, frameHeight: o, frameElement: i }) => {
5686
+ const l = k(), { commands: s } = G(), c = _((C) => C.spec.styles.overrides), u = lt(), d = nt()(e.id), h = ah(d.borderWidth), v = M(() => ({
5687
5687
  target: "annotation",
5688
5688
  kind: "shape",
5689
5689
  annotation: e.id
5690
5690
  }), [e.id]), p = (C, A) => {
5691
- const L = Te(c, { select: v })?.declarations ?? {};
5692
- s.dispatch(new Ne({
5691
+ const L = fe(c, { select: v })?.declarations ?? {};
5692
+ s.dispatch(new Le({
5693
5693
  list: "overrides",
5694
5694
  rule: {
5695
5695
  select: v,
@@ -5771,10 +5771,10 @@ var Ku = {
5771
5771
  });
5772
5772
  r.current = i, i.start();
5773
5773
  } }), [t]);
5774
- }, Xe = (e, t) => {
5774
+ }, je = (e, t) => {
5775
5775
  const r = e.shapes.find((a) => a.id === t);
5776
5776
  return r === void 0 || r.region.anchorType !== "panel" ? null : r.region;
5777
- }, lh = class extends ze {
5777
+ }, ih = class extends _e {
5778
5778
  constructor(...e) {
5779
5779
  super(...e), this.kind = "shape-resize-drag";
5780
5780
  }
@@ -5782,7 +5782,7 @@ var Ku = {
5782
5782
  return Rt(V(e, "shape-resize-drag"), this.params.annotationId);
5783
5783
  }
5784
5784
  resolvePreview(e) {
5785
- const { annotationId: t, corner: r, press: a, readInputs: o } = this.params, { annotations: i, panelRect: l } = o(), s = Xe(i, t);
5785
+ const { annotationId: t, corner: r, press: a, readInputs: o } = this.params, { annotations: i, panelRect: l } = o(), s = je(i, t);
5786
5786
  return s === null ? null : {
5787
5787
  kind: "shape-resize-drag",
5788
5788
  annotationId: t,
@@ -5795,19 +5795,19 @@ var Ku = {
5795
5795
  };
5796
5796
  }
5797
5797
  commit({ region: e }) {
5798
- const { annotationId: t, dispatch: r, readInputs: a } = this.params, o = Xe(a().annotations, t);
5798
+ const { annotationId: t, dispatch: r, readInputs: a } = this.params, o = je(a().annotations, t);
5799
5799
  o === null || pa(o, e) || r(new re({
5800
5800
  kind: "shape",
5801
5801
  id: t,
5802
5802
  patch: { region: e }
5803
5803
  }));
5804
5804
  }
5805
- }, sh = ({ annotationId: e, panelRect: t }) => {
5805
+ }, lh = ({ annotationId: e, panelRect: t }) => {
5806
5806
  const { commands: r } = G(), a = U(), o = J({
5807
5807
  annotations: _((i) => i.spec.annotations),
5808
5808
  panelRect: t
5809
5809
  });
5810
- return ba((i, l) => new lh({
5810
+ return ba((i, l) => new ih({
5811
5811
  ...l,
5812
5812
  annotationId: e,
5813
5813
  corner: i,
@@ -5815,12 +5815,12 @@ var Ku = {
5815
5815
  editorStore: a,
5816
5816
  dispatch: r.dispatch
5817
5817
  }));
5818
- }, ch = [" ", "Enter"], Ca = (e) => {
5818
+ }, sh = [" ", "Enter"], Ca = (e) => {
5819
5819
  const t = U(), r = J(e);
5820
5820
  return O(() => () => Pn(t, r.current), [t, r]), ie((a) => ({ onKeyDown: (o) => {
5821
5821
  if (o.altKey || o.ctrlKey || o.metaKey || o.shiftKey) return;
5822
5822
  const i = t.getState(), l = r.current.readHeld();
5823
- if (ch.includes(o.key)) {
5823
+ if (sh.includes(o.key)) {
5824
5824
  if (o.preventDefault(), o.repeat) return;
5825
5825
  if (l !== null) {
5826
5826
  Pn(t, r.current);
@@ -5838,12 +5838,12 @@ var Ku = {
5838
5838
  }, Pn = (e, t) => {
5839
5839
  const r = t.readHeld();
5840
5840
  r !== null && (e.getState().releaseInteraction(r.kind), t.commit(r));
5841
- }, In = 4, dh = ({ annotationId: e, panelRect: t }) => {
5841
+ }, In = 4, ch = ({ annotationId: e, panelRect: t }) => {
5842
5842
  const { commands: r } = G(), a = U(), o = _((i) => i.spec.annotations);
5843
5843
  return Ca({
5844
5844
  readHeld: () => Rt(V(a.getState(), "shape-resize-drag"), e),
5845
5845
  claim: () => {
5846
- const i = Xe(o, e);
5846
+ const i = je(o, e);
5847
5847
  return i === null ? null : {
5848
5848
  kind: "shape-resize-drag",
5849
5849
  annotationId: e,
@@ -5851,7 +5851,7 @@ var Ku = {
5851
5851
  };
5852
5852
  },
5853
5853
  step: (i, l, s) => {
5854
- const c = uh(s, t);
5854
+ const c = dh(s, t);
5855
5855
  return c === null ? null : {
5856
5856
  kind: "shape-resize-drag",
5857
5857
  annotationId: e,
@@ -5864,7 +5864,7 @@ var Ku = {
5864
5864
  };
5865
5865
  },
5866
5866
  commit: ({ region: i }) => {
5867
- const l = Xe(o, e);
5867
+ const l = je(o, e);
5868
5868
  l === null || pa(l, i) || r.dispatch(new re({
5869
5869
  kind: "shape",
5870
5870
  id: e,
@@ -5872,7 +5872,7 @@ var Ku = {
5872
5872
  }));
5873
5873
  }
5874
5874
  });
5875
- }, uh = (e, t) => {
5875
+ }, dh = (e, t) => {
5876
5876
  const r = ne(In, t.width), a = ne(In, t.height);
5877
5877
  switch (e) {
5878
5878
  case "ArrowLeft":
@@ -5898,49 +5898,49 @@ var Ku = {
5898
5898
  default:
5899
5899
  return null;
5900
5900
  }
5901
- }, hh = {
5901
+ }, uh = {
5902
5902
  "top-left": "diagonalDown",
5903
5903
  "bottom-right": "diagonalDown",
5904
5904
  "top-right": "diagonalUp",
5905
5905
  "bottom-left": "diagonalUp"
5906
- }, ph = (e) => {
5907
- const t = De(), r = gh(t), a = vh(t);
5906
+ }, hh = (e) => {
5907
+ const t = ze(), r = mh(t), a = gh(t);
5908
5908
  if (r === null) return null;
5909
5909
  const o = a.resizedRegion ?? (r.region.anchorType === "panel" ? r.region : null);
5910
- return o === null ? null : /* @__PURE__ */ n(mh, {
5910
+ return o === null ? null : /* @__PURE__ */ n(ph, {
5911
5911
  shape: r,
5912
5912
  region: o,
5913
5913
  isSettled: a.resizedRegion === null && !a.isMoved,
5914
5914
  isMoved: a.isMoved,
5915
5915
  ...e
5916
5916
  });
5917
- }, mh = ({ shape: e, region: t, isSettled: r, isMoved: a, panelRect: o, frameRect: i, frameElement: l }) => {
5918
- const s = k(), c = sh({
5917
+ }, ph = ({ shape: e, region: t, isSettled: r, isMoved: a, panelRect: o, frameRect: i, frameElement: l }) => {
5918
+ const s = k(), c = lh({
5919
5919
  annotationId: e.id,
5920
5920
  panelRect: o
5921
- }), u = dh({
5921
+ }), u = ch({
5922
5922
  annotationId: e.id,
5923
5923
  panelRect: o
5924
- }), d = tt()(e.id), { rect: h } = Zn(Ut(t), d.borderWidth, o);
5924
+ }), d = nt()(e.id), { rect: h } = Zn(Ut(t), d.borderWidth, o);
5925
5925
  return /* @__PURE__ */ m("div", {
5926
5926
  "data-testid": "shape-selection",
5927
5927
  "data-annotation-id": e.id,
5928
- children: [r && /* @__PURE__ */ n(ih, {
5928
+ children: [r && /* @__PURE__ */ n(oh, {
5929
5929
  shape: e,
5930
5930
  shapeBox: h,
5931
5931
  panelRect: o,
5932
5932
  frameWidth: i.width,
5933
5933
  frameHeight: i.height,
5934
5934
  frameElement: l
5935
- }), !a && Uu.map((v) => {
5936
- const p = Wu(h, v);
5935
+ }), !a && $u.map((v) => {
5936
+ const p = Uu(h, v);
5937
5937
  return /* @__PURE__ */ n(fa, {
5938
5938
  point: {
5939
5939
  x: o.x + p.x,
5940
5940
  y: o.y + p.y
5941
5941
  },
5942
5942
  label: s(`graph.annotations.shapeToolbar.resize.${v}`),
5943
- pull: hh[v],
5943
+ pull: uh[v],
5944
5944
  size: "md",
5945
5945
  attributes: {
5946
5946
  "data-testid": "shape-resize-handle",
@@ -5951,16 +5951,16 @@ var Ku = {
5951
5951
  }, v);
5952
5952
  })]
5953
5953
  });
5954
- }, gh = (e) => {
5954
+ }, mh = (e) => {
5955
5955
  const t = _((r) => r.spec.annotations.shapes);
5956
5956
  return e === null ? null : t.find((r) => r.id === e) ?? null;
5957
- }, vh = (e) => X(Pe((t) => e === null ? {
5957
+ }, gh = (e) => X(Ie((t) => e === null ? {
5958
5958
  resizedRegion: null,
5959
5959
  isMoved: !1
5960
5960
  } : {
5961
5961
  resizedRegion: Rt(V(t, "shape-resize-drag"), e)?.region ?? null,
5962
- isMoved: et(V(t, "move-drag"), e) !== null
5963
- })), fh = ({ textColor: e, ...t }) => /* @__PURE__ */ m(x, {
5962
+ isMoved: tt(V(t, "move-drag"), e) !== null
5963
+ })), vh = ({ textColor: e, ...t }) => /* @__PURE__ */ m(x, {
5964
5964
  ...t,
5965
5965
  children: [/* @__PURE__ */ m("g", {
5966
5966
  stroke: "currentColor",
@@ -5974,15 +5974,15 @@ var Ku = {
5974
5974
  strokeLinecap: "round"
5975
5975
  })]
5976
5976
  });
5977
- var je = "textStyle", ya = /* @__PURE__ */ new Set(["paragraph", "heading"]), bh = (e) => {
5978
- const t = Sa(e), r = Th(e);
5977
+ var Ye = "textStyle", ya = /* @__PURE__ */ new Set(["paragraph", "heading"]), fh = (e) => {
5978
+ const t = Sa(e), r = wh(e);
5979
5979
  return {
5980
- color: Ge(t.map((a) => Ah(gt(a)?.color))),
5981
- font: Ge(t.map((a) => wh(gt(a)))),
5982
- fontSize: Ge(t.map((a) => kh(gt(a)?.fontSize))),
5983
- alignment: Ge(r.map((a) => Lh(a.attrs?.textAlign)))
5980
+ color: $e(t.map((a) => Th(gt(a)?.color))),
5981
+ font: $e(t.map((a) => xh(gt(a)))),
5982
+ fontSize: $e(t.map((a) => Ah(gt(a)?.fontSize))),
5983
+ alignment: $e(r.map((a) => kh(a.attrs?.textAlign)))
5984
5984
  };
5985
- }, Ch = (e, t) => Wt(e, (r) => r.type === "text" ? xh(r, t) : r), yh = (e) => Sa(e).length > 0, Sh = (e, t) => Wt(e, (r) => ya.has(r.type ?? "") ? {
5985
+ }, bh = (e, t) => Wt(e, (r) => r.type === "text" ? Sh(r, t) : r), Ch = (e) => Sa(e).length > 0, yh = (e, t) => Wt(e, (r) => ya.has(r.type ?? "") ? {
5986
5986
  ...r,
5987
5987
  attrs: {
5988
5988
  ...r.attrs,
@@ -5991,9 +5991,9 @@ var je = "textStyle", ya = /* @__PURE__ */ new Set(["paragraph", "heading"]), bh
5991
5991
  } : r), Wt = (e, t) => t(e.content === void 0 ? e : {
5992
5992
  ...e,
5993
5993
  content: e.content.map((r) => Wt(r, t))
5994
- }), xh = (e, t) => {
5995
- const r = e.marks ?? [], a = r.find((i) => i.type === je), o = {
5996
- type: je,
5994
+ }), Sh = (e, t) => {
5995
+ const r = e.marks ?? [], a = r.find((i) => i.type === Ye), o = {
5996
+ type: Ye,
5997
5997
  attrs: {
5998
5998
  ...a?.attrs,
5999
5999
  ...t
@@ -6003,10 +6003,10 @@ var je = "textStyle", ya = /* @__PURE__ */ new Set(["paragraph", "heading"]), bh
6003
6003
  ...e,
6004
6004
  marks: a === void 0 ? [...r, o] : r.map((i) => i === a ? o : i)
6005
6005
  };
6006
- }, gt = (e) => e.marks?.find((t) => t.type === je)?.attrs, wh = (e) => Qt(e?.font) ?? Qt(e?.fontFamily), Sa = (e) => Kt(e, (t) => t.type === "text"), Th = (e) => Kt(e, (t) => ya.has(t.type ?? "")), Kt = (e, t) => [...t(e) ? [e] : [], ...(e.content ?? []).flatMap((r) => Kt(r, t))], Ge = (e) => {
6006
+ }, gt = (e) => e.marks?.find((t) => t.type === Ye)?.attrs, xh = (e) => Qt(e?.font) ?? Qt(e?.fontFamily), Sa = (e) => Kt(e, (t) => t.type === "text"), wh = (e) => Kt(e, (t) => ya.has(t.type ?? "")), Kt = (e, t) => [...t(e) ? [e] : [], ...(e.content ?? []).flatMap((r) => Kt(r, t))], $e = (e) => {
6007
6007
  const [t, ...r] = e;
6008
6008
  return t === void 0 ? null : r.every((a) => a === t) ? t : null;
6009
- }, Ah = (e) => typeof e == "string" && e.length > 0 ? e : void 0, kh = (e) => typeof e == "number" && Number.isFinite(e) ? e : void 0, Lh = (e) => e === "left" || e === "center" || e === "right" ? e : void 0;
6009
+ }, Th = (e) => typeof e == "string" && e.length > 0 ? e : void 0, Ah = (e) => typeof e == "number" && Number.isFinite(e) ? e : void 0, kh = (e) => e === "left" || e === "center" || e === "right" ? e : void 0;
6010
6010
  var xa = [
6011
6011
  {
6012
6012
  id: "modern",
@@ -6032,7 +6032,7 @@ var xa = [
6032
6032
  id: e,
6033
6033
  key: t,
6034
6034
  fontFamily: yo[e] ?? e
6035
- })), Ph = (e) => xa.find((t) => t.id === (e ?? "modern")) ?? null;
6035
+ })), Lh = (e) => xa.find((t) => t.id === (e ?? "modern")) ?? null;
6036
6036
  var wa = [
6037
6037
  {
6038
6038
  size: 12,
@@ -6054,7 +6054,7 @@ var wa = [
6054
6054
  size: 30,
6055
6055
  key: "graph.annotations.textToolbar.fontSize.huge"
6056
6056
  }
6057
- ], Ih = (e) => wa.find((t) => t.size === (e ?? 15)) ?? null, Eh = (e) => `${e}px`, Mh = [
6057
+ ], Ph = (e) => wa.find((t) => t.size === (e ?? 15)) ?? null, Ih = (e) => `${e}px`, Eh = [
6058
6058
  {
6059
6059
  alignment: "left",
6060
6060
  Icon: Gr
@@ -6067,19 +6067,19 @@ var wa = [
6067
6067
  alignment: "right",
6068
6068
  Icon: Vr
6069
6069
  }
6070
- ], Nh = ({ annotation: e, textBox: t, panelRect: r, frameWidth: a, frameHeight: o, frameElement: i }) => {
6071
- const l = k(), { commands: s } = G(), c = _((b) => b.spec.styles.overrides), u = U(), d = lt(), h = Qn()(e.id), v = bh(e.content), p = Ph(v.font), g = Ih(v.fontSize), f = v.color ?? h.textColor, y = M(() => ({
6070
+ ], Mh = ({ annotation: e, textBox: t, panelRect: r, frameWidth: a, frameHeight: o, frameElement: i }) => {
6071
+ const l = k(), { commands: s } = G(), c = _((b) => b.spec.styles.overrides), u = U(), d = lt(), h = Qn()(e.id), v = fh(e.content), p = Lh(v.font), g = Ph(v.fontSize), f = v.color ?? h.textColor, y = M(() => ({
6072
6072
  target: "annotation",
6073
6073
  kind: "text",
6074
6074
  annotation: e.id
6075
6075
  }), [e.id]), P = (b, Z) => {
6076
- const ye = Te(c, { select: y })?.declarations ?? {};
6077
- s.dispatch(new Ne({
6076
+ const Se = fe(c, { select: y })?.declarations ?? {};
6077
+ s.dispatch(new Le({
6078
6078
  list: "overrides",
6079
6079
  rule: {
6080
6080
  select: y,
6081
6081
  declarations: {
6082
- ...ye,
6082
+ ...Se,
6083
6083
  ...b
6084
6084
  }
6085
6085
  }
@@ -6091,19 +6091,19 @@ var wa = [
6091
6091
  patch: b
6092
6092
  }), Z);
6093
6093
  }, A = () => u.getState().caret?.editor?.getJSON() ?? e.content, L = (b, Z) => {
6094
- const ye = A(), _e = u.getState().caret?.editor ?? null;
6095
- if (_e !== null && !yh(ye)) {
6096
- _e.chain().focus().setMark(je, b).run();
6094
+ const Se = A(), Fe = u.getState().caret?.editor ?? null;
6095
+ if (Fe !== null && !Ch(Se)) {
6096
+ Fe.chain().focus().setMark(Ye, b).run();
6097
6097
  return;
6098
6098
  }
6099
- C({ content: Ch(ye, b) }, Z);
6099
+ C({ content: bh(Se, b) }, Z);
6100
6100
  }, R = () => {
6101
6101
  s.dispatch(new ke({ id: e.id })), i.focus({ preventScroll: !0 });
6102
- }, F = (b) => P(Oh(b), { transient: !0 }), D = (b) => L({ color: b }, { transient: !0 }), E = (b) => () => {
6102
+ }, F = (b) => P(Nh(b), { transient: !0 }), D = (b) => L({ color: b }, { transient: !0 }), E = (b) => () => {
6103
6103
  L({ font: b }), d.close();
6104
6104
  }, N = (b) => () => {
6105
6105
  L({ fontSize: b }), d.close();
6106
- }, T = (b) => C({ content: Sh(A(), b) });
6106
+ }, T = (b) => C({ content: yh(A(), b) });
6107
6107
  return /* @__PURE__ */ m(I.Root, {
6108
6108
  anchorBox: t,
6109
6109
  panelRect: r,
@@ -6125,7 +6125,7 @@ var wa = [
6125
6125
  label: l("graph.annotations.textToolbar.color"),
6126
6126
  onChange: D,
6127
6127
  ...d.bind("color"),
6128
- children: /* @__PURE__ */ n(fh, {
6128
+ children: /* @__PURE__ */ n(vh, {
6129
6129
  size: "sm",
6130
6130
  textColor: f,
6131
6131
  title: ""
@@ -6155,13 +6155,13 @@ var wa = [
6155
6155
  isSelected: b.size === g?.size,
6156
6156
  onClick: N(b.size),
6157
6157
  children: /* @__PURE__ */ n("span", {
6158
- style: { fontSize: Eh(b.size) },
6158
+ style: { fontSize: Ih(b.size) },
6159
6159
  children: l(b.key)
6160
6160
  })
6161
6161
  }, b.size))
6162
6162
  }),
6163
6163
  /* @__PURE__ */ n(I.Separator, {}),
6164
- /* @__PURE__ */ n(Rh, {
6164
+ /* @__PURE__ */ n(Oh, {
6165
6165
  current: v.alignment ?? "center",
6166
6166
  onPick: T
6167
6167
  }),
@@ -6176,12 +6176,12 @@ var wa = [
6176
6176
  })
6177
6177
  ]
6178
6178
  });
6179
- }, Oh = (e) => e === "transparent" ? { background: Er } : {
6179
+ }, Nh = (e) => e === "transparent" ? { background: Er } : {
6180
6180
  background: e,
6181
- alpha: Es(e) ? Ni : 1
6182
- }, Rh = ({ current: e, onPick: t }) => {
6181
+ alpha: Is(e) ? Mi : 1
6182
+ }, Oh = ({ current: e, onPick: t }) => {
6183
6183
  const r = k(), a = (o) => () => t(o);
6184
- return /* @__PURE__ */ n(j, { children: Mh.map((o) => /* @__PURE__ */ n(I.ToggleButton, {
6184
+ return /* @__PURE__ */ n(j, { children: Eh.map((o) => /* @__PURE__ */ n(I.ToggleButton, {
6185
6185
  label: r(`graph.annotations.textToolbar.align.${o.alignment}`),
6186
6186
  isPressed: o.alignment === e,
6187
6187
  onClick: a(o.alignment),
@@ -6190,8 +6190,8 @@ var wa = [
6190
6190
  title: ""
6191
6191
  })
6192
6192
  }, o.alignment)) });
6193
- }, Dh = ["left", "right"];
6194
- var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6193
+ }, Rh = ["left", "right"];
6194
+ var Ta = ({ width: e }) => ne(60, e), Dh = (e, t) => ({
6195
6195
  x: t === "left" ? e.x : e.x + e.width,
6196
6196
  y: e.y + e.height / 2
6197
6197
  }), Aa = ({ at: e, width: t, align: r, edge: a, delta: o, minWidth: i, panelWidth: l }) => {
@@ -6200,7 +6200,7 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6200
6200
  width: t,
6201
6201
  shift: 0
6202
6202
  };
6203
- const s = Hi(r).x, c = _h(e.offset, l), u = Tt({
6203
+ const s = Fi(r).x, c = zh(e.offset, l), u = Tt({
6204
6204
  start: e.x + c - s * t,
6205
6205
  extent: t,
6206
6206
  isStartMoving: a === "left",
@@ -6215,14 +6215,14 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6215
6215
  width: u.extent,
6216
6216
  shift: d - e.x
6217
6217
  };
6218
- }, ka = (e, t) => e.at.x === t.at.x && e.width === t.width, _h = (e, t) => e?.x === void 0 ? 0 : e.unit === "px" ? ne(e.x, t) : e.x, Ye = (e, t) => {
6218
+ }, ka = (e, t) => e.at.x === t.at.x && e.width === t.width, zh = (e, t) => e?.x === void 0 ? 0 : e.unit === "px" ? ne(e.x, t) : e.x, Je = (e, t) => {
6219
6219
  const r = e.textAnnotations.find((a) => a.id === t);
6220
6220
  return r === void 0 || r.at.anchorType !== "panel" ? null : {
6221
6221
  at: r.at,
6222
6222
  width: r.width,
6223
6223
  align: r.align
6224
6224
  };
6225
- }, Fh = class extends ze {
6225
+ }, _h = class extends _e {
6226
6226
  constructor(...e) {
6227
6227
  super(...e), this.kind = "text-resize-drag";
6228
6228
  }
@@ -6230,7 +6230,7 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6230
6230
  return Et(V(e, "text-resize-drag"), this.params.annotationId);
6231
6231
  }
6232
6232
  resolvePreview(e) {
6233
- const { annotationId: t, edge: r, press: a, readInputs: o } = this.params, { annotations: i, panelRect: l } = o(), s = Ye(i, t);
6233
+ const { annotationId: t, edge: r, press: a, readInputs: o } = this.params, { annotations: i, panelRect: l } = o(), s = Je(i, t);
6234
6234
  if (s === null) return null;
6235
6235
  const c = st(a, e, l).x;
6236
6236
  return {
@@ -6247,7 +6247,7 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6247
6247
  };
6248
6248
  }
6249
6249
  commit(e) {
6250
- const { annotationId: t, dispatch: r, readInputs: a } = this.params, o = Ye(a().annotations, t);
6250
+ const { annotationId: t, dispatch: r, readInputs: a } = this.params, o = Je(a().annotations, t);
6251
6251
  o === null || ka(o, e) || r(new re({
6252
6252
  kind: "text",
6253
6253
  id: t,
@@ -6257,12 +6257,12 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6257
6257
  }
6258
6258
  }));
6259
6259
  }
6260
- }, Hh = ({ annotationId: e, panelRect: t }) => {
6260
+ }, Fh = ({ annotationId: e, panelRect: t }) => {
6261
6261
  const { commands: r } = G(), a = U(), o = J({
6262
6262
  annotations: _((i) => i.spec.annotations),
6263
6263
  panelRect: t
6264
6264
  });
6265
- return ba((i, l) => new Fh({
6265
+ return ba((i, l) => new _h({
6266
6266
  ...l,
6267
6267
  annotationId: e,
6268
6268
  edge: i,
@@ -6270,9 +6270,9 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6270
6270
  editorStore: a,
6271
6271
  dispatch: r.dispatch
6272
6272
  }));
6273
- }, Bh = 4, Vh = ({ annotationId: e, panelRect: t }) => {
6273
+ }, Hh = 4, Bh = ({ annotationId: e, panelRect: t }) => {
6274
6274
  const { commands: r } = G(), a = U(), o = _((l) => l.spec.annotations), i = (l, s) => {
6275
- const c = Ye(o, e);
6275
+ const c = Je(o, e);
6276
6276
  return c === null ? null : {
6277
6277
  kind: "text-resize-drag",
6278
6278
  annotationId: e,
@@ -6290,11 +6290,11 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6290
6290
  readHeld: () => Et(V(a.getState(), "text-resize-drag"), e),
6291
6291
  claim: (l) => i(l, 0),
6292
6292
  step: (l, s, c) => {
6293
- const u = Gh(c, t);
6293
+ const u = Vh(c, t);
6294
6294
  return u === null ? null : i(s, l.delta + u);
6295
6295
  },
6296
6296
  commit: (l) => {
6297
- const s = Ye(o, e);
6297
+ const s = Je(o, e);
6298
6298
  s === null || ka(s, l) || r.dispatch(new re({
6299
6299
  kind: "text",
6300
6300
  id: e,
@@ -6305,8 +6305,8 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6305
6305
  }));
6306
6306
  }
6307
6307
  });
6308
- }, Gh = (e, t) => {
6309
- const r = ne(Bh, t.width);
6308
+ }, Vh = (e, t) => {
6309
+ const r = ne(Hh, t.width);
6310
6310
  switch (e) {
6311
6311
  case "ArrowLeft":
6312
6312
  return -r;
@@ -6315,9 +6315,9 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6315
6315
  default:
6316
6316
  return null;
6317
6317
  }
6318
- }, $h = (e) => {
6319
- const t = De(), r = Wh(t), a = Kh(t), o = X((l) => l.caret?.annotationId === t), i = qh(e.panelRect, t, a.resized);
6320
- return r === null || i === null ? null : /* @__PURE__ */ n(Uh, {
6318
+ }, Gh = (e) => {
6319
+ const t = ze(), r = Uh(t), a = Wh(t), o = X((l) => l.caret?.annotationId === t), i = Kh(e.panelRect, t, a.resized);
6320
+ return r === null || i === null ? null : /* @__PURE__ */ n($h, {
6321
6321
  annotation: r,
6322
6322
  textBox: i,
6323
6323
  isSettled: a.resized === null && !a.isMoved,
@@ -6326,26 +6326,26 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6326
6326
  hasCaret: o,
6327
6327
  ...e
6328
6328
  });
6329
- }, Uh = ({ annotation: e, textBox: t, isSettled: r, isMoved: a, isResizable: o, hasCaret: i, panelRect: l, frameRect: s, frameElement: c }) => {
6330
- const u = k(), d = Hh({
6329
+ }, $h = ({ annotation: e, textBox: t, isSettled: r, isMoved: a, isResizable: o, hasCaret: i, panelRect: l, frameRect: s, frameElement: c }) => {
6330
+ const u = k(), d = Fh({
6331
6331
  annotationId: e.id,
6332
6332
  panelRect: l
6333
- }), h = Vh({
6333
+ }), h = Bh({
6334
6334
  annotationId: e.id,
6335
6335
  panelRect: l
6336
6336
  });
6337
6337
  return /* @__PURE__ */ m("div", {
6338
6338
  "data-testid": "text-selection",
6339
6339
  "data-annotation-id": e.id,
6340
- children: [r && /* @__PURE__ */ n(Nh, {
6340
+ children: [r && /* @__PURE__ */ n(Mh, {
6341
6341
  annotation: e,
6342
6342
  textBox: t,
6343
6343
  panelRect: l,
6344
6344
  frameWidth: s.width,
6345
6345
  frameHeight: s.height,
6346
6346
  frameElement: c
6347
- }), o && !a && !i && Dh.map((v) => {
6348
- const p = zh(t, v);
6347
+ }), o && !a && !i && Rh.map((v) => {
6348
+ const p = Dh(t, v);
6349
6349
  return /* @__PURE__ */ n(fa, {
6350
6350
  point: {
6351
6351
  x: l.x + p.x,
@@ -6363,17 +6363,17 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6363
6363
  }, v);
6364
6364
  })]
6365
6365
  });
6366
- }, Wh = (e) => {
6366
+ }, Uh = (e) => {
6367
6367
  const t = _((r) => r.spec.annotations.textAnnotations);
6368
6368
  return e === null ? null : t.find((r) => r.id === e) ?? null;
6369
- }, Kh = (e) => X(Pe((t) => e === null ? {
6369
+ }, Wh = (e) => X(Ie((t) => e === null ? {
6370
6370
  resized: null,
6371
6371
  isMoved: !1
6372
6372
  } : {
6373
6373
  resized: Et(V(t, "text-resize-drag"), e),
6374
- isMoved: et(V(t, "move-drag"), e) !== null
6375
- })), qh = (e, t, r) => {
6376
- const a = fe(e), o = jn(), i = Xn(), l = M(() => ({
6374
+ isMoved: tt(V(t, "move-drag"), e) !== null
6375
+ })), Kh = (e, t, r) => {
6376
+ const a = be(e), o = jn(), i = Xn(), l = M(() => ({
6377
6377
  panel: {
6378
6378
  width: e.width,
6379
6379
  height: e.height
@@ -6387,7 +6387,7 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6387
6387
  i
6388
6388
  ]);
6389
6389
  return t === null ? null : va(a, t, r, l)?.rect ?? null;
6390
- }, Zh = (e) => /* @__PURE__ */ n(x, {
6390
+ }, qh = (e) => /* @__PURE__ */ n(x, {
6391
6391
  ...e,
6392
6392
  children: /* @__PURE__ */ m("g", {
6393
6393
  stroke: "currentColor",
@@ -6396,25 +6396,25 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
6396
6396
  strokeLinejoin: "round",
6397
6397
  children: [/* @__PURE__ */ n("path", { d: "M12 5v14" }), /* @__PURE__ */ n("path", { d: "M5 12h14" })]
6398
6398
  })
6399
- }), Xh = "var(--_1tyillx0)", jh = {
6399
+ }), Zh = "var(--_1tyillx0)", Xh = {
6400
6400
  rest: 0.5,
6401
6401
  hovered: 0.75,
6402
6402
  open: 1
6403
6403
  };
6404
- var Yh = "_1tyillx1", Jh = {
6404
+ var jh = "_1tyillx1", Yh = {
6405
6405
  rest: "_1tyillx2",
6406
6406
  hovered: "_1tyillx3",
6407
6407
  open: "_1tyillx4"
6408
- }, Qh = "_1tyillx5", e1 = {
6408
+ }, Jh = "_1tyillx5", Qh = {
6409
6409
  closed: "_1tyillx6",
6410
6410
  open: "_1tyillx7"
6411
- }, t1 = ({ interaction: e, panelRect: t }) => {
6412
- const r = U(), a = e.kind === "trigger" || e.kind === "menu" ? e.anchor : null, o = n1(e), i = M(() => {
6411
+ }, e1 = ({ interaction: e, panelRect: t }) => {
6412
+ const r = U(), a = e.kind === "trigger" || e.kind === "menu" ? e.anchor : null, o = t1(e), i = M(() => {
6413
6413
  if (a === null) return null;
6414
- const l = Ue(a.position, t);
6414
+ const l = We(a.position, t);
6415
6415
  return {
6416
6416
  center: l,
6417
- radius: 19 * jh[o],
6417
+ radius: 19 * Xh[o],
6418
6418
  target: {
6419
6419
  kind: "observation",
6420
6420
  cursor: Dt(l, t)
@@ -6431,24 +6431,24 @@ var Yh = "_1tyillx1", Jh = {
6431
6431
  "aria-hidden": "true",
6432
6432
  "data-testid": "observation-menu-trigger",
6433
6433
  "data-state": o,
6434
- className: de(Yh, Jh[o]),
6434
+ className: de(jh, Yh[o]),
6435
6435
  style: {
6436
6436
  left: t.x + i.center.x,
6437
6437
  top: t.y + i.center.y,
6438
- ...br({ [Xh]: a.color })
6438
+ ...br({ [Zh]: a.color })
6439
6439
  },
6440
6440
  children: /* @__PURE__ */ n("span", {
6441
- className: de(Qh, e1[o === "open" ? "open" : "closed"]),
6442
- children: /* @__PURE__ */ n(Zh, { size: "lg" })
6441
+ className: de(Jh, Qh[o === "open" ? "open" : "closed"]),
6442
+ children: /* @__PURE__ */ n(qh, { size: "lg" })
6443
6443
  })
6444
6444
  });
6445
- }, n1 = (e) => e.kind === "menu" ? "open" : e.kind === "trigger" && e.isEngaged ? "hovered" : "rest", r1 = 'button:not([disabled]):not([tabindex="-1"]), [tabindex]:not([tabindex="-1"])', a1 = (e, t) => {
6445
+ }, t1 = (e) => e.kind === "menu" ? "open" : e.kind === "trigger" && e.isEngaged ? "hovered" : "rest", n1 = 'button:not([disabled]):not([tabindex="-1"]), [tabindex]:not([tabindex="-1"])', r1 = (e, t) => {
6446
6446
  const { chartId: r } = G(), a = U();
6447
6447
  O(() => {
6448
6448
  if (t === null) return;
6449
6449
  const o = (i) => {
6450
- if (i.key !== "Tab" || i.defaultPrevented || !Me(i.target, e, r) || a.getState().standingInteraction?.kind === "chrome-popup") return;
6451
- const l = [...t.querySelectorAll(r1)];
6450
+ if (i.key !== "Tab" || i.defaultPrevented || !Ne(i.target, e, r) || a.getState().standingInteraction?.kind === "chrome-popup") return;
6451
+ const l = [...t.querySelectorAll(n1)];
6452
6452
  if (l.length === 0) return;
6453
6453
  i.preventDefault();
6454
6454
  const s = l.findIndex((c) => c === document.activeElement);
@@ -6461,20 +6461,20 @@ var Yh = "_1tyillx1", Jh = {
6461
6461
  r,
6462
6462
  a
6463
6463
  ]);
6464
- }, o1 = `[${Yn}]`, Je = (e, t, r) => {
6464
+ }, a1 = `[${Yn}]`, Qe = (e, t, r) => {
6465
6465
  if (typeof document.elementsFromPoint != "function") return null;
6466
6466
  const a = document.elementsFromPoint(e, t);
6467
- return i1(a, r);
6468
- }, i1 = (e, t) => {
6467
+ return o1(a, r);
6468
+ }, o1 = (e, t) => {
6469
6469
  for (const r of e) {
6470
- const a = r.closest(o1);
6470
+ const a = r.closest(a1);
6471
6471
  if (a === null || !t.contains(a)) continue;
6472
- const o = l1(a);
6472
+ const o = i1(a);
6473
6473
  if (o !== null) return o;
6474
6474
  if (a !== r) return null;
6475
6475
  }
6476
6476
  return null;
6477
- }, l1 = (e) => {
6477
+ }, i1 = (e) => {
6478
6478
  const t = e.getAttribute(Yn);
6479
6479
  if (t !== "annotation") return null;
6480
6480
  const r = e.getAttribute(bo);
@@ -6482,19 +6482,19 @@ var Yh = "_1tyillx1", Jh = {
6482
6482
  kind: t,
6483
6483
  id: r
6484
6484
  };
6485
- }, s1 = (e) => {
6485
+ }, l1 = (e) => {
6486
6486
  const { selectionStore: t, chartId: r } = G(), a = U();
6487
6487
  O(() => {
6488
6488
  let o = null;
6489
6489
  const i = (c) => {
6490
- const { caret: u } = a.getState(), d = u === null ? null : Je(c.clientX, c.clientY, e);
6490
+ const { caret: u } = a.getState(), d = u === null ? null : Qe(c.clientX, c.clientY, e);
6491
6491
  d !== null && d.id === u?.annotationId || e.focus({ preventScroll: !0 });
6492
6492
  }, l = (c) => {
6493
6493
  const { selection: u, clearSelection: d } = t.getState();
6494
- u.length !== 0 && (Me(c.target, e, r) || d());
6494
+ u.length !== 0 && (Ne(c.target, e, r) || d());
6495
6495
  }, s = (c) => {
6496
- t.getState().selection.length !== 0 && Me(c.target, e, r) && c.relatedTarget === null && (o !== null && cancelAnimationFrame(o), o = requestAnimationFrame(() => {
6497
- o = null, document.hasFocus() && (Me(document.activeElement, e, r) || t.getState().clearSelection());
6496
+ t.getState().selection.length !== 0 && Ne(c.target, e, r) && c.relatedTarget === null && (o !== null && cancelAnimationFrame(o), o = requestAnimationFrame(() => {
6497
+ o = null, document.hasFocus() && (Ne(document.activeElement, e, r) || t.getState().clearSelection());
6498
6498
  }));
6499
6499
  };
6500
6500
  return e.addEventListener("pointerdown", i), document.addEventListener("focusin", l), document.addEventListener("focusout", s), () => {
@@ -6506,17 +6506,17 @@ var Yh = "_1tyillx1", Jh = {
6506
6506
  e,
6507
6507
  r
6508
6508
  ]);
6509
- }, c1 = class extends ze {
6509
+ }, s1 = class extends _e {
6510
6510
  constructor(...e) {
6511
6511
  super(...e), this.kind = "move-drag";
6512
6512
  }
6513
6513
  readOwn(e) {
6514
- return et(V(e, "move-drag"), this.params.annotationId);
6514
+ return tt(V(e, "move-drag"), this.params.annotationId);
6515
6515
  }
6516
6516
  resolvePreview(e) {
6517
- const { annotationId: t, press: r, readInputs: a } = this.params, { annotations: o, panelRect: i } = a(), l = el(o, t);
6517
+ const { annotationId: t, press: r, readInputs: a } = this.params, { annotations: o, panelRect: i } = a(), l = Qi(o, t);
6518
6518
  if (l === null) return null;
6519
- const s = Zi(l, st(r, e, i));
6519
+ const s = qi(l, st(r, e, i));
6520
6520
  return s === null ? null : {
6521
6521
  kind: "move-drag",
6522
6522
  annotationId: t,
@@ -6525,12 +6525,12 @@ var Yh = "_1tyillx1", Jh = {
6525
6525
  }
6526
6526
  commit({ translation: e }) {
6527
6527
  const { annotationId: t, dispatch: r } = this.params;
6528
- lu(e) && r(new Zo({
6528
+ iu(e) && r(new Zo({
6529
6529
  id: t,
6530
6530
  translation: e
6531
6531
  }));
6532
6532
  }
6533
- }, d1 = (e, t, r) => {
6533
+ }, c1 = (e, t, r) => {
6534
6534
  const { commands: a, selectionStore: o } = G(), i = U(), l = J({
6535
6535
  annotations: _((u) => u.spec.annotations),
6536
6536
  panelRect: r
@@ -6538,7 +6538,7 @@ var Yh = "_1tyillx1", Jh = {
6538
6538
  O(() => () => c.current?.finish(!1), []), O(() => {
6539
6539
  const u = (p) => {
6540
6540
  const { editTargetUnderPointer: g, standingInteraction: f } = i.getState();
6541
- return g !== null && f === null && p.pointerType === "mouse" && u1(p.target, e) ? g : Je(p.clientX, p.clientY, e);
6541
+ return g !== null && f === null && p.pointerType === "mouse" && d1(p.target, e) ? g : Qe(p.clientX, p.clientY, e);
6542
6542
  }, d = (p, g) => {
6543
6543
  if (c.current !== null || !Fo(l.current.annotations, g.id)) return;
6544
6544
  try {
@@ -6547,7 +6547,7 @@ var Yh = "_1tyillx1", Jh = {
6547
6547
  return;
6548
6548
  }
6549
6549
  p.preventDefault();
6550
- const f = new c1({
6550
+ const f = new s1({
6551
6551
  handle: e,
6552
6552
  pointerId: p.pointerId,
6553
6553
  annotationId: g.id,
@@ -6575,7 +6575,7 @@ var Yh = "_1tyillx1", Jh = {
6575
6575
  }
6576
6576
  }, v = (p) => {
6577
6577
  if (xt(p.target)) return;
6578
- const g = Je(p.clientX, p.clientY, e);
6578
+ const g = Qe(p.clientX, p.clientY, e);
6579
6579
  g !== null && l.current.annotations.textAnnotations.some((f) => f.id === g.id) && (o.getState().setSelection([g]), i.getState().setCaret(g.id));
6580
6580
  };
6581
6581
  return document.addEventListener("pointerdown", h), document.addEventListener("dblclick", v), () => {
@@ -6589,7 +6589,7 @@ var Yh = "_1tyillx1", Jh = {
6589
6589
  l,
6590
6590
  s
6591
6591
  ]);
6592
- }, u1 = (e, t) => e instanceof Node && t.contains(e), h1 = (e) => {
6592
+ }, d1 = (e, t) => e instanceof Node && t.contains(e), u1 = (e) => {
6593
6593
  const { selectionStore: t, commands: r, chartId: a } = G(), o = U(), i = J(_((u) => u.spec.annotations.textAnnotations)), l = ie((u) => {
6594
6594
  const { selection: d } = t.getState(), h = wt(d);
6595
6595
  h !== null && (u.preventDefault(), r.dispatch(new ke({ id: h })), e.focus({ preventScroll: !0 }));
@@ -6598,7 +6598,7 @@ var Yh = "_1tyillx1", Jh = {
6598
6598
  r,
6599
6599
  t
6600
6600
  ]), s = ie((u) => {
6601
- if ($e(u.target, a)) return;
6601
+ if (Ue(u.target, a)) return;
6602
6602
  const d = wt(t.getState().selection);
6603
6603
  d !== null && i.current.some((h) => h.id === d) && (u.preventDefault(), o.getState().setCaret(d));
6604
6604
  }, [
@@ -6616,7 +6616,7 @@ var Yh = "_1tyillx1", Jh = {
6616
6616
  d.setCaret(null), e.focus({ preventScroll: !0 });
6617
6617
  return;
6618
6618
  }
6619
- return $e(u.target, a) ? e.focus({ preventScroll: !0 }) : t.getState().clearSelection();
6619
+ return Ue(u.target, a) ? e.focus({ preventScroll: !0 }) : t.getState().clearSelection();
6620
6620
  }, [
6621
6621
  o,
6622
6622
  t,
@@ -6625,8 +6625,8 @@ var Yh = "_1tyillx1", Jh = {
6625
6625
  ]);
6626
6626
  O(() => {
6627
6627
  const u = (d) => {
6628
- if (!Me(d.target, e, a) || Gc(d.target)) return;
6629
- const h = p1(d.target), v = o.getState().caret !== null && !$e(d.target, a);
6628
+ if (!Ne(d.target, e, a) || Vc(d.target)) return;
6629
+ const h = h1(d.target), v = o.getState().caret !== null && !Ue(d.target, a);
6630
6630
  if (!(h && !v))
6631
6631
  switch (d.key) {
6632
6632
  case "Escape":
@@ -6649,11 +6649,11 @@ var Yh = "_1tyillx1", Jh = {
6649
6649
  a,
6650
6650
  o
6651
6651
  ]);
6652
- }, p1 = (e) => e instanceof HTMLElement && (e.isContentEditable || e instanceof HTMLInputElement || e instanceof HTMLTextAreaElement), m1 = () => {
6653
- const e = Co((l) => l.hover.primary), { layers: t, coordSystem: r } = _(Pe((l) => ({
6652
+ }, h1 = (e) => e instanceof HTMLElement && (e.isContentEditable || e instanceof HTMLInputElement || e instanceof HTMLTextAreaElement), p1 = () => {
6653
+ const e = Co((l) => l.hover.primary), { layers: t, coordSystem: r } = _(Ie((l) => ({
6654
6654
  layers: l.layers,
6655
6655
  coordSystem: l.coordSystem
6656
- }))), { anchorResolver: a, colorScheme: o } = G(), i = M(() => at({ colorScheme: o }), [o]);
6656
+ }))), { anchorResolver: a, colorScheme: o } = G(), i = M(() => Oe({ colorScheme: o }), [o]);
6657
6657
  return M(() => {
6658
6658
  if (e === null) return null;
6659
6659
  const l = t.find((u) => u.id === e.layerId);
@@ -6664,7 +6664,7 @@ var Yh = "_1tyillx1", Jh = {
6664
6664
  purpose: "pin"
6665
6665
  });
6666
6666
  if (s === null) return null;
6667
- const c = Xi(l)(e.observation);
6667
+ const c = Zi(l)(e.observation);
6668
6668
  return c === null ? null : {
6669
6669
  position: s,
6670
6670
  color: i.geomReaders(l).get("color", e.observation),
@@ -6679,9 +6679,9 @@ var Yh = "_1tyillx1", Jh = {
6679
6679
  a,
6680
6680
  i
6681
6681
  ]);
6682
- }, g1 = { kind: "idle" }, La = () => {
6683
- const e = X((a) => a.standingInteraction), t = X((a) => a.chromeUnderPointer), r = m1();
6684
- return M(() => e !== null ? e : r === null ? g1 : {
6682
+ }, m1 = { kind: "idle" }, La = () => {
6683
+ const e = X((a) => a.standingInteraction), t = X((a) => a.chromeUnderPointer), r = p1();
6684
+ return M(() => e !== null ? e : r === null ? m1 : {
6685
6685
  kind: "trigger",
6686
6686
  anchor: r,
6687
6687
  isEngaged: t === "menu-trigger"
@@ -6690,7 +6690,7 @@ var Yh = "_1tyillx1", Jh = {
6690
6690
  r,
6691
6691
  t
6692
6692
  ]);
6693
- }, v1 = (e, t, r) => {
6693
+ }, g1 = (e, t, r) => {
6694
6694
  const a = U(), { selectionStore: o } = G(), { store: i, engine: l } = Ot(), s = J(e), c = J(t), u = J(r);
6695
6695
  O(() => {
6696
6696
  const d = (f) => Wr(f, c.current, a.getState().menuTrigger), h = (f) => {
@@ -6698,7 +6698,7 @@ var Yh = "_1tyillx1", Jh = {
6698
6698
  const y = u.current, P = c.current, C = {
6699
6699
  x: f.clientX - P.x,
6700
6700
  y: f.clientY - P.y
6701
- }, A = f1(C, y) ? l.query(Dt(C, y)) : or;
6701
+ }, A = v1(C, y) ? l.query(Dt(C, y)) : or;
6702
6702
  i.getState().setHoverState(A);
6703
6703
  };
6704
6704
  let v = !1;
@@ -6729,7 +6729,7 @@ var Yh = "_1tyillx1", Jh = {
6729
6729
  c,
6730
6730
  u
6731
6731
  ]);
6732
- }, f1 = (e, t) => e.x >= 0 && e.x <= t.width && e.y >= 0 && e.y <= t.height, b1 = (e, t) => {
6732
+ }, v1 = (e, t) => e.x >= 0 && e.x <= t.width && e.y >= 0 && e.y <= t.height, f1 = (e, t) => {
6733
6733
  const r = U(), a = J(t);
6734
6734
  O(() => {
6735
6735
  let o = null, i = null;
@@ -6745,7 +6745,7 @@ var Yh = "_1tyillx1", Jh = {
6745
6745
  x: p.x - g.x,
6746
6746
  y: p.y - g.y
6747
6747
  })), vt(f.standingInteraction)) return;
6748
- const y = Je(p.x, p.y, e);
6748
+ const y = Qe(p.x, p.y, e);
6749
6749
  f.setEditTargetUnderPointer(y);
6750
6750
  }, c = () => {
6751
6751
  o === null && (o = requestAnimationFrame(s));
@@ -6783,9 +6783,9 @@ var Yh = "_1tyillx1", Jh = {
6783
6783
  case "chrome-popup":
6784
6784
  return !1;
6785
6785
  }
6786
- }, En = "editor", Mn = [], C1 = (e, t, r, a) => {
6787
- const o = La(), { store: i } = Ot(), l = Jn().length > 0, s = X((d) => d.menuTrigger), c = o.kind === "menu", u = M(() => s === null ? Mn : [Vi(s)], [s]);
6788
- b1(e, t), d1(e, t, r), v1(o, t, r), s1(e), h1(e), a1(e, a), O(() => (i.getState().publishPointerRegions(En, u), () => i.getState().publishPointerRegions(En, Mn)), [i, u]), O(() => (i.getState().setPointerSuspended(c || l), () => i.getState().setPointerSuspended(!1)), [
6786
+ }, En = "editor", Mn = [], b1 = (e, t, r, a) => {
6787
+ const o = La(), { store: i } = Ot(), l = Jn().length > 0, s = X((d) => d.menuTrigger), c = o.kind === "menu", u = M(() => s === null ? Mn : [Bi(s)], [s]);
6788
+ f1(e, t), c1(e, t, r), g1(o, t, r), l1(e), u1(e), r1(e, a), O(() => (i.getState().publishPointerRegions(En, u), () => i.getState().publishPointerRegions(En, Mn)), [i, u]), O(() => (i.getState().setPointerSuspended(c || l), () => i.getState().setPointerSuspended(!1)), [
6789
6789
  i,
6790
6790
  c,
6791
6791
  l
@@ -6794,21 +6794,21 @@ var Yh = "_1tyillx1", Jh = {
6794
6794
  const d = i.getState();
6795
6795
  d.setHoverState(or), d.setTooltipAnchor(null);
6796
6796
  }, [i, l]);
6797
- }, y1 = ({ frameElement: e, panelRect: t }) => {
6797
+ }, C1 = ({ frameElement: e, panelRect: t }) => {
6798
6798
  const { measureRef: r, screenRect: a } = Eo(), o = U(), i = X((l) => l.caret?.annotationId ?? null);
6799
6799
  return O(() => (r(e), () => r(null)), [r, e]), O(() => () => {
6800
6800
  const l = o.getState();
6801
6801
  l.releaseInteraction("menu"), l.setCaret(null);
6802
- }, [o]), a === null ? null : /* @__PURE__ */ m(Uc, { children: [i !== null && /* @__PURE__ */ n(S1, {
6802
+ }, [o]), a === null ? null : /* @__PURE__ */ m($c, { children: [i !== null && /* @__PURE__ */ n(y1, {
6803
6803
  annotationId: i,
6804
6804
  panelRect: t
6805
- }), /* @__PURE__ */ n(x1, {
6805
+ }), /* @__PURE__ */ n(S1, {
6806
6806
  frameElement: e,
6807
6807
  frameRect: a,
6808
6808
  panelRect: t
6809
6809
  })] });
6810
- }, S1 = ({ annotationId: e, panelRect: t }) => {
6811
- const r = U(), { textAnnotations: a } = fe(t);
6810
+ }, y1 = ({ annotationId: e, panelRect: t }) => {
6811
+ const r = U(), { textAnnotations: a } = be(t);
6812
6812
  return O(() => {
6813
6813
  a.some(({ id: o }) => o === e) || r.getState().setCaret(null);
6814
6814
  }, [
@@ -6816,7 +6816,7 @@ var Yh = "_1tyillx1", Jh = {
6816
6816
  a,
6817
6817
  r
6818
6818
  ]), null;
6819
- }, x1 = ({ frameElement: e, frameRect: t, panelRect: r }) => {
6819
+ }, S1 = ({ frameElement: e, frameRect: t, panelRect: r }) => {
6820
6820
  const a = M(() => ({
6821
6821
  x: t.left + r.x,
6822
6822
  y: t.top + r.y
@@ -6826,14 +6826,14 @@ var Yh = "_1tyillx1", Jh = {
6826
6826
  r.x,
6827
6827
  r.y
6828
6828
  ]), [o, i] = Q(null);
6829
- return C1(e, a, r, o), /* @__PURE__ */ n(w1, {
6829
+ return b1(e, a, r, o), /* @__PURE__ */ n(x1, {
6830
6830
  frameElement: e,
6831
6831
  frameRect: t,
6832
6832
  panelOrigin: a,
6833
6833
  panelRect: r,
6834
6834
  boxRef: i
6835
6835
  });
6836
- }, w1 = ({ frameElement: e, frameRect: t, panelOrigin: r, panelRect: a, boxRef: o }) => {
6836
+ }, x1 = ({ frameElement: e, frameRect: t, panelOrigin: r, panelRect: a, boxRef: o }) => {
6837
6837
  const i = Bt(), l = La();
6838
6838
  return /* @__PURE__ */ n(To, {
6839
6839
  rect: t,
@@ -6842,54 +6842,54 @@ var Yh = "_1tyillx1", Jh = {
6842
6842
  "data-testid": "editor-overlay",
6843
6843
  boxRef: o,
6844
6844
  children: /* @__PURE__ */ m(ee, { children: [
6845
- /* @__PURE__ */ n(Vu, {
6845
+ /* @__PURE__ */ n(Bu, {
6846
6846
  panelRect: a,
6847
6847
  panelOrigin: r,
6848
6848
  frameRect: t,
6849
6849
  frameElement: e
6850
6850
  }),
6851
- /* @__PURE__ */ n(ph, {
6851
+ /* @__PURE__ */ n(hh, {
6852
6852
  panelRect: a,
6853
6853
  frameRect: t,
6854
6854
  frameElement: e
6855
6855
  }),
6856
- /* @__PURE__ */ n(mu, {
6856
+ /* @__PURE__ */ n(pu, {
6857
6857
  panelRect: a,
6858
6858
  frameRect: t,
6859
6859
  frameElement: e
6860
6860
  }),
6861
- /* @__PURE__ */ n($h, {
6861
+ /* @__PURE__ */ n(Gh, {
6862
6862
  panelRect: a,
6863
6863
  frameRect: t,
6864
6864
  frameElement: e
6865
6865
  }),
6866
- /* @__PURE__ */ n(Xu, { panelRect: a }),
6867
- /* @__PURE__ */ n(nh, { panelRect: a }),
6868
- /* @__PURE__ */ n(Dd, { panelRect: a }),
6869
6866
  /* @__PURE__ */ n(Zu, { panelRect: a }),
6870
- /* @__PURE__ */ n(t1, {
6867
+ /* @__PURE__ */ n(th, { panelRect: a }),
6868
+ /* @__PURE__ */ n(Rd, { panelRect: a }),
6869
+ /* @__PURE__ */ n(qu, { panelRect: a }),
6870
+ /* @__PURE__ */ n(e1, {
6871
6871
  interaction: l,
6872
6872
  panelRect: a
6873
6873
  }),
6874
- /* @__PURE__ */ n(Pd, {
6874
+ /* @__PURE__ */ n(Ld, {
6875
6875
  interaction: l,
6876
6876
  panelOrigin: r
6877
6877
  })
6878
6878
  ] })
6879
6879
  });
6880
- }, Qm = ({ slots: e, ...t }) => /* @__PURE__ */ n(ls, {
6880
+ }, Qm = ({ slots: e, ...t }) => /* @__PURE__ */ n(is, {
6881
6881
  locale: No(),
6882
6882
  children: /* @__PURE__ */ n(go, { children: /* @__PURE__ */ n(io, {
6883
- editors: Hc,
6883
+ editors: Fc,
6884
6884
  children: /* @__PURE__ */ n(Mo, {
6885
6885
  slots: M(() => ({
6886
- EditorSurface: y1,
6886
+ EditorSurface: C1,
6887
6887
  ...e
6888
6888
  }), [e]),
6889
6889
  ...t
6890
6890
  })
6891
6891
  }) })
6892
- }), Pa = Oe(null), Ia = ({ labelId: e, controlId: t, children: r }) => {
6892
+ }), Pa = Re(null), Ia = ({ labelId: e, controlId: t, children: r }) => {
6893
6893
  const a = M(() => {
6894
6894
  let o = null;
6895
6895
  return {
@@ -6903,17 +6903,17 @@ var Yh = "_1tyillx1", Jh = {
6903
6903
  children: r
6904
6904
  });
6905
6905
  }, ge = ({ id: e, ariaLabel: t, ariaLabelledBy: r }, a = !0) => {
6906
- const o = Le(Pa), i = Ae(), [l] = Q(() => a ? o?.claimControlId(i) ?? !1 : !1), s = e ?? (l ? o?.controlId : void 0), c = r ?? (t === void 0 ? o?.labelId : void 0);
6906
+ const o = Pe(Pa), i = Ae(), [l] = Q(() => a ? o?.claimControlId(i) ?? !1 : !1), s = e ?? (l ? o?.controlId : void 0), c = r ?? (t === void 0 ? o?.labelId : void 0);
6907
6907
  return {
6908
6908
  ...s !== void 0 && { id: s },
6909
6909
  ...t !== void 0 && { "aria-label": t },
6910
6910
  ...c !== void 0 && { "aria-labelledby": c }
6911
6911
  };
6912
6912
  };
6913
- var T1 = {
6913
+ var w1 = {
6914
6914
  default: "woi4bh4 woi4bh3",
6915
6915
  tile: "woi4bh5 woi4bh3"
6916
- }, A1 = ({ label: e, icon: t, onClick: r, variant: a = "default", isDisabled: o, ariaLabel: i, ariaLabelledBy: l, id: s }) => {
6916
+ }, T1 = ({ label: e, icon: t, onClick: r, variant: a = "default", isDisabled: o, ariaLabel: i, ariaLabelledBy: l, id: s }) => {
6917
6917
  const c = ge({
6918
6918
  id: s,
6919
6919
  ariaLabel: i,
@@ -6921,7 +6921,7 @@ var T1 = {
6921
6921
  }), u = a === "tile";
6922
6922
  return /* @__PURE__ */ m("button", {
6923
6923
  type: "button",
6924
- className: T1[a],
6924
+ className: w1[a],
6925
6925
  disabled: o,
6926
6926
  onClick: r,
6927
6927
  ...c,
@@ -6933,12 +6933,12 @@ var T1 = {
6933
6933
  children: e
6934
6934
  })]
6935
6935
  });
6936
- }, qt = Oe(null), H = () => {
6937
- const e = Le(qt);
6936
+ }, qt = Re(null), H = () => {
6937
+ const e = Pe(qt);
6938
6938
  if (!e) throw new Error("An editing section must sit inside an <EditorPanel.Root> bound to a graph — pass it a `handle`, or render the panel inside a <GraphProvider>.");
6939
6939
  return e;
6940
6940
  }, Ea = ({ children: e, onKeyDown: t, ...r }) => {
6941
- const a = Le(qt);
6941
+ const a = Pe(qt);
6942
6942
  return /* @__PURE__ */ n("div", {
6943
6943
  onKeyDown: (i) => {
6944
6944
  if (t?.(i), !a || i.defaultPrevented) return;
@@ -6977,15 +6977,15 @@ var T1 = {
6977
6977
  }
6978
6978
  }
6979
6979
  };
6980
- }, k1 = "eh8dvc0", L1 = "eh8dvc1 uz3g760", P1 = "eh8dvc2 uz3g761";
6981
- var I1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, placeholder: l, prefix: s, suffix: c, isDisabled: u, hasError: d, ariaLabel: h, ariaLabelledBy: v, id: p }) => {
6980
+ }, A1 = "eh8dvc0", k1 = "eh8dvc1 uz3g760", L1 = "eh8dvc2 uz3g761";
6981
+ var P1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, placeholder: l, prefix: s, suffix: c, isDisabled: u, hasError: d, ariaLabel: h, ariaLabelledBy: v, id: p }) => {
6982
6982
  const g = ge({
6983
6983
  id: p,
6984
6984
  ariaLabel: h,
6985
6985
  ariaLabelledBy: v
6986
6986
  }), { commitUnlessHeldKey: f, gestureHandlers: y } = ct(r);
6987
6987
  return /* @__PURE__ */ n(sn.Root, {
6988
- className: k1,
6988
+ className: A1,
6989
6989
  value: e,
6990
6990
  onValueChange: (P) => t(P),
6991
6991
  onValueCommitted: (P, C) => {
@@ -6996,7 +6996,7 @@ var I1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, placeho
6996
6996
  step: i,
6997
6997
  disabled: u,
6998
6998
  children: /* @__PURE__ */ m(Ea, {
6999
- className: L1,
6999
+ className: k1,
7000
7000
  "data-error": d === !0,
7001
7001
  "data-disabled": u === !0 ? "" : void 0,
7002
7002
  children: [
@@ -7005,7 +7005,7 @@ var I1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, placeho
7005
7005
  children: s
7006
7006
  }),
7007
7007
  /* @__PURE__ */ n(sn.Input, {
7008
- className: P1,
7008
+ className: L1,
7009
7009
  placeholder: l,
7010
7010
  ...y,
7011
7011
  "aria-invalid": d === !0 ? !0 : void 0,
@@ -7018,22 +7018,22 @@ var I1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, placeho
7018
7018
  ]
7019
7019
  })
7020
7020
  });
7021
- }, E1 = "_1b7s5f0", Se = {
7021
+ }, I1 = "_1b7s5f0", xe = {
7022
7022
  1: "_1b7s5f1",
7023
7023
  2: "_1b7s5f2",
7024
7024
  3: "_1b7s5f3",
7025
7025
  4: "_1b7s5f4",
7026
7026
  5: "_1b7s5f5",
7027
7027
  6: "_1b7s5f6"
7028
- }, M1 = "_1b7s5f7";
7029
- var N1 = 6, O1 = ({ options: e, value: t, onChange: r, onCommit: a, columns: o, itemLayout: i = "tile", isDisabled: l, ariaLabel: s, ariaLabelledBy: c, id: u }) => {
7028
+ }, E1 = "_1b7s5f7";
7029
+ var M1 = 6, N1 = ({ options: e, value: t, onChange: r, onCommit: a, columns: o, itemLayout: i = "tile", isDisabled: l, ariaLabel: s, ariaLabelledBy: c, id: u }) => {
7030
7030
  const d = ge({
7031
7031
  id: u,
7032
7032
  ariaLabel: s,
7033
7033
  ariaLabelledBy: c
7034
7034
  }), h = i === "swatch", { commitAfterChange: v, gestureHandlers: p } = ct(a);
7035
7035
  return /* @__PURE__ */ n(Tr, {
7036
- className: de(E1, R1(o ?? e.length)),
7036
+ className: de(I1, O1(o ?? e.length)),
7037
7037
  value: t,
7038
7038
  onValueChange: (g) => {
7039
7039
  r(g), v();
@@ -7044,7 +7044,7 @@ var N1 = 6, O1 = ({ options: e, value: t, onChange: r, onCommit: a, columns: o,
7044
7044
  children: e.map((g) => /* @__PURE__ */ m(wr.Root, {
7045
7045
  value: g.value,
7046
7046
  disabled: g.isDisabled,
7047
- className: de(M1, h && "_1b7s5f8"),
7047
+ className: de(E1, h && "_1b7s5f8"),
7048
7048
  "aria-label": h ? g.label : void 0,
7049
7049
  children: [g.icon, !h && /* @__PURE__ */ n("span", {
7050
7050
  className: "_1b7s5f9",
@@ -7052,23 +7052,23 @@ var N1 = 6, O1 = ({ options: e, value: t, onChange: r, onCommit: a, columns: o,
7052
7052
  })]
7053
7053
  }, g.value))
7054
7054
  });
7055
- }, R1 = (e) => {
7056
- switch (Math.min(Math.max(Math.round(e), 1), N1)) {
7055
+ }, O1 = (e) => {
7056
+ switch (Math.min(Math.max(Math.round(e), 1), M1)) {
7057
7057
  case 1:
7058
- return Se[1];
7058
+ return xe[1];
7059
7059
  case 2:
7060
- return Se[2];
7060
+ return xe[2];
7061
7061
  case 3:
7062
- return Se[3];
7062
+ return xe[3];
7063
7063
  case 4:
7064
- return Se[4];
7064
+ return xe[4];
7065
7065
  case 5:
7066
- return Se[5];
7066
+ return xe[5];
7067
7067
  default:
7068
- return Se[6];
7068
+ return xe[6];
7069
7069
  }
7070
- }, D1 = "_1g5x15w0 uz3g760", z1 = "_1g5x15w1", _1 = "_1g5x15w2", Nn = "_1g5x15w3", F1 = "_1g5x15w4", H1 = "_1g5x15w5", B1 = "_1g5x15w6", V1 = "_1g5x15w7";
7071
- var G1 = ({ options: e, value: t, onChange: r, placeholder: a, isDisabled: o, hasError: i, ariaLabel: l, ariaLabelledBy: s, id: c }) => {
7070
+ }, R1 = "_1g5x15w0 uz3g760", D1 = "_1g5x15w1", z1 = "_1g5x15w2", Nn = "_1g5x15w3", _1 = "_1g5x15w4", F1 = "_1g5x15w5", H1 = "_1g5x15w6", B1 = "_1g5x15w7";
7071
+ var V1 = ({ options: e, value: t, onChange: r, placeholder: a, isDisabled: o, hasError: i, ariaLabel: l, ariaLabelledBy: s, id: c }) => {
7072
7072
  const u = ge({
7073
7073
  id: c,
7074
7074
  ariaLabel: l,
@@ -7083,32 +7083,32 @@ var G1 = ({ options: e, value: t, onChange: r, placeholder: a, isDisabled: o, ha
7083
7083
  label: d.label
7084
7084
  })),
7085
7085
  children: [/* @__PURE__ */ m(ae.Trigger, {
7086
- className: D1,
7086
+ className: R1,
7087
7087
  "data-error": i === !0,
7088
7088
  ...u,
7089
7089
  children: [/* @__PURE__ */ n(ae.Value, {
7090
- className: z1,
7091
- children: (d) => $1(e, d, a)
7090
+ className: D1,
7091
+ children: (d) => G1(e, d, a)
7092
7092
  }), /* @__PURE__ */ n(ae.Icon, {
7093
7093
  className: Nn,
7094
- children: /* @__PURE__ */ n(Re, { size: "sm" })
7094
+ children: /* @__PURE__ */ n(De, { size: "sm" })
7095
7095
  })]
7096
7096
  }), /* @__PURE__ */ n(ae.Portal, {
7097
7097
  container: le(),
7098
7098
  children: /* @__PURE__ */ n(ee, { children: /* @__PURE__ */ n(ae.Positioner, {
7099
- className: F1,
7099
+ className: _1,
7100
7100
  sideOffset: 4,
7101
7101
  alignItemWithTrigger: !1,
7102
7102
  children: /* @__PURE__ */ n(ae.Popup, {
7103
- className: H1,
7103
+ className: F1,
7104
7104
  children: e.map((d) => /* @__PURE__ */ m(ae.Item, {
7105
7105
  value: d.value,
7106
7106
  disabled: d.isDisabled,
7107
- className: B1,
7107
+ className: H1,
7108
7108
  children: [
7109
7109
  d.icon,
7110
7110
  /* @__PURE__ */ m("span", {
7111
- className: V1,
7111
+ className: B1,
7112
7112
  children: [/* @__PURE__ */ n(ae.ItemText, { children: d.label }), d.description !== void 0 && /* @__PURE__ */ n("span", {
7113
7113
  className: "_1g5x15w8",
7114
7114
  children: d.description
@@ -7124,19 +7124,19 @@ var G1 = ({ options: e, value: t, onChange: r, placeholder: a, isDisabled: o, ha
7124
7124
  }) })
7125
7125
  })]
7126
7126
  });
7127
- }, $1 = (e, t, r) => t === null ? /* @__PURE__ */ n("span", {
7128
- className: _1,
7127
+ }, G1 = (e, t, r) => t === null ? /* @__PURE__ */ n("span", {
7128
+ className: z1,
7129
7129
  children: r
7130
- }) : U1(e, t), U1 = (e, t) => e.find((r) => r.value === t)?.label ?? t, W1 = "vod76w0", K1 = "vod76w1", q1 = "vod76w2", Z1 = "vod76w3", X1 = "vod76w4", j1 = "vod76w5";
7131
- var Y1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, suffix: l, formatValue: s, isDisabled: c, ariaLabel: u, ariaLabelledBy: d }) => {
7130
+ }) : $1(e, t), $1 = (e, t) => e.find((r) => r.value === t)?.label ?? t, U1 = "vod76w0", W1 = "vod76w1", K1 = "vod76w2", q1 = "vod76w3", Z1 = "vod76w4", X1 = "vod76w5";
7131
+ var j1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, suffix: l, formatValue: s, isDisabled: c, ariaLabel: u, ariaLabelledBy: d }) => {
7132
7132
  const h = ge({
7133
7133
  ariaLabel: u,
7134
7134
  ariaLabelledBy: d
7135
- }, !1), v = J1(e, l, s), { commitUnlessHeldKey: p, gestureHandlers: g } = ct(r);
7135
+ }, !1), v = Y1(e, l, s), { commitUnlessHeldKey: p, gestureHandlers: g } = ct(r);
7136
7136
  return /* @__PURE__ */ m("div", {
7137
- className: W1,
7137
+ className: U1,
7138
7138
  children: [/* @__PURE__ */ n(oe.Root, {
7139
- className: K1,
7139
+ className: W1,
7140
7140
  value: e,
7141
7141
  onValueChange: (f) => t(f),
7142
7142
  onValueCommitted: (f, y) => {
@@ -7147,11 +7147,11 @@ var Y1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, suffix:
7147
7147
  step: i,
7148
7148
  disabled: c,
7149
7149
  children: /* @__PURE__ */ n(oe.Control, {
7150
- className: q1,
7150
+ className: K1,
7151
7151
  children: /* @__PURE__ */ m(oe.Track, {
7152
- className: Z1,
7153
- children: [/* @__PURE__ */ n(oe.Indicator, { className: X1 }), /* @__PURE__ */ n(oe.Thumb, {
7154
- className: j1,
7152
+ className: q1,
7153
+ children: [/* @__PURE__ */ n(oe.Indicator, { className: Z1 }), /* @__PURE__ */ n(oe.Thumb, {
7154
+ className: X1,
7155
7155
  ...g,
7156
7156
  ...h
7157
7157
  })]
@@ -7162,7 +7162,7 @@ var Y1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, suffix:
7162
7162
  children: v
7163
7163
  })]
7164
7164
  });
7165
- }, J1 = (e, t, r) => r !== void 0 ? r(e) : t !== void 0 ? `${e}${t}` : null, Q1 = "_1hyrlw60", ep = "_1hyrlw61", tp = ({ isChecked: e, onChange: t, isDisabled: r, ariaLabel: a, ariaLabelledBy: o, id: i }) => {
7165
+ }, Y1 = (e, t, r) => r !== void 0 ? r(e) : t !== void 0 ? `${e}${t}` : null, J1 = "_1hyrlw60", Q1 = "_1hyrlw61", ep = ({ isChecked: e, onChange: t, isDisabled: r, ariaLabel: a, ariaLabelledBy: o, id: i }) => {
7166
7166
  const l = ge({
7167
7167
  id: i,
7168
7168
  ariaLabel: a,
@@ -7172,21 +7172,21 @@ var Y1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, suffix:
7172
7172
  checked: e,
7173
7173
  onCheckedChange: (s) => t(s),
7174
7174
  disabled: r,
7175
- className: Q1,
7175
+ className: J1,
7176
7176
  ...l,
7177
- children: /* @__PURE__ */ n(cn.Thumb, { className: ep })
7177
+ children: /* @__PURE__ */ n(cn.Thumb, { className: Q1 })
7178
7178
  });
7179
- }, np = "uz3g761", rp = "tpcnun0 uz3g760", ap = ({ value: e, onChange: t, onCommit: r, placeholder: a, isDisabled: o, hasError: i, ariaLabel: l, ariaLabelledBy: s, id: c }) => {
7179
+ }, tp = "uz3g761", np = "tpcnun0 uz3g760", rp = ({ value: e, onChange: t, onCommit: r, placeholder: a, isDisabled: o, hasError: i, ariaLabel: l, ariaLabelledBy: s, id: c }) => {
7180
7180
  const u = ge({
7181
7181
  id: c,
7182
7182
  ariaLabel: l,
7183
7183
  ariaLabelledBy: s
7184
7184
  });
7185
7185
  return /* @__PURE__ */ n(Ea, {
7186
- className: rp,
7186
+ className: np,
7187
7187
  "data-error": i === !0,
7188
- children: /* @__PURE__ */ n(Ul, {
7189
- className: np,
7188
+ children: /* @__PURE__ */ n($l, {
7189
+ className: tp,
7190
7190
  value: e,
7191
7191
  onValueChange: (d) => t(d),
7192
7192
  onBlur: r,
@@ -7196,15 +7196,15 @@ var Y1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, suffix:
7196
7196
  ...u
7197
7197
  })
7198
7198
  });
7199
- }, op = "cnu9yl0", ip = "cnu9yl1";
7200
- var lp = ({ options: e, value: t, onChange: r, onCommit: a, itemLayout: o = "inline", isDisabled: i, ariaLabel: l, ariaLabelledBy: s, id: c }) => {
7199
+ }, ap = "cnu9yl0", op = "cnu9yl1";
7200
+ var ip = ({ options: e, value: t, onChange: r, onCommit: a, itemLayout: o = "inline", isDisabled: i, ariaLabel: l, ariaLabelledBy: s, id: c }) => {
7201
7201
  const u = ge({
7202
7202
  id: c,
7203
7203
  ariaLabel: l,
7204
7204
  ariaLabelledBy: s
7205
7205
  }), d = o === "stacked", { commitAfterChange: h, gestureHandlers: v } = ct(a);
7206
7206
  return /* @__PURE__ */ n(Tr, {
7207
- className: op,
7207
+ className: ap,
7208
7208
  value: t,
7209
7209
  onValueChange: (p) => {
7210
7210
  r(p), h();
@@ -7215,27 +7215,27 @@ var lp = ({ options: e, value: t, onChange: r, onCommit: a, itemLayout: o = "inl
7215
7215
  children: e.map((p) => /* @__PURE__ */ m(wr.Root, {
7216
7216
  value: p.value,
7217
7217
  disabled: p.isDisabled,
7218
- className: de(ip, d && "cnu9yl2"),
7219
- "aria-label": sp(p, d),
7218
+ className: de(op, d && "cnu9yl2"),
7219
+ "aria-label": lp(p, d),
7220
7220
  children: [p.icon, Na(p, d) && /* @__PURE__ */ n("span", {
7221
7221
  className: "cnu9yl3",
7222
7222
  children: p.label
7223
7223
  })]
7224
7224
  }, p.value))
7225
7225
  });
7226
- }, Na = (e, t) => e.icon === void 0 || t, sp = (e, t) => {
7226
+ }, Na = (e, t) => e.icon === void 0 || t, lp = (e, t) => {
7227
7227
  if (!Na(e, t))
7228
7228
  return e.label;
7229
7229
  }, Oa = {
7230
- ToggleGroup: lp,
7231
- Switch: tp,
7232
- Slider: Y1,
7233
- RadioGrid: O1,
7234
- Button: A1,
7235
- TextField: ap,
7236
- NumberField: I1,
7237
- Select: G1
7238
- }, Ra = Oe(Oa), cp = ({ controls: e, children: t }) => {
7230
+ ToggleGroup: ip,
7231
+ Switch: ep,
7232
+ Slider: j1,
7233
+ RadioGrid: N1,
7234
+ Button: T1,
7235
+ TextField: rp,
7236
+ NumberField: P1,
7237
+ Select: V1
7238
+ }, Ra = Re(Oa), sp = ({ controls: e, children: t }) => {
7239
7239
  const r = M(() => ({
7240
7240
  ...Oa,
7241
7241
  ...e
@@ -7244,39 +7244,39 @@ var lp = ({ options: e, value: t, onChange: r, onCommit: a, itemLayout: o = "inl
7244
7244
  value: r,
7245
7245
  children: t
7246
7246
  });
7247
- }, B = () => Le(Ra), dp = "_12lhx9e0", Da = ({ children: e }) => /* @__PURE__ */ n("div", {
7248
- className: dp,
7247
+ }, B = () => Pe(Ra), cp = "_12lhx9e0", Da = ({ children: e }) => /* @__PURE__ */ n("div", {
7248
+ className: cp,
7249
7249
  children: e
7250
- }), up = "_139ohwv0", q = ({ children: e }) => /* @__PURE__ */ n("div", {
7251
- className: up,
7250
+ }), dp = "_139ohwv0", q = ({ children: e }) => /* @__PURE__ */ n("div", {
7251
+ className: dp,
7252
7252
  children: e
7253
- }), za = Oe(null), hp = za.Provider, pp = () => {
7254
- const e = Le(za);
7253
+ }), za = Re(null), up = za.Provider, hp = () => {
7254
+ const e = Pe(za);
7255
7255
  if (!e) throw new Error("A section must be rendered inside <EditorPanel.Root>.");
7256
7256
  return e;
7257
- }, mp = "_1jlczkt0", gp = "data-graphy-editor-panel", vp = {
7257
+ }, pp = "_1jlczkt0", mp = "data-graphy-editor-panel", gp = {
7258
7258
  List: q,
7259
7259
  Grid: Da
7260
7260
  };
7261
- function fp(e) {
7261
+ function vp(e) {
7262
7262
  if (e === void 0) return !1;
7263
7263
  const t = e.split(/\s+/);
7264
7264
  return t.includes("_1ii3bsb0") || t.includes("_1ii3bsb1");
7265
7265
  }
7266
- var bp = ({ handle: e, children: t, controls: r, defaultExpandedSection: a = void 0, className: o }) => {
7267
- const i = Lo(e), { themeClass: l, inlineVarsStyle: s } = nt(), [c, u] = Q(() => a ? [a] : []), d = M(() => ({
7266
+ var fp = ({ handle: e, children: t, controls: r, defaultExpandedSection: a = void 0, className: o }) => {
7267
+ const i = Lo(e), { themeClass: l, inlineVarsStyle: s } = rt(), [c, u] = Q(() => a ? [a] : []), d = M(() => ({
7268
7268
  expandSection: (h) => u([h]),
7269
7269
  collapseAllSections: () => u([])
7270
7270
  }), []);
7271
7271
  return /* @__PURE__ */ n(qt.Provider, {
7272
7272
  value: i,
7273
- children: /* @__PURE__ */ n(cp, {
7273
+ children: /* @__PURE__ */ n(sp, {
7274
7274
  controls: r,
7275
- children: /* @__PURE__ */ n(hp, {
7275
+ children: /* @__PURE__ */ n(up, {
7276
7276
  value: d,
7277
- children: /* @__PURE__ */ n(Ee.Root, {
7278
- [gp]: "",
7279
- className: de(mp, o, { [l]: !fp(o) }),
7277
+ children: /* @__PURE__ */ n(Me.Root, {
7278
+ [mp]: "",
7279
+ className: de(pp, o, { [l]: !vp(o) }),
7280
7280
  style: s,
7281
7281
  value: c,
7282
7282
  onValueChange: (h) => u(h),
@@ -7286,12 +7286,12 @@ var bp = ({ handle: e, children: t, controls: r, defaultExpandedSection: a = voi
7286
7286
  })
7287
7287
  });
7288
7288
  }, _a = {
7289
- Root: bp,
7290
- Controls: vp
7289
+ Root: fp,
7290
+ Controls: gp
7291
7291
  }, On = {
7292
7292
  stack: "pr583x0",
7293
7293
  grid: "pr583x1"
7294
- }, Rn = "pr583x2", Cp = {
7294
+ }, Rn = "pr583x2", bp = {
7295
7295
  plain: "pr583x4 pr583x3",
7296
7296
  withIcon: "pr583x5 pr583x3"
7297
7297
  }, S = ({ label: e, layout: t = "grid", icon: r, children: a }) => {
@@ -7307,7 +7307,7 @@ var bp = ({ handle: e, children: t, controls: r, defaultExpandedSection: a = voi
7307
7307
  children: [/* @__PURE__ */ m("label", {
7308
7308
  id: o,
7309
7309
  htmlFor: i,
7310
- className: Cp[r === void 0 ? "plain" : "withIcon"],
7310
+ className: bp[r === void 0 ? "plain" : "withIcon"],
7311
7311
  children: [r !== void 0 && /* @__PURE__ */ n("span", {
7312
7312
  "aria-hidden": "true",
7313
7313
  children: r
@@ -7321,7 +7321,7 @@ var bp = ({ handle: e, children: t, controls: r, defaultExpandedSection: a = voi
7321
7321
  })
7322
7322
  })]
7323
7323
  });
7324
- }, yp = (e) => /* @__PURE__ */ n(x, {
7324
+ }, Cp = (e) => /* @__PURE__ */ n(x, {
7325
7325
  ...e,
7326
7326
  children: /* @__PURE__ */ n("g", {
7327
7327
  stroke: "currentColor",
@@ -7330,15 +7330,15 @@ var bp = ({ handle: e, children: t, controls: r, defaultExpandedSection: a = voi
7330
7330
  strokeLinejoin: "round",
7331
7331
  children: /* @__PURE__ */ n("path", { d: "m9 6 6 6-6 6" })
7332
7332
  })
7333
- }), Zt = "_40zvwv0", Xt = "_40zvwv1", Sp = "_40zvwv2", Fa = "_40zvwv3", xp = "_40zvwv4 _40zvwv3";
7334
- var wp = "_40zvwv6";
7335
- var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory: a, onOpenChange: o, children: i }) => t === "collapsible" ? /* @__PURE__ */ n(kp, {
7333
+ }), Zt = "_40zvwv0", Xt = "_40zvwv1", yp = "_40zvwv2", Fa = "_40zvwv3", Sp = "_40zvwv4 _40zvwv3";
7334
+ var xp = "_40zvwv6";
7335
+ var wp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory: a, onOpenChange: o, children: i }) => t === "collapsible" ? /* @__PURE__ */ n(Ap, {
7336
7336
  title: e,
7337
7337
  preview: r,
7338
7338
  accessory: a,
7339
7339
  onOpenChange: o,
7340
7340
  children: i
7341
- }) : t === "inline" && r === void 0 ? /* @__PURE__ */ n(Ap, {
7341
+ }) : t === "inline" && r === void 0 ? /* @__PURE__ */ n(Tp, {
7342
7342
  title: e,
7343
7343
  accessory: a,
7344
7344
  children: i
@@ -7361,7 +7361,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7361
7361
  })
7362
7362
  ]
7363
7363
  }), /* @__PURE__ */ n("div", { children: i })]
7364
- }), Ap = ({ title: e, accessory: t, children: r }) => {
7364
+ }), Tp = ({ title: e, accessory: t, children: r }) => {
7365
7365
  const a = Ae(), o = Ae();
7366
7366
  return /* @__PURE__ */ n("div", {
7367
7367
  className: Zt,
@@ -7371,11 +7371,11 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7371
7371
  /* @__PURE__ */ n("label", {
7372
7372
  id: a,
7373
7373
  htmlFor: o,
7374
- className: xp,
7374
+ className: Sp,
7375
7375
  children: e
7376
7376
  }),
7377
7377
  /* @__PURE__ */ n("span", {
7378
- className: wp,
7378
+ className: xp,
7379
7379
  children: /* @__PURE__ */ n(Ia, {
7380
7380
  labelId: a,
7381
7381
  controlId: o,
@@ -7389,18 +7389,18 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7389
7389
  ]
7390
7390
  })
7391
7391
  });
7392
- }, kp = ({ title: e, preview: t, accessory: r, onOpenChange: a, children: o }) => {
7392
+ }, Ap = ({ title: e, preview: t, accessory: r, onOpenChange: a, children: o }) => {
7393
7393
  const i = k();
7394
- return /* @__PURE__ */ m(Ee.Item, {
7394
+ return /* @__PURE__ */ m(Me.Item, {
7395
7395
  value: e,
7396
7396
  className: Zt,
7397
7397
  onOpenChange: a,
7398
- children: [/* @__PURE__ */ m(Ee.Header, {
7398
+ children: [/* @__PURE__ */ m(Me.Header, {
7399
7399
  className: Xt,
7400
7400
  render: /* @__PURE__ */ n("div", {}),
7401
7401
  children: [
7402
- /* @__PURE__ */ n(Ee.Trigger, {
7403
- className: Sp,
7402
+ /* @__PURE__ */ n(Me.Trigger, {
7403
+ className: yp,
7404
7404
  "aria-label": i("editor.accessibility.toggleSection", { title: e })
7405
7405
  }),
7406
7406
  /* @__PURE__ */ n("span", {
@@ -7416,14 +7416,14 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7416
7416
  children: r
7417
7417
  }),
7418
7418
  /* @__PURE__ */ n("span", {
7419
- className: Tp,
7420
- children: /* @__PURE__ */ n(yp, { size: "sm" })
7419
+ className: wp,
7420
+ children: /* @__PURE__ */ n(Cp, { size: "sm" })
7421
7421
  })
7422
7422
  ]
7423
- }), /* @__PURE__ */ n(Ee.Panel, { children: /* @__PURE__ */ n("div", { children: o }) })]
7423
+ }), /* @__PURE__ */ n(Me.Panel, { children: /* @__PURE__ */ n("div", { children: o }) })]
7424
7424
  });
7425
- }, Lp = ({ title: e, isChecked: t, onToggle: r, isDisabled: a, preview: o, children: i }) => {
7426
- const { expandSection: l, collapseAllSections: s } = pp(), { Switch: c } = B();
7425
+ }, kp = ({ title: e, isChecked: t, onToggle: r, isDisabled: a, preview: o, children: i }) => {
7426
+ const { expandSection: l, collapseAllSections: s } = hp(), { Switch: c } = B();
7427
7427
  return /* @__PURE__ */ n(W, {
7428
7428
  title: e,
7429
7429
  layout: "collapsible",
@@ -7441,15 +7441,15 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7441
7441
  }),
7442
7442
  children: i
7443
7443
  });
7444
- }, Pp = {
7444
+ }, Lp = {
7445
7445
  horizontal: ["bottom", "top"],
7446
7446
  vertical: ["left", "right"]
7447
- }, Ip = {
7447
+ }, Pp = {
7448
7448
  left: "editor.axesPanel.position.left",
7449
7449
  right: "editor.axesPanel.position.right",
7450
7450
  top: "editor.axesPanel.position.top",
7451
7451
  bottom: "editor.axesPanel.position.bottom"
7452
- }, Ep = {
7452
+ }, Ip = {
7453
7453
  x: "editor.axesPanel.mainAxisSection.xAxis",
7454
7454
  y: "editor.axesPanel.mainAxisSection.yAxis"
7455
7455
  }, Dn = ({ axis: e, title: t, layout: r = "collapsible", preview: a }) => {
@@ -7457,48 +7457,48 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7457
7457
  if (!i) return null;
7458
7458
  const h = i.coordSystem.type === "polar" ? i.coordSystem.axisMapping[e].geometry : "linear", v = i.config.axes[e], p = i.scales[e], g = p?.spec, f = g?.scaleType === "continuous" ? g : void 0;
7459
7459
  if (h === "circular" || h === "radial" && f === void 0) return null;
7460
- const y = g !== void 0 && "reverse" in g ? g : void 0, P = g?.scaleType === "continuous" || g?.scaleType === "datetime", C = e === "y" && f !== void 0 && i.layers.some((w) => w.yScaleType === "primary" && w.geom === "bar"), A = f?.transform === "log", L = f?.domainMax ?? null, R = Mp(f), F = (w, he) => w.map((Fe) => ({
7461
- value: Fe,
7462
- label: he(Fe)
7463
- })), D = i.guides.axes.find((w) => w.scaleAestheticKey === e)?.position, E = Pp[D === "bottom" || D === "top" || D === void 0 && e === "x" ? "horizontal" : "vertical"], N = e === "y" ? pl(i.spec) : null, T = N === null ? void 0 : i.spec.layers.find((w) => w.id === N), b = i.guides.legends.drawn.some((w) => E.some((he) => he === w.position)), Z = E.map((w) => ({
7460
+ const y = g !== void 0 && "reverse" in g ? g : void 0, P = g?.scaleType === "continuous" || g?.scaleType === "datetime", C = e === "y" && f !== void 0 && i.layers.some((w) => w.yScaleType === "primary" && w.geom === "bar"), A = f?.transform === "log", L = f?.domainMax ?? null, R = Ep(f), F = (w, he) => w.map((He) => ({
7461
+ value: He,
7462
+ label: he(He)
7463
+ })), D = i.guides.axes.find((w) => w.scaleAestheticKey === e)?.position, E = Lp[D === "bottom" || D === "top" || D === void 0 && e === "x" ? "horizontal" : "vertical"], N = e === "y" ? hl(i.spec) : null, T = N === null ? void 0 : i.spec.layers.find((w) => w.id === N), b = i.guides.legends.drawn.some((w) => E.some((he) => he === w.position)), Z = E.map((w) => ({
7464
7464
  value: w,
7465
- label: l(Ip[w])
7466
- })), ye = F(["auto", "edges"], (w) => l(w === "edges" ? "editor.axesPanel.labelMode.edges" : "editor.axesPanel.labelMode.auto")), _e = F(["linear", "log"], (w) => l(w === "log" ? "editor.axesPanel.scale.log" : "editor.axesPanel.scale.auto")), $a = F([
7465
+ label: l(Pp[w])
7466
+ })), Se = F(["auto", "edges"], (w) => l(w === "edges" ? "editor.axesPanel.labelMode.edges" : "editor.axesPanel.labelMode.auto")), Fe = F(["linear", "log"], (w) => l(w === "log" ? "editor.axesPanel.scale.log" : "editor.axesPanel.scale.auto")), $a = F([
7467
7467
  "auto",
7468
7468
  "zero",
7469
7469
  "custom"
7470
7470
  ], (w) => l(w === "zero" ? "editor.axesPanel.startFrom.zero" : w === "custom" ? "editor.axesPanel.startFrom.custom" : "editor.axesPanel.startFrom.auto")), Ua = F(["auto", "custom"], (w) => l(w === "custom" ? "editor.axesPanel.endAt.custom" : "editor.axesPanel.endAt.auto")), Wa = F(["no", "yes"], (w) => l(w === "yes" ? "editor.axesPanel.yesNo.yes" : "editor.axesPanel.yesNo.no")), Ka = F(["single", "double"], (w) => l(w === "double" ? "editor.axesPanel.axisCount.double" : "editor.axesPanel.axisCount.single")), qa = (w) => {
7471
- o.commands.dispatch(new ni({
7471
+ o.commands.dispatch(new ti({
7472
7472
  axis: e,
7473
7473
  isVisible: w
7474
7474
  }));
7475
7475
  }, Za = (w) => {
7476
- o.commands.dispatch(new Jo({
7476
+ o.commands.dispatch(new Yo({
7477
7477
  axis: e,
7478
7478
  label: w === "" ? null : w
7479
7479
  }), { transient: !0 });
7480
7480
  }, Xa = (w) => {
7481
- o.commands.dispatch(new ti({
7481
+ o.commands.dispatch(new ei({
7482
7482
  axis: e,
7483
7483
  isVisible: w
7484
7484
  }));
7485
7485
  }, ja = (w) => {
7486
- o.commands.dispatch(new ei({
7486
+ o.commands.dispatch(new Qo({
7487
7487
  axis: e,
7488
7488
  tickMode: w === "edges" ? "edges" : "auto"
7489
7489
  }));
7490
7490
  }, Ya = (w) => {
7491
- o.commands.dispatch(new Pi({
7491
+ o.commands.dispatch(new Li({
7492
7492
  scaledAesthetic: e,
7493
7493
  reverse: w === "yes"
7494
7494
  }));
7495
7495
  }, Ja = (w) => {
7496
- o.commands.dispatch(new Ii({
7496
+ o.commands.dispatch(new Pi({
7497
7497
  scaledAesthetic: e,
7498
7498
  transform: w === "log" ? "log" : "linear"
7499
7499
  }));
7500
7500
  }, Jt = (w) => {
7501
- o.commands.dispatch(new He({
7501
+ o.commands.dispatch(new Be({
7502
7502
  scaledAesthetic: e,
7503
7503
  ...w
7504
7504
  }), { transient: !0 });
@@ -7512,13 +7512,13 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7512
7512
  f.zero && o.commands.dispatch(new ln({
7513
7513
  scaledAesthetic: e,
7514
7514
  zero: !1
7515
- })), o.commands.dispatch(new He({
7515
+ })), o.commands.dispatch(new Be({
7516
7516
  scaledAesthetic: e,
7517
7517
  domainMin: zn(p?.domain, "start")
7518
7518
  }));
7519
7519
  return;
7520
7520
  }
7521
- f.domainMin !== null && o.commands.dispatch(new He({
7521
+ f.domainMin !== null && o.commands.dispatch(new Be({
7522
7522
  scaledAesthetic: e,
7523
7523
  domainMin: null
7524
7524
  })), o.commands.dispatch(new ln({
@@ -7528,24 +7528,24 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7528
7528
  }
7529
7529
  }, no = (w) => {
7530
7530
  const he = w === "custom" ? zn(p?.domain, "end") : null;
7531
- o.commands.dispatch(new He({
7531
+ o.commands.dispatch(new Be({
7532
7532
  scaledAesthetic: e,
7533
7533
  domainMax: he
7534
7534
  }));
7535
7535
  }, ro = (w) => {
7536
- T !== void 0 && o.commands.dispatch(new gi({
7536
+ T !== void 0 && o.commands.dispatch(new mi({
7537
7537
  layerId: T.id,
7538
7538
  yScaleType: w === "double" ? "secondary" : "primary"
7539
7539
  }));
7540
7540
  }, ao = (w) => {
7541
- const he = E.find((Fe) => Fe === w);
7542
- he && o.commands.dispatch(new Qo({
7541
+ const he = E.find((He) => He === w);
7542
+ he && o.commands.dispatch(new Jo({
7543
7543
  axis: e,
7544
7544
  position: he
7545
7545
  }));
7546
7546
  };
7547
7547
  return /* @__PURE__ */ n(W, {
7548
- title: t ?? l(Ep[e]),
7548
+ title: t ?? l(Ip[e]),
7549
7549
  layout: r,
7550
7550
  preview: a,
7551
7551
  children: /* @__PURE__ */ m(q, { children: [
@@ -7582,7 +7582,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7582
7582
  label: l("editor.axesPanel.controls.labels"),
7583
7583
  children: /* @__PURE__ */ n(d, {
7584
7584
  value: v.ticks.mode,
7585
- options: ye,
7585
+ options: Se,
7586
7586
  onChange: ja
7587
7587
  })
7588
7588
  }),
@@ -7606,7 +7606,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7606
7606
  label: l("editor.axesPanel.controls.scale"),
7607
7607
  children: /* @__PURE__ */ n(d, {
7608
7608
  value: A ? "log" : "linear",
7609
- options: _e,
7609
+ options: Fe,
7610
7610
  onChange: Ja
7611
7611
  })
7612
7612
  }),
@@ -7645,7 +7645,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7645
7645
  ] })
7646
7646
  ] })
7647
7647
  });
7648
- }, Mp = (e) => e === void 0 ? "auto" : e.domainMin !== null && e.domainMin !== void 0 ? "custom" : e.zero === !0 ? "zero" : "auto", zn = (e, t) => {
7648
+ }, Ep = (e) => e === void 0 ? "auto" : e.domainMin !== null && e.domainMin !== void 0 ? "custom" : e.zero === !0 ? "zero" : "auto", zn = (e, t) => {
7649
7649
  const r = t === "start" ? e?.[0] : e?.[e.length - 1];
7650
7650
  return typeof r == "number" ? r : 0;
7651
7651
  }, jt = ({ value: e, onChange: t }) => {
@@ -7659,11 +7659,11 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7659
7659
  isDisabled: i
7660
7660
  })
7661
7661
  });
7662
- }, Np = ({ title: e, layout: t = "collapsible", preview: r }) => {
7662
+ }, Mp = ({ title: e, layout: t = "collapsible", preview: r }) => {
7663
7663
  const a = H(), o = $(a), i = k(), { Switch: l } = B();
7664
7664
  if (!o) return null;
7665
7665
  const s = o.config.content, c = (d) => {
7666
- a.commands.dispatch(new rt({
7666
+ a.commands.dispatch(new at({
7667
7667
  slot: "caption",
7668
7668
  isVisible: d
7669
7669
  }));
@@ -7685,11 +7685,11 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7685
7685
  onChange: u
7686
7686
  })] })
7687
7687
  });
7688
- }, _n = /^[a-z][a-z\d+.-]*:/i, Op = {}, Rp = ({ title: e, layout: t = "collapsible", preview: r }) => {
7688
+ }, _n = /^[a-z][a-z\d+.-]*:/i, Np = {}, Op = ({ title: e, layout: t = "collapsible", preview: r }) => {
7689
7689
  const a = H(), o = $(a), i = k(), { Switch: l } = B();
7690
7690
  if (!o) return null;
7691
7691
  const s = o.config.content, c = (u) => {
7692
- a.commands.dispatch(new rt({
7692
+ a.commands.dispatch(new at({
7693
7693
  slot: "source",
7694
7694
  isVisible: u
7695
7695
  }));
@@ -7704,12 +7704,12 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7704
7704
  isChecked: s.isSourceVisible,
7705
7705
  onChange: c
7706
7706
  })
7707
- }), /* @__PURE__ */ n(Dp, { source: s.source ?? Op })] })
7707
+ }), /* @__PURE__ */ n(Rp, { source: s.source ?? Np })] })
7708
7708
  });
7709
- }, Dp = ({ source: e }) => {
7709
+ }, Rp = ({ source: e }) => {
7710
7710
  const t = H(), r = k(), { TextField: a } = B(), o = (c) => {
7711
7711
  const u = (c.label ?? "") !== "" || (c.url ?? "") !== "";
7712
- t.commands.dispatch(new oi({ source: u ? c : null }), { transient: !0 });
7712
+ t.commands.dispatch(new ai({ source: u ? c : null }), { transient: !0 });
7713
7713
  }, i = () => {
7714
7714
  const c = e.url ?? "";
7715
7715
  c !== "" && !_n.test(c) && o({
@@ -7729,7 +7729,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7729
7729
  value: e.url ?? "",
7730
7730
  onChange: l,
7731
7731
  onCommit: i,
7732
- hasError: _n.test(e.url ?? "") && !hl(e.url)
7732
+ hasError: _n.test(e.url ?? "") && !ul(e.url)
7733
7733
  })
7734
7734
  }), /* @__PURE__ */ n(S, {
7735
7735
  label: r("editor.elementsPanel.sourceSection.name"),
@@ -7739,11 +7739,11 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7739
7739
  onCommit: t.commands.seal
7740
7740
  })
7741
7741
  })] });
7742
- }, zp = ({ title: e, layout: t = "collapsible", preview: r }) => {
7742
+ }, Dp = ({ title: e, layout: t = "collapsible", preview: r }) => {
7743
7743
  const a = H(), o = $(a), i = k(), { Switch: l } = B();
7744
7744
  if (!o) return null;
7745
7745
  const s = o.config.content, c = (d) => {
7746
- a.commands.dispatch(new rt({
7746
+ a.commands.dispatch(new at({
7747
7747
  slot: "subtitle",
7748
7748
  isVisible: d
7749
7749
  }));
@@ -7776,15 +7776,26 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7776
7776
  2.5,
7777
7777
  3,
7778
7778
  4
7779
- ], _p = kt.length / 2, Fp = ({ title: e, layout: t = "collapsible", preview: r }) => {
7779
+ ], zp = kt.length / 2, _p = { select: { target: "graph" } }, Fp = ({ title: e, layout: t = "collapsible", preview: r }) => {
7780
7780
  const a = H(), o = $(a), i = k(), { RadioGrid: l } = B();
7781
7781
  if (!o) return null;
7782
- const { textScale: s } = o.config.appearance, c = (h) => i("editor.elementsPanel.textSizeSection.scaleFormat", { value: `${h}` }), u = kt.map((h) => ({
7782
+ const s = Oe().chromeReaders(o.chrome).graph.get("textScale"), c = (h) => i("editor.elementsPanel.textSizeSection.scaleFormat", { value: `${h}` }), u = kt.map((h) => ({
7783
7783
  value: `${h}`,
7784
7784
  label: c(h)
7785
7785
  })), d = (h) => {
7786
- const v = kt.find((p) => `${p}` === h);
7787
- v !== void 0 && a.commands.dispatch(new Yo({ textScale: v }));
7786
+ const v = kt.find((g) => `${g}` === h);
7787
+ if (v === void 0) return;
7788
+ const p = fe(o.spec.styles.overrides, _p)?.declarations ?? {};
7789
+ a.commands.dispatch(new Le({
7790
+ list: "overrides",
7791
+ rule: {
7792
+ select: { target: "graph" },
7793
+ declarations: {
7794
+ ...p,
7795
+ textScale: v
7796
+ }
7797
+ }
7798
+ }));
7788
7799
  };
7789
7800
  return /* @__PURE__ */ n(W, {
7790
7801
  title: e ?? i("editor.elementsPanel.textSizeSection.title"),
@@ -7793,7 +7804,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7793
7804
  children: /* @__PURE__ */ n(l, {
7794
7805
  value: `${s}`,
7795
7806
  options: u,
7796
- columns: _p,
7807
+ columns: zp,
7797
7808
  onChange: d,
7798
7809
  ariaLabel: i("editor.elementsPanel.textSizeSection.title")
7799
7810
  })
@@ -7802,7 +7813,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7802
7813
  const a = H(), o = $(a), i = k(), { Switch: l } = B();
7803
7814
  if (!o) return null;
7804
7815
  const s = o.config.content, c = (d) => {
7805
- a.commands.dispatch(new rt({
7816
+ a.commands.dispatch(new at({
7806
7817
  slot: "title",
7807
7818
  isVisible: d
7808
7819
  }));
@@ -7828,9 +7839,9 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7828
7839
  ...t,
7829
7840
  children: e ?? /* @__PURE__ */ m(j, { children: [
7830
7841
  /* @__PURE__ */ n(Hp, {}),
7831
- /* @__PURE__ */ n(zp, {}),
7832
- /* @__PURE__ */ n(Np, {}),
7833
- /* @__PURE__ */ n(Rp, {}),
7842
+ /* @__PURE__ */ n(Dp, {}),
7843
+ /* @__PURE__ */ n(Mp, {}),
7844
+ /* @__PURE__ */ n(Op, {}),
7834
7845
  /* @__PURE__ */ n(Fp, {})
7835
7846
  ] })
7836
7847
  }), t0 = ({ children: e, ...t }) => /* @__PURE__ */ n(_a.Root, {
@@ -7839,12 +7850,12 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7839
7850
  }), dt = (e) => `${e}px`, Ha = (e) => `${Math.round(e * 100)}%`, Bp = (e) => `${e}°`, Vp = 24, Gp = { select: { target: "graph" } }, Fn = ["dim", "desaturate"], n0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
7840
7851
  const a = H(), o = $(a), i = k(), { Slider: l, ToggleGroup: s } = B();
7841
7852
  if (!o) return null;
7842
- const c = at().chromeReaders(o.chrome).graph.get("borderRadius"), u = ml(o.spec), d = Fn.map((p) => ({
7853
+ const c = Oe().chromeReaders(o.chrome).graph.get("borderRadius"), u = pl(o.spec), d = Fn.map((p) => ({
7843
7854
  value: p,
7844
7855
  label: i(p === "dim" ? "editor.highlighting.highlightStyle.tint" : "editor.highlighting.highlightStyle.grey")
7845
7856
  })), h = (p) => {
7846
- const g = Te(o.spec.styles.overrides, Gp)?.declarations ?? {};
7847
- a.commands.dispatch(new Ne({
7857
+ const g = fe(o.spec.styles.overrides, Gp)?.declarations ?? {};
7858
+ a.commands.dispatch(new Le({
7848
7859
  list: "overrides",
7849
7860
  rule: {
7850
7861
  select: { target: "graph" },
@@ -7856,7 +7867,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7856
7867
  }), { transient: !0 });
7857
7868
  }, v = (p) => {
7858
7869
  const g = Fn.find((f) => f === p);
7859
- g && a.commands.dispatch(new mi({ dimStyle: g }));
7870
+ g && a.commands.dispatch(new pi({ dimStyle: g }));
7860
7871
  };
7861
7872
  return /* @__PURE__ */ n(W, {
7862
7873
  title: e ?? i("editor.colorPanel.appearanceSection.title"),
@@ -7883,10 +7894,10 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7883
7894
  })] })
7884
7895
  });
7885
7896
  }, Yt = (e, t) => {
7886
- const { colorScheme: r } = nt();
7897
+ const { colorScheme: r } = rt();
7887
7898
  return M(() => {
7888
7899
  const a = e?.layers.find((o) => o.id === t);
7889
- return a === void 0 ? null : at({ colorScheme: r }).geomReaders(a);
7900
+ return a === void 0 ? null : Oe({ colorScheme: r }).geomReaders(a);
7890
7901
  }, [
7891
7902
  e,
7892
7903
  t,
@@ -7896,20 +7907,20 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
7896
7907
  const a = H(), o = $(a), i = k(), { Slider: l, ToggleGroup: s } = B(), c = o ? hr(o.spec.layers, "bar") : void 0, u = Yt(o, c?.id ?? null);
7897
7908
  if (!o || !c || o.coordSystem.type === "polar" && o.coordSystem.bandAxis === null) return null;
7898
7909
  const d = (g) => {
7899
- a.commands.dispatch(new ai({
7910
+ a.commands.dispatch(new ri({
7900
7911
  layerId: c.id,
7901
7912
  width: g
7902
7913
  }), { transient: !0 });
7903
7914
  }, h = (g) => {
7904
7915
  const f = en.find((y) => y === g);
7905
- f && a.commands.dispatch(new ri({
7916
+ f && a.commands.dispatch(new ni({
7906
7917
  layerId: c.id,
7907
7918
  borderRadius: f
7908
7919
  }));
7909
7920
  }, v = en.map((g) => ({
7910
7921
  value: g,
7911
7922
  label: i(`editor.graphPanel.barSection.roundingOptions.${g}`)
7912
- })), p = bl(c.params, o.coordSystem.type);
7923
+ })), p = fl(c.params, o.coordSystem.type);
7913
7924
  return /* @__PURE__ */ n(W, {
7914
7925
  title: e ?? i("editor.graphPanel.barSection.title"),
7915
7926
  layout: t,
@@ -8027,7 +8038,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
8027
8038
  a.commands.dispatch(new pe({
8028
8039
  kind: "text",
8029
8040
  annotation: {
8030
- ...Mi,
8041
+ ...Ei,
8031
8042
  content: t2(i("editor.annotatePanel.callOutSection.text")),
8032
8043
  at: {
8033
8044
  anchorType: "panel",
@@ -8064,7 +8075,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
8064
8075
  }
8065
8076
  }));
8066
8077
  }, d = () => {
8067
- const v = cl(o);
8078
+ const v = sl(o);
8068
8079
  v !== null && a.commands.dispatch(new pe({
8069
8080
  kind: "differenceArrow",
8070
8081
  annotation: {
@@ -8143,8 +8154,8 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
8143
8154
  }, n2 = 0.1, r2 = 20, i0 = ({ title: e, preview: t }) => {
8144
8155
  const r = H(), a = $(r), o = k(), { NumberField: i, TextField: l } = B();
8145
8156
  if (!a || a.coordSystem.type === "polar") return null;
8146
- const s = nl(a.spec.layers), c = e ?? o("editor.annotationsPanel.goalSection.title"), u = Ji(s?.mapping.y), d = typeof u == "number" ? u : null, h = (g) => {
8147
- const f = new Di({
8157
+ const s = tl(a.spec.layers), c = e ?? o("editor.annotationsPanel.goalSection.title"), u = Yi(s?.mapping.y), d = typeof u == "number" ? u : null, h = (g) => {
8158
+ const f = new Ri({
8148
8159
  showGoalLine: g,
8149
8160
  value: a2(a),
8150
8161
  ...s !== void 0 && { layerId: s.id }
@@ -8152,20 +8163,20 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
8152
8163
  r.commands.dispatch(f);
8153
8164
  }, v = (g) => {
8154
8165
  if (s === void 0) return;
8155
- const f = new ki({
8166
+ const f = new Ai({
8156
8167
  layerId: s.id,
8157
8168
  label: g === "" ? null : g
8158
8169
  });
8159
8170
  r.commands.dispatch(f, { transient: !0 });
8160
8171
  }, p = (g) => {
8161
8172
  if (s === void 0 || g === null) return;
8162
- const f = new Li({
8173
+ const f = new ki({
8163
8174
  layerId: s.id,
8164
8175
  value: g
8165
8176
  });
8166
8177
  r.commands.dispatch(f, { transient: !0 });
8167
8178
  };
8168
- return /* @__PURE__ */ n(Lp, {
8179
+ return /* @__PURE__ */ n(kp, {
8169
8180
  title: c,
8170
8181
  preview: t,
8171
8182
  isChecked: s !== void 0,
@@ -8203,27 +8214,27 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
8203
8214
  const c = e === void 0 ? i.spec.layers[0] : i.spec.layers.find((D) => D.id === e);
8204
8215
  if (!c) return null;
8205
8216
  const { showDataLabels: u, format: d, showStackTotals: h, showCategoryLabels: v } = c.dataLabels, p = i.coordSystem.type === "polar", g = c.geom === "bar", f = c.position === "stack" || c.position === "fill", y = g && !p && c.position === "stack", P = g && (!p || u), C = g || c.geom === "area" && f;
8206
- if (!qi(c.geom, i.coordSystem.type)) return null;
8217
+ if (!Ki(c.geom, i.coordSystem.type)) return null;
8207
8218
  const A = (D) => {
8208
- const E = new Ri({
8219
+ const E = new Oi({
8209
8220
  layerId: c.id,
8210
8221
  showDataLabels: D
8211
8222
  });
8212
8223
  o.commands.dispatch(E);
8213
8224
  }, L = (D) => {
8214
- const E = new ii({
8225
+ const E = new oi({
8215
8226
  layerId: c.id,
8216
8227
  format: D ? "percentage" : "absolute"
8217
8228
  });
8218
8229
  o.commands.dispatch(E);
8219
8230
  }, R = (D) => {
8220
- const E = new Fi({
8231
+ const E = new _i({
8221
8232
  layerId: c.id,
8222
8233
  showStackTotals: D
8223
8234
  });
8224
8235
  o.commands.dispatch(E);
8225
8236
  }, F = (D) => {
8226
- const E = new Oi({
8237
+ const E = new Ni({
8227
8238
  layerId: c.id,
8228
8239
  showCategoryLabels: D
8229
8240
  });
@@ -9029,20 +9040,20 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9029
9040
  return t === null || ve(r) ? r : r.position === "dodge" && Ba(t) ? {
9030
9041
  ...r,
9031
9042
  position: "identity"
9032
- } : r.coordType !== "polar" || !Qe(r.innerRadius) || t.coordType !== "polar" || !Qe(t.innerRadius) ? r : {
9043
+ } : r.coordType !== "polar" || !et(r.innerRadius) || t.coordType !== "polar" || !et(t.innerRadius) ? r : {
9033
9044
  ...r,
9034
9045
  innerRadius: t.innerRadius
9035
9046
  };
9036
9047
  }, Ba = (e) => !ve(e) && e.geom === "bar" && e.position === "identity", P2 = (e, t) => {
9037
9048
  if (ve(e) || ve(t)) return ve(e) && ve(t);
9038
9049
  const r = e.position === t.position || e.position === "dodge" && Ba(t);
9039
- return e.coordType !== t.coordType || e.geom !== t.geom || !r ? !1 : e.coordType !== "polar" || t.coordType !== "polar" ? !0 : e.theta === t.theta && Qe(e.innerRadius) === Qe(t.innerRadius);
9040
- }, Qe = (e) => e >= A2, I2 = 3, s0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
9050
+ return e.coordType !== t.coordType || e.geom !== t.geom || !r ? !1 : e.coordType !== "polar" || t.coordType !== "polar" ? !0 : e.theta === t.theta && et(e.innerRadius) === et(t.innerRadius);
9051
+ }, et = (e) => e >= A2, I2 = 3, s0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
9041
9052
  const a = H(), o = $(a), i = k(), { RadioGrid: l } = B(), s = M(() => Lt.map(({ name: h, icon: v }) => ({
9042
9053
  value: h,
9043
9054
  label: i(`editor.graphTypes.${h}`),
9044
9055
  icon: /* @__PURE__ */ n(v, { size: "md" }),
9045
- isDisabled: h === "combo" && !Wi(o?.spec) || h === "heatmap" && !Ki(o?.spec)
9056
+ isDisabled: h === "combo" && !Ui(o?.spec) || h === "heatmap" && !Wi(o?.spec)
9046
9057
  })), [i, o]);
9047
9058
  if (!o) return null;
9048
9059
  const c = gr(o.spec), u = k2(c), d = (h) => {
@@ -9066,26 +9077,26 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9066
9077
  "dashed",
9067
9078
  "dotted"
9068
9079
  ], E2 = 8, M2 = 0, c0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
9069
- const a = H(), o = $(a), i = k(), { Slider: l, Switch: s, ToggleGroup: c } = B(), { colorScheme: u } = nt();
9080
+ const a = H(), o = $(a), i = k(), { Slider: l, Switch: s, ToggleGroup: c } = B(), { colorScheme: u } = rt();
9070
9081
  if (!o) return null;
9071
9082
  const d = o.guides.axes.filter(N2);
9072
9083
  if (d.length === 0) return null;
9073
- const h = o.coordSystem.type !== "polar", v = d.some((C) => C.gridVisible), p = yl(at({ colorScheme: u }).chromeReaders(o.chrome), "y"), g = Hn.map((C) => ({
9084
+ const h = o.coordSystem.type !== "polar", v = d.some((C) => C.gridVisible), p = Cl(Oe({ colorScheme: u }).chromeReaders(o.chrome), "y"), g = Hn.map((C) => ({
9074
9085
  value: C,
9075
9086
  label: i(`editor.graphPanel.gridSection.lineStyles.${C}`)
9076
9087
  })), f = (C) => (A) => {
9077
- a.commands.dispatch(new di({
9088
+ a.commands.dispatch(new ci({
9078
9089
  axis: C,
9079
9090
  isVisible: A
9080
9091
  }));
9081
9092
  }, y = (C) => {
9082
9093
  const A = Hn.find((L) => L === C);
9083
- A && a.commands.dispatch(new si({
9094
+ A && a.commands.dispatch(new li({
9084
9095
  axis: "both",
9085
9096
  lineStyle: A
9086
9097
  }));
9087
9098
  }, P = (C) => {
9088
- a.commands.dispatch(new ci({
9099
+ a.commands.dispatch(new si({
9089
9100
  axis: "both",
9090
9101
  lineWidth: C
9091
9102
  }), { transient: !0 });
@@ -9156,12 +9167,12 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9156
9167
  b && a.commands.dispatch(new rn({ show: b }));
9157
9168
  }, D = (T) => {
9158
9169
  const b = Bn.find((Z) => Z === T);
9159
- b && a.commands.dispatch(new ui({ compareWith: b }));
9170
+ b && a.commands.dispatch(new di({ compareWith: b }));
9160
9171
  }, E = (T) => {
9161
9172
  const b = Vn.find((Z) => Z === T);
9162
- b && a.commands.dispatch(new pi({ size: b }));
9173
+ b && a.commands.dispatch(new hi({ size: b }));
9163
9174
  }, N = (T) => {
9164
- a.commands.dispatch(new hi({ position: T === "center" ? "center" : "above" }));
9175
+ a.commands.dispatch(new ui({ position: T === "center" ? "center" : "above" }));
9165
9176
  };
9166
9177
  return /* @__PURE__ */ n(W, {
9167
9178
  title: e ?? i("editor.graphPanel.headlineNumberSection.title"),
@@ -9187,7 +9198,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9187
9198
  label: i("editor.graphPanel.headlineNumberSection.compareWithLabel"),
9188
9199
  layout: "stack",
9189
9200
  children: /* @__PURE__ */ n(s, {
9190
- value: Cl(c.compareWith),
9201
+ value: bl(c.compareWith),
9191
9202
  options: C,
9192
9203
  onChange: D
9193
9204
  })
@@ -9231,7 +9242,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9231
9242
  ], u0 = ({ positions: e, title: t, layout: r = "collapsible", preview: a }) => {
9232
9243
  const o = H(), i = $(o), l = k(), { ToggleGroup: s } = B();
9233
9244
  if (!i) return null;
9234
- const c = i.config.legend.position, u = e ?? ft, d = i.guides.legends.drawn[0], h = Ui({
9245
+ const c = i.config.legend.position, u = e ?? ft, d = i.guides.legends.drawn[0], h = $i({
9235
9246
  legendPosition: i.guides.legends.position,
9236
9247
  coordSystem: i.coordSystem,
9237
9248
  layers: i.layers
@@ -9242,13 +9253,13 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9242
9253
  label: l(`editor.graphPanel.legendSection.${N}`)
9243
9254
  })), P = (N) => {
9244
9255
  const T = ft.find((b) => b === N);
9245
- T && o.commands.dispatch(new bi({ position: T }));
9256
+ T && o.commands.dispatch(new fi({ position: T }));
9246
9257
  }, C = (N) => {
9247
9258
  const T = Gn.find((b) => b === N);
9248
- T && o.commands.dispatch(new vi({ align: T }));
9259
+ T && o.commands.dispatch(new gi({ align: T }));
9249
9260
  }, A = (N) => {
9250
9261
  const T = $n.find((b) => b === N);
9251
- T && o.commands.dispatch(new fi({ display: T }));
9262
+ T && o.commands.dispatch(new vi({ display: T }));
9252
9263
  }, L = Gn.map((N) => ({
9253
9264
  value: N,
9254
9265
  label: l(`editor.graphPanel.legendSection.align.${N}`)
@@ -9294,7 +9305,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9294
9305
  const t = H(), r = $(t), { Slider: a } = B(), o = Yt(r, e);
9295
9306
  if (!r) return null;
9296
9307
  const i = (l) => {
9297
- const s = new wi({
9308
+ const s = new xi({
9298
9309
  layerId: e,
9299
9310
  size: l
9300
9311
  });
@@ -9323,17 +9334,17 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9323
9334
  value: "custom",
9324
9335
  label: i("editor.graphPanel.numberFormat.options.custom")
9325
9336
  }], L = (T) => {
9326
- a.commands.dispatch(new _i({
9337
+ a.commands.dispatch(new zi({
9327
9338
  layerId: h.id,
9328
9339
  showPoints: T
9329
9340
  }));
9330
9341
  }, R = (T) => {
9331
- C && a.commands.dispatch(new zi({
9342
+ C && a.commands.dispatch(new Di({
9332
9343
  layerId: C.id,
9333
9344
  showFill: T
9334
9345
  }));
9335
9346
  }, F = (T) => {
9336
- a.commands.dispatch(new Ci({
9347
+ a.commands.dispatch(new bi({
9337
9348
  layerId: h.id,
9338
9349
  interpolate: T ? "catmull-rom" : "linear"
9339
9350
  }));
@@ -9350,7 +9361,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9350
9361
  }), { transient: !0 });
9351
9362
  }, N = (T) => {
9352
9363
  const b = U2(T);
9353
- b && a.commands.dispatch(new yi({
9364
+ b && a.commands.dispatch(new Ci({
9354
9365
  layerId: h.id,
9355
9366
  missingValues: b
9356
9367
  }));
@@ -9415,7 +9426,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9415
9426
  })
9416
9427
  ] })
9417
9428
  });
9418
- }, U2 = (e) => $2.find((t) => t === e), Un = (e, t, r, a) => al(e.styles.overrides, Gi(t, a))?.[r], W2 = (e, t) => bt(t, "point").find((r) => pr(r, [e])), K2 = (e, t) => {
9429
+ }, U2 = (e) => $2.find((t) => t === e), Un = (e, t, r, a) => rl(e.styles.overrides, Vi(t, a))?.[r], W2 = (e, t) => bt(t, "point").find((r) => pr(r, [e])), K2 = (e, t) => {
9419
9430
  const r = [{
9420
9431
  value: "gap",
9421
9432
  label: e("editor.graphPanel.treatEmptyValues.leaveGap.label")
@@ -9440,15 +9451,15 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9440
9451
  size: "editor.graphPanel.mappingSection.size",
9441
9452
  label: "editor.graphPanel.mappingSection.label"
9442
9453
  }, p0 = ({ title: e, layout: t = "collapsible" }) => {
9443
- const r = H(), a = $(r), o = k(), { Select: i } = B(), l = o("editor.graphPanel.mappingSection.none"), s = a?.spec, c = M(() => s === void 0 ? [] : gl(s, q2).map(({ aesthetic: u, variables: d, isRequired: h }) => {
9444
- const v = vl(s.mapping, u);
9454
+ const r = H(), a = $(r), o = k(), { Select: i } = B(), l = o("editor.graphPanel.mappingSection.none"), s = a?.spec, c = M(() => s === void 0 ? [] : ml(s, q2).map(({ aesthetic: u, variables: d, isRequired: h }) => {
9455
+ const v = gl(s.mapping, u);
9445
9456
  return {
9446
9457
  aesthetic: u,
9447
9458
  label: o(Z2[u]),
9448
9459
  value: v ?? (h ? null : Pt),
9449
9460
  options: X2(d, v, h ? null : l),
9450
9461
  chooseColumn: (p) => {
9451
- r.commands.dispatch(new Si({
9462
+ r.commands.dispatch(new yi({
9452
9463
  aesthetic: u,
9453
9464
  variable: p === Pt ? null : p
9454
9465
  }));
@@ -9505,7 +9516,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9505
9516
  value: A,
9506
9517
  label: i(`common.abbreviations.${L}`)
9507
9518
  })), g = (A) => {
9508
- a.commands.dispatch(new xi({ abbreviation: A }));
9519
+ a.commands.dispatch(new Si({ abbreviation: A }));
9509
9520
  }, f = (A) => {
9510
9521
  const L = em.find((R) => R === A);
9511
9522
  g(L ?? j2);
@@ -9582,9 +9593,9 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9582
9593
  const a = H(), o = $(a), i = k(), { Slider: l } = B();
9583
9594
  if (!o || o.spec.coords.coordType !== "polar") return null;
9584
9595
  const { innerRadius: s, startAngle: c } = o.spec.coords.params, u = (h) => {
9585
- a.commands.dispatch(new Ti({ innerRadius: h }), { transient: !0 });
9596
+ a.commands.dispatch(new wi({ innerRadius: h }), { transient: !0 });
9586
9597
  }, d = (h) => {
9587
- a.commands.dispatch(new Ai({ startAngle: h }), { transient: !0 });
9598
+ a.commands.dispatch(new Ti({ startAngle: h }), { transient: !0 });
9588
9599
  };
9589
9600
  return /* @__PURE__ */ n(W, {
9590
9601
  title: e ?? i("editor.graphPanel.polarSection.title"),
@@ -9667,7 +9678,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9667
9678
  }
9668
9679
  };
9669
9680
  const { parsingLocale: t, numberFormat: r } = e.config, a = e.guides.colorGroups.map((o) => {
9670
- const i = Yi({
9681
+ const i = ji({
9671
9682
  valueFormat: o.valueFormat,
9672
9683
  locale: t,
9673
9684
  numberFormat: r
@@ -9695,11 +9706,11 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
9695
9706
  ], cm = "linear", f0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
9696
9707
  const a = H(), o = $(a), i = k(), { Select: l, Switch: s } = B(), { options: c, findValue: u } = sm(o);
9697
9708
  if (!o || o.coordSystem.type === "polar") return null;
9698
- const d = il(o.spec.layers), h = tl(o.spec.layers), v = d?.stat.type === "smooth" ? d.stat.method : cm, p = dm(h), g = Kn.map((L) => ({
9709
+ const d = ol(o.spec.layers), h = el(o.spec.layers), v = d?.stat.type === "smooth" ? d.stat.method : cm, p = dm(h), g = Kn.map((L) => ({
9699
9710
  value: L,
9700
9711
  label: i(`editor.annotationsPanel.trendType.options.${L}`)
9701
9712
  })), f = (L, R = {}) => {
9702
- const F = d ?? h, D = new Ei({
9713
+ const F = d ?? h, D = new Ii({
9703
9714
  line: L,
9704
9715
  ...R,
9705
9716
  ...F !== void 0 && { layerId: F.id },
@@ -9764,9 +9775,9 @@ export {
9764
9775
  t0 as AxesPanel,
9765
9776
  Dn as AxisSection,
9766
9777
  r0 as BarSection,
9767
- A1 as Button,
9778
+ T1 as Button,
9768
9779
  a0 as CalloutsSection,
9769
- Np as CaptionSection,
9780
+ Mp as CaptionSection,
9770
9781
  o0 as ComboSection,
9771
9782
  Qm as EditableGraphRenderer,
9772
9783
  _a as EditorPanel,
@@ -9776,30 +9787,30 @@ export {
9776
9787
  s0 as GraphTypeSection,
9777
9788
  c0 as GridSection,
9778
9789
  d0 as HeadlineSection,
9779
- ls as IntlProvider,
9790
+ is as IntlProvider,
9780
9791
  u0 as LegendSection,
9781
9792
  h0 as LineSection,
9782
9793
  p0 as MappingSection,
9783
- I1 as NumberField,
9794
+ P1 as NumberField,
9784
9795
  m0 as NumberFormatSection,
9785
- gp as PANEL_ROOT_ATTRIBUTE,
9796
+ mp as PANEL_ROOT_ATTRIBUTE,
9786
9797
  g0 as PointSection,
9787
9798
  v0 as PolarSection,
9788
- O1 as RadioGrid,
9799
+ N1 as RadioGrid,
9789
9800
  S as Row,
9790
9801
  W as Section,
9791
- G1 as Select,
9792
- Y1 as Slider,
9793
- Rp as SourceSection,
9794
- zp as SubtitleSection,
9795
- tp as Switch,
9796
- ap as TextField,
9802
+ V1 as Select,
9803
+ j1 as Slider,
9804
+ Op as SourceSection,
9805
+ Dp as SubtitleSection,
9806
+ ep as Switch,
9807
+ rp as TextField,
9797
9808
  Fp as TextSizeSection,
9798
9809
  Hp as TitleSection,
9799
- lp as ToggleGroup,
9800
- Lp as ToggledSection,
9810
+ ip as ToggleGroup,
9811
+ kp as ToggledSection,
9801
9812
  f0 as TrendsAndAveragesSection,
9802
9813
  B as useControls,
9803
- pp as usePanelExpansion,
9814
+ hp as usePanelExpansion,
9804
9815
  H as usePanelGraph
9805
9816
  };