@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.
Files changed (522) hide show
  1. package/README.md +1 -1
  2. package/browser/esm/{CYyv6uGjo10ig5FP.mjs → -Jx-jNHmtIQQfLvK.mjs} +1 -1
  3. package/browser/esm/{CdLZWVcH8cncBUPJ.mjs → 2WuhYrIpYmOR5H73.mjs} +110 -261
  4. package/browser/esm/{Cqr3knDsBvoVZ6MN.mjs → 2mIwPy2D2JUX-9wx.mjs} +2 -2
  5. package/browser/esm/B3wf5vZCsWfWsDbj.mjs +12 -0
  6. package/browser/esm/{BzLfNyc6OOShIErH.mjs → BIHrHjRGWVlJglcp.mjs} +2 -2
  7. package/browser/esm/{C9B0djuUarfNdoj0.mjs → BTFBedJMRWGvZyCE.mjs} +1 -1
  8. package/browser/esm/{Btg43M1Bf-ENDreu.mjs → BdCJNawfifyPupCP.mjs} +1 -1
  9. package/browser/esm/{ClB5ix51roQOpZEr.mjs → Bg5Di9GLNAkbqQ1P.mjs} +2877 -2067
  10. package/browser/esm/BnC4-27Igwb8oDf2.mjs +1552 -0
  11. package/browser/esm/{DhKkrCVASZ6Isvz6.mjs → Bt8_m94tBdks209L.mjs} +1 -1
  12. package/browser/esm/{zqJOaweiXE9D8RY1.mjs → BudSIfXBAsTxvu-K.mjs} +31835 -40812
  13. package/browser/esm/C9u8FUewte5ugUjH.mjs +5132 -0
  14. package/browser/esm/{Di58Ji1n--3Mgc_2.mjs → CBYMTDzMf1Vh7pkw.mjs} +1 -1
  15. package/browser/esm/CNdjyofiRu6CYOrr.mjs +12835 -0
  16. package/browser/esm/{Dtoyt8q5RyGAlxCp.mjs → CRkYR-siY2C994KV.mjs} +1 -1
  17. package/browser/esm/CTe2qfmIUEad6FJv.mjs +199 -0
  18. package/browser/esm/CUzYuYTTGsChC_kZ.mjs +8422 -0
  19. package/browser/esm/CdEO8CEee6lEhabA.mjs +117 -0
  20. package/browser/esm/CfRqiPDg6RBTg1EN.mjs +367 -0
  21. package/browser/esm/CndRBvVfQUJIYRRj.mjs +193 -0
  22. package/browser/esm/{Y79I7Sm8kjaYexhf.mjs → CwOPLXU3-9ZHGyOT.mjs} +1 -1
  23. package/browser/esm/{CjsUGJEQSbGjnH6R.mjs → Cxjxk0ncRKx80I-w.mjs} +1 -1
  24. package/browser/esm/D2RZh0O9neOsyLAE.mjs +281 -0
  25. package/browser/esm/{De175LygU7ot4nQm.mjs → D64dM68B1pKYFzdP.mjs} +2 -2
  26. package/browser/esm/{o8MFgcVXns987D6_.mjs → D9xNz46kAfXMZzp4.mjs} +6 -6
  27. package/browser/esm/{BcHmrKHwMMOlzc9_.mjs → DK899HhWX1HINMC1.mjs} +55 -55
  28. package/browser/esm/DPhGQLNGmDZwODwJ.mjs +395 -0
  29. package/browser/esm/DVroRnhi-5IDXNgM.mjs +210 -0
  30. package/browser/esm/{Bk7xxbdDpa7-sIwd.mjs → DZiivy0NmO1Vnyzk.mjs} +2 -2
  31. package/browser/esm/{CZ5oa92wZEAXebgk.mjs → DgrAuRD2qr2DvFeJ.mjs} +78 -68
  32. package/browser/esm/{D4uVlrG0xEFctsSM.mjs → DobHLF6VjHr7Xi40.mjs} +285 -67
  33. package/browser/esm/{CSx9ed1JOs7K5BXO.mjs → DwZCT7DZiiXoTweg.mjs} +2 -2
  34. package/browser/esm/DwwR3O2sEZApPSTF.mjs +86 -0
  35. package/browser/esm/Tah7cnFb_HNZdLtj.mjs +128 -0
  36. package/browser/esm/{BEAY9XgKNx-bakXW.mjs → fXWUMDhZ5yMSO629.mjs} +1 -1
  37. package/browser/esm/{BqskM7wA8oPfFQue.mjs → hCQJcmIzPDxDEv2q.mjs} +2 -2
  38. package/browser/esm/index.mjs +1294 -1008
  39. package/browser/esm/{Cgd5BnM3hg9RyUel.mjs → qO-ujUrgq6H3TQix.mjs} +1 -1
  40. package/browser/esm/w6Jea0TiclPrYZ2M.mjs +1703 -0
  41. package/browser/esm/yuhcOYw6SHQ-RCm3.mjs +114 -0
  42. package/licenses/dependencies.txt +75 -75
  43. package/node/esm/-TA0MneBDKdGhsib.mjs +8668 -0
  44. package/node/esm/B-HUPAcqvK0eeeCz.mjs +134 -0
  45. package/node/esm/BL2iiEoqxDEV2Xrg.mjs +8320 -0
  46. package/node/esm/{C6ZXsNyLXI6zA63X.mjs → BNXLOEddJ6O9gYws.mjs} +9 -9
  47. package/node/esm/{BH1v-E4Ro3bR7Znw.mjs → BSvOluusoDM4z_dx.mjs} +151 -302
  48. package/node/esm/{CD9wbvufChVYYkrI.mjs → BskP3b8vUoIOGLY6.mjs} +2 -2
  49. package/node/esm/{CnSQ7MTXAUAyBOoS.mjs → Btw4148Ot8ifhNc1.mjs} +285 -64
  50. package/node/esm/{B6D7sSetrcOWLsKj.mjs → C14-R6tifRh7pc0p.mjs} +1 -1
  51. package/node/esm/C99zzq8DImQXi4BQ.mjs +133 -0
  52. package/node/esm/{BtuY37FumvLE7EBo.mjs → CBuEu5Jk-LfaDy-H.mjs} +176 -166
  53. package/node/esm/{DdFgXl-Ux2cMBTs_.mjs → CG-qBU5BAaVz7e-P.mjs} +1 -1
  54. package/node/esm/CPI58duc0j0a-HpJ.mjs +115 -0
  55. package/node/esm/CRt3vXe6YmXzqk3H.mjs +406 -0
  56. package/node/esm/{CUUoseJmFsCf82bb.mjs → C_aL7CGS1lrNn1Ng.mjs} +1 -1
  57. package/node/esm/{D7MfcID2Wf6l6VpC.mjs → C_xf5Bz30VqiJjXn.mjs} +1 -1
  58. package/node/esm/CiIymQN6aJCul62g.mjs +610 -0
  59. package/node/esm/{B9ljpEIZg6wOTzRE.mjs → Ci_zLYmCD7e-C79O.mjs} +1 -1
  60. package/node/esm/{Bqd62L8KFgdS0Vou.mjs → CkRYLed8Mmn3giNg.mjs} +2 -2
  61. package/node/esm/D3ptRKzASqBut1DE.mjs +117 -0
  62. package/node/esm/{DefYISWfdZJFx57m.mjs → D4ROK9UwDpS6jO3Z.mjs} +1 -1
  63. package/node/esm/D8hO07ToAibIuniw.mjs +13014 -0
  64. package/node/esm/{Bh4dv6tMjXX3X4nI.mjs → DUTmDHbFbhLDT4F3.mjs} +1 -1
  65. package/node/esm/{DCplLG93GfTs1vNw.mjs → DV5CU37aEbFbWFL0.mjs} +1 -1
  66. package/node/esm/{CUQi5ZtMO02nhG0W.mjs → DdoiuKg9BKubtF1V.mjs} +1 -1
  67. package/node/esm/DggQ23jKMpwhENfa.mjs +372 -0
  68. package/node/esm/DhS6yWjrrSNIJMsn.mjs +1033 -0
  69. package/node/esm/{DMD12JUh7HJw2-jl.mjs → DhTya_mhmN53vskv.mjs} +1 -1
  70. package/node/esm/Dn1M7YWi25DeeYUb.mjs +210 -0
  71. package/node/esm/DrCf6ITcBhVOFpRj.mjs +86 -0
  72. package/node/esm/{BN9j8V9gCExMjVtJ.mjs → DxazKtROyaI51dWl.mjs} +1 -1
  73. package/node/esm/{MiU4rDOiocmJ-9Ry.mjs → Q_S1g46ZOTrdhTae.mjs} +1 -1
  74. package/node/esm/Vocy-I9dKzZMr0Ct.mjs +59323 -0
  75. package/node/esm/ZXPFcsT2zrALCZux.mjs +289 -0
  76. package/node/esm/eimUGjiIP-b8HiM6.mjs +199 -0
  77. package/node/esm/icn2nX5Z8e_3mNAv.mjs +12 -0
  78. package/node/esm/index.mjs +2808 -65678
  79. package/node/esm/lGJ42sHqg5if2bba.mjs +1770 -0
  80. package/node/esm/{Bsx9uijd4X_SKV3L.mjs → pYtP7wPyS96NQyXS.mjs} +51 -51
  81. package/package.json +6 -7
  82. package/resources/contents.json +120 -0
  83. package/resources/fonts/arial-bold-italic.hinted.json +125 -0
  84. package/resources/fonts/arial-bold-italic.metrics.json +13 -13
  85. package/resources/fonts/arial-bold-italic.rows.json +9 -0
  86. package/resources/fonts/arial-bold.hinted.json +125 -0
  87. package/resources/fonts/arial-bold.metrics.json +12 -12
  88. package/resources/fonts/arial-bold.rows.json +9 -0
  89. package/resources/fonts/arial-italic.hinted.json +125 -0
  90. package/resources/fonts/arial-italic.metrics.json +13 -13
  91. package/resources/fonts/arial-italic.rows.json +9 -0
  92. package/resources/fonts/arial-regular.hinted.json +125 -0
  93. package/resources/fonts/arial-regular.metrics.json +12 -12
  94. package/resources/fonts/arial-regular.rows.json +9 -0
  95. package/resources/fonts/calibri-bold-italic.hinted.json +122 -0
  96. package/resources/fonts/calibri-bold-italic.metrics.json +2 -2
  97. package/resources/fonts/calibri-bold-italic.rows.json +9 -0
  98. package/resources/fonts/calibri-bold.hinted.json +122 -0
  99. package/resources/fonts/calibri-bold.metrics.json +1 -1
  100. package/resources/fonts/calibri-bold.rows.json +9 -0
  101. package/resources/fonts/calibri-italic.hinted.json +121 -0
  102. package/resources/fonts/calibri-italic.metrics.json +2 -2
  103. package/resources/fonts/calibri-italic.rows.json +9 -0
  104. package/resources/fonts/calibri-regular.hinted.json +121 -0
  105. package/resources/fonts/calibri-regular.metrics.json +1 -1
  106. package/resources/fonts/calibri-regular.rows.json +9 -0
  107. package/resources/fonts/cambria-bold-italic.hinted.json +105 -0
  108. package/resources/fonts/cambria-bold-italic.metrics.json +26 -26
  109. package/resources/fonts/cambria-bold-italic.rows.json +9 -0
  110. package/resources/fonts/cambria-bold.hinted.json +108 -0
  111. package/resources/fonts/cambria-bold.metrics.json +19 -19
  112. package/resources/fonts/cambria-bold.rows.json +9 -0
  113. package/resources/fonts/cambria-italic.hinted.json +102 -0
  114. package/resources/fonts/cambria-italic.metrics.json +23 -23
  115. package/resources/fonts/cambria-italic.rows.json +9 -0
  116. package/resources/fonts/cambria-regular.hinted.json +110 -0
  117. package/resources/fonts/cambria-regular.metrics.json +18 -18
  118. package/resources/fonts/cambria-regular.rows.json +9 -0
  119. package/resources/fonts/contents.json +280 -0
  120. package/resources/fonts/courier-new-bold-italic.hinted.json +11 -0
  121. package/resources/fonts/courier-new-bold-italic.metrics.json +12 -12
  122. package/resources/fonts/courier-new-bold-italic.rows.json +9 -0
  123. package/resources/fonts/courier-new-bold.hinted.json +11 -0
  124. package/resources/fonts/courier-new-bold.metrics.json +12 -12
  125. package/resources/fonts/courier-new-bold.rows.json +9 -0
  126. package/resources/fonts/courier-new-italic.hinted.json +11 -0
  127. package/resources/fonts/courier-new-italic.metrics.json +12 -12
  128. package/resources/fonts/courier-new-italic.rows.json +9 -0
  129. package/resources/fonts/courier-new-regular.hinted.json +11 -0
  130. package/resources/fonts/courier-new-regular.metrics.json +12 -12
  131. package/resources/fonts/courier-new-regular.rows.json +9 -0
  132. package/resources/fonts/times-new-roman-bold-italic.hinted.json +125 -0
  133. package/resources/fonts/times-new-roman-bold-italic.metrics.json +15 -15
  134. package/resources/fonts/times-new-roman-bold-italic.rows.json +9 -0
  135. package/resources/fonts/times-new-roman-bold.hinted.json +125 -0
  136. package/resources/fonts/times-new-roman-bold.metrics.json +12 -12
  137. package/resources/fonts/times-new-roman-bold.rows.json +9 -0
  138. package/resources/fonts/times-new-roman-italic.hinted.json +125 -0
  139. package/resources/fonts/times-new-roman-italic.metrics.json +16 -16
  140. package/resources/fonts/times-new-roman-italic.rows.json +9 -0
  141. package/resources/fonts/times-new-roman-regular.hinted.json +125 -0
  142. package/resources/fonts/times-new-roman-regular.metrics.json +16 -16
  143. package/resources/fonts/times-new-roman-regular.rows.json +9 -0
  144. package/resources/locales/de/model.msg.json +93 -9
  145. package/resources/locales/en/model.msg.json +95 -10
  146. package/types/scripting-api.json +10809 -8021
  147. package/types/scripting-enums.json +201 -44
  148. package/types/scripting.d.ts +17030 -8666
  149. package/types/src/.generated/wasm/fonts.d.ts +161 -0
  150. package/types/src/.generated/wasm/fonts_bg.inline.d.ts +3 -0
  151. package/types/src/.generated/wasm/sdk.d.ts +122 -0
  152. package/types/src/.generated/wasm/sdk_bg.inline.d.ts +3 -0
  153. package/types/src/address/AddressUtils.d.ts +10 -1
  154. package/types/src/address/_StructuredAddress.d.ts +58 -0
  155. package/types/src/anomalies/_Anomalies.d.ts +109 -0
  156. package/types/src/anomalies/_FocusTable.d.ts +11 -0
  157. package/types/src/anomalies/_FormulaChecks.d.ts +133 -0
  158. package/types/src/anomalies/_LabelChecks.d.ts +21 -0
  159. package/types/src/anomalies/_LiteralChecks.d.ts +35 -0
  160. package/types/src/anomalies/_SeriesChecks.d.ts +13 -0
  161. package/types/src/border/IBorders.d.ts +16 -0
  162. package/types/src/calculation/Calculation.d.ts +139 -371
  163. package/types/src/calculation/ExternalBookBindings.d.ts +2 -3
  164. package/types/src/calculation/FormulaLiterals.d.ts +2 -1
  165. package/types/src/calculation/FormulaText.d.ts +18 -2
  166. package/types/src/calculation/ICalculation.d.ts +133 -18
  167. package/types/src/calculation/INamedFormulasCollection.d.ts +4 -0
  168. package/types/src/calculation/NamedFormulaCollection.d.ts +293 -22
  169. package/types/src/calculation/_CloneBoundary.d.ts +1 -1
  170. package/types/src/calculation/_FormulaToolkit.d.ts +9 -0
  171. package/types/src/calculation/_TableExtent.d.ts +60 -0
  172. package/types/src/calculation/compiler/ASTTypes.d.ts +6 -2
  173. package/types/src/calculation/compiler/CompilerUtils.d.ts +17 -0
  174. package/types/src/calculation/compiler/ParserUtils.d.ts +16 -0
  175. package/types/src/calculation/compiler/Types.d.ts +9 -1
  176. package/types/src/calculation/engine/CalcBackend.d.ts +953 -0
  177. package/types/src/calculation/engine/index.d.ts +10 -0
  178. package/types/src/calculation/executor/CalcExecutor.d.ts +94 -24
  179. package/types/src/calculation/executor/CalcExecutorUtils.d.ts +23 -1
  180. package/types/src/calculation/executor/_WhatIf.d.ts +50 -0
  181. package/types/src/calculation/formula/Formula.d.ts +9 -0
  182. package/types/src/calculation/formula/FormulaBlock.d.ts +10 -3
  183. package/types/src/calculation/formula/IFormulaBlock.d.ts +21 -0
  184. package/types/src/calculation/formula/LambdaValue.d.ts +5 -3
  185. package/types/src/calculation/functions/FunctionDeclarations.d.ts +5 -1
  186. package/types/src/calculation/functions/_DataTableFunction.d.ts +14 -0
  187. package/types/src/calculation/functions/expandDeclaration.d.ts +15 -0
  188. package/types/src/calculation/functions/initializeFunctions.d.ts +0 -12
  189. package/types/src/calculation/grid/CalcGrid.d.ts +44 -10
  190. package/types/src/calculation/grid/CalcGridBackend.d.ts +35 -27
  191. package/types/src/calculation/grid/CalcGridProxy.d.ts +2 -2
  192. package/types/src/calculation/grid/CalcGridUtils.d.ts +12 -3
  193. package/types/src/calculation/grid/FormulaHost.d.ts +51 -6
  194. package/types/src/calculation/grid/ICalcGrid.d.ts +48 -15
  195. package/types/src/calculation/grid/_CalcRequest.d.ts +28 -6
  196. package/types/src/calculation/grid/_CellValueRun.d.ts +21 -0
  197. package/types/src/calculation/spatial/FormulaSpatialValue.d.ts +29 -2
  198. package/types/src/calculation/spatial/SpillEntry.d.ts +16 -2
  199. package/types/src/calculation/state/CalcNode.d.ts +0 -1
  200. package/types/src/calculation/state/CalcScope.d.ts +44 -6
  201. package/types/src/calculation/state/CalcState.d.ts +36 -4
  202. package/types/src/calculation/state/CalculationContext.d.ts +30 -3
  203. package/types/src/calculation/state/DeferredCalls.d.ts +260 -0
  204. package/types/src/calculation/state/IContextContainer.d.ts +32 -0
  205. package/types/src/calculation/state/_PendingOverlayGrid.d.ts +6 -0
  206. package/types/src/calculation/state/_WhatIfLayer.d.ts +91 -0
  207. package/types/src/calculation/toolkit/FormulaLiteralReader.d.ts +4 -0
  208. package/types/src/calculation/toolkit/FormulaTextParser.d.ts +10 -0
  209. package/types/src/calculation/toolkit/FunctionDeclarationTable.d.ts +4 -0
  210. package/types/src/calculation/toolkit/index.d.ts +12 -0
  211. package/types/src/cell/ICell.d.ts +302 -34
  212. package/types/src/cell/ICellHeader.d.ts +7 -6
  213. package/types/src/cell/ICellProtection.d.ts +1 -1
  214. package/types/src/cellControl/CellControl.d.ts +67 -0
  215. package/types/src/cellControl/CellControlCollection.d.ts +29 -0
  216. package/types/src/cellControl/CellControlRegistry.d.ts +47 -0
  217. package/types/src/cellControl/ICellControl.d.ts +99 -0
  218. package/types/src/cellControl/ICellControlCollection.d.ts +67 -0
  219. package/types/src/cellControl/index.d.ts +4 -0
  220. package/types/src/cellRange/ICellHeaderRange.d.ts +6 -9
  221. package/types/src/cellRange/ICellHeaderRanges.d.ts +5 -0
  222. package/types/src/cellRange/ICellRange.d.ts +525 -110
  223. package/types/src/cellRange/ICellRanges.d.ts +12 -6
  224. package/types/src/chart/Chart.d.ts +217 -15
  225. package/types/src/chart/ChartCollection.d.ts +7 -2
  226. package/types/src/chart/IChart.d.ts +1921 -35
  227. package/types/src/chart/IChartCollection.d.ts +27 -2
  228. package/types/src/chart/_ChartParts.d.ts +1066 -0
  229. package/types/src/chart/_ChartSource.d.ts +47 -0
  230. package/types/src/chart/createChart.d.ts +26 -0
  231. package/types/src/chart/index.d.ts +4 -0
  232. package/types/src/chart/kinds/ChartKind.d.ts +252 -0
  233. package/types/src/chart/kinds/_Area.d.ts +3 -0
  234. package/types/src/chart/kinds/_Bar.d.ts +4 -0
  235. package/types/src/chart/kinds/_BoxWhisker.d.ts +4 -0
  236. package/types/src/chart/kinds/_Bubble.d.ts +3 -0
  237. package/types/src/chart/kinds/_Funnel.d.ts +4 -0
  238. package/types/src/chart/kinds/_Hierarchy.d.ts +31 -0
  239. package/types/src/chart/kinds/_Histogram.d.ts +4 -0
  240. package/types/src/chart/kinds/_HitKinds.d.ts +23 -0
  241. package/types/src/chart/kinds/_Line.d.ts +4 -0
  242. package/types/src/chart/kinds/_OfPie.d.ts +4 -0
  243. package/types/src/chart/kinds/_Pie.d.ts +4 -0
  244. package/types/src/chart/kinds/_Placeholder.d.ts +6 -0
  245. package/types/src/chart/kinds/_Radar.d.ts +4 -0
  246. package/types/src/chart/kinds/_Scatter.d.ts +8 -0
  247. package/types/src/chart/kinds/_Sunburst.d.ts +4 -0
  248. package/types/src/chart/kinds/_Surface.d.ts +4 -0
  249. package/types/src/chart/kinds/_Treemap.d.ts +4 -0
  250. package/types/src/chart/kinds/_Waterfall.d.ts +18 -0
  251. package/types/src/chart/kinds/_builtIns.d.ts +11 -0
  252. package/types/src/chart/layout/ChartLayout.d.ts +829 -0
  253. package/types/src/chart/layout/TextMeasurer.d.ts +38 -0
  254. package/types/src/chart/layout/_HitGeometry.d.ts +50 -0
  255. package/types/src/chart/layout/_HitTest.d.ts +36 -0
  256. package/types/src/chart/layout/_Layout.d.ts +25 -0
  257. package/types/src/chart/layout/_LayoutUtils.d.ts +97 -0
  258. package/types/src/chart/math/BoxStats.d.ts +35 -0
  259. package/types/src/chart/math/DateUnitCalcs.d.ts +80 -0
  260. package/types/src/chart/math/DisplayUnits.d.ts +53 -0
  261. package/types/src/chart/math/Histogram.d.ts +48 -0
  262. package/types/src/chart/math/OrdUnitCalcs.d.ts +166 -0
  263. package/types/src/chart/math/Treemap.d.ts +28 -0
  264. package/types/src/chart/math/Trendlines.d.ts +71 -0
  265. package/types/src/chart/math/UnitCalcs.d.ts +98 -0
  266. package/types/src/chart/model/ChartModel.d.ts +681 -0
  267. package/types/src/chart/model/_ChartType.d.ts +14 -0
  268. package/types/src/chart/model/_Edits.d.ts +489 -0
  269. package/types/src/chart/model/_Grouping.d.ts +83 -0
  270. package/types/src/chart/model/_Inference.d.ts +52 -0
  271. package/types/src/chart/model/_ModelFacts.d.ts +112 -0
  272. package/types/src/chart/model/_NewChart.d.ts +208 -0
  273. package/types/src/chart/model/_OfPie.d.ts +18 -0
  274. package/types/src/chart/resolve/_LegacyStyles.d.ts +48 -0
  275. package/types/src/chart/resolve/_Resolve.d.ts +61 -0
  276. package/types/src/chart/resolve/_ResolvedChart.d.ts +447 -0
  277. package/types/src/collections/ISparseGrid.d.ts +11 -2
  278. package/types/src/collections/MixedTypedArrayList.d.ts +8 -2
  279. package/types/src/collections/RTree.d.ts +116 -36
  280. package/types/src/collections/SparseGrid.d.ts +9 -11
  281. package/types/src/collections/SpatialMap.d.ts +2 -8
  282. package/types/src/collections/SpatialMap3D.d.ts +2 -0
  283. package/types/src/collections/index.d.ts +1 -1
  284. package/types/src/comment/Comment.d.ts +32 -9
  285. package/types/src/comment/IComment.d.ts +41 -4
  286. package/types/src/comment/_NoteBox.d.ts +19 -2
  287. package/types/src/condition/AnchoredConditional.d.ts +30 -4
  288. package/types/src/condition/ICondition.d.ts +3 -2
  289. package/types/src/conditionalFormat/ConditionalFormat.d.ts +9 -3
  290. package/types/src/conditionalFormat/IConditionalFormat.d.ts +4 -3
  291. package/types/src/dataValidation/DataValidation.d.ts +1 -1
  292. package/types/src/dataValidation/DataValidationCollection.d.ts +4 -1
  293. package/types/src/dataValidation/IDataValidation.d.ts +1 -1
  294. package/types/src/dataValidation/IDataValidationCollection.d.ts +24 -0
  295. package/types/src/documentProperties/DocumentProperties.d.ts +66 -0
  296. package/types/src/documentProperties/ICustomProperty.d.ts +69 -0
  297. package/types/src/documentProperties/IDocumentProperties.d.ts +110 -0
  298. package/types/src/documentProperties/index.d.ts +3 -0
  299. package/types/src/externalBook/IExternalBook.d.ts +3 -4
  300. package/types/src/fetch/Fetcher.d.ts +15 -0
  301. package/types/src/fetch/IFetcher.d.ts +47 -0
  302. package/types/src/fetch/_WorkbookFetch.d.ts +43 -0
  303. package/types/src/fetch/index.d.ts +3 -0
  304. package/types/src/fill/IFill.d.ts +7 -0
  305. package/types/src/fill/IFillable.d.ts +47 -0
  306. package/types/src/fill/IStroke.d.ts +15 -1
  307. package/types/src/fill/PaintUtils.d.ts +24 -0
  308. package/types/src/fill/index.d.ts +2 -0
  309. package/types/src/font/AdvanceBuilder.d.ts +34 -0
  310. package/types/src/font/AdvanceTable.d.ts +128 -14
  311. package/types/src/font/CanvasAdvanceBuilder.d.ts +54 -0
  312. package/types/src/font/FontCapture.d.ts +4 -0
  313. package/types/src/font/FontCollection.d.ts +53 -2
  314. package/types/src/font/FontPlatform.d.ts +20 -0
  315. package/types/src/font/FontUtils.d.ts +5 -0
  316. package/types/src/font/IFont.d.ts +191 -61
  317. package/types/src/font/IFontCollection.d.ts +20 -14
  318. package/types/src/font/IFontStyle.d.ts +207 -0
  319. package/types/src/font/TableFileAdvanceBuilder.d.ts +9 -0
  320. package/types/src/font/_FontUtils.d.ts +11 -4
  321. package/types/src/font/_FontsVersion.d.ts +7 -0
  322. package/types/src/font/index.d.ts +1 -3
  323. package/types/src/font/platform.browser.d.ts +15 -0
  324. package/types/src/font/platform.node.d.ts +5 -0
  325. package/types/src/group/Group.d.ts +5 -0
  326. package/types/src/group/GroupMovableCollection.d.ts +4 -0
  327. package/types/src/history/IHistory.d.ts +19 -2
  328. package/types/src/hyperlink/IHyperlink.d.ts +17 -1
  329. package/types/src/hyperlink/_Hyperlink.d.ts +4 -1
  330. package/types/src/index.d.ts +4 -0
  331. package/types/src/license/LicenseManager.d.ts +21 -0
  332. package/types/src/license/_Utils.d.ts +18 -1
  333. package/types/src/license/runtime.browser.d.ts +5 -0
  334. package/types/src/license/runtime.node.d.ts +10 -0
  335. package/types/src/listener/IListener.d.ts +14 -2
  336. package/types/src/listener/ListenerEmitter.d.ts +11 -3
  337. package/types/src/movable/IMovable.d.ts +28 -15
  338. package/types/src/movable/IMovableCollection.d.ts +1 -1
  339. package/types/src/movable/Movable.d.ts +12 -1
  340. package/types/src/movable/MovableCollection.d.ts +7 -3
  341. package/types/src/movable/_InsertableCollection.d.ts +16 -5
  342. package/types/src/named/INamed.d.ts +30 -0
  343. package/types/src/named/INamedCollection.d.ts +38 -2
  344. package/types/src/named/NamedCollection.d.ts +34 -4
  345. package/types/src/numFmt/NumberFormatParser.d.ts +5 -0
  346. package/types/src/outline/IOutline.d.ts +1 -1
  347. package/types/src/outline/Outline.d.ts +2 -2
  348. package/types/src/picture/IPicture.d.ts +98 -1
  349. package/types/src/picture/Picture.d.ts +15 -7
  350. package/types/src/pivot/IPivotTable.d.ts +2 -2
  351. package/types/src/pivot/PivotTable.d.ts +5 -5
  352. package/types/src/primitives/AsyncValue.d.ts +58 -0
  353. package/types/src/primitives/ReferenceRange.d.ts +2 -2
  354. package/types/src/print/IPageLayout.d.ts +635 -0
  355. package/types/src/print/PageLayout.d.ts +258 -0
  356. package/types/src/print/index.d.ts +1 -1
  357. package/types/src/protectedRange/IProtectedRange.d.ts +2 -2
  358. package/types/src/protection/IProtection.d.ts +6 -0
  359. package/types/src/protection/PasswordHasher.d.ts +13 -0
  360. package/types/src/resource/IResource.d.ts +9 -0
  361. package/types/src/resource/IResourceCollection.d.ts +4 -0
  362. package/types/src/resource/Resource.d.ts +2 -0
  363. package/types/src/resource/_AddResource.d.ts +13 -0
  364. package/types/src/richData/CellImage.d.ts +95 -0
  365. package/types/src/richData/Hyperlink.d.ts +49 -0
  366. package/types/src/richData/IRichDataCollection.d.ts +76 -0
  367. package/types/src/richData/IRichDataKind.d.ts +66 -0
  368. package/types/src/richData/RichArray.d.ts +42 -0
  369. package/types/src/richData/RichDataCollection.d.ts +23 -0
  370. package/types/src/richData/RichDataRegistry.d.ts +89 -0
  371. package/types/src/richData/RichDataValues.d.ts +20 -0
  372. package/types/src/richData/RichRecord.d.ts +68 -0
  373. package/types/src/richData/RichText.d.ts +59 -0
  374. package/types/src/richData/index.d.ts +9 -0
  375. package/types/src/scripting/FunctionArguments.d.ts +17 -1
  376. package/types/src/scripting/FunctionCollection.d.ts +8 -0
  377. package/types/src/scripting/IModule.d.ts +3 -3
  378. package/types/src/scripting/IScript.d.ts +2 -2
  379. package/types/src/scripting/ITypedFunction.d.ts +1 -1
  380. package/types/src/scripting/Scripts.d.ts +10 -0
  381. package/types/src/scripting/TypedFunction.d.ts +2 -0
  382. package/types/src/scripting/declarations.d.ts +3 -0
  383. package/types/src/selection/ChartElementSelection.d.ts +39 -0
  384. package/types/src/selection/IChartElementSelection.d.ts +103 -0
  385. package/types/src/selection/IItemSelection.d.ts +131 -0
  386. package/types/src/selection/IMovableSelection.d.ts +6 -34
  387. package/types/src/selection/IRangeSelection.d.ts +4 -4
  388. package/types/src/selection/ItemSelection.d.ts +49 -0
  389. package/types/src/selection/MovableSelection.d.ts +11 -30
  390. package/types/src/selection/RangeSelection.d.ts +4 -4
  391. package/types/src/selection/index.d.ts +3 -0
  392. package/types/src/shape/IShape.d.ts +2 -1
  393. package/types/src/shape/IShapeStyle.d.ts +5 -31
  394. package/types/src/shape/ITextBoxStyle.d.ts +85 -0
  395. package/types/src/shape/ShapeStyleUtils.d.ts +13 -1
  396. package/types/src/shape/_Connectors.d.ts +9 -9
  397. package/types/src/shape/_ShapeStyle.d.ts +9 -0
  398. package/types/src/shape/index.d.ts +1 -0
  399. package/types/src/sheet/CellRegion.d.ts +37 -3
  400. package/types/src/sheet/ICellContainerOptions.d.ts +6 -0
  401. package/types/src/sheet/IOpaqueSheet.d.ts +46 -0
  402. package/types/src/sheet/ISheet.d.ts +81 -1078
  403. package/types/src/sheet/IWorksheet.d.ts +1521 -0
  404. package/types/src/sheet/{ISheetCollection.d.ts → IWorksheetCollection.d.ts} +37 -12
  405. package/types/src/sheet/NamedCellRange.d.ts +2 -2
  406. package/types/src/sheet/NamedRange.d.ts +2 -2
  407. package/types/src/sheet/OpaqueSheet.d.ts +114 -0
  408. package/types/src/sheet/SheetCell.d.ts +40 -27
  409. package/types/src/sheet/SheetRange.d.ts +50 -13
  410. package/types/src/sheet/SheetRanges.d.ts +14 -12
  411. package/types/src/sheet/{Sheet.d.ts → Worksheet.d.ts} +591 -171
  412. package/types/src/sheet/WorksheetCollection.d.ts +39 -0
  413. package/types/src/sheet/_CellBuffer.d.ts +11 -1
  414. package/types/src/sheet/_CopyUtils.d.ts +13 -6
  415. package/types/src/sheet/_IgnoredErrors.d.ts +46 -0
  416. package/types/src/sheet/_InvalidSheetRange.d.ts +3 -2
  417. package/types/src/sheet/_Kinds.d.ts +34 -0
  418. package/types/src/sheet/_Labels.d.ts +38 -0
  419. package/types/src/sheet/_ListenerAnchor.d.ts +7 -1
  420. package/types/src/sheet/_RangeStateSweep.d.ts +2 -3
  421. package/types/src/sheet/_ScalarListFactory.d.ts +55 -7
  422. package/types/src/sheet/_SheetAutoFillUtils.d.ts +3 -3
  423. package/types/src/sheet/_SheetAutoFitUtils.d.ts +3 -3
  424. package/types/src/sheet/_SheetChangeEvent.d.ts +72 -0
  425. package/types/src/sheet/_SheetCoords.d.ts +3 -3
  426. package/types/src/sheet/_SheetEvents.d.ts +1 -1
  427. package/types/src/sheet/_SheetFilterUtils.d.ts +6 -6
  428. package/types/src/sheet/_SheetIntents.d.ts +32 -14
  429. package/types/src/sheet/_SheetMessages.d.ts +1 -1
  430. package/types/src/sheet/_SheetMutations.d.ts +11 -9
  431. package/types/src/sheet/_SheetSortUtils.d.ts +2 -2
  432. package/types/src/sheet/_SheetStateReader.d.ts +18 -0
  433. package/types/src/sheet/_SheetStateTypes.d.ts +80 -9
  434. package/types/src/sheet/_SheetUtils.d.ts +20 -19
  435. package/types/src/sheet/_WatchAnchor.d.ts +15 -2
  436. package/types/src/sheet/clipboard/RangeClipboardItems.d.ts +4 -4
  437. package/types/src/sheet/clipboard/SheetHTMLTableParser.d.ts +3 -3
  438. package/types/src/sheet/clipboard/SheetHTMLTableWriter.d.ts +3 -3
  439. package/types/src/sheet/index.d.ts +5 -2
  440. package/types/src/sheet/style/SheetCellStyle.d.ts +67 -86
  441. package/types/src/sheet/style/SheetDirectStyle.d.ts +3 -3
  442. package/types/src/sheet/style/SheetNamedStyle.d.ts +2 -0
  443. package/types/src/sheet/style/_DigitWidth.d.ts +7 -0
  444. package/types/src/sheet/style/_Resolvers.d.ts +3 -2
  445. package/types/src/sheet/style/_StyleUtils.d.ts +7 -43
  446. package/types/src/sheetHeader/ISheetHeader.d.ts +2 -2
  447. package/types/src/sheetHeader/SheetCellHeader.d.ts +2 -0
  448. package/types/src/sheetHeader/SheetCellHeaderRange.d.ts +2 -0
  449. package/types/src/sheetHeader/SheetCellHeaderRanges.d.ts +2 -0
  450. package/types/src/sheetHeader/SheetHeader.d.ts +7 -6
  451. package/types/src/sheetHeader/_HeaderUtils.d.ts +2 -3
  452. package/types/src/sheetProtection/{ISheetProtection.d.ts → IWorksheetProtection.d.ts} +28 -28
  453. package/types/src/sheetProtection/WorksheetProtection.d.ts +51 -0
  454. package/types/src/sheetProtection/index.d.ts +1 -1
  455. package/types/src/sheetView/{ISheetView.d.ts → IWorksheetView.d.ts} +168 -61
  456. package/types/src/sheetView/WorksheetView.d.ts +139 -0
  457. package/types/src/sheetView/_SheetViewUtils.d.ts +5 -3
  458. package/types/src/sheetView/index.d.ts +1 -1
  459. package/types/src/slicer/ISlicer.d.ts +2 -2
  460. package/types/src/sort/ISort.d.ts +35 -5
  461. package/types/src/style/ICellStyle.d.ts +56 -44
  462. package/types/src/style/_BuiltInStyleDefs.d.ts +4 -3
  463. package/types/src/table/AnchoredTable.d.ts +23 -7
  464. package/types/src/table/AutoTable.d.ts +1 -1
  465. package/types/src/table/ITable.d.ts +32 -19
  466. package/types/src/table/_NamedTable.d.ts +3 -3
  467. package/types/src/table/_NamedTableSource.d.ts +2 -2
  468. package/types/src/text/IText.d.ts +4 -51
  469. package/types/src/text/TextEngine.d.ts +34 -0
  470. package/types/src/text/TextFrame.d.ts +4 -2
  471. package/types/src/text/TextRun.d.ts +3 -2
  472. package/types/src/text/TextWrapper.d.ts +32 -26
  473. package/types/src/text/_TextUtils.d.ts +5 -5
  474. package/types/src/text/_TextWrapperFallback.d.ts +49 -0
  475. package/types/src/text/impl/TabStrategy.d.ts +3 -1
  476. package/types/src/text/richtext/IRichText.d.ts +16 -2
  477. package/types/src/text/richtext/index.d.ts +0 -1
  478. package/types/src/theme/ITheme.d.ts +108 -7
  479. package/types/src/theme/ThemeCollection.d.ts +5 -0
  480. package/types/src/theme/_OfficeFontScheme.d.ts +8 -0
  481. package/types/src/transaction/ITransaction.d.ts +20 -1
  482. package/types/src/transaction/Transaction.d.ts +8 -1
  483. package/types/src/transaction/_BatchHandle.d.ts +118 -0
  484. package/types/src/type/AbstractCollection.d.ts +4 -13
  485. package/types/src/type/ICollection.d.ts +17 -4
  486. package/types/src/type/IProperties.d.ts +1 -1
  487. package/types/src/utils/_CSSUtils.d.ts +1 -1
  488. package/types/src/wasm/_fontsWasm.d.ts +7 -0
  489. package/types/src/wasm/_sdkWasm.d.ts +1 -1
  490. package/types/src/wasm/fontsWasm.d.ts +32 -0
  491. package/types/src/wasm/index.d.ts +1 -0
  492. package/types/src/wasm/loader.browser.d.ts +9 -0
  493. package/types/src/wasm/loader.node.d.ts +9 -0
  494. package/types/src/wasm/sdkWasm.d.ts +6 -3
  495. package/types/src/workbook/IWorkbook.d.ts +269 -39
  496. package/types/src/workbook/Workbook.d.ts +102 -25
  497. package/types/src/workbook/WorkbookRange.d.ts +2 -2
  498. package/types/src/workbook/WorkbookRanges.d.ts +3 -3
  499. package/types/src/workbook/_WorkbookIntents.d.ts +2 -2
  500. package/types/src/workbook/_WorkbookMessages.d.ts +5 -0
  501. package/types/src/workbookView/IWorkbookView.d.ts +82 -0
  502. package/types/src/workbookView/WorkbookView.d.ts +21 -0
  503. package/browser/esm/BbSmt62FpFIpoVzu.mjs +0 -392
  504. package/browser/esm/BgcZ-CoTbMfmyDJL.mjs +0 -412
  505. package/browser/esm/DOMHmhYzPcLVcpAW.mjs +0 -7
  506. package/browser/esm/DUvUK61b2_4pf4tG.mjs +0 -484
  507. package/node/esm/CCouEwT37f08qO3V.mjs +0 -7
  508. package/node/esm/CImNvdz1iP-lUlro.mjs +0 -610
  509. package/node/esm/CT0CN82y0_Qgoryk.mjs +0 -7568
  510. package/node/esm/DHUADiCmxNQS1ARz.mjs +0 -417
  511. package/node/esm/Ds0d8zXzmgOu3MGx.mjs +0 -403
  512. package/types/src/chart/_ChartXml.d.ts +0 -70
  513. package/types/src/collections/OverlappingRangeIterator.d.ts +0 -87
  514. package/types/src/collections/_RangeSweep.d.ts +0 -97
  515. package/types/src/font/CanvasFontMeasurer.d.ts +0 -25
  516. package/types/src/font/FontKitFontMeasurer.d.ts +0 -11
  517. package/types/src/font/SimpleFontMeasurer.d.ts +0 -4
  518. package/types/src/print/IPrint.d.ts +0 -212
  519. package/types/src/sheet/SheetCollection.d.ts +0 -29
  520. package/types/src/sheetProtection/SheetProtection.d.ts +0 -51
  521. package/types/src/sheetView/SheetView.d.ts +0 -122
  522. package/types/src/text/richtext/IStyledFont.d.ts +0 -330
@@ -0,0 +1,1521 @@
1
+ import { Scalar, IRange, IRangeStats, IRichType, IRuntime } from '@sheetxl/primitives';
2
+ import { Bounds, Size } from '@sheetxl/utils';
3
+ import { ITypes } from '../type';
4
+ import { ITransaction } from '../transaction';
5
+ import { Tuple } from '../collections';
6
+ import { IWorkbook } from '../workbook';
7
+ import { IPageLayout } from '../print';
8
+ import { IColor } from '../color';
9
+ import { IListener } from '../listener';
10
+ import { IHyperlink } from '../hyperlink';
11
+ import { IPicture } from '../picture';
12
+ import { ICell, ICellHeader } from '../cell';
13
+ import { ICellRange, ICellRanges, ICellRegions } from '../cellRange';
14
+ import { IRangeSelection } from '../selection';
15
+ import { IStyleCollection } from '../style';
16
+ import { IStringCollection } from '../string';
17
+ import { IRichDataCollection } from '../richData';
18
+ import { IResource, IResourceCollection } from '../resource';
19
+ import { IMovable, IMovableCollection } from '../movable';
20
+ import { IPivotTable, IPivotTableCollection } from '../pivot';
21
+ import { IComment, ICommentCollection } from '../comment';
22
+ import { ITable, ITableCollection } from '../table';
23
+ import { IDataValidation, IDataValidationCollection } from '../dataValidation';
24
+ import { IConditionalFormat, IConditionalFormatCollection } from '../conditionalFormat';
25
+ import { IProtectedRange, IProtectedRangeCollection } from '../protectedRange';
26
+ import { ICellControl, ICellControlCollection } from '../cellControl';
27
+ import { IModule, IModuleCollection } from '../scripting';
28
+ import { IChartCollection } from '../chart';
29
+ import { INamedCollection } from '../named';
30
+ import { ICalculation } from '../calculation';
31
+ import { IWorksheetView } from '../sheetView';
32
+ import { ISheetHeader } from '../sheetHeader';
33
+ import { IWorksheetProtection } from '../sheetProtection';
34
+ import { IOutline } from '../outline';
35
+ import { ICellContainerOptions } from './ICellContainerOptions';
36
+ import { ISheet } from './ISheet';
37
+ /**
38
+ * An `IWorksheet` represents a collection of elements (such as {@link ICellRange | ranges},
39
+ * {@link ITable | tables}, etc) contained within and visualized through a {@link IWorksheetView | view}.
40
+ *
41
+ * This interface provides methods for accessing its elements and event handling.
42
+ *
43
+ * Most interactions with a {@link IWorksheet | sheet} are done using either a {@link ICellRange | range} or {@link ICellRanges | ranges}.
44
+ *
45
+ * @remarks
46
+ * While a {@link IWorksheet | sheet} can be used stand-alone it is typically used within the context of a {@link IWorkbook | workbook}.
47
+ *
48
+ * ### **Key Methods**
49
+ *
50
+ * * {@link IWorksheet.getRange} - For interacting with {@link ICell | cells} and {@link Scalar | values} and formatting.
51
+ * * {@link IWorksheet.getTables} - For managing {@link ITable | tables}.
52
+ * * {@link IWorksheet.getView} - For non-data related properties such as selection or frozen headers.
53
+ * * {@link IWorkbook} - For working with collections of `ISheets`.
54
+ */
55
+ export interface IWorksheet extends ISheet, ITransaction.ITransactional, IListener.ISource<IWorksheet, IWorksheet.IListeners> {
56
+ /**
57
+ * Always `'worksheet'`.
58
+ *
59
+ * @see {@link ISheet.getKind}
60
+ */
61
+ getKind(): typeof ISheet.Kind.Worksheet;
62
+ /**
63
+ * Returns an {@link ICellRange} used to interact with a
64
+ * a rectangular 2D collection of cells at a specific range.
65
+ *
66
+ * @param address Address of the ranges. Omit for the selected range — selection is modeled
67
+ * by the SDK (not a UI mode), and many operations default to it. `getSelectedRange` remains
68
+ * the explicit form.
69
+ * @param options Options for the ranges.
70
+ */
71
+ getRange(address?: ICellRange.Address, options?: ICellRange.GetRangeOptions): ICellRange;
72
+ /**
73
+ * Returns a {@link ICell} at the specified address.
74
+ *
75
+ * @param address Address of the cell. Omit for the selected cell — selection is modeled
76
+ * by the SDK (not a UI mode), and many operations default to it. `getSelectedCell` remains
77
+ * the explicit form.
78
+ */
79
+ getCell(address?: ICell.Address): ICell;
80
+ /**
81
+ * Returns an {@link ICellRanges}. An {@link ICellRanges} is an ordered list of
82
+ * {@link ICellRange}s. These are used to interact with a set of contiguous 2D ranges.
83
+ *
84
+ * @param address Address of the ranges.
85
+ * @param options Options for the ranges.
86
+ */
87
+ getRanges(address: ICellRanges.Address, options?: ICellRange.GetRangeOptions): ICellRanges;
88
+ /**
89
+ * Returns the range for the entire sheet.
90
+ *
91
+ * @remarks
92
+ * This can be updated via {@link IWorksheet.setEntireSize}.
93
+ *
94
+ * @see
95
+ * {@link ICellRange}
96
+ */
97
+ getEntireRange(options?: ICellRange.GetRangeOptions): ICellRange;
98
+ /**
99
+ * Returns the coords for the entire sheet.
100
+ *
101
+ * @remarks
102
+ * This is a lightweight call to `IWorksheet.getEntireRange().getCoords()`.
103
+ */
104
+ getEntireCoords(): IRange.Coords;
105
+ /**
106
+ * Returns the smallest range within the sheet that contains any used cells.
107
+ *
108
+ * @see
109
+ * {@link ICellRange.getUsedRange}
110
+ */
111
+ getUsedRange(options?: ICellRange.GetRangeOptions): ICellRange | null;
112
+ /**
113
+ * Returns the statistics for the used cells of the sheet.
114
+ *
115
+ * @param options Iterator options the stats are created with — most usefully
116
+ * `{ onError: 'ignore' }` so aggregate reads degrade instead of faulting on error values.
117
+ *
118
+ * @remarks
119
+ * Equivalent to `getUsedRange().getStats(…)` except **null-safe** — an empty sheet returns
120
+ * empty statistics (`getSize() === 0`) rather than forcing the caller to branch on
121
+ * {@link getUsedRange} returning `null`.
122
+ *
123
+ * @see
124
+ * {@link ICellRange.getStats}
125
+ */
126
+ getStats(options?: ICellRange.GetStatsOptions): IRangeStats;
127
+ /**
128
+ * Returns the uniform regions for the requested features across the whole sheet.
129
+ *
130
+ * @remarks
131
+ * The partition operator belongs on the thing partitioned, and *"where are the blocks in this
132
+ * sheet"* is the question an agent actually has — the `ICellRange` flavor is how you
133
+ * **constrain** that query, not how you start it.
134
+ *
135
+ * Equivalent to `getEntireRange().getRegions(…)`: the partition reads the feature indexes, so
136
+ * it costs the used cells rather than the address space.
137
+ * @see
138
+ * {@link ICellRange.getRegions}
139
+ */
140
+ getRegions(features?: ICellRange.Feature | readonly ICellRange.Feature[], options?: ICellRange.GetRegionsOptions): ICellRegions;
141
+ /**
142
+ * Returns the regions of the `anomalies` feature across the whole sheet, in reading order.
143
+ *
144
+ * @example
145
+ * ```ts
146
+ * sheet.getAnomalies({ checks: ['hardcodeInRun', 'styleRole'], limit: 25 });
147
+ * ```
148
+ *
149
+ * @remarks
150
+ * Equivalent to `getEntireRange().getAnomalies(…)`.
151
+ * @see
152
+ * {@link ICellRange.getAnomalies}
153
+ */
154
+ getAnomalies(options?: ICellRange.GetAnomaliesOptions): ICellRegions;
155
+ /**
156
+ * Returns the current selection.
157
+ *
158
+ * @remarks
159
+ * This allows for listening to selection changes and advanced navigation.
160
+ */
161
+ getSelection(): IRangeSelection;
162
+ /**
163
+ * Returns the selected cell.
164
+ *
165
+ * @remarks
166
+ * This is a convenience method for 'getSelection().getCell()'.
167
+ */
168
+ getSelectedCell(): ICell;
169
+ /**
170
+ * Returns a range of cells for the current selection.
171
+ *
172
+ * @remarks
173
+ * This is a convenience method for 'getSelection().getRange()'.
174
+ */
175
+ getSelectedRange(options?: ICellRange.GetRangeOptions): ICellRange;
176
+ /**
177
+ * Returns ranges of cells for the current selection.
178
+ *
179
+ * @remarks
180
+ * This is a convenience method for 'getSelection().getRanges()'.
181
+ */
182
+ getSelectedRanges(options?: ICellRange.GetRangeOptions): ICellRanges;
183
+ /**
184
+ * Returns an iterator of ICells that match the results.
185
+ *
186
+ * @param options This is either a search string or {@link ICellRange.FindOptions}.
187
+ *
188
+ * @remarks
189
+ * This is the equivalent of `getEntireRange().find`.
190
+ * @see
191
+ * {@link ICellRange.find}
192
+ */
193
+ find(options: string | ICellRange.FindOptions): Iterator<ICell>;
194
+ /**
195
+ * Creates a 'light' table used for stateful filtering and sorting with-in a sheet.
196
+ *
197
+ * @see {@link ITable}
198
+ */
199
+ addAutoTable(address?: ICellRange, options?: ICellRange.AddAutoTableOptions): ITable;
200
+ /**
201
+ * Returns the {@link ITable} created using {@link addAutoTable}.
202
+ */
203
+ getAutoTable(): ITable | null;
204
+ /**
205
+ * Returns a collection of tables that are embedded in this sheet.
206
+ */
207
+ getTables(): ITableCollection;
208
+ /**
209
+ * Returns a collection of validations that are embedded in this sheet.
210
+ */
211
+ getDataValidations(): IDataValidationCollection;
212
+ /**
213
+ * Returns a collection of conditional formats that are embedded in this sheet.
214
+ */
215
+ getConditionalFormats(): IConditionalFormatCollection;
216
+ /**
217
+ * Returns a collection of ranges that stay editable while this sheet is protected.
218
+ *
219
+ * @remarks
220
+ * Excel's *Review → Allow Edit Ranges*. Only consulted while
221
+ * {@link IWorksheetProtection.isLocked} is true.
222
+ */
223
+ getProtectedRanges(): IProtectedRangeCollection;
224
+ /**
225
+ * Returns the cell controls on this sheet, such as checkboxes.
226
+ *
227
+ * @remarks
228
+ * Every entry, in drawing order. To put a control on cells or read what is there, use
229
+ * {@link ICellRange.setControl} and {@link ICellRange.getControls}.
230
+ */
231
+ getCellControls(): ICellControlCollection;
232
+ /**
233
+ * Returns the comments and notes on this sheet.
234
+ *
235
+ * @remarks
236
+ * One per cell. The workbook's {@link IWorkbook.getComments} walks every sheet's.
237
+ */
238
+ getComments(): ICommentCollection;
239
+ /**
240
+ * Returns a collection of movables that are embedded in this sheet.
241
+ */
242
+ getMovables(): IMovableCollection;
243
+ /**
244
+ * Returns the charts on this sheet.
245
+ *
246
+ * @remarks
247
+ * A view over {@link IWorksheet.getMovables}: every chart is the content of a movable, which is what
248
+ * places and names it. Read-only for now — a chart is added by adding a movable with chart
249
+ * content.
250
+ */
251
+ getCharts(): IChartCollection;
252
+ /**
253
+ * Returns the row headers managed by the sheet.
254
+ */
255
+ getRowHeaders(): ISheetHeader;
256
+ /**
257
+ * Returns the column headers managed by the sheet.
258
+ */
259
+ getColumnHeaders(): ISheetHeader;
260
+ /**
261
+ * Return a custom color or `null` if no custom color has been set.
262
+ *
263
+ * @defaultValue null
264
+ */
265
+ getTabColor(): IColor;
266
+ /**
267
+ * See the tab color for the sheet.
268
+ *
269
+ * @param color The color
270
+ *
271
+ * @remarks
272
+ * * If set to `null` the color will revert to the default.
273
+ * * The tab color is not used by the sheet but rather by the workbook.
274
+ */
275
+ setTabColor(color: IColor | string | null): this;
276
+ /**
277
+ * The sheet's VBA code name, or `null` if it has none.
278
+ *
279
+ * @defaultValue null
280
+ *
281
+ * @remarks
282
+ * The identifier VBA binds a sheet through — `Sheet1.Range("A1")` in a macro resolves by code
283
+ * name, never by tab name. It is a **second, independent identity** for the sheet: renaming the
284
+ * tab does not change it, and it is not the sheet's position. Excel's default happens to look
285
+ * positional (`Sheet1`, `Sheet2`, …) but drifts from position the moment sheets are reordered,
286
+ * inserted or deleted, so it can only be carried — never derived.
287
+ *
288
+ * Present on any workbook that has, or has ever had, a VBA project: it survives the project
289
+ * being stripped, so an `.xlsx` saved down from an `.xlsm` still carries code names. A workbook
290
+ * that never had one has none, and this is `null` throughout.
291
+ *
292
+ * **Read-only.** SheetXL preserves what a file declared and never mints one — a code name is
293
+ * assigned by the VBA editor, and inventing one would create a binding target no macro refers
294
+ * to. There is deliberately no `setCodeName`.
295
+ */
296
+ getCodeName(): string | null;
297
+ /**
298
+ * The row and column groups on this sheet, and how they are laid out.
299
+ */
300
+ getOutline(): IOutline;
301
+ /**
302
+ * How the sheet is laid out on printed pages: paper, orientation, scale, margins, headers and
303
+ * footers, the print area and the rows and columns repeated on every page.
304
+ *
305
+ * @remarks
306
+ * The counterpart of Office Scripts' `Worksheet.getPageLayout`. The manual page breaks are part
307
+ * of it ({@link IPageLayout.getHorizontalPageBreaks}).
308
+ */
309
+ getPageLayout(): IPageLayout;
310
+ /**
311
+ * The manual page breaks before rows, in order. The same as
312
+ * `getPageLayout().getHorizontalPageBreaks()`.
313
+ *
314
+ * @remarks
315
+ * The counterpart of Office Scripts' `Worksheet.getHorizontalPageBreaks`.
316
+ */
317
+ getHorizontalPageBreaks(): IPageLayout.IPageBreak[];
318
+ /**
319
+ * The manual page breaks before columns, in order. The same as
320
+ * `getPageLayout().getVerticalPageBreaks()`.
321
+ */
322
+ getVerticalPageBreaks(): IPageLayout.IPageBreak[];
323
+ /**
324
+ * Adds a page break before the top row of the range. The same as
325
+ * `getPageLayout().addHorizontalPageBreak()`.
326
+ *
327
+ * @throws `Error` If the range starts on the first row, which no break can sit before.
328
+ */
329
+ addHorizontalPageBreak(pageBreakRange: ICellRange.Address, options?: ITransaction.OperationOptions): IPageLayout.IPageBreak;
330
+ /**
331
+ * Adds a page break before the left column of the range. The same as
332
+ * `getPageLayout().addVerticalPageBreak()`.
333
+ *
334
+ * @throws `Error` If the range starts on the first column, which no break can sit before.
335
+ */
336
+ addVerticalPageBreak(pageBreakRange: ICellRange.Address, options?: ITransaction.OperationOptions): IPageLayout.IPageBreak;
337
+ /**
338
+ * Removes every page break before a row. The same as
339
+ * `getPageLayout().removeAllHorizontalPageBreaks()`.
340
+ */
341
+ removeAllHorizontalPageBreaks(options?: ITransaction.OperationOptions): void;
342
+ /**
343
+ * Removes every page break before a column. The same as
344
+ * `getPageLayout().removeAllVerticalPageBreaks()`.
345
+ */
346
+ removeAllVerticalPageBreaks(options?: ITransaction.OperationOptions): void;
347
+ /**
348
+ * Whether conditional formats on this sheet are recalculated as the sheet changes.
349
+ *
350
+ * @defaultValue true
351
+ *
352
+ * @remarks
353
+ * Excel exposes this only to VBA (`Worksheet.EnableFormatConditionsCalculation`). It is carried
354
+ * so a workbook that turned it off keeps it off when saved; SheetXL still evaluates conditional
355
+ * formats either way.
356
+ */
357
+ isConditionalFormatCalculationEnabled(): boolean;
358
+ /**
359
+ * Whether formulas on this sheet are evaluated by Lotus 1-2-3 rules ("Transition formula
360
+ * evaluation" in Excel's Lotus compatibility settings).
361
+ *
362
+ * @defaultValue false
363
+ *
364
+ * @remarks
365
+ * VBA's `Worksheet.TransitionExpEval`. Carried so a workbook that set it keeps it when saved;
366
+ * SheetXL evaluates by Excel's rules either way.
367
+ */
368
+ isTransitionFormulaEvaluation(): boolean;
369
+ /**
370
+ * Whether formulas on this sheet are entered by Lotus 1-2-3 rules ("Transition formula entry" in
371
+ * Excel's Lotus compatibility settings).
372
+ *
373
+ * @defaultValue false
374
+ *
375
+ * @remarks
376
+ * VBA's `Worksheet.TransitionFormEntry`. Carried so a workbook that set it keeps it when saved;
377
+ * SheetXL parses formulas by Excel's rules either way.
378
+ */
379
+ isTransitionFormulaEntry(): boolean;
380
+ /**
381
+ * Whether this sheet is left out when the workbook is published (to SharePoint Excel Services).
382
+ *
383
+ * @defaultValue false
384
+ *
385
+ * @remarks
386
+ * The file's `sheetPr/@published="0"`. Carried, not acted on.
387
+ */
388
+ isExcludedFromPublishing(): boolean;
389
+ /**
390
+ * The sheet's synchronized scrolling, or `null` when it has none.
391
+ *
392
+ * @remarks
393
+ * The file's `sheetPr` `syncHorizontal`, `syncVertical` and `syncRef`. Carried, not acted on: the
394
+ * anchor is kept as written and does not move with inserts or deletes.
395
+ */
396
+ getSyncScroll(): IWorksheet.SyncScroll | null;
397
+ /**
398
+ * Returns the modules this sheet owns.
399
+ *
400
+ * @remarks
401
+ * A sheet's modules are stored by the sheet rather than tagged with its name, so the state a
402
+ * tag would allow — a module left behind pointing at a sheet that no longer exists — cannot
403
+ * occur: delete the sheet and its modules go with it, which is also what Excel does.
404
+ *
405
+ * These modules are scoped to the sheet ({@link IModule.getScope}), and scope is a visibility
406
+ * rule: a function declared here is **not** callable from a cell formula, on this sheet or any
407
+ * other. Only globally scoped modules contribute to the formula namespace.
408
+ *
409
+ * The VBA document module for this sheet lands here, joined to it by
410
+ * {@link IWorksheet.getCodeName} — for a document module the module name *is* the code name.
411
+ *
412
+ * As with {@link IWorkbook.getScripts}, the collection filters to TypeScript unless asked
413
+ * otherwise; imported VBA is read with `getItems({ language: 'vba' })`.
414
+ */
415
+ getModules(): IModuleCollection;
416
+ /**
417
+ * Returns the sheet protection.
418
+ */
419
+ getProtection(): IWorksheetProtection;
420
+ /**
421
+ * Returns the current view settings
422
+ * View settings determine how the sheet is displayed and interacted with (e.g., frozen panes, zoom level, selection) but do not affect the underlying data itself.
423
+ *
424
+ * @returns The {@link IWorksheetView} object representing the current view settings.
425
+ */
426
+ getView(): IWorksheetView;
427
+ /**
428
+ * Set a specific view.
429
+ *
430
+ * @param view The view properties.
431
+ */
432
+ setView(view: IWorksheetView): this;
433
+ /**
434
+ * Returns `IStyleCollection` associated with this sheet.
435
+ */
436
+ getStyles(): IStyleCollection;
437
+ /**
438
+ * Returns the current shared resources.
439
+ */
440
+ getResources(): IResourceCollection;
441
+ /**
442
+ * Returns the current shared resources.
443
+ */
444
+ getStrings(): IStringCollection;
445
+ /**
446
+ * Returns the current shared resources.
447
+ */
448
+ getTransactions(): ITransaction.IStore;
449
+ /**
450
+ * Performs a set of operations as one: one commit, one undo step, one round of events.
451
+ *
452
+ * @param callback Performs the operations. Handed the commit being written and `sheet`, this
453
+ * sheet bound to the batch.
454
+ * @param options Description of the operation or additional options. Used for undo/redo and
455
+ * history.
456
+ *
457
+ * @remarks
458
+ * Work through `sheet` rather than this one: what is reached through it is part of the batch, as
459
+ * for {@link IWorkbook.doBatch}.
460
+ */
461
+ doBatch<R = any>(callback: (commit: ITransaction.ICommit, sheet: this) => R | Promise<R>, options?: string | ITransaction.OperationOptions): R | Promise<R>;
462
+ /**
463
+ * Returns the runtime used for this sheet.
464
+ *
465
+ * @remarks
466
+ * This can not be set on the `IWorksheet`. This is managed by the sheet's container.
467
+ */
468
+ getRuntime(): IRuntime;
469
+ /**
470
+ * Returns the column width as a font unit.
471
+ *
472
+ * This is used as an informative tooltip.
473
+ *
474
+ * @param pixelWidth
475
+ *
476
+ * @see
477
+ * * {@link https://docs.microsoft.com/en-us/office/troubleshoot/excel/determine-column-widths}
478
+ * * {@link https://www.ablebits.com/office-addins-blog/change-autofit-column-width-excel/}
479
+ */
480
+ getColumnWidthAsFontUnit(pixelWidth: number): number;
481
+ /**
482
+ * Returns the {@link ICellRange | range} for a given pixel bounds.
483
+ *
484
+ * @param bounds
485
+ */
486
+ getRangeAtBounds(bounds: Bounds, options?: ICellRange.GetRangeOptions): ICellRange;
487
+ /**
488
+ * Returns a 1×1 cell or an explicit range at the specified **absolute** sheet coordinates.
489
+ *
490
+ * @see {@link ICellRange.getRangeAt} for relative coordinates.
491
+ */
492
+ getRangeAt(rowStart: number, columnStart: number, rowEnd?: number, columnEnd?: number, options?: ICellRange.GetRangeOptions): ICellRange;
493
+ /**
494
+ * Creates a cell that is not including at a coordinate but adopts all rendering.
495
+ *
496
+ * @param update Cell Update
497
+ * @param coords Optional CellCoord
498
+ * @param options How the update is read. See {@link ICell.CreateCellOptions}.
499
+ * @returns A detached ICell
500
+ *
501
+ * @remarks
502
+ * * Useful for previewing values such as tooltip, or what typed text would be entered as.
503
+ * * Does not add to the sheet but provides a standalone ICell.
504
+ * * If the coords are passed it will return disconnect cell update for that value.
505
+ */
506
+ createCell(update: ICell.Update, coords?: IRange.FixableCellCoords, options?: ICell.CreateCellOptions): ICell;
507
+ /**
508
+ * Parses a formula expression and returns a *transient* formula object anchored to this sheet.
509
+ *
510
+ * @param expression The formula expression to parse.
511
+ * @param coords Optional anchor coordinates.
512
+ * @param options Optional parse options; the expression is storage text unless `target` is `'display'`.
513
+ *
514
+ * @remarks
515
+ * This is a convenience method for `getCalculation().createFormula(expression, coords, options)`;
516
+ * like everything reached through the sheet's {@link getCalculation}, a bare reference (`A2`)
517
+ * resolves against THIS sheet rather than the selected one.
518
+ *
519
+ * @see {@link ICalculation.createFormula}
520
+ */
521
+ createFormula(expression: string, coords?: Partial<IRange.CellCoords>, options?: ICalculation.CreateFormulaOptions): ICalculation.IFormula;
522
+ /**
523
+ * Add Listeners.
524
+ *
525
+ * @see
526
+ * {@link IListener.ISource.addListeners}
527
+ */
528
+ addListeners(listeners: IWorksheet.IListeners, options?: IListener.Options): IListener.Remove;
529
+ /**
530
+ * Returns the display name for the sheet.
531
+ */
532
+ getName(): string;
533
+ /**
534
+ * Set the display name for the sheet.
535
+ */
536
+ setName(name: string, options?: ITransaction.OperationOptions): this;
537
+ /**
538
+ * Returns the visibility of the sheet.
539
+ */
540
+ getVisibility(): ISheet.Visibility;
541
+ /**
542
+ * Change the visibility of the sheet.
543
+ *
544
+ * @defaultValue ISheet.Visibility.Visible
545
+ */
546
+ setVisibility(visibility?: ISheet.Visibility | boolean, options?: ITransaction.OperationOptions): IWorksheet;
547
+ /**
548
+ * The {@link INamed}s **visible from this sheet** — what a formula written here can refer to.
549
+ *
550
+ * @remarks
551
+ * The global items (every table among them, since a table name is always global) plus this sheet's
552
+ * own scoped names, with shadowing resolved: where a sheet-scoped name and a global share a name,
553
+ * only this sheet's is returned, because that is the one a formula here resolves to. Another
554
+ * sheet's scoped names are never included.
555
+ *
556
+ * Everything is anchored to THIS sheet, not the selected one: `getByName` resolves against it, and
557
+ * `getByRanges` reads unqualified coords as being on it — which is what lets this sheet's own
558
+ * selection be passed straight in.
559
+ *
560
+ * Use {@link IWorkbook.getNames} for every name in the workbook (a name manager), and
561
+ * {@link IWorksheet.getTables} for the tables that LIVE on this sheet — scope here is visibility, never
562
+ * location, so a table anchored to another sheet is still visible from this one.
563
+ */
564
+ getNames(): INamedCollection;
565
+ /**
566
+ * Returns the {@link ICalculation} **anchored to this sheet**.
567
+ *
568
+ * @remarks
569
+ * The engine itself is workbook-wide; this is a view over it that supplies THIS sheet as the context
570
+ * whenever a caller doesn't name one. So an expression parsed or evaluated through it resolves a bare
571
+ * reference (`A2`) against this sheet — not against whichever sheet happens to be selected.
572
+ *
573
+ * That matters for anything anchored by coords alone, e.g.
574
+ * `sheet.getCalculation().createFormula('=A2+B2', cell.getCoords())`: reached through the
575
+ * workbook ({@link IWorkbook.getCalculation}) the same call has no sheet context and falls back to the
576
+ * active cell's sheet, which makes the parse depend on UI selection state. Pass an explicit
577
+ * `coords.scope` to override the anchor (a cross-sheet reference is unaffected either way — it names its
578
+ * own sheet).
579
+ */
580
+ getCalculation(): ICalculation;
581
+ /**
582
+ * Recalculates THIS sheet — Excel's "Calculate Sheet" (Shift+F9) / `Worksheet.Calculate`.
583
+ *
584
+ * @param full When `true`, recalculate every formula on the sheet. Otherwise only the ones whose
585
+ * inputs changed (plus volatiles), which is what Excel's Shift+F9 does.
586
+ *
587
+ * @remarks
588
+ * Distinct from `getEntireRange().calculate(full)`, which marks the range dirty first and is
589
+ * therefore always a FORCE for those cells. This is the dirty-respecting sheet-scoped pass.
590
+ *
591
+ * Only the SEED is scoped to this sheet: dependents on other sheets still recalculate, and
592
+ * volatiles are still workbook-wide. Excel leaves both stale; being more current is the safe
593
+ * direction, and the volatile registry is drained per pass, so skipping them would deregister
594
+ * them outright.
595
+ */
596
+ calculate(full?: boolean): Promise<ICalculation.Status>;
597
+ /**
598
+ * Evaluates a formula in the context of the sheet and returns the resulting value.
599
+ *
600
+ * @param formula The formula to evaluate.
601
+ * @param options Optional evaluation options.
602
+ *
603
+ * @remarks
604
+ * This is similar convenience method for `getCalculation().createFormula(expression).evaluate(options)`.
605
+ */
606
+ evaluate(formula: string, options?: ICalculation.EvaluateOptions & Partial<IRange.CellCoords> & ICalculation.CreateFormulaOptions): Promise<Scalar | IRange>;
607
+ /**
608
+ * Returns when all calculations are complete and there are no pending calculations.
609
+ *
610
+ * @remarks
611
+ * * Also waits for the load-time start: the pass {@link ICellContainerOptions.calcOnLoad} asks
612
+ * for. This is the settle point after constructing from JSON.
613
+ * * Otherwise a convenience method for `getCalculation().ready()`, which starts the engine if
614
+ * it has not been started.
615
+ */
616
+ whenCalculationReady(): Promise<ICalculation.Status>;
617
+ /**
618
+ * Returns the {@link IWorkbook} for the sheet.
619
+ *
620
+ * @remarks
621
+ * This may be `null` if not created via a workbook.
622
+ */
623
+ getWorkbook(): IWorkbook | null;
624
+ /**
625
+ * Removes from a container. This is usually the `Workbook`. If this is being
626
+ * used standalone this operation will throw an exception.
627
+ */
628
+ delete(): void;
629
+ /**
630
+ * Returns if the sheet has been deleted from its container.
631
+ */
632
+ isDeleted(): boolean;
633
+ /**
634
+ * Select the `IWorksheet`.
635
+ */
636
+ select(options?: ITypes.SelectOptions): Promise<this>;
637
+ /**
638
+ * Attempt to scroll the range into view.
639
+ *
640
+ * @param coords The partial coords to scroll to.
641
+ * @param options {@link IWorksheet.ScrollToOptions}.
642
+ */
643
+ scrollTo(coords: Partial<IRange.Coords>, options: IWorksheet.ScrollToOptions): Promise<boolean>;
644
+ /**
645
+ * Returns a promise that will resolve to a copy of the current sheet.
646
+ */
647
+ duplicate(): Promise<this>;
648
+ /**
649
+ * Returns the current index of the `IWorksheet` within its container.
650
+ *
651
+ * @remarks
652
+ * Will return -1 if not in a Workbook or other sheet container.
653
+ */
654
+ getIndex(): number;
655
+ /**
656
+ * Reorders the `IWorksheet` with in the container. This is generally the tab order within an `IWorkbook` but may
657
+ * be the zIndex if the `ISheets` are movable. This only affects visual listings of the sheets (but selection doesn't change).
658
+ *
659
+ * @remarks
660
+ * This is zero-based.
661
+ */
662
+ setIndex(index: number): this;
663
+ /**
664
+ * Set the entire size of the sheet: where its last column and row are.
665
+ *
666
+ * @param size The number of columns and rows. `'fit'` ends that axis where the sheet's content does,
667
+ * and keeps it there: an insert grows the sheet instead of being refused for pushing content off
668
+ * the end, and a delete shrinks it. A number fixes the axis at that size. An axis left out keeps
669
+ * its size and whether it fits; `null` resets both to the default.
670
+ *
671
+ * @example
672
+ * ```ts
673
+ * sheet.setEntireSize({ width: 4, height: 'fit' }); // columns A:D, rows to the last used row
674
+ * ```
675
+ */
676
+ setEntireSize(size?: Partial<IWorksheet.EntireSize> | null, options?: ITransaction.OperationOptions): this;
677
+ /**
678
+ * Returns the picture interface for the sheet.
679
+ */
680
+ getPicture(): IPicture | null;
681
+ /**
682
+ * Returns the pivot tables laid out on this sheet, in the order they were read.
683
+ *
684
+ * @remarks
685
+ * Read-only for now: each table is carried as it was read and written back unchanged. The
686
+ * workbook's {@link IWorkbook.getPivotTables} walks every sheet's.
687
+ */
688
+ getPivotTables(): IPivotTableCollection;
689
+ /**
690
+ * Set the picture interface for the entire sheet.
691
+ * @param picture The picture interface to set for the sheet, or null to remove it.
692
+ */
693
+ setPicture(picture: string | IResource | IResourceCollection.AddOptions | null, options?: ITransaction.OperationOptions): this;
694
+ /**
695
+ * Returns a JSON representation of the sheet.
696
+ *
697
+ * @param options Options to control the JSON output.
698
+ */
699
+ toJSON(options?: IWorksheet.ToJSONOptions): Promise<IWorksheet.JSON>;
700
+ /**
701
+ * Free all resources associated with the sheet.
702
+ *
703
+ * @remarks
704
+ * * Called by workbooks when the workbook is is closed.
705
+ * * This is different than delete which removes the sheet from the workbook.
706
+ *
707
+ * @see
708
+ * {@link IWorksheet.addListeners} for closeEvent
709
+ */
710
+ close(): void;
711
+ /**
712
+ * Returns true if the sheet has been closed.
713
+ */
714
+ isClosed(): boolean;
715
+ /**
716
+ * For runtime type checking.
717
+ */
718
+ readonly isIWorksheet: true;
719
+ }
720
+ /**
721
+ * {@inheritDoc IWorksheet}
722
+ * @see
723
+ * ### **Interface**
724
+ *
725
+ * {@link IWorksheet}
726
+ *
727
+ * ### **Implementation**
728
+ *
729
+ * {@link Sheet}
730
+ */
731
+ export declare namespace IWorksheet {
732
+ /**
733
+ * The different ways to identify a range within a sheet,
734
+ * supporting both relative and absolute (fixed) addressing.
735
+ *
736
+ * Accepts:
737
+ * - `ICellRange`
738
+ * - A parsable `string` representing a range address (e.g., A1 or $A$1 notation).
739
+ * - A partial `IRange.Coords` object (specifying at least some of the range boundaries),
740
+ * optionally with a `$fixed` flag to indicate absolute addressing.
741
+ * - `ICellRange.Address` (representing a single cell within the sheet),
742
+ * optionally with a `$fixed` flag to indicate absolute addressing.
743
+ *
744
+ * @example
745
+ * ```typescript
746
+ * const address1: Address = "A1:B2"; // Relative addressing (A1 notation)
747
+ * const address2: Address = "$A$1:$B$2"; // Absolute addressing (A1 notation)
748
+ * ```
749
+ */
750
+ type RangeAddress = ICellRange | string | Partial<IRange.FixableCoords> | ICell.Address;
751
+ /**
752
+ * Represents the different ways to identify multiple ranges within a sheet.
753
+ *
754
+ * Accepts:
755
+ * - `ICellRanges`
756
+ * - A parsable `string` containing multiple range addresses separated by commas (e.g., "A1:B2,C3:D4").
757
+ * - An array of `ICellRange.Address` objects, each representing a single range.
758
+ *
759
+ * @example
760
+ * ```typescript
761
+ * const address1: ICellRanges.Address = "A1:B2,C3:D4"; // String with multiple ranges.
762
+ * ```
763
+ * @remarks
764
+ * This extends {@link ICellRange.Address} to support multiple values.
765
+ */
766
+ type RangesAddress = ICellRanges | string | ICellRange.Address | ICellRange.Address[];
767
+ /**
768
+ * Options for scrolling to a specific range.
769
+ */
770
+ interface ScrollToOptions {
771
+ /**
772
+ * The partial coords to scroll to.
773
+ */
774
+ coords?: Partial<IRange.Coords>;
775
+ /**
776
+ * Any pixel offsets
777
+ */
778
+ offsets?: Bounds;
779
+ /**
780
+ * The scrollTo options.
781
+ */
782
+ scroll?: globalThis.ScrollIntoViewOptions | boolean;
783
+ }
784
+ /**
785
+ * The events that carry a {@link ChangeEvent}: what {@link ChangeEvent.getKind} names.
786
+ */
787
+ type ChangeEventKey = 'onDataChange' | 'onStyleChange' | 'onLayoutChange' | 'onMergesChange' | 'onSpillsChange';
788
+ /**
789
+ * What a change event announces: where the change landed and what wrote it.
790
+ *
791
+ * @example
792
+ * ```ts
793
+ * sheet.addListeners({
794
+ * onDataChange(_sheet, event) {
795
+ * if (!event.getCommit()) return; // recalculated, not written
796
+ * console.log(`${event.getCommit()!.getDescription()}: ${event.getRanges()?.toString() ?? 'the sheet'}`);
797
+ * }
798
+ * });
799
+ * ```
800
+ */
801
+ interface ChangeEvent {
802
+ /**
803
+ * The sheet that changed.
804
+ */
805
+ getSheet(): IWorksheet;
806
+ /**
807
+ * The event this is: the listener it is delivered to, and for one read back with
808
+ * {@link IWorkbook.getChanges}, the listener it was delivered to.
809
+ */
810
+ getKind(): IWorksheet.ChangeEventKey;
811
+ /**
812
+ * The ranges that changed, or `null` when the extent is not known and the whole sheet should
813
+ * be treated as changed.
814
+ *
815
+ * @remarks
816
+ * Addresses are as of the change. Read them in the listener; after a later insert or delete
817
+ * they may no longer name the same cells.
818
+ */
819
+ getRanges(): ICellRanges | null;
820
+ /**
821
+ * The commit that wrote the change, or `null` when it was not written: a calculation landing,
822
+ * the engine rewriting a formula's text, or a change announced outside a commit (a table's own
823
+ * style, a cache that has to repaint).
824
+ *
825
+ * @remarks
826
+ * An undo or redo announces the commit it moved to. When one delivery covers several
827
+ * commits, this is the latest.
828
+ */
829
+ getCommit(): ITransaction.ICommit | null;
830
+ /**
831
+ * `true` when the change is an undo. A redo is not an undo: it announces the commit it
832
+ * restored, as the forward commit did.
833
+ */
834
+ isUndo(): boolean;
835
+ /**
836
+ * The commit the change moved from: for a write its parent, for an undo the commit undone.
837
+ * `null` for a derived change, or when there is none.
838
+ */
839
+ getPreviousCommit(): ITransaction.ICommit | null;
840
+ /**
841
+ * The same ranges as they were at {@link getPreviousCommit}: what the change replaced.
842
+ *
843
+ * @remarks
844
+ * Ranges on a detached copy of the sheet, built only when asked for: reading them costs
845
+ * nothing on the write path, and writing to them does not reach the workbook. `null` when
846
+ * there is no previous commit, when the store no longer keeps it, or when the change moved
847
+ * cells (an insert, a delete, a move): the addresses then name different cells before it.
848
+ * {@link getShifts} says how they moved.
849
+ *
850
+ * @example
851
+ * ```ts
852
+ * const replaced = event.getPreviousRanges()?.getCounts(); // what the write overwrote
853
+ * ```
854
+ */
855
+ getPreviousRanges(): ICellRanges | null;
856
+ /**
857
+ * The inserts and deletes of cells the change made on this sheet, in the order they ran.
858
+ * Empty when it moved no cells.
859
+ *
860
+ * @remarks
861
+ * A move of cells is the insert and the delete it is made of. An undo reports the inverse of
862
+ * what it undid, last first: the undo of an insert is a delete.
863
+ *
864
+ * @example
865
+ * ```ts
866
+ * for (const shift of event.getShifts()) {
867
+ * console.log(`${shift.getKind()} ${shift.getAxis()}s: ${shift.getRanges()?.toString()}`);
868
+ * }
869
+ * ```
870
+ */
871
+ getShifts(): readonly IWorksheet.Shift[];
872
+ }
873
+ /**
874
+ * Whether a {@link Shift} opened cells or removed them.
875
+ */
876
+ type ShiftKind = 'insert' | 'delete';
877
+ /**
878
+ * One insert or delete of cells, as {@link ChangeEvent.getShifts} reports it.
879
+ */
880
+ interface Shift {
881
+ /**
882
+ * Whether cells were inserted or deleted.
883
+ */
884
+ getKind(): IWorksheet.ShiftKind;
885
+ /**
886
+ * The axis the neighboring cells moved along: `'row'` moves them down or up, `'column'`
887
+ * right or left.
888
+ */
889
+ getAxis(): IRange.Axis;
890
+ /**
891
+ * The cells inserted or deleted, read where they exist: an insert's on the sheet, a
892
+ * delete's on a detached copy of the sheet as it was before the change.
893
+ *
894
+ * @remarks
895
+ * `null` for a delete when the store no longer keeps the state before it. When one change
896
+ * makes several shifts, each one's addresses are as that shift found the sheet.
897
+ */
898
+ getRanges(): ICellRanges | null;
899
+ }
900
+ /**
901
+ * Events for {@link IWorksheet}.
902
+ */
903
+ interface Events {
904
+ /**
905
+ * Called when the UsedRange bounds changes.
906
+ *
907
+ * @remarks
908
+ * Useful when interested in knowing when the bounds of the area
909
+ * that is being used within the sheet changes; for example this is used
910
+ * by the scrollbars to adjust the size.
911
+ * @see
912
+ * {@link IWorksheet.getUsedRange}
913
+ */
914
+ onUsedRangeChange?(source: IWorksheet): void;
915
+ /**
916
+ * Called when any data has changed.
917
+ *
918
+ * @param source The sheet.
919
+ * @param event Where the change landed and the commit that wrote it.
920
+ *
921
+ * @remarks
922
+ * Values and formulas written or cleared, hyperlinks, a structural shift (insert, delete,
923
+ * move), a rename other sheets' formulas read through, and a calculation landing. Not
924
+ * formatting: that is {@link onStyleChange}.
925
+ * To listen for changes on data regions use {@link ICellRange.addListener}.
926
+ */
927
+ onDataChange?(source: IWorksheet, event: IWorksheet.ChangeEvent): void;
928
+ /**
929
+ * Called when the sheet tab color changes.
930
+ */
931
+ onTabColorChange?(source: IWorksheet): void;
932
+ /**
933
+ * Called when any merges are added or removed.
934
+ *
935
+ * @param source The sheet.
936
+ * @param event Where the merges changed and the commit that changed them.
937
+ */
938
+ onMergesChange?(source: IWorksheet, event: IWorksheet.ChangeEvent): void;
939
+ /**
940
+ * Called if any spills occur.
941
+ *
942
+ * @param source The sheet.
943
+ * @param event Where the spills changed, and the commit when a write (not a calculation)
944
+ * changed them.
945
+ */
946
+ onSpillsChange?(source: IWorksheet, event: IWorksheet.ChangeEvent): void;
947
+ /**
948
+ * Called when any movables are added or removed.
949
+ */
950
+ onMovablesChange?(source: IWorksheet): void;
951
+ /**
952
+ * Called when any table are added or removed.
953
+ */
954
+ onTablesChange?(source: IWorksheet): void;
955
+ /**
956
+ * Called when any data validation is added, removed, re-anchored, or re-evaluates its results.
957
+ *
958
+ * @remarks
959
+ * Always accompanied by the coarse {@link onStyleChange}. Listen here only when reacting to
960
+ * the validations themselves (an editor panel, the alert indicators); renderers should listen
961
+ * to the class event instead.
962
+ */
963
+ onDataValidationsChange?(source: IWorksheet): void;
964
+ /**
965
+ * Called when any conditional format is added, removed, re-anchored, reordered, or finishes
966
+ * (re)evaluating — a rule's results land asynchronously, after the calculation engine answers.
967
+ *
968
+ * @remarks
969
+ * Always accompanied by the coarse {@link onStyleChange}. Listen here only when reacting to
970
+ * the rules themselves (an editor panel); renderers should listen to the class event instead.
971
+ */
972
+ onConditionalFormatsChange?(source: IWorksheet): void;
973
+ /**
974
+ * Called when protected ranges are added, removed, renamed, reordered or re-anchored.
975
+ *
976
+ * @remarks
977
+ * Always accompanied by the coarse {@link onProtectionChange}.
978
+ */
979
+ onProtectedRangesChange?(source: IWorksheet): void;
980
+ /**
981
+ * Called when a cell control is added, removed, re-anchored or reordered.
982
+ *
983
+ * @remarks
984
+ * Always accompanied by the coarse {@link onStyleChange}: a control is a format.
985
+ */
986
+ onCellControlsChange?(source: IWorksheet): void;
987
+ /**
988
+ * Called when a comment is added, removed, edited, resolved, replied to or re-anchored.
989
+ *
990
+ * @remarks
991
+ * Always accompanied by the coarse {@link onStyleChange}, since a cell paints its comment
992
+ * indicator.
993
+ */
994
+ onCommentsChange?(source: IWorksheet): void;
995
+ /**
996
+ * Called when the auto table is added or removed.
997
+ */
998
+ onAutoTableChange?(source: IWorksheet): void;
999
+ /**
1000
+ * Called when anything that affects how cells PAINT (other than data or layout) changes.
1001
+ *
1002
+ * @remarks
1003
+ * One of the three coarse class events (with {@link onLayoutChange} and
1004
+ * {@link onProtectionChange}): a single subscription for "the sheet may render differently",
1005
+ * meant for renderers so they never have to accumulate the finer-grained events. It fires
1006
+ * alongside each of them — direct and named style edits, table styling
1007
+ * ({@link onTablesChange}), conditional formatting results
1008
+ * ({@link onConditionalFormatsChange}, including their asynchronous evaluation completing),
1009
+ * and data validation visuals ({@link onDataValidationsChange}) all raise it. Listen to a
1010
+ * finer event only when reacting to that specific collection.
1011
+ *
1012
+ * A direct style edit, and its undo and redo, announce the ranges they wrote and their
1013
+ * commit; the collections and the caches announce the whole sheet.
1014
+ *
1015
+ * @param source The sheet.
1016
+ * @param event Where the formatting changed, when it is known.
1017
+ */
1018
+ onStyleChange?(source: IWorksheet, event: IWorksheet.ChangeEvent): void;
1019
+ /**
1020
+ * Called when the sizes of the cells change.
1021
+ *
1022
+ * @remarks
1023
+ * One of the three coarse class events (see {@link onStyleChange}): the single subscription
1024
+ * for "cell geometry moved".
1025
+ * * This can be be due to row/column sizes changes or changing the max rows columns.
1026
+ * * Zoom and viewport do not change the underlying layout.
1027
+ *
1028
+ * @param source The sheet.
1029
+ * @param event The whole sheet: sizes are announced by the headers, which do not say where.
1030
+ */
1031
+ onLayoutChange?(source: IWorksheet, event: IWorksheet.ChangeEvent): void;
1032
+ /**
1033
+ * Called when which rows are hidden has changed.
1034
+ */
1035
+ onRowsHiddenChange?(source: IWorksheet): void;
1036
+ /**
1037
+ * Called when which columns are hidden has changed.
1038
+ */
1039
+ onColumnsHiddenChange?(source: IWorksheet): void;
1040
+ /**
1041
+ * Called on any protection changes.
1042
+ *
1043
+ * @remarks
1044
+ * One of the three coarse class events (see {@link onStyleChange}): the single subscription
1045
+ * for "what the user may touch changed" — the sheet lock state, its allowed actions, and the
1046
+ * protected ranges ({@link onProtectedRangesChange}) all raise it.
1047
+ */
1048
+ onProtectionChange?(source: IWorksheet): void;
1049
+ /**
1050
+ * Called before load. If any exception is thrown this
1051
+ * exception will be returned to the client and delete will fail.
1052
+ */
1053
+ onBeforeLoad?(source: IWorksheet, json: IWorksheet.JSON): void;
1054
+ /**
1055
+ * Called after load.
1056
+ */
1057
+ onLoad?(source: IWorksheet): void;
1058
+ /**
1059
+ * Called before load. If any exception is thrown this
1060
+ * exception will be returned to the client and delete will be aborted.
1061
+ */
1062
+ onBeforeSave?(source: IWorksheet): Promise<void> | void;
1063
+ /**
1064
+ * Called after save.
1065
+ */
1066
+ onSave?(source: IWorksheet, json: IWorksheet.JSON): void;
1067
+ /**
1068
+ * Called before delete. If any exception is thrown the
1069
+ * exception will be returned to the client and delete will be aborted.
1070
+ */
1071
+ onBeforeDelete?(source: IWorksheet): void;
1072
+ /**
1073
+ * Request that the sheet become focused.
1074
+ * @returns A promise indicating if the focus was honored.
1075
+ *
1076
+ * @remarks
1077
+ * This should only be handled by one consumer.
1078
+ */
1079
+ onRequestScrollIntoView?(source: IWorksheet, options: IWorksheet.ScrollToOptions): Promise<boolean>;
1080
+ /**
1081
+ * Request that the sheet become focused.
1082
+ * @returns A promise indicating if the focus was honored.
1083
+ * @remarks
1084
+ * This should only be handled by one consumer.
1085
+ */
1086
+ onRequestFocus?(source: IWorksheet): Promise<boolean>;
1087
+ /**
1088
+ * Request the visible viewport ("window") bounds in absolute sheet pixels — the one placement input the
1089
+ * model can't derive itself. Used to center a bounds-less movable (e.g. a chart via
1090
+ * {@link IMovableCollection.AddOptions.autoPlace}); when no consumer responds (headless) the add falls
1091
+ * back to default cursor placement.
1092
+ *
1093
+ * @remarks
1094
+ * This should only be handled by one consumer (the grid view).
1095
+ */
1096
+ onRequestViewport?(source: IWorksheet): Promise<Bounds | null>;
1097
+ /**
1098
+ * Called when the sheet is deleted.
1099
+ */
1100
+ onDelete?(source: IWorksheet): void;
1101
+ /**
1102
+ * Called when the `IWorksheetView` changes.
1103
+ *
1104
+ * This is not called when individual properties on the view change.
1105
+ */
1106
+ onViewChange?(source: IWorksheet): void;
1107
+ /**
1108
+ * Called when the topLeft changes.
1109
+ *
1110
+ * @remarks
1111
+ * This is a delegated event from the `IWorksheetView`.
1112
+ */
1113
+ onTopLeftChange?(source: IWorksheet): void;
1114
+ /**
1115
+ * Called when the selection changes.
1116
+ *
1117
+ * @remarks
1118
+ * This is a delegated event from the `IWorksheetView`.
1119
+ */
1120
+ onSelectionChange?(source: IWorksheet): void;
1121
+ /**
1122
+ * Called when freeze or split settings have changed.
1123
+ *
1124
+ * @remarks
1125
+ * This is a delegated event from the `IWorksheetView`.
1126
+ */
1127
+ onFreezePaneChange?(source: IWorksheet): void;
1128
+ /**
1129
+ * Called when the zoom scale changes.
1130
+ *
1131
+ * @remarks
1132
+ * This is a delegated event from the `IWorksheetView`.
1133
+ */
1134
+ onZoomScaleChange?(source: IWorksheet): void;
1135
+ /**
1136
+ * Called when the movable selection changes.
1137
+ *
1138
+ * @remarks
1139
+ * This is a delegated event from the `IWorksheetView`.
1140
+ */
1141
+ onMovableSelectionChange?(source: IWorksheet): void;
1142
+ /**
1143
+ * Called when the view changes.
1144
+ */
1145
+ onViewChange?(source: IWorksheet): void;
1146
+ /**
1147
+ * Called when the name changes.
1148
+ */
1149
+ onNameChange?(source: IWorksheet): void;
1150
+ /**
1151
+ * Called when the visibility changes..
1152
+ */
1153
+ onVisibilityChange?(source: IWorksheet): void;
1154
+ /**
1155
+ * Called when the index changes.
1156
+ */
1157
+ onIndexChange?(source: IWorksheet): void;
1158
+ /**
1159
+ * Called when the state has been updated due to a undo/redo and a rerender is required.
1160
+ */
1161
+ onInvalidated?(source: IWorksheet): void;
1162
+ /**
1163
+ * Called when the sheet is closed.
1164
+ */
1165
+ onClose?(source: IWorksheet): void;
1166
+ }
1167
+ interface IListeners extends IListener.Callbacks<IWorksheet, IWorksheet.Events> {
1168
+ }
1169
+ interface ToJSONOptions {
1170
+ /**
1171
+ * If `true` the raw values will not be included in the JSON.
1172
+ *
1173
+ * @remarks
1174
+ * When ignoring Data the strings will also not be included in the JSON.
1175
+ */
1176
+ ignoreData?: boolean;
1177
+ /**
1178
+ * How resources — images and the other binaries the sheet references — are written.
1179
+ *
1180
+ * * `'embed'` serializes each one into the JSON, base64 encoded.
1181
+ * * `'ignore'` writes every id as `0` and no resources.
1182
+ * * An {@link IResource.Writer} puts each one wherever the caller wants and records what it
1183
+ * returns, so resources can be stored outside the JSON — uploaded and referenced by `uri`,
1184
+ * or emitted as parts of another format and referenced by id alone.
1185
+ *
1186
+ * @defaultValue 'embed'
1187
+ */
1188
+ resources?: 'embed' | 'ignore' | IResource.Writer;
1189
+ /**
1190
+ * If `true` the resources will not include formatting.
1191
+ *
1192
+ * @remarks
1193
+ * This will also ignore merges and hyperlinks styles
1194
+ */
1195
+ ignoreStyles?: boolean;
1196
+ /**
1197
+ * If `true` the formulas will not be included in the JSON.
1198
+ */
1199
+ ignoreFormulas?: boolean;
1200
+ }
1201
+ /**
1202
+ * Optional values used in the construction of am {@link IWorksheet}.
1203
+ *
1204
+ * @remarks
1205
+ * Changes to these options will be ignored after construction.
1206
+ */
1207
+ interface ConstructorOptions extends ICellContainerOptions {
1208
+ /**
1209
+ * When adding to another container.
1210
+ */
1211
+ container?: IWorksheet.ContainerOptions;
1212
+ /**
1213
+ * The sheet's id ({@link IWorksheet.getId}): what formulas and operations (copy/paste) identify it
1214
+ * by. Must be unique among all in-memory sheets.
1215
+ *
1216
+ * @returns The id. If not provided a new one is made.
1217
+ * @remarks
1218
+ * Not saved as part of the {@link IWorksheet.JSON} persisted model. A container that names its
1219
+ * sheets before it builds them (a workbook loading its sheets) supplies it.
1220
+ */
1221
+ uid?: () => string;
1222
+ /**
1223
+ * Initial JSON.
1224
+ */
1225
+ json?: IWorksheet.JSON;
1226
+ }
1227
+ /**
1228
+ * Options needed for embedding a sheet into another container such as a workbook.
1229
+ */
1230
+ interface ContainerOptions {
1231
+ /**
1232
+ * Required to be called before from JSON.
1233
+ * @param self -The Sheet
1234
+ *
1235
+ * @remarks
1236
+ * This is needed to ensure the contain has access to the sheet reference so that
1237
+ * it can resolve references.
1238
+ */
1239
+ beforeFromJSON?: (self: IWorksheet) => void;
1240
+ /**
1241
+ * Callback to provide a sheet with a logical name. This is used
1242
+ * when a sheet name property is invoked.
1243
+ *
1244
+ * @remarks
1245
+ * Sheets don't have a name by default but as a convenience we allow
1246
+ * for the name to be called from the sheet.
1247
+ */
1248
+ getName: () => string | null;
1249
+ setName?: (name: string | null, options?: ITransaction.OperationOptions) => void;
1250
+ setNameChangeCallback?: (callback: () => void) => void;
1251
+ /**
1252
+ * Return the current index.
1253
+ */
1254
+ getIndex?: () => number | null;
1255
+ /**
1256
+ * Request that this moved.
1257
+ *
1258
+ * @param index The index to set to.
1259
+ *
1260
+ * @remarks
1261
+ * For traditional workbooks with not docking tabs this will be the tab position.
1262
+ */
1263
+ setIndex?: (index: number, options?: ITransaction.OperationOptions) => boolean;
1264
+ setIndexCallback?: (callback: () => void) => void;
1265
+ /**
1266
+ * Callback to provide a sheet with a visibility.
1267
+ *
1268
+ * @remarks
1269
+ * Sheets don't manage this but as a convenience we allow
1270
+ * for the visibility to be called from the sheet.
1271
+ */
1272
+ getVisibility?: () => ISheet.Visibility;
1273
+ setVisibility?: (visibility: ISheet.Visibility, options?: ITransaction.OperationOptions) => void;
1274
+ setVisibilityCallback?: (callback: () => void) => void;
1275
+ /**
1276
+ * Returns a copy of the sheet provided sheet.
1277
+ */
1278
+ duplicate?: () => Promise<IWorksheet>;
1279
+ /**
1280
+ * Request that the sheet become the active sheet.
1281
+ *
1282
+ * @returns A flag indicating that the sheet was brought to the front.
1283
+ *
1284
+ * @remarks
1285
+ * In a workbook context there is only one active sheet at a time but other clients
1286
+ * may treat this this differently.
1287
+ */
1288
+ requestSelect?: (options?: ITypes.SelectOptions) => Promise<boolean>;
1289
+ }
1290
+ /**
1291
+ * A set of properties for `IWorksheet`.
1292
+ */
1293
+ interface PropertiesJSON {
1294
+ custom?: Record<string, string>;
1295
+ calc?: {
1296
+ fullCalcOnLoad?: boolean;
1297
+ };
1298
+ ignoreErrors?: Record<string, string[]>;
1299
+ phoneticPr?: {
1300
+ alignment?: string;
1301
+ fontId?: number;
1302
+ type: string;
1303
+ };
1304
+ }
1305
+ /**
1306
+ * A drawing whose shapes are described in the origin format's own legacy vector markup rather
1307
+ * than through {@link IMovable | movables}.
1308
+ *
1309
+ * @remarks
1310
+ * A carrier, not a concept: what a spreadsheet keeps out of its main drawing — the box a note is
1311
+ * displayed in, a form control's shape, and the pictures placed in a header or footer — held as
1312
+ * one unit and put back on save, so a document that has them survives a round trip. Each piece
1313
+ * folds into its own model as that lands (the note's box onto the note, the control's shape onto
1314
+ * the control, the pictures onto the print header), and the carrier goes with the last of them.
1315
+ *
1316
+ * The markup is opaque: it is held as it was read and replayed unchanged, which also means the
1317
+ * positions in it do not follow rows and columns that are inserted or deleted. Its images are
1318
+ * carried by {@link IResource} id, each under the id the markup references it by.
1319
+ */
1320
+ interface LegacyDrawingJSON {
1321
+ xml: string;
1322
+ images?: {
1323
+ id: string;
1324
+ resId: number;
1325
+ }[];
1326
+ }
1327
+ /**
1328
+ * A sheet's synchronized scrolling. See {@link IWorksheet.getSyncScroll}.
1329
+ */
1330
+ interface SyncScroll {
1331
+ /** Whether horizontal scrolling is synchronized. */
1332
+ horizontal?: boolean;
1333
+ /** Whether vertical scrolling is synchronized. */
1334
+ vertical?: boolean;
1335
+ /** The cell scrolling is synchronized to (A1 form), as written. */
1336
+ anchor?: string;
1337
+ }
1338
+ /**
1339
+ * The size of a sheet, in columns and rows. `'fit'` ends that axis where the content does.
1340
+ *
1341
+ * @see {@link IWorksheet.setEntireSize}
1342
+ */
1343
+ interface EntireSize {
1344
+ width: number | 'fit';
1345
+ height: number | 'fit';
1346
+ }
1347
+ /**
1348
+ * JSON representation of an `IWorksheet` used for serialization and deserialization.
1349
+ */
1350
+ interface JSON extends ISheet.JSON {
1351
+ data?: Tuple.GridTuple<Scalar.JSON>;
1352
+ formulas?: IRange.JSONReferenceTuple<string>[];
1353
+ /**
1354
+ * The extent occupied by an array formula, and which of the three
1355
+ * {@link ITypes.FormulaArrayKind | kinds} of array formula it is.
1356
+ *
1357
+ * @remarks
1358
+ * Every array formula earns an entry, degenerate 1x1 ones included - a 1x1 extent is not the
1359
+ * same thing as no extent. Only the `kind` distinguishes a fixed one-cell block from a
1360
+ * dynamic formula that happened not to spill; the extent cannot.
1361
+ */
1362
+ formulaArray?: IRange.JSONReferenceTuple<ITypes.FormulaArrayKind>[];
1363
+ volatile?: IRange.Address[];
1364
+ /**
1365
+ * Column headers, each addressed as an entire-column run (`'E:E'`, `'E:H'`).
1366
+ *
1367
+ * @remarks
1368
+ * Can be empty. The address carries the orientation, so a row address is read here too.
1369
+ */
1370
+ cols?: IRange.JSONReference<ICellHeader.JSON>[];
1371
+ defaultColSize?: number;
1372
+ /**
1373
+ * The width, in digits of the Normal font, that the default column width is derived from when
1374
+ * there is no {@link defaultColSize}. Absent, `8`.
1375
+ */
1376
+ baseColSize?: number;
1377
+ /**
1378
+ * Row headers, each addressed as an entire-row run (`'5:5'`, `'5:12'`).
1379
+ *
1380
+ * @remarks
1381
+ * Can be empty. The address carries the orientation, so a column address is read here too.
1382
+ */
1383
+ rows?: IRange.JSONReference<ICellHeader.JSON>[];
1384
+ defaultRowSize?: number;
1385
+ styles?: IStyleCollection.JSON;
1386
+ resources?: IResource.JSON[];
1387
+ strings?: string[];
1388
+ /** The rich values cells name by id (`{ t: 'r', v: id }`), when the sheet owns its own. */
1389
+ richData?: IRichDataCollection.JSON[];
1390
+ /** The kinds {@link richData} names that are not registered in code (a kind read from a file). */
1391
+ richTypes?: IRichType.JSON[];
1392
+ /**
1393
+ * Modules owned by this sheet, keyed by module name.
1394
+ *
1395
+ * @see {@link IWorksheet.getModules}
1396
+ */
1397
+ modules?: Record<string, IModule.JSON>;
1398
+ /**
1399
+ * The comments and notes, one per cell, each thread with its replies.
1400
+ *
1401
+ * @see {@link IWorksheet.getComments}
1402
+ */
1403
+ comments?: IRange.JSONReference<IComment.JSON>[];
1404
+ hyperlinks?: IRange.JSONReference<IHyperlink.JSON>[];
1405
+ /**
1406
+ * A generalize solution for dynamic areas.
1407
+ * This is used for externalData
1408
+ *
1409
+ "C5:G10": {
1410
+ "type": "externalData",
1411
+ "error": false, // Or true if the last refresh failed
1412
+ "source": "Query1", // Example: Type-specific info
1413
+ "overrides": { // Object storing user edits within the region
1414
+ "D6": "Manual Edit", // Key = Cell Address within region
1415
+ "F8": 123.45 // Value = User-entered value
1416
+ }
1417
+ }
1418
+ */
1419
+ /**
1420
+ * Either an object with RangeAddress to style id or an array of RangeCoordValue to style id.
1421
+ */
1422
+ directStyles?: IRange.JSONReferenceTuple<number>[];
1423
+ merges?: IRange.Address[];
1424
+ autoTable?: IRange.JSONReference<ITable.JSON>;
1425
+ tables?: IRange.JSONReference<ITable.JSON>[];
1426
+ conditionals?: IRange.JSONReference<IConditionalFormat.JSON>[];
1427
+ validations?: IRange.JSONReference<IDataValidation.JSON>[];
1428
+ /**
1429
+ * @see {@link IDataValidationCollection.getSettings}
1430
+ */
1431
+ validationSettings?: IDataValidationCollection.Settings;
1432
+ protectedRanges?: IRange.JSONReference<IProtectedRange.JSON>[];
1433
+ cellControls?: IRange.JSONReference<ICellControl.JSON>[];
1434
+ movables?: IMovable.JSON[];
1435
+ /**
1436
+ * The sheet's VBA code name. Absent when it has none.
1437
+ *
1438
+ * @see {@link IWorksheet.getCodeName}
1439
+ */
1440
+ codeName?: string;
1441
+ /**
1442
+ * The outline settings that differ from their defaults.
1443
+ *
1444
+ * @see {@link IWorksheet.getOutline}
1445
+ */
1446
+ outline?: IOutline.JSON;
1447
+ /**
1448
+ * Present, as `false`, only when conditional format calculation is turned off.
1449
+ *
1450
+ * @see {@link IWorksheet.isConditionalFormatCalculationEnabled}
1451
+ */
1452
+ conditionalFormatCalculation?: boolean;
1453
+ /**
1454
+ * @see {@link IWorksheet.isTransitionFormulaEvaluation}
1455
+ */
1456
+ transitionFormulaEvaluation?: boolean;
1457
+ /**
1458
+ * @see {@link IWorksheet.isTransitionFormulaEntry}
1459
+ */
1460
+ transitionFormulaEntry?: boolean;
1461
+ /**
1462
+ * @see {@link IWorksheet.isExcludedFromPublishing}
1463
+ */
1464
+ excludeFromPublishing?: boolean;
1465
+ /**
1466
+ * @see {@link IWorksheet.getSyncScroll}
1467
+ */
1468
+ syncScroll?: IWorksheet.SyncScroll;
1469
+ /**
1470
+ * The sheet's picture.
1471
+ */
1472
+ picture?: IPicture.JSON;
1473
+ /**
1474
+ * The sheet's legacy drawing: note boxes and form control shapes.
1475
+ *
1476
+ * @see {@link IWorksheet.LegacyDrawingJSON}
1477
+ */
1478
+ legacyDrawing?: LegacyDrawingJSON;
1479
+ /**
1480
+ * The legacy drawing for the sheet's header and footer, which holds their pictures.
1481
+ *
1482
+ * @see {@link IWorksheet.LegacyDrawingJSON}
1483
+ */
1484
+ legacyDrawingHF?: LegacyDrawingJSON;
1485
+ /**
1486
+ * The sheet's pivot tables.
1487
+ *
1488
+ * @see {@link IWorksheet.getPivotTables}
1489
+ */
1490
+ pivotTables?: IPivotTable.JSON[];
1491
+ /**
1492
+ * The cells where Excel's error checks are ignored (the green triangle's **Ignore Error**):
1493
+ * each reference's value is the set of checks its cells ignore.
1494
+ *
1495
+ * @see {@link ICellRange.setErrorIgnored}
1496
+ */
1497
+ ignoredErrors?: IRange.JSONReference<ICell.ErrorCheck[]>[];
1498
+ protection?: IWorksheetProtection.JSON;
1499
+ view?: IWorksheetView.JSON;
1500
+ /**
1501
+ * The print layout settings that differ from their defaults.
1502
+ *
1503
+ * @see {@link IWorksheet.getPageLayout}
1504
+ */
1505
+ pageLayout?: IPageLayout.JSON;
1506
+ /**
1507
+ * If specified this indicates the entire range of the sheet.
1508
+ */
1509
+ entireSize?: Partial<Size>;
1510
+ /**
1511
+ * The axes of {@link entireSize} that end where the content does.
1512
+ *
1513
+ * @see {@link IWorksheet.setEntireSize}
1514
+ */
1515
+ entireSizeFit?: {
1516
+ width?: boolean;
1517
+ height?: boolean;
1518
+ };
1519
+ }
1520
+ }
1521
+ //# sourceMappingURL=IWorksheet.d.ts.map