@sheetxl/studio-mui 1.0.5 → 1.0.6
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/browser/esm/{ePpKy03kKJVlSVTe.mjs → 6wAcMpoIZS1ffzqR.mjs} +3 -3
- package/browser/esm/{BPvVycga6_ukFjmo.mjs → AVMBYVWPe170RO8d.mjs} +20 -20
- package/browser/esm/{DThDfv3f2iMSjT53.mjs → B2k09pbNHOie-ZPU.mjs} +5 -5
- package/browser/esm/B5hj7BR72rs3Xx2-.mjs +40 -0
- package/browser/esm/{CPaacOpodhMft_HZ.mjs → BK0H9A2QjD4YqPxq.mjs} +2 -2
- package/browser/esm/{zvoxJTExywdfgNRc.mjs → BMtR4PaoNnEhVh2U.mjs} +243 -245
- package/browser/esm/{DOKtLrUbVlvQxv4H.mjs → BVQX7HEZNPIvf0Bg.mjs} +1 -1
- package/browser/esm/BZWyHJnsP5yHfByl.mjs +461 -0
- package/browser/esm/{B6-hMCdKZvyVLr0H.mjs → BaYDGaXi_5fNEPo1.mjs} +1 -1
- package/browser/esm/{7yj4dvdTrP3TJcG2.mjs → BgOevzKxdIm3FqSz.mjs} +4 -4
- package/browser/esm/{B-BP7YC6OqOv5MV4.mjs → BgvcXlX-fe99mlfa.mjs} +1 -1
- package/browser/esm/{DKVZo-UN8IISuX4Y.mjs → BmJRmCarQ2Y_DhcS.mjs} +6 -6
- package/browser/esm/{bBvScRhjFIhLO-BQ.mjs → BnIfAdE8Qnu8RF3t.mjs} +1 -1
- package/browser/esm/{BRtyp4rO-zBQUZou.mjs → Bu4IunF89gqzLc6A.mjs} +2 -2
- package/browser/esm/{BTvmDvFq0AmcpyAD.mjs → BvvD5BVF5uSL-2Ow.mjs} +2 -2
- package/browser/esm/{VtQjtk60kuTE6s0Z.mjs → Bzr0CzpORAOD9X-l.mjs} +1 -1
- package/browser/esm/{Bqz9mx_1Lg0aSHGm.mjs → C-lKdgOAbn4Ycu7e.mjs} +2 -2
- package/browser/esm/{DryZ4M6NKZEfr7g_.mjs → C211u9yUXa4149g9.mjs} +1 -1
- package/browser/esm/{C8Lqnn-28XkX0Nka.mjs → C7RPgX_8hKN1Umxm.mjs} +2 -2
- package/browser/esm/{BncHnyZbePCwr9Eo.mjs → C9cBnewCaYFf2JV6.mjs} +21 -22
- package/browser/esm/{R0acIC-n-z00Zc8M.mjs → CA42_0vpQwF292tA.mjs} +1 -1
- package/browser/esm/{hSCeagPj7N_7GznP.mjs → CAbY1N8X3Iryy2XC.mjs} +4 -4
- package/browser/esm/{C7HaLVp6sci5ODXI.mjs → CD6iCHysAki3ui3u.mjs} +4 -4
- package/browser/esm/{CvbBPZFXJWgWy-WO.mjs → CFUur1yDoVOJMuo5.mjs} +1 -1
- package/browser/esm/{BK1rW101-KwC1O3y.mjs → CHb2gapathcPfhdM.mjs} +5 -5
- package/browser/esm/{C_-UmBzcMFoDo0fX.mjs → CIZh3NmE8QG5ZkiA.mjs} +2 -2
- package/browser/esm/{iK7GQTGlybnAwDFn.mjs → CImvd-NxbJGZOozE.mjs} +1 -1
- package/browser/esm/{Dbg4a76nvHk2YiQX.mjs → CO-AxUDR6qjjgpyK.mjs} +2 -2
- package/browser/esm/CQ1ArTuEvBmc7W5I.mjs +695 -0
- package/browser/esm/{BztoCStIl9cOlMP2.mjs → CVNzlTdizLlhU05M.mjs} +2 -2
- package/browser/esm/{DBsWN0XGhfhzjKYP.mjs → CXwkm9x8MkCxPz74.mjs} +1 -1
- package/browser/esm/{CfVmUxioa6e4pJgE.mjs → CZIV7UuyM5VGNrJT.mjs} +4 -4
- package/browser/esm/{C0EVQMZCECx8ZtfT.mjs → CdK1lF_PdSw6YfAo.mjs} +1 -1
- package/browser/esm/{Cg0gGXUOW_fkgnny.mjs → CpgoYQ3P-S7njA7p.mjs} +2 -2
- package/browser/esm/{CUVpARqLbIk1YJpR.mjs → CqEyDFDlQ75w1c41.mjs} +2 -2
- package/browser/esm/{D6uC2TMlHyJaRxfz.mjs → CqIX3rp_vI2S2KbN.mjs} +2 -2
- package/browser/esm/{CeVY5B3Jxs6uNbw_.mjs → Csmz2j1S5pk-J0B3.mjs} +2 -2
- package/browser/esm/{BPyB91W7jUDKOF7m.mjs → CsuFocZfRucugR3q.mjs} +1153 -922
- package/browser/esm/{C-J4c4cA_UafY5j-.mjs → Cw6wZyiZkwn9DPZn.mjs} +193 -105
- package/browser/esm/{CD1F2JZ9VNb4fMFB.mjs → D91G6sYfKgwC24dQ.mjs} +1 -1
- package/browser/esm/{D834tBZr2uiui3Yl.mjs → DF_ssRdRHuBueJgX.mjs} +89 -102
- package/browser/esm/{BwcKRrn0FbEQXA_w.mjs → DJaMl_5NGyq62zwW.mjs} +1 -1
- package/browser/esm/DLixDE7fzzurotzQ.mjs +826 -0
- package/browser/esm/{GfW7QFtTUyK1yS0P.mjs → DM86XhEF4qmUnjuK.mjs} +4 -4
- package/browser/esm/{RRwtR6zhJEHrCP8n.mjs → DNXDqUO4_S_N8sSC.mjs} +2 -2
- package/browser/esm/{CIdbrUCRQ3XRp27_.mjs → DfrMUwmPoZFEFJFk.mjs} +1 -1
- package/browser/esm/{Rx8jKs1hNt5rF1o6.mjs → Dn3ur1I_S9SlR8vu.mjs} +1 -1
- package/browser/esm/{BZJa6r9ArcmluwF7.mjs → IUt6EgxYCpZe9iCH.mjs} +2 -2
- package/browser/esm/{BxdEhMqG0AJfgYo_.mjs → JNoXh3IYri5h1W3Y.mjs} +1 -1
- package/browser/esm/{CdWTSkoOn2S7LbgA.mjs → LZ2X5C1kjiwUCDGz.mjs} +2 -2
- package/browser/esm/{CzKOC7ykGeweE8YO.mjs → MSkt-6o2ZLEiAbDl.mjs} +1 -1
- package/browser/esm/{BJdjpkMLIVz2dfey.mjs → bQOt-2VGBciMnvp_.mjs} +3 -3
- package/browser/esm/{Dl3HN6jGh1DIosIz.mjs → drMcpHj_xCQ0KxuA.mjs} +4 -4
- package/browser/esm/{CKN_49irWz3yBOic.mjs → g-ScvvLFu66BzoGI.mjs} +2 -2
- package/browser/esm/index.mjs +299 -299
- package/browser/esm/{BablQ60b_Sr7yt0c.mjs → j6NYTR7qK3Ra-ctk.mjs} +2 -2
- package/browser/esm/qSdXw8S3Pv-_PPNl.mjs +210 -0
- package/browser/esm/{-JkustapYpJLIlTC.mjs → r8gxfS-mY5qhTMtJ.mjs} +2 -2
- package/browser/esm/{L2h5hAhioUPka05m.mjs → ro5VSIHWH1Nehr75.mjs} +1 -1
- package/browser/esm/tfUleloRF2hBRjjZ.mjs +996 -0
- package/browser/esm/vTlYAw0bvWP8B4jg.mjs +103 -0
- package/browser/esm/{AXga1X4C6fqsi-pa.mjs → vzJavAz2onbnB0zm.mjs} +1183 -1204
- package/browser/esm/{vTrvnXbLCCRg1M_Z.mjs → xaG6CESboBdgd5SL.mjs} +3 -3
- package/browser/esm/{CVI6kZdcPa6NJ2QN.mjs → ze358yTiZmVH9_vX.mjs} +6 -4
- package/node/esm/5WNL9ztJdLI0VLJ7.mjs +997 -0
- package/node/esm/{BE8tFJNzJd21ET8u.mjs → 8aFKkKyEL5n7sJAn.mjs} +12 -12
- package/node/esm/{D9h-5-KAL05_Ky2c.mjs → 9Yzu2QTWzvPBNvc4.mjs} +1 -1
- package/node/esm/{BKNq-LKfmWLM8xN8.mjs → BDGax8JuzpXDLe1U.mjs} +1 -1
- package/node/esm/{Dfq_WQN4R9_EI6mT.mjs → BMuPM5U4Q2kQVYTt.mjs} +251 -253
- package/node/esm/B_XE-SYyFRwWgVyQ.mjs +2070 -0
- package/node/esm/{Dn886fw8cN-Js_4o.mjs → Bap-XMVZ0X80-MNV.mjs} +2 -2
- package/node/esm/{BxiLu3gZqvEwm0MC.mjs → BghhH54dXAqciBpw.mjs} +2 -2
- package/node/esm/{5w-_-2HcuZN2IilY.mjs → Bgsi1G5RDBa4Rnmh.mjs} +1 -1
- package/node/esm/{CZZkkEXKtF-XmMg_.mjs → Bj6wKB1N--BJ0A7u.mjs} +1 -1
- package/node/esm/{4333CfN0xFlZJlzT.mjs → Bp6DyaGr7Ah4mCbj.mjs} +2 -2
- package/node/esm/BxIw0JqQD7Ibk44S.mjs +103 -0
- package/node/esm/{DiZJjw3IrOJhpe5p.mjs → C6J3DXYnvgXi5m4u.mjs} +1 -1
- package/node/esm/{D8Nhs3gz4-jRbvJR.mjs → CAXzH3lCFKI5mhsY.mjs} +2 -2
- package/node/esm/CBpG1x4pS6pNfRR1.mjs +461 -0
- package/node/esm/{C7-xjC8Lj2O146i0.mjs → CDx7cgKCqLflEubV.mjs} +1 -1
- package/node/esm/{wMu6qavkExEvCP9w.mjs → CFL1BiUsTE9X1-c8.mjs} +24 -24
- package/node/esm/{BFSKvA0b7rgbSW6P.mjs → CHBfOuyPAMiTojvS.mjs} +97 -110
- package/node/esm/{DzDcGqDCrlXyZGFT.mjs → CJIgRvLMiUJG79DB.mjs} +1 -1
- package/node/esm/{OIr4GV8spsS0lHX8.mjs → CcbjmWOlODDY8gGF.mjs} +1 -1
- package/node/esm/CdrSmZ9WDzkEGAXL.mjs +695 -0
- package/node/esm/{DxONr2LD1x7bwMGg.mjs → Ck0jN6hnefC5Hbsk.mjs} +22 -22
- package/node/esm/{B8w-DV7qSRfQye14.mjs → CkGQNbOwGQPWEcUf.mjs} +2 -2
- package/node/esm/{CUDMxAfvU8oooK2c.mjs → D283LXrMqi3exI_l.mjs} +1 -1
- package/node/esm/DH0tw27cVxmy7-AI.mjs +40 -0
- package/node/esm/{Calh2yf8E7k7eyxM.mjs → DJ4lhPXDGigmgQ-y.mjs} +2 -2
- package/node/esm/{Rl3tQd58HLEsY11C.mjs → DUZYSELfaHMSnDU2.mjs} +1 -1
- package/node/esm/{CsCU9lo125xnF_Ca.mjs → DZYzjxDF58TKD0xV.mjs} +2 -2
- package/node/esm/{Bz5j26qH_sdjuoGi.mjs → Debl1EJrMSlRwGcN.mjs} +2 -2
- package/node/esm/{DlFptlPZHQuBgG50.mjs → Dga-nEOi0B5TjgH6.mjs} +148 -148
- package/node/esm/{DLvtpSUsavFrtiw5.mjs → Diszdr1X5yDuuIzT.mjs} +1 -1
- package/node/esm/{D6KPG_DnQJRP4iGb.mjs → Dms4poPA6WOC4jyK.mjs} +1 -1
- package/node/esm/{B-CirwhCWSk3r-uN.mjs → DnjxhVMqfBhfsNHj.mjs} +14 -14
- package/node/esm/{Bj1JsBoPHXCz4fFP.mjs → DsoWGkhZNfvhmpK-.mjs} +2 -2
- package/node/esm/DyKgKDqbquskgXEA.mjs +828 -0
- package/node/esm/{XEQfvW0ujUY6vUoF.mjs → DzZb-LzjScchWCpk.mjs} +66 -67
- package/node/esm/{CEblCNurnWlc2SK0.mjs → MvXs13X1leYt7rBb.mjs} +2 -2
- package/node/esm/{D0ouF5sfJzhQUuQg.mjs → SBp59gHxCkFpvNwi.mjs} +1 -1
- package/node/esm/{B2ba9oxCLDj7q9Fz.mjs → iJrkLXWLGxVhCmtE.mjs} +1 -1
- package/node/esm/index.mjs +3294 -3031
- package/node/esm/{5cll_oe5x8KteiZX.mjs → l0liY9jxGCFXsxNX.mjs} +1 -1
- package/node/esm/{BzEIi_Iy_4PrcaE_.mjs → mhPcr4NaFejGRG5p.mjs} +1 -1
- package/node/esm/{CwfKrba55FGBz2Jb.mjs → vfgV7wwOvzh9iYjc.mjs} +1 -1
- package/package.json +9 -9
- package/resources/locales/de/groups.cmd.json +4 -6
- package/resources/locales/de/ui.msg.json +164 -3
- package/resources/locales/en/groups.cmd.json +4 -6
- package/resources/locales/en/ui.msg.json +164 -3
- package/types/src/anomalies/AnomaliesCommands.d.ts +1 -1
- package/types/src/chart/ChartDetailsPanel.d.ts +34 -0
- package/types/src/chart/ChartDetailsTaskPane.d.ts +9 -0
- package/types/src/chart/ChartFormatPanel.d.ts +12 -14
- package/types/src/chart/command/ChartColorsCommandButton.d.ts +54 -0
- package/types/src/chart/command/ChartStyleCommandButton.d.ts +64 -0
- package/types/src/chart/command/InsertChartCommandButton.d.ts +15 -0
- package/types/src/chart/command/index.d.ts +2 -0
- package/types/src/chart/format/ChartElementFormat.d.ts +54 -0
- package/types/src/chart/pane/ChartPaneModel.d.ts +134 -0
- package/types/src/chart/pane/ChartPaneRow.d.ts +77 -0
- package/types/src/color/ColorSetSwatch.d.ts +34 -0
- package/types/src/color/index.d.ts +1 -0
- package/types/src/command/NumberFormatQuickButtons.d.ts +1 -1
- package/types/src/format/FillPanel.d.ts +1 -3
- package/types/src/format/FormatPanelParts.d.ts +2 -2
- package/types/src/format/FormatPlugin.d.ts +2 -2
- package/types/src/format/FormatTaskPane.d.ts +4 -10
- package/types/src/format/LinePanel.d.ts +0 -2
- package/types/src/format/editor/FormatEditor.d.ts +36 -0
- package/types/src/format/editor/FormatField.d.ts +97 -0
- package/types/src/format/editor/FormatFields.d.ts +20 -0
- package/types/src/format/editor/index.d.ts +4 -0
- package/types/src/format/index.d.ts +1 -0
- package/types/src/format/useFormatSelection.d.ts +0 -2
- package/types/src/index.d.ts +1 -1
- package/types/src/shape/ShapeFormatPanel.d.ts +3 -7
- package/types/src/workbook/DefaultRenderers.d.ts +7 -1
- package/browser/esm/7afcXNPsXUui-iRB.mjs +0 -517
- package/browser/esm/CeElTSJMZukT5ODA.mjs +0 -516
- package/browser/esm/DJ0FThW4hRGIvy2O.mjs +0 -72
- package/node/esm/BGlQ9Ae_1Kf9chO-.mjs +0 -1831
- package/node/esm/CTibYRwgtHRsGojh.mjs +0 -519
- package/node/esm/D2GNY72eMSKe5Gt7.mjs +0 -516
- package/node/esm/DrpnqRfDHbua0oN6.mjs +0 -73
- package/types/src/studio/StudioSplitPane.d.ts +0 -60
|
@@ -0,0 +1,695 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v1.0.6
|
|
3
|
+
*
|
|
4
|
+
* (C) 2026-present SheetXL Inc. & Michael T. Ford
|
|
5
|
+
* License: MIT
|
|
6
|
+
*/
|
|
7
|
+
import { d as e } from "./index.mjs";
|
|
8
|
+
import { o as t } from "./vfgV7wwOvzh9iYjc.mjs";
|
|
9
|
+
import { t as n } from "./DyKgKDqbquskgXEA.mjs";
|
|
10
|
+
import { a, i as r, n as i, r as l, t as o } from "./CBpG1x4pS6pNfRR1.mjs";
|
|
11
|
+
import { i as d, r as s } from "./B_XE-SYyFRwWgVyQ.mjs";
|
|
12
|
+
import { TaskPaneEmpty as c, TaskPaneKey as p, chartIconKey as m, useWorksheet as h } from "@sheetxl/react";
|
|
13
|
+
import { DynamicIcon as u, useCallbackRef as g, useCommands as x, useTranslator as b } from "@sheetxl/utils-react";
|
|
14
|
+
import { memo as f, useEffect as y, useLayoutEffect as v, useReducer as C, useRef as w, useState as S } from "react";
|
|
15
|
+
import { Fragment as T, jsx as I, jsxs as k } from "react/jsx-runtime";
|
|
16
|
+
import { Box as D, ButtonBase as z, Collapse as A, IconButton as R, ListItemIcon as W, MenuItem as H, Paper as B, Select as E, Switch as K, Tooltip as L, Typography as O } from "@mui/material";
|
|
17
|
+
var j = (e) => {
|
|
18
|
+
const { type: t, label: n, disabled: a, run: r } = e, i = t.options(), l = (e) => I(u, {
|
|
19
|
+
iconKey: m(e),
|
|
20
|
+
size: 16
|
|
21
|
+
});
|
|
22
|
+
return I(E, {
|
|
23
|
+
variant: "standard",
|
|
24
|
+
disableUnderline: !0,
|
|
25
|
+
size: "small",
|
|
26
|
+
disabled: a,
|
|
27
|
+
value: t.get(),
|
|
28
|
+
onChange: (e) => {
|
|
29
|
+
const n = e.target.value;
|
|
30
|
+
r(() => t.set(n));
|
|
31
|
+
},
|
|
32
|
+
SelectDisplayProps: { "aria-label": n },
|
|
33
|
+
renderValue: (e) => I("span", {
|
|
34
|
+
title: i.find((t) => t.type === e)?.label ?? e,
|
|
35
|
+
style: { display: "inline-flex" },
|
|
36
|
+
children: l(e)
|
|
37
|
+
}),
|
|
38
|
+
sx: {
|
|
39
|
+
flex: "none",
|
|
40
|
+
maxWidth: 96,
|
|
41
|
+
marginInline: .5,
|
|
42
|
+
"& .MuiSelect-select": {
|
|
43
|
+
display: "flex",
|
|
44
|
+
alignItems: "center",
|
|
45
|
+
paddingBlock: .25
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
children: i.map((e) => k(H, {
|
|
49
|
+
value: e.type,
|
|
50
|
+
children: [I(W, { children: l(e.type) }), e.label]
|
|
51
|
+
}, e.type))
|
|
52
|
+
});
|
|
53
|
+
}, M = (e) => {
|
|
54
|
+
const { node: r, context: i, listId: l = "", count: o = 0, card: d = !1 } = e, { t: s, disabled: c, run: p, open: m, active: h, drag: g } = i, x = c ? void 0 : r.order, b = () => {
|
|
55
|
+
const e = g.current;
|
|
56
|
+
return !!x && !!e && e.listId === l && e.node.id !== r.id && !!e.node.order;
|
|
57
|
+
}, f = r.swatch?.(), y = !r.leaf && m.has(r.id), v = null !== h && h === r.element, C = i.lit === r.id, w = !r.toggle || r.toggle.get(), S = `chart-pane-body:${r.id}`;
|
|
58
|
+
return k(D, {
|
|
59
|
+
"data-row": r.id,
|
|
60
|
+
"data-row-kind": r.kind,
|
|
61
|
+
"data-row-active": v ? "" : void 0,
|
|
62
|
+
sx: {
|
|
63
|
+
minWidth: 0,
|
|
64
|
+
border: 1,
|
|
65
|
+
borderColor: v ? "primary.main" : "divider",
|
|
66
|
+
borderRadius: 1,
|
|
67
|
+
...d ? { backgroundColor: "background.paper" } : null
|
|
68
|
+
},
|
|
69
|
+
children: [k(D, {
|
|
70
|
+
ref: (e) => i.registerRow(r.id, e),
|
|
71
|
+
draggable: !!x || void 0,
|
|
72
|
+
onDragStart: x ? (e) => {
|
|
73
|
+
g.current = {
|
|
74
|
+
node: r,
|
|
75
|
+
listId: l
|
|
76
|
+
}, e.dataTransfer.effectAllowed = "move", e.dataTransfer.setData("text/plain", r.label);
|
|
77
|
+
} : void 0,
|
|
78
|
+
onDragEnd: x ? () => {
|
|
79
|
+
g.current = null, i.setDropTarget(null);
|
|
80
|
+
} : void 0,
|
|
81
|
+
onDragOver: x ? (e) => {
|
|
82
|
+
b() && (e.preventDefault(), e.dataTransfer.dropEffect = "move", i.dropTarget !== r.id && i.setDropTarget(r.id));
|
|
83
|
+
} : void 0,
|
|
84
|
+
onDrop: x ? (e) => {
|
|
85
|
+
if (!b()) return;
|
|
86
|
+
e.preventDefault();
|
|
87
|
+
const t = g.current.node;
|
|
88
|
+
g.current = null, i.setDropTarget(null), p(() => t.order.set(x.get()));
|
|
89
|
+
} : void 0,
|
|
90
|
+
sx: {
|
|
91
|
+
display: "flex",
|
|
92
|
+
alignItems: "center",
|
|
93
|
+
minHeight: 36,
|
|
94
|
+
borderRadius: 1,
|
|
95
|
+
paddingInlineEnd: "6px",
|
|
96
|
+
"& .chart-pane-hover": { opacity: 0 },
|
|
97
|
+
"&:hover .chart-pane-hover, &:focus-within .chart-pane-hover": { opacity: 1 },
|
|
98
|
+
"@media (hover: none)": { "& .chart-pane-hover": { opacity: 1 } },
|
|
99
|
+
boxShadow: (e) => i.dropTarget === r.id ? `inset 0 2px 0 ${e.palette.primary.main}` : "none"
|
|
100
|
+
},
|
|
101
|
+
children: [
|
|
102
|
+
k(z, {
|
|
103
|
+
disableRipple: !0,
|
|
104
|
+
focusVisibleClassName: "chart-pane-focus",
|
|
105
|
+
"aria-expanded": r.leaf ? void 0 : y,
|
|
106
|
+
"aria-controls": r.leaf ? void 0 : S,
|
|
107
|
+
onClick: () => i.onToggleOpen(r),
|
|
108
|
+
onKeyDown: x ? (e) => {
|
|
109
|
+
if (!e.altKey || "ArrowUp" !== e.key && "ArrowDown" !== e.key) return;
|
|
110
|
+
e.preventDefault();
|
|
111
|
+
const t = x.get() + ("ArrowUp" === e.key ? -1 : 1);
|
|
112
|
+
t >= 0 && t < o && p(() => x.set(t));
|
|
113
|
+
} : void 0,
|
|
114
|
+
sx: {
|
|
115
|
+
flex: r.type ? "0 1 auto" : "1 1 auto",
|
|
116
|
+
minWidth: 0,
|
|
117
|
+
minHeight: 36,
|
|
118
|
+
justifyContent: "flex-start",
|
|
119
|
+
gap: .5,
|
|
120
|
+
px: .5,
|
|
121
|
+
borderRadius: 1,
|
|
122
|
+
textAlign: "start",
|
|
123
|
+
"&.chart-pane-focus": {
|
|
124
|
+
outline: "2px solid",
|
|
125
|
+
outlineColor: "primary.main",
|
|
126
|
+
outlineOffset: "-2px"
|
|
127
|
+
}
|
|
128
|
+
},
|
|
129
|
+
children: [
|
|
130
|
+
r.leaf ? I(D, {
|
|
131
|
+
component: "span",
|
|
132
|
+
sx: {
|
|
133
|
+
flex: "none",
|
|
134
|
+
width: 18
|
|
135
|
+
}
|
|
136
|
+
}) : I(D, {
|
|
137
|
+
component: "span",
|
|
138
|
+
"data-chevron-lit": C ? "" : void 0,
|
|
139
|
+
sx: {
|
|
140
|
+
display: "inline-flex",
|
|
141
|
+
transition: "transform 120ms, color 120ms",
|
|
142
|
+
transform: y ? "none" : "rotate(-90deg)",
|
|
143
|
+
color: v || C ? "primary.main" : "inherit"
|
|
144
|
+
},
|
|
145
|
+
children: I(u, {
|
|
146
|
+
iconKey: "ExpandMore",
|
|
147
|
+
size: 18,
|
|
148
|
+
ariaHidden: !0
|
|
149
|
+
})
|
|
150
|
+
}),
|
|
151
|
+
r.swatch ? I(D, {
|
|
152
|
+
component: "span",
|
|
153
|
+
"data-swatch": f ?? "",
|
|
154
|
+
sx: {
|
|
155
|
+
flex: "none",
|
|
156
|
+
width: 12,
|
|
157
|
+
height: 12,
|
|
158
|
+
borderRadius: .5,
|
|
159
|
+
border: "1px solid",
|
|
160
|
+
borderColor: "divider",
|
|
161
|
+
backgroundColor: f ?? "transparent"
|
|
162
|
+
}
|
|
163
|
+
}) : null,
|
|
164
|
+
I(O, {
|
|
165
|
+
variant: "body2",
|
|
166
|
+
component: "span",
|
|
167
|
+
noWrap: !0,
|
|
168
|
+
sx: { color: w ? "text.primary" : "text.secondary" },
|
|
169
|
+
children: r.label
|
|
170
|
+
})
|
|
171
|
+
]
|
|
172
|
+
}),
|
|
173
|
+
r.type ? k(T, { children: [I(j, {
|
|
174
|
+
type: r.type,
|
|
175
|
+
label: s("chart.pane.seriesType", { name: r.name }),
|
|
176
|
+
disabled: c,
|
|
177
|
+
run: p
|
|
178
|
+
}), I(D, {
|
|
179
|
+
"aria-hidden": !0,
|
|
180
|
+
onClick: () => i.onToggleOpen(r),
|
|
181
|
+
sx: {
|
|
182
|
+
flex: "1 1 auto",
|
|
183
|
+
alignSelf: "stretch",
|
|
184
|
+
minWidth: 0,
|
|
185
|
+
cursor: "pointer"
|
|
186
|
+
}
|
|
187
|
+
})] }) : null,
|
|
188
|
+
r.element ? I(R, {
|
|
189
|
+
className: "chart-pane-hover",
|
|
190
|
+
size: "small",
|
|
191
|
+
"aria-label": s("chart.pane.format", { name: r.name }),
|
|
192
|
+
onClick: () => i.onFormat(r),
|
|
193
|
+
children: I(u, {
|
|
194
|
+
iconKey: "Format",
|
|
195
|
+
size: 18,
|
|
196
|
+
ariaHidden: !0
|
|
197
|
+
})
|
|
198
|
+
}) : null,
|
|
199
|
+
r.remove ? I(R, {
|
|
200
|
+
className: "chart-pane-hover",
|
|
201
|
+
size: "small",
|
|
202
|
+
disabled: c,
|
|
203
|
+
"aria-label": s("chart.pane.remove", { name: r.name }),
|
|
204
|
+
onClick: () => p(r.remove),
|
|
205
|
+
children: I(u, {
|
|
206
|
+
iconKey: "Delete",
|
|
207
|
+
size: 18,
|
|
208
|
+
ariaHidden: !0
|
|
209
|
+
})
|
|
210
|
+
}) : null,
|
|
211
|
+
r.toggle ? I(D, {
|
|
212
|
+
sx: {
|
|
213
|
+
flex: "none",
|
|
214
|
+
width: 44,
|
|
215
|
+
display: "flex",
|
|
216
|
+
justifyContent: "flex-end"
|
|
217
|
+
},
|
|
218
|
+
children: I(K, {
|
|
219
|
+
size: "small",
|
|
220
|
+
disabled: c,
|
|
221
|
+
checked: w,
|
|
222
|
+
onChange: (e) => {
|
|
223
|
+
const t = e.target.checked;
|
|
224
|
+
p(() => r.toggle.set(t));
|
|
225
|
+
},
|
|
226
|
+
slotProps: { input: { "aria-label": s("chart.pane.show", { name: r.name }) } }
|
|
227
|
+
})
|
|
228
|
+
}) : null
|
|
229
|
+
]
|
|
230
|
+
}), r.leaf ? null : I(A, {
|
|
231
|
+
in: y,
|
|
232
|
+
mountOnEnter: !0,
|
|
233
|
+
unmountOnExit: !0,
|
|
234
|
+
children: k(D, {
|
|
235
|
+
id: S,
|
|
236
|
+
"data-row-body": r.id,
|
|
237
|
+
sx: {
|
|
238
|
+
...t,
|
|
239
|
+
gap: 1,
|
|
240
|
+
marginInlineStart: "12px",
|
|
241
|
+
marginInlineEnd: 1,
|
|
242
|
+
marginBottom: 1,
|
|
243
|
+
paddingInlineStart: 1.5,
|
|
244
|
+
paddingTop: 1,
|
|
245
|
+
paddingBottom: 1,
|
|
246
|
+
borderInlineStart: "1px solid",
|
|
247
|
+
borderBottom: "1px solid",
|
|
248
|
+
borderEndStartRadius: "4px",
|
|
249
|
+
borderColor: C ? "primary.main" : "divider",
|
|
250
|
+
transition: "border-color 120ms"
|
|
251
|
+
},
|
|
252
|
+
children: [I(n, {
|
|
253
|
+
fields: r.fields(),
|
|
254
|
+
sheet: i.sheet,
|
|
255
|
+
disabled: c,
|
|
256
|
+
run: p
|
|
257
|
+
}), r.children().map((e) => a(e) ? I(N, {
|
|
258
|
+
list: e,
|
|
259
|
+
context: i,
|
|
260
|
+
nested: !0
|
|
261
|
+
}, e.id) : I(M, {
|
|
262
|
+
node: e,
|
|
263
|
+
context: i
|
|
264
|
+
}, e.id))]
|
|
265
|
+
})
|
|
266
|
+
})]
|
|
267
|
+
});
|
|
268
|
+
}, F = (e) => {
|
|
269
|
+
const { list: t, context: n } = e, { disabled: a } = n, r = t.items(), i = r.length > 0 && !n.open.has(V(t.id));
|
|
270
|
+
return k(D, {
|
|
271
|
+
"data-list": t.id,
|
|
272
|
+
sx: {
|
|
273
|
+
minWidth: 0,
|
|
274
|
+
display: "flex",
|
|
275
|
+
flexDirection: "column",
|
|
276
|
+
gap: .75,
|
|
277
|
+
border: 1,
|
|
278
|
+
borderColor: "divider",
|
|
279
|
+
borderRadius: 1,
|
|
280
|
+
paddingBottom: i ? 1 : 0,
|
|
281
|
+
"& > [data-row]": { marginInline: "8px" }
|
|
282
|
+
},
|
|
283
|
+
children: [k(D, {
|
|
284
|
+
sx: {
|
|
285
|
+
display: "flex",
|
|
286
|
+
alignItems: "center",
|
|
287
|
+
minHeight: 36,
|
|
288
|
+
paddingInlineEnd: "15px"
|
|
289
|
+
},
|
|
290
|
+
children: [k(z, {
|
|
291
|
+
disableRipple: !0,
|
|
292
|
+
focusVisibleClassName: "chart-pane-focus",
|
|
293
|
+
disabled: 0 === r.length,
|
|
294
|
+
"aria-expanded": r.length > 0 ? i : void 0,
|
|
295
|
+
onClick: () => n.onToggleList(t),
|
|
296
|
+
sx: {
|
|
297
|
+
flex: "1 1 auto",
|
|
298
|
+
minWidth: 0,
|
|
299
|
+
minHeight: 36,
|
|
300
|
+
justifyContent: "flex-start",
|
|
301
|
+
gap: .5,
|
|
302
|
+
px: .5,
|
|
303
|
+
borderRadius: 1,
|
|
304
|
+
textAlign: "start",
|
|
305
|
+
"&.chart-pane-focus": {
|
|
306
|
+
outline: "2px solid",
|
|
307
|
+
outlineColor: "primary.main",
|
|
308
|
+
outlineOffset: "-2px"
|
|
309
|
+
}
|
|
310
|
+
},
|
|
311
|
+
children: [0 === r.length ? I(D, {
|
|
312
|
+
component: "span",
|
|
313
|
+
sx: {
|
|
314
|
+
flex: "none",
|
|
315
|
+
width: 18
|
|
316
|
+
}
|
|
317
|
+
}) : I(D, {
|
|
318
|
+
component: "span",
|
|
319
|
+
sx: {
|
|
320
|
+
display: "inline-flex",
|
|
321
|
+
transition: "transform 120ms",
|
|
322
|
+
transform: i ? "none" : "rotate(-90deg)"
|
|
323
|
+
},
|
|
324
|
+
children: I(u, {
|
|
325
|
+
iconKey: "ExpandMore",
|
|
326
|
+
size: 18,
|
|
327
|
+
ariaHidden: !0
|
|
328
|
+
})
|
|
329
|
+
}), I(O, {
|
|
330
|
+
variant: "body2",
|
|
331
|
+
component: "span",
|
|
332
|
+
noWrap: !0,
|
|
333
|
+
sx: { color: "text.primary" },
|
|
334
|
+
children: t.label
|
|
335
|
+
})]
|
|
336
|
+
}), t.add ? I(R, {
|
|
337
|
+
size: "small",
|
|
338
|
+
disabled: a,
|
|
339
|
+
"aria-label": t.addLabel,
|
|
340
|
+
onClick: () => n.onAdd(t),
|
|
341
|
+
children: I(u, {
|
|
342
|
+
iconKey: "Add",
|
|
343
|
+
size: 18,
|
|
344
|
+
ariaHidden: !0
|
|
345
|
+
})
|
|
346
|
+
}) : null]
|
|
347
|
+
}), i ? r.map((e) => I(M, {
|
|
348
|
+
node: e,
|
|
349
|
+
context: n,
|
|
350
|
+
listId: t.id,
|
|
351
|
+
count: r.length
|
|
352
|
+
}, e.id)) : null]
|
|
353
|
+
});
|
|
354
|
+
}, V = (e) => `closed:${e}`, N = (e) => {
|
|
355
|
+
const { list: t, context: n, nested: a } = e, { disabled: r } = n;
|
|
356
|
+
if (a) return I(F, {
|
|
357
|
+
list: t,
|
|
358
|
+
context: n
|
|
359
|
+
});
|
|
360
|
+
const i = t.items();
|
|
361
|
+
return k(D, {
|
|
362
|
+
sx: { minWidth: 0 },
|
|
363
|
+
children: [k(D, {
|
|
364
|
+
sx: {
|
|
365
|
+
display: "flex",
|
|
366
|
+
alignItems: "center",
|
|
367
|
+
minHeight: 32,
|
|
368
|
+
paddingInlineStart: "9px",
|
|
369
|
+
paddingInlineEnd: "16px"
|
|
370
|
+
},
|
|
371
|
+
children: [I(O, {
|
|
372
|
+
variant: "subtitle2",
|
|
373
|
+
component: "div",
|
|
374
|
+
sx: {
|
|
375
|
+
flex: "1 1 auto",
|
|
376
|
+
minWidth: 0,
|
|
377
|
+
color: "text.primary"
|
|
378
|
+
},
|
|
379
|
+
children: t.label
|
|
380
|
+
}), t.add ? I(R, {
|
|
381
|
+
size: "small",
|
|
382
|
+
disabled: r,
|
|
383
|
+
"aria-label": t.addLabel,
|
|
384
|
+
onClick: () => n.onAdd(t),
|
|
385
|
+
children: I(u, {
|
|
386
|
+
iconKey: "Add",
|
|
387
|
+
size: 18,
|
|
388
|
+
ariaHidden: !0
|
|
389
|
+
})
|
|
390
|
+
}) : null]
|
|
391
|
+
}), k(D, {
|
|
392
|
+
"data-list": t.id,
|
|
393
|
+
sx: {
|
|
394
|
+
minWidth: 0,
|
|
395
|
+
display: "flex",
|
|
396
|
+
flexDirection: "column",
|
|
397
|
+
gap: .75,
|
|
398
|
+
padding: "8px",
|
|
399
|
+
border: 1,
|
|
400
|
+
borderColor: "divider",
|
|
401
|
+
borderRadius: 1,
|
|
402
|
+
backgroundColor: "action.hover"
|
|
403
|
+
},
|
|
404
|
+
children: [0 === i.length && t.empty ? I(O, {
|
|
405
|
+
variant: "caption",
|
|
406
|
+
component: "div",
|
|
407
|
+
"data-empty": !0,
|
|
408
|
+
sx: {
|
|
409
|
+
color: "text.secondary",
|
|
410
|
+
paddingBlock: .5,
|
|
411
|
+
paddingInlineStart: .5
|
|
412
|
+
},
|
|
413
|
+
children: t.empty
|
|
414
|
+
}) : null, i.map((e) => I(M, {
|
|
415
|
+
node: e,
|
|
416
|
+
context: n,
|
|
417
|
+
listId: t.id,
|
|
418
|
+
count: i.length,
|
|
419
|
+
card: !0
|
|
420
|
+
}, e.id))]
|
|
421
|
+
})]
|
|
422
|
+
});
|
|
423
|
+
}, P = f((a) => {
|
|
424
|
+
const { movable: c, sheet: h } = a, f = b(), T = c.getContent(), [, z] = C((e) => e + 1, 0);
|
|
425
|
+
y(() => T.addListeners({ onAnyChange: z }), [T]);
|
|
426
|
+
const A = h.getView().getChartElementSelection();
|
|
427
|
+
y(() => A.addListeners({ onChange: z }), [A]);
|
|
428
|
+
const W = A.getChart() === T ? A.getActive() : null, [H, B] = S(() => /* @__PURE__ */ new Set()), [E, K] = S(null), j = i(T, f), M = g((e) => {
|
|
429
|
+
try {
|
|
430
|
+
"chartArea" === e.getElementType() ? A.clear() : A.select([e]);
|
|
431
|
+
} catch {}
|
|
432
|
+
}, [A]), [F] = x([p.Format]), P = g((e, t) => {
|
|
433
|
+
M(e), F?.execute(t);
|
|
434
|
+
}, [M, F]), U = o(T, f, {
|
|
435
|
+
active: W,
|
|
436
|
+
select: M,
|
|
437
|
+
format: P
|
|
438
|
+
}), $ = w(/* @__PURE__ */ new Map()), q = w(null);
|
|
439
|
+
y(() => {
|
|
440
|
+
if (!W) return;
|
|
441
|
+
let e = null;
|
|
442
|
+
for (let t = W; t && !e; t = t.getParent()) e = r(U, t);
|
|
443
|
+
if (!e) return;
|
|
444
|
+
const t = e;
|
|
445
|
+
q.current = t[t.length - 1], B((e) => {
|
|
446
|
+
if (t.every((t) => e.has(t))) return e;
|
|
447
|
+
const n = new Set(e);
|
|
448
|
+
for (const e of t) n.add(e);
|
|
449
|
+
return n;
|
|
450
|
+
});
|
|
451
|
+
}, [W]), v(() => {
|
|
452
|
+
const e = q.current;
|
|
453
|
+
if (null === e) return;
|
|
454
|
+
const t = $.current.get(e);
|
|
455
|
+
t && (q.current = null, t.scrollIntoView?.({ block: "nearest" }));
|
|
456
|
+
});
|
|
457
|
+
const G = g((e) => {
|
|
458
|
+
try {
|
|
459
|
+
e(), K(null);
|
|
460
|
+
} catch (e) {
|
|
461
|
+
K(e?.message ?? String(e));
|
|
462
|
+
}
|
|
463
|
+
}, []), J = g((e) => {
|
|
464
|
+
if (e.leaf) return void (e.element && M(e.element));
|
|
465
|
+
const t = !H.has(e.id);
|
|
466
|
+
B((n) => {
|
|
467
|
+
const a = new Set(n);
|
|
468
|
+
return t ? a.add(e.id) : a.delete(e.id), a;
|
|
469
|
+
}), t && e.element && M(e.element);
|
|
470
|
+
}, [H, M]), Q = g((e) => {
|
|
471
|
+
const t = V(e.id);
|
|
472
|
+
B((e) => {
|
|
473
|
+
const n = new Set(e);
|
|
474
|
+
return n.has(t) ? n.delete(t) : n.add(t), n;
|
|
475
|
+
});
|
|
476
|
+
}, []), X = g((e) => {
|
|
477
|
+
e.element && P(e.element, e.tab);
|
|
478
|
+
}, [P]), Y = g((e, t) => {
|
|
479
|
+
t ? $.current.set(e, t) : $.current.delete(e);
|
|
480
|
+
}, []), Z = g((e) => {
|
|
481
|
+
G(() => {
|
|
482
|
+
const t = e.add?.();
|
|
483
|
+
"string" == typeof t && (q.current = t), B((n) => {
|
|
484
|
+
const a = new Set(n);
|
|
485
|
+
return a.delete(V(e.id)), "string" == typeof t && a.add(t), a;
|
|
486
|
+
});
|
|
487
|
+
});
|
|
488
|
+
}, [G]), [_, ee] = S(null), [te, ne] = S(null), ae = (e) => e?.closest?.("[data-row-body]")?.getAttribute("data-row-body") ?? null, re = w(null), [ie, le] = S(null), oe = {
|
|
489
|
+
sheet: h,
|
|
490
|
+
t: f,
|
|
491
|
+
disabled: T.isReadOnly(),
|
|
492
|
+
run: G,
|
|
493
|
+
open: H,
|
|
494
|
+
onToggleOpen: J,
|
|
495
|
+
onToggleList: Q,
|
|
496
|
+
onFormat: X,
|
|
497
|
+
lit: _ ?? te,
|
|
498
|
+
active: W,
|
|
499
|
+
registerRow: Y,
|
|
500
|
+
onAdd: Z,
|
|
501
|
+
drag: re,
|
|
502
|
+
dropTarget: ie,
|
|
503
|
+
setDropTarget: le
|
|
504
|
+
}, de = l(f, j.area), se = g((e) => {
|
|
505
|
+
G(() => j.type.set(e.type));
|
|
506
|
+
}, [G, j]), ce = g((e) => {
|
|
507
|
+
G(() => {
|
|
508
|
+
T.setChartStyle(e);
|
|
509
|
+
});
|
|
510
|
+
}, [G, T]), pe = g((e) => {
|
|
511
|
+
G(() => {
|
|
512
|
+
T.setColorScheme(e);
|
|
513
|
+
});
|
|
514
|
+
}, [G, T]);
|
|
515
|
+
return k(D, {
|
|
516
|
+
onMouseOver: (e) => {
|
|
517
|
+
const t = ae(e.target);
|
|
518
|
+
t !== _ && ee(t);
|
|
519
|
+
},
|
|
520
|
+
onMouseLeave: () => {
|
|
521
|
+
null !== _ && ee(null);
|
|
522
|
+
},
|
|
523
|
+
onFocus: (e) => {
|
|
524
|
+
const t = ae(e.target);
|
|
525
|
+
t !== te && ne(t);
|
|
526
|
+
},
|
|
527
|
+
onBlur: (e) => {
|
|
528
|
+
e.currentTarget.contains(e.relatedTarget) || null === te || ne(null);
|
|
529
|
+
},
|
|
530
|
+
sx: {
|
|
531
|
+
...t,
|
|
532
|
+
gap: 1.5,
|
|
533
|
+
paddingTop: (e) => e.spacing(1)
|
|
534
|
+
},
|
|
535
|
+
children: [
|
|
536
|
+
E ? I(O, {
|
|
537
|
+
variant: "caption",
|
|
538
|
+
color: "error",
|
|
539
|
+
role: "alert",
|
|
540
|
+
children: E
|
|
541
|
+
}) : null,
|
|
542
|
+
k(D, {
|
|
543
|
+
"data-section": "source",
|
|
544
|
+
sx: {
|
|
545
|
+
...t,
|
|
546
|
+
gap: 0,
|
|
547
|
+
minWidth: 0
|
|
548
|
+
},
|
|
549
|
+
children: [k(D, {
|
|
550
|
+
sx: {
|
|
551
|
+
...t,
|
|
552
|
+
gap: 2.5,
|
|
553
|
+
minWidth: 0,
|
|
554
|
+
paddingTop: .5
|
|
555
|
+
},
|
|
556
|
+
children: [I(n, {
|
|
557
|
+
fields: j.fields.slice(0, 1),
|
|
558
|
+
sheet: h,
|
|
559
|
+
disabled: oe.disabled,
|
|
560
|
+
run: G
|
|
561
|
+
}), k(D, {
|
|
562
|
+
sx: {
|
|
563
|
+
display: "flex",
|
|
564
|
+
alignItems: "center",
|
|
565
|
+
gap: .5,
|
|
566
|
+
minWidth: 0
|
|
567
|
+
},
|
|
568
|
+
children: [I(D, {
|
|
569
|
+
sx: {
|
|
570
|
+
flex: "1 1 auto",
|
|
571
|
+
minWidth: 0
|
|
572
|
+
},
|
|
573
|
+
children: I(n, {
|
|
574
|
+
fields: j.fields.slice(1),
|
|
575
|
+
sheet: h,
|
|
576
|
+
disabled: oe.disabled,
|
|
577
|
+
run: G
|
|
578
|
+
})
|
|
579
|
+
}), I(L, {
|
|
580
|
+
title: j.seriesBy.switchLabel,
|
|
581
|
+
children: I("span", { children: I(R, {
|
|
582
|
+
size: "small",
|
|
583
|
+
disabled: oe.disabled || j.seriesBy.disabled,
|
|
584
|
+
"data-series-by": j.seriesBy.disabled ? void 0 : j.seriesBy.get(),
|
|
585
|
+
"aria-label": j.seriesBy.switchLabel,
|
|
586
|
+
onClick: () => G(j.seriesBy.switch),
|
|
587
|
+
sx: { borderRadius: 1 },
|
|
588
|
+
children: I(u, {
|
|
589
|
+
iconKey: "PivotAxis",
|
|
590
|
+
size: 18,
|
|
591
|
+
ariaHidden: !0
|
|
592
|
+
})
|
|
593
|
+
}) })
|
|
594
|
+
})]
|
|
595
|
+
})]
|
|
596
|
+
}), k(D, {
|
|
597
|
+
role: "toolbar",
|
|
598
|
+
"aria-label": f("chart.pane.chartType"),
|
|
599
|
+
sx: {
|
|
600
|
+
display: "flex",
|
|
601
|
+
alignItems: "center",
|
|
602
|
+
gap: .5,
|
|
603
|
+
minWidth: 0,
|
|
604
|
+
padding: .5,
|
|
605
|
+
marginTop: 3.5,
|
|
606
|
+
border: 1,
|
|
607
|
+
borderColor: "divider",
|
|
608
|
+
borderRadius: 1
|
|
609
|
+
},
|
|
610
|
+
children: [
|
|
611
|
+
I(e, {
|
|
612
|
+
"data-chart-type": j.type.get(),
|
|
613
|
+
"aria-label": f("chart.pane.chartType"),
|
|
614
|
+
tip: {
|
|
615
|
+
label: f("chart.pane.chartType"),
|
|
616
|
+
description: j.type.label
|
|
617
|
+
},
|
|
618
|
+
icon: I(u, {
|
|
619
|
+
iconKey: m(j.type.get()),
|
|
620
|
+
size: 18
|
|
621
|
+
}),
|
|
622
|
+
disabled: oe.disabled,
|
|
623
|
+
onSelectType: se
|
|
624
|
+
}),
|
|
625
|
+
I(d, {
|
|
626
|
+
chart: T,
|
|
627
|
+
"data-chart-style-button": T.getChartStyle(),
|
|
628
|
+
"aria-label": f("chart.style.title"),
|
|
629
|
+
tip: {
|
|
630
|
+
label: f("chart.style.title"),
|
|
631
|
+
description: f("chart.style.name", { index: T.getChartStyle() })
|
|
632
|
+
},
|
|
633
|
+
disabled: oe.disabled,
|
|
634
|
+
onSelectStyle: ce
|
|
635
|
+
}),
|
|
636
|
+
I(s, {
|
|
637
|
+
chart: T,
|
|
638
|
+
"data-chart-colors-button": T.getColorScheme() ?? "",
|
|
639
|
+
"aria-label": f("chart.colors.title"),
|
|
640
|
+
tip: { label: f("chart.colors.title") },
|
|
641
|
+
disabled: oe.disabled,
|
|
642
|
+
onSelectScheme: pe
|
|
643
|
+
}),
|
|
644
|
+
I(D, { sx: { flex: "1 1 auto" } }),
|
|
645
|
+
I(L, {
|
|
646
|
+
title: f("chart.pane.format", { name: de }),
|
|
647
|
+
children: I(R, {
|
|
648
|
+
size: "small",
|
|
649
|
+
"aria-label": f("chart.pane.format", { name: de }),
|
|
650
|
+
onClick: () => P(j.area),
|
|
651
|
+
sx: { borderRadius: 1 },
|
|
652
|
+
children: I(u, {
|
|
653
|
+
iconKey: "Format",
|
|
654
|
+
size: 18,
|
|
655
|
+
ariaHidden: !0
|
|
656
|
+
})
|
|
657
|
+
})
|
|
658
|
+
})
|
|
659
|
+
]
|
|
660
|
+
})]
|
|
661
|
+
}),
|
|
662
|
+
U.map((e) => I(N, {
|
|
663
|
+
list: e,
|
|
664
|
+
context: oe
|
|
665
|
+
}, e.id))
|
|
666
|
+
]
|
|
667
|
+
});
|
|
668
|
+
});
|
|
669
|
+
P.displayName = "ChartDetailsPanel";
|
|
670
|
+
var U = (e) => {
|
|
671
|
+
const { model: t, entryKey: n, args: a, frame: r, ref: i, ...l } = e, o = h(), d = b(), [, s] = C((e) => e + 1, 0);
|
|
672
|
+
y(() => o?.getView().addListeners({ onMovableSelectionChange: s }), [o]);
|
|
673
|
+
const p = o?.getView().getMovableSelection().getActive() ?? null, m = p?.getContent(), u = "chart" === m?.getType() ? m : null;
|
|
674
|
+
return I(B, {
|
|
675
|
+
square: !0,
|
|
676
|
+
ref: i,
|
|
677
|
+
sx: {
|
|
678
|
+
display: "flex",
|
|
679
|
+
flexDirection: "column",
|
|
680
|
+
flex: "1 1 auto",
|
|
681
|
+
width: "100%",
|
|
682
|
+
height: "100%",
|
|
683
|
+
minHeight: 0,
|
|
684
|
+
overflow: "auto",
|
|
685
|
+
boxSizing: "border-box",
|
|
686
|
+
padding: (e) => e.spacing(1, 2, 2)
|
|
687
|
+
},
|
|
688
|
+
...l,
|
|
689
|
+
children: o && p && u ? I(P, {
|
|
690
|
+
movable: p,
|
|
691
|
+
sheet: o
|
|
692
|
+
}, u.getId()) : I(c, { children: d("chart.details.empty") })
|
|
693
|
+
});
|
|
694
|
+
};
|
|
695
|
+
export { U as ChartDetailsTaskPane, U as default };
|