@dxos/react-ui-editor 0.3.11-next.ee2b64c → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (25) hide show
  1. package/dist/lib/browser/index.mjs +1178 -159
  2. package/dist/lib/browser/index.mjs.map +3 -3
  3. package/dist/lib/browser/meta.json +1 -1
  4. package/dist/types/src/components/TextEditor/MarkdownEditor.stories.d.ts.map +1 -1
  5. package/dist/types/src/components/TextEditor/hooks.stories.d.ts.map +1 -1
  6. package/dist/types/src/components/Toolbar/Toolbar.d.ts +8 -4
  7. package/dist/types/src/components/Toolbar/Toolbar.d.ts.map +1 -1
  8. package/dist/types/src/components/Toolbar/Toolbar.stories.d.ts +5 -3
  9. package/dist/types/src/components/Toolbar/Toolbar.stories.d.ts.map +1 -1
  10. package/dist/types/src/extensions/comments.d.ts +5 -1
  11. package/dist/types/src/extensions/comments.d.ts.map +1 -1
  12. package/dist/types/src/extensions/markdown/formatting.d.ts +55 -10
  13. package/dist/types/src/extensions/markdown/formatting.d.ts.map +1 -1
  14. package/dist/types/src/extensions/markdown/formatting.test.d.ts +3 -0
  15. package/dist/types/src/extensions/markdown/formatting.test.d.ts.map +1 -0
  16. package/dist/types/src/hooks/useActionHandler.d.ts.map +1 -1
  17. package/package.json +24 -24
  18. package/src/components/TextEditor/MarkdownEditor.stories.tsx +3 -3
  19. package/src/components/TextEditor/hooks.stories.tsx +6 -1
  20. package/src/components/Toolbar/Toolbar.stories.tsx +16 -4
  21. package/src/components/Toolbar/Toolbar.tsx +128 -30
  22. package/src/extensions/comments.ts +2 -2
  23. package/src/extensions/markdown/formatting.test.ts +482 -0
  24. package/src/extensions/markdown/formatting.ts +1118 -69
  25. package/src/hooks/useActionHandler.ts +47 -16
@@ -1 +1 @@
1
- {"inputs":{"packages/ui/react-ui-editor/src/extensions/autocomplete.ts":{"bytes":5653,"imports":[{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/lang-markdown","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/cursor.ts":{"bytes":4504,"imports":[{"path":"lodash.get","kind":"import-statement","external":true},{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/defs.ts":{"bytes":3775,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/update-automerge.ts":{"bytes":5383,"imports":[{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/update-codemirror.ts":{"bytes":11386,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/defs.ts","kind":"import-statement","original":"./defs"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/semaphore.ts":{"bytes":9174,"imports":[{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/defs.ts","kind":"import-statement","original":"./defs"},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/update-automerge.ts","kind":"import-statement","original":"./update-automerge"},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/update-codemirror.ts","kind":"import-statement","original":"./update-codemirror"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/cursor.ts":{"bytes":5036,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/automerge.ts":{"bytes":10456,"imports":[{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/cursor.ts","kind":"import-statement","original":"./cursor"},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/defs.ts","kind":"import-statement","original":"./defs"},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/semaphore.ts","kind":"import-statement","original":"./semaphore"},{"path":"packages/ui/react-ui-editor/src/extensions/cursor.ts","kind":"import-statement","original":"../cursor"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/index.ts":{"bytes":605,"imports":[{"path":"packages/ui/react-ui-editor/src/extensions/automerge/automerge.ts","kind":"import-statement","original":"./automerge"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/awareness.ts":{"bytes":30390,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/context","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/cursor.ts","kind":"import-statement","original":"./cursor"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/basic.ts":{"bytes":4195,"imports":[{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/theme-one-dark","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/blast.ts":{"bytes":39556,"imports":[{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"lodash.defaultsdeep","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/styles/cursors.ts":{"bytes":2633,"imports":[{"path":"lib0/random","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/styles/markdown.ts":{"bytes":6664,"imports":[{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/styles/tokens.ts":{"bytes":1697,"imports":[{"path":"lodash.get","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/styles/index.ts":{"bytes":643,"imports":[{"path":"packages/ui/react-ui-editor/src/styles/cursors.ts","kind":"import-statement","original":"./cursors"},{"path":"packages/ui/react-ui-editor/src/styles/markdown.ts","kind":"import-statement","original":"./markdown"},{"path":"packages/ui/react-ui-editor/src/styles/tokens.ts","kind":"import-statement","original":"./tokens"}],"format":"esm"},"packages/ui/react-ui-editor/src/util.ts":{"bytes":3789,"imports":[{"path":"@dxos/log","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/comments.ts":{"bytes":50414,"imports":[{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"lodash.sortby","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/cursor.ts","kind":"import-statement","original":"./cursor"},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../styles"},{"path":"packages/ui/react-ui-editor/src/util.ts","kind":"import-statement","original":"../util"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/listener.ts":{"bytes":2475,"imports":[{"path":"@codemirror/view","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/highlight.ts":{"bytes":18853,"imports":[{"path":"@codemirror/lang-markdown","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@lezer/highlight","kind":"import-statement","external":true},{"path":"@lezer/markdown","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../../styles"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/bundle.ts":{"bytes":10718,"imports":[{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/lang-markdown","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/language-data","kind":"import-statement","external":true},{"path":"@codemirror/search","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/theme-one-dark","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/highlight.ts","kind":"import-statement","original":"./highlight"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/code.ts":{"bytes":14440,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../../styles"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/formatting.ts":{"bytes":17490,"imports":[{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/heading.ts":{"bytes":6054,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/hr.ts":{"bytes":6885,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../../styles"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/image.ts":{"bytes":10625,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/link.ts":{"bytes":21976,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/table.ts":{"bytes":13558,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/tasklist.ts":{"bytes":11918,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../../styles"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/index.ts":{"bytes":1235,"imports":[{"path":"packages/ui/react-ui-editor/src/extensions/markdown/bundle.ts","kind":"import-statement","original":"./bundle"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/code.ts","kind":"import-statement","original":"./code"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/formatting.ts","kind":"import-statement","original":"./formatting"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/heading.ts","kind":"import-statement","original":"./heading"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/highlight.ts","kind":"import-statement","original":"./highlight"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/hr.ts","kind":"import-statement","original":"./hr"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/image.ts","kind":"import-statement","original":"./image"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/link.ts","kind":"import-statement","original":"./link"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/table.ts","kind":"import-statement","original":"./table"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/tasklist.ts","kind":"import-statement","original":"./tasklist"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/mention.ts":{"bytes":3969,"imports":[{"path":"@codemirror/autocomplete","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/outliner.ts":{"bytes":1051,"imports":[],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/typewriter.ts":{"bytes":6277,"imports":[{"path":"@codemirror/view","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/index.ts":{"bytes":1449,"imports":[{"path":"packages/ui/react-ui-editor/src/extensions/autocomplete.ts","kind":"import-statement","original":"./autocomplete"},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/index.ts","kind":"import-statement","original":"./automerge"},{"path":"packages/ui/react-ui-editor/src/extensions/awareness.ts","kind":"import-statement","original":"./awareness"},{"path":"packages/ui/react-ui-editor/src/extensions/basic.ts","kind":"import-statement","original":"./basic"},{"path":"packages/ui/react-ui-editor/src/extensions/blast.ts","kind":"import-statement","original":"./blast"},{"path":"packages/ui/react-ui-editor/src/extensions/comments.ts","kind":"import-statement","original":"./comments"},{"path":"packages/ui/react-ui-editor/src/extensions/cursor.ts","kind":"import-statement","original":"./cursor"},{"path":"packages/ui/react-ui-editor/src/extensions/listener.ts","kind":"import-statement","original":"./listener"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/index.ts","kind":"import-statement","original":"./markdown"},{"path":"packages/ui/react-ui-editor/src/extensions/mention.ts","kind":"import-statement","original":"./mention"},{"path":"packages/ui/react-ui-editor/src/extensions/outliner.ts","kind":"import-statement","original":"./outliner"},{"path":"packages/ui/react-ui-editor/src/extensions/typewriter.ts","kind":"import-statement","original":"./typewriter"}],"format":"esm"},"packages/ui/react-ui-editor/src/themes/default.ts":{"bytes":23362,"imports":[{"path":"lodash.get","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../styles"}],"format":"esm"},"packages/ui/react-ui-editor/src/themes/index.ts":{"bytes":473,"imports":[{"path":"packages/ui/react-ui-editor/src/themes/default.ts","kind":"import-statement","original":"./default"}],"format":"esm"},"packages/ui/react-ui-editor/src/components/TextEditor/TextEditor.tsx":{"bytes":25851,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@replit/codemirror-vim","kind":"import-statement","external":true},{"path":"lodash.defaultsdeep","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/index.ts","kind":"import-statement","original":"../../extensions"},{"path":"packages/ui/react-ui-editor/src/themes/index.ts","kind":"import-statement","original":"../../themes"},{"path":"packages/ui/react-ui-editor/src/util.ts","kind":"import-statement","original":"../../util"}],"format":"esm"},"packages/ui/react-ui-editor/src/components/TextEditor/index.ts":{"bytes":712,"imports":[{"path":"@lezer/highlight","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/components/TextEditor/TextEditor.tsx","kind":"import-statement","original":"./TextEditor"}],"format":"esm"},"packages/ui/react-ui-editor/src/components/Toolbar/Toolbar.tsx":{"bytes":17145,"imports":[{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/components/Toolbar/index.ts":{"bytes":485,"imports":[{"path":"packages/ui/react-ui-editor/src/components/Toolbar/Toolbar.tsx","kind":"import-statement","original":"./Toolbar"}],"format":"esm"},"packages/ui/react-ui-editor/src/components/index.ts":{"bytes":571,"imports":[{"path":"packages/ui/react-ui-editor/src/components/TextEditor/index.ts","kind":"import-statement","original":"./TextEditor"},{"path":"packages/ui/react-ui-editor/src/components/Toolbar/index.ts","kind":"import-statement","original":"./Toolbar"}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/awareness-provider.ts":{"bytes":10990,"imports":[{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/context","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/defs.ts":{"bytes":1902,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/useActionHandler.ts":{"bytes":4443,"imports":[{"path":"packages/ui/react-ui-editor/src/extensions/index.ts","kind":"import-statement","original":"../extensions"}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/useEditorView.ts":{"bytes":2025,"imports":[{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/useTextEditor.ts":{"bytes":13694,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/themes/index.ts","kind":"import-statement","original":"../themes"},{"path":"packages/ui/react-ui-editor/src/util.ts","kind":"import-statement","original":"../util"}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/useTextModel.ts":{"bytes":9406,"imports":[{"path":"lodash.get","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/display-name","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/hooks/awareness-provider.ts","kind":"import-statement","original":"./awareness-provider"},{"path":"packages/ui/react-ui-editor/src/hooks/defs.ts","kind":"import-statement","original":"./defs"},{"path":"packages/ui/react-ui-editor/src/extensions/index.ts","kind":"import-statement","original":"../extensions"},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../styles"}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/index.ts":{"bytes":997,"imports":[{"path":"packages/ui/react-ui-editor/src/hooks/awareness-provider.ts","kind":"import-statement","original":"./awareness-provider"},{"path":"packages/ui/react-ui-editor/src/hooks/defs.ts","kind":"import-statement","original":"./defs"},{"path":"packages/ui/react-ui-editor/src/hooks/useActionHandler.ts","kind":"import-statement","original":"./useActionHandler"},{"path":"packages/ui/react-ui-editor/src/hooks/useEditorView.ts","kind":"import-statement","original":"./useEditorView"},{"path":"packages/ui/react-ui-editor/src/hooks/useTextEditor.ts","kind":"import-statement","original":"./useTextEditor"},{"path":"packages/ui/react-ui-editor/src/hooks/useTextModel.ts","kind":"import-statement","original":"./useTextModel"}],"format":"esm"},"packages/ui/react-ui-editor/src/index.ts":{"bytes":1666,"imports":[{"path":"@dxos/protocols/proto/dxos/echo/model/text","kind":"import-statement","external":true},{"path":"@dxos/text-model","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"packages/ui/react-ui-editor/src/extensions/index.ts","kind":"import-statement","original":"./extensions"},{"path":"packages/ui/react-ui-editor/src/hooks/index.ts","kind":"import-statement","original":"./hooks"},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"./styles"},{"path":"packages/ui/react-ui-editor/src/themes/index.ts","kind":"import-statement","original":"./themes"},{"path":"packages/ui/react-ui-editor/src/util.ts","kind":"import-statement","original":"./util"}],"format":"esm"}},"outputs":{"packages/ui/react-ui-editor/dist/lib/browser/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":225964},"packages/ui/react-ui-editor/dist/lib/browser/index.mjs":{"imports":[{"path":"@dxos/protocols/proto/dxos/echo/model/text","kind":"import-statement","external":true},{"path":"@dxos/text-model","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@lezer/highlight","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@replit/codemirror-vim","kind":"import-statement","external":true},{"path":"lodash.defaultsdeep","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/lang-markdown","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true},{"path":"lodash.get","kind":"import-statement","external":true},{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true},{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/context","kind":"import-statement","external":true},{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/theme-one-dark","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"lodash.defaultsdeep","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"lodash.sortby","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"lib0/random","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"lodash.get","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/lang-markdown","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/language-data","kind":"import-statement","external":true},{"path":"@codemirror/search","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/theme-one-dark","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"@codemirror/lang-markdown","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@lezer/highlight","kind":"import-statement","external":true},{"path":"@lezer/markdown","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"lodash.get","kind":"import-statement","external":true},{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/context","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"lodash.get","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/display-name","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true}],"exports":["BaseTextEditor","Cursor","Doc","EditorModes","MarkdownEditor","RemoteSelectionsDecorator","SpaceAwarenessProvider","TextEditor","TextKind","Toolbar","YText","YXmlFragment","autocomplete","automerge","awareness","awarenessProvider","blast","callbackWrapper","code","codeTheme","comments","createBasicBundle","createComment","createDataExtensions","createMarkdownExtensions","createThemeExtensions","defaultMarkdownSlots","defaultOptions","defaultSlots","defaultTextSlots","defaultTheme","focusComment","formatting","getToken","heading","hr","image","insertCodeblock","insertTable","keymap","link","listener","logChanges","markdownHighlightStyle","markdownTags","markdownTagsExtensions","markdownTheme","mention","modelState","outliner","setComments","setHeading","setSelection","table","tags","tasklist","textTheme","toggleBold","toggleItalic","toggleList","toggleStrikethrough","toggleStyle","typewriter","useActionHandler","useComments","useEditorView","useInMemoryTextModel","useTextEditor","useTextModel","useToolbarContext"],"entryPoint":"packages/ui/react-ui-editor/src/index.ts","inputs":{"packages/ui/react-ui-editor/src/index.ts":{"bytesInOutput":186},"packages/ui/react-ui-editor/src/components/TextEditor/index.ts":{"bytesInOutput":50},"packages/ui/react-ui-editor/src/components/TextEditor/TextEditor.tsx":{"bytesInOutput":5323},"packages/ui/react-ui-editor/src/extensions/autocomplete.ts":{"bytesInOutput":1240},"packages/ui/react-ui-editor/src/extensions/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/extensions/automerge/automerge.ts":{"bytesInOutput":2162},"packages/ui/react-ui-editor/src/extensions/automerge/cursor.ts":{"bytesInOutput":862},"packages/ui/react-ui-editor/src/extensions/automerge/defs.ts":{"bytesInOutput":428},"packages/ui/react-ui-editor/src/extensions/automerge/semaphore.ts":{"bytesInOutput":1458},"packages/ui/react-ui-editor/src/extensions/automerge/update-automerge.ts":{"bytesInOutput":863},"packages/ui/react-ui-editor/src/extensions/automerge/update-codemirror.ts":{"bytesInOutput":2416},"packages/ui/react-ui-editor/src/extensions/cursor.ts":{"bytesInOutput":1019},"packages/ui/react-ui-editor/src/extensions/automerge/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/extensions/awareness.ts":{"bytesInOutput":7099},"packages/ui/react-ui-editor/src/extensions/basic.ts":{"bytesInOutput":954},"packages/ui/react-ui-editor/src/extensions/blast.ts":{"bytesInOutput":8806},"packages/ui/react-ui-editor/src/extensions/comments.ts":{"bytesInOutput":11274},"packages/ui/react-ui-editor/src/styles/cursors.ts":{"bytesInOutput":567},"packages/ui/react-ui-editor/src/styles/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/styles/markdown.ts":{"bytesInOutput":981},"packages/ui/react-ui-editor/src/styles/tokens.ts":{"bytesInOutput":207},"packages/ui/react-ui-editor/src/util.ts":{"bytesInOutput":793},"packages/ui/react-ui-editor/src/extensions/listener.ts":{"bytesInOutput":407},"packages/ui/react-ui-editor/src/extensions/markdown/bundle.ts":{"bytesInOutput":2981},"packages/ui/react-ui-editor/src/extensions/markdown/highlight.ts":{"bytesInOutput":4115},"packages/ui/react-ui-editor/src/extensions/markdown/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/extensions/markdown/code.ts":{"bytesInOutput":3301},"packages/ui/react-ui-editor/src/extensions/markdown/formatting.ts":{"bytesInOutput":3667},"packages/ui/react-ui-editor/src/extensions/markdown/heading.ts":{"bytesInOutput":1404},"packages/ui/react-ui-editor/src/extensions/markdown/hr.ts":{"bytesInOutput":1567},"packages/ui/react-ui-editor/src/extensions/markdown/image.ts":{"bytesInOutput":2291},"packages/ui/react-ui-editor/src/extensions/markdown/link.ts":{"bytesInOutput":4165},"packages/ui/react-ui-editor/src/extensions/markdown/table.ts":{"bytesInOutput":3044},"packages/ui/react-ui-editor/src/extensions/markdown/tasklist.ts":{"bytesInOutput":2788},"packages/ui/react-ui-editor/src/extensions/mention.ts":{"bytesInOutput":763},"packages/ui/react-ui-editor/src/extensions/outliner.ts":{"bytesInOutput":51},"packages/ui/react-ui-editor/src/extensions/typewriter.ts":{"bytesInOutput":1341},"packages/ui/react-ui-editor/src/themes/default.ts":{"bytesInOutput":6596},"packages/ui/react-ui-editor/src/themes/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/components/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/components/Toolbar/Toolbar.tsx":{"bytesInOutput":5035},"packages/ui/react-ui-editor/src/components/Toolbar/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/hooks/awareness-provider.ts":{"bytesInOutput":2588},"packages/ui/react-ui-editor/src/hooks/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/hooks/defs.ts":{"bytesInOutput":156},"packages/ui/react-ui-editor/src/hooks/useActionHandler.ts":{"bytesInOutput":805},"packages/ui/react-ui-editor/src/hooks/useEditorView.ts":{"bytesInOutput":188},"packages/ui/react-ui-editor/src/hooks/useTextEditor.ts":{"bytesInOutput":2985},"packages/ui/react-ui-editor/src/hooks/useTextModel.ts":{"bytesInOutput":2025}},"bytes":103013}}}
1
+ {"inputs":{"packages/ui/react-ui-editor/src/extensions/autocomplete.ts":{"bytes":5653,"imports":[{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/lang-markdown","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/cursor.ts":{"bytes":4504,"imports":[{"path":"lodash.get","kind":"import-statement","external":true},{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/defs.ts":{"bytes":3775,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/update-automerge.ts":{"bytes":5383,"imports":[{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/update-codemirror.ts":{"bytes":11386,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/defs.ts","kind":"import-statement","original":"./defs"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/semaphore.ts":{"bytes":9174,"imports":[{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/defs.ts","kind":"import-statement","original":"./defs"},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/update-automerge.ts","kind":"import-statement","original":"./update-automerge"},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/update-codemirror.ts","kind":"import-statement","original":"./update-codemirror"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/cursor.ts":{"bytes":5036,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/automerge.ts":{"bytes":10456,"imports":[{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/cursor.ts","kind":"import-statement","original":"./cursor"},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/defs.ts","kind":"import-statement","original":"./defs"},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/semaphore.ts","kind":"import-statement","original":"./semaphore"},{"path":"packages/ui/react-ui-editor/src/extensions/cursor.ts","kind":"import-statement","original":"../cursor"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/automerge/index.ts":{"bytes":605,"imports":[{"path":"packages/ui/react-ui-editor/src/extensions/automerge/automerge.ts","kind":"import-statement","original":"./automerge"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/awareness.ts":{"bytes":30390,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/context","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/cursor.ts","kind":"import-statement","original":"./cursor"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/basic.ts":{"bytes":4195,"imports":[{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/theme-one-dark","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/blast.ts":{"bytes":39556,"imports":[{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"lodash.defaultsdeep","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/styles/cursors.ts":{"bytes":2633,"imports":[{"path":"lib0/random","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/styles/markdown.ts":{"bytes":6664,"imports":[{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/styles/tokens.ts":{"bytes":1697,"imports":[{"path":"lodash.get","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/styles/index.ts":{"bytes":643,"imports":[{"path":"packages/ui/react-ui-editor/src/styles/cursors.ts","kind":"import-statement","original":"./cursors"},{"path":"packages/ui/react-ui-editor/src/styles/markdown.ts","kind":"import-statement","original":"./markdown"},{"path":"packages/ui/react-ui-editor/src/styles/tokens.ts","kind":"import-statement","original":"./tokens"}],"format":"esm"},"packages/ui/react-ui-editor/src/util.ts":{"bytes":3789,"imports":[{"path":"@dxos/log","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/comments.ts":{"bytes":50570,"imports":[{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"lodash.sortby","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/cursor.ts","kind":"import-statement","original":"./cursor"},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../styles"},{"path":"packages/ui/react-ui-editor/src/util.ts","kind":"import-statement","original":"../util"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/listener.ts":{"bytes":2475,"imports":[{"path":"@codemirror/view","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/highlight.ts":{"bytes":18853,"imports":[{"path":"@codemirror/lang-markdown","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@lezer/highlight","kind":"import-statement","external":true},{"path":"@lezer/markdown","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../../styles"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/bundle.ts":{"bytes":10718,"imports":[{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/lang-markdown","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/language-data","kind":"import-statement","external":true},{"path":"@codemirror/search","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/theme-one-dark","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/highlight.ts","kind":"import-statement","original":"./highlight"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/code.ts":{"bytes":14440,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../../styles"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/formatting.ts":{"bytes":150221,"imports":[{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/heading.ts":{"bytes":6054,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/hr.ts":{"bytes":6885,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../../styles"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/image.ts":{"bytes":10625,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/link.ts":{"bytes":21976,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/table.ts":{"bytes":13558,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/tasklist.ts":{"bytes":11918,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../../styles"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/markdown/index.ts":{"bytes":1235,"imports":[{"path":"packages/ui/react-ui-editor/src/extensions/markdown/bundle.ts","kind":"import-statement","original":"./bundle"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/code.ts","kind":"import-statement","original":"./code"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/formatting.ts","kind":"import-statement","original":"./formatting"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/heading.ts","kind":"import-statement","original":"./heading"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/highlight.ts","kind":"import-statement","original":"./highlight"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/hr.ts","kind":"import-statement","original":"./hr"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/image.ts","kind":"import-statement","original":"./image"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/link.ts","kind":"import-statement","original":"./link"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/table.ts","kind":"import-statement","original":"./table"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/tasklist.ts","kind":"import-statement","original":"./tasklist"}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/mention.ts":{"bytes":3969,"imports":[{"path":"@codemirror/autocomplete","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/outliner.ts":{"bytes":1051,"imports":[],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/typewriter.ts":{"bytes":6277,"imports":[{"path":"@codemirror/view","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/extensions/index.ts":{"bytes":1449,"imports":[{"path":"packages/ui/react-ui-editor/src/extensions/autocomplete.ts","kind":"import-statement","original":"./autocomplete"},{"path":"packages/ui/react-ui-editor/src/extensions/automerge/index.ts","kind":"import-statement","original":"./automerge"},{"path":"packages/ui/react-ui-editor/src/extensions/awareness.ts","kind":"import-statement","original":"./awareness"},{"path":"packages/ui/react-ui-editor/src/extensions/basic.ts","kind":"import-statement","original":"./basic"},{"path":"packages/ui/react-ui-editor/src/extensions/blast.ts","kind":"import-statement","original":"./blast"},{"path":"packages/ui/react-ui-editor/src/extensions/comments.ts","kind":"import-statement","original":"./comments"},{"path":"packages/ui/react-ui-editor/src/extensions/cursor.ts","kind":"import-statement","original":"./cursor"},{"path":"packages/ui/react-ui-editor/src/extensions/listener.ts","kind":"import-statement","original":"./listener"},{"path":"packages/ui/react-ui-editor/src/extensions/markdown/index.ts","kind":"import-statement","original":"./markdown"},{"path":"packages/ui/react-ui-editor/src/extensions/mention.ts","kind":"import-statement","original":"./mention"},{"path":"packages/ui/react-ui-editor/src/extensions/outliner.ts","kind":"import-statement","original":"./outliner"},{"path":"packages/ui/react-ui-editor/src/extensions/typewriter.ts","kind":"import-statement","original":"./typewriter"}],"format":"esm"},"packages/ui/react-ui-editor/src/themes/default.ts":{"bytes":23362,"imports":[{"path":"lodash.get","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../styles"}],"format":"esm"},"packages/ui/react-ui-editor/src/themes/index.ts":{"bytes":473,"imports":[{"path":"packages/ui/react-ui-editor/src/themes/default.ts","kind":"import-statement","original":"./default"}],"format":"esm"},"packages/ui/react-ui-editor/src/components/TextEditor/TextEditor.tsx":{"bytes":25851,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@replit/codemirror-vim","kind":"import-statement","external":true},{"path":"lodash.defaultsdeep","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/extensions/index.ts","kind":"import-statement","original":"../../extensions"},{"path":"packages/ui/react-ui-editor/src/themes/index.ts","kind":"import-statement","original":"../../themes"},{"path":"packages/ui/react-ui-editor/src/util.ts","kind":"import-statement","original":"../../util"}],"format":"esm"},"packages/ui/react-ui-editor/src/components/TextEditor/index.ts":{"bytes":712,"imports":[{"path":"@lezer/highlight","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/components/TextEditor/TextEditor.tsx","kind":"import-statement","original":"./TextEditor"}],"format":"esm"},"packages/ui/react-ui-editor/src/components/Toolbar/Toolbar.tsx":{"bytes":25306,"imports":[{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/components/Toolbar/index.ts":{"bytes":485,"imports":[{"path":"packages/ui/react-ui-editor/src/components/Toolbar/Toolbar.tsx","kind":"import-statement","original":"./Toolbar"}],"format":"esm"},"packages/ui/react-ui-editor/src/components/index.ts":{"bytes":571,"imports":[{"path":"packages/ui/react-ui-editor/src/components/TextEditor/index.ts","kind":"import-statement","original":"./TextEditor"},{"path":"packages/ui/react-ui-editor/src/components/Toolbar/index.ts","kind":"import-statement","original":"./Toolbar"}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/awareness-provider.ts":{"bytes":10990,"imports":[{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/context","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/defs.ts":{"bytes":1902,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/useActionHandler.ts":{"bytes":8003,"imports":[{"path":"packages/ui/react-ui-editor/src/extensions/index.ts","kind":"import-statement","original":"../extensions"}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/useEditorView.ts":{"bytes":2025,"imports":[{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/useTextEditor.ts":{"bytes":13694,"imports":[{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/themes/index.ts","kind":"import-statement","original":"../themes"},{"path":"packages/ui/react-ui-editor/src/util.ts","kind":"import-statement","original":"../util"}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/useTextModel.ts":{"bytes":9406,"imports":[{"path":"lodash.get","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/display-name","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/hooks/awareness-provider.ts","kind":"import-statement","original":"./awareness-provider"},{"path":"packages/ui/react-ui-editor/src/hooks/defs.ts","kind":"import-statement","original":"./defs"},{"path":"packages/ui/react-ui-editor/src/extensions/index.ts","kind":"import-statement","original":"../extensions"},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"../styles"}],"format":"esm"},"packages/ui/react-ui-editor/src/hooks/index.ts":{"bytes":997,"imports":[{"path":"packages/ui/react-ui-editor/src/hooks/awareness-provider.ts","kind":"import-statement","original":"./awareness-provider"},{"path":"packages/ui/react-ui-editor/src/hooks/defs.ts","kind":"import-statement","original":"./defs"},{"path":"packages/ui/react-ui-editor/src/hooks/useActionHandler.ts","kind":"import-statement","original":"./useActionHandler"},{"path":"packages/ui/react-ui-editor/src/hooks/useEditorView.ts","kind":"import-statement","original":"./useEditorView"},{"path":"packages/ui/react-ui-editor/src/hooks/useTextEditor.ts","kind":"import-statement","original":"./useTextEditor"},{"path":"packages/ui/react-ui-editor/src/hooks/useTextModel.ts","kind":"import-statement","original":"./useTextModel"}],"format":"esm"},"packages/ui/react-ui-editor/src/index.ts":{"bytes":1666,"imports":[{"path":"@dxos/protocols/proto/dxos/echo/model/text","kind":"import-statement","external":true},{"path":"@dxos/text-model","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"packages/ui/react-ui-editor/src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"packages/ui/react-ui-editor/src/extensions/index.ts","kind":"import-statement","original":"./extensions"},{"path":"packages/ui/react-ui-editor/src/hooks/index.ts","kind":"import-statement","original":"./hooks"},{"path":"packages/ui/react-ui-editor/src/styles/index.ts","kind":"import-statement","original":"./styles"},{"path":"packages/ui/react-ui-editor/src/themes/index.ts","kind":"import-statement","original":"./themes"},{"path":"packages/ui/react-ui-editor/src/util.ts","kind":"import-statement","original":"./util"}],"format":"esm"}},"outputs":{"packages/ui/react-ui-editor/dist/lib/browser/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":295885},"packages/ui/react-ui-editor/dist/lib/browser/index.mjs":{"imports":[{"path":"@dxos/protocols/proto/dxos/echo/model/text","kind":"import-statement","external":true},{"path":"@dxos/text-model","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@lezer/highlight","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@replit/codemirror-vim","kind":"import-statement","external":true},{"path":"lodash.defaultsdeep","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/lang-markdown","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true},{"path":"lodash.get","kind":"import-statement","external":true},{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true},{"path":"@dxos/automerge/automerge","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/context","kind":"import-statement","external":true},{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/theme-one-dark","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"lodash.defaultsdeep","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"lodash.sortby","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"lib0/random","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"lodash.get","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/commands","kind":"import-statement","external":true},{"path":"@codemirror/lang-markdown","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/language-data","kind":"import-statement","external":true},{"path":"@codemirror/search","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/theme-one-dark","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"@codemirror/lang-markdown","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@lezer/highlight","kind":"import-statement","external":true},{"path":"@lezer/markdown","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"@codemirror/autocomplete","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"lodash.get","kind":"import-statement","external":true},{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@dxos/async","kind":"import-statement","external":true},{"path":"@dxos/context","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"lodash.get","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/display-name","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true}],"exports":["BaseTextEditor","Cursor","Doc","EditorModes","Inline","List","MarkdownEditor","RemoteSelectionsDecorator","SpaceAwarenessProvider","TextEditor","TextKind","Toolbar","YText","YXmlFragment","addBlockquote","addCodeblock","addLink","addList","addStyle","autocomplete","automerge","awareness","awarenessProvider","blast","callbackWrapper","code","codeTheme","comments","compareFormatting","createBasicBundle","createComment","createDataExtensions","createMarkdownExtensions","createThemeExtensions","defaultMarkdownSlots","defaultOptions","defaultSlots","defaultTextSlots","defaultTheme","focusComment","formatting","getFormatting","getToken","heading","hr","image","insertTable","keymap","link","listener","logChanges","markdownHighlightStyle","markdownTags","markdownTagsExtensions","markdownTheme","mention","modelState","outliner","removeBlockquote","removeCodeblock","removeLink","removeList","removeStyle","setBlockquote","setComments","setHeading","setSelection","setStyle","table","tags","tasklist","textTheme","toggleBlockquote","toggleCodeblock","toggleEmphasis","toggleInlineCode","toggleList","toggleStrikethrough","toggleStrong","toggleStyle","typewriter","useActionHandler","useComments","useEditorView","useFormattingState","useInMemoryTextModel","useTextEditor","useTextModel","useToolbarContext"],"entryPoint":"packages/ui/react-ui-editor/src/index.ts","inputs":{"packages/ui/react-ui-editor/src/index.ts":{"bytesInOutput":186},"packages/ui/react-ui-editor/src/components/TextEditor/index.ts":{"bytesInOutput":50},"packages/ui/react-ui-editor/src/components/TextEditor/TextEditor.tsx":{"bytesInOutput":5337},"packages/ui/react-ui-editor/src/extensions/autocomplete.ts":{"bytesInOutput":1240},"packages/ui/react-ui-editor/src/extensions/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/extensions/automerge/automerge.ts":{"bytesInOutput":2162},"packages/ui/react-ui-editor/src/extensions/automerge/cursor.ts":{"bytesInOutput":862},"packages/ui/react-ui-editor/src/extensions/automerge/defs.ts":{"bytesInOutput":428},"packages/ui/react-ui-editor/src/extensions/automerge/semaphore.ts":{"bytesInOutput":1458},"packages/ui/react-ui-editor/src/extensions/automerge/update-automerge.ts":{"bytesInOutput":863},"packages/ui/react-ui-editor/src/extensions/automerge/update-codemirror.ts":{"bytesInOutput":2416},"packages/ui/react-ui-editor/src/extensions/cursor.ts":{"bytesInOutput":1019},"packages/ui/react-ui-editor/src/extensions/automerge/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/extensions/awareness.ts":{"bytesInOutput":7099},"packages/ui/react-ui-editor/src/extensions/basic.ts":{"bytesInOutput":954},"packages/ui/react-ui-editor/src/extensions/blast.ts":{"bytesInOutput":8806},"packages/ui/react-ui-editor/src/extensions/comments.ts":{"bytesInOutput":11316},"packages/ui/react-ui-editor/src/styles/cursors.ts":{"bytesInOutput":567},"packages/ui/react-ui-editor/src/styles/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/styles/markdown.ts":{"bytesInOutput":981},"packages/ui/react-ui-editor/src/styles/tokens.ts":{"bytesInOutput":207},"packages/ui/react-ui-editor/src/util.ts":{"bytesInOutput":793},"packages/ui/react-ui-editor/src/extensions/listener.ts":{"bytesInOutput":407},"packages/ui/react-ui-editor/src/extensions/markdown/bundle.ts":{"bytesInOutput":2981},"packages/ui/react-ui-editor/src/extensions/markdown/highlight.ts":{"bytesInOutput":4115},"packages/ui/react-ui-editor/src/extensions/markdown/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/extensions/markdown/code.ts":{"bytesInOutput":3301},"packages/ui/react-ui-editor/src/extensions/markdown/formatting.ts":{"bytesInOutput":33724},"packages/ui/react-ui-editor/src/extensions/markdown/heading.ts":{"bytesInOutput":1404},"packages/ui/react-ui-editor/src/extensions/markdown/hr.ts":{"bytesInOutput":1569},"packages/ui/react-ui-editor/src/extensions/markdown/image.ts":{"bytesInOutput":2291},"packages/ui/react-ui-editor/src/extensions/markdown/link.ts":{"bytesInOutput":4165},"packages/ui/react-ui-editor/src/extensions/markdown/table.ts":{"bytesInOutput":3044},"packages/ui/react-ui-editor/src/extensions/markdown/tasklist.ts":{"bytesInOutput":2788},"packages/ui/react-ui-editor/src/extensions/mention.ts":{"bytesInOutput":763},"packages/ui/react-ui-editor/src/extensions/outliner.ts":{"bytesInOutput":51},"packages/ui/react-ui-editor/src/extensions/typewriter.ts":{"bytesInOutput":1341},"packages/ui/react-ui-editor/src/themes/default.ts":{"bytesInOutput":6596},"packages/ui/react-ui-editor/src/themes/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/components/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/components/Toolbar/Toolbar.tsx":{"bytesInOutput":6790},"packages/ui/react-ui-editor/src/components/Toolbar/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/hooks/awareness-provider.ts":{"bytesInOutput":2588},"packages/ui/react-ui-editor/src/hooks/index.ts":{"bytesInOutput":0},"packages/ui/react-ui-editor/src/hooks/defs.ts":{"bytesInOutput":156},"packages/ui/react-ui-editor/src/hooks/useActionHandler.ts":{"bytesInOutput":1576},"packages/ui/react-ui-editor/src/hooks/useEditorView.ts":{"bytesInOutput":188},"packages/ui/react-ui-editor/src/hooks/useTextEditor.ts":{"bytesInOutput":3006},"packages/ui/react-ui-editor/src/hooks/useTextModel.ts":{"bytesInOutput":2025}},"bytes":135975}}}
@@ -1 +1 @@
1
- {"version":3,"file":"MarkdownEditor.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/TextEditor/MarkdownEditor.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAInD,OAAO,KAAgD,MAAM,OAAO,CAAC;AASrE,OAAO,EAAkB,KAAK,eAAe,EAAE,MAAM,cAAc,CAAC;AAoBpE,OAAO,EAAE,KAAK,OAAO,EAAgB,MAAM,aAAa,CAAC;AA2KzD,KAAK,UAAU,GAAG;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,OAAO,EAAE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G,aAAa,GAAG,OAAO,GAAG,YAAY,CAAC,CAAC;;;;;;;AAsB/E,wBAKE;AAgBF,eAAO,MAAM,OAAO;;CAEnB,CAAC;AAEF,eAAO,MAAM,QAAQ;;CAEpB,CAAC;AAEF,eAAO,MAAM,YAAY;;CAExB,CAAC;AAIF,eAAO,MAAM,KAAK;;CAEjB,CAAC;AAEF,eAAO,MAAM,SAAS;;CAErB,CAAC;AAEF,eAAO,MAAM,KAAK;;CAOjB,CAAC;AAEF,eAAO,MAAM,IAAI;;CAEhB,CAAC;AAEF,eAAO,MAAM,KAAK;;CAEjB,CAAC;AAEF,eAAO,MAAM,KAAK;;CAIjB,CAAC;AAEF,eAAO,MAAM,KAAK;;CAEjB,CAAC;AAWF,eAAO,MAAM,YAAY;;CAYxB,CAAC;AAEF,eAAO,MAAM,OAAO;;CAWnB,CAAC;AAEF,eAAO,MAAM,QAAQ;;CAkCpB,CAAC;AAEF,eAAO,MAAM,cAAc;;CAO1B,CAAC;AAIF,eAAO,MAAM,UAAU;;CAOtB,CAAC;AAEF,eAAO,MAAM,KAAK;;CAqBjB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"hooks.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/TextEditor/hooks.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,KAAK,MAAM,OAAO,CAAC;AA4B1B,KAAK,UAAU,GAAG;IAChB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;;;;;mBAyDe,UAAU;;AAJ3B,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;CAMnB,CAAC"}
1
+ {"version":3,"file":"hooks.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/TextEditor/hooks.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAEpB,OAAO,KAAK,MAAM,OAAO,CAAC;AA6B1B,KAAK,UAAU,GAAG;IAChB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;;;;;mBA6De,UAAU;;AAJ3B,wBAKE;AAEF,eAAO,MAAM,OAAO;;;;;;CAMnB,CAAC"}
@@ -1,22 +1,26 @@
1
1
  import { type Icon } from '@phosphor-icons/react';
2
2
  import { type PropsWithChildren } from 'react';
3
3
  import { type ButtonProps } from '@dxos/react-ui';
4
- export type ActionType = 'blockquote' | 'bold' | 'codeblock' | 'comment' | 'heading' | 'image' | 'italic' | 'link' | 'list' | 'list-ordered' | 'list-tasks' | 'mention' | 'prompt' | 'strikethrough' | 'table';
4
+ import { type Formatting } from '../../extensions';
5
+ export type ActionType = 'blockquote' | 'strong' | 'codeblock' | 'comment' | 'heading' | 'image' | 'emphasis' | 'code' | 'link' | 'list-bullet' | 'list-ordered' | 'list-tasks' | 'mention' | 'prompt' | 'strikethrough' | 'table';
5
6
  export type Action = {
6
7
  type: ActionType;
7
8
  data?: any;
8
9
  };
9
10
  export type ToolbarProps = PropsWithChildren<{
11
+ state: Formatting | null;
10
12
  onAction?: (action: Action) => void;
11
13
  }>;
12
14
  declare const useToolbarContext: (consumerName: string) => ToolbarProps;
13
15
  type ToolbarButtonProps = {
14
16
  Icon: Icon;
15
- onClick: () => Action | undefined;
17
+ disable?: (state: Formatting) => boolean;
18
+ getState?: (state: Formatting) => boolean;
19
+ onClick: (state: Formatting | null) => Action | undefined;
16
20
  } & NonNullable<Pick<ButtonProps, 'title'>>;
17
21
  export declare const Toolbar: {
18
- Root: ({ children, onAction }: ToolbarProps) => JSX.Element;
19
- Button: ({ Icon, onClick, title }: ToolbarButtonProps) => JSX.Element;
22
+ Root: ({ children, onAction, state }: ToolbarProps) => JSX.Element;
23
+ Button: ({ Icon, onClick, title, getState, disable }: ToolbarButtonProps) => JSX.Element;
20
24
  Separator: () => JSX.Element;
21
25
  Markdown: () => JSX.Element;
22
26
  Extended: () => JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"Toolbar.d.ts","sourceRoot":"","sources":["../../../../../src/components/Toolbar/Toolbar.tsx"],"names":[],"mappings":"AAIA,OAAO,EACL,KAAK,IAAI,EAcV,MAAM,uBAAuB,CAAC;AAE/B,OAAc,EAAE,KAAK,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAEtD,OAAO,EAAU,KAAK,WAAW,EAA2B,MAAM,gBAAgB,CAAC;AAInF,MAAM,MAAM,UAAU,GAClB,YAAY,GACZ,MAAM,GACN,WAAW,GACX,SAAS,GACT,SAAS,GACT,OAAO,GACP,QAAQ,GACR,MAAM,GACN,MAAM,GACN,cAAc,GACd,YAAY,GACZ,SAAS,GACT,QAAQ,GACR,eAAe,GACf,OAAO,CAAC;AAEZ,MAAM,MAAM,MAAM,GAAG;IACnB,IAAI,EAAE,UAAU,CAAC;IACjB,IAAI,CAAC,EAAE,GAAG,CAAC;CACZ,CAAC;AAEF,MAAM,MAAM,YAAY,GAAG,iBAAiB,CAAC;IAC3C,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;CACrC,CAAC,CAAC;AAEH,QAAA,MAA+B,iBAAiB,wCAA0C,CAAC;AAc3F,KAAK,kBAAkB,GAAG;IACxB,IAAI,EAAE,IAAI,CAAC;IACX,OAAO,EAAE,MAAM,MAAM,GAAG,SAAS,CAAC;CACnC,GAAG,WAAW,CAAC,IAAI,CAAC,WAAW,EAAE,OAAO,CAAC,CAAC,CAAC;AAuF5C,eAAO,MAAM,OAAO;mCAtGyB,YAAY;uCAiBR,kBAAkB;;;;CA2FlE,CAAC;AAEF,OAAO,EAAE,iBAAiB,EAAE,CAAC"}
1
+ {"version":3,"file":"Toolbar.d.ts","sourceRoot":"","sources":["../../../../../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F,OAAO,EAAE,iBAAiB,EAAE,CAAC"}
@@ -2,10 +2,12 @@ import '@dxosTheme';
2
2
  declare const _default: {
3
3
  title: string;
4
4
  component: {
5
- Root: ({ children, onAction }: import("./Toolbar").ToolbarProps) => JSX.Element;
6
- Button: ({ Icon, onClick, title }: {
5
+ Root: ({ children, onAction, state }: import("./Toolbar").ToolbarProps) => JSX.Element;
6
+ Button: ({ Icon, onClick, title, getState, disable }: {
7
7
  Icon: import("@phosphor-icons/react").Icon;
8
- onClick: () => import("./Toolbar").Action | undefined;
8
+ disable?: ((state: import("../../extensions").Formatting) => boolean) | undefined;
9
+ getState?: ((state: import("../../extensions").Formatting) => boolean) | undefined;
10
+ onClick: (state: import("../../extensions").Formatting | null) => import("./Toolbar").Action | undefined;
9
11
  } & Pick<import("@dxos/react-ui/dist/types/src/components/Buttons/Button").ButtonProps, "title">) => JSX.Element;
10
12
  Separator: () => JSX.Element;
11
13
  Markdown: () => JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"Toolbar.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Toolbar/Toolbar.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;;;;;;;;;;;;;mBAmEH,GAAG;;;AAHpB,wBAKE;AAYF,eAAO,MAAM,OAAO;;;;CAInB,CAAC"}
1
+ {"version":3,"file":"Toolbar.stories.d.ts","sourceRoot":"","sources":["../../../../../src/components/Toolbar/Toolbar.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;;;;;;;;;;;;;;;mBA+EH,GAAG;;;AAHpB,wBAKE;AAYF,eAAO,MAAM,OAAO;;;;CAInB,CAAC"}
@@ -25,7 +25,11 @@ export type CommentsOptions = {
25
25
  /**
26
26
  * Called to create a new thread and return the thread id.
27
27
  */
28
- onCreate?: (cursor: string, location?: Rect | null) => string | undefined;
28
+ onCreate?: (params: {
29
+ cursor: string;
30
+ from: number;
31
+ location?: Rect | null;
32
+ }) => string | undefined;
29
33
  /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AY,6DAAuC,CAAC;AAwEjE,MAAM,MAAM,eAAe,GAAG;IAC5B;;OAEG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;IACb;;OAEG;IACH,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,IAAI,GAAG,IAAI,CAAA;KAAE,KAAK,MAAM,GAAG,SAAS,CAAC;IACpG;;OAEG;IACH,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IACpC;;OAEG;IACH,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IACpD;;OAEG;IACH,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,aAAa,KAAK,IAAI,CAAC;IAC1C;;OAEG;IACH,OAAO,CAAC,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;CACnD,CAAC;AAwHF;;GAEG;AACH,eAAO,MAAM,aAAa,EAAE,OAiC3B,CAAC;AAEF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,QAAQ,aAAa,eAAe,KAAQ,SAgIxD,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,WAAW,SAAU,UAAU,GAAG,IAAI,aAAY,OAAO,EAAE,SAQvE,CAAC"}
@@ -1,13 +1,58 @@
1
- import { type Extension } from '@codemirror/state';
2
- import { type Command, type EditorView } from '@codemirror/view';
3
- export type FormattingOptions = {};
4
- export declare const setHeading: (level: number) => Command;
5
- export declare const toggleStyle: (mark: string) => Command;
6
- export declare const insertCodeblock: (view: EditorView) => void;
1
+ import { type Extension, type StateCommand, type EditorState } from '@codemirror/state';
2
+ import { EditorView } from '@codemirror/view';
3
+ export type Formatting = {
4
+ blankLine: boolean;
5
+ blockType: 'codeblock' | 'heading1' | 'heading2' | 'heading3' | 'heading4' | 'heading5' | 'heading6' | 'paragraph' | 'tablecell' | null;
6
+ blockQuote: boolean;
7
+ strong: boolean;
8
+ emphasis: boolean;
9
+ strikethrough: boolean;
10
+ code: boolean;
11
+ link: boolean;
12
+ listStyle: null | 'ordered' | 'bullet' | 'task';
13
+ };
14
+ export declare const compareFormatting: (a: Formatting, b: Formatting) => boolean;
15
+ export declare enum Inline {
16
+ Strong = 0,
17
+ Emphasis = 1,
18
+ Strikethrough = 2,
19
+ Code = 3
20
+ }
21
+ export declare enum List {
22
+ Ordered = 0,
23
+ Bullet = 1,
24
+ Task = 2
25
+ }
26
+ export declare const setHeading: (level: number) => StateCommand;
27
+ export declare const setStyle: (type: Inline, enable: boolean) => StateCommand;
28
+ export declare const addStyle: (style: Inline) => StateCommand;
29
+ export declare const removeStyle: (style: Inline) => StateCommand;
30
+ export declare const toggleStyle: (style: Inline) => StateCommand;
31
+ export declare const toggleStrong: StateCommand;
32
+ export declare const toggleEmphasis: StateCommand;
33
+ export declare const toggleStrikethrough: StateCommand;
34
+ export declare const toggleInlineCode: StateCommand;
7
35
  export declare const insertTable: (view: EditorView) => void;
8
- export declare const toggleBold: Command;
9
- export declare const toggleItalic: Command;
10
- export declare const toggleStrikethrough: Command;
11
- export declare const toggleList: (view: EditorView) => void;
36
+ export declare const removeLink: StateCommand;
37
+ export declare const addLink: StateCommand;
38
+ export declare const addList: (type: List) => StateCommand;
39
+ export declare const removeList: (type: List) => StateCommand;
40
+ export declare const toggleList: (type: List) => StateCommand;
41
+ export declare const setBlockquote: (enable: boolean) => StateCommand;
42
+ export declare const addBlockquote: StateCommand;
43
+ export declare const removeBlockquote: StateCommand;
44
+ export declare const toggleBlockquote: StateCommand;
45
+ export declare const addCodeblock: StateCommand;
46
+ export declare const removeCodeblock: StateCommand;
47
+ export declare const toggleCodeblock: StateCommand;
48
+ export type FormattingOptions = {};
12
49
  export declare const formatting: (options?: FormattingOptions) => Extension;
50
+ /**
51
+ * Query an editor state for the active formatting at the selection.
52
+ */
53
+ export declare const getFormatting: (state: EditorState) => Formatting;
54
+ /**
55
+ * Hook computes the current formatting state.
56
+ */
57
+ export declare const useFormattingState: () => [Formatting | null, Extension];
13
58
  //# sourceMappingURL=formatting.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"formatting.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/markdown/formatting.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,KAAK,SAAS,EAAmB,MAAM,mBAAmB,CAAC;AACpE,OAAO,EACL,KAAK,OAAO,EAGZ,KAAK,UAAU,EAIhB,MAAM,kBAAkB,CAAC;AAG1B,MAAM,MAAM,iBAAiB,GAAG,EAAE,CAAC;AAEnC,eAAO,MAAM,UAAU,UACb,MAAM,KAAG,OA6BhB,CAAC;AAEJ,eAAO,MAAM,WAAW,SACf,MAAM,KAAG,OAwBf,CAAC;AAUJ,eAAO,MAAM,eAAe,SAAU,UAAU,SAQ/C,CAAC;AAEF,eAAO,MAAM,WAAW,SAAU,UAAU,SAQ3C,CAAC;AAEF,eAAO,MAAM,UAAU,SAAoB,CAAC;AAC5C,eAAO,MAAM,YAAY,SAAmB,CAAC;AAC7C,eAAO,MAAM,mBAAmB,SAAoB,CAAC;AAErD,eAAO,MAAM,UAAU,SAAU,UAAU,SAAO,CAAC;AAEnD,eAAO,MAAM,UAAU,aAAa,iBAAiB,KAAQ,SAU5D,CAAC"}
1
+ {"version":3,"file":"formatting.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/markdown/formatting.ts"],"names":[],"mappings":"AAMA,OAAO,EACL,KAAK,SAAS,EACd,KAAK,YAAY,EAEjB,KAAK,WAAW,EAKjB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAkC,UAAU,EAAuC,MAAM,kBAAkB,CAAC;AAYnH,MAAM,MAAM,UAAU,GAAG;IACvB,SAAS,EAAE,OAAO,CAAC;IAGnB,SAAS,EACL,WAAW,GACX,UAAU,GACV,UAAU,GACV,UAAU,GACV,UA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U,SACd,IAAI,KAAG,YAwDb,CAAC;AAEJ,eAAO,MAAM,UAAU,SACd,IAAI,KAAG,YAMb,CAAC;AAqBJ,eAAO,MAAM,aAAa,WACf,OAAO,KAAG,YAiElB,CAAC;AAEJ,eAAO,MAAM,aAAa,cAAsB,CAAC;AAEjD,eAAO,MAAM,gBAAgB,cAAuB,CAAC;AAErD,eAAO,MAAM,gBAAgB,EAAE,YAE9B,CAAC;AAMF,eAAO,MAAM,YAAY,EAAE,YAsD1B,CAAC;AAEF,eAAO,MAAM,eAAe,EAAE,YAyC7B,CAAC;AAEF,eAAO,MAAM,eAAe,EAAE,YAE7B,CAAC;AAMF,MAAM,MAAM,iBAAiB,GAAG,EAAE,CAAC;AAEnC,eAAO,MAAM,UAAU,aAAa,iBAAiB,KAAQ,SAU5D,CAAC;AAyGF;;GAEG;AACH,eAAO,MAAM,aAAa,UAAW,WAAW,KAAG,UAqKlD,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,kBAAkB,QAAO,CAAC,UAAU,GAAG,IAAI,EAAE,SAAS,CAgBlE,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { type Formatting } from './formatting';
2
+ export declare const emptyFormatting: Formatting;
3
+ //# sourceMappingURL=formatting.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"formatting.test.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/markdown/formatting.test.ts"],"names":[],"mappings":"AAUA,OAAO,EAeL,KAAK,UAAU,EAChB,MAAM,cAAc,CAAC;AAEtB,eAAO,MAAM,eAAe,EAAE,UAU7B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"useActionHandler.d.ts","sourceRoot":"","sources":["../../../../src/hooks/useActionHandler.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAEnD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAYlD,eAAO,MAAM,gBAAgB,UAAW,UAAU,GAAG,IAAI,KAAG,YAAY,CAAC,UAAU,CA2ClF,CAAC"}
1
+ {"version":3,"file":"useActionHandler.d.ts","sourceRoot":"","sources":["../../../../src/hooks/useActionHandler.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAEnD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAqBlD,eAAO,MAAM,gBAAgB,UAAW,UAAU,GAAG,IAAI,KAAG,YAAY,CAAC,UAAU,CAiElF,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dxos/react-ui-editor",
3
- "version": "0.3.11-next.ee2b64c",
3
+ "version": "0.4.0",
4
4
  "description": "Document editing experience within a DXOS shell.",
5
5
  "homepage": "https://dxos.org",
6
6
  "bugs": "https://github.com/dxos/dxos/issues",
@@ -36,24 +36,23 @@
36
36
  "lodash.pick": "^4.4.0",
37
37
  "lodash.sortby": "^4.7.0",
38
38
  "style-mod": "^4.1.0",
39
- "@dxos/async": "0.3.11-next.ee2b64c",
40
- "@dxos/context": "0.3.11-next.ee2b64c",
41
- "@dxos/debug": "0.3.11-next.ee2b64c",
42
- "@dxos/automerge": "0.3.11-next.ee2b64c",
43
- "@dxos/display-name": "0.3.11-next.ee2b64c",
44
- "@dxos/echo-schema": "0.3.11-next.ee2b64c",
45
- "@dxos/log": "0.3.11-next.ee2b64c",
46
- "@dxos/invariant": "0.3.11-next.ee2b64c",
47
- "@dxos/react-async": "0.3.11-next.ee2b64c",
48
- "@dxos/protocols": "0.3.11-next.ee2b64c",
49
- "@dxos/text-model": "0.3.11-next.ee2b64c",
50
- "@dxos/react-ui": "0.3.11-next.ee2b64c",
51
- "@dxos/react-ui-theme": "0.3.11-next.ee2b64c",
52
- "@dxos/util": "0.3.11-next.ee2b64c"
39
+ "@dxos/async": "0.4.0",
40
+ "@dxos/automerge": "0.4.0",
41
+ "@dxos/echo-schema": "0.4.0",
42
+ "@dxos/context": "0.4.0",
43
+ "@dxos/invariant": "0.4.0",
44
+ "@dxos/log": "0.4.0",
45
+ "@dxos/debug": "0.4.0",
46
+ "@dxos/display-name": "0.4.0",
47
+ "@dxos/protocols": "0.4.0",
48
+ "@dxos/react-async": "0.4.0",
49
+ "@dxos/react-ui-theme": "0.4.0",
50
+ "@dxos/text-model": "0.4.0",
51
+ "@dxos/react-ui": "0.4.0",
52
+ "@dxos/util": "0.4.0"
53
53
  },
54
54
  "devDependencies": {
55
55
  "@automerge/automerge-repo-network-broadcastchannel": "^1.1.0",
56
- "@faker-js/faker": "^8.3.1",
57
56
  "@phosphor-icons/react": "^2.0.5",
58
57
  "@preact/signals-react": "^1.3.6",
59
58
  "@testing-library/dom": "^8.17.1",
@@ -77,19 +76,20 @@
77
76
  "vite-plugin-top-level-await": "^1.4.1",
78
77
  "vite-plugin-wasm": "^3.3.0",
79
78
  "vitest": "^1.2.1",
80
- "@dxos/config": "0.3.11-next.ee2b64c",
81
- "@dxos/echo-signals": "0.3.11-next.ee2b64c",
82
- "@dxos/echo-typegen": "0.3.11-next.ee2b64c",
83
- "@dxos/keyboard": "0.3.11-next.ee2b64c",
84
- "@dxos/react-ui": "0.3.11-next.ee2b64c",
85
- "@dxos/storybook-utils": "0.3.11-next.ee2b64c",
86
- "@dxos/react-client": "0.3.11-next.ee2b64c"
79
+ "@dxos/echo-signals": "0.4.0",
80
+ "@dxos/config": "0.4.0",
81
+ "@dxos/echo-typegen": "0.4.0",
82
+ "@dxos/keyboard": "0.4.0",
83
+ "@dxos/random": "0.4.0",
84
+ "@dxos/react-ui": "0.4.0",
85
+ "@dxos/storybook-utils": "0.4.0",
86
+ "@dxos/react-client": "0.4.0"
87
87
  },
88
88
  "peerDependencies": {
89
89
  "@phosphor-icons/react": "^2.0.5",
90
90
  "react": "^18.2.0",
91
91
  "react-dom": "^18.2.0",
92
- "@dxos/react-client": "0.3.11-next.ee2b64c"
92
+ "@dxos/react-client": "0.4.0"
93
93
  },
94
94
  "publishConfig": {
95
95
  "access": "public"
@@ -5,7 +5,6 @@
5
5
  import '@dxosTheme';
6
6
 
7
7
  import { type EditorView } from '@codemirror/view';
8
- import { faker } from '@faker-js/faker';
9
8
  import { ArrowSquareOut } from '@phosphor-icons/react';
10
9
  import defaultsDeep from 'lodash.defaultsdeep';
11
10
  import React, { type FC, StrictMode, useRef, useState } from 'react';
@@ -14,6 +13,7 @@ import { createRoot } from 'react-dom/client';
14
13
  import { TextObject } from '@dxos/echo-schema';
15
14
  import { keySymbols, parseShortcut } from '@dxos/keyboard';
16
15
  import { PublicKey } from '@dxos/keys';
16
+ import { faker } from '@dxos/random';
17
17
  import { fixedInsetFlexLayout, getSize, groupSurface, mx } from '@dxos/react-ui-theme';
18
18
  import { withTheme } from '@dxos/storybook-utils';
19
19
 
@@ -350,9 +350,9 @@ export const Comments = {
350
350
  extensions={[
351
351
  comments({
352
352
  onHover: onCommentsHover,
353
- onCreate: (range) => {
353
+ onCreate: ({ cursor }) => {
354
354
  const id = PublicKey.random().toHex();
355
- setComments((commentRanges) => [...commentRanges, { id, cursor: range }]);
355
+ setComments((commentRanges) => [...commentRanges, { id, cursor }]);
356
356
  return id;
357
357
  },
358
358
  onSelect: (state) => {