@mog-sdk/spreadsheet-contracts 0.1.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (701) hide show
  1. package/dist/accessibility/index.d.ts +9 -0
  2. package/dist/accessibility/index.d.ts.map +1 -0
  3. package/dist/accessibility/types.d.ts +75 -0
  4. package/dist/accessibility/types.d.ts.map +1 -0
  5. package/dist/actions/comments.d.ts +31 -0
  6. package/dist/actions/comments.d.ts.map +1 -0
  7. package/dist/actions/index.d.ts +22 -0
  8. package/dist/actions/index.d.ts.map +1 -0
  9. package/dist/actions/types.d.ts +448 -0
  10. package/dist/actions/types.d.ts.map +1 -0
  11. package/dist/actors/chart.d.ts +88 -0
  12. package/dist/actors/chart.d.ts.map +1 -0
  13. package/dist/actors/clipboard.d.ts +243 -0
  14. package/dist/actors/clipboard.d.ts.map +1 -0
  15. package/dist/actors/commands.d.ts +1343 -0
  16. package/dist/actors/commands.d.ts.map +1 -0
  17. package/dist/actors/comment.d.ts +84 -0
  18. package/dist/actors/comment.d.ts.map +1 -0
  19. package/dist/actors/draw-border.d.ts +89 -0
  20. package/dist/actors/draw-border.d.ts.map +1 -0
  21. package/dist/actors/editor.d.ts +161 -0
  22. package/dist/actors/editor.d.ts.map +1 -0
  23. package/dist/actors/find-replace.d.ts +88 -0
  24. package/dist/actors/find-replace.d.ts.map +1 -0
  25. package/dist/actors/focus.d.ts +91 -0
  26. package/dist/actors/focus.d.ts.map +1 -0
  27. package/dist/actors/index.d.ts +88 -0
  28. package/dist/actors/index.d.ts.map +1 -0
  29. package/dist/actors/input.d.ts +98 -0
  30. package/dist/actors/input.d.ts.map +1 -0
  31. package/dist/actors/object-interaction.d.ts +163 -0
  32. package/dist/actors/object-interaction.d.ts.map +1 -0
  33. package/dist/actors/object.d.ts +124 -0
  34. package/dist/actors/object.d.ts.map +1 -0
  35. package/dist/actors/page-break.d.ts +64 -0
  36. package/dist/actors/page-break.d.ts.map +1 -0
  37. package/dist/actors/pane-focus.d.ts +56 -0
  38. package/dist/actors/pane-focus.d.ts.map +1 -0
  39. package/dist/actors/renderer.d.ts +197 -0
  40. package/dist/actors/renderer.d.ts.map +1 -0
  41. package/dist/actors/selection.d.ts +170 -0
  42. package/dist/actors/selection.d.ts.map +1 -0
  43. package/dist/actors/slicer.d.ts +175 -0
  44. package/dist/actors/slicer.d.ts.map +1 -0
  45. package/dist/actors/smartart.d.ts +48 -0
  46. package/dist/actors/smartart.d.ts.map +1 -0
  47. package/dist/api/index.d.ts +19 -0
  48. package/dist/api/index.d.ts.map +1 -0
  49. package/dist/api/mutation-receipt.d.ts +26 -0
  50. package/dist/api/mutation-receipt.d.ts.map +1 -0
  51. package/dist/api/types.d.ts +1542 -0
  52. package/dist/api/types.d.ts.map +1 -0
  53. package/dist/api/workbook/history.d.ts +43 -0
  54. package/dist/api/workbook/history.d.ts.map +1 -0
  55. package/dist/api/workbook/index.d.ts +17 -0
  56. package/dist/api/workbook/index.d.ts.map +1 -0
  57. package/dist/api/workbook/names.d.ts +104 -0
  58. package/dist/api/workbook/names.d.ts.map +1 -0
  59. package/dist/api/workbook/notifications.d.ts +35 -0
  60. package/dist/api/workbook/notifications.d.ts.map +1 -0
  61. package/dist/api/workbook/protection.d.ts +14 -0
  62. package/dist/api/workbook/protection.d.ts.map +1 -0
  63. package/dist/api/workbook/scenarios.d.ts +45 -0
  64. package/dist/api/workbook/scenarios.d.ts.map +1 -0
  65. package/dist/api/workbook/sheets.d.ts +74 -0
  66. package/dist/api/workbook/sheets.d.ts.map +1 -0
  67. package/dist/api/workbook/slicers.d.ts +63 -0
  68. package/dist/api/workbook/slicers.d.ts.map +1 -0
  69. package/dist/api/workbook/styles.d.ts +19 -0
  70. package/dist/api/workbook/styles.d.ts.map +1 -0
  71. package/dist/api/workbook/theme.d.ts +38 -0
  72. package/dist/api/workbook/theme.d.ts.map +1 -0
  73. package/dist/api/workbook/viewport.d.ts +85 -0
  74. package/dist/api/workbook/viewport.d.ts.map +1 -0
  75. package/dist/api/workbook.d.ts +279 -0
  76. package/dist/api/workbook.d.ts.map +1 -0
  77. package/dist/api/worksheet/bindings.d.ts +66 -0
  78. package/dist/api/worksheet/bindings.d.ts.map +1 -0
  79. package/dist/api/worksheet/changes.d.ts +60 -0
  80. package/dist/api/worksheet/changes.d.ts.map +1 -0
  81. package/dist/api/worksheet/charts.d.ts +83 -0
  82. package/dist/api/worksheet/charts.d.ts.map +1 -0
  83. package/dist/api/worksheet/collections/connector-collection.d.ts +7 -0
  84. package/dist/api/worksheet/collections/connector-collection.d.ts.map +1 -0
  85. package/dist/api/worksheet/collections/drawing-collection.d.ts +9 -0
  86. package/dist/api/worksheet/collections/drawing-collection.d.ts.map +1 -0
  87. package/dist/api/worksheet/collections/equation-collection.d.ts +8 -0
  88. package/dist/api/worksheet/collections/equation-collection.d.ts.map +1 -0
  89. package/dist/api/worksheet/collections/index.d.ts +12 -0
  90. package/dist/api/worksheet/collections/index.d.ts.map +1 -0
  91. package/dist/api/worksheet/collections/object-collection.d.ts +45 -0
  92. package/dist/api/worksheet/collections/object-collection.d.ts.map +1 -0
  93. package/dist/api/worksheet/collections/picture-collection.d.ts +8 -0
  94. package/dist/api/worksheet/collections/picture-collection.d.ts.map +1 -0
  95. package/dist/api/worksheet/collections/shape-collection.d.ts +8 -0
  96. package/dist/api/worksheet/collections/shape-collection.d.ts.map +1 -0
  97. package/dist/api/worksheet/collections/textbox-collection.d.ts +8 -0
  98. package/dist/api/worksheet/collections/textbox-collection.d.ts.map +1 -0
  99. package/dist/api/worksheet/collections/wordart-collection.d.ts +8 -0
  100. package/dist/api/worksheet/collections/wordart-collection.d.ts.map +1 -0
  101. package/dist/api/worksheet/comments.d.ts +143 -0
  102. package/dist/api/worksheet/comments.d.ts.map +1 -0
  103. package/dist/api/worksheet/conditional-formats.d.ts +101 -0
  104. package/dist/api/worksheet/conditional-formats.d.ts.map +1 -0
  105. package/dist/api/worksheet/filters.d.ts +141 -0
  106. package/dist/api/worksheet/filters.d.ts.map +1 -0
  107. package/dist/api/worksheet/form-controls.d.ts +22 -0
  108. package/dist/api/worksheet/form-controls.d.ts.map +1 -0
  109. package/dist/api/worksheet/format-mappings.d.ts +50 -0
  110. package/dist/api/worksheet/format-mappings.d.ts.map +1 -0
  111. package/dist/api/worksheet/formats.d.ts +136 -0
  112. package/dist/api/worksheet/formats.d.ts.map +1 -0
  113. package/dist/api/worksheet/handles/chart-handle.d.ts +11 -0
  114. package/dist/api/worksheet/handles/chart-handle.d.ts.map +1 -0
  115. package/dist/api/worksheet/handles/connector-handle.d.ts +9 -0
  116. package/dist/api/worksheet/handles/connector-handle.d.ts.map +1 -0
  117. package/dist/api/worksheet/handles/drawing-handle.d.ts +14 -0
  118. package/dist/api/worksheet/handles/drawing-handle.d.ts.map +1 -0
  119. package/dist/api/worksheet/handles/equation-handle.d.ts +9 -0
  120. package/dist/api/worksheet/handles/equation-handle.d.ts.map +1 -0
  121. package/dist/api/worksheet/handles/floating-object-handle.d.ts +75 -0
  122. package/dist/api/worksheet/handles/floating-object-handle.d.ts.map +1 -0
  123. package/dist/api/worksheet/handles/index.d.ts +16 -0
  124. package/dist/api/worksheet/handles/index.d.ts.map +1 -0
  125. package/dist/api/worksheet/handles/ole-object-handle.d.ts +10 -0
  126. package/dist/api/worksheet/handles/ole-object-handle.d.ts.map +1 -0
  127. package/dist/api/worksheet/handles/picture-handle.d.ts +9 -0
  128. package/dist/api/worksheet/handles/picture-handle.d.ts.map +1 -0
  129. package/dist/api/worksheet/handles/shape-handle.d.ts +11 -0
  130. package/dist/api/worksheet/handles/shape-handle.d.ts.map +1 -0
  131. package/dist/api/worksheet/handles/slicer-handle.d.ts +13 -0
  132. package/dist/api/worksheet/handles/slicer-handle.d.ts.map +1 -0
  133. package/dist/api/worksheet/handles/smartart-handle.d.ts +11 -0
  134. package/dist/api/worksheet/handles/smartart-handle.d.ts.map +1 -0
  135. package/dist/api/worksheet/handles/textbox-handle.d.ts +9 -0
  136. package/dist/api/worksheet/handles/textbox-handle.d.ts.map +1 -0
  137. package/dist/api/worksheet/handles/wordart-handle.d.ts +10 -0
  138. package/dist/api/worksheet/handles/wordart-handle.d.ts.map +1 -0
  139. package/dist/api/worksheet/hyperlinks.d.ts +52 -0
  140. package/dist/api/worksheet/hyperlinks.d.ts.map +1 -0
  141. package/dist/api/worksheet/index.d.ts +35 -0
  142. package/dist/api/worksheet/index.d.ts.map +1 -0
  143. package/dist/api/worksheet/internal.d.ts +105 -0
  144. package/dist/api/worksheet/internal.d.ts.map +1 -0
  145. package/dist/api/worksheet/layout.d.ts +150 -0
  146. package/dist/api/worksheet/layout.d.ts.map +1 -0
  147. package/dist/api/worksheet/names.d.ts +52 -0
  148. package/dist/api/worksheet/names.d.ts.map +1 -0
  149. package/dist/api/worksheet/objects.d.ts +124 -0
  150. package/dist/api/worksheet/objects.d.ts.map +1 -0
  151. package/dist/api/worksheet/outline.d.ts +101 -0
  152. package/dist/api/worksheet/outline.d.ts.map +1 -0
  153. package/dist/api/worksheet/pivots.d.ts +257 -0
  154. package/dist/api/worksheet/pivots.d.ts.map +1 -0
  155. package/dist/api/worksheet/print.d.ts +108 -0
  156. package/dist/api/worksheet/print.d.ts.map +1 -0
  157. package/dist/api/worksheet/protection.d.ts +73 -0
  158. package/dist/api/worksheet/protection.d.ts.map +1 -0
  159. package/dist/api/worksheet/settings.d.ts +54 -0
  160. package/dist/api/worksheet/settings.d.ts.map +1 -0
  161. package/dist/api/worksheet/slicers.d.ts +101 -0
  162. package/dist/api/worksheet/slicers.d.ts.map +1 -0
  163. package/dist/api/worksheet/smartart.d.ts +49 -0
  164. package/dist/api/worksheet/smartart.d.ts.map +1 -0
  165. package/dist/api/worksheet/sparklines.d.ts +143 -0
  166. package/dist/api/worksheet/sparklines.d.ts.map +1 -0
  167. package/dist/api/worksheet/structure.d.ts +44 -0
  168. package/dist/api/worksheet/structure.d.ts.map +1 -0
  169. package/dist/api/worksheet/tables.d.ts +313 -0
  170. package/dist/api/worksheet/tables.d.ts.map +1 -0
  171. package/dist/api/worksheet/validation.d.ts +101 -0
  172. package/dist/api/worksheet/validation.d.ts.map +1 -0
  173. package/dist/api/worksheet/view.d.ts +91 -0
  174. package/dist/api/worksheet/view.d.ts.map +1 -0
  175. package/dist/api/worksheet.d.ts +370 -0
  176. package/dist/api/worksheet.d.ts.map +1 -0
  177. package/dist/app/index.d.ts +17 -0
  178. package/dist/app/index.d.ts.map +1 -0
  179. package/dist/app/types.d.ts +349 -0
  180. package/dist/app/types.d.ts.map +1 -0
  181. package/dist/apps/api.d.ts +519 -0
  182. package/dist/apps/api.d.ts.map +1 -0
  183. package/dist/apps/bindings.d.ts +72 -0
  184. package/dist/apps/bindings.d.ts.map +1 -0
  185. package/dist/apps/index.d.ts +13 -0
  186. package/dist/apps/index.d.ts.map +1 -0
  187. package/dist/apps/types.d.ts +224 -0
  188. package/dist/apps/types.d.ts.map +1 -0
  189. package/dist/apps/views.d.ts +142 -0
  190. package/dist/apps/views.d.ts.map +1 -0
  191. package/dist/bridges/chart-bridge.d.ts +172 -0
  192. package/dist/bridges/chart-bridge.d.ts.map +1 -0
  193. package/dist/bridges/equation-bridge.d.ts +74 -0
  194. package/dist/bridges/equation-bridge.d.ts.map +1 -0
  195. package/dist/bridges/index.d.ts +25 -0
  196. package/dist/bridges/index.d.ts.map +1 -0
  197. package/dist/bridges/ink-recognition-bridge.d.ts +142 -0
  198. package/dist/bridges/ink-recognition-bridge.d.ts.map +1 -0
  199. package/dist/bridges/locale-bridge.d.ts +93 -0
  200. package/dist/bridges/locale-bridge.d.ts.map +1 -0
  201. package/dist/bridges/pivot-bridge.d.ts +201 -0
  202. package/dist/bridges/pivot-bridge.d.ts.map +1 -0
  203. package/dist/bridges/schema-bridge.d.ts +137 -0
  204. package/dist/bridges/schema-bridge.d.ts.map +1 -0
  205. package/dist/bridges/smartart-bridge.d.ts +217 -0
  206. package/dist/bridges/smartart-bridge.d.ts.map +1 -0
  207. package/dist/bridges/wordart-bridge.d.ts +86 -0
  208. package/dist/bridges/wordart-bridge.d.ts.map +1 -0
  209. package/dist/capabilities/errors.d.ts +16 -0
  210. package/dist/capabilities/errors.d.ts.map +1 -0
  211. package/dist/capabilities/gated-api.d.ts +355 -0
  212. package/dist/capabilities/gated-api.d.ts.map +1 -0
  213. package/dist/capabilities/grants.d.ts +239 -0
  214. package/dist/capabilities/grants.d.ts.map +1 -0
  215. package/dist/capabilities/index.d.ts +24 -0
  216. package/dist/capabilities/index.d.ts.map +1 -0
  217. package/dist/capabilities/manifest.d.ts +128 -0
  218. package/dist/capabilities/manifest.d.ts.map +1 -0
  219. package/dist/capabilities/requester.d.ts +209 -0
  220. package/dist/capabilities/requester.d.ts.map +1 -0
  221. package/dist/capabilities/scope.d.ts +55 -0
  222. package/dist/capabilities/scope.d.ts.map +1 -0
  223. package/dist/capabilities/sensitive.d.ts +279 -0
  224. package/dist/capabilities/sensitive.d.ts.map +1 -0
  225. package/dist/capabilities/taxonomy.d.ts +15 -0
  226. package/dist/capabilities/taxonomy.d.ts.map +1 -0
  227. package/dist/capabilities/types.d.ts +91 -0
  228. package/dist/capabilities/types.d.ts.map +1 -0
  229. package/dist/cells/cell-identity.d.ts +281 -0
  230. package/dist/cells/cell-identity.d.ts.map +1 -0
  231. package/dist/cells/cell-style.d.ts +67 -0
  232. package/dist/cells/cell-style.d.ts.map +1 -0
  233. package/dist/cells/formula-string.d.ts +37 -0
  234. package/dist/cells/formula-string.d.ts.map +1 -0
  235. package/dist/cells/index.d.ts +7 -0
  236. package/dist/cells/index.d.ts.map +1 -0
  237. package/dist/cells/range-ref.d.ts +77 -0
  238. package/dist/cells/range-ref.d.ts.map +1 -0
  239. package/dist/cells/rich-text.d.ts +66 -0
  240. package/dist/cells/rich-text.d.ts.map +1 -0
  241. package/dist/cells/spill.d.ts +121 -0
  242. package/dist/cells/spill.d.ts.map +1 -0
  243. package/dist/conditional-format/index.d.ts +11 -0
  244. package/dist/conditional-format/index.d.ts.map +1 -0
  245. package/dist/conditional-format/presets.d.ts +54 -0
  246. package/dist/conditional-format/presets.d.ts.map +1 -0
  247. package/dist/conditional-format/range-utils.d.ts +11 -0
  248. package/dist/conditional-format/range-utils.d.ts.map +1 -0
  249. package/dist/conditional-format/render-types.d.ts +80 -0
  250. package/dist/conditional-format/render-types.d.ts.map +1 -0
  251. package/dist/connections/api-errors.d.ts +29 -0
  252. package/dist/connections/api-errors.d.ts.map +1 -0
  253. package/dist/connections/api.d.ts +879 -0
  254. package/dist/connections/api.d.ts.map +1 -0
  255. package/dist/connections/database-bridge-types.d.ts +108 -0
  256. package/dist/connections/database-bridge-types.d.ts.map +1 -0
  257. package/dist/connections/index.d.ts +5 -0
  258. package/dist/connections/index.d.ts.map +1 -0
  259. package/dist/connections/power-query.d.ts +1 -0
  260. package/dist/connections/power-query.d.ts.map +1 -0
  261. package/dist/connections/query.d.ts +144 -0
  262. package/dist/connections/query.d.ts.map +1 -0
  263. package/dist/context-menu/index.d.ts +10 -0
  264. package/dist/context-menu/index.d.ts.map +1 -0
  265. package/dist/context-menu/types.d.ts +28 -0
  266. package/dist/context-menu/types.d.ts.map +1 -0
  267. package/dist/core/commands.d.ts +143 -0
  268. package/dist/core/commands.d.ts.map +1 -0
  269. package/dist/core/core.d.ts +943 -0
  270. package/dist/core/core.d.ts.map +1 -0
  271. package/dist/core/disposable.d.ts +30 -0
  272. package/dist/core/disposable.d.ts.map +1 -0
  273. package/dist/core/event-base.d.ts +31 -0
  274. package/dist/core/event-base.d.ts.map +1 -0
  275. package/dist/core/execution.d.ts +79 -0
  276. package/dist/core/execution.d.ts.map +1 -0
  277. package/dist/core/formatted-text.d.ts +8 -0
  278. package/dist/core/formatted-text.d.ts.map +1 -0
  279. package/dist/core/index.d.ts +10 -0
  280. package/dist/core/index.d.ts.map +1 -0
  281. package/dist/core/result.d.ts +23 -0
  282. package/dist/core/result.d.ts.map +1 -0
  283. package/dist/core/schema.d.ts +360 -0
  284. package/dist/core/schema.d.ts.map +1 -0
  285. package/dist/core/testing.d.ts +309 -0
  286. package/dist/core/testing.d.ts.map +1 -0
  287. package/dist/culture/index.d.ts +11 -0
  288. package/dist/culture/index.d.ts.map +1 -0
  289. package/dist/culture/types.d.ts +320 -0
  290. package/dist/culture/types.d.ts.map +1 -0
  291. package/dist/data/charts.d.ts +412 -0
  292. package/dist/data/charts.d.ts.map +1 -0
  293. package/dist/data/conditional-format.d.ts +188 -0
  294. package/dist/data/conditional-format.d.ts.map +1 -0
  295. package/dist/data/filter.d.ts +364 -0
  296. package/dist/data/filter.d.ts.map +1 -0
  297. package/dist/data/grouping.d.ts +170 -0
  298. package/dist/data/grouping.d.ts.map +1 -0
  299. package/dist/data/index.d.ts +12 -0
  300. package/dist/data/index.d.ts.map +1 -0
  301. package/dist/data/named-ranges.d.ts +104 -0
  302. package/dist/data/named-ranges.d.ts.map +1 -0
  303. package/dist/data/pivot.d.ts +68 -0
  304. package/dist/data/pivot.d.ts.map +1 -0
  305. package/dist/data/slicers.d.ts +417 -0
  306. package/dist/data/slicers.d.ts.map +1 -0
  307. package/dist/data/sorting.d.ts +172 -0
  308. package/dist/data/sorting.d.ts.map +1 -0
  309. package/dist/data/sparklines.d.ts +358 -0
  310. package/dist/data/sparklines.d.ts.map +1 -0
  311. package/dist/data/tables.d.ts +333 -0
  312. package/dist/data/tables.d.ts.map +1 -0
  313. package/dist/data/trace-arrows.d.ts +165 -0
  314. package/dist/data/trace-arrows.d.ts.map +1 -0
  315. package/dist/diagnostics/core.d.ts +219 -0
  316. package/dist/diagnostics/core.d.ts.map +1 -0
  317. package/dist/diagnostics/index.d.ts +9 -0
  318. package/dist/diagnostics/index.d.ts.map +1 -0
  319. package/dist/diagnostics/style.d.ts +196 -0
  320. package/dist/diagnostics/style.d.ts.map +1 -0
  321. package/dist/document/comments.d.ts +109 -0
  322. package/dist/document/comments.d.ts.map +1 -0
  323. package/dist/document/document.d.ts +182 -0
  324. package/dist/document/document.d.ts.map +1 -0
  325. package/dist/document/index.d.ts +5 -0
  326. package/dist/document/index.d.ts.map +1 -0
  327. package/dist/document/protection.d.ts +114 -0
  328. package/dist/document/protection.d.ts.map +1 -0
  329. package/dist/document/search.d.ts +202 -0
  330. package/dist/document/search.d.ts.map +1 -0
  331. package/dist/drawing/index.d.ts +8 -0
  332. package/dist/drawing/index.d.ts.map +1 -0
  333. package/dist/drawing/three-d.d.ts +171 -0
  334. package/dist/drawing/three-d.d.ts.map +1 -0
  335. package/dist/editor/drag.d.ts +178 -0
  336. package/dist/editor/drag.d.ts.map +1 -0
  337. package/dist/editor/editor.d.ts +59 -0
  338. package/dist/editor/editor.d.ts.map +1 -0
  339. package/dist/editor/form-controls.d.ts +428 -0
  340. package/dist/editor/form-controls.d.ts.map +1 -0
  341. package/dist/editor/index.d.ts +4 -0
  342. package/dist/editor/index.d.ts.map +1 -0
  343. package/dist/equation/errors.d.ts +19 -0
  344. package/dist/equation/errors.d.ts.map +1 -0
  345. package/dist/equation/index.d.ts +12 -0
  346. package/dist/equation/index.d.ts.map +1 -0
  347. package/dist/equation/omml-ast.d.ts +358 -0
  348. package/dist/equation/omml-ast.d.ts.map +1 -0
  349. package/dist/equation/templates.d.ts +26 -0
  350. package/dist/equation/templates.d.ts.map +1 -0
  351. package/dist/equation/types.d.ts +87 -0
  352. package/dist/equation/types.d.ts.map +1 -0
  353. package/dist/events/canvas-object-events.d.ts +31 -0
  354. package/dist/events/canvas-object-events.d.ts.map +1 -0
  355. package/dist/events/cell-events.d.ts +60 -0
  356. package/dist/events/cell-events.d.ts.map +1 -0
  357. package/dist/events/chart-events.d.ts +61 -0
  358. package/dist/events/chart-events.d.ts.map +1 -0
  359. package/dist/events/comment-events.d.ts +43 -0
  360. package/dist/events/comment-events.d.ts.map +1 -0
  361. package/dist/events/conditional-formatting-events.d.ts +40 -0
  362. package/dist/events/conditional-formatting-events.d.ts.map +1 -0
  363. package/dist/events/data-tools-events.d.ts +29 -0
  364. package/dist/events/data-tools-events.d.ts.map +1 -0
  365. package/dist/events/file-io-events.d.ts +39 -0
  366. package/dist/events/file-io-events.d.ts.map +1 -0
  367. package/dist/events/filter-events.d.ts +43 -0
  368. package/dist/events/filter-events.d.ts.map +1 -0
  369. package/dist/events/floating-object-events.d.ts +158 -0
  370. package/dist/events/floating-object-events.d.ts.map +1 -0
  371. package/dist/events/grouping-events.d.ts +75 -0
  372. package/dist/events/grouping-events.d.ts.map +1 -0
  373. package/dist/events/index.d.ts +129 -0
  374. package/dist/events/index.d.ts.map +1 -0
  375. package/dist/events/ink-collaboration-events.d.ts +57 -0
  376. package/dist/events/ink-collaboration-events.d.ts.map +1 -0
  377. package/dist/events/ink-events.d.ts +33 -0
  378. package/dist/events/ink-events.d.ts.map +1 -0
  379. package/dist/events/ink-recognition-events.d.ts +149 -0
  380. package/dist/events/ink-recognition-events.d.ts.map +1 -0
  381. package/dist/events/ink-stroke-events.d.ts +197 -0
  382. package/dist/events/ink-stroke-events.d.ts.map +1 -0
  383. package/dist/events/merge-events.d.ts +46 -0
  384. package/dist/events/merge-events.d.ts.map +1 -0
  385. package/dist/events/named-range-events.d.ts +24 -0
  386. package/dist/events/named-range-events.d.ts.map +1 -0
  387. package/dist/events/pivot-events.d.ts +47 -0
  388. package/dist/events/pivot-events.d.ts.map +1 -0
  389. package/dist/events/print-events.d.ts +75 -0
  390. package/dist/events/print-events.d.ts.map +1 -0
  391. package/dist/events/recalc-events.d.ts +20 -0
  392. package/dist/events/recalc-events.d.ts.map +1 -0
  393. package/dist/events/scenario-events.d.ts +37 -0
  394. package/dist/events/scenario-events.d.ts.map +1 -0
  395. package/dist/events/selection-events.d.ts +16 -0
  396. package/dist/events/selection-events.d.ts.map +1 -0
  397. package/dist/events/settings-events.d.ts +41 -0
  398. package/dist/events/settings-events.d.ts.map +1 -0
  399. package/dist/events/sheet-events.d.ts +68 -0
  400. package/dist/events/sheet-events.d.ts.map +1 -0
  401. package/dist/events/slicer-events.d.ts +47 -0
  402. package/dist/events/slicer-events.d.ts.map +1 -0
  403. package/dist/events/smartart-events.d.ts +222 -0
  404. package/dist/events/smartart-events.d.ts.map +1 -0
  405. package/dist/events/sparkline-events.d.ts +68 -0
  406. package/dist/events/sparkline-events.d.ts.map +1 -0
  407. package/dist/events/store-events.d.ts +18 -0
  408. package/dist/events/store-events.d.ts.map +1 -0
  409. package/dist/events/structure-events.d.ts +76 -0
  410. package/dist/events/structure-events.d.ts.map +1 -0
  411. package/dist/events/table-events.d.ts +99 -0
  412. package/dist/events/table-events.d.ts.map +1 -0
  413. package/dist/events/validation-events.d.ts +85 -0
  414. package/dist/events/validation-events.d.ts.map +1 -0
  415. package/dist/events/view-events.d.ts +72 -0
  416. package/dist/events/view-events.d.ts.map +1 -0
  417. package/dist/events/wordart-events.d.ts +169 -0
  418. package/dist/events/wordart-events.d.ts.map +1 -0
  419. package/dist/events.d.ts +41 -0
  420. package/dist/events.d.ts.map +1 -0
  421. package/dist/extensions/index.d.ts +9 -0
  422. package/dist/extensions/index.d.ts.map +1 -0
  423. package/dist/extensions/types.d.ts +64 -0
  424. package/dist/extensions/types.d.ts.map +1 -0
  425. package/dist/filesystem/index.d.ts +11 -0
  426. package/dist/filesystem/index.d.ts.map +1 -0
  427. package/dist/filesystem/paths.d.ts +38 -0
  428. package/dist/filesystem/paths.d.ts.map +1 -0
  429. package/dist/filesystem/permissions.d.ts +89 -0
  430. package/dist/filesystem/permissions.d.ts.map +1 -0
  431. package/dist/filesystem/types.d.ts +251 -0
  432. package/dist/filesystem/types.d.ts.map +1 -0
  433. package/dist/fill/custom-lists.d.ts +41 -0
  434. package/dist/fill/custom-lists.d.ts.map +1 -0
  435. package/dist/fill/index.d.ts +11 -0
  436. package/dist/fill/index.d.ts.map +1 -0
  437. package/dist/fill/types.d.ts +102 -0
  438. package/dist/fill/types.d.ts.map +1 -0
  439. package/dist/formatting/format-registry.d.ts +45 -0
  440. package/dist/formatting/format-registry.d.ts.map +1 -0
  441. package/dist/formatting/index.d.ts +9 -0
  442. package/dist/formatting/index.d.ts.map +1 -0
  443. package/dist/formatting/theme.d.ts +108 -0
  444. package/dist/formatting/theme.d.ts.map +1 -0
  445. package/dist/index.d.ts +49 -0
  446. package/dist/index.d.ts.map +1 -0
  447. package/dist/ink/index.d.ts +16 -0
  448. package/dist/ink/index.d.ts.map +1 -0
  449. package/dist/ink/spatial-index.d.ts +113 -0
  450. package/dist/ink/spatial-index.d.ts.map +1 -0
  451. package/dist/ink/types.d.ts +558 -0
  452. package/dist/ink/types.d.ts.map +1 -0
  453. package/dist/kernel/floating-object-manager.d.ts +68 -0
  454. package/dist/kernel/floating-object-manager.d.ts.map +1 -0
  455. package/dist/kernel/index.d.ts +12 -0
  456. package/dist/kernel/index.d.ts.map +1 -0
  457. package/dist/kernel/kernel-context.d.ts +129 -0
  458. package/dist/kernel/kernel-context.d.ts.map +1 -0
  459. package/dist/keyboard/actions.d.ts +328 -0
  460. package/dist/keyboard/actions.d.ts.map +1 -0
  461. package/dist/keyboard/binding-utils.d.ts +112 -0
  462. package/dist/keyboard/binding-utils.d.ts.map +1 -0
  463. package/dist/keyboard/customization.d.ts +121 -0
  464. package/dist/keyboard/customization.d.ts.map +1 -0
  465. package/dist/keyboard/display-utils.d.ts +9 -0
  466. package/dist/keyboard/display-utils.d.ts.map +1 -0
  467. package/dist/keyboard/excel-reference.d.ts +28 -0
  468. package/dist/keyboard/excel-reference.d.ts.map +1 -0
  469. package/dist/keyboard/index.d.ts +16 -0
  470. package/dist/keyboard/index.d.ts.map +1 -0
  471. package/dist/keyboard/input.d.ts +124 -0
  472. package/dist/keyboard/input.d.ts.map +1 -0
  473. package/dist/keyboard/physical-keys.d.ts +79 -0
  474. package/dist/keyboard/physical-keys.d.ts.map +1 -0
  475. package/dist/keyboard/shortcuts/definitions/index.d.ts +10 -0
  476. package/dist/keyboard/shortcuts/definitions/index.d.ts.map +1 -0
  477. package/dist/keyboard/shortcuts/types.d.ts +347 -0
  478. package/dist/keyboard/shortcuts/types.d.ts.map +1 -0
  479. package/dist/machines/index.d.ts +12 -0
  480. package/dist/machines/index.d.ts.map +1 -0
  481. package/dist/machines/snapshots.d.ts +160 -0
  482. package/dist/machines/snapshots.d.ts.map +1 -0
  483. package/dist/machines/types.d.ts +64 -0
  484. package/dist/machines/types.d.ts.map +1 -0
  485. package/dist/number-formats/constants.d.ts +39 -0
  486. package/dist/number-formats/constants.d.ts.map +1 -0
  487. package/dist/number-formats/index.d.ts +14 -0
  488. package/dist/number-formats/index.d.ts.map +1 -0
  489. package/dist/number-formats/locale/index.d.ts +5 -0
  490. package/dist/number-formats/locale/index.d.ts.map +1 -0
  491. package/dist/number-formats/locale/locale-defaults.d.ts +17 -0
  492. package/dist/number-formats/locale/locale-defaults.d.ts.map +1 -0
  493. package/dist/number-formats/registry.d.ts +52 -0
  494. package/dist/number-formats/registry.d.ts.map +1 -0
  495. package/dist/number-formats/types.d.ts +134 -0
  496. package/dist/number-formats/types.d.ts.map +1 -0
  497. package/dist/objects/canvas-object.d.ts +157 -0
  498. package/dist/objects/canvas-object.d.ts.map +1 -0
  499. package/dist/objects/drawing-object.d.ts +144 -0
  500. package/dist/objects/drawing-object.d.ts.map +1 -0
  501. package/dist/objects/floating-objects.d.ts +742 -0
  502. package/dist/objects/floating-objects.d.ts.map +1 -0
  503. package/dist/objects/index.d.ts +5 -0
  504. package/dist/objects/index.d.ts.map +1 -0
  505. package/dist/objects/object-bounds-reader.d.ts +25 -0
  506. package/dist/objects/object-bounds-reader.d.ts.map +1 -0
  507. package/dist/objects/object-mutator.d.ts +30 -0
  508. package/dist/objects/object-mutator.d.ts.map +1 -0
  509. package/dist/performance/index.d.ts +8 -0
  510. package/dist/performance/index.d.ts.map +1 -0
  511. package/dist/performance/profiler-types.d.ts +351 -0
  512. package/dist/performance/profiler-types.d.ts.map +1 -0
  513. package/dist/platform/identity.d.ts +24 -0
  514. package/dist/platform/identity.d.ts.map +1 -0
  515. package/dist/platform/index.d.ts +17 -0
  516. package/dist/platform/index.d.ts.map +1 -0
  517. package/dist/platform/types.d.ts +359 -0
  518. package/dist/platform/types.d.ts.map +1 -0
  519. package/dist/rendering/canvas-bridge-types.d.ts +68 -0
  520. package/dist/rendering/canvas-bridge-types.d.ts.map +1 -0
  521. package/dist/rendering/constants.d.ts +76 -0
  522. package/dist/rendering/constants.d.ts.map +1 -0
  523. package/dist/rendering/coordinates.d.ts +452 -0
  524. package/dist/rendering/coordinates.d.ts.map +1 -0
  525. package/dist/rendering/coordinator-interfaces.d.ts +163 -0
  526. package/dist/rendering/coordinator-interfaces.d.ts.map +1 -0
  527. package/dist/rendering/data-sources.d.ts +372 -0
  528. package/dist/rendering/data-sources.d.ts.map +1 -0
  529. package/dist/rendering/grid-region.d.ts +32 -0
  530. package/dist/rendering/grid-region.d.ts.map +1 -0
  531. package/dist/rendering/grid-renderer.d.ts +391 -0
  532. package/dist/rendering/grid-renderer.d.ts.map +1 -0
  533. package/dist/rendering/grouping.d.ts +21 -0
  534. package/dist/rendering/grouping.d.ts.map +1 -0
  535. package/dist/rendering/hit-test-service.d.ts +58 -0
  536. package/dist/rendering/hit-test-service.d.ts.map +1 -0
  537. package/dist/rendering/hit-test.d.ts +223 -0
  538. package/dist/rendering/hit-test.d.ts.map +1 -0
  539. package/dist/rendering/index.d.ts +25 -0
  540. package/dist/rendering/index.d.ts.map +1 -0
  541. package/dist/rendering/interactive-elements.d.ts +121 -0
  542. package/dist/rendering/interactive-elements.d.ts.map +1 -0
  543. package/dist/rendering/primitives.d.ts +17 -0
  544. package/dist/rendering/primitives.d.ts.map +1 -0
  545. package/dist/rendering/render-context.d.ts +457 -0
  546. package/dist/rendering/render-context.d.ts.map +1 -0
  547. package/dist/rendering/text-measurement-service.d.ts +197 -0
  548. package/dist/rendering/text-measurement-service.d.ts.map +1 -0
  549. package/dist/ribbon/collapse-configs.d.ts +298 -0
  550. package/dist/ribbon/collapse-configs.d.ts.map +1 -0
  551. package/dist/ribbon/collapse-types.d.ts +76 -0
  552. package/dist/ribbon/collapse-types.d.ts.map +1 -0
  553. package/dist/ribbon/index.d.ts +25 -0
  554. package/dist/ribbon/index.d.ts.map +1 -0
  555. package/dist/selection/index.d.ts +10 -0
  556. package/dist/selection/index.d.ts.map +1 -0
  557. package/dist/selection/registry.d.ts +17 -0
  558. package/dist/selection/registry.d.ts.map +1 -0
  559. package/dist/selection/types.d.ts +82 -0
  560. package/dist/selection/types.d.ts.map +1 -0
  561. package/dist/selectors/index.d.ts +8 -0
  562. package/dist/selectors/index.d.ts.map +1 -0
  563. package/dist/selectors/smart-art.d.ts +58 -0
  564. package/dist/selectors/smart-art.d.ts.map +1 -0
  565. package/dist/services/index.d.ts +273 -0
  566. package/dist/services/index.d.ts.map +1 -0
  567. package/dist/smartart/index.d.ts +26 -0
  568. package/dist/smartart/index.d.ts.map +1 -0
  569. package/dist/smartart/layouts.d.ts +193 -0
  570. package/dist/smartart/layouts.d.ts.map +1 -0
  571. package/dist/smartart/ooxml-algorithm-types.d.ts +939 -0
  572. package/dist/smartart/ooxml-algorithm-types.d.ts.map +1 -0
  573. package/dist/smartart/ooxml-data-model-types.d.ts +845 -0
  574. package/dist/smartart/ooxml-data-model-types.d.ts.map +1 -0
  575. package/dist/smartart/ooxml-drawing-types.d.ts +356 -0
  576. package/dist/smartart/ooxml-drawing-types.d.ts.map +1 -0
  577. package/dist/smartart/ooxml-engine-types.d.ts +873 -0
  578. package/dist/smartart/ooxml-engine-types.d.ts.map +1 -0
  579. package/dist/smartart/ooxml-layout-types.d.ts +405 -0
  580. package/dist/smartart/ooxml-layout-types.d.ts.map +1 -0
  581. package/dist/smartart/ooxml-style-types.d.ts +474 -0
  582. package/dist/smartart/ooxml-style-types.d.ts.map +1 -0
  583. package/dist/smartart/styles.d.ts +137 -0
  584. package/dist/smartart/styles.d.ts.map +1 -0
  585. package/dist/smartart/types.d.ts +323 -0
  586. package/dist/smartart/types.d.ts.map +1 -0
  587. package/dist/storage/capabilities.d.ts +33 -0
  588. package/dist/storage/capabilities.d.ts.map +1 -0
  589. package/dist/storage/connection.d.ts +183 -0
  590. package/dist/storage/connection.d.ts.map +1 -0
  591. package/dist/storage/index.d.ts +13 -0
  592. package/dist/storage/index.d.ts.map +1 -0
  593. package/dist/storage/query.d.ts +91 -0
  594. package/dist/storage/query.d.ts.map +1 -0
  595. package/dist/storage/table-driver.d.ts +249 -0
  596. package/dist/storage/table-driver.d.ts.map +1 -0
  597. package/dist/store/cell-schema.d.ts +235 -0
  598. package/dist/store/cell-schema.d.ts.map +1 -0
  599. package/dist/store/equation-schema.d.ts +22 -0
  600. package/dist/store/equation-schema.d.ts.map +1 -0
  601. package/dist/store/index.d.ts +33 -0
  602. package/dist/store/index.d.ts.map +1 -0
  603. package/dist/store/ink-schema.d.ts +26 -0
  604. package/dist/store/ink-schema.d.ts.map +1 -0
  605. package/dist/store/scenarios-schema.d.ts +105 -0
  606. package/dist/store/scenarios-schema.d.ts.map +1 -0
  607. package/dist/store/schema-types.d.ts +113 -0
  608. package/dist/store/schema-types.d.ts.map +1 -0
  609. package/dist/store/sheet-maps-schema.d.ts +222 -0
  610. package/dist/store/sheet-maps-schema.d.ts.map +1 -0
  611. package/dist/store/sheet-meta-schema.d.ts +16 -0
  612. package/dist/store/sheet-meta-schema.d.ts.map +1 -0
  613. package/dist/store/smartart-schema.d.ts +17 -0
  614. package/dist/store/smartart-schema.d.ts.map +1 -0
  615. package/dist/store/store-types.d.ts +381 -0
  616. package/dist/store/store-types.d.ts.map +1 -0
  617. package/dist/store/wordart-schema.d.ts +13 -0
  618. package/dist/store/wordart-schema.d.ts.map +1 -0
  619. package/dist/store/workbook-schema.d.ts +16 -0
  620. package/dist/store/workbook-schema.d.ts.map +1 -0
  621. package/dist/styles/built-in-styles.d.ts +10 -0
  622. package/dist/styles/built-in-styles.d.ts.map +1 -0
  623. package/dist/styles/index.d.ts +18 -0
  624. package/dist/styles/index.d.ts.map +1 -0
  625. package/dist/utils/a1.d.ts +12 -0
  626. package/dist/utils/a1.d.ts.map +1 -0
  627. package/dist/utils/datetime.d.ts +7 -0
  628. package/dist/utils/datetime.d.ts.map +1 -0
  629. package/dist/utils/function-registry.d.ts +40 -0
  630. package/dist/utils/function-registry.d.ts.map +1 -0
  631. package/dist/utils/index.d.ts +9 -0
  632. package/dist/utils/index.d.ts.map +1 -0
  633. package/dist/utils/protection.d.ts +9 -0
  634. package/dist/utils/protection.d.ts.map +1 -0
  635. package/dist/utils/range-navigation.d.ts +9 -0
  636. package/dist/utils/range-navigation.d.ts.map +1 -0
  637. package/dist/utils/range.d.ts +9 -0
  638. package/dist/utils/range.d.ts.map +1 -0
  639. package/dist/utils/rich-text.d.ts +9 -0
  640. package/dist/utils/rich-text.d.ts.map +1 -0
  641. package/dist/viewport/geometry.d.ts +90 -0
  642. package/dist/viewport/geometry.d.ts.map +1 -0
  643. package/dist/viewport/grid-canvas.d.ts +133 -0
  644. package/dist/viewport/grid-canvas.d.ts.map +1 -0
  645. package/dist/viewport/index.d.ts +5 -0
  646. package/dist/viewport/index.d.ts.map +1 -0
  647. package/dist/viewport/viewport-config.d.ts +95 -0
  648. package/dist/viewport/viewport-config.d.ts.map +1 -0
  649. package/dist/viewport/viewport.d.ts +191 -0
  650. package/dist/viewport/viewport.d.ts.map +1 -0
  651. package/dist/views/index.d.ts +9 -0
  652. package/dist/views/index.d.ts.map +1 -0
  653. package/dist/views/types.d.ts +161 -0
  654. package/dist/views/types.d.ts.map +1 -0
  655. package/dist/what-if/index.d.ts +2 -0
  656. package/dist/what-if/index.d.ts.map +1 -0
  657. package/dist/what-if/what-if.d.ts +152 -0
  658. package/dist/what-if/what-if.d.ts.map +1 -0
  659. package/dist/window-manager/index.d.ts +134 -0
  660. package/dist/window-manager/index.d.ts.map +1 -0
  661. package/dist/wordart/effects.d.ts +611 -0
  662. package/dist/wordart/effects.d.ts.map +1 -0
  663. package/dist/wordart/index.d.ts +17 -0
  664. package/dist/wordart/index.d.ts.map +1 -0
  665. package/dist/wordart/presets.d.ts +133 -0
  666. package/dist/wordart/presets.d.ts.map +1 -0
  667. package/dist/wordart/types.d.ts +444 -0
  668. package/dist/wordart/types.d.ts.map +1 -0
  669. package/dist/workflows/context.d.ts +777 -0
  670. package/dist/workflows/context.d.ts.map +1 -0
  671. package/dist/workflows/definition.d.ts +256 -0
  672. package/dist/workflows/definition.d.ts.map +1 -0
  673. package/dist/workflows/events.d.ts +397 -0
  674. package/dist/workflows/events.d.ts.map +1 -0
  675. package/dist/workflows/index.d.ts +19 -0
  676. package/dist/workflows/index.d.ts.map +1 -0
  677. package/dist/workflows/instance.d.ts +358 -0
  678. package/dist/workflows/instance.d.ts.map +1 -0
  679. package/dist/workflows/runtime.d.ts +287 -0
  680. package/dist/workflows/runtime.d.ts.map +1 -0
  681. package/dist/workflows/triggers.d.ts +335 -0
  682. package/dist/workflows/triggers.d.ts.map +1 -0
  683. package/dist/workflows/versioning.d.ts +245 -0
  684. package/dist/workflows/versioning.d.ts.map +1 -0
  685. package/dist/xlsx-parser/conditional-format.d.ts +137 -0
  686. package/dist/xlsx-parser/conditional-format.d.ts.map +1 -0
  687. package/dist/xlsx-parser/core.d.ts +622 -0
  688. package/dist/xlsx-parser/core.d.ts.map +1 -0
  689. package/dist/xlsx-parser/data-validation.d.ts +55 -0
  690. package/dist/xlsx-parser/data-validation.d.ts.map +1 -0
  691. package/dist/xlsx-parser/errors.d.ts +38 -0
  692. package/dist/xlsx-parser/errors.d.ts.map +1 -0
  693. package/dist/xlsx-parser/index.d.ts +17 -0
  694. package/dist/xlsx-parser/index.d.ts.map +1 -0
  695. package/dist/xlsx-parser/options.d.ts +89 -0
  696. package/dist/xlsx-parser/options.d.ts.map +1 -0
  697. package/dist/xlsx-parser/styles.d.ts +157 -0
  698. package/dist/xlsx-parser/styles.d.ts.map +1 -0
  699. package/dist/xlsx-parser/table.d.ts +170 -0
  700. package/dist/xlsx-parser/table.d.ts.map +1 -0
  701. package/package.json +410 -0
@@ -0,0 +1,142 @@
1
+ /**
2
+ * Ink Recognition Bridge Interface
3
+ *
4
+ * Bridge interface for converting ink strokes into geometric shapes or text.
5
+ * Provides shape recognition (local algorithms) and text recognition (browser API).
6
+ *
7
+ * Bridge Pattern:
8
+ * - Interface defined here in contracts/
9
+ * - Implementation in engine/src/bridges/
10
+ * - Accessed via DocumentContext for dependency injection
11
+ *
12
+ * @see plans/active/ink-engine/07-INK-RECOGNITION.md
13
+ * @see contracts/src/ink/types.ts for InkStroke, RecognizedShape, RecognizedText
14
+ */
15
+ import type { InkStroke, RecognizedShapeType, ShapeParams } from '../ink/types';
16
+ /**
17
+ * Result of shape recognition.
18
+ *
19
+ * Contains the recognized shape type, confidence score, bounding box,
20
+ * and shape-specific parameters.
21
+ */
22
+ export interface ShapeRecognitionResult {
23
+ /** Type of recognized shape */
24
+ type: RecognizedShapeType;
25
+ /** Confidence score [0, 1] */
26
+ confidence: number;
27
+ /** Bounding box of the recognized shape */
28
+ bounds: {
29
+ x: number;
30
+ y: number;
31
+ width: number;
32
+ height: number;
33
+ };
34
+ /** Shape-specific parameters */
35
+ params: ShapeParams;
36
+ }
37
+ /**
38
+ * Result of text recognition.
39
+ *
40
+ * Contains the recognized text string, confidence score, and optional bounds.
41
+ */
42
+ export interface TextRecognitionResult {
43
+ /** Recognized text string */
44
+ text: string;
45
+ /** Confidence score [0, 1] */
46
+ confidence: number;
47
+ /** Bounding box of the text (null if not available) */
48
+ bounds: {
49
+ x: number;
50
+ y: number;
51
+ width: number;
52
+ height: number;
53
+ } | null;
54
+ }
55
+ /**
56
+ * Configurable confidence thresholds per shape type.
57
+ *
58
+ * Users can tune these based on their drawing precision:
59
+ * - Lower values = more permissive (may get false positives)
60
+ * - Higher values = stricter (may miss intended shapes)
61
+ */
62
+ export interface RecognitionThresholds {
63
+ /** Threshold for line recognition (default: 0.70) */
64
+ line: number;
65
+ /** Threshold for rectangle recognition (default: 0.65) */
66
+ rectangle: number;
67
+ /** Threshold for ellipse/circle recognition (default: 0.70) */
68
+ ellipse: number;
69
+ /** Threshold for triangle recognition (default: 0.60) */
70
+ triangle: number;
71
+ /** Threshold for arrow recognition (default: 0.60) */
72
+ arrow: number;
73
+ /** Threshold for star recognition (default: 0.65) */
74
+ star: number;
75
+ /** Threshold for text recognition (default: 0.50) */
76
+ text: number;
77
+ }
78
+ /**
79
+ * Default thresholds - balanced for most users.
80
+ */
81
+ export declare const DEFAULT_RECOGNITION_THRESHOLDS: RecognitionThresholds;
82
+ /**
83
+ * Bridge interface for ink recognition.
84
+ *
85
+ * Provides methods for recognizing strokes as shapes or text,
86
+ * with configurable confidence thresholds.
87
+ */
88
+ export interface IInkRecognitionBridge {
89
+ /**
90
+ * Recognize strokes as a geometric shape.
91
+ *
92
+ * Returns the highest-confidence match above its type's threshold.
93
+ * Returns null if no shape is recognized with sufficient confidence.
94
+ *
95
+ * @param strokes - Array of strokes to analyze
96
+ * @returns Recognition result or null
97
+ */
98
+ recognizeShape(strokes: InkStroke[]): Promise<ShapeRecognitionResult | null>;
99
+ /**
100
+ * Recognize strokes as handwritten text.
101
+ *
102
+ * Uses browser Handwriting Recognition API when available.
103
+ * Returns null if recognition fails or API is unavailable.
104
+ *
105
+ * @param strokes - Array of strokes to analyze
106
+ * @returns Recognition result or null
107
+ */
108
+ recognizeText(strokes: InkStroke[]): Promise<TextRecognitionResult | null>;
109
+ /**
110
+ * Check if shape recognition is available.
111
+ *
112
+ * Shape recognition uses local algorithms, so it's always available.
113
+ */
114
+ isShapeRecognitionAvailable(): boolean;
115
+ /**
116
+ * Check if text recognition is available.
117
+ *
118
+ * Text recognition requires the browser Handwriting Recognition API.
119
+ */
120
+ isTextRecognitionAvailable(): boolean;
121
+ /**
122
+ * Update recognition thresholds.
123
+ *
124
+ * Allows runtime tuning without recreating the bridge.
125
+ *
126
+ * @param thresholds - Partial threshold updates
127
+ */
128
+ setThresholds(thresholds: Partial<RecognitionThresholds>): void;
129
+ /**
130
+ * Get current thresholds.
131
+ *
132
+ * @returns Current threshold configuration
133
+ */
134
+ getThresholds(): RecognitionThresholds;
135
+ /**
136
+ * Cleanup resources.
137
+ *
138
+ * Called when the bridge is no longer needed.
139
+ */
140
+ destroy(): void;
141
+ }
142
+ //# sourceMappingURL=ink-recognition-bridge.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ink-recognition-bridge.d.ts","sourceRoot":"","sources":["../../src/bridges/ink-recognition-bridge.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,mBAAmB,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAMhF;;;;;GAKG;AACH,MAAM,WAAW,sBAAsB;IACrC,+BAA+B;IAC/B,IAAI,EAAE,mBAAmB,CAAC;IAC1B,8BAA8B;IAC9B,UAAU,EAAE,MAAM,CAAC;IACnB,2CAA2C;IAC3C,MAAM,EAAE;QAAE,CAAC,EAAE,MAAM,CAAC;QAAC,CAAC,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC;IAChE,gCAAgC;IAChC,MAAM,EAAE,WAAW,CAAC;CACrB;AAED;;;;GAIG;AACH,MAAM,WAAW,qBAAqB;IACpC,6BAA6B;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,8BAA8B;IAC9B,UAAU,EAAE,MAAM,CAAC;IACnB,uDAAuD;IACvD,MAAM,EAAE;QAAE,CAAC,EAAE,MAAM,CAAC;QAAC,CAAC,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC;CACxE;AAMD;;;;;;GAMG;AACH,MAAM,WAAW,qBAAqB;IACpC,qDAAqD;IACrD,IAAI,EAAE,MAAM,CAAC;IACb,0DAA0D;IAC1D,SAAS,EAAE,MAAM,CAAC;IAClB,+DAA+D;IAC/D,OAAO,EAAE,MAAM,CAAC;IAChB,yDAAyD;IACzD,QAAQ,EAAE,MAAM,CAAC;IACjB,sDAAsD;IACtD,KAAK,EAAE,MAAM,CAAC;IACd,qDAAqD;IACrD,IAAI,EAAE,MAAM,CAAC;IACb,qDAAqD;IACrD,IAAI,EAAE,MAAM,CAAC;CACd;AAED;;GAEG;AACH,eAAO,MAAM,8BAA8B,EAAE,qBAQ5C,CAAC;AAMF;;;;;GAKG;AACH,MAAM,WAAW,qBAAqB;IACpC;;;;;;;;OAQG;IACH,cAAc,CAAC,OAAO,EAAE,SAAS,EAAE,GAAG,OAAO,CAAC,sBAAsB,GAAG,IAAI,CAAC,CAAC;IAE7E;;;;;;;;OAQG;IACH,aAAa,CAAC,OAAO,EAAE,SAAS,EAAE,GAAG,OAAO,CAAC,qBAAqB,GAAG,IAAI,CAAC,CAAC;IAE3E;;;;OAIG;IACH,2BAA2B,IAAI,OAAO,CAAC;IAEvC;;;;OAIG;IACH,0BAA0B,IAAI,OAAO,CAAC;IAEtC;;;;;;OAMG;IACH,aAAa,CAAC,UAAU,EAAE,OAAO,CAAC,qBAAqB,CAAC,GAAG,IAAI,CAAC;IAEhE;;;;OAIG;IACH,aAAa,IAAI,qBAAqB,CAAC;IAEvC;;;;OAIG;IACH,OAAO,IAAI,IAAI,CAAC;CACjB"}
@@ -0,0 +1,93 @@
1
+ /**
2
+ * Locale Bridge Interface
3
+ *
4
+ * Defines the contract for locale-aware input normalization.
5
+ * This interface handles locale-specific number parsing, transforming
6
+ * locale-specific formats into normalized format for the schema engine.
7
+ *
8
+ * Features:
9
+ * - Locale-aware decimal separator (1,5 -> 1.5 in European locales)
10
+ * - Locale-aware thousands separator (1.000,50 -> 1000.50)
11
+ * - Locale-aware negative format ((123) -> -123)
12
+ * - Fraction input recognition (1/2 -> 0.5, 3 1/4 -> 3.25)
13
+ * - Format auto-detection from input ($100 -> currency format)
14
+ *
15
+ * @see engine/src/state/bridges/locale-bridge.ts - Implementation
16
+ * @see contracts/src/culture.ts - CultureInfo type
17
+ */
18
+ import type { SheetId } from '../core';
19
+ import type { CultureInfo } from '../culture/types';
20
+ /**
21
+ * Result of normalizing user input.
22
+ */
23
+ export interface LocaleNormalizationResult {
24
+ /** The normalized value (locale-agnostic) */
25
+ normalizedValue: string;
26
+ /** Whether normalization was applied */
27
+ wasNormalized: boolean;
28
+ /** Detected input type for format auto-detection */
29
+ detectedType?: 'number' | 'currency' | 'percentage' | 'fraction' | 'date' | 'time';
30
+ /** Suggested format code based on input */
31
+ suggestedFormat?: string;
32
+ /** Detected currency symbol if any */
33
+ currencySymbol?: string;
34
+ }
35
+ /**
36
+ * Partial cell format for format suggestions.
37
+ */
38
+ export interface PartialCellFormat {
39
+ /** Suggested number format code */
40
+ numberFormat?: string;
41
+ }
42
+ /**
43
+ * Bridge interface for locale-aware input handling.
44
+ *
45
+ * This interface provides methods for normalizing user input according to
46
+ * locale settings and suggesting appropriate cell formats.
47
+ */
48
+ export interface ILocaleBridge {
49
+ /**
50
+ * Normalize user input according to locale settings.
51
+ * Call this before passing input to coercion.
52
+ *
53
+ * @param input - Raw user input string
54
+ * @param sheetId - Sheet for locale lookup (optional)
55
+ * @returns Normalization result with locale-agnostic value
56
+ */
57
+ normalizeInput(input: string, sheetId?: SheetId): LocaleNormalizationResult;
58
+ /**
59
+ * Get the decimal separator for the current locale.
60
+ * Used for numpad decimal key handling.
61
+ *
62
+ * @param sheetId - Sheet for locale lookup (optional)
63
+ * @returns Decimal separator character ('.' or ',')
64
+ */
65
+ getDecimalSeparator(sheetId?: SheetId): string;
66
+ /**
67
+ * Get the thousands separator for the current locale.
68
+ *
69
+ * @param sheetId - Sheet for locale lookup (optional)
70
+ * @returns Thousands separator character (',', '.', or ' ')
71
+ */
72
+ getThousandsSeparator(sheetId?: SheetId): string;
73
+ /**
74
+ * Get the current culture info.
75
+ *
76
+ * @param sheetId - Sheet for locale lookup (optional)
77
+ * @returns Full CultureInfo object
78
+ */
79
+ getCulture(sheetId?: SheetId): CultureInfo;
80
+ /**
81
+ * Suggest a cell format based on input pattern.
82
+ *
83
+ * @param input - Raw user input string
84
+ * @param sheetId - Sheet for locale lookup (optional)
85
+ * @returns Suggested format or undefined
86
+ */
87
+ suggestFormat(input: string, sheetId?: SheetId): PartialCellFormat | undefined;
88
+ /**
89
+ * Cleanup resources.
90
+ */
91
+ destroy(): void;
92
+ }
93
+ //# sourceMappingURL=locale-bridge.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"locale-bridge.d.ts","sourceRoot":"","sources":["../../src/bridges/locale-bridge.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAMpD;;GAEG;AACH,MAAM,WAAW,yBAAyB;IACxC,6CAA6C;IAC7C,eAAe,EAAE,MAAM,CAAC;IACxB,wCAAwC;IACxC,aAAa,EAAE,OAAO,CAAC;IACvB,oDAAoD;IACpD,YAAY,CAAC,EAAE,QAAQ,GAAG,UAAU,GAAG,YAAY,GAAG,UAAU,GAAG,MAAM,GAAG,MAAM,CAAC;IACnF,2CAA2C;IAC3C,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,sCAAsC;IACtC,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,mCAAmC;IACnC,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAMD;;;;;GAKG;AACH,MAAM,WAAW,aAAa;IAK5B;;;;;;;OAOG;IACH,cAAc,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,OAAO,GAAG,yBAAyB,CAAC;IAM5E;;;;;;OAMG;IACH,mBAAmB,CAAC,OAAO,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IAE/C;;;;;OAKG;IACH,qBAAqB,CAAC,OAAO,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IAEjD;;;;;OAKG;IACH,UAAU,CAAC,OAAO,CAAC,EAAE,OAAO,GAAG,WAAW,CAAC;IAM3C;;;;;;OAMG;IACH,aAAa,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,OAAO,GAAG,iBAAiB,GAAG,SAAS,CAAC;IAM/E;;OAEG;IACH,OAAO,IAAI,IAAI,CAAC;CACjB"}
@@ -0,0 +1,201 @@
1
+ /**
2
+ * Pivot Bridge Interface
3
+ *
4
+ * Defines the contract for pivot table computation and caching.
5
+ * This interface wraps IPivotEngine (from pivot.ts) with engine-specific
6
+ * functionality like result caching and subscription.
7
+ *
8
+ * NOTE: IPivotEngine already exists in contracts/src/pivot.ts and handles
9
+ * the core computation. IPivotBridge adds:
10
+ * - Result caching with invalidation
11
+ * - Subscription for reactive updates
12
+ * - Integration with DocumentContext
13
+ *
14
+ * @see contracts/src/pivot.ts - IPivotEngine (core computation)
15
+ * @see engine/src/state/bridges/pivot-bridge.ts - Implementation
16
+ */
17
+ import type { CellValue, SheetId } from '../core';
18
+ import type { PivotField, PivotTableConfig, PivotTableResult } from '../data/pivot';
19
+ /**
20
+ * Callback for pivot result updates.
21
+ */
22
+ export type PivotResultCallback = (pivotId: string, result: PivotTableResult | null, error?: string) => void;
23
+ /**
24
+ * Cache statistics for debugging/monitoring.
25
+ */
26
+ export interface PivotCacheStats {
27
+ /** Number of cached results */
28
+ size: number;
29
+ /** Individual cache entries */
30
+ entries: Array<{
31
+ pivotId: string;
32
+ computedAt: number;
33
+ ageMs: number;
34
+ }>;
35
+ }
36
+ /**
37
+ * Bridge interface for pivot table computation.
38
+ *
39
+ * This interface provides methods for computing pivot tables with caching,
40
+ * subscription for reactive updates, and field detection.
41
+ *
42
+ * All CRUD operations delegate to the Rust compute engine.
43
+ * The former IPivotStore/PivotStore has been deleted (Phase 4).
44
+ */
45
+ export interface IPivotBridge {
46
+ /**
47
+ * Create a new pivot table.
48
+ * Delegates to Rust compute engine which generates the ID and timestamps.
49
+ *
50
+ * @param config - Pivot table configuration (without id, createdAt, updatedAt)
51
+ * @returns Created pivot table configuration with generated ID
52
+ */
53
+ createPivot(config: PivotTableConfig): Promise<PivotTableConfig>;
54
+ /**
55
+ * Get a single pivot table by ID.
56
+ *
57
+ * @param sheetId - Output sheet ID where the pivot is displayed
58
+ * @param pivotId - Pivot table ID
59
+ * @returns Pivot table configuration or null if not found
60
+ */
61
+ getPivot(sheetId: string, pivotId: string): Promise<PivotTableConfig | null>;
62
+ /**
63
+ * Get all pivot tables displayed on a sheet.
64
+ *
65
+ * @param sheetId - Output sheet ID
66
+ * @returns Array of pivot table configurations
67
+ */
68
+ getAllPivots(sheetId: string): Promise<PivotTableConfig[]>;
69
+ /**
70
+ * Update a pivot table configuration by merging partial updates.
71
+ * All granular operations (addFieldPlacement, setAggregateFunction, etc.)
72
+ * map to this method with different partial configs.
73
+ *
74
+ * @param sheetId - Output sheet ID where the pivot is displayed
75
+ * @param pivotId - Pivot table ID
76
+ * @param updates - Partial configuration updates
77
+ * @returns Updated configuration or null if not found
78
+ */
79
+ updatePivot(sheetId: string, pivotId: string, updates: Partial<PivotTableConfig>): Promise<PivotTableConfig | null>;
80
+ /**
81
+ * Delete a pivot table.
82
+ *
83
+ * @param sheetId - Output sheet ID where the pivot is displayed
84
+ * @param pivotId - Pivot table ID
85
+ * @returns True if deleted, false if not found
86
+ */
87
+ deletePivot(sheetId: string, pivotId: string): Promise<boolean>;
88
+ /**
89
+ * Atomically create a new sheet AND a pivot table on it.
90
+ * Both operations happen in a single transaction for undo atomicity.
91
+ *
92
+ * @param sheetName - Name for the new sheet
93
+ * @param config - Pivot table configuration
94
+ * @returns The new sheet's ID and the stored pivot config
95
+ */
96
+ createPivotWithSheet(sheetName: string, config: PivotTableConfig): Promise<{
97
+ sheetId: string;
98
+ config: PivotTableConfig;
99
+ }>;
100
+ /**
101
+ * Compute a pivot table result.
102
+ * Uses cached result if available and valid.
103
+ *
104
+ * @param sheetId - Sheet containing the pivot table
105
+ * @param pivotId - Pivot table ID
106
+ * @param forceRefresh - Force recomputation ignoring cache
107
+ * @returns Computed pivot table result or null if not found/failed
108
+ */
109
+ compute(sheetId: SheetId, pivotId: string, forceRefresh?: boolean): Promise<PivotTableResult | null>;
110
+ /**
111
+ * Compute all pivot tables in a sheet.
112
+ *
113
+ * @param sheetId - Sheet ID
114
+ * @returns Map of pivot ID to result
115
+ */
116
+ computeAll(sheetId: SheetId): Promise<Map<string, PivotTableResult>>;
117
+ /**
118
+ * Refresh a pivot table (recompute without cache).
119
+ *
120
+ * @param sheetId - Sheet ID
121
+ * @param pivotId - Pivot table ID
122
+ * @returns Recomputed result
123
+ */
124
+ refresh(sheetId: SheetId, pivotId: string): Promise<PivotTableResult | null>;
125
+ /**
126
+ * Refresh all pivot tables that depend on a sheet's data.
127
+ *
128
+ * @param sourceSheetId - Sheet whose data changed
129
+ */
130
+ refreshDependentPivots(sourceSheetId: SheetId): Promise<void>;
131
+ /**
132
+ * Detect fields from source data range.
133
+ *
134
+ * @param sourceSheetId - Sheet containing source data
135
+ * @param range - Data range to analyze
136
+ * @returns Array of detected fields
137
+ */
138
+ detectFields(sourceSheetId: SheetId, range: {
139
+ startRow: number;
140
+ startCol: number;
141
+ endRow: number;
142
+ endCol: number;
143
+ }): Promise<PivotField[]>;
144
+ /**
145
+ * Get source row indices for a pivot cell (drill-down).
146
+ *
147
+ * @param sheetId - Sheet ID
148
+ * @param pivotId - Pivot table ID
149
+ * @param rowKey - Row key from result
150
+ * @param columnKey - Column key from result
151
+ * @returns Source row indices that contribute to this cell
152
+ */
153
+ drillDown(sheetId: SheetId, pivotId: string, rowKey: string, columnKey: string): Promise<number[]>;
154
+ /**
155
+ * Get actual source rows for a pivot cell.
156
+ *
157
+ * @param sheetId - Sheet ID
158
+ * @param pivotId - Pivot table ID
159
+ * @param rowKey - Row key from result
160
+ * @param columnKey - Column key from result
161
+ * @returns Source data rows
162
+ */
163
+ getDrillDownData(sheetId: SheetId, pivotId: string, rowKey: string, columnKey: string): Promise<CellValue[][]>;
164
+ /**
165
+ * Subscribe to updates for a specific pivot table.
166
+ *
167
+ * @param pivotId - Pivot table ID
168
+ * @param callback - Called when pivot result changes
169
+ * @returns Unsubscribe function
170
+ */
171
+ subscribe(pivotId: string, callback: PivotResultCallback): () => void;
172
+ /**
173
+ * Get current cached result for a pivot table.
174
+ *
175
+ * @param pivotId - Pivot table ID
176
+ * @returns Cached result or null
177
+ */
178
+ getCachedResult(pivotId: string): PivotTableResult | null;
179
+ /**
180
+ * Invalidate cache for a specific pivot table.
181
+ *
182
+ * @param pivotId - Pivot table ID
183
+ */
184
+ invalidateCache(pivotId: string): void;
185
+ /**
186
+ * Invalidate all cached results.
187
+ */
188
+ invalidateAllCache(): void;
189
+ /**
190
+ * Get cache statistics.
191
+ *
192
+ * @returns Cache statistics
193
+ */
194
+ getCacheStats(): PivotCacheStats;
195
+ /**
196
+ * Clean up resources.
197
+ */
198
+ destroy(): void;
199
+ }
200
+ export type { IPivotEngine, PivotTableConfig, PivotTableResult } from '../data/pivot';
201
+ //# sourceMappingURL=pivot-bridge.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pivot-bridge.d.ts","sourceRoot":"","sources":["../../src/bridges/pivot-bridge.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAClD,OAAO,KAAK,EAAE,UAAU,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAMpF;;GAEG;AACH,MAAM,MAAM,mBAAmB,GAAG,CAChC,OAAO,EAAE,MAAM,EACf,MAAM,EAAE,gBAAgB,GAAG,IAAI,EAC/B,KAAK,CAAC,EAAE,MAAM,KACX,IAAI,CAAC;AAEV;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,+BAA+B;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,+BAA+B;IAC/B,OAAO,EAAE,KAAK,CAAC;QACb,OAAO,EAAE,MAAM,CAAC;QAChB,UAAU,EAAE,MAAM,CAAC;QACnB,KAAK,EAAE,MAAM,CAAC;KACf,CAAC,CAAC;CACJ;AAMD;;;;;;;;GAQG;AACH,MAAM,WAAW,YAAY;IAK3B;;;;;;OAMG;IACH,WAAW,CAAC,MAAM,EAAE,gBAAgB,GAAG,OAAO,CAAC,gBAAgB,CAAC,CAAC;IAEjE;;;;;;OAMG;IACH,QAAQ,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC,CAAC;IAE7E;;;;;OAKG;IACH,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,gBAAgB,EAAE,CAAC,CAAC;IAE3D;;;;;;;;;OASG;IACH,WAAW,CACT,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,OAAO,CAAC,gBAAgB,CAAC,GACjC,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC,CAAC;IAEpC;;;;;;OAMG;IACH,WAAW,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;IAEhE;;;;;;;OAOG;IACH,oBAAoB,CAClB,SAAS,EAAE,MAAM,EACjB,MAAM,EAAE,gBAAgB,GACvB,OAAO,CAAC;QAAE,OAAO,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,gBAAgB,CAAA;KAAE,CAAC,CAAC;IAM1D;;;;;;;;OAQG;IACH,OAAO,CACL,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,MAAM,EACf,YAAY,CAAC,EAAE,OAAO,GACrB,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC,CAAC;IAEpC;;;;;OAKG;IACH,UAAU,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,gBAAgB,CAAC,CAAC,CAAC;IAErE;;;;;;OAMG;IACH,OAAO,CAAC,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC,CAAC;IAE7E;;;;OAIG;IACH,sBAAsB,CAAC,aAAa,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAM9D;;;;;;OAMG;IACH,YAAY,CACV,aAAa,EAAE,OAAO,EACtB,KAAK,EAAE;QAAE,QAAQ,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,GAC5E,OAAO,CAAC,UAAU,EAAE,CAAC,CAAC;IAMzB;;;;;;;;OAQG;IACH,SAAS,CACP,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,MAAM,EACf,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,MAAM,EAAE,CAAC,CAAC;IAErB;;;;;;;;OAQG;IACH,gBAAgB,CACd,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,MAAM,EACf,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,SAAS,EAAE,EAAE,CAAC,CAAC;IAM1B;;;;;;OAMG;IACH,SAAS,CAAC,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,mBAAmB,GAAG,MAAM,IAAI,CAAC;IAEtE;;;;;OAKG;IACH,eAAe,CAAC,OAAO,EAAE,MAAM,GAAG,gBAAgB,GAAG,IAAI,CAAC;IAM1D;;;;OAIG;IACH,eAAe,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IAEvC;;OAEG;IACH,kBAAkB,IAAI,IAAI,CAAC;IAE3B;;;;OAIG;IACH,aAAa,IAAI,eAAe,CAAC;IAMjC;;OAEG;IACH,OAAO,IAAI,IAAI,CAAC;CACjB;AAQD,YAAY,EAAE,YAAY,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC"}
@@ -0,0 +1,137 @@
1
+ /**
2
+ * Schema Bridge Interface
3
+ *
4
+ * Defines the contract for schema validation and type checking.
5
+ * This interface wraps ISchemaValidator (from schema.ts) with engine-specific
6
+ * functionality like event-driven validation and cell metadata storage.
7
+ *
8
+ * Validation is primarily owned by Rust compute-core, which validates cells
9
+ * during every mutation (in prepare_recalc_for_flush). Annotations flow through
10
+ * MutationResult.recalc.validationAnnotations and are emitted as
11
+ * `validation:recalc-annotations` EventBus events. The SchemaBridge listens
12
+ * for these events and processes the annotations (storing errors in cell
13
+ * metadata and emitting validation:failed / validation:passed events).
14
+ *
15
+ * NOTE: ISchemaValidator and ISchemaRegistry already exist in contracts/src/schema.ts
16
+ * and handle core validation/registry operations. ISchemaBridge adds:
17
+ * - Processing validation annotations from Rust recalc results
18
+ * - Validation error storage in cell metadata
19
+ * - Event emission for validation results
20
+ * - On-demand validation (validateColumn, validateSheet)
21
+ *
22
+ * @see contracts/src/schema.ts - ISchemaValidator, ISchemaRegistry (core validation)
23
+ * @see kernel/src/bridges/schema-bridge.ts - Implementation
24
+ */
25
+ import type { SheetId, ValidationError } from '../core';
26
+ import type { ValidationRecalcAnnotationsEvent } from '../events/validation-events';
27
+ /**
28
+ * Options for schema validation bridge.
29
+ */
30
+ export interface SchemaValidationOptions {
31
+ /**
32
+ * Whether to validate on every cell change.
33
+ * @default true
34
+ */
35
+ validateOnChange?: boolean;
36
+ /**
37
+ * Whether to clear validation errors when a cell is cleared.
38
+ * @default true
39
+ */
40
+ clearErrorsOnEmpty?: boolean;
41
+ /**
42
+ * Whether to emit validation events to the event bus.
43
+ * @default true
44
+ */
45
+ emitEvents?: boolean;
46
+ }
47
+ /**
48
+ * Cell with validation errors.
49
+ */
50
+ export interface CellWithErrors {
51
+ row: number;
52
+ col: number;
53
+ errors: ValidationError[];
54
+ }
55
+ /**
56
+ * Validation error summary for a sheet.
57
+ */
58
+ export interface ValidationErrorSummary {
59
+ /** Total number of errors */
60
+ totalErrors: number;
61
+ /** Total number of warnings */
62
+ totalWarnings: number;
63
+ /** Number of cells with at least one error */
64
+ cellsWithErrors: number;
65
+ }
66
+ /**
67
+ * A single validation annotation from Rust recalc results.
68
+ */
69
+ export type ValidationRecalcAnnotation = ValidationRecalcAnnotationsEvent['annotations'][number];
70
+ /**
71
+ * Bridge interface for schema validation.
72
+ *
73
+ * Validation is primarily driven by Rust compute-core. The bridge listens
74
+ * for `validation:recalc-annotations` events and processes them into
75
+ * cell metadata and UI events.
76
+ */
77
+ export interface ISchemaBridge {
78
+ /**
79
+ * Start listening for validation annotation events from Rust recalc.
80
+ *
81
+ * @returns Cleanup function to stop listening
82
+ */
83
+ start(): () => void;
84
+ /**
85
+ * Stop listening for events.
86
+ */
87
+ stop(): void;
88
+ /**
89
+ * Process validation annotations from Rust mutation results.
90
+ * For each annotation: stores errors in cell metadata and emits
91
+ * validation:failed or validation:passed events.
92
+ *
93
+ * @param annotations - Validation annotations from Rust recalc
94
+ */
95
+ processValidationAnnotations(annotations: ValidationRecalcAnnotation[]): void;
96
+ /**
97
+ * Validate a single cell value against its column schema.
98
+ * Stores validation errors in cell metadata and emits events.
99
+ *
100
+ * @param sheetId - Sheet ID
101
+ * @param row - Row index
102
+ * @param col - Column index
103
+ * @param value - Cell value to validate
104
+ */
105
+ validateCell(sheetId: SheetId, row: number, col: number, value: unknown): void;
106
+ /**
107
+ * Validate all cells in a column against the column schema.
108
+ * Useful when a schema is first applied to an existing column.
109
+ *
110
+ * @param sheetId - Sheet ID
111
+ * @param colIndex - Column index
112
+ */
113
+ validateColumn(sheetId: SheetId, colIndex: number): void;
114
+ /**
115
+ * Validate all cells that have column schemas in a sheet.
116
+ * Useful after importing data or applying schemas.
117
+ *
118
+ * @param sheetId - Sheet ID
119
+ */
120
+ validateSheet(sheetId: SheetId): void;
121
+ /**
122
+ * Get all cells with validation errors in a sheet.
123
+ *
124
+ * @param sheetId - Sheet ID
125
+ * @returns Array of cells with their errors
126
+ */
127
+ getCellsWithErrors(sheetId: SheetId): CellWithErrors[] | Promise<CellWithErrors[]>;
128
+ /**
129
+ * Get validation error summary for a sheet.
130
+ *
131
+ * @param sheetId - Sheet ID
132
+ * @returns Error summary
133
+ */
134
+ getErrorSummary(sheetId: SheetId): ValidationErrorSummary | Promise<ValidationErrorSummary>;
135
+ }
136
+ export type { ColumnSchema, ISchemaRegistry, ISchemaValidator, ValidationResult, } from '../core/schema';
137
+ //# sourceMappingURL=schema-bridge.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema-bridge.d.ts","sourceRoot":"","sources":["../../src/bridges/schema-bridge.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AACxD,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,6BAA6B,CAAC;AAMpF;;GAEG;AACH,MAAM,WAAW,uBAAuB;IACtC;;;OAGG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAE3B;;;OAGG;IACH,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAE7B;;;OAGG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,eAAe,EAAE,CAAC;CAC3B;AAED;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACrC,6BAA6B;IAC7B,WAAW,EAAE,MAAM,CAAC;IACpB,+BAA+B;IAC/B,aAAa,EAAE,MAAM,CAAC;IACtB,8CAA8C;IAC9C,eAAe,EAAE,MAAM,CAAC;CACzB;AAED;;GAEG;AACH,MAAM,MAAM,0BAA0B,GAAG,gCAAgC,CAAC,aAAa,CAAC,CAAC,MAAM,CAAC,CAAC;AAMjG;;;;;;GAMG;AACH,MAAM,WAAW,aAAa;IAK5B;;;;OAIG;IACH,KAAK,IAAI,MAAM,IAAI,CAAC;IAEpB;;OAEG;IACH,IAAI,IAAI,IAAI,CAAC;IAMb;;;;;;OAMG;IACH,4BAA4B,CAAC,WAAW,EAAE,0BAA0B,EAAE,GAAG,IAAI,CAAC;IAM9E;;;;;;;;OAQG;IACH,YAAY,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,GAAG,IAAI,CAAC;IAE/E;;;;;;OAMG;IACH,cAAc,CAAC,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IAEzD;;;;;OAKG;IACH,aAAa,CAAC,OAAO,EAAE,OAAO,GAAG,IAAI,CAAC;IAMtC;;;;;OAKG;IACH,kBAAkB,CAAC,OAAO,EAAE,OAAO,GAAG,cAAc,EAAE,GAAG,OAAO,CAAC,cAAc,EAAE,CAAC,CAAC;IAEnF;;;;;OAKG;IACH,eAAe,CAAC,OAAO,EAAE,OAAO,GAAG,sBAAsB,GAAG,OAAO,CAAC,sBAAsB,CAAC,CAAC;CAC7F;AAMD,YAAY,EACV,YAAY,EACZ,eAAe,EACf,gBAAgB,EAChB,gBAAgB,GACjB,MAAM,gBAAgB,CAAC"}