@graphysdk/react-renderer 1.8.1-beta.1788418998006 → 1.9.0-beta.1788545270301
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/dev.utils-C5W6wbHd.cjs +2 -0
- package/dist/{dev.utils-DepuGtOF.js → dev.utils-HBVa4Fj9.js} +6 -22
- package/dist/editable.cjs +1 -1
- package/dist/editable.d.ts +5 -0
- package/dist/editable.mjs +736 -563
- package/dist/graph-config.cjs +1 -1
- package/dist/graph-config.d.ts +0 -12
- package/dist/graph-config.mjs +1 -1
- package/dist/{history-chords-DRmTKWlW.js → history-chords-Bnz0bbie.js} +1866 -1799
- package/dist/history-chords-BurHF4pj.cjs +1 -0
- package/dist/history-chords.css +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +46 -16
- package/dist/index.mjs +309 -304
- package/package.json +17 -17
- package/dist/dev.utils-Cu9g-Xx9.cjs +0 -2
- package/dist/history-chords-DlaXmuho.cjs +0 -1
package/dist/editable.mjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { $ as oo, A as io, At as lo, B as qn, C as
|
|
2
|
-
import { d as nr, f as he, n as rr } from "./dev.utils-
|
|
3
|
-
import { ARROW_DEFAULTS as Ho, ARROW_STICKER_DECLARATIONS as Bo, ARROW_STROKE_WIDTHS as pt, AddAnnotationCommand as pe, AddHighlightCommand as Vo, BORDER_RADIUS_TOKENS as en, COMBO_TYPES as tn, CONSTANT_VARIABLES as Go, DEFAULT_BAR_BORDER_RADIUS as $o, DEFAULT_POINT_SIZE as Uo, DEFAULT_STROKE_WIDTH as Wo, DIFFERENCE_ARROW_DEFAULTS as ar, DIFFERENCE_ARROW_SIZE_DECLARATIONS as nn, MAX_BAR_WIDTH as Ko, MIN_BAR_WIDTH as qo, MoveAnnotationCommand as
|
|
4
|
-
import { createContext as Oe, useCallback as ie, useContext as Le, useEffect as O, useId as Ae, useMemo as
|
|
5
|
-
import { Fragment as
|
|
1
|
+
import { $ as oo, A as io, At as lo, B as qn, C as Zn, D as x, Dt as so, E as co, Et as Xn, F as X, Ft as G, G as uo, H as et, I as U, J as ho, K as jn, L as V, N as po, Nt as _, Ot as mo, P as go, Q as Qt, R as Et, S as vo, T as fo, U as bo, V as Mt, W as Yn, X as Co, Z as yo, _ as Jn, at as So, b as Nt, c as xo, d as wo, dt as To, et as ee, f as Qn, ft as le, g as Ao, gt as J, h as ko, ht as Ot, i as Lo, kt as Po, l as Io, lt as Eo, m as tt, n as se, nt, o as Mo, ot as k, p as er, q as No, r as $, st as Oo, t as Ro, u as Do, ut as zo, v as tr, w as _o, x as Fo, y as fe, z as Rt } from "./history-chords-Bnz0bbie.js";
|
|
2
|
+
import { d as nr, f as he, n as rr } from "./dev.utils-HBVa4Fj9.js";
|
|
3
|
+
import { ARROW_DEFAULTS as Ho, ARROW_STICKER_DECLARATIONS as Bo, ARROW_STROKE_WIDTHS as pt, AddAnnotationCommand as pe, AddHighlightCommand as Vo, BORDER_RADIUS_TOKENS as en, COMBO_TYPES as tn, CONSTANT_VARIABLES as Go, DEFAULT_BAR_BORDER_RADIUS as $o, DEFAULT_POINT_SIZE as Uo, DEFAULT_STROKE_WIDTH as Wo, DIFFERENCE_ARROW_DEFAULTS as ar, DIFFERENCE_ARROW_SIZE_DECLARATIONS as nn, MAX_BAR_WIDTH as Ko, MIN_BAR_WIDTH as qo, MoveAnnotationCommand as Zo, RESTING_HOVER_STATE as or, RemoveAnnotationCommand as ke, RemoveHighlightCommand as Xo, SHAPE_DEFAULTS as jo, SetAppearanceTextScaleCommand as Yo, SetAxisLabelCommand as Jo, SetAxisPositionCommand as Qo, SetAxisTickModeCommand as ei, SetAxisTicksVisibilityCommand as ti, SetAxisVisibilityCommand as ni, SetBarBorderRadiusCommand as ri, SetBarWidthCommand as ai, SetChartTypeCommand as ir, SetContentCaptionCommand as lr, SetContentSourceCommand as oi, SetContentSubtitleCommand as sr, SetContentTitleCommand as cr, SetDataLabelsFormatCommand as ii, SetDifferenceArrowStyleCommand as li, SetGridLineStyleCommand as si, SetGridLineWidthCommand as ci, SetGridVisibilityCommand as di, SetHeadlineCompareWithCommand as ui, SetHeadlinePositionCommand as hi, SetHeadlineShowCommand as rn, SetHeadlineSizeCommand as pi, SetHighlightDimStyleCommand as mi, SetLayerYScaleTypeCommand as gi, SetLegendAlignCommand as vi, SetLegendDisplayCommand as fi, SetLegendPositionCommand as bi, SetLineInterpolationCommand as Ci, SetLineMissingValuesCommand as yi, SetLineWidthCommand as an, SetMappingCommand as Si, SetNumberFormatAbbreviationCommand as xi, SetNumberFormatDecimalsCommand as on, SetPointSizeCommand as wi, SetPolarInnerRadiusCommand as Ti, SetPolarStartAngleCommand as Ai, SetRuleLabelCommand as ki, SetRuleValueCommand as Li, SetScaleDomainCommand as He, SetScaleReverseCommand as Pi, SetScaleTransformCommand as Ii, SetScaleZeroCommand as ln, SetStatLineCommand as Ei, SetStyleRuleCommand as Ne, TEXT_ANNOTATION_DEFAULTS as Mi, TEXT_ANNOTATION_FADE_ALPHA as Ni, ToggleCategoryLabelsCommand as Oi, ToggleContentVisibilityCommand as rt, ToggleDataLabelsCommand as Ri, ToggleGoalLineCommand as Di, ToggleLineFillCommand as zi, ToggleLinePointsVisibilityCommand as _i, ToggleStackTotalsCommand as Fi, UpdateAnnotationCommand as re, alignUnitFractions as Hi, areAnchorsEqual as dr, areEndpointsComparable as Bi, buildEditMenuTriggerRegion as Vi, buildLayerStyleAddress as Gi, buildObservationPredicate as $i, canAnchorDirectLabels as Ui, canBecomeCombo as Wi, canBecomeHeatmap as Ki, canPlaceDataLabels as qi, clampAnnotationTranslation as Zi, computeArrow as ur, createObservationAnchorBuilder as Xi, createObservationAnchorParser as ji, createStyleResolver as at, createValueFormatter as Yi, extractConstantValue as Ji, extractVariableName as Qi, filterLayersByGeoms as bt, findAnnotation as el, findAverageLineLayer as tl, findGoalLineLayer as nl, findHighlightsAtObservation as rl, findKindStyleDeclarations as al, findLayerByGeom as hr, findObservationAttachment as ol, findStyleRule as Te, findTrendLineLayer as il, formatDifferenceLabel as ll, hasMultipleGroups as sl, inferDefaultDifferenceArrowEndpoints as cl, inferDifferenceArrowEndpoints as dl, isComboChartType as ve, isCompanionLayer as pr, isObservationAttachmentKind as ul, isPointWithinEditMenuTrigger as mr, isSafeUrl as hl, projectAnchorToPanel as Ue, readChartType as gr, readComboLineLayerId as pl, readHighlightDimStyle as ml, readMappableAesthetics as gl, readMappedVariable as vl, readObservationIndex as fl, resolveBarBandFraction as bl, resolveComparisonBasis as Cl, resolveGridLineStyle as yl, resolveObservationPoint as vr, resolveShapeAnnotationStyle as Sl, stepDifferenceArrowEndpoint as xl, toPanelCursor as Dt } from "@graphysdk/viz-engine";
|
|
4
|
+
import { createContext as Oe, useCallback as ie, useContext as Le, useEffect as O, useId as Ae, useMemo as M, useRef as te, useState as Q } from "react";
|
|
5
|
+
import { Fragment as j, jsx as n, jsxs as m } from "react/jsx-runtime";
|
|
6
6
|
import { useShallow as Pe } from "zustand/react/shallow";
|
|
7
7
|
import { createPortal as fr } from "react-dom";
|
|
8
8
|
import ce from "clsx";
|
|
@@ -13,11 +13,11 @@ import { Bold as Pl } from "@tiptap/extension-bold";
|
|
|
13
13
|
import { Document as We } from "@tiptap/extension-document";
|
|
14
14
|
import { HardBreak as Il } from "@tiptap/extension-hard-break";
|
|
15
15
|
import { Heading as El } from "@tiptap/extension-heading";
|
|
16
|
-
import { Italic as
|
|
17
|
-
import { Link as
|
|
16
|
+
import { Italic as Ml } from "@tiptap/extension-italic";
|
|
17
|
+
import { Link as Nl } from "@tiptap/extension-link";
|
|
18
18
|
import { Text as Ol } from "@tiptap/extension-text";
|
|
19
|
-
import { TextAlign as
|
|
20
|
-
import { Color as
|
|
19
|
+
import { TextAlign as Rl } from "@tiptap/extension-text-align";
|
|
20
|
+
import { Color as Dl, FontFamily as yr, TextStyle as zl } from "@tiptap/extension-text-style";
|
|
21
21
|
import { Underline as _l } from "@tiptap/extension-underline";
|
|
22
22
|
import { Placeholder as zt, UndoRedo as Fl } from "@tiptap/extensions";
|
|
23
23
|
import { Paragraph as Sr } from "@tiptap/extension-paragraph";
|
|
@@ -63,6 +63,8 @@ import './editable.css';var Wl = {
|
|
|
63
63
|
areaStacked: "مساحة مكدسة",
|
|
64
64
|
pie: "دائري",
|
|
65
65
|
donut: "حلقي",
|
|
66
|
+
radar: "راداري",
|
|
67
|
+
radarFilled: "راداري معبأ",
|
|
66
68
|
scatter: "نقطي",
|
|
67
69
|
bubble: "فقاعي",
|
|
68
70
|
funnel: "قمعي",
|
|
@@ -801,11 +803,11 @@ import './editable.css';var Wl = {
|
|
|
801
803
|
}
|
|
802
804
|
}
|
|
803
805
|
}
|
|
804
|
-
},
|
|
806
|
+
}, Zl = {
|
|
805
807
|
common: Wl,
|
|
806
808
|
editor: Kl,
|
|
807
809
|
graph: ql
|
|
808
|
-
},
|
|
810
|
+
}, Xl = {
|
|
809
811
|
save: "Save",
|
|
810
812
|
cancel: "Cancel",
|
|
811
813
|
confirm: "Confirm",
|
|
@@ -816,7 +818,7 @@ import './editable.css';var Wl = {
|
|
|
816
818
|
millions: "m",
|
|
817
819
|
billions: "b"
|
|
818
820
|
}
|
|
819
|
-
},
|
|
821
|
+
}, jl = {
|
|
820
822
|
title: "Graphy Editor",
|
|
821
823
|
description: "Edit your content here",
|
|
822
824
|
graphTypes: {
|
|
@@ -830,6 +832,11 @@ import './editable.css';var Wl = {
|
|
|
830
832
|
areaStacked: "Stacked area",
|
|
831
833
|
pie: "Pie",
|
|
832
834
|
donut: "Donut",
|
|
835
|
+
radialBar: "Radial bar",
|
|
836
|
+
rose: "Rose",
|
|
837
|
+
roseStacked: "Stacked rose",
|
|
838
|
+
radar: "Radar",
|
|
839
|
+
radarFilled: "Filled radar",
|
|
833
840
|
scatter: "Scatter",
|
|
834
841
|
bubble: "Bubble",
|
|
835
842
|
funnel: "Funnel",
|
|
@@ -1568,8 +1575,8 @@ import './editable.css';var Wl = {
|
|
|
1568
1575
|
}
|
|
1569
1576
|
}
|
|
1570
1577
|
}, Jl = {
|
|
1571
|
-
common:
|
|
1572
|
-
editor:
|
|
1578
|
+
common: Xl,
|
|
1579
|
+
editor: jl,
|
|
1573
1580
|
graph: Yl
|
|
1574
1581
|
}, Ql = {
|
|
1575
1582
|
colorPanel: {
|
|
@@ -1602,6 +1609,9 @@ import './editable.css';var Wl = {
|
|
|
1602
1609
|
areaStacked: "Área sobreposta",
|
|
1603
1610
|
pie: "Circular",
|
|
1604
1611
|
donut: "Donut",
|
|
1612
|
+
radialBar: "Barras radiais",
|
|
1613
|
+
radar: "Radar",
|
|
1614
|
+
radarFilled: "Radar preenchido",
|
|
1605
1615
|
scatter: "Dispersão",
|
|
1606
1616
|
bubble: "Bolhas",
|
|
1607
1617
|
funnel: "Funil",
|
|
@@ -2347,7 +2357,7 @@ import './editable.css';var Wl = {
|
|
|
2347
2357
|
}, os = {
|
|
2348
2358
|
"en-GB": Jl,
|
|
2349
2359
|
"en-US": es,
|
|
2350
|
-
ar:
|
|
2360
|
+
ar: Zl,
|
|
2351
2361
|
"pt-PT": as
|
|
2352
2362
|
}, is = [os, Oo], ls = ({ children: e, ...t }) => /* @__PURE__ */ n(So, {
|
|
2353
2363
|
dictionaries: is,
|
|
@@ -2382,15 +2392,15 @@ import './editable.css';var Wl = {
|
|
|
2382
2392
|
3
|
|
2383
2393
|
] }),
|
|
2384
2394
|
Pl,
|
|
2385
|
-
|
|
2395
|
+
Ml,
|
|
2386
2396
|
_l,
|
|
2387
|
-
|
|
2388
|
-
|
|
2397
|
+
Rl.configure({ types: ["heading", "paragraph"] }),
|
|
2398
|
+
Nl.configure({
|
|
2389
2399
|
openOnClick: !1,
|
|
2390
2400
|
autolink: !0
|
|
2391
2401
|
}),
|
|
2392
2402
|
zl,
|
|
2393
|
-
|
|
2403
|
+
Dl,
|
|
2394
2404
|
Il
|
|
2395
2405
|
], ds = ({ titlePlaceholder: e, subtitlePlaceholder: t, isTitleVisible: r, isSubtitleVisible: a }) => [
|
|
2396
2406
|
hs({
|
|
@@ -2436,7 +2446,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2436
2446
|
})]
|
|
2437
2447
|
})
|
|
2438
2448
|
})
|
|
2439
|
-
}), Er = "transparent", yt = nr.map((e) => he[e]), Is = Object.fromEntries(nr.map((e) => [he[e], e])), Es = (e) => yt.some((t) =>
|
|
2449
|
+
}), Er = "transparent", yt = nr.map((e) => he[e]), Is = Object.fromEntries(nr.map((e) => [he[e], e])), Es = (e) => yt.some((t) => Nr(t, e)), Ms = ({ color: e, onChange: t, isOpen: r, onOpenChange: a, children: o, label: i, popupAttributes: l, opacity: s, onOpacityChange: c, hasTransparentOption: u = !1 }) => {
|
|
2440
2450
|
const d = k(), h = Os(), v = u ? [Er, ...yt] : yt, p = (g) => {
|
|
2441
2451
|
t(g), a(!1);
|
|
2442
2452
|
};
|
|
@@ -2475,7 +2485,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2475
2485
|
currentColor: e,
|
|
2476
2486
|
onPick: p
|
|
2477
2487
|
}),
|
|
2478
|
-
/* @__PURE__ */ n(
|
|
2488
|
+
/* @__PURE__ */ n(Ns, {
|
|
2479
2489
|
value: e ?? "#000000",
|
|
2480
2490
|
onChange: t,
|
|
2481
2491
|
popupAttributes: l
|
|
@@ -2509,18 +2519,18 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2509
2519
|
type: "button",
|
|
2510
2520
|
"aria-label": i === "transparent" ? o("graph.colorDropdown.transparent") : i,
|
|
2511
2521
|
className: vs,
|
|
2512
|
-
"data-active":
|
|
2522
|
+
"data-active": Nr(i, r),
|
|
2513
2523
|
onMouseDown: (l) => l.preventDefault(),
|
|
2514
2524
|
onClick: () => a(i),
|
|
2515
2525
|
children: /* @__PURE__ */ n("span", {
|
|
2516
2526
|
className: Ir,
|
|
2517
|
-
style:
|
|
2527
|
+
style: Mr(i)
|
|
2518
2528
|
})
|
|
2519
2529
|
}, i))
|
|
2520
2530
|
})]
|
|
2521
2531
|
});
|
|
2522
|
-
},
|
|
2523
|
-
const a = k(), [o, i] = Q(!1), l = lo(e) ? e : "#000000", s =
|
|
2532
|
+
}, Ns = ({ value: e, onChange: t, popupAttributes: r }) => {
|
|
2533
|
+
const a = k(), [o, i] = Q(!1), l = lo(e) ? e : "#000000", s = Rs(l);
|
|
2524
2534
|
return /* @__PURE__ */ m(Y.Root, {
|
|
2525
2535
|
open: o,
|
|
2526
2536
|
onOpenChange: i,
|
|
@@ -2535,7 +2545,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2535
2545
|
"aria-label": a("graph.colorDropdown.pickCustom"),
|
|
2536
2546
|
children: [/* @__PURE__ */ n("span", {
|
|
2537
2547
|
className: Ir,
|
|
2538
|
-
style:
|
|
2548
|
+
style: Mr(l)
|
|
2539
2549
|
}), /* @__PURE__ */ n("span", {
|
|
2540
2550
|
className: bs,
|
|
2541
2551
|
children: s
|
|
@@ -2576,7 +2586,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2576
2586
|
});
|
|
2577
2587
|
}, Os = () => {
|
|
2578
2588
|
const e = _((t) => t.scales.color);
|
|
2579
|
-
return
|
|
2589
|
+
return M(() => {
|
|
2580
2590
|
if (!e || e.kind !== "visual") return [];
|
|
2581
2591
|
const t = /* @__PURE__ */ new Set();
|
|
2582
2592
|
for (const r of e.domain) {
|
|
@@ -2585,18 +2595,18 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2585
2595
|
}
|
|
2586
2596
|
return [...t];
|
|
2587
2597
|
}, [e]);
|
|
2588
|
-
},
|
|
2598
|
+
}, Mr = (e) => e === "transparent" ? {
|
|
2589
2599
|
background: kr,
|
|
2590
2600
|
border: `1px solid ${he.border100}`
|
|
2591
2601
|
} : {
|
|
2592
2602
|
background: e,
|
|
2593
2603
|
border: `1px solid ${mo(e, 0.1)}`
|
|
2594
|
-
},
|
|
2604
|
+
}, Rs = (e) => {
|
|
2595
2605
|
const { themeValues: t } = nt();
|
|
2596
2606
|
if (Po(e)) return e.toUpperCase();
|
|
2597
2607
|
const r = Is[e];
|
|
2598
2608
|
return r ? t[r].toUpperCase() : "#000000";
|
|
2599
|
-
},
|
|
2609
|
+
}, Nr = (e, t) => t === null ? !1 : e.toLowerCase() === t.toLowerCase(), Ds = "l9kff0", zs = "l9kff1", _s = "l9kff2", Fs = "xn24px0", Hs = "xn24px1", Bs = "xn24px2", Vs = ({ children: e, popupAttributes: t }) => /* @__PURE__ */ n(z.Portal, {
|
|
2600
2610
|
container: le(),
|
|
2601
2611
|
children: /* @__PURE__ */ n(ee, { children: /* @__PURE__ */ n(z.Positioner, {
|
|
2602
2612
|
side: "bottom",
|
|
@@ -2618,7 +2628,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2618
2628
|
children: e
|
|
2619
2629
|
}), $s = ({ className: e, ...t }) => /* @__PURE__ */ n(xe.Provider, { children: /* @__PURE__ */ n(de.Root, {
|
|
2620
2630
|
...t,
|
|
2621
|
-
className: ce(
|
|
2631
|
+
className: ce(Ds, e)
|
|
2622
2632
|
}) }), Us = ({ className: e, ...t }) => /* @__PURE__ */ n(de.Group, {
|
|
2623
2633
|
...t,
|
|
2624
2634
|
className: ce(zs, e)
|
|
@@ -2634,10 +2644,10 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2634
2644
|
Group: Us,
|
|
2635
2645
|
Separator: Ws,
|
|
2636
2646
|
Button: de.Button,
|
|
2637
|
-
ColorPicker:
|
|
2647
|
+
ColorPicker: Ms,
|
|
2638
2648
|
MenuPopup: Vs,
|
|
2639
2649
|
MenuItem: Gs
|
|
2640
|
-
},
|
|
2650
|
+
}, Re = (e) => /* @__PURE__ */ n(x, {
|
|
2641
2651
|
...e,
|
|
2642
2652
|
children: /* @__PURE__ */ n("g", {
|
|
2643
2653
|
stroke: "currentColor",
|
|
@@ -2646,7 +2656,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2646
2656
|
strokeLinejoin: "round",
|
|
2647
2657
|
children: /* @__PURE__ */ n("path", { d: "m6 9 6 6 6-6" })
|
|
2648
2658
|
})
|
|
2649
|
-
}), qs = "'Noto Serif', Georgia, 'Times New Roman', serif, 'Apple Color Emoji', 'NotoColorEmoji'",
|
|
2659
|
+
}), qs = "'Noto Serif', Georgia, 'Times New Roman', serif, 'Apple Color Emoji', 'NotoColorEmoji'", Zs = `'Aeonik', 'Aeonik Fallback', ${rr}`, Xs = "'PT Mono', 'Courier New', monospace, 'Apple Color Emoji', 'NotoColorEmoji'", js = "'Intruding Cat', cursive, 'Apple Color Emoji', 'NotoColorEmoji'", St = [
|
|
2650
2660
|
{
|
|
2651
2661
|
id: "modern",
|
|
2652
2662
|
label: "Modern",
|
|
@@ -2657,7 +2667,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2657
2667
|
id: "fresh",
|
|
2658
2668
|
label: "Fresh",
|
|
2659
2669
|
preview: "Aa",
|
|
2660
|
-
fontFamily:
|
|
2670
|
+
fontFamily: Zs
|
|
2661
2671
|
},
|
|
2662
2672
|
{
|
|
2663
2673
|
id: "timeless",
|
|
@@ -2669,15 +2679,15 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2669
2679
|
id: "technical",
|
|
2670
2680
|
label: "Technical",
|
|
2671
2681
|
preview: "00",
|
|
2672
|
-
fontFamily:
|
|
2682
|
+
fontFamily: Xs
|
|
2673
2683
|
},
|
|
2674
2684
|
{
|
|
2675
2685
|
id: "fineliner",
|
|
2676
2686
|
label: "Fineliner",
|
|
2677
2687
|
preview: "Aa",
|
|
2678
|
-
fontFamily:
|
|
2688
|
+
fontFamily: js
|
|
2679
2689
|
}
|
|
2680
|
-
], Ys = (e) => e ? St.find((t) => t.fontFamily === e) ?? null : null, Or = "_70l3rt0",
|
|
2690
|
+
], Ys = (e) => e ? St.find((t) => t.fontFamily === e) ?? null : null, Or = "_70l3rt0", Rr = "_70l3rt1", Dr = "_70l3rt3", zr = "_70l3rt4", _r = "_70l3rt5", Js = ({ editor: e, currentFontFamily: t, isOpen: r, onOpenChange: a }) => {
|
|
2681
2691
|
const o = k(), i = Ys(t) ?? St[0], l = (s) => {
|
|
2682
2692
|
e.chain().focus().setFontFamily(s.fontFamily).run();
|
|
2683
2693
|
};
|
|
@@ -2690,17 +2700,17 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2690
2700
|
className: Or,
|
|
2691
2701
|
onMouseDown: (s) => s.preventDefault(),
|
|
2692
2702
|
children: [/* @__PURE__ */ n("span", {
|
|
2693
|
-
className:
|
|
2703
|
+
className: Rr,
|
|
2694
2704
|
style: { fontFamily: i?.fontFamily },
|
|
2695
2705
|
children: i?.preview
|
|
2696
|
-
}), /* @__PURE__ */ n(
|
|
2706
|
+
}), /* @__PURE__ */ n(Re, { size: "sm" })]
|
|
2697
2707
|
}), /* @__PURE__ */ n(z.Portal, {
|
|
2698
2708
|
container: le(),
|
|
2699
2709
|
children: /* @__PURE__ */ n(ee, { children: /* @__PURE__ */ n(z.Positioner, {
|
|
2700
2710
|
side: "bottom",
|
|
2701
2711
|
align: "start",
|
|
2702
2712
|
sideOffset: 6,
|
|
2703
|
-
className:
|
|
2713
|
+
className: Dr,
|
|
2704
2714
|
children: /* @__PURE__ */ n(z.Popup, {
|
|
2705
2715
|
className: zr,
|
|
2706
2716
|
onMouseDown: (s) => s.preventDefault(),
|
|
@@ -2754,16 +2764,16 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2754
2764
|
className: Or,
|
|
2755
2765
|
onMouseDown: (l) => l.preventDefault(),
|
|
2756
2766
|
children: [/* @__PURE__ */ n("span", {
|
|
2757
|
-
className:
|
|
2767
|
+
className: Rr,
|
|
2758
2768
|
children: o(i.translationKey)
|
|
2759
|
-
}), /* @__PURE__ */ n(
|
|
2769
|
+
}), /* @__PURE__ */ n(Re, { size: "sm" })]
|
|
2760
2770
|
}), /* @__PURE__ */ n(z.Portal, {
|
|
2761
2771
|
container: le(),
|
|
2762
2772
|
children: /* @__PURE__ */ n(ee, { children: /* @__PURE__ */ n(z.Positioner, {
|
|
2763
2773
|
side: "bottom",
|
|
2764
2774
|
align: "start",
|
|
2765
2775
|
sideOffset: 6,
|
|
2766
|
-
className:
|
|
2776
|
+
className: Dr,
|
|
2767
2777
|
children: /* @__PURE__ */ n(z.Popup, {
|
|
2768
2778
|
className: zr,
|
|
2769
2779
|
onMouseDown: (l) => l.preventDefault(),
|
|
@@ -2803,7 +2813,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2803
2813
|
margin: 0
|
|
2804
2814
|
},
|
|
2805
2815
|
children: t
|
|
2806
|
-
}), Hr = (e) => /* @__PURE__ */ n(
|
|
2816
|
+
}), Hr = (e) => /* @__PURE__ */ n(x, {
|
|
2807
2817
|
...e,
|
|
2808
2818
|
children: /* @__PURE__ */ n("g", {
|
|
2809
2819
|
stroke: "currentColor",
|
|
@@ -2812,7 +2822,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2812
2822
|
strokeLinejoin: "round",
|
|
2813
2823
|
children: /* @__PURE__ */ n("path", { d: "M20 6 9 17l-5-5" })
|
|
2814
2824
|
})
|
|
2815
|
-
}), nc = (e) => /* @__PURE__ */ n(
|
|
2825
|
+
}), nc = (e) => /* @__PURE__ */ n(x, {
|
|
2816
2826
|
...e,
|
|
2817
2827
|
children: /* @__PURE__ */ m("g", {
|
|
2818
2828
|
stroke: "currentColor",
|
|
@@ -2821,7 +2831,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2821
2831
|
strokeLinejoin: "round",
|
|
2822
2832
|
children: [/* @__PURE__ */ n("path", { d: "M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71" }), /* @__PURE__ */ n("path", { d: "M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71" })]
|
|
2823
2833
|
})
|
|
2824
|
-
}), rc = (e) => /* @__PURE__ */ n(
|
|
2834
|
+
}), rc = (e) => /* @__PURE__ */ n(x, {
|
|
2825
2835
|
...e,
|
|
2826
2836
|
children: /* @__PURE__ */ m("g", {
|
|
2827
2837
|
stroke: "currentColor",
|
|
@@ -2921,7 +2931,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2921
2931
|
}
|
|
2922
2932
|
const o = oc(e);
|
|
2923
2933
|
e.chain().focus().setTextSelection(o).setLink({ href: r }).run();
|
|
2924
|
-
}, Br = (e) => /* @__PURE__ */ n(
|
|
2934
|
+
}, Br = (e) => /* @__PURE__ */ n(x, {
|
|
2925
2935
|
...e,
|
|
2926
2936
|
children: /* @__PURE__ */ m("g", {
|
|
2927
2937
|
stroke: "currentColor",
|
|
@@ -2934,7 +2944,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2934
2944
|
/* @__PURE__ */ n("path", { d: "M19 19H5" })
|
|
2935
2945
|
]
|
|
2936
2946
|
})
|
|
2937
|
-
}), Vr = (e) => /* @__PURE__ */ n(
|
|
2947
|
+
}), Vr = (e) => /* @__PURE__ */ n(x, {
|
|
2938
2948
|
...e,
|
|
2939
2949
|
children: /* @__PURE__ */ m("g", {
|
|
2940
2950
|
stroke: "currentColor",
|
|
@@ -2947,7 +2957,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2947
2957
|
/* @__PURE__ */ n("path", { d: "M21 19H7" })
|
|
2948
2958
|
]
|
|
2949
2959
|
})
|
|
2950
|
-
}), Gr = (e) => /* @__PURE__ */ n(
|
|
2960
|
+
}), Gr = (e) => /* @__PURE__ */ n(x, {
|
|
2951
2961
|
...e,
|
|
2952
2962
|
children: /* @__PURE__ */ m("g", {
|
|
2953
2963
|
stroke: "currentColor",
|
|
@@ -2984,7 +2994,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
2984
2994
|
})] });
|
|
2985
2995
|
}, gc = ({ editor: e, activeAlignment: t = "left" }) => {
|
|
2986
2996
|
const r = k();
|
|
2987
|
-
return /* @__PURE__ */ m(
|
|
2997
|
+
return /* @__PURE__ */ m(j, { children: [
|
|
2988
2998
|
/* @__PURE__ */ n(we, {
|
|
2989
2999
|
label: r("graph.toolbar.textAlign.left"),
|
|
2990
3000
|
isActive: t === "left",
|
|
@@ -3158,7 +3168,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
3158
3168
|
return /* @__PURE__ */ n($r, {
|
|
3159
3169
|
editor: Ft({
|
|
3160
3170
|
content: e,
|
|
3161
|
-
extensions:
|
|
3171
|
+
extensions: M(() => us({ placeholder: "Add caption" }), []),
|
|
3162
3172
|
isEditable: !0,
|
|
3163
3173
|
onUpdate: (r) => {
|
|
3164
3174
|
const a = ac(r) ? null : r;
|
|
@@ -3177,7 +3187,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
3177
3187
|
placeholder: ({ pos: t }) => t === 0 ? e : ""
|
|
3178
3188
|
})
|
|
3179
3189
|
], Ic = ({ annotation: e }) => {
|
|
3180
|
-
const t = k(), { dispatch: r } = se(), a = U(), o =
|
|
3190
|
+
const t = k(), { dispatch: r } = se(), a = U(), o = M(() => Pc(t("graph.annotations.text.placeholder")), [t]), i = Ft({
|
|
3181
3191
|
content: e.content,
|
|
3182
3192
|
extensions: o,
|
|
3183
3193
|
isEditable: !0,
|
|
@@ -3224,13 +3234,13 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
3224
3234
|
}
|
|
3225
3235
|
}];
|
|
3226
3236
|
}
|
|
3227
|
-
}),
|
|
3237
|
+
}), Mc = 3, Nc = ({ title: e, isTitleVisible: t, subtitle: r, isSubtitleVisible: a }) => {
|
|
3228
3238
|
const o = [];
|
|
3229
3239
|
return t && o.push({
|
|
3230
3240
|
type: "heading",
|
|
3231
|
-
attrs: { level:
|
|
3232
|
-
content:
|
|
3233
|
-
}), a && o.push(...
|
|
3241
|
+
attrs: { level: Mc },
|
|
3242
|
+
content: Rc(e)
|
|
3243
|
+
}), a && o.push(...Dc(r)), {
|
|
3234
3244
|
type: "doc",
|
|
3235
3245
|
content: o
|
|
3236
3246
|
};
|
|
@@ -3246,10 +3256,10 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
3246
3256
|
...e.text !== void 0 ? { text: e.text } : {},
|
|
3247
3257
|
...e.marks !== void 0 ? { marks: e.marks } : {},
|
|
3248
3258
|
...e.attrs !== void 0 ? { attrs: e.attrs } : {}
|
|
3249
|
-
}),
|
|
3259
|
+
}), Rc = (e) => e === null ? [] : typeof e == "string" ? e === "" ? [] : [{
|
|
3250
3260
|
type: "text",
|
|
3251
3261
|
text: e
|
|
3252
|
-
}] : e.type === "doc" && e.content ? e.content.flatMap((t) => t.content ?? []) : e.type === "text" || e.type === "hardBreak" ? [e] : e.content ?? [],
|
|
3262
|
+
}] : e.type === "doc" && e.content ? e.content.flatMap((t) => t.content ?? []) : e.type === "text" || e.type === "hardBreak" ? [e] : e.content ?? [], Dc = (e) => e === null ? [{ type: "paragraph" }] : typeof e == "string" ? e === "" ? [{ type: "paragraph" }] : [{
|
|
3253
3263
|
type: "paragraph",
|
|
3254
3264
|
content: [{
|
|
3255
3265
|
type: "text",
|
|
@@ -3278,7 +3288,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
3278
3288
|
content: t.map(Ht)
|
|
3279
3289
|
};
|
|
3280
3290
|
}, Fc = ({ title: e, isTitleVisible: t, isSubtitleVisible: r, subtitle: a }) => {
|
|
3281
|
-
const { dispatch: o } = se(), i =
|
|
3291
|
+
const { dispatch: o } = se(), i = M(() => ds({
|
|
3282
3292
|
titlePlaceholder: "Untitled",
|
|
3283
3293
|
subtitlePlaceholder: "Untitled",
|
|
3284
3294
|
isTitleVisible: t,
|
|
@@ -3286,7 +3296,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
3286
3296
|
}), [t, r]);
|
|
3287
3297
|
return /* @__PURE__ */ n($r, {
|
|
3288
3298
|
editor: Ft({
|
|
3289
|
-
content:
|
|
3299
|
+
content: M(() => Nc({
|
|
3290
3300
|
title: e,
|
|
3291
3301
|
isTitleVisible: t,
|
|
3292
3302
|
subtitle: a,
|
|
@@ -3313,9 +3323,9 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
3313
3323
|
}, Bc = "data-graphy-chart-chrome", Vc = "data-graphy-chart-menu", Ur = { [Vc]: "" }, ot = (e) => ({ [Bc]: e }), $e = (e, t) => e instanceof Element && e.closest(`[data-graphy-chart-chrome="${CSS.escape(t)}"]`) !== null, Gc = (e) => e instanceof Element && e.closest("[data-graphy-chart-menu]") !== null, xt = (e) => e instanceof Element && e.closest("[data-graphy-chart-chrome]") !== null, Wr = (e, t, r) => r !== null && mr({
|
|
3314
3324
|
x: e.clientX - t.x,
|
|
3315
3325
|
y: e.clientY - t.y
|
|
3316
|
-
}, r),
|
|
3326
|
+
}, r), Me = (e, t, r) => e instanceof Node && (t.contains(e) || $e(e, r)), $c = "cml7ha0", Kr = Oe(null), Uc = ({ children: e }) => {
|
|
3317
3327
|
const { chartId: t } = G(), [r] = Q(le), [a, o] = Q(null);
|
|
3318
|
-
return r === null ? null : /* @__PURE__ */ m(
|
|
3328
|
+
return r === null ? null : /* @__PURE__ */ m(j, { children: [fr(/* @__PURE__ */ n("div", {
|
|
3319
3329
|
ref: o,
|
|
3320
3330
|
className: $c,
|
|
3321
3331
|
...ot(t)
|
|
@@ -3323,7 +3333,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
3323
3333
|
value: a,
|
|
3324
3334
|
children: e
|
|
3325
3335
|
})] });
|
|
3326
|
-
}, Bt = () => Le(Kr), qr = (e) => /* @__PURE__ */ m(
|
|
3336
|
+
}, Bt = () => Le(Kr), qr = (e) => /* @__PURE__ */ m(x, {
|
|
3327
3337
|
viewBox: "0 0 16 16",
|
|
3328
3338
|
...e,
|
|
3329
3339
|
children: [
|
|
@@ -3349,7 +3359,7 @@ var Lr = "d0bl03", ms = "d0bl04", Pr = "d0bl05", Ct = "d0bl06", gs = "d0bl07", v
|
|
|
3349
3359
|
})
|
|
3350
3360
|
]
|
|
3351
3361
|
});
|
|
3352
|
-
var
|
|
3362
|
+
var Zr = "efjmb40", Xr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb44", Kc = "efjmb45", qc = /* @__PURE__ */ new Set([
|
|
3353
3363
|
"item-press",
|
|
3354
3364
|
"escape-key",
|
|
3355
3365
|
"outside-press",
|
|
@@ -3363,7 +3373,7 @@ var Xr = "efjmb40", jr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb4
|
|
|
3363
3373
|
return /* @__PURE__ */ m(me.SubmenuRoot, {
|
|
3364
3374
|
open: i,
|
|
3365
3375
|
onOpenChange: s,
|
|
3366
|
-
children: [/* @__PURE__ */ n(
|
|
3376
|
+
children: [/* @__PURE__ */ n(Zc, {
|
|
3367
3377
|
label: e,
|
|
3368
3378
|
icon: t
|
|
3369
3379
|
}), /* @__PURE__ */ n(me.Portal, {
|
|
@@ -3372,16 +3382,16 @@ var Xr = "efjmb40", jr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb4
|
|
|
3372
3382
|
side: "right",
|
|
3373
3383
|
align: "start",
|
|
3374
3384
|
sideOffset: 4,
|
|
3375
|
-
className:
|
|
3385
|
+
className: Zr,
|
|
3376
3386
|
...Ur,
|
|
3377
3387
|
children: /* @__PURE__ */ n(me.Popup, {
|
|
3378
|
-
className:
|
|
3388
|
+
className: Xr,
|
|
3379
3389
|
children: a
|
|
3380
3390
|
})
|
|
3381
3391
|
}) })
|
|
3382
3392
|
})]
|
|
3383
3393
|
});
|
|
3384
|
-
},
|
|
3394
|
+
}, Zc = ({ label: e, icon: t }) => /* @__PURE__ */ m(me.SubmenuTrigger, {
|
|
3385
3395
|
className: be,
|
|
3386
3396
|
openOnHover: !1,
|
|
3387
3397
|
children: [
|
|
@@ -3392,10 +3402,10 @@ var Xr = "efjmb40", jr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb4
|
|
|
3392
3402
|
}),
|
|
3393
3403
|
/* @__PURE__ */ n("span", {
|
|
3394
3404
|
className: Kc,
|
|
3395
|
-
children: /* @__PURE__ */ n(
|
|
3405
|
+
children: /* @__PURE__ */ n(Re, { size: "sm" })
|
|
3396
3406
|
})
|
|
3397
3407
|
]
|
|
3398
|
-
}),
|
|
3408
|
+
}), Xc = "_1qe7q450", jc = "_1qe7q451", Yc = "_1qe7q452", Jc = ({ label: e, placeholder: t, addLabel: r, at: a, onRequestClose: o }) => {
|
|
3399
3409
|
const i = te(null), [l, s] = Q(""), { dispatch: c } = se(), u = l.trim(), d = () => {
|
|
3400
3410
|
u.length !== 0 && (c(new pe({
|
|
3401
3411
|
kind: "comment",
|
|
@@ -3412,10 +3422,10 @@ var Xr = "efjmb40", jr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb4
|
|
|
3412
3422
|
requestAnimationFrame(() => i.current?.focus());
|
|
3413
3423
|
},
|
|
3414
3424
|
children: /* @__PURE__ */ m("div", {
|
|
3415
|
-
className:
|
|
3425
|
+
className: Xc,
|
|
3416
3426
|
children: [/* @__PURE__ */ n("input", {
|
|
3417
3427
|
ref: i,
|
|
3418
|
-
className:
|
|
3428
|
+
className: jc,
|
|
3419
3429
|
value: l,
|
|
3420
3430
|
placeholder: t,
|
|
3421
3431
|
onChange: (g) => {
|
|
@@ -3442,7 +3452,7 @@ var Xr = "efjmb40", jr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb4
|
|
|
3442
3452
|
text: e
|
|
3443
3453
|
}]
|
|
3444
3454
|
}]
|
|
3445
|
-
}), ed = (e) => /* @__PURE__ */ n(
|
|
3455
|
+
}), ed = (e) => /* @__PURE__ */ n(x, {
|
|
3446
3456
|
viewBox: "0 0 15 14",
|
|
3447
3457
|
...e,
|
|
3448
3458
|
children: /* @__PURE__ */ n("path", {
|
|
@@ -3451,7 +3461,7 @@ var Xr = "efjmb40", jr = "efjmb41", be = "efjmb42", Ce = "efjmb43", Wc = "efjmb4
|
|
|
3451
3461
|
fillOpacity: "0.8"
|
|
3452
3462
|
})
|
|
3453
3463
|
}), td = "relative-difference", nd = ({ label: e, layer: t, at: r, onRequestClose: a }) => {
|
|
3454
|
-
const { dispatch: o } = se(), i = _((c) => c.coordSystem), l =
|
|
3464
|
+
const { dispatch: o } = se(), i = _((c) => c.coordSystem), l = M(() => dl({
|
|
3455
3465
|
layer: t,
|
|
3456
3466
|
at: r,
|
|
3457
3467
|
coordSystem: i
|
|
@@ -3532,7 +3542,7 @@ function rd(e, t) {
|
|
|
3532
3542
|
var ad = (e) => {
|
|
3533
3543
|
const t = Qi(e.mapping.x);
|
|
3534
3544
|
return t !== null && t !== Go.x;
|
|
3535
|
-
}, od = (e) => /* @__PURE__ */ m(
|
|
3545
|
+
}, od = (e) => /* @__PURE__ */ m(x, {
|
|
3536
3546
|
viewBox: "0 0 16 16",
|
|
3537
3547
|
...e,
|
|
3538
3548
|
children: [
|
|
@@ -3571,7 +3581,7 @@ var ad = (e) => {
|
|
|
3571
3581
|
rx: ".533"
|
|
3572
3582
|
})
|
|
3573
3583
|
]
|
|
3574
|
-
}), id = (e) => /* @__PURE__ */ m(
|
|
3584
|
+
}), id = (e) => /* @__PURE__ */ m(x, {
|
|
3575
3585
|
viewBox: "0 0 16 16",
|
|
3576
3586
|
...e,
|
|
3577
3587
|
children: [
|
|
@@ -3610,7 +3620,7 @@ var ad = (e) => {
|
|
|
3610
3620
|
rx: ".533"
|
|
3611
3621
|
})
|
|
3612
3622
|
]
|
|
3613
|
-
}), ld = (e) => /* @__PURE__ */ m(
|
|
3623
|
+
}), ld = (e) => /* @__PURE__ */ m(x, {
|
|
3614
3624
|
viewBox: "0 0 16 16",
|
|
3615
3625
|
...e,
|
|
3616
3626
|
children: [
|
|
@@ -3649,7 +3659,7 @@ var ad = (e) => {
|
|
|
3649
3659
|
rx: ".533"
|
|
3650
3660
|
})
|
|
3651
3661
|
]
|
|
3652
|
-
}), sd = (e) => /* @__PURE__ */ m(
|
|
3662
|
+
}), sd = (e) => /* @__PURE__ */ m(x, {
|
|
3653
3663
|
viewBox: "0 0 16 16",
|
|
3654
3664
|
...e,
|
|
3655
3665
|
children: [
|
|
@@ -3669,7 +3679,7 @@ var ad = (e) => {
|
|
|
3669
3679
|
d: "M11.733 10.074H16v5.408a.52.52 0 0 1-.518.518h-3.23a.52.52 0 0 1-.519-.518zM11.733 9.481H16V.52A.52.52 0 0 0 15.482 0h-3.23a.52.52 0 0 0-.519.519z"
|
|
3670
3680
|
})
|
|
3671
3681
|
]
|
|
3672
|
-
}), cd = (e) => /* @__PURE__ */ m(
|
|
3682
|
+
}), cd = (e) => /* @__PURE__ */ m(x, {
|
|
3673
3683
|
viewBox: "0 0 16 16",
|
|
3674
3684
|
...e,
|
|
3675
3685
|
children: [
|
|
@@ -3703,7 +3713,7 @@ var ad = (e) => {
|
|
|
3703
3713
|
d: "M5.29 6.62a1.3 1.3 0 0 1-.424-.075 1 1 0 0 1-.373-.244 1.2 1.2 0 0 1-.262-.45 2.1 2.1 0 0 1-.096-.699q0-.389.082-.693.083-.304.238-.514a1.05 1.05 0 0 1 .374-.322q.22-.11.492-.11.285 0 .505.112a.973.973 0 0 1 .526.744h-.54a.5.5 0 0 0-.17-.277.5.5 0 0 0-.321-.105.54.54 0 0 0-.485.273q-.168.273-.17.75h.021a.8.8 0 0 1 .188-.223.92.92 0 0 1 .569-.195.91.91 0 0 1 .813.477q.125.222.123.509 0 .297-.136.536a1 1 0 0 1-.383.372 1.15 1.15 0 0 1-.571.134m-.003-.443a.54.54 0 0 0 .288-.078.57.57 0 0 0 .2-.211.6.6 0 0 0 .073-.299.6.6 0 0 0-.07-.294.54.54 0 0 0-.484-.285.55.55 0 0 0-.403.173.596.596 0 0 0 .108.914.53.53 0 0 0 .288.08M6.88 6.579v-.396l1.05-1.03q.15-.15.25-.27a1 1 0 0 0 .151-.229.6.6 0 0 0 .05-.236.432.432 0 0 0-.244-.405.6.6 0 0 0-.258-.056q-.15 0-.261.062a.43.43 0 0 0-.175.173.56.56 0 0 0-.06.267H6.86q0-.288.132-.5a.9.9 0 0 1 .362-.33q.231-.117.532-.117.303 0 .534.114.23.114.358.312a.8.8 0 0 1 .128.452.9.9 0 0 1-.065.334q-.065.164-.229.363-.162.2-.456.483l-.522.53v.021h1.318v.458zM10.57 6.62a1.3 1.3 0 0 1-.423-.075 1 1 0 0 1-.373-.244 1.2 1.2 0 0 1-.263-.45 2.1 2.1 0 0 1-.096-.699q0-.389.083-.693t.238-.514a1.05 1.05 0 0 1 .374-.322q.219-.11.492-.11.285 0 .505.112a.973.973 0 0 1 .526.744h-.54a.5.5 0 0 0-.17-.277.5.5 0 0 0-.322-.105.54.54 0 0 0-.484.273q-.168.273-.17.75h.02a.8.8 0 0 1 .188-.223.92.92 0 0 1 .569-.195.91.91 0 0 1 .814.477q.125.222.123.509 0 .297-.136.536a1 1 0 0 1-.383.372 1.15 1.15 0 0 1-.572.134m-.002-.443a.54.54 0 0 0 .288-.078.57.57 0 0 0 .2-.211.6.6 0 0 0 .073-.299.6.6 0 0 0-.071-.294.54.54 0 0 0-.483-.285.54.54 0 0 0-.403.173.597.597 0 0 0 .107.914.53.53 0 0 0 .289.08"
|
|
3704
3714
|
})
|
|
3705
3715
|
]
|
|
3706
|
-
}), dd = (e) => /* @__PURE__ */ m(
|
|
3716
|
+
}), dd = (e) => /* @__PURE__ */ m(x, {
|
|
3707
3717
|
viewBox: "0 0 16 16",
|
|
3708
3718
|
...e,
|
|
3709
3719
|
children: [
|
|
@@ -3744,7 +3754,7 @@ var ad = (e) => {
|
|
|
3744
3754
|
fillOpacity: "0.8"
|
|
3745
3755
|
})
|
|
3746
3756
|
]
|
|
3747
|
-
}), ud = (e) => /* @__PURE__ */ m(
|
|
3757
|
+
}), ud = (e) => /* @__PURE__ */ m(x, {
|
|
3748
3758
|
viewBox: "0 0 16 16",
|
|
3749
3759
|
...e,
|
|
3750
3760
|
children: [
|
|
@@ -3766,7 +3776,7 @@ var ad = (e) => {
|
|
|
3766
3776
|
d: "M15.999 8a8 8 0 0 1-7.588 7.989l-.412.01V8z"
|
|
3767
3777
|
})
|
|
3768
3778
|
]
|
|
3769
|
-
}), hd = (e) => /* @__PURE__ */ m(
|
|
3779
|
+
}), hd = (e) => /* @__PURE__ */ m(x, {
|
|
3770
3780
|
viewBox: "0 0 16 16",
|
|
3771
3781
|
...e,
|
|
3772
3782
|
children: [
|
|
@@ -3827,7 +3837,7 @@ var ad = (e) => {
|
|
|
3827
3837
|
transform: "matrix(-1 0 0 1 15.933 .533)"
|
|
3828
3838
|
})
|
|
3829
3839
|
]
|
|
3830
|
-
}), pd = (e) => /* @__PURE__ */ m(
|
|
3840
|
+
}), pd = (e) => /* @__PURE__ */ m(x, {
|
|
3831
3841
|
viewBox: "0 0 16 16",
|
|
3832
3842
|
...e,
|
|
3833
3843
|
children: [
|
|
@@ -3898,10 +3908,10 @@ var ad = (e) => {
|
|
|
3898
3908
|
scatterPoint: hd,
|
|
3899
3909
|
scatterSeries: pd,
|
|
3900
3910
|
pieSlice: ud
|
|
3901
|
-
},
|
|
3911
|
+
}, jr = ({ labelKey: e }) => {
|
|
3902
3912
|
const t = md[e];
|
|
3903
3913
|
return /* @__PURE__ */ n(t, {});
|
|
3904
|
-
}, Yr = (e) => /* @__PURE__ */ m(
|
|
3914
|
+
}, Yr = (e) => /* @__PURE__ */ m(x, {
|
|
3905
3915
|
viewBox: "0 0 16 16",
|
|
3906
3916
|
...e,
|
|
3907
3917
|
children: [/* @__PURE__ */ n("path", {
|
|
@@ -3922,14 +3932,14 @@ var ad = (e) => {
|
|
|
3922
3932
|
children: t.map((o) => /* @__PURE__ */ m(me.Item, {
|
|
3923
3933
|
className: be,
|
|
3924
3934
|
onClick: () => r(o.scope),
|
|
3925
|
-
children: [/* @__PURE__ */ n(
|
|
3935
|
+
children: [/* @__PURE__ */ n(jr, { labelKey: o.labelKey }), /* @__PURE__ */ n("span", {
|
|
3926
3936
|
className: Ce,
|
|
3927
3937
|
children: a(`graph.annotations.highlights.labels.${o.labelKey}`)
|
|
3928
3938
|
})]
|
|
3929
3939
|
}, o.scope))
|
|
3930
3940
|
});
|
|
3931
3941
|
}, vd = ({ label: e, layer: t, observation: r, highlights: a, onRequestClose: o }) => {
|
|
3932
|
-
const i = k(), { dispatch: l } = se(), s = _((p) => p.coordSystem), c =
|
|
3942
|
+
const i = k(), { dispatch: l } = se(), s = _((p) => p.coordSystem), c = M(() => $i(t, r), [t, r]), u = M(() => rd(s, t), [s, t]), d = M(() => {
|
|
3933
3943
|
const p = new Set(a.map((g) => g.scope));
|
|
3934
3944
|
return u.filter((g) => !p.has(g.scope));
|
|
3935
3945
|
}, [u, a]), [h] = d;
|
|
@@ -3946,7 +3956,7 @@ var ad = (e) => {
|
|
|
3946
3956
|
return /* @__PURE__ */ m(me.Item, {
|
|
3947
3957
|
className: be,
|
|
3948
3958
|
onClick: () => v(h.scope),
|
|
3949
|
-
children: [/* @__PURE__ */ n(
|
|
3959
|
+
children: [/* @__PURE__ */ n(jr, { labelKey: h.labelKey }), /* @__PURE__ */ n("span", {
|
|
3950
3960
|
className: Ce,
|
|
3951
3961
|
children: p
|
|
3952
3962
|
})]
|
|
@@ -3965,7 +3975,7 @@ var ad = (e) => {
|
|
|
3965
3975
|
const { dispatch: a } = se(), o = t.at(-1);
|
|
3966
3976
|
if (o === void 0) return null;
|
|
3967
3977
|
const i = () => {
|
|
3968
|
-
a(new
|
|
3978
|
+
a(new Xo({ id: o.id })), r();
|
|
3969
3979
|
};
|
|
3970
3980
|
return /* @__PURE__ */ m(z.Item, {
|
|
3971
3981
|
className: be,
|
|
@@ -3977,7 +3987,7 @@ var ad = (e) => {
|
|
|
3977
3987
|
});
|
|
3978
3988
|
}, yd = (e, t) => {
|
|
3979
3989
|
const r = _((o) => o.spec.highlights), a = _((o) => o.config.parsingLocale);
|
|
3980
|
-
return
|
|
3990
|
+
return M(() => rl({
|
|
3981
3991
|
layer: e,
|
|
3982
3992
|
highlights: r,
|
|
3983
3993
|
observation: t,
|
|
@@ -3988,7 +3998,7 @@ var ad = (e) => {
|
|
|
3988
3998
|
t,
|
|
3989
3999
|
a
|
|
3990
4000
|
]);
|
|
3991
|
-
}, Qr = (e) => /* @__PURE__ */ m(
|
|
4001
|
+
}, Qr = (e) => /* @__PURE__ */ m(x, {
|
|
3992
4002
|
viewBox: "0 0 16 16",
|
|
3993
4003
|
...e,
|
|
3994
4004
|
children: [
|
|
@@ -4026,7 +4036,7 @@ var ad = (e) => {
|
|
|
4026
4036
|
children: e
|
|
4027
4037
|
})]
|
|
4028
4038
|
});
|
|
4029
|
-
}, ea = (e) => /* @__PURE__ */ m(
|
|
4039
|
+
}, ea = (e) => /* @__PURE__ */ m(x, {
|
|
4030
4040
|
viewBox: "0 0 16 16",
|
|
4031
4041
|
...e,
|
|
4032
4042
|
children: [
|
|
@@ -4116,7 +4126,7 @@ var ad = (e) => {
|
|
|
4116
4126
|
})
|
|
4117
4127
|
});
|
|
4118
4128
|
}, Pd = ({ interaction: e, panelOrigin: t }) => {
|
|
4119
|
-
const r = U(), a =
|
|
4129
|
+
const r = U(), a = X((i) => i.menuTrigger);
|
|
4120
4130
|
if (e.kind !== "menu" || a === null) return null;
|
|
4121
4131
|
const o = () => {
|
|
4122
4132
|
r.getState().releaseInteraction("menu");
|
|
@@ -4133,12 +4143,12 @@ var ad = (e) => {
|
|
|
4133
4143
|
onClose: o
|
|
4134
4144
|
});
|
|
4135
4145
|
}, Id = ({ trigger: e, layer: t, at: r, observation: a, onClose: o }) => {
|
|
4136
|
-
const i = k(), l = Bt(), s = _((C) => C.spec.annotations), c = _((C) => C.config.parsingLocale), u =
|
|
4146
|
+
const i = k(), l = Bt(), s = _((C) => C.spec.annotations), c = _((C) => C.config.parsingLocale), u = Md(), { x: d, y: h, radius: v } = e, p = M(() => Ed(d, h, v), [
|
|
4137
4147
|
d,
|
|
4138
4148
|
h,
|
|
4139
4149
|
v
|
|
4140
|
-
]), g = ol(s, r,
|
|
4141
|
-
!C &&
|
|
4150
|
+
]), g = ol(s, r, M(() => ji(t, c), [t, c])), f = g !== null && xd(g) ? g : null, y = yd(t, a), P = (C, A) => {
|
|
4151
|
+
!C && Nd(A.reason) && o();
|
|
4142
4152
|
};
|
|
4143
4153
|
return /* @__PURE__ */ n(z.Root, {
|
|
4144
4154
|
open: u,
|
|
@@ -4151,10 +4161,10 @@ var ad = (e) => {
|
|
|
4151
4161
|
side: "right",
|
|
4152
4162
|
align: "start",
|
|
4153
4163
|
sideOffset: 8,
|
|
4154
|
-
className:
|
|
4164
|
+
className: Zr,
|
|
4155
4165
|
...Ur,
|
|
4156
4166
|
children: /* @__PURE__ */ m(z.Popup, {
|
|
4157
|
-
className:
|
|
4167
|
+
className: Xr,
|
|
4158
4168
|
"data-testid": "observation-menu",
|
|
4159
4169
|
children: [
|
|
4160
4170
|
f !== null && /* @__PURE__ */ n(wd, {
|
|
@@ -4167,7 +4177,7 @@ var ad = (e) => {
|
|
|
4167
4177
|
onRequestClose: o
|
|
4168
4178
|
}),
|
|
4169
4179
|
/* @__PURE__ */ n(z.Separator, { className: Wc }),
|
|
4170
|
-
f === null && /* @__PURE__ */ m(
|
|
4180
|
+
f === null && /* @__PURE__ */ m(j, { children: [
|
|
4171
4181
|
/* @__PURE__ */ n(Sd, {
|
|
4172
4182
|
label: i("graph.annotations.baseMenu.pinNumber"),
|
|
4173
4183
|
at: r,
|
|
@@ -4204,12 +4214,12 @@ var ad = (e) => {
|
|
|
4204
4214
|
}) })
|
|
4205
4215
|
})
|
|
4206
4216
|
});
|
|
4207
|
-
}, Ed = (e, t, r) => ({ getBoundingClientRect: () => new DOMRect(e - r, t - r, r * 2, r * 2) }),
|
|
4217
|
+
}, Ed = (e, t, r) => ({ getBoundingClientRect: () => new DOMRect(e - r, t - r, r * 2, r * 2) }), Md = () => {
|
|
4208
4218
|
const [e, t] = Q(!1);
|
|
4209
4219
|
return O(() => {
|
|
4210
4220
|
t(!0);
|
|
4211
4221
|
}, []), e;
|
|
4212
|
-
},
|
|
4222
|
+
}, Nd = (e) => e === "outside-press" || e === "escape-key" || e === "item-press", Gt = "l8tsqe0", na = ["start", "end"], ra = ({ anchor: e, point: t, delta: r }) => {
|
|
4213
4223
|
const a = {
|
|
4214
4224
|
x: fn(t.x, r.x),
|
|
4215
4225
|
y: fn(1 - t.y, r.y)
|
|
@@ -4237,7 +4247,7 @@ var ad = (e) => {
|
|
|
4237
4247
|
x: t.x + r.x,
|
|
4238
4248
|
y: t.y + r.y
|
|
4239
4249
|
};
|
|
4240
|
-
},
|
|
4250
|
+
}, Rd = (e, t, r) => {
|
|
4241
4251
|
const a = Ue(e, r), o = Ue(t, r);
|
|
4242
4252
|
return {
|
|
4243
4253
|
x: Math.min(a.x, o.x),
|
|
@@ -4245,8 +4255,8 @@ var ad = (e) => {
|
|
|
4245
4255
|
width: Math.abs(o.x - a.x),
|
|
4246
4256
|
height: Math.abs(o.y - a.y)
|
|
4247
4257
|
};
|
|
4248
|
-
}, fn = (e, t) => !Number.isFinite(t) || !Number.isFinite(e) ? 0 : Ke(t, Math.min(-e, 0), Math.max(1 - e, 0)),
|
|
4249
|
-
const t =
|
|
4258
|
+
}, fn = (e, t) => !Number.isFinite(t) || !Number.isFinite(e) ? 0 : Ke(t, Math.min(-e, 0), Math.max(1 - e, 0)), Dd = ({ panelRect: e }) => {
|
|
4259
|
+
const t = X((s) => V(s, "arrow-endpoint-drag")), r = fe(e).arrows, a = Nt();
|
|
4250
4260
|
if (t === null) return null;
|
|
4251
4261
|
const o = r.find((s) => s.id === t.annotationId);
|
|
4252
4262
|
if (o === void 0) return null;
|
|
@@ -4273,14 +4283,14 @@ var ad = (e) => {
|
|
|
4273
4283
|
isAddressable: !1
|
|
4274
4284
|
})
|
|
4275
4285
|
});
|
|
4276
|
-
},
|
|
4286
|
+
}, De = () => {
|
|
4277
4287
|
const e = Jn();
|
|
4278
4288
|
return wt(e);
|
|
4279
4289
|
}, wt = (e) => {
|
|
4280
4290
|
if (e.length !== 1) return null;
|
|
4281
4291
|
const [t] = e;
|
|
4282
4292
|
return t?.kind === "annotation" ? t.id : null;
|
|
4283
|
-
}, zd = (e) => /* @__PURE__ */ n(
|
|
4293
|
+
}, zd = (e) => /* @__PURE__ */ n(x, {
|
|
4284
4294
|
...e,
|
|
4285
4295
|
children: /* @__PURE__ */ m("g", {
|
|
4286
4296
|
stroke: "currentColor",
|
|
@@ -4289,7 +4299,7 @@ var ad = (e) => {
|
|
|
4289
4299
|
strokeLinejoin: "round",
|
|
4290
4300
|
children: [/* @__PURE__ */ n("path", { d: "m12 19-7-7 7-7" }), /* @__PURE__ */ n("path", { d: "M19 12H5" })]
|
|
4291
4301
|
})
|
|
4292
|
-
}), oa = (e) => /* @__PURE__ */ n(
|
|
4302
|
+
}), oa = (e) => /* @__PURE__ */ n(x, {
|
|
4293
4303
|
...e,
|
|
4294
4304
|
children: /* @__PURE__ */ m("g", {
|
|
4295
4305
|
stroke: "currentColor",
|
|
@@ -4298,7 +4308,7 @@ var ad = (e) => {
|
|
|
4298
4308
|
strokeLinejoin: "round",
|
|
4299
4309
|
children: [/* @__PURE__ */ n("path", { d: "M5 12h14" }), /* @__PURE__ */ n("path", { d: "m12 5 7 7-7 7" })]
|
|
4300
4310
|
})
|
|
4301
|
-
}), _d = (e) => /* @__PURE__ */ n(
|
|
4311
|
+
}), _d = (e) => /* @__PURE__ */ n(x, {
|
|
4302
4312
|
...e,
|
|
4303
4313
|
children: /* @__PURE__ */ m("g", {
|
|
4304
4314
|
stroke: "currentColor",
|
|
@@ -4307,7 +4317,7 @@ var ad = (e) => {
|
|
|
4307
4317
|
strokeLinejoin: "round",
|
|
4308
4318
|
children: [/* @__PURE__ */ n("path", { d: "M7 17 17 7" }), /* @__PURE__ */ n("path", { d: "M7 7h10v10" })]
|
|
4309
4319
|
})
|
|
4310
|
-
}), ia = (e) => /* @__PURE__ */ n(
|
|
4320
|
+
}), ia = (e) => /* @__PURE__ */ n(x, {
|
|
4311
4321
|
...e,
|
|
4312
4322
|
children: /* @__PURE__ */ m("g", {
|
|
4313
4323
|
fill: "currentColor",
|
|
@@ -4335,7 +4345,7 @@ var ad = (e) => {
|
|
|
4335
4345
|
})
|
|
4336
4346
|
]
|
|
4337
4347
|
})
|
|
4338
|
-
}), it = (e) => /* @__PURE__ */ n(
|
|
4348
|
+
}), it = (e) => /* @__PURE__ */ n(x, {
|
|
4339
4349
|
...e,
|
|
4340
4350
|
children: /* @__PURE__ */ m("g", {
|
|
4341
4351
|
stroke: "currentColor",
|
|
@@ -4383,7 +4393,7 @@ var ad = (e) => {
|
|
|
4383
4393
|
children: l
|
|
4384
4394
|
})
|
|
4385
4395
|
});
|
|
4386
|
-
},
|
|
4396
|
+
}, Zd = ({ label: e, trigger: t, isOpen: r, onOpenChange: a, isDisabled: o = !1, children: i }) => {
|
|
4387
4397
|
const { chartId: l } = G();
|
|
4388
4398
|
return /* @__PURE__ */ m(z.Root, {
|
|
4389
4399
|
open: r,
|
|
@@ -4395,19 +4405,19 @@ var ad = (e) => {
|
|
|
4395
4405
|
className: Wd,
|
|
4396
4406
|
disabled: o,
|
|
4397
4407
|
onMouseDown: (s) => s.preventDefault(),
|
|
4398
|
-
children: [t, /* @__PURE__ */ n(
|
|
4408
|
+
children: [t, /* @__PURE__ */ n(Re, { size: "sm" })]
|
|
4399
4409
|
}), /* @__PURE__ */ n(K.MenuPopup, {
|
|
4400
4410
|
popupAttributes: ot(l),
|
|
4401
4411
|
children: i
|
|
4402
4412
|
})]
|
|
4403
4413
|
});
|
|
4404
|
-
},
|
|
4414
|
+
}, Xd = (e) => {
|
|
4405
4415
|
const { chartId: t } = G();
|
|
4406
4416
|
return /* @__PURE__ */ n(K.ColorPicker, {
|
|
4407
4417
|
...e,
|
|
4408
4418
|
popupAttributes: ot(t)
|
|
4409
4419
|
});
|
|
4410
|
-
},
|
|
4420
|
+
}, jd = ({ color: e, opacity: t }) => /* @__PURE__ */ n("span", {
|
|
4411
4421
|
className: Gd,
|
|
4412
4422
|
style: {
|
|
4413
4423
|
background: e,
|
|
@@ -4426,10 +4436,10 @@ var ad = (e) => {
|
|
|
4426
4436
|
children: a
|
|
4427
4437
|
}), I = {
|
|
4428
4438
|
Root: qd,
|
|
4429
|
-
Dropdown:
|
|
4439
|
+
Dropdown: Zd,
|
|
4430
4440
|
MenuItem: K.MenuItem,
|
|
4431
|
-
ColorPicker:
|
|
4432
|
-
Swatch:
|
|
4441
|
+
ColorPicker: Xd,
|
|
4442
|
+
Swatch: jd,
|
|
4433
4443
|
IconButton: Yd,
|
|
4434
4444
|
ToggleButton: Jd,
|
|
4435
4445
|
Button: K.Button,
|
|
@@ -4450,7 +4460,7 @@ var ad = (e) => {
|
|
|
4450
4460
|
}),
|
|
4451
4461
|
close: o
|
|
4452
4462
|
};
|
|
4453
|
-
}, eu = (e) => /* @__PURE__ */ n(
|
|
4463
|
+
}, eu = (e) => /* @__PURE__ */ n(x, {
|
|
4454
4464
|
...e,
|
|
4455
4465
|
children: /* @__PURE__ */ m("g", {
|
|
4456
4466
|
stroke: "currentColor",
|
|
@@ -4462,7 +4472,7 @@ var ad = (e) => {
|
|
|
4462
4472
|
/* @__PURE__ */ n("path", { d: "M16 8 19 5" })
|
|
4463
4473
|
]
|
|
4464
4474
|
})
|
|
4465
|
-
}), tu = (e) => /* @__PURE__ */ n(
|
|
4475
|
+
}), tu = (e) => /* @__PURE__ */ n(x, {
|
|
4466
4476
|
...e,
|
|
4467
4477
|
children: /* @__PURE__ */ m("g", {
|
|
4468
4478
|
stroke: "currentColor",
|
|
@@ -4476,7 +4486,7 @@ var ad = (e) => {
|
|
|
4476
4486
|
/* @__PURE__ */ n("path", { d: "M19 5h0" })
|
|
4477
4487
|
]
|
|
4478
4488
|
})
|
|
4479
|
-
}), nu = (e) => /* @__PURE__ */ n(
|
|
4489
|
+
}), nu = (e) => /* @__PURE__ */ n(x, {
|
|
4480
4490
|
...e,
|
|
4481
4491
|
children: /* @__PURE__ */ n("path", {
|
|
4482
4492
|
d: "M5 19 19 5",
|
|
@@ -4523,22 +4533,22 @@ var ad = (e) => {
|
|
|
4523
4533
|
}
|
|
4524
4534
|
], au = (e, t) => e.find((r) => r.value === t) ?? e[0];
|
|
4525
4535
|
var ou = ({ arrow: e, arrowBox: t, panelRect: r, frameWidth: a, frameHeight: o, frameElement: i }) => {
|
|
4526
|
-
const l = k(), { commands: s } = G(), c = _((E) => E.spec.styles.overrides), u = lt(), d =
|
|
4536
|
+
const l = k(), { commands: s } = G(), c = _((E) => E.spec.styles.overrides), u = lt(), d = Nt()(e.id), h = au(Cn, d.lineType), v = d.borderWidth > 0 || d.shadow !== "none", p = M(() => ({
|
|
4527
4537
|
target: "annotation",
|
|
4528
4538
|
kind: "arrow",
|
|
4529
4539
|
annotation: e.id
|
|
4530
|
-
}), [e.id]), g = (E,
|
|
4531
|
-
const
|
|
4532
|
-
s.dispatch(new
|
|
4540
|
+
}), [e.id]), g = (E, N) => {
|
|
4541
|
+
const T = Te(c, { select: p })?.declarations ?? {};
|
|
4542
|
+
s.dispatch(new Ne({
|
|
4533
4543
|
list: "overrides",
|
|
4534
4544
|
rule: {
|
|
4535
4545
|
select: p,
|
|
4536
4546
|
declarations: {
|
|
4537
|
-
...
|
|
4547
|
+
...T,
|
|
4538
4548
|
...E
|
|
4539
4549
|
}
|
|
4540
4550
|
}
|
|
4541
|
-
}),
|
|
4551
|
+
}), N);
|
|
4542
4552
|
}, f = (E) => {
|
|
4543
4553
|
g(E), u.close();
|
|
4544
4554
|
}, y = (E) => {
|
|
@@ -4549,7 +4559,7 @@ var ou = ({ arrow: e, arrowBox: t, panelRect: r, frameWidth: a, frameHeight: o,
|
|
|
4549
4559
|
})), u.close();
|
|
4550
4560
|
}, P = () => {
|
|
4551
4561
|
s.dispatch(new ke({ id: e.id })), i.focus({ preventScroll: !0 });
|
|
4552
|
-
}, C = (E) => g({ color: E }, { transient: !0 }), A = (E) => f({ strokeWidth: E }), L = (E) => y({ startArrowheadStyle: E }),
|
|
4562
|
+
}, C = (E) => g({ color: E }, { transient: !0 }), A = (E) => f({ strokeWidth: E }), L = (E) => y({ startArrowheadStyle: E }), R = (E) => f({ lineType: E }), F = (E) => y({ endArrowheadStyle: E }), D = () => g(v ? {
|
|
4553
4563
|
borderWidth: 0,
|
|
4554
4564
|
shadow: "none"
|
|
4555
4565
|
} : Bo);
|
|
@@ -4604,7 +4614,7 @@ var ou = ({ arrow: e, arrowBox: t, panelRect: r, frameWidth: a, frameHeight: o,
|
|
|
4604
4614
|
children: /* @__PURE__ */ n(Be, {
|
|
4605
4615
|
options: Cn,
|
|
4606
4616
|
current: d.lineType,
|
|
4607
|
-
onPick:
|
|
4617
|
+
onPick: R
|
|
4608
4618
|
})
|
|
4609
4619
|
}),
|
|
4610
4620
|
/* @__PURE__ */ n(I.Dropdown, {
|
|
@@ -4623,7 +4633,7 @@ var ou = ({ arrow: e, arrowBox: t, panelRect: r, frameWidth: a, frameHeight: o,
|
|
|
4623
4633
|
/* @__PURE__ */ n(I.ToggleButton, {
|
|
4624
4634
|
label: l("graph.annotations.arrowToolbar.sticker"),
|
|
4625
4635
|
isPressed: v,
|
|
4626
|
-
onClick:
|
|
4636
|
+
onClick: D,
|
|
4627
4637
|
children: /* @__PURE__ */ n(_d, {
|
|
4628
4638
|
size: "sm",
|
|
4629
4639
|
title: ""
|
|
@@ -4642,7 +4652,7 @@ var ou = ({ arrow: e, arrowBox: t, panelRect: r, frameWidth: a, frameHeight: o,
|
|
|
4642
4652
|
});
|
|
4643
4653
|
}, Be = ({ options: e, current: t, onPick: r }) => {
|
|
4644
4654
|
const a = k(), o = (i) => () => r(i);
|
|
4645
|
-
return /* @__PURE__ */ n(
|
|
4655
|
+
return /* @__PURE__ */ n(j, { children: e.map((i) => /* @__PURE__ */ m(I.MenuItem, {
|
|
4646
4656
|
isSelected: i.value === t,
|
|
4647
4657
|
onClick: o(i.value),
|
|
4648
4658
|
children: [/* @__PURE__ */ n("span", { children: a(i.key) }), i.Icon !== void 0 && /* @__PURE__ */ n("span", {
|
|
@@ -4706,7 +4716,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
|
|
|
4706
4716
|
cancelFrame() {
|
|
4707
4717
|
this.scheduledFrame !== null && (cancelAnimationFrame(this.scheduledFrame), this.scheduledFrame = null);
|
|
4708
4718
|
}
|
|
4709
|
-
},
|
|
4719
|
+
}, Ze = (e, t, r) => {
|
|
4710
4720
|
const a = e.arrows.find((i) => i.id === t);
|
|
4711
4721
|
if (a === void 0) return null;
|
|
4712
4722
|
const o = a[r];
|
|
@@ -4717,10 +4727,10 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
|
|
|
4717
4727
|
}
|
|
4718
4728
|
readOwn(e) {
|
|
4719
4729
|
const { annotationId: t, endpoint: r } = this.params;
|
|
4720
|
-
return
|
|
4730
|
+
return Mt(V(e, "arrow-endpoint-drag"), t, r);
|
|
4721
4731
|
}
|
|
4722
4732
|
resolvePreview(e) {
|
|
4723
|
-
const { annotationId: t, endpoint: r, press: a, readInputs: o } = this.params, { annotations: i, arrow: l, panelRect: s } = o(), c =
|
|
4733
|
+
const { annotationId: t, endpoint: r, press: a, readInputs: o } = this.params, { annotations: i, arrow: l, panelRect: s } = o(), c = Ze(i, t, r);
|
|
4724
4734
|
return c === null ? null : {
|
|
4725
4735
|
kind: "arrow-endpoint-drag",
|
|
4726
4736
|
annotationId: t,
|
|
@@ -4733,7 +4743,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
|
|
|
4733
4743
|
};
|
|
4734
4744
|
}
|
|
4735
4745
|
commit({ anchor: e }) {
|
|
4736
|
-
const { annotationId: t, endpoint: r, dispatch: a, readInputs: o } = this.params, i =
|
|
4746
|
+
const { annotationId: t, endpoint: r, dispatch: a, readInputs: o } = this.params, i = Ze(o().annotations, t, r);
|
|
4737
4747
|
i === null || aa(i, e) || a(new re({
|
|
4738
4748
|
kind: "arrow",
|
|
4739
4749
|
id: t,
|
|
@@ -4793,7 +4803,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
|
|
|
4793
4803
|
s
|
|
4794
4804
|
]), ie((c) => ({ onKeyDown: (u) => {
|
|
4795
4805
|
if (u.altKey || u.ctrlKey || u.metaKey || u.shiftKey) return;
|
|
4796
|
-
const d = o.getState(), h =
|
|
4806
|
+
const d = o.getState(), h = Mt(V(d, "arrow-endpoint-drag"), e, c);
|
|
4797
4807
|
if (uu.includes(u.key)) {
|
|
4798
4808
|
if (u.preventDefault(), u.repeat) return;
|
|
4799
4809
|
if (h !== null) {
|
|
@@ -4806,7 +4816,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
|
|
|
4806
4816
|
});
|
|
4807
4817
|
return;
|
|
4808
4818
|
}
|
|
4809
|
-
const p =
|
|
4819
|
+
const p = Ze(i, e, c);
|
|
4810
4820
|
if (p === null) return;
|
|
4811
4821
|
d.claimInteraction({
|
|
4812
4822
|
kind: "arrow-endpoint-drag",
|
|
@@ -4838,10 +4848,10 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
|
|
|
4838
4848
|
a
|
|
4839
4849
|
]);
|
|
4840
4850
|
}, Sn = ({ editorStore: e, annotationId: t, endpoint: r, annotations: a, dispatch: o }) => {
|
|
4841
|
-
const i = e.getState(), l =
|
|
4851
|
+
const i = e.getState(), l = Mt(V(i, "arrow-endpoint-drag"), t, r);
|
|
4842
4852
|
if (l === null) return;
|
|
4843
4853
|
i.releaseInteraction("arrow-endpoint-drag");
|
|
4844
|
-
const s =
|
|
4854
|
+
const s = Ze(a, t, r);
|
|
4845
4855
|
s === null || aa(s, l.anchor) || o(new re({
|
|
4846
4856
|
kind: "arrow",
|
|
4847
4857
|
id: t,
|
|
@@ -4874,7 +4884,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
|
|
|
4874
4884
|
return null;
|
|
4875
4885
|
}
|
|
4876
4886
|
}, mu = (e) => {
|
|
4877
|
-
const t =
|
|
4887
|
+
const t = De(), r = fu(t), a = bu(e.panelRect, t), o = Cu(t);
|
|
4878
4888
|
if (r === null || a === null) return null;
|
|
4879
4889
|
const i = o.dragged === null ? a : $t(a, o.dragged);
|
|
4880
4890
|
return /* @__PURE__ */ n(gu, {
|
|
@@ -4900,7 +4910,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
|
|
|
4900
4910
|
"data-annotation-id": e.id,
|
|
4901
4911
|
children: [a && /* @__PURE__ */ n(ou, {
|
|
4902
4912
|
arrow: e,
|
|
4903
|
-
arrowBox:
|
|
4913
|
+
arrowBox: Rd(t.start, t.end, i),
|
|
4904
4914
|
panelRect: i,
|
|
4905
4915
|
frameWidth: l.width,
|
|
4906
4916
|
frameHeight: l.height,
|
|
@@ -4932,7 +4942,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
|
|
|
4932
4942
|
}, bu = (e, t) => {
|
|
4933
4943
|
const r = fe(e).arrows;
|
|
4934
4944
|
return t === null ? null : r.find((a) => a.id === t) ?? null;
|
|
4935
|
-
}, Cu = (e) =>
|
|
4945
|
+
}, Cu = (e) => X(Pe((t) => {
|
|
4936
4946
|
if (e === null) return {
|
|
4937
4947
|
dragged: null,
|
|
4938
4948
|
isMoved: !1
|
|
@@ -4942,7 +4952,7 @@ var su = (e, t) => Math.hypot(t.x - e.x, t.y - e.y) >= 3, ze = class {
|
|
|
4942
4952
|
dragged: r?.annotationId === e ? r : null,
|
|
4943
4953
|
isMoved: et(V(t, "move-drag"), e) !== null
|
|
4944
4954
|
};
|
|
4945
|
-
})), yu = (e) => /* @__PURE__ */ n(
|
|
4955
|
+
})), yu = (e) => /* @__PURE__ */ n(x, {
|
|
4946
4956
|
...e,
|
|
4947
4957
|
children: /* @__PURE__ */ m("g", {
|
|
4948
4958
|
stroke: "currentColor",
|
|
@@ -4962,7 +4972,7 @@ var Tu = [
|
|
|
4962
4972
|
proportion: "graph.annotations.differenceArrowToolbar.labelKind.proportion"
|
|
4963
4973
|
}, Lu = (e) => {
|
|
4964
4974
|
const { formattingLocale: t } = G(), r = _((o) => o.config.parsingLocale), a = t ?? r;
|
|
4965
|
-
return
|
|
4975
|
+
return M(() => {
|
|
4966
4976
|
const o = Bi(e.start, e.end);
|
|
4967
4977
|
return Tu.filter((i) => o || !xn.includes(i) || i === e.label).map((i) => ({
|
|
4968
4978
|
kind: i,
|
|
@@ -4992,30 +5002,30 @@ var Tu = [
|
|
|
4992
5002
|
key: "graph.annotations.differenceArrowToolbar.size.large"
|
|
4993
5003
|
}
|
|
4994
5004
|
], Pu = ({ arrow: e, color: t, labelBox: r, panelRect: a, frameWidth: o, frameHeight: i, frameElement: l }) => {
|
|
4995
|
-
const s = k(), { commands: c } = G(), u = _((b) => b.spec.styles.overrides), d = lt(), h = Lu(e), v = ho()(e.id), p =
|
|
5005
|
+
const s = k(), { commands: c } = G(), u = _((b) => b.spec.styles.overrides), d = lt(), h = Lu(e), v = ho()(e.id), p = M(() => ({
|
|
4996
5006
|
target: "annotation",
|
|
4997
5007
|
kind: "differenceArrow",
|
|
4998
5008
|
annotation: e.id
|
|
4999
|
-
}), [e.id]), g =
|
|
5009
|
+
}), [e.id]), g = M(() => ({
|
|
5000
5010
|
...p,
|
|
5001
5011
|
part: "label"
|
|
5002
|
-
}), [p]), f = h.find((b) => b.kind === e.label), y = h.some((b) => b.isPickable && b.kind !== e.label), P = wn.find((b) => nn[b.id].arrow.strokeWidth === v.strokeWidth), C = (b,
|
|
5012
|
+
}), [p]), f = h.find((b) => b.kind === e.label), y = h.some((b) => b.isPickable && b.kind !== e.label), P = wn.find((b) => nn[b.id].arrow.strokeWidth === v.strokeWidth), C = (b, Z) => {
|
|
5003
5013
|
c.dispatch(new re({
|
|
5004
5014
|
kind: "differenceArrow",
|
|
5005
5015
|
id: e.id,
|
|
5006
5016
|
patch: b
|
|
5007
|
-
}),
|
|
5017
|
+
}), Z);
|
|
5008
5018
|
}, A = (b) => ({
|
|
5009
5019
|
...Te(u, { select: p })?.declarations,
|
|
5010
5020
|
...b
|
|
5011
5021
|
}), L = (b) => ({
|
|
5012
5022
|
...Te(u, { select: g })?.declarations,
|
|
5013
5023
|
...b
|
|
5014
|
-
}),
|
|
5024
|
+
}), R = (b) => {
|
|
5015
5025
|
C(b), d.close();
|
|
5016
5026
|
}, F = () => {
|
|
5017
5027
|
c.dispatch(new ke({ id: e.id })), l.focus({ preventScroll: !0 });
|
|
5018
|
-
},
|
|
5028
|
+
}, D = (b) => c.dispatch(new Ne({
|
|
5019
5029
|
list: "overrides",
|
|
5020
5030
|
rule: {
|
|
5021
5031
|
select: p,
|
|
@@ -5024,12 +5034,12 @@ var Tu = [
|
|
|
5024
5034
|
}), { transient: !0 }), E = () => C({
|
|
5025
5035
|
start: e.end.anchor,
|
|
5026
5036
|
end: e.start.anchor
|
|
5027
|
-
}),
|
|
5028
|
-
const
|
|
5037
|
+
}), N = (b) => () => R({ label: b }), T = (b) => () => {
|
|
5038
|
+
const Z = nn[b];
|
|
5029
5039
|
c.dispatch(new li({
|
|
5030
5040
|
annotationId: e.id,
|
|
5031
|
-
arrow: A(
|
|
5032
|
-
label: L(
|
|
5041
|
+
arrow: A(Z.arrow),
|
|
5042
|
+
label: L(Z.label)
|
|
5033
5043
|
})), d.close();
|
|
5034
5044
|
};
|
|
5035
5045
|
return /* @__PURE__ */ m(I.Root, {
|
|
@@ -5048,7 +5058,7 @@ var Tu = [
|
|
|
5048
5058
|
children: h.map((b) => /* @__PURE__ */ m(I.MenuItem, {
|
|
5049
5059
|
isSelected: b.kind === e.label,
|
|
5050
5060
|
isDisabled: !b.isPickable,
|
|
5051
|
-
onClick:
|
|
5061
|
+
onClick: N(b.kind),
|
|
5052
5062
|
children: [
|
|
5053
5063
|
/* @__PURE__ */ n("span", { children: s(b.key) }),
|
|
5054
5064
|
(b.isSuspect || !b.isPickable) && /* @__PURE__ */ n("span", {
|
|
@@ -5068,7 +5078,7 @@ var Tu = [
|
|
|
5068
5078
|
/* @__PURE__ */ n(I.ColorPicker, {
|
|
5069
5079
|
color: t,
|
|
5070
5080
|
label: s("graph.annotations.differenceArrowToolbar.color"),
|
|
5071
|
-
onChange:
|
|
5081
|
+
onChange: D,
|
|
5072
5082
|
...d.bind("color"),
|
|
5073
5083
|
children: /* @__PURE__ */ n(I.Swatch, { color: t })
|
|
5074
5084
|
}),
|
|
@@ -5078,7 +5088,7 @@ var Tu = [
|
|
|
5078
5088
|
...d.bind("size"),
|
|
5079
5089
|
children: wn.map((b) => /* @__PURE__ */ n(I.MenuItem, {
|
|
5080
5090
|
isSelected: b.id === P?.id,
|
|
5081
|
-
onClick:
|
|
5091
|
+
onClick: T(b.id),
|
|
5082
5092
|
children: s(b.key)
|
|
5083
5093
|
}, b.id))
|
|
5084
5094
|
}),
|
|
@@ -5103,7 +5113,7 @@ var Tu = [
|
|
|
5103
5113
|
});
|
|
5104
5114
|
}, Iu = ({ option: e }) => {
|
|
5105
5115
|
const t = k();
|
|
5106
|
-
return e === void 0 ? null : /* @__PURE__ */ m(
|
|
5116
|
+
return e === void 0 ? null : /* @__PURE__ */ m(j, { children: [/* @__PURE__ */ n("span", {
|
|
5107
5117
|
className: xu,
|
|
5108
5118
|
children: t(e.key)
|
|
5109
5119
|
}), /* @__PURE__ */ m("span", {
|
|
@@ -5115,11 +5125,11 @@ var Tu = [
|
|
|
5115
5125
|
]
|
|
5116
5126
|
})] });
|
|
5117
5127
|
};
|
|
5118
|
-
var Eu = "ydgo3h0",
|
|
5119
|
-
const u =
|
|
5128
|
+
var Eu = "ydgo3h0", Mu = "ydgo3h1", Nu = "ydgo3h2", Ou = ({ clientPoint: e, panelOrigin: t, panelRect: r, engine: a, layers: o, coordSystem: i, resolver: l, fixedAnchor: s, align: c }) => {
|
|
5129
|
+
const u = Ru({
|
|
5120
5130
|
x: e.x - t.x,
|
|
5121
5131
|
y: e.y - t.y
|
|
5122
|
-
}, r), { primary: d } = a.query(
|
|
5132
|
+
}, r), { primary: d } = a.query(Dt(u, r));
|
|
5123
5133
|
if (d === null) return null;
|
|
5124
5134
|
const h = o.find((p) => p.id === d.layerId);
|
|
5125
5135
|
if (h === void 0) return null;
|
|
@@ -5132,7 +5142,7 @@ var Eu = "ydgo3h0", Nu = "ydgo3h1", Mu = "ydgo3h2", Ou = ({ clientPoint: e, pane
|
|
|
5132
5142
|
align: c
|
|
5133
5143
|
});
|
|
5134
5144
|
return v === null || dr(v.anchor, s) ? null : v;
|
|
5135
|
-
},
|
|
5145
|
+
}, Ru = (e, t) => ({
|
|
5136
5146
|
x: Math.max(0, Math.min(e.x, t.width)),
|
|
5137
5147
|
y: Math.max(0, Math.min(e.y, t.height))
|
|
5138
5148
|
}), ca = (e) => e === "start" ? "end" : "start", da = ({ dispatch: e, arrow: t, endpoint: r, anchor: a }) => {
|
|
@@ -5141,7 +5151,7 @@ var Eu = "ydgo3h0", Nu = "ydgo3h1", Mu = "ydgo3h2", Ou = ({ clientPoint: e, pane
|
|
|
5141
5151
|
id: t.id,
|
|
5142
5152
|
patch: { [r]: a }
|
|
5143
5153
|
}));
|
|
5144
|
-
},
|
|
5154
|
+
}, Du = class extends ze {
|
|
5145
5155
|
constructor(...e) {
|
|
5146
5156
|
super(...e), this.kind = "difference-arrow-endpoint-drag";
|
|
5147
5157
|
}
|
|
@@ -5197,7 +5207,7 @@ var Eu = "ydgo3h0", Nu = "ydgo3h1", Mu = "ydgo3h2", Ou = ({ clientPoint: e, pane
|
|
|
5197
5207
|
} catch {
|
|
5198
5208
|
return;
|
|
5199
5209
|
}
|
|
5200
|
-
d.currentTarget.focus({ preventScroll: !0 }), d.preventDefault(), c.current = new
|
|
5210
|
+
d.currentTarget.focus({ preventScroll: !0 }), d.preventDefault(), c.current = new Du({
|
|
5201
5211
|
handle: d.currentTarget,
|
|
5202
5212
|
pointerId: d.pointerId,
|
|
5203
5213
|
press: {
|
|
@@ -5307,13 +5317,13 @@ var Eu = "ydgo3h0", Nu = "ydgo3h1", Mu = "ydgo3h2", Ou = ({ clientPoint: e, pane
|
|
|
5307
5317
|
})
|
|
5308
5318
|
})?.point ?? null;
|
|
5309
5319
|
}, Vu = (e) => {
|
|
5310
|
-
const t =
|
|
5320
|
+
const t = De();
|
|
5311
5321
|
return t === null ? null : /* @__PURE__ */ n(Gu, {
|
|
5312
5322
|
annotationId: t,
|
|
5313
5323
|
...e
|
|
5314
5324
|
});
|
|
5315
5325
|
}, Gu = ({ annotationId: e, ...t }) => {
|
|
5316
|
-
const r = po(), a =
|
|
5326
|
+
const r = po(), a = M(() => r.find((o) => o.id === e), [r, e]);
|
|
5317
5327
|
return a === void 0 ? null : /* @__PURE__ */ n($u, {
|
|
5318
5328
|
committedArrow: a.committedArrow,
|
|
5319
5329
|
color: a.color,
|
|
@@ -5345,7 +5355,7 @@ var Eu = "ydgo3h0", Nu = "ydgo3h1", Mu = "ydgo3h2", Ou = ({ clientPoint: e, pane
|
|
|
5345
5355
|
}),
|
|
5346
5356
|
/* @__PURE__ */ n("div", {
|
|
5347
5357
|
"aria-hidden": "true",
|
|
5348
|
-
className:
|
|
5358
|
+
className: Nu,
|
|
5349
5359
|
"data-testid": "difference-arrow-selection-label",
|
|
5350
5360
|
style: {
|
|
5351
5361
|
left: s.x + o.x - 2,
|
|
@@ -5385,7 +5395,7 @@ var Eu = "ydgo3h0", Nu = "ydgo3h1", Mu = "ydgo3h2", Ou = ({ clientPoint: e, pane
|
|
|
5385
5395
|
...o,
|
|
5386
5396
|
children: /* @__PURE__ */ n("span", {
|
|
5387
5397
|
"aria-hidden": "true",
|
|
5388
|
-
className:
|
|
5398
|
+
className: Mu
|
|
5389
5399
|
})
|
|
5390
5400
|
}), Tt = ({ start: e, extent: t, isStartMoving: r, delta: a, minExtent: o }) => {
|
|
5391
5401
|
if (!Number.isFinite(a)) return {
|
|
@@ -5453,11 +5463,11 @@ var Ku = {
|
|
|
5453
5463
|
}, qu = {
|
|
5454
5464
|
hovered: "_1ee8fau4 _1ee8fau3",
|
|
5455
5465
|
selected: "_1ee8fau5 _1ee8fau3"
|
|
5456
|
-
},
|
|
5457
|
-
const t = fe(e), r =
|
|
5466
|
+
}, Zu = ({ panelRect: e }) => {
|
|
5467
|
+
const t = fe(e), r = jn(), a = Xn(), o = De(), i = X((f) => V(f, "move-drag")), l = X((f) => V(f, "shape-resize-drag")), s = X((f) => V(f, "arrow-endpoint-drag")), c = X((f) => V(f, "text-resize-drag")), u = X((f) => {
|
|
5458
5468
|
const y = f.editTargetUnderPointer;
|
|
5459
5469
|
return y?.kind === "annotation" ? y.id : null;
|
|
5460
|
-
}), d =
|
|
5470
|
+
}), d = M(() => ({
|
|
5461
5471
|
panel: {
|
|
5462
5472
|
width: e.width,
|
|
5463
5473
|
height: e.height
|
|
@@ -5472,7 +5482,7 @@ var Ku = {
|
|
|
5472
5482
|
]), h = An(t, o, d), v = An(t, u === o ? null : u, d), p = (f) => {
|
|
5473
5483
|
if (l?.annotationId === f.id) {
|
|
5474
5484
|
const y = t.shapes.find((P) => P.id === f.id);
|
|
5475
|
-
return y === void 0 ? f.geometry :
|
|
5485
|
+
return y === void 0 ? f.geometry : Zn(Ut(l.region), Sl(a, y.id).borderWidth, d.panel);
|
|
5476
5486
|
}
|
|
5477
5487
|
if (s?.annotationId === f.id) {
|
|
5478
5488
|
const y = t.arrows.find((P) => P.id === f.id);
|
|
@@ -5487,7 +5497,7 @@ var Ku = {
|
|
|
5487
5497
|
y: e.y + y.y
|
|
5488
5498
|
};
|
|
5489
5499
|
};
|
|
5490
|
-
return /* @__PURE__ */ m(
|
|
5500
|
+
return /* @__PURE__ */ m(j, { children: [v !== null && /* @__PURE__ */ n(kn, {
|
|
5491
5501
|
annotationId: v.id,
|
|
5492
5502
|
geometry: p(v),
|
|
5493
5503
|
state: "hovered",
|
|
@@ -5537,8 +5547,8 @@ var Ku = {
|
|
|
5537
5547
|
left: r.x + e.x,
|
|
5538
5548
|
top: r.y + e.y
|
|
5539
5549
|
}
|
|
5540
|
-
}),
|
|
5541
|
-
const t =
|
|
5550
|
+
}), Xu = ({ panelRect: e }) => {
|
|
5551
|
+
const t = X((o) => V(o, "move-drag")), r = fe(e);
|
|
5542
5552
|
if (t === null) return null;
|
|
5543
5553
|
const a = la(t.translation, e);
|
|
5544
5554
|
return /* @__PURE__ */ n("svg", {
|
|
@@ -5554,9 +5564,9 @@ var Ku = {
|
|
|
5554
5564
|
"data-annotation-id": t.annotationId,
|
|
5555
5565
|
children: Ju(r, t.annotationId, e)
|
|
5556
5566
|
});
|
|
5557
|
-
},
|
|
5567
|
+
}, ju = ({ annotation: e, panel: t }) => {
|
|
5558
5568
|
const r = uo(e.id);
|
|
5559
|
-
return /* @__PURE__ */ n(
|
|
5569
|
+
return /* @__PURE__ */ n(Do, {
|
|
5560
5570
|
annotation: e,
|
|
5561
5571
|
panel: t,
|
|
5562
5572
|
style: Qn()(e.id),
|
|
@@ -5566,7 +5576,7 @@ var Ku = {
|
|
|
5566
5576
|
const a = e.find((o) => o.id === t);
|
|
5567
5577
|
return a === void 0 ? null : r(a);
|
|
5568
5578
|
}, Yu = {
|
|
5569
|
-
text: (e, t, r) => Ve(e.textAnnotations, t, (a) => /* @__PURE__ */ n(
|
|
5579
|
+
text: (e, t, r) => Ve(e.textAnnotations, t, (a) => /* @__PURE__ */ n(ju, {
|
|
5570
5580
|
annotation: a,
|
|
5571
5581
|
panel: r
|
|
5572
5582
|
})),
|
|
@@ -5589,7 +5599,7 @@ var Ku = {
|
|
|
5589
5599
|
}
|
|
5590
5600
|
return null;
|
|
5591
5601
|
}, Qu = ({ arrow: e, panelSize: t }) => {
|
|
5592
|
-
const r =
|
|
5602
|
+
const r = Nt()(e.id), a = ur({
|
|
5593
5603
|
arrow: e,
|
|
5594
5604
|
style: r,
|
|
5595
5605
|
panelWidth: t.width,
|
|
@@ -5609,7 +5619,7 @@ var Ku = {
|
|
|
5609
5619
|
panel: t,
|
|
5610
5620
|
style: Ao()(e.id)
|
|
5611
5621
|
}), nh = ({ panelRect: e }) => {
|
|
5612
|
-
const t =
|
|
5622
|
+
const t = X((i) => V(i, "shape-resize-drag")), r = fe(e).shapes, a = tt();
|
|
5613
5623
|
if (t === null) return null;
|
|
5614
5624
|
const o = r.find((i) => i.id === t.annotationId);
|
|
5615
5625
|
return o === void 0 ? null : /* @__PURE__ */ n("svg", {
|
|
@@ -5673,13 +5683,13 @@ var Ku = {
|
|
|
5673
5683
|
key: "graph.annotations.shapeToolbar.border.thick"
|
|
5674
5684
|
}
|
|
5675
5685
|
], oh = (e) => [...At].reverse().find((t) => t.width <= e) ?? At[0], ih = ({ shape: e, shapeBox: t, panelRect: r, frameWidth: a, frameHeight: o, frameElement: i }) => {
|
|
5676
|
-
const l = k(), { commands: s } = G(), c = _((C) => C.spec.styles.overrides), u = lt(), d = tt()(e.id), h = oh(d.borderWidth), v =
|
|
5686
|
+
const l = k(), { commands: s } = G(), c = _((C) => C.spec.styles.overrides), u = lt(), d = tt()(e.id), h = oh(d.borderWidth), v = M(() => ({
|
|
5677
5687
|
target: "annotation",
|
|
5678
5688
|
kind: "shape",
|
|
5679
5689
|
annotation: e.id
|
|
5680
5690
|
}), [e.id]), p = (C, A) => {
|
|
5681
5691
|
const L = Te(c, { select: v })?.declarations ?? {};
|
|
5682
|
-
s.dispatch(new
|
|
5692
|
+
s.dispatch(new Ne({
|
|
5683
5693
|
list: "overrides",
|
|
5684
5694
|
rule: {
|
|
5685
5695
|
select: v,
|
|
@@ -5761,7 +5771,7 @@ var Ku = {
|
|
|
5761
5771
|
});
|
|
5762
5772
|
r.current = i, i.start();
|
|
5763
5773
|
} }), [t]);
|
|
5764
|
-
},
|
|
5774
|
+
}, Xe = (e, t) => {
|
|
5765
5775
|
const r = e.shapes.find((a) => a.id === t);
|
|
5766
5776
|
return r === void 0 || r.region.anchorType !== "panel" ? null : r.region;
|
|
5767
5777
|
}, lh = class extends ze {
|
|
@@ -5769,10 +5779,10 @@ var Ku = {
|
|
|
5769
5779
|
super(...e), this.kind = "shape-resize-drag";
|
|
5770
5780
|
}
|
|
5771
5781
|
readOwn(e) {
|
|
5772
|
-
return
|
|
5782
|
+
return Rt(V(e, "shape-resize-drag"), this.params.annotationId);
|
|
5773
5783
|
}
|
|
5774
5784
|
resolvePreview(e) {
|
|
5775
|
-
const { annotationId: t, corner: r, press: a, readInputs: o } = this.params, { annotations: i, panelRect: l } = o(), s =
|
|
5785
|
+
const { annotationId: t, corner: r, press: a, readInputs: o } = this.params, { annotations: i, panelRect: l } = o(), s = Xe(i, t);
|
|
5776
5786
|
return s === null ? null : {
|
|
5777
5787
|
kind: "shape-resize-drag",
|
|
5778
5788
|
annotationId: t,
|
|
@@ -5785,7 +5795,7 @@ var Ku = {
|
|
|
5785
5795
|
};
|
|
5786
5796
|
}
|
|
5787
5797
|
commit({ region: e }) {
|
|
5788
|
-
const { annotationId: t, dispatch: r, readInputs: a } = this.params, o =
|
|
5798
|
+
const { annotationId: t, dispatch: r, readInputs: a } = this.params, o = Xe(a().annotations, t);
|
|
5789
5799
|
o === null || pa(o, e) || r(new re({
|
|
5790
5800
|
kind: "shape",
|
|
5791
5801
|
id: t,
|
|
@@ -5831,9 +5841,9 @@ var Ku = {
|
|
|
5831
5841
|
}, In = 4, dh = ({ annotationId: e, panelRect: t }) => {
|
|
5832
5842
|
const { commands: r } = G(), a = U(), o = _((i) => i.spec.annotations);
|
|
5833
5843
|
return Ca({
|
|
5834
|
-
readHeld: () =>
|
|
5844
|
+
readHeld: () => Rt(V(a.getState(), "shape-resize-drag"), e),
|
|
5835
5845
|
claim: () => {
|
|
5836
|
-
const i =
|
|
5846
|
+
const i = Xe(o, e);
|
|
5837
5847
|
return i === null ? null : {
|
|
5838
5848
|
kind: "shape-resize-drag",
|
|
5839
5849
|
annotationId: e,
|
|
@@ -5854,7 +5864,7 @@ var Ku = {
|
|
|
5854
5864
|
};
|
|
5855
5865
|
},
|
|
5856
5866
|
commit: ({ region: i }) => {
|
|
5857
|
-
const l =
|
|
5867
|
+
const l = Xe(o, e);
|
|
5858
5868
|
l === null || pa(l, i) || r.dispatch(new re({
|
|
5859
5869
|
kind: "shape",
|
|
5860
5870
|
id: e,
|
|
@@ -5894,7 +5904,7 @@ var Ku = {
|
|
|
5894
5904
|
"top-right": "diagonalUp",
|
|
5895
5905
|
"bottom-left": "diagonalUp"
|
|
5896
5906
|
}, ph = (e) => {
|
|
5897
|
-
const t =
|
|
5907
|
+
const t = De(), r = gh(t), a = vh(t);
|
|
5898
5908
|
if (r === null) return null;
|
|
5899
5909
|
const o = a.resizedRegion ?? (r.region.anchorType === "panel" ? r.region : null);
|
|
5900
5910
|
return o === null ? null : /* @__PURE__ */ n(mh, {
|
|
@@ -5911,7 +5921,7 @@ var Ku = {
|
|
|
5911
5921
|
}), u = dh({
|
|
5912
5922
|
annotationId: e.id,
|
|
5913
5923
|
panelRect: o
|
|
5914
|
-
}), d = tt()(e.id), { rect: h } =
|
|
5924
|
+
}), d = tt()(e.id), { rect: h } = Zn(Ut(t), d.borderWidth, o);
|
|
5915
5925
|
return /* @__PURE__ */ m("div", {
|
|
5916
5926
|
"data-testid": "shape-selection",
|
|
5917
5927
|
"data-annotation-id": e.id,
|
|
@@ -5944,13 +5954,13 @@ var Ku = {
|
|
|
5944
5954
|
}, gh = (e) => {
|
|
5945
5955
|
const t = _((r) => r.spec.annotations.shapes);
|
|
5946
5956
|
return e === null ? null : t.find((r) => r.id === e) ?? null;
|
|
5947
|
-
}, vh = (e) =>
|
|
5957
|
+
}, vh = (e) => X(Pe((t) => e === null ? {
|
|
5948
5958
|
resizedRegion: null,
|
|
5949
5959
|
isMoved: !1
|
|
5950
5960
|
} : {
|
|
5951
|
-
resizedRegion:
|
|
5961
|
+
resizedRegion: Rt(V(t, "shape-resize-drag"), e)?.region ?? null,
|
|
5952
5962
|
isMoved: et(V(t, "move-drag"), e) !== null
|
|
5953
|
-
})), fh = ({ textColor: e, ...t }) => /* @__PURE__ */ m(
|
|
5963
|
+
})), fh = ({ textColor: e, ...t }) => /* @__PURE__ */ m(x, {
|
|
5954
5964
|
...t,
|
|
5955
5965
|
children: [/* @__PURE__ */ m("g", {
|
|
5956
5966
|
stroke: "currentColor",
|
|
@@ -5964,7 +5974,7 @@ var Ku = {
|
|
|
5964
5974
|
strokeLinecap: "round"
|
|
5965
5975
|
})]
|
|
5966
5976
|
});
|
|
5967
|
-
var
|
|
5977
|
+
var je = "textStyle", ya = /* @__PURE__ */ new Set(["paragraph", "heading"]), bh = (e) => {
|
|
5968
5978
|
const t = Sa(e), r = Th(e);
|
|
5969
5979
|
return {
|
|
5970
5980
|
color: Ge(t.map((a) => Ah(gt(a)?.color))),
|
|
@@ -5982,8 +5992,8 @@ var Ze = "textStyle", ya = /* @__PURE__ */ new Set(["paragraph", "heading"]), bh
|
|
|
5982
5992
|
...e,
|
|
5983
5993
|
content: e.content.map((r) => Wt(r, t))
|
|
5984
5994
|
}), xh = (e, t) => {
|
|
5985
|
-
const r = e.marks ?? [], a = r.find((i) => i.type ===
|
|
5986
|
-
type:
|
|
5995
|
+
const r = e.marks ?? [], a = r.find((i) => i.type === je), o = {
|
|
5996
|
+
type: je,
|
|
5987
5997
|
attrs: {
|
|
5988
5998
|
...a?.attrs,
|
|
5989
5999
|
...t
|
|
@@ -5993,7 +6003,7 @@ var Ze = "textStyle", ya = /* @__PURE__ */ new Set(["paragraph", "heading"]), bh
|
|
|
5993
6003
|
...e,
|
|
5994
6004
|
marks: a === void 0 ? [...r, o] : r.map((i) => i === a ? o : i)
|
|
5995
6005
|
};
|
|
5996
|
-
}, gt = (e) => e.marks?.find((t) => t.type ===
|
|
6006
|
+
}, gt = (e) => e.marks?.find((t) => t.type === je)?.attrs, wh = (e) => Qt(e?.font) ?? Qt(e?.fontFamily), Sa = (e) => Kt(e, (t) => t.type === "text"), Th = (e) => Kt(e, (t) => ya.has(t.type ?? "")), Kt = (e, t) => [...t(e) ? [e] : [], ...(e.content ?? []).flatMap((r) => Kt(r, t))], Ge = (e) => {
|
|
5997
6007
|
const [t, ...r] = e;
|
|
5998
6008
|
return t === void 0 ? null : r.every((a) => a === t) ? t : null;
|
|
5999
6009
|
}, Ah = (e) => typeof e == "string" && e.length > 0 ? e : void 0, kh = (e) => typeof e == "number" && Number.isFinite(e) ? e : void 0, Lh = (e) => e === "left" || e === "center" || e === "right" ? e : void 0;
|
|
@@ -6044,7 +6054,7 @@ var wa = [
|
|
|
6044
6054
|
size: 20,
|
|
6045
6055
|
key: "graph.annotations.textToolbar.fontSize.huge"
|
|
6046
6056
|
}
|
|
6047
|
-
], Ih = (e) => wa.find((t) => t.size === (e ?? 10)) ?? null, Eh = (e) => `${e / 10}em`,
|
|
6057
|
+
], Ih = (e) => wa.find((t) => t.size === (e ?? 10)) ?? null, Eh = (e) => `${e / 10}em`, Mh = [
|
|
6048
6058
|
{
|
|
6049
6059
|
alignment: "left",
|
|
6050
6060
|
Icon: Gr
|
|
@@ -6057,14 +6067,14 @@ var wa = [
|
|
|
6057
6067
|
alignment: "right",
|
|
6058
6068
|
Icon: Vr
|
|
6059
6069
|
}
|
|
6060
|
-
],
|
|
6061
|
-
const l = k(), { commands: s } = G(), c = _((b) => b.spec.styles.overrides), u = U(), d = lt(), h = Qn()(e.id), v = bh(e.content), p = Ph(v.font), g = Ih(v.fontSize), f = v.color ?? h.textColor, y =
|
|
6070
|
+
], Nh = ({ annotation: e, textBox: t, panelRect: r, frameWidth: a, frameHeight: o, frameElement: i }) => {
|
|
6071
|
+
const l = k(), { commands: s } = G(), c = _((b) => b.spec.styles.overrides), u = U(), d = lt(), h = Qn()(e.id), v = bh(e.content), p = Ph(v.font), g = Ih(v.fontSize), f = v.color ?? h.textColor, y = M(() => ({
|
|
6062
6072
|
target: "annotation",
|
|
6063
6073
|
kind: "text",
|
|
6064
6074
|
annotation: e.id
|
|
6065
|
-
}), [e.id]), P = (b,
|
|
6075
|
+
}), [e.id]), P = (b, Z) => {
|
|
6066
6076
|
const ye = Te(c, { select: y })?.declarations ?? {};
|
|
6067
|
-
s.dispatch(new
|
|
6077
|
+
s.dispatch(new Ne({
|
|
6068
6078
|
list: "overrides",
|
|
6069
6079
|
rule: {
|
|
6070
6080
|
select: y,
|
|
@@ -6073,27 +6083,27 @@ var wa = [
|
|
|
6073
6083
|
...b
|
|
6074
6084
|
}
|
|
6075
6085
|
}
|
|
6076
|
-
}),
|
|
6077
|
-
}, C = (b,
|
|
6086
|
+
}), Z);
|
|
6087
|
+
}, C = (b, Z) => {
|
|
6078
6088
|
s.dispatch(new re({
|
|
6079
6089
|
kind: "text",
|
|
6080
6090
|
id: e.id,
|
|
6081
6091
|
patch: b
|
|
6082
|
-
}),
|
|
6083
|
-
}, A = () => u.getState().caret?.editor?.getJSON() ?? e.content, L = (b,
|
|
6092
|
+
}), Z);
|
|
6093
|
+
}, A = () => u.getState().caret?.editor?.getJSON() ?? e.content, L = (b, Z) => {
|
|
6084
6094
|
const ye = A(), _e = u.getState().caret?.editor ?? null;
|
|
6085
6095
|
if (_e !== null && !yh(ye)) {
|
|
6086
|
-
_e.chain().focus().setMark(
|
|
6096
|
+
_e.chain().focus().setMark(je, b).run();
|
|
6087
6097
|
return;
|
|
6088
6098
|
}
|
|
6089
|
-
C({ content: Ch(ye, b) },
|
|
6090
|
-
},
|
|
6099
|
+
C({ content: Ch(ye, b) }, Z);
|
|
6100
|
+
}, R = () => {
|
|
6091
6101
|
s.dispatch(new ke({ id: e.id })), i.focus({ preventScroll: !0 });
|
|
6092
|
-
}, F = (b) => P(Oh(b), { transient: !0 }),
|
|
6102
|
+
}, F = (b) => P(Oh(b), { transient: !0 }), D = (b) => L({ color: b }, { transient: !0 }), E = (b) => () => {
|
|
6093
6103
|
L({ font: b }), d.close();
|
|
6094
|
-
},
|
|
6104
|
+
}, N = (b) => () => {
|
|
6095
6105
|
L({ fontSize: b }), d.close();
|
|
6096
|
-
},
|
|
6106
|
+
}, T = (b) => C({ content: Sh(A(), b) });
|
|
6097
6107
|
return /* @__PURE__ */ m(I.Root, {
|
|
6098
6108
|
anchorBox: t,
|
|
6099
6109
|
panelRect: r,
|
|
@@ -6113,7 +6123,7 @@ var wa = [
|
|
|
6113
6123
|
/* @__PURE__ */ n(I.ColorPicker, {
|
|
6114
6124
|
color: f,
|
|
6115
6125
|
label: l("graph.annotations.textToolbar.color"),
|
|
6116
|
-
onChange:
|
|
6126
|
+
onChange: D,
|
|
6117
6127
|
...d.bind("color"),
|
|
6118
6128
|
children: /* @__PURE__ */ n(fh, {
|
|
6119
6129
|
size: "sm",
|
|
@@ -6143,7 +6153,7 @@ var wa = [
|
|
|
6143
6153
|
...d.bind("fontSize"),
|
|
6144
6154
|
children: wa.map((b) => /* @__PURE__ */ n(I.MenuItem, {
|
|
6145
6155
|
isSelected: b.size === g?.size,
|
|
6146
|
-
onClick:
|
|
6156
|
+
onClick: N(b.size),
|
|
6147
6157
|
children: /* @__PURE__ */ n("span", {
|
|
6148
6158
|
style: { fontSize: Eh(b.size) },
|
|
6149
6159
|
children: l(b.key)
|
|
@@ -6151,14 +6161,14 @@ var wa = [
|
|
|
6151
6161
|
}, b.size))
|
|
6152
6162
|
}),
|
|
6153
6163
|
/* @__PURE__ */ n(I.Separator, {}),
|
|
6154
|
-
/* @__PURE__ */ n(
|
|
6164
|
+
/* @__PURE__ */ n(Rh, {
|
|
6155
6165
|
current: v.alignment ?? "center",
|
|
6156
|
-
onPick:
|
|
6166
|
+
onPick: T
|
|
6157
6167
|
}),
|
|
6158
6168
|
/* @__PURE__ */ n(I.Separator, {}),
|
|
6159
6169
|
/* @__PURE__ */ n(I.IconButton, {
|
|
6160
6170
|
label: l("graph.annotations.textToolbar.remove"),
|
|
6161
|
-
onClick:
|
|
6171
|
+
onClick: R,
|
|
6162
6172
|
children: /* @__PURE__ */ n(it, {
|
|
6163
6173
|
size: "sm",
|
|
6164
6174
|
title: ""
|
|
@@ -6168,10 +6178,10 @@ var wa = [
|
|
|
6168
6178
|
});
|
|
6169
6179
|
}, Oh = (e) => e === "transparent" ? { background: Er } : {
|
|
6170
6180
|
background: e,
|
|
6171
|
-
alpha: Es(e) ?
|
|
6172
|
-
},
|
|
6181
|
+
alpha: Es(e) ? Ni : 1
|
|
6182
|
+
}, Rh = ({ current: e, onPick: t }) => {
|
|
6173
6183
|
const r = k(), a = (o) => () => t(o);
|
|
6174
|
-
return /* @__PURE__ */ n(
|
|
6184
|
+
return /* @__PURE__ */ n(j, { children: Mh.map((o) => /* @__PURE__ */ n(I.ToggleButton, {
|
|
6175
6185
|
label: r(`graph.annotations.textToolbar.align.${o.alignment}`),
|
|
6176
6186
|
isPressed: o.alignment === e,
|
|
6177
6187
|
onClick: a(o.alignment),
|
|
@@ -6180,7 +6190,7 @@ var wa = [
|
|
|
6180
6190
|
title: ""
|
|
6181
6191
|
})
|
|
6182
6192
|
}, o.alignment)) });
|
|
6183
|
-
},
|
|
6193
|
+
}, Dh = ["left", "right"];
|
|
6184
6194
|
var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
|
|
6185
6195
|
x: t === "left" ? e.x : e.x + e.width,
|
|
6186
6196
|
y: e.y + e.height / 2
|
|
@@ -6306,7 +6316,7 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
|
|
|
6306
6316
|
return null;
|
|
6307
6317
|
}
|
|
6308
6318
|
}, $h = (e) => {
|
|
6309
|
-
const t =
|
|
6319
|
+
const t = De(), r = Wh(t), a = Kh(t), o = X((l) => l.caret?.annotationId === t), i = qh(e.panelRect, t, a.resized);
|
|
6310
6320
|
return r === null || i === null ? null : /* @__PURE__ */ n(Uh, {
|
|
6311
6321
|
annotation: r,
|
|
6312
6322
|
textBox: i,
|
|
@@ -6327,14 +6337,14 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
|
|
|
6327
6337
|
return /* @__PURE__ */ m("div", {
|
|
6328
6338
|
"data-testid": "text-selection",
|
|
6329
6339
|
"data-annotation-id": e.id,
|
|
6330
|
-
children: [r && /* @__PURE__ */ n(
|
|
6340
|
+
children: [r && /* @__PURE__ */ n(Nh, {
|
|
6331
6341
|
annotation: e,
|
|
6332
6342
|
textBox: t,
|
|
6333
6343
|
panelRect: l,
|
|
6334
6344
|
frameWidth: s.width,
|
|
6335
6345
|
frameHeight: s.height,
|
|
6336
6346
|
frameElement: c
|
|
6337
|
-
}), o && !a && !i &&
|
|
6347
|
+
}), o && !a && !i && Dh.map((v) => {
|
|
6338
6348
|
const p = zh(t, v);
|
|
6339
6349
|
return /* @__PURE__ */ n(fa, {
|
|
6340
6350
|
point: {
|
|
@@ -6356,14 +6366,14 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
|
|
|
6356
6366
|
}, Wh = (e) => {
|
|
6357
6367
|
const t = _((r) => r.spec.annotations.textAnnotations);
|
|
6358
6368
|
return e === null ? null : t.find((r) => r.id === e) ?? null;
|
|
6359
|
-
}, Kh = (e) =>
|
|
6369
|
+
}, Kh = (e) => X(Pe((t) => e === null ? {
|
|
6360
6370
|
resized: null,
|
|
6361
6371
|
isMoved: !1
|
|
6362
6372
|
} : {
|
|
6363
6373
|
resized: Et(V(t, "text-resize-drag"), e),
|
|
6364
6374
|
isMoved: et(V(t, "move-drag"), e) !== null
|
|
6365
6375
|
})), qh = (e, t, r) => {
|
|
6366
|
-
const a = fe(e), o =
|
|
6376
|
+
const a = fe(e), o = jn(), i = Xn(), l = M(() => ({
|
|
6367
6377
|
panel: {
|
|
6368
6378
|
width: e.width,
|
|
6369
6379
|
height: e.height
|
|
@@ -6377,7 +6387,7 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
|
|
|
6377
6387
|
i
|
|
6378
6388
|
]);
|
|
6379
6389
|
return t === null ? null : va(a, t, r, l)?.rect ?? null;
|
|
6380
|
-
},
|
|
6390
|
+
}, Zh = (e) => /* @__PURE__ */ n(x, {
|
|
6381
6391
|
...e,
|
|
6382
6392
|
children: /* @__PURE__ */ m("g", {
|
|
6383
6393
|
stroke: "currentColor",
|
|
@@ -6386,7 +6396,7 @@ var Ta = ({ width: e }) => ne(60, e), zh = (e, t) => ({
|
|
|
6386
6396
|
strokeLinejoin: "round",
|
|
6387
6397
|
children: [/* @__PURE__ */ n("path", { d: "M12 5v14" }), /* @__PURE__ */ n("path", { d: "M5 12h14" })]
|
|
6388
6398
|
})
|
|
6389
|
-
}),
|
|
6399
|
+
}), Xh = "var(--_1tyillx0)", jh = {
|
|
6390
6400
|
rest: 0.5,
|
|
6391
6401
|
hovered: 0.75,
|
|
6392
6402
|
open: 1
|
|
@@ -6399,15 +6409,15 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6399
6409
|
closed: "_1tyillx6",
|
|
6400
6410
|
open: "_1tyillx7"
|
|
6401
6411
|
}, t1 = ({ interaction: e, panelRect: t }) => {
|
|
6402
|
-
const r = U(), a = e.kind === "trigger" || e.kind === "menu" ? e.anchor : null, o = n1(e), i =
|
|
6412
|
+
const r = U(), a = e.kind === "trigger" || e.kind === "menu" ? e.anchor : null, o = n1(e), i = M(() => {
|
|
6403
6413
|
if (a === null) return null;
|
|
6404
6414
|
const l = Ue(a.position, t);
|
|
6405
6415
|
return {
|
|
6406
6416
|
center: l,
|
|
6407
|
-
radius: 19 *
|
|
6417
|
+
radius: 19 * jh[o],
|
|
6408
6418
|
target: {
|
|
6409
6419
|
kind: "observation",
|
|
6410
|
-
cursor:
|
|
6420
|
+
cursor: Dt(l, t)
|
|
6411
6421
|
}
|
|
6412
6422
|
};
|
|
6413
6423
|
}, [
|
|
@@ -6425,11 +6435,11 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6425
6435
|
style: {
|
|
6426
6436
|
left: t.x + i.center.x,
|
|
6427
6437
|
top: t.y + i.center.y,
|
|
6428
|
-
...br({ [
|
|
6438
|
+
...br({ [Xh]: a.color })
|
|
6429
6439
|
},
|
|
6430
6440
|
children: /* @__PURE__ */ n("span", {
|
|
6431
6441
|
className: ce(Qh, e1[o === "open" ? "open" : "closed"]),
|
|
6432
|
-
children: /* @__PURE__ */ n(
|
|
6442
|
+
children: /* @__PURE__ */ n(Zh, { size: "lg" })
|
|
6433
6443
|
})
|
|
6434
6444
|
});
|
|
6435
6445
|
}, n1 = (e) => e.kind === "menu" ? "open" : e.kind === "trigger" && e.isEngaged ? "hovered" : "rest", r1 = 'button:not([disabled]):not([tabindex="-1"]), [tabindex]:not([tabindex="-1"])', a1 = (e, t) => {
|
|
@@ -6437,7 +6447,7 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6437
6447
|
O(() => {
|
|
6438
6448
|
if (t === null) return;
|
|
6439
6449
|
const o = (i) => {
|
|
6440
|
-
if (i.key !== "Tab" || i.defaultPrevented || !
|
|
6450
|
+
if (i.key !== "Tab" || i.defaultPrevented || !Me(i.target, e, r) || a.getState().standingInteraction?.kind === "chrome-popup") return;
|
|
6441
6451
|
const l = [...t.querySelectorAll(r1)];
|
|
6442
6452
|
if (l.length === 0) return;
|
|
6443
6453
|
i.preventDefault();
|
|
@@ -6481,10 +6491,10 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6481
6491
|
d !== null && d.id === u?.annotationId || e.focus({ preventScroll: !0 });
|
|
6482
6492
|
}, l = (c) => {
|
|
6483
6493
|
const { selection: u, clearSelection: d } = t.getState();
|
|
6484
|
-
u.length !== 0 && (
|
|
6494
|
+
u.length !== 0 && (Me(c.target, e, r) || d());
|
|
6485
6495
|
}, s = (c) => {
|
|
6486
|
-
t.getState().selection.length !== 0 &&
|
|
6487
|
-
o = null, document.hasFocus() && (
|
|
6496
|
+
t.getState().selection.length !== 0 && Me(c.target, e, r) && c.relatedTarget === null && (o !== null && cancelAnimationFrame(o), o = requestAnimationFrame(() => {
|
|
6497
|
+
o = null, document.hasFocus() && (Me(document.activeElement, e, r) || t.getState().clearSelection());
|
|
6488
6498
|
}));
|
|
6489
6499
|
};
|
|
6490
6500
|
return e.addEventListener("pointerdown", i), document.addEventListener("focusin", l), document.addEventListener("focusout", s), () => {
|
|
@@ -6506,7 +6516,7 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6506
6516
|
resolvePreview(e) {
|
|
6507
6517
|
const { annotationId: t, press: r, readInputs: a } = this.params, { annotations: o, panelRect: i } = a(), l = el(o, t);
|
|
6508
6518
|
if (l === null) return null;
|
|
6509
|
-
const s =
|
|
6519
|
+
const s = Zi(l, st(r, e, i));
|
|
6510
6520
|
return s === null ? null : {
|
|
6511
6521
|
kind: "move-drag",
|
|
6512
6522
|
annotationId: t,
|
|
@@ -6515,7 +6525,7 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6515
6525
|
}
|
|
6516
6526
|
commit({ translation: e }) {
|
|
6517
6527
|
const { annotationId: t, dispatch: r } = this.params;
|
|
6518
|
-
lu(e) && r(new
|
|
6528
|
+
lu(e) && r(new Zo({
|
|
6519
6529
|
id: t,
|
|
6520
6530
|
translation: e
|
|
6521
6531
|
}));
|
|
@@ -6615,7 +6625,7 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6615
6625
|
]);
|
|
6616
6626
|
O(() => {
|
|
6617
6627
|
const u = (d) => {
|
|
6618
|
-
if (!
|
|
6628
|
+
if (!Me(d.target, e, a) || Gc(d.target)) return;
|
|
6619
6629
|
const h = p1(d.target), v = o.getState().caret !== null && !$e(d.target, a);
|
|
6620
6630
|
if (!(h && !v))
|
|
6621
6631
|
switch (d.key) {
|
|
@@ -6643,8 +6653,8 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6643
6653
|
const e = Co((l) => l.hover.primary), { layers: t, coordSystem: r } = _(Pe((l) => ({
|
|
6644
6654
|
layers: l.layers,
|
|
6645
6655
|
coordSystem: l.coordSystem
|
|
6646
|
-
}))), { anchorResolver: a, colorScheme: o } = G(), i =
|
|
6647
|
-
return
|
|
6656
|
+
}))), { anchorResolver: a, colorScheme: o } = G(), i = M(() => at({ colorScheme: o }), [o]);
|
|
6657
|
+
return M(() => {
|
|
6648
6658
|
if (e === null) return null;
|
|
6649
6659
|
const l = t.find((u) => u.id === e.layerId);
|
|
6650
6660
|
if (l === void 0) return null;
|
|
@@ -6654,7 +6664,7 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6654
6664
|
purpose: "pin"
|
|
6655
6665
|
});
|
|
6656
6666
|
if (s === null) return null;
|
|
6657
|
-
const c =
|
|
6667
|
+
const c = Xi(l)(e.observation);
|
|
6658
6668
|
return c === null ? null : {
|
|
6659
6669
|
position: s,
|
|
6660
6670
|
color: i.geomReaders(l).get("color", e.observation),
|
|
@@ -6670,8 +6680,8 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6670
6680
|
i
|
|
6671
6681
|
]);
|
|
6672
6682
|
}, g1 = { kind: "idle" }, La = () => {
|
|
6673
|
-
const e =
|
|
6674
|
-
return
|
|
6683
|
+
const e = X((a) => a.standingInteraction), t = X((a) => a.chromeUnderPointer), r = m1();
|
|
6684
|
+
return M(() => e !== null ? e : r === null ? g1 : {
|
|
6675
6685
|
kind: "trigger",
|
|
6676
6686
|
anchor: r,
|
|
6677
6687
|
isEngaged: t === "menu-trigger"
|
|
@@ -6688,7 +6698,7 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6688
6698
|
const y = u.current, P = c.current, C = {
|
|
6689
6699
|
x: f.clientX - P.x,
|
|
6690
6700
|
y: f.clientY - P.y
|
|
6691
|
-
}, A = f1(C, y) ? l.query(
|
|
6701
|
+
}, A = f1(C, y) ? l.query(Dt(C, y)) : or;
|
|
6692
6702
|
i.getState().setHoverState(A);
|
|
6693
6703
|
};
|
|
6694
6704
|
let v = !1;
|
|
@@ -6773,9 +6783,9 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6773
6783
|
case "chrome-popup":
|
|
6774
6784
|
return !1;
|
|
6775
6785
|
}
|
|
6776
|
-
}, En = "editor",
|
|
6777
|
-
const o = La(), { store: i } = Ot(), l = Jn().length > 0, s =
|
|
6778
|
-
b1(e, t), d1(e, t, r), v1(o, t, r), s1(e), h1(e), a1(e, a), O(() => (i.getState().publishPointerRegions(En, u), () => i.getState().publishPointerRegions(En,
|
|
6786
|
+
}, En = "editor", Mn = [], C1 = (e, t, r, a) => {
|
|
6787
|
+
const o = La(), { store: i } = Ot(), l = Jn().length > 0, s = X((d) => d.menuTrigger), c = o.kind === "menu", u = M(() => s === null ? Mn : [Vi(s)], [s]);
|
|
6788
|
+
b1(e, t), d1(e, t, r), v1(o, t, r), s1(e), h1(e), a1(e, a), O(() => (i.getState().publishPointerRegions(En, u), () => i.getState().publishPointerRegions(En, Mn)), [i, u]), O(() => (i.getState().setPointerSuspended(c || l), () => i.getState().setPointerSuspended(!1)), [
|
|
6779
6789
|
i,
|
|
6780
6790
|
c,
|
|
6781
6791
|
l
|
|
@@ -6785,7 +6795,7 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6785
6795
|
d.setHoverState(or), d.setTooltipAnchor(null);
|
|
6786
6796
|
}, [i, l]);
|
|
6787
6797
|
}, y1 = ({ frameElement: e, panelRect: t }) => {
|
|
6788
|
-
const { measureRef: r, screenRect: a } = Eo(), o = U(), i =
|
|
6798
|
+
const { measureRef: r, screenRect: a } = Eo(), o = U(), i = X((l) => l.caret?.annotationId ?? null);
|
|
6789
6799
|
return O(() => (r(e), () => r(null)), [r, e]), O(() => () => {
|
|
6790
6800
|
const l = o.getState();
|
|
6791
6801
|
l.releaseInteraction("menu"), l.setCaret(null);
|
|
@@ -6807,7 +6817,7 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6807
6817
|
r
|
|
6808
6818
|
]), null;
|
|
6809
6819
|
}, x1 = ({ frameElement: e, frameRect: t, panelRect: r }) => {
|
|
6810
|
-
const a =
|
|
6820
|
+
const a = M(() => ({
|
|
6811
6821
|
x: t.left + r.x,
|
|
6812
6822
|
y: t.top + r.y
|
|
6813
6823
|
}), [
|
|
@@ -6853,10 +6863,10 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6853
6863
|
frameRect: t,
|
|
6854
6864
|
frameElement: e
|
|
6855
6865
|
}),
|
|
6856
|
-
/* @__PURE__ */ n(ju, { panelRect: a }),
|
|
6857
|
-
/* @__PURE__ */ n(nh, { panelRect: a }),
|
|
6858
|
-
/* @__PURE__ */ n(Rd, { panelRect: a }),
|
|
6859
6866
|
/* @__PURE__ */ n(Xu, { panelRect: a }),
|
|
6867
|
+
/* @__PURE__ */ n(nh, { panelRect: a }),
|
|
6868
|
+
/* @__PURE__ */ n(Dd, { panelRect: a }),
|
|
6869
|
+
/* @__PURE__ */ n(Zu, { panelRect: a }),
|
|
6860
6870
|
/* @__PURE__ */ n(t1, {
|
|
6861
6871
|
interaction: l,
|
|
6862
6872
|
panelRect: a
|
|
@@ -6867,12 +6877,12 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6867
6877
|
})
|
|
6868
6878
|
] })
|
|
6869
6879
|
});
|
|
6870
|
-
},
|
|
6871
|
-
locale:
|
|
6880
|
+
}, Qm = ({ slots: e, ...t }) => /* @__PURE__ */ n(ls, {
|
|
6881
|
+
locale: No(),
|
|
6872
6882
|
children: /* @__PURE__ */ n(go, { children: /* @__PURE__ */ n(io, {
|
|
6873
6883
|
editors: Hc,
|
|
6874
|
-
children: /* @__PURE__ */ n(
|
|
6875
|
-
slots:
|
|
6884
|
+
children: /* @__PURE__ */ n(Mo, {
|
|
6885
|
+
slots: M(() => ({
|
|
6876
6886
|
EditorSurface: y1,
|
|
6877
6887
|
...e
|
|
6878
6888
|
}), [e]),
|
|
@@ -6880,7 +6890,7 @@ var Yh = "_1tyillx1", Jh = {
|
|
|
6880
6890
|
})
|
|
6881
6891
|
}) })
|
|
6882
6892
|
}), Pa = Oe(null), Ia = ({ labelId: e, controlId: t, children: r }) => {
|
|
6883
|
-
const a =
|
|
6893
|
+
const a = M(() => {
|
|
6884
6894
|
let o = null;
|
|
6885
6895
|
return {
|
|
6886
6896
|
labelId: e,
|
|
@@ -6932,13 +6942,13 @@ var T1 = {
|
|
|
6932
6942
|
return /* @__PURE__ */ n("div", {
|
|
6933
6943
|
onKeyDown: (i) => {
|
|
6934
6944
|
if (t?.(i), !a || i.defaultPrevented) return;
|
|
6935
|
-
const l =
|
|
6945
|
+
const l = Ro(i.nativeEvent);
|
|
6936
6946
|
l && (i.preventDefault(), l === "undo" ? a.undo() : a.redo());
|
|
6937
6947
|
},
|
|
6938
6948
|
...r,
|
|
6939
6949
|
children: e
|
|
6940
6950
|
});
|
|
6941
|
-
},
|
|
6951
|
+
}, Ma = "keyboard", ct = (e) => {
|
|
6942
6952
|
const t = te(!1), r = te(!1), a = () => {
|
|
6943
6953
|
t.current = !1, r.current && (r.current = !1, e?.());
|
|
6944
6954
|
};
|
|
@@ -6979,7 +6989,7 @@ var I1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, placeho
|
|
|
6979
6989
|
value: e,
|
|
6980
6990
|
onValueChange: (P) => t(P),
|
|
6981
6991
|
onValueCommitted: (P, C) => {
|
|
6982
|
-
f(C.reason ===
|
|
6992
|
+
f(C.reason === Ma);
|
|
6983
6993
|
},
|
|
6984
6994
|
min: a,
|
|
6985
6995
|
max: o,
|
|
@@ -7015,15 +7025,15 @@ var I1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, placeho
|
|
|
7015
7025
|
4: "_1b7s5f4",
|
|
7016
7026
|
5: "_1b7s5f5",
|
|
7017
7027
|
6: "_1b7s5f6"
|
|
7018
|
-
},
|
|
7019
|
-
var
|
|
7028
|
+
}, M1 = "_1b7s5f7";
|
|
7029
|
+
var N1 = 6, O1 = ({ options: e, value: t, onChange: r, onCommit: a, columns: o, itemLayout: i = "tile", isDisabled: l, ariaLabel: s, ariaLabelledBy: c, id: u }) => {
|
|
7020
7030
|
const d = ge({
|
|
7021
7031
|
id: u,
|
|
7022
7032
|
ariaLabel: s,
|
|
7023
7033
|
ariaLabelledBy: c
|
|
7024
7034
|
}), h = i === "swatch", { commitAfterChange: v, gestureHandlers: p } = ct(a);
|
|
7025
7035
|
return /* @__PURE__ */ n(Tr, {
|
|
7026
|
-
className: ce(E1,
|
|
7036
|
+
className: ce(E1, R1(o ?? e.length)),
|
|
7027
7037
|
value: t,
|
|
7028
7038
|
onValueChange: (g) => {
|
|
7029
7039
|
r(g), v();
|
|
@@ -7034,7 +7044,7 @@ var M1 = 6, O1 = ({ options: e, value: t, onChange: r, onCommit: a, columns: o,
|
|
|
7034
7044
|
children: e.map((g) => /* @__PURE__ */ m(wr.Root, {
|
|
7035
7045
|
value: g.value,
|
|
7036
7046
|
disabled: g.isDisabled,
|
|
7037
|
-
className: ce(
|
|
7047
|
+
className: ce(M1, h && "_1b7s5f8"),
|
|
7038
7048
|
"aria-label": h ? g.label : void 0,
|
|
7039
7049
|
children: [g.icon, !h && /* @__PURE__ */ n("span", {
|
|
7040
7050
|
className: "_1b7s5f9",
|
|
@@ -7042,8 +7052,8 @@ var M1 = 6, O1 = ({ options: e, value: t, onChange: r, onCommit: a, columns: o,
|
|
|
7042
7052
|
})]
|
|
7043
7053
|
}, g.value))
|
|
7044
7054
|
});
|
|
7045
|
-
},
|
|
7046
|
-
switch (Math.min(Math.max(Math.round(e), 1),
|
|
7055
|
+
}, R1 = (e) => {
|
|
7056
|
+
switch (Math.min(Math.max(Math.round(e), 1), N1)) {
|
|
7047
7057
|
case 1:
|
|
7048
7058
|
return Se[1];
|
|
7049
7059
|
case 2:
|
|
@@ -7057,7 +7067,7 @@ var M1 = 6, O1 = ({ options: e, value: t, onChange: r, onCommit: a, columns: o,
|
|
|
7057
7067
|
default:
|
|
7058
7068
|
return Se[6];
|
|
7059
7069
|
}
|
|
7060
|
-
},
|
|
7070
|
+
}, D1 = "_1g5x15w0 uz3g760", z1 = "_1g5x15w1", _1 = "_1g5x15w2", Nn = "_1g5x15w3", F1 = "_1g5x15w4", H1 = "_1g5x15w5", B1 = "_1g5x15w6", V1 = "_1g5x15w7";
|
|
7061
7071
|
var G1 = ({ options: e, value: t, onChange: r, placeholder: a, isDisabled: o, hasError: i, ariaLabel: l, ariaLabelledBy: s, id: c }) => {
|
|
7062
7072
|
const u = ge({
|
|
7063
7073
|
id: c,
|
|
@@ -7073,15 +7083,15 @@ var G1 = ({ options: e, value: t, onChange: r, placeholder: a, isDisabled: o, ha
|
|
|
7073
7083
|
label: d.label
|
|
7074
7084
|
})),
|
|
7075
7085
|
children: [/* @__PURE__ */ m(ae.Trigger, {
|
|
7076
|
-
className:
|
|
7086
|
+
className: D1,
|
|
7077
7087
|
"data-error": i === !0,
|
|
7078
7088
|
...u,
|
|
7079
7089
|
children: [/* @__PURE__ */ n(ae.Value, {
|
|
7080
7090
|
className: z1,
|
|
7081
7091
|
children: (d) => $1(e, d, a)
|
|
7082
7092
|
}), /* @__PURE__ */ n(ae.Icon, {
|
|
7083
|
-
className:
|
|
7084
|
-
children: /* @__PURE__ */ n(
|
|
7093
|
+
className: Nn,
|
|
7094
|
+
children: /* @__PURE__ */ n(Re, { size: "sm" })
|
|
7085
7095
|
})]
|
|
7086
7096
|
}), /* @__PURE__ */ n(ae.Portal, {
|
|
7087
7097
|
container: le(),
|
|
@@ -7105,7 +7115,7 @@ var G1 = ({ options: e, value: t, onChange: r, placeholder: a, isDisabled: o, ha
|
|
|
7105
7115
|
})]
|
|
7106
7116
|
}),
|
|
7107
7117
|
/* @__PURE__ */ n(ae.ItemIndicator, {
|
|
7108
|
-
className:
|
|
7118
|
+
className: Nn,
|
|
7109
7119
|
children: /* @__PURE__ */ n(Hr, { size: "sm" })
|
|
7110
7120
|
})
|
|
7111
7121
|
]
|
|
@@ -7117,7 +7127,7 @@ var G1 = ({ options: e, value: t, onChange: r, placeholder: a, isDisabled: o, ha
|
|
|
7117
7127
|
}, $1 = (e, t, r) => t === null ? /* @__PURE__ */ n("span", {
|
|
7118
7128
|
className: _1,
|
|
7119
7129
|
children: r
|
|
7120
|
-
}) : U1(e, t), U1 = (e, t) => e.find((r) => r.value === t)?.label ?? t, W1 = "vod76w0", K1 = "vod76w1", q1 = "vod76w2",
|
|
7130
|
+
}) : U1(e, t), U1 = (e, t) => e.find((r) => r.value === t)?.label ?? t, W1 = "vod76w0", K1 = "vod76w1", q1 = "vod76w2", Z1 = "vod76w3", X1 = "vod76w4", j1 = "vod76w5";
|
|
7121
7131
|
var Y1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, suffix: l, formatValue: s, isDisabled: c, ariaLabel: u, ariaLabelledBy: d }) => {
|
|
7122
7132
|
const h = ge({
|
|
7123
7133
|
ariaLabel: u,
|
|
@@ -7130,7 +7140,7 @@ var Y1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, suffix:
|
|
|
7130
7140
|
value: e,
|
|
7131
7141
|
onValueChange: (f) => t(f),
|
|
7132
7142
|
onValueCommitted: (f, y) => {
|
|
7133
|
-
p(y.reason ===
|
|
7143
|
+
p(y.reason === Ma);
|
|
7134
7144
|
},
|
|
7135
7145
|
min: a,
|
|
7136
7146
|
max: o,
|
|
@@ -7139,9 +7149,9 @@ var Y1 = ({ value: e, onChange: t, onCommit: r, min: a, max: o, step: i, suffix:
|
|
|
7139
7149
|
children: /* @__PURE__ */ n(oe.Control, {
|
|
7140
7150
|
className: q1,
|
|
7141
7151
|
children: /* @__PURE__ */ m(oe.Track, {
|
|
7142
|
-
className:
|
|
7143
|
-
children: [/* @__PURE__ */ n(oe.Indicator, { className:
|
|
7144
|
-
className:
|
|
7152
|
+
className: Z1,
|
|
7153
|
+
children: [/* @__PURE__ */ n(oe.Indicator, { className: X1 }), /* @__PURE__ */ n(oe.Thumb, {
|
|
7154
|
+
className: j1,
|
|
7145
7155
|
...g,
|
|
7146
7156
|
...h
|
|
7147
7157
|
})]
|
|
@@ -7207,14 +7217,14 @@ var lp = ({ options: e, value: t, onChange: r, onCommit: a, itemLayout: o = "inl
|
|
|
7207
7217
|
disabled: p.isDisabled,
|
|
7208
7218
|
className: ce(ip, d && "cnu9yl2"),
|
|
7209
7219
|
"aria-label": sp(p, d),
|
|
7210
|
-
children: [p.icon,
|
|
7220
|
+
children: [p.icon, Na(p, d) && /* @__PURE__ */ n("span", {
|
|
7211
7221
|
className: "cnu9yl3",
|
|
7212
7222
|
children: p.label
|
|
7213
7223
|
})]
|
|
7214
7224
|
}, p.value))
|
|
7215
7225
|
});
|
|
7216
|
-
},
|
|
7217
|
-
if (!
|
|
7226
|
+
}, Na = (e, t) => e.icon === void 0 || t, sp = (e, t) => {
|
|
7227
|
+
if (!Na(e, t))
|
|
7218
7228
|
return e.label;
|
|
7219
7229
|
}, Oa = {
|
|
7220
7230
|
ToggleGroup: lp,
|
|
@@ -7225,16 +7235,16 @@ var lp = ({ options: e, value: t, onChange: r, onCommit: a, itemLayout: o = "inl
|
|
|
7225
7235
|
TextField: ap,
|
|
7226
7236
|
NumberField: I1,
|
|
7227
7237
|
Select: G1
|
|
7228
|
-
},
|
|
7229
|
-
const r =
|
|
7238
|
+
}, Ra = Oe(Oa), cp = ({ controls: e, children: t }) => {
|
|
7239
|
+
const r = M(() => ({
|
|
7230
7240
|
...Oa,
|
|
7231
7241
|
...e
|
|
7232
7242
|
}), [e]);
|
|
7233
|
-
return /* @__PURE__ */ n(
|
|
7243
|
+
return /* @__PURE__ */ n(Ra.Provider, {
|
|
7234
7244
|
value: r,
|
|
7235
7245
|
children: t
|
|
7236
7246
|
});
|
|
7237
|
-
}, B = () => Le(
|
|
7247
|
+
}, B = () => Le(Ra), dp = "_12lhx9e0", Da = ({ children: e }) => /* @__PURE__ */ n("div", {
|
|
7238
7248
|
className: dp,
|
|
7239
7249
|
children: e
|
|
7240
7250
|
}), up = "_139ohwv0", q = ({ children: e }) => /* @__PURE__ */ n("div", {
|
|
@@ -7246,7 +7256,7 @@ var lp = ({ options: e, value: t, onChange: r, onCommit: a, itemLayout: o = "inl
|
|
|
7246
7256
|
return e;
|
|
7247
7257
|
}, mp = "_1jlczkt0", gp = "data-graphy-editor-panel", vp = {
|
|
7248
7258
|
List: q,
|
|
7249
|
-
Grid:
|
|
7259
|
+
Grid: Da
|
|
7250
7260
|
};
|
|
7251
7261
|
function fp(e) {
|
|
7252
7262
|
if (e === void 0) return !1;
|
|
@@ -7254,7 +7264,7 @@ function fp(e) {
|
|
|
7254
7264
|
return t.includes("_1ii3bsb0") || t.includes("_1ii3bsb1");
|
|
7255
7265
|
}
|
|
7256
7266
|
var bp = ({ handle: e, children: t, controls: r, defaultExpandedSection: a = void 0, className: o }) => {
|
|
7257
|
-
const i = Lo(e), { themeClass: l, inlineVarsStyle: s } = nt(), [c, u] = Q(() => a ? [a] : []), d =
|
|
7267
|
+
const i = Lo(e), { themeClass: l, inlineVarsStyle: s } = nt(), [c, u] = Q(() => a ? [a] : []), d = M(() => ({
|
|
7258
7268
|
expandSection: (h) => u([h]),
|
|
7259
7269
|
collapseAllSections: () => u([])
|
|
7260
7270
|
}), []);
|
|
@@ -7281,7 +7291,7 @@ var bp = ({ handle: e, children: t, controls: r, defaultExpandedSection: a = voi
|
|
|
7281
7291
|
}, On = {
|
|
7282
7292
|
stack: "pr583x0",
|
|
7283
7293
|
grid: "pr583x1"
|
|
7284
|
-
},
|
|
7294
|
+
}, Rn = "pr583x2", Cp = {
|
|
7285
7295
|
plain: "pr583x4 pr583x3",
|
|
7286
7296
|
withIcon: "pr583x5 pr583x3"
|
|
7287
7297
|
}, S = ({ label: e, layout: t = "grid", icon: r, children: a }) => {
|
|
@@ -7289,7 +7299,7 @@ var bp = ({ handle: e, children: t, controls: r, defaultExpandedSection: a = voi
|
|
|
7289
7299
|
return e === void 0 ? /* @__PURE__ */ n("div", {
|
|
7290
7300
|
className: On[t],
|
|
7291
7301
|
children: /* @__PURE__ */ n("div", {
|
|
7292
|
-
className:
|
|
7302
|
+
className: Rn,
|
|
7293
7303
|
children: a
|
|
7294
7304
|
})
|
|
7295
7305
|
}) : /* @__PURE__ */ m("div", {
|
|
@@ -7303,7 +7313,7 @@ var bp = ({ handle: e, children: t, controls: r, defaultExpandedSection: a = voi
|
|
|
7303
7313
|
children: r
|
|
7304
7314
|
}), e]
|
|
7305
7315
|
}), /* @__PURE__ */ n("div", {
|
|
7306
|
-
className:
|
|
7316
|
+
className: Rn,
|
|
7307
7317
|
children: /* @__PURE__ */ n(Ia, {
|
|
7308
7318
|
labelId: o,
|
|
7309
7319
|
controlId: i,
|
|
@@ -7311,7 +7321,7 @@ var bp = ({ handle: e, children: t, controls: r, defaultExpandedSection: a = voi
|
|
|
7311
7321
|
})
|
|
7312
7322
|
})]
|
|
7313
7323
|
});
|
|
7314
|
-
}, yp = (e) => /* @__PURE__ */ n(
|
|
7324
|
+
}, yp = (e) => /* @__PURE__ */ n(x, {
|
|
7315
7325
|
...e,
|
|
7316
7326
|
children: /* @__PURE__ */ n("g", {
|
|
7317
7327
|
stroke: "currentColor",
|
|
@@ -7320,7 +7330,7 @@ var bp = ({ handle: e, children: t, controls: r, defaultExpandedSection: a = voi
|
|
|
7320
7330
|
strokeLinejoin: "round",
|
|
7321
7331
|
children: /* @__PURE__ */ n("path", { d: "m9 6 6 6-6 6" })
|
|
7322
7332
|
})
|
|
7323
|
-
}),
|
|
7333
|
+
}), Zt = "_40zvwv0", Xt = "_40zvwv1", Sp = "_40zvwv2", Fa = "_40zvwv3", xp = "_40zvwv4 _40zvwv3";
|
|
7324
7334
|
var wp = "_40zvwv6";
|
|
7325
7335
|
var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory: a, onOpenChange: o, children: i }) => t === "collapsible" ? /* @__PURE__ */ n(kp, {
|
|
7326
7336
|
title: e,
|
|
@@ -7333,9 +7343,9 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7333
7343
|
accessory: a,
|
|
7334
7344
|
children: i
|
|
7335
7345
|
}) : /* @__PURE__ */ m("div", {
|
|
7336
|
-
className:
|
|
7346
|
+
className: Zt,
|
|
7337
7347
|
children: [/* @__PURE__ */ m("div", {
|
|
7338
|
-
className:
|
|
7348
|
+
className: Xt,
|
|
7339
7349
|
children: [
|
|
7340
7350
|
/* @__PURE__ */ n("span", {
|
|
7341
7351
|
className: Fa,
|
|
@@ -7354,9 +7364,9 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7354
7364
|
}), Ap = ({ title: e, accessory: t, children: r }) => {
|
|
7355
7365
|
const a = Ae(), o = Ae();
|
|
7356
7366
|
return /* @__PURE__ */ n("div", {
|
|
7357
|
-
className:
|
|
7367
|
+
className: Zt,
|
|
7358
7368
|
children: /* @__PURE__ */ m("div", {
|
|
7359
|
-
className:
|
|
7369
|
+
className: Xt,
|
|
7360
7370
|
children: [
|
|
7361
7371
|
/* @__PURE__ */ n("label", {
|
|
7362
7372
|
id: a,
|
|
@@ -7383,10 +7393,10 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7383
7393
|
const i = k();
|
|
7384
7394
|
return /* @__PURE__ */ m(Ee.Item, {
|
|
7385
7395
|
value: e,
|
|
7386
|
-
className:
|
|
7396
|
+
className: Zt,
|
|
7387
7397
|
onOpenChange: a,
|
|
7388
7398
|
children: [/* @__PURE__ */ m(Ee.Header, {
|
|
7389
|
-
className:
|
|
7399
|
+
className: Xt,
|
|
7390
7400
|
render: /* @__PURE__ */ n("div", {}),
|
|
7391
7401
|
children: [
|
|
7392
7402
|
/* @__PURE__ */ n(Ee.Trigger, {
|
|
@@ -7442,63 +7452,63 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7442
7452
|
}, Ep = {
|
|
7443
7453
|
x: "editor.axesPanel.mainAxisSection.xAxis",
|
|
7444
7454
|
y: "editor.axesPanel.mainAxisSection.yAxis"
|
|
7445
|
-
},
|
|
7455
|
+
}, Dn = ({ axis: e, title: t, layout: r = "collapsible", preview: a }) => {
|
|
7446
7456
|
const o = H(), i = $(o), l = k(), { NumberField: s, Switch: c, TextField: u, ToggleGroup: d } = B();
|
|
7447
7457
|
if (!i) return null;
|
|
7448
7458
|
const h = i.coordSystem.type === "polar" ? i.coordSystem.axisMapping[e].geometry : "linear", v = i.config.axes[e], p = i.scales[e], g = p?.spec, f = g?.scaleType === "continuous" ? g : void 0;
|
|
7449
7459
|
if (h === "circular" || h === "radial" && f === void 0) return null;
|
|
7450
|
-
const y = g !== void 0 && "reverse" in g ? g : void 0, P = g?.scaleType === "continuous" || g?.scaleType === "datetime", C = e === "y" && f !== void 0 && i.layers.some((
|
|
7460
|
+
const y = g !== void 0 && "reverse" in g ? g : void 0, P = g?.scaleType === "continuous" || g?.scaleType === "datetime", C = e === "y" && f !== void 0 && i.layers.some((w) => w.yScaleType === "primary" && w.geom === "bar"), A = f?.transform === "log", L = f?.domainMax ?? null, R = Mp(f), F = (w, ue) => w.map((Fe) => ({
|
|
7451
7461
|
value: Fe,
|
|
7452
7462
|
label: ue(Fe)
|
|
7453
|
-
})),
|
|
7454
|
-
value:
|
|
7455
|
-
label: l(Ip[
|
|
7456
|
-
})), ye = F(["auto", "edges"], (
|
|
7463
|
+
})), D = i.guides.axes.find((w) => w.scaleAestheticKey === e)?.position, E = Pp[D === "bottom" || D === "top" || D === void 0 && e === "x" ? "horizontal" : "vertical"], N = e === "y" ? pl(i.spec) : null, T = N === null ? void 0 : i.spec.layers.find((w) => w.id === N), b = i.guides.legends.drawn.some((w) => E.some((ue) => ue === w.position)), Z = E.map((w) => ({
|
|
7464
|
+
value: w,
|
|
7465
|
+
label: l(Ip[w])
|
|
7466
|
+
})), ye = F(["auto", "edges"], (w) => l(w === "edges" ? "editor.axesPanel.labelMode.edges" : "editor.axesPanel.labelMode.auto")), _e = F(["linear", "log"], (w) => l(w === "log" ? "editor.axesPanel.scale.log" : "editor.axesPanel.scale.auto")), $a = F([
|
|
7457
7467
|
"auto",
|
|
7458
7468
|
"zero",
|
|
7459
7469
|
"custom"
|
|
7460
|
-
], (
|
|
7470
|
+
], (w) => l(w === "zero" ? "editor.axesPanel.startFrom.zero" : w === "custom" ? "editor.axesPanel.startFrom.custom" : "editor.axesPanel.startFrom.auto")), Ua = F(["auto", "custom"], (w) => l(w === "custom" ? "editor.axesPanel.endAt.custom" : "editor.axesPanel.endAt.auto")), Wa = F(["no", "yes"], (w) => l(w === "yes" ? "editor.axesPanel.yesNo.yes" : "editor.axesPanel.yesNo.no")), Ka = F(["single", "double"], (w) => l(w === "double" ? "editor.axesPanel.axisCount.double" : "editor.axesPanel.axisCount.single")), qa = (w) => {
|
|
7461
7471
|
o.commands.dispatch(new ni({
|
|
7462
7472
|
axis: e,
|
|
7463
|
-
isVisible:
|
|
7473
|
+
isVisible: w
|
|
7464
7474
|
}));
|
|
7465
|
-
},
|
|
7475
|
+
}, Za = (w) => {
|
|
7466
7476
|
o.commands.dispatch(new Jo({
|
|
7467
7477
|
axis: e,
|
|
7468
|
-
label:
|
|
7478
|
+
label: w === "" ? null : w
|
|
7469
7479
|
}), { transient: !0 });
|
|
7470
|
-
},
|
|
7480
|
+
}, Xa = (w) => {
|
|
7471
7481
|
o.commands.dispatch(new ti({
|
|
7472
7482
|
axis: e,
|
|
7473
|
-
isVisible:
|
|
7483
|
+
isVisible: w
|
|
7474
7484
|
}));
|
|
7475
|
-
},
|
|
7485
|
+
}, ja = (w) => {
|
|
7476
7486
|
o.commands.dispatch(new ei({
|
|
7477
7487
|
axis: e,
|
|
7478
|
-
tickMode:
|
|
7488
|
+
tickMode: w === "edges" ? "edges" : "auto"
|
|
7479
7489
|
}));
|
|
7480
|
-
}, Ya = (
|
|
7490
|
+
}, Ya = (w) => {
|
|
7481
7491
|
o.commands.dispatch(new Pi({
|
|
7482
7492
|
scaledAesthetic: e,
|
|
7483
|
-
reverse:
|
|
7493
|
+
reverse: w === "yes"
|
|
7484
7494
|
}));
|
|
7485
|
-
}, Ja = (
|
|
7495
|
+
}, Ja = (w) => {
|
|
7486
7496
|
o.commands.dispatch(new Ii({
|
|
7487
7497
|
scaledAesthetic: e,
|
|
7488
|
-
transform:
|
|
7498
|
+
transform: w === "log" ? "log" : "linear"
|
|
7489
7499
|
}));
|
|
7490
|
-
}, Jt = (
|
|
7500
|
+
}, Jt = (w) => {
|
|
7491
7501
|
o.commands.dispatch(new He({
|
|
7492
7502
|
scaledAesthetic: e,
|
|
7493
|
-
...
|
|
7503
|
+
...w
|
|
7494
7504
|
}), { transient: !0 });
|
|
7495
|
-
}, Qa = (
|
|
7496
|
-
|
|
7497
|
-
}, eo = (
|
|
7498
|
-
|
|
7499
|
-
}, to = (
|
|
7505
|
+
}, Qa = (w) => {
|
|
7506
|
+
w !== null && Jt({ domainMin: w });
|
|
7507
|
+
}, eo = (w) => {
|
|
7508
|
+
w !== null && Jt({ domainMax: w });
|
|
7509
|
+
}, to = (w) => {
|
|
7500
7510
|
if (f) {
|
|
7501
|
-
if (
|
|
7511
|
+
if (w === "custom") {
|
|
7502
7512
|
f.zero && o.commands.dispatch(new ln({
|
|
7503
7513
|
scaledAesthetic: e,
|
|
7504
7514
|
zero: !1
|
|
@@ -7513,22 +7523,22 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7513
7523
|
domainMin: null
|
|
7514
7524
|
})), o.commands.dispatch(new ln({
|
|
7515
7525
|
scaledAesthetic: e,
|
|
7516
|
-
zero:
|
|
7526
|
+
zero: w === "zero"
|
|
7517
7527
|
}));
|
|
7518
7528
|
}
|
|
7519
|
-
}, no = (
|
|
7520
|
-
const ue =
|
|
7529
|
+
}, no = (w) => {
|
|
7530
|
+
const ue = w === "custom" ? zn(p?.domain, "end") : null;
|
|
7521
7531
|
o.commands.dispatch(new He({
|
|
7522
7532
|
scaledAesthetic: e,
|
|
7523
7533
|
domainMax: ue
|
|
7524
7534
|
}));
|
|
7525
|
-
}, ro = (
|
|
7526
|
-
|
|
7527
|
-
layerId:
|
|
7528
|
-
yScaleType:
|
|
7535
|
+
}, ro = (w) => {
|
|
7536
|
+
T !== void 0 && o.commands.dispatch(new gi({
|
|
7537
|
+
layerId: T.id,
|
|
7538
|
+
yScaleType: w === "double" ? "secondary" : "primary"
|
|
7529
7539
|
}));
|
|
7530
|
-
}, ao = (
|
|
7531
|
-
const ue = E.find((Fe) => Fe ===
|
|
7540
|
+
}, ao = (w) => {
|
|
7541
|
+
const ue = E.find((Fe) => Fe === w);
|
|
7532
7542
|
ue && o.commands.dispatch(new Qo({
|
|
7533
7543
|
axis: e,
|
|
7534
7544
|
position: ue
|
|
@@ -7546,26 +7556,26 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7546
7556
|
onChange: qa
|
|
7547
7557
|
})
|
|
7548
7558
|
}),
|
|
7549
|
-
|
|
7559
|
+
T !== void 0 && /* @__PURE__ */ n(S, {
|
|
7550
7560
|
label: l("editor.axesPanel.controls.numberOfAxes"),
|
|
7551
7561
|
children: /* @__PURE__ */ n(d, {
|
|
7552
|
-
value:
|
|
7562
|
+
value: T.yScaleType === "secondary" ? "double" : "single",
|
|
7553
7563
|
options: Ka,
|
|
7554
7564
|
onChange: ro
|
|
7555
7565
|
})
|
|
7556
7566
|
}),
|
|
7557
|
-
h === "linear" && /* @__PURE__ */ m(
|
|
7567
|
+
h === "linear" && /* @__PURE__ */ m(j, { children: [/* @__PURE__ */ n(S, {
|
|
7558
7568
|
label: l("editor.axesPanel.controls.title"),
|
|
7559
7569
|
children: /* @__PURE__ */ n(u, {
|
|
7560
7570
|
value: v.label ?? "",
|
|
7561
|
-
onChange:
|
|
7571
|
+
onChange: Za,
|
|
7562
7572
|
onCommit: o.commands.seal
|
|
7563
7573
|
})
|
|
7564
7574
|
}), /* @__PURE__ */ n(S, {
|
|
7565
7575
|
label: l("editor.axesPanel.controls.ticks"),
|
|
7566
7576
|
children: /* @__PURE__ */ n(c, {
|
|
7567
7577
|
isChecked: v.ticks.isVisible,
|
|
7568
|
-
onChange:
|
|
7578
|
+
onChange: Xa
|
|
7569
7579
|
})
|
|
7570
7580
|
})] }),
|
|
7571
7581
|
P && /* @__PURE__ */ n(S, {
|
|
@@ -7573,14 +7583,14 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7573
7583
|
children: /* @__PURE__ */ n(d, {
|
|
7574
7584
|
value: v.ticks.mode,
|
|
7575
7585
|
options: ye,
|
|
7576
|
-
onChange:
|
|
7586
|
+
onChange: ja
|
|
7577
7587
|
})
|
|
7578
7588
|
}),
|
|
7579
7589
|
f && h === "linear" && !b && /* @__PURE__ */ n(S, {
|
|
7580
7590
|
label: l("editor.axesPanel.controls.position"),
|
|
7581
7591
|
children: /* @__PURE__ */ n(d, {
|
|
7582
|
-
value:
|
|
7583
|
-
options:
|
|
7592
|
+
value: D ?? v.position,
|
|
7593
|
+
options: Z,
|
|
7584
7594
|
onChange: ao
|
|
7585
7595
|
})
|
|
7586
7596
|
}),
|
|
@@ -7600,15 +7610,15 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7600
7610
|
onChange: Ja
|
|
7601
7611
|
})
|
|
7602
7612
|
}),
|
|
7603
|
-
f && !A && /* @__PURE__ */ m(
|
|
7604
|
-
!C && /* @__PURE__ */ m(
|
|
7613
|
+
f && !A && /* @__PURE__ */ m(j, { children: [
|
|
7614
|
+
!C && /* @__PURE__ */ m(j, { children: [/* @__PURE__ */ n(S, {
|
|
7605
7615
|
label: l("editor.axesPanel.controls.startFrom"),
|
|
7606
7616
|
children: /* @__PURE__ */ n(d, {
|
|
7607
|
-
value:
|
|
7617
|
+
value: R,
|
|
7608
7618
|
options: $a,
|
|
7609
7619
|
onChange: to
|
|
7610
7620
|
})
|
|
7611
|
-
}),
|
|
7621
|
+
}), R === "custom" && /* @__PURE__ */ n(S, {
|
|
7612
7622
|
label: l("editor.axesPanel.controls.value"),
|
|
7613
7623
|
children: /* @__PURE__ */ n(s, {
|
|
7614
7624
|
value: f.domainMin ?? null,
|
|
@@ -7635,10 +7645,10 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7635
7645
|
] })
|
|
7636
7646
|
] })
|
|
7637
7647
|
});
|
|
7638
|
-
},
|
|
7648
|
+
}, Mp = (e) => e === void 0 ? "auto" : e.domainMin !== null && e.domainMin !== void 0 ? "custom" : e.zero === !0 ? "zero" : "auto", zn = (e, t) => {
|
|
7639
7649
|
const r = t === "start" ? e?.[0] : e?.[e.length - 1];
|
|
7640
7650
|
return typeof r == "number" ? r : 0;
|
|
7641
|
-
},
|
|
7651
|
+
}, jt = ({ value: e, onChange: t }) => {
|
|
7642
7652
|
const r = H(), a = k(), { TextField: o } = B(), i = e !== null && typeof e != "string", l = (s) => t(s === "" ? null : s);
|
|
7643
7653
|
return /* @__PURE__ */ n(S, {
|
|
7644
7654
|
label: a("editor.elementsPanel.contentValue"),
|
|
@@ -7649,7 +7659,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7649
7659
|
isDisabled: i
|
|
7650
7660
|
})
|
|
7651
7661
|
});
|
|
7652
|
-
},
|
|
7662
|
+
}, Np = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
7653
7663
|
const a = H(), o = $(a), i = k(), { Switch: l } = B();
|
|
7654
7664
|
if (!o) return null;
|
|
7655
7665
|
const s = o.config.content, c = (d) => {
|
|
@@ -7670,12 +7680,12 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7670
7680
|
isChecked: s.isCaptionVisible,
|
|
7671
7681
|
onChange: c
|
|
7672
7682
|
})
|
|
7673
|
-
}), /* @__PURE__ */ n(
|
|
7683
|
+
}), /* @__PURE__ */ n(jt, {
|
|
7674
7684
|
value: s.caption,
|
|
7675
7685
|
onChange: u
|
|
7676
7686
|
})] })
|
|
7677
7687
|
});
|
|
7678
|
-
}, _n = /^[a-z][a-z\d+.-]*:/i, Op = {},
|
|
7688
|
+
}, _n = /^[a-z][a-z\d+.-]*:/i, Op = {}, Rp = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
7679
7689
|
const a = H(), o = $(a), i = k(), { Switch: l } = B();
|
|
7680
7690
|
if (!o) return null;
|
|
7681
7691
|
const s = o.config.content, c = (u) => {
|
|
@@ -7694,9 +7704,9 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7694
7704
|
isChecked: s.isSourceVisible,
|
|
7695
7705
|
onChange: c
|
|
7696
7706
|
})
|
|
7697
|
-
}), /* @__PURE__ */ n(
|
|
7707
|
+
}), /* @__PURE__ */ n(Dp, { source: s.source ?? Op })] })
|
|
7698
7708
|
});
|
|
7699
|
-
},
|
|
7709
|
+
}, Dp = ({ source: e }) => {
|
|
7700
7710
|
const t = H(), r = k(), { TextField: a } = B(), o = (c) => {
|
|
7701
7711
|
const u = (c.label ?? "") !== "" || (c.url ?? "") !== "";
|
|
7702
7712
|
t.commands.dispatch(new oi({ source: u ? c : null }), { transient: !0 });
|
|
@@ -7713,7 +7723,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7713
7723
|
...e,
|
|
7714
7724
|
label: c
|
|
7715
7725
|
});
|
|
7716
|
-
return /* @__PURE__ */ m(
|
|
7726
|
+
return /* @__PURE__ */ m(j, { children: [/* @__PURE__ */ n(S, {
|
|
7717
7727
|
label: r("editor.elementsPanel.sourceSection.url"),
|
|
7718
7728
|
children: /* @__PURE__ */ n(a, {
|
|
7719
7729
|
value: e.url ?? "",
|
|
@@ -7750,7 +7760,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7750
7760
|
isChecked: s.isSubtitleVisible,
|
|
7751
7761
|
onChange: c
|
|
7752
7762
|
})
|
|
7753
|
-
}), /* @__PURE__ */ n(
|
|
7763
|
+
}), /* @__PURE__ */ n(jt, {
|
|
7754
7764
|
value: s.subtitle,
|
|
7755
7765
|
onChange: u
|
|
7756
7766
|
})] })
|
|
@@ -7809,24 +7819,24 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7809
7819
|
isChecked: s.isTitleVisible,
|
|
7810
7820
|
onChange: c
|
|
7811
7821
|
})
|
|
7812
|
-
}), /* @__PURE__ */ n(
|
|
7822
|
+
}), /* @__PURE__ */ n(jt, {
|
|
7813
7823
|
value: s.title,
|
|
7814
7824
|
onChange: u
|
|
7815
7825
|
})] })
|
|
7816
7826
|
});
|
|
7817
|
-
},
|
|
7827
|
+
}, e0 = ({ children: e, ...t }) => /* @__PURE__ */ n(_a.Root, {
|
|
7818
7828
|
...t,
|
|
7819
|
-
children: e ?? /* @__PURE__ */ m(
|
|
7829
|
+
children: e ?? /* @__PURE__ */ m(j, { children: [
|
|
7820
7830
|
/* @__PURE__ */ n(Hp, {}),
|
|
7821
7831
|
/* @__PURE__ */ n(zp, {}),
|
|
7822
|
-
/* @__PURE__ */ n(
|
|
7823
|
-
/* @__PURE__ */ n(
|
|
7832
|
+
/* @__PURE__ */ n(Np, {}),
|
|
7833
|
+
/* @__PURE__ */ n(Rp, {}),
|
|
7824
7834
|
/* @__PURE__ */ n(Fp, {})
|
|
7825
7835
|
] })
|
|
7826
|
-
}),
|
|
7836
|
+
}), t0 = ({ children: e, ...t }) => /* @__PURE__ */ n(_a.Root, {
|
|
7827
7837
|
...t,
|
|
7828
|
-
children: e ?? /* @__PURE__ */ m(
|
|
7829
|
-
}), dt = (e) => `${e}px`, Ha = (e) => `${Math.round(e * 100)}%`, Bp = (e) => `${e}°`, Vp = 24, Gp = { select: { target: "graph" } }, Fn = ["dim", "desaturate"],
|
|
7838
|
+
children: e ?? /* @__PURE__ */ m(j, { children: [/* @__PURE__ */ n(Dn, { axis: "x" }), /* @__PURE__ */ n(Dn, { axis: "y" })] })
|
|
7839
|
+
}), dt = (e) => `${e}px`, Ha = (e) => `${Math.round(e * 100)}%`, Bp = (e) => `${e}°`, Vp = 24, Gp = { select: { target: "graph" } }, Fn = ["dim", "desaturate"], n0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
7830
7840
|
const a = H(), o = $(a), i = k(), { Slider: l, ToggleGroup: s } = B();
|
|
7831
7841
|
if (!o) return null;
|
|
7832
7842
|
const c = at().chromeReaders(o.chrome).graph.get("borderRadius"), u = ml(o.spec), d = Fn.map((p) => ({
|
|
@@ -7834,7 +7844,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7834
7844
|
label: i(p === "dim" ? "editor.highlighting.highlightStyle.tint" : "editor.highlighting.highlightStyle.grey")
|
|
7835
7845
|
})), h = (p) => {
|
|
7836
7846
|
const g = Te(o.spec.styles.overrides, Gp)?.declarations ?? {};
|
|
7837
|
-
a.commands.dispatch(new
|
|
7847
|
+
a.commands.dispatch(new Ne({
|
|
7838
7848
|
list: "overrides",
|
|
7839
7849
|
rule: {
|
|
7840
7850
|
select: { target: "graph" },
|
|
@@ -7874,7 +7884,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7874
7884
|
});
|
|
7875
7885
|
}, Yt = (e, t) => {
|
|
7876
7886
|
const { colorScheme: r } = nt();
|
|
7877
|
-
return
|
|
7887
|
+
return M(() => {
|
|
7878
7888
|
const a = e?.layers.find((o) => o.id === t);
|
|
7879
7889
|
return a === void 0 ? null : at({ colorScheme: r }).geomReaders(a);
|
|
7880
7890
|
}, [
|
|
@@ -7882,7 +7892,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7882
7892
|
t,
|
|
7883
7893
|
r
|
|
7884
7894
|
]);
|
|
7885
|
-
}, $p = 0.05,
|
|
7895
|
+
}, $p = 0.05, r0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
7886
7896
|
const a = H(), o = $(a), i = k(), { Slider: l, ToggleGroup: s } = B(), c = o ? hr(o.spec.layers, "bar") : void 0, u = Yt(o, c?.id ?? null);
|
|
7887
7897
|
if (!o || !c || o.coordSystem.type === "polar" && o.coordSystem.bandAxis === null) return null;
|
|
7888
7898
|
const d = (g) => {
|
|
@@ -7927,7 +7937,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7927
7937
|
});
|
|
7928
7938
|
}, ut = ({ children: e }) => {
|
|
7929
7939
|
const t = Ae();
|
|
7930
|
-
return /* @__PURE__ */ m(
|
|
7940
|
+
return /* @__PURE__ */ m(j, { children: [/* @__PURE__ */ n("g", {
|
|
7931
7941
|
filter: `url(#${t})`,
|
|
7932
7942
|
children: e
|
|
7933
7943
|
}), /* @__PURE__ */ n("defs", { children: /* @__PURE__ */ m("filter", {
|
|
@@ -7950,7 +7960,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7950
7960
|
floodOpacity: "0.16"
|
|
7951
7961
|
})]
|
|
7952
7962
|
}) })] });
|
|
7953
|
-
}, ht = "qdaoth0", Up = (e) => /* @__PURE__ */ m(
|
|
7963
|
+
}, ht = "qdaoth0", Up = (e) => /* @__PURE__ */ m(x, {
|
|
7954
7964
|
viewBox: "0 0 31 33",
|
|
7955
7965
|
...e,
|
|
7956
7966
|
children: [/* @__PURE__ */ n(ut, { children: /* @__PURE__ */ n("path", {
|
|
@@ -7962,7 +7972,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7962
7972
|
fill: "currentColor",
|
|
7963
7973
|
d: "M12.0591 7.11C11.5767 7.11 11.1857 6.71899 11.1857 6.23664C11.1857 5.7543 11.5767 5.36328 12.0591 5.36328H24.8684C25.3507 5.36328 25.7417 5.7543 25.7417 6.23664V19.0459C25.7417 19.5283 25.3507 19.9193 24.8684 19.9193C24.386 19.9193 23.995 19.5283 23.995 19.0459V8.34512L6.8542 25.4859C6.51313 25.827 5.96015 25.827 5.61908 25.4859C5.27801 25.1448 5.27801 24.5919 5.61908 24.2508L22.7599 7.11H12.0591Z"
|
|
7964
7974
|
})]
|
|
7965
|
-
}), Wp = (e) => /* @__PURE__ */ n(
|
|
7975
|
+
}), Wp = (e) => /* @__PURE__ */ n(x, {
|
|
7966
7976
|
viewBox: "0 0 32 32",
|
|
7967
7977
|
...e,
|
|
7968
7978
|
children: /* @__PURE__ */ m(ut, { children: [/* @__PURE__ */ n("path", {
|
|
@@ -7972,7 +7982,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7972
7982
|
fill: "currentColor",
|
|
7973
7983
|
d: "M24.25 9C24.25 8.30964 23.6904 7.75 23 7.75H9C8.30964 7.75 7.75 8.30964 7.75 9V23C7.75 23.6904 8.30964 24.25 9 24.25H23C23.6904 24.25 24.25 23.6904 24.25 23V9ZM25.75 23C25.75 24.5188 24.5188 25.75 23 25.75H9C7.48122 25.75 6.25 24.5188 6.25 23V9C6.25 7.48122 7.48122 6.25 9 6.25H23C24.5188 6.25 25.75 7.48122 25.75 9V23Z"
|
|
7974
7984
|
})] })
|
|
7975
|
-
}), Kp = (e) => /* @__PURE__ */ m(
|
|
7985
|
+
}), Kp = (e) => /* @__PURE__ */ m(x, {
|
|
7976
7986
|
viewBox: "0 0 32 33",
|
|
7977
7987
|
...e,
|
|
7978
7988
|
children: [/* @__PURE__ */ n(ut, { children: /* @__PURE__ */ n("path", {
|
|
@@ -7986,7 +7996,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7986
7996
|
clipRule: "evenodd",
|
|
7987
7997
|
d: "M25.25 22C25.25 20.7574 24.2426 19.75 23 19.75C21.7574 19.75 20.75 20.7574 20.75 22C20.75 23.2426 21.7574 24.25 23 24.25C24.2426 24.25 25.25 23.2426 25.25 22ZM23 18.25C25.0711 18.25 26.75 19.9289 26.75 22C26.75 24.0711 25.0711 25.75 23 25.75C20.9289 25.75 19.25 24.0711 19.25 22C19.25 19.9289 20.9289 18.25 23 18.25ZM11.25 9C11.25 7.75736 10.2426 6.75 9 6.75C7.75736 6.75 6.75 7.75736 6.75 9C6.75 10.2426 7.75736 11.25 9 11.25C10.2426 11.25 11.25 10.2426 11.25 9ZM9.75 12.675C11.4617 12.3275 12.75 10.8142 12.75 9C12.75 6.92893 11.0711 5.25 9 5.25C6.92893 5.25 5.25 6.92893 5.25 9C5.25 10.8142 6.53832 12.3275 8.25 12.675L8.25 24C8.25 24.4142 8.58579 24.75 9 24.75L16 24.75C16.4142 24.75 16.75 24.4142 16.75 24L16.75 7.75L22.25 7.75L22.25 14.1893L21.0303 12.9697C20.7374 12.6768 20.2626 12.6768 19.9697 12.9697C19.6768 13.2626 19.6768 13.7374 19.9697 14.0303L22.4697 16.5303C22.7626 16.8232 23.2374 16.8232 23.5303 16.5303L26.0303 14.0303C26.3232 13.7374 26.3232 13.2626 26.0303 12.9697C25.7374 12.6768 25.2626 12.6768 24.9697 12.9697L23.75 14.1893L23.75 7C23.75 6.58579 23.4142 6.25 23 6.25L16 6.25C15.5858 6.25 15.25 6.58579 15.25 7L15.25 23.25L9.75 23.25L9.75 12.675Z"
|
|
7988
7998
|
})]
|
|
7989
|
-
}), qp = (e) => /* @__PURE__ */ m(
|
|
7999
|
+
}), qp = (e) => /* @__PURE__ */ m(x, {
|
|
7990
8000
|
viewBox: "0 0 32 33",
|
|
7991
8001
|
...e,
|
|
7992
8002
|
children: [/* @__PURE__ */ n(ut, { children: /* @__PURE__ */ n("path", {
|
|
@@ -7996,10 +8006,10 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
7996
8006
|
fill: "currentColor",
|
|
7997
8007
|
d: "M8.41371 5H20.7271C21.1595 5 21.5325 5 21.8398 5.02507C22.1641 5.05157 22.4867 5.11007 22.7971 5.26822C23.2601 5.50416 23.6366 5.88064 23.8726 6.3437C24.0307 6.65409 24.0892 6.97666 24.1157 7.30097C24.1408 7.60823 24.1408 7.98127 24.1408 8.41369V9.10155C24.1408 9.55465 23.7735 9.92195 23.3205 9.92195C22.8674 9.92195 22.5001 9.55465 22.5001 9.10155V8.44533C22.5001 7.97237 22.4995 7.66699 22.4805 7.43457C22.4623 7.21172 22.4314 7.12909 22.4107 7.08853C22.3321 6.93418 22.2066 6.80869 22.0522 6.73004C22.0117 6.70938 21.9291 6.67847 21.7062 6.66026C21.4738 6.64127 21.1684 6.64063 20.6954 6.64063H15.3907V24.6877H20.0392C20.4922 24.6877 20.8595 25.0549 20.8595 25.508C20.8595 25.961 20.4922 26.3283 20.0392 26.3283H9.10159C8.64854 26.3283 8.28127 25.961 8.28127 25.508C8.28127 25.0549 8.64854 24.6877 9.10159 24.6877H13.7501V6.64063H8.44533C7.97238 6.64063 7.66699 6.64127 7.43457 6.66026C7.21172 6.67847 7.1291 6.70938 7.08854 6.73004C6.93418 6.80869 6.80869 6.93418 6.73004 7.08853C6.70938 7.12909 6.67847 7.21172 6.66026 7.43457C6.64127 7.66699 6.64063 7.97237 6.64063 8.44533V9.10155C6.64063 9.55465 6.27337 9.92195 5.82032 9.92195C5.36727 9.92195 5 9.55465 5 9.10155V8.41371C5 7.98128 5 7.60823 5.02508 7.30097C5.05157 6.97666 5.11007 6.65409 5.26823 6.3437C5.50417 5.88064 5.88064 5.50416 6.3437 5.26822C6.65409 5.11007 6.97666 5.05157 7.30097 5.02507C7.60824 5 7.98129 5 8.41371 5Z"
|
|
7998
8008
|
})]
|
|
7999
|
-
}),
|
|
8009
|
+
}), Zp = {
|
|
8000
8010
|
x: 0.5,
|
|
8001
8011
|
y: 0.5
|
|
8002
|
-
},
|
|
8012
|
+
}, Xp = 0.2, jp = {
|
|
8003
8013
|
x: 0.375,
|
|
8004
8014
|
y: 0.25,
|
|
8005
8015
|
width: 0.25,
|
|
@@ -8010,20 +8020,20 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8010
8020
|
}, Qp = {
|
|
8011
8021
|
x: 0.6,
|
|
8012
8022
|
y: 0.4
|
|
8013
|
-
}, e2 = "relative-difference",
|
|
8023
|
+
}, e2 = "relative-difference", a0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
8014
8024
|
const a = H(), o = $(a), i = k(), { Button: l } = B();
|
|
8015
8025
|
if (!o) return null;
|
|
8016
8026
|
const s = () => {
|
|
8017
8027
|
a.commands.dispatch(new pe({
|
|
8018
8028
|
kind: "text",
|
|
8019
8029
|
annotation: {
|
|
8020
|
-
...
|
|
8030
|
+
...Mi,
|
|
8021
8031
|
content: t2(i("editor.annotatePanel.callOutSection.text")),
|
|
8022
8032
|
at: {
|
|
8023
8033
|
anchorType: "panel",
|
|
8024
|
-
...
|
|
8034
|
+
...Zp
|
|
8025
8035
|
},
|
|
8026
|
-
width:
|
|
8036
|
+
width: Xp
|
|
8027
8037
|
}
|
|
8028
8038
|
}));
|
|
8029
8039
|
}, c = () => {
|
|
@@ -8045,11 +8055,11 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8045
8055
|
a.commands.dispatch(new pe({
|
|
8046
8056
|
kind: "shape",
|
|
8047
8057
|
annotation: {
|
|
8048
|
-
...
|
|
8058
|
+
...jo,
|
|
8049
8059
|
...Yp,
|
|
8050
8060
|
region: {
|
|
8051
8061
|
anchorType: "panel",
|
|
8052
|
-
...
|
|
8062
|
+
...jp
|
|
8053
8063
|
}
|
|
8054
8064
|
}
|
|
8055
8065
|
}));
|
|
@@ -8068,7 +8078,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8068
8078
|
title: e ?? i("editor.annotatePanel.callOutSection.title"),
|
|
8069
8079
|
layout: t,
|
|
8070
8080
|
preview: r,
|
|
8071
|
-
children: /* @__PURE__ */ m(
|
|
8081
|
+
children: /* @__PURE__ */ m(Da, { children: [
|
|
8072
8082
|
/* @__PURE__ */ n(l, {
|
|
8073
8083
|
variant: "tile",
|
|
8074
8084
|
icon: /* @__PURE__ */ n(qp, { size: "xl" }),
|
|
@@ -8104,7 +8114,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8104
8114
|
text: e
|
|
8105
8115
|
}]
|
|
8106
8116
|
}]
|
|
8107
|
-
}),
|
|
8117
|
+
}), o0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
8108
8118
|
const a = H(), o = $(a), i = k(), { ToggleGroup: l } = B();
|
|
8109
8119
|
if (!o) return null;
|
|
8110
8120
|
const s = gr(o.spec);
|
|
@@ -8130,11 +8140,11 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8130
8140
|
ariaLabel: i("editor.graphPanel.comboSection.title")
|
|
8131
8141
|
})
|
|
8132
8142
|
});
|
|
8133
|
-
}, n2 = 0.1, r2 = 20,
|
|
8143
|
+
}, n2 = 0.1, r2 = 20, i0 = ({ title: e, preview: t }) => {
|
|
8134
8144
|
const r = H(), a = $(r), o = k(), { NumberField: i, TextField: l } = B();
|
|
8135
8145
|
if (!a || a.coordSystem.type === "polar") return null;
|
|
8136
8146
|
const s = nl(a.spec.layers), c = e ?? o("editor.annotationsPanel.goalSection.title"), u = Ji(s?.mapping.y), d = typeof u == "number" ? u : null, h = (g) => {
|
|
8137
|
-
const f = new
|
|
8147
|
+
const f = new Di({
|
|
8138
8148
|
showGoalLine: g,
|
|
8139
8149
|
value: a2(a),
|
|
8140
8150
|
...s !== void 0 && { layerId: s.id }
|
|
@@ -8187,35 +8197,35 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8187
8197
|
if (o === 0) return 0;
|
|
8188
8198
|
const i = Math.min(r2, Math.max(0, 1 - Math.floor(Math.log10(o))));
|
|
8189
8199
|
return Number((r + o * n2).toFixed(i));
|
|
8190
|
-
},
|
|
8200
|
+
}, l0 = ({ layerId: e, title: t, layout: r = "collapsible", preview: a }) => {
|
|
8191
8201
|
const o = H(), i = $(o), l = k(), { Switch: s } = B();
|
|
8192
8202
|
if (!i) return null;
|
|
8193
|
-
const c = e === void 0 ? i.spec.layers[0] : i.spec.layers.find((
|
|
8203
|
+
const c = e === void 0 ? i.spec.layers[0] : i.spec.layers.find((D) => D.id === e);
|
|
8194
8204
|
if (!c) return null;
|
|
8195
8205
|
const { showDataLabels: u, format: d, showStackTotals: h, showCategoryLabels: v } = c.dataLabels, p = i.coordSystem.type === "polar", g = c.geom === "bar", f = c.position === "stack" || c.position === "fill", y = g && !p && c.position === "stack", P = g && (!p || u), C = g || c.geom === "area" && f;
|
|
8196
8206
|
if (!qi(c.geom, i.coordSystem.type)) return null;
|
|
8197
|
-
const A = (
|
|
8198
|
-
const E = new
|
|
8207
|
+
const A = (D) => {
|
|
8208
|
+
const E = new Ri({
|
|
8199
8209
|
layerId: c.id,
|
|
8200
|
-
showDataLabels:
|
|
8210
|
+
showDataLabels: D
|
|
8201
8211
|
});
|
|
8202
8212
|
o.commands.dispatch(E);
|
|
8203
|
-
}, L = (
|
|
8213
|
+
}, L = (D) => {
|
|
8204
8214
|
const E = new ii({
|
|
8205
8215
|
layerId: c.id,
|
|
8206
|
-
format:
|
|
8216
|
+
format: D ? "percentage" : "absolute"
|
|
8207
8217
|
});
|
|
8208
8218
|
o.commands.dispatch(E);
|
|
8209
|
-
},
|
|
8219
|
+
}, R = (D) => {
|
|
8210
8220
|
const E = new Fi({
|
|
8211
8221
|
layerId: c.id,
|
|
8212
|
-
showStackTotals:
|
|
8222
|
+
showStackTotals: D
|
|
8213
8223
|
});
|
|
8214
8224
|
o.commands.dispatch(E);
|
|
8215
|
-
}, F = (
|
|
8225
|
+
}, F = (D) => {
|
|
8216
8226
|
const E = new Oi({
|
|
8217
8227
|
layerId: c.id,
|
|
8218
|
-
showCategoryLabels:
|
|
8228
|
+
showCategoryLabels: D
|
|
8219
8229
|
});
|
|
8220
8230
|
o.commands.dispatch(E);
|
|
8221
8231
|
};
|
|
@@ -8242,7 +8252,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8242
8252
|
label: l("editor.graphPanel.graphOptions.stackTotals"),
|
|
8243
8253
|
children: /* @__PURE__ */ n(s, {
|
|
8244
8254
|
isChecked: h,
|
|
8245
|
-
onChange:
|
|
8255
|
+
onChange: R
|
|
8246
8256
|
})
|
|
8247
8257
|
}),
|
|
8248
8258
|
P && /* @__PURE__ */ n(S, {
|
|
@@ -8254,7 +8264,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8254
8264
|
})
|
|
8255
8265
|
] })
|
|
8256
8266
|
});
|
|
8257
|
-
}, o2 = (e) => /* @__PURE__ */ m(
|
|
8267
|
+
}, o2 = (e) => /* @__PURE__ */ m(x, {
|
|
8258
8268
|
viewBox: "0 0 16 16",
|
|
8259
8269
|
...e,
|
|
8260
8270
|
children: [/* @__PURE__ */ n("path", {
|
|
@@ -8266,7 +8276,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8266
8276
|
fillOpacity: "0.3",
|
|
8267
8277
|
d: "M5.744 5.565 0 11.826V8l5.744-6.957 4.718 2.087L16 0v6.957l-5.538 4z"
|
|
8268
8278
|
})]
|
|
8269
|
-
}), i2 = (e) => /* @__PURE__ */ n(
|
|
8279
|
+
}), i2 = (e) => /* @__PURE__ */ n(x, {
|
|
8270
8280
|
viewBox: "0 0 16 16",
|
|
8271
8281
|
...e,
|
|
8272
8282
|
children: /* @__PURE__ */ m("g", {
|
|
@@ -8308,7 +8318,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8308
8318
|
})
|
|
8309
8319
|
]
|
|
8310
8320
|
})
|
|
8311
|
-
}), l2 = (e) => /* @__PURE__ */ n(
|
|
8321
|
+
}), l2 = (e) => /* @__PURE__ */ n(x, {
|
|
8312
8322
|
viewBox: "0 0 16 16",
|
|
8313
8323
|
...e,
|
|
8314
8324
|
children: /* @__PURE__ */ m("g", {
|
|
@@ -8323,7 +8333,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8323
8333
|
d: "M0 12.445h4.267V.52A.52.52 0 0 0 3.748 0H.518A.52.52 0 0 0 0 .519zM5.867 7.111h4.266V.52A.52.52 0 0 0 9.615 0h-3.23a.52.52 0 0 0-.518.519zM11.733 9.481H16V.52A.52.52 0 0 0 15.482 0h-3.23a.52.52 0 0 0-.519.519z"
|
|
8324
8334
|
})]
|
|
8325
8335
|
})
|
|
8326
|
-
}), s2 = (e) => /* @__PURE__ */ n(
|
|
8336
|
+
}), s2 = (e) => /* @__PURE__ */ n(x, {
|
|
8327
8337
|
viewBox: "0 0 16 16",
|
|
8328
8338
|
...e,
|
|
8329
8339
|
children: /* @__PURE__ */ m("g", {
|
|
@@ -8338,7 +8348,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8338
8348
|
d: "M0 7.037c0-.286.232-.518.519-.518h3.23c.286 0 .518.232.518.518v5.408H0zM5.867 7.111h4.266V4.074a.52.52 0 0 0-.518-.518h-3.23a.52.52 0 0 0-.518.518zM11.733 9.481H16V.52A.52.52 0 0 0 15.482 0h-3.23a.52.52 0 0 0-.519.519z"
|
|
8339
8349
|
})]
|
|
8340
8350
|
})
|
|
8341
|
-
}), c2 = (e) => /* @__PURE__ */ m(
|
|
8351
|
+
}), c2 = (e) => /* @__PURE__ */ m(x, {
|
|
8342
8352
|
viewBox: "0 0 16 16",
|
|
8343
8353
|
...e,
|
|
8344
8354
|
children: [
|
|
@@ -8377,7 +8387,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8377
8387
|
rx: ".533"
|
|
8378
8388
|
})
|
|
8379
8389
|
]
|
|
8380
|
-
}), d2 = (e) => /* @__PURE__ */ m(
|
|
8390
|
+
}), d2 = (e) => /* @__PURE__ */ m(x, {
|
|
8381
8391
|
viewBox: "0 0 16 16",
|
|
8382
8392
|
...e,
|
|
8383
8393
|
children: [/* @__PURE__ */ n("path", {
|
|
@@ -8389,7 +8399,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8389
8399
|
fillOpacity: "0.3",
|
|
8390
8400
|
d: "M0 12.445h4.267V.52A.52.52 0 0 0 3.748 0H.518A.52.52 0 0 0 0 .519zM5.867 7.111h4.266V.52A.52.52 0 0 0 9.615 0h-3.23a.52.52 0 0 0-.518.519zM11.733 9.481H16V.52A.52.52 0 0 0 15.482 0h-3.23a.52.52 0 0 0-.519.519z"
|
|
8391
8401
|
})]
|
|
8392
|
-
}), u2 = (e) => /* @__PURE__ */ m(
|
|
8402
|
+
}), u2 = (e) => /* @__PURE__ */ m(x, {
|
|
8393
8403
|
viewBox: "0 0 16 16",
|
|
8394
8404
|
...e,
|
|
8395
8405
|
children: [/* @__PURE__ */ n("path", {
|
|
@@ -8401,7 +8411,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8401
8411
|
fillOpacity: "0.3",
|
|
8402
8412
|
d: "M0 7.037c0-.286.232-.518.519-.518h3.23c.286 0 .518.232.518.518v5.408H0zM5.867 7.111h4.266V4.074a.52.52 0 0 0-.518-.518h-3.23a.52.52 0 0 0-.518.518zM11.733 9.481H16V.52A.52.52 0 0 0 15.482 0h-3.23a.52.52 0 0 0-.519.519z"
|
|
8403
8413
|
})]
|
|
8404
|
-
}), h2 = (e) => /* @__PURE__ */ m(
|
|
8414
|
+
}), h2 = (e) => /* @__PURE__ */ m(x, {
|
|
8405
8415
|
viewBox: "0 0 16 16",
|
|
8406
8416
|
...e,
|
|
8407
8417
|
children: [/* @__PURE__ */ m("g", {
|
|
@@ -8475,7 +8485,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8475
8485
|
})
|
|
8476
8486
|
]
|
|
8477
8487
|
})]
|
|
8478
|
-
}), p2 = (e) => /* @__PURE__ */ n(
|
|
8488
|
+
}), p2 = (e) => /* @__PURE__ */ n(x, {
|
|
8479
8489
|
viewBox: "0 0 16 16",
|
|
8480
8490
|
...e,
|
|
8481
8491
|
children: /* @__PURE__ */ m("g", {
|
|
@@ -8510,7 +8520,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8510
8520
|
})
|
|
8511
8521
|
]
|
|
8512
8522
|
})
|
|
8513
|
-
}), m2 = (e) => /* @__PURE__ */ n(
|
|
8523
|
+
}), m2 = (e) => /* @__PURE__ */ n(x, {
|
|
8514
8524
|
viewBox: "0 0 16 16",
|
|
8515
8525
|
...e,
|
|
8516
8526
|
children: /* @__PURE__ */ m("g", {
|
|
@@ -8587,7 +8597,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8587
8597
|
})
|
|
8588
8598
|
]
|
|
8589
8599
|
})
|
|
8590
|
-
}), g2 = (e) => /* @__PURE__ */ n(
|
|
8600
|
+
}), g2 = (e) => /* @__PURE__ */ n(x, {
|
|
8591
8601
|
viewBox: "0 0 16 16",
|
|
8592
8602
|
...e,
|
|
8593
8603
|
children: /* @__PURE__ */ m("g", {
|
|
@@ -8664,7 +8674,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8664
8674
|
]
|
|
8665
8675
|
})]
|
|
8666
8676
|
})
|
|
8667
|
-
}), v2 = (e) => /* @__PURE__ */ m(
|
|
8677
|
+
}), v2 = (e) => /* @__PURE__ */ m(x, {
|
|
8668
8678
|
viewBox: "0 0 16 16",
|
|
8669
8679
|
...e,
|
|
8670
8680
|
children: [
|
|
@@ -8686,7 +8696,115 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8686
8696
|
d: "M15.999 8a8 8 0 0 1-7.588 7.989l-.412.01V8z"
|
|
8687
8697
|
})
|
|
8688
8698
|
]
|
|
8689
|
-
}), f2 = (e) => /* @__PURE__ */ n(
|
|
8699
|
+
}), f2 = (e) => /* @__PURE__ */ n(x, {
|
|
8700
|
+
viewBox: "0 0 16 16",
|
|
8701
|
+
...e,
|
|
8702
|
+
children: /* @__PURE__ */ m("g", {
|
|
8703
|
+
fill: "none",
|
|
8704
|
+
stroke: "currentColor",
|
|
8705
|
+
strokeLinejoin: "round",
|
|
8706
|
+
children: [/* @__PURE__ */ n("polygon", {
|
|
8707
|
+
points: "8,0.5 15.13,5.68 12.41,14.07 3.59,14.07 0.87,5.68",
|
|
8708
|
+
strokeOpacity: "0.3",
|
|
8709
|
+
strokeWidth: ".8"
|
|
8710
|
+
}), /* @__PURE__ */ n("polygon", {
|
|
8711
|
+
points: "8,2.5 14.66,5.84 10.06,10.83 4.47,12.85 3.72,6.61",
|
|
8712
|
+
strokeOpacity: "0.8",
|
|
8713
|
+
strokeWidth: "1.2"
|
|
8714
|
+
})]
|
|
8715
|
+
})
|
|
8716
|
+
}), b2 = (e) => /* @__PURE__ */ m(x, {
|
|
8717
|
+
viewBox: "0 0 16 16",
|
|
8718
|
+
...e,
|
|
8719
|
+
children: [/* @__PURE__ */ n("polygon", {
|
|
8720
|
+
points: "8,0.5 15.13,5.68 12.41,14.07 3.59,14.07 0.87,5.68",
|
|
8721
|
+
fill: "none",
|
|
8722
|
+
stroke: "currentColor",
|
|
8723
|
+
strokeLinejoin: "round",
|
|
8724
|
+
strokeOpacity: "0.3",
|
|
8725
|
+
strokeWidth: ".8"
|
|
8726
|
+
}), /* @__PURE__ */ n("polygon", {
|
|
8727
|
+
points: "8,2.5 14.66,5.84 10.06,10.83 4.47,12.85 3.72,6.61",
|
|
8728
|
+
fill: "currentColor",
|
|
8729
|
+
fillOpacity: "0.6"
|
|
8730
|
+
})]
|
|
8731
|
+
}), C2 = (e) => /* @__PURE__ */ n(x, {
|
|
8732
|
+
viewBox: "0 0 16 16",
|
|
8733
|
+
...e,
|
|
8734
|
+
children: /* @__PURE__ */ m("g", {
|
|
8735
|
+
fill: "none",
|
|
8736
|
+
stroke: "currentColor",
|
|
8737
|
+
strokeWidth: "1.5",
|
|
8738
|
+
transform: "rotate(-90 8 8)",
|
|
8739
|
+
children: [
|
|
8740
|
+
/* @__PURE__ */ m("g", {
|
|
8741
|
+
strokeOpacity: "0.2",
|
|
8742
|
+
children: [
|
|
8743
|
+
/* @__PURE__ */ n("circle", {
|
|
8744
|
+
cx: "8",
|
|
8745
|
+
cy: "8",
|
|
8746
|
+
r: "6.6"
|
|
8747
|
+
}),
|
|
8748
|
+
/* @__PURE__ */ n("circle", {
|
|
8749
|
+
cx: "8",
|
|
8750
|
+
cy: "8",
|
|
8751
|
+
r: "4.4"
|
|
8752
|
+
}),
|
|
8753
|
+
/* @__PURE__ */ n("circle", {
|
|
8754
|
+
cx: "8",
|
|
8755
|
+
cy: "8",
|
|
8756
|
+
r: "2.2"
|
|
8757
|
+
})
|
|
8758
|
+
]
|
|
8759
|
+
}),
|
|
8760
|
+
/* @__PURE__ */ n("circle", {
|
|
8761
|
+
cx: "8",
|
|
8762
|
+
cy: "8",
|
|
8763
|
+
r: "6.6",
|
|
8764
|
+
pathLength: "100",
|
|
8765
|
+
strokeDasharray: "72 100",
|
|
8766
|
+
strokeOpacity: "0.8"
|
|
8767
|
+
}),
|
|
8768
|
+
/* @__PURE__ */ n("circle", {
|
|
8769
|
+
cx: "8",
|
|
8770
|
+
cy: "8",
|
|
8771
|
+
r: "4.4",
|
|
8772
|
+
pathLength: "100",
|
|
8773
|
+
strokeDasharray: "52 100",
|
|
8774
|
+
strokeOpacity: "0.6"
|
|
8775
|
+
}),
|
|
8776
|
+
/* @__PURE__ */ n("circle", {
|
|
8777
|
+
cx: "8",
|
|
8778
|
+
cy: "8",
|
|
8779
|
+
r: "2.2",
|
|
8780
|
+
pathLength: "100",
|
|
8781
|
+
strokeDasharray: "34 100",
|
|
8782
|
+
strokeOpacity: "0.45"
|
|
8783
|
+
})
|
|
8784
|
+
]
|
|
8785
|
+
})
|
|
8786
|
+
}), y2 = (e) => /* @__PURE__ */ n(x, {
|
|
8787
|
+
viewBox: "0 0 16 16",
|
|
8788
|
+
...e,
|
|
8789
|
+
children: /* @__PURE__ */ n("path", {
|
|
8790
|
+
fill: "currentColor",
|
|
8791
|
+
fillOpacity: "0.75",
|
|
8792
|
+
d: "M8.4 7.31 8.4 1.01A7 7 0 0 1 13.85 4.16ZM8.8 8 13.64 5.2A6.3 6.3 0 0 1 13.64 10.8ZM8.4 8.69 12.64 11.14A5.6 5.6 0 0 1 8.4 13.59ZM7.6 8.69 7.6 12.78A4.8 4.8 0 0 1 4.06 10.74ZM7.2 8 4.27 9.69A4.1 4.1 0 0 1 4.27 6.31ZM7.6 7.31 5.19 5.92A3.5 3.5 0 0 1 7.6 4.52Z"
|
|
8793
|
+
})
|
|
8794
|
+
}), S2 = (e) => /* @__PURE__ */ n(x, {
|
|
8795
|
+
viewBox: "0 0 16 16",
|
|
8796
|
+
...e,
|
|
8797
|
+
children: /* @__PURE__ */ m("g", {
|
|
8798
|
+
fill: "currentColor",
|
|
8799
|
+
children: [/* @__PURE__ */ n("path", {
|
|
8800
|
+
fillOpacity: "0.35",
|
|
8801
|
+
d: "M8.4 3.82 8.4 1.01A7 7 0 0 1 13.85 4.16L11.42 5.56A4.2 4.2 0 0 0 8.4 3.82ZM11.46 6.47 13.64 5.2A6.3 6.3 0 0 1 13.64 10.8L11.46 9.53A3.78 3.78 0 0 0 11.46 6.47ZM10.69 10.01 12.64 11.14A5.6 5.6 0 0 1 8.4 13.59L8.4 11.34A3.36 3.36 0 0 0 10.69 10.01ZM7.6 10.85 7.6 12.78A4.8 4.8 0 0 1 4.06 10.74L5.73 9.77A2.88 2.88 0 0 0 7.6 10.85ZM5.7 8.87 4.27 9.69A4.1 4.1 0 0 1 4.27 6.31L5.7 7.13A2.46 2.46 0 0 0 5.7 8.87ZM6.41 6.62 5.19 5.92A3.5 3.5 0 0 1 7.6 4.52L7.6 5.94A2.1 2.1 0 0 0 6.41 6.62Z"
|
|
8802
|
+
}), /* @__PURE__ */ n("path", {
|
|
8803
|
+
fillOpacity: "0.9",
|
|
8804
|
+
d: "M8.4 7.31 8.4 3.82A4.2 4.2 0 0 1 11.42 5.56ZM8.8 8 11.46 6.47A3.78 3.78 0 0 1 11.46 9.53ZM8.4 8.69 10.69 10.01A3.36 3.36 0 0 1 8.4 11.34ZM7.6 8.69 7.6 10.85A2.88 2.88 0 0 1 5.73 9.77ZM7.2 8 5.7 8.87A2.46 2.46 0 0 1 5.7 7.13ZM7.6 7.31 6.41 6.62A2.1 2.1 0 0 1 7.6 5.94Z"
|
|
8805
|
+
})]
|
|
8806
|
+
})
|
|
8807
|
+
}), x2 = (e) => /* @__PURE__ */ n(x, {
|
|
8690
8808
|
viewBox: "0 0 16 16",
|
|
8691
8809
|
...e,
|
|
8692
8810
|
children: /* @__PURE__ */ m("g", {
|
|
@@ -8730,7 +8848,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8730
8848
|
})
|
|
8731
8849
|
]
|
|
8732
8850
|
})
|
|
8733
|
-
}),
|
|
8851
|
+
}), w2 = 0.55, T2 = 0.15, Lt = [
|
|
8734
8852
|
{
|
|
8735
8853
|
name: "column",
|
|
8736
8854
|
icon: c2,
|
|
@@ -8813,7 +8931,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8813
8931
|
},
|
|
8814
8932
|
{
|
|
8815
8933
|
name: "scatter",
|
|
8816
|
-
icon:
|
|
8934
|
+
icon: x2,
|
|
8817
8935
|
summary: {
|
|
8818
8936
|
coordType: "cartesian",
|
|
8819
8937
|
geom: "point",
|
|
@@ -8839,7 +8957,62 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8839
8957
|
geom: "bar",
|
|
8840
8958
|
position: "fill",
|
|
8841
8959
|
theta: "y",
|
|
8842
|
-
innerRadius:
|
|
8960
|
+
innerRadius: w2
|
|
8961
|
+
}
|
|
8962
|
+
},
|
|
8963
|
+
{
|
|
8964
|
+
name: "radialBar",
|
|
8965
|
+
icon: C2,
|
|
8966
|
+
summary: {
|
|
8967
|
+
coordType: "polar",
|
|
8968
|
+
geom: "bar",
|
|
8969
|
+
position: "stack",
|
|
8970
|
+
theta: "y",
|
|
8971
|
+
innerRadius: T2
|
|
8972
|
+
}
|
|
8973
|
+
},
|
|
8974
|
+
{
|
|
8975
|
+
name: "rose",
|
|
8976
|
+
icon: y2,
|
|
8977
|
+
summary: {
|
|
8978
|
+
coordType: "polar",
|
|
8979
|
+
geom: "bar",
|
|
8980
|
+
position: "dodge",
|
|
8981
|
+
theta: "x",
|
|
8982
|
+
innerRadius: 0
|
|
8983
|
+
}
|
|
8984
|
+
},
|
|
8985
|
+
{
|
|
8986
|
+
name: "roseStacked",
|
|
8987
|
+
icon: S2,
|
|
8988
|
+
summary: {
|
|
8989
|
+
coordType: "polar",
|
|
8990
|
+
geom: "bar",
|
|
8991
|
+
position: "stack",
|
|
8992
|
+
theta: "x",
|
|
8993
|
+
innerRadius: 0
|
|
8994
|
+
}
|
|
8995
|
+
},
|
|
8996
|
+
{
|
|
8997
|
+
name: "radar",
|
|
8998
|
+
icon: f2,
|
|
8999
|
+
summary: {
|
|
9000
|
+
coordType: "polar",
|
|
9001
|
+
geom: "line",
|
|
9002
|
+
position: "identity",
|
|
9003
|
+
theta: "x",
|
|
9004
|
+
innerRadius: 0
|
|
9005
|
+
}
|
|
9006
|
+
},
|
|
9007
|
+
{
|
|
9008
|
+
name: "radarFilled",
|
|
9009
|
+
icon: b2,
|
|
9010
|
+
summary: {
|
|
9011
|
+
coordType: "polar",
|
|
9012
|
+
geom: "area",
|
|
9013
|
+
position: "identity",
|
|
9014
|
+
theta: "x",
|
|
9015
|
+
innerRadius: 0
|
|
8843
9016
|
}
|
|
8844
9017
|
},
|
|
8845
9018
|
{
|
|
@@ -8851,7 +9024,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8851
9024
|
position: "identity"
|
|
8852
9025
|
}
|
|
8853
9026
|
}
|
|
8854
|
-
],
|
|
9027
|
+
], A2 = 0.05, k2 = (e) => e === null ? null : Lt.find((t) => P2(t.summary, e)) ?? null, L2 = (e, t) => {
|
|
8855
9028
|
const { summary: r } = e;
|
|
8856
9029
|
return t === null || ve(r) ? r : r.position === "dodge" && Ba(t) ? {
|
|
8857
9030
|
...r,
|
|
@@ -8860,21 +9033,21 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8860
9033
|
...r,
|
|
8861
9034
|
innerRadius: t.innerRadius
|
|
8862
9035
|
};
|
|
8863
|
-
}, Ba = (e) => !ve(e) && e.geom === "bar" && e.position === "identity",
|
|
9036
|
+
}, Ba = (e) => !ve(e) && e.geom === "bar" && e.position === "identity", P2 = (e, t) => {
|
|
8864
9037
|
if (ve(e) || ve(t)) return ve(e) && ve(t);
|
|
8865
9038
|
const r = e.position === t.position || e.position === "dodge" && Ba(t);
|
|
8866
9039
|
return e.coordType !== t.coordType || e.geom !== t.geom || !r ? !1 : e.coordType !== "polar" || t.coordType !== "polar" ? !0 : e.theta === t.theta && Qe(e.innerRadius) === Qe(t.innerRadius);
|
|
8867
|
-
}, Qe = (e) => e >=
|
|
8868
|
-
const a = H(), o = $(a), i = k(), { RadioGrid: l } = B(), s =
|
|
9040
|
+
}, Qe = (e) => e >= A2, I2 = 3, s0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
9041
|
+
const a = H(), o = $(a), i = k(), { RadioGrid: l } = B(), s = M(() => Lt.map(({ name: h, icon: v }) => ({
|
|
8869
9042
|
value: h,
|
|
8870
9043
|
label: i(`editor.graphTypes.${h}`),
|
|
8871
9044
|
icon: /* @__PURE__ */ n(v, { size: "md" }),
|
|
8872
9045
|
isDisabled: h === "combo" && !Wi(o?.spec) || h === "heatmap" && !Ki(o?.spec)
|
|
8873
9046
|
})), [i, o]);
|
|
8874
9047
|
if (!o) return null;
|
|
8875
|
-
const c = gr(o.spec), u =
|
|
9048
|
+
const c = gr(o.spec), u = k2(c), d = (h) => {
|
|
8876
9049
|
const v = Lt.find((p) => p.name === h);
|
|
8877
|
-
v && a.commands.dispatch(new ir(
|
|
9050
|
+
v && a.commands.dispatch(new ir(L2(v, c)));
|
|
8878
9051
|
};
|
|
8879
9052
|
return /* @__PURE__ */ n(W, {
|
|
8880
9053
|
title: e ?? i("editor.graphPanel.graphTypeSection.title"),
|
|
@@ -8883,7 +9056,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8883
9056
|
children: /* @__PURE__ */ n(l, {
|
|
8884
9057
|
value: u?.name ?? "",
|
|
8885
9058
|
options: s,
|
|
8886
|
-
columns:
|
|
9059
|
+
columns: I2,
|
|
8887
9060
|
onChange: d,
|
|
8888
9061
|
ariaLabel: i("editor.graphPanel.graphTypeSection.title")
|
|
8889
9062
|
})
|
|
@@ -8892,10 +9065,10 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8892
9065
|
"solid",
|
|
8893
9066
|
"dashed",
|
|
8894
9067
|
"dotted"
|
|
8895
|
-
],
|
|
9068
|
+
], E2 = 8, M2 = 0, c0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
8896
9069
|
const a = H(), o = $(a), i = k(), { Slider: l, Switch: s, ToggleGroup: c } = B(), { colorScheme: u } = nt();
|
|
8897
9070
|
if (!o) return null;
|
|
8898
|
-
const d = o.guides.axes.filter(
|
|
9071
|
+
const d = o.guides.axes.filter(N2);
|
|
8899
9072
|
if (d.length === 0) return null;
|
|
8900
9073
|
const h = o.coordSystem.type !== "polar", v = d.some((C) => C.gridVisible), p = yl(at({ colorScheme: u }).chromeReaders(o.chrome), "y"), g = Hn.map((C) => ({
|
|
8901
9074
|
value: C,
|
|
@@ -8922,12 +9095,12 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8922
9095
|
layout: t,
|
|
8923
9096
|
preview: r,
|
|
8924
9097
|
children: /* @__PURE__ */ m(q, { children: [d.map((C) => /* @__PURE__ */ n(S, {
|
|
8925
|
-
label: i(
|
|
9098
|
+
label: i(O2(C)),
|
|
8926
9099
|
children: /* @__PURE__ */ n(s, {
|
|
8927
9100
|
isChecked: C.gridVisible,
|
|
8928
9101
|
onChange: f(C.scaleAestheticKey)
|
|
8929
9102
|
})
|
|
8930
|
-
}, C.scaleAestheticKey)), h && v && /* @__PURE__ */ m(
|
|
9103
|
+
}, C.scaleAestheticKey)), h && v && /* @__PURE__ */ m(j, { children: [/* @__PURE__ */ n(S, {
|
|
8931
9104
|
label: i("editor.graphPanel.gridSection.gridStyle"),
|
|
8932
9105
|
children: /* @__PURE__ */ n(c, {
|
|
8933
9106
|
value: p.lineType,
|
|
@@ -8938,8 +9111,8 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8938
9111
|
label: i("editor.graphPanel.gridSection.gridThickness"),
|
|
8939
9112
|
children: /* @__PURE__ */ n(l, {
|
|
8940
9113
|
value: p.strokeWidth,
|
|
8941
|
-
min:
|
|
8942
|
-
max:
|
|
9114
|
+
min: M2,
|
|
9115
|
+
max: E2,
|
|
8943
9116
|
step: 0.5,
|
|
8944
9117
|
formatValue: dt,
|
|
8945
9118
|
onChange: P,
|
|
@@ -8947,60 +9120,60 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
8947
9120
|
})
|
|
8948
9121
|
})] })] })
|
|
8949
9122
|
});
|
|
8950
|
-
},
|
|
9123
|
+
}, N2 = (e) => e.scaleAestheticKey === "x" || e.scaleAestheticKey === "y", O2 = (e) => e.geometry === "radial" ? "editor.graphPanel.gridSection.rings" : e.geometry === "circular" ? "editor.graphPanel.gridSection.spokes" : e.scaleAestheticKey === "x" ? "editor.graphPanel.gridSection.verticalGridLines" : "editor.graphPanel.gridSection.horizontalGridLines", R2 = "total", Va = [
|
|
8951
9124
|
"total",
|
|
8952
9125
|
"average",
|
|
8953
9126
|
"current"
|
|
8954
|
-
],
|
|
9127
|
+
], D2 = ["total"], Bn = ["previous", "first"], Vn = [
|
|
8955
9128
|
"auto",
|
|
8956
9129
|
"small",
|
|
8957
9130
|
"medium",
|
|
8958
9131
|
"large"
|
|
8959
|
-
],
|
|
9132
|
+
], d0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
8960
9133
|
const a = H(), o = $(a), i = k(), { Switch: l, ToggleGroup: s } = B();
|
|
8961
9134
|
if (!o) return null;
|
|
8962
|
-
const c = o.config.headline, u = c.show !== "none", d = o.coordSystem, h = d.type === "polar", v = d.type === "polar" && d.innerRadius > 0, p = o.layers.some((
|
|
9135
|
+
const c = o.config.headline, u = c.show !== "none", d = o.coordSystem, h = d.type === "polar", v = d.type === "polar" && d.innerRadius > 0, p = o.layers.some((T) => T.summary.grandTotal !== void 0);
|
|
8963
9136
|
if (h && !p) return null;
|
|
8964
|
-
const g = h ?
|
|
8965
|
-
value:
|
|
8966
|
-
label: i(`editor.graphPanel.headlineNumberSection.metrics.${
|
|
8967
|
-
})), C = Bn.map((
|
|
8968
|
-
value:
|
|
8969
|
-
label: i(`editor.graphPanel.headlineNumberSection.comparison.${
|
|
8970
|
-
})), A = Vn.map((
|
|
8971
|
-
value:
|
|
8972
|
-
label: i(
|
|
9137
|
+
const g = h ? D2 : Va, f = o.guides.headline, y = f?.kind === "perGroup" && f.items.some((T) => T.comparison !== null), P = g.map((T) => ({
|
|
9138
|
+
value: T,
|
|
9139
|
+
label: i(`editor.graphPanel.headlineNumberSection.metrics.${T}`)
|
|
9140
|
+
})), C = Bn.map((T) => ({
|
|
9141
|
+
value: T,
|
|
9142
|
+
label: i(`editor.graphPanel.headlineNumberSection.comparison.${T}`)
|
|
9143
|
+
})), A = Vn.map((T) => ({
|
|
9144
|
+
value: T,
|
|
9145
|
+
label: i(T === "auto" ? "editor.graphPanel.numberFormat.options.auto" : `editor.graphPanel.headlineNumberSize.sizes.${T}`)
|
|
8973
9146
|
})), L = [{
|
|
8974
9147
|
value: "above",
|
|
8975
9148
|
label: i("editor.graphPanel.headlineNumberSection.position.above")
|
|
8976
9149
|
}, {
|
|
8977
9150
|
value: "center",
|
|
8978
9151
|
label: i("editor.graphPanel.headlineNumberSection.position.center")
|
|
8979
|
-
}],
|
|
8980
|
-
a.commands.dispatch(new rn({ show:
|
|
8981
|
-
}, F = (
|
|
8982
|
-
const b = g.find((
|
|
9152
|
+
}], R = (T) => {
|
|
9153
|
+
a.commands.dispatch(new rn({ show: T ? R2 : "none" }));
|
|
9154
|
+
}, F = (T) => {
|
|
9155
|
+
const b = g.find((Z) => Z === T);
|
|
8983
9156
|
b && a.commands.dispatch(new rn({ show: b }));
|
|
8984
|
-
},
|
|
8985
|
-
const b = Bn.find((
|
|
9157
|
+
}, D = (T) => {
|
|
9158
|
+
const b = Bn.find((Z) => Z === T);
|
|
8986
9159
|
b && a.commands.dispatch(new ui({ compareWith: b }));
|
|
8987
|
-
}, E = (
|
|
8988
|
-
const b = Vn.find((
|
|
9160
|
+
}, E = (T) => {
|
|
9161
|
+
const b = Vn.find((Z) => Z === T);
|
|
8989
9162
|
b && a.commands.dispatch(new pi({ size: b }));
|
|
8990
|
-
},
|
|
8991
|
-
a.commands.dispatch(new hi({ position:
|
|
9163
|
+
}, N = (T) => {
|
|
9164
|
+
a.commands.dispatch(new hi({ position: T === "center" ? "center" : "above" }));
|
|
8992
9165
|
};
|
|
8993
9166
|
return /* @__PURE__ */ n(W, {
|
|
8994
9167
|
title: e ?? i("editor.graphPanel.headlineNumberSection.title"),
|
|
8995
9168
|
layout: t,
|
|
8996
|
-
preview: r ??
|
|
9169
|
+
preview: r ?? z2(i, c.show),
|
|
8997
9170
|
children: /* @__PURE__ */ m(q, { children: [/* @__PURE__ */ n(S, {
|
|
8998
9171
|
label: i("editor.graphPanel.headlineNumberSection.toggle"),
|
|
8999
9172
|
children: /* @__PURE__ */ n(l, {
|
|
9000
9173
|
isChecked: u,
|
|
9001
|
-
onChange:
|
|
9174
|
+
onChange: R
|
|
9002
9175
|
})
|
|
9003
|
-
}), u && /* @__PURE__ */ m(
|
|
9176
|
+
}), u && /* @__PURE__ */ m(j, { children: [
|
|
9004
9177
|
P.length > 1 && /* @__PURE__ */ n(S, {
|
|
9005
9178
|
label: i("editor.graphPanel.headlineNumberSection.metricLabel"),
|
|
9006
9179
|
layout: "stack",
|
|
@@ -9016,7 +9189,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9016
9189
|
children: /* @__PURE__ */ n(s, {
|
|
9017
9190
|
value: Cl(c.compareWith),
|
|
9018
9191
|
options: C,
|
|
9019
|
-
onChange:
|
|
9192
|
+
onChange: D
|
|
9020
9193
|
})
|
|
9021
9194
|
}),
|
|
9022
9195
|
/* @__PURE__ */ n(S, {
|
|
@@ -9032,12 +9205,12 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9032
9205
|
children: /* @__PURE__ */ n(s, {
|
|
9033
9206
|
value: c.position,
|
|
9034
9207
|
options: L,
|
|
9035
|
-
onChange:
|
|
9208
|
+
onChange: N
|
|
9036
9209
|
})
|
|
9037
9210
|
})
|
|
9038
9211
|
] })] })
|
|
9039
9212
|
});
|
|
9040
|
-
},
|
|
9213
|
+
}, z2 = (e, t) => {
|
|
9041
9214
|
const r = Va.find((a) => a === t);
|
|
9042
9215
|
return r && e(`editor.graphPanel.headlineNumberSection.metrics.${r}`);
|
|
9043
9216
|
}, ft = [
|
|
@@ -9055,7 +9228,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9055
9228
|
"auto",
|
|
9056
9229
|
"pill",
|
|
9057
9230
|
"direct"
|
|
9058
|
-
],
|
|
9231
|
+
], u0 = ({ positions: e, title: t, layout: r = "collapsible", preview: a }) => {
|
|
9059
9232
|
const o = H(), i = $(o), l = k(), { ToggleGroup: s } = B();
|
|
9060
9233
|
if (!i) return null;
|
|
9061
9234
|
const c = i.config.legend.position, u = e ?? ft, d = i.guides.legends.drawn[0], h = Ui({
|
|
@@ -9064,29 +9237,29 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9064
9237
|
layers: i.layers
|
|
9065
9238
|
}), v = i.guides.headline?.kind === "perGroup", p = i.guides.colorGroups.length > 0;
|
|
9066
9239
|
if (c === "auto" && d === void 0 && !h && (v || !p)) return null;
|
|
9067
|
-
const g = d?.position ?? "none", f = c === "auto" ? g : c, y = ft.filter((
|
|
9068
|
-
value:
|
|
9069
|
-
label: l(`editor.graphPanel.legendSection.${
|
|
9070
|
-
})), P = (
|
|
9071
|
-
const
|
|
9072
|
-
|
|
9073
|
-
}, C = (
|
|
9074
|
-
const
|
|
9075
|
-
|
|
9076
|
-
}, A = (
|
|
9077
|
-
const
|
|
9078
|
-
|
|
9079
|
-
}, L = Gn.map((
|
|
9080
|
-
value:
|
|
9081
|
-
label: l(`editor.graphPanel.legendSection.align.${
|
|
9082
|
-
})),
|
|
9083
|
-
value:
|
|
9084
|
-
label: l(`editor.graphPanel.legendSection.display.${
|
|
9085
|
-
})), F = t ?? l("editor.graphPanel.legendSection.title"),
|
|
9240
|
+
const g = d?.position ?? "none", f = c === "auto" ? g : c, y = ft.filter((N) => N === f || u.includes(N)).map((N) => ({
|
|
9241
|
+
value: N,
|
|
9242
|
+
label: l(`editor.graphPanel.legendSection.${N}`)
|
|
9243
|
+
})), P = (N) => {
|
|
9244
|
+
const T = ft.find((b) => b === N);
|
|
9245
|
+
T && o.commands.dispatch(new bi({ position: T }));
|
|
9246
|
+
}, C = (N) => {
|
|
9247
|
+
const T = Gn.find((b) => b === N);
|
|
9248
|
+
T && o.commands.dispatch(new vi({ align: T }));
|
|
9249
|
+
}, A = (N) => {
|
|
9250
|
+
const T = $n.find((b) => b === N);
|
|
9251
|
+
T && o.commands.dispatch(new fi({ display: T }));
|
|
9252
|
+
}, L = Gn.map((N) => ({
|
|
9253
|
+
value: N,
|
|
9254
|
+
label: l(`editor.graphPanel.legendSection.align.${N}`)
|
|
9255
|
+
})), R = $n.map((N) => ({
|
|
9256
|
+
value: N,
|
|
9257
|
+
label: l(`editor.graphPanel.legendSection.display.${N}`)
|
|
9258
|
+
})), F = t ?? l("editor.graphPanel.legendSection.title"), D = y.find((N) => N.value === f)?.label, E = d !== void 0;
|
|
9086
9259
|
return /* @__PURE__ */ n(W, {
|
|
9087
9260
|
title: F,
|
|
9088
9261
|
layout: r,
|
|
9089
|
-
preview: a ??
|
|
9262
|
+
preview: a ?? D,
|
|
9090
9263
|
children: /* @__PURE__ */ m(q, { children: [
|
|
9091
9264
|
/* @__PURE__ */ n(S, {
|
|
9092
9265
|
label: l("editor.axesPanel.controls.position"),
|
|
@@ -9111,13 +9284,13 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9111
9284
|
layout: "stack",
|
|
9112
9285
|
children: /* @__PURE__ */ n(s, {
|
|
9113
9286
|
value: i.config.legend.display,
|
|
9114
|
-
options:
|
|
9287
|
+
options: R,
|
|
9115
9288
|
onChange: A
|
|
9116
9289
|
})
|
|
9117
9290
|
})
|
|
9118
9291
|
] })
|
|
9119
9292
|
});
|
|
9120
|
-
},
|
|
9293
|
+
}, _2 = 1, F2 = 20, H2 = 0.5, Ga = ({ layerId: e }) => {
|
|
9121
9294
|
const t = H(), r = $(t), { Slider: a } = B(), o = Yt(r, e);
|
|
9122
9295
|
if (!r) return null;
|
|
9123
9296
|
const i = (l) => {
|
|
@@ -9129,54 +9302,54 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9129
9302
|
};
|
|
9130
9303
|
return /* @__PURE__ */ n(a, {
|
|
9131
9304
|
value: o?.get("size") ?? Uo,
|
|
9132
|
-
min:
|
|
9133
|
-
max:
|
|
9134
|
-
step:
|
|
9305
|
+
min: _2,
|
|
9306
|
+
max: F2,
|
|
9307
|
+
step: H2,
|
|
9135
9308
|
formatValue: dt,
|
|
9136
9309
|
onChange: i,
|
|
9137
9310
|
onCommit: t.commands.seal
|
|
9138
9311
|
});
|
|
9139
|
-
},
|
|
9312
|
+
}, B2 = 1, V2 = 10, G2 = 0.1, $2 = [
|
|
9140
9313
|
"gap",
|
|
9141
9314
|
"zero",
|
|
9142
9315
|
"connect"
|
|
9143
|
-
],
|
|
9316
|
+
], h0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
9144
9317
|
const a = H(), o = $(a), i = k(), { Select: l, Slider: s, Switch: c, ToggleGroup: u } = B(), d = o?.spec.layers ?? [], h = hr(d, "line", "area"), v = Yt(o, h?.id ?? null);
|
|
9145
9318
|
if (!o || !h) return null;
|
|
9146
|
-
const p = o.coordSystem.type === "polar", g =
|
|
9319
|
+
const p = o.coordSystem.type === "polar", g = K2(i, h), f = W2(h, d), y = Un(o.spec, h.geom, "strokeWidth", h.id), P = typeof y == "number", C = h.geom === "line" ? h : void 0, A = [{
|
|
9147
9320
|
value: "auto",
|
|
9148
9321
|
label: i("editor.graphPanel.numberFormat.options.auto")
|
|
9149
9322
|
}, {
|
|
9150
9323
|
value: "custom",
|
|
9151
9324
|
label: i("editor.graphPanel.numberFormat.options.custom")
|
|
9152
|
-
}], L = (
|
|
9325
|
+
}], L = (T) => {
|
|
9153
9326
|
a.commands.dispatch(new _i({
|
|
9154
9327
|
layerId: h.id,
|
|
9155
|
-
showPoints:
|
|
9328
|
+
showPoints: T
|
|
9156
9329
|
}));
|
|
9157
|
-
},
|
|
9330
|
+
}, R = (T) => {
|
|
9158
9331
|
C && a.commands.dispatch(new zi({
|
|
9159
9332
|
layerId: C.id,
|
|
9160
|
-
showFill:
|
|
9333
|
+
showFill: T
|
|
9161
9334
|
}));
|
|
9162
|
-
}, F = (
|
|
9335
|
+
}, F = (T) => {
|
|
9163
9336
|
a.commands.dispatch(new Ci({
|
|
9164
9337
|
layerId: h.id,
|
|
9165
|
-
interpolate:
|
|
9338
|
+
interpolate: T ? "catmull-rom" : "linear"
|
|
9166
9339
|
}));
|
|
9167
|
-
},
|
|
9340
|
+
}, D = (T) => {
|
|
9168
9341
|
const b = v?.get("strokeWidth") ?? Wo;
|
|
9169
9342
|
a.commands.dispatch(new an({
|
|
9170
9343
|
layerId: h.id,
|
|
9171
|
-
lineWidth:
|
|
9344
|
+
lineWidth: T === "custom" ? b : null
|
|
9172
9345
|
}));
|
|
9173
|
-
}, E = (
|
|
9346
|
+
}, E = (T) => {
|
|
9174
9347
|
a.commands.dispatch(new an({
|
|
9175
9348
|
layerId: h.id,
|
|
9176
|
-
lineWidth:
|
|
9349
|
+
lineWidth: T
|
|
9177
9350
|
}), { transient: !0 });
|
|
9178
|
-
},
|
|
9179
|
-
const b =
|
|
9351
|
+
}, N = (T) => {
|
|
9352
|
+
const b = U2(T);
|
|
9180
9353
|
b && a.commands.dispatch(new yi({
|
|
9181
9354
|
layerId: h.id,
|
|
9182
9355
|
missingValues: b
|
|
@@ -9202,7 +9375,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9202
9375
|
label: i("editor.graphPanel.graphOptions.lineFill"),
|
|
9203
9376
|
children: /* @__PURE__ */ n(c, {
|
|
9204
9377
|
isChecked: Un(o.spec, "line", "fillAlpha", C.id) !== void 0,
|
|
9205
|
-
onChange:
|
|
9378
|
+
onChange: R
|
|
9206
9379
|
})
|
|
9207
9380
|
}),
|
|
9208
9381
|
!p && /* @__PURE__ */ n(S, {
|
|
@@ -9217,16 +9390,16 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9217
9390
|
children: /* @__PURE__ */ n(u, {
|
|
9218
9391
|
value: P ? "custom" : "auto",
|
|
9219
9392
|
options: A,
|
|
9220
|
-
onChange:
|
|
9393
|
+
onChange: D
|
|
9221
9394
|
})
|
|
9222
9395
|
}),
|
|
9223
9396
|
P && /* @__PURE__ */ n(S, {
|
|
9224
9397
|
label: i("editor.graphPanel.numberFormat.valueLabel"),
|
|
9225
9398
|
children: /* @__PURE__ */ n(s, {
|
|
9226
9399
|
value: y,
|
|
9227
|
-
min:
|
|
9228
|
-
max:
|
|
9229
|
-
step:
|
|
9400
|
+
min: B2,
|
|
9401
|
+
max: V2,
|
|
9402
|
+
step: G2,
|
|
9230
9403
|
formatValue: dt,
|
|
9231
9404
|
onChange: E,
|
|
9232
9405
|
onCommit: a.commands.seal
|
|
@@ -9237,12 +9410,12 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9237
9410
|
children: /* @__PURE__ */ n(l, {
|
|
9238
9411
|
value: h.params.missingValues,
|
|
9239
9412
|
options: g,
|
|
9240
|
-
onChange:
|
|
9413
|
+
onChange: N
|
|
9241
9414
|
})
|
|
9242
9415
|
})
|
|
9243
9416
|
] })
|
|
9244
9417
|
});
|
|
9245
|
-
},
|
|
9418
|
+
}, U2 = (e) => $2.find((t) => t === e), Un = (e, t, r, a) => al(e.styles.overrides, Gi(t, a))?.[r], W2 = (e, t) => bt(t, "point").find((r) => pr(r, [e])), K2 = (e, t) => {
|
|
9246
9419
|
const r = [{
|
|
9247
9420
|
value: "gap",
|
|
9248
9421
|
label: e("editor.graphPanel.treatEmptyValues.leaveGap.label")
|
|
@@ -9254,26 +9427,26 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9254
9427
|
value: "connect",
|
|
9255
9428
|
label: e("editor.graphPanel.treatEmptyValues.connectGaps.label")
|
|
9256
9429
|
}), t.geom === "area" ? r.filter((a) => a.value !== "gap") : r;
|
|
9257
|
-
}, Pt = "\0none",
|
|
9430
|
+
}, Pt = "\0none", q2 = [
|
|
9258
9431
|
"x",
|
|
9259
9432
|
"y",
|
|
9260
9433
|
"color",
|
|
9261
9434
|
"size",
|
|
9262
9435
|
"label"
|
|
9263
|
-
],
|
|
9436
|
+
], Z2 = {
|
|
9264
9437
|
x: "editor.graphPanel.mappingSection.x",
|
|
9265
9438
|
y: "editor.graphPanel.mappingSection.y",
|
|
9266
9439
|
color: "editor.graphPanel.mappingSection.color",
|
|
9267
9440
|
size: "editor.graphPanel.mappingSection.size",
|
|
9268
9441
|
label: "editor.graphPanel.mappingSection.label"
|
|
9269
|
-
},
|
|
9270
|
-
const r = H(), a = $(r), o = k(), { Select: i } = B(), l = o("editor.graphPanel.mappingSection.none"), s = a?.spec, c =
|
|
9442
|
+
}, p0 = ({ title: e, layout: t = "collapsible" }) => {
|
|
9443
|
+
const r = H(), a = $(r), o = k(), { Select: i } = B(), l = o("editor.graphPanel.mappingSection.none"), s = a?.spec, c = M(() => s === void 0 ? [] : gl(s, q2).map(({ aesthetic: u, variables: d, isRequired: h }) => {
|
|
9271
9444
|
const v = vl(s.mapping, u);
|
|
9272
9445
|
return {
|
|
9273
9446
|
aesthetic: u,
|
|
9274
|
-
label: o(
|
|
9447
|
+
label: o(Z2[u]),
|
|
9275
9448
|
value: v ?? (h ? null : Pt),
|
|
9276
|
-
options:
|
|
9449
|
+
options: X2(d, v, h ? null : l),
|
|
9277
9450
|
chooseColumn: (p) => {
|
|
9278
9451
|
r.commands.dispatch(new Si({
|
|
9279
9452
|
aesthetic: u,
|
|
@@ -9300,7 +9473,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9300
9473
|
})
|
|
9301
9474
|
}, u)) })
|
|
9302
9475
|
}) : null;
|
|
9303
|
-
},
|
|
9476
|
+
}, X2 = (e, t, r) => {
|
|
9304
9477
|
const a = t !== null && !e.includes(t) ? [t, ...e] : e;
|
|
9305
9478
|
return [...r === null ? [] : [{
|
|
9306
9479
|
value: Pt,
|
|
@@ -9309,7 +9482,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9309
9482
|
value: o,
|
|
9310
9483
|
label: o
|
|
9311
9484
|
}))];
|
|
9312
|
-
},
|
|
9485
|
+
}, j2 = "k", Y2 = 2, J2 = 0, Q2 = 5, It = [
|
|
9313
9486
|
{
|
|
9314
9487
|
value: "k",
|
|
9315
9488
|
labelKey: "thousands"
|
|
@@ -9322,10 +9495,10 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9322
9495
|
value: "b",
|
|
9323
9496
|
labelKey: "billions"
|
|
9324
9497
|
}
|
|
9325
|
-
],
|
|
9498
|
+
], em = ["auto", "none"], m0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
9326
9499
|
const a = H(), o = $(a), i = k(), { NumberField: l, ToggleGroup: s } = B();
|
|
9327
9500
|
if (!o) return null;
|
|
9328
|
-
const { abbreviation: c, decimals: u } = o.config.numberFormat, d =
|
|
9501
|
+
const { abbreviation: c, decimals: u } = o.config.numberFormat, d = tm(c) !== void 0, h = u !== "auto", v = (A) => A.map((L) => ({
|
|
9329
9502
|
value: L,
|
|
9330
9503
|
label: i(`editor.graphPanel.numberFormat.options.${L}`)
|
|
9331
9504
|
})), p = It.map(({ value: A, labelKey: L }) => ({
|
|
@@ -9334,13 +9507,13 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9334
9507
|
})), g = (A) => {
|
|
9335
9508
|
a.commands.dispatch(new xi({ abbreviation: A }));
|
|
9336
9509
|
}, f = (A) => {
|
|
9337
|
-
const L =
|
|
9338
|
-
g(L ??
|
|
9510
|
+
const L = em.find((R) => R === A);
|
|
9511
|
+
g(L ?? j2);
|
|
9339
9512
|
}, y = (A) => {
|
|
9340
|
-
const L = It.find((
|
|
9513
|
+
const L = It.find((R) => R.value === A);
|
|
9341
9514
|
L && g(L.value);
|
|
9342
9515
|
}, P = (A) => {
|
|
9343
|
-
a.commands.dispatch(new on({ decimals: A === "custom" ?
|
|
9516
|
+
a.commands.dispatch(new on({ decimals: A === "custom" ? Y2 : "auto" }));
|
|
9344
9517
|
}, C = (A) => {
|
|
9345
9518
|
A !== null && a.commands.dispatch(new on({ decimals: A }), { transient: !0 });
|
|
9346
9519
|
};
|
|
@@ -9381,18 +9554,18 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9381
9554
|
label: i("editor.graphPanel.numberFormat.valueLabel"),
|
|
9382
9555
|
children: /* @__PURE__ */ n(l, {
|
|
9383
9556
|
value: u,
|
|
9384
|
-
min:
|
|
9385
|
-
max:
|
|
9557
|
+
min: J2,
|
|
9558
|
+
max: Q2,
|
|
9386
9559
|
onChange: C,
|
|
9387
9560
|
onCommit: a.commands.seal
|
|
9388
9561
|
})
|
|
9389
9562
|
})
|
|
9390
9563
|
] })
|
|
9391
9564
|
});
|
|
9392
|
-
},
|
|
9565
|
+
}, tm = (e) => It.find((t) => t.value === e), g0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
9393
9566
|
const a = $(H()), o = k();
|
|
9394
9567
|
if (!a) return null;
|
|
9395
|
-
const i =
|
|
9568
|
+
const i = nm(a.spec.layers);
|
|
9396
9569
|
return i ? /* @__PURE__ */ n(W, {
|
|
9397
9570
|
title: e ?? o("editor.graphPanel.pointSize.label"),
|
|
9398
9571
|
layout: t,
|
|
@@ -9402,10 +9575,10 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9402
9575
|
children: /* @__PURE__ */ n(Ga, { layerId: i.id })
|
|
9403
9576
|
}) })
|
|
9404
9577
|
}) : null;
|
|
9405
|
-
},
|
|
9578
|
+
}, nm = (e) => {
|
|
9406
9579
|
const t = bt(e, "line", "area");
|
|
9407
9580
|
return bt(e, "point").find((r) => !pr(r, t));
|
|
9408
|
-
},
|
|
9581
|
+
}, rm = 0.9, am = 360, om = 0.05, im = 15, v0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
9409
9582
|
const a = H(), o = $(a), i = k(), { Slider: l } = B();
|
|
9410
9583
|
if (!o || o.spec.coords.coordType !== "polar") return null;
|
|
9411
9584
|
const { innerRadius: s, startAngle: c } = o.spec.coords.params, u = (h) => {
|
|
@@ -9422,8 +9595,8 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9422
9595
|
children: /* @__PURE__ */ n(l, {
|
|
9423
9596
|
value: s,
|
|
9424
9597
|
min: 0,
|
|
9425
|
-
max:
|
|
9426
|
-
step:
|
|
9598
|
+
max: rm,
|
|
9599
|
+
step: om,
|
|
9427
9600
|
formatValue: Ha,
|
|
9428
9601
|
onChange: u,
|
|
9429
9602
|
onCommit: a.commands.seal
|
|
@@ -9433,15 +9606,15 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9433
9606
|
children: /* @__PURE__ */ n(l, {
|
|
9434
9607
|
value: c,
|
|
9435
9608
|
min: 0,
|
|
9436
|
-
max:
|
|
9437
|
-
step:
|
|
9609
|
+
max: am - 1,
|
|
9610
|
+
step: im,
|
|
9438
9611
|
formatValue: Bp,
|
|
9439
9612
|
onChange: d,
|
|
9440
9613
|
onCommit: a.commands.seal
|
|
9441
9614
|
})
|
|
9442
9615
|
})] })
|
|
9443
9616
|
});
|
|
9444
|
-
},
|
|
9617
|
+
}, lm = (e) => /* @__PURE__ */ m(x, {
|
|
9445
9618
|
...e,
|
|
9446
9619
|
children: [
|
|
9447
9620
|
/* @__PURE__ */ n("path", {
|
|
@@ -9464,7 +9637,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9464
9637
|
fill: "currentColor"
|
|
9465
9638
|
})
|
|
9466
9639
|
]
|
|
9467
|
-
}), Wn = (e) => /* @__PURE__ */ m(
|
|
9640
|
+
}), Wn = (e) => /* @__PURE__ */ m(x, {
|
|
9468
9641
|
...e,
|
|
9469
9642
|
children: [
|
|
9470
9643
|
/* @__PURE__ */ n("path", {
|
|
@@ -9487,7 +9660,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9487
9660
|
fill: "currentColor"
|
|
9488
9661
|
})
|
|
9489
9662
|
]
|
|
9490
|
-
}),
|
|
9663
|
+
}), sm = (e) => M(() => {
|
|
9491
9664
|
if (e === null) return {
|
|
9492
9665
|
options: [],
|
|
9493
9666
|
findValue: () => {
|
|
@@ -9519,26 +9692,26 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9519
9692
|
"logarithmic",
|
|
9520
9693
|
"power",
|
|
9521
9694
|
"loess"
|
|
9522
|
-
],
|
|
9523
|
-
const a = H(), o = $(a), i = k(), { Select: l, Switch: s } = B(), { options: c, findValue: u } =
|
|
9695
|
+
], cm = "linear", f0 = ({ title: e, layout: t = "collapsible", preview: r }) => {
|
|
9696
|
+
const a = H(), o = $(a), i = k(), { Select: l, Switch: s } = B(), { options: c, findValue: u } = sm(o);
|
|
9524
9697
|
if (!o || o.coordSystem.type === "polar") return null;
|
|
9525
|
-
const d = il(o.spec.layers), h = tl(o.spec.layers), v = d?.stat.type === "smooth" ? d.stat.method :
|
|
9698
|
+
const d = il(o.spec.layers), h = tl(o.spec.layers), v = d?.stat.type === "smooth" ? d.stat.method : cm, p = dm(h), g = Kn.map((L) => ({
|
|
9526
9699
|
value: L,
|
|
9527
9700
|
label: i(`editor.annotationsPanel.trendType.options.${L}`)
|
|
9528
|
-
})), f = (L,
|
|
9529
|
-
const F = d ?? h,
|
|
9701
|
+
})), f = (L, R = {}) => {
|
|
9702
|
+
const F = d ?? h, D = new Ei({
|
|
9530
9703
|
line: L,
|
|
9531
|
-
...
|
|
9704
|
+
...R,
|
|
9532
9705
|
...F !== void 0 && { layerId: F.id },
|
|
9533
9706
|
label: i("editor.annotationsPanel.trendsAndAveragesSection.average")
|
|
9534
9707
|
});
|
|
9535
|
-
a.commands.dispatch(
|
|
9708
|
+
a.commands.dispatch(D);
|
|
9536
9709
|
}, y = (L) => f(L ? "trend" : "none", { method: v }), P = (L) => f(L ? "average" : "none", { group: p ?? u(c[0]?.value ?? "") }), C = (L) => {
|
|
9537
|
-
const
|
|
9538
|
-
|
|
9710
|
+
const R = Kn.find((F) => F === L);
|
|
9711
|
+
R !== void 0 && f("trend", { method: R });
|
|
9539
9712
|
}, A = (L) => {
|
|
9540
|
-
const
|
|
9541
|
-
|
|
9713
|
+
const R = L === null ? void 0 : u(L);
|
|
9714
|
+
R !== void 0 && f("average", { group: R });
|
|
9542
9715
|
};
|
|
9543
9716
|
return /* @__PURE__ */ n(W, {
|
|
9544
9717
|
title: e ?? i("editor.annotationsPanel.trendsAndAveragesSection.title"),
|
|
@@ -9564,7 +9737,7 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9564
9737
|
}),
|
|
9565
9738
|
/* @__PURE__ */ n(S, {
|
|
9566
9739
|
label: i("editor.annotationsPanel.trendsAndAveragesSection.average"),
|
|
9567
|
-
icon: /* @__PURE__ */ n(
|
|
9740
|
+
icon: /* @__PURE__ */ n(lm, { size: "lg" }),
|
|
9568
9741
|
children: /* @__PURE__ */ n(s, {
|
|
9569
9742
|
isChecked: h !== void 0,
|
|
9570
9743
|
onChange: P
|
|
@@ -9582,42 +9755,42 @@ var Tp = "_40zvwv8", W = ({ title: e, layout: t = "fixed", preview: r, accessory
|
|
|
9582
9755
|
})
|
|
9583
9756
|
] })
|
|
9584
9757
|
});
|
|
9585
|
-
},
|
|
9758
|
+
}, dm = (e) => {
|
|
9586
9759
|
const t = e?.transforms.find((r) => r.transformType === "filter")?.options.value;
|
|
9587
9760
|
return t instanceof Date ? t.getTime() : t;
|
|
9588
9761
|
};
|
|
9589
9762
|
export {
|
|
9590
|
-
|
|
9591
|
-
|
|
9592
|
-
|
|
9593
|
-
|
|
9763
|
+
n0 as AppearanceSection,
|
|
9764
|
+
t0 as AxesPanel,
|
|
9765
|
+
Dn as AxisSection,
|
|
9766
|
+
r0 as BarSection,
|
|
9594
9767
|
A1 as Button,
|
|
9595
|
-
|
|
9596
|
-
|
|
9597
|
-
|
|
9598
|
-
|
|
9768
|
+
a0 as CalloutsSection,
|
|
9769
|
+
Np as CaptionSection,
|
|
9770
|
+
o0 as ComboSection,
|
|
9771
|
+
Qm as EditableGraphRenderer,
|
|
9599
9772
|
_a as EditorPanel,
|
|
9600
|
-
|
|
9601
|
-
|
|
9602
|
-
|
|
9603
|
-
|
|
9604
|
-
|
|
9605
|
-
|
|
9773
|
+
e0 as ElementsPanel,
|
|
9774
|
+
i0 as GoalSection,
|
|
9775
|
+
l0 as GraphOptionsSection,
|
|
9776
|
+
s0 as GraphTypeSection,
|
|
9777
|
+
c0 as GridSection,
|
|
9778
|
+
d0 as HeadlineSection,
|
|
9606
9779
|
ls as IntlProvider,
|
|
9607
|
-
|
|
9608
|
-
|
|
9609
|
-
|
|
9780
|
+
u0 as LegendSection,
|
|
9781
|
+
h0 as LineSection,
|
|
9782
|
+
p0 as MappingSection,
|
|
9610
9783
|
I1 as NumberField,
|
|
9611
|
-
|
|
9784
|
+
m0 as NumberFormatSection,
|
|
9612
9785
|
gp as PANEL_ROOT_ATTRIBUTE,
|
|
9613
|
-
|
|
9614
|
-
|
|
9786
|
+
g0 as PointSection,
|
|
9787
|
+
v0 as PolarSection,
|
|
9615
9788
|
O1 as RadioGrid,
|
|
9616
9789
|
S as Row,
|
|
9617
9790
|
W as Section,
|
|
9618
9791
|
G1 as Select,
|
|
9619
9792
|
Y1 as Slider,
|
|
9620
|
-
|
|
9793
|
+
Rp as SourceSection,
|
|
9621
9794
|
zp as SubtitleSection,
|
|
9622
9795
|
tp as Switch,
|
|
9623
9796
|
ap as TextField,
|
|
@@ -9625,7 +9798,7 @@ export {
|
|
|
9625
9798
|
Hp as TitleSection,
|
|
9626
9799
|
lp as ToggleGroup,
|
|
9627
9800
|
Lp as ToggledSection,
|
|
9628
|
-
|
|
9801
|
+
f0 as TrendsAndAveragesSection,
|
|
9629
9802
|
B as useControls,
|
|
9630
9803
|
pp as usePanelExpansion,
|
|
9631
9804
|
H as usePanelGraph
|