@graphysdk/react-renderer 1.9.0-beta.1795015443496 → 1.9.0-beta.1795022135575
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.cjs +1 -1
- package/dist/editable.mjs +519 -503
- package/dist/{history-chords-B52rWY-3.cjs → history-chords-Brh9GUjC.cjs} +1 -1
- package/dist/{history-chords-BN_SvCJO.js → history-chords-eAw9OJIk.js} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +4 -4
package/dist/editable.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { $t as vd, A as fd, An as ct, At as He, Bt as N, C as bd, Cn as yd, D as Sd, Dn as wd, Dt as qa, E as Cd, En as xd, Et as kd, F as Cr, G as O, Gt as Td, H as Ad, Hn as Pd, Ht as Ld, I as zi, It as Id, J as Md, K as Od, Kn as Ed, L as xr, M as Rd, Mt as Nd, N as Dd, Nt as Rn, O as Hi, On as Ce, Ot as ta, Qt as _d, R as Nn, Rt as Fd, S as
|
|
2
|
-
import { ARROW_DEFAULTS as rl, ARROW_STICKER_DECLARATIONS as ku, ARROW_STROKE_WIDTHS_PX as ir, ARROW_TARGET_GAP_PX as Ja, AUTO_COLOR as
|
|
3
|
-
import { Fragment as zl, createContext as lt, memo as Hl, useCallback as fe, useContext as Le, useEffect as W, useId as Ue, useLayoutEffect as
|
|
4
|
-
import { Fragment as
|
|
1
|
+
import { $t as vd, A as fd, An as ct, At as He, Bt as N, C as bd, Cn as yd, D as Sd, Dn as wd, Dt as qa, E as Cd, En as xd, Et as kd, F as Cr, G as O, Gt as Td, H as Ad, Hn as Pd, Ht as Ld, I as zi, It as Id, J as Md, K as Od, Kn as Ed, L as xr, M as Rd, Mt as Nd, N as Dd, Nt as Rn, O as Hi, On as Ce, Ot as ta, Qt as _d, R as Nn, Rt as Fd, S as je, St as Dn, T as Gi, Tn as Bd, Tt as $i, U as Vi, Un as Wi, Ut as zd, Vn as Hd, Vt as Ui, W as Gd, Wt as $d, X as Vd, Xn as Wd, Xt as qe, Y as Ud, Zt as be, _ as Ki, _t as Xi, ar as re, at as Kd, b as ji, bn as Xd, bt as jd, c as qd, cr as Yd, ct as Zd, d as Jd, dn as Qd, dt as na, er as eu, et as tu, f as nu, fr as ra, ft as ru, g as au, gn as qi, gt as ou, h as iu, ht as lu, i as Wt, it as ue, jt as su, k as cu, kn as aa, kt as Re, lr as j, lt as ee, m as du, mn as Yi, mt as uu, n as Pe, nn as kr, nt as hu, o as pu, ot as Ya, p as gu, pt as mu, r as oe, rn as Ne, rr as Zi, rt as Q, s as Za, sr as G, st as vu, t as fu, tn as Ji, tr as bu, tt as Qi, u as el, ur as xe, ut as oa, v as yu, vn as Su, vt as ia, w as wu, wn as _n, x as tl, xn as Cu, xt as Fn, y as mt, yn as xu, yt as Bn, zt as nl } from "./history-chords-eAw9OJIk.js";
|
|
2
|
+
import { ARROW_DEFAULTS as rl, ARROW_STICKER_DECLARATIONS as ku, ARROW_STROKE_WIDTHS_PX as ir, ARROW_TARGET_GAP_PX as Ja, AUTO_COLOR as Tt, AddAnnotationCommand as Te, AddHighlightCommand as Tu, COMBO_TYPES as Qa, CONSTANT_VARIABLES as la, DASH_PRESETS as Au, DEFAULT_BAR_CORNER_RADII as Pu, DEFAULT_GEOM_COLOR as Lu, DEFAULT_POINT_SIZE_PX as al, DEFAULT_STROKE_WIDTH_PX as Iu, DIFFERENCE_ARROW_DEFAULTS as ol, DIFFERENCE_ARROW_SIZE_DECLARATIONS as gn, InternalError as Mu, MAX_BAR_WIDTH_FRACTION as Ou, MIN_BAR_WIDTH_FRACTION as Eu, MoveAnnotationCommand as Ru, PANEL_FRACTION_BOUNDS as il, POSITION_VARIABLES as et, RESTING_HOVER_STATE as Ut, RemoveAnnotationCommand as tt, RemoveHighlightCommand as eo, SHAPE_DEFAULTS as ll, SequenceCommand as st, SetAxisLabelCommand as sl, SetAxisPositionCommand as cl, SetAxisTickModeCommand as Tr, SetAxisTicksVisibilityCommand as to, SetAxisVisibilityCommand as bn, SetBarCornerRadiusCommand as Nu, SetBarWidthCommand as dl, SetContentCaptionCommand as ul, SetContentSourceCommand as Du, SetContentSubtitleCommand as hl, SetContentTitleCommand as pl, SetDataLabelsCommand as gl, SetDataLabelsFormatCommand as ml, SetDifferenceArrowStyleCommand as _u, SetGraphTypeCommand as sa, SetGridLineStyleCommand as vl, SetGridVisibilityCommand as Ar, SetHeadlineCompareWithCommand as Fu, SetHeadlinePositionCommand as Bu, SetHeadlineShowCommand as no, SetHeadlineSizeCommand as zu, SetHighlightDimStyleCommand as Hu, SetLayerYScaleTypeCommand as Gu, SetLegendAlignCommand as $u, SetLegendDisplayCommand as Vu, SetLegendPlacementCommand as Wu, SetLegendPositionCommand as Pr, SetLineCurveCommand as fl, SetLineMissingValuesCommand as bl, SetLineStyleCommand as We, SetMappingCommand as Uu, SetNumberFormatAbbreviationCommand as Ku, SetNumberFormatDecimalsCommand as ro, SetObservationsColorCommand as Xu, SetPointSizeCommand as zn, SetPointSymbolCommand as ca, SetPolarInnerRadiusCommand as ju, SetPolarStartAngleCommand as qu, SetRuleLabelCommand as Yu, SetRuleValueCommand as Zu, SetScaleDomainCommand as Qe, SetScaleRangeCommand as yl, SetScaleTransformCommand as Sl, SetStatLineCommand as Ju, SetStyleRuleCommand as nt, TEXT_ANNOTATION_DEFAULTS as Lr, TEXT_ANNOTATION_FADE_ALPHA as Qu, ToggleCategoryLabelsCommand as wl, ToggleContentVisibilityCommand as dt, ToggleDataLabelsCommand as Cl, ToggleGoalLineCommand as eh, ToggleLinePointsCommand as da, ToggleStackTotalsCommand as xl, UpdateAnnotationCommand as we, alignUnitFractions as ua, areAnchorsEqual as Hn, areEditTargetsEqual as ha, areEndpointsComparable as th, areSameStackEndpoints as nh, buildColormapRange as rh, buildDivergingRange as ao, buildLayerStyleAddress as At, buildObservationPredicate as kl, buildObservationsTarget as Ye, buildObservationsTargetAtValue as Tl, buildPointSymbolInBox as ah, canAnchorDirectLabels as oh, canBecomeCombo as ih, canBecomeHeatmap as lh, clampAnnotationTranslation as sh, collectDependentAnnotationIds as pa, combineKindStyleDeclarations as oo, computeArrow as Al, createObservationAnchorBuilder as ch, createObservationAnchorLander as dh, createObservationAnchorParser as uh, createStyleResolver as hh, createStyleRuleMatcher as ph, createValueFormatter as ga, createXValueReader as gh, filterLayersByGeoms as Ir, findAnnotation as io, findAverageLineLayer as mh, findAxisGuide as Pl, findCompanionLayers as Ll, findGoalLineLayer as vh, findHighlightsAtObservation as fh, findHostLayer as Gn, findKindStyleDeclarations as yn, findLayerByGeom as Il, findLayerById as ne, findObservationAttachment as bh, findOverflowedPanelEdges as yh, findPointerRegion as Sh, findStyleRule as rt, findTrendLineLayer as wh, formatDifferenceLabel as Ch, getBoundingRect as Mr, getGroupVariables as ma, getScaledAesthetic as xh, getXBand as kh, getYBand as Th, hasMainAxisBand as Ah, hasMultipleGroups as $n, indexSceneAnnotations as Ml, inferDefaultDifferenceArrowEndpoints as Ph, inferDifferenceArrowEndpoints as Lh, isComboGraphType as Ae, isCompanionLayer as Ol, isGeomStyleRule as Ih, isGeometricSymbol as _t, isImageSymbol as Or, isLayerSpecOf as Lt, isObservationAttachmentKind as Mh, isSafeUrl as Oh, isZeroAnchoredAxis as El, measureObservationsBoxes as Rl, omitLegacyDifferenceArrowLabelPlate as Eh, polarToUnit as Rh, projectAnchorToPanel as at, projectBoxToPanel as Sn, readAnnotationBox as va, readBroadestObservationsScope as Nh, readColorChoices as Nl, readColorPart as Dh, readColormapColor as _h, readComboLineLayerId as Fh, readCompanionRowsAtScopeKey as Bh, readConstantValue as zh, readDivergingColor as lo, readEditTargetKey as Kt, readGeomColor as Hh, readGraphType as Vn, readHighlightDimStyle as Gh, readMainAxis as $h, readMappableAesthetics as Vh, readMappedVariable as Wh, readObservationIndex as It, readObservationsColor as Uh, readObservationsColorPart as Kh, readObservationsColorRoute as Wn, readOutwardGapOffset as Xh, readReachableLevels as jh, readRectPoint as fa, readRowScopeKey as qh, readRowsAtScopeKey as Yh, readScopeXVariable as Zh, readStyleCoord as Me, readStyleRulesBeneath as Jh, readVariableName as ze, resolveArrowAnnotationStyle as ba, resolveBarBandFraction as Dl, resolveComparisonBasis as Qh, resolveDifferenceArrowAnnotationStyle as ep, resolveEditOutlineStyle as tp, resolveLayerAxisValueFormat as np, resolveObservationPoint as _l, resolveObservationsTarget as ht, resolvePointPlacement as Fl, resolveTextAnnotationStyle as Bl, stepDifferenceArrowEndpoint as rp, toDashPreset as pt, toFontSpec as ap, toPaintColor as ut, toPanelCursor as vt, toStrokeDasharray as ya } from "@graphysdk/viz-engine";
|
|
3
|
+
import { Fragment as zl, createContext as lt, memo as Hl, useCallback as fe, useContext as Le, useEffect as W, useId as Ue, useLayoutEffect as Ke, useMemo as z, useRef as te, useState as Z, useSyncExternalStore as op } from "react";
|
|
4
|
+
import { Fragment as J, jsx as o, jsxs as f } from "react/jsx-runtime";
|
|
5
5
|
import { motion as ip } from "motion/react";
|
|
6
6
|
import { useShallow as Ie } from "zustand/react/shallow";
|
|
7
7
|
import { clamp as gt, isEqual as Un } from "lodash-es";
|
|
@@ -16,7 +16,7 @@ import { NumberField as wn } from "@base-ui/react/number-field";
|
|
|
16
16
|
import { Radio as Gl } from "@base-ui/react/radio";
|
|
17
17
|
import { RadioGroup as $l } from "@base-ui/react/radio-group";
|
|
18
18
|
import { Select as Fe } from "@base-ui/react/select";
|
|
19
|
-
import { Slider as
|
|
19
|
+
import { Slider as Rt } from "@base-ui/react/slider";
|
|
20
20
|
import { Switch as so } from "@base-ui/react/switch";
|
|
21
21
|
import { Input as gp } from "@base-ui/react/input";
|
|
22
22
|
import { DirectionProvider as wa } from "@base-ui/react/direction-provider";
|
|
@@ -34,7 +34,7 @@ import { Underline as kp } from "@tiptap/extension-underline";
|
|
|
34
34
|
import { Placeholder as Ca, UndoRedo as Tp } from "@tiptap/extensions";
|
|
35
35
|
import { Paragraph as Ul } from "@tiptap/extension-paragraph";
|
|
36
36
|
import { EditorContent as Kl, useEditor as Ap, useEditorState as Ht } from "@tiptap/react";
|
|
37
|
-
import { Toolbar as
|
|
37
|
+
import { Toolbar as Ze } from "@base-ui/react/toolbar";
|
|
38
38
|
import { Menu as Se } from "@base-ui/react/menu";
|
|
39
39
|
import { Toggle as Pp } from "@base-ui/react/toggle";
|
|
40
40
|
import { Accordion as Ft } from "@base-ui/react/accordion";
|
|
@@ -138,7 +138,7 @@ import './editable.css';var Xl = (e, t) => {
|
|
|
138
138
|
children: n
|
|
139
139
|
});
|
|
140
140
|
}, De = ({ id: e, ariaLabel: t, ariaLabelledBy: n }, r = !0) => {
|
|
141
|
-
const a = Le(jl), i = Ue(), [l] =
|
|
141
|
+
const a = Le(jl), i = Ue(), [l] = Z(() => r ? a?.claimControlId(i) ?? !1 : !1), s = e ?? (l ? a?.controlId : void 0), c = n ?? (t === void 0 ? a?.labelId : void 0);
|
|
142
142
|
return {
|
|
143
143
|
...s !== void 0 && { id: s },
|
|
144
144
|
...t !== void 0 && { "aria-label": t },
|
|
@@ -169,17 +169,17 @@ var Yl = "srewh00", _p = "srewh01", Fp = {
|
|
|
169
169
|
dismiss: () => {
|
|
170
170
|
}
|
|
171
171
|
}), Er = ({ className: e, children: t }) => {
|
|
172
|
-
const [n, r] =
|
|
173
|
-
i(!1), s((
|
|
174
|
-
...
|
|
172
|
+
const [n, r] = Z(!1), [a, i] = Z(!1), [l, s] = Z(Fp), c = fe((m, v) => {
|
|
173
|
+
i(!1), s((y) => ({
|
|
174
|
+
...y,
|
|
175
175
|
[v]: m,
|
|
176
176
|
last: v
|
|
177
177
|
}));
|
|
178
178
|
}, []), d = fe((m, v) => {
|
|
179
|
-
s((
|
|
180
|
-
...
|
|
179
|
+
s((y) => y[v] === m ? {
|
|
180
|
+
...y,
|
|
181
181
|
[v]: null
|
|
182
|
-
} :
|
|
182
|
+
} : y);
|
|
183
183
|
}, []), u = fe(() => i(!0), []), h = Bp(l), p = z(() => ({
|
|
184
184
|
hovered: n,
|
|
185
185
|
dismissed: a,
|
|
@@ -207,16 +207,16 @@ var Yl = "srewh00", _p = "srewh01", Fp = {
|
|
|
207
207
|
})
|
|
208
208
|
});
|
|
209
209
|
}, it = ({ label: e, checked: t = !1, side: n, delay: r, nameTrigger: a = !0, children: i }) => {
|
|
210
|
-
const { hovered: l, dismissed: s, reachedTooltipId: c, reach: d, release: u, dismiss: h } = Le(Zl), p = Ue(), [g, m] =
|
|
210
|
+
const { hovered: l, dismissed: s, reachedTooltipId: c, reach: d, release: u, dismiss: h } = Le(Zl), p = Ue(), [g, m] = Z(!1), v = l ? !s && (c === p || t && c === null) : g;
|
|
211
211
|
W(() => () => {
|
|
212
212
|
u(p, "pointer"), u(p, "focus");
|
|
213
213
|
}, [p, u]);
|
|
214
|
-
const
|
|
214
|
+
const y = (b, T) => {
|
|
215
215
|
T.reason === "escape-key" && (h(), T.allowPropagation()), m(b);
|
|
216
216
|
};
|
|
217
217
|
return /* @__PURE__ */ f(Ee.Root, {
|
|
218
218
|
open: v,
|
|
219
|
-
onOpenChange:
|
|
219
|
+
onOpenChange: y,
|
|
220
220
|
disableHoverablePopup: !0,
|
|
221
221
|
children: [/* @__PURE__ */ o(Ee.Trigger, {
|
|
222
222
|
render: i,
|
|
@@ -250,7 +250,7 @@ var Gp = {
|
|
|
250
250
|
id: m,
|
|
251
251
|
ariaLabel: p,
|
|
252
252
|
ariaLabelledBy: g
|
|
253
|
-
}),
|
|
253
|
+
}), y = r === "tile", b = /* @__PURE__ */ f("button", {
|
|
254
254
|
type: "button",
|
|
255
255
|
className: Gp[r],
|
|
256
256
|
disabled: i,
|
|
@@ -266,7 +266,7 @@ var Gp = {
|
|
|
266
266
|
children: t
|
|
267
267
|
}),
|
|
268
268
|
e !== void 0 && /* @__PURE__ */ o("span", {
|
|
269
|
-
className:
|
|
269
|
+
className: y ? "woi4bh3" : "woi4bh1",
|
|
270
270
|
children: e
|
|
271
271
|
}),
|
|
272
272
|
a !== void 0 && r === "default" && /* @__PURE__ */ o("span", {
|
|
@@ -305,7 +305,7 @@ var Gp = {
|
|
|
305
305
|
}, Vp = "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))", Wp = "linear-gradient(135deg, var(--graphy-white) 50%, var(--graphy-black) 50%) border-box", Jl = "_14ty2ng0", uo = "_14ty2ng1", Up = "_14ty2ng2", Kp = "_14ty2ng3", Ql = "_14ty2ng4", Xp = "_14ty2ng5", jp = "_14ty2ng6", xn = "transparent", es = (e) => e === "transparent" ? {
|
|
306
306
|
background: Vp,
|
|
307
307
|
border: `1px solid ${Ce.border100}`
|
|
308
|
-
} : e ===
|
|
308
|
+
} : e === Tt ? {
|
|
309
309
|
background: Wp,
|
|
310
310
|
border: `1px solid ${co.border}`
|
|
311
311
|
} : {
|
|
@@ -316,7 +316,7 @@ var Gp = {
|
|
|
316
316
|
id: u,
|
|
317
317
|
ariaLabel: h,
|
|
318
318
|
ariaLabelledBy: p
|
|
319
|
-
}, !1), v = a !== void 0 || i,
|
|
319
|
+
}, !1), v = a !== void 0 || i, y = (b) => {
|
|
320
320
|
const T = b === "transparent" ? g("graph.colorDropdown.transparent") : b, w = l?.[b], k = /* @__PURE__ */ o("button", {
|
|
321
321
|
type: "button",
|
|
322
322
|
"aria-label": w ?? T,
|
|
@@ -345,7 +345,7 @@ var Gp = {
|
|
|
345
345
|
}), /* @__PURE__ */ f("div", {
|
|
346
346
|
className: Up,
|
|
347
347
|
...m,
|
|
348
|
-
children: [t.map(
|
|
348
|
+
children: [t.map(y), v && /* @__PURE__ */ f("span", {
|
|
349
349
|
className: "_14ty2ng5",
|
|
350
350
|
children: [
|
|
351
351
|
/* @__PURE__ */ o("span", {
|
|
@@ -353,14 +353,14 @@ var Gp = {
|
|
|
353
353
|
"aria-hidden": "true"
|
|
354
354
|
}),
|
|
355
355
|
a,
|
|
356
|
-
i &&
|
|
356
|
+
i && y("transparent")
|
|
357
357
|
]
|
|
358
358
|
})]
|
|
359
359
|
})]
|
|
360
360
|
});
|
|
361
|
-
}, ka = (e, t) => t !== null && e.toLowerCase() === t.toLowerCase(), Yp = "data-graphy-chart-chrome", Zp = "data-graphy-chart-menu", Jp = { [Zp]: "" }, Kn = (e) => ({ [Yp]: e }), zt = (e, t) => e instanceof Element && e.closest(`[data-graphy-chart-chrome="${CSS.escape(t)}"]`) !== null, kn = (e) => e instanceof Element && e.closest("[data-graphy-chart-menu]") !== null, Rr = (e) => e instanceof Element && e.closest("[data-graphy-chart-chrome]") !== null,
|
|
362
|
-
const { chartId: t } = j(), [n] =
|
|
363
|
-
return n === null ? null : /* @__PURE__ */ f(
|
|
361
|
+
}, ka = (e, t) => t !== null && e.toLowerCase() === t.toLowerCase(), Yp = "data-graphy-chart-chrome", Zp = "data-graphy-chart-menu", Jp = { [Zp]: "" }, Kn = (e) => ({ [Yp]: e }), zt = (e, t) => e instanceof Element && e.closest(`[data-graphy-chart-chrome="${CSS.escape(t)}"]`) !== null, kn = (e) => e instanceof Element && e.closest("[data-graphy-chart-menu]") !== null, Rr = (e) => e instanceof Element && e.closest("[data-graphy-chart-chrome]") !== null, xt = (e, t, n) => e instanceof Node && (t.contains(e) || zt(e, n)), Qp = "cml7ha0", ts = lt(null), eg = ({ children: e }) => {
|
|
362
|
+
const { chartId: t } = j(), [n] = Z(Re), [r, a] = Z(null);
|
|
363
|
+
return n === null ? null : /* @__PURE__ */ f(J, { children: [Sa(/* @__PURE__ */ o("div", {
|
|
364
364
|
ref: a,
|
|
365
365
|
className: Qp,
|
|
366
366
|
...Kn(t)
|
|
@@ -373,7 +373,7 @@ var Gp = {
|
|
|
373
373
|
align: "shift",
|
|
374
374
|
fallbackAxisSide: "end"
|
|
375
375
|
}, dg = ({ value: e, onChange: t, onCommit: n, popupAttributes: r, variant: a = "default" }) => {
|
|
376
|
-
const i = N(), l = Xn(), [s, c] =
|
|
376
|
+
const i = N(), l = Xn(), [s, c] = Z(!1), d = (p) => {
|
|
377
377
|
c(p), p || n?.();
|
|
378
378
|
}, u = e !== null && Cu(e) ? e : "#000000", h = Xd(u) ? u.toUpperCase() : "#000000";
|
|
379
379
|
return /* @__PURE__ */ f(ge.Root, {
|
|
@@ -565,7 +565,7 @@ var xg = ({ value: e, onChange: t, onCommit: n, min: r, max: a, step: i, placeho
|
|
|
565
565
|
id: g,
|
|
566
566
|
ariaLabel: h,
|
|
567
567
|
ariaLabelledBy: p
|
|
568
|
-
}), { commitUnlessHeldKey: v, gestureHandlers:
|
|
568
|
+
}), { commitUnlessHeldKey: v, gestureHandlers: y } = Yn(n);
|
|
569
569
|
return /* @__PURE__ */ o(wn.Root, {
|
|
570
570
|
className: Sg,
|
|
571
571
|
value: e,
|
|
@@ -589,7 +589,7 @@ var xg = ({ value: e, onChange: t, onCommit: n, min: r, max: a, step: i, placeho
|
|
|
589
589
|
/* @__PURE__ */ o(wn.Input, {
|
|
590
590
|
className: Cg,
|
|
591
591
|
placeholder: l,
|
|
592
|
-
...
|
|
592
|
+
...y,
|
|
593
593
|
"aria-invalid": u === !0 ? !0 : void 0,
|
|
594
594
|
...m
|
|
595
595
|
}),
|
|
@@ -613,12 +613,12 @@ var Ag = 6, Pg = ({ options: e, value: t, onChange: n, onCommit: r, columns: a,
|
|
|
613
613
|
id: d,
|
|
614
614
|
ariaLabel: s,
|
|
615
615
|
ariaLabelledBy: c
|
|
616
|
-
}), h = i === "tile", p = i === "swatch", g = i === "icon", m = i === "track", v = i === "chip", { commitAfterChange:
|
|
616
|
+
}), h = i === "tile", p = i === "swatch", g = i === "icon", m = i === "track", v = i === "chip", { commitAfterChange: y, gestureHandlers: b } = Yn(r);
|
|
617
617
|
return /* @__PURE__ */ o($l, {
|
|
618
618
|
className: ot(kg, Lg(a ?? e.length), g && "_1b7s5f9", m && "_1b7s5fb", v && "_1b7s5fd"),
|
|
619
619
|
value: t,
|
|
620
620
|
onValueChange: (T) => {
|
|
621
|
-
n(T),
|
|
621
|
+
n(T), y();
|
|
622
622
|
},
|
|
623
623
|
...b,
|
|
624
624
|
disabled: l,
|
|
@@ -740,22 +740,22 @@ var Ug = ({ value: e, onChange: t, onCommit: n, min: r, max: a, step: i, suffix:
|
|
|
740
740
|
}, !1), g = Kg(e, l, s), { commitUnlessHeldKey: m, gestureHandlers: v } = Yn(n);
|
|
741
741
|
return /* @__PURE__ */ f("div", {
|
|
742
742
|
className: zg,
|
|
743
|
-
children: [/* @__PURE__ */ o(
|
|
743
|
+
children: [/* @__PURE__ */ o(Rt.Root, {
|
|
744
744
|
className: Hg,
|
|
745
745
|
value: e,
|
|
746
|
-
onValueChange: (
|
|
747
|
-
onValueCommitted: (
|
|
746
|
+
onValueChange: (y) => t(y),
|
|
747
|
+
onValueCommitted: (y, b) => {
|
|
748
748
|
m(b.reason === ns);
|
|
749
749
|
},
|
|
750
750
|
min: r,
|
|
751
751
|
max: a,
|
|
752
752
|
step: i,
|
|
753
753
|
disabled: d,
|
|
754
|
-
children: /* @__PURE__ */ o(
|
|
754
|
+
children: /* @__PURE__ */ o(Rt.Control, {
|
|
755
755
|
className: Gg,
|
|
756
|
-
children: /* @__PURE__ */ f(
|
|
756
|
+
children: /* @__PURE__ */ f(Rt.Track, {
|
|
757
757
|
className: $g,
|
|
758
|
-
children: [/* @__PURE__ */ o(
|
|
758
|
+
children: [/* @__PURE__ */ o(Rt.Indicator, { className: Vg }), /* @__PURE__ */ o(Rt.Thumb, {
|
|
759
759
|
className: Wg,
|
|
760
760
|
...v,
|
|
761
761
|
...p
|
|
@@ -782,7 +782,7 @@ var Qg = 1e-9, em = (e) => {
|
|
|
782
782
|
id: u,
|
|
783
783
|
ariaLabel: c,
|
|
784
784
|
ariaLabelledBy: d
|
|
785
|
-
}),
|
|
785
|
+
}), y = N(), b = i ?? y("editor.accessibility.decrease"), T = l ?? y("editor.accessibility.increase"), [w, k] = Z(t), [x, L] = Z(t);
|
|
786
786
|
t !== x && (L(t), k(t));
|
|
787
787
|
const I = t === null ? void 0 : m(t), P = t === null ? void 0 : g(t), H = (A) => {
|
|
788
788
|
A !== void 0 && (k(A), n(A));
|
|
@@ -827,8 +827,8 @@ var Qg = 1e-9, em = (e) => {
|
|
|
827
827
|
return;
|
|
828
828
|
}
|
|
829
829
|
if (A.key !== "ArrowUp" && A.key !== "ArrowDown" || (A.preventBaseUIHandler(), A.preventDefault(), A.repeat)) return;
|
|
830
|
-
const
|
|
831
|
-
|
|
830
|
+
const S = w ?? t;
|
|
831
|
+
S !== null && (R(C), H(A.key === "ArrowUp" ? g(S) : m(S)));
|
|
832
832
|
},
|
|
833
833
|
...v
|
|
834
834
|
}), r !== void 0 && /* @__PURE__ */ o("span", {
|
|
@@ -943,7 +943,7 @@ var as = ({ options: e, value: t, onChange: n, onCommit: r, itemLayout: a = "inl
|
|
|
943
943
|
disabled: l,
|
|
944
944
|
...u,
|
|
945
945
|
children: e.map((m) => {
|
|
946
|
-
const v = dm(m, h),
|
|
946
|
+
const v = dm(m, h), y = /* @__PURE__ */ f(Gl.Root, {
|
|
947
947
|
value: m.value,
|
|
948
948
|
disabled: m.disabled,
|
|
949
949
|
className: ot(cm, h && "cnu9yl3", i && "cnu9yl2"),
|
|
@@ -953,10 +953,10 @@ var as = ({ options: e, value: t, onChange: n, onCommit: r, itemLayout: a = "inl
|
|
|
953
953
|
children: m.label
|
|
954
954
|
})]
|
|
955
955
|
}, m.value);
|
|
956
|
-
return v === void 0 ?
|
|
956
|
+
return v === void 0 ? y : /* @__PURE__ */ o(it, {
|
|
957
957
|
label: v,
|
|
958
958
|
checked: m.value === t,
|
|
959
|
-
children:
|
|
959
|
+
children: y
|
|
960
960
|
}, m.value);
|
|
961
961
|
})
|
|
962
962
|
});
|
|
@@ -1056,7 +1056,7 @@ is.hasRows = (e, { scene: t }) => t.coordSystem.type !== "polar";
|
|
|
1056
1056
|
var gm = ({ graph: e, axis: t }) => {
|
|
1057
1057
|
const n = oe(e), r = N(), { NumberField: a, TextField: i, ToggleGroup: l } = U(), s = n?.guides.axes.find((P) => P.scaledAesthetic === t);
|
|
1058
1058
|
if (W(() => () => e.commands.commit(), [e.commands]), n === null || s?.geometry !== "linear") return null;
|
|
1059
|
-
const c = !s.visible, d = s.visible || s.showGrid, u = n.scales[t]?.spec.scaleType, h = u === "continuous" || u === "datetime", p = n.guides.legends.drawn.some((P) => P.position === "left" || P.position === "right"), g = t !== "x" && u === "continuous" && (s.position === "left" || s.position === "right") && !p, m = t === "x" ? void 0 : n.scales[t]?.spec, v = m?.scaleType === "continuous" ? m : void 0,
|
|
1059
|
+
const c = !s.visible, d = s.visible || s.showGrid, u = n.scales[t]?.spec.scaleType, h = u === "continuous" || u === "datetime", p = n.guides.legends.drawn.some((P) => P.position === "left" || P.position === "right"), g = t !== "x" && u === "continuous" && (s.position === "left" || s.position === "right") && !p, m = t === "x" ? void 0 : n.scales[t]?.spec, v = m?.scaleType === "continuous" ? m : void 0, y = v !== void 0 && (s.position === "left" || s.position === "right") && !El(n, t), b = v?.transform === "log" ? "log" : "linear", T = y && v.transform !== "log", w = v?.domainMin ?? null, k = v !== void 0 && (s.position === "left" || s.position === "right") && v.transform !== "log", x = v?.domainMax ?? null, L = n.config.axes[t]?.label ?? s.label ?? "", I = (P) => {
|
|
1060
1060
|
const H = t === "ySecondary" ? {
|
|
1061
1061
|
axis: t,
|
|
1062
1062
|
label: P
|
|
@@ -1066,7 +1066,7 @@ var gm = ({ graph: e, axis: t }) => {
|
|
|
1066
1066
|
};
|
|
1067
1067
|
e.commands.dispatch(new sl(H), { transient: !0 });
|
|
1068
1068
|
};
|
|
1069
|
-
return /* @__PURE__ */ f(
|
|
1069
|
+
return /* @__PURE__ */ f(J, { children: [
|
|
1070
1070
|
/* @__PURE__ */ o(M, {
|
|
1071
1071
|
label: r("editor.axesPanel.controls.title"),
|
|
1072
1072
|
children: /* @__PURE__ */ o(i, {
|
|
@@ -1125,7 +1125,7 @@ var gm = ({ graph: e, axis: t }) => {
|
|
|
1125
1125
|
}
|
|
1126
1126
|
})
|
|
1127
1127
|
}),
|
|
1128
|
-
|
|
1128
|
+
y && /* @__PURE__ */ o(M, {
|
|
1129
1129
|
label: r("editor.axesPanel.controls.scale"),
|
|
1130
1130
|
children: /* @__PURE__ */ o(l, {
|
|
1131
1131
|
value: b,
|
|
@@ -1152,7 +1152,7 @@ var gm = ({ graph: e, axis: t }) => {
|
|
|
1152
1152
|
value: w,
|
|
1153
1153
|
placeholder: r("editor.axesPanel.startFrom.auto"),
|
|
1154
1154
|
onChange: (P) => {
|
|
1155
|
-
e.commands.dispatch(new
|
|
1155
|
+
e.commands.dispatch(new Qe({
|
|
1156
1156
|
scaledAesthetic: t,
|
|
1157
1157
|
domainMin: P
|
|
1158
1158
|
}), { transient: !0 });
|
|
@@ -1166,7 +1166,7 @@ var gm = ({ graph: e, axis: t }) => {
|
|
|
1166
1166
|
value: x,
|
|
1167
1167
|
placeholder: r("editor.axesPanel.endAt.auto"),
|
|
1168
1168
|
onChange: (P) => {
|
|
1169
|
-
e.commands.dispatch(new
|
|
1169
|
+
e.commands.dispatch(new Qe({
|
|
1170
1170
|
scaledAesthetic: t,
|
|
1171
1171
|
domainMax: P
|
|
1172
1172
|
}), { transient: !0 });
|
|
@@ -1192,7 +1192,7 @@ var gm = ({ graph: e, axis: t }) => {
|
|
|
1192
1192
|
fill: "currentColor"
|
|
1193
1193
|
})
|
|
1194
1194
|
});
|
|
1195
|
-
}, fm = 6,
|
|
1195
|
+
}, fm = 6, Xe = ({ target: e }) => {
|
|
1196
1196
|
const { commands: t, findGeom: n } = j(), r = N(), a = re(), i = G((u) => u), l = ss(e, i, n);
|
|
1197
1197
|
W(() => () => t.commit(), [t]);
|
|
1198
1198
|
const s = z(() => Uh({
|
|
@@ -1240,7 +1240,7 @@ var gm = ({ graph: e, axis: t }) => {
|
|
|
1240
1240
|
})
|
|
1241
1241
|
});
|
|
1242
1242
|
};
|
|
1243
|
-
|
|
1243
|
+
Xe.hasRows = (e, { scene: t, findGeom: n }) => ss(e, t, n) !== null;
|
|
1244
1244
|
var ss = (e, t, n) => {
|
|
1245
1245
|
if (ne(t.layers, e.layerId) === void 0) return null;
|
|
1246
1246
|
const r = Kh({
|
|
@@ -1262,7 +1262,7 @@ var ss = (e, t, n) => {
|
|
|
1262
1262
|
width: 0.95
|
|
1263
1263
|
}
|
|
1264
1264
|
], cs = ({ target: e }) => {
|
|
1265
|
-
const t = G((p) => p), n = Pe(), r = N(), { ToggleGroup: a } = U(), i = ne(t.spec.layers, e.layerId), l =
|
|
1265
|
+
const t = G((p) => p), n = Pe(), r = N(), { ToggleGroup: a } = U(), i = ne(t.spec.layers, e.layerId), l = Lt(i, "bar") ? i : null, s = t.coordSystem.type === "polar" && t.coordSystem.bandAxis === null, c = (p) => {
|
|
1266
1266
|
const g = lr.find(({ name: m }) => m === p);
|
|
1267
1267
|
g !== void 0 && n.dispatch(new dl({
|
|
1268
1268
|
layerId: e.layerId,
|
|
@@ -1273,7 +1273,7 @@ var ss = (e, t, n) => {
|
|
|
1273
1273
|
label: r(`editor.graphPanel.barSection.widths.${p}`),
|
|
1274
1274
|
icon: /* @__PURE__ */ o(vm, { barWidth: p })
|
|
1275
1275
|
})), u = l === null ? null : Dl(l.params, t.coordSystem.type), h = lr.find(({ width: p }) => p === u)?.name ?? "";
|
|
1276
|
-
return /* @__PURE__ */ f(
|
|
1276
|
+
return /* @__PURE__ */ f(J, { children: [/* @__PURE__ */ o(Xe, { target: e }), l !== null && !s ? /* @__PURE__ */ o(M, {
|
|
1277
1277
|
label: r("editor.graphPanel.barSection.thickness"),
|
|
1278
1278
|
children: /* @__PURE__ */ o(a, {
|
|
1279
1279
|
value: h,
|
|
@@ -1282,7 +1282,7 @@ var ss = (e, t, n) => {
|
|
|
1282
1282
|
})
|
|
1283
1283
|
}) : null] });
|
|
1284
1284
|
};
|
|
1285
|
-
cs.hasRows =
|
|
1285
|
+
cs.hasRows = Xe.hasRows;
|
|
1286
1286
|
var ym = {
|
|
1287
1287
|
smooth: "M2 13C6 13 7 5 10 5s4 6 6 6",
|
|
1288
1288
|
linear: "M2 13l5-8 4 6 5-4"
|
|
@@ -1347,8 +1347,8 @@ var Dr = [
|
|
|
1347
1347
|
"connect"
|
|
1348
1348
|
], Ta = (e, t, n) => {
|
|
1349
1349
|
const r = ne(e.spec.layers, n);
|
|
1350
|
-
if (!
|
|
1351
|
-
const a = e.coordSystem.type === "polar", i =
|
|
1350
|
+
if (!Lt(r, "line", "area")) return null;
|
|
1351
|
+
const a = e.coordSystem.type === "polar", i = At(r.geom, r.id), l = Me(e.spec), s = e.spec.styles.overrides, c = oo(s, i, l), d = oo(Jh(s, i, l), i, l), u = typeof c?.strokeWidth == "number" ? c.strokeWidth : null, h = km(r, e.spec.layers), p = a ? [] : Am(r), g = p.length > 1, m = r.geom === "line" && !a, v = m ? Lm(e, t, r) : 0;
|
|
1352
1352
|
return {
|
|
1353
1353
|
layerId: r.id,
|
|
1354
1354
|
showPoints: h !== void 0 && Tm(e, t, h.id),
|
|
@@ -2304,7 +2304,7 @@ var Jm = "_1a90obs1", Qm = [
|
|
|
2304
2304
|
stackedBars: "stacked",
|
|
2305
2305
|
lines: "lines"
|
|
2306
2306
|
}, a1 = () => {
|
|
2307
|
-
const e = G((L) => L.spec), t = G(({ layers: L }) => L.some((I) => $n(I.data, I.mapping))), n = Pe(), r = N(), { Button: a, RadioGrid: i } = U(), [l, s] =
|
|
2307
|
+
const e = G((L) => L.spec), t = G(({ layers: L }) => L.some((I) => $n(I.data, I.mapping))), n = Pe(), r = N(), { Button: a, RadioGrid: i } = U(), [l, s] = Z(!1), c = te(null);
|
|
2308
2308
|
W(() => {
|
|
2309
2309
|
if (!l) return;
|
|
2310
2310
|
const L = ({ target: I, detail: P }) => {
|
|
@@ -2314,18 +2314,18 @@ var Jm = "_1a90obs1", Qm = [
|
|
|
2314
2314
|
}, [l]);
|
|
2315
2315
|
const d = Vn(e);
|
|
2316
2316
|
if (d === null) return null;
|
|
2317
|
-
const u = l1(d), h = Pn(d), p = Tn(d), g = u ?? p, m = r(g === null ? "editor.overlayMenu.customChartType" : `editor.graphTypes.${g.name}`), v = (u === void 0 ? p : So(u, h))?.icon,
|
|
2317
|
+
const u = l1(d), h = Pn(d), p = Tn(d), g = u ?? p, m = r(g === null ? "editor.overlayMenu.customChartType" : `editor.graphTypes.${g.name}`), v = (u === void 0 ? p : So(u, h))?.icon, y = u !== void 0 && u.arrangements.length > 1, b = y && (t || u.name === "combo"), T = () => s(!l), w = ({ summary: L }) => {
|
|
2318
2318
|
n.dispatch(new sa(gs(L, d)), { transient: !0 });
|
|
2319
2319
|
}, k = (L) => {
|
|
2320
2320
|
const I = yo.find((P) => P.name === L);
|
|
2321
|
-
I !== void 0 && w(So(I,
|
|
2321
|
+
I !== void 0 && w(So(I, y ? h : null));
|
|
2322
2322
|
}, x = yo.map(({ name: L, arrangements: [I] }) => ({
|
|
2323
2323
|
value: L,
|
|
2324
2324
|
label: r(`editor.graphTypes.${L}`),
|
|
2325
2325
|
icon: /* @__PURE__ */ o(I.icon, { size: "md" }),
|
|
2326
2326
|
disabled: !ps(I.summary, e)
|
|
2327
2327
|
}));
|
|
2328
|
-
return /* @__PURE__ */ f(
|
|
2328
|
+
return /* @__PURE__ */ f(J, { children: [
|
|
2329
2329
|
/* @__PURE__ */ o(M, {
|
|
2330
2330
|
label: r("editor.overlayMenu.chartType"),
|
|
2331
2331
|
children: v === void 0 ? /* @__PURE__ */ o(a, {
|
|
@@ -2394,7 +2394,7 @@ var Jm = "_1a90obs1", Qm = [
|
|
|
2394
2394
|
})
|
|
2395
2395
|
});
|
|
2396
2396
|
}, i1 = (e) => e instanceof Element && e.closest('[role="radio"]:not([aria-disabled="true"])') !== null, Pn = (e) => Ae(e) ? r1[e.comboType] : n1[e.position], So = (e, t) => e.arrangements.find(({ summary: n }) => Pn(n) === t) ?? e.arrangements[0], l1 = (e) => fs.find(({ arrangements: [t] }) => vs(t.summary, e)), s1 = () => {
|
|
2397
|
-
const e = G((s) => s.scales.color), t = Pe(), n = N(), [r, a] =
|
|
2397
|
+
const e = G((s) => s.scales.color), t = Pe(), n = N(), [r, a] = Z(null);
|
|
2398
2398
|
W(() => () => t.commit(), [t]);
|
|
2399
2399
|
const i = Nl(e), l = _h(e, r === null ? i : [r, ...i]);
|
|
2400
2400
|
return (l === null ? [{
|
|
@@ -2582,9 +2582,9 @@ var A7 = 512 * 1024, v1 = (e) => new Promise((t) => {
|
|
|
2582
2582
|
})
|
|
2583
2583
|
});
|
|
2584
2584
|
}, Aa = ({ symbol: e, coordType: t, onChange: n }) => {
|
|
2585
|
-
const r = N(), { RadioGrid: a } = U(), [i, l] =
|
|
2585
|
+
const r = N(), { RadioGrid: a } = U(), [i, l] = Z(null), s = Le(jn), c = bu(), d = Yi(), u = s ? s.getPointSymbols(t) : d("point", t)?.symbols, h = s ? new Map(s.getGlyphs().map(({ name: x, definition: L }) => [x, L])) : c;
|
|
2586
2586
|
if (u === void 0 || u.length === 0) return null;
|
|
2587
|
-
const p = (x) => typeof x == "string" && u.includes(x), g = (x) => p(x) || Or(x) || !_t(x) && h.has(x), m = (x) => !_t(x) || f1.some((L) => L === x), v = [...h.keys()].filter((x) => !_t(x) && !p(x)),
|
|
2587
|
+
const p = (x) => typeof x == "string" && u.includes(x), g = (x) => p(x) || Or(x) || !_t(x) && h.has(x), m = (x) => !_t(x) || f1.some((L) => L === x), v = [...h.keys()].filter((x) => !_t(x) && !p(x)), y = [...u.filter(m), ...v], b = e === null ? "" : nn(e), T = e === null || y.some((x) => nn(x) === b) || !g(e) ? y : [...y, e], w = (x) => _t(x) ? r(`editor.graphPanel.pointSymbol.symbols.${x}`) : Or(x) ? r("editor.graphPanel.pointSymbol.custom") : x, k = (x) => {
|
|
2588
2588
|
l(null);
|
|
2589
2589
|
const L = T.find((I) => nn(I) === x);
|
|
2590
2590
|
L !== void 0 && n(L);
|
|
@@ -2742,63 +2742,63 @@ var A7 = 512 * 1024, v1 = (e) => new Promise((t) => {
|
|
|
2742
2742
|
"inside",
|
|
2743
2743
|
"outside"
|
|
2744
2744
|
], xs = () => {
|
|
2745
|
-
const e = G((
|
|
2745
|
+
const e = G((S) => S), t = re(), n = ra(), r = Pe(), a = N(), { Switch: i, ToggleGroup: l } = U(), s = ks(e.layers, e.coordSystem.type, n), c = (S) => s.filter(({ support: E }) => S(E)).map(({ layer: E }) => E), d = P1(e, t), u = d.filter((S) => S.smooth !== null), h = d.filter((S) => S.missingValues !== null && S.missingValueOptions.length > 1), p = Dr.filter((S) => h.some((E) => E.missingValueOptions.includes(S))), g = O1(u), m = E1(h), v = (S) => {
|
|
2746
2746
|
r.dispatch(new st({ commands: d.map((E) => new da({
|
|
2747
2747
|
layerId: E.layerId,
|
|
2748
|
-
showPoints:
|
|
2748
|
+
showPoints: S
|
|
2749
2749
|
})) }));
|
|
2750
|
-
},
|
|
2751
|
-
const E = ko.find(($) => $ ===
|
|
2750
|
+
}, y = (S) => {
|
|
2751
|
+
const E = ko.find(($) => $ === S);
|
|
2752
2752
|
E !== void 0 && r.dispatch(new st({ commands: u.map(($) => new fl({
|
|
2753
2753
|
layerId: $.layerId,
|
|
2754
2754
|
curve: E
|
|
2755
2755
|
})) }));
|
|
2756
|
-
}, b = c((
|
|
2757
|
-
const E = To.find(($) => $ ===
|
|
2756
|
+
}, b = c((S) => S.supportsPosition), T = an(b.map((S) => S.dataLabels.position)) ?? "", w = (S) => {
|
|
2757
|
+
const E = To.find(($) => $ === S);
|
|
2758
2758
|
E !== void 0 && r.dispatch(new st({ commands: b.map(($) => new gl({
|
|
2759
2759
|
layerId: $.id,
|
|
2760
2760
|
position: E
|
|
2761
2761
|
})) }));
|
|
2762
|
-
}, k = (
|
|
2763
|
-
const E = Dr.find((_) => _ ===
|
|
2762
|
+
}, k = (S) => {
|
|
2763
|
+
const E = Dr.find((_) => _ === S);
|
|
2764
2764
|
if (E === void 0) return;
|
|
2765
2765
|
const $ = h.filter((_) => _.missingValueOptions.includes(E)).map((_) => new bl({
|
|
2766
2766
|
layerId: _.layerId,
|
|
2767
2767
|
missingValues: E
|
|
2768
2768
|
}));
|
|
2769
2769
|
$.length !== 0 && r.dispatch(new st({ commands: $ }));
|
|
2770
|
-
}, x = d.filter((
|
|
2771
|
-
|
|
2772
|
-
}, B = (
|
|
2770
|
+
}, x = d.filter((S) => S.showFill !== null), L = d.filter((S) => S.showPoints), I = L1(e, t, d), P = x.some((S) => I1(e, S)), H = (S) => {
|
|
2771
|
+
S.length > 0 && r.dispatch(new st({ commands: S }));
|
|
2772
|
+
}, B = (S) => {
|
|
2773
2773
|
H(d.map((E) => new We({
|
|
2774
2774
|
layerId: E.layerId,
|
|
2775
|
-
strokeWidth:
|
|
2775
|
+
strokeWidth: S
|
|
2776
2776
|
})));
|
|
2777
|
-
}, R = (
|
|
2777
|
+
}, R = (S) => {
|
|
2778
2778
|
H(d.map((E) => new We({
|
|
2779
2779
|
layerId: E.layerId,
|
|
2780
|
-
lineStyle:
|
|
2780
|
+
lineStyle: S
|
|
2781
2781
|
})));
|
|
2782
|
-
}, A = (
|
|
2782
|
+
}, A = (S) => {
|
|
2783
2783
|
H(x.map((E) => new We({
|
|
2784
2784
|
layerId: E.layerId,
|
|
2785
|
-
showFill:
|
|
2785
|
+
showFill: S,
|
|
2786
2786
|
drawnFillAlpha: E.drawnFillAlpha
|
|
2787
2787
|
})));
|
|
2788
|
-
}, C = (
|
|
2788
|
+
}, C = (S) => {
|
|
2789
2789
|
H(L.flatMap(({ pointLayerId: E }) => E === null ? [] : [new zn({
|
|
2790
2790
|
layerId: E,
|
|
2791
|
-
size:
|
|
2791
|
+
size: S
|
|
2792
2792
|
})]));
|
|
2793
2793
|
};
|
|
2794
|
-
return /* @__PURE__ */ f(
|
|
2794
|
+
return /* @__PURE__ */ f(J, { children: [
|
|
2795
2795
|
/* @__PURE__ */ o(a1, {}),
|
|
2796
2796
|
/* @__PURE__ */ o(on, {
|
|
2797
2797
|
label: a("editor.graphPanel.graphOptions.dataLabels"),
|
|
2798
|
-
layers: c((
|
|
2799
|
-
isOn: (
|
|
2800
|
-
buildCommand: (
|
|
2801
|
-
layerId:
|
|
2798
|
+
layers: c((S) => S.supportsDataLabels),
|
|
2799
|
+
isOn: (S) => S.showDataLabels,
|
|
2800
|
+
buildCommand: (S, E) => new Cl({
|
|
2801
|
+
layerId: S,
|
|
2802
2802
|
showDataLabels: E
|
|
2803
2803
|
})
|
|
2804
2804
|
}),
|
|
@@ -2806,37 +2806,37 @@ var A7 = 512 * 1024, v1 = (e) => new Promise((t) => {
|
|
|
2806
2806
|
label: a("editor.graphPanel.graphOptions.labelPosition"),
|
|
2807
2807
|
children: /* @__PURE__ */ o(l, {
|
|
2808
2808
|
value: T,
|
|
2809
|
-
options: To.map((
|
|
2810
|
-
value:
|
|
2811
|
-
label: a(`editor.graphPanel.graphOptions.labelPositions.${
|
|
2809
|
+
options: To.map((S) => ({
|
|
2810
|
+
value: S,
|
|
2811
|
+
label: a(`editor.graphPanel.graphOptions.labelPositions.${S}`)
|
|
2812
2812
|
})),
|
|
2813
2813
|
onChange: w
|
|
2814
2814
|
})
|
|
2815
2815
|
}),
|
|
2816
2816
|
/* @__PURE__ */ o(on, {
|
|
2817
2817
|
label: a("editor.graphPanel.graphOptions.showPercentages"),
|
|
2818
|
-
layers: c((
|
|
2819
|
-
isOn: (
|
|
2820
|
-
buildCommand: (
|
|
2821
|
-
layerId:
|
|
2818
|
+
layers: c((S) => S.supportsPercentages),
|
|
2819
|
+
isOn: (S) => S.format === "percentage",
|
|
2820
|
+
buildCommand: (S, E) => new ml({
|
|
2821
|
+
layerId: S,
|
|
2822
2822
|
format: E ? "percentage" : "absolute"
|
|
2823
2823
|
})
|
|
2824
2824
|
}),
|
|
2825
2825
|
/* @__PURE__ */ o(on, {
|
|
2826
2826
|
label: a("editor.graphPanel.graphOptions.stackTotals"),
|
|
2827
|
-
layers: c((
|
|
2828
|
-
isOn: (
|
|
2829
|
-
buildCommand: (
|
|
2830
|
-
layerId:
|
|
2827
|
+
layers: c((S) => S.supportsStackTotals),
|
|
2828
|
+
isOn: (S) => S.showStackTotals,
|
|
2829
|
+
buildCommand: (S, E) => new xl({
|
|
2830
|
+
layerId: S,
|
|
2831
2831
|
showStackTotals: E
|
|
2832
2832
|
})
|
|
2833
2833
|
}),
|
|
2834
2834
|
/* @__PURE__ */ o(on, {
|
|
2835
2835
|
label: a("editor.graphPanel.graphOptions.categoryLabels"),
|
|
2836
|
-
layers: c((
|
|
2837
|
-
isOn: (
|
|
2838
|
-
buildCommand: (
|
|
2839
|
-
layerId:
|
|
2836
|
+
layers: c((S) => S.supportsCategoryLabels),
|
|
2837
|
+
isOn: (S) => S.showCategoryLabels,
|
|
2838
|
+
buildCommand: (S, E) => new wl({
|
|
2839
|
+
layerId: S,
|
|
2840
2840
|
showCategoryLabels: E
|
|
2841
2841
|
})
|
|
2842
2842
|
}),
|
|
@@ -2844,9 +2844,9 @@ var A7 = 512 * 1024, v1 = (e) => new Promise((t) => {
|
|
|
2844
2844
|
label: a("editor.elementsPanel.headerSection.toggleTitle"),
|
|
2845
2845
|
children: /* @__PURE__ */ o(i, {
|
|
2846
2846
|
checked: e.config.content.showTitle,
|
|
2847
|
-
onChange: (
|
|
2847
|
+
onChange: (S) => r.dispatch(new dt({
|
|
2848
2848
|
part: "title",
|
|
2849
|
-
visible:
|
|
2849
|
+
visible: S
|
|
2850
2850
|
}))
|
|
2851
2851
|
})
|
|
2852
2852
|
}),
|
|
@@ -2854,9 +2854,9 @@ var A7 = 512 * 1024, v1 = (e) => new Promise((t) => {
|
|
|
2854
2854
|
label: a("editor.elementsPanel.headerSection.subtitle"),
|
|
2855
2855
|
children: /* @__PURE__ */ o(i, {
|
|
2856
2856
|
checked: e.config.content.showSubtitle,
|
|
2857
|
-
onChange: (
|
|
2857
|
+
onChange: (S) => r.dispatch(new dt({
|
|
2858
2858
|
part: "subtitle",
|
|
2859
|
-
visible:
|
|
2859
|
+
visible: S
|
|
2860
2860
|
}))
|
|
2861
2861
|
})
|
|
2862
2862
|
}),
|
|
@@ -2864,9 +2864,9 @@ var A7 = 512 * 1024, v1 = (e) => new Promise((t) => {
|
|
|
2864
2864
|
label: a("editor.elementsPanel.footerSection.caption"),
|
|
2865
2865
|
children: /* @__PURE__ */ o(i, {
|
|
2866
2866
|
checked: e.config.content.showCaption,
|
|
2867
|
-
onChange: (
|
|
2867
|
+
onChange: (S) => r.dispatch(new dt({
|
|
2868
2868
|
part: "caption",
|
|
2869
|
-
visible:
|
|
2869
|
+
visible: S
|
|
2870
2870
|
}))
|
|
2871
2871
|
})
|
|
2872
2872
|
}),
|
|
@@ -2874,31 +2874,31 @@ var A7 = 512 * 1024, v1 = (e) => new Promise((t) => {
|
|
|
2874
2874
|
label: a("editor.graphPanel.graphOptions.smoothLines"),
|
|
2875
2875
|
children: /* @__PURE__ */ o(l, {
|
|
2876
2876
|
value: g,
|
|
2877
|
-
options: ko.map((
|
|
2878
|
-
value:
|
|
2879
|
-
label: a(`editor.graphPanel.graphOptions.curves.${
|
|
2880
|
-
icon: /* @__PURE__ */ o(Sm, { curve:
|
|
2877
|
+
options: ko.map((S) => ({
|
|
2878
|
+
value: S,
|
|
2879
|
+
label: a(`editor.graphPanel.graphOptions.curves.${S}`),
|
|
2880
|
+
icon: /* @__PURE__ */ o(Sm, { curve: S })
|
|
2881
2881
|
})),
|
|
2882
|
-
onChange:
|
|
2882
|
+
onChange: y
|
|
2883
2883
|
})
|
|
2884
2884
|
}),
|
|
2885
2885
|
p.length > 1 && /* @__PURE__ */ o(M, {
|
|
2886
2886
|
label: a("editor.fineTunePanel.detailSection.missingValues"),
|
|
2887
2887
|
children: /* @__PURE__ */ o(l, {
|
|
2888
2888
|
value: m,
|
|
2889
|
-
options: p.map((
|
|
2890
|
-
value:
|
|
2891
|
-
label: us(a,
|
|
2892
|
-
icon: /* @__PURE__ */ o(Cm, { missingValues:
|
|
2889
|
+
options: p.map((S) => ({
|
|
2890
|
+
value: S,
|
|
2891
|
+
label: us(a, S),
|
|
2892
|
+
icon: /* @__PURE__ */ o(Cm, { missingValues: S })
|
|
2893
2893
|
})),
|
|
2894
2894
|
onChange: k
|
|
2895
2895
|
})
|
|
2896
2896
|
}),
|
|
2897
|
-
d.length > 0 && /* @__PURE__ */ f(
|
|
2898
|
-
widthPx: an(I.map((
|
|
2897
|
+
d.length > 0 && /* @__PURE__ */ f(J, { children: [/* @__PURE__ */ o(Ss, {
|
|
2898
|
+
widthPx: an(I.map((S) => S.strokeWidth)),
|
|
2899
2899
|
onChange: B
|
|
2900
2900
|
}), /* @__PURE__ */ o(ws, {
|
|
2901
|
-
lineStyle: an(I.map((
|
|
2901
|
+
lineStyle: an(I.map((S) => S.lineStyle)),
|
|
2902
2902
|
onChange: R
|
|
2903
2903
|
})] }),
|
|
2904
2904
|
x.length > 0 && /* @__PURE__ */ o(M, {
|
|
@@ -2923,7 +2923,7 @@ var A7 = 512 * 1024, v1 = (e) => new Promise((t) => {
|
|
|
2923
2923
|
/* @__PURE__ */ o(s1, {})
|
|
2924
2924
|
] });
|
|
2925
2925
|
};
|
|
2926
|
-
xs.hasRows = (e, { scene: t, dataLabelPlacement: n }) => Vn(t.spec) !== null || ks(t.layers, t.coordSystem.type, n).some(({ support: r }) => r.supportsDataLabels) || t.spec.layers.some((r) => r.interactive &&
|
|
2926
|
+
xs.hasRows = (e, { scene: t, dataLabelPlacement: n }) => Vn(t.spec) !== null || ks(t.layers, t.coordSystem.type, n).some(({ support: r }) => r.supportsDataLabels) || t.spec.layers.some((r) => r.interactive && Lt(r, "line", "area"));
|
|
2927
2927
|
var ks = (e, t, n) => e.filter((r) => r.interactive).map((r) => ({
|
|
2928
2928
|
layer: r,
|
|
2929
2929
|
support: ds(r, t, n)
|
|
@@ -2952,7 +2952,7 @@ var ks = (e, t, n) => e.filter((r) => r.interactive).map((r) => ({
|
|
|
2952
2952
|
}));
|
|
2953
2953
|
}), I1 = (e, t) => {
|
|
2954
2954
|
if (t.showFill === !0) return !0;
|
|
2955
|
-
const n =
|
|
2955
|
+
const n = At("line", t.layerId), r = Me(e.spec);
|
|
2956
2956
|
return e.spec.styles.overrides.some((a) => !Ih(a) || a.when?.where === void 0 ? !1 : ph({
|
|
2957
2957
|
...n,
|
|
2958
2958
|
when: a.when
|
|
@@ -3042,24 +3042,24 @@ var Ts = (e) => e.scaledAesthetic === "x" || e.scaledAesthetic === "y", As = (e,
|
|
|
3042
3042
|
widthPx: 4
|
|
3043
3043
|
}
|
|
3044
3044
|
], Is = ({ target: e }) => {
|
|
3045
|
-
const t = G((
|
|
3045
|
+
const t = G((y) => y), n = re(), r = As(t, n), a = N(), i = Pe(), { ToggleGroup: l } = U();
|
|
3046
3046
|
if (r === null || !r.stylable) return null;
|
|
3047
|
-
const s = e.axis === "both" ? "y" : e.axis, c = n.gridLine[s]().resolve(), d = pt(c.dashArray), u = _1(e.axis, r), h = Ln.map((
|
|
3048
|
-
value:
|
|
3049
|
-
label: a(`editor.graphPanel.gridSection.lineStyles.${
|
|
3050
|
-
icon: /* @__PURE__ */ o(bs, { lineStyle:
|
|
3051
|
-
})), p = dr.map(({ name:
|
|
3052
|
-
value:
|
|
3053
|
-
label: a(`editor.graphPanel.gridSection.lineWidths.${
|
|
3047
|
+
const s = e.axis === "both" ? "y" : e.axis, c = n.gridLine[s]().resolve(), d = pt(c.dashArray), u = _1(e.axis, r), h = Ln.map((y) => ({
|
|
3048
|
+
value: y,
|
|
3049
|
+
label: a(`editor.graphPanel.gridSection.lineStyles.${y}`),
|
|
3050
|
+
icon: /* @__PURE__ */ o(bs, { lineStyle: y })
|
|
3051
|
+
})), p = dr.map(({ name: y, widthPx: b }) => ({
|
|
3052
|
+
value: y,
|
|
3053
|
+
label: a(`editor.graphPanel.gridSection.lineWidths.${y}`),
|
|
3054
3054
|
icon: /* @__PURE__ */ o(ys, { lineWidth: b })
|
|
3055
|
-
})), g = dr.find(({ widthPx:
|
|
3056
|
-
const b = Ln.find((T) => T ===
|
|
3055
|
+
})), g = dr.find(({ widthPx: y }) => y === c.strokeWidth)?.name ?? "", m = (y) => {
|
|
3056
|
+
const b = Ln.find((T) => T === y);
|
|
3057
3057
|
b !== void 0 && i.dispatch(Ps(b, e.axis));
|
|
3058
|
-
}, v = (
|
|
3059
|
-
const b = dr.find(({ name: T }) => T ===
|
|
3058
|
+
}, v = (y) => {
|
|
3059
|
+
const b = dr.find(({ name: T }) => T === y);
|
|
3060
3060
|
b !== void 0 && i.dispatch(Ls(b.widthPx, e.axis));
|
|
3061
3061
|
};
|
|
3062
|
-
return /* @__PURE__ */ f(
|
|
3062
|
+
return /* @__PURE__ */ f(J, { children: [/* @__PURE__ */ o(M, {
|
|
3063
3063
|
label: a("editor.graphPanel.gridSection.gridStyle"),
|
|
3064
3064
|
children: /* @__PURE__ */ o(l, {
|
|
3065
3065
|
value: d,
|
|
@@ -3186,7 +3186,7 @@ var Lo = [
|
|
|
3186
3186
|
const i = ne(e.layers, n);
|
|
3187
3187
|
return i?.geom === "point" ? t.geom.point(i).get("symbol") : "circle";
|
|
3188
3188
|
}, Es = (e, t, n) => n === void 0 ? void 0 : yn(e.spec.styles.overrides, {
|
|
3189
|
-
...
|
|
3189
|
+
...At("point", t),
|
|
3190
3190
|
when: { where: n }
|
|
3191
3191
|
}, Me(e.spec)), Br = ({ target: e }) => {
|
|
3192
3192
|
const t = Wt();
|
|
@@ -3199,7 +3199,7 @@ Br.hasRows = (e, { scene: t }) => e.scope === "group" && Rs(t, e.layerId) !== nu
|
|
|
3199
3199
|
var G1 = ({ graph: e, target: t }) => {
|
|
3200
3200
|
const n = oe(e), r = re(), a = N(), { Switch: i } = U(), l = n === null ? null : Rs(n, t.layerId), s = n === null || l === null ? null : Ta(n, r, l.id);
|
|
3201
3201
|
if (n === null || l === null || s === null) return null;
|
|
3202
|
-
const c = U1(n, t), d = c === void 0 ? {} : { where: c }, u = c === void 0 || l.geom !== "line" ? void 0 : W1(n, s.layerId, c), h = u === void 0 ? s.showFill : u > 0, p = c === void 0 ? null : $1(n, l.geom, s.layerId, c), g = c === void 0 ? s.strokeWidth : p ?? V1(n, r, t) ?? s.strokeWidth, m = s.pointLayerId === null ? null : Ms(n, r, s.pointLayerId, c), v = s.pointLayerId === null ? null : Os(n, r, s.pointLayerId, c),
|
|
3202
|
+
const c = U1(n, t), d = c === void 0 ? {} : { where: c }, u = c === void 0 || l.geom !== "line" ? void 0 : W1(n, s.layerId, c), h = u === void 0 ? s.showFill : u > 0, p = c === void 0 ? null : $1(n, l.geom, s.layerId, c), g = c === void 0 ? s.strokeWidth : p ?? V1(n, r, t) ?? s.strokeWidth, m = s.pointLayerId === null ? null : Ms(n, r, s.pointLayerId, c), v = s.pointLayerId === null ? null : Os(n, r, s.pointLayerId, c), y = m !== null && m > 0, b = (P) => {
|
|
3203
3203
|
e.commands.dispatch(new da({
|
|
3204
3204
|
layerId: s.layerId,
|
|
3205
3205
|
showPoints: P,
|
|
@@ -3237,8 +3237,8 @@ var G1 = ({ graph: e, target: t }) => {
|
|
|
3237
3237
|
...d
|
|
3238
3238
|
}));
|
|
3239
3239
|
}, I = Wn(n.spec, t)?.some((P) => P.geomKind === "line" || P.geomKind === "area") === !0;
|
|
3240
|
-
return /* @__PURE__ */ f(
|
|
3241
|
-
/* @__PURE__ */ o(
|
|
3240
|
+
return /* @__PURE__ */ f(J, { children: [
|
|
3241
|
+
/* @__PURE__ */ o(Xe, { target: t }),
|
|
3242
3242
|
/* @__PURE__ */ o(Ss, {
|
|
3243
3243
|
widthPx: g,
|
|
3244
3244
|
onChange: w
|
|
@@ -3257,15 +3257,15 @@ var G1 = ({ graph: e, target: t }) => {
|
|
|
3257
3257
|
/* @__PURE__ */ o(M, {
|
|
3258
3258
|
label: a("editor.graphPanel.graphOptions.showPoints"),
|
|
3259
3259
|
children: /* @__PURE__ */ o(i, {
|
|
3260
|
-
checked:
|
|
3260
|
+
checked: y,
|
|
3261
3261
|
onChange: b
|
|
3262
3262
|
})
|
|
3263
3263
|
}),
|
|
3264
|
-
|
|
3264
|
+
y && /* @__PURE__ */ o(Pa, {
|
|
3265
3265
|
sizePx: m,
|
|
3266
3266
|
onChange: k
|
|
3267
3267
|
}),
|
|
3268
|
-
|
|
3268
|
+
y && /* @__PURE__ */ o(Aa, {
|
|
3269
3269
|
symbol: v,
|
|
3270
3270
|
coordType: n.coordSystem.type,
|
|
3271
3271
|
onChange: x
|
|
@@ -3273,10 +3273,10 @@ var G1 = ({ graph: e, target: t }) => {
|
|
|
3273
3273
|
] });
|
|
3274
3274
|
}, $1 = (e, t, n, r) => {
|
|
3275
3275
|
const a = (t === "line" ? yn(e.spec.styles.overrides, {
|
|
3276
|
-
...
|
|
3276
|
+
...At("line", n),
|
|
3277
3277
|
when: { where: r }
|
|
3278
3278
|
}, Me(e.spec)) : yn(e.spec.styles.overrides, {
|
|
3279
|
-
...
|
|
3279
|
+
...At("area", n),
|
|
3280
3280
|
when: { where: r }
|
|
3281
3281
|
}, Me(e.spec)))?.strokeWidth;
|
|
3282
3282
|
return typeof a == "number" ? a : null;
|
|
@@ -3291,7 +3291,7 @@ var G1 = ({ graph: e, target: t }) => {
|
|
|
3291
3291
|
return typeof s == "number" ? s : null;
|
|
3292
3292
|
}, W1 = (e, t, n) => {
|
|
3293
3293
|
const r = yn(e.spec.styles.overrides, {
|
|
3294
|
-
...
|
|
3294
|
+
...At("line", t),
|
|
3295
3295
|
when: { where: n }
|
|
3296
3296
|
}, Me(e.spec))?.fillAlpha;
|
|
3297
3297
|
return typeof r == "number" ? r : void 0;
|
|
@@ -3308,7 +3308,7 @@ var G1 = ({ graph: e, target: t }) => {
|
|
|
3308
3308
|
const n = ne(e.spec.layers, t);
|
|
3309
3309
|
if (n === void 0) return null;
|
|
3310
3310
|
const r = Gn(n, e.spec.layers);
|
|
3311
|
-
return
|
|
3311
|
+
return Lt(r, "line", "area") ? r : null;
|
|
3312
3312
|
}, Ns = (e) => /* @__PURE__ */ f(O, {
|
|
3313
3313
|
viewBox: "0 0 16 16",
|
|
3314
3314
|
...e,
|
|
@@ -3531,7 +3531,7 @@ var J1 = (e) => {
|
|
|
3531
3531
|
if (i === null || !av(i, n)) continue;
|
|
3532
3532
|
const l = i[t] ?? null;
|
|
3533
3533
|
if (l === null) continue;
|
|
3534
|
-
const s = i[
|
|
3534
|
+
const s = i[et.x], c = typeof s == "number" ? s : a, d = $t(l), u = r.get(d);
|
|
3535
3535
|
(u === void 0 || c < u.position) && r.set(d, {
|
|
3536
3536
|
value: l,
|
|
3537
3537
|
position: c
|
|
@@ -3547,7 +3547,7 @@ var J1 = (e) => {
|
|
|
3547
3547
|
}
|
|
3548
3548
|
return !1;
|
|
3549
3549
|
}, Hs = (e, t) => {
|
|
3550
|
-
const n = e[
|
|
3550
|
+
const n = e[et.yRaw], r = typeof n == "number" ? n : e[t];
|
|
3551
3551
|
return typeof r == "number" && Number.isFinite(r) ? r : null;
|
|
3552
3552
|
}, Gs = (e, t, n, r, a) => {
|
|
3553
3553
|
const i = ga({
|
|
@@ -3556,13 +3556,13 @@ var J1 = (e) => {
|
|
|
3556
3556
|
numberFormat: a
|
|
3557
3557
|
})(n);
|
|
3558
3558
|
return i.length > 0 ? i : String(n);
|
|
3559
|
-
}, $t = (e) => e instanceof Date ? String(e.getTime()) : String(e), In = (e, t) => "and" in e || "and" in t ? "and" in e && "and" in t && Oo(e.and, t.and) : "or" in e || "or" in t ? "or" in e && "or" in t && Oo(e.or, t.or) : "not" in e || "not" in t ? "not" in e && "not" in t && In(e.not, t.not) : e.variable !== t.variable ? !1 : "eq" in e || "eq" in t ? "eq" in e && "eq" in t &&
|
|
3559
|
+
}, $t = (e) => e instanceof Date ? String(e.getTime()) : String(e), In = (e, t) => "and" in e || "and" in t ? "and" in e && "and" in t && Oo(e.and, t.and) : "or" in e || "or" in t ? "or" in e && "or" in t && Oo(e.or, t.or) : "not" in e || "not" in t ? "not" in e && "not" in t && In(e.not, t.not) : e.variable !== t.variable ? !1 : "eq" in e || "eq" in t ? "eq" in e && "eq" in t && wt(e.eq, t.eq) : "oneOf" in e || "oneOf" in t ? "oneOf" in e && "oneOf" in t && Eo(e.oneOf, t.oneOf) : "lt" in e || "lt" in t ? "lt" in e && "lt" in t && wt(e.lt, t.lt) : "lte" in e || "lte" in t ? "lte" in e && "lte" in t && wt(e.lte, t.lte) : "gt" in e || "gt" in t ? "gt" in e && "gt" in t && wt(e.gt, t.gt) : "gte" in e || "gte" in t ? "gte" in e && "gte" in t && wt(e.gte, t.gte) : "range" in e && "range" in t && Eo(e.range, t.range), Oo = (e, t) => e.length === t.length && e.every((n, r) => {
|
|
3560
3560
|
const a = t[r];
|
|
3561
3561
|
return a !== void 0 && In(n, a);
|
|
3562
3562
|
}), Eo = (e, t) => e.length === t.length && e.every((n, r) => {
|
|
3563
3563
|
const a = t[r];
|
|
3564
|
-
return a !== void 0 &&
|
|
3565
|
-
}),
|
|
3564
|
+
return a !== void 0 && wt(n, a);
|
|
3565
|
+
}), wt = (e, t) => e instanceof Date || t instanceof Date ? e instanceof Date && t instanceof Date && e.getTime() === t.getTime() : e === t, iv = (e, t) => {
|
|
3566
3566
|
const n = G((a) => a.spec.highlights), r = G((a) => a.config.parsingLocale);
|
|
3567
3567
|
return z(() => fh({
|
|
3568
3568
|
layer: e,
|
|
@@ -3695,7 +3695,7 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3695
3695
|
return;
|
|
3696
3696
|
}
|
|
3697
3697
|
e.key === "ArrowUp" && !a && r !== null && (e.preventDefault(), n.querySelector('[aria-expanded="true"]')?.focus());
|
|
3698
|
-
},
|
|
3698
|
+
}, Je = {
|
|
3699
3699
|
side: "top",
|
|
3700
3700
|
delay: 200
|
|
3701
3701
|
}, Ks = {
|
|
@@ -3732,14 +3732,14 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3732
3732
|
}, mn = La((e, t) => Z1(t, e)), No = La(Fs), Pv = La(Bs), Lv = ({ anchor: e, readHighlightOptions: t }) => {
|
|
3733
3733
|
const { layer: n, observation: r, at: a } = e, i = N(), { dispatch: l, paintPreview: s, clearPreview: c } = Pe(), { selectionStore: d, findGeom: u } = j(), h = te(null), p = te(c);
|
|
3734
3734
|
p.current = c;
|
|
3735
|
-
const { Button: g } = U(), m = G((V) => V), v = m.spec.annotations,
|
|
3735
|
+
const { Button: g } = U(), m = G((V) => V), v = m.spec.annotations, y = m.config.parsingLocale, b = m.config.numberFormat, T = Dn(), w = {
|
|
3736
3736
|
scene: m,
|
|
3737
3737
|
layer: n,
|
|
3738
3738
|
observation: r,
|
|
3739
3739
|
groupOptions: Zn(m, T),
|
|
3740
3740
|
locale: T,
|
|
3741
3741
|
t: i
|
|
3742
|
-
}, k = zr(w, "xValue").value, x = zr(w, "group").value, L = $s(w).observation, I = z(() => uh(n,
|
|
3742
|
+
}, k = zr(w, "xValue").value, x = zr(w, "group").value, L = $s(w).observation, I = z(() => uh(n, y), [n, y]), P = bh(v, a, I, z(() => dh({
|
|
3743
3743
|
layers: m.layers,
|
|
3744
3744
|
coordSystem: m.coordSystem,
|
|
3745
3745
|
findGeom: u,
|
|
@@ -3749,7 +3749,7 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3749
3749
|
m.coordSystem,
|
|
3750
3750
|
u,
|
|
3751
3751
|
I
|
|
3752
|
-
])), H = P !== null && sv(P) ? P : null, B = h.current, R = H !== null && B?.key.startsWith("sticker:") === !0 && H.kind === "sticker" ? null : H, A = R?.kind === "comment" ? R.annotation.content : null, C = A === null ? "" : $v(A) ?? void 0, [
|
|
3752
|
+
])), H = P !== null && sv(P) ? P : null, B = h.current, R = H !== null && B?.key.startsWith("sticker:") === !0 && H.kind === "sticker" ? null : H, A = R?.kind === "comment" ? R.annotation.content : null, C = A === null ? "" : $v(A) ?? void 0, [S, E] = Z(() => Hv(H?.kind)), $ = iv(n, r), _ = m.coordSystem, se = t(n, _), ce = se.length === 0 ? [] : Q1(n, r, T, b), F = h.current?.heldHighlight, X = F === void 0 ? $ : [...$, F], q = z(() => Lh({
|
|
3753
3753
|
layer: n,
|
|
3754
3754
|
at: a,
|
|
3755
3755
|
coordSystem: _
|
|
@@ -3773,9 +3773,9 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3773
3773
|
}),
|
|
3774
3774
|
onwardLabel: (V) => i("graph.annotations.highlights.onward", { label: V }),
|
|
3775
3775
|
onwardDescription: (V) => i("graph.annotations.highlights.onwardDescription", { label: V })
|
|
3776
|
-
}), Ve = kl(n, r),
|
|
3776
|
+
}), Ve = kl(n, r), Ot = new Set(ie?.available.map((V) => V.id) ?? []), Y = $.filter((V) => {
|
|
3777
3777
|
const de = zs(V, ce, Ve);
|
|
3778
|
-
return de === null || !
|
|
3778
|
+
return de === null || !Ot.has(de);
|
|
3779
3779
|
}).at(-1), ae = () => {
|
|
3780
3780
|
h.current !== null && (h.current = null, p.current());
|
|
3781
3781
|
};
|
|
@@ -3788,7 +3788,7 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3788
3788
|
}, s(de) || (h.current = null));
|
|
3789
3789
|
}, ke = (V) => {
|
|
3790
3790
|
ae(), l(V), d.getState().clearSelection();
|
|
3791
|
-
},
|
|
3791
|
+
}, Et = (V, de) => {
|
|
3792
3792
|
if (h.current?.key === V) {
|
|
3793
3793
|
h.current = null, p.current(), l(de), d.getState().clearSelection();
|
|
3794
3794
|
return;
|
|
@@ -3797,7 +3797,7 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3797
3797
|
}, or = (V, de, _e, D) => ({
|
|
3798
3798
|
onPointerEnter: () => Oe(V, de, _e, D),
|
|
3799
3799
|
onPointerLeave: ae,
|
|
3800
|
-
onClick: () =>
|
|
3800
|
+
onClick: () => Et(V, de)
|
|
3801
3801
|
}), ft = (V) => {
|
|
3802
3802
|
ae(), E((de) => de === V ? null : V);
|
|
3803
3803
|
}, en = (V) => {
|
|
@@ -3823,7 +3823,7 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3823
3823
|
"aria-label": i("graph.annotations.baseMenu.annotate"),
|
|
3824
3824
|
onKeyDown: (V) => {
|
|
3825
3825
|
if (R !== null && Gv(V)) {
|
|
3826
|
-
ke(new
|
|
3826
|
+
ke(new tt({ id: R.annotation.id }));
|
|
3827
3827
|
return;
|
|
3828
3828
|
}
|
|
3829
3829
|
Us(V);
|
|
@@ -3834,29 +3834,29 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3834
3834
|
children: [
|
|
3835
3835
|
ie !== null && /* @__PURE__ */ o(g, {
|
|
3836
3836
|
variant: "icon",
|
|
3837
|
-
...
|
|
3837
|
+
...Je,
|
|
3838
3838
|
ariaLabel: i("graph.annotations.baseMenu.highlight"),
|
|
3839
3839
|
icon: /* @__PURE__ */ o(Mo, {}),
|
|
3840
|
-
expanded:
|
|
3840
|
+
expanded: S === "highlight",
|
|
3841
3841
|
onClick: () => ft("highlight")
|
|
3842
3842
|
}),
|
|
3843
3843
|
Y !== void 0 && /* @__PURE__ */ o(g, {
|
|
3844
3844
|
variant: "icon",
|
|
3845
|
-
...
|
|
3845
|
+
...Je,
|
|
3846
3846
|
ariaLabel: i("graph.annotations.baseMenu.removeHighlight"),
|
|
3847
3847
|
icon: /* @__PURE__ */ o(Io, { children: /* @__PURE__ */ o(Mo, {}) }),
|
|
3848
3848
|
onClick: () => ke(new eo({ id: Y.id }))
|
|
3849
3849
|
}),
|
|
3850
3850
|
R !== null && /* @__PURE__ */ o(g, {
|
|
3851
3851
|
variant: "icon",
|
|
3852
|
-
...
|
|
3852
|
+
...Je,
|
|
3853
3853
|
ariaLabel: i(Ks[R.kind].phrase),
|
|
3854
3854
|
icon: /* @__PURE__ */ o(Io, { children: Iv(R.kind) }),
|
|
3855
|
-
onClick: () => ke(new
|
|
3855
|
+
onClick: () => ke(new tt({ id: R.annotation.id }))
|
|
3856
3856
|
}),
|
|
3857
|
-
R === null && /* @__PURE__ */ f(
|
|
3857
|
+
R === null && /* @__PURE__ */ f(J, { children: [/* @__PURE__ */ o(g, {
|
|
3858
3858
|
variant: "icon",
|
|
3859
|
-
...
|
|
3859
|
+
...Je,
|
|
3860
3860
|
ariaLabel: i("graph.annotations.baseMenu.pinNumber"),
|
|
3861
3861
|
icon: /* @__PURE__ */ o(Ds, {}),
|
|
3862
3862
|
onClick: () => ke(new Te({
|
|
@@ -3865,31 +3865,31 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3865
3865
|
}))
|
|
3866
3866
|
}), /* @__PURE__ */ o(g, {
|
|
3867
3867
|
variant: "icon",
|
|
3868
|
-
...
|
|
3868
|
+
...Je,
|
|
3869
3869
|
ariaLabel: i("graph.annotations.baseMenu.addNote"),
|
|
3870
3870
|
icon: /* @__PURE__ */ o(Ns, {}),
|
|
3871
|
-
expanded:
|
|
3871
|
+
expanded: S === "comment",
|
|
3872
3872
|
onClick: () => ft("comment")
|
|
3873
3873
|
})] }),
|
|
3874
3874
|
q !== null && /* @__PURE__ */ o(g, {
|
|
3875
3875
|
variant: "icon",
|
|
3876
|
-
...
|
|
3876
|
+
...Je,
|
|
3877
3877
|
ariaLabel: i("graph.annotations.baseMenu.differenceArrow"),
|
|
3878
3878
|
icon: /* @__PURE__ */ o(hr, {}),
|
|
3879
|
-
expanded:
|
|
3879
|
+
expanded: S === "difference",
|
|
3880
3880
|
onClick: () => ft("difference")
|
|
3881
3881
|
}),
|
|
3882
3882
|
R === null && /* @__PURE__ */ o(g, {
|
|
3883
3883
|
variant: "icon",
|
|
3884
|
-
...
|
|
3884
|
+
...Je,
|
|
3885
3885
|
ariaLabel: i("graph.annotations.baseMenu.addSticker"),
|
|
3886
3886
|
icon: /* @__PURE__ */ o(_s, {}),
|
|
3887
|
-
expanded:
|
|
3887
|
+
expanded: S === "sticker",
|
|
3888
3888
|
onClick: () => ft("sticker")
|
|
3889
3889
|
})
|
|
3890
3890
|
]
|
|
3891
3891
|
}),
|
|
3892
|
-
|
|
3892
|
+
S === "comment" && C !== void 0 && /* @__PURE__ */ o("div", {
|
|
3893
3893
|
className: "vez73g6",
|
|
3894
3894
|
children: /* @__PURE__ */ o(Mv, {
|
|
3895
3895
|
at: a,
|
|
@@ -3898,22 +3898,22 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3898
3898
|
initialText: C
|
|
3899
3899
|
})
|
|
3900
3900
|
}),
|
|
3901
|
-
|
|
3901
|
+
S === "sticker" && /* @__PURE__ */ o("div", {
|
|
3902
3902
|
className: "vez73g2",
|
|
3903
3903
|
children: /* @__PURE__ */ o(Ov, {
|
|
3904
3904
|
at: a,
|
|
3905
3905
|
showPreview: Oe,
|
|
3906
3906
|
dropPreview: ae,
|
|
3907
|
-
keepPreview:
|
|
3907
|
+
keepPreview: Et,
|
|
3908
3908
|
annotationId: R?.kind === "sticker" ? R.annotation.id : void 0
|
|
3909
3909
|
})
|
|
3910
3910
|
}),
|
|
3911
|
-
|
|
3911
|
+
S === "difference" && /* @__PURE__ */ f("div", {
|
|
3912
3912
|
className: "vez73g4",
|
|
3913
3913
|
children: [/* @__PURE__ */ o(g, {
|
|
3914
3914
|
variant: "icon",
|
|
3915
3915
|
ariaLabel: i("graph.annotations.differenceArrowToolbar.labelKind.asPercent"),
|
|
3916
|
-
icon: /* @__PURE__ */ f(
|
|
3916
|
+
icon: /* @__PURE__ */ f(J, { children: [/* @__PURE__ */ o(hr, { size: "sm" }), /* @__PURE__ */ o("span", {
|
|
3917
3917
|
className: "vez73g5",
|
|
3918
3918
|
"aria-hidden": "true",
|
|
3919
3919
|
children: "%"
|
|
@@ -3922,7 +3922,7 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3922
3922
|
}), /* @__PURE__ */ o(g, {
|
|
3923
3923
|
variant: "icon",
|
|
3924
3924
|
ariaLabel: i("graph.annotations.differenceArrowToolbar.labelKind.asNumber"),
|
|
3925
|
-
icon: /* @__PURE__ */ f(
|
|
3925
|
+
icon: /* @__PURE__ */ f(J, { children: [/* @__PURE__ */ o(hr, { size: "sm" }), /* @__PURE__ */ o("span", {
|
|
3926
3926
|
className: "vez73g5",
|
|
3927
3927
|
"aria-hidden": "true",
|
|
3928
3928
|
children: "+n"
|
|
@@ -3930,7 +3930,7 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3930
3930
|
onClick: () => en("absoluteDifference")
|
|
3931
3931
|
})]
|
|
3932
3932
|
}),
|
|
3933
|
-
|
|
3933
|
+
S === "highlight" && ie !== null && /* @__PURE__ */ o("div", {
|
|
3934
3934
|
className: "vez73g3",
|
|
3935
3935
|
children: ie.available.map((V) => {
|
|
3936
3936
|
const de = V.appliedHighlightId, _e = de === void 0 ? Nv(V, n.id) : new eo({ id: de }), D = de === void 0 ? void 0 : X.find((ve) => ve.id === de);
|
|
@@ -3938,7 +3938,7 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3938
3938
|
label: V.label,
|
|
3939
3939
|
pressed: de !== void 0,
|
|
3940
3940
|
tooltip: V.description === V.label ? void 0 : V.description,
|
|
3941
|
-
...
|
|
3941
|
+
...Je,
|
|
3942
3942
|
...or(Ev(V.id), _e, de === void 0 ? V.id : void 0, D)
|
|
3943
3943
|
}, V.id);
|
|
3944
3944
|
})
|
|
@@ -3949,7 +3949,7 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3949
3949
|
const t = Ks[e].Icon;
|
|
3950
3950
|
return /* @__PURE__ */ o(t, {});
|
|
3951
3951
|
}, Mv = ({ at: e, onRun: t, annotationId: n, initialText: r = "" }) => {
|
|
3952
|
-
const a = N(), { Button: i, TextField: l } = U(), [s, c] =
|
|
3952
|
+
const a = N(), { Button: i, TextField: l } = U(), [s, c] = Z(r), d = te(null), u = s.trim();
|
|
3953
3953
|
W(() => {
|
|
3954
3954
|
const p = d.current?.querySelector("input");
|
|
3955
3955
|
p instanceof HTMLInputElement && p.focus({ preventScroll: !0 });
|
|
@@ -3988,7 +3988,7 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
3988
3988
|
disabled: u.length === 0
|
|
3989
3989
|
})]
|
|
3990
3990
|
});
|
|
3991
|
-
}, Ov = ({ at: e, showPreview: t, dropPreview: n, keepPreview: r, annotationId: a }) => /* @__PURE__ */ o(
|
|
3991
|
+
}, Ov = ({ at: e, showPreview: t, dropPreview: n, keepPreview: r, annotationId: a }) => /* @__PURE__ */ o(J, { children: Object.entries(Hi).map(([i, l]) => {
|
|
3992
3992
|
const s = Dv(e, i, a);
|
|
3993
3993
|
return /* @__PURE__ */ o("button", {
|
|
3994
3994
|
type: "button",
|
|
@@ -4047,8 +4047,8 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
4047
4047
|
}), v = a.map((w) => ({
|
|
4048
4048
|
...Fv(w, c, d, u, h),
|
|
4049
4049
|
appliedHighlightId: g.get(w.id)
|
|
4050
|
-
})), [
|
|
4051
|
-
|
|
4050
|
+
})), [y, ...b] = m, T = y === void 0 ? v : [
|
|
4051
|
+
y,
|
|
4052
4052
|
...v,
|
|
4053
4053
|
...b
|
|
4054
4054
|
];
|
|
@@ -4140,13 +4140,13 @@ var yv = "vez73g6", Sv = "vez73g7", wv = "vez73g8", Cv = "vez73g9", xv = "vez73g
|
|
|
4140
4140
|
target: e
|
|
4141
4141
|
});
|
|
4142
4142
|
};
|
|
4143
|
-
js.hasRows = (e, t) =>
|
|
4143
|
+
js.hasRows = (e, t) => Lt(ne(t.scene.spec.layers, e.layerId), "point") ? !0 : Xe.hasRows(e, t);
|
|
4144
4144
|
var Wv = ({ graph: e, target: t }) => {
|
|
4145
4145
|
const n = oe(e), r = re(), a = n === null ? void 0 : ne(n.spec.layers, t.layerId);
|
|
4146
|
-
if (n === null || !
|
|
4146
|
+
if (n === null || !Lt(a, "point")) return /* @__PURE__ */ o(Xe, { target: t });
|
|
4147
4147
|
const i = Wn(n.spec, t)?.find((c) => c.geomKind === "point")?.where, l = i === void 0 ? {} : { where: i }, s = ze(ne(n.layers, a.id)?.mapping.size) !== null;
|
|
4148
|
-
return /* @__PURE__ */ f(
|
|
4149
|
-
/* @__PURE__ */ o(
|
|
4148
|
+
return /* @__PURE__ */ f(J, { children: [
|
|
4149
|
+
/* @__PURE__ */ o(Xe, { target: t }),
|
|
4150
4150
|
!s && /* @__PURE__ */ o(Pa, {
|
|
4151
4151
|
sizePx: Ms(n, r, a.id, i),
|
|
4152
4152
|
onChange: (c) => {
|
|
@@ -4192,7 +4192,7 @@ var Wv = ({ graph: e, target: t }) => {
|
|
|
4192
4192
|
annotate: mn
|
|
4193
4193
|
},
|
|
4194
4194
|
tile: {
|
|
4195
|
-
style:
|
|
4195
|
+
style: Xe,
|
|
4196
4196
|
annotate: mn
|
|
4197
4197
|
}
|
|
4198
4198
|
},
|
|
@@ -4237,7 +4237,7 @@ var Wv = ({ graph: e, target: t }) => {
|
|
|
4237
4237
|
if (r === "annotate" && e.kind !== "observations") return null;
|
|
4238
4238
|
switch (e.kind) {
|
|
4239
4239
|
case "observations": {
|
|
4240
|
-
const a = R1(e.layerId, n.scene), i = a === null ? null : N1(a, t, r, r === "annotate" ? mn :
|
|
4240
|
+
const a = R1(e.layerId, n.scene), i = a === null ? null : N1(a, t, r, r === "annotate" ? mn : Xe);
|
|
4241
4241
|
return i === null || i.hasRows?.(e, n) === !1 ? null : /* @__PURE__ */ o(i, { target: e });
|
|
4242
4242
|
}
|
|
4243
4243
|
case "legend": {
|
|
@@ -6985,17 +6985,17 @@ var Wv = ({ graph: e, target: t }) => {
|
|
|
6985
6985
|
], Oa = nc.map((e) => e.color);
|
|
6986
6986
|
var bf = "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))", yf = "d0bl00";
|
|
6987
6987
|
var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowerCase() === e.toLowerCase()), kf = ({ color: e, onChange: t, open: n, onOpenChange: r, children: a, label: i, popupAttributes: l, opacity: s, onOpacityChange: c, hasTransparentOption: d = !1, hasAutomaticOption: u = !1 }) => {
|
|
6988
|
-
const h = N(), { ColorSwatches: p, Slider: g } = U(), m = ec(), v = tc(),
|
|
6989
|
-
...u ? [
|
|
6988
|
+
const h = N(), { ColorSwatches: p, Slider: g } = U(), m = ec(), v = tc(), y = [
|
|
6989
|
+
...u ? [Tt] : [],
|
|
6990
6990
|
...d ? [xn] : [],
|
|
6991
6991
|
...Oa
|
|
6992
6992
|
], b = {
|
|
6993
6993
|
...m,
|
|
6994
6994
|
[xn]: h("graph.colorDropdown.transparent"),
|
|
6995
|
-
[
|
|
6995
|
+
[Tt]: h("graph.colorDropdown.automatic")
|
|
6996
6996
|
}, T = (I) => {
|
|
6997
6997
|
t(I), r(!1);
|
|
6998
|
-
}, w = v.length > 0, k = w ? v :
|
|
6998
|
+
}, w = v.length > 0, k = w ? v : y, x = e !== null && !Bo(y, e) && !Bo(v, e) ? [...k, e] : k, L = /* @__PURE__ */ o(Tf, {
|
|
6999
6999
|
value: e,
|
|
7000
7000
|
onChange: t,
|
|
7001
7001
|
popupAttributes: l
|
|
@@ -7004,7 +7004,7 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7004
7004
|
open: n,
|
|
7005
7005
|
onOpenChange: r,
|
|
7006
7006
|
children: [/* @__PURE__ */ o(ge.Trigger, {
|
|
7007
|
-
render: /* @__PURE__ */ o(
|
|
7007
|
+
render: /* @__PURE__ */ o(Ze.Button, {}),
|
|
7008
7008
|
"aria-label": i ?? h("graph.toolbar.color.label"),
|
|
7009
7009
|
className: yf,
|
|
7010
7010
|
onMouseDown: (I) => I.preventDefault(),
|
|
@@ -7026,7 +7026,7 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7026
7026
|
children: [
|
|
7027
7027
|
/* @__PURE__ */ o(p, {
|
|
7028
7028
|
title: h("graph.colorDropdown.colors"),
|
|
7029
|
-
colors: w ?
|
|
7029
|
+
colors: w ? y : x,
|
|
7030
7030
|
names: b,
|
|
7031
7031
|
value: e,
|
|
7032
7032
|
onChange: T,
|
|
@@ -7064,7 +7064,7 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7064
7064
|
const { CustomColor: r } = U(), { themeValues: a } = Rn();
|
|
7065
7065
|
return /* @__PURE__ */ o(r, {
|
|
7066
7066
|
variant: "chip",
|
|
7067
|
-
value: e === null || e ===
|
|
7067
|
+
value: e === null || e === Tt ? null : iu(e, a),
|
|
7068
7068
|
onChange: t,
|
|
7069
7069
|
popupAttributes: n
|
|
7070
7070
|
});
|
|
@@ -7089,13 +7089,13 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7089
7089
|
disabled: n,
|
|
7090
7090
|
onClick: r,
|
|
7091
7091
|
children: e
|
|
7092
|
-
}), Nf = ({ className: e, ...t }) => /* @__PURE__ */ o(Ee.Provider, { children: /* @__PURE__ */ o(
|
|
7092
|
+
}), Nf = ({ className: e, ...t }) => /* @__PURE__ */ o(Ee.Provider, { children: /* @__PURE__ */ o(Ze.Root, {
|
|
7093
7093
|
...t,
|
|
7094
7094
|
className: ot(Af, e)
|
|
7095
|
-
}) }), Df = ({ className: e, ...t }) => /* @__PURE__ */ o(
|
|
7095
|
+
}) }), Df = ({ className: e, ...t }) => /* @__PURE__ */ o(Ze.Group, {
|
|
7096
7096
|
...t,
|
|
7097
7097
|
className: ot(Pf, e)
|
|
7098
|
-
}), _f = ({ className: e, ...t }) => /* @__PURE__ */ o(
|
|
7098
|
+
}), _f = ({ className: e, ...t }) => /* @__PURE__ */ o(Ze.Separator, {
|
|
7099
7099
|
...t,
|
|
7100
7100
|
className: ot(Lf, e)
|
|
7101
7101
|
}), Ff = ({ children: e }) => {
|
|
@@ -7106,7 +7106,7 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7106
7106
|
Root: Nf,
|
|
7107
7107
|
Group: Df,
|
|
7108
7108
|
Separator: _f,
|
|
7109
|
-
Button:
|
|
7109
|
+
Button: Ze.Button,
|
|
7110
7110
|
ColorPicker: kf,
|
|
7111
7111
|
MenuPopup: Ef,
|
|
7112
7112
|
MenuItem: Rf
|
|
@@ -7149,7 +7149,7 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7149
7149
|
open: n,
|
|
7150
7150
|
onOpenChange: r,
|
|
7151
7151
|
children: [/* @__PURE__ */ f(Se.Trigger, {
|
|
7152
|
-
render: /* @__PURE__ */ o(
|
|
7152
|
+
render: /* @__PURE__ */ o(Ze.Button, {}),
|
|
7153
7153
|
"aria-label": a("graph.toolbar.font.ariaLabel"),
|
|
7154
7154
|
className: rc,
|
|
7155
7155
|
onMouseDown: (s) => s.preventDefault(),
|
|
@@ -7214,7 +7214,7 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7214
7214
|
open: n,
|
|
7215
7215
|
onOpenChange: r,
|
|
7216
7216
|
children: [/* @__PURE__ */ f(Se.Trigger, {
|
|
7217
|
-
render: /* @__PURE__ */ o(
|
|
7217
|
+
render: /* @__PURE__ */ o(Ze.Button, {}),
|
|
7218
7218
|
"aria-label": a("graph.toolbar.heading.ariaLabel"),
|
|
7219
7219
|
className: rc,
|
|
7220
7220
|
onMouseDown: (l) => l.preventDefault(),
|
|
@@ -7298,7 +7298,7 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7298
7298
|
to: a + l
|
|
7299
7299
|
};
|
|
7300
7300
|
}, Ho = (e) => e !== void 0 && /\S/.test(e), Zf = "fop13s0", Jf = "fop13s1", Qf = "fop13s2", e2 = "fop13s3", Go = "fop13s4", t2 = ({ editor: e, currentUrl: t, active: n, open: r, onOpenChange: a }) => {
|
|
7301
|
-
const i = N(), [l, s] =
|
|
7301
|
+
const i = N(), [l, s] = Z(""), c = te(null);
|
|
7302
7302
|
W(() => {
|
|
7303
7303
|
r && s(t ?? "");
|
|
7304
7304
|
}, [r, t]);
|
|
@@ -7315,7 +7315,7 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7315
7315
|
open: r,
|
|
7316
7316
|
onOpenChange: a,
|
|
7317
7317
|
children: [/* @__PURE__ */ o(ge.Trigger, {
|
|
7318
|
-
render: /* @__PURE__ */ o(
|
|
7318
|
+
render: /* @__PURE__ */ o(Ze.Button, {}),
|
|
7319
7319
|
"aria-label": i("graph.toolbar.formatting.link"),
|
|
7320
7320
|
"data-active": n,
|
|
7321
7321
|
className: Zf,
|
|
@@ -7418,11 +7418,11 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7418
7418
|
/* @__PURE__ */ o("path", { d: "M17 19H3" })
|
|
7419
7419
|
]
|
|
7420
7420
|
})
|
|
7421
|
-
}), r2 = "_1d66w570", a2 = "_1d66w571",
|
|
7421
|
+
}), r2 = "_1d66w570", a2 = "_1d66w571", kt = ({ label: e, active: t, onToggle: n, children: r }) => {
|
|
7422
7422
|
const a = (i) => i.preventDefault();
|
|
7423
7423
|
return /* @__PURE__ */ f(Ee.Root, { children: [/* @__PURE__ */ o(Ee.Trigger, {
|
|
7424
7424
|
render: /* @__PURE__ */ o(Pp, {
|
|
7425
|
-
render: /* @__PURE__ */ o(
|
|
7425
|
+
render: /* @__PURE__ */ o(Ze.Button, {}),
|
|
7426
7426
|
pressed: t,
|
|
7427
7427
|
onPressedChange: () => n()
|
|
7428
7428
|
}),
|
|
@@ -7444,20 +7444,20 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7444
7444
|
})] });
|
|
7445
7445
|
}, o2 = ({ editor: e, activeAlignment: t = "left" }) => {
|
|
7446
7446
|
const n = N();
|
|
7447
|
-
return /* @__PURE__ */ f(
|
|
7448
|
-
/* @__PURE__ */ o(
|
|
7447
|
+
return /* @__PURE__ */ f(J, { children: [
|
|
7448
|
+
/* @__PURE__ */ o(kt, {
|
|
7449
7449
|
label: n("graph.toolbar.textAlign.left"),
|
|
7450
7450
|
active: t === "left",
|
|
7451
7451
|
onToggle: () => e.chain().focus().setTextAlign("left").run(),
|
|
7452
7452
|
children: /* @__PURE__ */ o(uc, {})
|
|
7453
7453
|
}),
|
|
7454
|
-
/* @__PURE__ */ o(
|
|
7454
|
+
/* @__PURE__ */ o(kt, {
|
|
7455
7455
|
label: n("graph.toolbar.textAlign.center"),
|
|
7456
7456
|
active: t === "center",
|
|
7457
7457
|
onToggle: () => e.chain().focus().setTextAlign("center").run(),
|
|
7458
7458
|
children: /* @__PURE__ */ o(cc, {})
|
|
7459
7459
|
}),
|
|
7460
|
-
/* @__PURE__ */ o(
|
|
7460
|
+
/* @__PURE__ */ o(kt, {
|
|
7461
7461
|
label: n("graph.toolbar.textAlign.right"),
|
|
7462
7462
|
active: t === "right",
|
|
7463
7463
|
onToggle: () => e.chain().focus().setTextAlign("right").run(),
|
|
@@ -7475,7 +7475,7 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7475
7475
|
fontSize: s2(e),
|
|
7476
7476
|
textAlign: c2(e)
|
|
7477
7477
|
}), s2 = (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", c2 = (e) => e ? e.isActive({ textAlign: "center" }) ? "center" : e.isActive({ textAlign: "right" }) ? "right" : "left" : "left", d2 = 8, u2 = 8, h2 = ({ editor: e }) => {
|
|
7478
|
-
const t = N(), [n, r] =
|
|
7478
|
+
const t = N(), [n, r] = Z(!1), [a, i] = Z(null), l = a !== null, s = (g) => (m) => {
|
|
7479
7479
|
i(m ? g : null);
|
|
7480
7480
|
}, { refs: c, floatingStyles: d } = up({
|
|
7481
7481
|
placement: "top-start",
|
|
@@ -7497,7 +7497,7 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7497
7497
|
}, [e, c]), W(() => {
|
|
7498
7498
|
if (!e) return;
|
|
7499
7499
|
const g = () => r(!0), m = ({ event: v }) => {
|
|
7500
|
-
const { relatedTarget:
|
|
7500
|
+
const { relatedTarget: y, currentTarget: b } = v, T = y instanceof Node && u.current?.contains(y), w = y instanceof Node && b instanceof Node && b.contains(y);
|
|
7501
7501
|
!T && !w && r(!1);
|
|
7502
7502
|
};
|
|
7503
7503
|
return e.on("focus", g), e.on("blur", m), () => {
|
|
@@ -7528,19 +7528,19 @@ var Sf = "d0bl03", wf = "d0bl04", Cf = 0.01, xf = (e) => Oa.some((t) => t.toLowe
|
|
|
7528
7528
|
}) }),
|
|
7529
7529
|
/* @__PURE__ */ o(pe.Separator, {}),
|
|
7530
7530
|
/* @__PURE__ */ f(pe.Group, { children: [
|
|
7531
|
-
/* @__PURE__ */ o(
|
|
7531
|
+
/* @__PURE__ */ o(kt, {
|
|
7532
7532
|
label: t("graph.toolbar.formatting.bold"),
|
|
7533
7533
|
active: h?.bold ?? !1,
|
|
7534
7534
|
onToggle: () => e.chain().focus().toggleBold().run(),
|
|
7535
7535
|
children: /* @__PURE__ */ o("strong", { children: "B" })
|
|
7536
7536
|
}),
|
|
7537
|
-
/* @__PURE__ */ o(
|
|
7537
|
+
/* @__PURE__ */ o(kt, {
|
|
7538
7538
|
label: t("graph.toolbar.formatting.italic"),
|
|
7539
7539
|
active: h?.italic ?? !1,
|
|
7540
7540
|
onToggle: () => e.chain().focus().toggleItalic().run(),
|
|
7541
7541
|
children: /* @__PURE__ */ o("em", { children: "I" })
|
|
7542
7542
|
}),
|
|
7543
|
-
/* @__PURE__ */ o(
|
|
7543
|
+
/* @__PURE__ */ o(kt, {
|
|
7544
7544
|
label: t("graph.toolbar.formatting.underline"),
|
|
7545
7545
|
active: h?.underlined ?? !1,
|
|
7546
7546
|
onToggle: () => e.chain().focus().toggleUnderline().run(),
|
|
@@ -7810,7 +7810,7 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
7810
7810
|
const l = a ? t.x + t.width - i.to : i.from - t.x;
|
|
7811
7811
|
return Wo(l, r.width, t.width);
|
|
7812
7812
|
}, F2 = () => {
|
|
7813
|
-
const [e, t] =
|
|
7813
|
+
const [e, t] = Z(!1);
|
|
7814
7814
|
return W(() => {
|
|
7815
7815
|
t(!0);
|
|
7816
7816
|
}, []), e;
|
|
@@ -7822,25 +7822,25 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
7822
7822
|
align: "shift",
|
|
7823
7823
|
fallbackAxisSide: "end"
|
|
7824
7824
|
}, Cc = ({ frameElement: e, boundary: t, spans: n, clearance: r = z2, onEscape: a, children: i }) => {
|
|
7825
|
-
const l = Xn(), s = F2(), [c, d] =
|
|
7825
|
+
const l = Xn(), s = F2(), [c, d] = Z(null), u = te(null), h = fe((k) => {
|
|
7826
7826
|
u.current = k, d(k);
|
|
7827
7827
|
}, []), p = te(null);
|
|
7828
|
-
|
|
7828
|
+
Ke(() => () => {
|
|
7829
7829
|
c?.contains(document.activeElement) && e.focus({ preventScroll: !0 });
|
|
7830
7830
|
}, [c, e]);
|
|
7831
|
-
const { x: g, y: m, width: v, height:
|
|
7831
|
+
const { x: g, y: m, width: v, height: y } = t, b = z(() => ({
|
|
7832
7832
|
box: {
|
|
7833
7833
|
x: g,
|
|
7834
7834
|
y: m,
|
|
7835
7835
|
width: v,
|
|
7836
|
-
height:
|
|
7836
|
+
height: y
|
|
7837
7837
|
},
|
|
7838
7838
|
spans: n
|
|
7839
7839
|
}), [
|
|
7840
7840
|
g,
|
|
7841
7841
|
m,
|
|
7842
7842
|
v,
|
|
7843
|
-
|
|
7843
|
+
y,
|
|
7844
7844
|
n
|
|
7845
7845
|
]), T = z(() => D2(e, b.box), [e, b]), w = (k, x) => {
|
|
7846
7846
|
k || (x.cancel(), x.reason === "escape-key" && a());
|
|
@@ -7943,7 +7943,7 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
7943
7943
|
default:
|
|
7944
7944
|
return e;
|
|
7945
7945
|
}
|
|
7946
|
-
},
|
|
7946
|
+
}, Mt = () => {
|
|
7947
7947
|
const e = Xv(), { store: t } = j();
|
|
7948
7948
|
return fe((n) => e(n) || kc(n, t.getState().scene) !== null, [e, t]);
|
|
7949
7949
|
}, _a = (e) => ({
|
|
@@ -7960,7 +7960,7 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
7960
7960
|
if (s === void 0 || Bt(s.content)) return;
|
|
7961
7961
|
}
|
|
7962
7962
|
const l = a.placementCommandId;
|
|
7963
|
-
l !== null && r !== null && r.readTopCommandId() === l && r.undo() || n(new
|
|
7963
|
+
l !== null && r !== null && r.readTopCommandId() === l && r.undo() || n(new tt({ id: a.annotationId }));
|
|
7964
7964
|
}, jt = (e, t) => e.geom === "boxplot" && xh(t, "outlier") !== null, W2 = (e, t, n) => {
|
|
7965
7965
|
const r = [];
|
|
7966
7966
|
for (let a = e.layers.length - 1; a >= 0; a -= 1) {
|
|
@@ -7970,14 +7970,14 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
7970
7970
|
return r;
|
|
7971
7971
|
}, Uo = (e, t) => {
|
|
7972
7972
|
if (t === null) return -1;
|
|
7973
|
-
const n =
|
|
7973
|
+
const n = It(t);
|
|
7974
7974
|
return e.findIndex((r) => r.target.layerId === t.layerId && r.target.observationIndex === n);
|
|
7975
7975
|
}, U2 = (e, t, n, r) => {
|
|
7976
7976
|
const a = [];
|
|
7977
7977
|
for (let i = 0; i < e.data.size(); i += 1) {
|
|
7978
7978
|
const l = e.data.getAt(i);
|
|
7979
7979
|
if (l === null || jt(e, l)) continue;
|
|
7980
|
-
const s =
|
|
7980
|
+
const s = Ye({
|
|
7981
7981
|
layer: e,
|
|
7982
7982
|
observationIndex: i,
|
|
7983
7983
|
scope: "observation",
|
|
@@ -8007,7 +8007,7 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
8007
8007
|
return a.sort((i, l) => i.x - l.x), a;
|
|
8008
8008
|
}, K2 = (e, t, n) => {
|
|
8009
8009
|
if (t.type !== "polar") return n;
|
|
8010
|
-
const r = e[
|
|
8010
|
+
const r = e[et.x], a = e[et.y];
|
|
8011
8011
|
return typeof r != "number" || typeof a != "number" || !Number.isFinite(r) || !Number.isFinite(a) ? n : {
|
|
8012
8012
|
x: r,
|
|
8013
8013
|
y: a
|
|
@@ -8020,9 +8020,9 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
8020
8020
|
const [t] = e;
|
|
8021
8021
|
return t?.kind === "annotation" ? t.id : null;
|
|
8022
8022
|
}, X2 = (e) => {
|
|
8023
|
-
const { selectionStore: t, commands: n, chartId: r, history: a, store: i, anchorResolver: l } = j(), { store: s, engine: c, overlayRef: d } =
|
|
8023
|
+
const { selectionStore: t, commands: n, chartId: r, history: a, store: i, anchorResolver: l } = j(), { store: s, engine: c, overlayRef: d } = qe(), u = Mt(), h = ue(), p = be(G((L) => L.spec.annotations.textAnnotations)), g = te(null), m = te(null), v = te(!0), y = te(/* @__PURE__ */ new WeakSet()), { showAnnotations: b, showMenuTriggerOnHover: T } = Ne[xe()], w = fe((L) => {
|
|
8024
8024
|
const { selection: I } = t.getState(), P = b ? Wr(I) : null;
|
|
8025
|
-
P !== null && (L.preventDefault(), n.dispatch(new
|
|
8025
|
+
P !== null && (L.preventDefault(), n.dispatch(new tt({ id: P })), e.focus({ preventScroll: !0 }));
|
|
8026
8026
|
}, [
|
|
8027
8027
|
e,
|
|
8028
8028
|
n,
|
|
@@ -8060,18 +8060,18 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
8060
8060
|
]);
|
|
8061
8061
|
W(() => {
|
|
8062
8062
|
const L = (A) => {
|
|
8063
|
-
if (!
|
|
8064
|
-
const C =
|
|
8063
|
+
if (!xt(A.target, e, r) || kn(A.target)) return;
|
|
8064
|
+
const C = Pt(A.target), S = h.getState(), E = S.caret !== null && !zt(A.target, r);
|
|
8065
8065
|
if (C && !E) return;
|
|
8066
|
-
const $ = () => T && A.target === e && !C && !A.metaKey && !A.ctrlKey && !A.altKey && !A.shiftKey &&
|
|
8066
|
+
const $ = () => T && A.target === e && !C && !A.metaKey && !A.ctrlKey && !A.altKey && !A.shiftKey && S.standingInteraction === null && t.getState().selection.length === 0, _ = () => {
|
|
8067
8067
|
if (!$()) return;
|
|
8068
8068
|
const ce = W2(i.getState().scene, l, u);
|
|
8069
8069
|
if (ce.length === 0) return;
|
|
8070
8070
|
const F = s.getState().hover.primary, X = A.key === "ArrowRight" || A.key === "ArrowDown" ? 1 : -1, q = g.current === null ? Uo(ce, F) : Uo(ce, g.current.primary), ie = ce[q < 0 ? X > 0 ? 0 : ce.length - 1 : Math.min(ce.length - 1, Math.max(0, q + X))];
|
|
8071
8071
|
if (ie !== void 0) {
|
|
8072
8072
|
if (m.current === null) {
|
|
8073
|
-
const Ve =
|
|
8074
|
-
Ve !== null && !vn(Ve,
|
|
8073
|
+
const Ve = Ct(F);
|
|
8074
|
+
Ve !== null && !vn(Ve, Ct(ie.primary)) && (m.current = Ve);
|
|
8075
8075
|
}
|
|
8076
8076
|
g.current = ie, A.preventDefault(), I(ie);
|
|
8077
8077
|
}
|
|
@@ -8090,7 +8090,7 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
8090
8090
|
return C ? void 0 : w(A);
|
|
8091
8091
|
case "n":
|
|
8092
8092
|
case "N":
|
|
8093
|
-
if (A.metaKey || A.ctrlKey || A.altKey || C || !T || A.target !== e ||
|
|
8093
|
+
if (A.metaKey || A.ctrlKey || A.altKey || C || !T || A.target !== e || S.standingInteraction !== null) return;
|
|
8094
8094
|
A.preventDefault(), t.getState().clearSelection(), h.getState().setPlotMenu({
|
|
8095
8095
|
x: 0.5,
|
|
8096
8096
|
y: 0.5
|
|
@@ -8106,12 +8106,12 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
8106
8106
|
}
|
|
8107
8107
|
}, I = (A) => {
|
|
8108
8108
|
const C = q2(c, A, i.getState().scene.coordSystem, Q2(c, d.current));
|
|
8109
|
-
|
|
8109
|
+
y.current.add(C), s.getState().setHoverState(C);
|
|
8110
8110
|
}, P = s.subscribe((A) => {
|
|
8111
8111
|
const C = g.current;
|
|
8112
|
-
if (C === null ||
|
|
8113
|
-
const
|
|
8114
|
-
if (
|
|
8112
|
+
if (C === null || y.current.has(A.hover)) return;
|
|
8113
|
+
const S = A.hover.primary;
|
|
8114
|
+
if (S === null) {
|
|
8115
8115
|
if (v.current) {
|
|
8116
8116
|
I(C);
|
|
8117
8117
|
return;
|
|
@@ -8119,8 +8119,8 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
8119
8119
|
g.current = null, m.current = null;
|
|
8120
8120
|
return;
|
|
8121
8121
|
}
|
|
8122
|
-
const E =
|
|
8123
|
-
if (vn(E,
|
|
8122
|
+
const E = Ct(S);
|
|
8123
|
+
if (vn(E, Ct(C.primary))) {
|
|
8124
8124
|
m.current = E;
|
|
8125
8125
|
return;
|
|
8126
8126
|
}
|
|
@@ -8153,7 +8153,7 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
8153
8153
|
c,
|
|
8154
8154
|
d
|
|
8155
8155
|
]);
|
|
8156
|
-
},
|
|
8156
|
+
}, Pt = (e) => e instanceof HTMLElement && (e.isContentEditable || e.closest('[contenteditable="true"]') !== null || e instanceof HTMLInputElement || e instanceof HTMLTextAreaElement), j2 = (e, t, n) => {
|
|
8157
8157
|
if (t === null) return !1;
|
|
8158
8158
|
const r = n.getState().pointerRegions;
|
|
8159
8159
|
if (r.length === 0) return !1;
|
|
@@ -8162,14 +8162,14 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
8162
8162
|
x: e.clientX - a.left,
|
|
8163
8163
|
y: e.clientY - a.top
|
|
8164
8164
|
}, r) !== null;
|
|
8165
|
-
},
|
|
8165
|
+
}, Ct = (e) => e === null ? null : {
|
|
8166
8166
|
layerId: e.layerId,
|
|
8167
|
-
observationIndex:
|
|
8167
|
+
observationIndex: It(e)
|
|
8168
8168
|
}, q2 = (e, t, n, r) => {
|
|
8169
8169
|
const a = Y2(t.primary, n, r);
|
|
8170
8170
|
if (a !== null) {
|
|
8171
8171
|
const i = e.query(a, { tolerance: Ji });
|
|
8172
|
-
if (vn(
|
|
8172
|
+
if (vn(Ct(i.primary), Ct(t.primary))) return {
|
|
8173
8173
|
primary: i.primary,
|
|
8174
8174
|
group: [...i.group],
|
|
8175
8175
|
related: new Map(i.related),
|
|
@@ -8201,7 +8201,7 @@ var Vt = "textStyle", pc = /* @__PURE__ */ new Set(["paragraph", "heading"]), gc
|
|
|
8201
8201
|
y: 0.5 - r.y * n / 2
|
|
8202
8202
|
};
|
|
8203
8203
|
}, J2 = (e) => {
|
|
8204
|
-
const { observation: t, x: n, y: r } = e, a = cn(t,
|
|
8204
|
+
const { observation: t, x: n, y: r } = e, a = cn(t, et.xMin), i = cn(t, et.xMax), l = cn(t, et.yMin), s = cn(t, et.yMax);
|
|
8205
8205
|
return a === null || i === null || l === null || s === null ? {
|
|
8206
8206
|
x: n,
|
|
8207
8207
|
y: r
|
|
@@ -8302,29 +8302,29 @@ var e0 = "_1vbfegu3", Yt = {
|
|
|
8302
8302
|
paddingInline: 12,
|
|
8303
8303
|
paddingBlock: 10
|
|
8304
8304
|
}, d0 = ({ frameElement: e, panelRect: t }) => {
|
|
8305
|
-
const n =
|
|
8305
|
+
const n = Q((r) => r.plotMenu);
|
|
8306
8306
|
return n === null ? null : /* @__PURE__ */ o(u0, {
|
|
8307
8307
|
frameElement: e,
|
|
8308
8308
|
panelRect: t,
|
|
8309
8309
|
point: n
|
|
8310
8310
|
}, `${n.x}:${n.y}`);
|
|
8311
8311
|
}, u0 = ({ frameElement: e, panelRect: t, point: n }) => {
|
|
8312
|
-
const r = N(), a = ue(), { commands: i, chartId: l, history: s, selectionStore: c } = j(), { Button: d, ColorSwatches: u } = U(), h = ec(), p = tc(), g = xc(), [m, v] =
|
|
8313
|
-
|
|
8312
|
+
const r = N(), a = ue(), { commands: i, chartId: l, history: s, selectionStore: c } = j(), { Button: d, ColorSwatches: u } = U(), h = ec(), p = tc(), g = xc(), [m, v] = Z({ kind: "choose" }), y = Q((A) => A.standingInteraction?.kind === "box-draw"), b = Q((A) => A.standingInteraction?.kind === "arrow-draw"), T = !y && !b, w = () => {
|
|
8313
|
+
Nt(a), a.getState().setPlotMenu(null);
|
|
8314
8314
|
};
|
|
8315
|
-
W(() => () =>
|
|
8316
|
-
if (!
|
|
8315
|
+
W(() => () => Nt(a), [a]), W(() => {
|
|
8316
|
+
if (!y && !b) return;
|
|
8317
8317
|
const A = (C) => {
|
|
8318
|
-
if (C.key !== "Escape" || !
|
|
8319
|
-
const
|
|
8320
|
-
if (
|
|
8318
|
+
if (C.key !== "Escape" || !xt(C.target, e, l) || kn(C.target)) return;
|
|
8319
|
+
const S = Pt(C.target), E = a.getState().caret !== null && !zt(C.target, l);
|
|
8320
|
+
if (S && !E) return;
|
|
8321
8321
|
const $ = a.getState().standingInteraction?.kind;
|
|
8322
8322
|
$ !== "arrow-draw" && $ !== "box-draw" || (C.preventDefault(), a.getState().releaseInteraction($));
|
|
8323
8323
|
};
|
|
8324
8324
|
return document.addEventListener("keydown", A), () => document.removeEventListener("keydown", A);
|
|
8325
8325
|
}, [
|
|
8326
8326
|
l,
|
|
8327
|
-
|
|
8327
|
+
y,
|
|
8328
8328
|
b,
|
|
8329
8329
|
a,
|
|
8330
8330
|
e
|
|
@@ -8352,7 +8352,7 @@ var e0 = "_1vbfegu3", Yt = {
|
|
|
8352
8352
|
to: k.y + k.height
|
|
8353
8353
|
}
|
|
8354
8354
|
}, L = (A) => {
|
|
8355
|
-
|
|
8355
|
+
Nt(a), v((C) => C.kind === A ? { kind: "choose" } : { kind: A });
|
|
8356
8356
|
}, I = (A) => (...C) => {
|
|
8357
8357
|
a.getState().claimInteraction({
|
|
8358
8358
|
kind: "arrow-draw",
|
|
@@ -8365,7 +8365,7 @@ var e0 = "_1vbfegu3", Yt = {
|
|
|
8365
8365
|
a.getState().releaseInteraction("box-draw");
|
|
8366
8366
|
return;
|
|
8367
8367
|
}
|
|
8368
|
-
|
|
8368
|
+
Nt(a), v({ kind: "choose" }), a.getState().claimInteraction({
|
|
8369
8369
|
kind: "box-draw",
|
|
8370
8370
|
start: n,
|
|
8371
8371
|
...jo(A[0])
|
|
@@ -8378,7 +8378,7 @@ var e0 = "_1vbfegu3", Yt = {
|
|
|
8378
8378
|
}
|
|
8379
8379
|
w();
|
|
8380
8380
|
}, B = (A) => {
|
|
8381
|
-
|
|
8381
|
+
Nt(a);
|
|
8382
8382
|
const C = new Te({
|
|
8383
8383
|
kind: "text",
|
|
8384
8384
|
annotation: {
|
|
@@ -8391,8 +8391,8 @@ var e0 = "_1vbfegu3", Yt = {
|
|
|
8391
8391
|
},
|
|
8392
8392
|
width: Ko
|
|
8393
8393
|
}
|
|
8394
|
-
}),
|
|
8395
|
-
annotationId:
|
|
8394
|
+
}), S = C.params.annotation.id, E = g({
|
|
8395
|
+
annotationId: S,
|
|
8396
8396
|
anchorX: n.x,
|
|
8397
8397
|
align: Lr.align,
|
|
8398
8398
|
panelWidth: t.width,
|
|
@@ -8405,13 +8405,13 @@ var e0 = "_1vbfegu3", Yt = {
|
|
|
8405
8405
|
width: E
|
|
8406
8406
|
}
|
|
8407
8407
|
});
|
|
8408
|
-
A === null ? i.dispatch($) : i.dispatch(new st({ commands: [$, new
|
|
8408
|
+
A === null ? i.dispatch($) : i.dispatch(new st({ commands: [$, new nt({
|
|
8409
8409
|
list: "overrides",
|
|
8410
8410
|
rule: {
|
|
8411
8411
|
select: {
|
|
8412
8412
|
target: "annotation",
|
|
8413
8413
|
kind: "text",
|
|
8414
|
-
annotation:
|
|
8414
|
+
annotation: S
|
|
8415
8415
|
},
|
|
8416
8416
|
declarations: {
|
|
8417
8417
|
fill: A,
|
|
@@ -8420,8 +8420,8 @@ var e0 = "_1vbfegu3", Yt = {
|
|
|
8420
8420
|
}
|
|
8421
8421
|
})] })), c.getState().setSelection([{
|
|
8422
8422
|
kind: "annotation",
|
|
8423
|
-
id:
|
|
8424
|
-
}]), a.getState().setCaret(
|
|
8423
|
+
id: S
|
|
8424
|
+
}]), a.getState().setCaret(S, s.stack.getSnapshot().undoStack.at(-1)?.id ?? null), a.getState().setPlotMenu(null);
|
|
8425
8425
|
}, R = (A) => {
|
|
8426
8426
|
i.dispatch(new Te({
|
|
8427
8427
|
kind: "sticker",
|
|
@@ -8435,7 +8435,7 @@ var e0 = "_1vbfegu3", Yt = {
|
|
|
8435
8435
|
}
|
|
8436
8436
|
})), w();
|
|
8437
8437
|
};
|
|
8438
|
-
return /* @__PURE__ */ f(
|
|
8438
|
+
return /* @__PURE__ */ f(J, { children: [/* @__PURE__ */ o("span", {
|
|
8439
8439
|
className: e0,
|
|
8440
8440
|
style: {
|
|
8441
8441
|
left: k.x,
|
|
@@ -8485,7 +8485,7 @@ var e0 = "_1vbfegu3", Yt = {
|
|
|
8485
8485
|
...yt,
|
|
8486
8486
|
ariaLabel: r("graph.annotations.baseMenu.box"),
|
|
8487
8487
|
icon: /* @__PURE__ */ o(a0, {}),
|
|
8488
|
-
expanded:
|
|
8488
|
+
expanded: y,
|
|
8489
8489
|
onClick: P
|
|
8490
8490
|
}),
|
|
8491
8491
|
/* @__PURE__ */ o(d, {
|
|
@@ -8557,7 +8557,7 @@ var e0 = "_1vbfegu3", Yt = {
|
|
|
8557
8557
|
]
|
|
8558
8558
|
})
|
|
8559
8559
|
})] });
|
|
8560
|
-
},
|
|
8560
|
+
}, Nt = (e) => {
|
|
8561
8561
|
const t = e.getState().standingInteraction?.kind;
|
|
8562
8562
|
(t === "arrow-draw" || t === "box-draw") && e.getState().releaseInteraction(t);
|
|
8563
8563
|
}, jo = (e) => {
|
|
@@ -8715,7 +8715,7 @@ var S0 = (e, { coordSystem: t, panelRect: n }) => {
|
|
|
8715
8715
|
to: e.y + e.height
|
|
8716
8716
|
}), A0 = (e, { frameElement: t, panelRect: n, look: r }) => {
|
|
8717
8717
|
const a = ue(), i = re(), l = G((h) => h.coordSystem), s = te(/* @__PURE__ */ new Map()), c = e?.target ?? null, d = e?.outline ?? null;
|
|
8718
|
-
|
|
8718
|
+
Ke(() => {
|
|
8719
8719
|
if (c === null || d === null) return;
|
|
8720
8720
|
const h = s.current, p = /* @__PURE__ */ new Map(), m = g0(d, {
|
|
8721
8721
|
panelRect: n,
|
|
@@ -8734,12 +8734,12 @@ var S0 = (e, { coordSystem: t, panelRect: n }) => {
|
|
|
8734
8734
|
const v = k0(S0(d, {
|
|
8735
8735
|
coordSystem: l,
|
|
8736
8736
|
panelRect: n
|
|
8737
|
-
}), m, Zt(r)),
|
|
8737
|
+
}), m, Zt(r)), y = wc(t);
|
|
8738
8738
|
a.getState().setSelectedOutline({
|
|
8739
8739
|
target: c,
|
|
8740
8740
|
frame: m,
|
|
8741
8741
|
frameSpans: v,
|
|
8742
|
-
frameScale:
|
|
8742
|
+
frameScale: y
|
|
8743
8743
|
});
|
|
8744
8744
|
}, [
|
|
8745
8745
|
a,
|
|
@@ -8752,7 +8752,7 @@ var S0 = (e, { coordSystem: t, panelRect: n }) => {
|
|
|
8752
8752
|
r
|
|
8753
8753
|
]);
|
|
8754
8754
|
const u = e !== null;
|
|
8755
|
-
|
|
8755
|
+
Ke(() => u ? () => a.getState().setSelectedOutline(null) : void 0, [a, u]);
|
|
8756
8756
|
}, za = "var(--_1qfw3e00)", P0 = "_1qfw3e01", L0 = "_1qfw3e02", Zo = ({ pathData: e, animateTransitions: t, source: n, ...r }) => t ? /* @__PURE__ */ o(I0, {
|
|
8757
8757
|
pathData: e,
|
|
8758
8758
|
source: n,
|
|
@@ -8775,9 +8775,9 @@ var S0 = (e, { coordSystem: t, panelRect: n }) => {
|
|
|
8775
8775
|
if (s === null) return null;
|
|
8776
8776
|
const c = t.find((u) => u.id === s.layerId);
|
|
8777
8777
|
if (c === void 0 || jt(c, s.observation)) return null;
|
|
8778
|
-
const d =
|
|
8778
|
+
const d = Ye({
|
|
8779
8779
|
layer: c,
|
|
8780
|
-
observationIndex:
|
|
8780
|
+
observationIndex: It(s),
|
|
8781
8781
|
scope: "observation",
|
|
8782
8782
|
parsingLocale: r
|
|
8783
8783
|
});
|
|
@@ -8835,7 +8835,7 @@ var S0 = (e, { coordSystem: t, panelRect: n }) => {
|
|
|
8835
8835
|
layers: i.layers,
|
|
8836
8836
|
coordSystem: i.coordSystem,
|
|
8837
8837
|
parsingLocale: i.config.parsingLocale
|
|
8838
|
-
}))), { anchorResolver: n } = j(), r = Zi(), a =
|
|
8838
|
+
}))), { anchorResolver: n } = j(), r = Zi(), a = Mt();
|
|
8839
8839
|
return {
|
|
8840
8840
|
showMenuTriggerOnHover: e,
|
|
8841
8841
|
...t,
|
|
@@ -8929,7 +8929,7 @@ var S0 = (e, { coordSystem: t, panelRect: n }) => {
|
|
|
8929
8929
|
return null;
|
|
8930
8930
|
}
|
|
8931
8931
|
}, F0 = () => {
|
|
8932
|
-
const e = E0(), t = $i((s) => s.hover.intersection?.intersects === !0), n = mt()[0] ?? null, r =
|
|
8932
|
+
const e = E0(), t = $i((s) => s.hover.intersection?.intersects === !0), n = mt()[0] ?? null, r = Q((s) => s.standingInteraction), a = Q((s) => s.plotMenu), { layers: i, parsingLocale: l } = G(Ie((s) => ({
|
|
8933
8933
|
layers: s.layers,
|
|
8934
8934
|
parsingLocale: s.config.parsingLocale
|
|
8935
8935
|
})));
|
|
@@ -8962,12 +8962,12 @@ var Jo = (e, t) => {
|
|
|
8962
8962
|
const { layers: t, parsingLocale: n } = G(Ie((p) => ({
|
|
8963
8963
|
layers: p.layers,
|
|
8964
8964
|
parsingLocale: p.config.parsingLocale
|
|
8965
|
-
}))), r =
|
|
8965
|
+
}))), r = Q((p) => p.editTargetUnderPointer), a = r?.kind === "observations" ? r.observations : null, i = a === null ? void 0 : ne(t, a.layerId), l = a?.target.scope ?? null, s = a === null || i === void 0 ? null : qh(i, a.target.scope, a.observationIndex), c = z(() => i === void 0 || l === null || s === null ? null : G0(t, i, l, s), [
|
|
8966
8966
|
t,
|
|
8967
8967
|
i,
|
|
8968
8968
|
l,
|
|
8969
8969
|
s
|
|
8970
|
-
]), d = z(() => c !== null && e !== null && Jo(c, e), [c, e]), u =
|
|
8970
|
+
]), d = z(() => c !== null && e !== null && Jo(c, e), [c, e]), u = Mt(), h = a !== null && i !== void 0 && $0(a, i, n, u) ? a.observationIndex : null;
|
|
8971
8971
|
return z(() => {
|
|
8972
8972
|
switch (r?.kind) {
|
|
8973
8973
|
case "observations": {
|
|
@@ -9032,7 +9032,7 @@ var Jo = (e, t) => {
|
|
|
9032
9032
|
};
|
|
9033
9033
|
}, $0 = ({ observationIndex: e, target: t, onObservation: n }, r, a, i) => {
|
|
9034
9034
|
if (!n || t.scope !== "group") return !1;
|
|
9035
|
-
const l =
|
|
9035
|
+
const l = Ye({
|
|
9036
9036
|
layer: r,
|
|
9037
9037
|
observationIndex: e,
|
|
9038
9038
|
scope: "observation",
|
|
@@ -9179,8 +9179,8 @@ var Jo = (e, t) => {
|
|
|
9179
9179
|
d
|
|
9180
9180
|
]);
|
|
9181
9181
|
}, Z0 = (e, t) => {
|
|
9182
|
-
const [n, r] =
|
|
9183
|
-
return
|
|
9182
|
+
const [n, r] = Z(() => Vr(e, t));
|
|
9183
|
+
return Ke(() => {
|
|
9184
9184
|
r((a) => {
|
|
9185
9185
|
const i = Vr(e, {
|
|
9186
9186
|
width: t.width,
|
|
@@ -9222,8 +9222,8 @@ var Jo = (e, t) => {
|
|
|
9222
9222
|
})
|
|
9223
9223
|
};
|
|
9224
9224
|
}, J0 = (e, { frameElement: t, frameSize: n }) => {
|
|
9225
|
-
const r = G((u) => u.coordSystem.type), a = G(Ie((u) => u.guides.legends.drawn.map((h) => h.display))), i = G((u) => e === null ? null : u), [l, s] =
|
|
9226
|
-
return
|
|
9225
|
+
const r = G((u) => u.coordSystem.type), a = G(Ie((u) => u.guides.legends.drawn.map((h) => h.display))), i = G((u) => e === null ? null : u), [l, s] = Z([]), c = be(e), d = te(!1);
|
|
9226
|
+
return Ke(() => {
|
|
9227
9227
|
const u = c.current;
|
|
9228
9228
|
if (u === null) return;
|
|
9229
9229
|
const h = () => {
|
|
@@ -9663,7 +9663,7 @@ var Jo = (e, t) => {
|
|
|
9663
9663
|
xValue: vb,
|
|
9664
9664
|
group: fb
|
|
9665
9665
|
}, yb = () => {
|
|
9666
|
-
const { selectionStore: e } = j(), t = ue(), n = N(), r = Dn(), a = G((
|
|
9666
|
+
const { selectionStore: e } = j(), t = ue(), n = N(), r = Dn(), a = G((y) => y), i = Zn(a, r), l = Q((y) => y.pressedObservation), s = Mt(), c = z(() => Sb({
|
|
9667
9667
|
scene: a,
|
|
9668
9668
|
pressed: l,
|
|
9669
9669
|
groupOptions: i,
|
|
@@ -9679,15 +9679,15 @@ var Jo = (e, t) => {
|
|
|
9679
9679
|
s
|
|
9680
9680
|
]);
|
|
9681
9681
|
if (c === null) return null;
|
|
9682
|
-
const { layer: d, levels: u, names: h } = c, { observationIndex: p, selectedFor: g } = c.pressed, m = u.map((
|
|
9683
|
-
const b = bb[
|
|
9682
|
+
const { layer: d, levels: u, names: h } = c, { observationIndex: p, selectedFor: g } = c.pressed, m = u.map((y) => {
|
|
9683
|
+
const b = bb[y];
|
|
9684
9684
|
return {
|
|
9685
|
-
value:
|
|
9686
|
-
label: h[
|
|
9685
|
+
value: y,
|
|
9686
|
+
label: h[y],
|
|
9687
9687
|
icon: /* @__PURE__ */ o(b, {})
|
|
9688
9688
|
};
|
|
9689
|
-
}), v = (
|
|
9690
|
-
const b = u.find((k) => k ===
|
|
9689
|
+
}), v = (y) => {
|
|
9690
|
+
const b = u.find((k) => k === y), { parsingLocale: T } = a.config, w = b === void 0 ? null : Ye({
|
|
9691
9691
|
layer: d,
|
|
9692
9692
|
observationIndex: p,
|
|
9693
9693
|
scope: b,
|
|
@@ -9713,7 +9713,7 @@ var Jo = (e, t) => {
|
|
|
9713
9713
|
parsingLocale: h,
|
|
9714
9714
|
scales: e.scales
|
|
9715
9715
|
}).filter((g) => {
|
|
9716
|
-
const m =
|
|
9716
|
+
const m = Ye({
|
|
9717
9717
|
layer: s,
|
|
9718
9718
|
observationIndex: d,
|
|
9719
9719
|
scope: g,
|
|
@@ -9762,7 +9762,7 @@ var Jo = (e, t) => {
|
|
|
9762
9762
|
]
|
|
9763
9763
|
})
|
|
9764
9764
|
}), xb = "_11vjgg60", kb = ({ target: e }) => {
|
|
9765
|
-
const t = N(), n = Pe(), r = G((g) => g), [a, i] =
|
|
9765
|
+
const t = N(), n = Pe(), r = G((g) => g), [a, i] = Z(null), l = kc(e, r);
|
|
9766
9766
|
if (l === null) return null;
|
|
9767
9767
|
const { hidden: s, hide: c, show: d } = l, u = () => {
|
|
9768
9768
|
if (s) {
|
|
@@ -9856,15 +9856,15 @@ var Jo = (e, t) => {
|
|
|
9856
9856
|
]);
|
|
9857
9857
|
return /* @__PURE__ */ o(Db, { title: i });
|
|
9858
9858
|
}, Db = ({ title: e }) => {
|
|
9859
|
-
const t = te(null), n = te(null), [r, a] =
|
|
9859
|
+
const t = te(null), n = te(null), [r, a] = Z(!1), i = fe(() => {
|
|
9860
9860
|
const c = t.current, d = n.current;
|
|
9861
9861
|
c === null || d === null || a(d.offsetWidth > c.clientWidth);
|
|
9862
9862
|
}, []);
|
|
9863
|
-
|
|
9863
|
+
Ke(i, [i, e.whole]);
|
|
9864
9864
|
const { setElement: l } = $d({ onResize: i }), s = fe((c) => {
|
|
9865
9865
|
t.current = c, l(c);
|
|
9866
9866
|
}, [l]);
|
|
9867
|
-
return /* @__PURE__ */ f(
|
|
9867
|
+
return /* @__PURE__ */ f(J, { children: [/* @__PURE__ */ o(ge.Title, {
|
|
9868
9868
|
ref: s,
|
|
9869
9869
|
className: Ib,
|
|
9870
9870
|
"data-testid": "overlay-menu-title",
|
|
@@ -9897,7 +9897,7 @@ var Jo = (e, t) => {
|
|
|
9897
9897
|
t: a
|
|
9898
9898
|
}, e.scope);
|
|
9899
9899
|
}, Fb = ({ frameElement: e }) => {
|
|
9900
|
-
const { selectionStore: t } = j(), n = Bb(
|
|
9900
|
+
const { selectionStore: t } = j(), n = Bb(Q((u) => u.selectedOutline)), r = Q((u) => u.annotatePress), a = Ne[xe()].showMenuTriggerOnHover, i = Kv(n?.target ?? null), l = Mt(), s = n === null ? null : Kt(n.target), c = z(() => a && s !== null ? Ab(r, s) : null, [
|
|
9901
9901
|
a,
|
|
9902
9902
|
r,
|
|
9903
9903
|
s
|
|
@@ -9920,10 +9920,10 @@ var Jo = (e, t) => {
|
|
|
9920
9920
|
}), /* @__PURE__ */ o(zl, { children: i }, s)]
|
|
9921
9921
|
});
|
|
9922
9922
|
}, Bb = (e) => {
|
|
9923
|
-
const t = mt(), [n, r] =
|
|
9923
|
+
const t = mt(), [n, r] = Z(e), a = n !== null && ha(t[0] ?? null, n.target), i = e ?? (a ? n : null);
|
|
9924
9924
|
return i !== n && r(i), i;
|
|
9925
9925
|
}, zb = ({ frameRect: e }) => {
|
|
9926
|
-
const { targetBoundaryStore: t } = j(), n =
|
|
9926
|
+
const { targetBoundaryStore: t } = j(), n = Q((l) => l.selectedOutline), { left: r, top: a } = e, i = z(() => {
|
|
9927
9927
|
if (n === null) return null;
|
|
9928
9928
|
const { frame: l, frameSpans: s, frameScale: c } = n;
|
|
9929
9929
|
return {
|
|
@@ -9947,9 +9947,9 @@ var Jo = (e, t) => {
|
|
|
9947
9947
|
r,
|
|
9948
9948
|
a
|
|
9949
9949
|
]);
|
|
9950
|
-
return
|
|
9950
|
+
return Ke(() => {
|
|
9951
9951
|
t.getState().setBoundary(i);
|
|
9952
|
-
}, [t, i]),
|
|
9952
|
+
}, [t, i]), Ke(() => () => t.getState().setBoundary(null), [t]), null;
|
|
9953
9953
|
}, un = (e, t, n) => ({
|
|
9954
9954
|
from: t + e.from * n,
|
|
9955
9955
|
to: t + e.to * n
|
|
@@ -9982,16 +9982,16 @@ var Jo = (e, t) => {
|
|
|
9982
9982
|
type: "free",
|
|
9983
9983
|
anchor: e,
|
|
9984
9984
|
sourceAlign: null,
|
|
9985
|
-
point:
|
|
9985
|
+
point: at(t, n),
|
|
9986
9986
|
nearby: []
|
|
9987
9987
|
}), Oc = (e, t) => Un(e, t), Gb = (e, t) => {
|
|
9988
|
-
const n =
|
|
9988
|
+
const n = at(e, t);
|
|
9989
9989
|
return {
|
|
9990
9990
|
x: t.x + n.x,
|
|
9991
9991
|
y: t.y + n.y
|
|
9992
9992
|
};
|
|
9993
9993
|
}, $b = (e, t, n) => {
|
|
9994
|
-
const r =
|
|
9994
|
+
const r = at(e, n), a = at(t, n);
|
|
9995
9995
|
return {
|
|
9996
9996
|
x: Math.min(r.x, a.x),
|
|
9997
9997
|
y: Math.min(r.y, a.y),
|
|
@@ -10022,7 +10022,7 @@ var Wb = "_1am0al61", Ub = "_1am0al62", me = (e, t) => t > 0 ? e / t : 0, Rc = (
|
|
|
10022
10022
|
x: e.x * t.width,
|
|
10023
10023
|
y: e.y * t.height
|
|
10024
10024
|
}), Xb = ({ panelRect: e }) => {
|
|
10025
|
-
const t =
|
|
10025
|
+
const t = je(e), n = Fn(), r = re(), a = qt(), i = Q((v) => ee(v, "move-drag")), l = Q((v) => ee(v, "shape-resize-drag")), s = Q((v) => ee(v, "arrow-endpoint-drag")), c = Q((v) => ee(v, "text-resize-drag")), d = Q(Kd), u = {
|
|
10026
10026
|
panel: {
|
|
10027
10027
|
width: e.width,
|
|
10028
10028
|
height: e.height
|
|
@@ -10031,23 +10031,23 @@ var Wb = "_1am0al61", Ub = "_1am0al62", me = (e, t) => t > 0 ? e / t : 0, Rc = (
|
|
|
10031
10031
|
readers: r
|
|
10032
10032
|
}, h = ri(t, a, u), p = ri(t, d === a ? null : d, u), g = (v) => {
|
|
10033
10033
|
if (l?.annotationId === v.id) {
|
|
10034
|
-
const
|
|
10035
|
-
return
|
|
10034
|
+
const y = t.shapes.find((b) => b.id === v.id);
|
|
10035
|
+
return y === void 0 ? v.geometry : Gi(l.region, r.annotation.shape(y.id).get("strokeWidth"), u.panel);
|
|
10036
10036
|
}
|
|
10037
10037
|
if (s?.annotationId === v.id) {
|
|
10038
|
-
const
|
|
10039
|
-
return
|
|
10038
|
+
const y = t.arrows.find((b) => b.id === v.id);
|
|
10039
|
+
return y === void 0 ? v.geometry : wu(Ha(y, s, u.panel), u.panel);
|
|
10040
10040
|
}
|
|
10041
10041
|
return c?.annotationId === v.id ? Ec(t, v.id, c, u) ?? v.geometry : v.geometry;
|
|
10042
10042
|
}, m = (v) => {
|
|
10043
10043
|
if (i?.annotationId !== v) return e;
|
|
10044
|
-
const
|
|
10044
|
+
const y = Dc(i.translation, e);
|
|
10045
10045
|
return {
|
|
10046
|
-
x: e.x +
|
|
10047
|
-
y: e.y +
|
|
10046
|
+
x: e.x + y.x,
|
|
10047
|
+
y: e.y + y.y
|
|
10048
10048
|
};
|
|
10049
10049
|
};
|
|
10050
|
-
return /* @__PURE__ */ f(
|
|
10050
|
+
return /* @__PURE__ */ f(J, { children: [p !== null && /* @__PURE__ */ o(ai, {
|
|
10051
10051
|
annotationId: p.id,
|
|
10052
10052
|
geometry: g(p),
|
|
10053
10053
|
state: "hovered",
|
|
@@ -10103,7 +10103,7 @@ var Wb = "_1am0al61", Ub = "_1am0al62", me = (e, t) => t > 0 ? e / t : 0, Rc = (
|
|
|
10103
10103
|
top: t.y + e.y
|
|
10104
10104
|
}
|
|
10105
10105
|
}), $a = "c44vv80", jb = ({ panelRect: e }) => {
|
|
10106
|
-
const t =
|
|
10106
|
+
const t = Q((a) => ee(a, "move-drag")), n = je(e);
|
|
10107
10107
|
if (t === null) return null;
|
|
10108
10108
|
const r = Dc(t.translation, e);
|
|
10109
10109
|
return /* @__PURE__ */ o("svg", {
|
|
@@ -10127,27 +10127,27 @@ var Wb = "_1am0al61", Ub = "_1am0al62", me = (e, t) => t > 0 ? e / t : 0, Rc = (
|
|
|
10127
10127
|
style: Bl(re(), e.id),
|
|
10128
10128
|
blockRef: n
|
|
10129
10129
|
});
|
|
10130
|
-
},
|
|
10130
|
+
}, Dt = (e, t, n) => {
|
|
10131
10131
|
const r = e.find((a) => a.id === t);
|
|
10132
10132
|
return r === void 0 ? null : n(r);
|
|
10133
10133
|
}, Yb = {
|
|
10134
|
-
text: (e, t, n) =>
|
|
10134
|
+
text: (e, t, n) => Dt(e.textAnnotations, t, (r) => /* @__PURE__ */ o(qb, {
|
|
10135
10135
|
annotation: r,
|
|
10136
10136
|
panelSize: n
|
|
10137
10137
|
})),
|
|
10138
|
-
shape: (e, t, n) =>
|
|
10138
|
+
shape: (e, t, n) => Dt(e.shapes, t, (r) => /* @__PURE__ */ o(Qb, {
|
|
10139
10139
|
shape: r,
|
|
10140
10140
|
panelSize: n
|
|
10141
10141
|
})),
|
|
10142
|
-
image: (e, t, n) =>
|
|
10142
|
+
image: (e, t, n) => Dt(e.images, t, (r) => /* @__PURE__ */ o(ty, {
|
|
10143
10143
|
image: r,
|
|
10144
10144
|
panelSize: n
|
|
10145
10145
|
})),
|
|
10146
|
-
arrow: (e, t, n) =>
|
|
10146
|
+
arrow: (e, t, n) => Dt(e.arrows, t, (r) => /* @__PURE__ */ o(Jb, {
|
|
10147
10147
|
arrow: r,
|
|
10148
10148
|
panelSize: n
|
|
10149
10149
|
})),
|
|
10150
|
-
sticker: (e, t, n) =>
|
|
10150
|
+
sticker: (e, t, n) => Dt(e.stickers, t, (r) => /* @__PURE__ */ o(ey, {
|
|
10151
10151
|
sticker: r,
|
|
10152
10152
|
panelSize: n
|
|
10153
10153
|
}))
|
|
@@ -10182,7 +10182,7 @@ var Wb = "_1am0al61", Ub = "_1am0al62", me = (e, t) => t > 0 ? e / t : 0, Rc = (
|
|
|
10182
10182
|
panel: t,
|
|
10183
10183
|
style: re().annotation.image(e.id).resolve()
|
|
10184
10184
|
}), ny = "_1lp7ph20", ry = ({ panelRect: e }) => {
|
|
10185
|
-
const t =
|
|
10185
|
+
const t = Q((n) => ee(n, "move-drag")?.placement ?? ee(n, "arrow-endpoint-drag")?.placement ?? null);
|
|
10186
10186
|
return t === null ? null : /* @__PURE__ */ o(ay, {
|
|
10187
10187
|
placement: t,
|
|
10188
10188
|
panelRect: e
|
|
@@ -10274,7 +10274,7 @@ var Wb = "_1am0al61", Ub = "_1am0al62", me = (e, t) => t > 0 ? e / t : 0, Rc = (
|
|
|
10274
10274
|
strokeWidth: e.strokeWidth,
|
|
10275
10275
|
strokeDasharray: ya(e.dashArray, e.strokeWidth)
|
|
10276
10276
|
}), oy = (e) => e.target.type === "observation" ? e.target.box : e.target.rect, iy = (e) => e.target.type === "observation" ? String(e.target.point.anchor.anchorValue) : e.target.id, ly = ({ panelRect: e }) => {
|
|
10277
|
-
const t =
|
|
10277
|
+
const t = Q((s) => ee(s, "arrow-endpoint-drag")), n = je(e).arrows, r = re();
|
|
10278
10278
|
if (t === null) return null;
|
|
10279
10279
|
const a = n.find((s) => s.id === t.annotationId);
|
|
10280
10280
|
if (a === void 0) return null;
|
|
@@ -10370,21 +10370,28 @@ var Wb = "_1am0al61", Ub = "_1am0al62", me = (e, t) => t > 0 ? e / t : 0, Rc = (
|
|
|
10370
10370
|
/* @__PURE__ */ o("path", { d: "M9 7V5a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v2" })
|
|
10371
10371
|
]
|
|
10372
10372
|
})
|
|
10373
|
-
}), dy = "var(--pvjfpx0)", uy = "var(--pvjfpx1)", hy = "pvjfpx2", py = "pvjfpx3", gy = "pvjfpx4", my = "pvjfpx6 pvjfpx5", vy = "pvjfpx7 pvjfpx6 pvjfpx5", fy = "pvjfpx8 pvjfpx5",
|
|
10374
|
-
const l = t.y + e.y, s = l + e.height, c = l - 8 - 44, d = s + 8, u = r -
|
|
10373
|
+
}), dy = "var(--pvjfpx0)", uy = "var(--pvjfpx1)", hy = "pvjfpx2", py = "pvjfpx3", gy = "pvjfpx4", my = "pvjfpx6 pvjfpx5", vy = "pvjfpx7 pvjfpx6 pvjfpx5", fy = "pvjfpx8 pvjfpx5", St = 8, by = ({ anchorBox: e, panelRect: t, frameWidth: n, frameHeight: r, avoidBoxes: a = [], pillWidthPx: i }) => {
|
|
10374
|
+
const l = t.y + e.y, s = l + e.height, c = l - 8 - 44, d = s + 8, u = r - St - 44, h = St, p = Math.max(0, n - St * 2), g = t.x + e.x + e.width / 2 - h, m = (w) => w >= St && w <= u, v = gt(d <= u ? d : c, St, u);
|
|
10375
10375
|
if (a.length === 0 || i === void 0) return {
|
|
10376
10376
|
top: v,
|
|
10377
10377
|
left: h,
|
|
10378
10378
|
available: p,
|
|
10379
10379
|
centre: g
|
|
10380
10380
|
};
|
|
10381
|
-
const
|
|
10382
|
-
|
|
10383
|
-
top:
|
|
10381
|
+
const y = (w) => !yy(w, h, p, g, i, a), b = Math.max(d, St);
|
|
10382
|
+
if (m(b) && y(b)) return {
|
|
10383
|
+
top: b,
|
|
10384
10384
|
left: h,
|
|
10385
10385
|
available: p,
|
|
10386
10386
|
centre: g
|
|
10387
|
-
}
|
|
10387
|
+
};
|
|
10388
|
+
const T = Math.max(s, ...a.map((w) => w.y + w.height)) + 8;
|
|
10389
|
+
return m(T) ? {
|
|
10390
|
+
top: T,
|
|
10391
|
+
left: h,
|
|
10392
|
+
available: p,
|
|
10393
|
+
centre: g
|
|
10394
|
+
} : m(c) && y(c) ? {
|
|
10388
10395
|
top: c,
|
|
10389
10396
|
left: h,
|
|
10390
10397
|
available: p,
|
|
@@ -10399,29 +10406,38 @@ var Wb = "_1am0al61", Ub = "_1am0al62", me = (e, t) => t > 0 ? e / t : 0, Rc = (
|
|
|
10399
10406
|
const l = Math.min(a, n), s = t + gt(r - l / 2, 0, Math.max(0, n - l)), c = s + l, d = e + 44;
|
|
10400
10407
|
return i.some((u) => s < u.x + u.width && c > u.x && e < u.y + u.height && d > u.y);
|
|
10401
10408
|
}, Sy = ({ anchorBox: e, panelRect: t, frameWidth: n, frameHeight: r, avoidBoxes: a, estimatedPillWidthPx: i, label: l, testId: s, children: c }) => {
|
|
10402
|
-
const { chartId: d } = j(), u =
|
|
10409
|
+
const { chartId: d } = j(), [u, h] = Z(null), [p, g] = Z(null);
|
|
10410
|
+
Ke(() => {
|
|
10411
|
+
if (u === null) return;
|
|
10412
|
+
const v = () => g(u.offsetWidth);
|
|
10413
|
+
v();
|
|
10414
|
+
const y = new ResizeObserver(v);
|
|
10415
|
+
return y.observe(u), () => y.disconnect();
|
|
10416
|
+
}, [u]);
|
|
10417
|
+
const m = by({
|
|
10403
10418
|
anchorBox: e,
|
|
10404
10419
|
panelRect: t,
|
|
10405
10420
|
frameWidth: n,
|
|
10406
10421
|
frameHeight: r,
|
|
10407
10422
|
avoidBoxes: a,
|
|
10408
|
-
|
|
10423
|
+
pillWidthPx: p ?? i
|
|
10409
10424
|
});
|
|
10410
10425
|
return /* @__PURE__ */ o("div", {
|
|
10411
10426
|
className: hy,
|
|
10412
10427
|
style: {
|
|
10413
|
-
top:
|
|
10414
|
-
left:
|
|
10415
|
-
width:
|
|
10428
|
+
top: m.top,
|
|
10429
|
+
left: m.left,
|
|
10430
|
+
width: m.available
|
|
10416
10431
|
},
|
|
10417
10432
|
children: /* @__PURE__ */ o(pe.Root, {
|
|
10433
|
+
ref: h,
|
|
10418
10434
|
"aria-label": l,
|
|
10419
10435
|
className: py,
|
|
10420
10436
|
"data-testid": s,
|
|
10421
10437
|
...Kn(d),
|
|
10422
10438
|
style: Ge({
|
|
10423
|
-
[dy]: `${
|
|
10424
|
-
[uy]: `${
|
|
10439
|
+
[dy]: `${m.centre}px`,
|
|
10440
|
+
[uy]: `${m.available}px`
|
|
10425
10441
|
}),
|
|
10426
10442
|
children: c
|
|
10427
10443
|
})
|
|
@@ -10475,7 +10491,7 @@ var Wb = "_1am0al61", Ub = "_1am0al62", me = (e, t) => t > 0 ? e / t : 0, Rc = (
|
|
|
10475
10491
|
Button: pe.Button,
|
|
10476
10492
|
Separator: pe.Separator
|
|
10477
10493
|
}, Ay = { kind: "chrome-popup" }, er = () => {
|
|
10478
|
-
const { commands: e } = j(), t = ue(), [n, r] =
|
|
10494
|
+
const { commands: e } = j(), t = ue(), [n, r] = Z(null);
|
|
10479
10495
|
W(() => () => e.commit(), [e]), W(() => {
|
|
10480
10496
|
const { claimInteraction: i, releaseInteraction: l } = t.getState();
|
|
10481
10497
|
return n === null ? l("chrome-popup") : i(Ay), () => l("chrome-popup");
|
|
@@ -10570,9 +10586,9 @@ var Ey = ({ arrow: e, arrowBox: t, panelRect: n, frameWidth: r, frameHeight: a,
|
|
|
10570
10586
|
}), [e.id]), v = z(() => ({
|
|
10571
10587
|
...m,
|
|
10572
10588
|
part: "outline"
|
|
10573
|
-
}), [m]),
|
|
10574
|
-
const C =
|
|
10575
|
-
s.dispatch(new
|
|
10589
|
+
}), [m]), y = (R, A) => {
|
|
10590
|
+
const C = rt(c, { select: m }, d)?.declarations ?? {};
|
|
10591
|
+
s.dispatch(new nt({
|
|
10576
10592
|
list: "overrides",
|
|
10577
10593
|
rule: {
|
|
10578
10594
|
select: m,
|
|
@@ -10583,8 +10599,8 @@ var Ey = ({ arrow: e, arrowBox: t, panelRect: n, frameWidth: r, frameHeight: a,
|
|
|
10583
10599
|
}
|
|
10584
10600
|
}), A);
|
|
10585
10601
|
}, b = (R) => {
|
|
10586
|
-
const A =
|
|
10587
|
-
s.dispatch(new
|
|
10602
|
+
const A = rt(c, { select: v }, d)?.declarations ?? {};
|
|
10603
|
+
s.dispatch(new nt({
|
|
10588
10604
|
list: "overrides",
|
|
10589
10605
|
rule: {
|
|
10590
10606
|
select: v,
|
|
@@ -10595,7 +10611,7 @@ var Ey = ({ arrow: e, arrowBox: t, panelRect: n, frameWidth: r, frameHeight: a,
|
|
|
10595
10611
|
}
|
|
10596
10612
|
}));
|
|
10597
10613
|
}, T = (R) => {
|
|
10598
|
-
|
|
10614
|
+
y(R), u.close();
|
|
10599
10615
|
}, w = (R) => {
|
|
10600
10616
|
s.dispatch(new we({
|
|
10601
10617
|
kind: "arrow",
|
|
@@ -10603,8 +10619,8 @@ var Ey = ({ arrow: e, arrowBox: t, panelRect: n, frameWidth: r, frameHeight: a,
|
|
|
10603
10619
|
patch: R
|
|
10604
10620
|
})), u.close();
|
|
10605
10621
|
}, k = () => {
|
|
10606
|
-
s.dispatch(new
|
|
10607
|
-
}, x = (R) =>
|
|
10622
|
+
s.dispatch(new tt({ id: e.id })), i.focus({ preventScroll: !0 });
|
|
10623
|
+
}, x = (R) => y({ stroke: R }, { transient: !0 }), L = (R) => T({ strokeWidth: R }), I = (R) => w({ startArrowheadStyle: R }), P = (R) => T({ dashArray: Au.arrow[R] }), H = (R) => w({ endArrowheadStyle: R }), B = () => b(g ? {
|
|
10608
10624
|
strokeWidth: 0,
|
|
10609
10625
|
shadow: "none"
|
|
10610
10626
|
} : ku);
|
|
@@ -10697,7 +10713,7 @@ var Ey = ({ arrow: e, arrowBox: t, panelRect: n, frameWidth: r, frameHeight: a,
|
|
|
10697
10713
|
});
|
|
10698
10714
|
}, hn = ({ options: e, current: t, onPick: n }) => {
|
|
10699
10715
|
const r = N(), a = (i) => () => n(i);
|
|
10700
|
-
return /* @__PURE__ */ o(
|
|
10716
|
+
return /* @__PURE__ */ o(J, { children: e.map((i) => /* @__PURE__ */ f(K.MenuItem, {
|
|
10701
10717
|
selected: i.value === t,
|
|
10702
10718
|
onClick: a(i.value),
|
|
10703
10719
|
children: [/* @__PURE__ */ o("span", { children: r(i.key) }), i.Icon !== void 0 && /* @__PURE__ */ o("span", {
|
|
@@ -10761,7 +10777,7 @@ var Ny = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, Jt = class {
|
|
|
10761
10777
|
}
|
|
10762
10778
|
}, Xr = (e, t, n, r, a) => {
|
|
10763
10779
|
if (e.anchorType === "panel") return null;
|
|
10764
|
-
const i =
|
|
10780
|
+
const i = at(n, r), l = a === void 0 ? void 0 : Xh(e.align, a), s = e.offset ?? l, c = (s?.x ?? 0) * (s?.unit === "px" ? 1 : r.width), d = (s?.y ?? 0) * (s?.unit === "px" ? 1 : r.height);
|
|
10765
10781
|
return {
|
|
10766
10782
|
anchor: e,
|
|
10767
10783
|
sourceAlign: t,
|
|
@@ -10863,7 +10879,7 @@ var Ny = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, Jt = class {
|
|
|
10863
10879
|
resolveStickerPreview(e, t, n, r) {
|
|
10864
10880
|
const { annotationId: a, press: i } = this.params, { scene: l, panelRect: s } = r, c = l.stickers.find((p) => p.id === a);
|
|
10865
10881
|
if (c === void 0) return null;
|
|
10866
|
-
const d =
|
|
10882
|
+
const d = at(c.at, s), u = {
|
|
10867
10883
|
x: t.x - i.x,
|
|
10868
10884
|
y: t.y - i.y
|
|
10869
10885
|
}, h = this.resolvePlacement([{
|
|
@@ -10906,7 +10922,7 @@ var Ny = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, Jt = class {
|
|
|
10906
10922
|
};
|
|
10907
10923
|
}
|
|
10908
10924
|
resolvePlacement(e, t, n, r, a, i) {
|
|
10909
|
-
const { annotationId: l, engine: s, anchorResolver: c, editorStore: d } = this.params, { spec: u, scene: h, panelRect: p, frameElement: g, layers: m, coordSystem: v, measuredBoxes:
|
|
10925
|
+
const { annotationId: l, engine: s, anchorResolver: c, editorStore: d } = this.params, { spec: u, scene: h, panelRect: p, frameElement: g, layers: m, coordSystem: v, measuredBoxes: y, readObservationBox: b } = a, T = /* @__PURE__ */ new Set([l, ...pa(u, l)]), w = Nc(Be(p, g), {
|
|
10910
10926
|
x: me(t.x, p.width),
|
|
10911
10927
|
y: me(t.y, p.height)
|
|
10912
10928
|
}), k = this.readOwn(d.getState())?.placement;
|
|
@@ -10920,7 +10936,7 @@ var Ny = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, Jt = class {
|
|
|
10920
10936
|
coordSystem: v,
|
|
10921
10937
|
resolver: c,
|
|
10922
10938
|
readObservationBox: b,
|
|
10923
|
-
annotationTargets: r.altKey ? [] : zc(h, T, p,
|
|
10939
|
+
annotationTargets: r.altKey ? [] : zc(h, T, p, y),
|
|
10924
10940
|
snapDistance: 8,
|
|
10925
10941
|
releaseDistance: 12,
|
|
10926
10942
|
revealDistance: 160,
|
|
@@ -10958,7 +10974,7 @@ var Ny = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, Jt = class {
|
|
|
10958
10974
|
const r = fn(e, t, n);
|
|
10959
10975
|
return r?.anchorType === "panel" ? r : null;
|
|
10960
10976
|
}, Gc = (e, t) => e === "start" ? { start: t } : { end: t }, zy = (e, t, { scene: n, panelRect: r, measuredBoxes: a, readObservationBox: i }) => {
|
|
10961
|
-
const l =
|
|
10977
|
+
const l = at(t, r), s = {
|
|
10962
10978
|
x: l.x,
|
|
10963
10979
|
y: l.y,
|
|
10964
10980
|
width: 0,
|
|
@@ -10999,20 +11015,20 @@ var Ny = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, Jt = class {
|
|
|
10999
11015
|
return ia(ee(e, "arrow-endpoint-drag"), t, n);
|
|
11000
11016
|
}
|
|
11001
11017
|
resolvePreview(e, t) {
|
|
11002
|
-
const { annotationId: n, endpoint: r, press: a, readInputs: i, engine: l, anchorResolver: s, editorStore: c } = this.params, d = i(), { spec: u, arrow: h, scene: p, panelRect: g, layers: m, coordSystem: v, measuredBoxes:
|
|
11018
|
+
const { annotationId: n, endpoint: r, press: a, readInputs: i, engine: l, anchorResolver: s, editorStore: c } = this.params, d = i(), { spec: u, arrow: h, scene: p, panelRect: g, layers: m, coordSystem: v, measuredBoxes: y, readObservationBox: b } = d, T = fn(u, n, r);
|
|
11003
11019
|
if (T === null) return null;
|
|
11004
11020
|
const w = {
|
|
11005
11021
|
x: e.x - a.x,
|
|
11006
11022
|
y: e.y - a.y
|
|
11007
|
-
}, k =
|
|
11023
|
+
}, k = at(h[r], g), x = Nc(Be(g, d.frameElement), {
|
|
11008
11024
|
x: me(k.x, g.width),
|
|
11009
11025
|
y: me(k.y, g.height)
|
|
11010
11026
|
}), L = r === "start" ? "end" : "start", I = fn(u, n, L), P = I === null ? void 0 : zy(I, h[L], {
|
|
11011
11027
|
scene: p,
|
|
11012
11028
|
panelRect: g,
|
|
11013
|
-
measuredBoxes:
|
|
11029
|
+
measuredBoxes: y,
|
|
11014
11030
|
readObservationBox: b
|
|
11015
|
-
}), H = /* @__PURE__ */ new Set([n, ...pa(u, n)]), B = this.readOwn(c.getState())?.placement, R = (
|
|
11031
|
+
}), H = /* @__PURE__ */ new Set([n, ...pa(u, n)]), B = this.readOwn(c.getState())?.placement, R = (S) => Fl({
|
|
11016
11032
|
sourcePoints: [{
|
|
11017
11033
|
align: null,
|
|
11018
11034
|
point: {
|
|
@@ -11028,7 +11044,7 @@ var Ny = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, Jt = class {
|
|
|
11028
11044
|
coordSystem: v,
|
|
11029
11045
|
resolver: s,
|
|
11030
11046
|
readObservationBox: b,
|
|
11031
|
-
annotationTargets: t.altKey ? [] : zc(p, H, g,
|
|
11047
|
+
annotationTargets: t.altKey ? [] : zc(p, H, g, y),
|
|
11032
11048
|
snapDistance: 8,
|
|
11033
11049
|
releaseDistance: 12,
|
|
11034
11050
|
revealDistance: 160,
|
|
@@ -11036,8 +11052,8 @@ var Ny = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, Jt = class {
|
|
|
11036
11052
|
detachDistance: 40,
|
|
11037
11053
|
targetGapPx: Ja,
|
|
11038
11054
|
targetAligns: Va,
|
|
11039
|
-
areaAlign:
|
|
11040
|
-
annotationAreaAlign:
|
|
11055
|
+
areaAlign: S,
|
|
11056
|
+
annotationAreaAlign: S,
|
|
11041
11057
|
areaSnapDistance: 16,
|
|
11042
11058
|
facing: P,
|
|
11043
11059
|
purpose: "pin",
|
|
@@ -11065,11 +11081,11 @@ var Ny = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, Jt = class {
|
|
|
11065
11081
|
}));
|
|
11066
11082
|
}
|
|
11067
11083
|
}, $y = ({ annotationId: e, arrow: t, panelRect: n, frameElement: r }) => {
|
|
11068
|
-
const { commands: a, anchorResolver: i } = j(), { engine: l } =
|
|
11084
|
+
const { commands: a, anchorResolver: i } = j(), { engine: l } = qe(), s = ue(), c = G(Ie((m) => ({
|
|
11069
11085
|
spec: m.spec.annotations,
|
|
11070
11086
|
layers: m.layers,
|
|
11071
11087
|
coordSystem: m.coordSystem
|
|
11072
|
-
}))), d =
|
|
11088
|
+
}))), d = je(n), u = Fn(), h = tl(n), p = be({
|
|
11073
11089
|
...c,
|
|
11074
11090
|
arrow: t,
|
|
11075
11091
|
scene: d,
|
|
@@ -11158,7 +11174,7 @@ var Ny = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, Jt = class {
|
|
|
11158
11174
|
const m = Uy(u.key, n);
|
|
11159
11175
|
if (m === null) return;
|
|
11160
11176
|
u.preventDefault();
|
|
11161
|
-
const { anchor: v, point:
|
|
11177
|
+
const { anchor: v, point: y } = Hb({
|
|
11162
11178
|
anchor: g,
|
|
11163
11179
|
point: vt(p.placement.point, n),
|
|
11164
11180
|
delta: m,
|
|
@@ -11168,7 +11184,7 @@ var Ny = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, Jt = class {
|
|
|
11168
11184
|
kind: "arrow-endpoint-drag",
|
|
11169
11185
|
annotationId: e,
|
|
11170
11186
|
endpoint: d,
|
|
11171
|
-
placement: ti(v,
|
|
11187
|
+
placement: ti(v, y, n)
|
|
11172
11188
|
});
|
|
11173
11189
|
} }), [
|
|
11174
11190
|
e,
|
|
@@ -11274,9 +11290,9 @@ var Ny = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, Jt = class {
|
|
|
11274
11290
|
const t = G((n) => n.spec.annotations.arrows);
|
|
11275
11291
|
return e === null ? null : t.find((n) => n.id === e) ?? null;
|
|
11276
11292
|
}, Yy = (e, t) => {
|
|
11277
|
-
const n =
|
|
11293
|
+
const n = je(e).arrows;
|
|
11278
11294
|
return t === null ? null : n.find((r) => r.id === t) ?? null;
|
|
11279
|
-
}, Zy = (e) =>
|
|
11295
|
+
}, Zy = (e) => Q(Ie((t) => {
|
|
11280
11296
|
if (e === null) return {
|
|
11281
11297
|
dragged: null,
|
|
11282
11298
|
moving: !1
|
|
@@ -11354,7 +11370,7 @@ var s5 = 4, c5 = 6, d5 = Od.sm, u5 = 3, h5 = ({ textMeasurer: e, textScale: t, l
|
|
|
11354
11370
|
key: "graph.annotations.differenceArrowToolbar.size.large"
|
|
11355
11371
|
}
|
|
11356
11372
|
], b5 = ({ arrow: e, color: t, labelBox: n, start: r, end: a, panelRect: i, frameWidth: l, frameHeight: s, frameElement: c }) => {
|
|
11357
|
-
const d = N(), u = qi(), { commands: h } = j(), p = G((_) => _.spec.styles.overrides), g = G((_) => Me(_.spec)), m = er(), v = f5(e),
|
|
11373
|
+
const d = N(), u = qi(), { commands: h } = j(), p = G((_) => _.spec.styles.overrides), g = G((_) => Me(_.spec)), m = er(), v = f5(e), y = re(), b = ep(y, e.id), T = y.graph().get("textScale"), w = z(() => ({
|
|
11358
11374
|
target: "annotation",
|
|
11359
11375
|
kind: "differenceArrow",
|
|
11360
11376
|
annotation: e.id
|
|
@@ -11368,22 +11384,22 @@ var s5 = 4, c5 = 6, d5 = Od.sm, u5 = 3, h5 = ({ textMeasurer: e, textScale: t, l
|
|
|
11368
11384
|
patch: _
|
|
11369
11385
|
}), se);
|
|
11370
11386
|
}, H = (_) => ({
|
|
11371
|
-
...
|
|
11387
|
+
...rt(p, { select: w }, g)?.declarations,
|
|
11372
11388
|
..._
|
|
11373
11389
|
}), B = (_) => ({
|
|
11374
|
-
...
|
|
11390
|
+
...rt(p, { select: k }, g)?.declarations,
|
|
11375
11391
|
..._
|
|
11376
11392
|
}), R = (_) => {
|
|
11377
11393
|
P(_), m.close();
|
|
11378
11394
|
}, A = () => {
|
|
11379
|
-
h.dispatch(new
|
|
11380
|
-
}, C = (_) => h.dispatch(new
|
|
11395
|
+
h.dispatch(new tt({ id: e.id })), c.focus({ preventScroll: !0 });
|
|
11396
|
+
}, C = (_) => h.dispatch(new nt({
|
|
11381
11397
|
list: "overrides",
|
|
11382
11398
|
rule: {
|
|
11383
11399
|
select: w,
|
|
11384
11400
|
declarations: H({ stroke: _ })
|
|
11385
11401
|
}
|
|
11386
|
-
}), { transient: !0 }),
|
|
11402
|
+
}), { transient: !0 }), S = () => P({
|
|
11387
11403
|
start: e.end.anchor,
|
|
11388
11404
|
end: e.start.anchor
|
|
11389
11405
|
}), E = (_) => () => R({ label: _ }), $ = (_) => () => {
|
|
@@ -11455,7 +11471,7 @@ var s5 = 4, c5 = 6, d5 = Od.sm, u5 = 3, h5 = ({ textMeasurer: e, textScale: t, l
|
|
|
11455
11471
|
/* @__PURE__ */ o(K.Separator, {}),
|
|
11456
11472
|
/* @__PURE__ */ o(K.IconButton, {
|
|
11457
11473
|
label: d("graph.annotations.differenceArrowToolbar.swap"),
|
|
11458
|
-
onClick:
|
|
11474
|
+
onClick: S,
|
|
11459
11475
|
children: /* @__PURE__ */ o(Jy, {
|
|
11460
11476
|
size: "sm",
|
|
11461
11477
|
title: ""
|
|
@@ -11473,7 +11489,7 @@ var s5 = 4, c5 = 6, d5 = Od.sm, u5 = 3, h5 = ({ textMeasurer: e, textScale: t, l
|
|
|
11473
11489
|
});
|
|
11474
11490
|
}, y5 = ({ option: e }) => {
|
|
11475
11491
|
const t = N();
|
|
11476
|
-
return e === void 0 ? null : /* @__PURE__ */ f(
|
|
11492
|
+
return e === void 0 ? null : /* @__PURE__ */ f(J, { children: [/* @__PURE__ */ o("span", {
|
|
11477
11493
|
className: i5,
|
|
11478
11494
|
children: t(e.key)
|
|
11479
11495
|
}), /* @__PURE__ */ f("span", {
|
|
@@ -11501,7 +11517,7 @@ var s5 = 4, c5 = 6, d5 = Od.sm, u5 = 3, h5 = ({ textMeasurer: e, textScale: t, l
|
|
|
11501
11517
|
resolver: l,
|
|
11502
11518
|
layer: h,
|
|
11503
11519
|
observation: u.observation,
|
|
11504
|
-
observationIndex:
|
|
11520
|
+
observationIndex: It(u),
|
|
11505
11521
|
coordSystem: i,
|
|
11506
11522
|
align: c
|
|
11507
11523
|
});
|
|
@@ -11552,7 +11568,7 @@ var s5 = 4, c5 = 6, d5 = Od.sm, u5 = 3, h5 = ({ textMeasurer: e, textScale: t, l
|
|
|
11552
11568
|
});
|
|
11553
11569
|
}
|
|
11554
11570
|
}, x5 = ({ arrow: e, panelOrigin: t, panelRect: n, onClick: r }) => {
|
|
11555
|
-
const { commands: a, anchorResolver: i } = j(), { engine: l } =
|
|
11571
|
+
const { commands: a, anchorResolver: i } = j(), { engine: l } = qe(), s = ue(), c = be({
|
|
11556
11572
|
arrow: e,
|
|
11557
11573
|
panelOrigin: t,
|
|
11558
11574
|
panelRect: n,
|
|
@@ -11804,7 +11820,7 @@ var s5 = 4, c5 = 6, d5 = Od.sm, u5 = 3, h5 = ({ textMeasurer: e, textScale: t, l
|
|
|
11804
11820
|
className: t5
|
|
11805
11821
|
})
|
|
11806
11822
|
}), E5 = "s8eewu0", mi = "s8eewu1", R5 = ({ frameElement: e, panelRect: t }) => {
|
|
11807
|
-
const n =
|
|
11823
|
+
const n = Q((d) => ee(d, "arrow-draw")), r = Q((d) => ee(d, "box-draw")), a = n?.start ?? r?.start ?? null, [i, l] = Z(null);
|
|
11808
11824
|
if (W(() => {
|
|
11809
11825
|
if (n === null && r === null) return;
|
|
11810
11826
|
const d = (p, g) => {
|
|
@@ -11845,7 +11861,7 @@ var s5 = 4, c5 = 6, d5 = Od.sm, u5 = 3, h5 = ({ textMeasurer: e, textScale: t, l
|
|
|
11845
11861
|
})
|
|
11846
11862
|
});
|
|
11847
11863
|
}, vi = (e, t, n) => Math.min(Math.max(e, t), n), N5 = ({ panelRect: e }) => {
|
|
11848
|
-
const t =
|
|
11864
|
+
const t = Q((i) => ee(i, "shape-resize-drag")), n = je(e).shapes, r = re();
|
|
11849
11865
|
if (t === null) return null;
|
|
11850
11866
|
const a = n.find((i) => i.id === t.annotationId);
|
|
11851
11867
|
return a === void 0 ? null : /* @__PURE__ */ o("svg", {
|
|
@@ -11918,8 +11934,8 @@ var s5 = 4, c5 = 6, d5 = Od.sm, u5 = 3, h5 = ({ textMeasurer: e, textScale: t, l
|
|
|
11918
11934
|
kind: "shape",
|
|
11919
11935
|
annotation: e.id
|
|
11920
11936
|
}), [e.id]), m = (w, k) => {
|
|
11921
|
-
const x =
|
|
11922
|
-
s.dispatch(new
|
|
11937
|
+
const x = rt(c, { select: g }, d)?.declarations ?? {};
|
|
11938
|
+
s.dispatch(new nt({
|
|
11923
11939
|
list: "overrides",
|
|
11924
11940
|
rule: {
|
|
11925
11941
|
select: g,
|
|
@@ -11930,8 +11946,8 @@ var s5 = 4, c5 = 6, d5 = Od.sm, u5 = 3, h5 = ({ textMeasurer: e, textScale: t, l
|
|
|
11930
11946
|
}
|
|
11931
11947
|
}), k);
|
|
11932
11948
|
}, v = () => {
|
|
11933
|
-
s.dispatch(new
|
|
11934
|
-
},
|
|
11949
|
+
s.dispatch(new tt({ id: e.id })), i.focus({ preventScroll: !0 });
|
|
11950
|
+
}, y = (w) => m({ fill: w }, { transient: !0 }), b = (w) => m({ fillAlpha: w }, { transient: !0 }), T = (w) => () => {
|
|
11935
11951
|
m({ strokeWidth: w }), u.close();
|
|
11936
11952
|
};
|
|
11937
11953
|
return /* @__PURE__ */ f(K.Root, {
|
|
@@ -11945,7 +11961,7 @@ var s5 = 4, c5 = 6, d5 = Od.sm, u5 = 3, h5 = ({ textMeasurer: e, textScale: t, l
|
|
|
11945
11961
|
/* @__PURE__ */ o(K.ColorPicker, {
|
|
11946
11962
|
color: ut(h.fill),
|
|
11947
11963
|
label: l("graph.annotations.shapeToolbar.color"),
|
|
11948
|
-
onChange:
|
|
11964
|
+
onChange: y,
|
|
11949
11965
|
opacity: h.fillAlpha,
|
|
11950
11966
|
onOpacityChange: b,
|
|
11951
11967
|
...u.bind("color"),
|
|
@@ -12248,7 +12264,7 @@ var Kc = ({ width: e, height: t }) => ({
|
|
|
12248
12264
|
}, Y5 = (e) => {
|
|
12249
12265
|
const t = G((n) => n.spec.annotations.shapes);
|
|
12250
12266
|
return e === null ? null : t.find((n) => n.id === e) ?? null;
|
|
12251
|
-
}, Z5 = (e) =>
|
|
12267
|
+
}, Z5 = (e) => Q(Ie((t) => e === null ? {
|
|
12252
12268
|
resizedRegion: null,
|
|
12253
12269
|
moving: !1
|
|
12254
12270
|
} : {
|
|
@@ -12333,19 +12349,19 @@ var ed = [
|
|
|
12333
12349
|
Icon: dc
|
|
12334
12350
|
}
|
|
12335
12351
|
], r3 = ({ annotation: e, textBox: t, panelRect: n, frameWidth: r, frameHeight: a, frameElement: i }) => {
|
|
12336
|
-
const l = N(), { commands: s } = j(), c = G((F) => F.spec.styles.overrides), d = G((F) => Me(F.spec)), u = ue(), h = er(), p = xc(), g = Bl(re(), e.id), m = b2(e.content), v =
|
|
12352
|
+
const l = N(), { commands: s } = j(), c = G((F) => F.spec.styles.overrides), d = G((F) => Me(F.spec)), u = ue(), h = er(), p = xc(), g = Bl(re(), e.id), m = b2(e.content), v = Q((F) => F.caret?.editor ?? null), y = Ht({
|
|
12337
12353
|
editor: v,
|
|
12338
12354
|
selector: () => gc(v)
|
|
12339
12355
|
}), b = Ht({
|
|
12340
12356
|
editor: v,
|
|
12341
12357
|
selector: () => mc(v)
|
|
12342
|
-
}), T = Q5(m.font ?? b), w = e3(m.fontSize ??
|
|
12358
|
+
}), T = Q5(m.font ?? b), w = e3(m.fontSize ?? y), k = du(g), x = m.color ?? k, L = z(() => ({
|
|
12343
12359
|
target: "annotation",
|
|
12344
12360
|
kind: "text",
|
|
12345
12361
|
annotation: e.id
|
|
12346
12362
|
}), [e.id]), I = (F, X) => {
|
|
12347
|
-
const q =
|
|
12348
|
-
s.dispatch(new
|
|
12363
|
+
const q = rt(c, { select: L }, d)?.declarations ?? {};
|
|
12364
|
+
s.dispatch(new nt({
|
|
12349
12365
|
list: "overrides",
|
|
12350
12366
|
rule: {
|
|
12351
12367
|
select: L,
|
|
@@ -12369,8 +12385,8 @@ var ed = [
|
|
|
12369
12385
|
}
|
|
12370
12386
|
P({ content: y2(q, F) }, X);
|
|
12371
12387
|
}, R = () => {
|
|
12372
|
-
s.dispatch(new
|
|
12373
|
-
}, A = (F) => I(a3(F), { transient: !0 }), C = (F) => I({ fillAlpha: F }, { transient: !0 }),
|
|
12388
|
+
s.dispatch(new tt({ id: e.id })), i.focus({ preventScroll: !0 });
|
|
12389
|
+
}, A = (F) => I(a3(F), { transient: !0 }), C = (F) => I({ fillAlpha: F }, { transient: !0 }), S = g.fill !== xn, E = (F) => B({ color: F === Tt ? void 0 : F }, { transient: !0 }), $ = (F) => () => {
|
|
12374
12390
|
Bt(H()) || se({ font: F }), B({ font: F }), h.close();
|
|
12375
12391
|
}, _ = (F) => () => {
|
|
12376
12392
|
Bt(H()) || se({ fontSize: F }), B({ fontSize: F }), h.close();
|
|
@@ -12381,7 +12397,7 @@ var ed = [
|
|
|
12381
12397
|
align: e.align,
|
|
12382
12398
|
panelWidth: n.width,
|
|
12383
12399
|
minWidth: e.width,
|
|
12384
|
-
pickedFontSize: F.fontSize ??
|
|
12400
|
+
pickedFontSize: F.fontSize ?? y,
|
|
12385
12401
|
pickedFont: F.font ?? b
|
|
12386
12402
|
});
|
|
12387
12403
|
q > e.width && P({ width: q });
|
|
@@ -12407,16 +12423,16 @@ var ed = [
|
|
|
12407
12423
|
label: l("graph.annotations.textToolbar.background"),
|
|
12408
12424
|
hasTransparentOption: !0,
|
|
12409
12425
|
onChange: A,
|
|
12410
|
-
opacity:
|
|
12411
|
-
onOpacityChange:
|
|
12426
|
+
opacity: S ? g.fillAlpha : void 0,
|
|
12427
|
+
onOpacityChange: S ? C : void 0,
|
|
12412
12428
|
...h.bind("background"),
|
|
12413
12429
|
children: /* @__PURE__ */ o(K.Swatch, {
|
|
12414
|
-
color:
|
|
12415
|
-
opacity:
|
|
12430
|
+
color: S ? ut(g.fill) : bf,
|
|
12431
|
+
opacity: S ? g.fillAlpha : void 0
|
|
12416
12432
|
})
|
|
12417
12433
|
}),
|
|
12418
12434
|
/* @__PURE__ */ o(K.ColorPicker, {
|
|
12419
|
-
color: m.color ??
|
|
12435
|
+
color: m.color ?? Tt,
|
|
12420
12436
|
label: l("graph.annotations.textToolbar.color"),
|
|
12421
12437
|
hasAutomaticOption: !0,
|
|
12422
12438
|
onChange: E,
|
|
@@ -12477,7 +12493,7 @@ var ed = [
|
|
|
12477
12493
|
fillAlpha: xf(e) ? Qu : 1
|
|
12478
12494
|
}, o3 = ({ current: e, onPick: t }) => {
|
|
12479
12495
|
const n = N(), r = (a) => () => t(a);
|
|
12480
|
-
return /* @__PURE__ */ o(
|
|
12496
|
+
return /* @__PURE__ */ o(J, { children: n3.map((a) => /* @__PURE__ */ o(K.ToggleButton, {
|
|
12481
12497
|
label: n(`graph.annotations.textToolbar.align.${a.alignment}`),
|
|
12482
12498
|
pressed: a.alignment === e,
|
|
12483
12499
|
onClick: r(a.alignment),
|
|
@@ -12619,7 +12635,7 @@ var td = ({ width: e }) => me(60, e), l3 = (e, t) => ({
|
|
|
12619
12635
|
return null;
|
|
12620
12636
|
}
|
|
12621
12637
|
}, g3 = (e) => {
|
|
12622
|
-
const t = qt(), n = v3(t), r = f3(t), a =
|
|
12638
|
+
const t = qt(), n = v3(t), r = f3(t), a = Q((l) => l.caret?.annotationId === t), i = b3(e.panelRect, t, r.resized);
|
|
12623
12639
|
return n === null || i === null ? null : /* @__PURE__ */ o(m3, {
|
|
12624
12640
|
annotation: n,
|
|
12625
12641
|
textBox: i,
|
|
@@ -12671,14 +12687,14 @@ var td = ({ width: e }) => me(60, e), l3 = (e, t) => ({
|
|
|
12671
12687
|
}, v3 = (e) => {
|
|
12672
12688
|
const t = G((n) => n.spec.annotations.textAnnotations);
|
|
12673
12689
|
return e === null ? null : t.find((n) => n.id === e) ?? null;
|
|
12674
|
-
}, f3 = (e) =>
|
|
12690
|
+
}, f3 = (e) => Q(Ie((t) => e === null ? {
|
|
12675
12691
|
resized: null,
|
|
12676
12692
|
moving: !1
|
|
12677
12693
|
} : {
|
|
12678
12694
|
resized: oa(ee(t, "text-resize-drag"), e),
|
|
12679
12695
|
moving: Bn(ee(t, "move-drag"), e) !== null
|
|
12680
12696
|
})), b3 = (e, t, n) => {
|
|
12681
|
-
const r =
|
|
12697
|
+
const r = je(e), a = Fn(), i = re(), l = z(() => ({
|
|
12682
12698
|
panel: {
|
|
12683
12699
|
width: e.width,
|
|
12684
12700
|
height: e.height
|
|
@@ -12700,7 +12716,7 @@ var yi = [
|
|
|
12700
12716
|
"mouseup",
|
|
12701
12717
|
"click"
|
|
12702
12718
|
], ad = (e) => e instanceof Element && e.closest("[data-menu-shield]") !== null, w3 = () => {
|
|
12703
|
-
const e =
|
|
12719
|
+
const e = Q((s) => s.plotMenu !== null), t = Q((s) => k3(s.standingInteraction?.kind)), n = mt()[0]?.kind === "observations", r = Ne[xe()].showMenuTriggerOnHover, { store: a } = qe(), i = r && !t && (e || n), l = te(null);
|
|
12704
12720
|
return W(() => {
|
|
12705
12721
|
if (!i) return;
|
|
12706
12722
|
const s = a.getState();
|
|
@@ -12735,7 +12751,7 @@ var yi = [
|
|
|
12735
12751
|
W(() => {
|
|
12736
12752
|
if (t === null) return;
|
|
12737
12753
|
const a = (i) => {
|
|
12738
|
-
if (i.key !== "Tab" || i.defaultPrevented || !
|
|
12754
|
+
if (i.key !== "Tab" || i.defaultPrevented || !xt(i.target, e, n) || kn(i.target) || r.getState().standingInteraction?.kind === "chrome-popup") return;
|
|
12739
12755
|
const l = [...t.querySelectorAll(T3)];
|
|
12740
12756
|
if (l.length === 0) return;
|
|
12741
12757
|
i.preventDefault();
|
|
@@ -12754,15 +12770,15 @@ var yi = [
|
|
|
12754
12770
|
W(() => {
|
|
12755
12771
|
let a = null;
|
|
12756
12772
|
const i = (c) => {
|
|
12757
|
-
if (
|
|
12773
|
+
if (Pt(c.target)) return;
|
|
12758
12774
|
const { caret: d } = r.getState(), u = d === null ? null : y3(c.clientX, c.clientY, e);
|
|
12759
12775
|
u?.kind === "annotation" && u.target.id === d?.annotationId || e.focus({ preventScroll: !0 });
|
|
12760
12776
|
}, l = (c) => {
|
|
12761
12777
|
const { selection: d, clearSelection: u } = t.getState();
|
|
12762
|
-
d.length !== 0 && (
|
|
12778
|
+
d.length !== 0 && (xt(c.target, e, n) || u());
|
|
12763
12779
|
}, s = (c) => {
|
|
12764
|
-
t.getState().selection.length !== 0 &&
|
|
12765
|
-
a = null, document.hasFocus() && (
|
|
12780
|
+
t.getState().selection.length !== 0 && xt(c.target, e, n) && c.relatedTarget === null && (a !== null && cancelAnimationFrame(a), a = requestAnimationFrame(() => {
|
|
12781
|
+
a = null, document.hasFocus() && (xt(document.activeElement, e, n) || t.getState().clearSelection());
|
|
12766
12782
|
}));
|
|
12767
12783
|
};
|
|
12768
12784
|
return e.addEventListener("pointerdown", i), document.addEventListener("focusin", l), document.addEventListener("focusout", s), () => {
|
|
@@ -12840,9 +12856,9 @@ var yi = [
|
|
|
12840
12856
|
if (a === null) return null;
|
|
12841
12857
|
const l = ne(t, a.layerId);
|
|
12842
12858
|
if (l === void 0) return null;
|
|
12843
|
-
const s =
|
|
12859
|
+
const s = It(a), c = i?.intersects !== !1, d = Nh(l), u = c || !Ah(n) ? [d] : ["xValue", d];
|
|
12844
12860
|
for (const h of u) {
|
|
12845
|
-
const p =
|
|
12861
|
+
const p = Ye({
|
|
12846
12862
|
layer: l,
|
|
12847
12863
|
observationIndex: s,
|
|
12848
12864
|
scope: h,
|
|
@@ -12859,7 +12875,7 @@ var yi = [
|
|
|
12859
12875
|
}, N3 = (e, t, n) => {
|
|
12860
12876
|
if (!e.onObservation || e.target.scope !== "group") return null;
|
|
12861
12877
|
const r = ne(t, e.layerId);
|
|
12862
|
-
return r === void 0 ? null :
|
|
12878
|
+
return r === void 0 ? null : Ye({
|
|
12863
12879
|
layer: r,
|
|
12864
12880
|
observationIndex: e.observationIndex,
|
|
12865
12881
|
scope: "observation",
|
|
@@ -12933,7 +12949,7 @@ var yi = [
|
|
|
12933
12949
|
if (s === null || c?.intersects !== !0) return null;
|
|
12934
12950
|
const d = r.find((p) => p.id === s.layerId);
|
|
12935
12951
|
if (d === void 0 || jt(d, s.observation) || !B3(d.spatialKind)) return null;
|
|
12936
|
-
const u =
|
|
12952
|
+
const u = It(s), h = Ye({
|
|
12937
12953
|
layer: d,
|
|
12938
12954
|
observationIndex: u,
|
|
12939
12955
|
scope: "observation",
|
|
@@ -12983,7 +12999,7 @@ var yi = [
|
|
|
12983
12999
|
return a === null || a.length === 0 ? null : a;
|
|
12984
13000
|
}, G3 = (e, t, n) => {
|
|
12985
13001
|
const r = t === void 0 ? void 0 : e.layers.find((a) => a.id === t);
|
|
12986
|
-
return r === void 0 ? null :
|
|
13002
|
+
return r === void 0 ? null : Ye({
|
|
12987
13003
|
layer: r,
|
|
12988
13004
|
observationIndex: n,
|
|
12989
13005
|
scope: "observation",
|
|
@@ -13056,11 +13072,11 @@ var yi = [
|
|
|
13056
13072
|
target: e,
|
|
13057
13073
|
observationIndex: n ? t : null
|
|
13058
13074
|
}, K3 = `[${Rd}], [${Cr}="axis"], [${Cr}="legend"]`, X3 = (e, t, n, r) => {
|
|
13059
|
-
const { commands: a, history: i, selectionStore: l, store: s, anchorResolver: c } = j(), { engine: d } =
|
|
13075
|
+
const { commands: a, history: i, selectionStore: l, store: s, anchorResolver: c } = j(), { engine: d } = qe(), u = ue(), h = G(Ie((I) => ({
|
|
13060
13076
|
spec: I.spec.annotations,
|
|
13061
13077
|
layers: I.layers,
|
|
13062
13078
|
coordSystem: I.coordSystem
|
|
13063
|
-
}))), p =
|
|
13079
|
+
}))), p = je(t), g = Fn(), m = tl(t), v = xe(), { selectGraphOnPress: y } = Ne[v], b = be(y), T = be(v === kr.annotate), w = be(v === kr.annotate), k = be({
|
|
13064
13080
|
...h,
|
|
13065
13081
|
scene: p,
|
|
13066
13082
|
panelRect: t,
|
|
@@ -13078,10 +13094,10 @@ var yi = [
|
|
|
13078
13094
|
clientY: C.clientY
|
|
13079
13095
|
}, n()).targetAtPoint, P = (C) => {
|
|
13080
13096
|
if (!(C.target instanceof Element)) return !1;
|
|
13081
|
-
const
|
|
13082
|
-
return
|
|
13083
|
-
}, H = (C,
|
|
13084
|
-
if (L.current !== null || !bd(k.current.spec,
|
|
13097
|
+
const S = C.target.closest(zi);
|
|
13098
|
+
return S !== null && e.contains(S) && Nn([C.target], e) === null;
|
|
13099
|
+
}, H = (C, S) => {
|
|
13100
|
+
if (L.current !== null || !bd(k.current.spec, S.id)) return;
|
|
13085
13101
|
try {
|
|
13086
13102
|
e.setPointerCapture(C.pointerId);
|
|
13087
13103
|
} catch {
|
|
@@ -13091,7 +13107,7 @@ var yi = [
|
|
|
13091
13107
|
const E = new By({
|
|
13092
13108
|
handle: e,
|
|
13093
13109
|
pointerId: C.pointerId,
|
|
13094
|
-
annotationId:
|
|
13110
|
+
annotationId: S.id,
|
|
13095
13111
|
press: {
|
|
13096
13112
|
x: C.clientX,
|
|
13097
13113
|
y: C.clientY
|
|
@@ -13106,34 +13122,34 @@ var yi = [
|
|
|
13106
13122
|
}
|
|
13107
13123
|
});
|
|
13108
13124
|
L.current = E, E.start();
|
|
13109
|
-
}, B = (C,
|
|
13110
|
-
const E = l.getState(), { layers: $, config: _, coordSystem: se } = s.getState().scene, ce =
|
|
13111
|
-
if (u.getState().setPressedObservation(ce), T.current && (
|
|
13112
|
-
const F = ne($,
|
|
13125
|
+
}, B = (C, S) => {
|
|
13126
|
+
const E = l.getState(), { layers: $, config: _, coordSystem: se } = s.getState().scene, ce = S.kind === "select-observations" && S.observationIndex !== null ? Zd(S.observationIndex, $, S.target, _.parsingLocale) : null;
|
|
13127
|
+
if (u.getState().setPressedObservation(ce), T.current && (S.kind === "select-observations" || S.kind === "select-band")) {
|
|
13128
|
+
const F = ne($, S.target.layerId);
|
|
13113
13129
|
if (F !== void 0 && Tb(F.geom, se.type)) {
|
|
13114
13130
|
const X = e.getBoundingClientRect(), q = Da(e, X.width);
|
|
13115
13131
|
u.getState().setAnnotatePress({
|
|
13116
|
-
key: Kt(
|
|
13132
|
+
key: Kt(S.target),
|
|
13117
13133
|
x: (C.clientX - X.left) / q,
|
|
13118
13134
|
y: (C.clientY - X.top) / q
|
|
13119
13135
|
});
|
|
13120
13136
|
} else u.getState().setAnnotatePress(null);
|
|
13121
13137
|
}
|
|
13122
|
-
switch (
|
|
13138
|
+
switch (S.kind) {
|
|
13123
13139
|
case "select-annotation":
|
|
13124
|
-
E.setSelection([
|
|
13140
|
+
E.setSelection([S.target]), H(C, S.target);
|
|
13125
13141
|
return;
|
|
13126
13142
|
case "select-observations":
|
|
13127
13143
|
case "select-band":
|
|
13128
13144
|
case "select-guide":
|
|
13129
13145
|
case "select-graph":
|
|
13130
|
-
E.setSelection([
|
|
13146
|
+
E.setSelection([S.target]);
|
|
13131
13147
|
return;
|
|
13132
13148
|
case "clear":
|
|
13133
13149
|
E.clearSelection();
|
|
13134
13150
|
return;
|
|
13135
13151
|
default:
|
|
13136
|
-
throw new Mu({ message: `No press outcome for: ${JSON.stringify(
|
|
13152
|
+
throw new Mu({ message: `No press outcome for: ${JSON.stringify(S)}` });
|
|
13137
13153
|
}
|
|
13138
13154
|
}, R = (C) => {
|
|
13139
13155
|
if (C.button !== 0) return;
|
|
@@ -13142,8 +13158,8 @@ var yi = [
|
|
|
13142
13158
|
return;
|
|
13143
13159
|
}
|
|
13144
13160
|
if (Rr(C.target)) return;
|
|
13145
|
-
const
|
|
13146
|
-
!
|
|
13161
|
+
const S = u.getState().caret?.annotationId ?? null, E = C.target instanceof Element ? C.target.closest("[data-edit-id]")?.getAttribute("data-edit-id") ?? null : null;
|
|
13162
|
+
!Pt(C.target) && E !== S && Fa(u, s.getState().scene.annotations, a.dispatch, _a(i));
|
|
13147
13163
|
const $ = u.getState().standingInteraction, _ = (Y) => {
|
|
13148
13164
|
u.getState().releaseInteraction(Y), u.getState().setPlotMenu(null), l.getState().clearSelection();
|
|
13149
13165
|
}, se = Be(k.current.panelRect, k.current.frameElement), ce = (Y) => {
|
|
@@ -13221,7 +13237,7 @@ var yi = [
|
|
|
13221
13237
|
}
|
|
13222
13238
|
}
|
|
13223
13239
|
const q = C.target instanceof Node && e.contains(C.target), ie = W3(X.targetAtPoint, {
|
|
13224
|
-
canSelectGraph: b.current && !
|
|
13240
|
+
canSelectGraph: b.current && !Pt(C.target) && n().hasOverlayMenu({ kind: "graph" }),
|
|
13225
13241
|
withinFrame: q,
|
|
13226
13242
|
caretAnnotationId: u.getState().caret?.annotationId ?? null
|
|
13227
13243
|
});
|
|
@@ -13251,8 +13267,8 @@ var yi = [
|
|
|
13251
13267
|
}
|
|
13252
13268
|
}
|
|
13253
13269
|
}
|
|
13254
|
-
const
|
|
13255
|
-
if (q && (ie.kind === "clear" ||
|
|
13270
|
+
const Ot = F.scene.coordSystem.type === "polar" && ie.kind === "select-observations";
|
|
13271
|
+
if (q && (ie.kind === "clear" || Ot) && w.current && Ci(C, e, X.elements) === null && !j3(C.target, X.elements)) {
|
|
13256
13272
|
const Y = V3({
|
|
13257
13273
|
client: {
|
|
13258
13274
|
x: C.clientX,
|
|
@@ -13271,10 +13287,10 @@ var yi = [
|
|
|
13271
13287
|
u.getState().setCaret(null), B(C, ie);
|
|
13272
13288
|
}, A = (C) => {
|
|
13273
13289
|
if (Rr(C.target) || P(C) || xr(C.target, e)) return;
|
|
13274
|
-
const
|
|
13275
|
-
switch (
|
|
13290
|
+
const S = I(C), { layers: E, guides: $, config: _ } = s.getState().scene, { hasOverlayMenu: se } = n(), ce = l.getState(), F = u.getState();
|
|
13291
|
+
switch (S?.kind) {
|
|
13276
13292
|
case "observations": {
|
|
13277
|
-
const { observations: X } =
|
|
13293
|
+
const { observations: X } = S, q = N3(X, E, _.parsingLocale);
|
|
13278
13294
|
if (q === null || !se(q)) return;
|
|
13279
13295
|
const { observationIndex: ie } = X;
|
|
13280
13296
|
F.setPressedObservation({
|
|
@@ -13286,7 +13302,7 @@ var yi = [
|
|
|
13286
13302
|
}
|
|
13287
13303
|
case "axis":
|
|
13288
13304
|
case "legend": {
|
|
13289
|
-
const X = L3(
|
|
13305
|
+
const X = L3(S, {
|
|
13290
13306
|
layers: E,
|
|
13291
13307
|
legends: $.legends.drawn,
|
|
13292
13308
|
formattedAxes: x.current,
|
|
@@ -13297,7 +13313,7 @@ var yi = [
|
|
|
13297
13313
|
return;
|
|
13298
13314
|
}
|
|
13299
13315
|
case "annotation": {
|
|
13300
|
-
const { target: X } =
|
|
13316
|
+
const { target: X } = S;
|
|
13301
13317
|
if (!k.current.spec.textAnnotations.some((q) => q.id === X.id)) return;
|
|
13302
13318
|
ce.setSelection([X]), F.setCaret(X.id);
|
|
13303
13319
|
return;
|
|
@@ -13326,8 +13342,8 @@ var yi = [
|
|
|
13326
13342
|
d,
|
|
13327
13343
|
c
|
|
13328
13344
|
]);
|
|
13329
|
-
}, j3 = (e, t) =>
|
|
13330
|
-
const { store: t } = j(), { engine: n, overlayRef: r } =
|
|
13345
|
+
}, j3 = (e, t) => Pt(e) || Ai(e) || t.some(Ai), Ai = (e) => e instanceof Element && e.closest(K3) !== null, q3 = (e) => {
|
|
13346
|
+
const { store: t } = j(), { engine: n, overlayRef: r } = qe(), { showAnnotations: a, selectObservationsOnPress: i, selectGuidesOnPress: l, hoverTolerance: s } = Ne[xe()], { waitingForView: c } = Wi(), d = Mt(), u = i && !c;
|
|
13331
13347
|
return fe(() => ({
|
|
13332
13348
|
frameElement: e,
|
|
13333
13349
|
captureRect: r.current,
|
|
@@ -13350,21 +13366,21 @@ var yi = [
|
|
|
13350
13366
|
t
|
|
13351
13367
|
]);
|
|
13352
13368
|
}, Y3 = { kind: "idle" }, Z3 = () => {
|
|
13353
|
-
const e =
|
|
13369
|
+
const e = Q((n) => n.standingInteraction), t = R0();
|
|
13354
13370
|
return z(() => e !== null ? e : t === null ? Y3 : {
|
|
13355
13371
|
kind: "trigger",
|
|
13356
13372
|
anchor: t,
|
|
13357
13373
|
isOpen: !0
|
|
13358
13374
|
}, [e, t]);
|
|
13359
13375
|
}, J3 = (e, t) => e.x >= 0 && e.x <= t.width && e.y >= 0 && e.y <= t.height, Q3 = (e, t, n) => {
|
|
13360
|
-
const { selectionStore: r } = j(), { store: a, engine: i } =
|
|
13376
|
+
const { selectionStore: r } = j(), { store: a, engine: i } = qe(), l = be(e), s = be(t), c = be(n);
|
|
13361
13377
|
W(() => {
|
|
13362
13378
|
const d = (g) => {
|
|
13363
13379
|
if (r.getState().selection.length > 0) return;
|
|
13364
|
-
const m = c.current, v = s.current,
|
|
13380
|
+
const m = c.current, v = s.current, y = {
|
|
13365
13381
|
x: g.clientX - v.x,
|
|
13366
13382
|
y: g.clientY - v.y
|
|
13367
|
-
}, b = J3(
|
|
13383
|
+
}, b = J3(y, m) ? i.query(vt(y, m)) : Ut;
|
|
13368
13384
|
a.getState().setHoverState(b);
|
|
13369
13385
|
};
|
|
13370
13386
|
let u = !1;
|
|
@@ -13386,7 +13402,7 @@ var yi = [
|
|
|
13386
13402
|
c
|
|
13387
13403
|
]);
|
|
13388
13404
|
}, eS = (e, t) => {
|
|
13389
|
-
const n = ue(), { store: r } = j(), { store: a } =
|
|
13405
|
+
const n = ue(), { store: r } = j(), { store: a } = qe(), { selectObservationsOnPress: i } = Ne[xe()];
|
|
13390
13406
|
W(() => (a.getState().setEditorOwnsQuery(i), () => a.getState().setEditorOwnsQuery(!1)), [a, i]), W(() => {
|
|
13391
13407
|
let l = null, s = null, c = !1;
|
|
13392
13408
|
const d = (T) => {
|
|
@@ -13420,13 +13436,13 @@ var yi = [
|
|
|
13420
13436
|
}, c = !1, h();
|
|
13421
13437
|
}, v = () => {
|
|
13422
13438
|
s = null, l !== null && (cancelAnimationFrame(l), l = null), g();
|
|
13423
|
-
},
|
|
13439
|
+
}, y = n.subscribe((T, w) => {
|
|
13424
13440
|
pn(w.standingInteraction) && !pn(T.standingInteraction) && p();
|
|
13425
13441
|
}), b = r.subscribe((T, w) => {
|
|
13426
13442
|
T.scene !== w.scene && (pn(n.getState().standingInteraction) || p());
|
|
13427
13443
|
});
|
|
13428
13444
|
return e.addEventListener("pointermove", m), e.addEventListener("pointerleave", v), () => {
|
|
13429
|
-
l !== null && cancelAnimationFrame(l),
|
|
13445
|
+
l !== null && cancelAnimationFrame(l), y(), b(), e.removeEventListener("pointermove", m), e.removeEventListener("pointerleave", v), g();
|
|
13430
13446
|
};
|
|
13431
13447
|
}, [
|
|
13432
13448
|
e,
|
|
@@ -13451,7 +13467,7 @@ var yi = [
|
|
|
13451
13467
|
return !1;
|
|
13452
13468
|
}
|
|
13453
13469
|
}, nS = (e, t, n, r, a) => {
|
|
13454
|
-
const i = Z3(), { store: l } =
|
|
13470
|
+
const i = Z3(), { store: l } = qe(), s = mt().length > 0, { freezeHoverWhileSelected: c } = Ne[xe()], d = q3(e);
|
|
13455
13471
|
eS(e, d), X3(e, n, d, a), Q3(i, t, n), P3(e), X2(e), A3(e, r);
|
|
13456
13472
|
const u = s && c;
|
|
13457
13473
|
W(() => (l.getState().setSuspendsHover(u), () => l.getState().setSuspendsHover(!1)), [l, u]), W(() => {
|
|
@@ -13491,14 +13507,14 @@ var yi = [
|
|
|
13491
13507
|
p,
|
|
13492
13508
|
d
|
|
13493
13509
|
]);
|
|
13494
|
-
const m =
|
|
13510
|
+
const m = Q((b) => b.caret?.annotationId ?? null), v = xe(), y = te(v);
|
|
13495
13511
|
return W(() => (r(e), () => r(null)), [r, e]), W(() => () => {
|
|
13496
13512
|
u.current();
|
|
13497
13513
|
const b = d.getState();
|
|
13498
13514
|
b.setCaret(null), b.setPressedObservation(null), b.setPlotMenu(null), i.getState().clearSelection();
|
|
13499
13515
|
}, [d, i]), W(() => {
|
|
13500
|
-
if (
|
|
13501
|
-
|
|
13516
|
+
if (y.current === v) return;
|
|
13517
|
+
y.current = v, u.current();
|
|
13502
13518
|
const b = d.getState();
|
|
13503
13519
|
b.setCaret(null), b.setEditTargetUnderPointer(null), b.setPlotMenu(null), i.getState().clearSelection();
|
|
13504
13520
|
}, [
|
|
@@ -13515,7 +13531,7 @@ var yi = [
|
|
|
13515
13531
|
formattedAxes: n
|
|
13516
13532
|
})] });
|
|
13517
13533
|
}, aS = ({ annotationId: e, panelRect: t }) => {
|
|
13518
|
-
const n = ue(), { textAnnotations: r } =
|
|
13534
|
+
const n = ue(), { textAnnotations: r } = je(t);
|
|
13519
13535
|
return W(() => {
|
|
13520
13536
|
r.some(({ id: a }) => a === e) || n.getState().setCaret(null);
|
|
13521
13537
|
}, [
|
|
@@ -13532,7 +13548,7 @@ var yi = [
|
|
|
13532
13548
|
t.top,
|
|
13533
13549
|
n.x,
|
|
13534
13550
|
n.y
|
|
13535
|
-
]), [i, l] =
|
|
13551
|
+
]), [i, l] = Z(null);
|
|
13536
13552
|
return nS(e, a, n, i, r), /* @__PURE__ */ o(iS, {
|
|
13537
13553
|
frameElement: e,
|
|
13538
13554
|
frameRect: t,
|
|
@@ -13542,7 +13558,7 @@ var yi = [
|
|
|
13542
13558
|
});
|
|
13543
13559
|
}, iS = ({ frameElement: e, frameRect: t, panelOrigin: n, panelRect: r, boxRef: a }) => {
|
|
13544
13560
|
const i = Xn(), { showAnnotations: l } = Ne[xe()];
|
|
13545
|
-
return /* @__PURE__ */ f(
|
|
13561
|
+
return /* @__PURE__ */ f(J, { children: [
|
|
13546
13562
|
/* @__PURE__ */ o(tb, {
|
|
13547
13563
|
frameElement: e,
|
|
13548
13564
|
frameSize: z(() => ({
|
|
@@ -13559,7 +13575,7 @@ var yi = [
|
|
|
13559
13575
|
"data-testid": "editor-overlay",
|
|
13560
13576
|
boxRef: a,
|
|
13561
13577
|
children: /* @__PURE__ */ f(He, { children: [
|
|
13562
|
-
l && /* @__PURE__ */ f(
|
|
13578
|
+
l && /* @__PURE__ */ f(J, { children: [
|
|
13563
13579
|
/* @__PURE__ */ o(L5, {
|
|
13564
13580
|
panelRect: r,
|
|
13565
13581
|
panelOrigin: n,
|
|
@@ -13658,7 +13674,7 @@ var vS = () => () => {
|
|
|
13658
13674
|
Root: bS,
|
|
13659
13675
|
Controls: gS
|
|
13660
13676
|
}, yS = ({ handle: e, children: t, controls: n, defaultExpandedSection: r = void 0, className: a }) => {
|
|
13661
|
-
const i = Wt(e), { themeClass: l, inlineVarsStyle: s } = Rn(), [c, d] =
|
|
13677
|
+
const i = Wt(e), { themeClass: l, inlineVarsStyle: s } = Rn(), [c, d] = Z(() => r ? [r] : []), u = z(() => ({
|
|
13662
13678
|
expandSection: (h) => d([h]),
|
|
13663
13679
|
collapseAllSections: () => d([])
|
|
13664
13680
|
}), []);
|
|
@@ -13814,17 +13830,17 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
13814
13830
|
}, yr = ({ axis: e, title: t, layout: n = "collapsible", preview: r }) => {
|
|
13815
13831
|
const a = le(), i = oe(a), l = N(), { DateField: s, NumberField: c, Switch: d, TextField: u, ToggleGroup: h } = U();
|
|
13816
13832
|
if (!i || e === "ySecondary" && (i.coordSystem.type !== "cartesian" || i.scales.ySecondary === void 0)) return null;
|
|
13817
|
-
const p = e === "ySecondary" || i.coordSystem.type !== "polar" ? "linear" : i.coordSystem.axisMapping[e].geometry, g = i.scales[e], m = g?.spec, v = m?.scaleType === "continuous" ? m : void 0,
|
|
13833
|
+
const p = e === "ySecondary" || i.coordSystem.type !== "polar" ? "linear" : i.coordSystem.axisMapping[e].geometry, g = i.scales[e], m = g?.spec, v = m?.scaleType === "continuous" ? m : void 0, y = m?.scaleType === "datetime", b = m?.scaleType === "continuous" || y ? m : void 0;
|
|
13818
13834
|
if (p === "circular" || p === "radial" && v === void 0) return null;
|
|
13819
13835
|
const T = m?.scaleType === "continuous" || m?.scaleType === "datetime", w = v !== void 0 && El(i, e), k = v?.transform === "log", x = b?.domainMax ?? null, L = ES(b), I = (D, ve) => D.map((tn) => ({
|
|
13820
13836
|
value: tn,
|
|
13821
13837
|
label: ve(tn)
|
|
13822
13838
|
})), P = i.guides.axes.find((D) => D.scaledAesthetic === e);
|
|
13823
13839
|
if (P === void 0) return null;
|
|
13824
|
-
const H = P.position, B = i.guides.axes.filter((D) => D.scaledAesthetic === e), R = B.some((D) => D.visible), A = B.some((D) => D.visible || D.showGrid), C = e === "ySecondary" ? i.config.axes.ySecondary?.label ?? P.label ?? "" : i.config.axes[e].label ?? P.label ?? "",
|
|
13840
|
+
const H = P.position, B = i.guides.axes.filter((D) => D.scaledAesthetic === e), R = B.some((D) => D.visible), A = B.some((D) => D.visible || D.showGrid), C = e === "ySecondary" ? i.config.axes.ySecondary?.label ?? P.label ?? "" : i.config.axes[e].label ?? P.label ?? "", S = IS[H === "bottom" || H === "top" ? "horizontal" : "vertical"], E = e === "y" ? Fh(i.spec) : null, $ = E === null ? void 0 : ne(i.spec.layers, E), _ = i.guides.legends.drawn.some((D) => !D.inHeadlineRow && S.some((ve) => ve === D.position)), se = S.map((D) => ({
|
|
13825
13841
|
value: D,
|
|
13826
13842
|
label: l(MS[D])
|
|
13827
|
-
})), ce = I(["auto", "edges"], (D) => l(D === "edges" ? "editor.axesPanel.labelMode.edges" : "editor.axesPanel.labelMode.auto")), F = I(["linear", "log"], (D) => l(D === "log" ? "editor.axesPanel.scale.log" : "editor.axesPanel.scale.auto")), X = I(
|
|
13843
|
+
})), ce = I(["auto", "edges"], (D) => l(D === "edges" ? "editor.axesPanel.labelMode.edges" : "editor.axesPanel.labelMode.auto")), F = I(["linear", "log"], (D) => l(D === "log" ? "editor.axesPanel.scale.log" : "editor.axesPanel.scale.auto")), X = I(y ? ["auto", "custom"] : [
|
|
13828
13844
|
"auto",
|
|
13829
13845
|
"zero",
|
|
13830
13846
|
"custom"
|
|
@@ -13841,7 +13857,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
13841
13857
|
visible: D,
|
|
13842
13858
|
keepSecondaryAxis: !0
|
|
13843
13859
|
}));
|
|
13844
|
-
},
|
|
13860
|
+
}, Ot = (D) => {
|
|
13845
13861
|
a.commands.dispatch(new sl({
|
|
13846
13862
|
axis: e,
|
|
13847
13863
|
label: D
|
|
@@ -13879,11 +13895,11 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
13879
13895
|
transform: D === "log" ? "log" : "linear"
|
|
13880
13896
|
}));
|
|
13881
13897
|
}, ke = (D) => {
|
|
13882
|
-
a.commands.dispatch(new
|
|
13898
|
+
a.commands.dispatch(new Qe({
|
|
13883
13899
|
scaledAesthetic: e,
|
|
13884
13900
|
...D
|
|
13885
13901
|
}), { transient: !0 });
|
|
13886
|
-
},
|
|
13902
|
+
}, Et = (D) => {
|
|
13887
13903
|
D !== null && ke({ domainMin: D });
|
|
13888
13904
|
}, or = (D) => {
|
|
13889
13905
|
D !== null && ke({ domainMax: D });
|
|
@@ -13892,34 +13908,34 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
13892
13908
|
ve !== null && ke({ domainMax: ve });
|
|
13893
13909
|
}, en = (D) => {
|
|
13894
13910
|
if (D === "auto") {
|
|
13895
|
-
a.commands.dispatch(new
|
|
13911
|
+
a.commands.dispatch(new Qe({
|
|
13896
13912
|
scaledAesthetic: e,
|
|
13897
13913
|
domainMin: null
|
|
13898
13914
|
}));
|
|
13899
13915
|
return;
|
|
13900
13916
|
}
|
|
13901
13917
|
if (D === "zero") {
|
|
13902
|
-
a.commands.dispatch(new
|
|
13918
|
+
a.commands.dispatch(new Qe({
|
|
13903
13919
|
scaledAesthetic: e,
|
|
13904
13920
|
domainMin: 0
|
|
13905
13921
|
}));
|
|
13906
13922
|
return;
|
|
13907
13923
|
}
|
|
13908
13924
|
const ve = Pi(g?.domain, "start");
|
|
13909
|
-
ve !== null && a.commands.dispatch(new
|
|
13925
|
+
ve !== null && a.commands.dispatch(new Qe({
|
|
13910
13926
|
scaledAesthetic: e,
|
|
13911
13927
|
domainMin: ve
|
|
13912
13928
|
}));
|
|
13913
13929
|
}, V = (D) => {
|
|
13914
13930
|
if (D !== "custom") {
|
|
13915
|
-
a.commands.dispatch(new
|
|
13931
|
+
a.commands.dispatch(new Qe({
|
|
13916
13932
|
scaledAesthetic: e,
|
|
13917
13933
|
domainMax: null
|
|
13918
13934
|
}));
|
|
13919
13935
|
return;
|
|
13920
13936
|
}
|
|
13921
13937
|
const ve = Pi(g?.domain, "end");
|
|
13922
|
-
ve !== null && a.commands.dispatch(new
|
|
13938
|
+
ve !== null && a.commands.dispatch(new Qe({
|
|
13923
13939
|
scaledAesthetic: e,
|
|
13924
13940
|
domainMax: ve
|
|
13925
13941
|
}));
|
|
@@ -13930,7 +13946,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
13930
13946
|
}));
|
|
13931
13947
|
}, _e = (D) => {
|
|
13932
13948
|
if (e === "ySecondary") return;
|
|
13933
|
-
const ve =
|
|
13949
|
+
const ve = S.find((tn) => tn === D);
|
|
13934
13950
|
ve && a.commands.dispatch(new cl({
|
|
13935
13951
|
axis: e,
|
|
13936
13952
|
position: ve
|
|
@@ -13956,12 +13972,12 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
13956
13972
|
onChange: de
|
|
13957
13973
|
})
|
|
13958
13974
|
}),
|
|
13959
|
-
p === "linear" && /* @__PURE__ */ f(
|
|
13975
|
+
p === "linear" && /* @__PURE__ */ f(J, { children: [P.visible && /* @__PURE__ */ o(M, {
|
|
13960
13976
|
label: l("editor.axesPanel.controls.title"),
|
|
13961
13977
|
children: /* @__PURE__ */ o(u, {
|
|
13962
13978
|
value: C,
|
|
13963
13979
|
placeholder: l("editor.axesPanel.controls.titlePlaceholder"),
|
|
13964
|
-
onChange:
|
|
13980
|
+
onChange: Ot,
|
|
13965
13981
|
onCommit: a.commands.commit
|
|
13966
13982
|
})
|
|
13967
13983
|
}), R && /* @__PURE__ */ o(M, {
|
|
@@ -13995,8 +14011,8 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
13995
14011
|
onChange: Oe
|
|
13996
14012
|
})
|
|
13997
14013
|
}),
|
|
13998
|
-
b && !k && /* @__PURE__ */ f(
|
|
13999
|
-
!w && /* @__PURE__ */ f(
|
|
14014
|
+
b && !k && /* @__PURE__ */ f(J, { children: [
|
|
14015
|
+
!w && /* @__PURE__ */ f(J, { children: [/* @__PURE__ */ o(M, {
|
|
14000
14016
|
label: l("editor.axesPanel.controls.startFrom"),
|
|
14001
14017
|
children: /* @__PURE__ */ o(h, {
|
|
14002
14018
|
value: L,
|
|
@@ -14005,13 +14021,13 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14005
14021
|
})
|
|
14006
14022
|
}), L !== "auto" && /* @__PURE__ */ o(M, {
|
|
14007
14023
|
label: l("editor.axesPanel.controls.value"),
|
|
14008
|
-
children:
|
|
14024
|
+
children: y ? /* @__PURE__ */ o(s, {
|
|
14009
14025
|
value: tr(b.domainMin ?? null),
|
|
14010
|
-
onChange:
|
|
14026
|
+
onChange: Et,
|
|
14011
14027
|
onCommit: a.commands.commit
|
|
14012
14028
|
}) : /* @__PURE__ */ o(c, {
|
|
14013
14029
|
value: b.domainMin ?? null,
|
|
14014
|
-
onChange:
|
|
14030
|
+
onChange: Et,
|
|
14015
14031
|
onCommit: a.commands.commit
|
|
14016
14032
|
})
|
|
14017
14033
|
})] }),
|
|
@@ -14025,7 +14041,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14025
14041
|
}),
|
|
14026
14042
|
x !== null && /* @__PURE__ */ o(M, {
|
|
14027
14043
|
label: l("editor.axesPanel.controls.value"),
|
|
14028
|
-
children:
|
|
14044
|
+
children: y ? /* @__PURE__ */ o(s, {
|
|
14029
14045
|
value: RS(x),
|
|
14030
14046
|
onChange: ft,
|
|
14031
14047
|
onCommit: a.commands.commit
|
|
@@ -14152,7 +14168,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14152
14168
|
...e,
|
|
14153
14169
|
label: c
|
|
14154
14170
|
});
|
|
14155
|
-
return /* @__PURE__ */ f(
|
|
14171
|
+
return /* @__PURE__ */ f(J, { children: [/* @__PURE__ */ o(M, {
|
|
14156
14172
|
label: n("editor.elementsPanel.sourceSection.url"),
|
|
14157
14173
|
children: /* @__PURE__ */ o(r, {
|
|
14158
14174
|
value: e.url ?? "",
|
|
@@ -14229,8 +14245,8 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14229
14245
|
})), h = (p) => {
|
|
14230
14246
|
const g = Jr.find((v) => `${v}` === p);
|
|
14231
14247
|
if (g === void 0) return;
|
|
14232
|
-
const m =
|
|
14233
|
-
r.commands.dispatch(new
|
|
14248
|
+
const m = rt(a.spec.styles.overrides, HS, Me(a.spec))?.declarations ?? {};
|
|
14249
|
+
r.commands.dispatch(new nt({
|
|
14234
14250
|
list: "overrides",
|
|
14235
14251
|
rule: {
|
|
14236
14252
|
select: { target: "graph" },
|
|
@@ -14281,7 +14297,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14281
14297
|
});
|
|
14282
14298
|
}, I7 = ({ children: e, ...t }) => /* @__PURE__ */ o(ld.Root, {
|
|
14283
14299
|
...t,
|
|
14284
|
-
children: e ?? /* @__PURE__ */ f(
|
|
14300
|
+
children: e ?? /* @__PURE__ */ f(J, { children: [
|
|
14285
14301
|
/* @__PURE__ */ o($S, {}),
|
|
14286
14302
|
/* @__PURE__ */ o(BS, {}),
|
|
14287
14303
|
/* @__PURE__ */ o(NS, {}),
|
|
@@ -14290,7 +14306,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14290
14306
|
] })
|
|
14291
14307
|
}), M7 = ({ children: e, ...t }) => /* @__PURE__ */ o(ld.Root, {
|
|
14292
14308
|
...t,
|
|
14293
|
-
children: e ?? /* @__PURE__ */ f(
|
|
14309
|
+
children: e ?? /* @__PURE__ */ f(J, { children: [
|
|
14294
14310
|
/* @__PURE__ */ o(yr, { axis: "x" }),
|
|
14295
14311
|
/* @__PURE__ */ o(yr, { axis: "y" }),
|
|
14296
14312
|
/* @__PURE__ */ o(yr, { axis: "ySecondary" })
|
|
@@ -14302,8 +14318,8 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14302
14318
|
value: m,
|
|
14303
14319
|
label: i(m === "dim" ? "editor.highlighting.highlightStyle.tint" : "editor.highlighting.highlightStyle.gray")
|
|
14304
14320
|
})), p = (m) => {
|
|
14305
|
-
const v =
|
|
14306
|
-
r.commands.dispatch(new
|
|
14321
|
+
const v = rt(a.spec.styles.overrides, US, Me(a.spec))?.declarations ?? {};
|
|
14322
|
+
r.commands.dispatch(new nt({
|
|
14307
14323
|
list: "overrides",
|
|
14308
14324
|
rule: {
|
|
14309
14325
|
select: { target: "graph" },
|
|
@@ -14314,7 +14330,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14314
14330
|
}
|
|
14315
14331
|
}), { transient: !0 });
|
|
14316
14332
|
}, g = (m) => {
|
|
14317
|
-
const v = Ii.find((
|
|
14333
|
+
const v = Ii.find((y) => y === m);
|
|
14318
14334
|
v && r.commands.dispatch(new Hu({ dimStyle: v }));
|
|
14319
14335
|
};
|
|
14320
14336
|
return /* @__PURE__ */ o(he, {
|
|
@@ -14372,8 +14388,8 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14372
14388
|
layerId: c.id,
|
|
14373
14389
|
width: v
|
|
14374
14390
|
}), { transient: !0 });
|
|
14375
|
-
}, h = d?.get("cornerRadius") ?? Pu, p = (v,
|
|
14376
|
-
const b = Mi.find((k) => k ===
|
|
14391
|
+
}, h = d?.get("cornerRadius") ?? Pu, p = (v, y) => {
|
|
14392
|
+
const b = Mi.find((k) => k === y);
|
|
14377
14393
|
if (!b) return;
|
|
14378
14394
|
const [T, w] = hd[v];
|
|
14379
14395
|
r.commands.dispatch(new Nu({
|
|
@@ -14429,7 +14445,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14429
14445
|
return typeof a != "string" || a !== e[r] ? "" : a === "none" || a === "full" ? a : "md";
|
|
14430
14446
|
}, rr = ({ children: e }) => {
|
|
14431
14447
|
const t = Ue();
|
|
14432
|
-
return /* @__PURE__ */ f(
|
|
14448
|
+
return /* @__PURE__ */ f(J, { children: [/* @__PURE__ */ o("g", {
|
|
14433
14449
|
filter: `url(#${t})`,
|
|
14434
14450
|
children: e
|
|
14435
14451
|
}), /* @__PURE__ */ o("defs", { children: /* @__PURE__ */ f("filter", {
|
|
@@ -14703,7 +14719,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14703
14719
|
hasPercentageFormat: a.canFormatDataLabelsAsPercentages
|
|
14704
14720
|
});
|
|
14705
14721
|
if (!v.supportsDataLabels) return null;
|
|
14706
|
-
const
|
|
14722
|
+
const y = (x) => {
|
|
14707
14723
|
const L = new Cl({
|
|
14708
14724
|
layerId: d.id,
|
|
14709
14725
|
showDataLabels: x
|
|
@@ -14743,7 +14759,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14743
14759
|
label: l("editor.graphPanel.graphOptions.dataLabels"),
|
|
14744
14760
|
children: /* @__PURE__ */ o(s, {
|
|
14745
14761
|
checked: u,
|
|
14746
|
-
onChange:
|
|
14762
|
+
onChange: y
|
|
14747
14763
|
})
|
|
14748
14764
|
}),
|
|
14749
14765
|
v.supportsPosition && /* @__PURE__ */ o(M, {
|
|
@@ -14820,7 +14836,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14820
14836
|
}, v = (b) => {
|
|
14821
14837
|
const T = Ln.find((w) => w === b);
|
|
14822
14838
|
T !== void 0 && r.commands.dispatch(Ps(T));
|
|
14823
|
-
},
|
|
14839
|
+
}, y = (b) => {
|
|
14824
14840
|
r.commands.dispatch(Ls(b), { transient: !0 });
|
|
14825
14841
|
};
|
|
14826
14842
|
return /* @__PURE__ */ o(he, {
|
|
@@ -14833,7 +14849,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14833
14849
|
checked: b.showGrid,
|
|
14834
14850
|
onChange: m(b.scaledAesthetic)
|
|
14835
14851
|
})
|
|
14836
|
-
}, b.scaledAesthetic)), u.stylable && p && /* @__PURE__ */ f(
|
|
14852
|
+
}, b.scaledAesthetic)), u.stylable && p && /* @__PURE__ */ f(J, { children: [/* @__PURE__ */ o(M, {
|
|
14837
14853
|
label: i("editor.graphPanel.gridSection.gridStyle"),
|
|
14838
14854
|
children: /* @__PURE__ */ o(c, {
|
|
14839
14855
|
value: u.lineStyle,
|
|
@@ -14848,7 +14864,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14848
14864
|
max: 8,
|
|
14849
14865
|
step: 0.5,
|
|
14850
14866
|
formatValue: nr,
|
|
14851
|
-
onChange:
|
|
14867
|
+
onChange: y,
|
|
14852
14868
|
onCommit: r.commands.commit
|
|
14853
14869
|
})
|
|
14854
14870
|
})] })] })
|
|
@@ -14867,7 +14883,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14867
14883
|
if (!a) return null;
|
|
14868
14884
|
const c = a.config.headline, d = c.show !== "none", u = a.coordSystem, h = u.type === "polar", p = u.type === "polar" && u.innerRadius > 0, g = a.layers.some((B) => B.summary.grandTotal !== void 0);
|
|
14869
14885
|
if (h && !g) return null;
|
|
14870
|
-
const m = h ? p6 : pd, v = a.guides.headline,
|
|
14886
|
+
const m = h ? p6 : pd, v = a.guides.headline, y = v?.kind === "perGroup" && v.items.some((B) => B.comparison !== null), b = m.map((B) => ({
|
|
14871
14887
|
value: B,
|
|
14872
14888
|
label: i(`editor.graphPanel.headlineNumberSection.metrics.${B}`)
|
|
14873
14889
|
})), T = Ri.map((B) => ({
|
|
@@ -14906,7 +14922,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14906
14922
|
checked: d,
|
|
14907
14923
|
onChange: x
|
|
14908
14924
|
})
|
|
14909
|
-
}), d && /* @__PURE__ */ f(
|
|
14925
|
+
}), d && /* @__PURE__ */ f(J, { children: [
|
|
14910
14926
|
b.length > 1 && /* @__PURE__ */ o(M, {
|
|
14911
14927
|
label: i("editor.graphPanel.headlineNumberSection.metricLabel"),
|
|
14912
14928
|
layout: "stack",
|
|
@@ -14916,7 +14932,7 @@ var TS = "_40zvwv8", he = ({ title: e, layout: t = "fixed", preview: n, accessor
|
|
|
14916
14932
|
onChange: L
|
|
14917
14933
|
})
|
|
14918
14934
|
}),
|
|
14919
|
-
|
|
14935
|
+
y && /* @__PURE__ */ o(M, {
|
|
14920
14936
|
label: i("editor.graphPanel.headlineNumberSection.compareWithLabel"),
|
|
14921
14937
|
layout: "stack",
|
|
14922
14938
|
children: /* @__PURE__ */ o(s, {
|
|
@@ -14980,25 +14996,25 @@ var wr = [
|
|
|
14980
14996
|
layers: i.layers
|
|
14981
14997
|
}), g = i.guides.headline?.kind === "perGroup", m = i.guides.colorGroups.length > 0;
|
|
14982
14998
|
if (d === "auto" && h === void 0 && !p && (g || !m)) return null;
|
|
14983
|
-
const v = h?.position ?? "none",
|
|
14999
|
+
const v = h?.position ?? "none", y = d === "auto" ? v : d, b = wr.filter((C) => C === y || u.includes(C)).map((C) => ({
|
|
14984
15000
|
value: C,
|
|
14985
15001
|
label: l(`editor.graphPanel.legendSection.${C}`)
|
|
14986
15002
|
})), T = (C) => {
|
|
14987
|
-
const
|
|
14988
|
-
|
|
15003
|
+
const S = wr.find((E) => E === C);
|
|
15004
|
+
S && a.commands.dispatch(new Pr({ position: S }));
|
|
14989
15005
|
}, w = (C) => {
|
|
14990
|
-
const
|
|
14991
|
-
|
|
15006
|
+
const S = Di.find((E) => E === C);
|
|
15007
|
+
S && a.commands.dispatch(new $u({ align: S }));
|
|
14992
15008
|
}, k = (C) => {
|
|
14993
|
-
const
|
|
14994
|
-
|
|
15009
|
+
const S = _i.find((E) => E === C);
|
|
15010
|
+
S && a.commands.dispatch(new Vu({ display: S }));
|
|
14995
15011
|
}, x = h?.position === "left" || h?.position === "right" ? "column" : "row", L = x === "row" ? "ltr" : c, I = (C) => l(C === "start" || C === "end" ? `editor.graphPanel.legendSection.${m6[x][C]}` : `editor.graphPanel.legendSection.align.${C}`), P = Di.map((C) => ({
|
|
14996
15012
|
value: C,
|
|
14997
15013
|
label: I(C)
|
|
14998
15014
|
})), H = _i.map((C) => ({
|
|
14999
15015
|
value: C,
|
|
15000
15016
|
label: l(`editor.graphPanel.legendSection.display.${C}`)
|
|
15001
|
-
})), B = t ?? l("editor.graphPanel.legendSection.title"), R = b.find((C) => C.value ===
|
|
15017
|
+
})), B = t ?? l("editor.graphPanel.legendSection.title"), R = b.find((C) => C.value === y)?.label, A = h !== void 0 && !h.inHeadlineRow;
|
|
15002
15018
|
return /* @__PURE__ */ o(he, {
|
|
15003
15019
|
title: B,
|
|
15004
15020
|
layout: n,
|
|
@@ -15008,7 +15024,7 @@ var wr = [
|
|
|
15008
15024
|
label: l("editor.axesPanel.controls.position"),
|
|
15009
15025
|
layout: "stack",
|
|
15010
15026
|
children: /* @__PURE__ */ o(s, {
|
|
15011
|
-
value:
|
|
15027
|
+
value: y,
|
|
15012
15028
|
options: b,
|
|
15013
15029
|
onChange: T
|
|
15014
15030
|
})
|
|
@@ -15089,7 +15105,7 @@ var wr = [
|
|
|
15089
15105
|
layerId: p.layerId,
|
|
15090
15106
|
showPoints: x
|
|
15091
15107
|
}));
|
|
15092
|
-
},
|
|
15108
|
+
}, y = (x) => {
|
|
15093
15109
|
r.commands.dispatch(new We({
|
|
15094
15110
|
layerId: p.layerId,
|
|
15095
15111
|
showFill: x,
|
|
@@ -15138,7 +15154,7 @@ var wr = [
|
|
|
15138
15154
|
label: i("editor.graphPanel.graphOptions.lineFill"),
|
|
15139
15155
|
children: /* @__PURE__ */ o(c, {
|
|
15140
15156
|
checked: p.showFill,
|
|
15141
|
-
onChange:
|
|
15157
|
+
onChange: y
|
|
15142
15158
|
})
|
|
15143
15159
|
}),
|
|
15144
15160
|
p.smooth !== null && /* @__PURE__ */ o(M, {
|
|
@@ -15260,7 +15276,7 @@ var wr = [
|
|
|
15260
15276
|
}, v = (w) => {
|
|
15261
15277
|
const k = A6.find((x) => x === w);
|
|
15262
15278
|
m(k ?? C6);
|
|
15263
|
-
},
|
|
15279
|
+
}, y = (w) => {
|
|
15264
15280
|
const k = ea.find((x) => x.value === w);
|
|
15265
15281
|
k && m(k.value);
|
|
15266
15282
|
}, b = (w) => {
|
|
@@ -15290,7 +15306,7 @@ var wr = [
|
|
|
15290
15306
|
children: /* @__PURE__ */ o(s, {
|
|
15291
15307
|
value: c,
|
|
15292
15308
|
options: g,
|
|
15293
|
-
onChange:
|
|
15309
|
+
onChange: y
|
|
15294
15310
|
})
|
|
15295
15311
|
}),
|
|
15296
15312
|
/* @__PURE__ */ o(M, {
|
|
@@ -15433,7 +15449,7 @@ var wr = [
|
|
|
15433
15449
|
label: i("editor.annotationsPanel.trendsAndAveragesSection.average")
|
|
15434
15450
|
});
|
|
15435
15451
|
r.commands.dispatch(I);
|
|
15436
|
-
},
|
|
15452
|
+
}, y = (k) => v(k ? "trend" : "none", { method: p }), b = (k) => v(k ? "average" : "none", { group: g ?? d(c[0]?.value ?? "") }), T = (k) => {
|
|
15437
15453
|
const x = Bi.find((L) => L === k);
|
|
15438
15454
|
x !== void 0 && v("trend", { method: x });
|
|
15439
15455
|
}, w = (k) => {
|
|
@@ -15450,7 +15466,7 @@ var wr = [
|
|
|
15450
15466
|
icon: /* @__PURE__ */ o(Fi, { size: "lg" }),
|
|
15451
15467
|
children: /* @__PURE__ */ o(s, {
|
|
15452
15468
|
checked: u !== void 0,
|
|
15453
|
-
onChange:
|
|
15469
|
+
onChange: y
|
|
15454
15470
|
})
|
|
15455
15471
|
}),
|
|
15456
15472
|
u !== void 0 && /* @__PURE__ */ o(M, {
|
|
@@ -15497,7 +15513,7 @@ export {
|
|
|
15497
15513
|
R7 as CalloutsSection,
|
|
15498
15514
|
NS as CaptionSection,
|
|
15499
15515
|
xs as ChartEditMenu,
|
|
15500
|
-
|
|
15516
|
+
Xe as ColorRow,
|
|
15501
15517
|
qp as ColorSwatches,
|
|
15502
15518
|
N7 as ComboSection,
|
|
15503
15519
|
hm as ControlRegistryProvider,
|