@dxos/plugin-sheet 0.6.13-main.ed424a1 → 0.6.13
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.
- package/dist/lib/browser/SheetContainer-U4H5D34A.mjs +1772 -0
- package/dist/lib/browser/SheetContainer-U4H5D34A.mjs.map +7 -0
- package/dist/lib/browser/chunk-APHOLYUB.mjs +175 -0
- package/dist/lib/browser/chunk-APHOLYUB.mjs.map +7 -0
- package/dist/lib/{node-esm/chunk-5WPZCXNS.mjs → browser/chunk-D5AGLXJP.mjs} +678 -411
- package/dist/lib/browser/chunk-D5AGLXJP.mjs.map +7 -0
- package/dist/lib/browser/chunk-FUAGSXA4.mjs +82 -0
- package/dist/lib/browser/chunk-FUAGSXA4.mjs.map +7 -0
- package/dist/lib/browser/chunk-JRL5LGCE.mjs +18 -0
- package/dist/lib/browser/chunk-JRL5LGCE.mjs.map +7 -0
- package/dist/lib/browser/chunk-NU4PBN33.mjs +8 -0
- package/dist/lib/browser/chunk-NU4PBN33.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +62 -93
- package/dist/lib/browser/index.mjs.map +3 -3
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/meta.mjs +1 -1
- package/dist/lib/browser/testing.mjs +92 -0
- package/dist/lib/browser/testing.mjs.map +7 -0
- package/dist/lib/browser/types.mjs +12 -6
- package/dist/lib/node/SheetContainer-AXQV3ZT5.cjs +1765 -0
- package/dist/lib/node/SheetContainer-AXQV3ZT5.cjs.map +7 -0
- package/dist/lib/node/{chunk-5XPK2V4A.cjs → chunk-5KKJ4NPP.cjs} +678 -418
- package/dist/lib/node/chunk-5KKJ4NPP.cjs.map +7 -0
- package/dist/lib/node/chunk-BJ6ZD7MN.cjs +51 -0
- package/dist/lib/node/chunk-BJ6ZD7MN.cjs.map +7 -0
- package/dist/lib/node/chunk-CN3RPESU.cjs +202 -0
- package/dist/lib/node/chunk-CN3RPESU.cjs.map +7 -0
- package/dist/lib/node/{chunk-NZARD7UP.cjs → chunk-DSYKOI4E.cjs} +51 -40
- package/dist/lib/node/chunk-DSYKOI4E.cjs.map +7 -0
- package/dist/lib/node/chunk-PYXHNAAK.cjs +40 -0
- package/dist/lib/node/chunk-PYXHNAAK.cjs.map +7 -0
- package/dist/lib/node/index.cjs +69 -105
- package/dist/lib/node/index.cjs.map +3 -3
- package/dist/lib/node/meta.cjs +3 -3
- package/dist/lib/node/meta.cjs.map +1 -1
- package/dist/lib/node/meta.json +1 -1
- package/dist/lib/node/testing.cjs +111 -0
- package/dist/lib/node/testing.cjs.map +7 -0
- package/dist/lib/node/types.cjs +15 -9
- package/dist/lib/node/types.cjs.map +2 -2
- package/dist/types/src/SheetPlugin.d.ts.map +1 -1
- package/dist/types/src/components/CellEditor/CellEditor.d.ts +14 -0
- package/dist/types/src/components/CellEditor/CellEditor.d.ts.map +1 -0
- package/dist/types/src/components/{GridSheet/SheetCellEditor.stories.d.ts → CellEditor/CellEditor.stories.d.ts} +4 -4
- package/dist/types/src/components/CellEditor/CellEditor.stories.d.ts.map +1 -0
- package/dist/types/src/{extensions/editor → components/CellEditor}/extension.d.ts +1 -1
- package/dist/types/src/components/CellEditor/extension.d.ts.map +1 -0
- package/dist/types/src/components/CellEditor/extension.test.d.ts.map +1 -0
- package/dist/types/src/components/CellEditor/index.d.ts +3 -0
- package/dist/types/src/components/CellEditor/index.d.ts.map +1 -0
- package/dist/types/src/{graph/functions → components/ComputeGraph}/async-function.d.ts +5 -14
- package/dist/types/src/components/ComputeGraph/async-function.d.ts.map +1 -0
- package/dist/types/src/components/ComputeGraph/custom.d.ts +21 -0
- package/dist/types/src/components/ComputeGraph/custom.d.ts.map +1 -0
- package/dist/types/src/components/ComputeGraph/edge-function.d.ts +20 -0
- package/dist/types/src/components/ComputeGraph/edge-function.d.ts.map +1 -0
- package/dist/types/src/components/ComputeGraph/graph-context.d.ts +12 -0
- package/dist/types/src/components/ComputeGraph/graph-context.d.ts.map +1 -0
- package/dist/types/src/components/ComputeGraph/graph.browser.test.d.ts +2 -0
- package/dist/types/src/components/ComputeGraph/graph.browser.test.d.ts.map +1 -0
- package/dist/types/src/components/ComputeGraph/graph.d.ts +26 -0
- package/dist/types/src/components/ComputeGraph/graph.d.ts.map +1 -0
- package/dist/types/src/components/ComputeGraph/index.d.ts +3 -1
- package/dist/types/src/components/ComputeGraph/index.d.ts.map +1 -1
- package/dist/types/src/components/Sheet/Sheet.d.ts +55 -0
- package/dist/types/src/components/Sheet/Sheet.d.ts.map +1 -0
- package/dist/types/src/components/Sheet/Sheet.stories.d.ts +54 -0
- package/dist/types/src/components/Sheet/Sheet.stories.d.ts.map +1 -0
- package/dist/types/src/components/Sheet/formatting.d.ts +14 -0
- package/dist/types/src/components/Sheet/formatting.d.ts.map +1 -0
- package/dist/types/src/components/Sheet/grid.d.ts +52 -0
- package/dist/types/src/components/Sheet/grid.d.ts.map +1 -0
- package/dist/types/src/components/Sheet/index.d.ts +2 -0
- package/dist/types/src/components/Sheet/index.d.ts.map +1 -0
- package/dist/types/src/components/Sheet/nav.d.ts +29 -0
- package/dist/types/src/components/Sheet/nav.d.ts.map +1 -0
- package/dist/types/src/components/Sheet/sheet-context.d.ts +25 -0
- package/dist/types/src/components/Sheet/sheet-context.d.ts.map +1 -0
- package/dist/types/src/components/Sheet/util.d.ts +18 -0
- package/dist/types/src/components/Sheet/util.d.ts.map +1 -0
- package/dist/types/src/components/SheetContainer.d.ts +9 -0
- package/dist/types/src/components/SheetContainer.d.ts.map +1 -0
- package/dist/types/src/components/Toolbar/Toolbar.d.ts +9 -33
- package/dist/types/src/components/Toolbar/Toolbar.d.ts.map +1 -1
- package/dist/types/src/components/Toolbar/Toolbar.stories.d.ts +15 -19
- package/dist/types/src/components/Toolbar/Toolbar.stories.d.ts.map +1 -1
- package/dist/types/src/components/Toolbar/common.d.ts +20 -0
- package/dist/types/src/components/Toolbar/common.d.ts.map +1 -0
- package/dist/types/src/components/index.d.ts +2 -3
- package/dist/types/src/components/index.d.ts.map +1 -1
- package/dist/types/src/meta.d.ts +9 -3
- package/dist/types/src/meta.d.ts.map +1 -1
- package/dist/types/src/{graph/functions/function-defs.d.ts → model/functions.d.ts} +1 -1
- package/dist/types/src/model/functions.d.ts.map +1 -0
- package/dist/types/src/model/index.d.ts +3 -2
- package/dist/types/src/model/index.d.ts.map +1 -1
- package/dist/types/src/model/model.browser.test.d.ts +2 -0
- package/dist/types/src/model/model.browser.test.d.ts.map +1 -0
- package/dist/types/src/model/{sheet-model.d.ts → model.d.ts} +67 -13
- package/dist/types/src/model/model.d.ts.map +1 -0
- package/dist/types/src/{defs → model}/types.d.ts +3 -8
- package/dist/types/src/model/types.d.ts.map +1 -0
- package/dist/types/src/model/types.test.d.ts.map +1 -0
- package/dist/types/src/model/util.d.ts +15 -0
- package/dist/types/src/model/util.d.ts.map +1 -0
- package/dist/types/src/testing.d.ts +9 -0
- package/dist/types/src/testing.d.ts.map +1 -0
- package/dist/types/src/translations.d.ts +12 -17
- package/dist/types/src/translations.d.ts.map +1 -1
- package/dist/types/src/types.d.ts +40 -125
- package/dist/types/src/types.d.ts.map +1 -1
- package/package.json +52 -58
- package/src/SheetPlugin.tsx +74 -52
- package/src/components/{GridSheet/SheetCellEditor.stories.tsx → CellEditor/CellEditor.stories.tsx} +8 -8
- package/src/components/CellEditor/CellEditor.tsx +113 -0
- package/src/{extensions/editor → components/CellEditor}/extension.test.ts +6 -4
- package/src/{extensions/editor → components/CellEditor}/extension.ts +6 -5
- package/src/{extensions/editor → components/CellEditor}/index.ts +1 -0
- package/src/{graph/functions → components/ComputeGraph}/async-function.ts +15 -25
- package/src/{graph/testing/test-plugin.ts → components/ComputeGraph/custom.ts} +14 -44
- package/src/{graph/functions → components/ComputeGraph}/edge-function.ts +14 -16
- package/src/components/ComputeGraph/graph-context.tsx +50 -0
- package/src/components/ComputeGraph/graph.browser.test.ts +50 -0
- package/src/components/ComputeGraph/graph.ts +62 -0
- package/src/components/ComputeGraph/index.ts +3 -1
- package/src/components/Sheet/Sheet.stories.tsx +287 -0
- package/src/components/Sheet/Sheet.tsx +1160 -0
- package/src/components/Sheet/formatting.ts +106 -0
- package/src/components/Sheet/grid.ts +191 -0
- package/src/{testing → components/Sheet}/index.ts +1 -1
- package/src/components/Sheet/nav.ts +157 -0
- package/src/components/Sheet/sheet-context.tsx +150 -0
- package/src/components/Sheet/util.ts +56 -0
- package/src/components/SheetContainer.tsx +34 -0
- package/src/components/Toolbar/Toolbar.tsx +112 -242
- package/src/components/Toolbar/common.tsx +72 -0
- package/src/components/index.ts +0 -2
- package/src/meta.tsx +18 -0
- package/src/model/index.ts +3 -2
- package/src/model/model.browser.test.ts +100 -0
- package/src/model/model.ts +550 -0
- package/src/{defs → model}/types.test.ts +9 -8
- package/src/{defs → model}/types.ts +14 -24
- package/src/model/util.ts +36 -0
- package/src/testing.ts +50 -0
- package/src/translations.ts +1 -6
- package/src/types.ts +47 -40
- package/dist/lib/browser/SheetContainer-RVRACGCZ.mjs +0 -290
- package/dist/lib/browser/SheetContainer-RVRACGCZ.mjs.map +0 -7
- package/dist/lib/browser/chunk-BWN5DZWZ.mjs +0 -74
- package/dist/lib/browser/chunk-BWN5DZWZ.mjs.map +0 -7
- package/dist/lib/browser/chunk-D3QTX46O.mjs +0 -14
- package/dist/lib/browser/chunk-D3QTX46O.mjs.map +0 -7
- package/dist/lib/browser/chunk-GSV5QNLD.mjs +0 -2966
- package/dist/lib/browser/chunk-GSV5QNLD.mjs.map +0 -7
- package/dist/lib/browser/chunk-HOG37RYS.mjs +0 -1528
- package/dist/lib/browser/chunk-HOG37RYS.mjs.map +0 -7
- package/dist/lib/browser/graph-M4IQ76QX.mjs +0 -33
- package/dist/lib/browser/graph-M4IQ76QX.mjs.map +0 -7
- package/dist/lib/node/SheetContainer-J7XROAMN.cjs +0 -300
- package/dist/lib/node/SheetContainer-J7XROAMN.cjs.map +0 -7
- package/dist/lib/node/chunk-5XPK2V4A.cjs.map +0 -7
- package/dist/lib/node/chunk-AXQZA2YS.cjs +0 -1527
- package/dist/lib/node/chunk-AXQZA2YS.cjs.map +0 -7
- package/dist/lib/node/chunk-NZARD7UP.cjs.map +0 -7
- package/dist/lib/node/chunk-QIFIGEKV.cjs +0 -37
- package/dist/lib/node/chunk-QIFIGEKV.cjs.map +0 -7
- package/dist/lib/node/graph-Q3N2X26H.cjs +0 -55
- package/dist/lib/node/graph-Q3N2X26H.cjs.map +0 -7
- package/dist/lib/node-esm/SheetContainer-YWQVKHQB.mjs +0 -291
- package/dist/lib/node-esm/SheetContainer-YWQVKHQB.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-5WPZCXNS.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-BPXXIAOQ.mjs +0 -1529
- package/dist/lib/node-esm/chunk-BPXXIAOQ.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-VCYJWE3O.mjs +0 -16
- package/dist/lib/node-esm/chunk-VCYJWE3O.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-WFDTY3IC.mjs +0 -75
- package/dist/lib/node-esm/chunk-WFDTY3IC.mjs.map +0 -7
- package/dist/lib/node-esm/graph-SMPUMOV2.mjs +0 -34
- package/dist/lib/node-esm/graph-SMPUMOV2.mjs.map +0 -7
- package/dist/lib/node-esm/index.mjs +0 -280
- package/dist/lib/node-esm/index.mjs.map +0 -7
- package/dist/lib/node-esm/meta.json +0 -1
- package/dist/lib/node-esm/meta.mjs +0 -10
- package/dist/lib/node-esm/meta.mjs.map +0 -7
- package/dist/lib/node-esm/types.mjs +0 -17
- package/dist/lib/node-esm/types.mjs.map +0 -7
- package/dist/types/src/components/ComputeGraph/ComputeGraphContextProvider.d.ts +0 -11
- package/dist/types/src/components/ComputeGraph/ComputeGraphContextProvider.d.ts.map +0 -1
- package/dist/types/src/components/FunctionEditor/FunctionEditor.d.ts +0 -3
- package/dist/types/src/components/FunctionEditor/FunctionEditor.d.ts.map +0 -1
- package/dist/types/src/components/FunctionEditor/index.d.ts +0 -2
- package/dist/types/src/components/FunctionEditor/index.d.ts.map +0 -1
- package/dist/types/src/components/GridSheet/GridSheet.d.ts +0 -3
- package/dist/types/src/components/GridSheet/GridSheet.d.ts.map +0 -1
- package/dist/types/src/components/GridSheet/GridSheet.stories.d.ts +0 -9
- package/dist/types/src/components/GridSheet/GridSheet.stories.d.ts.map +0 -1
- package/dist/types/src/components/GridSheet/SheetCellEditor.stories.d.ts.map +0 -1
- package/dist/types/src/components/GridSheet/index.d.ts +0 -2
- package/dist/types/src/components/GridSheet/index.d.ts.map +0 -1
- package/dist/types/src/components/GridSheet/util.d.ts +0 -16
- package/dist/types/src/components/GridSheet/util.d.ts.map +0 -1
- package/dist/types/src/components/SheetContainer/SheetContainer.d.ts +0 -6
- package/dist/types/src/components/SheetContainer/SheetContainer.d.ts.map +0 -1
- package/dist/types/src/components/SheetContainer/SheetContainer.stories.d.ts +0 -11
- package/dist/types/src/components/SheetContainer/SheetContainer.stories.d.ts.map +0 -1
- package/dist/types/src/components/SheetContainer/index.d.ts +0 -3
- package/dist/types/src/components/SheetContainer/index.d.ts.map +0 -1
- package/dist/types/src/components/SheetContext/SheetContext.d.ts +0 -26
- package/dist/types/src/components/SheetContext/SheetContext.d.ts.map +0 -1
- package/dist/types/src/components/SheetContext/index.d.ts +0 -2
- package/dist/types/src/components/SheetContext/index.d.ts.map +0 -1
- package/dist/types/src/defs/index.d.ts +0 -4
- package/dist/types/src/defs/index.d.ts.map +0 -1
- package/dist/types/src/defs/sheet-range-types.d.ts +0 -13
- package/dist/types/src/defs/sheet-range-types.d.ts.map +0 -1
- package/dist/types/src/defs/types.d.ts.map +0 -1
- package/dist/types/src/defs/types.test.d.ts.map +0 -1
- package/dist/types/src/defs/util.d.ts +0 -43
- package/dist/types/src/defs/util.d.ts.map +0 -1
- package/dist/types/src/extensions/compute.d.ts +0 -6
- package/dist/types/src/extensions/compute.d.ts.map +0 -1
- package/dist/types/src/extensions/compute.stories.d.ts +0 -26
- package/dist/types/src/extensions/compute.stories.d.ts.map +0 -1
- package/dist/types/src/extensions/editor/extension.d.ts.map +0 -1
- package/dist/types/src/extensions/editor/extension.test.d.ts.map +0 -1
- package/dist/types/src/extensions/editor/index.d.ts +0 -2
- package/dist/types/src/extensions/editor/index.d.ts.map +0 -1
- package/dist/types/src/extensions/index.d.ts +0 -3
- package/dist/types/src/extensions/index.d.ts.map +0 -1
- package/dist/types/src/graph/compute-graph-registry.d.ts +0 -34
- package/dist/types/src/graph/compute-graph-registry.d.ts.map +0 -1
- package/dist/types/src/graph/compute-graph.d.ts +0 -64
- package/dist/types/src/graph/compute-graph.d.ts.map +0 -1
- package/dist/types/src/graph/compute-graph.stories.d.ts +0 -10
- package/dist/types/src/graph/compute-graph.stories.d.ts.map +0 -1
- package/dist/types/src/graph/compute-graph.test.d.ts +0 -2
- package/dist/types/src/graph/compute-graph.test.d.ts.map +0 -1
- package/dist/types/src/graph/compute-node.d.ts +0 -26
- package/dist/types/src/graph/compute-node.d.ts.map +0 -1
- package/dist/types/src/graph/functions/async-function.d.ts.map +0 -1
- package/dist/types/src/graph/functions/edge-function.d.ts +0 -21
- package/dist/types/src/graph/functions/edge-function.d.ts.map +0 -1
- package/dist/types/src/graph/functions/function-defs.d.ts.map +0 -1
- package/dist/types/src/graph/functions/index.d.ts +0 -4
- package/dist/types/src/graph/functions/index.d.ts.map +0 -1
- package/dist/types/src/graph/hyperformula.test.d.ts +0 -2
- package/dist/types/src/graph/hyperformula.test.d.ts.map +0 -1
- package/dist/types/src/graph/index.d.ts +0 -5
- package/dist/types/src/graph/index.d.ts.map +0 -1
- package/dist/types/src/graph/testing/index.d.ts +0 -3
- package/dist/types/src/graph/testing/index.d.ts.map +0 -1
- package/dist/types/src/graph/testing/test-builder.d.ts +0 -15
- package/dist/types/src/graph/testing/test-builder.d.ts.map +0 -1
- package/dist/types/src/graph/testing/test-plugin.d.ts +0 -36
- package/dist/types/src/graph/testing/test-plugin.d.ts.map +0 -1
- package/dist/types/src/graph/util.d.ts +0 -2
- package/dist/types/src/graph/util.d.ts.map +0 -1
- package/dist/types/src/hooks/hooks.stories.d.ts +0 -11
- package/dist/types/src/hooks/hooks.stories.d.ts.map +0 -1
- package/dist/types/src/hooks/index.d.ts +0 -4
- package/dist/types/src/hooks/index.d.ts.map +0 -1
- package/dist/types/src/hooks/threads.d.ts +0 -8
- package/dist/types/src/hooks/threads.d.ts.map +0 -1
- package/dist/types/src/hooks/useComputeGraph.d.ts +0 -7
- package/dist/types/src/hooks/useComputeGraph.d.ts.map +0 -1
- package/dist/types/src/hooks/useSheetModel.d.ts +0 -8
- package/dist/types/src/hooks/useSheetModel.d.ts.map +0 -1
- package/dist/types/src/model/decorations.d.ts +0 -25
- package/dist/types/src/model/decorations.d.ts.map +0 -1
- package/dist/types/src/model/sheet-model.d.ts.map +0 -1
- package/dist/types/src/model/sheet-model.test.d.ts +0 -2
- package/dist/types/src/model/sheet-model.test.d.ts.map +0 -1
- package/dist/types/src/sanity.test.d.ts +0 -2
- package/dist/types/src/sanity.test.d.ts.map +0 -1
- package/dist/types/src/testing/index.d.ts +0 -2
- package/dist/types/src/testing/index.d.ts.map +0 -1
- package/dist/types/src/testing/testing.d.ts +0 -8
- package/dist/types/src/testing/testing.d.ts.map +0 -1
- package/dist/vendor/hyperformula.mjs +0 -37145
- package/src/components/ComputeGraph/ComputeGraphContextProvider.tsx +0 -20
- package/src/components/FunctionEditor/FunctionEditor.tsx +0 -45
- package/src/components/FunctionEditor/index.ts +0 -5
- package/src/components/GridSheet/GridSheet.stories.tsx +0 -41
- package/src/components/GridSheet/GridSheet.tsx +0 -163
- package/src/components/GridSheet/index.ts +0 -5
- package/src/components/GridSheet/util.ts +0 -158
- package/src/components/SheetContainer/SheetContainer.stories.tsx +0 -40
- package/src/components/SheetContainer/SheetContainer.tsx +0 -27
- package/src/components/SheetContainer/index.ts +0 -7
- package/src/components/SheetContext/SheetContext.tsx +0 -104
- package/src/components/SheetContext/index.ts +0 -5
- package/src/defs/index.ts +0 -7
- package/src/defs/sheet-range-types.ts +0 -46
- package/src/defs/util.ts +0 -151
- package/src/extensions/compute.stories.tsx +0 -151
- package/src/extensions/compute.ts +0 -147
- package/src/extensions/index.ts +0 -6
- package/src/graph/compute-graph-registry.ts +0 -90
- package/src/graph/compute-graph.stories.tsx +0 -93
- package/src/graph/compute-graph.test.ts +0 -87
- package/src/graph/compute-graph.ts +0 -242
- package/src/graph/compute-node.ts +0 -63
- package/src/graph/functions/index.ts +0 -7
- package/src/graph/hyperformula.test.ts +0 -14
- package/src/graph/index.ts +0 -8
- package/src/graph/testing/index.ts +0 -6
- package/src/graph/testing/test-builder.ts +0 -54
- package/src/graph/util.ts +0 -8
- package/src/hooks/hooks.stories.tsx +0 -50
- package/src/hooks/index.ts +0 -7
- package/src/hooks/threads.ts +0 -147
- package/src/hooks/useComputeGraph.ts +0 -28
- package/src/hooks/useSheetModel.ts +0 -40
- package/src/meta.ts +0 -14
- package/src/model/decorations.ts +0 -64
- package/src/model/sheet-model.test.ts +0 -57
- package/src/model/sheet-model.ts +0 -418
- package/src/sanity.test.ts +0 -40
- package/src/testing/testing.tsx +0 -68
- /package/dist/types/src/{extensions/editor → components/CellEditor}/extension.test.d.ts +0 -0
- /package/dist/types/src/{defs → model}/types.test.d.ts +0 -0
- /package/src/{graph/functions/function-defs.ts → model/functions.ts} +0 -0
|
@@ -1,26 +1,41 @@
|
|
|
1
1
|
import { type SimpleDate, type SimpleDateTime } from 'hyperformula/typings/DateTimeHelper';
|
|
2
2
|
import { Event } from '@dxos/async';
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { type
|
|
6
|
-
import { type
|
|
7
|
-
import { type
|
|
3
|
+
import { type Space } from '@dxos/client/echo';
|
|
4
|
+
import { type FunctionType } from '@dxos/plugin-script/types';
|
|
5
|
+
import { type FunctionDefinition } from './functions';
|
|
6
|
+
import { type CellAddress, type CellRange } from './types';
|
|
7
|
+
import { type ComputeGraph } from '../components';
|
|
8
|
+
import { type CellScalarValue, type CellValue, type SheetType, ValueTypeEnum } from '../types';
|
|
9
|
+
export type CellIndex = string;
|
|
10
|
+
export type CellContentValue = number | string | boolean | null;
|
|
8
11
|
export type SheetModelOptions = {
|
|
9
12
|
readonly?: boolean;
|
|
13
|
+
rows: number;
|
|
14
|
+
columns: number;
|
|
15
|
+
mapFormulaBindingToId: (functions: FunctionType[]) => (formula: string) => string;
|
|
16
|
+
mapFormulaBindingFromId: (functions: FunctionType[]) => (formula: string) => string;
|
|
10
17
|
};
|
|
18
|
+
export declare const defaultOptions: SheetModelOptions;
|
|
11
19
|
/**
|
|
12
20
|
* Spreadsheet data model.
|
|
13
21
|
*
|
|
14
22
|
* [ComputeGraphContext] > [SheetContext]:[SheetModel] > [Sheet.Root]
|
|
15
23
|
*/
|
|
16
|
-
export declare class SheetModel
|
|
24
|
+
export declare class SheetModel {
|
|
17
25
|
private readonly _graph;
|
|
18
26
|
private readonly _sheet;
|
|
19
|
-
private readonly
|
|
27
|
+
private readonly _space?;
|
|
20
28
|
readonly id: string;
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
29
|
+
private _ctx?;
|
|
30
|
+
/**
|
|
31
|
+
* Formula engine.
|
|
32
|
+
* Acts as a write through cache for scalar and computed values.
|
|
33
|
+
*/
|
|
34
|
+
private readonly _sheetId;
|
|
35
|
+
private readonly _options;
|
|
36
|
+
private _functions;
|
|
37
|
+
readonly update: Event<void>;
|
|
38
|
+
constructor(_graph: ComputeGraph, _sheet: SheetType, _space?: Space | undefined, options?: Partial<SheetModelOptions>);
|
|
24
39
|
get graph(): ComputeGraph;
|
|
25
40
|
get sheet(): SheetType;
|
|
26
41
|
get readonly(): boolean | undefined;
|
|
@@ -28,10 +43,13 @@ export declare class SheetModel extends Resource {
|
|
|
28
43
|
rows: number;
|
|
29
44
|
columns: number;
|
|
30
45
|
};
|
|
46
|
+
get functions(): FunctionDefinition[];
|
|
47
|
+
get initialized(): boolean;
|
|
31
48
|
/**
|
|
32
49
|
* Initialize sheet and engine.
|
|
33
50
|
*/
|
|
34
|
-
|
|
51
|
+
initialize(): Promise<this>;
|
|
52
|
+
destroy(): Promise<void>;
|
|
35
53
|
/**
|
|
36
54
|
* Update engine.
|
|
37
55
|
* NOTE: This resets the undo history.
|
|
@@ -75,7 +93,7 @@ export declare class SheetModel extends Resource {
|
|
|
75
93
|
/**
|
|
76
94
|
* Get value type.
|
|
77
95
|
*/
|
|
78
|
-
getValueType(cell: CellAddress):
|
|
96
|
+
getValueType(cell: CellAddress): ValueTypeEnum;
|
|
79
97
|
/**
|
|
80
98
|
* Sets the value, updating the sheet and engine.
|
|
81
99
|
*/
|
|
@@ -88,8 +106,44 @@ export declare class SheetModel extends Resource {
|
|
|
88
106
|
* Iterate range.
|
|
89
107
|
*/
|
|
90
108
|
private _iterRange;
|
|
109
|
+
/**
|
|
110
|
+
*
|
|
111
|
+
*/
|
|
112
|
+
private _insertIndices;
|
|
91
113
|
private _deleteIndices;
|
|
92
114
|
private _moveIndices;
|
|
115
|
+
/**
|
|
116
|
+
* E.g., "A1" => "x1@y1".
|
|
117
|
+
*/
|
|
118
|
+
addressToIndex(cell: CellAddress): CellIndex;
|
|
119
|
+
/**
|
|
120
|
+
* E.g., "x1@y1" => "A1".
|
|
121
|
+
*/
|
|
122
|
+
addressFromIndex(idx: CellIndex): CellAddress;
|
|
123
|
+
/**
|
|
124
|
+
* E.g., "A1:B2" => "x1@y1:x2@y2".
|
|
125
|
+
*/
|
|
126
|
+
rangeToIndex(range: CellRange): string;
|
|
127
|
+
/**
|
|
128
|
+
* E.g., "x1@y1:x2@y2" => "A1:B2".
|
|
129
|
+
*/
|
|
130
|
+
rangeFromIndex(idx: string): CellRange;
|
|
131
|
+
/**
|
|
132
|
+
* E.g., "HELLO()" => "EDGE("HELLO")".
|
|
133
|
+
*/
|
|
134
|
+
mapFormulaBindingToFormula(formula: string): string;
|
|
135
|
+
/**
|
|
136
|
+
* E.g., "EDGE("HELLO")" => "HELLO()".
|
|
137
|
+
*/
|
|
138
|
+
mapFormulaBindingFromFormula(formula: string): string;
|
|
139
|
+
/**
|
|
140
|
+
* Map from binding to fully qualified ECHO ID.
|
|
141
|
+
*/
|
|
142
|
+
mapFormulaBindingToId(formula: string): string;
|
|
143
|
+
/**
|
|
144
|
+
* Map from fully qualified ECHO ID to binding.
|
|
145
|
+
*/
|
|
146
|
+
mapFormulaBindingFromId(formula: string): string;
|
|
93
147
|
/**
|
|
94
148
|
* Map from A1 notation to indices.
|
|
95
149
|
*/
|
|
@@ -108,4 +162,4 @@ export declare class SheetModel extends Resource {
|
|
|
108
162
|
toDate(num: number): SimpleDate;
|
|
109
163
|
toTime(num: number): SimpleDate;
|
|
110
164
|
}
|
|
111
|
-
//# sourceMappingURL=
|
|
165
|
+
//# sourceMappingURL=model.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"model.d.ts","sourceRoot":"","sources":["../../../../src/model/model.ts"],"names":[],"mappings":"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"}
|
|
@@ -1,20 +1,15 @@
|
|
|
1
|
-
export declare const DEFAULT_ROWS = 50;
|
|
2
|
-
export declare const DEFAULT_COLUMNS = 26;
|
|
3
|
-
export declare const MAX_ROWS = 500;
|
|
4
1
|
export declare const MAX_COLUMNS: number;
|
|
5
2
|
export type CellAddress = {
|
|
6
|
-
|
|
3
|
+
column: number;
|
|
7
4
|
row: number;
|
|
8
5
|
};
|
|
9
6
|
export type CellRange = {
|
|
10
7
|
from: CellAddress;
|
|
11
8
|
to?: CellAddress;
|
|
12
9
|
};
|
|
13
|
-
export type CellIndex = string;
|
|
14
|
-
export type CellContentValue = number | string | boolean | null;
|
|
15
10
|
export declare const posEquals: (a: CellAddress | undefined, b: CellAddress | undefined) => boolean;
|
|
16
|
-
export declare const columnLetter: (
|
|
17
|
-
export declare const addressToA1Notation: ({
|
|
11
|
+
export declare const columnLetter: (column: number) => string;
|
|
12
|
+
export declare const addressToA1Notation: ({ column, row }: CellAddress) => string;
|
|
18
13
|
export declare const addressFromA1Notation: (ref: string) => CellAddress;
|
|
19
14
|
export declare const rangeToA1Notation: (range: CellRange) => string;
|
|
20
15
|
export declare const rangeFromA1Notation: (ref: string) => CellRange;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/model/types.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,WAAW,QAAU,CAAC;AAEnC,MAAM,MAAM,WAAW,GAAG;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,CAAC;AAC1D,MAAM,MAAM,SAAS,GAAG;IAAE,IAAI,EAAE,WAAW,CAAC;IAAC,EAAE,CAAC,EAAE,WAAW,CAAA;CAAE,CAAC;AAEhE,eAAO,MAAM,SAAS,MAAO,WAAW,GAAG,SAAS,KAAK,WAAW,GAAG,SAAS,YAE/E,CAAC;AAEF,eAAO,MAAM,YAAY,WAAY,MAAM,KAAG,MAM7C,CAAC;AAEF,eAAO,MAAM,mBAAmB,oBAAqB,WAAW,KAAG,MAElE,CAAC;AAEF,eAAO,MAAM,qBAAqB,QAAS,MAAM,KAAG,WAOnD,CAAC;AAEF,eAAO,MAAM,iBAAiB,UAAW,SAAS,WAIjD,CAAC;AAEF,eAAO,MAAM,mBAAmB,QAAS,MAAM,KAAG,SAGjD,CAAC;AAEF,eAAO,MAAM,OAAO,UAAW,SAAS,GAAG,SAAS,QAAQ,WAAW,KAAG,OAuBzE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.test.d.ts","sourceRoot":"","sources":["../../../../src/model/types.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare class ApiError extends Error {
|
|
2
|
+
}
|
|
3
|
+
export declare class ReadonlyException extends ApiError {
|
|
4
|
+
}
|
|
5
|
+
export declare class RangeException extends ApiError {
|
|
6
|
+
constructor(n: number);
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* With a string length of 8, the chance of a collision is 0.02% for a sheet with 10,000 strings.
|
|
10
|
+
*/
|
|
11
|
+
export declare const createIndex: (length?: number) => string;
|
|
12
|
+
export declare const createIndices: (length: number) => string[];
|
|
13
|
+
export declare const pickOne: <T>(values: T[]) => T;
|
|
14
|
+
export declare const pickSome: <T>(values: T[], n?: number) => T[];
|
|
15
|
+
//# sourceMappingURL=util.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../../../../src/model/util.ts"],"names":[],"mappings":"AAOA,qBAAa,QAAS,SAAQ,KAAK;CAAG;AACtC,qBAAa,iBAAkB,SAAQ,QAAQ;CAAG;AAClD,qBAAa,cAAe,SAAQ,QAAQ;gBAC9B,CAAC,EAAE,MAAM;CAGtB;AAED;;GAEG;AACH,eAAO,MAAM,WAAW,uBAAiB,MAKxC,CAAC;AAEF,eAAO,MAAM,aAAa,WAAY,MAAM,KAAG,MAAM,EAAqD,CAAC;AAG3G,eAAO,MAAM,OAAO,GAAI,CAAC,UAAU,CAAC,EAAE,KAAG,CAAsD,CAAC;AAChG,eAAO,MAAM,QAAQ,GAAI,CAAC,UAAU,CAAC,EAAE,iBAAU,CAAC,EAMjD,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type ComputeGraph } from './components';
|
|
2
|
+
import { type CellValue } from './types';
|
|
3
|
+
export declare const testSheetName = "test";
|
|
4
|
+
export declare const createCells: () => Record<string, CellValue>;
|
|
5
|
+
export declare const createTestSheet: ({ name, graph, }?: {
|
|
6
|
+
name?: string;
|
|
7
|
+
graph?: ComputeGraph;
|
|
8
|
+
}) => Promise<import("./types").SheetType>;
|
|
9
|
+
//# sourceMappingURL=testing.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"testing.d.ts","sourceRoot":"","sources":["../../../src/testing.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,YAAY,EAAsB,MAAM,cAAc,CAAC;AAErE,OAAO,EAAe,KAAK,SAAS,EAAE,MAAM,SAAS,CAAC;AAEtD,eAAO,MAAM,aAAa,SAAS,CAAC;AAEpC,eAAO,MAAM,WAAW,QAAO,MAAM,CAAC,MAAM,EAAE,SAAS,CA0BrD,CAAC;AAEH,eAAO,MAAM,eAAe,sBAGzB;IAAE,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,KAAK,CAAC,EAAE,YAAY,CAAA;CAAE,yCAQzC,CAAC"}
|
|
@@ -1,21 +1,16 @@
|
|
|
1
|
-
declare const _default:
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
readonly 'selection overlaps existing comment label': "Selected cell already has a comment";
|
|
13
|
-
readonly 'comment label': "Add comment";
|
|
14
|
-
readonly 'comment ranges not supported label': "Commenting on ranges is not yet supported";
|
|
15
|
-
readonly 'no cursor label': "Select a cell to comment";
|
|
16
|
-
readonly 'open comment for sheet cell': "View comments for cell";
|
|
1
|
+
declare const _default: {
|
|
2
|
+
'en-US': {
|
|
3
|
+
"dxos.org/plugin/sheet": {
|
|
4
|
+
'plugin name': string;
|
|
5
|
+
'sheet title placeholder': string;
|
|
6
|
+
'create sheet label': string;
|
|
7
|
+
'create sheet section label': string;
|
|
8
|
+
'cell placeholder': string;
|
|
9
|
+
'toolbar left label': string;
|
|
10
|
+
'toolbar left center': string;
|
|
11
|
+
'toolbar left right': string;
|
|
17
12
|
};
|
|
18
13
|
};
|
|
19
|
-
}];
|
|
14
|
+
}[];
|
|
20
15
|
export default _default;
|
|
21
16
|
//# sourceMappingURL=translations.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"translations.d.ts","sourceRoot":"","sources":["../../../src/translations.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"translations.d.ts","sourceRoot":"","sources":["../../../src/translations.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAMA,wBAeE"}
|
|
@@ -1,43 +1,45 @@
|
|
|
1
1
|
import type { GraphBuilderProvides, IntentResolverProvides, MetadataRecordsProvides, SurfaceProvides, TranslationsProvides } from '@dxos/app-framework';
|
|
2
|
-
import {
|
|
2
|
+
import { S } from '@dxos/echo-schema';
|
|
3
3
|
import { type SchemaProvides } from '@dxos/plugin-client';
|
|
4
|
-
import { type MarkdownExtensionProvides } from '@dxos/plugin-markdown';
|
|
5
|
-
import { type SpaceInitProvides } from '@dxos/plugin-space';
|
|
6
4
|
import { type StackProvides } from '@dxos/plugin-stack';
|
|
7
5
|
export declare enum SheetAction {
|
|
8
6
|
CREATE = "dxos.org/plugin/sheet/action/create"
|
|
9
7
|
}
|
|
10
|
-
type
|
|
11
|
-
thread: {
|
|
12
|
-
predicate: (obj: any) => obj is T;
|
|
13
|
-
createSort: (obj: T) => (anchorA: string | undefined, anchorB: string | undefined) => number;
|
|
14
|
-
};
|
|
15
|
-
};
|
|
16
|
-
export type SheetPluginProvides = SurfaceProvides & IntentResolverProvides & GraphBuilderProvides & MarkdownExtensionProvides & MetadataRecordsProvides & TranslationsProvides & SchemaProvides & SpaceInitProvides & StackProvides & ThreadProvides<SheetType>;
|
|
8
|
+
export type SheetPluginProvides = SurfaceProvides & IntentResolverProvides & GraphBuilderProvides & MetadataRecordsProvides & TranslationsProvides & SchemaProvides & StackProvides;
|
|
17
9
|
export type CellScalarValue = number | string | boolean | null;
|
|
18
10
|
export declare const CellValue: S.Struct<{
|
|
19
11
|
value: typeof S.Any;
|
|
20
12
|
}>;
|
|
21
13
|
export type CellValue = S.Schema.Type<typeof CellValue>;
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
14
|
+
/**
|
|
15
|
+
* https://www.tutorialsteacher.com/typescript/typescript-number
|
|
16
|
+
*/
|
|
17
|
+
export declare enum ValueTypeEnum {
|
|
18
|
+
Null = 0,
|
|
19
|
+
Number = 1,
|
|
20
|
+
Boolean = 2,
|
|
21
|
+
String = 3,
|
|
22
|
+
Percent = 10,
|
|
23
|
+
Currency = 11,
|
|
24
|
+
DateTime = 20,
|
|
25
|
+
Date = 21,
|
|
26
|
+
Time = 22,
|
|
27
|
+
URL = 30,
|
|
28
|
+
DID = 31
|
|
29
|
+
}
|
|
30
|
+
export declare const ValueType: S.Enums<typeof ValueTypeEnum>;
|
|
31
|
+
export declare const Formatting: S.Struct<{
|
|
32
|
+
type: S.optional<S.Enums<typeof ValueTypeEnum>>;
|
|
33
|
+
format: S.optional<typeof S.String>;
|
|
34
|
+
precision: S.optional<typeof S.Number>;
|
|
35
|
+
classNames: S.optional<S.Array$<typeof S.String>>;
|
|
35
36
|
}>;
|
|
37
|
+
export type Formatting = S.Schema.Type<typeof Formatting>;
|
|
36
38
|
export declare const RowColumnMeta: S.Struct<{
|
|
37
39
|
size: S.optional<typeof S.Number>;
|
|
38
40
|
}>;
|
|
39
41
|
declare const SheetType_base: import("@dxos/echo-schema").AbstractTypedObject<{
|
|
40
|
-
|
|
42
|
+
title?: string | undefined;
|
|
41
43
|
cells: {
|
|
42
44
|
[x: string]: {
|
|
43
45
|
value: any;
|
|
@@ -55,57 +57,18 @@ declare const SheetType_base: import("@dxos/echo-schema").AbstractTypedObject<{
|
|
|
55
57
|
size?: number | undefined;
|
|
56
58
|
};
|
|
57
59
|
};
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
};
|
|
65
|
-
readonly to: {
|
|
66
|
-
readonly col: number;
|
|
67
|
-
readonly row: number;
|
|
68
|
-
};
|
|
60
|
+
formatting: {
|
|
61
|
+
[x: string]: {
|
|
62
|
+
type?: ValueTypeEnum | undefined;
|
|
63
|
+
format?: string | undefined;
|
|
64
|
+
precision?: number | undefined;
|
|
65
|
+
classNames?: readonly string[] | undefined;
|
|
69
66
|
};
|
|
70
|
-
|
|
71
|
-
}[];
|
|
72
|
-
threads?: import("@dxos/echo-schema").Ref<{
|
|
73
|
-
name?: string | undefined;
|
|
74
|
-
anchor?: string | undefined;
|
|
75
|
-
status?: "active" | "staged" | "resolved" | undefined;
|
|
76
|
-
messages: import("@dxos/echo-schema").Ref<{
|
|
77
|
-
text: string;
|
|
78
|
-
timestamp: string;
|
|
79
|
-
state?: import("@dxos/plugin-space").MessageState | undefined;
|
|
80
|
-
sender: {
|
|
81
|
-
name?: string | undefined;
|
|
82
|
-
contact?: import("@dxos/echo-schema").Ref<{
|
|
83
|
-
name?: string | undefined;
|
|
84
|
-
identifiers: {
|
|
85
|
-
readonly value: string;
|
|
86
|
-
readonly type: string;
|
|
87
|
-
}[];
|
|
88
|
-
} & {
|
|
89
|
-
id: string;
|
|
90
|
-
}>;
|
|
91
|
-
identityKey?: string | undefined;
|
|
92
|
-
email?: string | undefined;
|
|
93
|
-
};
|
|
94
|
-
parts?: import("@dxos/echo-schema").Ref<import("@dxos/echo-schema").Expando>[] | undefined;
|
|
95
|
-
properties?: {
|
|
96
|
-
[x: string]: any;
|
|
97
|
-
} | undefined;
|
|
98
|
-
context?: import("@dxos/echo-schema").Ref<import("@dxos/echo-schema").Expando>;
|
|
99
|
-
} & {
|
|
100
|
-
id: string;
|
|
101
|
-
}>[];
|
|
102
|
-
} & {
|
|
103
|
-
id: string;
|
|
104
|
-
}>[] | undefined;
|
|
67
|
+
};
|
|
105
68
|
} & {
|
|
106
69
|
id: string;
|
|
107
70
|
}, S.Struct.Encoded<{
|
|
108
|
-
|
|
71
|
+
title: S.optional<typeof S.String>;
|
|
109
72
|
cells: S.mutable<S.Record$<typeof S.String, S.mutable<S.Struct<{
|
|
110
73
|
value: typeof S.Any;
|
|
111
74
|
}>>>>;
|
|
@@ -117,63 +80,15 @@ declare const SheetType_base: import("@dxos/echo-schema").AbstractTypedObject<{
|
|
|
117
80
|
columnMeta: S.mutable<S.Record$<typeof S.String, S.mutable<S.Struct<{
|
|
118
81
|
size: S.optional<typeof S.Number>;
|
|
119
82
|
}>>>>;
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
}>;
|
|
126
|
-
to: S.Struct<{
|
|
127
|
-
col: typeof S.Number;
|
|
128
|
-
row: typeof S.Number;
|
|
129
|
-
}>;
|
|
130
|
-
}>;
|
|
131
|
-
key: typeof S.String;
|
|
132
|
-
value: typeof S.String;
|
|
133
|
-
}>>>;
|
|
134
|
-
threads: S.optional<S.mutable<S.Array$<ref<{
|
|
135
|
-
name?: string | undefined;
|
|
136
|
-
anchor?: string | undefined;
|
|
137
|
-
status?: "active" | "staged" | "resolved" | undefined;
|
|
138
|
-
messages: import("@dxos/echo-schema").Ref<{
|
|
139
|
-
text: string;
|
|
140
|
-
timestamp: string;
|
|
141
|
-
state?: import("@dxos/plugin-space").MessageState | undefined;
|
|
142
|
-
sender: {
|
|
143
|
-
name?: string | undefined;
|
|
144
|
-
contact?: import("@dxos/echo-schema").Ref<{
|
|
145
|
-
name?: string | undefined;
|
|
146
|
-
identifiers: {
|
|
147
|
-
readonly value: string;
|
|
148
|
-
readonly type: string;
|
|
149
|
-
}[];
|
|
150
|
-
} & {
|
|
151
|
-
id: string;
|
|
152
|
-
}>;
|
|
153
|
-
identityKey?: string | undefined;
|
|
154
|
-
email?: string | undefined;
|
|
155
|
-
};
|
|
156
|
-
parts?: import("@dxos/echo-schema").Ref<import("@dxos/echo-schema").Expando>[] | undefined;
|
|
157
|
-
properties?: {
|
|
158
|
-
[x: string]: any;
|
|
159
|
-
} | undefined;
|
|
160
|
-
context?: import("@dxos/echo-schema").Ref<import("@dxos/echo-schema").Expando>;
|
|
161
|
-
} & {
|
|
162
|
-
id: string;
|
|
163
|
-
}>[];
|
|
164
|
-
} & {
|
|
165
|
-
id: string;
|
|
83
|
+
formatting: S.mutable<S.Record$<typeof S.String, S.mutable<S.Struct<{
|
|
84
|
+
type: S.optional<S.Enums<typeof ValueTypeEnum>>;
|
|
85
|
+
format: S.optional<typeof S.String>;
|
|
86
|
+
precision: S.optional<typeof S.Number>;
|
|
87
|
+
classNames: S.optional<S.Array$<typeof S.String>>;
|
|
166
88
|
}>>>>;
|
|
167
89
|
}>>;
|
|
168
90
|
export declare class SheetType extends SheetType_base {
|
|
169
91
|
}
|
|
170
|
-
export
|
|
171
|
-
rows: number;
|
|
172
|
-
columns: number;
|
|
173
|
-
};
|
|
174
|
-
export type CreateSheetOptions = {
|
|
175
|
-
name?: string;
|
|
176
|
-
cells?: Record<string, CellValue>;
|
|
177
|
-
} & Partial<SheetSize>;
|
|
92
|
+
export declare const createSheet: (title?: string) => SheetType;
|
|
178
93
|
export {};
|
|
179
94
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/types.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACV,oBAAoB,EACpB,sBAAsB,EACtB,uBAAuB,EACvB,eAAe,EACf,oBAAoB,EACrB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/types.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACV,oBAAoB,EACpB,sBAAsB,EACtB,uBAAuB,EACvB,eAAe,EACf,oBAAoB,EACrB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAU,CAAC,EAAe,MAAM,mBAAmB,CAAC;AAC3D,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAC1D,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAMxD,oBAAY,WAAW;IACrB,MAAM,wCAA2B;CAClC;AAED,MAAM,MAAM,mBAAmB,GAAG,eAAe,GAC/C,sBAAsB,GACtB,oBAAoB,GACpB,uBAAuB,GACvB,oBAAoB,GACpB,cAAc,GACd,aAAa,CAAC;AAEhB,MAAM,MAAM,eAAe,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,IAAI,CAAC;AAE/D,eAAO,MAAM,SAAS;;EAMpB,CAAC;AAEH,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,SAAS,CAAC,CAAC;AAExD;;GAEG;AAEH,oBAAY,aAAa;IACvB,IAAI,IAAI;IACR,MAAM,IAAI;IACV,OAAO,IAAI;IACX,MAAM,IAAI;IAGV,OAAO,KAAK;IACZ,QAAQ,KAAK;IAGb,QAAQ,KAAK;IACb,IAAI,KAAK;IACT,IAAI,KAAK;IAIT,GAAG,KAAK;IACR,GAAG,KAAK;CACT;AAED,eAAO,MAAM,SAAS,+BAAyB,CAAC;AAEhD,eAAO,MAAM,UAAU;;;;;EAKrB,CAAC;AAEH,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,UAAU,CAAC,CAAC;AAG1D,eAAO,MAAM,aAAa;;EAExB,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAKH,qBAAa,SAAU,SAAQ,cAoB7B;CAAG;AAGL,eAAO,MAAM,WAAW,WAAY,MAAM,KAAG,SACgE,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,39 +1,37 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dxos/plugin-sheet",
|
|
3
|
-
"version": "0.6.13
|
|
3
|
+
"version": "0.6.13",
|
|
4
4
|
"description": "Braneframe sketch plugin",
|
|
5
5
|
"homepage": "https://dxos.org",
|
|
6
6
|
"bugs": "https://github.com/dxos/dxos/issues",
|
|
7
7
|
"license": "MIT",
|
|
8
8
|
"author": "DXOS.org",
|
|
9
|
-
"imports": {
|
|
10
|
-
"#hyperformula": {
|
|
11
|
-
"types": "hyperformula",
|
|
12
|
-
"default": "./dist/vendor/hyperformula.mjs"
|
|
13
|
-
}
|
|
14
|
-
},
|
|
15
9
|
"exports": {
|
|
16
10
|
".": {
|
|
17
11
|
"browser": "./dist/lib/browser/index.mjs",
|
|
18
12
|
"node": {
|
|
19
|
-
"
|
|
20
|
-
"default": "./dist/lib/node-esm/index.mjs"
|
|
13
|
+
"default": "./dist/lib/node/index.cjs"
|
|
21
14
|
},
|
|
22
15
|
"types": "./dist/types/src/index.d.ts"
|
|
23
16
|
},
|
|
24
17
|
"./meta": {
|
|
25
18
|
"browser": "./dist/lib/browser/meta.mjs",
|
|
26
19
|
"node": {
|
|
27
|
-
"
|
|
28
|
-
"default": "./dist/lib/node-esm/meta.mjs"
|
|
20
|
+
"default": "./dist/lib/node/meta.cjs"
|
|
29
21
|
},
|
|
30
22
|
"types": "./dist/types/src/meta.d.ts"
|
|
31
23
|
},
|
|
24
|
+
"./testing": {
|
|
25
|
+
"browser": "./dist/lib/browser/testing.mjs",
|
|
26
|
+
"node": {
|
|
27
|
+
"default": "./dist/lib/node/testing.cjs"
|
|
28
|
+
},
|
|
29
|
+
"types": "./dist/types/src/testing.d.ts"
|
|
30
|
+
},
|
|
32
31
|
"./types": {
|
|
33
32
|
"browser": "./dist/lib/browser/types.mjs",
|
|
34
33
|
"node": {
|
|
35
|
-
"
|
|
36
|
-
"default": "./dist/lib/node-esm/types.mjs"
|
|
34
|
+
"default": "./dist/lib/node/types.cjs"
|
|
37
35
|
},
|
|
38
36
|
"types": "./dist/types/src/types.d.ts"
|
|
39
37
|
}
|
|
@@ -44,6 +42,9 @@
|
|
|
44
42
|
"meta": [
|
|
45
43
|
"dist/types/src/meta.d.ts"
|
|
46
44
|
],
|
|
45
|
+
"testing": [
|
|
46
|
+
"dist/types/src/testing.d.ts"
|
|
47
|
+
],
|
|
47
48
|
"types": [
|
|
48
49
|
"dist/types/src/types.d.ts"
|
|
49
50
|
]
|
|
@@ -54,57 +55,50 @@
|
|
|
54
55
|
"src"
|
|
55
56
|
],
|
|
56
57
|
"dependencies": {
|
|
57
|
-
"@codemirror/autocomplete": "^6.18.
|
|
58
|
-
"@codemirror/language": "^6.10.
|
|
58
|
+
"@codemirror/autocomplete": "^6.18.0",
|
|
59
|
+
"@codemirror/language": "^6.10.2",
|
|
59
60
|
"@codemirror/state": "^6.4.1",
|
|
60
|
-
"@codemirror/view": "^6.
|
|
61
|
+
"@codemirror/view": "^6.29.1",
|
|
61
62
|
"@dnd-kit/core": "^6.0.5",
|
|
62
63
|
"@dnd-kit/modifiers": "^6.0.0",
|
|
63
64
|
"@dnd-kit/sortable": "^7.0.1",
|
|
64
65
|
"@dnd-kit/utilities": "^3.2.0",
|
|
65
|
-
"@
|
|
66
|
-
"@lezer/
|
|
67
|
-
"@lezer/highlight": "^1.2.1",
|
|
66
|
+
"@lezer/common": "^1.2.1",
|
|
67
|
+
"@lezer/highlight": "^1.2.0",
|
|
68
68
|
"@lezer/lezer": "^1.1.2",
|
|
69
69
|
"@lezer/lr": "^1.4.2",
|
|
70
70
|
"@preact/signals-core": "^1.6.0",
|
|
71
71
|
"@radix-ui/react-context": "^1.0.0",
|
|
72
72
|
"@tanstack/react-virtual": "^3.9.0",
|
|
73
73
|
"codemirror-lang-spreadsheet": "^1.3.0",
|
|
74
|
-
"date-fns": "^3.3.1",
|
|
75
74
|
"hyperformula": "^2.7.1",
|
|
76
75
|
"lodash.defaultsdeep": "^4.6.1",
|
|
77
76
|
"re-resizable": "^6.9.17",
|
|
78
77
|
"react-markdown": "^8.0.5",
|
|
79
78
|
"react-resize-detector": "^11.0.1",
|
|
80
|
-
"@dxos/
|
|
81
|
-
"@dxos/
|
|
82
|
-
"@dxos/client": "0.6.13
|
|
83
|
-
"@dxos/
|
|
84
|
-
"@dxos/
|
|
85
|
-
"@dxos/debug": "0.6.13
|
|
86
|
-
"@dxos/echo-schema": "0.6.13
|
|
87
|
-
"@dxos/invariant": "0.6.13
|
|
88
|
-
"@dxos/keys": "0.6.13
|
|
89
|
-
"@dxos/log": "0.6.13
|
|
90
|
-
"@dxos/plugin-client": "0.6.13
|
|
91
|
-
"@dxos/plugin-
|
|
92
|
-
"@dxos/plugin-
|
|
93
|
-
"@dxos/plugin-
|
|
94
|
-
"@dxos/plugin-
|
|
95
|
-
"@dxos/
|
|
96
|
-
"@dxos/
|
|
97
|
-
"@dxos/react-
|
|
98
|
-
"@dxos/
|
|
99
|
-
"@dxos/react-ui-attention": "0.6.13-main.ed424a1",
|
|
100
|
-
"@dxos/react-ui-data": "0.6.13-main.ed424a1",
|
|
101
|
-
"@dxos/schema": "0.6.13-main.ed424a1",
|
|
102
|
-
"@dxos/react-ui-grid": "0.6.13-main.ed424a1",
|
|
103
|
-
"@dxos/react-ui-editor": "0.6.13-main.ed424a1",
|
|
104
|
-
"@dxos/util": "0.6.13-main.ed424a1"
|
|
79
|
+
"@dxos/app-framework": "0.6.13",
|
|
80
|
+
"@dxos/async": "0.6.13",
|
|
81
|
+
"@dxos/client": "0.6.13",
|
|
82
|
+
"@dxos/context": "0.6.13",
|
|
83
|
+
"@dxos/crypto": "0.6.13",
|
|
84
|
+
"@dxos/debug": "0.6.13",
|
|
85
|
+
"@dxos/echo-schema": "0.6.13",
|
|
86
|
+
"@dxos/invariant": "0.6.13",
|
|
87
|
+
"@dxos/keys": "0.6.13",
|
|
88
|
+
"@dxos/log": "0.6.13",
|
|
89
|
+
"@dxos/plugin-client": "0.6.13",
|
|
90
|
+
"@dxos/plugin-graph": "0.6.13",
|
|
91
|
+
"@dxos/plugin-script": "0.6.13",
|
|
92
|
+
"@dxos/plugin-space": "0.6.13",
|
|
93
|
+
"@dxos/plugin-stack": "0.6.13",
|
|
94
|
+
"@dxos/react-client": "0.6.13",
|
|
95
|
+
"@dxos/react-ui-attention": "0.6.13",
|
|
96
|
+
"@dxos/react-ui-editor": "0.6.13",
|
|
97
|
+
"@dxos/util": "0.6.13"
|
|
105
98
|
},
|
|
106
99
|
"devDependencies": {
|
|
107
100
|
"@lezer/generator": "^1.7.1",
|
|
101
|
+
"@phosphor-icons/react": "^2.1.5",
|
|
108
102
|
"@tldraw/indices": "^2.0.0-alpha.14",
|
|
109
103
|
"@types/lodash.defaultsdeep": "^4.6.6",
|
|
110
104
|
"@types/react": "~18.2.0",
|
|
@@ -112,20 +106,20 @@
|
|
|
112
106
|
"@types/react-window": "^1.8.8",
|
|
113
107
|
"react": "~18.2.0",
|
|
114
108
|
"react-dom": "~18.2.0",
|
|
115
|
-
"vite": "5.4
|
|
116
|
-
"@dxos/
|
|
117
|
-
"@dxos/
|
|
118
|
-
"@dxos/react-ui
|
|
119
|
-
"@dxos/react-ui": "0.6.13
|
|
120
|
-
"@dxos/react-ui-
|
|
121
|
-
"@dxos/
|
|
122
|
-
"@dxos/storybook-utils": "0.6.13-main.ed424a1"
|
|
109
|
+
"vite": "^5.3.4",
|
|
110
|
+
"@dxos/echo-generator": "0.6.13",
|
|
111
|
+
"@dxos/random": "0.6.13",
|
|
112
|
+
"@dxos/react-ui": "0.6.13",
|
|
113
|
+
"@dxos/react-ui-theme": "0.6.13",
|
|
114
|
+
"@dxos/react-ui-types": "0.6.13",
|
|
115
|
+
"@dxos/storybook-utils": "0.6.13"
|
|
123
116
|
},
|
|
124
|
-
"
|
|
125
|
-
"react": "
|
|
126
|
-
"react
|
|
127
|
-
"
|
|
128
|
-
"@dxos/react-ui": "0.6.13
|
|
117
|
+
"optionalDependencies": {
|
|
118
|
+
"@phosphor-icons/react": "^2.1.5",
|
|
119
|
+
"react": "^18.0.0",
|
|
120
|
+
"react-dom": "^18.0.0",
|
|
121
|
+
"@dxos/react-ui-theme": "0.6.13",
|
|
122
|
+
"@dxos/react-ui": "0.6.13"
|
|
129
123
|
},
|
|
130
124
|
"publishConfig": {
|
|
131
125
|
"access": "public"
|