@sheetxl/sdk 0.8.0-beta.1 → 0.8.0-beta.2

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 (353) hide show
  1. package/THIRD-PARTY-NOTICES.md +1 -1
  2. package/browser/cjs/4f5eoQQfV-V7LO2_.cjs +1 -0
  3. package/browser/cjs/BEnEDC1m546-gzWS.cjs +1 -0
  4. package/browser/cjs/CwCUa4IzGNGissLL.cjs +1 -0
  5. package/browser/cjs/{a0Z-SXs_N71CtqYb.cjs → Dg3GaW0QWwnlqetX.cjs} +1 -1
  6. package/browser/cjs/KWQPie2u7AP69web.cjs +93 -0
  7. package/browser/cjs/index.cjs +2 -2
  8. package/browser/esm/{B0HS42a7lga1k1U_.mjs → BJ9hcZAGY8Tj5_9L.mjs} +1 -1
  9. package/browser/esm/C8vpA2ZBtZf6w4nq.mjs +394 -0
  10. package/browser/esm/DDojiE2-oycJ7qGi.mjs +20 -0
  11. package/browser/esm/DEPT7zmpiMdZ-_qC.mjs +70253 -0
  12. package/browser/esm/DOvCi3lf49To36WP.mjs +8 -0
  13. package/browser/esm/{uyWBMSIxMlt8n5Z3.mjs → Dq3sc4B_HQHBrT5N.mjs} +2 -2
  14. package/browser/esm/index.mjs +871 -696
  15. package/browser/esm/{DlPMeIyxT9tG_WDk.mjs → trwZArJQQq7K9kL7.mjs} +2 -2
  16. package/licenses/dependencies.txt +204 -204
  17. package/node/esm/CGWsQOMWdnDeF4dX.mjs +8 -0
  18. package/node/esm/{Cku7XiUvw1xrRasi.mjs → CL9MI-b6D9BmtVXW.mjs} +1 -1
  19. package/node/esm/CressiwiIhxCVp1v.mjs +28 -0
  20. package/node/esm/O2cOO3xIynWUgOWe.mjs +403 -0
  21. package/node/esm/index.mjs +52356 -37345
  22. package/package.json +6 -7
  23. package/resources/locales/de/model.msg.json +45 -9
  24. package/resources/locales/en/model.msg.json +42 -9
  25. package/types/scripting-api.json +7093 -0
  26. package/types/scripting-enums.json +54 -8
  27. package/types/scripting.d.ts +7006 -1202
  28. package/types/src/anchored/AbstractAnchored.d.ts +18 -8
  29. package/types/src/anchored/AnchoredMap.d.ts +2 -0
  30. package/types/src/anchored/IAnchoredMap.d.ts +52 -4
  31. package/types/src/autoFill/AutoFill.d.ts +316 -32
  32. package/types/src/autoFill/IAutoFill.d.ts +232 -15
  33. package/types/src/border/{IBorder.d.ts → IBorders.d.ts} +41 -40
  34. package/types/src/border/index.d.ts +1 -1
  35. package/types/src/calculation/Calculation.d.ts +740 -35
  36. package/types/src/calculation/ExternalBookBindings.d.ts +118 -0
  37. package/types/src/calculation/FormulaText.d.ts +74 -0
  38. package/types/src/calculation/ICalculation.d.ts +318 -81
  39. package/types/src/calculation/INamedFormulasCollection.d.ts +5 -8
  40. package/types/src/calculation/NamedFormulaCollection.d.ts +139 -107
  41. package/types/src/calculation/NamedLambdaFunction.d.ts +28 -0
  42. package/types/src/calculation/TokenType.d.ts +9 -0
  43. package/types/src/calculation/Types.d.ts +83 -2
  44. package/types/src/calculation/_CloneBoundary.d.ts +80 -0
  45. package/types/src/calculation/compiler/ASTTypes.d.ts +58 -0
  46. package/types/src/calculation/compiler/CompilerUtils.d.ts +134 -12
  47. package/types/src/calculation/compiler/FormulaCompiler.d.ts +29 -4
  48. package/types/src/calculation/compiler/FormulaParser.d.ts +1 -2
  49. package/types/src/calculation/compiler/LiteTransform.d.ts +17 -0
  50. package/types/src/calculation/compiler/ParserUtils.d.ts +26 -1
  51. package/types/src/calculation/compiler/SRParser.d.ts +2 -1
  52. package/types/src/calculation/compiler/Types.d.ts +79 -9
  53. package/types/src/calculation/executor/CalcExecutor.d.ts +312 -33
  54. package/types/src/calculation/executor/CalcExecutorUtils.d.ts +43 -2
  55. package/types/src/calculation/executor/CircularReference.d.ts +2 -0
  56. package/types/src/calculation/formula/Formula.d.ts +58 -21
  57. package/types/src/calculation/formula/FormulaBlock.d.ts +124 -21
  58. package/types/src/calculation/formula/FormulaRecordView.d.ts +79 -0
  59. package/types/src/calculation/formula/IFormulaBlock.d.ts +261 -67
  60. package/types/src/calculation/formula/LambdaValue.d.ts +15 -16
  61. package/types/src/calculation/formula/LazyValue.d.ts +96 -0
  62. package/types/src/calculation/formula/TokenUtils.d.ts +25 -1
  63. package/types/src/calculation/formula/index.d.ts +1 -0
  64. package/types/src/calculation/functions/FunctionDeclarations.d.ts +31 -0
  65. package/types/src/calculation/functions/initializeFunctions.d.ts +15 -2
  66. package/types/src/calculation/grid/CalcGrid.d.ts +384 -158
  67. package/types/src/calculation/grid/CalcGridBackend.d.ts +450 -0
  68. package/types/src/calculation/grid/CalcGridProxy.d.ts +133 -0
  69. package/types/src/calculation/grid/CalcGridUtils.d.ts +62 -12
  70. package/types/src/calculation/grid/FormulaEntry.d.ts +129 -0
  71. package/types/src/calculation/grid/FormulaHost.d.ts +236 -0
  72. package/types/src/calculation/grid/ICalcGrid.d.ts +456 -143
  73. package/types/src/calculation/grid/_CalcRequest.d.ts +272 -0
  74. package/types/src/calculation/grid/index.d.ts +4 -0
  75. package/types/src/calculation/index.d.ts +2 -0
  76. package/types/src/calculation/spatial/ContentfulSpatialValue.d.ts +6 -2
  77. package/types/src/calculation/spatial/FormulaSpatialValue.d.ts +339 -11
  78. package/types/src/calculation/spatial/SpillEntry.d.ts +20 -5
  79. package/types/src/calculation/spatial/TouchedWindows.d.ts +86 -0
  80. package/types/src/calculation/spatial/index.d.ts +1 -0
  81. package/types/src/calculation/state/CalcInputs.d.ts +41 -0
  82. package/types/src/calculation/state/CalcNode.d.ts +141 -30
  83. package/types/src/calculation/state/CalcScope.d.ts +37 -0
  84. package/types/src/calculation/state/CalcState.d.ts +22 -1
  85. package/types/src/calculation/state/CalculationContext.d.ts +36 -2
  86. package/types/src/calculation/state/IContextContainer.d.ts +129 -27
  87. package/types/src/calculation/state/_PendingOverlayGrid.d.ts +163 -0
  88. package/types/src/calculation/state/_ReadObservedGrid.d.ts +74 -8
  89. package/types/src/calculation/state/index.d.ts +1 -0
  90. package/types/src/calculation/symbol/ExternalSheetSymbols.d.ts +80 -0
  91. package/types/src/calculation/symbol/ISymbolRegistry.d.ts +23 -0
  92. package/types/src/calculation/symbol/IndirectSymbolProvider.d.ts +16 -2
  93. package/types/src/calculation/symbol/SheetSymbolProvider.d.ts +63 -3
  94. package/types/src/calculation/symbol/SymbolRegistry.d.ts +20 -0
  95. package/types/src/calculation/symbol/index.d.ts +3 -2
  96. package/types/src/cell/ICell.d.ts +78 -23
  97. package/types/src/cell/ICellProtection.d.ts +50 -10
  98. package/types/src/cellRange/ICellRange.d.ts +329 -72
  99. package/types/src/cellRange/ICellRanges.d.ts +9 -7
  100. package/types/src/chart/Chart.d.ts +72 -2
  101. package/types/src/chart/ChartCollection.d.ts +26 -0
  102. package/types/src/chart/IChart.d.ts +162 -9
  103. package/types/src/chart/IChartCollection.d.ts +25 -0
  104. package/types/src/chart/_ChartXml.d.ts +70 -0
  105. package/types/src/chart/index.d.ts +1 -3
  106. package/types/src/collections/ArraysGrid.d.ts +1 -1
  107. package/types/src/collections/IGrid.d.ts +1 -1
  108. package/types/src/collections/ISparseGrid.d.ts +9 -0
  109. package/types/src/collections/ISpatialMap.d.ts +59 -21
  110. package/types/src/collections/ImmutableList.d.ts +28 -0
  111. package/types/src/collections/MixedTypedArrayList.d.ts +168 -108
  112. package/types/src/collections/OverlappingRangeIterator.d.ts +13 -17
  113. package/types/src/collections/RepeatingList.d.ts +7 -0
  114. package/types/src/collections/ScalarGrid.d.ts +50 -0
  115. package/types/src/collections/SparseGrid.d.ts +1 -1
  116. package/types/src/collections/SpatialMap.d.ts +13 -21
  117. package/types/src/collections/Tuple.d.ts +128 -16
  118. package/types/src/collections/_GridUtils.d.ts +19 -6
  119. package/types/src/collections/_RangeSweep.d.ts +97 -0
  120. package/types/src/collections/_SpatialUtils.d.ts +20 -2
  121. package/types/src/collections/index.d.ts +1 -0
  122. package/types/src/comment/Comment.d.ts +159 -0
  123. package/types/src/comment/CommentCollection.d.ts +40 -0
  124. package/types/src/comment/IComment.d.ts +319 -48
  125. package/types/src/comment/ICommentCollection.d.ts +90 -0
  126. package/types/src/comment/_CommentUtils.d.ts +28 -0
  127. package/types/src/comment/index.d.ts +1 -0
  128. package/types/src/condition/AnchoredConditional.d.ts +76 -17
  129. package/types/src/condition/BuiltInOperators/AbstractOperator.d.ts +8 -7
  130. package/types/src/condition/BuiltInOperators/EqualToOperator.d.ts +2 -1
  131. package/types/src/condition/BuiltInOperators/ExpressionOperator.d.ts +3 -6
  132. package/types/src/condition/BuiltInOperators/InSetOperator.d.ts +1 -1
  133. package/types/src/condition/BuiltinSelectors/BaseSelector.d.ts +7 -0
  134. package/types/src/condition/BuiltinSelectors/ListSelector.d.ts +9 -0
  135. package/types/src/condition/Condition.d.ts +16 -0
  136. package/types/src/condition/ICondition.d.ts +86 -33
  137. package/types/src/condition/_ConditionFormula.d.ts +152 -0
  138. package/types/src/condition/_ConditionUtils.d.ts +73 -10
  139. package/types/src/conditionalFormat/ConditionalFormat.d.ts +21 -10
  140. package/types/src/conditionalFormat/ConditionalFormatCollection.d.ts +19 -8
  141. package/types/src/conditionalFormat/IConditionalFormat.d.ts +5 -3
  142. package/types/src/conditionalFormat/IConditionalFormatCollection.d.ts +2 -0
  143. package/types/src/dataValidation/DataValidation.d.ts +50 -3
  144. package/types/src/dataValidation/DataValidationCollection.d.ts +20 -9
  145. package/types/src/dataValidation/IDataValidation.d.ts +119 -30
  146. package/types/src/dataValidation/IDataValidationCollection.d.ts +10 -2
  147. package/types/src/date/DateUtils.d.ts +20 -0
  148. package/types/src/date/_DateUtils.d.ts +91 -7
  149. package/types/src/externalBook/ExternalBookCollection.d.ts +145 -12
  150. package/types/src/externalBook/ExternalBookName.d.ts +96 -0
  151. package/types/src/externalBook/IExternalBook.d.ts +170 -18
  152. package/types/src/externalBook/IExternalBookCollection.d.ts +79 -7
  153. package/types/src/externalBook/index.d.ts +1 -0
  154. package/types/src/fill/IStroke.d.ts +1 -1
  155. package/types/src/filter/IFilter.d.ts +29 -4
  156. package/types/src/font/IFont.d.ts +17 -0
  157. package/types/src/history/IHistory.d.ts +3 -2
  158. package/types/src/i18n/LanguagePack.d.ts +12 -4
  159. package/types/src/index.d.ts +3 -0
  160. package/types/src/io/AbstractBackingStore.d.ts +24 -1
  161. package/types/src/io/ArrayBackingStore.d.ts +1 -1
  162. package/types/src/io/EmbeddedPart.d.ts +20 -0
  163. package/types/src/io/IEmbeddedPart.d.ts +63 -0
  164. package/types/src/io/IWorkbookIO.d.ts +185 -18
  165. package/types/src/io/WorkbookIO.d.ts +9 -0
  166. package/types/src/io/WorkbookOrigin.d.ts +20 -11
  167. package/types/src/io/WorkbookOriginProvider.d.ts +46 -0
  168. package/types/src/io/_XmlFragment.d.ts +49 -0
  169. package/types/src/io/index.d.ts +1 -0
  170. package/types/src/lib/file/file.browser.d.ts +19 -5
  171. package/types/src/lib/file/file.node.d.ts +5 -0
  172. package/types/src/lib/utils/_Utils.d.ts +11 -0
  173. package/types/src/lib/utils/utils.browser.d.ts +9 -3
  174. package/types/src/license/license-key.d.ts +27 -0
  175. package/types/src/listener/IListener.d.ts +12 -7
  176. package/types/src/listener/ListenerEmitter.d.ts +46 -5
  177. package/types/src/model/AbstractModel.d.ts +14 -5
  178. package/types/src/movable/Control.d.ts +57 -0
  179. package/types/src/movable/IControl.d.ts +84 -0
  180. package/types/src/movable/IMovable.d.ts +23 -1
  181. package/types/src/movable/IMovableCollection.d.ts +2 -0
  182. package/types/src/movable/Movable.d.ts +4 -6
  183. package/types/src/movable/MovableCollection.d.ts +7 -7
  184. package/types/src/movable/index.d.ts +4 -0
  185. package/types/src/named/AbstractNamed.d.ts +1 -1
  186. package/types/src/named/INamed.d.ts +4 -1
  187. package/types/src/named/INamedCollection.d.ts +26 -0
  188. package/types/src/named/NamedCollection.d.ts +16 -15
  189. package/types/src/numFmt/BuiltInFormats.d.ts +15 -7
  190. package/types/src/numFmt/IFormatEngine.d.ts +2 -0
  191. package/types/src/numFmt/NumfmtFormatEngine.d.ts +2 -0
  192. package/types/src/person/IPerson.d.ts +99 -0
  193. package/types/src/person/IPersonCollection.d.ts +51 -0
  194. package/types/src/person/Person.d.ts +32 -0
  195. package/types/src/person/PersonCollection.d.ts +49 -0
  196. package/types/src/person/index.d.ts +3 -0
  197. package/types/src/picture/IPicture.d.ts +2 -0
  198. package/types/src/picture/Picture.d.ts +2 -0
  199. package/types/src/pivot/IPivotTable.d.ts +107 -0
  200. package/types/src/pivot/IPivotTableCollection.d.ts +25 -0
  201. package/types/src/pivot/PivotTable.d.ts +57 -0
  202. package/types/src/pivot/PivotTableCollection.d.ts +25 -0
  203. package/types/src/pivot/index.d.ts +6 -0
  204. package/types/src/primitives/CompositeRangeStats.d.ts +2 -0
  205. package/types/src/primitives/Criteria.d.ts +1 -1
  206. package/types/src/primitives/LambdaBrand.d.ts +21 -0
  207. package/types/src/primitives/PrimitiveUtils.d.ts +56 -19
  208. package/types/src/primitives/Range.d.ts +102 -24
  209. package/types/src/primitives/RangeStats.d.ts +24 -1
  210. package/types/src/primitives/ReferenceRange.d.ts +42 -0
  211. package/types/src/primitives/Runtime.d.ts +15 -2
  212. package/types/src/primitives/stats/FrequencyStats.d.ts +9 -0
  213. package/types/src/primitives/stats/LookupIndex.d.ts +46 -0
  214. package/types/src/primitives/stats/SortedNumbers.d.ts +2 -0
  215. package/types/src/primitives/stats/index.d.ts +1 -0
  216. package/types/src/print/IPrint.d.ts +0 -22
  217. package/types/src/protectedRange/IProtectedRange.d.ts +4 -0
  218. package/types/src/protectedRange/IProtectedRangeCollection.d.ts +2 -0
  219. package/types/src/protectedRange/ProtectedRange.d.ts +1 -4
  220. package/types/src/protectedRange/ProtectedRangeCollection.d.ts +19 -8
  221. package/types/src/protection/DefaultProtection.d.ts +12 -1
  222. package/types/src/protection/IProtection.d.ts +36 -2
  223. package/types/src/reference/ReferenceUtils.d.ts +80 -0
  224. package/types/src/reference/index.d.ts +2 -0
  225. package/types/src/resource/IResource.d.ts +21 -1
  226. package/types/src/resource/IResourceCollection.d.ts +9 -1
  227. package/types/src/resource/ResourceCollection.d.ts +6 -6
  228. package/types/src/scripting/FunctionCollection.d.ts +41 -11
  229. package/types/src/scripting/IFunctionCollection.d.ts +41 -0
  230. package/types/src/scripting/IModule.d.ts +25 -0
  231. package/types/src/scripting/IModuleCollection.d.ts +17 -0
  232. package/types/src/scripting/IScript.d.ts +18 -0
  233. package/types/src/scripting/Module.d.ts +34 -6
  234. package/types/src/scripting/ModuleCollection.d.ts +17 -12
  235. package/types/src/scripting/Runtime.d.ts +15 -0
  236. package/types/src/scripting/Scripts.d.ts +2 -0
  237. package/types/src/scripting/TypedFunction.d.ts +151 -18
  238. package/types/src/scripting/_FunctionIndex.d.ts +5 -0
  239. package/types/src/scripting/_ModuleUtils.d.ts +11 -1
  240. package/types/src/scripting/_ScriptUtils.d.ts +3 -0
  241. package/types/src/scripting/declarations.browser.d.ts +10 -0
  242. package/types/src/scripting/declarations.d.ts +49 -0
  243. package/types/src/scripting/declarations.node.d.ts +9 -0
  244. package/types/src/scripting/index.d.ts +3 -0
  245. package/types/src/selection/IRangeSelection.d.ts +9 -4
  246. package/types/src/selection/RangeSelection.d.ts +2 -0
  247. package/types/src/shape/IShape.d.ts +41 -3
  248. package/types/src/shape/Shape.d.ts +10 -0
  249. package/types/src/shape/_ShapeXml.d.ts +28 -0
  250. package/types/src/sheet/CellRegion.d.ts +6 -0
  251. package/types/src/sheet/ICellContainerOptions.d.ts +50 -0
  252. package/types/src/sheet/ISheet.d.ts +224 -41
  253. package/types/src/sheet/ISheetCollection.d.ts +2 -5
  254. package/types/src/sheet/NamedCellRange.d.ts +16 -7
  255. package/types/src/sheet/Sheet.d.ts +749 -114
  256. package/types/src/sheet/SheetCell.d.ts +81 -21
  257. package/types/src/sheet/SheetCollection.d.ts +19 -8
  258. package/types/src/sheet/SheetRange.d.ts +62 -14
  259. package/types/src/sheet/SheetRanges.d.ts +4 -6
  260. package/types/src/sheet/_CellBuffer.d.ts +214 -0
  261. package/types/src/sheet/_InvalidSheetRange.d.ts +5 -5
  262. package/types/src/sheet/_ListenerAnchor.d.ts +104 -0
  263. package/types/src/sheet/_RangeStateSweep.d.ts +16 -0
  264. package/types/src/sheet/_ScalarListFactory.d.ts +61 -0
  265. package/types/src/sheet/_SheetAutoFillUtils.d.ts +74 -0
  266. package/types/src/sheet/_SheetAutoFitUtils.d.ts +2 -2
  267. package/types/src/sheet/_SheetEvents.d.ts +43 -0
  268. package/types/src/sheet/_SheetFilterUtils.d.ts +32 -1
  269. package/types/src/sheet/_SheetIntents.d.ts +250 -0
  270. package/types/src/sheet/_SheetMutations.d.ts +179 -59
  271. package/types/src/sheet/_SheetStateReader.d.ts +16 -10
  272. package/types/src/sheet/_SheetStateTypes.d.ts +57 -73
  273. package/types/src/sheet/_SheetUtils.d.ts +2 -18
  274. package/types/src/sheet/_WatchAnchor.d.ts +93 -0
  275. package/types/src/sheet/spatial/HeldFormulaEntry.d.ts +36 -0
  276. package/types/src/sheet/spatial/index.d.ts +1 -0
  277. package/types/src/sheet/style/SheetCellStyle.d.ts +91 -64
  278. package/types/src/sheet/style/SheetDirectStyle.d.ts +16 -5
  279. package/types/src/sheet/style/_Resolvers.d.ts +5 -3
  280. package/types/src/sheet/style/_StyleUtils.d.ts +37 -7
  281. package/types/src/sheetHeader/ISheetHeader.d.ts +2 -0
  282. package/types/src/sheetHeader/SheetHeader.d.ts +14 -0
  283. package/types/src/sheetProtection/ISheetProtection.d.ts +41 -7
  284. package/types/src/sheetProtection/SheetProtection.d.ts +12 -0
  285. package/types/src/sheetView/ISheetView.d.ts +45 -1
  286. package/types/src/sheetView/SheetView.d.ts +11 -0
  287. package/types/src/slicer/ISlicer.d.ts +2 -0
  288. package/types/src/slicer/Slicer.d.ts +2 -0
  289. package/types/src/sort/ISort.d.ts +2 -0
  290. package/types/src/string/IStringCollection.d.ts +5 -0
  291. package/types/src/string/StringCollection.d.ts +6 -6
  292. package/types/src/style/INamedStyleCollection.d.ts +72 -0
  293. package/types/src/style/IStyle.d.ts +30 -10
  294. package/types/src/style/IStyleCollection.d.ts +63 -42
  295. package/types/src/style/ITableStyleCollection.d.ts +89 -0
  296. package/types/src/style/NamedStyleCollection.d.ts +39 -0
  297. package/types/src/style/StyleCollection.d.ts +41 -5
  298. package/types/src/style/TableStyleCollection.d.ts +49 -0
  299. package/types/src/style/_BuiltInStyleDefs.d.ts +3 -3
  300. package/types/src/style/index.d.ts +4 -0
  301. package/types/src/table/AnchoredTable.d.ts +644 -68
  302. package/types/src/table/AutoTable.d.ts +5 -5
  303. package/types/src/table/ITable.d.ts +228 -30
  304. package/types/src/table/ITableCollection.d.ts +2 -0
  305. package/types/src/table/TableCollection.d.ts +19 -8
  306. package/types/src/table/_FilterField.d.ts +7 -5
  307. package/types/src/table/_NamedTable.d.ts +17 -1
  308. package/types/src/table/_NamedTableSource.d.ts +1 -0
  309. package/types/src/table/_SortField.d.ts +2 -0
  310. package/types/src/table/_TableColumn.d.ts +13 -2
  311. package/types/src/table/_TableMessages.d.ts +1 -0
  312. package/types/src/table/_TableUtils.d.ts +40 -0
  313. package/types/src/text/Bullet.d.ts +4 -0
  314. package/types/src/text/ITextFrame.d.ts +25 -1
  315. package/types/src/text/TextBoxAlignment.d.ts +15 -6
  316. package/types/src/text/TextFrame.d.ts +4 -0
  317. package/types/src/text/TextLine.d.ts +4 -0
  318. package/types/src/text/TextParagraph.d.ts +4 -0
  319. package/types/src/text/TextRun.d.ts +9 -0
  320. package/types/src/text/TextStacked.d.ts +83 -0
  321. package/types/src/text/index.d.ts +1 -0
  322. package/types/src/theme/ITheme.d.ts +2 -0
  323. package/types/src/theme/IThemeCollection.d.ts +2 -0
  324. package/types/src/theme/ThemeCollection.d.ts +8 -7
  325. package/types/src/transaction/ITransaction.d.ts +238 -36
  326. package/types/src/transaction/Transaction.d.ts +99 -11
  327. package/types/src/type/AbstractCollection.d.ts +101 -0
  328. package/types/src/type/ICollection.d.ts +117 -0
  329. package/types/src/type/ITypes.d.ts +9 -7
  330. package/types/src/type/index.d.ts +1 -0
  331. package/types/src/utils/_CSSUtils.d.ts +3 -3
  332. package/types/src/workbook/IWorkbook.d.ts +171 -40
  333. package/types/src/workbook/Workbook.d.ts +103 -7
  334. package/types/src/workbook/_WorkbookIntents.d.ts +36 -0
  335. package/types/src/workbookProtection/IWorkbookProtection.d.ts +7 -0
  336. package/types/src/workbookProtection/WorkbookProtection.d.ts +3 -0
  337. package/types/src/workbookView/IWorkbookView.d.ts +12 -0
  338. package/types/src/workbookView/WorkbookView.d.ts +5 -0
  339. package/browser/cjs/BatsV2UUraVDCRXm.cjs +0 -57
  340. package/browser/cjs/CUz53T65cRGQRgvv.cjs +0 -33
  341. package/browser/cjs/DU0kYUtdFa3jK-im.cjs +0 -1
  342. package/browser/cjs/Dv4yIPLV98M5zLHa.cjs +0 -1
  343. package/browser/esm/6JKSOvc5czaQB2Bj.mjs +0 -109
  344. package/browser/esm/BtuJ9AGzeURtAsGo.mjs +0 -51241
  345. package/browser/esm/DGU6sM25u0EWCKl1.mjs +0 -824
  346. package/browser/esm/f2G3QRgEbvFJcoa2.mjs +0 -4436
  347. package/node/esm/-pxdn3M3tc6PLHs7.mjs +0 -114
  348. package/node/esm/0n5bslM9jhO1JnI2.mjs +0 -843
  349. package/types/src/cellRange/_GraphNode.d.ts +0 -38
  350. package/types/src/dataValidation/_Utils.d.ts +0 -10
  351. package/types/src/sheet/listener/RangesListener.d.ts +0 -32
  352. package/types/src/sheet/listener/RangesListenerEntry.d.ts +0 -19
  353. package/types/src/sheet/listener/index.d.ts +0 -3
@@ -1,6 +1,6 @@
1
1
  import { IRange, Scalar } from '@sheetxl/primitives';
2
2
  import { IProperties } from '../../type';
3
- import { IBorder } from '../../border';
3
+ import { IBorders } from '../../border';
4
4
  import { IStyle, IStyleCollection } from '../../style';
5
5
  import { ISpatialMap } from '../../collections/ISpatialMap';
6
6
  /**
@@ -24,6 +24,8 @@ export declare class SheetDirectStyle implements ISpatialMap.IUpdatableValue, IP
24
24
  * that DO have a previous style. See the ranged-style update in Sheet.ts.
25
25
  */
26
26
  protected _u: IStyle.Properties | undefined;
27
+ /** Lazily built {@link getMeasureKey}. */
28
+ protected _mk: string | undefined;
27
29
  constructor(styles: IStyleCollection, getEntireRange: (() => IRange.Coords) | null, range: IRange.Coords, properties?: IStyle.Properties | null, tile?: IRange.Coords | null, axes?: IRange.AxisSelection);
28
30
  isEmpty(): boolean;
29
31
  getProperties(): IStyle.Properties | null;
@@ -34,8 +36,17 @@ export declare class SheetDirectStyle implements ISpatialMap.IUpdatableValue, IP
34
36
  * @see {@link _u}
35
37
  */
36
38
  getUpdateProperties(): IStyle.Properties | undefined;
39
+ /**
40
+ * A compare key over the properties that can change a MEASURED size: the named base, number
41
+ * format, font, the metric alignment properties (overflow / rotation / indent) and insets. Two
42
+ * direct styles with equal keys resolve to the same metrics for the same value, so a scan can
43
+ * treat distinct instances (every spatial fragment is one) as a single style run. `''` for no
44
+ * properties — the same key as no direct style at all. Built once per instance (immutable).
45
+ * @internal
46
+ */
47
+ getMeasureKey(): string;
37
48
  /** Category key partition for {@link splitByFeature} (SHEET-STYLE-SPLIT). Covers every
38
- * `IStyle.Properties` key exactly once so the split is lossless. `protection` is future. */
49
+ * `IStyle.Properties` key exactly once so the split is lossless. */
39
50
  static readonly BorderKeys: readonly (keyof IStyle.Properties)[];
40
51
  static readonly FillKeys: readonly (keyof IStyle.Properties)[];
41
52
  static readonly ContentKeys: readonly (keyof IStyle.Properties)[];
@@ -113,15 +124,15 @@ export declare class SheetDirectStyle implements ISpatialMap.IUpdatableValue, IP
113
124
  * exists to prevent.
114
125
  * @internal
115
126
  */
116
- getInnerBorder(range: IRange.Coords): Readonly<Partial<IBorder.Properties>> | null;
117
- protected _localizeBorderRange(unscoped: Readonly<IBorder.Properties>, rangeUnscoped: IRange.Coords, range: IRange.Coords): Partial<IBorder.Properties> | null | undefined;
127
+ getInnerBorder(range: IRange.Coords): Readonly<Partial<IBorders.Properties>> | null;
128
+ protected _localizeBorderRange(unscoped: Readonly<IBorders.Properties>, rangeUnscoped: IRange.Coords, range: IRange.Coords): Partial<IBorders.Properties> | null | undefined;
118
129
  /**
119
130
  * Localizes the border to the cell coords.
120
131
  * Returns border properties, null, or undefined.
121
132
  * * If undefined then there was no border to localize.
122
133
  * * `null` is localize to none.
123
134
  */
124
- protected _localizeBorder(unscoped: IBorder.Properties, range: IRange.Coords, rowIndex: number, colIndex: number): Partial<IBorder.Properties> | null | undefined;
135
+ protected _localizeBorder(unscoped: IBorders.Properties, range: IRange.Coords, rowIndex: number, colIndex: number): Partial<IBorders.Properties> | null | undefined;
125
136
  /** {@inheritDoc IProperties.ICellRanged.getPropertiesAt} */
126
137
  getPropertiesAt(rowIndex: number, colIndex: number, value: Scalar): Readonly<IStyle.Properties>;
127
138
  /** {@inheritDoc ISpatialMap.IUpdatableValue.toJSON} */
@@ -2,12 +2,13 @@ import { TypedObject } from '@sheetxl/utils';
2
2
  import { IColor } from '../../color';
3
3
  import { IFill } from '../../fill';
4
4
  import { ITextFrame, IStyledFont } from '../../text';
5
- import { IBorder } from '../../border';
5
+ import { IBorders } from '../../border';
6
+ import { ICellProtection } from '../../cell';
6
7
  import { NumberFormat } from '../../numFmt';
7
8
  import { IStyle, IStyleCollection } from '../../style';
8
9
  export declare const COLOR: TypedObject<IColor.Serializable, IColor, IStyleCollection>;
9
- export declare const BORDER_STROKE: TypedObject<IBorder.StrokeProperties<IColor.Serializable>, IBorder.IStroke, IStyleCollection>;
10
- export declare const CELL_BORDER: TypedObject<IBorder.Properties, IBorder, IStyleCollection>;
10
+ export declare const BORDER_STROKE: TypedObject<IBorders.StrokeProperties<IColor.Serializable>, IBorders.IStroke, IStyleCollection>;
11
+ export declare const CELL_BORDER: TypedObject<IBorders.Properties, IBorders, IStyleCollection>;
11
12
  export declare const CELL_NUM_FMT: TypedObject<string | NumberFormat.Type | number, any, IStyleCollection>;
12
13
  export declare const CELL_FONT: TypedObject<IStyledFont.Properties, IStyledFont, IStyleCollection>;
13
14
  export declare const CELL_ALIGNMENT: TypedObject<ITextFrame.IAlignment.Properties, ITextFrame.IAlignment, IStyleCollection>;
@@ -18,6 +19,7 @@ export declare const GRADIENT_STOPS: TypedObject<(IFill.GradientStopProperties |
18
19
  export declare const FILL_GRADIENT: TypedObject<IFill.GradientProperties, IFill.IGradient, IStyleCollection>;
19
20
  export declare const FILL_PATTERN: TypedObject<IFill.PatternProperties, IFill.IPattern, IStyleCollection>;
20
21
  export declare const FILL: TypedObject<IFill.Properties | IFill.SolidProperties | IFill.GradientProperties | IFill.PatternProperties | IFill.NoneProperties, IFill.ISolid | IFill.IGradient | IFill.IPattern | IFill.INone, IStyleCollection>;
22
+ export declare const CELL_PROTECTION: TypedObject<ICellProtection.Properties, ICellProtection, IStyleCollection>;
21
23
  export declare const CELL_STYLE: TypedObject<IStyle.Properties, IStyle, IStyleCollection>;
22
24
  /**
23
25
  * The APPLY-direction cell style. Shares {@link CELL_STYLE}'s property tree but adds a `shorthand`
@@ -1,13 +1,37 @@
1
1
  import { IRange } from '@sheetxl/primitives';
2
2
  import { ITypes } from '../../type';
3
3
  import { ICellHeader } from '../../cell';
4
- import { IStyle } from '../../style';
5
- import { IBorder } from '../../border';
6
- import { ISpatialMap } from '../../collections';
4
+ import { IStyle, IStyleCollection } from '../../style';
5
+ import { IBorders } from '../../border';
6
+ import { ISheetProtection } from '../../sheetProtection';
7
+ import { ISpatialMap, ISpatialQuery } from '../../collections';
7
8
  /**
9
+ * `alwaysUnlocked` as a cell with these direct content properties resolves it: its own, then its
10
+ * named style's, then Normal's.
8
11
  * @internal
9
12
  */
10
- export declare function isEqualStrokeProperties(a: IBorder.StrokeProperties | undefined, b: IBorder.StrokeProperties | undefined): boolean;
13
+ export declare function resolveAlwaysUnlocked(styles: IStyleCollection, direct: Readonly<IStyle.Properties> | null | undefined): boolean;
14
+ /**
15
+ * `showFormulas` as a cell with these direct content properties resolves it: its own, then its
16
+ * named style's, then Normal's.
17
+ * @internal
18
+ */
19
+ export declare function resolveShowFormulas(styles: IStyleCollection, direct: Readonly<IStyle.Properties> | null | undefined): boolean;
20
+ /**
21
+ * The formula entries over `bounds` that protection lets a reader see.
22
+ *
23
+ * @remarks
24
+ * Every range-state read takes its formulas from here, so a hidden formula is not there for cells,
25
+ * regions, counts or copies alike. Saving, undo, writes and calculation read the formula map
26
+ * directly. Only a sheet that hides its formulas pays: each run is cut to the cells whose style
27
+ * grants `showFormulas`.
28
+ * @internal
29
+ */
30
+ export declare function searchVisibleFormulas(formulaSpatial: ISpatialQuery<any>, contentSpatial: ISpatialQuery<any>, bounds: IRange.Coords, protection: ISheetProtection | null | undefined, styles: IStyleCollection): ISpatialMap.Entry<any>[];
31
+ /**
32
+ * @internal
33
+ */
34
+ export declare function isEqualStrokeProperties(a: IBorders.StrokeProperties | undefined, b: IBorders.StrokeProperties | undefined): boolean;
11
35
  /**
12
36
  * Splits a border range into a new range with adjusted border properties.
13
37
  *
@@ -22,7 +46,7 @@ export declare function isEqualStrokeProperties(a: IBorder.StrokeProperties | un
22
46
  * carry explicit `null` clears (see SheetDirectStyle update form), and those must localize to the
23
47
  * same pieces a real stroke would.
24
48
  */
25
- export declare function splitBorderRange(border: IBorder.Properties, rangeFrom: IRange.Coords, rangeTo: IRange.Coords, isColumn: boolean): Partial<IBorder.Properties> | null | undefined;
49
+ export declare function splitBorderRange(border: IBorders.Properties, rangeFrom: IRange.Coords, rangeTo: IRange.Coords, isColumn: boolean): Partial<IBorders.Properties> | null | undefined;
26
50
  /**
27
51
  * Takes a range with a border and breaks it into range parts that can be used without
28
52
  * any coordinates.
@@ -30,7 +54,7 @@ export declare function splitBorderRange(border: IBorder.Properties, rangeFrom:
30
54
  * @remarks
31
55
  * * This allows for each cell style to know how to render it's borders without dereferencing from a range.
32
56
  * * This was designed for Excel export compatibility.
33
- * * We don't use in internally as we want the original 'border' intent to be maintained for
57
+ * * We don't use in internally as we want the original 'borders' intent to be maintained for
34
58
  * easy .toJSON and AI inference.
35
59
  * * A range that reaches the grid's terminal row/column (Excel's `<col style>` reads back as a
36
60
  * full-height range) has no closing border at the boundary, so no end sliver is split off
@@ -54,8 +78,14 @@ export interface StyleRangesJSON {
54
78
  * 1. Identifying the total style count for rows and columns if > than 50% then it converts
55
79
  * the styles into a style header.
56
80
  * 2. If then uses overlap CellRangeIterator to find any intersections.
81
+ *
82
+ * A style's border is relative to the range it is stored with (a row or column style's range is
83
+ * the whole row or column), so the ids are not position-independent: wherever a range is written
84
+ * smaller than the entry it came from, its id is re-derived from the style's JSON through `ids`,
85
+ * and two entries sharing an id agree on a crossing only if they draw the same edges there.
86
+ * Styles without a border take none of this.
57
87
  */
58
- export declare function promoteStylesToHeaders(styles: StyleRangesJSON, entireCoords: IRange.Coords): StyleRangesJSON;
88
+ export declare function promoteStylesToHeaders(styles: StyleRangesJSON, entireCoords: IRange.Coords, ids: Pick<IStyleCollection.IPersistScope, 'getElementJSON' | 'getElementID'>): StyleRangesJSON;
59
89
  /**
60
90
  * Performs a shift but uses the entire range to ensure edge styles.
61
91
  *
@@ -181,6 +181,8 @@ export interface ISheetHeader extends ITransaction.ITransactional, IListener.ISo
181
181
  */
182
182
  addListeners(listeners: ISheetHeader.IListeners, options?: IListener.Options): IListener.Remove;
183
183
  close(): void;
184
+ /** For runtime type checking. */
185
+ readonly isISheetHeader: true;
184
186
  }
185
187
  /**
186
188
  * {@inheritDoc ISheetHeader}
@@ -53,6 +53,18 @@ export declare class SheetHeader implements ISheetHeader {
53
53
  constructor(options: SheetHeader.ConstructorOptions);
54
54
  /** {@inheritDoc IListener.ISource.addListeners} */
55
55
  addListeners(listeners: ISheetHeader.IListeners, options?: IListener.Options): IListener.Remove;
56
+ /**
57
+ * Re-derive what is cached from the sheet's extent: the indexed sizes and the maximum index.
58
+ *
59
+ * @remarks
60
+ * The `onViewChange` listener above does this when it hears the sheet's extent change. An
61
+ * operation that changes the extent and then writes against it - `Sheet.setEntireSize` grows
62
+ * the sheet and then inserts into the new band, which is bounds-checked against the maximum
63
+ * index - cannot wait to be told, so it calls this.
64
+ *
65
+ * @internal
66
+ */
67
+ _invalidateExtent(): void;
56
68
  protected _invalidateMaxIndex(): void;
57
69
  protected _invalidSizes(force?: boolean): void;
58
70
  /**
@@ -153,6 +165,8 @@ export declare class SheetHeader implements ISheetHeader {
153
165
  toJSON(): ISheetHeader.JSON | null;
154
166
  get [Symbol.toStringTag](): string;
155
167
  toString(): string;
168
+ /** {@inheritDoc ISheetHeader.isISheetHeader} */
169
+ get isISheetHeader(): true;
156
170
  }
157
171
  /**
158
172
  * {@inheritDoc SheetHeader}
@@ -7,8 +7,8 @@ export interface ISheetProtection extends IProtection<ISheetProtection, ISheetPr
7
7
  /**
8
8
  * Retrieves the protection properties for the sheet.
9
9
  *
10
- * @returns The {@link ISheetProtection.Properties} object representing the current protection settings,
11
- * or `null` if the sheet is not locked.
10
+ * @returns The {@link ISheetProtection.Properties} the sheet protects with, kept while it is
11
+ * unprotected, or `null` when it has none.
12
12
  */
13
13
  getProperties(): Partial<ISheetProtection.Properties> | null;
14
14
  /**
@@ -90,17 +90,36 @@ export interface ISheetProtection extends IProtection<ISheetProtection, ISheetPr
90
90
  */
91
91
  isSortAllowed(): boolean;
92
92
  /**
93
- * Checks if selecting locked cells is protected on the sheet.
93
+ * Checks if formulas may be shown on the protected sheet.
94
94
  *
95
- * @returns `true` if selecting locked cells is locked, `false` otherwise.
95
+ * @returns `false` if the sheet hides its formulas while protected.
96
+ *
97
+ * @remarks
98
+ * * While this is `false`, a cell's formula shows only when its style grants it
99
+ * (`ICellProtection.isShowFormulas`) — an exception, the way an always-unlocked cell is one.
100
+ * * Defaults to `true`, and is always `true` while the sheet is not locked (including paused).
101
+ */
102
+ isShowFormulasAllowed(): boolean;
103
+ /**
104
+ * Checks if locked cells may be selected on the protected sheet.
105
+ *
106
+ * @returns `false` if the sheet refuses selection of its locked cells while protected.
107
+ *
108
+ * @remarks
109
+ * Defaults to `true`, and is always `true` while the sheet is not locked (including paused).
96
110
  */
97
111
  isSelectLockedCellsAllowed(): boolean;
98
112
  /**
99
- * Checks if selecting unlocked cells is protected on the sheet.
113
+ * Checks if unlocked cells may be selected on the protected sheet.
100
114
  *
101
- * @returns `true` if selecting unlocked cells is locked, `false` otherwise.
115
+ * @returns `false` if the sheet refuses selection of its unlocked cells while protected.
116
+ *
117
+ * @remarks
118
+ * Defaults to `true`, and is always `true` while the sheet is not locked (including paused).
102
119
  */
103
120
  isSelectUnlockedCellsAllowed(): boolean;
121
+ /** For runtime type checking. */
122
+ readonly isISheetProtection: true;
104
123
  }
105
124
  /**
106
125
  * {@inheritDoc ISheetProtection}
@@ -110,6 +129,12 @@ export interface ISheetProtection extends IProtection<ISheetProtection, ISheetPr
110
129
  * {@link ISheetProtection}
111
130
  */
112
131
  export declare namespace ISheetProtection {
132
+ /**
133
+ * @remarks
134
+ * There is no whole-sheet flag here: changing it is {@link IProtection.lock} and
135
+ * {@link IProtection.unlock}, reading it {@link ISheetProtection.isLocked}. It is saved as
136
+ * {@link ISheetProtection.JSON.sheet}.
137
+ */
113
138
  interface Properties extends IProtection.Properties {
114
139
  /** {@inheritDoc ISheetProtection.isAutoTableAllowed} */
115
140
  autoTable?: boolean;
@@ -141,9 +166,18 @@ export declare namespace ISheetProtection {
141
166
  selectUnlockedCells?: boolean;
142
167
  /** {@inheritDoc ISheetProtection.isSortAllowed} */
143
168
  sort?: boolean;
144
- sheet?: boolean;
169
+ /** {@inheritDoc ISheetProtection.isShowFormulasAllowed} */
170
+ showFormulas?: boolean;
145
171
  }
146
172
  interface JSON extends ISheetProtection.Properties, IProtection.JSON {
173
+ /**
174
+ * `true` when the whole sheet stays allowed: it is not protected, and keeps its options for the
175
+ * next lock. Absent, the sheet is protected.
176
+ *
177
+ * @remarks
178
+ * Like every allowance here, the inverse of its OOXML attribute (`sheet="1"` is protected).
179
+ */
180
+ sheet?: boolean;
147
181
  }
148
182
  type PropertyKeys = (keyof ISheetProtection.Properties);
149
183
  }
@@ -27,13 +27,25 @@ export declare class SheetProtection extends DefaultProtection<ISheetProtection,
27
27
  isScenariosAllowed(): boolean;
28
28
  /** {@inheritDoc ISheetProtection.isSortAllowed} */
29
29
  isSortAllowed(): boolean;
30
+ /** {@inheritDoc ISheetProtection.isShowFormulasAllowed} */
31
+ isShowFormulasAllowed(): boolean;
32
+ /** {@inheritDoc ISheetProtection.isSelectLockedCellsAllowed} */
30
33
  isSelectLockedCellsAllowed(): boolean;
34
+ /** {@inheritDoc ISheetProtection.isSelectUnlockedCellsAllowed} */
31
35
  isSelectUnlockedCellsAllowed(): boolean;
36
+ /**
37
+ * A property that a locked sheet must deny explicitly: unset is allowed, and read-only does not
38
+ * deny it. The opposite of {@link _isPropertyAllowed}, which a locked sheet must grant explicitly.
39
+ */
40
+ protected _isPropertyAllowedByDefault(property: ISheetProtection.PropertyKeys): boolean;
41
+ protected _getAllowedKey(): string;
32
42
  protected _updateProperties(properties: ISheetProtection.Properties | null): void;
33
43
  protected _clearProperties(): void;
34
44
  protected _fromJSON(json: ISheetProtection.JSON | null): void;
35
45
  protected _toJSON(json: ISheetProtection.JSON): ISheetProtection.JSON;
36
46
  get [Symbol.toStringTag](): string;
37
47
  toString(): string;
48
+ /** {@inheritDoc ISheetProtection.isISheetProtection} */
49
+ get isISheetProtection(): true;
38
50
  }
39
51
  //# sourceMappingURL=SheetProtection.d.ts.map
@@ -17,6 +17,15 @@ import { ISheet } from '../sheet';
17
17
  * * Multiple views can be associated to the same collection of data, each providing a different way of viewing and interacting.
18
18
  */
19
19
  export interface ISheetView extends IMovableSelection, IListener.ISource<IMovableSelection> {
20
+ /**
21
+ * Identifies this view.
22
+ *
23
+ * @remarks
24
+ * Stable for the life of the view. A sheet can be shown through more than one view — each user
25
+ * in a shared workbook has their own — so anything recorded against a view (a restored
26
+ * selection, for example) names it by this id rather than holding the view itself.
27
+ */
28
+ getId(): string;
20
29
  /**
21
30
  * The top left scroll position of the (main) pane.
22
31
  *
@@ -31,7 +40,7 @@ export interface ISheetView extends IMovableSelection, IListener.ISource<IMovabl
31
40
  getTopLeft(): TopLeft;
32
41
  /**
33
42
  * The first VISIBLE cell — the cell sitting at the grid's top-left corner right now. `A1` when
34
- * unscrolled.
43
+ * un-scrolled.
35
44
  *
36
45
  * @remarks
37
46
  * The cell-coordinate reading of {@link getTopLeft} (which is base px), resolved against the row /
@@ -157,6 +166,37 @@ export interface ISheetView extends IMovableSelection, IListener.ISource<IMovabl
157
166
  * @see {@link setShowFormulas}
158
167
  */
159
168
  isShowFormulas(): boolean;
169
+ /**
170
+ * Indicate whether the cells that sheet protection locks are shaded, leaving the ranges that stay
171
+ * editable clear.
172
+ *
173
+ * @defaultValue `false`
174
+ *
175
+ * @remarks
176
+ * Only meaningful while the sheet is protected: it shades what protection is actually holding
177
+ * shut, so an unprotected sheet has nothing to shade.
178
+ */
179
+ setShowLockedShading(showLockedShading: boolean): this;
180
+ /**
181
+ * @see {@link setShowLockedShading}
182
+ */
183
+ isShowLockedShading(): boolean;
184
+ /**
185
+ * Indicate whether cells whose value fails a data validation are marked.
186
+ *
187
+ * @defaultValue `false`
188
+ *
189
+ * @remarks
190
+ * The sheet's counterpart of Excel's *Circle Invalid Data*, except that the marks follow the
191
+ * values as they change. A cell is marked when its value fails any data validation covering it;
192
+ * a list cell is marked only when its value is not on the list. Not written to xlsx, where Excel
193
+ * keeps no such setting.
194
+ */
195
+ setShowInvalid(showInvalid: boolean): this;
196
+ /**
197
+ * @see {@link setShowInvalid}
198
+ */
199
+ isShowInvalid(): boolean;
160
200
  /**
161
201
  * Indicate whether the sheet is displayed right-to-left (the leftmost column on
162
202
  * the right). Persisted per sheet; round-trips through xlsx `sheetView@rightToLeft`.
@@ -329,6 +369,10 @@ export declare namespace ISheetView {
329
369
  zoomScale: number;
330
370
  /** {@inheritDoc ISheetView.setShowFormulas} */
331
371
  showFormulas: boolean;
372
+ /** {@inheritDoc ISheetView.setShowLockedShading} */
373
+ showLockedShading: boolean;
374
+ /** {@inheritDoc ISheetView.setShowInvalid} */
375
+ showInvalid: boolean;
332
376
  /** {@inheritDoc ISheetView.setShowZeros} */
333
377
  showZeros: boolean;
334
378
  /** {@inheritDoc ISheetView.setRightToLeft} */
@@ -17,7 +17,10 @@ export declare class SheetView implements ISheetView, IMovableSelection {
17
17
  protected _rangeSelectionRemoveListener: IListener.Remove;
18
18
  protected _emitter: ListenerEmitter<ISheetView, ISheetView.IListeners>;
19
19
  protected _movableSelection: readonly IMovable[];
20
+ protected _id: string;
20
21
  constructor(options: ISheetView.ConstructorOptions);
22
+ /** {@inheritDoc ISheetView.getId} */
23
+ getId(): string;
21
24
  /** {@inheritDoc ISheetView.addListeners} */
22
25
  addListeners(listeners: ISheetView.IListeners, options?: IListener.Options): IListener.Remove;
23
26
  /** {@inheritDoc ISheetView.setTopLeft} */
@@ -74,6 +77,14 @@ export declare class SheetView implements ISheetView, IMovableSelection {
74
77
  isShowFormulas(): boolean;
75
78
  /** {@inheritDoc ISheetView.setShowFormulas} */
76
79
  setShowFormulas(newValue: boolean): this;
80
+ /** {@inheritDoc ISheetView.isShowLockedShading} */
81
+ isShowLockedShading(): boolean;
82
+ /** {@inheritDoc ISheetView.setShowLockedShading} */
83
+ setShowLockedShading(newValue: boolean): this;
84
+ /** {@inheritDoc ISheetView.isShowInvalid} */
85
+ isShowInvalid(): boolean;
86
+ /** {@inheritDoc ISheetView.setShowInvalid} */
87
+ setShowInvalid(newValue: boolean): this;
77
88
  /** {@inheritDoc ISheetView.isRightToLeft} */
78
89
  isRightToLeft(): boolean;
79
90
  /** {@inheritDoc ISheetView.setRightToLeft} */
@@ -12,6 +12,8 @@ import { IModel } from '../model';
12
12
  export interface ISlicer extends IModel {
13
13
  toJSON(toResourceId?: (resource: IResource) => number | null): ISlicer.JSON | null;
14
14
  getDescription(): string;
15
+ /** For runtime type checking. */
16
+ readonly isISlicer: true;
15
17
  }
16
18
  export declare namespace ISlicer {
17
19
  /**
@@ -16,6 +16,8 @@ export declare class Slicer extends AbstractModel<State, ISlicer.JSON> implement
16
16
  getTypeDescription(): string;
17
17
  get [Symbol.toStringTag](): string;
18
18
  toString(): string;
19
+ /** {@inheritDoc ISlicer.isISlicer} */
20
+ get isISlicer(): true;
19
21
  }
20
22
  /**
21
23
  * Interfaces for creating `Slicer` items.
@@ -64,6 +64,8 @@ export interface ISort {
64
64
  * Clears the sort criteria and removes from sort levels.
65
65
  */
66
66
  delete(): void;
67
+ /** For runtime type checking. */
68
+ readonly isISort: true;
67
69
  }
68
70
  /**
69
71
  * Types used for sorting.
@@ -1,6 +1,9 @@
1
1
  import { ICollection } from '../type';
2
2
  /**
3
3
  * Contains a collection of interned strings.
4
+ *
5
+ * @remarks
6
+ * Keyed by the string's id, not ordered: iteration order is unspecified.
4
7
  */
5
8
  export interface IStringCollection extends ICollection<string>, ICollection.IPersistable {
6
9
  /**
@@ -30,6 +33,8 @@ export interface IStringCollection extends ICollection<string>, ICollection.IPer
30
33
  getById(id: number): string | null;
31
34
  /** {@inheritDoc ICollection.IPersistScope} */
32
35
  beginPersist(): ICollection.IPersistScope<IStringCollection.JSON>;
36
+ /** For runtime type checking. */
37
+ readonly isIStringCollection: true;
33
38
  }
34
39
  /**
35
40
  * {@inheritDoc IStringCollection}
@@ -1,6 +1,6 @@
1
- import { ICollection } from '../type';
1
+ import { ICollection, AbstractCollection } from '../type';
2
2
  import { IStringCollection } from './IStringCollection';
3
- export declare class StringCollection implements IStringCollection {
3
+ export declare class StringCollection extends AbstractCollection<string, IStringCollection.GetItemsOptions> implements IStringCollection {
4
4
  private _persistOpen;
5
5
  private _stringsByText;
6
6
  private _stringsById;
@@ -12,15 +12,15 @@ export declare class StringCollection implements IStringCollection {
12
12
  addMultiple(shared: string[], conflateDuplicates?: boolean): void;
13
13
  /** {@inheritDoc IStringCollection.add} */
14
14
  add(shared: string): number;
15
- /** {@inheritDoc ICollection.[Symbol.iterator]} */
16
- [Symbol.iterator](): IterableIterator<string>;
17
- /** {@inheritDoc IStringCollection.getItems} */
18
- getItems(options?: IStringCollection.GetItemsOptions): string[];
15
+ /** {@inheritDoc AbstractCollection._getItems} */
16
+ protected _getItems(options?: IStringCollection.GetItemsOptions): string[];
19
17
  /** {@inheritDoc IStringCollection.getById} */
20
18
  getById(id: number): string | null;
21
19
  /** {@inheritDoc ICollection.getCount} */
22
20
  getCount(): number;
23
21
  /** {@inheritDoc ICollection.IPersistable.beginPersist} */
24
22
  beginPersist(): ICollection.IPersistScope<IStringCollection.JSON>;
23
+ /** {@inheritDoc IStringCollection.isIStringCollection} */
24
+ get isIStringCollection(): true;
25
25
  }
26
26
  //# sourceMappingURL=StringCollection.d.ts.map
@@ -0,0 +1,72 @@
1
+ import { ICollection } from '../type';
2
+ import { IThemeCollection } from '../theme';
3
+ import { IStyle } from './IStyle';
4
+ /**
5
+ * The named cell styles of a workbook — the built-ins (`Normal`, `Heading 1`, `Good`, ...) and
6
+ * the ones the document defines.
7
+ *
8
+ * @remarks
9
+ * Office Scripts calls these predefined cell styles (`Workbook.getPredefinedCellStyles()`).
10
+ *
11
+ * Order is the gallery's: the built-ins in their definition order, each replaced in place by a
12
+ * custom style of the same name, then the document's own styles by name. A hidden style is
13
+ * left out unless asked for — see {@link INamedStyleCollection.GetItemsOptions.includeHidden}.
14
+ *
15
+ * Reached from {@link IStyleCollection.getNamedStyles}.
16
+ */
17
+ export interface INamedStyleCollection extends ICollection<IStyle.INamed> {
18
+ /**
19
+ * Returns the style with the given name, or `null` if there is none.
20
+ *
21
+ * @param name The name, compared case-insensitively.
22
+ *
23
+ * @remarks
24
+ * A custom style of a built-in's name replaces the built-in, and is what is returned.
25
+ */
26
+ getByName(name: string): IStyle.INamed | null;
27
+ /**
28
+ * Adds or updates a style.
29
+ *
30
+ * @param update The name, the style, and any of the other {@link IStyle.NamedProperties}.
31
+ * @param mergeIfExists If `true` the style is merged over the existing one of that name;
32
+ * otherwise it replaces it. @defaultValue `false`
33
+ * @returns The style as stored.
34
+ *
35
+ * @remarks
36
+ * Names are case-insensitive. Setting a built-in's name customizes the built-in.
37
+ */
38
+ set(update: IStyle.NamedUpdate, mergeIfExists?: boolean): IStyle.INamed;
39
+ /**
40
+ * Returns the styles that match the filter, in gallery order.
41
+ *
42
+ * @param options {@link INamedStyleCollection.GetItemsOptions}
43
+ */
44
+ getItems(options?: INamedStyleCollection.GetItemsOptions): IStyle.INamed[];
45
+ /** For runtime type checking. */
46
+ readonly isINamedStyleCollection: true;
47
+ }
48
+ /**
49
+ * {@inheritDoc INamedStyleCollection}
50
+ * @see
51
+ * ### **Interface**
52
+ *
53
+ * {@link INamedStyleCollection}
54
+ */
55
+ export declare namespace INamedStyleCollection {
56
+ interface GetItemsOptions extends ICollection.GetItemsOptions {
57
+ /**
58
+ * Which styles: the built-ins, the document's own (a customized built-in is one of the
59
+ * document's own), or every style.
60
+ *
61
+ * @defaultValue `IThemeCollection.BuiltInFilterType.All`
62
+ */
63
+ type?: IThemeCollection.BuiltInFilterType;
64
+ /**
65
+ * Include styles marked hidden — a deleted built-in is a hidden one.
66
+ *
67
+ * @defaultValue `false`
68
+ */
69
+ includeHidden?: boolean;
70
+ }
71
+ }
72
+ //# sourceMappingURL=INamedStyleCollection.d.ts.map
@@ -6,7 +6,8 @@ import { IColor } from '../color';
6
6
  import { IFill } from '../fill';
7
7
  import { ITextFrame, IStyledFont } from '../text';
8
8
  import { IFont } from '../font';
9
- import { IBorder } from '../border';
9
+ import { IBorders } from '../border';
10
+ import { ICellProtection } from '../cell';
10
11
  import { NumberFormat } from '../numFmt';
11
12
  /**
12
13
  * The `IStyle` interface combines user-applied styles with dynamic styles, such as those from tables or conditional
@@ -37,19 +38,31 @@ export interface IStyle {
37
38
  */
38
39
  setQuotePrefix(quotePrefix: boolean | null, options?: IStyle.UpdateOptions): IStyle;
39
40
  /**
40
- * Returns the border style.
41
+ * Returns the protection format: whether the cell stays editable, and whether it shows its
42
+ * formula, while its sheet is protected.
41
43
  */
42
- getBorder(): IBorder;
44
+ getProtection(): ICellProtection;
43
45
  /**
44
- * Sets the border style.
46
+ * Sets the protection format.
45
47
  *
46
- * This method allows updating borders using an {@link IBorder} or a shorthand property object.
48
+ * @param protection The protection or a partial property object to apply. Pass `null` to clear.
49
+ * @param options Optional configuration for the update.
50
+ */
51
+ setProtection(protection: ICellProtection.Update, options?: IStyle.UpdateOptions): IStyle;
52
+ /**
53
+ * Returns the borders.
54
+ */
55
+ getBorders(): IBorders;
56
+ /**
57
+ * Sets the borders.
47
58
  *
48
- * @param border The border object or a shorthand property object to apply. Pass `null` to clear.
59
+ * This method allows updating borders using an {@link IBorders} or a shorthand property object.
60
+ *
61
+ * @param borders The borders object or a shorthand property object to apply. Pass `null` to clear.
49
62
  * @param options Optional configuration for the update.
50
- * @returns The `IBorder` object for further modifications.
63
+ * @returns The `IBorders` object for further modifications.
51
64
  */
52
- setBorder(border: IBorder.Update, options?: IStyle.UpdateOptions): IStyle;
65
+ setBorders(borders: IBorders.Update, options?: IStyle.UpdateOptions): IStyle;
53
66
  /**
54
67
  * Fill properties for the background.
55
68
  */
@@ -225,9 +238,9 @@ export declare namespace IStyle {
225
238
  * Border properties.
226
239
  *
227
240
  * @see
228
- * {@link IStyle.getBorder}
241
+ * {@link IStyle.getBorders}
229
242
  */
230
- border?: IBorder.Properties;
243
+ borders?: IBorders.Properties;
231
244
  /**
232
245
  * Quote Prefix property.
233
246
  *
@@ -235,6 +248,13 @@ export declare namespace IStyle {
235
248
  * {@link IStyle.getQuotePrefix}
236
249
  */
237
250
  quotePrefix?: boolean;
251
+ /**
252
+ * Protection properties.
253
+ *
254
+ * @see
255
+ * {@link IStyle.getProtection}
256
+ */
257
+ protection?: ICellProtection.Properties;
238
258
  /**
239
259
  * Named style property.
240
260
  *