@univerjs/sheets-formula 0.24.0 → 0.25.0

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 (281) hide show
  1. package/lib/cjs/facade.js +4 -55
  2. package/lib/cjs/index.js +4040 -3694
  3. package/lib/cjs/locale/ar-SA.js +10538 -0
  4. package/lib/cjs/locale/ca-ES.js +10307 -6
  5. package/lib/cjs/locale/de-DE.js +10538 -0
  6. package/lib/cjs/locale/en-US.js +10532 -6
  7. package/lib/cjs/locale/es-ES.js +10307 -6
  8. package/lib/cjs/locale/fa-IR.js +10817 -6
  9. package/lib/cjs/locale/fr-FR.js +10783 -6
  10. package/lib/cjs/locale/id-ID.js +10538 -0
  11. package/lib/cjs/locale/it-IT.js +10538 -0
  12. package/lib/cjs/locale/ja-JP.js +10306 -6
  13. package/lib/cjs/locale/ko-KR.js +10306 -6
  14. package/lib/cjs/locale/pl-PL.js +10538 -0
  15. package/lib/cjs/locale/pt-BR.js +10538 -0
  16. package/lib/cjs/locale/ru-RU.js +10340 -6
  17. package/lib/cjs/locale/sk-SK.js +10306 -6
  18. package/lib/cjs/locale/vi-VN.js +10307 -6
  19. package/lib/cjs/locale/zh-CN.js +10307 -6
  20. package/lib/cjs/locale/zh-HK.js +10538 -0
  21. package/lib/cjs/locale/zh-TW.js +10307 -6
  22. package/lib/es/facade.js +6 -57
  23. package/lib/es/index.js +4036 -3697
  24. package/lib/es/locale/ar-SA.js +10537 -0
  25. package/lib/es/locale/ca-ES.js +10307 -6
  26. package/lib/es/locale/de-DE.js +10537 -0
  27. package/lib/es/locale/en-US.js +10532 -6
  28. package/lib/es/locale/es-ES.js +10307 -6
  29. package/lib/es/locale/fa-IR.js +10817 -6
  30. package/lib/es/locale/fr-FR.js +10783 -6
  31. package/lib/es/locale/id-ID.js +10537 -0
  32. package/lib/es/locale/it-IT.js +10537 -0
  33. package/lib/es/locale/ja-JP.js +10306 -6
  34. package/lib/es/locale/ko-KR.js +10306 -6
  35. package/lib/es/locale/pl-PL.js +10537 -0
  36. package/lib/es/locale/pt-BR.js +10537 -0
  37. package/lib/es/locale/ru-RU.js +10340 -6
  38. package/lib/es/locale/sk-SK.js +10306 -6
  39. package/lib/es/locale/vi-VN.js +10307 -6
  40. package/lib/es/locale/zh-CN.js +10307 -6
  41. package/lib/es/locale/zh-HK.js +10537 -0
  42. package/lib/es/locale/zh-TW.js +10307 -6
  43. package/lib/facade.js +6 -57
  44. package/lib/index.js +4036 -3697
  45. package/lib/locale/ar-SA.js +10537 -0
  46. package/lib/locale/ca-ES.js +10307 -6
  47. package/lib/locale/de-DE.js +10537 -0
  48. package/lib/locale/en-US.js +10532 -6
  49. package/lib/locale/es-ES.js +10307 -6
  50. package/lib/locale/fa-IR.js +10817 -6
  51. package/lib/locale/fr-FR.js +10783 -6
  52. package/lib/locale/id-ID.js +10537 -0
  53. package/lib/locale/it-IT.js +10537 -0
  54. package/lib/locale/ja-JP.js +10306 -6
  55. package/lib/locale/ko-KR.js +10306 -6
  56. package/lib/locale/pl-PL.js +10537 -0
  57. package/lib/locale/pt-BR.js +10537 -0
  58. package/lib/locale/ru-RU.js +10340 -6
  59. package/lib/locale/sk-SK.js +10306 -6
  60. package/lib/locale/vi-VN.js +10307 -6
  61. package/lib/locale/zh-CN.js +10307 -6
  62. package/lib/locale/zh-HK.js +10537 -0
  63. package/lib/locale/zh-TW.js +10307 -6
  64. package/lib/types/controllers/active-dirty.controller.d.ts +1 -0
  65. package/lib/types/controllers/formula-calculation-session.controller.d.ts +24 -0
  66. package/lib/types/controllers/trigger-calculation.controller.d.ts +1 -1
  67. package/lib/types/controllers/utils/ref-range-formula.d.ts +7 -1
  68. package/lib/types/facade/f-formula.d.ts +20 -19
  69. package/lib/types/facade/f-range.d.ts +3 -3
  70. package/lib/types/index.d.ts +3 -0
  71. package/lib/types/locale/ar-SA.d.ts +18 -0
  72. package/lib/types/locale/de-DE.d.ts +18 -0
  73. package/lib/types/locale/en-US.d.ts +10450 -7
  74. package/lib/types/locale/function-list/array/ca-ES.d.ts +18 -0
  75. package/lib/types/locale/function-list/array/en-US.d.ts +58 -0
  76. package/lib/types/locale/function-list/array/es-ES.d.ts +18 -0
  77. package/lib/types/locale/function-list/array/fa-IR.d.ts +18 -0
  78. package/lib/types/locale/function-list/array/fr-FR.d.ts +18 -0
  79. package/lib/types/locale/function-list/array/ja-JP.d.ts +18 -0
  80. package/lib/types/locale/function-list/array/ko-KR.d.ts +18 -0
  81. package/lib/types/locale/function-list/array/ru-RU.d.ts +18 -0
  82. package/lib/types/locale/function-list/array/sk-SK.d.ts +18 -0
  83. package/lib/types/locale/function-list/array/vi-VN.d.ts +18 -0
  84. package/lib/types/locale/function-list/array/zh-CN.d.ts +18 -0
  85. package/lib/types/locale/function-list/array/zh-TW.d.ts +18 -0
  86. package/lib/types/locale/function-list/compatibility/ca-ES.d.ts +18 -0
  87. package/lib/types/locale/function-list/compatibility/en-US.d.ts +838 -0
  88. package/lib/types/locale/function-list/compatibility/es-ES.d.ts +18 -0
  89. package/lib/types/locale/function-list/compatibility/fa-IR.d.ts +18 -0
  90. package/lib/types/locale/function-list/compatibility/fr-FR.d.ts +18 -0
  91. package/lib/types/locale/function-list/compatibility/ja-JP.d.ts +18 -0
  92. package/lib/types/locale/function-list/compatibility/ko-KR.d.ts +18 -0
  93. package/lib/types/locale/function-list/compatibility/ru-RU.d.ts +18 -0
  94. package/lib/types/locale/function-list/compatibility/sk-SK.d.ts +18 -0
  95. package/lib/types/locale/function-list/compatibility/vi-VN.d.ts +18 -0
  96. package/lib/types/locale/function-list/compatibility/zh-CN.d.ts +18 -0
  97. package/lib/types/locale/function-list/compatibility/zh-TW.d.ts +18 -0
  98. package/lib/types/locale/function-list/cube/ca-ES.d.ts +18 -0
  99. package/lib/types/locale/function-list/cube/en-US.d.ts +144 -0
  100. package/lib/types/locale/function-list/cube/es-ES.d.ts +18 -0
  101. package/lib/types/locale/function-list/cube/fa-IR.d.ts +18 -0
  102. package/lib/types/locale/function-list/cube/fr-FR.d.ts +18 -0
  103. package/lib/types/locale/function-list/cube/ja-JP.d.ts +18 -0
  104. package/lib/types/locale/function-list/cube/ko-KR.d.ts +18 -0
  105. package/lib/types/locale/function-list/cube/ru-RU.d.ts +18 -0
  106. package/lib/types/locale/function-list/cube/sk-SK.d.ts +18 -0
  107. package/lib/types/locale/function-list/cube/vi-VN.d.ts +18 -0
  108. package/lib/types/locale/function-list/cube/zh-CN.d.ts +18 -0
  109. package/lib/types/locale/function-list/cube/zh-TW.d.ts +18 -0
  110. package/lib/types/locale/function-list/database/ca-ES.d.ts +18 -0
  111. package/lib/types/locale/function-list/database/en-US.d.ts +282 -0
  112. package/lib/types/locale/function-list/database/es-ES.d.ts +18 -0
  113. package/lib/types/locale/function-list/database/fa-IR.d.ts +18 -0
  114. package/lib/types/locale/function-list/database/fr-FR.d.ts +18 -0
  115. package/lib/types/locale/function-list/database/ja-JP.d.ts +18 -0
  116. package/lib/types/locale/function-list/database/ko-KR.d.ts +18 -0
  117. package/lib/types/locale/function-list/database/ru-RU.d.ts +18 -0
  118. package/lib/types/locale/function-list/database/sk-SK.d.ts +18 -0
  119. package/lib/types/locale/function-list/database/vi-VN.d.ts +18 -0
  120. package/lib/types/locale/function-list/database/zh-CN.d.ts +18 -0
  121. package/lib/types/locale/function-list/database/zh-TW.d.ts +18 -0
  122. package/lib/types/locale/function-list/date/ca-ES.d.ts +18 -0
  123. package/lib/types/locale/function-list/date/en-US.d.ts +490 -0
  124. package/lib/types/locale/function-list/date/es-ES.d.ts +18 -0
  125. package/lib/types/locale/function-list/date/fa-IR.d.ts +18 -0
  126. package/lib/types/locale/function-list/date/fr-FR.d.ts +18 -0
  127. package/lib/types/locale/function-list/date/ja-JP.d.ts +18 -0
  128. package/lib/types/locale/function-list/date/ko-KR.d.ts +18 -0
  129. package/lib/types/locale/function-list/date/ru-RU.d.ts +18 -0
  130. package/lib/types/locale/function-list/date/sk-SK.d.ts +18 -0
  131. package/lib/types/locale/function-list/date/vi-VN.d.ts +18 -0
  132. package/lib/types/locale/function-list/date/zh-CN.d.ts +18 -0
  133. package/lib/types/locale/function-list/date/zh-TW.d.ts +18 -0
  134. package/lib/types/locale/function-list/engineering/ca-ES.d.ts +18 -0
  135. package/lib/types/locale/function-list/engineering/en-US.d.ts +940 -0
  136. package/lib/types/locale/function-list/engineering/es-ES.d.ts +18 -0
  137. package/lib/types/locale/function-list/engineering/fa-IR.d.ts +18 -0
  138. package/lib/types/locale/function-list/engineering/fr-FR.d.ts +18 -0
  139. package/lib/types/locale/function-list/engineering/ja-JP.d.ts +18 -0
  140. package/lib/types/locale/function-list/engineering/ko-KR.d.ts +18 -0
  141. package/lib/types/locale/function-list/engineering/ru-RU.d.ts +18 -0
  142. package/lib/types/locale/function-list/engineering/sk-SK.d.ts +18 -0
  143. package/lib/types/locale/function-list/engineering/vi-VN.d.ts +18 -0
  144. package/lib/types/locale/function-list/engineering/zh-CN.d.ts +18 -0
  145. package/lib/types/locale/function-list/engineering/zh-TW.d.ts +18 -0
  146. package/lib/types/locale/function-list/financial/ca-ES.d.ts +18 -0
  147. package/lib/types/locale/function-list/financial/en-US.d.ts +1608 -0
  148. package/lib/types/locale/function-list/financial/es-ES.d.ts +18 -0
  149. package/lib/types/locale/function-list/financial/fa-IR.d.ts +18 -0
  150. package/lib/types/locale/function-list/financial/fr-FR.d.ts +18 -0
  151. package/lib/types/locale/function-list/financial/ja-JP.d.ts +18 -0
  152. package/lib/types/locale/function-list/financial/ko-KR.d.ts +18 -0
  153. package/lib/types/locale/function-list/financial/ru-RU.d.ts +18 -0
  154. package/lib/types/locale/function-list/financial/sk-SK.d.ts +18 -0
  155. package/lib/types/locale/function-list/financial/vi-VN.d.ts +18 -0
  156. package/lib/types/locale/function-list/financial/zh-CN.d.ts +18 -0
  157. package/lib/types/locale/function-list/financial/zh-TW.d.ts +18 -0
  158. package/lib/types/locale/function-list/information/ca-ES.d.ts +18 -0
  159. package/lib/types/locale/function-list/information/en-US.d.ts +386 -0
  160. package/lib/types/locale/function-list/information/es-ES.d.ts +18 -0
  161. package/lib/types/locale/function-list/information/fa-IR.d.ts +18 -0
  162. package/lib/types/locale/function-list/information/fr-FR.d.ts +18 -0
  163. package/lib/types/locale/function-list/information/ja-JP.d.ts +18 -0
  164. package/lib/types/locale/function-list/information/ko-KR.d.ts +18 -0
  165. package/lib/types/locale/function-list/information/ru-RU.d.ts +18 -0
  166. package/lib/types/locale/function-list/information/sk-SK.d.ts +18 -0
  167. package/lib/types/locale/function-list/information/vi-VN.d.ts +18 -0
  168. package/lib/types/locale/function-list/information/zh-CN.d.ts +18 -0
  169. package/lib/types/locale/function-list/information/zh-TW.d.ts +18 -0
  170. package/lib/types/locale/function-list/logical/ca-ES.d.ts +18 -0
  171. package/lib/types/locale/function-list/logical/en-US.d.ts +390 -0
  172. package/lib/types/locale/function-list/logical/es-ES.d.ts +18 -0
  173. package/lib/types/locale/function-list/logical/fa-IR.d.ts +18 -0
  174. package/lib/types/locale/function-list/logical/fr-FR.d.ts +18 -0
  175. package/lib/types/locale/function-list/logical/ja-JP.d.ts +18 -0
  176. package/lib/types/locale/function-list/logical/ko-KR.d.ts +18 -0
  177. package/lib/types/locale/function-list/logical/ru-RU.d.ts +18 -0
  178. package/lib/types/locale/function-list/logical/sk-SK.d.ts +18 -0
  179. package/lib/types/locale/function-list/logical/vi-VN.d.ts +18 -0
  180. package/lib/types/locale/function-list/logical/zh-CN.d.ts +18 -0
  181. package/lib/types/locale/function-list/logical/zh-TW.d.ts +18 -0
  182. package/lib/types/locale/function-list/lookup/ca-ES.d.ts +18 -0
  183. package/lib/types/locale/function-list/lookup/en-US.d.ts +820 -0
  184. package/lib/types/locale/function-list/lookup/es-ES.d.ts +18 -0
  185. package/lib/types/locale/function-list/lookup/fa-IR.d.ts +18 -0
  186. package/lib/types/locale/function-list/lookup/fr-FR.d.ts +18 -0
  187. package/lib/types/locale/function-list/lookup/ja-JP.d.ts +18 -0
  188. package/lib/types/locale/function-list/lookup/ko-KR.d.ts +18 -0
  189. package/lib/types/locale/function-list/lookup/ru-RU.d.ts +18 -0
  190. package/lib/types/locale/function-list/lookup/sk-SK.d.ts +18 -0
  191. package/lib/types/locale/function-list/lookup/vi-VN.d.ts +18 -0
  192. package/lib/types/locale/function-list/lookup/zh-CN.d.ts +18 -0
  193. package/lib/types/locale/function-list/lookup/zh-TW.d.ts +18 -0
  194. package/lib/types/locale/function-list/math/ca-ES.d.ts +18 -0
  195. package/lib/types/locale/function-list/math/en-US.d.ts +1410 -0
  196. package/lib/types/locale/function-list/math/es-ES.d.ts +18 -0
  197. package/lib/types/locale/function-list/math/fa-IR.d.ts +18 -0
  198. package/lib/types/locale/function-list/math/fr-FR.d.ts +18 -0
  199. package/lib/types/locale/function-list/math/ja-JP.d.ts +18 -0
  200. package/lib/types/locale/function-list/math/ko-KR.d.ts +18 -0
  201. package/lib/types/locale/function-list/math/ru-RU.d.ts +18 -0
  202. package/lib/types/locale/function-list/math/sk-SK.d.ts +18 -0
  203. package/lib/types/locale/function-list/math/vi-VN.d.ts +18 -0
  204. package/lib/types/locale/function-list/math/zh-CN.d.ts +18 -0
  205. package/lib/types/locale/function-list/math/zh-TW.d.ts +18 -0
  206. package/lib/types/locale/function-list/statistical/ca-ES.d.ts +18 -0
  207. package/lib/types/locale/function-list/statistical/en-US.d.ts +2308 -0
  208. package/lib/types/locale/function-list/statistical/es-ES.d.ts +18 -0
  209. package/lib/types/locale/function-list/statistical/fa-IR.d.ts +18 -0
  210. package/lib/types/locale/function-list/statistical/fr-FR.d.ts +18 -0
  211. package/lib/types/locale/function-list/statistical/ja-JP.d.ts +18 -0
  212. package/lib/types/locale/function-list/statistical/ko-KR.d.ts +18 -0
  213. package/lib/types/locale/function-list/statistical/ru-RU.d.ts +18 -0
  214. package/lib/types/locale/function-list/statistical/sk-SK.d.ts +18 -0
  215. package/lib/types/locale/function-list/statistical/vi-VN.d.ts +18 -0
  216. package/lib/types/locale/function-list/statistical/zh-CN.d.ts +18 -0
  217. package/lib/types/locale/function-list/statistical/zh-TW.d.ts +18 -0
  218. package/lib/types/locale/function-list/text/ca-ES.d.ts +18 -0
  219. package/lib/types/locale/function-list/text/en-US.d.ts +988 -0
  220. package/lib/types/locale/function-list/text/es-ES.d.ts +18 -0
  221. package/lib/types/locale/function-list/text/fa-IR.d.ts +18 -0
  222. package/lib/types/locale/function-list/text/fr-FR.d.ts +18 -0
  223. package/lib/types/locale/function-list/text/ja-JP.d.ts +18 -0
  224. package/lib/types/locale/function-list/text/ko-KR.d.ts +18 -0
  225. package/lib/types/locale/function-list/text/ru-RU.d.ts +18 -0
  226. package/lib/types/locale/function-list/text/sk-SK.d.ts +18 -0
  227. package/lib/types/locale/function-list/text/vi-VN.d.ts +18 -0
  228. package/lib/types/locale/function-list/text/zh-CN.d.ts +18 -0
  229. package/lib/types/locale/function-list/text/zh-TW.d.ts +18 -0
  230. package/lib/types/locale/function-list/univer/ca-ES.d.ts +18 -0
  231. package/lib/types/locale/function-list/univer/en-US.d.ts +17 -0
  232. package/lib/types/locale/function-list/univer/es-ES.d.ts +18 -0
  233. package/lib/types/locale/function-list/univer/fa-IR.d.ts +18 -0
  234. package/lib/types/locale/function-list/univer/fr-FR.d.ts +18 -0
  235. package/lib/types/locale/function-list/univer/ja-JP.d.ts +18 -0
  236. package/lib/types/locale/function-list/univer/ko-KR.d.ts +18 -0
  237. package/lib/types/locale/function-list/univer/ru-RU.d.ts +17 -0
  238. package/lib/types/locale/function-list/univer/sk-SK.d.ts +18 -0
  239. package/lib/types/locale/function-list/univer/vi-VN.d.ts +18 -0
  240. package/lib/types/locale/function-list/univer/zh-CN.d.ts +18 -0
  241. package/lib/types/locale/function-list/univer/zh-TW.d.ts +18 -0
  242. package/lib/types/locale/function-list/web/ca-ES.d.ts +18 -0
  243. package/lib/types/locale/function-list/web/en-US.d.ts +68 -0
  244. package/lib/types/locale/function-list/web/es-ES.d.ts +18 -0
  245. package/lib/types/locale/function-list/web/fa-IR.d.ts +18 -0
  246. package/lib/types/locale/function-list/web/fr-FR.d.ts +18 -0
  247. package/lib/types/locale/function-list/web/ja-JP.d.ts +18 -0
  248. package/lib/types/locale/function-list/web/ko-KR.d.ts +18 -0
  249. package/lib/types/locale/function-list/web/ru-RU.d.ts +18 -0
  250. package/lib/types/locale/function-list/web/sk-SK.d.ts +18 -0
  251. package/lib/types/locale/function-list/web/vi-VN.d.ts +18 -0
  252. package/lib/types/locale/function-list/web/zh-CN.d.ts +18 -0
  253. package/lib/types/locale/function-list/web/zh-TW.d.ts +18 -0
  254. package/lib/types/locale/id-ID.d.ts +18 -0
  255. package/lib/types/locale/it-IT.d.ts +18 -0
  256. package/lib/types/locale/pl-PL.d.ts +18 -0
  257. package/lib/types/locale/pt-BR.d.ts +18 -0
  258. package/lib/types/locale/zh-HK.d.ts +18 -0
  259. package/lib/types/services/formula-calculation-session.service.d.ts +48 -0
  260. package/lib/umd/facade.js +1 -1
  261. package/lib/umd/index.js +1 -1
  262. package/lib/umd/locale/ar-SA.js +44 -0
  263. package/lib/umd/locale/ca-ES.js +39 -1
  264. package/lib/umd/locale/de-DE.js +44 -0
  265. package/lib/umd/locale/en-US.js +44 -1
  266. package/lib/umd/locale/es-ES.js +39 -1
  267. package/lib/umd/locale/fa-IR.js +44 -1
  268. package/lib/umd/locale/fr-FR.js +44 -1
  269. package/lib/umd/locale/id-ID.js +44 -0
  270. package/lib/umd/locale/it-IT.js +44 -0
  271. package/lib/umd/locale/ja-JP.js +43 -1
  272. package/lib/umd/locale/ko-KR.js +37 -1
  273. package/lib/umd/locale/pl-PL.js +44 -0
  274. package/lib/umd/locale/pt-BR.js +44 -0
  275. package/lib/umd/locale/ru-RU.js +31 -1
  276. package/lib/umd/locale/sk-SK.js +39 -1
  277. package/lib/umd/locale/vi-VN.js +43 -1
  278. package/lib/umd/locale/zh-CN.js +44 -1
  279. package/lib/umd/locale/zh-HK.js +44 -0
  280. package/lib/umd/locale/zh-TW.js +44 -1
  281. package/package.json +9 -9
@@ -27,6 +27,7 @@ export declare class ActiveDirtyController extends Disposable {
27
27
  private _initialHideRow;
28
28
  private _initialSheet;
29
29
  private _initialDefinedName;
30
+ private _initialSuperTable;
30
31
  private _getDefinedNameMutation;
31
32
  private _getSetRangeValuesMutationDirtyRange;
32
33
  private _getMoveRangeMutationDirtyRange;
@@ -0,0 +1,24 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Disposable, ICommandService } from '@univerjs/core';
17
+ import { FormulaCalculationSessionService } from '../services/formula-calculation-session.service';
18
+ export declare class FormulaCalculationSessionController extends Disposable {
19
+ private readonly _commandService;
20
+ private readonly _sessionService;
21
+ constructor(_commandService: ICommandService, _sessionService: FormulaCalculationSessionService);
22
+ private _initialize;
23
+ private _hasFormulaResultToApply;
24
+ }
@@ -62,7 +62,7 @@ export declare class TriggerCalculationController extends Disposable {
62
62
  * @param dirtyRanges
63
63
  */
64
64
  private _mergeDirtyRanges;
65
- private _mergeDirtyNameMap;
65
+ private _mergeDirtyUnitStringMap;
66
66
  private _mergeDirtyUnitFeatureOrOtherFormulaMap;
67
67
  private _initialExecuteFormulaProcessListener;
68
68
  private _resetExecutingDirtyData;
@@ -30,7 +30,10 @@ export declare enum FormulaReferenceMoveType {
30
30
  SetName = 11,
31
31
  RemoveSheet = 12,
32
32
  SetDefinedName = 13,// update defined name
33
- RemoveDefinedName = 14
33
+ RemoveDefinedName = 14,// remove defined name
34
+ SetSuperTableName = 15,// update super table name
35
+ RemoveSuperTableName = 16,// remove super table name
36
+ RemoveSuperTableColumn = 17
34
37
  }
35
38
  export interface IFormulaReferenceMoveParam {
36
39
  type: FormulaReferenceMoveType;
@@ -51,6 +54,9 @@ export interface IFormulaReferenceMoveParam {
51
54
  * new defined name
52
55
  */
53
56
  definedName?: string;
57
+ oldTableName?: string;
58
+ tableName?: string;
59
+ tableColumnNames?: string[];
54
60
  /**
55
61
  * The filtered rows contained in the range, used for remove rows operation, etc.
56
62
  */
@@ -50,7 +50,8 @@ export interface IFFormulaSheetsMixin {
50
50
  *
51
51
  * // Use the function in a cell
52
52
  * const fWorkbook = univerAPI.getActiveWorkbook();
53
- * const fWorksheet = fWorkbook.getActiveSheet();
53
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
54
+ * if (!fWorksheet) return;
54
55
  * const cellA1 = fWorksheet.getRange('A1');
55
56
  * cellA1.setValue('World');
56
57
  * const cellA2 = fWorksheet.getRange('A2');
@@ -75,7 +76,8 @@ export interface IFFormulaSheetsMixin {
75
76
  *
76
77
  * // Use the function in a cell
77
78
  * const fWorkbook = univerAPI.getActiveWorkbook();
78
- * const fWorksheet = fWorkbook.getActiveSheet();
79
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
80
+ * if (!fWorksheet) return;
79
81
  * const cellA1 = fWorksheet.getRange('A1');
80
82
  * cellA1.setValue(100);
81
83
  * const cellA2 = fWorksheet.getRange('A2');
@@ -115,7 +117,8 @@ export interface IFFormulaSheetsMixin {
115
117
  *
116
118
  * // Use the function in a cell
117
119
  * const fWorkbook = univerAPI.getActiveWorkbook();
118
- * const fWorksheet = fWorkbook.getActiveSheet();
120
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
121
+ * if (!fWorksheet) return;
119
122
  * const cellA1 = fWorksheet.getRange('A1');
120
123
  * cellA1.setValue(1);
121
124
  * const cellA2 = fWorksheet.getRange('A2');
@@ -170,7 +173,8 @@ export interface IFFormulaSheetsMixin {
170
173
  *
171
174
  * // Use the function in a cell
172
175
  * const fWorkbook = univerAPI.getActiveWorkbook();
173
- * const fWorksheet = fWorkbook.getActiveSheet();
176
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
177
+ * if (!fWorksheet) return;
174
178
  * const cellA1 = fWorksheet.getRange('A1');
175
179
  * cellA1.setValue('World');
176
180
  * const cellA2 = fWorksheet.getRange('A2');
@@ -208,7 +212,8 @@ export interface IFFormulaSheetsMixin {
208
212
  *
209
213
  * // Use the function in a cell
210
214
  * const fWorkbook = univerAPI.getActiveWorkbook();
211
- * const fWorksheet = fWorkbook.getActiveSheet();
215
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
216
+ * if (!fWorksheet) return;
212
217
  * const cellA1 = fWorksheet.getRange('A1');
213
218
  * cellA1.setValue({ f: '=RANDOM_DELAYED()' });
214
219
  *
@@ -258,7 +263,8 @@ export interface IFFormulaSheetsMixin {
258
263
  *
259
264
  * // Use the function in a cell
260
265
  * const fWorkbook = univerAPI.getActiveWorkbook();
261
- * const fWorksheet = fWorkbook.getActiveSheet();
266
+ * const fWorksheet = fWorkbook.getSheetByName('Sheet1');
267
+ * if (!fWorksheet) return;
262
268
  * const cellA1 = fWorksheet.getRange('A1');
263
269
  * cellA1.setValue({ f: '=FETCH_USER_SCORE(42)' });
264
270
  *
@@ -296,17 +302,13 @@ export interface IFFormulaSheetsMixin {
296
302
  /**
297
303
  * Waits for formula-calculation results to be applied.
298
304
  *
299
- * This method resolves under three conditions:
300
- * 1. A real calculation runs and the engine emits a "calculation started" signal,
301
- * followed by a "calculation result applied" signal.
302
- * 2. No calculation actually starts within 500 ms — the method assumes there is
303
- * nothing to wait for and resolves automatically.
304
- * 3. A global 30 s timeout triggers, in which case the promise rejects.
305
- *
306
- * The API internally listens to both “calculation in progress” events and
307
- * “calculation result applied” events, ensuring it behaves correctly whether
308
- * formulas are recalculated or skipped due to cache/state.
305
+ * The API follows the latest formula-calculation session. If a running
306
+ * calculation is stopped and immediately restarted, the promise waits for
307
+ * the restarted session to apply its results.
309
308
  *
309
+ * @param {number} [timeout] Optional timeout in milliseconds. If omitted,
310
+ * the promise waits until calculation results are applied or no calculation
311
+ * occurs within the start-detection window.
310
312
  * @returns {Promise<void>} A promise that resolves when calculation results are applied
311
313
  * or when no calculation occurs within the start-detection window.
312
314
  *
@@ -321,7 +323,7 @@ export interface IFFormulaSheetsMixin {
321
323
  * console.log("Updated value:", value);
322
324
  * ```
323
325
  */
324
- onCalculationResultApplied(): Promise<void>;
326
+ onCalculationResultApplied(timeout?: number): Promise<void>;
325
327
  }
326
328
  export declare class FFormulaSheetsMixin extends FFormula implements IFFormulaSheetsMixin {
327
329
  /**
@@ -339,8 +341,7 @@ export declare class FFormulaSheetsMixin extends FFormula implements IFFormulaSh
339
341
  registerAsyncFunction(name: string, func: IRegisterAsyncFunction): IDisposable;
340
342
  registerAsyncFunction(name: string, func: IRegisterAsyncFunction, description: string): IDisposable;
341
343
  calculationResultApplied(callback: (result: ISetFormulaCalculationResultMutation) => void): IDisposable;
342
- private _hasFormulaResultToApply;
343
- onCalculationResultApplied(): Promise<void>;
344
+ onCalculationResultApplied(timeout?: number): Promise<void>;
344
345
  }
345
346
  declare module '@univerjs/engine-formula/facade' {
346
347
  interface FFormula extends IFFormulaSheetsMixin {
@@ -24,9 +24,9 @@ export interface IFRangeEngineFormulaMixin {
24
24
  * @returns {ISheetFormulaError[]} Array of formula errors in the range
25
25
  * @example
26
26
  * ```typescript
27
- * const range = univerAPI.getActiveWorkbook()
28
- * .getActiveSheet()
29
- * .getRange('A1:B10');
27
+ * const fWorksheet = univerAPI.getActiveWorkbook().getSheetByName('Sheet1');
28
+ * if (!fWorksheet) return;
29
+ * const range = fWorksheet.getRange('A1:B10');
30
30
  * const errors = range.getFormulaError();
31
31
  * console.log('Formula errors in range:', errors);
32
32
  * ```
@@ -18,6 +18,7 @@ export { QuickSumCommand } from './commands/commands/quick-sum.command';
18
18
  export { CalculationMode, PLUGIN_CONFIG_KEY_BASE } from './config/config';
19
19
  export type { IUniverSheetsFormulaBaseConfig, IUniverSheetsFormulaRemoteConfig } from './config/config';
20
20
  export { FormulaAutoFillController } from './controllers/formula-auto-fill.controller';
21
+ export { FormulaCalculationSessionController } from './controllers/formula-calculation-session.controller';
21
22
  export { ImageFormulaCellInterceptorController } from './controllers/image-formula-cell-interceptor.controller';
22
23
  export { TriggerCalculationController } from './controllers/trigger-calculation.controller';
23
24
  export { UpdateDefinedNameController } from './controllers/update-defined-name.controller';
@@ -25,6 +26,8 @@ export { UpdateFormulaController } from './controllers/update-formula.controller
25
26
  export { UniverRemoteSheetsFormulaPlugin, UniverSheetsFormulaPlugin } from './plugin';
26
27
  export { DescriptionService, IDescriptionService } from './services/description.service';
27
28
  export type { ISearchItem, ISearchItemWithType } from './services/description.service';
29
+ export { FormulaCalculationSessionService } from './services/formula-calculation-session.service';
30
+ export type { IFormulaCalculationSessionState } from './services/formula-calculation-session.service';
28
31
  export { FormulaRefRangeService } from './services/formula-ref-range.service';
29
32
  export type { IRegisterAsyncFunction, IRegisterFunction, ISingleFunctionRegisterParams } from './services/register-function.service';
30
33
  export type { IRegisterFunctionParams, IUnregisterFunctionParams } from './services/register-function.service';
@@ -0,0 +1,18 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type enUS from './en-US';
17
+ declare const locale: typeof enUS;
18
+ export default locale;
@@ -0,0 +1,18 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type enUS from './en-US';
17
+ declare const locale: typeof enUS;
18
+ export default locale;