@sheetxl/studio-mui 0.3.3 → 0.3.4
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/cjs/B1DCwLSJMTHSgdcP.cjs +6 -0
- package/browser/cjs/{YpWYrg3Eysqtr9aZ.cjs → BHC1oqfBYh7Xmx_G.cjs} +1 -1
- package/browser/cjs/{DAyHZyXZGsDWfbyd.cjs → BMUOX4KpmBu6GH8Q.cjs} +1 -1
- package/browser/cjs/BsXtNRaOhnjlXTcA.cjs +6 -0
- package/browser/cjs/{scolQa-PxnIvyiDb.cjs → Bwk2L5ydEvoRIisp.cjs} +1 -1
- package/browser/cjs/{DSNu0kgR1_X-nK_Z.cjs → C0hVi0a9d9Sh_FgO.cjs} +2 -2
- package/browser/cjs/{B0-aLTQ0dAlPdRnQ.cjs → C0sbobSHWURMB8m0.cjs} +3 -3
- package/browser/cjs/{C9TJkm0tBPD04idM.cjs → C1GrJth6YhBZDgvq.cjs} +2 -2
- package/browser/cjs/{D8qPzQKLyGrgGg08.cjs → CB6TEerfGxS24WUy.cjs} +2 -2
- package/browser/cjs/CBIj9rqxh2ze9ckF.cjs +6 -0
- package/browser/cjs/CkdT8JSum0WmJ7Tn.cjs +87 -0
- package/browser/cjs/CtKfykOLBwpCtsPd.cjs +11 -0
- package/browser/cjs/D9t4mfnS94EkWCXT.cjs +6 -0
- package/browser/cjs/{D69p4DRnZE5Oa52x.cjs → DEa9UMmpvbiH_Dxm.cjs} +1 -1
- package/browser/cjs/{CEx5ZMI8c4HYrxzW.cjs → DY0yxZSYTOZvtIkB.cjs} +1 -1
- package/browser/cjs/DbczL66CNJYzHHvr.cjs +12 -0
- package/browser/cjs/{BL1st_QvuF5m8AaJ.cjs → DfPqfTiRAZ9i5RVA.cjs} +2 -2
- package/browser/cjs/{BlBsVySC7wICKf3b.cjs → Dpc0lG73ekHkTPOA.cjs} +2 -2
- package/browser/cjs/{BH160EggM2K8qaSr.cjs → DzdnNJvBx5lkLTW-.cjs} +1 -1
- package/browser/cjs/EPoWWLrVLfRMaxvD.cjs +6 -0
- package/browser/cjs/_JBLryXFRVS5vFVX.cjs +12 -0
- package/browser/cjs/{CPKZW7FfYlmkNYbE.cjs → edAxlEEqzjJ_PaBv.cjs} +2 -2
- package/browser/cjs/{Bh785l7WNSK7G3hU.cjs → f1m-IERoDbQdUMNJ.cjs} +1 -1
- package/browser/cjs/index.cjs +2 -2
- package/browser/cjs/{CP_eU6V1jkcP4WtQ.cjs → j8ba84pFnKx2xWvW.cjs} +2 -2
- package/browser/cjs/{BQyDL6TxMqPmkugH.cjs → xRKATlLPCXjQqLyR.cjs} +1 -1
- package/browser/esm/{DpJqkBHKECEClAah.mjs → B3E24eA0KrqZGcc6.mjs} +6 -6
- package/browser/esm/{C8eXD0cT7ZPGYNCl.mjs → B7spDz0f3MErGle0.mjs} +21 -20
- package/browser/esm/{DTW06ga7BIWfkpc3.mjs → BQSJPoCxw_CbM_GB.mjs} +11 -10
- package/browser/esm/{QNCUQO7a-oixacNG.mjs → C0HMqAubZ7789bne.mjs} +1 -1
- package/browser/esm/{B1fKMAH-vx3TJ0ii.mjs → C72RDqmHBctKx6yu.mjs} +1 -1
- package/browser/esm/{B9IRFHtuYz6_J4Sj.mjs → CSEDlIO1VyJbsJUh.mjs} +8 -8
- package/browser/esm/{BLiRvSBEJD-6dWH0.mjs → Ca8SXunZNcPT82kM.mjs} +1 -1
- package/browser/esm/{DJVGX60ly4BfiFse.mjs → Cbj_GBiwqMbV7xNp.mjs} +44 -43
- package/browser/esm/Cdr3G0s5DSG6bX6w.mjs +52 -0
- package/browser/esm/{5uqs7KjiX3pi6cd5.mjs → CoPf1k9QR8u7c9dJ.mjs} +10 -10
- package/browser/esm/{BXvDIYhOIHqmZQQo.mjs → CyUxX9cLgslryjv5.mjs} +1 -1
- package/browser/esm/{CE3LjR3RfccnMUQt.mjs → D7kxhKOLn3UAkGzE.mjs} +13 -13
- package/browser/esm/{PbEXrCdkQc02gfVZ.mjs → DGIZQy_4rgYfRKUt.mjs} +10 -10
- package/browser/esm/{BVjzMl2EkoD1ceqn.mjs → DJmEZGVO4DnLsMSK.mjs} +7 -7
- package/browser/esm/{BIQXdDApQqsa7WWH.mjs → DTY6o1fHyy7Ldm2E.mjs} +1 -1
- package/browser/esm/DhuuaOVgVDtHsSft.mjs +1467 -0
- package/browser/esm/{q1cTyqrb2yKNSDq5.mjs → Dig0J4i2Urjl9Z--.mjs} +170 -169
- package/browser/esm/{DrzfnYtbTkZ0Vztm.mjs → DmqNGi-j-G64Ah3R.mjs} +2 -2
- package/browser/esm/{BeMVD9uqSXo5o9U7.mjs → DnH6tB6PvfbWK92p.mjs} +13 -13
- package/browser/esm/{CTdZQdi5BoNPu7rZ.mjs → Sg5ukHMhDKaJmwC5.mjs} +65 -65
- package/browser/esm/{BCiGYy5wMbcNSF3g.mjs → TfEcJxbuvenMTWzb.mjs} +1 -1
- package/browser/esm/{0qppnWkLyeMGOizg.mjs → buSI99ehYQ3RDGh9.mjs} +1 -1
- package/browser/esm/index.mjs +74 -73
- package/browser/esm/{Dy7xNyqd4jfUcj2t.mjs → n91lwJODGYpl_0sb.mjs} +1 -1
- package/browser/esm/{B0k5xuPgYO9B-vto.mjs → oJzTpcQBF382AsoK.mjs} +16 -16
- package/browser/esm/tEvhefgL1pPAbBne.mjs +19828 -0
- package/licenses/dependencies.txt +156 -178
- package/node/esm/{BiiNcUkTIcWxOabS.mjs → B794OzAyQ2S3DUvE.mjs} +2 -2
- package/node/esm/{tk69oRoeZHf4vk1z.mjs → B9eTznHjWdKEfnmd.mjs} +13 -13
- package/node/esm/{CZlpZhqzgcRkv_bX.mjs → BA_RIYlnXvTDRdhy.mjs} +9 -9
- package/node/esm/{BnbhKW27rQ185mOb.mjs → BBUuSB5DBjPGuwXm.mjs} +2 -2
- package/node/esm/{Br_lQeehvACsDkzu.mjs → BPAWh9TN2AA_qg8Q.mjs} +13 -12
- package/node/esm/{Ro_fz9s3_2DHfiE-.mjs → BWxdcvg2Tp0Ysth3.mjs} +1 -1
- package/node/esm/{zQ0ozpm04cC2OG19.mjs → BX8ZbzM8Zfe_MtDJ.mjs} +22 -22
- package/node/esm/{DbzTWKX0Q8SGsGA4.mjs → BdXN9t5_NDfrKA2E.mjs} +29 -29
- package/node/esm/CaySzQgftaLFVU-a.mjs +25 -0
- package/node/esm/{CI3U9rEYT3a_Biw5.mjs → CrwtN-27La5MZ9yI.mjs} +1 -1
- package/node/esm/{cT4-HbwV7TBlRjja.mjs → Cug20O7hGugaeSka.mjs} +276 -275
- package/node/esm/{Cd5wE06_wa41Z6Wt.mjs → CwZUEv9f0ywDMV-Z.mjs} +12 -12
- package/node/esm/{CZA-oIez6io5vwv1.mjs → D0fA-N8eAJVD4a_b.mjs} +1 -1
- package/node/esm/{CBlVCA0uvCwlok1v.mjs → D1aU9ydYjq7iFVAr.mjs} +1 -1
- package/node/esm/{6L7TnSLCvI3zabFK.mjs → D2gUK2WMUbCR0-Kw.mjs} +24 -23
- package/node/esm/{C0eiYtK0Lkx4fQGc.mjs → D4HUF8JC55LqF87u.mjs} +86 -85
- package/node/esm/DOC-LvGYDU9FpsDS.mjs +553 -0
- package/node/esm/{D4ydLNNfUH8D41A7.mjs → DXNmGNM6ItcTOZyo.mjs} +1 -1
- package/node/esm/{D6wjzUXEh-Q71uoB.mjs → DY3eG9Mfo_-xsWGD.mjs} +2 -2
- package/node/esm/{BY1cZ8MXawge5drQ.mjs → Djc-gCpBoXNpI6yL.mjs} +2 -2
- package/node/esm/{BvOnjWMz5o3z-qWe.mjs → ILfHRiSFod9A2fKN.mjs} +1 -1
- package/node/esm/Sc5EyWF8aAI0xzOO.mjs +308 -0
- package/node/esm/{fENiUIb3u1Oy7Amv.mjs → dasEgLXLO2WWGkUm.mjs} +8 -8
- package/node/esm/index.mjs +12873 -41673
- package/package.json +8 -8
- package/browser/cjs/BAGEDalcFwfUrDOV.cjs +0 -6
- package/browser/cjs/BMcvveT3JniLuWWw.cjs +0 -6
- package/browser/cjs/B_JRx-UyLNBI8Jr9.cjs +0 -6
- package/browser/cjs/BbCINWmJNJ1UoABX.cjs +0 -6
- package/browser/cjs/BdPTNgv6BQFiJXiH.cjs +0 -238
- package/browser/cjs/BgqUvcQGSrZtIsnp.cjs +0 -6
- package/browser/cjs/Bub0lBbzpOagYy-6.cjs +0 -12
- package/browser/cjs/BvV0mrFKi8cdsSFF.cjs +0 -6
- package/browser/cjs/BxCxDRRwMVIA9T0Q.cjs +0 -6
- package/browser/cjs/BxbbUhKRSHRfeoNL.cjs +0 -32
- package/browser/cjs/C3RxbodVdJ0MR0eY.cjs +0 -11
- package/browser/cjs/C4zc2Ll270E135fR.cjs +0 -6
- package/browser/cjs/CEkRIfptK2yyy4PS.cjs +0 -6
- package/browser/cjs/CGp4fzG2ZIsJmB72.cjs +0 -6
- package/browser/cjs/CT5f8xMCNbOhih6R.cjs +0 -12
- package/browser/cjs/CV6WjeLkZrGoM4SB.cjs +0 -6
- package/browser/cjs/CZA_Av5pG0M1RgJK.cjs +0 -6
- package/browser/cjs/Ca6YJnV2DBQrqx0b.cjs +0 -124
- package/browser/cjs/Ci7CqdgErq0IGcl5.cjs +0 -6
- package/browser/cjs/CmROQEOLO7s-rzZW.cjs +0 -6
- package/browser/cjs/Cnc0-T-tLmqyX7Mq.cjs +0 -6
- package/browser/cjs/Ct6nh7ILtW_PHbB3.cjs +0 -6
- package/browser/cjs/CtmTxxgCijL1ZuPa.cjs +0 -6
- package/browser/cjs/CyUaP6X--CmuILoU.cjs +0 -6
- package/browser/cjs/D598Bk4npBA6UESy.cjs +0 -6
- package/browser/cjs/D7asEaPB97YVwe1v.cjs +0 -6
- package/browser/cjs/D9lDObZe3CkEPPGI.cjs +0 -6
- package/browser/cjs/DFrTuKkfDctye00L.cjs +0 -7
- package/browser/cjs/DNquPukGj-6iRmmP.cjs +0 -13
- package/browser/cjs/DOXD9gLvRI-UN_9l.cjs +0 -6
- package/browser/cjs/DRhcrHz-whpKmHXb.cjs +0 -6
- package/browser/cjs/DdBygPkI15syG3qE.cjs +0 -1501
- package/browser/cjs/DrgfA0AIigevE5fO.cjs +0 -15
- package/browser/cjs/DyjUI4ZuHoE2UtYP.cjs +0 -6
- package/browser/cjs/Ou0ysDOtKXD_MCyi.cjs +0 -6
- package/browser/cjs/Tkr7WOf1Km7F6jc1.cjs +0 -6
- package/browser/cjs/Ui6MyVXLy4hSZZln.cjs +0 -6
- package/browser/cjs/ZSSSnynZ-cYurCZ4.cjs +0 -6
- package/browser/cjs/hDl6HNkylTvv-qT3.cjs +0 -6
- package/browser/cjs/tLWq6abRGIT6oIrd.cjs +0 -6
- package/browser/cjs/xS50A4hbimnAA3g8.cjs +0 -6
- package/browser/esm/6qF6HMFmVJEMu5ze.mjs +0 -10
- package/browser/esm/91ZejdYNSNvEQyri.mjs +0 -43655
- package/browser/esm/B6KWiZxcJDzPKz7A.mjs +0 -10
- package/browser/esm/BGfz8kkDQwuckxnU.mjs +0 -10
- package/browser/esm/BNWWT7cxdCiMaWFC.mjs +0 -10
- package/browser/esm/BSB3k2C-vxhRI9pk.mjs +0 -5582
- package/browser/esm/Baiv07hkxLIkAcoq.mjs +0 -10
- package/browser/esm/Bc6K-JiRW1SodxIq.mjs +0 -10
- package/browser/esm/BpfyDNlbLX4dOPvj.mjs +0 -24
- package/browser/esm/Bs0RJigDhPR1WzFT.mjs +0 -21
- package/browser/esm/BtP3Wpc2YRk8W2KZ.mjs +0 -12
- package/browser/esm/BwWIlZYqfL7BAjSI.mjs +0 -10
- package/browser/esm/C7YTh7Sm32Nt_Kv5.mjs +0 -10
- package/browser/esm/CE1gssQmn8QAeBEI.mjs +0 -10
- package/browser/esm/CE3vBPdWXPf3M3h2.mjs +0 -51
- package/browser/esm/CJigh9OXZ04sdTLc.mjs +0 -1466
- package/browser/esm/CLHgqHwohIYlAAUF.mjs +0 -472
- package/browser/esm/CTuGnJMMNAi4EKiy.mjs +0 -10
- package/browser/esm/CUZmKq_NPR_OCibb.mjs +0 -10
- package/browser/esm/ChIE2YGkU9_cnmDj.mjs +0 -10
- package/browser/esm/Cv8VSqfWEaftgiTH.mjs +0 -10
- package/browser/esm/CvJUNcDyz497Gxl7.mjs +0 -10
- package/browser/esm/D2OQwThnobBdsQ1x.mjs +0 -3934
- package/browser/esm/D73ljnqYKCXMdyPd.mjs +0 -1575
- package/browser/esm/DAPWMPwVGQJsblPQ.mjs +0 -10
- package/browser/esm/Dsu3RRvUfCUWRZ6q.mjs +0 -10
- package/browser/esm/DxEtUnQEyEYWuqL7.mjs +0 -820
- package/browser/esm/Dxrje6uVvr2LGdV7.mjs +0 -10
- package/browser/esm/JMr0jtu67PC8clGf.mjs +0 -10
- package/browser/esm/QhTxW6tFl-So20AH.mjs +0 -425
- package/browser/esm/_tXPsCW6hHTdj45y.mjs +0 -10
- package/browser/esm/bJWg5_Jxjizyivdn.mjs +0 -29
- package/browser/esm/cVH-KYzKaUP4C3dh.mjs +0 -10
- package/browser/esm/cp8pKSzbJqh-zBtd.mjs +0 -10
- package/browser/esm/dmuee2Is7r5Q4B3M.mjs +0 -10
- package/node/esm/0CbEJyCpbWyFHdK1.mjs +0 -4002
- package/node/esm/6qF6HMFmVJEMu5ze.mjs +0 -10
- package/node/esm/A5WewF_ecyRMfEW9.mjs +0 -80
- package/node/esm/B0rQMzpUsBE47H-k.mjs +0 -10
- package/node/esm/B3TBImEZBAbKsEAq.mjs +0 -10
- package/node/esm/B6KWiZxcJDzPKz7A.mjs +0 -10
- package/node/esm/B8tFaB-W9JcM6xhy.mjs +0 -29
- package/node/esm/BGfz8kkDQwuckxnU.mjs +0 -10
- package/node/esm/BKb0zrP-OexxgIYb.mjs +0 -24
- package/node/esm/BNWWT7cxdCiMaWFC.mjs +0 -10
- package/node/esm/BQBHsnvwWPo5kQhy.mjs +0 -10
- package/node/esm/BZTLlsc-NvE1_mTb.mjs +0 -555
- package/node/esm/Baiv07hkxLIkAcoq.mjs +0 -10
- package/node/esm/Bc6K-JiRW1SodxIq.mjs +0 -10
- package/node/esm/BiVFM0O-4h4yY7oa.mjs +0 -10
- package/node/esm/Bq-gS5qqB1Jrllm2.mjs +0 -307
- package/node/esm/Bv7SpuMBfsaGEFxP.mjs +0 -16
- package/node/esm/BwWIlZYqfL7BAjSI.mjs +0 -10
- package/node/esm/C0qF-AAqNGDMeSVO.mjs +0 -813
- package/node/esm/CE1gssQmn8QAeBEI.mjs +0 -10
- package/node/esm/CUZmKq_NPR_OCibb.mjs +0 -10
- package/node/esm/ChIE2YGkU9_cnmDj.mjs +0 -10
- package/node/esm/CvJUNcDyz497Gxl7.mjs +0 -10
- package/node/esm/DAPWMPwVGQJsblPQ.mjs +0 -10
- package/node/esm/DJtTsiROzkkD2wRx.mjs +0 -5642
- package/node/esm/DLEDFraKFWvZtfvX.mjs +0 -10
- package/node/esm/DNYPU79SNlXuHN8j.mjs +0 -10
- package/node/esm/DjhMNAleaI3hhcHG.mjs +0 -13
- package/node/esm/DtUFCYSrTGcBjdBN.mjs +0 -453
- package/node/esm/Dxrje6uVvr2LGdV7.mjs +0 -10
- package/node/esm/EebvqIVFwWH3slRt.mjs +0 -14
- package/node/esm/cVH-KYzKaUP4C3dh.mjs +0 -10
- package/node/esm/cp8pKSzbJqh-zBtd.mjs +0 -10
- package/node/esm/dmuee2Is7r5Q4B3M.mjs +0 -10
|
@@ -1,307 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.3.3
|
|
3
|
-
*
|
|
4
|
-
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
|
-
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
-
*/
|
|
7
|
-
import { jsx as e, jsxs as o, Fragment as t } from "react/jsx-runtime";
|
|
8
|
-
import r, { forwardRef as n, useState as a, useCallback as s, memo as i, createElement as l, useMemo as c, useRef as d, useEffect as p, useLayoutEffect as m } from "react";
|
|
9
|
-
import u from "clsx";
|
|
10
|
-
import { mergeRefs as h } from "react-merge-refs";
|
|
11
|
-
import { ErrorBoundary as k } from "react-error-boundary";
|
|
12
|
-
import { useSnackbar as g, SnackbarContent as b, SnackbarProvider as w } from "notistack";
|
|
13
|
-
import { useTheme as f, ThemeProvider as y } from "@mui/material/styles/index.js";
|
|
14
|
-
import { Card as x, CardActions as C, Typography as M, IconButton as W, Collapse as v, Box as L, SvgIcon as S, CssBaseline as E } from "@mui/material";
|
|
15
|
-
import { _ as D, f as F, Z as T, q as O, t as I, F as P, h as A, W as N, k as R, WorkbookIO as j, X as _, U, j as H, m as K, N as G, Q as $, n as z, o as q, u as B, AppearanceCommandButton as V, v as J, w as X, E as Z, x as Q, y as Y, z as ee, useResolvedThemeMode as oe, ThemeMode as te, A as re, H as ne, I as ae, S as se, K as ie, L as le, HelpCommandButton as ce, M as de, R as pe, T as me, $ as ue, b as he, a0 as ke, a1 as ge, a2 as be, WorkbookTitle as we, WorkbookElement as fe, a3 as ye, a4 as xe } from "./index.mjs";
|
|
16
|
-
import { useMeasure as Ce } from "react-use";
|
|
17
|
-
import { ExpandMore as Me, Close as We, CancelOutlined as ve } from "@mui/icons-material";
|
|
18
|
-
const Le = { card: "_card_1a398_7", actionRoot: "_actionRoot_1a398_11", icons: "_icons_1a398_16", expand: "_expand_1a398_22", expandOpen: "_expandOpen_1a398_29", stackTraceContainer: "_stackTraceContainer_1a398_33" }, Se = n((t2, r2) => {
|
|
19
|
-
const { id: n2, message: i2, iconVariant: l2, error: c2, hideIconVariant: d2, ...p2 } = t2, { closeSnackbar: m2 } = g(), h2 = f(), [k2, w2] = a(false), y2 = s(() => {
|
|
20
|
-
w2((e2) => !e2);
|
|
21
|
-
}, []), L2 = s(() => {
|
|
22
|
-
m2(n2);
|
|
23
|
-
}, [n2, m2]), S2 = c2?.message || String(i2);
|
|
24
|
-
return e(b, { ref: r2, className: u(Le.root, "error-snackbar"), children: o(x, { className: Le.card, style: { backgroundColor: h2.palette.error.dark, border: `1px solid ${h2.palette.error.dark}` }, children: [o(C, { className: Le.actionRoot, children: [d2 ? null : l2?.error, e(M, { variant: "body2", component: "div", className: Le.typography, style: { color: h2.palette.text.primary }, children: S2 }), e("div", { style: { flex: "1 1 auto" } }), o("div", { className: Le.icons, children: [c2 ? e(W, { "aria-label": "Show more", size: "small", className: u(Le.expand, { [Le.expandOpen]: k2 }), style: { color: h2.palette.action.active }, onClick: y2, children: e(Me, {}) }) : null, e(W, { size: "small", className: Le.expand, style: { color: h2.palette.action.active }, onClick: L2, children: e(We, { fontSize: "small" }) })] })] }), c2 ? e(v, { in: k2, timeout: "auto", unmountOnExit: true, children: e("div", { className: Le.stackTraceContainer, style: { backgroundColor: h2.palette.error.light, borderTop: `1px solid ${h2.palette.error.main}` }, children: e(D, { error: c2, hideLineNumbers: true }) }) }) : null] }) });
|
|
25
|
-
});
|
|
26
|
-
Se.displayName = "ToastError";
|
|
27
|
-
const Ee = i(n((r2, n2) => {
|
|
28
|
-
const { commands: a2, commandHook: s2, scope: i2 = "workbook", disabled: c2 = false, ...d2 } = r2, p2 = F((r3) => {
|
|
29
|
-
const n3 = { variant: I.Menuitem, parentFloat: r3.floatReference, commandHook: s2, scope: i2, disabled: c2 }, d3 = o(t, { children: [e(T, { ...n3, command: a2.getCommand("newWorkbook"), icon: O(e(P, {})) }), e(A, { orientation: "horizontal" }), e(T, { ...n3, command: a2.getCommand("openWorkbook"), icon: O(e(N, {})) }), e(R, { ...n3, commands: a2, quickCommand: "saveWorkbook", icon: O(e(K, {})), createPopupPanel: (o2) => {
|
|
30
|
-
const t2 = { ...n3, parentFloat: o2.floatReference, scope: "saveWorkbook" }, r4 = [];
|
|
31
|
-
return j.getWriteFormats().forEach((o3) => {
|
|
32
|
-
if (o3.isDefault) return;
|
|
33
|
-
let n4 = null;
|
|
34
|
-
"CSV" === o3.key ? n4 = O(e(_, {})) : "Excel" === o3.key && (n4 = O(e(U, {})));
|
|
35
|
-
const s3 = a2.getCommand(`saveWorkbookAs${o3.key}`);
|
|
36
|
-
s3 ? r4.push(l(T, { ...t2, key: o3.key, command: s3, icon: n4 })) : console.warn(`Unable to resolve command: 'saveWorkbookAs${o3.key}'`);
|
|
37
|
-
}), H({ ...o2, children: r4, onClick: () => {
|
|
38
|
-
o2.closeFloatAll();
|
|
39
|
-
} });
|
|
40
|
-
} })] });
|
|
41
|
-
return H({ ...r3, children: d3, onClick: (e2) => {
|
|
42
|
-
e2.isDefaultPrevented || r3.closeFloatAll();
|
|
43
|
-
} });
|
|
44
|
-
}, [c2, a2, s2, i2]), m2 = "File";
|
|
45
|
-
return e(R, { commands: a2, disabled: c2, commandHook: s2, scope: i2, label: m2, tooltip: "Options for saving and loading the workbook.", sx: { paddingBottom: "0px", "& button": { paddingTop: "0px", paddingBottom: "0px", height: (e2) => `calc(1.25rem + ${e2.spacing(2)}px)` } }, ...d2, createPopupPanel: p2, icon: e(G, { className: "label", icon: null, label: m2 }) });
|
|
46
|
-
}));
|
|
47
|
-
Ee.displayName = "StandaloneFileCommandButton";
|
|
48
|
-
const De = e(q, { label: "SheetXL", description: "Visit me at sheetxl.com.", children: e(L, { sx: { width: "24px", height: "24px", marginBottom: "4px", marginLeft: "6px" }, children: e(B, { onClick: () => {
|
|
49
|
-
window?.open("https://www.sheetxl.com", "_blank");
|
|
50
|
-
}, style: { width: "24px", height: "24px", cursor: "pointer" } }) }) }), Fe = i(n((t2, r2) => {
|
|
51
|
-
const { commands: n2, workbook: a2, logo: s2 = De, mainElement: i2, showFileMenu: l2 = true, showAppearanceMenu: p2 = true, ...m2 } = t2, { reference: u2 } = $(), [k2, { width: g2 }] = Ce(), b2 = g2 < 530, w2 = l2 ? e(Ee, { commands: n2, commandHook: { beforeExecute() {
|
|
52
|
-
u2?.closeAll();
|
|
53
|
-
}, onError(e2, o2, t3) {
|
|
54
|
-
} } }) : null, f2 = p2 ? e(V, { commands: n2, commandHook: { beforeExecute() {
|
|
55
|
-
u2?.closeAll();
|
|
56
|
-
}, onError(e2, o2, t3) {
|
|
57
|
-
} } }) : null, y2 = c(() => ({ paddingLeft: (e2) => e2.spacing(1), paddingRight: (e2) => e2.spacing(1) }), []), x2 = d(null);
|
|
58
|
-
return e(L, { ref: h([x2, k2, r2]), ...m2, children: z({ commands: n2, renderCompact: b2, workbook: a2, selectWrapper: (t3) => o(L, { sx: { display: "flex", flex: "1", flexDirection: "row", alignItems: "stretch", gap: (e2) => e2.spacing(1), paddingLeft: (e2) => e2.spacing(1), paddingRight: (e2) => e2.spacing(1) }, children: [o(L, { sx: { display: "flex", flexDirection: "row", alignItems: "center", flex: "1 1 100%", gap: (e2) => e2.spacing(0.5) }, children: [s2, o(L, { sx: { display: "flex", flexDirection: "row", alignItems: "center", gap: (e2) => e2.spacing(0.25) }, children: [w2, t3] })] }), e(L, { sx: { display: "flex", flexDirection: "row", flex: "1 1 300%", overflow: "hidden", alignItems: "center", justifyContent: "center" }, children: i2 }), e(L, { sx: { display: "flex", alignItems: "center", justifyContent: "end", flex: b2 && !f2 ? "0 0 auto" : "1 1 100%" }, children: f2 })] }), selectProps: y2, toolbarsProps: { Home: { sx: {} } } }) });
|
|
59
|
-
}));
|
|
60
|
-
Fe.displayName = "StandaloneWorkbookToolbar";
|
|
61
|
-
const Te = i(n((n2, i2) => {
|
|
62
|
-
const { workbook: l2, setWorkbook: m2, refWorkbookTitle: u2, titleWorkbook: h2, setWorkbookTitle: k2, titlePlaceHolder: b2, children: w2, undoManager: f2, commands: y2, importExportDisabled: x2, themeModeOptions: C2 } = n2, M2 = g(), v2 = M2 ? M2.enqueueSnackbar : () => {
|
|
63
|
-
}, L2 = M2 ? M2.closeSnackbar : () => {
|
|
64
|
-
}, [S2, E2] = a({ isMounted: false, label: null, starting: /* @__PURE__ */ new Map(), running: /* @__PURE__ */ new Map() }), D2 = s(() => {
|
|
65
|
-
E2((e2) => ({ ...e2, isMounted: true }));
|
|
66
|
-
}, []), T2 = s(() => {
|
|
67
|
-
E2((e2) => ({ ...e2, isMounted: false }));
|
|
68
|
-
}, []), O2 = ne(), I2 = ae(), P2 = se(), A2 = d(/* @__PURE__ */ new Set()), N2 = c(() => {
|
|
69
|
-
const o2 = (o3, t2) => {
|
|
70
|
-
if (t2?.onceKey) {
|
|
71
|
-
if (A2.current.has(t2.onceKey)) return;
|
|
72
|
-
const e2 = new Set(A2.current);
|
|
73
|
-
e2.add(t2.onceKey), A2.current = e2;
|
|
74
|
-
}
|
|
75
|
-
const r2 = { variant: t2?.type ?? de.Info, anchorOrigin: { vertical: "top", horizontal: "center" }, preventDuplicate: t2?.preventDuplicate, persist: t2?.persist ?? t2?.type === de.Error, action: (o4) => e(W, { onClick: () => L2(o4), children: e(ve, {}) }) };
|
|
76
|
-
t2?.enqueueProps && Object.assign(r2, t2.enqueueProps), o3 || console.log("message is 'null'", t2), v2(o3 ?? "Alert", r2);
|
|
77
|
-
};
|
|
78
|
-
return { showMessage: o2, showBusy: (e2, o3) => {
|
|
79
|
-
let t2 = null;
|
|
80
|
-
const r2 = new Promise((e3) => {
|
|
81
|
-
t2 = e3;
|
|
82
|
-
});
|
|
83
|
-
return E2((o4) => {
|
|
84
|
-
const n3 = new Map(o4.starting);
|
|
85
|
-
n3.set(r2, t2);
|
|
86
|
-
return { ...o4, label: e2, starting: n3 };
|
|
87
|
-
}), r2;
|
|
88
|
-
}, showWindow: (e2, o3, t2) => {
|
|
89
|
-
const r2 = { ...o3, onKeyDown: (e3) => {
|
|
90
|
-
y2?.dispatchToFocusedCommand(e3), e3.isDefaultPrevented() || e3.isPropagationStopped() || o3?.onKeyDown?.(e3);
|
|
91
|
-
} };
|
|
92
|
-
return O2(e2, { sort: () => import("./BKb0zrP-OexxgIYb.mjs"), numberFormat: () => import("./Br_lQeehvACsDkzu.mjs"), hyperlink: () => import("./BnbhKW27rQ185mOb.mjs"), comments: () => import("./D6wjzUXEh-Q71uoB.mjs"), find: () => import("./6L7TnSLCvI3zabFK.mjs"), tableDetails: () => import("./DbzTWKX0Q8SGsGA4.mjs"), tableNew: () => import("./fENiUIb3u1Oy7Amv.mjs"), namedDetails: () => import("./tk69oRoeZHf4vk1z.mjs") }[e2], r2, t2);
|
|
93
|
-
}, showOptions: I2, showInputOptions: P2, showError: (e2) => {
|
|
94
|
-
let t2, r2 = de.Error, n3 = "Unknown Error";
|
|
95
|
-
"string" == typeof e2 ? n3 = e2 : e2 instanceof Error && (t2 = e2, e2.message && (n3 = e2.message)), e2 instanceof pe && (r2 = de.Info), o2(n3, { type: r2, enqueueProps: { error: t2 } });
|
|
96
|
-
} };
|
|
97
|
-
}, []), R2 = s(() => {
|
|
98
|
-
}, []), _2 = ((e2) => {
|
|
99
|
-
const { workbook: o2, setWorkbook: t2, importExportDisabled: n3, workbookTitle: a2 = "export", setWorkbookTitle: i3, notifier: l3, requestWorkbookTitle: d2, themeModeOptions: m3, undoManager: u3, commands: h3, onExecute: k3 } = e2, g2 = F(m3?.onForceModeChange, [m3?.onForceModeChange]), b3 = F(m3?.onForceLightGridChange, [m3?.onForceLightGridChange]), w3 = F(m3?.onForceLightImagesChange, [m3?.onForceLightImagesChange]), f3 = F(async (e3 = null, o3 = null) => {
|
|
100
|
-
const t3 = [];
|
|
101
|
-
let r2, n4 = null, a3 = null;
|
|
102
|
-
if ("string" == typeof e3 ? a3 = e3 : n4 = e3, r2 = n4 ? e3 : await J.openFileDialog(a3 ?? j.getAllReadFormatTypeAsString().join(",")), !r2) return null;
|
|
103
|
-
const s2 = { source: r2, constructorOptions: o3, onWarning: (e4) => {
|
|
104
|
-
t3.push(e4);
|
|
105
|
-
} }, i4 = await j.read(s2, l3);
|
|
106
|
-
return t3.length > 0 && (l3?.showMessage?.("Some elements were not able to be imported. See console for details."), console.warn("Import warnings:\n" + t3.join("\n"))), i4;
|
|
107
|
-
}, [k3, l3, o2]), y3 = F(async (e3, o3, t3) => {
|
|
108
|
-
if (!o3 && d2) {
|
|
109
|
-
const o4 = await d2("Enter Workbook name to " + (t3.isDefault ? "Save." : `Export as ${t3.description}.`));
|
|
110
|
-
return null !== o4 && j.writeFile(o4, e3, { formatType: t3.key });
|
|
111
|
-
}
|
|
112
|
-
return j.writeFile(o3, e3, { formatType: t3.key });
|
|
113
|
-
}, [l3, o2, d2]), x3 = s(() => ({ contains: (e3) => true, focus() {
|
|
114
|
-
} }), []), C3 = c(() => {
|
|
115
|
-
const e3 = [];
|
|
116
|
-
n3 || (j.getWriteFormats().forEach((t3) => {
|
|
117
|
-
const r3 = t3.isDefault, n4 = { label: r3 ? "Save Workbook" : `Save Workbook as ${t3.description}`, scopedLabels: { workbook: "Save", saveWorkbook: `as ${t3.description}` }, tags: t3.tags, description: `Save the workbook to the desktop${r3 ? "" : ` as ${t3.description}`}.` };
|
|
118
|
-
r3 && (n4.shortcut = { key: "S", modifiers: [Z.Ctrl] }, e3.push(new X("saveWorkbookAs", x3, { label: "Save Workbook As…", scopedLabels: { workbook: "Save as…", saveWorkbook: "as…" }, shortcut: [{ key: "S", modifiers: [Z.Shift, Z.Ctrl] }, { key: "F12" }], description: "Save the workbook to the desktop with the provided name." }, () => {
|
|
119
|
-
y3(o2, null, t3).catch((e4) => {
|
|
120
|
-
l3?.showError?.(e4);
|
|
121
|
-
});
|
|
122
|
-
})));
|
|
123
|
-
const s2 = r3 ? "saveWorkbook" : `saveWorkbookAs${t3.key}`;
|
|
124
|
-
e3.push(new X(s2, x3, n4, (e4) => {
|
|
125
|
-
y3(o2, e4 ?? a2, t3).catch((e5) => {
|
|
126
|
-
l3?.showError?.(e5);
|
|
127
|
-
});
|
|
128
|
-
}));
|
|
129
|
-
}), e3.push(new X("openWorkbook", x3, { label: "Open Workbook…", scopedLabels: { workbook: "Open…" }, description: "Open a workbook from the desktop.", shortcut: { key: "O", modifiers: [Z.Ctrl] } }, async (e4 = null) => {
|
|
130
|
-
const r3 = { date1904: o2.isDate1904(), ...o2.options };
|
|
131
|
-
try {
|
|
132
|
-
const n4 = await f3(e4, r3);
|
|
133
|
-
if (!n4) return;
|
|
134
|
-
const a3 = n4.title, s2 = n4.workbook, c2 = s2.getSelectedSheet();
|
|
135
|
-
if ("text/csv" === n4.formatType.mimeType) {
|
|
136
|
-
const e5 = o2.findValidSheetName(a3);
|
|
137
|
-
await o2.doBatch(async () => {
|
|
138
|
-
const t3 = c2.getUsedRange();
|
|
139
|
-
if (!t3) return void l3?.showMessage("The file appears to be blank.");
|
|
140
|
-
const r4 = o2.getSheets().add({ name: e5, autoSelect: true }).getRange({ colStart: 0, rowStart: 0, colEnd: 0, rowEnd: 0 });
|
|
141
|
-
await r4.copyFrom(t3);
|
|
142
|
-
}, `Import CSV '${a3}'`);
|
|
143
|
-
} else o2?.close(), i3?.(a3), t2(s2);
|
|
144
|
-
} catch (e5) {
|
|
145
|
-
l3?.showError?.(e5);
|
|
146
|
-
}
|
|
147
|
-
})), e3.push(new X("openWorkbookFromUrl", x3, { label: "Open Workbook From Web", scopedLabels: { insert: "From Web", workbook: "From Web…" }, description: "Open a workbook from the web." }, async function(e4) {
|
|
148
|
-
if (!e4) {
|
|
149
|
-
const o3 = await l3?.showInputOptions?.({ title: "Open Workbook from the Web", description: "Enter the web address for the workbook to open.", inputLabel: "Address", initialValue: "https://www.sheetxl.com/examples/features-checklist.xlsx", inputProps: { style: { minWidth: "440px" } }, options: ["Open"] });
|
|
150
|
-
if ("Open" !== o3.option) return;
|
|
151
|
-
e4 = o3.input;
|
|
152
|
-
}
|
|
153
|
-
e4 && console.log("openWorkbookFromUrl", e4);
|
|
154
|
-
})));
|
|
155
|
-
let r2 = [];
|
|
156
|
-
return m3 && (r2 = [new X("themeMode", x3, { label: "Light/Dark Mode", scopedLabels: { appearance: "Light/Dark Mode" }, description: "Toggle the application styling between light and dark mode." }), new X("defaultThemeMode", x3, { label: "Use System Light/Dark Mode", scopedLabels: { appearance: "Use System Default" }, description: "Use the system settings to determine styling for light and dark mode." }), new X("forceLightGrid", x3, { label: "Force Light Grid", description: "Force the grid to always render in light mode if dark mode is being used. This is ensures that the grid will render the colors as specified in another tools (for example Excel)." }), new X("forceLightImages", x3, { label: "Force Light Images", description: "Force the images to always render in light mode if dark mode is being used. This is ensures that the images will render the colors as specified in another tools (for example Excel). This only has any effect if the grid is in dark mode." })]), [...e3, ...r2, new Q("help", x3, { label: "Show Help", description: "Provide Help.", shortcut: { key: "F1" } }, () => {
|
|
157
|
-
}), new Q("showKeyboardShortcuts", x3, { label: "Keyboard Shortcuts", description: "Show keyboard shortcuts.", shortcut: { key: "/", modifiers: [Z.Ctrl] } }, () => {
|
|
158
|
-
}), new X("gotoUrlGithub", x3, { label: "Github", description: "Download examples, explore source code, and leave a star." }, () => {
|
|
159
|
-
window?.open("https://github.com/sheetxl/sheetxl");
|
|
160
|
-
}), new X("gotoUrlDiscord", x3, { label: "Discord", description: "Join our community on discord." }, () => {
|
|
161
|
-
window?.open("https://discord.gg/NTKdwUgK9p");
|
|
162
|
-
}), new X("gotoUrlDocumentation", x3, { label: "Documentation", description: "Read the documentation." }, () => {
|
|
163
|
-
window?.open("https://www.sheetxl.com/docs");
|
|
164
|
-
}), new X("gotoUrlIssue", x3, { label: "Create Issue", description: "Create an issue to identify a bug or a feature request." }, () => {
|
|
165
|
-
window?.open("https://github.com/sheetxl/sheetxl/issues");
|
|
166
|
-
})];
|
|
167
|
-
}, [o2, a2, l3, n3, m3, h3, u3]), M3 = c(() => {
|
|
168
|
-
let e3 = null;
|
|
169
|
-
return e3 = h3 ? h3.createChildGroup(x3, "standaloneWorkbook", false) : new Y(x3, "standaloneWorkbook"), e3.addCommands(C3, true), e3;
|
|
170
|
-
}, [h3, C3]);
|
|
171
|
-
ee({ manager: u3, commands: M3, notifier: l3 });
|
|
172
|
-
const { themeMode: W2 } = oe();
|
|
173
|
-
p(() => {
|
|
174
|
-
if (!m3 || !M3) return;
|
|
175
|
-
const e3 = "dark" === m3.forceMode || !m3.forceMode && "dark" === W2;
|
|
176
|
-
M3.getCommand("themeMode").update({ state: m3.forceMode ?? null, label: e3 ? "Dark Mode" : "Light Mode", scopedLabels: { appearance: e3 ? "Dark Mode" : "Light Mode" } }).updateCallback(() => {
|
|
177
|
-
g2(e3 ? te.Light : te.Dark);
|
|
178
|
-
}), M3.getCommand("defaultThemeMode").update({ state: !m3.forceMode }).updateCallback(() => {
|
|
179
|
-
g2(null);
|
|
180
|
-
}), M3.getCommand("forceLightGrid").update({ state: m3.forceLightGrid }).updateCallback(() => {
|
|
181
|
-
b3(!m3.forceLightGrid);
|
|
182
|
-
}), M3.getCommand("forceLightImages").update({ state: m3.forceLightImages }).updateCallback(() => {
|
|
183
|
-
w3(!m3.forceLightImages);
|
|
184
|
-
});
|
|
185
|
-
}, [W2, m3, C3]);
|
|
186
|
-
const { showModal: v3 } = re();
|
|
187
|
-
return p(() => {
|
|
188
|
-
const e3 = () => new Promise((e4, o3) => {
|
|
189
|
-
const t3 = r.lazy(() => import("./Cd5wE06_wa41Z6Wt.mjs")), n4 = v3(t3, { title: "Shortcut Keys Reference", commands: M3, onDone: () => {
|
|
190
|
-
n4.hide();
|
|
191
|
-
}, TransitionProps: { onExited: () => {
|
|
192
|
-
e4(true);
|
|
193
|
-
} } });
|
|
194
|
-
});
|
|
195
|
-
M3.getCommand("showKeyboardShortcuts").updateCallback(() => e3()), M3.getCommand("help").updateCallback(() => e3());
|
|
196
|
-
}, [C3, M3]), M3;
|
|
197
|
-
})({ workbook: l2, setWorkbook: m2, importExportDisabled: x2, workbookTitle: h2, setWorkbookTitle: k2, commands: y2, requestWorkbookTitle: (e2) => new Promise((o2) => {
|
|
198
|
-
u2.current ? u2.current.requestWorkbookTitle((e3, t2) => {
|
|
199
|
-
o2(e3);
|
|
200
|
-
}, { selectAll: true, requestReason: e2 }) : o2(b2);
|
|
201
|
-
}), themeModeOptions: C2, undoManager: f2, notifier: N2, onExecute: R2 });
|
|
202
|
-
p(() => {
|
|
203
|
-
S2.starting.size <= 0 || !S2.isMounted || E2((e2) => {
|
|
204
|
-
const o2 = new Map(e2.running);
|
|
205
|
-
e2.starting.forEach((e3, t2) => {
|
|
206
|
-
const r2 = () => {
|
|
207
|
-
E2((e4) => {
|
|
208
|
-
const o3 = new Map(e4.running);
|
|
209
|
-
o3.delete(t2);
|
|
210
|
-
return { ...e4, running: o3 };
|
|
211
|
-
});
|
|
212
|
-
};
|
|
213
|
-
o2.set(t2, r2), e3(r2);
|
|
214
|
-
});
|
|
215
|
-
return { ...e2, starting: /* @__PURE__ */ new Map(), running: o2 };
|
|
216
|
-
});
|
|
217
|
-
}, [S2]);
|
|
218
|
-
const [U2, H2] = a(null);
|
|
219
|
-
p(() => {
|
|
220
|
-
0 !== S2.starting.size || 0 !== S2.running.size ? H2(e(ie, { icon: e(le, { sx: { transform: "scale(0.7)", marginLeft: "-6px" } }), panel: true, label: S2.label, onMount: D2, onUnmount: T2, sx: { position: "absolute", left: "0", top: "0", width: "100%", height: "100%", zIndex: "9999" } })) : H2(null);
|
|
221
|
-
}, [S2.starting, S2.running]);
|
|
222
|
-
const K2 = c(() => e(ce, { commands: _2, disableHover: true, sx: { padding: "0" }, buttonProps: { sx: { maxHeight: "22px" } } }), [_2]), G2 = { notifier: N2, commands: _2 };
|
|
223
|
-
return l2 && (G2.statusBarProps = { childrenEnd: K2 }), o(t, { children: [U2, w2 ? r.cloneElement(w2, G2) : null] });
|
|
224
|
-
}));
|
|
225
|
-
Te.displayName = "SnackbarAndCommandsWrapper";
|
|
226
|
-
const Oe = i(n((t2, r2) => {
|
|
227
|
-
const { className: n2, sx: i2, style: l2, onElementLoad: g2, onError: b2, undoManager: f2, errorPanel: x2 = me, onKeyDown: C2, workbook: M2, createWorkbookOptions: W2, onWorkbookChange: v2, logo: L2, importExportDisabled: D2 = false, themeModeOptions: T2, autoFocus: O2 = false, commands: I2, title: P2, onTitleChange: A2, titleProps: N2, ...R2 } = t2, _2 = d(null), U2 = F(v2, [v2]), H2 = F(A2 ?? N2?.onTitleChange, [A2 ?? N2?.onTitleChange]), K2 = N2?.placeHolder ?? "Untitled", G2 = T2?.forceMode, { themeMode: $2, source: z2 } = oe({ mode: G2 }), q2 = c(() => ({ ...T2, light: ue(false, he.deepMerge(T2?.theme ?? {}, T2?.light ?? {})), dark: ue(true, he.deepMerge(T2?.theme ?? {}, T2?.dark ?? {})) }), [T2]), B2 = $2 === te.Dark, [V2, J2] = a(null);
|
|
228
|
-
p(() => {
|
|
229
|
-
J2(f2 ?? new ke());
|
|
230
|
-
}, [f2]);
|
|
231
|
-
const [X2, Z2] = a(null), [Q2, ee2] = a(null), re2 = ge();
|
|
232
|
-
m(() => {
|
|
233
|
-
if (!M2 || 0 === Object.keys(M2).length && !he.isPromiseLike(M2)) {
|
|
234
|
-
const e2 = { theme: re2.getDefaultTheme(), ...W2 };
|
|
235
|
-
ee2(new be(e2));
|
|
236
|
-
} else ee2(M2);
|
|
237
|
-
}, [M2]), m(() => {
|
|
238
|
-
if (!Q2) return;
|
|
239
|
-
if (Q2 instanceof be) return Z2({ workbook: Q2 }), void (M2 !== Q2 && U2?.(Q2));
|
|
240
|
-
(async () => {
|
|
241
|
-
try {
|
|
242
|
-
let e2, o2 = await Promise.resolve(Q2);
|
|
243
|
-
o2 && o2.source && (o2 = await j.read(o2)), o2.workbook ? (ce2(o2.title), e2 = o2.workbook) : e2 = o2, U2?.(e2), Z2({ workbook: e2 });
|
|
244
|
-
} catch (e2) {
|
|
245
|
-
U2?.(null), Z2({ error: e2 });
|
|
246
|
-
}
|
|
247
|
-
})();
|
|
248
|
-
}, [Q2]);
|
|
249
|
-
const [ne2, ae2] = a(null);
|
|
250
|
-
p(() => {
|
|
251
|
-
if (!V2 || !X2) return;
|
|
252
|
-
V2.clear();
|
|
253
|
-
const e2 = X2?.workbook?.getTransactions();
|
|
254
|
-
if (!e2) return;
|
|
255
|
-
return e2.addListener({ onCommitEnd: (o2) => {
|
|
256
|
-
o2.getDescription() ? V2.addUndoOperation({ description: o2.getDescription(), undo: () => (e2.revert(o2.getId()), ne2.source?.focus(), () => {
|
|
257
|
-
e2.restore(o2.getId()), ne2.source?.focus();
|
|
258
|
-
}) }) : console.warn("commit has no description", o2);
|
|
259
|
-
} });
|
|
260
|
-
}, [V2, X2, ne2]);
|
|
261
|
-
const se2 = F((e2) => {
|
|
262
|
-
e2 ? V2.setRepeatableOperation({ description: e2.label(), repeat: async () => e2.execute() }) : V2.setRepeatableOperation(null);
|
|
263
|
-
}, [V2]), [le2, ce2] = a(P2 ?? N2?.title ?? "");
|
|
264
|
-
p(() => {
|
|
265
|
-
ce2(P2 ?? N2?.title ?? "");
|
|
266
|
-
}, [P2 ?? N2?.title]), p(() => {
|
|
267
|
-
H2?.(le2);
|
|
268
|
-
}, [le2]);
|
|
269
|
-
const [de2, pe2] = a(null), Ce2 = c(() => {
|
|
270
|
-
const e2 = () => ({ contains: (e3) => true, focus() {
|
|
271
|
-
} });
|
|
272
|
-
return I2 ? I2.createChildGroup(e2, "application", false) : new Y(e2, "application");
|
|
273
|
-
}, [I2]), Me2 = F((e2) => {
|
|
274
|
-
pe2(e2.source.getViewportElement()), ae2(e2), Ce2.activate("sheet"), g2?.(e2);
|
|
275
|
-
}, [Ce2]);
|
|
276
|
-
p(() => {
|
|
277
|
-
ne2 && O2 && ne2.source?.focus("object" == typeof O2 ? O2 : void 0);
|
|
278
|
-
}, [ne2]);
|
|
279
|
-
const We2 = d(null), ve2 = s((o2) => {
|
|
280
|
-
let t3 = null;
|
|
281
|
-
return N2?.hidden || (t3 = e(we, { ...N2, style: { maxWidth: "100%", ...N2?.style }, workbook: _2.current, ref: We2, title: le2, placeHolder: K2, onTitleChange: (e2) => {
|
|
282
|
-
ce2(e2);
|
|
283
|
-
} })), e(Fe, { ...o2, logo: L2, mainElement: t3, showFileMenu: !D2, showAppearanceMenu: !!(q2?.onForceLightGridChange || q2?.onForceLightImagesChange || q2?.onForceModeChange) });
|
|
284
|
-
}, [L2, le2, N2, q2, D2, Ce2]);
|
|
285
|
-
p(() => {
|
|
286
|
-
const e2 = (e3) => e3.preventDefault();
|
|
287
|
-
return _2.current?.addEventListener("wheel", e2, { passive: false }), () => {
|
|
288
|
-
_2.current?.removeEventListener("wheel", e2);
|
|
289
|
-
};
|
|
290
|
-
}, []);
|
|
291
|
-
const Le2 = c(() => e(ie, { transparentBackground: true, sx: i2, style: l2 }), [i2, l2]), Ee2 = s(({ error: o2 }) => (b2?.(o2), e(x2, { sx: i2, style: l2, error: o2 ?? "Unable to display empty workbook." })), [i2, l2, b2]), De2 = c(() => ({ ...i2, "& .SnackbarContainer-root": { position: "absolute !important" }, "& .notistack-Snackbar": { minWidth: "unset" }, "& .notistack-MuiContent *": { fontFamily: (e2) => e2.typography.fontFamily }, "& #notistack-snackbar": { maxWidth: "560px", whiteSpace: "pre-wrap" }, "*": { userSelect: "none" } }), [i2]), Oe2 = h([_2, r2]), Ie = c(() => {
|
|
292
|
-
if (!X2) return Le2;
|
|
293
|
-
if (X2.error || !X2.workbook) return Ee2({ error: X2.error });
|
|
294
|
-
let o2 = null, t3 = null, r3 = false;
|
|
295
|
-
return q2 && (o2 = B2 ? q2.dark : q2.light, t3 = B2 && !q2.forceLightGrid ? q2.dark : q2.light, r3 = q2.forceLightImages), e(fe, { sx: De2, style: l2, tabIndex: 0, autoFocus: true, workbook: X2.workbook, ref: Oe2, renderToolbar: ve2, onElementLoad: Me2, onRepeatCommandChange: se2, onKeyDown: (e2) => {
|
|
296
|
-
C2?.(e2);
|
|
297
|
-
}, gridTheme: t3, headersTheme: o2, forceLightImages: r3, className: u(n2, "sheetxl-workbook"), onContextMenu: (e2) => e2.preventDefault(), ...R2 }, "WorkbookElement");
|
|
298
|
-
}, [X2, le2, V2, Le2, q2, R2, ve2, De2]);
|
|
299
|
-
let Pe = e(k, { fallbackRender: Ee2, children: e(w, { maxSnack: 3, domRoot: de2, anchorOrigin: { vertical: "bottom", horizontal: "right" }, autoHideDuration: 3500, onClose: (e2, o2, t3) => {
|
|
300
|
-
_2.current?.focus();
|
|
301
|
-
}, Components: { error: Se }, iconVariant: { success: e(S, { style: { marginRight: "8px" }, children: e("path", { d: "M20,12A8,8 0 0,1 12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4C12.76,4 13.5,4.11 14.2, 4.31L15.77,2.74C14.61,2.26 13.34,2 12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0, 0 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z" }) }), error: e(xe, { style: { marginRight: "8px" } }) }, children: e(ye, { children: e(Te, { workbook: X2?.workbook, setWorkbook: ee2, importExportDisabled: D2, titlePlaceHolder: K2, titleWorkbook: le2, setWorkbookTitle: ce2, refWorkbookTitle: We2, commands: Ce2, undoManager: V2, themeModeOptions: q2, children: Ie }) }) }) });
|
|
302
|
-
return q2 && (Pe = o(y, { theme: B2 ? q2.dark : q2.light, children: [q2.cssBaseline ? e(E, {}) : null, Pe] })), Pe;
|
|
303
|
-
}));
|
|
304
|
-
Oe.displayName = "EagerStandaloneWorkbook";
|
|
305
|
-
export {
|
|
306
|
-
Oe as default
|
|
307
|
-
};
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.3.3
|
|
3
|
-
*
|
|
4
|
-
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
|
-
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
-
*/
|
|
7
|
-
async function i() {
|
|
8
|
-
try {
|
|
9
|
-
return await import("typescript");
|
|
10
|
-
} catch (i2) {
|
|
11
|
-
throw console.error("Error initializing Node TypeScript module:", i2), i2;
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
export {
|
|
15
|
-
i as initialize
|
|
16
|
-
};
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.3.3
|
|
3
|
-
*
|
|
4
|
-
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
|
-
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
-
*/
|
|
7
|
-
const e = { DAVERAGE: { s: "Averages the values in a column in a list or database that match conditions you specify", p: { database: { d: "is the range of cells that makes up the list or database. A database is a list of related data" }, field: { d: "is either the label of the column in double quotation marks or a number that represents the column's position in the list" }, criteria: { d: "is the range of cells that contains the conditions you specify. The range includes a column label and one cell below the label for a condition" } }, h: "Unimplemented" }, DCOUNT: { s: "Counts the cells containing numbers in the field (column) of records in the database that match the conditions you specify", p: { database: { d: "is the range of cells that makes up the list or database. A database is a list of related data" }, field: { d: "is either the label of the column in double quotation marks or a number that represents the column's position in the list" }, criteria: { d: "is the range of cells that contains the conditions you specify. The range includes a column label and one cell below the label for a condition" } }, h: "Unimplemented" }, DCOUNTA: { s: "Counts nonblank cells in the field (column) of records in the database that match the conditions you specify", p: { database: { d: "is the range of cells that makes up the list or database. A database is a list of related data" }, field: { d: "is either the label of the column in double quotation marks or a number that represents the column's position in the list" }, criteria: { d: "is the range of cells that contains the conditions you specify. The range includes a column label and one cell below the label for a condition" } }, h: "Unimplemented" }, DGET: { s: "Extracts from a database a single record that matches the conditions you specify", p: { database: { d: "is the range of cells that makes up the list or database. A database is a list of related data" }, field: { d: "is either the label of the column in double quotation marks or a number that represents the column's position in the list" }, criteria: { d: "is the range of cells that contains the conditions you specify. The range includes a column label and one cell below the label for a condition" } }, h: "Unimplemented" }, DMAX: { s: "Returns the largest number in the field (column) of records in the database that match the conditions you specify", p: { database: { d: "is the range of cells that makes up the list or database. A database is a list of related data" }, field: { d: "is either the label of the column in double quotation marks or a number that represents the column's position in the list" }, criteria: { d: "is the range of cells that contains the conditions you specify. The range includes a column label and one cell below the label for a condition" } }, h: "Unimplemented" }, DMIN: { s: "Returns the smallest number in the field (column) of records in the database that match the conditions you specify", p: { database: { d: "is the range of cells that makes up the list or database. A database is a list of related data" }, field: { d: "is either the label of the column in double quotation marks or a number that represents the column's position in the list" }, criteria: { d: "is the range of cells that contains the conditions you specify. The range includes a column label and one cell below the label for a condition" } }, h: "Unimplemented" }, DPRODUCT: { s: "Multiplies the values in the field (column) of records in the database that match the conditions you specify", p: { database: { d: "is the range of cells that makes up the list or database. A database is a list of related data" }, field: { d: "is either the label of the column in double quotation marks or a number that represents the column's position in the list" }, criteria: { d: "is the range of cells that contains the conditions you specify. The range includes a column label and one cell below the label for a condition" } }, h: "Unimplemented" }, DSTDEV: { s: "Estimates the standard deviation based on a sample from selected database entries", p: { database: { d: "is the range of cells that makes up the list or database. A database is a list of related data" }, field: { d: "is either the label of the column in double quotation marks or a number that represents the column's position in the list" }, criteria: { d: "is the range of cells that contains the conditions you specify. The range includes a column label and one cell below the label for a condition" } }, h: "Unimplemented" }, DSTDEVP: { s: "Calculates the standard deviation based on the entire population of selected database entries", p: { database: { d: "is the range of cells that makes up the list or database. A database is a list of related data" }, field: { d: "is either the label of the column in double quotation marks or a number that represents the column's position in the list" }, criteria: { d: "is the range of cells that contains the conditions you specify. The range includes a column label and one cell below the label for a condition" } }, h: "Unimplemented" }, DSUM: { s: "Adds the numbers in the field (column) of records in the database that match the conditions you specify", p: { database: { d: "is the range of cells that makes up the list or database. A database is a list of related data" }, field: { d: "is either the label of the column in double quotation marks or a number that represents the column's position in the list" }, criteria: { d: "is the range of cells that contains the conditions you specify. The range includes a column label and one cell below the label for a condition" } }, h: "Unimplemented" }, DVAR: { s: "Estimates variance based on a sample from selected database entries", p: { database: { d: "is the range of cells that makes up the list or database. A database is a list of related data" }, field: { d: "is either the label of the column in double quotation marks or a number that represents the column's position in the list" }, criteria: { d: "is the range of cells that contains the conditions you specify. The range includes a column label and one cell below the label for a condition" } }, h: "Unimplemented" }, DVARP: { s: "Calculates variance based on the entire population of selected database entries", p: { database: { d: "is the range of cells that makes up the list or database. A database is a list of related data" }, field: { d: "is either the label of the column in double quotation marks or a number that represents the column's position in the list" }, criteria: { d: "is the range of cells that contains the conditions you specify. The range includes a column label and one cell below the label for a condition" } }, h: "Unimplemented" } };
|
|
8
|
-
export {
|
|
9
|
-
e as default
|
|
10
|
-
};
|