@sheetxl/formulas 0.8.0-beta.1 → 0.8.0-beta.3

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 (111) hide show
  1. package/README.md +15 -22
  2. package/browser/cjs/B6vy56yEA1I3B74O.cjs +1 -0
  3. package/browser/cjs/BcROQ4pvVajDQ1em.cjs +1 -0
  4. package/browser/cjs/{CRx1WvmgBjT8WVyB.cjs → C0g87ndP2zMUbX6f.cjs} +1 -1
  5. package/browser/cjs/C9q3zr8iCIoYDrdA.cjs +1 -0
  6. package/browser/cjs/CVHc_cJddJk7J3Zt.cjs +1 -0
  7. package/browser/cjs/{EeOVMRq7TuptFKTc.cjs → DF4l8xrxkcLkgExp.cjs} +1 -1
  8. package/browser/cjs/{Du4jBiFxRIF1OjD4.cjs → Dtxj9JR14A-uliu5.cjs} +1 -1
  9. package/browser/cjs/{CpJJh4UnFl1_qFui.cjs → Dx7GQ4ALtNG3kshu.cjs} +1 -1
  10. package/browser/cjs/index.cjs +1 -1
  11. package/{node/esm/Crb70T1Sp1S4uzq4.mjs → browser/esm/2fdplP7jj4bf9aCO.mjs} +2 -2
  12. package/browser/esm/{Bsb5i9Jq-Q8RTmvi.mjs → B7oeajl5_4jZhg1U.mjs} +1 -1
  13. package/browser/esm/{C7mAHEhFYDwSEU6O.mjs → BHET8V48YsNHt6OQ.mjs} +1 -1
  14. package/browser/esm/{DKFABgVKeBMflym9.mjs → BTdrlwsC44d78M6y.mjs} +1 -1
  15. package/browser/esm/{DtqLXxtPFISlNoUd.mjs → Bn3FsWESsJTzyaf4.mjs} +1 -1
  16. package/{node/esm/CCGjvL3YYwY09qF-.mjs → browser/esm/Bo7Cdsg6xFJcfM2I.mjs} +1 -1
  17. package/{node/esm/D2miaIrotHbpdWei.mjs → browser/esm/C-oFWt8pnPP-GVRA.mjs} +1 -1
  18. package/{node/esm/CkG4LZN-kb7plKXG.mjs → browser/esm/C5BfcrpiUcRVOBhm.mjs} +69 -4
  19. package/{node/esm/C9jpXFBeugwmOTbx.mjs → browser/esm/CCVWnizQrKmoAuCq.mjs} +2 -2
  20. package/browser/esm/{B7750ljsJF3qA9kU.mjs → COY1_1oXpyxOqH8F.mjs} +37 -3
  21. package/{node/esm/CG1Fn8D-2DrQZoD5.mjs → browser/esm/COxwtE73KoR2iWjR.mjs} +1 -1
  22. package/{node/esm/HgVmqQQhKQ_2v0HD.mjs → browser/esm/CiV3-7Z2N5XTPGpW.mjs} +2 -2
  23. package/{node/esm/CWAtVXxcIz86XLzE.mjs → browser/esm/Cvqs42hxCdRyGkOU.mjs} +1 -1
  24. package/browser/esm/{BYRjnggsufwbb27W.mjs → CyZAJHWFmctZ67Gr.mjs} +1 -1
  25. package/browser/esm/{-f-RKKojiLg94hp9.mjs → D0bH0XCUaTcJPN0I.mjs} +51 -11
  26. package/{node/esm/BzNFsi4RXuJrn_1n.mjs → browser/esm/D47uFhCNkVeulQHC.mjs} +1 -1
  27. package/{node/esm/Ct1gudv1TKk-5FMO.mjs → browser/esm/DFmMjSD0S1dmLV9j.mjs} +48 -2
  28. package/browser/esm/{B3pEie3jQN0SvV5B.mjs → DQFv41Ho5OgGtsO6.mjs} +1 -1
  29. package/browser/esm/{BR2ai1V5dGPphpRf.mjs → DZQP6n94wjUf7gh-.mjs} +2 -5
  30. package/browser/esm/{Cdl7ZalV6WPZHHRE.mjs → dInAtbi5okqOaY-T.mjs} +1 -1
  31. package/browser/esm/index.mjs +4863 -5072
  32. package/browser/esm/{Cyvobf2wi0quDD3U.mjs → jigjASYVbU6Fnqi2.mjs} +1 -1
  33. package/browser/esm/{CltdofO5ik8g_wQ8.mjs → lGpYdO1T9FmC6pk7.mjs} +1 -1
  34. package/browser/esm/{BM1YhvA2ppUZ3QLB.mjs → o_58F5W4flwhkBQc.mjs} +1 -1
  35. package/browser/esm/{CVv3DuciDQrnFFeu.mjs → vtj_jhVSTyj6cY8v.mjs} +1 -1
  36. package/browser/esm/{0amsHACCOHE_JjXI.mjs → y5kSs5KEnqsOSkuQ.mjs} +1 -1
  37. package/licenses/dependencies.txt +0 -33
  38. package/node/esm/{DxRD19RVMzj2YvKF.mjs → 2KrV5IunXEqYRPKJ.mjs} +1 -1
  39. package/{browser/esm/Crb70T1Sp1S4uzq4.mjs → node/esm/2fdplP7jj4bf9aCO.mjs} +2 -2
  40. package/{browser/esm/Ct1gudv1TKk-5FMO.mjs → node/esm/B8Q2nBHA3421d2De.mjs} +48 -2
  41. package/node/esm/{C7mAHEhFYDwSEU6O.mjs → BHET8V48YsNHt6OQ.mjs} +1 -1
  42. package/node/esm/{DKFABgVKeBMflym9.mjs → BTdrlwsC44d78M6y.mjs} +1 -1
  43. package/node/esm/{DtqLXxtPFISlNoUd.mjs → Bn3FsWESsJTzyaf4.mjs} +1 -1
  44. package/{browser/esm/CCGjvL3YYwY09qF-.mjs → node/esm/Bo7Cdsg6xFJcfM2I.mjs} +1 -1
  45. package/node/esm/{ZUay0bTGgyrF8e04.mjs → Bx-wAScb1XcOsbcE.mjs} +1 -1
  46. package/{browser/esm/D2miaIrotHbpdWei.mjs → node/esm/C-oFWt8pnPP-GVRA.mjs} +1 -1
  47. package/{browser/esm/CkG4LZN-kb7plKXG.mjs → node/esm/C5BfcrpiUcRVOBhm.mjs} +69 -4
  48. package/{browser/esm/C9jpXFBeugwmOTbx.mjs → node/esm/CCVWnizQrKmoAuCq.mjs} +2 -2
  49. package/node/esm/{B7750ljsJF3qA9kU.mjs → COY1_1oXpyxOqH8F.mjs} +37 -3
  50. package/{browser/esm/CG1Fn8D-2DrQZoD5.mjs → node/esm/COxwtE73KoR2iWjR.mjs} +1 -1
  51. package/{browser/esm/HgVmqQQhKQ_2v0HD.mjs → node/esm/CiV3-7Z2N5XTPGpW.mjs} +2 -2
  52. package/node/esm/{DDajoVNkJB39_Fkx.mjs → CqHyaF_3jzclX-4h.mjs} +1 -1
  53. package/{browser/esm/CWAtVXxcIz86XLzE.mjs → node/esm/Cvqs42hxCdRyGkOU.mjs} +1 -1
  54. package/{browser/esm/BzNFsi4RXuJrn_1n.mjs → node/esm/D47uFhCNkVeulQHC.mjs} +1 -1
  55. package/node/esm/{B8rSUcOwH6g4MUgm.mjs → DEvaxgU5D42eGtON.mjs} +1 -1
  56. package/node/esm/{BR2ai1V5dGPphpRf.mjs → DZQP6n94wjUf7gh-.mjs} +2 -5
  57. package/node/esm/{Cdl7ZalV6WPZHHRE.mjs → dInAtbi5okqOaY-T.mjs} +1 -1
  58. package/node/esm/index.mjs +5525 -3899
  59. package/node/esm/{-f-RKKojiLg94hp9.mjs → jVWpjaeDtzGmzWIs.mjs} +51 -11
  60. package/node/esm/{Cyvobf2wi0quDD3U.mjs → jigjASYVbU6Fnqi2.mjs} +1 -1
  61. package/node/esm/{CltdofO5ik8g_wQ8.mjs → lGpYdO1T9FmC6pk7.mjs} +1 -1
  62. package/node/esm/{2TCIoMd-SYs6i4-N.mjs → ly86gfj1I6wMAUqu.mjs} +1 -1
  63. package/node/esm/{CVv3DuciDQrnFFeu.mjs → vtj_jhVSTyj6cY8v.mjs} +1 -1
  64. package/package.json +4 -5
  65. package/types/src/.generated/decl/dateTime/Date.decl.d.ts +2 -1
  66. package/types/src/.generated/decl/information/Information.decl.d.ts +2 -1
  67. package/types/src/.generated/decl/lookupReference/Reference.decl.d.ts +2 -1
  68. package/types/src/.generated/decl/mathTrig/Math.decl.d.ts +2 -1
  69. package/types/src/.generated/desc/dateTime/Date.desc.d.ts +2 -1
  70. package/types/src/.generated/desc/information/Information.desc.d.ts +2 -1
  71. package/types/src/.generated/desc/lookupReference/Reference.desc.d.ts +2 -1
  72. package/types/src/.generated/desc/mathTrig/Math.desc.d.ts +2 -1
  73. package/types/src/_utils/AValues.d.ts +30 -0
  74. package/types/src/_utils/AggregateIFS.d.ts +3 -1
  75. package/types/src/_utils/Arithmetic.d.ts +36 -0
  76. package/types/src/_utils/Combinatorics.d.ts +20 -0
  77. package/types/src/_utils/Distributions.d.ts +94 -0
  78. package/types/src/_utils/Errors.d.ts +1 -20
  79. package/types/src/_utils/FirstCell.d.ts +32 -0
  80. package/types/src/_utils/Matrix.d.ts +31 -0
  81. package/types/src/_utils/SpecialFunctions.d.ts +91 -0
  82. package/types/src/_utils/X87.d.ts +28 -0
  83. package/types/src/database/Database.d.ts +25 -25
  84. package/types/src/dateTime/Date.d.ts +250 -41
  85. package/types/src/engineering/Bessel.d.ts +9 -9
  86. package/types/src/engineering/Bitwise.d.ts +35 -35
  87. package/types/src/engineering/Convert.d.ts +3 -3
  88. package/types/src/engineering/Engineering.d.ts +5 -5
  89. package/types/src/engineering/Error.d.ts +9 -9
  90. package/types/src/engineering/Imaginary.d.ts +54 -54
  91. package/types/src/information/Information.d.ts +118 -49
  92. package/types/src/japanese/Date.d.ts +2 -2
  93. package/types/src/japanese/Text.d.ts +1 -1
  94. package/types/src/logical/Logical.d.ts +45 -39
  95. package/types/src/lookupReference/GroupBy.d.ts +4 -4
  96. package/types/src/lookupReference/PivotBy.d.ts +4 -4
  97. package/types/src/lookupReference/Reference.d.ts +212 -86
  98. package/types/src/mathTrig/Math.d.ts +499 -152
  99. package/types/src/mathTrig/Trig.d.ts +26 -22
  100. package/types/src/operators/Operators.d.ts +15 -15
  101. package/types/src/statistical/Distribution.d.ts +157 -161
  102. package/types/src/statistical/Statistical.d.ts +37 -37
  103. package/types/src/testing/Testing.d.ts +2 -2
  104. package/types/src/text/Text.d.ts +119 -54
  105. package/types/src/thai/Text.d.ts +1 -1
  106. package/types/src/web/FilterXML.d.ts +1 -1
  107. package/types/src/web/Web.d.ts +2 -2
  108. package/browser/cjs/49_x589Na12sizKK.cjs +0 -1
  109. package/browser/cjs/C9C-pr-T_ThweQX9.cjs +0 -1
  110. package/browser/cjs/DCIlWcGDrp-5PDoA.cjs +0 -1
  111. package/browser/cjs/Kvn916ebqGc4t6hv.cjs +0 -1
@@ -1,33 +1,107 @@
1
- import { FormulaError, AcceptError, AcceptRefError, Scalar, IReferenceRange, IRange, Flatten } from '@sheetxl/primitives';
2
- /**
3
- * @summary Returns information about the cell.
4
- * @param {'address' | 'col' | 'contents' | 'row' | 'type'} infoType The type of information to return.
5
- * @param infoType
6
- * @param reference
1
+ import { FormulaError, AcceptError, NoLift, ReportType, Scalar, Volatile, IReferenceRange, IRange, Flatten } from '@sheetxl/primitives';
2
+ /**
3
+ * The information to return about the cell.
4
+ */
5
+ declare enum CellInfoType {
6
+ /** Reference of the first cell in the reference, as text. */
7
+ Address = "address",
8
+ /** Column number of the cell in the reference. */
9
+ Col = "col",
10
+ /**
11
+ * 1 if the cell is formatted in color for negative values; otherwise 0.
12
+ * @deprecated Excel desktop only
13
+ */
14
+ Color = "color",
15
+ /** Value of the upper-left cell in the reference; not a formula. */
16
+ Contents = "contents",
17
+ /**
18
+ * Full path of the file that contains the reference, as text.
19
+ * @deprecated Excel desktop only
20
+ */
21
+ Filename = "filename",
22
+ /**
23
+ * Text value corresponding to the number format of the cell.
24
+ * @deprecated Excel desktop only
25
+ */
26
+ Format = "format",
27
+ /**
28
+ * 1 if the cell is formatted with parentheses for positive or all values; otherwise 0.
29
+ * @deprecated Excel desktop only
30
+ */
31
+ Parentheses = "parentheses",
32
+ /**
33
+ * Text value corresponding to the label prefix of the cell.
34
+ * @deprecated Excel desktop only
35
+ */
36
+ Prefix = "prefix",
37
+ /**
38
+ * 0 if the cell is not locked; otherwise 1.
39
+ * @deprecated Excel desktop only
40
+ */
41
+ Protect = "protect",
42
+ /** Row number of the cell in the reference. */
43
+ Row = "row",
44
+ /** "b" for a blank cell, "l" for a text constant, "v" for anything else. */
45
+ Type = "type",
46
+ /**
47
+ * Column width of the cell, rounded to an integer.
48
+ * @deprecated Excel desktop only
49
+ */
50
+ Width = "width"
51
+ }
52
+ /**
53
+ * Returns information about the cell.
54
+ * @param infoType The type of information to return.
55
+ * @param reference The cell to report on. Defaults to the cell holding the formula.
7
56
  *
8
57
  * @remarks
9
58
  * This has similar functionality to Excel online but is missing formatting information from Excel desktop.
10
59
  * {@link https://support.office.com/client/results?authtype=unknown&lcid=1033&locale=en-us&ns=EXCEL&syslcid=1033&uilcid=1033&version=90&helpid=xlmain11.chm60173}
11
60
  */
12
- export declare function CELL(infoType: string, reference?: AcceptError<IReferenceRange>): Scalar;
61
+ export declare function CELL(infoType: CellInfoType, reference?: IReferenceRange): Volatile<Scalar>;
13
62
  /**
63
+ * Returns a number matching an error value.
14
64
  * @name ERROR.TYPE
15
- * @summary Returns a number matching an error value.
16
65
  * @param errorVal is the error value for which you want the identifying number, and can be an actual error value or a reference to a cell containing an error value.
17
66
  */
18
67
  export declare function ERROR_TYPE(errorVal: AcceptError<Scalar>): Scalar;
19
- /**
20
- * @summary Returns information about the current operating system.
21
- * @param {'DIRECTORY' | 'NUMFILE' | 'ORIGIN' | 'OSVERSION' | 'RECALC' | 'RELEASE' | 'SYSTEM' | 'USER'} typeText The type of information to return.
22
- */
23
- export declare function INFO(typeText: string): string;
24
- /**
25
- * @summary Checks whether a reference is to an empty cell, and returns TRUE or FALSE.
68
+ /** The information to return about the operating environment. */
69
+ declare enum InfoType {
70
+ /** Path of the current directory or folder. */
71
+ Directory = "directory",
72
+ /** Amount of memory available. Legacy: answers #N/A. */
73
+ MemAvail = "memavail",
74
+ /** Amount of memory being used for data. Legacy: answers #N/A. */
75
+ MemUsed = "memused",
76
+ /** Number of active worksheets in the open workbooks. */
77
+ NumFile = "numfile",
78
+ /** Absolute reference of the top and leftmost visible cell. */
79
+ Origin = "origin",
80
+ /** Current operating system version, as text. */
81
+ OSVersion = "osversion",
82
+ /** Current recalculation mode; "Automatic" or "Manual". */
83
+ Recalc = "recalc",
84
+ /** Version of the application, as text. */
85
+ Release = "release",
86
+ /** Name of the operating environment; "pcdos" or "mac". */
87
+ System = "system",
88
+ /** Total memory available. Legacy: answers #N/A. */
89
+ TotMem = "totmem",
90
+ /** The licensed user. Not part of Excel. */
91
+ User = "user"
92
+ }
93
+ /**
94
+ * Returns information about the current operating system.
95
+ * @param typeText The type of information to return.
96
+ */
97
+ export declare function INFO(typeText: InfoType): Volatile<Scalar>;
98
+ /**
99
+ * Checks whether a reference is to an empty cell, and returns TRUE or FALSE.
26
100
  * @param value is the cell or a name that refers to the cell you want to test.
27
101
  */
28
102
  export declare function ISBLANK(value: AcceptError<Scalar>): boolean;
29
103
  /**
30
- * @summary Returns TRUE if the value is a date.
104
+ * Returns TRUE if the value is a date.
31
105
  * @param value The value to check.
32
106
  * @category Sheets
33
107
  *
@@ -59,108 +133,103 @@ export declare function ISBLANK(value: AcceptError<Scalar>): boolean;
59
133
  */
60
134
  export declare function ISDATE(value: Scalar): boolean;
61
135
  /**
62
- * @summary Returns TRUE if the value is a valid email address.
136
+ * Returns TRUE if the value is a valid email address.
63
137
  * @param value The value to check.
64
138
  * @category Sheets
65
139
  */
66
140
  export declare function ISEMAIL(value: string): boolean;
67
141
  /**
68
- * @summary Checks whether a value is an error other than #N/A, and returns TRUE or FALSE.
142
+ * Checks whether a value is an error other than #N/A, and returns TRUE or FALSE.
69
143
  * @param value is the value you want to test. Value can refer to a cell, a formula, or a name that refers to a cell, formula, or value.
70
144
  */
71
145
  export declare function ISERR(value: AcceptError<Scalar>): Scalar;
72
146
  /**
73
- * @summary Checks whether a value is an error, and returns TRUE or FALSE
147
+ * Checks whether a value is an error, and returns TRUE or FALSE
74
148
  * @param value is the value you want to test. Value can refer to a cell, a formula, or a name that refers to a cell, formula, or value
75
149
  */
76
150
  export declare function ISERROR(value: AcceptError<Scalar>): Scalar;
77
151
  /**
78
- * @summary Returns TRUE if the number is even.
152
+ * Returns TRUE if the number is even.
79
153
  * @param number is the value to test.
80
- *
81
- * @remarks
82
- * We take a range to error if a range.
83
154
  */
84
- export declare function ISEVEN(number: IRange<number>): Scalar;
155
+ export declare function ISEVEN(number: NoLift<Scalar>): Scalar;
85
156
  /**
86
- * @summary Checks whether a reference is to a cell containing a formula, and returns TRUE or FALSE.
157
+ * Checks whether a reference is to a cell containing a formula, and returns TRUE or FALSE.
87
158
  * @param reference is a reference to the cell you want to test. Reference can be a cell reference, a formula, or name that refers to a cell.
88
159
  */
89
- export declare function ISFORMULA(reference: AcceptError<IReferenceRange>): boolean;
160
+ export declare function ISFORMULA(reference: ReportType<IReferenceRange>): boolean;
90
161
  /**
91
- * @summary Checks whether a value is a logical value (TRUE or FALSE), and returns TRUE or FALSE.
162
+ * Checks whether a value is a logical value (TRUE or FALSE), and returns TRUE or FALSE.
92
163
  * @param value is the value you want to test. Value can refer to a cell, a formula, or a name that refers to a cell, formula, or value.
93
164
  */
94
165
  export declare function ISLOGICAL(value: AcceptError<Scalar>): boolean;
95
166
  /**
96
- * @summary Checks whether a value is #N/A, and returns TRUE or FALSE.
167
+ * Checks whether a value is #N/A, and returns TRUE or FALSE.
97
168
  * @param value is the value you want to test. Value can refer to a cell, a formula, or a name that refers to a cell, formula, or value.
98
169
  */
99
170
  export declare function ISNA(value: AcceptError<Scalar>): boolean;
100
171
  /**
101
- * @summary Checks whether a value is not text (blank cells are not text), and returns TRUE or FALSE.
172
+ * Checks whether a value is not text (blank cells are not text), and returns TRUE or FALSE.
102
173
  * @param value is the value you want tested: a cell; a formula; or a name referring to a cell, formula, or value.
103
174
  */
104
175
  export declare function ISNONTEXT(value: AcceptError<Scalar>): boolean;
105
176
  /**
106
- * @summary Checks whether a value is not text (blank cells are not text), and returns TRUE or FALSE.
177
+ * Checks whether a value is not text (blank cells are not text), and returns TRUE or FALSE.
107
178
  * @param value is the value you want tested: a cell; a formula; or a name referring to a cell, formula, or value.
108
179
  */
109
180
  export declare function ISNUMBER(value: AcceptError<Scalar>): boolean;
110
181
  /**
111
- * @summary Returns TRUE if the number is odd.
182
+ * Returns TRUE if the number is odd.
112
183
  * @param number is the value to test.
113
- *
114
- * @remarks
115
- * We take a range to error if a range.
116
184
  */
117
- export declare function ISODD(number: IRange<number>): Scalar;
185
+ export declare function ISODD(number: NoLift<Scalar>): Scalar;
118
186
  /**
119
- * @summary Checks whether the value is omitted, and returns TRUE or FALSE.
187
+ * Checks whether the value is omitted, and returns TRUE or FALSE.
120
188
  * @param argument is the value you want to test, such as a LAMBDA parameter.
121
189
  */
122
- export declare function ISOMITTED(argument: AcceptError<Scalar>): boolean;
190
+ export declare function ISOMITTED(argument: AcceptError<any>): boolean;
123
191
  /**
124
- * @summary Returns TRUE if the value is a valid HTTP or HTTPS URL.
192
+ * Returns TRUE if the value is a valid HTTP or HTTPS URL.
125
193
  * @param value The value to check.
126
194
  * @category Sheets
127
195
  */
128
196
  export declare function ISURL(value: string): boolean;
129
197
  /**
130
- * @summary Checks whether a value is a reference, and returns TRUE or FALSE.
198
+ * Checks whether a value is a reference, and returns TRUE or FALSE.
131
199
  * @param value is the value you want to test. Value can refer to a cell, a formula, or a name that refers to a cell, formula, or value.
132
200
  */
133
201
  export declare function ISREF(value: Flatten<AcceptError<IRange>>): boolean;
134
202
  /**
135
- * @summary Converts a value to text in a specific number format.
203
+ * Converts a value to text in a specific number format.
136
204
  * @param value is a number, a formula that evaluates to a numeric value, or a reference to a cell containing a numeric value.
137
205
  */
138
206
  export declare function ISTEXT(value: AcceptError<Scalar>): boolean;
139
207
  /**
140
- * @summary Converts non-number value to a number, dates to serial numbers, TRUE to 1, anything else to 0 (zero).
208
+ * Converts non-number value to a number, dates to serial numbers, TRUE to 1, anything else to 0 (zero).
141
209
  * @param value is the value to convert.
142
210
  */
143
- export declare function N(value: AcceptError<Scalar>): Scalar;
211
+ export declare function N(value: IRange | Scalar): Scalar;
144
212
  /**
145
- * @summary Returns the #N/A error value
213
+ * Returns the #N/A error value
146
214
  */
147
215
  export declare function NA(): FormulaError.Known;
148
- /**.
149
- * @summary Returns the sheet number of the referenced sheet.
216
+ /**
217
+ * Returns the sheet number of the referenced sheet.
150
218
  * @param value is the name of a sheet or a reference that you want the sheet number of. If omitted the number of the sheet containing the function is returned.
151
219
  */
152
- export declare function SHEET(value?: AcceptRefError<IRange>): Scalar;
220
+ export declare function SHEET(value?: ReportType<IRange>): Scalar;
153
221
  /**
154
- * @summary Returns the number of sheets in a reference.
222
+ * Returns the number of sheets in a reference.
155
223
  * @param reference is a reference for which you want to know the number of sheets it contains. If omitted the number of sheets in the workbook containing the function is returned.
156
224
  *
157
225
  * @remarks
158
226
  * A non-reference argument — a number, text, an array, a computed value — returns `#N/A`.
159
227
  */
160
- export declare function SHEETS(reference?: AcceptRefError<IRange>): number | FormulaError.Known;
228
+ export declare function SHEETS(reference?: ReportType<IRange>): number | FormulaError.Known;
161
229
  /**
162
- * @summary Returns an integer representing the data type of a value: number = 1; text = 2; logical value = 4; error value = 16; array = 64; compound data = 128.
230
+ * Returns an integer representing the data type of a value: number = 1; text = 2; logical value = 4; error value = 16; array = 64; compound data = 128.
163
231
  * @param value is the value to check.
164
232
  */
165
233
  export declare function TYPE(value: AcceptError<IRange>): number;
234
+ export {};
166
235
  //# sourceMappingURL=Information.d.ts.map
@@ -1,13 +1,13 @@
1
1
  import { Scalar } from '@sheetxl/primitives';
2
2
  /**
3
+ * Converts a standard date code into a localized text string.
3
4
  * @hidden Unimplemented Japanese.
4
- * @summary Converts a standard date code into a localized text string.
5
5
  * @param number A numeric value representing a date code.
6
6
  */
7
7
  export declare function DATESTRING(number: number): Scalar;
8
8
  /**
9
+ * Converts a number into Japanese Kanji words.
9
10
  * @hidden Unimplemented Japanese.
10
- * @summary Converts a number into Japanese Kanji words.
11
11
  * @param number A numeric value representing a date code.
12
12
  * @param number2 A numeric value representing a date code.
13
13
  */
@@ -1,7 +1,7 @@
1
1
  import { Scalar, IReferenceRange } from '@sheetxl/primitives';
2
2
  /**
3
+ * Returns the phonetic spelling of a text string.
3
4
  * @hidden Unimplemented Japanese.
4
- * @summary Returns the phonetic spelling of a text string.
5
5
  * @param reference Text string or a reference to a single cell or a range of cells that contain a furigana text string.
6
6
  */
7
7
  export declare function PHONETIC(reference: IReferenceRange): Scalar | undefined;
@@ -1,100 +1,106 @@
1
- import { IRange, AcceptError, AcceptRefError, IReferenceRange, Scalar, Lambda, Omittable, Repeating } from '@sheetxl/primitives';
1
+ import { IRange, AcceptError, IReferenceRange, Scalar, Lambda, Lazy, Omittable, Repeating } from '@sheetxl/primitives';
2
2
  /**
3
- * @summary Checks whether all arguments are TRUE, and returns TRUE if all arguments are TRUE.
3
+ * Checks whether all arguments are TRUE, and returns TRUE if all arguments are TRUE.
4
4
  * @param logical are 1 to 255 conditions you want to test that can be either TRUE or FALSE and can be logical values, arrays, or references.
5
5
  */
6
- export declare function AND(logical: IRange[]): Scalar;
6
+ export declare function AND(logical: IRange<boolean>[]): Scalar;
7
7
  /**
8
- * @summary Applies a LAMBDA function to each column and returns an array of the results.
8
+ * Applies a LAMBDA function to each column and returns an array of the results.
9
9
  * @param array is an array to be separated by column.
10
10
  * @param fn is a LAMBDA that takes a column as its single parameter and returns one result for it.
11
11
  */
12
- export declare function BYCOL(array: AcceptRefError<IRange>, fn?: Lambda<[column: IRange], Scalar>): IRange;
12
+ export declare function BYCOL(array: IRange, fn?: Lambda<[column: IRange], Scalar>): IRange;
13
13
  /**
14
- * @summary Applies a LAMBDA function to each row and returns an array of the results.
14
+ * Applies a LAMBDA function to each row and returns an array of the results.
15
15
  * @param array is an array to be separated by row.
16
16
  * @param fn is a LAMBDA that takes a row as its single parameter and returns one result for it.
17
17
  */
18
- export declare function BYROW(array: AcceptRefError<IRange>, fn?: Lambda<[row: IRange], Scalar>): IRange;
18
+ export declare function BYROW(array: IRange, fn?: Lambda<[row: IRange], Scalar>): IRange;
19
19
  /**
20
- * @summary Returns the logical value FALSE.
20
+ * Returns the logical value FALSE.
21
21
  */
22
22
  export declare function FALSE(): boolean;
23
23
  /**
24
- * @summary Flattens all the values from one or more ranges into a single column.
24
+ * Flattens all the values from one or more ranges into a single column.
25
25
  * @param ranges One or more ranges or scalar values to flatten.
26
26
  * @category Sheets
27
27
  */
28
- export declare function FLATTEN(ranges: AcceptError<IRange>[]): IRange;
28
+ export declare function FLATTEN(ranges: IRange[]): IRange;
29
29
  /**
30
- * @summary Checks whether a condition is met, and returns one value if TRUE, and another value if FALSE.
30
+ * Checks whether a condition is met, and returns one value if TRUE, and another value if FALSE.
31
31
  * @param logicalTest is any value or expression that can be evaluated to TRUE or FALSE.
32
32
  * @param valueIfTrue is the value that is returned if logicalTest is TRUE. If omitted, TRUE is returned. You can nest up to seven IF functions.
33
33
  * @param valueIfFalse is the value that is returned if logicalTest is FALSE. If omitted, FALSE is returned.
34
34
  */
35
- export declare function IF(logicalTest: boolean, valueIfTrue: AcceptError<any>, valueIfFalse?: AcceptError<any>): any;
35
+ export declare function IF(logicalTest: boolean, valueIfTrue: Lazy<AcceptError<any>>, valueIfFalse: Lazy<AcceptError<any>, false>): any;
36
36
  /**
37
- * @summary Returns valueIfError if expression is an error and the value of the expression itself otherwise.
37
+ * Returns valueIfError if expression is an error and the value of the expression itself otherwise.
38
38
  * @param value is any value or expression or reference.
39
39
  * @param valueIfError is any value or expression or reference.
40
40
  */
41
- export declare function IFERROR(value: AcceptError<Scalar>, valueIfError: AcceptError<any>): Scalar;
41
+ export declare function IFERROR(value: AcceptError<Scalar>, valueIfError: Lazy<AcceptError<any>>): Scalar;
42
42
  /**
43
- * @summary Returns the value you specify if the expression resolves to #N/A, otherwise returns the result of the expression.
43
+ * Returns the value you specify if the expression resolves to #N/A, otherwise returns the result of the expression.
44
44
  * @param value is any value or expression or reference.
45
45
  * @param valueIfNA is any value or expression or reference.
46
46
  */
47
- export declare function IFNA(value: AcceptError<Scalar>, valueIfNA: AcceptError<any>): Scalar;
47
+ export declare function IFNA(value: AcceptError<Scalar>, valueIfNA: Lazy<AcceptError<any>>): Scalar;
48
48
  /**
49
- * @summary Checks whether one or more conditions are met and returns a value corresponding to the first TRUE condition.
49
+ * Checks whether one or more conditions are met and returns a value corresponding to the first TRUE condition.
50
50
  * @param condition the conditions to test and the values to return for them.
51
51
  * @param condition.logicalTest is any value or expression that can be evaluated to TRUE or FALSE.
52
52
  * @param condition.logicalTrue is the value returned if logicalTest is TRUE.
53
+ *
54
+ * @remarks
55
+ * The search STOPS at the first TRUE condition, and a condition past it is never read: a
56
+ * `#DIV/0!` or an uncoercible text there does not surface. A fault reached BEFORE the match is
57
+ * fatal, which is why the test slot accepts errors and this body decides — the engine's own
58
+ * left-to-right propagation would refuse the whole call for a condition Excel never evaluates.
53
59
  */
54
- export declare function IFS(condition: Repeating<[logicalTest: boolean, logicalTrue: AcceptError<any>]>): any;
60
+ export declare function IFS(condition: Repeating<[logicalTest: AcceptError<boolean>, logicalTrue: AcceptError<any>], 254>): any;
55
61
  /**
56
- * @summary Creates a function value which can be called within formulas.
62
+ * Creates a function value which can be called within formulas.
57
63
  * @param parameterOrCalculation a parameter or a calculation that returns a value. If a parameter, it must be the last argument.
58
64
  */
59
- export declare function LAMBDA(parameterOrCalculation: AcceptError<IRange>[]): Lambda;
65
+ export declare function LAMBDA(parameterOrCalculation: Repeating<AcceptError<IRange>, 254>): Lambda;
60
66
  /**
61
- * @summary Assigns calculation results to names. Useful for storing intermediate calculations and values by defining names inside a formula. These names only apply within the scope of the LET function.
67
+ * Assigns calculation results to names. Useful for storing intermediate calculations and values by defining names inside a formula. These names only apply within the scope of the LET function.
62
68
  * @param name the name, or a calculation which can make use of all names within the LET. Names must start with a letter, cannot be the output of a formula, or conflict with range syntax.
63
69
  * @param nameOrValue the value associated with the name.
64
70
  */
65
- export declare function LET(name: AcceptError<any>, nameOrValue: AcceptError<IRange>, calculationOrName: AcceptError<IRange>, ...rest: AcceptError<IRange>[]): any;
71
+ export declare function LET(name: AcceptError<any>, nameOrValue: AcceptError<IRange>, calculationOrName: AcceptError<IRange>, ...rest: Repeating<AcceptError<IRange>, 254>): any;
66
72
  /**
67
- * @summary Returns a calculated array of a specified row and column size, by applying a LAMBDA function.
73
+ * Returns a calculated array of a specified row and column size, by applying a LAMBDA function.
68
74
  * @param rows is the number of rows in the array. Must be greater than zero.
69
75
  * @param columns is the number of columns in the array. Must be greater than zero.
70
76
  * @param fn is a LAMBDA that is called to create the array. The LAMBDA takes two parameters, row index and column index.
71
77
  */
72
78
  export declare function MAKEARRAY(rows: Omittable<number, 1>, columns: Omittable<number, 1>, fn: Lambda<[rowIndex: number, colIndex: number], Scalar>): IRange;
73
79
  /**
74
- * @summary Returns an array formed by 'mapping' each value in the array(s) to a new value by applying a lambda to create a new value.
80
+ * Returns an array formed by 'mapping' each value in the array(s) to a new value by applying a lambda to create a new value.
75
81
  * @param array is an array to be mapped.
76
82
  * @param lambdaOrArray is a LAMBDA which must be the last argument and must have a parameter for each array passed, or another array to be mapped.
77
83
  */
78
- export declare function MAP(array: AcceptRefError<IRange>, lambdaOrArray: (any | Lambda<any[], Scalar>)[]): IRange;
84
+ export declare function MAP(array: IRange, lambdaOrArray: AcceptError<any | Lambda<any[], Scalar>>[]): IRange;
79
85
  /**
80
- * @summary Changes FALSE to TRUE, or TRUE to FALSE.
86
+ * Changes FALSE to TRUE, or TRUE to FALSE.
81
87
  * @param logical is a value or expression that can be evaluated to TRUE or FALSE.
82
88
  */
83
89
  export declare function NOT(logical: boolean): boolean;
84
90
  /**
85
- * @summary Checks whether any of the arguments are TRUE, and returns TRUE or FALSE. Returns FALSE only if all arguments are FALSE.
91
+ * Checks whether any of the arguments are TRUE, and returns TRUE or FALSE. Returns FALSE only if all arguments are FALSE.
86
92
  * @param logical are 1 to 255 conditions that you want to test that can be either TRUE or FALSE.
87
93
  */
88
- export declare function OR(logical: IRange[]): Scalar;
94
+ export declare function OR(logical: IRange<boolean>[]): Scalar;
89
95
  /**
90
- * @summary Reduces an array to an accumulated value by applying a LAMBDA function to each value and returning the total value in the accumulator.
96
+ * Reduces an array to an accumulated value by applying a LAMBDA function to each value and returning the total value in the accumulator.
91
97
  * @param initialValue is the starting value for the accumulator.
92
98
  * @param array is an array to be reduced.
93
99
  * @param fn is a LAMBDA that is called to reduce the array. The LAMBDA takes two parameters, accumulator and value.
94
100
  */
95
- export declare function REDUCE(initialValue: Omittable<AcceptError<any>>, array: AcceptRefError<IRange>, fn: Lambda<[accumulator: any, value: Scalar], any>): any;
101
+ export declare function REDUCE(initialValue: Omittable<AcceptError<any>>, array: IRange, fn: Lambda<[accumulator: any, value: IRange | Scalar], any>): any;
96
102
  /**
97
- * @summary Reduces the cells specified by a given condition or criteria.
103
+ * Reduces the cells specified by a given condition or criteria.
98
104
  * @param range is the range of cells you want evaluated.
99
105
  * @param criteria is the condition or criteria in the form of a number, expression, or text that defines which cells will be reduced.
100
106
  * @param reduceRange are the actual cells to reduce. If omitted, the cells in range are used. This can be blank.
@@ -104,30 +110,30 @@ export declare function REDUCE(initialValue: Omittable<AcceptError<any>>, array:
104
110
  * @remarks
105
111
  * This is a lambda equivalent to SUMIF, COUNTIF, and AVERAGEIF.
106
112
  */
107
- export declare function REDUCEIF(range: AcceptError<IReferenceRange>, criteria: AcceptError<Scalar>, reduceRange: Omittable<AcceptError<IReferenceRange>>, fn: Lambda<[accumulator: Scalar, value: Scalar], Scalar>): Scalar;
113
+ export declare function REDUCEIF(range: IReferenceRange, criteria: AcceptError<Scalar>, reduceRange: Omittable<IReferenceRange>, fn: Lambda<[accumulator: Scalar, value: Scalar], Scalar>): Scalar;
108
114
  /**
109
- * @summary Scans an array by applying a LAMBDA function to each value and returns an array that has each intermediate value.
115
+ * Scans an array by applying a LAMBDA function to each value and returns an array that has each intermediate value.
110
116
  * @param initialValue is the starting value for the accumulator.
111
117
  * @param array is an array to be reduced.
112
118
  * @param fn is a LAMBDA that is called to reduce the array. The LAMBDA takes two parameters, accumulator and value.
113
119
  */
114
- export declare function SCAN(initialValue: Omittable<Scalar>, array: AcceptRefError<IRange>, fn: Lambda<[accumulator: Scalar, value: Scalar], Scalar>): IRange;
120
+ export declare function SCAN(initialValue: Omittable<AcceptError<any>>, array: IRange, fn: Lambda<[accumulator: any, value: IRange | Scalar], Scalar>): IRange;
115
121
  /**
116
- * @summary Evaluates an expression against a list of values and returns the result corresponding to the first matching value. If there is no match, an optional default value is returned.
122
+ * Evaluates an expression against a list of values and returns the result corresponding to the first matching value. If there is no match, an optional default value is returned.
117
123
  * @param match the values to compare against expression and the results to return for them.
118
124
  * @param match.value is a value to compare against expression.
119
125
  * @param match.result is a result to be returned if the corresponding value matches expression.
120
126
  * @param expression is an expression to be evaluated.
121
127
  * @param defaultResult is the result to be returned when no value matches expression.
122
128
  */
123
- export declare function SWITCH(expression: Scalar, match: Repeating<[value: Scalar, result: AcceptError<any>]>, defaultResult?: Omittable<AcceptError<any>, 0>): any;
129
+ export declare function SWITCH(expression: Scalar, match: Repeating<[value: AcceptError<Scalar>, result: AcceptError<any>], 254>, defaultResult?: Omittable<AcceptError<any>, 0>): any;
124
130
  /**
125
- * @summary Returns the logical value TRUE.
131
+ * Returns the logical value TRUE.
126
132
  */
127
133
  export declare function TRUE(): boolean;
128
134
  /**
129
- * @summary Returns a logical 'Exclusive Or' of all arguments.
135
+ * Returns a logical 'Exclusive Or' of all arguments.
130
136
  * @param logical are 1 to 254 conditions you want to test that can be either TRUE or FALSE and can be logical values, arrays, or references.
131
137
  */
132
- export declare function XOR(logical: IRange[]): Scalar;
138
+ export declare function XOR(logical: Repeating<IRange<boolean>, 254>): Scalar;
133
139
  //# sourceMappingURL=Logical.d.ts.map
@@ -1,7 +1,7 @@
1
- import { IRange, AcceptRefError, Flatten, Omittable, Scalar } from '@sheetxl/primitives';
1
+ import { IRange, Flatten, Omittable, Scalar } from '@sheetxl/primitives';
2
2
  /**
3
- * @hidden Unimplemented TODO
4
- * @summary Aggregate values by row fields.
3
+ * Aggregate values by row fields.
4
+ * @hidden Not yet implemented.
5
5
  * @param rowFields The range or array containing the row fields.
6
6
  * @param values The range or array containing the values to aggregate.
7
7
  * @param fn The function used to do the aggregations.
@@ -11,7 +11,7 @@ import { IRange, AcceptRefError, Flatten, Omittable, Scalar } from '@sheetxl/pri
11
11
  * @param filterArray param-534 paramName-535.
12
12
  * @param fieldRelationship The relationship of fields when multiple columns are supplied to the rowFields argument.
13
13
  */
14
- export declare function GROUPBY(rowFields: AcceptRefError<IRange>, values: IRange, fn: Flatten<any>, // This can be either a Lamda function or a builtIn.
14
+ export declare function GROUPBY(rowFields: IRange, values: IRange, fn: Flatten<any>, // This can be either a lambda function or a built-in.
15
15
  fieldHeaders?: Omittable<number>, // 0-no, 1-yes, 2-no but generate, 3-yes and show
16
16
  totalDepth?: number, // 0-no totals, 1-grand totals, 2-grand and subtotals, -1-grand totals at top, -2 grand and sub totals at top
17
17
  sortOrder?: Omittable<Flatten<any>>, // <0, >0
@@ -1,7 +1,7 @@
1
- import { IRange, AcceptRefError, Flatten, Omittable, Scalar } from '@sheetxl/primitives';
1
+ import { IRange, Flatten, Omittable, Scalar } from '@sheetxl/primitives';
2
2
  /**
3
- * @hidden Unimplemented TODO
4
- * @summary Aggregate values by rows and columns.
3
+ * Aggregate values by rows and columns.
4
+ * @hidden Not yet implemented.
5
5
  * @param rowFields The range or array containing the row fields.
6
6
  * @param colFields The range or array containing the column fields.
7
7
  * @param values The range or array containing the value fields.
@@ -14,7 +14,7 @@ import { IRange, AcceptRefError, Flatten, Omittable, Scalar } from '@sheetxl/pri
14
14
  * @param filterArray An array of boolean where TRUE represents a row to retain.
15
15
  * @param relativeTo Defines what PERCENTOF is calculated relative to.
16
16
  */
17
- export declare function PIVOTBY(rowFields: AcceptRefError<IRange>, colFields: AcceptRefError<IRange>, values: Flatten<IRange>, fn: Flatten<IRange>, // Wow, this is a lambda function? No. I don't think so...
17
+ export declare function PIVOTBY(rowFields: IRange, colFields: IRange, values: Flatten<IRange>, fn: Flatten<IRange>, // This can be either a lambda function or a built-in.
18
18
  fieldHeaders?: Omittable<number>, // 0-no, 1-yes, 2-no but generate, 3-yes and show
19
19
  rowTotalDepth?: number, // 0-no totals, 1-grand totals, 2-grand and subtotals, -1-grand totals at top, -2 grand and sub totals at top
20
20
  rowSortOrder?: Omittable<Flatten<any>>, // <0, >0