@sheetxl/sdk 0.8.0-beta.10 → 0.8.0-beta.12
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/README.md +1 -1
- package/browser/esm/{CYyv6uGjo10ig5FP.mjs → -Jx-jNHmtIQQfLvK.mjs} +1 -1
- package/browser/esm/{CdLZWVcH8cncBUPJ.mjs → 2WuhYrIpYmOR5H73.mjs} +110 -261
- package/browser/esm/{Cqr3knDsBvoVZ6MN.mjs → 2mIwPy2D2JUX-9wx.mjs} +2 -2
- package/browser/esm/B3wf5vZCsWfWsDbj.mjs +12 -0
- package/browser/esm/{BzLfNyc6OOShIErH.mjs → BIHrHjRGWVlJglcp.mjs} +2 -2
- package/browser/esm/{C9B0djuUarfNdoj0.mjs → BTFBedJMRWGvZyCE.mjs} +1 -1
- package/browser/esm/{Btg43M1Bf-ENDreu.mjs → BdCJNawfifyPupCP.mjs} +1 -1
- package/browser/esm/{ClB5ix51roQOpZEr.mjs → Bg5Di9GLNAkbqQ1P.mjs} +2877 -2067
- package/browser/esm/BnC4-27Igwb8oDf2.mjs +1552 -0
- package/browser/esm/{DhKkrCVASZ6Isvz6.mjs → Bt8_m94tBdks209L.mjs} +1 -1
- package/browser/esm/{zqJOaweiXE9D8RY1.mjs → BudSIfXBAsTxvu-K.mjs} +31835 -40812
- package/browser/esm/C9u8FUewte5ugUjH.mjs +5132 -0
- package/browser/esm/{Di58Ji1n--3Mgc_2.mjs → CBYMTDzMf1Vh7pkw.mjs} +1 -1
- package/browser/esm/CNdjyofiRu6CYOrr.mjs +12835 -0
- package/browser/esm/{Dtoyt8q5RyGAlxCp.mjs → CRkYR-siY2C994KV.mjs} +1 -1
- package/browser/esm/CTe2qfmIUEad6FJv.mjs +199 -0
- package/browser/esm/CUzYuYTTGsChC_kZ.mjs +8422 -0
- package/browser/esm/CdEO8CEee6lEhabA.mjs +117 -0
- package/browser/esm/CfRqiPDg6RBTg1EN.mjs +367 -0
- package/browser/esm/CndRBvVfQUJIYRRj.mjs +193 -0
- package/browser/esm/{Y79I7Sm8kjaYexhf.mjs → CwOPLXU3-9ZHGyOT.mjs} +1 -1
- package/browser/esm/{CjsUGJEQSbGjnH6R.mjs → Cxjxk0ncRKx80I-w.mjs} +1 -1
- package/browser/esm/D2RZh0O9neOsyLAE.mjs +281 -0
- package/browser/esm/{De175LygU7ot4nQm.mjs → D64dM68B1pKYFzdP.mjs} +2 -2
- package/browser/esm/{o8MFgcVXns987D6_.mjs → D9xNz46kAfXMZzp4.mjs} +6 -6
- package/browser/esm/{BcHmrKHwMMOlzc9_.mjs → DK899HhWX1HINMC1.mjs} +55 -55
- package/browser/esm/DPhGQLNGmDZwODwJ.mjs +395 -0
- package/browser/esm/DVroRnhi-5IDXNgM.mjs +210 -0
- package/browser/esm/{Bk7xxbdDpa7-sIwd.mjs → DZiivy0NmO1Vnyzk.mjs} +2 -2
- package/browser/esm/{CZ5oa92wZEAXebgk.mjs → DgrAuRD2qr2DvFeJ.mjs} +78 -68
- package/browser/esm/{D4uVlrG0xEFctsSM.mjs → DobHLF6VjHr7Xi40.mjs} +285 -67
- package/browser/esm/{CSx9ed1JOs7K5BXO.mjs → DwZCT7DZiiXoTweg.mjs} +2 -2
- package/browser/esm/DwwR3O2sEZApPSTF.mjs +86 -0
- package/browser/esm/Tah7cnFb_HNZdLtj.mjs +128 -0
- package/browser/esm/{BEAY9XgKNx-bakXW.mjs → fXWUMDhZ5yMSO629.mjs} +1 -1
- package/browser/esm/{BqskM7wA8oPfFQue.mjs → hCQJcmIzPDxDEv2q.mjs} +2 -2
- package/browser/esm/index.mjs +1294 -1008
- package/browser/esm/{Cgd5BnM3hg9RyUel.mjs → qO-ujUrgq6H3TQix.mjs} +1 -1
- package/browser/esm/w6Jea0TiclPrYZ2M.mjs +1703 -0
- package/browser/esm/yuhcOYw6SHQ-RCm3.mjs +114 -0
- package/licenses/dependencies.txt +75 -75
- package/node/esm/-TA0MneBDKdGhsib.mjs +8668 -0
- package/node/esm/B-HUPAcqvK0eeeCz.mjs +134 -0
- package/node/esm/BL2iiEoqxDEV2Xrg.mjs +8320 -0
- package/node/esm/{C6ZXsNyLXI6zA63X.mjs → BNXLOEddJ6O9gYws.mjs} +9 -9
- package/node/esm/{BH1v-E4Ro3bR7Znw.mjs → BSvOluusoDM4z_dx.mjs} +151 -302
- package/node/esm/{CD9wbvufChVYYkrI.mjs → BskP3b8vUoIOGLY6.mjs} +2 -2
- package/node/esm/{CnSQ7MTXAUAyBOoS.mjs → Btw4148Ot8ifhNc1.mjs} +285 -64
- package/node/esm/{B6D7sSetrcOWLsKj.mjs → C14-R6tifRh7pc0p.mjs} +1 -1
- package/node/esm/C99zzq8DImQXi4BQ.mjs +133 -0
- package/node/esm/{BtuY37FumvLE7EBo.mjs → CBuEu5Jk-LfaDy-H.mjs} +176 -166
- package/node/esm/{DdFgXl-Ux2cMBTs_.mjs → CG-qBU5BAaVz7e-P.mjs} +1 -1
- package/node/esm/CPI58duc0j0a-HpJ.mjs +115 -0
- package/node/esm/CRt3vXe6YmXzqk3H.mjs +406 -0
- package/node/esm/{CUUoseJmFsCf82bb.mjs → C_aL7CGS1lrNn1Ng.mjs} +1 -1
- package/node/esm/{D7MfcID2Wf6l6VpC.mjs → C_xf5Bz30VqiJjXn.mjs} +1 -1
- package/node/esm/CiIymQN6aJCul62g.mjs +610 -0
- package/node/esm/{B9ljpEIZg6wOTzRE.mjs → Ci_zLYmCD7e-C79O.mjs} +1 -1
- package/node/esm/{Bqd62L8KFgdS0Vou.mjs → CkRYLed8Mmn3giNg.mjs} +2 -2
- package/node/esm/D3ptRKzASqBut1DE.mjs +117 -0
- package/node/esm/{DefYISWfdZJFx57m.mjs → D4ROK9UwDpS6jO3Z.mjs} +1 -1
- package/node/esm/D8hO07ToAibIuniw.mjs +13014 -0
- package/node/esm/{Bh4dv6tMjXX3X4nI.mjs → DUTmDHbFbhLDT4F3.mjs} +1 -1
- package/node/esm/{DCplLG93GfTs1vNw.mjs → DV5CU37aEbFbWFL0.mjs} +1 -1
- package/node/esm/{CUQi5ZtMO02nhG0W.mjs → DdoiuKg9BKubtF1V.mjs} +1 -1
- package/node/esm/DggQ23jKMpwhENfa.mjs +372 -0
- package/node/esm/DhS6yWjrrSNIJMsn.mjs +1033 -0
- package/node/esm/{DMD12JUh7HJw2-jl.mjs → DhTya_mhmN53vskv.mjs} +1 -1
- package/node/esm/Dn1M7YWi25DeeYUb.mjs +210 -0
- package/node/esm/DrCf6ITcBhVOFpRj.mjs +86 -0
- package/node/esm/{BN9j8V9gCExMjVtJ.mjs → DxazKtROyaI51dWl.mjs} +1 -1
- package/node/esm/{MiU4rDOiocmJ-9Ry.mjs → Q_S1g46ZOTrdhTae.mjs} +1 -1
- package/node/esm/Vocy-I9dKzZMr0Ct.mjs +59323 -0
- package/node/esm/ZXPFcsT2zrALCZux.mjs +289 -0
- package/node/esm/eimUGjiIP-b8HiM6.mjs +199 -0
- package/node/esm/icn2nX5Z8e_3mNAv.mjs +12 -0
- package/node/esm/index.mjs +2808 -65678
- package/node/esm/lGJ42sHqg5if2bba.mjs +1770 -0
- package/node/esm/{Bsx9uijd4X_SKV3L.mjs → pYtP7wPyS96NQyXS.mjs} +51 -51
- package/package.json +6 -7
- package/resources/contents.json +120 -0
- package/resources/fonts/arial-bold-italic.hinted.json +125 -0
- package/resources/fonts/arial-bold-italic.metrics.json +13 -13
- package/resources/fonts/arial-bold-italic.rows.json +9 -0
- package/resources/fonts/arial-bold.hinted.json +125 -0
- package/resources/fonts/arial-bold.metrics.json +12 -12
- package/resources/fonts/arial-bold.rows.json +9 -0
- package/resources/fonts/arial-italic.hinted.json +125 -0
- package/resources/fonts/arial-italic.metrics.json +13 -13
- package/resources/fonts/arial-italic.rows.json +9 -0
- package/resources/fonts/arial-regular.hinted.json +125 -0
- package/resources/fonts/arial-regular.metrics.json +12 -12
- package/resources/fonts/arial-regular.rows.json +9 -0
- package/resources/fonts/calibri-bold-italic.hinted.json +122 -0
- package/resources/fonts/calibri-bold-italic.metrics.json +2 -2
- package/resources/fonts/calibri-bold-italic.rows.json +9 -0
- package/resources/fonts/calibri-bold.hinted.json +122 -0
- package/resources/fonts/calibri-bold.metrics.json +1 -1
- package/resources/fonts/calibri-bold.rows.json +9 -0
- package/resources/fonts/calibri-italic.hinted.json +121 -0
- package/resources/fonts/calibri-italic.metrics.json +2 -2
- package/resources/fonts/calibri-italic.rows.json +9 -0
- package/resources/fonts/calibri-regular.hinted.json +121 -0
- package/resources/fonts/calibri-regular.metrics.json +1 -1
- package/resources/fonts/calibri-regular.rows.json +9 -0
- package/resources/fonts/cambria-bold-italic.hinted.json +105 -0
- package/resources/fonts/cambria-bold-italic.metrics.json +26 -26
- package/resources/fonts/cambria-bold-italic.rows.json +9 -0
- package/resources/fonts/cambria-bold.hinted.json +108 -0
- package/resources/fonts/cambria-bold.metrics.json +19 -19
- package/resources/fonts/cambria-bold.rows.json +9 -0
- package/resources/fonts/cambria-italic.hinted.json +102 -0
- package/resources/fonts/cambria-italic.metrics.json +23 -23
- package/resources/fonts/cambria-italic.rows.json +9 -0
- package/resources/fonts/cambria-regular.hinted.json +110 -0
- package/resources/fonts/cambria-regular.metrics.json +18 -18
- package/resources/fonts/cambria-regular.rows.json +9 -0
- package/resources/fonts/contents.json +280 -0
- package/resources/fonts/courier-new-bold-italic.hinted.json +11 -0
- package/resources/fonts/courier-new-bold-italic.metrics.json +12 -12
- package/resources/fonts/courier-new-bold-italic.rows.json +9 -0
- package/resources/fonts/courier-new-bold.hinted.json +11 -0
- package/resources/fonts/courier-new-bold.metrics.json +12 -12
- package/resources/fonts/courier-new-bold.rows.json +9 -0
- package/resources/fonts/courier-new-italic.hinted.json +11 -0
- package/resources/fonts/courier-new-italic.metrics.json +12 -12
- package/resources/fonts/courier-new-italic.rows.json +9 -0
- package/resources/fonts/courier-new-regular.hinted.json +11 -0
- package/resources/fonts/courier-new-regular.metrics.json +12 -12
- package/resources/fonts/courier-new-regular.rows.json +9 -0
- package/resources/fonts/times-new-roman-bold-italic.hinted.json +125 -0
- package/resources/fonts/times-new-roman-bold-italic.metrics.json +15 -15
- package/resources/fonts/times-new-roman-bold-italic.rows.json +9 -0
- package/resources/fonts/times-new-roman-bold.hinted.json +125 -0
- package/resources/fonts/times-new-roman-bold.metrics.json +12 -12
- package/resources/fonts/times-new-roman-bold.rows.json +9 -0
- package/resources/fonts/times-new-roman-italic.hinted.json +125 -0
- package/resources/fonts/times-new-roman-italic.metrics.json +16 -16
- package/resources/fonts/times-new-roman-italic.rows.json +9 -0
- package/resources/fonts/times-new-roman-regular.hinted.json +125 -0
- package/resources/fonts/times-new-roman-regular.metrics.json +16 -16
- package/resources/fonts/times-new-roman-regular.rows.json +9 -0
- package/resources/locales/de/model.msg.json +93 -9
- package/resources/locales/en/model.msg.json +95 -10
- package/types/scripting-api.json +10809 -8021
- package/types/scripting-enums.json +201 -44
- package/types/scripting.d.ts +17030 -8666
- package/types/src/.generated/wasm/fonts.d.ts +161 -0
- package/types/src/.generated/wasm/fonts_bg.inline.d.ts +3 -0
- package/types/src/.generated/wasm/sdk.d.ts +122 -0
- package/types/src/.generated/wasm/sdk_bg.inline.d.ts +3 -0
- package/types/src/address/AddressUtils.d.ts +10 -1
- package/types/src/address/_StructuredAddress.d.ts +58 -0
- package/types/src/anomalies/_Anomalies.d.ts +109 -0
- package/types/src/anomalies/_FocusTable.d.ts +11 -0
- package/types/src/anomalies/_FormulaChecks.d.ts +133 -0
- package/types/src/anomalies/_LabelChecks.d.ts +21 -0
- package/types/src/anomalies/_LiteralChecks.d.ts +35 -0
- package/types/src/anomalies/_SeriesChecks.d.ts +13 -0
- package/types/src/border/IBorders.d.ts +16 -0
- package/types/src/calculation/Calculation.d.ts +139 -371
- package/types/src/calculation/ExternalBookBindings.d.ts +2 -3
- package/types/src/calculation/FormulaLiterals.d.ts +2 -1
- package/types/src/calculation/FormulaText.d.ts +18 -2
- package/types/src/calculation/ICalculation.d.ts +133 -18
- package/types/src/calculation/INamedFormulasCollection.d.ts +4 -0
- package/types/src/calculation/NamedFormulaCollection.d.ts +293 -22
- package/types/src/calculation/_CloneBoundary.d.ts +1 -1
- package/types/src/calculation/_FormulaToolkit.d.ts +9 -0
- package/types/src/calculation/_TableExtent.d.ts +60 -0
- package/types/src/calculation/compiler/ASTTypes.d.ts +6 -2
- package/types/src/calculation/compiler/CompilerUtils.d.ts +17 -0
- package/types/src/calculation/compiler/ParserUtils.d.ts +16 -0
- package/types/src/calculation/compiler/Types.d.ts +9 -1
- package/types/src/calculation/engine/CalcBackend.d.ts +953 -0
- package/types/src/calculation/engine/index.d.ts +10 -0
- package/types/src/calculation/executor/CalcExecutor.d.ts +94 -24
- package/types/src/calculation/executor/CalcExecutorUtils.d.ts +23 -1
- package/types/src/calculation/executor/_WhatIf.d.ts +50 -0
- package/types/src/calculation/formula/Formula.d.ts +9 -0
- package/types/src/calculation/formula/FormulaBlock.d.ts +10 -3
- package/types/src/calculation/formula/IFormulaBlock.d.ts +21 -0
- package/types/src/calculation/formula/LambdaValue.d.ts +5 -3
- package/types/src/calculation/functions/FunctionDeclarations.d.ts +5 -1
- package/types/src/calculation/functions/_DataTableFunction.d.ts +14 -0
- package/types/src/calculation/functions/expandDeclaration.d.ts +15 -0
- package/types/src/calculation/functions/initializeFunctions.d.ts +0 -12
- package/types/src/calculation/grid/CalcGrid.d.ts +44 -10
- package/types/src/calculation/grid/CalcGridBackend.d.ts +35 -27
- package/types/src/calculation/grid/CalcGridProxy.d.ts +2 -2
- package/types/src/calculation/grid/CalcGridUtils.d.ts +12 -3
- package/types/src/calculation/grid/FormulaHost.d.ts +51 -6
- package/types/src/calculation/grid/ICalcGrid.d.ts +48 -15
- package/types/src/calculation/grid/_CalcRequest.d.ts +28 -6
- package/types/src/calculation/grid/_CellValueRun.d.ts +21 -0
- package/types/src/calculation/spatial/FormulaSpatialValue.d.ts +29 -2
- package/types/src/calculation/spatial/SpillEntry.d.ts +16 -2
- package/types/src/calculation/state/CalcNode.d.ts +0 -1
- package/types/src/calculation/state/CalcScope.d.ts +44 -6
- package/types/src/calculation/state/CalcState.d.ts +36 -4
- package/types/src/calculation/state/CalculationContext.d.ts +30 -3
- package/types/src/calculation/state/DeferredCalls.d.ts +260 -0
- package/types/src/calculation/state/IContextContainer.d.ts +32 -0
- package/types/src/calculation/state/_PendingOverlayGrid.d.ts +6 -0
- package/types/src/calculation/state/_WhatIfLayer.d.ts +91 -0
- package/types/src/calculation/toolkit/FormulaLiteralReader.d.ts +4 -0
- package/types/src/calculation/toolkit/FormulaTextParser.d.ts +10 -0
- package/types/src/calculation/toolkit/FunctionDeclarationTable.d.ts +4 -0
- package/types/src/calculation/toolkit/index.d.ts +12 -0
- package/types/src/cell/ICell.d.ts +302 -34
- package/types/src/cell/ICellHeader.d.ts +7 -6
- package/types/src/cell/ICellProtection.d.ts +1 -1
- package/types/src/cellControl/CellControl.d.ts +67 -0
- package/types/src/cellControl/CellControlCollection.d.ts +29 -0
- package/types/src/cellControl/CellControlRegistry.d.ts +47 -0
- package/types/src/cellControl/ICellControl.d.ts +99 -0
- package/types/src/cellControl/ICellControlCollection.d.ts +67 -0
- package/types/src/cellControl/index.d.ts +4 -0
- package/types/src/cellRange/ICellHeaderRange.d.ts +6 -9
- package/types/src/cellRange/ICellHeaderRanges.d.ts +5 -0
- package/types/src/cellRange/ICellRange.d.ts +525 -110
- package/types/src/cellRange/ICellRanges.d.ts +12 -6
- package/types/src/chart/Chart.d.ts +217 -15
- package/types/src/chart/ChartCollection.d.ts +7 -2
- package/types/src/chart/IChart.d.ts +1921 -35
- package/types/src/chart/IChartCollection.d.ts +27 -2
- package/types/src/chart/_ChartParts.d.ts +1066 -0
- package/types/src/chart/_ChartSource.d.ts +47 -0
- package/types/src/chart/createChart.d.ts +26 -0
- package/types/src/chart/index.d.ts +4 -0
- package/types/src/chart/kinds/ChartKind.d.ts +252 -0
- package/types/src/chart/kinds/_Area.d.ts +3 -0
- package/types/src/chart/kinds/_Bar.d.ts +4 -0
- package/types/src/chart/kinds/_BoxWhisker.d.ts +4 -0
- package/types/src/chart/kinds/_Bubble.d.ts +3 -0
- package/types/src/chart/kinds/_Funnel.d.ts +4 -0
- package/types/src/chart/kinds/_Hierarchy.d.ts +31 -0
- package/types/src/chart/kinds/_Histogram.d.ts +4 -0
- package/types/src/chart/kinds/_HitKinds.d.ts +23 -0
- package/types/src/chart/kinds/_Line.d.ts +4 -0
- package/types/src/chart/kinds/_OfPie.d.ts +4 -0
- package/types/src/chart/kinds/_Pie.d.ts +4 -0
- package/types/src/chart/kinds/_Placeholder.d.ts +6 -0
- package/types/src/chart/kinds/_Radar.d.ts +4 -0
- package/types/src/chart/kinds/_Scatter.d.ts +8 -0
- package/types/src/chart/kinds/_Sunburst.d.ts +4 -0
- package/types/src/chart/kinds/_Surface.d.ts +4 -0
- package/types/src/chart/kinds/_Treemap.d.ts +4 -0
- package/types/src/chart/kinds/_Waterfall.d.ts +18 -0
- package/types/src/chart/kinds/_builtIns.d.ts +11 -0
- package/types/src/chart/layout/ChartLayout.d.ts +829 -0
- package/types/src/chart/layout/TextMeasurer.d.ts +38 -0
- package/types/src/chart/layout/_HitGeometry.d.ts +50 -0
- package/types/src/chart/layout/_HitTest.d.ts +36 -0
- package/types/src/chart/layout/_Layout.d.ts +25 -0
- package/types/src/chart/layout/_LayoutUtils.d.ts +97 -0
- package/types/src/chart/math/BoxStats.d.ts +35 -0
- package/types/src/chart/math/DateUnitCalcs.d.ts +80 -0
- package/types/src/chart/math/DisplayUnits.d.ts +53 -0
- package/types/src/chart/math/Histogram.d.ts +48 -0
- package/types/src/chart/math/OrdUnitCalcs.d.ts +166 -0
- package/types/src/chart/math/Treemap.d.ts +28 -0
- package/types/src/chart/math/Trendlines.d.ts +71 -0
- package/types/src/chart/math/UnitCalcs.d.ts +98 -0
- package/types/src/chart/model/ChartModel.d.ts +681 -0
- package/types/src/chart/model/_ChartType.d.ts +14 -0
- package/types/src/chart/model/_Edits.d.ts +489 -0
- package/types/src/chart/model/_Grouping.d.ts +83 -0
- package/types/src/chart/model/_Inference.d.ts +52 -0
- package/types/src/chart/model/_ModelFacts.d.ts +112 -0
- package/types/src/chart/model/_NewChart.d.ts +208 -0
- package/types/src/chart/model/_OfPie.d.ts +18 -0
- package/types/src/chart/resolve/_LegacyStyles.d.ts +48 -0
- package/types/src/chart/resolve/_Resolve.d.ts +61 -0
- package/types/src/chart/resolve/_ResolvedChart.d.ts +447 -0
- package/types/src/collections/ISparseGrid.d.ts +11 -2
- package/types/src/collections/MixedTypedArrayList.d.ts +8 -2
- package/types/src/collections/RTree.d.ts +116 -36
- package/types/src/collections/SparseGrid.d.ts +9 -11
- package/types/src/collections/SpatialMap.d.ts +2 -8
- package/types/src/collections/SpatialMap3D.d.ts +2 -0
- package/types/src/collections/index.d.ts +1 -1
- package/types/src/comment/Comment.d.ts +32 -9
- package/types/src/comment/IComment.d.ts +41 -4
- package/types/src/comment/_NoteBox.d.ts +19 -2
- package/types/src/condition/AnchoredConditional.d.ts +30 -4
- package/types/src/condition/ICondition.d.ts +3 -2
- package/types/src/conditionalFormat/ConditionalFormat.d.ts +9 -3
- package/types/src/conditionalFormat/IConditionalFormat.d.ts +4 -3
- package/types/src/dataValidation/DataValidation.d.ts +1 -1
- package/types/src/dataValidation/DataValidationCollection.d.ts +4 -1
- package/types/src/dataValidation/IDataValidation.d.ts +1 -1
- package/types/src/dataValidation/IDataValidationCollection.d.ts +24 -0
- package/types/src/documentProperties/DocumentProperties.d.ts +66 -0
- package/types/src/documentProperties/ICustomProperty.d.ts +69 -0
- package/types/src/documentProperties/IDocumentProperties.d.ts +110 -0
- package/types/src/documentProperties/index.d.ts +3 -0
- package/types/src/externalBook/IExternalBook.d.ts +3 -4
- package/types/src/fetch/Fetcher.d.ts +15 -0
- package/types/src/fetch/IFetcher.d.ts +47 -0
- package/types/src/fetch/_WorkbookFetch.d.ts +43 -0
- package/types/src/fetch/index.d.ts +3 -0
- package/types/src/fill/IFill.d.ts +7 -0
- package/types/src/fill/IFillable.d.ts +47 -0
- package/types/src/fill/IStroke.d.ts +15 -1
- package/types/src/fill/PaintUtils.d.ts +24 -0
- package/types/src/fill/index.d.ts +2 -0
- package/types/src/font/AdvanceBuilder.d.ts +34 -0
- package/types/src/font/AdvanceTable.d.ts +128 -14
- package/types/src/font/CanvasAdvanceBuilder.d.ts +54 -0
- package/types/src/font/FontCapture.d.ts +4 -0
- package/types/src/font/FontCollection.d.ts +53 -2
- package/types/src/font/FontPlatform.d.ts +20 -0
- package/types/src/font/FontUtils.d.ts +5 -0
- package/types/src/font/IFont.d.ts +191 -61
- package/types/src/font/IFontCollection.d.ts +20 -14
- package/types/src/font/IFontStyle.d.ts +207 -0
- package/types/src/font/TableFileAdvanceBuilder.d.ts +9 -0
- package/types/src/font/_FontUtils.d.ts +11 -4
- package/types/src/font/_FontsVersion.d.ts +7 -0
- package/types/src/font/index.d.ts +1 -3
- package/types/src/font/platform.browser.d.ts +15 -0
- package/types/src/font/platform.node.d.ts +5 -0
- package/types/src/group/Group.d.ts +5 -0
- package/types/src/group/GroupMovableCollection.d.ts +4 -0
- package/types/src/history/IHistory.d.ts +19 -2
- package/types/src/hyperlink/IHyperlink.d.ts +17 -1
- package/types/src/hyperlink/_Hyperlink.d.ts +4 -1
- package/types/src/index.d.ts +4 -0
- package/types/src/license/LicenseManager.d.ts +21 -0
- package/types/src/license/_Utils.d.ts +18 -1
- package/types/src/license/runtime.browser.d.ts +5 -0
- package/types/src/license/runtime.node.d.ts +10 -0
- package/types/src/listener/IListener.d.ts +14 -2
- package/types/src/listener/ListenerEmitter.d.ts +11 -3
- package/types/src/movable/IMovable.d.ts +28 -15
- package/types/src/movable/IMovableCollection.d.ts +1 -1
- package/types/src/movable/Movable.d.ts +12 -1
- package/types/src/movable/MovableCollection.d.ts +7 -3
- package/types/src/movable/_InsertableCollection.d.ts +16 -5
- package/types/src/named/INamed.d.ts +30 -0
- package/types/src/named/INamedCollection.d.ts +38 -2
- package/types/src/named/NamedCollection.d.ts +34 -4
- package/types/src/numFmt/NumberFormatParser.d.ts +5 -0
- package/types/src/outline/IOutline.d.ts +1 -1
- package/types/src/outline/Outline.d.ts +2 -2
- package/types/src/picture/IPicture.d.ts +98 -1
- package/types/src/picture/Picture.d.ts +15 -7
- package/types/src/pivot/IPivotTable.d.ts +2 -2
- package/types/src/pivot/PivotTable.d.ts +5 -5
- package/types/src/primitives/AsyncValue.d.ts +58 -0
- package/types/src/primitives/ReferenceRange.d.ts +2 -2
- package/types/src/print/IPageLayout.d.ts +635 -0
- package/types/src/print/PageLayout.d.ts +258 -0
- package/types/src/print/index.d.ts +1 -1
- package/types/src/protectedRange/IProtectedRange.d.ts +2 -2
- package/types/src/protection/IProtection.d.ts +6 -0
- package/types/src/protection/PasswordHasher.d.ts +13 -0
- package/types/src/resource/IResource.d.ts +9 -0
- package/types/src/resource/IResourceCollection.d.ts +4 -0
- package/types/src/resource/Resource.d.ts +2 -0
- package/types/src/resource/_AddResource.d.ts +13 -0
- package/types/src/richData/CellImage.d.ts +95 -0
- package/types/src/richData/Hyperlink.d.ts +49 -0
- package/types/src/richData/IRichDataCollection.d.ts +76 -0
- package/types/src/richData/IRichDataKind.d.ts +66 -0
- package/types/src/richData/RichArray.d.ts +42 -0
- package/types/src/richData/RichDataCollection.d.ts +23 -0
- package/types/src/richData/RichDataRegistry.d.ts +89 -0
- package/types/src/richData/RichDataValues.d.ts +20 -0
- package/types/src/richData/RichRecord.d.ts +68 -0
- package/types/src/richData/RichText.d.ts +59 -0
- package/types/src/richData/index.d.ts +9 -0
- package/types/src/scripting/FunctionArguments.d.ts +17 -1
- package/types/src/scripting/FunctionCollection.d.ts +8 -0
- package/types/src/scripting/IModule.d.ts +3 -3
- package/types/src/scripting/IScript.d.ts +2 -2
- package/types/src/scripting/ITypedFunction.d.ts +1 -1
- package/types/src/scripting/Scripts.d.ts +10 -0
- package/types/src/scripting/TypedFunction.d.ts +2 -0
- package/types/src/scripting/declarations.d.ts +3 -0
- package/types/src/selection/ChartElementSelection.d.ts +39 -0
- package/types/src/selection/IChartElementSelection.d.ts +103 -0
- package/types/src/selection/IItemSelection.d.ts +131 -0
- package/types/src/selection/IMovableSelection.d.ts +6 -34
- package/types/src/selection/IRangeSelection.d.ts +4 -4
- package/types/src/selection/ItemSelection.d.ts +49 -0
- package/types/src/selection/MovableSelection.d.ts +11 -30
- package/types/src/selection/RangeSelection.d.ts +4 -4
- package/types/src/selection/index.d.ts +3 -0
- package/types/src/shape/IShape.d.ts +2 -1
- package/types/src/shape/IShapeStyle.d.ts +5 -31
- package/types/src/shape/ITextBoxStyle.d.ts +85 -0
- package/types/src/shape/ShapeStyleUtils.d.ts +13 -1
- package/types/src/shape/_Connectors.d.ts +9 -9
- package/types/src/shape/_ShapeStyle.d.ts +9 -0
- package/types/src/shape/index.d.ts +1 -0
- package/types/src/sheet/CellRegion.d.ts +37 -3
- package/types/src/sheet/ICellContainerOptions.d.ts +6 -0
- package/types/src/sheet/IOpaqueSheet.d.ts +46 -0
- package/types/src/sheet/ISheet.d.ts +81 -1078
- package/types/src/sheet/IWorksheet.d.ts +1521 -0
- package/types/src/sheet/{ISheetCollection.d.ts → IWorksheetCollection.d.ts} +37 -12
- package/types/src/sheet/NamedCellRange.d.ts +2 -2
- package/types/src/sheet/NamedRange.d.ts +2 -2
- package/types/src/sheet/OpaqueSheet.d.ts +114 -0
- package/types/src/sheet/SheetCell.d.ts +40 -27
- package/types/src/sheet/SheetRange.d.ts +50 -13
- package/types/src/sheet/SheetRanges.d.ts +14 -12
- package/types/src/sheet/{Sheet.d.ts → Worksheet.d.ts} +591 -171
- package/types/src/sheet/WorksheetCollection.d.ts +39 -0
- package/types/src/sheet/_CellBuffer.d.ts +11 -1
- package/types/src/sheet/_CopyUtils.d.ts +13 -6
- package/types/src/sheet/_IgnoredErrors.d.ts +46 -0
- package/types/src/sheet/_InvalidSheetRange.d.ts +3 -2
- package/types/src/sheet/_Kinds.d.ts +34 -0
- package/types/src/sheet/_Labels.d.ts +38 -0
- package/types/src/sheet/_ListenerAnchor.d.ts +7 -1
- package/types/src/sheet/_RangeStateSweep.d.ts +2 -3
- package/types/src/sheet/_ScalarListFactory.d.ts +55 -7
- package/types/src/sheet/_SheetAutoFillUtils.d.ts +3 -3
- package/types/src/sheet/_SheetAutoFitUtils.d.ts +3 -3
- package/types/src/sheet/_SheetChangeEvent.d.ts +72 -0
- package/types/src/sheet/_SheetCoords.d.ts +3 -3
- package/types/src/sheet/_SheetEvents.d.ts +1 -1
- package/types/src/sheet/_SheetFilterUtils.d.ts +6 -6
- package/types/src/sheet/_SheetIntents.d.ts +32 -14
- package/types/src/sheet/_SheetMessages.d.ts +1 -1
- package/types/src/sheet/_SheetMutations.d.ts +11 -9
- package/types/src/sheet/_SheetSortUtils.d.ts +2 -2
- package/types/src/sheet/_SheetStateReader.d.ts +18 -0
- package/types/src/sheet/_SheetStateTypes.d.ts +80 -9
- package/types/src/sheet/_SheetUtils.d.ts +20 -19
- package/types/src/sheet/_WatchAnchor.d.ts +15 -2
- package/types/src/sheet/clipboard/RangeClipboardItems.d.ts +4 -4
- package/types/src/sheet/clipboard/SheetHTMLTableParser.d.ts +3 -3
- package/types/src/sheet/clipboard/SheetHTMLTableWriter.d.ts +3 -3
- package/types/src/sheet/index.d.ts +5 -2
- package/types/src/sheet/style/SheetCellStyle.d.ts +67 -86
- package/types/src/sheet/style/SheetDirectStyle.d.ts +3 -3
- package/types/src/sheet/style/SheetNamedStyle.d.ts +2 -0
- package/types/src/sheet/style/_DigitWidth.d.ts +7 -0
- package/types/src/sheet/style/_Resolvers.d.ts +3 -2
- package/types/src/sheet/style/_StyleUtils.d.ts +7 -43
- package/types/src/sheetHeader/ISheetHeader.d.ts +2 -2
- package/types/src/sheetHeader/SheetCellHeader.d.ts +2 -0
- package/types/src/sheetHeader/SheetCellHeaderRange.d.ts +2 -0
- package/types/src/sheetHeader/SheetCellHeaderRanges.d.ts +2 -0
- package/types/src/sheetHeader/SheetHeader.d.ts +7 -6
- package/types/src/sheetHeader/_HeaderUtils.d.ts +2 -3
- package/types/src/sheetProtection/{ISheetProtection.d.ts → IWorksheetProtection.d.ts} +28 -28
- package/types/src/sheetProtection/WorksheetProtection.d.ts +51 -0
- package/types/src/sheetProtection/index.d.ts +1 -1
- package/types/src/sheetView/{ISheetView.d.ts → IWorksheetView.d.ts} +168 -61
- package/types/src/sheetView/WorksheetView.d.ts +139 -0
- package/types/src/sheetView/_SheetViewUtils.d.ts +5 -3
- package/types/src/sheetView/index.d.ts +1 -1
- package/types/src/slicer/ISlicer.d.ts +2 -2
- package/types/src/sort/ISort.d.ts +35 -5
- package/types/src/style/ICellStyle.d.ts +56 -44
- package/types/src/style/_BuiltInStyleDefs.d.ts +4 -3
- package/types/src/table/AnchoredTable.d.ts +23 -7
- package/types/src/table/AutoTable.d.ts +1 -1
- package/types/src/table/ITable.d.ts +32 -19
- package/types/src/table/_NamedTable.d.ts +3 -3
- package/types/src/table/_NamedTableSource.d.ts +2 -2
- package/types/src/text/IText.d.ts +4 -51
- package/types/src/text/TextEngine.d.ts +34 -0
- package/types/src/text/TextFrame.d.ts +4 -2
- package/types/src/text/TextRun.d.ts +3 -2
- package/types/src/text/TextWrapper.d.ts +32 -26
- package/types/src/text/_TextUtils.d.ts +5 -5
- package/types/src/text/_TextWrapperFallback.d.ts +49 -0
- package/types/src/text/impl/TabStrategy.d.ts +3 -1
- package/types/src/text/richtext/IRichText.d.ts +16 -2
- package/types/src/text/richtext/index.d.ts +0 -1
- package/types/src/theme/ITheme.d.ts +108 -7
- package/types/src/theme/ThemeCollection.d.ts +5 -0
- package/types/src/theme/_OfficeFontScheme.d.ts +8 -0
- package/types/src/transaction/ITransaction.d.ts +20 -1
- package/types/src/transaction/Transaction.d.ts +8 -1
- package/types/src/transaction/_BatchHandle.d.ts +118 -0
- package/types/src/type/AbstractCollection.d.ts +4 -13
- package/types/src/type/ICollection.d.ts +17 -4
- package/types/src/type/IProperties.d.ts +1 -1
- package/types/src/utils/_CSSUtils.d.ts +1 -1
- package/types/src/wasm/_fontsWasm.d.ts +7 -0
- package/types/src/wasm/_sdkWasm.d.ts +1 -1
- package/types/src/wasm/fontsWasm.d.ts +32 -0
- package/types/src/wasm/index.d.ts +1 -0
- package/types/src/wasm/loader.browser.d.ts +9 -0
- package/types/src/wasm/loader.node.d.ts +9 -0
- package/types/src/wasm/sdkWasm.d.ts +6 -3
- package/types/src/workbook/IWorkbook.d.ts +269 -39
- package/types/src/workbook/Workbook.d.ts +102 -25
- package/types/src/workbook/WorkbookRange.d.ts +2 -2
- package/types/src/workbook/WorkbookRanges.d.ts +3 -3
- package/types/src/workbook/_WorkbookIntents.d.ts +2 -2
- package/types/src/workbook/_WorkbookMessages.d.ts +5 -0
- package/types/src/workbookView/IWorkbookView.d.ts +82 -0
- package/types/src/workbookView/WorkbookView.d.ts +21 -0
- package/browser/esm/BbSmt62FpFIpoVzu.mjs +0 -392
- package/browser/esm/BgcZ-CoTbMfmyDJL.mjs +0 -412
- package/browser/esm/DOMHmhYzPcLVcpAW.mjs +0 -7
- package/browser/esm/DUvUK61b2_4pf4tG.mjs +0 -484
- package/node/esm/CCouEwT37f08qO3V.mjs +0 -7
- package/node/esm/CImNvdz1iP-lUlro.mjs +0 -610
- package/node/esm/CT0CN82y0_Qgoryk.mjs +0 -7568
- package/node/esm/DHUADiCmxNQS1ARz.mjs +0 -417
- package/node/esm/Ds0d8zXzmgOu3MGx.mjs +0 -403
- package/types/src/chart/_ChartXml.d.ts +0 -70
- package/types/src/collections/OverlappingRangeIterator.d.ts +0 -87
- package/types/src/collections/_RangeSweep.d.ts +0 -97
- package/types/src/font/CanvasFontMeasurer.d.ts +0 -25
- package/types/src/font/FontKitFontMeasurer.d.ts +0 -11
- package/types/src/font/SimpleFontMeasurer.d.ts +0 -4
- package/types/src/print/IPrint.d.ts +0 -212
- package/types/src/sheet/SheetCollection.d.ts +0 -29
- package/types/src/sheetProtection/SheetProtection.d.ts +0 -51
- package/types/src/sheetView/SheetView.d.ts +0 -122
- package/types/src/text/richtext/IStyledFont.d.ts +0 -330
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
import { IRange, Scalar } from '@sheetxl/primitives';
|
|
2
|
+
import { Direction, RangeAxis, CellCoords, RangeCoords } from '@sheetxl/utils';
|
|
3
|
+
import { Tuple, IGrid, ISparseGrid, IListLike } from '../../collections';
|
|
4
|
+
import { ReferenceErrorIndex } from '../../primitives/ReferenceRange';
|
|
5
|
+
/**
|
|
6
|
+
* A grid's values with a what-if substitution laid over them (DESIGN-DATA-TABLES §4.3): the input
|
|
7
|
+
* cells a `TABLE` puts axis values into, and the results of the cells it re-evaluates under them.
|
|
8
|
+
* A point read and an iteration answer from the map first and the grid underneath otherwise (the
|
|
9
|
+
* pass's pending overlay during a pass), as `PendingOverlayGrid` does; nothing here is ever written
|
|
10
|
+
* through, so the committed values, the formula blocks and the model are untouched and there is
|
|
11
|
+
* nothing to restore. Dropped when the table is done.
|
|
12
|
+
*
|
|
13
|
+
* @remarks
|
|
14
|
+
* Also the error index of the references built over it ({@link ReferenceErrorIndex}): the
|
|
15
|
+
* underlying index plus a scan of the map, taken only while the map holds an error.
|
|
16
|
+
*
|
|
17
|
+
* Every write of the grid interface is refused: a what-if evaluation reads.
|
|
18
|
+
*/
|
|
19
|
+
export declare class WhatIfLayer implements ISparseGrid<Scalar>, ReferenceErrorIndex {
|
|
20
|
+
protected readonly _inner: ISparseGrid<Scalar>;
|
|
21
|
+
protected readonly _committed: ReferenceErrorIndex;
|
|
22
|
+
protected readonly _isColumn: boolean;
|
|
23
|
+
protected _map: Map<number, Scalar>;
|
|
24
|
+
/** Substituted values that are errors — the scan in {@link hasErrorIn} runs only while > 0. */
|
|
25
|
+
protected _errors: number;
|
|
26
|
+
protected _rowStart: number;
|
|
27
|
+
protected _rowEnd: number;
|
|
28
|
+
protected _colStart: number;
|
|
29
|
+
protected _colEnd: number;
|
|
30
|
+
constructor(inner: ISparseGrid<Scalar>, committed: ReferenceErrorIndex);
|
|
31
|
+
get isWhatIfLayer(): true;
|
|
32
|
+
/** The committed grid. */
|
|
33
|
+
getInner(): ISparseGrid<Scalar>;
|
|
34
|
+
/** Substituted cells. */
|
|
35
|
+
get size(): number;
|
|
36
|
+
/** Substitutes `value` at the cell. A blank is kept as a blank (`null`), as an axis cell's is. */
|
|
37
|
+
set(row: number, col: number, value: Scalar): void;
|
|
38
|
+
/** Drops every substitution: the committed grid answers everything again. */
|
|
39
|
+
clear(): void;
|
|
40
|
+
/** Does a rectangle overlap the bounding box of the substituted cells? */
|
|
41
|
+
intersects(rowStart: number, colStart: number, rowEnd: number, colEnd: number): boolean;
|
|
42
|
+
/** {@inheritDoc ReferenceErrorIndex.hasErrorIn} */
|
|
43
|
+
hasErrorIn(coords: IRange.Coords): boolean;
|
|
44
|
+
/** Is the cell inside the substituted box? */
|
|
45
|
+
protected _inBounds(row: number, col: number): boolean;
|
|
46
|
+
/** The run with substituted values swapped in, or the run itself when none fall inside it. */
|
|
47
|
+
protected _substituteRun(major: number, minorFrom: number, run: IListLike<Scalar>): IListLike<Scalar>;
|
|
48
|
+
/** {@inheritDoc IGrid.getValueAt} */
|
|
49
|
+
getValueAt(row: number, column: number): Scalar;
|
|
50
|
+
/**
|
|
51
|
+
* {@inheritDoc ISparseGrid.getRuns}
|
|
52
|
+
*
|
|
53
|
+
* @remarks
|
|
54
|
+
* A substituted cell the committed grid does not hold at all (an input that was never written)
|
|
55
|
+
* is not shown by a run iteration: substitution only describes cells with a run under them, as
|
|
56
|
+
* the pending overlay's does. A point read answers it.
|
|
57
|
+
*/
|
|
58
|
+
getRuns(options?: ISparseGrid.RunIteratorOptions): ISparseGrid.RunIterableIterator<Scalar>;
|
|
59
|
+
/** {@inheritDoc IGrid.entries} */
|
|
60
|
+
entries(options?: IGrid.IteratorOptions): IGrid.EntryIterator<Scalar>;
|
|
61
|
+
/** {@inheritDoc IGrid.values} */
|
|
62
|
+
values(options?: IGrid.IteratorOptions): IGrid.ValueIterator;
|
|
63
|
+
/** {@inheritDoc IGrid.keys} */
|
|
64
|
+
keys(options?: IGrid.IteratorOptions): IGrid.KeyIterator;
|
|
65
|
+
/** {@inheritDoc IGrid.getValues} */
|
|
66
|
+
getValues(coords?: RangeCoords): Tuple.Region<Scalar> | null;
|
|
67
|
+
/** {@inheritDoc IGrid.copyTo} */
|
|
68
|
+
copyTo(destination: IGrid, topLeft: CellCoords, from: RangeCoords): void;
|
|
69
|
+
/** {@inheritDoc IGrid.getAxis} */
|
|
70
|
+
getAxis(): RangeAxis;
|
|
71
|
+
/** {@inheritDoc IGrid.getCount} */
|
|
72
|
+
getCount(): number;
|
|
73
|
+
/** {@inheritDoc IGrid.getCoords} */
|
|
74
|
+
getCoords(): RangeCoords | null;
|
|
75
|
+
/** {@inheritDoc IGrid.getMaxCoords} */
|
|
76
|
+
getMaxCoords(): RangeCoords | null;
|
|
77
|
+
/** {@inheritDoc IGrid.clone} */
|
|
78
|
+
clone(_cloneKey?: any): this;
|
|
79
|
+
/** {@inheritDoc IGrid.cloneEmpty} */
|
|
80
|
+
cloneEmpty(cloneKey?: any): this;
|
|
81
|
+
/** {@inheritDoc IGrid.setValues} */
|
|
82
|
+
setValues(_values: Tuple.GridTuple<Scalar>): this;
|
|
83
|
+
/** {@inheritDoc IGrid.setValueAt} */
|
|
84
|
+
setValueAt(_row: number, _column: number, _value: Scalar): void;
|
|
85
|
+
/** {@inheritDoc IGrid.delete} */
|
|
86
|
+
delete(_coords: RangeCoords | null): boolean;
|
|
87
|
+
/** {@inheritDoc IGrid.shift} */
|
|
88
|
+
shift(_coords: RangeCoords, _direction: Direction): boolean;
|
|
89
|
+
get [Symbol.toStringTag](): string;
|
|
90
|
+
}
|
|
91
|
+
//# sourceMappingURL=_WhatIfLayer.d.ts.map
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { IRange } from '@sheetxl/primitives';
|
|
2
|
+
import { ICalculation } from '../ICalculation';
|
|
3
|
+
import { FormulaText } from '../FormulaText';
|
|
4
|
+
/** {@link FormulaText.parse}, with the toolkit loaded. */
|
|
5
|
+
export declare function parse(text: string, options?: FormulaText.ParseOptions): ICalculation.FormulaNode | null;
|
|
6
|
+
/** {@link FormulaText.transform}, with the toolkit loaded. */
|
|
7
|
+
export declare function transform(root: ICalculation.FormulaNode, transform: ICalculation.FormulaTransform): ICalculation.FormulaNode;
|
|
8
|
+
/** {@link FormulaText.imager}, with the toolkit loaded. */
|
|
9
|
+
export declare function imager(root: ICalculation.FormulaNode, options?: Omit<FormulaText.ImageOptions, 'at'>): (at?: IRange.CellCoords) => string;
|
|
10
|
+
//# sourceMappingURL=FormulaTextParser.d.ts.map
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { FunctionDeclarations } from '../functions/FunctionDeclarations';
|
|
2
|
+
/** A built-in function's declaration, or `null` when no built-in has that name. Not case sensitive. */
|
|
3
|
+
export declare function getFunctionDeclaration(name: string): FunctionDeclarations.Declared | null;
|
|
4
|
+
//# sourceMappingURL=FunctionDeclarationTable.d.ts.map
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The formula toolkit's code: the parser, the printer, the literal reader and the built-in
|
|
3
|
+
* declarations, behind `FormulaText`, `parseFormulaLiteral` and `FunctionDeclarations`.
|
|
4
|
+
*
|
|
5
|
+
* @remarks
|
|
6
|
+
* Loaded by `FormulaText.load()` and by a calculation's start, never carried from import
|
|
7
|
+
* (DESIGN-CALC-SERVICE §13.25). Only `_FormulaToolkit` imports it.
|
|
8
|
+
*/
|
|
9
|
+
export { parse, transform, imager } from './FormulaTextParser';
|
|
10
|
+
export { readFormulaLiteral } from './FormulaLiteralReader';
|
|
11
|
+
export { getFunctionDeclaration } from './FunctionDeclarationTable';
|
|
12
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
import { Scalar, ScalarType, InteropScalarType, InteropScalar, IRange } from '@sheetxl/primitives';
|
|
2
2
|
import { Size, Rectangle, Bounds } from '@sheetxl/utils';
|
|
3
3
|
import { ITypes } from '../type';
|
|
4
|
-
import { ITextFrame, TextRotation, TextStacked } from '../text';
|
|
4
|
+
import { ITextFrame, TextRotation, TextStacked, IRichText } from '../text';
|
|
5
5
|
import { NumberFormat } from '../numFmt';
|
|
6
6
|
import { ITable } from '../table';
|
|
7
7
|
import { IDataValidation } from '../dataValidation';
|
|
8
|
-
import { IConditionalFormat } from '../conditionalFormat
|
|
8
|
+
import { IConditionalFormat } from '../conditionalFormat';
|
|
9
|
+
import { ICellControl } from '../cellControl';
|
|
9
10
|
import { IHyperlink } from '../hyperlink';
|
|
10
11
|
import { IComment } from '../comment';
|
|
11
12
|
import { ICellStyle } from '../style';
|
|
12
13
|
import { ICellRanges, ICellRange } from '../cellRange';
|
|
13
14
|
import { ICalculation } from '../calculation';
|
|
14
|
-
import {
|
|
15
|
+
import { IWorksheet } from '../sheet';
|
|
15
16
|
import { ICellProtection } from './ICellProtection';
|
|
16
17
|
/**
|
|
17
18
|
* A single unit of data and meta data within an `ICellRange`, located at a specific row and column.
|
|
@@ -114,18 +115,62 @@ export interface ICell {
|
|
|
114
115
|
*/
|
|
115
116
|
getDependents(): Promise<ICellRanges | null>;
|
|
116
117
|
/**
|
|
117
|
-
* Returns the
|
|
118
|
+
* Returns whether the cell ignores one of Excel's error checks.
|
|
119
|
+
*
|
|
120
|
+
* @param check The check.
|
|
121
|
+
* @see {@link ICellRange.setErrorIgnored}
|
|
122
|
+
*/
|
|
123
|
+
isErrorIgnored(check: ICell.ErrorCheck): boolean;
|
|
124
|
+
/**
|
|
125
|
+
* Returns the error checks that fire at the cell, each with its evidence.
|
|
126
|
+
*
|
|
127
|
+
* @remarks
|
|
128
|
+
* The payload of the `anomalies` feature at this cell ({@link ICellRange.Feature}): a cell of a
|
|
129
|
+
* `getRegions('anomalies')` region reads its region's findings here. A check the cell ignores
|
|
130
|
+
* ({@link isErrorIgnored}) does not fire. Empty when nothing fires.
|
|
131
|
+
*
|
|
132
|
+
* Derived on first read and cached until the sheet changes; it costs nothing before that.
|
|
133
|
+
*/
|
|
134
|
+
getAnomalies(): readonly ICell.Anomaly[];
|
|
135
|
+
/**
|
|
136
|
+
* Returns the cell's role: its job in the model, from what it reads and who reads it.
|
|
137
|
+
*
|
|
138
|
+
* @remarks
|
|
139
|
+
* The payload of the `role` feature at this cell ({@link ICellRange.Feature.Role}); see
|
|
140
|
+
* {@link ICell.Role} for the six roles. `null` for an empty cell, and for a formula before the
|
|
141
|
+
* calculation engine has loaded its parser.
|
|
142
|
+
*
|
|
143
|
+
* Derived on first read and cached until the sheet changes; it costs nothing before that.
|
|
144
|
+
*/
|
|
145
|
+
getRole(): ICell.Role | null;
|
|
146
|
+
/**
|
|
147
|
+
* Returns the cell's link: the hyperlink set on the cell, else the link its value is.
|
|
118
148
|
*
|
|
119
149
|
* @remarks
|
|
120
|
-
* Returns `null`
|
|
150
|
+
* Returns `null` when the cell has neither.
|
|
151
|
+
*
|
|
152
|
+
* A `HYPERLINK()` result (a {@link Hyperlink} value with an address) is returned as a link with
|
|
153
|
+
* {@link IHyperlink.isReadOnly} `true`; it is not removed or edited as a link, it changes with
|
|
154
|
+
* its formula. A hyperlink set on the cell wins when the cell has both. Excel's
|
|
155
|
+
* `Range.Hyperlinks` and Office Scripts' `Range.getHyperlink()` return nothing for a
|
|
156
|
+
* `HYPERLINK()` cell.
|
|
121
157
|
*/
|
|
122
158
|
getHyperlink(): IHyperlink | null;
|
|
159
|
+
/**
|
|
160
|
+
* The cell's text as formatted runs, or `null` when the text has one font throughout.
|
|
161
|
+
*
|
|
162
|
+
* @remarks
|
|
163
|
+
* Each run's font is the whole font the run shows in: the cell's font with what the run sets
|
|
164
|
+
* over it. The value itself (`getValue()`) is a `RichText`, whose runs record only what they
|
|
165
|
+
* set. Set with {@link ICellRange.setRichText}.
|
|
166
|
+
*/
|
|
167
|
+
getRichText(): IRichText.JSON | null;
|
|
123
168
|
/**
|
|
124
169
|
* Returns the comment on the cell, or `null` if there is none.
|
|
125
170
|
*
|
|
126
171
|
* @remarks
|
|
127
172
|
* One per cell — the thread's root, with its replies, or a note. The sheet's
|
|
128
|
-
* {@link
|
|
173
|
+
* {@link IWorksheet.getComments} is where one is added.
|
|
129
174
|
*/
|
|
130
175
|
getComments(): IComment | null;
|
|
131
176
|
/**
|
|
@@ -178,6 +223,11 @@ export interface ICell {
|
|
|
178
223
|
* Returns the cell's value as a formatted string, applying any number formatting.
|
|
179
224
|
*/
|
|
180
225
|
getText(options?: ICell.GetTextOptions): string;
|
|
226
|
+
/**
|
|
227
|
+
* @deprecated Use {@link getText}.
|
|
228
|
+
* @hidden
|
|
229
|
+
*/
|
|
230
|
+
getFormattedValue(): string;
|
|
181
231
|
/**
|
|
182
232
|
* Returns the cell's value as a string with additional number format details.
|
|
183
233
|
*
|
|
@@ -320,6 +370,14 @@ export interface ICell {
|
|
|
320
370
|
* only lays out text does not need to read this at all.
|
|
321
371
|
*/
|
|
322
372
|
getConditionalDecorations(): Readonly<IConditionalFormat.Decorations>;
|
|
373
|
+
/**
|
|
374
|
+
* Returns the cell's control, such as a checkbox, or `null` when it has none.
|
|
375
|
+
*
|
|
376
|
+
* @remarks
|
|
377
|
+
* A control draws only a value it accepts: ask `getControl()?.isAccepted(getValue())`. A
|
|
378
|
+
* checkbox cell holding `2` has a control and draws `2`.
|
|
379
|
+
*/
|
|
380
|
+
getControl(): ICellControl | null;
|
|
323
381
|
/**
|
|
324
382
|
* If the cell is in a table this will return it.
|
|
325
383
|
*/
|
|
@@ -386,6 +444,11 @@ export interface ICell {
|
|
|
386
444
|
* @param r1c1 If unspecified defaults to the environment's default format.
|
|
387
445
|
*/
|
|
388
446
|
getAddress(r1c1?: boolean): string;
|
|
447
|
+
/**
|
|
448
|
+
* @deprecated Use {@link getAddress}.
|
|
449
|
+
* @hidden
|
|
450
|
+
*/
|
|
451
|
+
getA1(): string;
|
|
389
452
|
/**
|
|
390
453
|
* Selects the current cell.
|
|
391
454
|
* @returns An async boolean indicating the cell was selected.
|
|
@@ -394,7 +457,7 @@ export interface ICell {
|
|
|
394
457
|
/**
|
|
395
458
|
* Returns the Sheet.
|
|
396
459
|
*/
|
|
397
|
-
|
|
460
|
+
getWorksheet(): IWorksheet;
|
|
398
461
|
/**
|
|
399
462
|
* For runtime type checking.
|
|
400
463
|
*/
|
|
@@ -522,7 +585,7 @@ export declare namespace ICell {
|
|
|
522
585
|
comments?: IComment.Update;
|
|
523
586
|
}
|
|
524
587
|
/**
|
|
525
|
-
* Options for {@link ICell.createCell} and {@link
|
|
588
|
+
* Options for {@link ICell.createCell} and {@link IWorksheet.createCell}.
|
|
526
589
|
*/
|
|
527
590
|
interface CreateCellOptions {
|
|
528
591
|
/**
|
|
@@ -669,36 +732,10 @@ export declare namespace ICell {
|
|
|
669
732
|
*/
|
|
670
733
|
anchorBounds: Bounds;
|
|
671
734
|
}
|
|
672
|
-
/**
|
|
673
|
-
* Encodings of ScalarType for persistence
|
|
674
|
-
*/
|
|
675
|
-
type JSONScalarType = 'n' | 's' | 'b' | 'e' | 'r' | 'z';
|
|
676
|
-
/**
|
|
677
|
-
* A value encoded as a number with an associated type.
|
|
678
|
-
*/
|
|
679
|
-
interface JSONTypedValue {
|
|
680
|
-
t: JSONScalarType;
|
|
681
|
-
v: number;
|
|
682
|
-
}
|
|
683
735
|
/**
|
|
684
736
|
* Reexports the `IRange.CellCoords` type for use in cell coordinates.
|
|
685
737
|
*/
|
|
686
738
|
type Coords = IRange.CellCoords;
|
|
687
|
-
/**
|
|
688
|
-
* JSON values types that have their type embedded in the
|
|
689
|
-
* 'format'.
|
|
690
|
-
*
|
|
691
|
-
* @remarks
|
|
692
|
-
* A string value is the string id in the `IStringsCollection`.
|
|
693
|
-
*/
|
|
694
|
-
type JSONUnTypedValue = number | boolean | string;
|
|
695
|
-
/**
|
|
696
|
-
* For persisting a single Cell value and type.
|
|
697
|
-
*
|
|
698
|
-
* @remarks
|
|
699
|
-
* Styling and other advanced properties are stored as ranges.
|
|
700
|
-
*/
|
|
701
|
-
type JSON = JSONUnTypedValue | JSONTypedValue;
|
|
702
739
|
/**
|
|
703
740
|
* Represents the types of content that can be associated with a cell or range.
|
|
704
741
|
*
|
|
@@ -759,5 +796,236 @@ export declare namespace ICell {
|
|
|
759
796
|
readonly DataValidations: "dataValidations";
|
|
760
797
|
};
|
|
761
798
|
type Content = typeof Content[keyof typeof Content];
|
|
799
|
+
/**
|
|
800
|
+
* A cell's job in the model, read from two facts: what the cell reads and who reads it.
|
|
801
|
+
*
|
|
802
|
+
* @remarks
|
|
803
|
+
* A typed cell is a `label` when nothing reads it and an `input` when something does. A formula
|
|
804
|
+
* is a `link` when it is one cell of another sheet (negated or scaled at most, or a reference
|
|
805
|
+
* built with `INDIRECT`), a `reference` when it is one cell of this sheet (negated at most),
|
|
806
|
+
* else `computed` where something reads it and `output` where nothing does. "Who reads it" is
|
|
807
|
+
* the sheet's own formulas, so a cell only another sheet reads is a `label` or an `output`.
|
|
808
|
+
*
|
|
809
|
+
* A finance model's color convention (inputs blue, links green, calculations black) is a
|
|
810
|
+
* statement about this layer, which is what the `styleRole` check reads
|
|
811
|
+
* ({@link ICell.ErrorCheck}).
|
|
812
|
+
*/
|
|
813
|
+
const Role: {
|
|
814
|
+
/** A typed value nothing on the sheet reads. */
|
|
815
|
+
readonly Label: "label";
|
|
816
|
+
/** A typed value a formula reads. */
|
|
817
|
+
readonly Input: "input";
|
|
818
|
+
/** One cell of another sheet. */
|
|
819
|
+
readonly Link: "link";
|
|
820
|
+
/** One cell of this sheet. */
|
|
821
|
+
readonly Reference: "reference";
|
|
822
|
+
/** An expression something reads. */
|
|
823
|
+
readonly Computed: "computed";
|
|
824
|
+
/** An expression nothing on the sheet reads. */
|
|
825
|
+
readonly Output: "output";
|
|
826
|
+
};
|
|
827
|
+
type Role = typeof Role[keyof typeof Role];
|
|
828
|
+
/**
|
|
829
|
+
* One of Excel's background error checks (**Formulas > Error Checking**), by the name the file
|
|
830
|
+
* stores it under, or one of SheetXL's own. A cell can be told to ignore a check
|
|
831
|
+
* ({@link ICellRange.setErrorIgnored}); Excel then draws no error indicator on it for that rule.
|
|
832
|
+
*
|
|
833
|
+
* @remarks
|
|
834
|
+
* The checks SheetXL runs fire through {@link ICell.getAnomalies} and the `anomalies` feature;
|
|
835
|
+
* an ignored check does not fire. Ignores follow their cells through inserts and deletes, are
|
|
836
|
+
* never copied, and leave a cell that is written or cleared, as in Excel.
|
|
837
|
+
*/
|
|
838
|
+
const ErrorCheck: {
|
|
839
|
+
/** A formula that evaluates to an error value. */
|
|
840
|
+
readonly EvaluatesToError: "evalError";
|
|
841
|
+
/** A year written as two digits in text. */
|
|
842
|
+
readonly TextDate: "twoDigitTextYear";
|
|
843
|
+
/** A number stored as text. */
|
|
844
|
+
readonly NumberAsText: "numberStoredAsText";
|
|
845
|
+
/** A formula inconsistent with the formulas around it. */
|
|
846
|
+
readonly InconsistentFormula: "formula";
|
|
847
|
+
/** A formula that omits cells adjacent to the range it refers to. */
|
|
848
|
+
readonly OmittedCells: "formulaRange";
|
|
849
|
+
/** A formula in an unlocked cell. */
|
|
850
|
+
readonly UnlockedFormula: "unlockedFormula";
|
|
851
|
+
/** A formula that refers to empty cells. */
|
|
852
|
+
readonly EmptyCellReference: "emptyCellReference";
|
|
853
|
+
/** A value that fails the cell's list data validation. */
|
|
854
|
+
readonly ListDataValidation: "listDataValidation";
|
|
855
|
+
/** A formula inconsistent with its table's calculated column. */
|
|
856
|
+
readonly InconsistentListFormula: "calculatedColumn";
|
|
857
|
+
/**
|
|
858
|
+
* A typed value in a run of formulas: the cells on both sides of it, along a row or a column,
|
|
859
|
+
* are formulas. SheetXL's own; not written to an xlsx file's ignored errors.
|
|
860
|
+
*/
|
|
861
|
+
readonly HardcodeInRun: "hardcodeInRun";
|
|
862
|
+
/**
|
|
863
|
+
* An authored format (font, fill, number format, alignment) that breaks the run around it:
|
|
864
|
+
* the cells on both sides carry one format, and this cell another. SheetXL's own; not
|
|
865
|
+
* written to an xlsx file's ignored errors.
|
|
866
|
+
*/
|
|
867
|
+
readonly StyleBreak: "styleBreak";
|
|
868
|
+
/**
|
|
869
|
+
* A format part paired with the cell's role: a link to another sheet, a reference on this
|
|
870
|
+
* sheet or a calculation whose font color is other than most of its role on the sheet have,
|
|
871
|
+
* and is one the workbook writes some role in. SheetXL's own; not written to an xlsx file's
|
|
872
|
+
* ignored errors.
|
|
873
|
+
*/
|
|
874
|
+
readonly StyleRole: "styleRole";
|
|
875
|
+
/** A cell or range counted twice in one sum. */
|
|
876
|
+
readonly RepeatedReference: "repeatedReference";
|
|
877
|
+
/** An aggregate over one cell, or over typed numbers only. */
|
|
878
|
+
readonly DegenerateCall: "degenerateCall";
|
|
879
|
+
/** A sum whose range holds a subtotal of its own cells, or a ratio. */
|
|
880
|
+
readonly SumIncludesSubtotal: "sumIncludesSubtotal";
|
|
881
|
+
/**
|
|
882
|
+
* A total, or the first line of a block, that sums its block and also adds a cell outside it:
|
|
883
|
+
* another block's line item, another block's total, or an absolute reference.
|
|
884
|
+
*/
|
|
885
|
+
readonly MisalignedReference: "misalignedReference";
|
|
886
|
+
/** A lookup that matches the nearest key rather than the key. */
|
|
887
|
+
readonly ApproximateMatch: "approximateMatch";
|
|
888
|
+
/** A lookup whose result array and lookup vector do not line up. */
|
|
889
|
+
readonly LookupShape: "lookupShape";
|
|
890
|
+
/** A reference to another workbook, a deleted reference, or a function a converter could not name. */
|
|
891
|
+
readonly ExternalReference: "externalReference";
|
|
892
|
+
/** A formula that is only an error value, such as `=#DIV/0!`: what a converter leaves when it drops a formula. */
|
|
893
|
+
readonly ErrorConstant: "errorConstant";
|
|
894
|
+
/** A link to another sheet whose target row is labeled other than its own row. */
|
|
895
|
+
readonly LinkLabelMismatch: "linkLabelMismatch";
|
|
896
|
+
/** A lookup keyed by a typed string that labels neither the formula's row nor its column. */
|
|
897
|
+
readonly KeyLabelMismatch: "keyLabelMismatch";
|
|
898
|
+
/** A link read with the other sign from the sheet's other links into the same row. */
|
|
899
|
+
readonly SignVsSiblings: "signVsSiblings";
|
|
900
|
+
/** A number typed into a formula that equals a typed number on the sheet no formula reads. */
|
|
901
|
+
readonly LiteralMatchesInput: "literalMatchesInput";
|
|
902
|
+
/** A formula that differs from its twins on the sheet, the formulas of the same shape, in a typed number. */
|
|
903
|
+
readonly TwinBlockDivergence: "twinBlockDivergence";
|
|
904
|
+
/** A typed number an order of magnitude or more off the numbers typed in its format on the sheet. */
|
|
905
|
+
readonly ScaleOutlier: "scaleOutlier";
|
|
906
|
+
/** A constant typed into a formula — a number, a string or a boolean — and how often the workbook types it. */
|
|
907
|
+
readonly ConstantFrequency: "constantFrequency";
|
|
908
|
+
};
|
|
909
|
+
type ErrorCheck = typeof ErrorCheck[keyof typeof ErrorCheck];
|
|
910
|
+
/**
|
|
911
|
+
* One error check firing at a cell: the check, and the facts that make it fire.
|
|
912
|
+
*
|
|
913
|
+
* @remarks
|
|
914
|
+
* Evidence, never a verdict: what the cell breaks and where, so the reader can judge it. A
|
|
915
|
+
* pattern break is sometimes the right cell in a wrong run. There is no confidence.
|
|
916
|
+
*
|
|
917
|
+
* The evidence a cell's finding carries is the same for every cell of a filled run that breaks
|
|
918
|
+
* the same way, so a row of breaks is one region of the `anomalies` feature. Positions are
|
|
919
|
+
* therefore relative to the cell, in R1C1 (`R[-1]C` is the cell above).
|
|
920
|
+
*
|
|
921
|
+
* | check | evidence |
|
|
922
|
+
* | --- | --- |
|
|
923
|
+
* | `formula` | `axis` (`'row'` / `'column'`) the run lies along; `expected`, the R1C1 formula both neighbors share; `thickness`, the cells across the break (Excel flags only `1`); `flanks`, how far the run goes on each side; `corroborated` |
|
|
924
|
+
* | `formulaRange` | `reference`, the range the formula reads; `omitted`, the typed number just past its end |
|
|
925
|
+
* | `numberStoredAsText` | none — the cell's own text is the fact |
|
|
926
|
+
* | `emptyCellReference` | `reference`, the reference that reads an empty cell |
|
|
927
|
+
* | `unlockedFormula` | none |
|
|
928
|
+
* | `hardcodeInRun` | `axis`, `expected` (`'formula'`), `thickness`, `flanks`, `corroborated` |
|
|
929
|
+
* | `styleBreak` | `layer` (`'font'`, `'fill'`, `'numberFormat'`, `'alignment'`); `axis`; `expected`, the format both sides share; `actual`, this cell's; `thickness`, `flanks`, `corroborated` |
|
|
930
|
+
* | `styleRole` | `part` (`'fontColor'`); `role` (`'link'`, `'reference'`, `'computed'`, `'input'`); `expected`, the color most cells of that role on the sheet have; `actual`, this cell's; `majority`, how many cells of the role have `expected`; `of`, how many cells the role has on the sheet |
|
|
931
|
+
* | `repeatedReference` | `reference`, the reference counted again; `overlaps`, the one it falls inside when the two are not the same |
|
|
932
|
+
* | `degenerateCall` | `function`; `reference`, the one cell aggregated, or `literals`, the typed numbers |
|
|
933
|
+
* | `sumIncludesSubtotal` | `reference`, the range summed; `subtotal` or `ratio`, the cell inside it that is one |
|
|
934
|
+
* | `misalignedReference` | `term`, the reference outside the block; `block`, the rows (or columns) of the cell's own block that the formula sums; `landsAt`, the block the term lands in, when it lands in one; `targetRole`, what the term reads: `'lineItem'` (a line of another block), `'closingRow'` (another block's last line, a subtotal), `'outsideBlocks'` (no block) or `'absolute'` (a fixed reference, a rate or an assumption) |
|
|
935
|
+
* | `approximateMatch` | `function`; `matchType`, `'1'`, `'-1'`, `'TRUE'` or `'omitted'` |
|
|
936
|
+
* | `lookupShape` | `array`, the range the result is read from; `vector`, the range the key is found in |
|
|
937
|
+
* | `externalReference` | `kind` (`'workbook'`, `'deleted'`, `'udf'`); `reference`, or `function` for a `'udf'` |
|
|
938
|
+
* | `errorConstant` | `error`, the error the formula is; `dataTable`, the anchor of a data table that spills less than the block it heads, and `extent`, the rectangle the two cover |
|
|
939
|
+
* | `linkLabelMismatch` | `label` / `labelAt`, the cell's row label; `target` / `targetAt`, the label of the row it links to |
|
|
940
|
+
* | `keyLabelMismatch` | `function`; `key`; `rowLabel` / `rowLabelAt` and `columnLabel` / `columnLabelAt`, where found |
|
|
941
|
+
* | `signVsSiblings` | `reference`; `sign` (`'negative'` / `'positive'`); `siblings`, how many links into that row read the other sign; `siblingAt`, one of them |
|
|
942
|
+
* | `literalMatchesInput` | `literal`, the number as the formula types it; `inputAt`, the nearest typed number of that value no formula reads; `label` / `labelAt`, that input's label, when it has one; `matches`, the places the value is typed unread |
|
|
943
|
+
* | `twinBlockDivergence` | `part` (`'literal'` / `'sign'`); for a literal, `literal` and `expected`, this formula's number and its twins'; for a sign, `term` of `terms`, the term that differs, `references`, how many the shape holds, and `sign`, how this formula adds it; `twins`, how many formulas carry the other side; `twinAt`, one of them |
|
|
944
|
+
* | `scaleOutlier` | `format` (`'percent'`); `times`, the power of ten the value is off by; `typical`, the median of the sheet's typed numbers in that format; `of`, how many there are |
|
|
945
|
+
* | `constantFrequency` | `kind` (`'number'`, `'string'`, `'boolean'`); `value`, a number without its sign; `uses`, the places in the workbook that type it; `of`, the workbook's constant uses |
|
|
946
|
+
*
|
|
947
|
+
* **Runs.** `formula`, `hardcodeInRun` and `styleBreak` are one rule over different layers of
|
|
948
|
+
* the sheet: a region thin against the run it sits in. The cells on both sides agree with each
|
|
949
|
+
* other and not with it, and the run goes on at least two cells each side and at least as far as
|
|
950
|
+
* the region is thick (`flanks`), so a block as large as its surroundings is a section, not a
|
|
951
|
+
* break. A single cell between two that agree is kept too, with `flanks: 1`. A format compares
|
|
952
|
+
* as authored on the cell: none (`'normal'`), one equal to the Normal style's
|
|
953
|
+
* (`'authored-normal'`), or the authored properties as JSON.
|
|
954
|
+
*
|
|
955
|
+
* `corroborated` lists the other layers that change at both of the region's edges too: formula
|
|
956
|
+
* shape (`'formulaShape'`), formula or typed value (`'hasFormula'`), the value's kind (`'kind'`),
|
|
957
|
+
* and the format layers. A lone change, corroborated by nothing, is the stronger candidate; a
|
|
958
|
+
* row that differs on many layers (a total under its line items) is usually structure.
|
|
959
|
+
*
|
|
960
|
+
* **Blocks.** `misalignedReference` reads a formula against the block it closes or opens: the
|
|
961
|
+
* lines (rows, or columns for a row-wise total) holding content in the formula's own columns,
|
|
962
|
+
* between blank lines that span them. It fires on a sum that adds the block's own cells and
|
|
963
|
+
* also, with the same sign, a cell off the block's lines: `=SUM(K51:K53)+J46` in K54. A term on
|
|
964
|
+
* the block's lines in another column (a prior period) and a term taken away are not reported,
|
|
965
|
+
* nor is a sum of other blocks' totals that reads nothing of its own block. A running total that
|
|
966
|
+
* adds the previous block's total is reported as `closingRow`, ranked low.
|
|
967
|
+
*
|
|
968
|
+
* **Roles.** A cell's role ({@link ICell.Role}, the `role` feature) is its job, from what it
|
|
969
|
+
* reads and who reads it. `styleRole` pairs a format part with the role, for links, references, computed cells and inputs
|
|
970
|
+
* beside a label: the color most cells of a role have on the
|
|
971
|
+
* sheet is the role's, and a link, reference or computed cell in another color fires when that
|
|
972
|
+
* color is one the workbook writes some role in, on any sheet (a link left black where links
|
|
973
|
+
* are green and calculations black), never when it is decorative (white, red, a section's text
|
|
974
|
+
* color). A label never fires, and an input fires only beside a label: a typed number inside a
|
|
975
|
+
* data block reads like the data around it. Colors are the authored font color as `#RRGGBB`; a
|
|
976
|
+
* cell with none authored has the Normal style's. `majority` and `of` are evidence, not a
|
|
977
|
+
* gate: a convention held by 3 of 5 cells is reported as such.
|
|
978
|
+
*
|
|
979
|
+
* **Rank** says which finding to read first. It is not a confidence. For a run finding it is
|
|
980
|
+
* `weight × (1 / thickness) × (flanks / max(2, thickness)) × (1 − corroboration)`, where
|
|
981
|
+
* `weight` is the layer's and `corroboration` is the weight of the corroborating layers over the
|
|
982
|
+
* weight of every layer that could have corroborated. The layer weights are formula shape `1`,
|
|
983
|
+
* kind `0.6`, number format `0.5`, formula or typed value `0.4`, font `0.3`, fill `0.1`,
|
|
984
|
+
* alignment `0.05`. Every other check ranks at a fixed weight: `repeatedReference` and
|
|
985
|
+
* `lookupShape` `1`, `approximateMatch` and `externalReference` `0.9`, `formulaRange` and
|
|
986
|
+
* `degenerateCall` `0.8`, `emptyCellReference` and `sumIncludesSubtotal` `0.6`,
|
|
987
|
+
* `keyLabelMismatch` and `linkLabelMismatch` `0.4`, `unlockedFormula` and `signVsSiblings` `0.1`,
|
|
988
|
+
* `numberStoredAsText` `0.05`. A `styleRole` finding ranks at the role's weight (`link` `0.6`,
|
|
989
|
+
* `reference` `0.4`, `input` `0.3`, `computed` `0.2`) times `majority / of`. A
|
|
990
|
+
* `misalignedReference` finding ranks at `0.8` times its target's share: `lineItem` `1`,
|
|
991
|
+
* `outsideBlocks` `0.5`, `closingRow` and `absolute` `0.25`.
|
|
992
|
+
*
|
|
993
|
+
* A run or `styleRole` finding's rank is then divided by the number of times the same finding
|
|
994
|
+
* (the same check and evidence) occurs in the workbook: a finding repeated across a model is the
|
|
995
|
+
* author's style, and the one that occurs once is the exception to read first. So a finding's
|
|
996
|
+
* rank can change when another sheet changes. The weights are measured on the SpreadsheetBench
|
|
997
|
+
* v2 Debugging goldens and move as other measurements arrive. Regions of the `anomalies` feature
|
|
998
|
+
* list highest rank first, and so do a cell's findings, in check order within an equal rank.
|
|
999
|
+
*
|
|
1000
|
+
* **Literals and twins.** `literalMatchesInput` reads the numbers typed into a formula against
|
|
1001
|
+
* the typed numbers no formula reads: a reference replaced by its value is what left the input
|
|
1002
|
+
* unread. Small counts, calendar periods and powers of ten never fire. `twinBlockDivergence`
|
|
1003
|
+
* reads formulas of the same shape once references, literals and signs are set aside: twins that
|
|
1004
|
+
* divide by `12` and by `365`, or one that adds a term the others take away. Literals compare only
|
|
1005
|
+
* when both are a calendar period, a power of ten or a small count. Every side of a divergence is
|
|
1006
|
+
* listed, since two wrong rows can outvote the right one.
|
|
1007
|
+
*
|
|
1008
|
+
* `literalMatchesInput` ranks at `0.8 / matches`. A `twinBlockDivergence` finding ranks at `0.8`
|
|
1009
|
+
* times the share of the twins on the other side, `twins / (twins + this side's count)`, halved
|
|
1010
|
+
* for a sign: signs differ between line items by design, so a sign divergence is read when asked
|
|
1011
|
+
* for by check. `scaleOutlier` ranks at `0.8`.
|
|
1012
|
+
*
|
|
1013
|
+
* `constantFrequency` reports every constant a formula types, the common ones too, with how many
|
|
1014
|
+
* places in the workbook type it (`uses`) and of how many constant uses (`of`). It ranks at
|
|
1015
|
+
* `0.1 / uses × of / (of + 10)`: the rarer the constant, the higher, and a constant on a workbook
|
|
1016
|
+
* that types few has little to be rare against. A finding's `uses` and `of` change when another
|
|
1017
|
+
* sheet changes.
|
|
1018
|
+
*
|
|
1019
|
+
* A label's position is absolute (`R12C3`), since it stays put whichever cell of a region reads
|
|
1020
|
+
* it; its text is the one read at the region's first cell.
|
|
1021
|
+
*/
|
|
1022
|
+
interface Anomaly {
|
|
1023
|
+
/** The check that fires. */
|
|
1024
|
+
readonly check: ErrorCheck;
|
|
1025
|
+
/** The facts it fires on. */
|
|
1026
|
+
readonly evidence: Readonly<Record<string, string | number | readonly string[]>>;
|
|
1027
|
+
/** Which finding to read first, highest first; see the remarks. */
|
|
1028
|
+
readonly rank: number;
|
|
1029
|
+
}
|
|
762
1030
|
}
|
|
763
1031
|
//# sourceMappingURL=ICell.d.ts.map
|
|
@@ -62,6 +62,11 @@ export interface ICellHeader {
|
|
|
62
62
|
* @see `IOutline`
|
|
63
63
|
*/
|
|
64
64
|
getOutlineLevel(): number;
|
|
65
|
+
/**
|
|
66
|
+
* Whether the column's width was last set by fitting it to its content. Setting the width any
|
|
67
|
+
* other way clears it, as in Excel. Always `false` for a row.
|
|
68
|
+
*/
|
|
69
|
+
isBestFit(): boolean;
|
|
65
70
|
/**
|
|
66
71
|
* For runtime introspection.
|
|
67
72
|
*/
|
|
@@ -152,13 +157,9 @@ export declare namespace ICellHeader {
|
|
|
152
157
|
*/
|
|
153
158
|
cl?: boolean;
|
|
154
159
|
/**
|
|
155
|
-
*
|
|
156
|
-
*
|
|
157
|
-
* @remarks
|
|
158
|
-
* * The style id is only available for export for backward compatible `ISheet.ToJSONOptions.includeHeaderStyles` is set.
|
|
159
|
-
* * This flag is ignored during loading.
|
|
160
|
+
* Best fit. The column's width was last set by fitting it to its content.
|
|
160
161
|
*/
|
|
161
|
-
|
|
162
|
+
bf?: boolean;
|
|
162
163
|
}
|
|
163
164
|
}
|
|
164
165
|
//# sourceMappingURL=ICellHeader.d.ts.map
|
|
@@ -32,7 +32,7 @@ export interface ICellProtection {
|
|
|
32
32
|
*
|
|
33
33
|
* @remarks
|
|
34
34
|
* * An exception, like {@link isAlwaysUnlocked}: a formula shows when the sheet
|
|
35
|
-
* (`
|
|
35
|
+
* (`IWorksheetProtection.isShowFormulasAllowed`) or the cell allows it, so this only matters while
|
|
36
36
|
* the sheet hides them.
|
|
37
37
|
* * A hidden formula reads as no formula ({@link ICell.getFormula} is `null`), but it still
|
|
38
38
|
* calculates and is still saved with the workbook. It is a view rule, not secrecy.
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { IRange, Scalar } from '@sheetxl/primitives';
|
|
2
|
+
import { IListener } from '../listener';
|
|
3
|
+
import { Anchored } from '../anchored/Anchored';
|
|
4
|
+
import { AbstractAnchored } from '../anchored/AbstractAnchored';
|
|
5
|
+
import { ICellControl } from './ICellControl';
|
|
6
|
+
/**
|
|
7
|
+
* Implementation of {@link ICellControl}.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* Extends {@link AbstractAnchored} directly: a control has no condition and no formula, so it
|
|
11
|
+
* never subscribes to range events. Its definition is fixed at creation; a different control is a
|
|
12
|
+
* different entry.
|
|
13
|
+
*/
|
|
14
|
+
export declare class CellControl extends AbstractAnchored<State, ICellControl.Events> implements ICellControl {
|
|
15
|
+
/** @internal */
|
|
16
|
+
protected _initialize(options: CellControl.ConstructorOptions): void;
|
|
17
|
+
/** @internal */
|
|
18
|
+
protected _getActionDescription(action: 'delete' | 'initialize' | 'updateListener'): string | null;
|
|
19
|
+
/**
|
|
20
|
+
* Always: a control pins to where it was authored, as a conditional format does.
|
|
21
|
+
* @internal
|
|
22
|
+
*/
|
|
23
|
+
protected _isAnchorAbsolute(): boolean;
|
|
24
|
+
/** @internal */
|
|
25
|
+
protected _processContainerShift(options: Anchored.ShiftOptions): IRange.Coords | null | void;
|
|
26
|
+
/** {@inheritDoc ICellControl.getType} */
|
|
27
|
+
getType(): string;
|
|
28
|
+
/** {@inheritDoc ICellControl.isAccepted} */
|
|
29
|
+
isAccepted(value: Scalar): boolean;
|
|
30
|
+
/**
|
|
31
|
+
* Covers `ranges` too, coalesced with what the control already covers. Autofill uses it to grow
|
|
32
|
+
* the template's control rather than mint a twin.
|
|
33
|
+
* @internal
|
|
34
|
+
*/
|
|
35
|
+
_extendRanges(ranges: readonly IRange.Coords[]): void;
|
|
36
|
+
/** {@inheritDoc IListener.ISource.addListeners} */
|
|
37
|
+
addListeners(listeners: ICellControl.IListeners, options?: IListener.Options): IListener.Remove;
|
|
38
|
+
/** {@inheritDoc ICellControl.toJSON} */
|
|
39
|
+
toJSON(): ICellControl.JSON;
|
|
40
|
+
get [Symbol.toStringTag](): string;
|
|
41
|
+
toString(): string;
|
|
42
|
+
/** {@inheritDoc ICellControl.isICellControl} */
|
|
43
|
+
get isICellControl(): true;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Interfaces for creating a {@link CellControl}.
|
|
47
|
+
*/
|
|
48
|
+
export declare namespace CellControl {
|
|
49
|
+
interface ConstructorOptions extends Anchored.ConstructorOptions<ICellControl.JSON> {
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* A frozen copy of `json` with a non-empty `type`.
|
|
53
|
+
*
|
|
54
|
+
* @throws when `json` names no type.
|
|
55
|
+
*/
|
|
56
|
+
function normalizeJSON(json: ICellControl.JSON | null | undefined): Readonly<ICellControl.JSON>;
|
|
57
|
+
/**
|
|
58
|
+
* Whether two controls are the same definition: the same type and the same properties.
|
|
59
|
+
*/
|
|
60
|
+
function isSameJSON(a: Readonly<ICellControl.JSON>, b: Readonly<ICellControl.JSON>): boolean;
|
|
61
|
+
}
|
|
62
|
+
/** @internal */
|
|
63
|
+
interface State extends AbstractAnchored.State {
|
|
64
|
+
json: Readonly<ICellControl.JSON>;
|
|
65
|
+
}
|
|
66
|
+
export {};
|
|
67
|
+
//# sourceMappingURL=CellControl.d.ts.map
|