@sheetxl/studio-mui 0.1.98
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/LICENSE.md +11 -0
- package/README.md +24 -0
- package/build/browser/cjs/4XrhSt2xtUIXkiCt.cjs +1516 -0
- package/build/browser/cjs/B3EvhaQf456RMc1Q.cjs +6 -0
- package/build/browser/cjs/B3kl467PN2cpvrfz.cjs +12 -0
- package/build/browser/cjs/B5LCoenQbQmzic16.cjs +314 -0
- package/build/browser/cjs/BBuyHZwFlDRvHzBH.cjs +7 -0
- package/build/browser/cjs/BGoG_ROASNB2owBR.cjs +28 -0
- package/build/browser/cjs/BJ6Da8vZLjAl44pz.cjs +6 -0
- package/build/browser/cjs/BL_UVvG75SFsFaT3.cjs +6 -0
- package/build/browser/cjs/BNDoTytIOGtVh5l9.cjs +6 -0
- package/build/browser/cjs/BQOyVCuOdwDja_VV.cjs +42 -0
- package/build/browser/cjs/BRiPktKUmeJipjaa.cjs +6 -0
- package/build/browser/cjs/BabbNVs5iKg49rfk.cjs +6 -0
- package/build/browser/cjs/BcOX5vODdThWbKrR.cjs +6 -0
- package/build/browser/cjs/BchlMljYmXDs0Ol2.cjs +6 -0
- package/build/browser/cjs/BmYZvm13acvbFhOu.cjs +6 -0
- package/build/browser/cjs/BmbsW1n0-CkF3ITF.cjs +6 -0
- package/build/browser/cjs/BnCUyGP_ERKmL3ZR.cjs +6 -0
- package/build/browser/cjs/BtP4E1_yhMjpfbr5.cjs +6 -0
- package/build/browser/cjs/C3E9wmSfmgYmXfJN.cjs +205 -0
- package/build/browser/cjs/C3Hl78e9qfEHxJYc.cjs +6 -0
- package/build/browser/cjs/CEvRH8aOx3etutK_.cjs +17 -0
- package/build/browser/cjs/CLZSdaBnKDfb142R.cjs +6 -0
- package/build/browser/cjs/CN1cS39WcNrcPVqS.cjs +129 -0
- package/build/browser/cjs/CSH1hUnHovjo8Lb8.cjs +6 -0
- package/build/browser/cjs/CTNt3asYQRA-MROc.cjs +47 -0
- package/build/browser/cjs/C_JZEtvgcli6T7Wg.cjs +11 -0
- package/build/browser/cjs/CbaYZmvS8u-p_Z8Z.cjs +6 -0
- package/build/browser/cjs/Cc-4c3DRm96wq5rj.cjs +12 -0
- package/build/browser/cjs/CnY6DbatGmPyylfU.cjs +20 -0
- package/build/browser/cjs/CqkQGfzNax6GmZFo.cjs +6 -0
- package/build/browser/cjs/D2AF0a4vbNKzFxzA.cjs +21 -0
- package/build/browser/cjs/D4y1iYdx8sdwQ50T.cjs +6 -0
- package/build/browser/cjs/D5cF1EnyvnPY2IxS.cjs +150 -0
- package/build/browser/cjs/DA1-OPTYQTepGKEg.cjs +11 -0
- package/build/browser/cjs/DJDMVDpUqlEKYLjt.cjs +6 -0
- package/build/browser/cjs/DLXLJ8SNNjwM5C-P.cjs +6 -0
- package/build/browser/cjs/DV8lOsZBgyx7MTBW.cjs +6 -0
- package/build/browser/cjs/DZAPn_d9mpvfRzsb.cjs +6 -0
- package/build/browser/cjs/DaicqO_9d1hYzyB_.cjs +11 -0
- package/build/browser/cjs/Dfh6eMCbAjW14fdh.cjs +6 -0
- package/build/browser/cjs/DhI2lgDZL8GqBejN.cjs +6 -0
- package/build/browser/cjs/Ds6s8fpzOZsd2m1r.cjs +6 -0
- package/build/browser/cjs/DvIWGmDT5uBVQ5zH.cjs +16 -0
- package/build/browser/cjs/DvLgu20RiaayrJcW.cjs +7 -0
- package/build/browser/cjs/Dvhwt25gyHzxQLrp.cjs +6 -0
- package/build/browser/cjs/DvwApJM_CVrlpLxn.cjs +6 -0
- package/build/browser/cjs/DwVYzo4a05DMfta_.cjs +28 -0
- package/build/browser/cjs/NYdqUauA5i2q33UZ.cjs +6 -0
- package/build/browser/cjs/S2Xfq-KDgoT7ipPC.cjs +25 -0
- package/build/browser/cjs/TOZQZr9ZZ_Q-jdQZ.cjs +6 -0
- package/build/browser/cjs/bJuLOalXTwrshZL3.cjs +16 -0
- package/build/browser/cjs/eh9refYW4Gm25cmW.cjs +6 -0
- package/build/browser/cjs/hKqcVeb_8_4M79xj.cjs +6 -0
- package/build/browser/cjs/index.cjs +7 -0
- package/build/browser/cjs/is17hbP-kpOIBRP3.cjs +6 -0
- package/build/browser/cjs/pNY789kHWwRQXqse.cjs +17 -0
- package/build/browser/cjs/qJcc3ALtLWml32LU.cjs +18 -0
- package/build/browser/cjs/vWgVoELLfZ2ff1xL.cjs +6 -0
- package/build/browser/esm/2kwF7RVUWBY1zsgG.mjs +16 -0
- package/build/browser/esm/7Imk0owJj7oNHR7v.mjs +48 -0
- package/build/browser/esm/AuNwPf0DXe0twn35.mjs +1592 -0
- package/build/browser/esm/B1Kw9U_AxCk0Aq9f.mjs +59 -0
- package/build/browser/esm/B9l1_Tfw_tMhKCNB.mjs +437 -0
- package/build/browser/esm/B9winT3ff8rc4sbn.mjs +490 -0
- package/build/browser/esm/BEo9XX1sHmVjScSm.mjs +16 -0
- package/build/browser/esm/BGTcOBCyrTTlov_i.mjs +13399 -0
- package/build/browser/esm/BMGddfMXtKQ9AXQS.mjs +16 -0
- package/build/browser/esm/BQSa7N7QMGysdZdU.mjs +3932 -0
- package/build/browser/esm/BVEuc_3fLG2GN34k.mjs +16 -0
- package/build/browser/esm/BVh9YUwiSov8wcyY.mjs +1708 -0
- package/build/browser/esm/BZt5yM_TvoPXqdeA.mjs +3867 -0
- package/build/browser/esm/BfU8KdaB9wrEPWM-.mjs +16 -0
- package/build/browser/esm/BjUaiSvRZnas-HJW.mjs +16 -0
- package/build/browser/esm/BqiVaoAYJJqPrCUZ.mjs +16 -0
- package/build/browser/esm/BtMqJ5CRpKuAC4UQ.mjs +1486 -0
- package/build/browser/esm/BwvMR2cgGwFn8hAL.mjs +36 -0
- package/build/browser/esm/BxU3eVA-Adrnq7ZJ.mjs +1372 -0
- package/build/browser/esm/C00coampLNiXjWJJ.mjs +436 -0
- package/build/browser/esm/C6nh1rvYnAg2w2V2.mjs +838 -0
- package/build/browser/esm/C8gc149K34Zi2lP2.mjs +16 -0
- package/build/browser/esm/CGSkuCZY1EmTUNlQ.mjs +52 -0
- package/build/browser/esm/CKXzosgZX8Xe3l59.mjs +16 -0
- package/build/browser/esm/CNYANG0Z7mhGYo00.mjs +859 -0
- package/build/browser/esm/CV_FNw2i_aEc5nwA.mjs +16 -0
- package/build/browser/esm/CYSj0-zys2FKWgnb.mjs +18 -0
- package/build/browser/esm/CbTs5cvVaP1vPCYD.mjs +2248 -0
- package/build/browser/esm/CfAob8gGydmX1xQu.mjs +16 -0
- package/build/browser/esm/ChGigf2OPu7d44Km.mjs +16 -0
- package/build/browser/esm/CnzGN0S6zOfL_3SS.mjs +1358 -0
- package/build/browser/esm/CpyeUtXgDmrcMESB.mjs +52 -0
- package/build/browser/esm/CrEGjvQKhAcdw5sY.mjs +16 -0
- package/build/browser/esm/CtrrmHx9YbrOithw.mjs +152 -0
- package/build/browser/esm/CzAM0pDdZ7sjGgn9.mjs +86 -0
- package/build/browser/esm/D0oVDcgRUMZ9MHzu.mjs +41 -0
- package/build/browser/esm/D54Fpmnd9MzCzp-Z.mjs +16 -0
- package/build/browser/esm/D78-3ghInxscHLVq.mjs +23 -0
- package/build/browser/esm/DEpR6b4DMs-va6RS.mjs +43734 -0
- package/build/browser/esm/DEsqE49cIQZ8AqCe.mjs +398 -0
- package/build/browser/esm/DGe70xvBhc62ZVZz.mjs +2410 -0
- package/build/browser/esm/DXapJ5_yR4E8vDaK.mjs +1685 -0
- package/build/browser/esm/DjAZeDxBIBZsRTm3.mjs +24 -0
- package/build/browser/esm/DttdPwwDTcRX4uwL.mjs +44 -0
- package/build/browser/esm/FXcO0MVElhw9cc3v.mjs +49 -0
- package/build/browser/esm/GpycqJcrwTRtjEqA.mjs +16 -0
- package/build/browser/esm/HCE-tMxyVd0m-PgN.mjs +16 -0
- package/build/browser/esm/OCdyQRicV8KxUwMt.mjs +16 -0
- package/build/browser/esm/UukTgmLv7or2mhlB.mjs +16 -0
- package/build/browser/esm/_cuE13TWr3oEoKGP.mjs +34 -0
- package/build/browser/esm/aIlK3Ybu-1T4WHPv.mjs +640 -0
- package/build/browser/esm/bFSkTthAEOn7gv5x.mjs +16 -0
- package/build/browser/esm/bOhN6up-rdLRp82s.mjs +5588 -0
- package/build/browser/esm/index.mjs +85 -0
- package/build/browser/esm/ng3JdG4_hi9SgtHk.mjs +16 -0
- package/build/browser/esm/o6U2z4gZ7GE4QKZD.mjs +16 -0
- package/build/browser/esm/psav3cvsBQQczhPL.mjs +16 -0
- package/build/browser/esm/vn0iS301yg2hAbYd.mjs +51 -0
- package/build/licenses/dependencies.txt +1341 -0
- package/build/node/assets/style.css +1 -0
- package/build/node/esm/2kwF7RVUWBY1zsgG.mjs +16 -0
- package/build/node/esm/B-Xlyl81h27-bnvO.mjs +16 -0
- package/build/node/esm/B1_NYsn5D8x9QedP.mjs +307 -0
- package/build/node/esm/BCA5bxOeDA8k1Bm1.mjs +16 -0
- package/build/node/esm/BEo9XX1sHmVjScSm.mjs +16 -0
- package/build/node/esm/BIfdVpnJR1TZwCPR.mjs +1378 -0
- package/build/node/esm/BIqDzNJtkm-dyH0v.mjs +154 -0
- package/build/node/esm/BMGddfMXtKQ9AXQS.mjs +16 -0
- package/build/node/esm/BUOdfqhtCh8lhOhm.mjs +4000 -0
- package/build/node/esm/BYbE15S73xgn7S5E.mjs +88 -0
- package/build/node/esm/BfU8KdaB9wrEPWM-.mjs +16 -0
- package/build/node/esm/BkyivirgeiDKFSjk.mjs +16 -0
- package/build/node/esm/Bm1RqNJ-XvHpJW9z.mjs +831 -0
- package/build/node/esm/BqiVaoAYJJqPrCUZ.mjs +16 -0
- package/build/node/esm/Bx-30HInllXS7M_J.mjs +41 -0
- package/build/node/esm/Bx3lQBEvcqhxffT-.mjs +1726 -0
- package/build/node/esm/BxsKlaBFnb5wNq6R.mjs +53 -0
- package/build/node/esm/C4PMhNAV0KpPsKFj.mjs +24 -0
- package/build/node/esm/C7x3L6HtPhZjSrrZ.mjs +471 -0
- package/build/node/esm/C8gc149K34Zi2lP2.mjs +16 -0
- package/build/node/esm/CK-kn1p9NGRVM_h7.mjs +16 -0
- package/build/node/esm/CKR6snAwSONs7kfL.mjs +19 -0
- package/build/node/esm/CKXzosgZX8Xe3l59.mjs +16 -0
- package/build/node/esm/CLE_RHHvsDeoZ9Zd.mjs +561 -0
- package/build/node/esm/CMKci_5THkcJ-w9a.mjs +80 -0
- package/build/node/esm/CVU9bu6AnxcgkEwq.mjs +13466 -0
- package/build/node/esm/CfAob8gGydmX1xQu.mjs +16 -0
- package/build/node/esm/ChGigf2OPu7d44Km.mjs +16 -0
- package/build/node/esm/CkvkuPSf4R_DqArg.mjs +5648 -0
- package/build/node/esm/CnBMj0oJAyr9ZbjP.mjs +23 -0
- package/build/node/esm/CrEGjvQKhAcdw5sY.mjs +16 -0
- package/build/node/esm/Crx9i_8dm3OQsk_T.mjs +28 -0
- package/build/node/esm/CwUulbiMQH11aF4x.mjs +16 -0
- package/build/node/esm/D0Lh0V1tkdJPxZnI.mjs +392 -0
- package/build/node/esm/D54Fpmnd9MzCzp-Z.mjs +16 -0
- package/build/node/esm/D5bg3v_W8K9MVp0j.mjs +1711 -0
- package/build/node/esm/D8F08tiG98tM_voL.mjs +16 -0
- package/build/node/esm/DR7o1DOIK9zdiBgS.mjs +50 -0
- package/build/node/esm/DYEgm2kd3haV-Ml8.mjs +1246 -0
- package/build/node/esm/DfzhmhZ4I0Zurcqn.mjs +44 -0
- package/build/node/esm/Dg_ERnlsy5hwbzMA.mjs +1498 -0
- package/build/node/esm/Dt4cj_0sWgvt4FGj.mjs +92 -0
- package/build/node/esm/GpycqJcrwTRtjEqA.mjs +16 -0
- package/build/node/esm/LlkIFFfAjLiQ5Or6.mjs +3840 -0
- package/build/node/esm/OCdyQRicV8KxUwMt.mjs +16 -0
- package/build/node/esm/QATDL2FGAYcVnd33.mjs +49 -0
- package/build/node/esm/SvgA2TyqJYOzheuf.mjs +26 -0
- package/build/node/esm/VZ150KIUh5JVRqpk.mjs +52 -0
- package/build/node/esm/XRLHatWlgABiuBDS.mjs +52 -0
- package/build/node/esm/bFSkTthAEOn7gv5x.mjs +16 -0
- package/build/node/esm/index.mjs +44754 -0
- package/build/node/esm/lgtVRbg712G5Ba-x.mjs +60 -0
- package/build/node/esm/ng3JdG4_hi9SgtHk.mjs +16 -0
- package/build/node/esm/psav3cvsBQQczhPL.mjs +16 -0
- package/build/node/esm/zWnN2OzbhzCc6T7u.mjs +86 -0
- package/build/package.json +84 -0
- package/build/types/index.d.ts +1848 -0
- package/package.json +100 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.0.0
|
|
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 n } from "react/jsx-runtime";
|
|
8
|
+
import { memo as t, useState as a, useCallback as o } from "react";
|
|
9
|
+
import { Box as i, FormControlLabel as l, Checkbox as s } from "@mui/material";
|
|
10
|
+
import { P as r, a7 as p, RangeInput as c } from "./index.mjs";
|
|
11
|
+
const d = ["Ok", "Cancel"], m = t((t2) => {
|
|
12
|
+
const { tableOptions: m2, context: g, onOption: u, onValidateOption: f, onDone: h, options: x = d, defaultOption: O = x?.[0], cancelOption: b = "Cancel", sx: C, ...D } = t2, [N, T] = a(false), [j, k] = a(() => m2?.hasHeader ?? false), [v, w] = a(() => m2?.ranges ?? null), y = r((e2) => {
|
|
13
|
+
const n2 = { ...m2, hasHeader: j, ranges: v };
|
|
14
|
+
u?.(e2, e2 === b, e2 === O), h?.({ option: e2, tableOptions: n2 });
|
|
15
|
+
}, [h, u, O, b, j, v, m2]), F = o(async (e2, n2) => null, []);
|
|
16
|
+
return e(p, { title: "Insert Table", options: x, onDone: y, onValidateOption: F, defaultOption: O, cancelOption: b, autoFocusSel: ".range-input input", sx: { width: "360px", ...C }, ...D, children: n(i, { sx: { paddingTop: (e2) => e2.spacing(1), paddingBottom: (e2) => e2.spacing(0), rowGap: (e2) => e2.spacing(1), display: "flex", flexDirection: "column" }, children: [e(c, { formName: "range", value: v, onChangeInput: (e2) => w(e2), resolvedAddress: g.getNames().getRanges.bind(g.getNames()), onFocus: (e2) => {
|
|
17
|
+
N || e2.target?.select(), T(true);
|
|
18
|
+
} }), e(l, { control: e(s, { checked: j, onChange: () => k(!j) }), label: "Table has headers", labelPlacement: "end" })] }) });
|
|
19
|
+
});
|
|
20
|
+
export {
|
|
21
|
+
m as TableNewDialog,
|
|
22
|
+
m as default
|
|
23
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.0.0
|
|
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
|
+
/**
|
|
8
|
+
* @license @sheetxl/sdk - A high-performance, embeddable spreadsheet engine. - v0.0.0
|
|
9
|
+
*
|
|
10
|
+
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
11
|
+
* License: The license can be found at https://www.sheetxl.com/license.
|
|
12
|
+
*/
|
|
13
|
+
const e = { AND: { s: "Checks whether all arguments are TRUE, and returns TRUE if all arguments are TRUE", p: { logical: { d: "logical1,logical2,... are 1 to 255 conditions you want to test that can be either TRUE or FALSE and can be logical values, arrays, or references" } } }, BYCOL: { s: "Applies a LAMBDA function to each column and returns an array of the results.", p: { array: { d: "is an array to be separated by column" }, fn: { d: "is a LAMBDA that is called to scan the array. The LAMBDA takes two parameters, accumulator and value." } }, h: "Unimplemented" }, BYROW: { s: "Applies a LAMBDA function to each row and returns an array of the results.", p: { array: { d: "is an array to be separated by column" }, fn: { d: "is a LAMBDA that is called to scan the array. The LAMBDA takes two parameters, accumulator and value." } }, h: "Unimplemented" }, FALSE: { s: "Returns the logical value FALSE", p: {} }, IF: { s: "Checks whether a condition is met, and returns one value if TRUE, and another value if FALSE", p: { logicalTest: { d: "is any value or expression that can be evaluated to TRUE or FALSE" }, valueIfTrue: { d: "is the value that is returned if Logical_test is TRUE. If omitted, TRUE is returned. You can nest up to seven IF functions" }, valueIfFalse: { d: "is the value that is returned if Logical_test is FALSE. If omitted, FALSE is returned" } } }, IFERROR: { s: "Returns value_if_error if expression is an error and the value of the expression itself otherwise", p: { value: { d: "is any value or expression or reference" }, valueIfError: { d: "is any value or expression or reference" } } }, IFNA: { s: "Returns the value you specify if the expression resolves to #N/A, otherwise returns the result of the expression", p: { value: { d: "is any value or expression or reference" }, valueIfError: { d: "is any value or expression or reference" } } }, IFS: { s: "Checks whether one or more conditions are met and returns a value corresponding to the first TRUE condition", p: { logicalTest: { d: "logical_test1,logical_test2,... is any value or expression that can be evaluated to TRUE or FALSE" }, logicalTrue: { d: "value_if_true1,value_if_true2,... is the value returned if Logical_test is TRUE" }, rest: {} } }, LAMDA: { s: "Creates a function value with can be called within formulas.", p: { parameterOrCalculation: { d: "a parameter or a calculation that returns a value. If a parameter, it must be the last argument." } }, h: "Unimplemented" }, LET: { s: "Assigns calculation results to names. Useful for storing intermediate calculations and values by defining names inside a formula. These names only apply within the scope of the LET function.", p: { name: { d: "name1,name2,... the name, or a calculation which can make use of all names within the LET. Names must start with a letter, cannot be the output of a formula, or conflict with range syntax." }, nameOrValue: { d: "name_value1,name_value2,... the value associated with the name." }, calculationOrName: {}, rest: {} }, h: "Unimplemented" }, MAKEARRAY: { s: "Returns a calculated array of a specified row and column size, by applying a LAMBDA function.", p: { rows: { d: "is the number of rows in the array. Must be greater than zero." }, columns: { d: "is the number of columns in the array. Must be greater than zero." }, fn: { d: "is a LAMBDA that is called to create the array. The LAMBDA takes two parameters, row index and column index." } }, h: "Unimplemented" }, MAP: { s: "Returns an array formed by 'mapping' each value in the array(s) to a new value by applying a lambda to create a new value.", p: { array: { d: "is an array to be mapped" }, lamdaOrArray: { d: "lambda_or_array1,lambda_or_array2,... is a LAMBDA which must be the last argument and must have a parameter for each array passed, or another array to be mapped" } }, h: "Unimplemented" }, NOT: { s: "Changes FALSE to TRUE, or TRUE to FALSE", p: { logical: { d: "is a value or expression that can be evaluated to TRUE or FALSE" } } }, OR: { s: "Checks whether any of the arguments are TRUE, and returns TRUE or FALSE. Returns FALSE only if all arguments are FALSE", p: { logical: { d: "logical1,logical2,... are 1 to 255 conditions that you want to test that can be either TRUE or FALSE" } } }, REDUCE: { s: "Reduces an array to an accumulated value by applying a LAMBDA function to each value and returning the total value in the accumulator.", p: { initialValue: { d: "is the starting value for the accumulator" }, array: { d: "is an array to be reduced" }, fn: { d: "is a LAMBDA that is called to reduce the array. The LAMBDA takes two parameters, accumulator and value." } }, h: "Unimplemented" }, SCAN: { s: "Scans an array by applying a LAMBDA function to each value and returns an array that has each intermediate value", p: { initialValue: { d: "is the starting value for the accumulator" }, array: { d: "is an array to be reduced" }, fn: { d: "is a LAMBDA that is called to reduce the array. The LAMBDA takes two parameters, accumulator and value." } }, h: "Unimplemented" }, SWITCH: { s: "Evaluates an expression against a list of values and returns the result corresponding to the first matching value. If there is no match, an optional default value is returned", p: { expression: {}, value: { d: "is an expression to be evaluated" }, results: { d: "result1,result2,... is a result to be returned if the corresponding value matches expression" } }, h: "Unimplemented" }, TRUE: { s: "Returns the logical value TRUE", p: {} }, XOR: { s: "Returns a logical 'Exclusive Or' of all arguments", p: { logical: { d: "logical1,logical2,... are 1 to 254 conditions you want to test that can be either TRUE or FALSE and can be logical values, arrays, or references" } } } };
|
|
14
|
+
export {
|
|
15
|
+
e as default
|
|
16
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.0.0
|
|
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
|
+
/**
|
|
8
|
+
* @license @sheetxl/sdk - A high-performance, embeddable spreadsheet engine. - v0.0.0
|
|
9
|
+
*
|
|
10
|
+
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
11
|
+
* License: The license can be found at https://www.sheetxl.com/license.
|
|
12
|
+
*/
|
|
13
|
+
/**
|
|
14
|
+
* @license @sheetxl/scripting - SheetXL scripting utilities including TypeScript compilation. - v0.0.0
|
|
15
|
+
*
|
|
16
|
+
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
17
|
+
* License: The license can be found at https://www.sheetxl.com/license.
|
|
18
|
+
*/
|
|
19
|
+
async function i() {
|
|
20
|
+
try {
|
|
21
|
+
return await import("typescript");
|
|
22
|
+
} catch (i2) {
|
|
23
|
+
throw console.error("Error initializing Node TypeScript module:", i2), i2;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
export {
|
|
27
|
+
i as initialize
|
|
28
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.0.0
|
|
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
|
+
/**
|
|
8
|
+
* @license @sheetxl/sdk - A high-performance, embeddable spreadsheet engine. - v0.0.0
|
|
9
|
+
*
|
|
10
|
+
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
11
|
+
* License: The license can be found at https://www.sheetxl.com/license.
|
|
12
|
+
*/
|
|
13
|
+
const t = { ASC: { s: "Converts a string to full-width characters to half-width. Uses the double-byte character set (DBCS).", p: { text: { d: "is a text or a reference to a cell containing text" } }, h: "DBCS" }, ARRAYTOTEXT: { s: "Returns a text representation of an array", p: { array: { d: "the array to represent as text" }, format: { d: "0 for relaxed format, 1 for strict format", v: 0 } } }, CHAR: { s: "Returns the character specified by the code number from the character set for your computer", p: { number: { d: "is a number between 1 and 255 specifying which character you want" } } }, CLEAN: { s: "Removes all nonprintable characters from text", p: { text: { d: "is the text you want to clean" } } }, CODE: { s: "Returns the Unicode value of the first character in a text string", p: { text: { d: "is the text string whose Unicode value you want" } } }, CONCAT: { s: "Concatenates a list or range of text strings", p: { text: { d: "text1,text2,... are 1 to 252 text strings or ranges to be joined" } } }, CONCATENATE: { s: "Joins several text strings into one text string", p: { text: { d: "text1, text2,... are 1 to 252 text strings or ranges to be joined" } }, c: "Compatibility" }, DETECTLANGUAGE: { s: "Detects the language of a given text.", p: { text: { d: "is the text to detect the language of" } }, h: "Unimplemented" }, DBCS: { s: "Changes half-width characters to full-width characters. Uses the double-byte character set (DBCS).", p: { text: { d: "is a text or a reference to a cell containing text" } }, h: "DBCS" }, DOLLAR: { s: "Converts a number to text in currency format", p: { number: { d: "is the number to convert" }, decimals: { d: "is the number of digits to the right of the decimal point", v: 2 } } }, EXACT: { s: "Checks whether two text strings are exactly the same, and returns TRUE or FALSE. EXACT is case-sensitive", p: { text1: { d: "is the first text string" }, text2: { d: "is the second text string" } } }, FIND: { s: "Returns the starting position of one text string within another text string. FIND is case-sensitive", p: { findText: { d: "Returns the starting position of one text string within another text string. FIND is case-sensitive" }, withinText: { d: "is the text you want to search" }, startNum: { d: "specifies the character at which to start the search. The first character in Within_text is character number 1", v: 1 } } }, FINDB: { s: "Finds the starting position of one text string with another text string. FINDB is case-sensitive. Use with double-byte characters.", p: { findText: { d: "is the text you want to find" }, withinText: { d: "is the text you want to search" }, startNum: { d: "is the position in within_text to start searching", v: 1 } }, h: "DBCS" }, FIXED: { s: "Rounds a number to the specified number of decimals and returns the result as text with or without commas", p: { number: { d: "is the number you want to round and convert to text" }, decimals: { d: "is the number of digits to the right of the decimal point", v: 2 }, noCommas: { d: "is a logical value: do not display commas in the returned text = TRUE; do display commas in the returned text = FALSE", v: false } } }, LEFT: { s: "Returns the specified number of characters from the start of a text string", p: { text: { d: "is the text string from which you want to extract characters" }, numChars: { d: "specifies how many characters you want LEFT to extract", v: 1 } } }, LEFTB: { s: "Returns the leftmost num_bytes characters from text. Uses double-byte characters.", p: { text: { d: "is the text string from which you want to extract characters" }, numBytes: { d: "is the number of bytes to extract", v: 1 } }, h: "DBCS" }, LEN: { s: "Returns the number of characters in a text string", p: { text: { d: "is the text whose length you want to find. Spaces count as characters" } } }, LENB: { s: "Returns the number of bytes in a text string. Uses double-byte characters.", p: { text: { d: "is the text string from which you want to extract characters" } } }, LOWER: { s: "Converts all letters in a text string to lowercase", p: { text: { d: "is the text you want to convert to lowercase. Characters in Text that are not letters are not changed" } } }, MID: { s: "Returns the characters from the middle of a text string, given a starting position and length", p: { text: { d: "is the text string from which you want to extract characters" }, startNum: { d: "is the position of the first character you want to extract" }, numChars: { d: "specifies how many characters to return from Text" } } }, MIDB: { s: "Returns characters from the middle of a text string. Uses double-byte characters.", p: { text: { d: "is the text string from which you want to extract characters" }, startNum: { d: "is the position of the first character you want to extract" }, numBytes: { d: "is the number of bytes to extract" } }, h: "DBCS" }, NUMBERVALUE: { s: "Converts text to number in a locale-independent manner", p: { text: { d: "is the text string you want to convert" }, decimalSeparator: { d: "is the character that separates the integer part from the decimal part of the number", v: "." }, groupSeparator: { d: "is the character that separates groups of thousands", v: "," } } }, PERCENTOF: { s: "Returns the percentage of a subset of a given data set", p: { dataSubset: { d: "is the subset" }, dataAll: { d: "is the data set" } }, h: "Unimplemented" }, PHONETIC: { s: "Returns the phonetic spelling of a text string", p: { reference: { d: "Text string or a reference to a single cell or a range of cells that contain a furigana text string" } }, h: "Unimplemented" }, PROPER: { s: "Converts the first letter of each word in a text string to uppercase", p: { text: { d: "is the text string you want to convert" } } }, REGEXEXTRACT: { s: "Extracts substrings of 'text' based on the provided REGEX 'pattern'", p: { text: { d: "is the text string from which you want to extract characters" }, pattern: { d: "The regular expression to be applied" }, returnMode: { d: "Specify which matches to return", v: 0 }, caseSensitivity: { d: "Whether the match is case sensitive", v: false } }, h: "Unimplemented" }, REGEXREPLACE: { s: "Returns 'text', with 'replacement' in place of matches with 'pattern'", p: { text: { d: "is the text string from which you want to extract characters" }, pattern: { d: "The regular expression to be applied" }, replacement: { d: "The replacement string" }, occurrence: { d: "The occurrence of the match to replace", v: 0 }, caseSensitivity: { d: "Whether the match is case sensitive", v: false } }, h: "Unimplemented" }, REGEXTEST: { s: "Checks whether the input matches the pattern, and returns TRUE or FALSE", p: { text: { d: "is the text string to be checked" }, pattern: { d: "is the regular expression to be applied" }, caseSensitivity: { d: "Whether the match is case sensitive", v: false } }, h: "Unimplemented" }, REPLACE: { s: "Replaces part of a text string with a different text string", p: { oldText: { d: "is the text string to be changed" }, startNum: { d: "is the position of the first character you want to replace" }, numChars: { d: "is the number of characters to replace" }, newText: { d: "is the text string that will replace old_text" } } }, REPLACEB: { s: "Replaces part of a text string with a different text string using the number of bytes. Uses the double-byte character set (DBCS).", p: { oldText: { d: "is the text string to be changed" }, startNum: { d: "is the position of the first character you want to replace" }, numBytes: { d: "is the number of bytes to replace" }, newText: { d: "is the text string that will replace old_text" } }, h: "DBCS" }, REPT: { s: "Repeats text a given number of times", p: { text: { d: "is the text you want to repeat" }, numberTimes: { d: "is the number of times you want to repeat text" } } }, RIGHT: { s: "Returns the specified number of characters from the end of a text string", p: { text: { d: "is the text string that contains the characters you want to extract" }, numChars: { d: "specifies how many characters you want to extract", v: 1 } } }, RIGHTB: { s: "Returns the rightmost num_bytes characters from text. Uses double-byte characters.", p: { text: { d: "is the text string from which you want to extract characters" }, numBytes: { d: "is the number of bytes to extract", v: 1 } } }, SEARCH: { s: "Returns the number of the character at which a specific character or text string is first found, reading left to right (not case-sensitive)", p: { findText: { d: "Returns the number of the character at which a specific character or text string is first found, reading left to right (not case-sensitive)" }, withinText: { d: "is the text in which you want to search for Find_text" }, startNum: { d: "is the character number in Within_text, counting from the left, at which you want to start searching", v: 1 } } }, SEARCHB: { s: "Returns the number of the character at which a specific character or text string is first found, reading left to right (not case-sensitive). Uses the double-byte character set (DBCS).", p: { findText: { d: "Returns the number of the character at which a specific character or text string is first found, reading left to right (not case-sensitive)" }, withinText: { d: "is the text in which you want to search for Find_text" }, startBytes: { d: "is the character number in Within_text, counting from the left, at which you want to start searching", v: 1 } }, h: "DBCS" }, SUBSTITUTE: { s: "Replaces existing text with new text in a text string", p: { text: { d: "is the text or the reference to a cell containing text in which you want to substitute characters" }, oldText: { d: "is the existing text you want to replace. If the case of Old_text does not match the case of text, SUBSTITUTE will not replace the text" }, newText: { d: "is the text you want to replace Old_text with" }, instanceNum: { d: "specifies which occurrence of Old_text you want to replace. If omitted, every instance of Old_text is replaced" } } }, T: { s: "Checks whether a value is text, and returns the text if it is, or returns double quotes (empty text) if it is not", p: { value: { d: "is the value to test" } } }, TEXT: { s: "Converts a value to text in a specific number format", p: { value: { d: "is a number, a formula that evaluates to a numeric value, or a reference to a cell containing a numeric value" }, formatText: { d: "is a text string that defines the number format to use" } } }, TEXTAFTER: { s: "Returns text that's after delimiting characters.", p: { text: { d: "The text you want to search for the delimiter." }, delimiter: { d: "The character or string to use as a delimiter." }, instanceNum: { d: "The desired occurrence of delimiter. The default is 1. A negative number searches from the end.", v: 1 }, matchMode: { d: "Searches the text for a delimiter match. By default, a case-sensitive match is done.", v: 0 }, matchEnd: { d: "Whether to match the delimiter against the end of text. By default, they're not matched.", v: 0 }, ifNotFound: { d: "Returned if no match is found. By default, #N/A is returned.", v: "undefined" } } }, TEXTJOIN: { s: "Concatenates a list or range of text strings using a delimiter", p: { delimiter: { d: "Character or string to insert between each text item" }, ignoreEmpty: { d: "if TRUE(default), ignores empty cells" }, text: { d: "text1,text2,... are 1 to 252 text strings or ranges to be joined" } } }, TEXTSPLIT: { s: "Splits text into rows or columns using delimiters.", p: { text: { d: "The text to split" }, colDelimiter: { d: "The column delimiter(s) - can be string or array of strings" }, rowDelimiter: { d: "The row delimiter(s), null/undefined means no row splitting", v: null }, ignoreEmpty: { d: "Whether to ignore empty values (defaults to `false`)", v: false }, matchMode: { d: "Whether to use case-sensitive (0) or case-insensitive (1) match (defaults to `0`)", v: 0 }, padWith: { d: "Value to use for padding if matrix is uneven (defaults to `#N/A`)", v: "undefined" } } }, TEXTBEFORE: { s: "Returns text that's before delimiting characters.", p: { text: { d: "The text you want to search for the delimiter." }, delimiter: { d: "The character or string to use as a delimiter." }, instanceNum: { d: "The desired occurrence of delimiter. The default is 1. A negative number searches from the end.", v: 1 }, matchMode: { d: "Whether to use case-sensitive (0) or case-insensitive (1) match (defaults to `0`)", v: 0 }, matchEnd: { d: "Whether to match the delimiter against the end of text. By default, they're not matched.", v: 0 }, ifNotFound: { d: "Returned if no match is found. By default, #N/A is returned.", v: "undefined" } } }, TRANSLATE: { s: "Translate a text string from one language to another using the Microsoft Translator service.", p: { text: { d: "The text to translate." }, sourceLanguage: { d: "Specifiy the source language your text is currently in. Expressed as a two-letter language code." }, targetLanguage: { d: "Specifiy the source language you want your text to be translated to. Expressed as a two-letter language code." } }, h: "Unimplemented" }, TRIM: { s: "Removes all spaces from text except for single spaces between words.", p: { text: { d: "The text from which you want to remove extra spaces." } } }, UNICHAR: { s: "Returns the Unicode character referenced by the given numeric value", p: { number: { d: "is the Unicode number representing a character" } } }, UNICODE: { s: "Returns the number (code point) corresponding to the first character of the text", p: { text: { d: "is the character that you want the Unicode value of" } } }, UPPER: { s: "Converts a text string to all uppercase letters", p: { text: { d: "is the text you want converted to uppercase, a reference or a text string" } } }, VALUE: { s: "Converts a text string that represents a number to a number", p: { text: { d: "is the text enclosed in quotation marks or a reference to a cell containing the text you want to convert" } } }, VALUETOTEXT: { s: "Returns a text representation of a value", p: { value: { d: "the value to represent as text" }, format: { d: "the format of the text", v: 0 } } } };
|
|
14
|
+
export {
|
|
15
|
+
t as default
|
|
16
|
+
};
|
|
@@ -0,0 +1,392 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.0.0
|
|
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 e, { memo as t, useState as r, useRef as n, useCallback as o, useEffect as i } from "react";
|
|
8
|
+
function c(e3, t2, r2) {
|
|
9
|
+
return t2 in e3 ? Object.defineProperty(e3, t2, { value: r2, enumerable: true, configurable: true, writable: true }) : e3[t2] = r2, e3;
|
|
10
|
+
}
|
|
11
|
+
function u(e3, t2) {
|
|
12
|
+
var r2 = Object.keys(e3);
|
|
13
|
+
if (Object.getOwnPropertySymbols) {
|
|
14
|
+
var n2 = Object.getOwnPropertySymbols(e3);
|
|
15
|
+
t2 && (n2 = n2.filter(function(t3) {
|
|
16
|
+
return Object.getOwnPropertyDescriptor(e3, t3).enumerable;
|
|
17
|
+
})), r2.push.apply(r2, n2);
|
|
18
|
+
}
|
|
19
|
+
return r2;
|
|
20
|
+
}
|
|
21
|
+
function a(e3) {
|
|
22
|
+
for (var t2 = 1; t2 < arguments.length; t2++) {
|
|
23
|
+
var r2 = null != arguments[t2] ? arguments[t2] : {};
|
|
24
|
+
t2 % 2 ? u(Object(r2), true).forEach(function(t3) {
|
|
25
|
+
c(e3, t3, r2[t3]);
|
|
26
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e3, Object.getOwnPropertyDescriptors(r2)) : u(Object(r2)).forEach(function(t3) {
|
|
27
|
+
Object.defineProperty(e3, t3, Object.getOwnPropertyDescriptor(r2, t3));
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
return e3;
|
|
31
|
+
}
|
|
32
|
+
function l(e3, t2) {
|
|
33
|
+
if (null == e3) return {};
|
|
34
|
+
var r2, n2, o2 = function(e4, t3) {
|
|
35
|
+
if (null == e4) return {};
|
|
36
|
+
var r3, n3, o3 = {}, i3 = Object.keys(e4);
|
|
37
|
+
for (n3 = 0; n3 < i3.length; n3++) r3 = i3[n3], t3.indexOf(r3) >= 0 || (o3[r3] = e4[r3]);
|
|
38
|
+
return o3;
|
|
39
|
+
}(e3, t2);
|
|
40
|
+
if (Object.getOwnPropertySymbols) {
|
|
41
|
+
var i2 = Object.getOwnPropertySymbols(e3);
|
|
42
|
+
for (n2 = 0; n2 < i2.length; n2++) r2 = i2[n2], t2.indexOf(r2) >= 0 || Object.prototype.propertyIsEnumerable.call(e3, r2) && (o2[r2] = e3[r2]);
|
|
43
|
+
}
|
|
44
|
+
return o2;
|
|
45
|
+
}
|
|
46
|
+
function s(e3, t2) {
|
|
47
|
+
(null == t2 || t2 > e3.length) && (t2 = e3.length);
|
|
48
|
+
for (var r2 = 0, n2 = new Array(t2); r2 < t2; r2++) n2[r2] = e3[r2];
|
|
49
|
+
return n2;
|
|
50
|
+
}
|
|
51
|
+
function d(e3, t2, r2) {
|
|
52
|
+
return t2 in e3 ? Object.defineProperty(e3, t2, { value: r2, enumerable: true, configurable: true, writable: true }) : e3[t2] = r2, e3;
|
|
53
|
+
}
|
|
54
|
+
function f(e3, t2) {
|
|
55
|
+
var r2 = Object.keys(e3);
|
|
56
|
+
if (Object.getOwnPropertySymbols) {
|
|
57
|
+
var n2 = Object.getOwnPropertySymbols(e3);
|
|
58
|
+
t2 && (n2 = n2.filter(function(t3) {
|
|
59
|
+
return Object.getOwnPropertyDescriptor(e3, t3).enumerable;
|
|
60
|
+
})), r2.push.apply(r2, n2);
|
|
61
|
+
}
|
|
62
|
+
return r2;
|
|
63
|
+
}
|
|
64
|
+
function g(e3) {
|
|
65
|
+
for (var t2 = 1; t2 < arguments.length; t2++) {
|
|
66
|
+
var r2 = null != arguments[t2] ? arguments[t2] : {};
|
|
67
|
+
t2 % 2 ? f(Object(r2), true).forEach(function(t3) {
|
|
68
|
+
d(e3, t3, r2[t3]);
|
|
69
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e3, Object.getOwnPropertyDescriptors(r2)) : f(Object(r2)).forEach(function(t3) {
|
|
70
|
+
Object.defineProperty(e3, t3, Object.getOwnPropertyDescriptor(r2, t3));
|
|
71
|
+
});
|
|
72
|
+
}
|
|
73
|
+
return e3;
|
|
74
|
+
}
|
|
75
|
+
function p(e3) {
|
|
76
|
+
return function t2() {
|
|
77
|
+
for (var r2 = this, n2 = arguments.length, o2 = new Array(n2), i2 = 0; i2 < n2; i2++) o2[i2] = arguments[i2];
|
|
78
|
+
return o2.length >= e3.length ? e3.apply(this, o2) : function() {
|
|
79
|
+
for (var e4 = arguments.length, n3 = new Array(e4), i3 = 0; i3 < e4; i3++) n3[i3] = arguments[i3];
|
|
80
|
+
return t2.apply(r2, [].concat(o2, n3));
|
|
81
|
+
};
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
function h(e3) {
|
|
85
|
+
return {}.toString.call(e3).includes("Object");
|
|
86
|
+
}
|
|
87
|
+
function y(e3) {
|
|
88
|
+
return "function" == typeof e3;
|
|
89
|
+
}
|
|
90
|
+
var v = p(function(e3, t2) {
|
|
91
|
+
throw new Error(e3[t2] || e3.default);
|
|
92
|
+
})({ initialIsRequired: "initial state is required", initialType: "initial state should be an object", initialContent: "initial state shouldn't be an empty object", handlerType: "handler should be an object or a function", handlersType: "all handlers should be a functions", selectorType: "selector should be a function", changeType: "provided value of changes should be an object", changeField: 'it seams you want to change a field in the state which is not specified in the "initial" state', default: "an unknown error accured in `state-local` package" }), m = { changes: function(e3, t2) {
|
|
93
|
+
return h(t2) || v("changeType"), Object.keys(t2).some(function(t3) {
|
|
94
|
+
return r2 = e3, n2 = t3, !Object.prototype.hasOwnProperty.call(r2, n2);
|
|
95
|
+
var r2, n2;
|
|
96
|
+
}) && v("changeField"), t2;
|
|
97
|
+
}, selector: function(e3) {
|
|
98
|
+
y(e3) || v("selectorType");
|
|
99
|
+
}, handler: function(e3) {
|
|
100
|
+
y(e3) || h(e3) || v("handlerType"), h(e3) && Object.values(e3).some(function(e4) {
|
|
101
|
+
return !y(e4);
|
|
102
|
+
}) && v("handlersType");
|
|
103
|
+
}, initial: function(e3) {
|
|
104
|
+
var t2;
|
|
105
|
+
e3 || v("initialIsRequired"), h(e3) || v("initialType"), t2 = e3, Object.keys(t2).length || v("initialContent");
|
|
106
|
+
} };
|
|
107
|
+
function b(e3, t2) {
|
|
108
|
+
return y(t2) ? t2(e3.current) : t2;
|
|
109
|
+
}
|
|
110
|
+
function w(e3, t2) {
|
|
111
|
+
return e3.current = g(g({}, e3.current), t2), t2;
|
|
112
|
+
}
|
|
113
|
+
function O(e3, t2, r2) {
|
|
114
|
+
return y(t2) ? t2(e3.current) : Object.keys(r2).forEach(function(r3) {
|
|
115
|
+
var n2;
|
|
116
|
+
return null === (n2 = t2[r3]) || void 0 === n2 ? void 0 : n2.call(t2, e3.current[r3]);
|
|
117
|
+
}), r2;
|
|
118
|
+
}
|
|
119
|
+
var j = { create: function(e3) {
|
|
120
|
+
var t2 = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {};
|
|
121
|
+
m.initial(e3), m.handler(t2);
|
|
122
|
+
var r2 = { current: e3 }, n2 = p(O)(r2, t2), o2 = p(w)(r2), i2 = p(m.changes)(e3), c2 = p(b)(r2);
|
|
123
|
+
return [function() {
|
|
124
|
+
var e4 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : function(e5) {
|
|
125
|
+
return e5;
|
|
126
|
+
};
|
|
127
|
+
return m.selector(e4), e4(r2.current);
|
|
128
|
+
}, function(e4) {
|
|
129
|
+
!function() {
|
|
130
|
+
for (var e5 = arguments.length, t3 = new Array(e5), r3 = 0; r3 < e5; r3++) t3[r3] = arguments[r3];
|
|
131
|
+
return function(e6) {
|
|
132
|
+
return t3.reduceRight(function(e7, t4) {
|
|
133
|
+
return t4(e7);
|
|
134
|
+
}, e6);
|
|
135
|
+
};
|
|
136
|
+
}(n2, o2, i2, c2)(e4);
|
|
137
|
+
}];
|
|
138
|
+
} };
|
|
139
|
+
var M, P = { configIsRequired: "the configuration object is required", configType: "the configuration object should be an object", default: "an unknown error accured in `@monaco-editor/loader` package", deprecation: "Deprecation warning!\n You are using deprecated way of configuration.\n\n Instead of using\n monaco.config({ urls: { monacoBase: '...' } })\n use\n monaco.config({ paths: { vs: '...' } })\n\n For more please check the link https://github.com/suren-atoyan/monaco-loader#config\n " }, E = (M = function(e3, t2) {
|
|
140
|
+
throw new Error(e3[t2] || e3.default);
|
|
141
|
+
}, function e2() {
|
|
142
|
+
for (var t2 = this, r2 = arguments.length, n2 = new Array(r2), o2 = 0; o2 < r2; o2++) n2[o2] = arguments[o2];
|
|
143
|
+
return n2.length >= M.length ? M.apply(this, n2) : function() {
|
|
144
|
+
for (var r3 = arguments.length, o3 = new Array(r3), i2 = 0; i2 < r3; i2++) o3[i2] = arguments[i2];
|
|
145
|
+
return e2.apply(t2, [].concat(n2, o3));
|
|
146
|
+
};
|
|
147
|
+
})(P), S = { config: function(e3) {
|
|
148
|
+
var t2;
|
|
149
|
+
return e3 || E("configIsRequired"), t2 = e3, {}.toString.call(t2).includes("Object") || E("configType"), e3.urls ? (console.warn(P.deprecation), { paths: { vs: e3.urls.monacoBase } }) : e3;
|
|
150
|
+
} };
|
|
151
|
+
function k(e3, t2) {
|
|
152
|
+
return Object.keys(t2).forEach(function(r2) {
|
|
153
|
+
t2[r2] instanceof Object && e3[r2] && Object.assign(t2[r2], k(e3[r2], t2[r2]));
|
|
154
|
+
}), a(a({}, e3), t2);
|
|
155
|
+
}
|
|
156
|
+
var x = { type: "cancelation", msg: "operation is manually canceled" };
|
|
157
|
+
function I(e3) {
|
|
158
|
+
var t2 = false, r2 = new Promise(function(r3, n2) {
|
|
159
|
+
e3.then(function(e4) {
|
|
160
|
+
return t2 ? n2(x) : r3(e4);
|
|
161
|
+
}), e3.catch(n2);
|
|
162
|
+
});
|
|
163
|
+
return r2.cancel = function() {
|
|
164
|
+
return t2 = true;
|
|
165
|
+
}, r2;
|
|
166
|
+
}
|
|
167
|
+
var T, A, D = j.create({ config: { paths: { vs: "https://cdn.jsdelivr.net/npm/monaco-editor@0.52.2/min/vs" } }, isInitialized: false, resolve: null, reject: null, monaco: null }), V = (A = 2, function(e3) {
|
|
168
|
+
if (Array.isArray(e3)) return e3;
|
|
169
|
+
}(T = D) || function(e3, t2) {
|
|
170
|
+
if ("undefined" != typeof Symbol && Symbol.iterator in Object(e3)) {
|
|
171
|
+
var r2 = [], n2 = true, o2 = false, i2 = void 0;
|
|
172
|
+
try {
|
|
173
|
+
for (var c2, u2 = e3[Symbol.iterator](); !(n2 = (c2 = u2.next()).done) && (r2.push(c2.value), !t2 || r2.length !== t2); n2 = true) ;
|
|
174
|
+
} catch (e4) {
|
|
175
|
+
o2 = true, i2 = e4;
|
|
176
|
+
} finally {
|
|
177
|
+
try {
|
|
178
|
+
n2 || null == u2.return || u2.return();
|
|
179
|
+
} finally {
|
|
180
|
+
if (o2) throw i2;
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
return r2;
|
|
184
|
+
}
|
|
185
|
+
}(T, A) || function(e3, t2) {
|
|
186
|
+
if (e3) {
|
|
187
|
+
if ("string" == typeof e3) return s(e3, t2);
|
|
188
|
+
var r2 = Object.prototype.toString.call(e3).slice(8, -1);
|
|
189
|
+
return "Object" === r2 && e3.constructor && (r2 = e3.constructor.name), "Map" === r2 || "Set" === r2 ? Array.from(e3) : "Arguments" === r2 || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r2) ? s(e3, t2) : void 0;
|
|
190
|
+
}
|
|
191
|
+
}(T, A) || function() {
|
|
192
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
193
|
+
}()), C = V[0], L = V[1];
|
|
194
|
+
function R(e3) {
|
|
195
|
+
return document.body.appendChild(e3);
|
|
196
|
+
}
|
|
197
|
+
function q(e3) {
|
|
198
|
+
var t2, r2, n2 = C(function(e4) {
|
|
199
|
+
return { config: e4.config, reject: e4.reject };
|
|
200
|
+
}), o2 = (t2 = "".concat(n2.config.paths.vs, "/loader.js"), r2 = document.createElement("script"), t2 && (r2.src = t2), r2);
|
|
201
|
+
return o2.onload = function() {
|
|
202
|
+
return e3();
|
|
203
|
+
}, o2.onerror = n2.reject, o2;
|
|
204
|
+
}
|
|
205
|
+
function z() {
|
|
206
|
+
var e3 = C(function(e4) {
|
|
207
|
+
return { config: e4.config, resolve: e4.resolve, reject: e4.reject };
|
|
208
|
+
}), t2 = window.require;
|
|
209
|
+
t2.config(e3.config), t2(["vs/editor/editor.main"], function(t3) {
|
|
210
|
+
_(t3), e3.resolve(t3);
|
|
211
|
+
}, function(t3) {
|
|
212
|
+
e3.reject(t3);
|
|
213
|
+
});
|
|
214
|
+
}
|
|
215
|
+
function _(e3) {
|
|
216
|
+
C().monaco || L({ monaco: e3 });
|
|
217
|
+
}
|
|
218
|
+
var N = new Promise(function(e3, t2) {
|
|
219
|
+
return L({ resolve: e3, reject: t2 });
|
|
220
|
+
}), F = { config: function(e3) {
|
|
221
|
+
var t2 = S.config(e3), r2 = t2.monaco, n2 = l(t2, ["monaco"]);
|
|
222
|
+
L(function(e4) {
|
|
223
|
+
return { config: k(e4.config, n2), monaco: r2 };
|
|
224
|
+
});
|
|
225
|
+
}, init: function() {
|
|
226
|
+
var e3 = C(function(e4) {
|
|
227
|
+
return { monaco: e4.monaco, isInitialized: e4.isInitialized, resolve: e4.resolve };
|
|
228
|
+
});
|
|
229
|
+
if (!e3.isInitialized) {
|
|
230
|
+
if (L({ isInitialized: true }), e3.monaco) return e3.resolve(e3.monaco), I(N);
|
|
231
|
+
if (window.monaco && window.monaco.editor) return _(window.monaco), e3.resolve(window.monaco), I(N);
|
|
232
|
+
!function() {
|
|
233
|
+
for (var e4 = arguments.length, t2 = new Array(e4), r2 = 0; r2 < e4; r2++) t2[r2] = arguments[r2];
|
|
234
|
+
return function(e5) {
|
|
235
|
+
return t2.reduceRight(function(e6, t3) {
|
|
236
|
+
return t3(e6);
|
|
237
|
+
}, e5);
|
|
238
|
+
};
|
|
239
|
+
}(R, q)(z);
|
|
240
|
+
}
|
|
241
|
+
return I(N);
|
|
242
|
+
}, __getMonacoInstance: function() {
|
|
243
|
+
return C(function(e3) {
|
|
244
|
+
return e3.monaco;
|
|
245
|
+
});
|
|
246
|
+
} }, U = { wrapper: { display: "flex", position: "relative", textAlign: "initial" }, fullWidth: { width: "100%" }, hide: { display: "none" } }, B = { container: { display: "flex", height: "100%", width: "100%", justifyContent: "center", alignItems: "center" } };
|
|
247
|
+
var W = function({ children: t2 }) {
|
|
248
|
+
return e.createElement("div", { style: B.container }, t2);
|
|
249
|
+
};
|
|
250
|
+
var Y = t(function({ width: t2, height: r2, isEditorReady: n2, loading: o2, _ref: i2, className: c2, wrapperProps: u2 }) {
|
|
251
|
+
return e.createElement("section", { style: { ...U.wrapper, width: t2, height: r2 }, ...u2 }, !n2 && e.createElement(W, null, o2), e.createElement("div", { ref: i2, style: { ...U.fullWidth, ...!n2 && U.hide }, className: c2 }));
|
|
252
|
+
});
|
|
253
|
+
var $ = function(e3) {
|
|
254
|
+
i(e3, []);
|
|
255
|
+
};
|
|
256
|
+
var G = function(e3, t2, r2 = true) {
|
|
257
|
+
let o2 = n(true);
|
|
258
|
+
i(o2.current || !r2 ? () => {
|
|
259
|
+
o2.current = false;
|
|
260
|
+
} : e3, t2);
|
|
261
|
+
};
|
|
262
|
+
function H() {
|
|
263
|
+
}
|
|
264
|
+
function J(e3, t2, r2, n2) {
|
|
265
|
+
return function(e4, t3) {
|
|
266
|
+
return e4.editor.getModel(K(e4, t3));
|
|
267
|
+
}(e3, n2) || function(e4, t3, r3, n3) {
|
|
268
|
+
return e4.editor.createModel(t3, r3, n3 ? K(e4, n3) : void 0);
|
|
269
|
+
}(e3, t2, r2, n2);
|
|
270
|
+
}
|
|
271
|
+
function K(e3, t2) {
|
|
272
|
+
return e3.Uri.parse(t2);
|
|
273
|
+
}
|
|
274
|
+
var Q = function({ original: t2, modified: c2, language: u2, originalLanguage: a2, modifiedLanguage: l2, originalModelPath: s2, modifiedModelPath: d2, keepCurrentOriginalModel: f2 = false, keepCurrentModifiedModel: g2 = false, theme: p2 = "light", loading: h2 = "Loading...", options: y2 = {}, height: v2 = "100%", width: m2 = "100%", className: b2, wrapperProps: w2 = {}, beforeMount: O2 = H, onMount: j2 = H }) {
|
|
275
|
+
let [M2, P2] = r(false), [E2, S2] = r(true), k2 = n(null), x2 = n(null), I2 = n(null), T2 = n(j2), A2 = n(O2), D2 = n(false);
|
|
276
|
+
$(() => {
|
|
277
|
+
let e3 = F.init();
|
|
278
|
+
return e3.then((e4) => (x2.current = e4) && S2(false)).catch((e4) => "cancelation" !== e4?.type && console.error("Monaco initialization: error:", e4)), () => k2.current ? function() {
|
|
279
|
+
let e4 = k2.current?.getModel();
|
|
280
|
+
f2 || e4?.original?.dispose(), g2 || e4?.modified?.dispose(), k2.current?.dispose();
|
|
281
|
+
}() : e3.cancel();
|
|
282
|
+
}), G(() => {
|
|
283
|
+
if (k2.current && x2.current) {
|
|
284
|
+
let e3 = k2.current.getOriginalEditor(), r2 = J(x2.current, t2 || "", a2 || u2 || "text", s2 || "");
|
|
285
|
+
r2 !== e3.getModel() && e3.setModel(r2);
|
|
286
|
+
}
|
|
287
|
+
}, [s2], M2), G(() => {
|
|
288
|
+
if (k2.current && x2.current) {
|
|
289
|
+
let e3 = k2.current.getModifiedEditor(), t3 = J(x2.current, c2 || "", l2 || u2 || "text", d2 || "");
|
|
290
|
+
t3 !== e3.getModel() && e3.setModel(t3);
|
|
291
|
+
}
|
|
292
|
+
}, [d2], M2), G(() => {
|
|
293
|
+
let e3 = k2.current.getModifiedEditor();
|
|
294
|
+
e3.getOption(x2.current.editor.EditorOption.readOnly) ? e3.setValue(c2 || "") : c2 !== e3.getValue() && (e3.executeEdits("", [{ range: e3.getModel().getFullModelRange(), text: c2 || "", forceMoveMarkers: true }]), e3.pushUndoStop());
|
|
295
|
+
}, [c2], M2), G(() => {
|
|
296
|
+
k2.current?.getModel()?.original.setValue(t2 || "");
|
|
297
|
+
}, [t2], M2), G(() => {
|
|
298
|
+
let { original: e3, modified: t3 } = k2.current.getModel();
|
|
299
|
+
x2.current.editor.setModelLanguage(e3, a2 || u2 || "text"), x2.current.editor.setModelLanguage(t3, l2 || u2 || "text");
|
|
300
|
+
}, [u2, a2, l2], M2), G(() => {
|
|
301
|
+
x2.current?.editor.setTheme(p2);
|
|
302
|
+
}, [p2], M2), G(() => {
|
|
303
|
+
k2.current?.updateOptions(y2);
|
|
304
|
+
}, [y2], M2);
|
|
305
|
+
let V2 = o(() => {
|
|
306
|
+
if (!x2.current) return;
|
|
307
|
+
A2.current(x2.current);
|
|
308
|
+
let e3 = J(x2.current, t2 || "", a2 || u2 || "text", s2 || ""), r2 = J(x2.current, c2 || "", l2 || u2 || "text", d2 || "");
|
|
309
|
+
k2.current?.setModel({ original: e3, modified: r2 });
|
|
310
|
+
}, [u2, c2, l2, t2, a2, s2, d2]), C2 = o(() => {
|
|
311
|
+
!D2.current && I2.current && (k2.current = x2.current.editor.createDiffEditor(I2.current, { automaticLayout: true, ...y2 }), V2(), x2.current?.editor.setTheme(p2), P2(true), D2.current = true);
|
|
312
|
+
}, [y2, p2, V2]);
|
|
313
|
+
return i(() => {
|
|
314
|
+
M2 && T2.current(k2.current, x2.current);
|
|
315
|
+
}, [M2]), i(() => {
|
|
316
|
+
!E2 && !M2 && C2();
|
|
317
|
+
}, [E2, M2, C2]), e.createElement(Y, { width: m2, height: v2, isEditorReady: M2, loading: h2, _ref: I2, className: b2, wrapperProps: w2 });
|
|
318
|
+
}, X = t(Q);
|
|
319
|
+
var Z = function() {
|
|
320
|
+
let [e3, t2] = r(F.__getMonacoInstance());
|
|
321
|
+
return $(() => {
|
|
322
|
+
let r2;
|
|
323
|
+
return e3 || (r2 = F.init(), r2.then((e4) => {
|
|
324
|
+
t2(e4);
|
|
325
|
+
})), () => r2?.cancel();
|
|
326
|
+
}), e3;
|
|
327
|
+
};
|
|
328
|
+
var ee = function(e3) {
|
|
329
|
+
let t2 = n();
|
|
330
|
+
return i(() => {
|
|
331
|
+
t2.current = e3;
|
|
332
|
+
}, [e3]), t2.current;
|
|
333
|
+
}, te = /* @__PURE__ */ new Map();
|
|
334
|
+
var re = function({ defaultValue: t2, defaultLanguage: c2, defaultPath: u2, value: a2, language: l2, path: s2, theme: d2 = "light", line: f2, loading: g2 = "Loading...", options: p2 = {}, overrideServices: h2 = {}, saveViewState: y2 = true, keepCurrentModel: v2 = false, width: m2 = "100%", height: b2 = "100%", className: w2, wrapperProps: O2 = {}, beforeMount: j2 = H, onMount: M2 = H, onChange: P2, onValidate: E2 = H }) {
|
|
335
|
+
let [S2, k2] = r(false), [x2, I2] = r(true), T2 = n(null), A2 = n(null), D2 = n(null), V2 = n(M2), C2 = n(j2), L2 = n(), R2 = n(a2), q2 = ee(s2), z2 = n(false), _2 = n(false);
|
|
336
|
+
$(() => {
|
|
337
|
+
let e3 = F.init();
|
|
338
|
+
return e3.then((e4) => (T2.current = e4) && I2(false)).catch((e4) => "cancelation" !== e4?.type && console.error("Monaco initialization: error:", e4)), () => A2.current ? (L2.current?.dispose(), v2 ? y2 && te.set(s2, A2.current.saveViewState()) : A2.current.getModel()?.dispose(), void A2.current.dispose()) : e3.cancel();
|
|
339
|
+
}), G(() => {
|
|
340
|
+
let e3 = J(T2.current, t2 || a2 || "", c2 || l2 || "", s2 || u2 || "");
|
|
341
|
+
e3 !== A2.current?.getModel() && (y2 && te.set(q2, A2.current?.saveViewState()), A2.current?.setModel(e3), y2 && A2.current?.restoreViewState(te.get(s2)));
|
|
342
|
+
}, [s2], S2), G(() => {
|
|
343
|
+
A2.current?.updateOptions(p2);
|
|
344
|
+
}, [p2], S2), G(() => {
|
|
345
|
+
!A2.current || void 0 === a2 || (A2.current.getOption(T2.current.editor.EditorOption.readOnly) ? A2.current.setValue(a2) : a2 !== A2.current.getValue() && (_2.current = true, A2.current.executeEdits("", [{ range: A2.current.getModel().getFullModelRange(), text: a2, forceMoveMarkers: true }]), A2.current.pushUndoStop(), _2.current = false));
|
|
346
|
+
}, [a2], S2), G(() => {
|
|
347
|
+
let e3 = A2.current?.getModel();
|
|
348
|
+
e3 && l2 && T2.current?.editor.setModelLanguage(e3, l2);
|
|
349
|
+
}, [l2], S2), G(() => {
|
|
350
|
+
void 0 !== f2 && A2.current?.revealLine(f2);
|
|
351
|
+
}, [f2], S2), G(() => {
|
|
352
|
+
T2.current?.editor.setTheme(d2);
|
|
353
|
+
}, [d2], S2);
|
|
354
|
+
let N2 = o(() => {
|
|
355
|
+
if (D2.current && T2.current && !z2.current) {
|
|
356
|
+
C2.current(T2.current);
|
|
357
|
+
let e3 = s2 || u2, r2 = J(T2.current, a2 || t2 || "", c2 || l2 || "", e3 || "");
|
|
358
|
+
A2.current = T2.current?.editor.create(D2.current, { model: r2, automaticLayout: true, ...p2 }, h2), y2 && A2.current.restoreViewState(te.get(e3)), T2.current.editor.setTheme(d2), void 0 !== f2 && A2.current.revealLine(f2), k2(true), z2.current = true;
|
|
359
|
+
}
|
|
360
|
+
}, [t2, c2, u2, a2, l2, s2, p2, h2, y2, d2, f2]);
|
|
361
|
+
return i(() => {
|
|
362
|
+
S2 && V2.current(A2.current, T2.current);
|
|
363
|
+
}, [S2]), i(() => {
|
|
364
|
+
!x2 && !S2 && N2();
|
|
365
|
+
}, [x2, S2, N2]), R2.current = a2, i(() => {
|
|
366
|
+
S2 && P2 && (L2.current?.dispose(), L2.current = A2.current?.onDidChangeModelContent((e3) => {
|
|
367
|
+
_2.current || P2(A2.current.getValue(), e3);
|
|
368
|
+
}));
|
|
369
|
+
}, [S2, P2]), i(() => {
|
|
370
|
+
if (S2) {
|
|
371
|
+
let e3 = T2.current.editor.onDidChangeMarkers((e4) => {
|
|
372
|
+
let t3 = A2.current.getModel()?.uri;
|
|
373
|
+
if (t3 && e4.find((e5) => e5.path === t3.path)) {
|
|
374
|
+
let e5 = T2.current.editor.getModelMarkers({ resource: t3 });
|
|
375
|
+
E2?.(e5);
|
|
376
|
+
}
|
|
377
|
+
});
|
|
378
|
+
return () => {
|
|
379
|
+
e3?.dispose();
|
|
380
|
+
};
|
|
381
|
+
}
|
|
382
|
+
return () => {
|
|
383
|
+
};
|
|
384
|
+
}, [S2, E2]), e.createElement(Y, { width: m2, height: b2, isEditorReady: S2, loading: g2, _ref: D2, className: w2, wrapperProps: O2 });
|
|
385
|
+
}, ne = t(re), oe = ne;
|
|
386
|
+
export {
|
|
387
|
+
X as DiffEditor,
|
|
388
|
+
ne as Editor,
|
|
389
|
+
oe as default,
|
|
390
|
+
F as loader,
|
|
391
|
+
Z as useMonaco
|
|
392
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.0.0
|
|
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
|
+
/**
|
|
8
|
+
* @license @sheetxl/sdk - A high-performance, embeddable spreadsheet engine. - v0.0.0
|
|
9
|
+
*
|
|
10
|
+
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
11
|
+
* License: The license can be found at https://www.sheetxl.com/license.
|
|
12
|
+
*/
|
|
13
|
+
const r = { ERF: { s: "Returns the error function", p: { lowerLimit: { d: "is the lower bound for integrating ERF" }, upperLimit: { d: "is the upper bound for integrating ERF", v: 0 } } }, "ERF.PRECISE": { s: "Returns the error function", p: { x: { d: "is the lower bound for integrating ERF.PRECISE" } } }, ERFC: { s: "Returns the complementary error function", p: { x: { d: "is the lower bound for integrating ERF" } } } };
|
|
14
|
+
export {
|
|
15
|
+
r as default
|
|
16
|
+
};
|