@dxos/plugin-sheet 0.8.4-main.406dc2a → 0.8.4-main.52d7546f51

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 (239) hide show
  1. package/dist/lib/browser/SheetContainer-6DNFC4TY.mjs +397 -0
  2. package/dist/lib/browser/SheetContainer-6DNFC4TY.mjs.map +7 -0
  3. package/dist/lib/browser/anchor-sort-AMMLA66W.mjs +24 -0
  4. package/dist/lib/browser/anchor-sort-AMMLA66W.mjs.map +7 -0
  5. package/dist/lib/browser/chunk-EDWHV64N.mjs +1473 -0
  6. package/dist/lib/browser/chunk-EDWHV64N.mjs.map +7 -0
  7. package/dist/lib/browser/{chunk-SSN4HYJL.mjs → chunk-IFLWVS2V.mjs} +9 -9
  8. package/dist/lib/browser/chunk-IFLWVS2V.mjs.map +7 -0
  9. package/dist/lib/browser/chunk-KE3AKN5W.mjs +397 -0
  10. package/dist/lib/browser/chunk-KE3AKN5W.mjs.map +7 -0
  11. package/dist/lib/browser/compute-graph-registry-RC5L7RE4.mjs +21 -0
  12. package/dist/lib/browser/compute-graph-registry-RC5L7RE4.mjs.map +7 -0
  13. package/dist/lib/browser/index.mjs +71 -80
  14. package/dist/lib/browser/index.mjs.map +4 -4
  15. package/dist/lib/browser/markdown-D2T2DOVX.mjs +29 -0
  16. package/dist/lib/browser/markdown-D2T2DOVX.mjs.map +7 -0
  17. package/dist/lib/browser/meta.json +1 -1
  18. package/dist/lib/browser/operation-resolver-P2RX75DA.mjs +79 -0
  19. package/dist/lib/browser/operation-resolver-P2RX75DA.mjs.map +7 -0
  20. package/dist/lib/browser/{react-surface-7ZDMQDCT.mjs → react-surface-45CRAB5G.mjs} +19 -21
  21. package/dist/lib/browser/react-surface-45CRAB5G.mjs.map +7 -0
  22. package/dist/lib/browser/types/index.mjs +7 -12
  23. package/dist/lib/node-esm/SheetContainer-7H5R7M54.mjs +398 -0
  24. package/dist/lib/node-esm/SheetContainer-7H5R7M54.mjs.map +7 -0
  25. package/dist/lib/node-esm/anchor-sort-VHMBRX2E.mjs +25 -0
  26. package/dist/lib/node-esm/anchor-sort-VHMBRX2E.mjs.map +7 -0
  27. package/dist/lib/node-esm/chunk-6J5L47IB.mjs +398 -0
  28. package/dist/lib/node-esm/chunk-6J5L47IB.mjs.map +7 -0
  29. package/dist/lib/node-esm/chunk-AYSEWH7N.mjs +1474 -0
  30. package/dist/lib/node-esm/chunk-AYSEWH7N.mjs.map +7 -0
  31. package/dist/lib/node-esm/{chunk-IK4O7FUJ.mjs → chunk-PPOYR7DK.mjs} +9 -9
  32. package/dist/lib/node-esm/chunk-PPOYR7DK.mjs.map +7 -0
  33. package/dist/lib/node-esm/compute-graph-registry-ZGXVLVGD.mjs +22 -0
  34. package/dist/lib/node-esm/compute-graph-registry-ZGXVLVGD.mjs.map +7 -0
  35. package/dist/lib/node-esm/index.mjs +71 -80
  36. package/dist/lib/node-esm/index.mjs.map +4 -4
  37. package/dist/lib/node-esm/markdown-PTV72DLO.mjs +30 -0
  38. package/dist/lib/node-esm/markdown-PTV72DLO.mjs.map +7 -0
  39. package/dist/lib/node-esm/meta.json +1 -1
  40. package/dist/lib/node-esm/operation-resolver-WPIWQ5IO.mjs +80 -0
  41. package/dist/lib/node-esm/operation-resolver-WPIWQ5IO.mjs.map +7 -0
  42. package/dist/lib/node-esm/{react-surface-TUME5MM2.mjs → react-surface-ITV2L6HK.mjs} +19 -21
  43. package/dist/lib/node-esm/react-surface-ITV2L6HK.mjs.map +7 -0
  44. package/dist/lib/node-esm/types/index.mjs +7 -12
  45. package/dist/types/src/SheetPlugin.d.ts +2 -1
  46. package/dist/types/src/SheetPlugin.d.ts.map +1 -1
  47. package/dist/types/src/capabilities/anchor-sort/anchor-sort.d.ts +6 -0
  48. package/dist/types/src/capabilities/anchor-sort/anchor-sort.d.ts.map +1 -0
  49. package/dist/types/src/capabilities/anchor-sort/index.d.ts +3 -0
  50. package/dist/types/src/capabilities/anchor-sort/index.d.ts.map +1 -0
  51. package/dist/types/src/capabilities/compute-graph-registry/compute-graph-registry.d.ts +5 -0
  52. package/dist/types/src/capabilities/compute-graph-registry/compute-graph-registry.d.ts.map +1 -0
  53. package/dist/types/src/capabilities/compute-graph-registry/index.d.ts +3 -0
  54. package/dist/types/src/capabilities/compute-graph-registry/index.d.ts.map +1 -0
  55. package/dist/types/src/capabilities/index.d.ts +5 -9
  56. package/dist/types/src/capabilities/index.d.ts.map +1 -1
  57. package/dist/types/src/capabilities/markdown/index.d.ts +3 -0
  58. package/dist/types/src/capabilities/markdown/index.d.ts.map +1 -0
  59. package/dist/types/src/capabilities/markdown/markdown.d.ts +5 -0
  60. package/dist/types/src/capabilities/markdown/markdown.d.ts.map +1 -0
  61. package/dist/types/src/capabilities/operation-resolver/index.d.ts +3 -0
  62. package/dist/types/src/capabilities/operation-resolver/index.d.ts.map +1 -0
  63. package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts +5 -0
  64. package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts.map +1 -0
  65. package/dist/types/src/capabilities/react-surface/index.d.ts +3 -0
  66. package/dist/types/src/capabilities/react-surface/index.d.ts.map +1 -0
  67. package/dist/types/src/capabilities/react-surface/react-surface.d.ts +5 -0
  68. package/dist/types/src/capabilities/react-surface/react-surface.d.ts.map +1 -0
  69. package/dist/types/src/components/GridSheet/GridSheet.d.ts.map +1 -1
  70. package/dist/types/src/components/GridSheet/GridSheet.stories.d.ts +3 -2
  71. package/dist/types/src/components/GridSheet/GridSheet.stories.d.ts.map +1 -1
  72. package/dist/types/src/components/GridSheet/SheetCellEditor.stories.d.ts +1 -1
  73. package/dist/types/src/components/GridSheet/SheetCellEditor.stories.d.ts.map +1 -1
  74. package/dist/types/src/components/GridSheet/util.d.ts.map +1 -1
  75. package/dist/types/src/components/RangeList/RangeList.d.ts +2 -2
  76. package/dist/types/src/components/RangeList/RangeList.d.ts.map +1 -1
  77. package/dist/types/src/components/SheetContainer/SheetContainer.d.ts +5 -6
  78. package/dist/types/src/components/SheetContainer/SheetContainer.d.ts.map +1 -1
  79. package/dist/types/src/components/SheetContainer/SheetContainer.stories.d.ts +5 -3
  80. package/dist/types/src/components/SheetContainer/SheetContainer.stories.d.ts.map +1 -1
  81. package/dist/types/src/components/SheetContext/SheetContext.d.ts +2 -2
  82. package/dist/types/src/components/SheetContext/SheetContext.d.ts.map +1 -1
  83. package/dist/types/src/components/SheetToolbar/SheetToolbar.d.ts +3 -4
  84. package/dist/types/src/components/SheetToolbar/SheetToolbar.d.ts.map +1 -1
  85. package/dist/types/src/components/SheetToolbar/SheetToolbar.stories.d.ts +2 -0
  86. package/dist/types/src/components/SheetToolbar/SheetToolbar.stories.d.ts.map +1 -1
  87. package/dist/types/src/components/SheetToolbar/align.d.ts +12 -19
  88. package/dist/types/src/components/SheetToolbar/align.d.ts.map +1 -1
  89. package/dist/types/src/components/SheetToolbar/style.d.ts +12 -18
  90. package/dist/types/src/components/SheetToolbar/style.d.ts.map +1 -1
  91. package/dist/types/src/components/SheetToolbar/useToolbarState.d.ts +14 -1
  92. package/dist/types/src/components/SheetToolbar/useToolbarState.d.ts.map +1 -1
  93. package/dist/types/src/components/index.d.ts +1 -1
  94. package/dist/types/src/components/index.d.ts.map +1 -1
  95. package/dist/types/src/extensions/compute.stories.d.ts.map +1 -1
  96. package/dist/types/src/extensions/editor/sheet-extension.d.ts.map +1 -1
  97. package/dist/types/src/index.d.ts +1 -1
  98. package/dist/types/src/index.d.ts.map +1 -1
  99. package/dist/types/src/integrations/thread-ranges.d.ts.map +1 -1
  100. package/dist/types/src/meta.d.ts +2 -2
  101. package/dist/types/src/meta.d.ts.map +1 -1
  102. package/dist/types/src/model/sheet-model.d.ts +6 -6
  103. package/dist/types/src/model/sheet-model.d.ts.map +1 -1
  104. package/dist/types/src/model/testing.d.ts +2 -2
  105. package/dist/types/src/model/testing.d.ts.map +1 -1
  106. package/dist/types/src/model/useSheetModel.d.ts +2 -2
  107. package/dist/types/src/model/useSheetModel.d.ts.map +1 -1
  108. package/dist/types/src/serializer.d.ts +2 -2
  109. package/dist/types/src/serializer.d.ts.map +1 -1
  110. package/dist/types/src/testing/data.d.ts +2 -2
  111. package/dist/types/src/testing/data.d.ts.map +1 -1
  112. package/dist/types/src/testing/testing.d.ts +26 -2
  113. package/dist/types/src/testing/testing.d.ts.map +1 -1
  114. package/dist/types/src/translations.d.ts +3 -2
  115. package/dist/types/src/translations.d.ts.map +1 -1
  116. package/dist/types/src/types/Sheet.d.ts +76 -0
  117. package/dist/types/src/types/Sheet.d.ts.map +1 -0
  118. package/dist/types/src/types/capabilities.d.ts +6 -0
  119. package/dist/types/src/types/capabilities.d.ts.map +1 -0
  120. package/dist/types/src/types/index.d.ts +2 -1
  121. package/dist/types/src/types/index.d.ts.map +1 -1
  122. package/dist/types/src/types/sheet-range-types.d.ts +2 -2
  123. package/dist/types/src/types/sheet-range-types.d.ts.map +1 -1
  124. package/dist/types/src/types/types.d.ts +91 -74
  125. package/dist/types/src/types/types.d.ts.map +1 -1
  126. package/dist/types/src/types/util.d.ts +10 -10
  127. package/dist/types/src/types/util.d.ts.map +1 -1
  128. package/dist/types/tsconfig.tsbuildinfo +1 -1
  129. package/package.json +76 -68
  130. package/src/SheetPlugin.tsx +41 -61
  131. package/src/capabilities/anchor-sort/anchor-sort.ts +27 -0
  132. package/src/capabilities/anchor-sort/index.ts +7 -0
  133. package/src/capabilities/compute-graph-registry/compute-graph-registry.ts +27 -0
  134. package/src/capabilities/compute-graph-registry/index.ts +7 -0
  135. package/src/capabilities/index.ts +5 -9
  136. package/src/capabilities/markdown/index.ts +7 -0
  137. package/src/capabilities/markdown/markdown.ts +30 -0
  138. package/src/capabilities/operation-resolver/index.ts +7 -0
  139. package/src/capabilities/operation-resolver/operation-resolver.ts +77 -0
  140. package/src/capabilities/react-surface/index.ts +7 -0
  141. package/src/capabilities/react-surface/react-surface.tsx +43 -0
  142. package/src/components/ComputeGraph/compute-graph.stories.tsx +9 -9
  143. package/src/components/FunctionEditor/FunctionEditor.tsx +2 -2
  144. package/src/components/GridSheet/GridSheet.stories.tsx +5 -5
  145. package/src/components/GridSheet/GridSheet.tsx +40 -30
  146. package/src/components/GridSheet/SheetCellEditor.stories.tsx +12 -9
  147. package/src/components/GridSheet/util.ts +11 -5
  148. package/src/components/RangeList/RangeList.tsx +10 -7
  149. package/src/components/SheetContainer/SheetContainer.stories.tsx +46 -23
  150. package/src/components/SheetContainer/SheetContainer.tsx +30 -22
  151. package/src/components/SheetContext/SheetContext.tsx +8 -8
  152. package/src/components/SheetToolbar/SheetToolbar.stories.tsx +1 -1
  153. package/src/components/SheetToolbar/SheetToolbar.tsx +39 -30
  154. package/src/components/SheetToolbar/align.ts +41 -16
  155. package/src/components/SheetToolbar/style.ts +45 -15
  156. package/src/components/SheetToolbar/useToolbarState.ts +22 -5
  157. package/src/extensions/compute.stories.tsx +19 -10
  158. package/src/extensions/compute.ts +1 -1
  159. package/src/extensions/editor/sheet-extension.ts +7 -4
  160. package/src/index.ts +1 -1
  161. package/src/integrations/thread-ranges.ts +39 -49
  162. package/src/meta.ts +8 -4
  163. package/src/model/sheet-model.test.ts +4 -4
  164. package/src/model/sheet-model.ts +80 -48
  165. package/src/model/testing.ts +4 -4
  166. package/src/model/useSheetModel.ts +2 -2
  167. package/src/playwright/playwright.config.ts +1 -1
  168. package/src/playwright/sheet.spec.ts +1 -0
  169. package/src/sanity.test.ts +3 -4
  170. package/src/serializer.ts +4 -4
  171. package/src/testing/data.ts +2 -2
  172. package/src/testing/testing.tsx +3 -3
  173. package/src/translations.ts +3 -2
  174. package/src/types/Sheet.ts +97 -0
  175. package/src/{capabilities → types}/capabilities.ts +2 -2
  176. package/src/types/index.ts +2 -1
  177. package/src/types/sheet-range-types.ts +2 -2
  178. package/src/types/types.ts +82 -48
  179. package/src/types/util.ts +11 -38
  180. package/dist/lib/browser/SheetContainer-VL34UND4.mjs +0 -351
  181. package/dist/lib/browser/SheetContainer-VL34UND4.mjs.map +0 -7
  182. package/dist/lib/browser/anchor-sort-3N44DS5F.mjs +0 -24
  183. package/dist/lib/browser/anchor-sort-3N44DS5F.mjs.map +0 -7
  184. package/dist/lib/browser/chunk-ADK2HW4A.mjs +0 -906
  185. package/dist/lib/browser/chunk-ADK2HW4A.mjs.map +0 -7
  186. package/dist/lib/browser/chunk-CSBSADPQ.mjs +0 -16
  187. package/dist/lib/browser/chunk-CSBSADPQ.mjs.map +0 -7
  188. package/dist/lib/browser/chunk-SSN4HYJL.mjs.map +0 -7
  189. package/dist/lib/browser/chunk-ZJWJMX4E.mjs +0 -852
  190. package/dist/lib/browser/chunk-ZJWJMX4E.mjs.map +0 -7
  191. package/dist/lib/browser/chunk-ZMPNHFIP.mjs +0 -15
  192. package/dist/lib/browser/chunk-ZMPNHFIP.mjs.map +0 -7
  193. package/dist/lib/browser/compute-graph-registry-MF65HGGM.mjs +0 -21
  194. package/dist/lib/browser/compute-graph-registry-MF65HGGM.mjs.map +0 -7
  195. package/dist/lib/browser/intent-resolver-BQLV6IAA.mjs +0 -56
  196. package/dist/lib/browser/intent-resolver-BQLV6IAA.mjs.map +0 -7
  197. package/dist/lib/browser/markdown-RMTMI237.mjs +0 -26
  198. package/dist/lib/browser/markdown-RMTMI237.mjs.map +0 -7
  199. package/dist/lib/browser/react-surface-7ZDMQDCT.mjs.map +0 -7
  200. package/dist/lib/node-esm/SheetContainer-NWJ7L6FC.mjs +0 -352
  201. package/dist/lib/node-esm/SheetContainer-NWJ7L6FC.mjs.map +0 -7
  202. package/dist/lib/node-esm/anchor-sort-YL2OZHYM.mjs +0 -25
  203. package/dist/lib/node-esm/anchor-sort-YL2OZHYM.mjs.map +0 -7
  204. package/dist/lib/node-esm/chunk-BZAPYBSH.mjs +0 -907
  205. package/dist/lib/node-esm/chunk-BZAPYBSH.mjs.map +0 -7
  206. package/dist/lib/node-esm/chunk-H3GSD33H.mjs +0 -18
  207. package/dist/lib/node-esm/chunk-H3GSD33H.mjs.map +0 -7
  208. package/dist/lib/node-esm/chunk-IK4O7FUJ.mjs.map +0 -7
  209. package/dist/lib/node-esm/chunk-LN6ZSAII.mjs +0 -16
  210. package/dist/lib/node-esm/chunk-LN6ZSAII.mjs.map +0 -7
  211. package/dist/lib/node-esm/chunk-YL7BVJPC.mjs +0 -853
  212. package/dist/lib/node-esm/chunk-YL7BVJPC.mjs.map +0 -7
  213. package/dist/lib/node-esm/compute-graph-registry-P2O5LDFZ.mjs +0 -22
  214. package/dist/lib/node-esm/compute-graph-registry-P2O5LDFZ.mjs.map +0 -7
  215. package/dist/lib/node-esm/intent-resolver-MV5ZFXAQ.mjs +0 -57
  216. package/dist/lib/node-esm/intent-resolver-MV5ZFXAQ.mjs.map +0 -7
  217. package/dist/lib/node-esm/markdown-EDIWHA3P.mjs +0 -27
  218. package/dist/lib/node-esm/markdown-EDIWHA3P.mjs.map +0 -7
  219. package/dist/lib/node-esm/react-surface-TUME5MM2.mjs.map +0 -7
  220. package/dist/types/src/capabilities/anchor-sort.d.ts +0 -6
  221. package/dist/types/src/capabilities/anchor-sort.d.ts.map +0 -1
  222. package/dist/types/src/capabilities/capabilities.d.ts +0 -5
  223. package/dist/types/src/capabilities/capabilities.d.ts.map +0 -1
  224. package/dist/types/src/capabilities/compute-graph-registry.d.ts +0 -4
  225. package/dist/types/src/capabilities/compute-graph-registry.d.ts.map +0 -1
  226. package/dist/types/src/capabilities/intent-resolver.d.ts +0 -4
  227. package/dist/types/src/capabilities/intent-resolver.d.ts.map +0 -1
  228. package/dist/types/src/capabilities/markdown.d.ts +0 -4
  229. package/dist/types/src/capabilities/markdown.d.ts.map +0 -1
  230. package/dist/types/src/capabilities/react-surface.d.ts +0 -4
  231. package/dist/types/src/capabilities/react-surface.d.ts.map +0 -1
  232. package/dist/types/src/types/schema.d.ts +0 -37
  233. package/dist/types/src/types/schema.d.ts.map +0 -1
  234. package/src/capabilities/anchor-sort.ts +0 -22
  235. package/src/capabilities/compute-graph-registry.ts +0 -23
  236. package/src/capabilities/intent-resolver.ts +0 -38
  237. package/src/capabilities/markdown.ts +0 -23
  238. package/src/capabilities/react-surface.tsx +0 -40
  239. package/src/types/schema.ts +0 -61
@@ -1,906 +0,0 @@
1
- import {
2
- meta
3
- } from "./chunk-CSBSADPQ.mjs";
4
-
5
- // src/types/schema.ts
6
- import * as Schema from "effect/Schema";
7
- import { Type } from "@dxos/echo";
8
- var CellValue = Schema.Struct({
9
- // TODO(burdon): How to store dates (datetime, date, time), percentages, etc.
10
- // Consider import/export; natural access for other plugins. Special handling for currency (precision).
11
- // TODO(burdon): Automerge (long string) or short string or number.
12
- value: Schema.Any
13
- });
14
- var Range = Schema.Struct({
15
- range: Schema.String,
16
- key: Schema.String,
17
- value: Schema.String
18
- });
19
- var RowColumnMeta = Schema.Struct({
20
- size: Schema.optional(Schema.Number)
21
- });
22
- var SheetType = Schema.Struct({
23
- name: Schema.optional(Schema.String),
24
- // Sparse map of cells referenced by index.
25
- cells: Schema.mutable(Schema.Record({
26
- key: Schema.String,
27
- value: Schema.mutable(CellValue)
28
- })),
29
- // Ordered row indices.
30
- rows: Schema.mutable(Schema.Array(Schema.String)),
31
- // Ordered column indices.
32
- columns: Schema.mutable(Schema.Array(Schema.String)),
33
- // Row metadata referenced by index.
34
- rowMeta: Schema.mutable(Schema.Record({
35
- key: Schema.String,
36
- value: Schema.mutable(RowColumnMeta)
37
- })),
38
- // Column metadata referenced by index.
39
- columnMeta: Schema.mutable(Schema.Record({
40
- key: Schema.String,
41
- value: Schema.mutable(RowColumnMeta)
42
- })),
43
- // Cell formatting referenced by indexed range.
44
- ranges: Schema.mutable(Schema.Array(Range))
45
- }).pipe(Type.Obj({
46
- typename: "dxos.org/type/Sheet",
47
- version: "0.1.0"
48
- }));
49
-
50
- // src/types/sheet-range-types.ts
51
- var alignKey = "alignment";
52
- var commentKey = "comment";
53
- var styleKey = "style";
54
- var cellClassNameForRange = ({ key, value }) => {
55
- switch (key) {
56
- case alignKey:
57
- switch (value) {
58
- case "start":
59
- return "text-start";
60
- case "center":
61
- return "text-center";
62
- case "end":
63
- return "text-end";
64
- default:
65
- return void 0;
66
- }
67
- case commentKey:
68
- return "bg-gridComment";
69
- case styleKey:
70
- switch (value) {
71
- case "highlight":
72
- return "!bg-gridHighlight";
73
- case "softwrap":
74
- return "!whitespace-normal";
75
- default:
76
- return void 0;
77
- }
78
- default:
79
- return void 0;
80
- }
81
- };
82
-
83
- // src/types/types.ts
84
- import * as Schema2 from "effect/Schema";
85
-
86
- // src/model/sheet-model.ts
87
- import { Event } from "@dxos/async";
88
- import { DetailedCellError, ExportedCellChange, addressFromA1Notation, addressToA1Notation, createSheetName, isFormula } from "@dxos/compute";
89
- import { Resource } from "@dxos/context";
90
- import { Obj } from "@dxos/echo";
91
- import { FormatEnum, TypeEnum } from "@dxos/echo/internal";
92
- import { invariant } from "@dxos/invariant";
93
- import { PublicKey } from "@dxos/keys";
94
- import { log } from "@dxos/log";
95
- function _define_property(obj, key, value) {
96
- if (key in obj) {
97
- Object.defineProperty(obj, key, {
98
- value,
99
- enumerable: true,
100
- configurable: true,
101
- writable: true
102
- });
103
- } else {
104
- obj[key] = value;
105
- }
106
- return obj;
107
- }
108
- var __dxlog_file = "/__w/dxos/dxos/packages/plugins/plugin-sheet/src/model/sheet-model.ts";
109
- var typeMap = {
110
- BOOLEAN: {
111
- type: TypeEnum.Boolean
112
- },
113
- NUMBER_RAW: {
114
- type: TypeEnum.Number
115
- },
116
- NUMBER_PERCENT: {
117
- type: TypeEnum.Number,
118
- format: FormatEnum.Percent
119
- },
120
- NUMBER_CURRENCY: {
121
- type: TypeEnum.Number,
122
- format: FormatEnum.Currency
123
- },
124
- NUMBER_DATETIME: {
125
- type: TypeEnum.String,
126
- format: FormatEnum.DateTime
127
- },
128
- NUMBER_DATE: {
129
- type: TypeEnum.String,
130
- format: FormatEnum.Date
131
- },
132
- NUMBER_TIME: {
133
- type: TypeEnum.String,
134
- format: FormatEnum.Time
135
- }
136
- };
137
- var getTopLeft = (range) => {
138
- const to = range.to ?? range.from;
139
- return {
140
- row: Math.min(range.from.row, to.row),
141
- col: Math.min(range.from.col, to.col)
142
- };
143
- };
144
- var toSimpleCellAddress = (sheet, cell) => ({
145
- sheet,
146
- row: cell.row,
147
- col: cell.col
148
- });
149
- var toModelRange = (sheet, range) => ({
150
- start: toSimpleCellAddress(sheet, range.from),
151
- end: toSimpleCellAddress(sheet, range.to ?? range.from)
152
- });
153
- var SheetModel = class extends Resource {
154
- get graph() {
155
- return this._graph;
156
- }
157
- get sheet() {
158
- return this._sheet;
159
- }
160
- get readonly() {
161
- return this._options.readonly;
162
- }
163
- get bounds() {
164
- return {
165
- rows: this._sheet.rows.length,
166
- columns: this._sheet.columns.length
167
- };
168
- }
169
- /**
170
- * Initialize sheet and engine.
171
- */
172
- async _open() {
173
- log("initialize", {
174
- id: this.id
175
- }, {
176
- F: __dxlog_file,
177
- L: 124,
178
- S: this,
179
- C: (f, a) => f(...a)
180
- });
181
- initialize(this._sheet);
182
- this._graph.update.on((event) => {
183
- if (event.type === "functionsUpdated") {
184
- this.reset();
185
- }
186
- });
187
- this._node = this._graph.getOrCreateNode(createSheetName({
188
- type: Obj.getTypename(this._sheet),
189
- id: this._sheet.id
190
- }));
191
- await this._node.open();
192
- const unsubscribe = this._node.update.on((event) => this.update.emit(event));
193
- this._ctx.onDispose(unsubscribe);
194
- this.reset();
195
- }
196
- /**
197
- * Update engine.
198
- * NOTE: This resets the undo history.
199
- * @deprecated
200
- */
201
- reset() {
202
- invariant(this._node, void 0, {
203
- F: __dxlog_file,
204
- L: 152,
205
- S: this,
206
- A: [
207
- "this._node",
208
- ""
209
- ]
210
- });
211
- this._node.graph.hf.clearSheet(this._node.sheetId);
212
- Object.entries(this._sheet.cells).forEach(([key, { value }]) => {
213
- invariant(this._node, void 0, {
214
- F: __dxlog_file,
215
- L: 155,
216
- S: this,
217
- A: [
218
- "this._node",
219
- ""
220
- ]
221
- });
222
- const { col, row } = addressFromIndex(this._sheet, key);
223
- if (isFormula(value)) {
224
- const binding = this._graph.mapFunctionBindingFromId(mapFormulaIndicesToRefs(this._sheet, value));
225
- if (binding) {
226
- value = this._graph.mapFormulaToNative(binding);
227
- } else {
228
- value = "";
229
- }
230
- }
231
- this._node.graph.hf.setCellContents({
232
- sheet: this._node.sheetId,
233
- row,
234
- col
235
- }, value);
236
- });
237
- }
238
- /**
239
- * Recalculate formulas.
240
- * NOTE: This resets the undo history.
241
- * https://hyperformula.handsontable.com/guide/volatile-functions.html#volatile-actions
242
- * @deprecated
243
- */
244
- // TODO(burdon): Remove.
245
- recalculate() {
246
- this._node?.graph.hf.rebuildAndRecalculate();
247
- }
248
- insertRows(i, n = 1) {
249
- const idx = insertIndices(this._sheet.rows, i, n, MAX_ROWS);
250
- this.reset();
251
- return idx;
252
- }
253
- insertColumns(i, n = 1) {
254
- const idx = insertIndices(this._sheet.columns, i, n, MAX_COLS);
255
- this.reset();
256
- return idx;
257
- }
258
- dropRow(rowIndex) {
259
- const range = {
260
- from: addressFromIndex(this._sheet, `${this._sheet.columns[0]}@${rowIndex}`),
261
- to: addressFromIndex(this._sheet, `${this._sheet.columns[this._sheet.columns.length - 1]}@${rowIndex}`)
262
- };
263
- const values = this.getCellValues(range).flat();
264
- const index = this._sheet.rows.indexOf(rowIndex);
265
- this.clear(range);
266
- this._sheet.rows.splice(index, 1);
267
- delete this._sheet.rowMeta[rowIndex];
268
- this.reset();
269
- return {
270
- axis: "row",
271
- index,
272
- axisIndex: rowIndex,
273
- axisMeta: this._sheet.rowMeta[rowIndex],
274
- values
275
- };
276
- }
277
- dropColumn(colIndex) {
278
- const range = {
279
- from: addressFromIndex(this._sheet, `${colIndex}@${this._sheet.rows[0]}`),
280
- to: addressFromIndex(this._sheet, `${colIndex}@${this._sheet.rows[this._sheet.rows.length - 1]}`)
281
- };
282
- const values = this.getCellValues(range).flat();
283
- const index = this._sheet.columns.indexOf(colIndex);
284
- this.clear(range);
285
- this._sheet.columns.splice(index, 1);
286
- delete this._sheet.columnMeta[colIndex];
287
- this.reset();
288
- return {
289
- axis: "col",
290
- index,
291
- axisIndex: colIndex,
292
- axisMeta: this._sheet.rowMeta[colIndex],
293
- values
294
- };
295
- }
296
- restoreRow({ index, axisIndex, axisMeta, values }) {
297
- this._sheet.rows.splice(index, 0, axisIndex);
298
- values.forEach((value, col) => {
299
- if (value) {
300
- this._sheet.cells[`${this._sheet.columns[col]}@${axisIndex}`] = {
301
- value
302
- };
303
- }
304
- });
305
- if (axisMeta) {
306
- this._sheet.rowMeta[axisIndex] = axisMeta;
307
- }
308
- this.reset();
309
- }
310
- restoreColumn({ index, axisIndex, axisMeta, values }) {
311
- this._sheet.columns.splice(index, 0, axisIndex);
312
- values.forEach((value, row) => {
313
- if (value) {
314
- this._sheet.cells[`${axisIndex}@${this._sheet.rows[row]}`] = {
315
- value
316
- };
317
- }
318
- });
319
- if (axisMeta) {
320
- this._sheet.columnMeta[axisIndex] = axisMeta;
321
- }
322
- this.reset();
323
- }
324
- //
325
- // Undoable actions.
326
- // TODO(burdon): Group undoable methods; consistently update hf/sheet.
327
- //
328
- /**
329
- * Clear range of values.
330
- */
331
- clear(range) {
332
- invariant(this._node, void 0, {
333
- F: __dxlog_file,
334
- L: 258,
335
- S: this,
336
- A: [
337
- "this._node",
338
- ""
339
- ]
340
- });
341
- const topLeft = getTopLeft(range);
342
- const values = this._iterRange(range, () => null);
343
- this._node.graph.hf.setCellContents(toSimpleCellAddress(this._node.sheetId, topLeft), values);
344
- this._iterRange(range, (cell) => {
345
- const idx = addressToIndex(this._sheet, cell);
346
- delete this._sheet.cells[idx];
347
- });
348
- }
349
- cut(range) {
350
- invariant(this._node, void 0, {
351
- F: __dxlog_file,
352
- L: 269,
353
- S: this,
354
- A: [
355
- "this._node",
356
- ""
357
- ]
358
- });
359
- this._node.graph.hf.cut(toModelRange(this._node.sheetId, range));
360
- this._iterRange(range, (cell) => {
361
- const idx = addressToIndex(this._sheet, cell);
362
- delete this._sheet.cells[idx];
363
- });
364
- }
365
- copy(range) {
366
- invariant(this._node, void 0, {
367
- F: __dxlog_file,
368
- L: 278,
369
- S: this,
370
- A: [
371
- "this._node",
372
- ""
373
- ]
374
- });
375
- this._node.graph.hf.copy(toModelRange(this._node.sheetId, range));
376
- }
377
- paste(cell) {
378
- invariant(this._node, void 0, {
379
- F: __dxlog_file,
380
- L: 283,
381
- S: this,
382
- A: [
383
- "this._node",
384
- ""
385
- ]
386
- });
387
- if (!this._node.graph.hf.isClipboardEmpty()) {
388
- const changes = this._node.graph.hf.paste(toSimpleCellAddress(this._node.sheetId, cell));
389
- for (const change of changes) {
390
- if (change instanceof ExportedCellChange) {
391
- const { address, newValue } = change;
392
- const idx = addressToIndex(this._sheet, {
393
- row: address.row,
394
- col: address.col
395
- });
396
- this._sheet.cells[idx] = {
397
- value: newValue
398
- };
399
- }
400
- }
401
- }
402
- }
403
- // TODO(burdon): Display undo/redo state.
404
- undo() {
405
- invariant(this._node, void 0, {
406
- F: __dxlog_file,
407
- L: 298,
408
- S: this,
409
- A: [
410
- "this._node",
411
- ""
412
- ]
413
- });
414
- if (this._node.graph.hf.isThereSomethingToUndo()) {
415
- this._node.graph.hf.undo();
416
- }
417
- }
418
- redo() {
419
- invariant(this._node, void 0, {
420
- F: __dxlog_file,
421
- L: 306,
422
- S: this,
423
- A: [
424
- "this._node",
425
- ""
426
- ]
427
- });
428
- if (this._node.graph.hf.isThereSomethingToRedo()) {
429
- this._node.graph.hf.redo();
430
- }
431
- }
432
- /**
433
- * Get value from sheet.
434
- */
435
- getCellValue(cell) {
436
- const idx = addressToIndex(this._sheet, cell);
437
- return this._sheet.cells[idx]?.value ?? null;
438
- }
439
- /**
440
- * Get value as a string for editing.
441
- */
442
- getCellText(cell) {
443
- const value = this.getCellValue(cell);
444
- if (value == null) {
445
- return void 0;
446
- }
447
- if (isFormula(value)) {
448
- return this._graph.mapFunctionBindingFromId(mapFormulaIndicesToRefs(this._sheet, value));
449
- } else {
450
- return String(value);
451
- }
452
- }
453
- /**
454
- * Get array of raw values from sheet.
455
- */
456
- getCellValues(range) {
457
- return this._iterRange(range, (cell) => this.getCellValue(cell));
458
- }
459
- /**
460
- * Gets the regular or computed value from the engine.
461
- */
462
- getValue(cell) {
463
- invariant(this._node, void 0, {
464
- F: __dxlog_file,
465
- L: 349,
466
- S: this,
467
- A: [
468
- "this._node",
469
- ""
470
- ]
471
- });
472
- const address = toSimpleCellAddress(this._node.sheetId, cell);
473
- const value = this._node.graph.hf.getCellValue(address);
474
- if (value instanceof DetailedCellError) {
475
- log.warn("cell error", {
476
- cell,
477
- error: value
478
- }, {
479
- F: __dxlog_file,
480
- L: 354,
481
- S: this,
482
- C: (f, a) => f(...a)
483
- });
484
- return value.toString();
485
- }
486
- return value;
487
- }
488
- /**
489
- * Get value type.
490
- */
491
- getValueDescription(cell) {
492
- invariant(this._node, void 0, {
493
- F: __dxlog_file,
494
- L: 365,
495
- S: this,
496
- A: [
497
- "this._node",
498
- ""
499
- ]
500
- });
501
- const addr = toSimpleCellAddress(this._node.sheetId, cell);
502
- const type = this._node.graph.hf.getCellValueDetailedType(addr);
503
- return typeMap[type];
504
- }
505
- /**
506
- * Sets the value, updating the sheet and engine.
507
- */
508
- setValue(cell, value) {
509
- invariant(this._node, void 0, {
510
- F: __dxlog_file,
511
- L: 375,
512
- S: this,
513
- A: [
514
- "this._node",
515
- ""
516
- ]
517
- });
518
- if (this._options.readonly) {
519
- throw new ReadonlyException();
520
- }
521
- let refresh = false;
522
- if (cell.row >= this._sheet.rows.length) {
523
- insertIndices(this._sheet.rows, cell.row, 1, MAX_ROWS);
524
- refresh = true;
525
- }
526
- if (cell.col >= this._sheet.columns.length) {
527
- insertIndices(this._sheet.columns, cell.col, 1, MAX_COLS);
528
- refresh = true;
529
- }
530
- if (refresh) {
531
- this.reset();
532
- }
533
- this._node.graph.hf.setCellContents({
534
- sheet: this._node.sheetId,
535
- row: cell.row,
536
- col: cell.col
537
- }, [
538
- [
539
- isFormula(value) ? this._graph.mapFormulaToNative(value) : value
540
- ]
541
- ]);
542
- const idx = addressToIndex(this._sheet, cell);
543
- if (value === void 0 || value === null) {
544
- delete this._sheet.cells[idx];
545
- } else {
546
- if (isFormula(value)) {
547
- value = this._graph.mapFunctionBindingToId(mapFormulaRefsToIndices(this._sheet, value));
548
- }
549
- this._sheet.cells[idx] = {
550
- value
551
- };
552
- }
553
- }
554
- /**
555
- * Sets values from a simple map.
556
- */
557
- setValues(values) {
558
- Object.entries(values).forEach(([key, { value }]) => {
559
- this.setValue(addressFromA1Notation(key), value);
560
- });
561
- }
562
- /**
563
- * Iterate range.
564
- */
565
- _iterRange(range, cb) {
566
- const to = range.to ?? range.from;
567
- const rowRange = [
568
- Math.min(range.from.row, to.row),
569
- Math.max(range.from.row, to.row)
570
- ];
571
- const columnRange = [
572
- Math.min(range.from.col, to.col),
573
- Math.max(range.from.col, to.col)
574
- ];
575
- const rows = [];
576
- for (let row = rowRange[0]; row <= rowRange[1]; row++) {
577
- const rowCells = [];
578
- for (let column = columnRange[0]; column <= columnRange[1]; column++) {
579
- const value = cb({
580
- row,
581
- col: column
582
- });
583
- if (value !== void 0) {
584
- rowCells.push(value);
585
- }
586
- }
587
- rows.push(rowCells);
588
- }
589
- return rows;
590
- }
591
- // TODO(burdon): Delete index.
592
- _deleteIndices(indices, i, n) {
593
- throw new Error("Not implemented");
594
- }
595
- // TODO(burdon): Move. Cannot use fractional without changing. Switch back to using unique IDs?
596
- _moveIndices(indices, i, j, n) {
597
- throw new Error("Not implemented");
598
- }
599
- /**
600
- * Map from indices to A1 notation.
601
- */
602
- mapFormulaIndicesToRefs(formula) {
603
- invariant(isFormula(formula), void 0, {
604
- F: __dxlog_file,
605
- L: 460,
606
- S: this,
607
- A: [
608
- "isFormula(formula)",
609
- ""
610
- ]
611
- });
612
- return formula.replace(/([a-zA-Z0-9]+)@([a-zA-Z0-9]+)/g, (idx) => {
613
- return addressToA1Notation(addressFromIndex(this._sheet, idx));
614
- });
615
- }
616
- //
617
- // Values
618
- //
619
- /**
620
- * https://hyperformula.handsontable.com/guide/date-and-time-handling.html#example
621
- * https://hyperformula.handsontable.com/api/interfaces/configparams.html#nulldate
622
- * NOTE: TODAY() is number of FULL days since nullDate. It will typically be -1 days from NOW().
623
- */
624
- toLocalDate(num) {
625
- const { year, month, day, hours, minutes, seconds } = this.toDateTime(num);
626
- return new Date(year, month - 1, day, hours, minutes, seconds);
627
- }
628
- toDateTime(num) {
629
- invariant(this._node, void 0, {
630
- F: __dxlog_file,
631
- L: 481,
632
- S: this,
633
- A: [
634
- "this._node",
635
- ""
636
- ]
637
- });
638
- return this._node.graph.hf.numberToDateTime(num);
639
- }
640
- toDate(num) {
641
- invariant(this._node, void 0, {
642
- F: __dxlog_file,
643
- L: 486,
644
- S: this,
645
- A: [
646
- "this._node",
647
- ""
648
- ]
649
- });
650
- return this._node.graph.hf.numberToDate(num);
651
- }
652
- toTime(num) {
653
- invariant(this._node, void 0, {
654
- F: __dxlog_file,
655
- L: 491,
656
- S: this,
657
- A: [
658
- "this._node",
659
- ""
660
- ]
661
- });
662
- return this._node.graph.hf.numberToTime(num);
663
- }
664
- constructor(_graph, _sheet, _options = {}) {
665
- super(), _define_property(this, "_graph", void 0), _define_property(this, "_sheet", void 0), _define_property(this, "_options", void 0), _define_property(this, "id", void 0), // Wraps compute node.
666
- _define_property(this, "update", void 0), _define_property(this, "_node", void 0), this._graph = _graph, this._sheet = _sheet, this._options = _options, this.id = `model-${PublicKey.random().truncate()}`, this.update = new Event();
667
- }
668
- };
669
-
670
- // src/model/useSheetModel.ts
671
- import { useEffect, useState } from "react";
672
- var useSheetModel = (graph, sheet, { readonly } = {}) => {
673
- const [model, setModel] = useState();
674
- useEffect(() => {
675
- if (!graph || !sheet) {
676
- return;
677
- }
678
- let model2;
679
- const t = setTimeout(async () => {
680
- model2 = new SheetModel(graph, sheet, {
681
- readonly
682
- });
683
- await model2.open();
684
- setModel(model2);
685
- });
686
- return () => {
687
- clearTimeout(t);
688
- void model2?.close();
689
- };
690
- }, [
691
- graph,
692
- sheet,
693
- readonly
694
- ]);
695
- return model;
696
- };
697
-
698
- // src/types/types.ts
699
- (function(SheetAction2) {
700
- const SHEET_ACTION = `${meta.id}/action`;
701
- class Create extends Schema2.TaggedClass()(`${SHEET_ACTION}/create`, {
702
- input: Schema2.Struct({
703
- name: Schema2.optional(Schema2.String)
704
- }),
705
- output: Schema2.Struct({
706
- object: SheetType
707
- })
708
- }) {
709
- }
710
- SheetAction2.Create = Create;
711
- const Axis = Schema2.Union(Schema2.Literal("row"), Schema2.Literal("col"));
712
- class InsertAxis extends Schema2.TaggedClass()(`${SHEET_ACTION}/axis-insert`, {
713
- input: Schema2.Struct({
714
- // TODO(wittjosiah): Schema.instanceOf(SheetModel) throws when running tests.
715
- model: Schema2.Any.pipe(Schema2.filter((model) => model instanceof SheetModel)),
716
- axis: Axis,
717
- index: Schema2.Number,
718
- count: Schema2.optional(Schema2.Number)
719
- }),
720
- output: Schema2.Void
721
- }) {
722
- }
723
- SheetAction2.InsertAxis = InsertAxis;
724
- SheetAction2.RestoreAxis = Schema2.Struct({
725
- axis: Axis,
726
- axisIndex: Schema2.String,
727
- index: Schema2.Number,
728
- axisMeta: RowColumnMeta,
729
- values: Schema2.Array(Schema2.Any)
730
- });
731
- class DropAxis extends Schema2.TaggedClass()(`${SHEET_ACTION}/axis-drop`, {
732
- input: Schema2.Struct({
733
- // TODO(wittjosiah): Schema.instanceOf(SheetModel) throws when running tests.
734
- model: Schema2.Any.pipe(Schema2.filter((model) => model instanceof SheetModel)),
735
- axis: Axis,
736
- axisIndex: Schema2.String,
737
- deletionData: Schema2.optional(SheetAction2.RestoreAxis)
738
- }),
739
- output: Schema2.Void
740
- }) {
741
- }
742
- SheetAction2.DropAxis = DropAxis;
743
- })(SheetAction || (SheetAction = {}));
744
- var SheetAction;
745
-
746
- // src/types/util.ts
747
- import { addressFromA1Notation as addressFromA1Notation2, addressToA1Notation as addressToA1Notation2, isFormula as isFormula2 } from "@dxos/compute";
748
- import { randomBytes } from "@dxos/crypto";
749
- import { Obj as Obj2 } from "@dxos/echo";
750
- import { invariant as invariant2 } from "@dxos/invariant";
751
- var __dxlog_file2 = "/__w/dxos/dxos/packages/plugins/plugin-sheet/src/types/util.ts";
752
- var MAX_ROWS = 500;
753
- var MAX_COLS = 676;
754
- var DEFAULT_ROWS = 50;
755
- var DEFAULT_COLS = 26;
756
- var ApiError = class extends Error {
757
- };
758
- var ReadonlyException = class extends ApiError {
759
- };
760
- var RangeException = class extends ApiError {
761
- constructor(n) {
762
- super();
763
- }
764
- };
765
- var createIndex = (length = 8) => {
766
- const characters = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
767
- const charactersLength = characters.length;
768
- const randomBuffer = randomBytes(length);
769
- return Array.from(randomBuffer, (byte) => characters[byte % charactersLength]).join("");
770
- };
771
- var createIndices = (length) => Array.from({
772
- length
773
- }).map(() => createIndex());
774
- var insertIndices = (indices, i, n, max) => {
775
- if (i + n > max) {
776
- throw new RangeException(i + n);
777
- }
778
- const idx = createIndices(n);
779
- indices.splice(i, 0, ...idx);
780
- return idx;
781
- };
782
- var initialize = (sheet, { rows = DEFAULT_ROWS, columns = DEFAULT_COLS } = {}) => {
783
- if (!sheet.rows.length) {
784
- insertIndices(sheet.rows, 0, rows, MAX_ROWS);
785
- }
786
- if (!sheet.columns.length) {
787
- insertIndices(sheet.columns, 0, columns, MAX_COLS);
788
- }
789
- };
790
- var createSheet = ({ name, cells, ...size } = {}) => {
791
- const sheet = Obj2.make(SheetType, {
792
- name,
793
- cells: {},
794
- rows: [],
795
- columns: [],
796
- rowMeta: {},
797
- columnMeta: {},
798
- ranges: []
799
- });
800
- initialize(sheet, size);
801
- if (cells) {
802
- Object.entries(cells).forEach(([key, { value }]) => {
803
- const idx = addressToIndex(sheet, addressFromA1Notation2(key));
804
- if (isFormula2(value)) {
805
- value = mapFormulaRefsToIndices(sheet, value);
806
- }
807
- sheet.cells[idx] = {
808
- value
809
- };
810
- });
811
- }
812
- return sheet;
813
- };
814
- var addressToIndex = (sheet, cell) => {
815
- return `${sheet.columns[cell.col]}@${sheet.rows[cell.row]}`;
816
- };
817
- var addressFromIndex = (sheet, idx) => {
818
- const [column, row] = idx.split("@");
819
- return {
820
- col: sheet.columns.indexOf(column),
821
- row: sheet.rows.indexOf(row)
822
- };
823
- };
824
- var rangeToIndex = (sheet, range) => {
825
- return [
826
- range.from,
827
- range.to ?? range.from
828
- ].map((cell) => addressToIndex(sheet, cell)).join(":");
829
- };
830
- var rangeFromIndex = (sheet, idx) => {
831
- const [from, to] = idx.split(":").map((index) => addressFromIndex(sheet, index));
832
- return {
833
- from,
834
- to
835
- };
836
- };
837
- var compareIndexPositions = (sheet, indexA, indexB) => {
838
- const { row: rowA, col: columnA } = addressFromIndex(sheet, indexA);
839
- const { row: rowB, col: columnB } = addressFromIndex(sheet, indexB);
840
- if (rowA !== rowB) {
841
- return rowA - rowB;
842
- } else {
843
- return columnA - columnB;
844
- }
845
- };
846
- var mapFormulaRefsToIndices = (sheet, formula) => {
847
- invariant2(isFormula2(formula), void 0, {
848
- F: __dxlog_file2,
849
- L: 152,
850
- S: void 0,
851
- A: [
852
- "isFormula(formula)",
853
- ""
854
- ]
855
- });
856
- return formula.replace(/([a-zA-Z]+)([0-9]+)/g, (match) => {
857
- return addressToIndex(sheet, addressFromA1Notation2(match));
858
- });
859
- };
860
- var mapFormulaIndicesToRefs = (sheet, formula) => {
861
- invariant2(isFormula2(formula), void 0, {
862
- F: __dxlog_file2,
863
- L: 162,
864
- S: void 0,
865
- A: [
866
- "isFormula(formula)",
867
- ""
868
- ]
869
- });
870
- return formula.replace(/([a-zA-Z0-9]+)@([a-zA-Z0-9]+)/g, (idx) => {
871
- return addressToA1Notation2(addressFromIndex(sheet, idx));
872
- });
873
- };
874
-
875
- export {
876
- CellValue,
877
- Range,
878
- RowColumnMeta,
879
- SheetType,
880
- alignKey,
881
- commentKey,
882
- styleKey,
883
- cellClassNameForRange,
884
- useSheetModel,
885
- SheetAction,
886
- MAX_ROWS,
887
- MAX_COLS,
888
- DEFAULT_ROWS,
889
- DEFAULT_COLS,
890
- ApiError,
891
- ReadonlyException,
892
- RangeException,
893
- createIndex,
894
- createIndices,
895
- insertIndices,
896
- initialize,
897
- createSheet,
898
- addressToIndex,
899
- addressFromIndex,
900
- rangeToIndex,
901
- rangeFromIndex,
902
- compareIndexPositions,
903
- mapFormulaRefsToIndices,
904
- mapFormulaIndicesToRefs
905
- };
906
- //# sourceMappingURL=chunk-ADK2HW4A.mjs.map