@dxos/plugin-sheet 0.8.4-main.5ea62a8 → 0.8.4-main.ae835ea

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 (168) hide show
  1. package/dist/lib/browser/{SheetContainer-CWSO5WTN.mjs → SheetContainer-GTINUSNB.mjs} +15 -16
  2. package/dist/lib/browser/SheetContainer-GTINUSNB.mjs.map +7 -0
  3. package/dist/lib/browser/{anchor-sort-7WD2VGXW.mjs → anchor-sort-R5CB37J7.mjs} +7 -7
  4. package/dist/lib/browser/anchor-sort-R5CB37J7.mjs.map +7 -0
  5. package/dist/lib/browser/{chunk-KJWZUQVA.mjs → chunk-73AV3NH6.mjs} +4 -4
  6. package/dist/lib/browser/chunk-73AV3NH6.mjs.map +7 -0
  7. package/dist/lib/browser/{chunk-CL3MDNKQ.mjs → chunk-7VEWYJJN.mjs} +5 -5
  8. package/dist/lib/browser/chunk-7VEWYJJN.mjs.map +7 -0
  9. package/dist/lib/browser/{chunk-XSXUU6FO.mjs → chunk-DVJ3QW3F.mjs} +222 -221
  10. package/dist/lib/browser/chunk-DVJ3QW3F.mjs.map +7 -0
  11. package/dist/lib/browser/chunk-FWFAAGXL.mjs +28 -0
  12. package/dist/lib/browser/chunk-FWFAAGXL.mjs.map +7 -0
  13. package/dist/lib/browser/{chunk-Q3VBLCSM.mjs → chunk-LS6D4GG7.mjs} +23 -24
  14. package/dist/lib/browser/chunk-LS6D4GG7.mjs.map +7 -0
  15. package/dist/lib/browser/compute-graph-registry-AP5RA7W3.mjs +21 -0
  16. package/dist/lib/browser/compute-graph-registry-AP5RA7W3.mjs.map +7 -0
  17. package/dist/lib/browser/index.mjs +20 -21
  18. package/dist/lib/browser/index.mjs.map +3 -3
  19. package/dist/lib/browser/{intent-resolver-ROEY4LHM.mjs → intent-resolver-66OAYVQF.mjs} +9 -9
  20. package/dist/lib/browser/intent-resolver-66OAYVQF.mjs.map +7 -0
  21. package/dist/lib/browser/{markdown-VMNYPXTQ.mjs → markdown-B6VKYY2S.mjs} +6 -6
  22. package/dist/lib/browser/{markdown-VMNYPXTQ.mjs.map → markdown-B6VKYY2S.mjs.map} +1 -1
  23. package/dist/lib/browser/meta.json +1 -1
  24. package/dist/lib/browser/{react-surface-2ES3D7MJ.mjs → react-surface-F3VQPGDV.mjs} +14 -14
  25. package/dist/lib/browser/react-surface-F3VQPGDV.mjs.map +7 -0
  26. package/dist/lib/browser/types/index.mjs +4 -12
  27. package/dist/lib/node-esm/{SheetContainer-3RSDBWDG.mjs → SheetContainer-PW4KNZME.mjs} +15 -16
  28. package/dist/lib/node-esm/SheetContainer-PW4KNZME.mjs.map +7 -0
  29. package/dist/lib/node-esm/{anchor-sort-ACQDUIPU.mjs → anchor-sort-HEND452H.mjs} +7 -7
  30. package/dist/lib/node-esm/anchor-sort-HEND452H.mjs.map +7 -0
  31. package/dist/lib/node-esm/{chunk-6SK5LJ5S.mjs → chunk-44YTKTMP.mjs} +4 -4
  32. package/dist/lib/node-esm/chunk-44YTKTMP.mjs.map +7 -0
  33. package/dist/lib/node-esm/{chunk-ODP4L4OV.mjs → chunk-4H2EHVWE.mjs} +222 -221
  34. package/dist/lib/node-esm/chunk-4H2EHVWE.mjs.map +7 -0
  35. package/dist/lib/node-esm/{chunk-ZIQZU4CH.mjs → chunk-4QV4AGWK.mjs} +5 -5
  36. package/dist/lib/node-esm/chunk-4QV4AGWK.mjs.map +7 -0
  37. package/dist/lib/node-esm/chunk-HILDMVPL.mjs +29 -0
  38. package/dist/lib/node-esm/chunk-HILDMVPL.mjs.map +7 -0
  39. package/dist/lib/node-esm/{chunk-LUCRXSK6.mjs → chunk-LYUIM3QG.mjs} +23 -24
  40. package/dist/lib/node-esm/chunk-LYUIM3QG.mjs.map +7 -0
  41. package/dist/lib/node-esm/compute-graph-registry-UMQ5UYCL.mjs +22 -0
  42. package/dist/lib/node-esm/compute-graph-registry-UMQ5UYCL.mjs.map +7 -0
  43. package/dist/lib/node-esm/index.mjs +20 -21
  44. package/dist/lib/node-esm/index.mjs.map +3 -3
  45. package/dist/lib/node-esm/{intent-resolver-HESRI2ML.mjs → intent-resolver-VNKIMQQT.mjs} +9 -9
  46. package/dist/lib/node-esm/intent-resolver-VNKIMQQT.mjs.map +7 -0
  47. package/dist/lib/node-esm/{markdown-SCOTGSWB.mjs → markdown-VKY7HXU2.mjs} +6 -6
  48. package/dist/lib/node-esm/{markdown-SCOTGSWB.mjs.map → markdown-VKY7HXU2.mjs.map} +1 -1
  49. package/dist/lib/node-esm/meta.json +1 -1
  50. package/dist/lib/node-esm/{react-surface-66VS5MY2.mjs → react-surface-GGX76V2Y.mjs} +14 -14
  51. package/dist/lib/node-esm/react-surface-GGX76V2Y.mjs.map +7 -0
  52. package/dist/lib/node-esm/types/index.mjs +4 -12
  53. package/dist/types/src/SheetPlugin.d.ts +1 -1
  54. package/dist/types/src/SheetPlugin.d.ts.map +1 -1
  55. package/dist/types/src/capabilities/compute-graph-registry.d.ts.map +1 -1
  56. package/dist/types/src/components/ComputeGraph/compute-graph.stories.d.ts +0 -1
  57. package/dist/types/src/components/ComputeGraph/compute-graph.stories.d.ts.map +1 -1
  58. package/dist/types/src/components/GridSheet/GridSheet.stories.d.ts +3 -3
  59. package/dist/types/src/components/GridSheet/GridSheet.stories.d.ts.map +1 -1
  60. package/dist/types/src/components/GridSheet/SheetCellEditor.stories.d.ts +2 -4
  61. package/dist/types/src/components/GridSheet/SheetCellEditor.stories.d.ts.map +1 -1
  62. package/dist/types/src/components/RangeList/RangeList.d.ts +2 -2
  63. package/dist/types/src/components/RangeList/RangeList.d.ts.map +1 -1
  64. package/dist/types/src/components/SheetContainer/SheetContainer.d.ts +2 -2
  65. package/dist/types/src/components/SheetContainer/SheetContainer.d.ts.map +1 -1
  66. package/dist/types/src/components/SheetContainer/SheetContainer.stories.d.ts +5 -5
  67. package/dist/types/src/components/SheetContainer/SheetContainer.stories.d.ts.map +1 -1
  68. package/dist/types/src/components/SheetContext/SheetContext.d.ts +2 -2
  69. package/dist/types/src/components/SheetContext/SheetContext.d.ts.map +1 -1
  70. package/dist/types/src/components/SheetToolbar/SheetToolbar.d.ts +3 -4
  71. package/dist/types/src/components/SheetToolbar/SheetToolbar.d.ts.map +1 -1
  72. package/dist/types/src/components/SheetToolbar/SheetToolbar.stories.d.ts +1 -2
  73. package/dist/types/src/components/SheetToolbar/SheetToolbar.stories.d.ts.map +1 -1
  74. package/dist/types/src/extensions/compute.d.ts +1 -1
  75. package/dist/types/src/extensions/compute.d.ts.map +1 -1
  76. package/dist/types/src/extensions/compute.stories.d.ts +2 -3
  77. package/dist/types/src/extensions/compute.stories.d.ts.map +1 -1
  78. package/dist/types/src/integrations/thread-ranges.d.ts.map +1 -1
  79. package/dist/types/src/meta.d.ts +0 -1
  80. package/dist/types/src/meta.d.ts.map +1 -1
  81. package/dist/types/src/model/sheet-model.d.ts +5 -5
  82. package/dist/types/src/model/sheet-model.d.ts.map +1 -1
  83. package/dist/types/src/model/testing.d.ts +2 -2
  84. package/dist/types/src/model/testing.d.ts.map +1 -1
  85. package/dist/types/src/model/useSheetModel.d.ts +2 -2
  86. package/dist/types/src/model/useSheetModel.d.ts.map +1 -1
  87. package/dist/types/src/serializer.d.ts +2 -2
  88. package/dist/types/src/serializer.d.ts.map +1 -1
  89. package/dist/types/src/testing/data.d.ts +2 -2
  90. package/dist/types/src/testing/data.d.ts.map +1 -1
  91. package/dist/types/src/testing/testing.d.ts +27 -3
  92. package/dist/types/src/testing/testing.d.ts.map +1 -1
  93. package/dist/types/src/translations.d.ts +2 -2
  94. package/dist/types/src/translations.d.ts.map +1 -1
  95. package/dist/types/src/types/{schema.d.ts → Sheet.d.ts} +37 -4
  96. package/dist/types/src/types/Sheet.d.ts.map +1 -0
  97. package/dist/types/src/types/index.d.ts +1 -1
  98. package/dist/types/src/types/index.d.ts.map +1 -1
  99. package/dist/types/src/types/sheet-range-types.d.ts +2 -2
  100. package/dist/types/src/types/sheet-range-types.d.ts.map +1 -1
  101. package/dist/types/src/types/types.d.ts +7 -16
  102. package/dist/types/src/types/types.d.ts.map +1 -1
  103. package/dist/types/src/types/util.d.ts +9 -10
  104. package/dist/types/src/types/util.d.ts.map +1 -1
  105. package/dist/types/tsconfig.tsbuildinfo +1 -1
  106. package/package.json +63 -63
  107. package/src/SheetPlugin.tsx +70 -61
  108. package/src/capabilities/anchor-sort.ts +3 -3
  109. package/src/capabilities/capabilities.ts +2 -2
  110. package/src/capabilities/compute-graph-registry.ts +8 -13
  111. package/src/capabilities/intent-resolver.ts +4 -4
  112. package/src/capabilities/react-surface.tsx +7 -7
  113. package/src/components/ComputeGraph/compute-graph.stories.tsx +10 -12
  114. package/src/components/GridSheet/GridSheet.stories.tsx +12 -9
  115. package/src/components/GridSheet/GridSheet.tsx +6 -6
  116. package/src/components/GridSheet/SheetCellEditor.stories.tsx +14 -17
  117. package/src/components/RangeList/RangeList.tsx +8 -8
  118. package/src/components/SheetContainer/SheetContainer.stories.tsx +39 -41
  119. package/src/components/SheetContainer/SheetContainer.tsx +7 -3
  120. package/src/components/SheetContext/SheetContext.tsx +2 -2
  121. package/src/components/SheetToolbar/SheetToolbar.stories.tsx +9 -6
  122. package/src/components/SheetToolbar/SheetToolbar.tsx +4 -9
  123. package/src/components/SheetToolbar/align.ts +3 -3
  124. package/src/components/SheetToolbar/style.ts +2 -2
  125. package/src/extensions/compute.stories.tsx +16 -13
  126. package/src/extensions/compute.ts +1 -2
  127. package/src/integrations/thread-ranges.ts +7 -6
  128. package/src/meta.ts +7 -5
  129. package/src/model/sheet-model.test.ts +4 -4
  130. package/src/model/sheet-model.ts +4 -4
  131. package/src/model/testing.ts +4 -4
  132. package/src/model/useSheetModel.ts +2 -2
  133. package/src/sanity.test.ts +3 -4
  134. package/src/serializer.ts +3 -3
  135. package/src/testing/data.ts +2 -2
  136. package/src/testing/testing.tsx +11 -5
  137. package/src/translations.ts +2 -2
  138. package/src/types/Sheet.ts +103 -0
  139. package/src/types/index.ts +1 -1
  140. package/src/types/sheet-range-types.ts +2 -2
  141. package/src/types/types.ts +6 -16
  142. package/src/types/util.ts +10 -38
  143. package/dist/lib/browser/SheetContainer-CWSO5WTN.mjs.map +0 -7
  144. package/dist/lib/browser/anchor-sort-7WD2VGXW.mjs.map +0 -7
  145. package/dist/lib/browser/chunk-6AKBCBL4.mjs +0 -18
  146. package/dist/lib/browser/chunk-6AKBCBL4.mjs.map +0 -7
  147. package/dist/lib/browser/chunk-CL3MDNKQ.mjs.map +0 -7
  148. package/dist/lib/browser/chunk-KJWZUQVA.mjs.map +0 -7
  149. package/dist/lib/browser/chunk-Q3VBLCSM.mjs.map +0 -7
  150. package/dist/lib/browser/chunk-XSXUU6FO.mjs.map +0 -7
  151. package/dist/lib/browser/compute-graph-registry-6YJHXORG.mjs +0 -30
  152. package/dist/lib/browser/compute-graph-registry-6YJHXORG.mjs.map +0 -7
  153. package/dist/lib/browser/intent-resolver-ROEY4LHM.mjs.map +0 -7
  154. package/dist/lib/browser/react-surface-2ES3D7MJ.mjs.map +0 -7
  155. package/dist/lib/node-esm/SheetContainer-3RSDBWDG.mjs.map +0 -7
  156. package/dist/lib/node-esm/anchor-sort-ACQDUIPU.mjs.map +0 -7
  157. package/dist/lib/node-esm/chunk-3K5VNYOF.mjs +0 -20
  158. package/dist/lib/node-esm/chunk-3K5VNYOF.mjs.map +0 -7
  159. package/dist/lib/node-esm/chunk-6SK5LJ5S.mjs.map +0 -7
  160. package/dist/lib/node-esm/chunk-LUCRXSK6.mjs.map +0 -7
  161. package/dist/lib/node-esm/chunk-ODP4L4OV.mjs.map +0 -7
  162. package/dist/lib/node-esm/chunk-ZIQZU4CH.mjs.map +0 -7
  163. package/dist/lib/node-esm/compute-graph-registry-ET5KJNLV.mjs +0 -31
  164. package/dist/lib/node-esm/compute-graph-registry-ET5KJNLV.mjs.map +0 -7
  165. package/dist/lib/node-esm/intent-resolver-HESRI2ML.mjs.map +0 -7
  166. package/dist/lib/node-esm/react-surface-66VS5MY2.mjs.map +0 -7
  167. package/dist/types/src/types/schema.d.ts.map +0 -1
  168. package/src/types/schema.ts +0 -61
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dxos/plugin-sheet",
3
- "version": "0.8.4-main.5ea62a8",
3
+ "version": "0.8.4-main.ae835ea",
4
4
  "description": "Braneframe sketch plugin",
5
5
  "homepage": "https://dxos.org",
6
6
  "bugs": "https://github.com/dxos/dxos/issues",
@@ -35,10 +35,10 @@
35
35
  "src"
36
36
  ],
37
37
  "dependencies": {
38
- "@codemirror/autocomplete": "^6.18.1",
39
- "@codemirror/language": "^6.10.3",
40
- "@codemirror/state": "^6.4.1",
41
- "@codemirror/view": "^6.34.1",
38
+ "@codemirror/autocomplete": "^6.19.0",
39
+ "@codemirror/language": "^6.11.3",
40
+ "@codemirror/state": "^6.5.2",
41
+ "@codemirror/view": "^6.38.4",
42
42
  "@dnd-kit/core": "^6.0.5",
43
43
  "@dnd-kit/modifiers": "^6.0.0",
44
44
  "@dnd-kit/sortable": "^7.0.1",
@@ -48,81 +48,81 @@
48
48
  "@lezer/lezer": "^1.1.2",
49
49
  "@lezer/lr": "^1.4.2",
50
50
  "@preact-signals/safe-react": "^0.9.0",
51
- "@preact/signals-core": "^1.9.0",
51
+ "@preact/signals-core": "^1.12.1",
52
52
  "@radix-ui/react-context": "1.1.1",
53
53
  "codemirror-lang-spreadsheet": "^1.3.0",
54
54
  "date-fns": "^3.3.1",
55
55
  "lodash.defaultsdeep": "^4.6.1",
56
56
  "re-resizable": "^6.9.17",
57
- "react-markdown": "^8.0.5",
57
+ "react-markdown": "^10.1.0",
58
58
  "react-resize-detector": "^11.0.1",
59
- "@dxos/app-framework": "0.8.4-main.5ea62a8",
60
- "@dxos/client": "0.8.4-main.5ea62a8",
61
- "@dxos/async": "0.8.4-main.5ea62a8",
62
- "@dxos/compute": "0.8.4-main.5ea62a8",
63
- "@dxos/crypto": "0.8.4-main.5ea62a8",
64
- "@dxos/context": "0.8.4-main.5ea62a8",
65
- "@dxos/debug": "0.8.4-main.5ea62a8",
66
- "@dxos/echo": "0.8.4-main.5ea62a8",
67
- "@dxos/echo-schema": "0.8.4-main.5ea62a8",
68
- "@dxos/functions": "0.8.4-main.5ea62a8",
69
- "@dxos/invariant": "0.8.4-main.5ea62a8",
70
- "@dxos/lit-grid": "0.8.4-main.5ea62a8",
71
- "@dxos/live-object": "0.8.4-main.5ea62a8",
72
- "@dxos/log": "0.8.4-main.5ea62a8",
73
- "@dxos/plugin-attention": "0.8.4-main.5ea62a8",
74
- "@dxos/keys": "0.8.4-main.5ea62a8",
75
- "@dxos/plugin-deck": "0.8.4-main.5ea62a8",
76
- "@dxos/plugin-client": "0.8.4-main.5ea62a8",
77
- "@dxos/plugin-graph": "0.8.4-main.5ea62a8",
78
- "@dxos/plugin-markdown": "0.8.4-main.5ea62a8",
79
- "@dxos/plugin-space": "0.8.4-main.5ea62a8",
80
- "@dxos/plugin-script": "0.8.4-main.5ea62a8",
81
- "@dxos/plugin-stack": "0.8.4-main.5ea62a8",
82
- "@dxos/plugin-thread": "0.8.4-main.5ea62a8",
83
- "@dxos/react-client": "0.8.4-main.5ea62a8",
84
- "@dxos/react-hooks": "0.8.4-main.5ea62a8",
85
- "@dxos/react-ui-attention": "0.8.4-main.5ea62a8",
86
- "@dxos/react-ui-editor": "0.8.4-main.5ea62a8",
87
- "@dxos/react-ui-grid": "0.8.4-main.5ea62a8",
88
- "@dxos/react-ui-form": "0.8.4-main.5ea62a8",
89
- "@dxos/react-ui-list": "0.8.4-main.5ea62a8",
90
- "@dxos/react-ui-menu": "0.8.4-main.5ea62a8",
91
- "@dxos/react-ui-stack": "0.8.4-main.5ea62a8",
92
- "@dxos/util": "0.8.4-main.5ea62a8",
93
- "@dxos/schema": "0.8.4-main.5ea62a8"
59
+ "@dxos/app-framework": "0.8.4-main.ae835ea",
60
+ "@dxos/async": "0.8.4-main.ae835ea",
61
+ "@dxos/crypto": "0.8.4-main.ae835ea",
62
+ "@dxos/debug": "0.8.4-main.ae835ea",
63
+ "@dxos/context": "0.8.4-main.ae835ea",
64
+ "@dxos/client": "0.8.4-main.ae835ea",
65
+ "@dxos/echo": "0.8.4-main.ae835ea",
66
+ "@dxos/compute": "0.8.4-main.ae835ea",
67
+ "@dxos/functions": "0.8.4-main.ae835ea",
68
+ "@dxos/invariant": "0.8.4-main.ae835ea",
69
+ "@dxos/keys": "0.8.4-main.ae835ea",
70
+ "@dxos/live-object": "0.8.4-main.ae835ea",
71
+ "@dxos/log": "0.8.4-main.ae835ea",
72
+ "@dxos/lit-grid": "0.8.4-main.ae835ea",
73
+ "@dxos/plugin-attention": "0.8.4-main.ae835ea",
74
+ "@dxos/plugin-automation": "0.8.4-main.ae835ea",
75
+ "@dxos/plugin-deck": "0.8.4-main.ae835ea",
76
+ "@dxos/plugin-graph": "0.8.4-main.ae835ea",
77
+ "@dxos/plugin-markdown": "0.8.4-main.ae835ea",
78
+ "@dxos/plugin-client": "0.8.4-main.ae835ea",
79
+ "@dxos/plugin-script": "0.8.4-main.ae835ea",
80
+ "@dxos/plugin-space": "0.8.4-main.ae835ea",
81
+ "@dxos/plugin-stack": "0.8.4-main.ae835ea",
82
+ "@dxos/plugin-thread": "0.8.4-main.ae835ea",
83
+ "@dxos/react-client": "0.8.4-main.ae835ea",
84
+ "@dxos/react-hooks": "0.8.4-main.ae835ea",
85
+ "@dxos/react-ui-editor": "0.8.4-main.ae835ea",
86
+ "@dxos/react-ui-form": "0.8.4-main.ae835ea",
87
+ "@dxos/react-ui-menu": "0.8.4-main.ae835ea",
88
+ "@dxos/react-ui-grid": "0.8.4-main.ae835ea",
89
+ "@dxos/react-ui-list": "0.8.4-main.ae835ea",
90
+ "@dxos/react-ui-attention": "0.8.4-main.ae835ea",
91
+ "@dxos/react-ui-stack": "0.8.4-main.ae835ea",
92
+ "@dxos/schema": "0.8.4-main.ae835ea",
93
+ "@dxos/util": "0.8.4-main.ae835ea"
94
94
  },
95
95
  "devDependencies": {
96
- "@effect-rx/rx-react": "0.38.0",
97
- "@effect/platform": "0.90.2",
96
+ "@effect-rx/rx-react": "0.42.4",
97
+ "@effect/platform": "0.92.1",
98
98
  "@lezer/generator": "^1.7.1",
99
99
  "@tldraw/indices": "^2.0.0-alpha.14",
100
100
  "@types/lodash.defaultsdeep": "^4.6.6",
101
- "@types/react": "~18.2.0",
102
- "@types/react-dom": "~18.2.0",
101
+ "@types/react": "~19.2.2",
102
+ "@types/react-dom": "~19.2.2",
103
103
  "@types/react-window": "^1.8.8",
104
- "effect": "3.17.7",
105
- "react": "~18.2.0",
106
- "react-dom": "~18.2.0",
107
- "vite": "7.1.1",
108
- "@dxos/echo-generator": "0.8.4-main.5ea62a8",
109
- "@dxos/lit-grid": "0.8.4-main.5ea62a8",
110
- "@dxos/random": "0.8.4-main.5ea62a8",
111
- "@dxos/react-ui": "0.8.4-main.5ea62a8",
112
- "@dxos/react-ui-syntax-highlighter": "0.8.4-main.5ea62a8",
113
- "@dxos/react-ui-theme": "0.8.4-main.5ea62a8",
114
- "@dxos/react-ui-types": "0.8.4-main.5ea62a8",
115
- "@dxos/storybook-utils": "0.8.4-main.5ea62a8",
116
- "@dxos/test-utils": "0.8.4-main.5ea62a8"
104
+ "effect": "3.18.3",
105
+ "react": "~19.2.0",
106
+ "react-dom": "~19.2.0",
107
+ "vite": "7.1.9",
108
+ "@dxos/echo-generator": "0.8.4-main.ae835ea",
109
+ "@dxos/random": "0.8.4-main.ae835ea",
110
+ "@dxos/lit-grid": "0.8.4-main.ae835ea",
111
+ "@dxos/react-ui": "0.8.4-main.ae835ea",
112
+ "@dxos/react-ui-syntax-highlighter": "0.8.4-main.ae835ea",
113
+ "@dxos/react-ui-theme": "0.8.4-main.ae835ea",
114
+ "@dxos/react-ui-types": "0.8.4-main.ae835ea",
115
+ "@dxos/storybook-utils": "0.8.4-main.ae835ea",
116
+ "@dxos/test-utils": "0.8.4-main.ae835ea"
117
117
  },
118
118
  "peerDependencies": {
119
119
  "@effect-rx/rx-react": "^0.34.1",
120
120
  "@effect/platform": "^0.80.12",
121
121
  "effect": "^3.13.3",
122
- "react": "~18.2.0",
123
- "react-dom": "~18.2.0",
124
- "@dxos/react-ui": "0.8.4-main.5ea62a8",
125
- "@dxos/react-ui-theme": "0.8.4-main.5ea62a8"
122
+ "react": "^19.0.0",
123
+ "react-dom": "^19.0.0",
124
+ "@dxos/react-ui": "0.8.4-main.ae835ea",
125
+ "@dxos/react-ui-theme": "0.8.4-main.ae835ea"
126
126
  },
127
127
  "publishConfig": {
128
128
  "access": "public"
@@ -2,7 +2,16 @@
2
2
  // Copyright 2023 DXOS.org
3
3
  //
4
4
 
5
- import { Capabilities, Events, contributes, createIntent, defineModule, definePlugin } from '@dxos/app-framework';
5
+ import {
6
+ Capabilities,
7
+ Events,
8
+ allOf,
9
+ contributes,
10
+ createIntent,
11
+ defineModule,
12
+ definePlugin,
13
+ } from '@dxos/app-framework';
14
+ import { AutomationEvents } from '@dxos/plugin-automation';
6
15
  import { ClientEvents } from '@dxos/plugin-client';
7
16
  import { MarkdownEvents } from '@dxos/plugin-markdown';
8
17
  import { SpaceCapabilities } from '@dxos/plugin-space';
@@ -12,65 +21,65 @@ import { AnchorSort, ComputeGraphRegistry, IntentResolver, Markdown, ReactSurfac
12
21
  import { meta } from './meta';
13
22
  import { serializer } from './serializer';
14
23
  import { translations } from './translations';
15
- import { SheetAction, SheetType } from './types';
24
+ import { Sheet, SheetAction } from './types';
16
25
 
17
- export const SheetPlugin = () =>
18
- definePlugin(meta, [
19
- defineModule({
20
- id: `${meta.id}/module/compute-graph-registry`,
21
- activatesOn: ClientEvents.ClientReady,
22
- activate: ComputeGraphRegistry,
23
- }),
24
- defineModule({
25
- id: `${meta.id}/module/translations`,
26
- activatesOn: Events.SetupTranslations,
27
- activate: () => contributes(Capabilities.Translations, translations),
28
- }),
29
- defineModule({
30
- id: `${meta.id}/module/metadata`,
31
- activatesOn: Events.SetupMetadata,
32
- activate: () =>
33
- contributes(Capabilities.Metadata, {
34
- id: SheetType.typename,
35
- metadata: {
36
- label: (object: SheetType) => object.name,
37
- icon: 'ph--grid-nine--regular',
38
- serializer,
39
- comments: 'anchored',
40
- },
26
+ export const SheetPlugin = definePlugin(meta, () => [
27
+ defineModule({
28
+ id: `${meta.id}/module/compute-graph-registry`,
29
+ activatesOn: allOf(ClientEvents.ClientReady, AutomationEvents.ComputeRuntimeReady),
30
+ activate: ComputeGraphRegistry,
31
+ }),
32
+ defineModule({
33
+ id: `${meta.id}/module/translations`,
34
+ activatesOn: Events.SetupTranslations,
35
+ activate: () => contributes(Capabilities.Translations, translations),
36
+ }),
37
+ defineModule({
38
+ id: `${meta.id}/module/metadata`,
39
+ activatesOn: Events.SetupMetadata,
40
+ activate: () =>
41
+ contributes(Capabilities.Metadata, {
42
+ id: Sheet.Sheet.typename,
43
+ metadata: {
44
+ label: (object: Sheet.Sheet) => object.name,
45
+ icon: 'ph--grid-nine--regular',
46
+ iconHue: 'indigo',
47
+ serializer,
48
+ comments: 'anchored',
49
+ },
50
+ }),
51
+ }),
52
+ defineModule({
53
+ id: `${meta.id}/module/object-form`,
54
+ activatesOn: ClientEvents.SetupSchema,
55
+ activate: () =>
56
+ contributes(
57
+ SpaceCapabilities.ObjectForm,
58
+ defineObjectForm({
59
+ objectSchema: Sheet.Sheet,
60
+ getIntent: (props) => createIntent(SheetAction.Create, { ...props }),
41
61
  }),
42
- }),
43
- defineModule({
44
- id: `${meta.id}/module/object-form`,
45
- activatesOn: ClientEvents.SetupSchema,
46
- activate: () =>
47
- contributes(
48
- SpaceCapabilities.ObjectForm,
49
- defineObjectForm({
50
- objectSchema: SheetType,
51
- getIntent: (props, options) => createIntent(SheetAction.Create, { ...props, space: options.space }),
52
- }),
53
- ),
54
- }),
55
- defineModule({
56
- id: `${meta.id}/module/markdown`,
57
- activatesOn: MarkdownEvents.SetupExtensions,
58
- activate: Markdown,
59
- }),
60
- defineModule({
61
- id: `${meta.id}/module/anchor-sort`,
62
- // TODO(wittjosiah): More relevant event?
63
- activatesOn: Events.AppGraphReady,
64
- activate: AnchorSort,
65
- }),
66
- defineModule({
67
- id: `${meta.id}/module/react-surface`,
68
- activatesOn: Events.SetupReactSurface,
69
- activate: ReactSurface,
70
- }),
71
- defineModule({
72
- id: `${meta.id}/module/intent-resolver`,
73
- activatesOn: Events.SetupIntentResolver,
74
- activate: IntentResolver,
75
- }),
76
- ]);
62
+ ),
63
+ }),
64
+ defineModule({
65
+ id: `${meta.id}/module/markdown`,
66
+ activatesOn: MarkdownEvents.SetupExtensions,
67
+ activate: Markdown,
68
+ }),
69
+ defineModule({
70
+ id: `${meta.id}/module/anchor-sort`,
71
+ // TODO(wittjosiah): More relevant event?
72
+ activatesOn: Events.AppGraphReady,
73
+ activate: AnchorSort,
74
+ }),
75
+ defineModule({
76
+ id: `${meta.id}/module/react-surface`,
77
+ activatesOn: Events.SetupReactSurface,
78
+ activate: ReactSurface,
79
+ }),
80
+ defineModule({
81
+ id: `${meta.id}/module/intent-resolver`,
82
+ activatesOn: Events.SetupIntentResolver,
83
+ activate: IntentResolver,
84
+ }),
85
+ ]);
@@ -6,13 +6,13 @@ import { Capabilities, contributes } from '@dxos/app-framework';
6
6
  import { Type } from '@dxos/echo';
7
7
  import { getTarget } from '@dxos/react-client/echo';
8
8
 
9
- import { SheetType, compareIndexPositions } from '../types';
9
+ import { Sheet, compareIndexPositions } from '../types';
10
10
 
11
11
  export default () =>
12
12
  contributes(Capabilities.AnchorSort, {
13
- key: Type.getTypename(SheetType)!,
13
+ key: Type.getTypename(Sheet.Sheet)!,
14
14
  sort: (anchorA, anchorB) => {
15
- const sheet = getTarget(anchorA) as SheetType;
15
+ const sheet = getTarget(anchorA) as Sheet.Sheet;
16
16
  if (sheet !== getTarget(anchorB)) {
17
17
  return 0;
18
18
  }
@@ -5,10 +5,10 @@
5
5
  import { defineCapability } from '@dxos/app-framework';
6
6
  import { type ComputeGraphRegistry } from '@dxos/compute';
7
7
 
8
- import { SHEET_PLUGIN } from '../meta';
8
+ import { meta } from '../meta';
9
9
 
10
10
  export namespace SheetCapabilities {
11
11
  export const ComputeGraphRegistry = defineCapability<ComputeGraphRegistry>(
12
- `${SHEET_PLUGIN}/capability/compute-graph-registry`,
12
+ `${meta.id}/capability/compute-graph-registry`,
13
13
  );
14
14
  }
@@ -3,26 +3,21 @@
3
3
  //
4
4
 
5
5
  import { type PluginContext, contributes } from '@dxos/app-framework';
6
- import { ClientCapabilities } from '@dxos/plugin-client';
6
+ import { AutomationCapabilities } from '@dxos/plugin-automation';
7
7
 
8
8
  import { SheetCapabilities } from './capabilities';
9
9
 
10
- const isSecure = (protocol: string) => {
11
- return protocol === 'https:' || protocol === 'wss:';
12
- };
10
+ // Locally declare the Automation ComputeRuntime capability by ID to avoid direct import dependency.
13
11
 
14
12
  export default async (context: PluginContext) => {
15
- const client = context.getCapability(ClientCapabilities.Client);
16
- let remoteFunctionUrl: string | undefined;
17
- if (client.config.values.runtime?.services?.edge?.url) {
18
- const url = new URL('/functions', client.config.values.runtime?.services?.edge?.url);
19
- url.protocol = isSecure(url.protocol) ? 'https' : 'http';
20
- remoteFunctionUrl = url.toString();
21
- }
22
-
23
13
  // TODO(wittjosiah): This can probably be a module level import now due to lazy capability loading.
24
14
  // Async import removes direct dependency on hyperformula.
25
15
  const { defaultPlugins, ComputeGraphRegistry } = await import('@dxos/compute');
26
- const computeGraphRegistry = new ComputeGraphRegistry({ plugins: defaultPlugins, remoteFunctionUrl });
16
+ const computeRuntimeResolver = context.getCapability(AutomationCapabilities.ComputeRuntime);
17
+ const computeGraphRegistry = new ComputeGraphRegistry({
18
+ plugins: defaultPlugins,
19
+ computeRuntime: computeRuntimeResolver,
20
+ });
21
+
27
22
  return contributes(SheetCapabilities.ComputeGraphRegistry, computeGraphRegistry);
28
23
  };
@@ -4,14 +4,14 @@
4
4
 
5
5
  import { Capabilities, contributes, createResolver } from '@dxos/app-framework';
6
6
 
7
- import { SHEET_PLUGIN } from '../meta';
8
- import { SheetAction, createSheet } from '../types';
7
+ import { meta } from '../meta';
8
+ import { Sheet, SheetAction } from '../types';
9
9
 
10
10
  export default () =>
11
11
  contributes(Capabilities.IntentResolver, [
12
12
  createResolver({
13
13
  intent: SheetAction.Create,
14
- resolve: ({ name }) => ({ data: { object: createSheet({ name }) } }),
14
+ resolve: ({ name }) => ({ data: { object: Sheet.make({ name }) } }),
15
15
  }),
16
16
  createResolver({
17
17
  intent: SheetAction.InsertAxis,
@@ -26,7 +26,7 @@ export default () =>
26
26
  const undoData = model[axis === 'col' ? 'dropColumn' : 'dropRow'](axisIndex);
27
27
  return {
28
28
  undoable: {
29
- message: [`${axis} dropped label`, { ns: SHEET_PLUGIN }],
29
+ message: [`${axis} dropped label`, { ns: meta.id }],
30
30
  data: { ...undoData, model },
31
31
  },
32
32
  };
@@ -9,18 +9,18 @@ import { Obj } from '@dxos/echo';
9
9
  import { getSpace } from '@dxos/react-client/echo';
10
10
 
11
11
  import { ComputeGraphContextProvider, RangeList, SheetContainer } from '../components';
12
- import { SHEET_PLUGIN } from '../meta';
13
- import { SheetType } from '../types';
12
+ import { meta } from '../meta';
13
+ import { Sheet } from '../types';
14
14
 
15
15
  import { SheetCapabilities } from './capabilities';
16
16
 
17
17
  export default () =>
18
18
  contributes(Capabilities.ReactSurface, [
19
19
  createSurface({
20
- id: `${SHEET_PLUGIN}/sheet`,
20
+ id: `${meta.id}/sheet`,
21
21
  role: ['article', 'section'],
22
- filter: (data): data is { subject: SheetType } =>
23
- Obj.instanceOf(SheetType, data.subject) && !!getSpace(data.subject),
22
+ filter: (data): data is { subject: Sheet.Sheet } =>
23
+ Obj.instanceOf(Sheet.Sheet, data.subject) && !!getSpace(data.subject),
24
24
  component: ({ data, role }) => {
25
25
  const computeGraphRegistry = useCapability(SheetCapabilities.ComputeGraphRegistry);
26
26
 
@@ -32,9 +32,9 @@ export default () =>
32
32
  },
33
33
  }),
34
34
  createSurface({
35
- id: `${SHEET_PLUGIN}/object-settings`,
35
+ id: `${meta.id}/object-settings`,
36
36
  role: 'object-settings',
37
- filter: (data): data is { subject: SheetType } => Obj.instanceOf(SheetType, data.subject),
37
+ filter: (data): data is { subject: Sheet.Sheet } => Obj.instanceOf(Sheet.Sheet, data.subject),
38
38
  component: ({ data }) => <RangeList sheet={data.subject} />,
39
39
  }),
40
40
  ]);
@@ -2,23 +2,21 @@
2
2
  // Copyright 2024 DXOS.org
3
3
  //
4
4
 
5
- import '@dxos-theme';
6
-
7
5
  import { type Meta, type StoryObj } from '@storybook/react-vite';
8
6
  import React, { useEffect, useRef, useState } from 'react';
9
7
 
10
8
  import { testFunctionPlugins } from '@dxos/compute/testing';
11
- import { Filter, Obj } from '@dxos/echo';
12
- import { FunctionType } from '@dxos/functions';
9
+ import { Filter } from '@dxos/echo';
10
+ import { Function } from '@dxos/functions';
13
11
  import { useSpace } from '@dxos/react-client/echo';
14
12
  import { withClientProvider } from '@dxos/react-client/testing';
15
13
  import { Button, Input, Toolbar } from '@dxos/react-ui';
14
+ import { withTheme } from '@dxos/react-ui/testing';
16
15
  import { SyntaxHighlighter } from '@dxos/react-ui-syntax-highlighter';
17
- import { withTheme } from '@dxos/storybook-utils';
18
16
 
19
17
  import { useSheetModel } from '../../model';
20
18
  import { withComputeGraphDecorator } from '../../testing';
21
- import { SheetType, createSheet } from '../../types';
19
+ import { Sheet } from '../../types';
22
20
 
23
21
  import { useComputeGraph } from './ComputeGraphContextProvider';
24
22
 
@@ -27,13 +25,13 @@ const FUNCTION_NAME = 'TEST';
27
25
  const DefaultStory = () => {
28
26
  const space = useSpace();
29
27
  const graph = useComputeGraph(space);
30
- const [sheet, setSheet] = useState<SheetType>();
28
+ const [sheet, setSheet] = useState<Sheet.Sheet>();
31
29
  const [text, setText] = useState(`${FUNCTION_NAME}(100)`);
32
30
  const [result, setResult] = useState<any>();
33
31
  const model = useSheetModel(graph, sheet);
34
32
  useEffect(() => {
35
33
  if (space) {
36
- const sheet = space.db.add(createSheet());
34
+ const sheet = space.db.add(Sheet.make());
37
35
  setSheet(sheet);
38
36
  }
39
37
  }, [space]);
@@ -46,14 +44,14 @@ const DefaultStory = () => {
46
44
  setResult({ functions: { standard: f1.length, echo: f2.length } });
47
45
  });
48
46
 
49
- space.db.add(Obj.make(FunctionType, { name: 'test', version: '0.0.1', binding: FUNCTION_NAME }));
47
+ space.db.add(Function.make({ name: 'test', version: '0.0.1', binding: FUNCTION_NAME }));
50
48
  }
51
49
  }, [space, graph]);
52
50
 
53
51
  const inputRef = useRef<HTMLInputElement | null>(null);
54
52
  const handleTest = async () => {
55
53
  if (space && graph) {
56
- const { objects } = await space.db.query(Filter.type(FunctionType)).run();
54
+ const { objects } = await space.db.query(Filter.type(Function.Function)).run();
57
55
  const mapped = graph.mapFunctionBindingToId(text);
58
56
  const unmapped = graph.mapFunctionBindingFromId(mapped);
59
57
  const internal = graph.mapFormulaToNative(text);
@@ -89,9 +87,9 @@ const meta = {
89
87
  title: 'plugins/plugin-sheet/functions',
90
88
  render: DefaultStory,
91
89
  decorators: [
92
- withClientProvider({ types: [FunctionType, SheetType], createIdentity: true, createSpace: true }),
93
- withComputeGraphDecorator({ plugins: testFunctionPlugins }),
94
90
  withTheme,
91
+ withClientProvider({ types: [Function.Function, Sheet.Sheet], createIdentity: true, createSpace: true }),
92
+ withComputeGraphDecorator({ plugins: testFunctionPlugins }),
95
93
  ],
96
94
  } satisfies Meta<typeof DefaultStory>;
97
95
 
@@ -2,20 +2,19 @@
2
2
  // Copyright 2024 DXOS.org
3
3
  //
4
4
 
5
- import '@dxos-theme';
6
-
7
5
  import { type Meta, type StoryObj } from '@storybook/react-vite';
8
6
  import React from 'react';
9
7
 
10
8
  import { IntentPlugin } from '@dxos/app-framework';
11
9
  import { withPluginManager } from '@dxos/app-framework/testing';
10
+ import { testFunctionPlugins } from '@dxos/compute/testing';
12
11
  import { useSpace } from '@dxos/react-client/echo';
13
12
  import { withClientProvider } from '@dxos/react-client/testing';
14
- import { withLayout, withTheme } from '@dxos/storybook-utils';
13
+ import { withTheme } from '@dxos/react-ui/testing';
15
14
 
16
15
  import { createTestCells, useTestSheet, withComputeGraphDecorator } from '../../testing';
17
16
  import { translations } from '../../translations';
18
- import { SheetType } from '../../types';
17
+ import { Sheet } from '../../types';
19
18
  import { useComputeGraph } from '../ComputeGraph';
20
19
  import { SheetProvider } from '../SheetContext';
21
20
 
@@ -31,7 +30,9 @@ export const Basic = () => {
31
30
 
32
31
  return (
33
32
  <SheetProvider graph={graph} sheet={sheet} ignoreAttention>
34
- <GridSheet />
33
+ <div role='none' className='grid bs-full is-full'>
34
+ <GridSheet />
35
+ </div>
35
36
  </SheetProvider>
36
37
  );
37
38
  };
@@ -40,15 +41,17 @@ const meta = {
40
41
  title: 'plugins/plugin-sheet/GridSheet',
41
42
  component: GridSheet,
42
43
  decorators: [
43
- withClientProvider({ types: [SheetType], createSpace: true }),
44
- withComputeGraphDecorator(),
45
44
  withTheme,
46
- withLayout({ fullscreen: true, classNames: 'grid' }),
45
+ withClientProvider({ types: [Sheet.Sheet], createSpace: true }),
46
+ withComputeGraphDecorator({ plugins: testFunctionPlugins }),
47
47
  withPluginManager({
48
48
  plugins: [IntentPlugin()],
49
49
  }),
50
50
  ],
51
- parameters: { translations },
51
+ parameters: {
52
+ layout: 'fullscreen',
53
+ translations,
54
+ },
52
55
  } satisfies Meta<typeof GridSheet>;
53
56
 
54
57
  export default meta;
@@ -34,7 +34,7 @@ import {
34
34
 
35
35
  import { type RangeController, rangeExtension, sheetExtension } from '../../extensions';
36
36
  import { useSelectThreadOnCellFocus, useUpdateFocusedCellOnThreadSelection } from '../../integrations';
37
- import { SHEET_PLUGIN } from '../../meta';
37
+ import { meta } from '../../meta';
38
38
  import { DEFAULT_COLS, DEFAULT_ROWS, SheetAction } from '../../types';
39
39
  import { useSheetContext } from '../SheetContext';
40
40
 
@@ -69,7 +69,7 @@ const sheetRowDefault = {
69
69
  };
70
70
 
71
71
  export const GridSheet = () => {
72
- const { t } = useTranslation(SHEET_PLUGIN);
72
+ const { t } = useTranslation(meta.id);
73
73
  const { id, model, editing, setCursor, setRange, cursor, cursorFallbackRange, activeRefs, ignoreAttention } =
74
74
  useSheetContext();
75
75
  // NOTE(thure): using `useState` instead of `useRef` works with refs provided by `@lit/react` and gives us
@@ -77,7 +77,7 @@ export const GridSheet = () => {
77
77
  const [dxGrid, setDxGrid] = useState<DxGridElement | null>(null);
78
78
  const [extraplanarFocus, setExtraplanarFocus] = useState<DxGridPosition | null>(null);
79
79
  const { dispatchPromise: dispatch } = useIntentDispatcher();
80
- const rangeController = useRef<RangeController>();
80
+ const rangeController = useRef<RangeController>(null);
81
81
  const { hasAttention } = useAttention(id);
82
82
 
83
83
  const handleFocus = useCallback(
@@ -279,7 +279,7 @@ export const GridSheet = () => {
279
279
 
280
280
  const { columns, rows } = useSheetModelDxGridProps(dxGrid, model);
281
281
 
282
- const extension = useMemo(
282
+ const extensions = useMemo(
283
283
  () => [
284
284
  editorKeys({ onClose: handleClose, ...(editing?.initialContent && { onNav: handleClose }) }),
285
285
  sheetExtension({ functions: model.graph.getFunctions() }),
@@ -308,8 +308,8 @@ export const GridSheet = () => {
308
308
 
309
309
  return (
310
310
  // TODO(thure): Why are Table’s and Sheet’s editor boxes off by 1px?
311
- <div role='none' className='relative min-bs-0 [&_.cm-editor]:!border-lb [&_.cm-editor]:!border-transparent '>
312
- <GridCellEditor getCellContent={getCellContent} extension={extension} onBlur={handleBlur} />
311
+ <div role='none' className='relative min-bs-0 [&_.cm-editor]:!border-lb [&_.cm-editor]:!border-transparent'>
312
+ <GridCellEditor getCellContent={getCellContent} extensions={extensions} onBlur={handleBlur} />
313
313
  <Grid.Content
314
314
  initialCells={initialCells}
315
315
  limitColumns={DEFAULT_COLS}