@dxos/react-ui-editor 0.8.4-main.c1de068 → 0.8.4-main.c85a9c8dae
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/browser/index.mjs +1259 -7415
- package/dist/lib/browser/index.mjs.map +4 -4
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/node-esm/index.mjs +1259 -7414
- package/dist/lib/node-esm/index.mjs.map +4 -4
- package/dist/lib/node-esm/meta.json +1 -1
- package/dist/types/src/components/Editor/Editor.d.ts +43 -15
- package/dist/types/src/components/Editor/Editor.d.ts.map +1 -1
- package/dist/types/src/components/Editor/Editor.stories.d.ts +23 -0
- package/dist/types/src/components/Editor/Editor.stories.d.ts.map +1 -0
- package/dist/types/src/components/EditorContent/EditorContent.d.ts +31 -0
- package/dist/types/src/components/EditorContent/EditorContent.d.ts.map +1 -0
- package/dist/types/src/components/EditorContent/controller.d.ts +10 -0
- package/dist/types/src/components/EditorContent/controller.d.ts.map +1 -0
- package/dist/types/src/components/EditorContent/index.d.ts +3 -0
- package/dist/types/src/components/EditorContent/index.d.ts.map +1 -0
- package/dist/types/src/components/EditorMenuProvider/EditorMenuProvider.d.ts +36 -0
- package/dist/types/src/components/EditorMenuProvider/EditorMenuProvider.d.ts.map +1 -0
- package/dist/types/src/components/EditorMenuProvider/index.d.ts +6 -0
- package/dist/types/src/components/EditorMenuProvider/index.d.ts.map +1 -0
- package/dist/types/src/components/EditorMenuProvider/menu-presets.d.ts +4 -0
- package/dist/types/src/components/EditorMenuProvider/menu-presets.d.ts.map +1 -0
- package/dist/types/src/components/EditorMenuProvider/menu.d.ts +28 -0
- package/dist/types/src/components/EditorMenuProvider/menu.d.ts.map +1 -0
- package/dist/types/src/components/EditorMenuProvider/popover.d.ts +46 -0
- package/dist/types/src/components/EditorMenuProvider/popover.d.ts.map +1 -0
- package/dist/types/src/components/EditorMenuProvider/useEditorMenu.d.ts +34 -0
- package/dist/types/src/components/EditorMenuProvider/useEditorMenu.d.ts.map +1 -0
- package/dist/types/src/components/EditorPreviewProvider/EditorPreviewProvider.d.ts +16 -0
- package/dist/types/src/components/EditorPreviewProvider/EditorPreviewProvider.d.ts.map +1 -0
- package/dist/types/src/components/EditorPreviewProvider/index.d.ts +2 -0
- package/dist/types/src/components/EditorPreviewProvider/index.d.ts.map +1 -0
- package/dist/types/src/components/EditorToolbar/EditorToolbar.d.ts +28 -2
- package/dist/types/src/components/EditorToolbar/EditorToolbar.d.ts.map +1 -1
- package/dist/types/src/components/EditorToolbar/actions.d.ts +25 -0
- package/dist/types/src/components/EditorToolbar/actions.d.ts.map +1 -0
- package/dist/types/src/components/EditorToolbar/blocks.d.ts +9 -7
- package/dist/types/src/components/EditorToolbar/blocks.d.ts.map +1 -1
- package/dist/types/src/components/EditorToolbar/formatting.d.ts +9 -7
- package/dist/types/src/components/EditorToolbar/formatting.d.ts.map +1 -1
- package/dist/types/src/components/EditorToolbar/headings.d.ts +9 -7
- package/dist/types/src/components/EditorToolbar/headings.d.ts.map +1 -1
- package/dist/types/src/components/EditorToolbar/image.d.ts +5 -11
- package/dist/types/src/components/EditorToolbar/image.d.ts.map +1 -1
- package/dist/types/src/components/EditorToolbar/index.d.ts +2 -1
- package/dist/types/src/components/EditorToolbar/index.d.ts.map +1 -1
- package/dist/types/src/components/EditorToolbar/search.d.ts +5 -11
- package/dist/types/src/components/EditorToolbar/search.d.ts.map +1 -1
- package/dist/types/src/components/EditorToolbar/useEditorToolbar.d.ts +11 -0
- package/dist/types/src/components/EditorToolbar/useEditorToolbar.d.ts.map +1 -0
- package/dist/types/src/components/EditorToolbar/view-mode.d.ts +10 -8
- package/dist/types/src/components/EditorToolbar/view-mode.d.ts.map +1 -1
- package/dist/types/src/components/index.d.ts +4 -2
- package/dist/types/src/components/index.d.ts.map +1 -1
- package/dist/types/src/hooks/useTextEditor.d.ts +6 -10
- package/dist/types/src/hooks/useTextEditor.d.ts.map +1 -1
- package/dist/types/src/index.d.ts +0 -8
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/{extensions/automerge/automerge.stories.d.ts → stories/Automerge.stories.d.ts} +14 -26
- package/dist/types/src/stories/Automerge.stories.d.ts.map +1 -0
- package/dist/types/src/stories/CommandDialog.stories.d.ts +14 -0
- package/dist/types/src/stories/CommandDialog.stories.d.ts.map +1 -0
- package/dist/types/src/stories/Comments.stories.d.ts +22 -10
- package/dist/types/src/stories/Comments.stories.d.ts.map +1 -1
- package/dist/types/src/stories/EditorToolbar.stories.d.ts +39 -3
- package/dist/types/src/stories/EditorToolbar.stories.d.ts.map +1 -1
- package/dist/types/src/stories/Experimental.stories.d.ts +23 -13
- package/dist/types/src/stories/Experimental.stories.d.ts.map +1 -1
- package/dist/types/src/stories/Markdown.stories.d.ts +33 -43
- package/dist/types/src/stories/Markdown.stories.d.ts.map +1 -1
- package/dist/types/src/stories/Outliner.stories.d.ts +15 -21
- package/dist/types/src/stories/Outliner.stories.d.ts.map +1 -1
- package/dist/types/src/stories/Popover.stories.d.ts +20 -0
- package/dist/types/src/stories/Popover.stories.d.ts.map +1 -0
- package/dist/types/src/stories/Preview.stories.d.ts +23 -7
- package/dist/types/src/stories/Preview.stories.d.ts.map +1 -1
- package/dist/types/src/stories/Tags.stories.d.ts +16 -0
- package/dist/types/src/stories/Tags.stories.d.ts.map +1 -0
- package/dist/types/src/stories/TextEditor.stories.d.ts +38 -52
- package/dist/types/src/stories/TextEditor.stories.d.ts.map +1 -1
- package/dist/types/src/stories/Theme.stories.d.ts +8 -0
- package/dist/types/src/stories/Theme.stories.d.ts.map +1 -0
- package/dist/types/src/stories/components/EditorStory.d.ts +11 -23
- package/dist/types/src/stories/components/EditorStory.d.ts.map +1 -1
- package/dist/types/src/stories/components/util.d.ts +3 -3
- package/dist/types/src/stories/components/util.d.ts.map +1 -1
- package/dist/types/src/translations.d.ts +6 -6
- package/dist/types/src/translations.d.ts.map +1 -1
- package/dist/types/src/util/index.d.ts +0 -4
- package/dist/types/src/util/index.d.ts.map +1 -1
- package/dist/types/src/util/react.d.ts +7 -6
- package/dist/types/src/util/react.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +84 -80
- package/src/components/Editor/Editor.stories.tsx +95 -0
- package/src/components/Editor/Editor.tsx +170 -24
- package/src/components/EditorContent/EditorContent.tsx +83 -0
- package/src/components/EditorContent/controller.ts +50 -0
- package/src/components/EditorContent/index.ts +6 -0
- package/src/components/EditorMenuProvider/EditorMenuProvider.tsx +228 -0
- package/src/components/EditorMenuProvider/index.ts +10 -0
- package/src/components/EditorMenuProvider/menu-presets.ts +124 -0
- package/src/components/EditorMenuProvider/menu.ts +70 -0
- package/src/components/EditorMenuProvider/popover.ts +285 -0
- package/src/components/EditorMenuProvider/useEditorMenu.ts +179 -0
- package/src/components/EditorPreviewProvider/EditorPreviewProvider.tsx +79 -0
- package/src/components/EditorPreviewProvider/index.ts +5 -0
- package/src/components/EditorToolbar/EditorToolbar.tsx +104 -96
- package/src/components/EditorToolbar/actions.ts +87 -0
- package/src/components/EditorToolbar/blocks.ts +24 -27
- package/src/components/EditorToolbar/formatting.ts +26 -29
- package/src/components/EditorToolbar/headings.ts +29 -21
- package/src/components/EditorToolbar/image.ts +18 -7
- package/src/components/EditorToolbar/index.ts +3 -7
- package/src/components/EditorToolbar/search.ts +18 -7
- package/src/components/EditorToolbar/useEditorToolbar.ts +20 -0
- package/src/components/EditorToolbar/view-mode.ts +17 -11
- package/src/components/index.ts +6 -2
- package/src/hooks/useTextEditor.ts +39 -45
- package/src/index.ts +0 -10
- package/src/stories/Automerge.stories.tsx +174 -0
- package/src/stories/CommandDialog.stories.tsx +81 -0
- package/src/stories/Comments.stories.tsx +59 -51
- package/src/stories/EditorToolbar.stories.tsx +47 -31
- package/src/stories/Experimental.stories.tsx +18 -16
- package/src/stories/Markdown.stories.tsx +37 -33
- package/src/stories/Outliner.stories.tsx +53 -42
- package/src/stories/Popover.stories.tsx +158 -0
- package/src/stories/Preview.stories.tsx +112 -92
- package/src/stories/Tags.stories.tsx +104 -0
- package/src/stories/TextEditor.stories.tsx +50 -75
- package/src/stories/Theme.stories.tsx +61 -0
- package/src/stories/components/EditorStory.tsx +37 -31
- package/src/stories/components/util.tsx +60 -31
- package/src/translations.ts +5 -5
- package/src/util/index.ts +1 -5
- package/src/util/react.tsx +9 -14
- package/dist/lib/browser/chunk-22UMM3QJ.mjs +0 -22
- package/dist/lib/browser/chunk-22UMM3QJ.mjs.map +0 -7
- package/dist/lib/browser/testing/index.mjs +0 -6
- package/dist/lib/browser/testing/index.mjs.map +0 -7
- package/dist/lib/browser/types/index.mjs +0 -13
- package/dist/lib/browser/types/index.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-YXYQPV6R.mjs +0 -24
- package/dist/lib/node-esm/chunk-YXYQPV6R.mjs.map +0 -7
- package/dist/lib/node-esm/testing/index.mjs +0 -8
- package/dist/lib/node-esm/testing/index.mjs.map +0 -7
- package/dist/lib/node-esm/types/index.mjs +0 -14
- package/dist/lib/node-esm/types/index.mjs.map +0 -7
- package/dist/types/src/components/EditorToolbar/lists.d.ts +0 -19
- package/dist/types/src/components/EditorToolbar/lists.d.ts.map +0 -1
- package/dist/types/src/components/EditorToolbar/util.d.ts +0 -51
- package/dist/types/src/components/EditorToolbar/util.d.ts.map +0 -1
- package/dist/types/src/components/Popover/CommandMenu.d.ts +0 -34
- package/dist/types/src/components/Popover/CommandMenu.d.ts.map +0 -1
- package/dist/types/src/components/Popover/RefDropdownMenu.d.ts +0 -21
- package/dist/types/src/components/Popover/RefDropdownMenu.d.ts.map +0 -1
- package/dist/types/src/components/Popover/RefPopover.d.ts +0 -34
- package/dist/types/src/components/Popover/RefPopover.d.ts.map +0 -1
- package/dist/types/src/components/Popover/index.d.ts +0 -4
- package/dist/types/src/components/Popover/index.d.ts.map +0 -1
- package/dist/types/src/defaults.d.ts +0 -14
- package/dist/types/src/defaults.d.ts.map +0 -1
- package/dist/types/src/extensions/annotations.d.ts +0 -9
- package/dist/types/src/extensions/annotations.d.ts.map +0 -1
- package/dist/types/src/extensions/autocomplete.d.ts +0 -13
- package/dist/types/src/extensions/autocomplete.d.ts.map +0 -1
- package/dist/types/src/extensions/automerge/automerge.d.ts +0 -4
- package/dist/types/src/extensions/automerge/automerge.d.ts.map +0 -1
- package/dist/types/src/extensions/automerge/automerge.stories.d.ts.map +0 -1
- package/dist/types/src/extensions/automerge/automerge.test.d.ts +0 -2
- package/dist/types/src/extensions/automerge/automerge.test.d.ts.map +0 -1
- package/dist/types/src/extensions/automerge/cursor.d.ts +0 -4
- package/dist/types/src/extensions/automerge/cursor.d.ts.map +0 -1
- package/dist/types/src/extensions/automerge/defs.d.ts +0 -17
- package/dist/types/src/extensions/automerge/defs.d.ts.map +0 -1
- package/dist/types/src/extensions/automerge/index.d.ts +0 -2
- package/dist/types/src/extensions/automerge/index.d.ts.map +0 -1
- package/dist/types/src/extensions/automerge/sync.d.ts +0 -17
- package/dist/types/src/extensions/automerge/sync.d.ts.map +0 -1
- package/dist/types/src/extensions/automerge/update-automerge.d.ts +0 -6
- package/dist/types/src/extensions/automerge/update-automerge.d.ts.map +0 -1
- package/dist/types/src/extensions/automerge/update-codemirror.d.ts +0 -5
- package/dist/types/src/extensions/automerge/update-codemirror.d.ts.map +0 -1
- package/dist/types/src/extensions/awareness/awareness-provider.d.ts +0 -31
- package/dist/types/src/extensions/awareness/awareness-provider.d.ts.map +0 -1
- package/dist/types/src/extensions/awareness/awareness.d.ts +0 -46
- package/dist/types/src/extensions/awareness/awareness.d.ts.map +0 -1
- package/dist/types/src/extensions/awareness/index.d.ts +0 -3
- package/dist/types/src/extensions/awareness/index.d.ts.map +0 -1
- package/dist/types/src/extensions/blast.d.ts +0 -25
- package/dist/types/src/extensions/blast.d.ts.map +0 -1
- package/dist/types/src/extensions/command/action.d.ts +0 -17
- package/dist/types/src/extensions/command/action.d.ts.map +0 -1
- package/dist/types/src/extensions/command/command-menu.d.ts +0 -20
- package/dist/types/src/extensions/command/command-menu.d.ts.map +0 -1
- package/dist/types/src/extensions/command/command.d.ts +0 -6
- package/dist/types/src/extensions/command/command.d.ts.map +0 -1
- package/dist/types/src/extensions/command/floating-menu.d.ts +0 -7
- package/dist/types/src/extensions/command/floating-menu.d.ts.map +0 -1
- package/dist/types/src/extensions/command/hint.d.ts +0 -24
- package/dist/types/src/extensions/command/hint.d.ts.map +0 -1
- package/dist/types/src/extensions/command/index.d.ts +0 -7
- package/dist/types/src/extensions/command/index.d.ts.map +0 -1
- package/dist/types/src/extensions/command/placeholder.d.ts +0 -10
- package/dist/types/src/extensions/command/placeholder.d.ts.map +0 -1
- package/dist/types/src/extensions/command/state.d.ts +0 -16
- package/dist/types/src/extensions/command/state.d.ts.map +0 -1
- package/dist/types/src/extensions/command/typeahead.d.ts +0 -22
- package/dist/types/src/extensions/command/typeahead.d.ts.map +0 -1
- package/dist/types/src/extensions/command/useCommandMenu.d.ts +0 -26
- package/dist/types/src/extensions/command/useCommandMenu.d.ts.map +0 -1
- package/dist/types/src/extensions/comments.d.ts +0 -95
- package/dist/types/src/extensions/comments.d.ts.map +0 -1
- package/dist/types/src/extensions/debug.d.ts +0 -3
- package/dist/types/src/extensions/debug.d.ts.map +0 -1
- package/dist/types/src/extensions/dnd.d.ts +0 -9
- package/dist/types/src/extensions/dnd.d.ts.map +0 -1
- package/dist/types/src/extensions/factories.d.ts +0 -83
- package/dist/types/src/extensions/factories.d.ts.map +0 -1
- package/dist/types/src/extensions/focus.d.ts +0 -7
- package/dist/types/src/extensions/focus.d.ts.map +0 -1
- package/dist/types/src/extensions/folding.d.ts +0 -7
- package/dist/types/src/extensions/folding.d.ts.map +0 -1
- package/dist/types/src/extensions/hashtag.d.ts +0 -3
- package/dist/types/src/extensions/hashtag.d.ts.map +0 -1
- package/dist/types/src/extensions/index.d.ts +0 -23
- package/dist/types/src/extensions/index.d.ts.map +0 -1
- package/dist/types/src/extensions/json.d.ts +0 -7
- package/dist/types/src/extensions/json.d.ts.map +0 -1
- package/dist/types/src/extensions/listener.d.ts +0 -11
- package/dist/types/src/extensions/listener.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/action.d.ts +0 -12
- package/dist/types/src/extensions/markdown/action.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/bundle.d.ts +0 -16
- package/dist/types/src/extensions/markdown/bundle.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/changes.d.ts +0 -10
- package/dist/types/src/extensions/markdown/changes.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/changes.test.d.ts +0 -2
- package/dist/types/src/extensions/markdown/changes.test.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/debug.d.ts +0 -11
- package/dist/types/src/extensions/markdown/debug.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/decorate.d.ts +0 -17
- package/dist/types/src/extensions/markdown/decorate.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/formatting.d.ts +0 -63
- package/dist/types/src/extensions/markdown/formatting.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/formatting.test.d.ts +0 -3
- package/dist/types/src/extensions/markdown/formatting.test.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/highlight.d.ts +0 -37
- package/dist/types/src/extensions/markdown/highlight.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/image.d.ts +0 -7
- package/dist/types/src/extensions/markdown/image.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/index.d.ts +0 -10
- package/dist/types/src/extensions/markdown/index.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/link.d.ts +0 -7
- package/dist/types/src/extensions/markdown/link.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/parser.test.d.ts +0 -2
- package/dist/types/src/extensions/markdown/parser.test.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/styles.d.ts +0 -4
- package/dist/types/src/extensions/markdown/styles.d.ts.map +0 -1
- package/dist/types/src/extensions/markdown/table.d.ts +0 -8
- package/dist/types/src/extensions/markdown/table.d.ts.map +0 -1
- package/dist/types/src/extensions/mention.d.ts +0 -7
- package/dist/types/src/extensions/mention.d.ts.map +0 -1
- package/dist/types/src/extensions/modes.d.ts +0 -10
- package/dist/types/src/extensions/modes.d.ts.map +0 -1
- package/dist/types/src/extensions/outliner/commands.d.ts +0 -10
- package/dist/types/src/extensions/outliner/commands.d.ts.map +0 -1
- package/dist/types/src/extensions/outliner/editor.d.ts +0 -5
- package/dist/types/src/extensions/outliner/editor.d.ts.map +0 -1
- package/dist/types/src/extensions/outliner/editor.test.d.ts +0 -2
- package/dist/types/src/extensions/outliner/editor.test.d.ts.map +0 -1
- package/dist/types/src/extensions/outliner/index.d.ts +0 -4
- package/dist/types/src/extensions/outliner/index.d.ts.map +0 -1
- package/dist/types/src/extensions/outliner/outliner.d.ts +0 -11
- package/dist/types/src/extensions/outliner/outliner.d.ts.map +0 -1
- package/dist/types/src/extensions/outliner/outliner.test.d.ts +0 -2
- package/dist/types/src/extensions/outliner/outliner.test.d.ts.map +0 -1
- package/dist/types/src/extensions/outliner/selection.d.ts +0 -12
- package/dist/types/src/extensions/outliner/selection.d.ts.map +0 -1
- package/dist/types/src/extensions/outliner/tree.d.ts +0 -79
- package/dist/types/src/extensions/outliner/tree.d.ts.map +0 -1
- package/dist/types/src/extensions/outliner/tree.test.d.ts +0 -2
- package/dist/types/src/extensions/outliner/tree.test.d.ts.map +0 -1
- package/dist/types/src/extensions/preview/index.d.ts +0 -2
- package/dist/types/src/extensions/preview/index.d.ts.map +0 -1
- package/dist/types/src/extensions/preview/preview.d.ts +0 -32
- package/dist/types/src/extensions/preview/preview.d.ts.map +0 -1
- package/dist/types/src/extensions/selection.d.ts +0 -24
- package/dist/types/src/extensions/selection.d.ts.map +0 -1
- package/dist/types/src/extensions/typewriter.d.ts +0 -10
- package/dist/types/src/extensions/typewriter.d.ts.map +0 -1
- package/dist/types/src/stories/Command.stories.d.ts +0 -7
- package/dist/types/src/stories/Command.stories.d.ts.map +0 -1
- package/dist/types/src/stories/CommandMenu.stories.d.ts +0 -13
- package/dist/types/src/stories/CommandMenu.stories.d.ts.map +0 -1
- package/dist/types/src/styles/index.d.ts +0 -4
- package/dist/types/src/styles/index.d.ts.map +0 -1
- package/dist/types/src/styles/markdown.d.ts +0 -8
- package/dist/types/src/styles/markdown.d.ts.map +0 -1
- package/dist/types/src/styles/theme.d.ts +0 -38
- package/dist/types/src/styles/theme.d.ts.map +0 -1
- package/dist/types/src/styles/tokens.d.ts +0 -3
- package/dist/types/src/styles/tokens.d.ts.map +0 -1
- package/dist/types/src/testing/index.d.ts +0 -2
- package/dist/types/src/testing/index.d.ts.map +0 -1
- package/dist/types/src/testing/util.d.ts +0 -2
- package/dist/types/src/testing/util.d.ts.map +0 -1
- package/dist/types/src/types/index.d.ts +0 -2
- package/dist/types/src/types/index.d.ts.map +0 -1
- package/dist/types/src/types/types.d.ts +0 -21
- package/dist/types/src/types/types.d.ts.map +0 -1
- package/dist/types/src/util/cursor.d.ts +0 -31
- package/dist/types/src/util/cursor.d.ts.map +0 -1
- package/dist/types/src/util/debug.d.ts +0 -17
- package/dist/types/src/util/debug.d.ts.map +0 -1
- package/dist/types/src/util/dom.d.ts +0 -20
- package/dist/types/src/util/dom.d.ts.map +0 -1
- package/dist/types/src/util/facet.d.ts +0 -3
- package/dist/types/src/util/facet.d.ts.map +0 -1
- package/src/components/EditorToolbar/lists.ts +0 -59
- package/src/components/EditorToolbar/util.ts +0 -65
- package/src/components/Popover/CommandMenu.tsx +0 -279
- package/src/components/Popover/RefDropdownMenu.tsx +0 -85
- package/src/components/Popover/RefPopover.tsx +0 -99
- package/src/components/Popover/index.ts +0 -7
- package/src/defaults.ts +0 -49
- package/src/extensions/annotations.ts +0 -55
- package/src/extensions/autocomplete.ts +0 -69
- package/src/extensions/automerge/automerge.stories.tsx +0 -142
- package/src/extensions/automerge/automerge.test.tsx +0 -78
- package/src/extensions/automerge/automerge.ts +0 -85
- package/src/extensions/automerge/cursor.ts +0 -28
- package/src/extensions/automerge/defs.ts +0 -31
- package/src/extensions/automerge/index.ts +0 -5
- package/src/extensions/automerge/sync.ts +0 -75
- package/src/extensions/automerge/update-automerge.ts +0 -50
- package/src/extensions/automerge/update-codemirror.ts +0 -115
- package/src/extensions/awareness/awareness-provider.ts +0 -127
- package/src/extensions/awareness/awareness.ts +0 -315
- package/src/extensions/awareness/index.ts +0 -6
- package/src/extensions/blast.ts +0 -363
- package/src/extensions/command/action.ts +0 -56
- package/src/extensions/command/command-menu.ts +0 -210
- package/src/extensions/command/command.ts +0 -34
- package/src/extensions/command/floating-menu.ts +0 -133
- package/src/extensions/command/hint.ts +0 -102
- package/src/extensions/command/index.ts +0 -10
- package/src/extensions/command/placeholder.ts +0 -113
- package/src/extensions/command/state.ts +0 -89
- package/src/extensions/command/typeahead.ts +0 -129
- package/src/extensions/command/useCommandMenu.ts +0 -118
- package/src/extensions/comments.ts +0 -592
- package/src/extensions/debug.ts +0 -15
- package/src/extensions/dnd.ts +0 -37
- package/src/extensions/factories.ts +0 -259
- package/src/extensions/focus.ts +0 -35
- package/src/extensions/folding.tsx +0 -46
- package/src/extensions/hashtag.tsx +0 -68
- package/src/extensions/index.ts +0 -26
- package/src/extensions/json.ts +0 -57
- package/src/extensions/listener.ts +0 -38
- package/src/extensions/markdown/action.ts +0 -116
- package/src/extensions/markdown/bundle.ts +0 -71
- package/src/extensions/markdown/changes.test.ts +0 -26
- package/src/extensions/markdown/changes.ts +0 -149
- package/src/extensions/markdown/debug.ts +0 -44
- package/src/extensions/markdown/decorate.ts +0 -591
- package/src/extensions/markdown/formatting.test.ts +0 -498
- package/src/extensions/markdown/formatting.ts +0 -1267
- package/src/extensions/markdown/highlight.ts +0 -183
- package/src/extensions/markdown/image.ts +0 -119
- package/src/extensions/markdown/index.ts +0 -13
- package/src/extensions/markdown/link.ts +0 -47
- package/src/extensions/markdown/parser.test.ts +0 -75
- package/src/extensions/markdown/styles.ts +0 -135
- package/src/extensions/markdown/table.ts +0 -144
- package/src/extensions/mention.ts +0 -41
- package/src/extensions/modes.ts +0 -41
- package/src/extensions/outliner/commands.ts +0 -270
- package/src/extensions/outliner/editor.test.ts +0 -33
- package/src/extensions/outliner/editor.ts +0 -184
- package/src/extensions/outliner/index.ts +0 -7
- package/src/extensions/outliner/outliner.test.ts +0 -99
- package/src/extensions/outliner/outliner.ts +0 -166
- package/src/extensions/outliner/selection.ts +0 -50
- package/src/extensions/outliner/tree.test.ts +0 -167
- package/src/extensions/outliner/tree.ts +0 -317
- package/src/extensions/preview/index.ts +0 -5
- package/src/extensions/preview/preview.ts +0 -193
- package/src/extensions/selection.ts +0 -100
- package/src/extensions/typewriter.ts +0 -68
- package/src/stories/Command.stories.tsx +0 -97
- package/src/stories/CommandMenu.stories.tsx +0 -159
- package/src/styles/index.ts +0 -7
- package/src/styles/markdown.ts +0 -26
- package/src/styles/theme.ts +0 -265
- package/src/styles/tokens.ts +0 -17
- package/src/testing/index.ts +0 -5
- package/src/testing/util.ts +0 -5
- package/src/types/index.ts +0 -5
- package/src/types/types.ts +0 -32
- package/src/util/cursor.ts +0 -55
- package/src/util/debug.ts +0 -64
- package/src/util/dom.ts +0 -56
- package/src/util/facet.ts +0 -13
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
export * from './action';
|
|
2
|
-
export * from './bundle';
|
|
3
|
-
export * from './debug';
|
|
4
|
-
export * from './decorate';
|
|
5
|
-
export * from './formatting';
|
|
6
|
-
export * from './highlight';
|
|
7
|
-
export * from './image';
|
|
8
|
-
export * from './link';
|
|
9
|
-
export * from './table';
|
|
10
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/markdown/index.ts"],"names":[],"mappings":"AAIA,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,SAAS,CAAC"}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { type RenderCallback } from '../../types';
|
|
2
|
-
export declare const linkTooltip: (renderTooltip: RenderCallback<{
|
|
3
|
-
url: string;
|
|
4
|
-
}>) => import("@codemirror/state").Extension & {
|
|
5
|
-
active: import("@codemirror/state").StateField<readonly import("@codemirror/view").Tooltip[]>;
|
|
6
|
-
};
|
|
7
|
-
//# sourceMappingURL=link.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"link.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/markdown/link.ts"],"names":[],"mappings":"AAWA,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,aAAa,CAAC;AAElD,eAAO,MAAM,WAAW,GAAI,eAAe,cAAc,CAAC;IAAE,GAAG,EAAE,MAAM,CAAA;CAAE,CAAC;;CAiCzE,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"parser.test.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/markdown/parser.test.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/markdown/styles.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,0BAA0B,KAAK,CAAC;AAC7C,eAAO,MAAM,2BAA2B,KAAK,CAAC;AAE9C,eAAO,MAAM,gBAAgB,uCA2H3B,CAAC"}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { type Extension } from '@codemirror/state';
|
|
2
|
-
export type TableOptions = {};
|
|
3
|
-
/**
|
|
4
|
-
* GFM tables.
|
|
5
|
-
* https://github.github.com/gfm/#tables-extension
|
|
6
|
-
*/
|
|
7
|
-
export declare const table: (options?: TableOptions) => Extension;
|
|
8
|
-
//# sourceMappingURL=table.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"table.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/markdown/table.ts"],"names":[],"mappings":"AAKA,OAAO,EAEL,KAAK,SAAS,EAKf,MAAM,mBAAmB,CAAC;AAQ3B,MAAM,MAAM,YAAY,GAAG,EAAE,CAAC;AAE9B;;;GAGG;AACH,eAAO,MAAM,KAAK,GAAI,UAAS,YAAiB,KAAG,SAMlD,CAAC"}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import type { Extension } from '@codemirror/state';
|
|
2
|
-
export type MentionOptions = {
|
|
3
|
-
debug?: boolean;
|
|
4
|
-
onSearch: (text: string) => string[];
|
|
5
|
-
};
|
|
6
|
-
export declare const mention: ({ debug, onSearch }: MentionOptions) => Extension;
|
|
7
|
-
//# sourceMappingURL=mention.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"mention.d.ts","sourceRoot":"","sources":["../../../../src/extensions/mention.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAInD,MAAM,MAAM,cAAc,GAAG;IAC3B,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,MAAM,EAAE,CAAC;CACtC,CAAC;AAGF,eAAO,MAAM,OAAO,GAAI,qBAAqB,cAAc,KAAG,SAyB7D,CAAC"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { type Extension } from '@codemirror/state';
|
|
2
|
-
export type EditorInputConfig = {
|
|
3
|
-
type?: string;
|
|
4
|
-
noTabster?: boolean;
|
|
5
|
-
};
|
|
6
|
-
export declare const editorInputMode: import("@codemirror/state").Facet<EditorInputConfig, EditorInputConfig>;
|
|
7
|
-
export declare const InputModeExtensions: {
|
|
8
|
-
[mode: string]: Extension;
|
|
9
|
-
};
|
|
10
|
-
//# sourceMappingURL=modes.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"modes.d.ts","sourceRoot":"","sources":["../../../../src/extensions/modes.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAOnD,MAAM,MAAM,iBAAiB,GAAG;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB,CAAC;AAEF,eAAO,MAAM,eAAe,yEAA0C,CAAC;AAEvE,eAAO,MAAM,mBAAmB,EAAE;IAAE,CAAC,IAAI,EAAE,MAAM,GAAG,SAAS,CAAA;CAsB5D,CAAC"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { type Extension } from '@codemirror/state';
|
|
2
|
-
import { type Command } from '@codemirror/view';
|
|
3
|
-
export declare const indentItemMore: Command;
|
|
4
|
-
export declare const indentItemLess: Command;
|
|
5
|
-
export declare const moveItemDown: Command;
|
|
6
|
-
export declare const moveItemUp: Command;
|
|
7
|
-
export declare const deleteItem: Command;
|
|
8
|
-
export declare const toggleTask: Command;
|
|
9
|
-
export declare const commands: () => Extension;
|
|
10
|
-
//# sourceMappingURL=commands.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"commands.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/outliner/commands.ts"],"names":[],"mappings":"AAMA,OAAO,EAAoC,KAAK,SAAS,EAAE,MAAM,mBAAmB,CAAC;AACrF,OAAO,EAAE,KAAK,OAAO,EAA2B,MAAM,kBAAkB,CAAC;AASzE,eAAO,MAAM,cAAc,EAAE,OAa5B,CAAC;AAEF,eAAO,MAAM,cAAc,EAAE,OAsB5B,CAAC;AAMF,eAAO,MAAM,YAAY,EAAE,OA6B1B,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,OA6BxB,CAAC;AAMF,eAAO,MAAM,UAAU,EAAE,OAiBxB,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,OAmBxB,CAAC;AAEF,eAAO,MAAM,QAAQ,QAAO,SAwGxB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"editor.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/outliner/editor.ts"],"names":[],"mappings":"AAsCA;;GAEG;AACH,eAAO,MAAM,MAAM,+CA8IlB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"editor.test.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/outliner/editor.test.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/outliner/index.ts"],"names":[],"mappings":"AAIA,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,QAAQ,CAAC"}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { type Extension } from '@codemirror/state';
|
|
2
|
-
export type OutlinerProps = {};
|
|
3
|
-
/**
|
|
4
|
-
* Outliner extension.
|
|
5
|
-
* - Stores outline as a standard markdown document with task and list markers.
|
|
6
|
-
* - Supports continuation lines and rich formatting (with Shift+Enter).
|
|
7
|
-
* - Constrains editor to outline structure.
|
|
8
|
-
* - Supports smart cut-and-paste.
|
|
9
|
-
*/
|
|
10
|
-
export declare const outliner: (options?: OutlinerProps) => Extension;
|
|
11
|
-
//# sourceMappingURL=outliner.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"outliner.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/outliner/outliner.ts"],"names":[],"mappings":"AAIA,OAAO,EAAoB,KAAK,SAAS,EAAoB,MAAM,mBAAmB,CAAC;AA0BvF,MAAM,MAAM,aAAa,GAAG,EAAE,CAAC;AAE/B;;;;;;GAMG;AACH,eAAO,MAAM,QAAQ,GAAI,UAAS,aAAkB,KAAG,SAwBtD,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"outliner.test.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/outliner/outliner.test.ts"],"names":[],"mappings":""}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { Compartment, type EditorState, Facet, type SelectionRange } from '@codemirror/state';
|
|
2
|
-
import { type Command } from '@codemirror/view';
|
|
3
|
-
export type Selection = number[];
|
|
4
|
-
export declare const getSelection: (state: EditorState) => SelectionRange;
|
|
5
|
-
export declare const selectionEquals: (a: number[], b: number[]) => boolean;
|
|
6
|
-
export declare const selectionFacet: Facet<Selection, Selection>;
|
|
7
|
-
export declare const selectionCompartment: Compartment;
|
|
8
|
-
export declare const selectNone: Command;
|
|
9
|
-
export declare const selectAll: Command;
|
|
10
|
-
export declare const selectUp: Command;
|
|
11
|
-
export declare const selectDown: Command;
|
|
12
|
-
//# sourceMappingURL=selection.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"selection.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/outliner/selection.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,KAAK,WAAW,EAAE,KAAK,EAAE,KAAK,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAC9F,OAAO,EAAmB,KAAK,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAIjE,MAAM,MAAM,SAAS,GAAG,MAAM,EAAE,CAAC;AAEjC,eAAO,MAAM,YAAY,GAAI,OAAO,WAAW,KAAG,cAAsC,CAAC;AAEzF,eAAO,MAAM,eAAe,GAAI,GAAG,MAAM,EAAE,EAAE,GAAG,MAAM,EAAE,YAA2D,CAAC;AAEpH,eAAO,MAAM,cAAc,6BAEzB,CAAC;AAEH,eAAO,MAAM,oBAAoB,aAAoB,CAAC;AAEtD,eAAO,MAAM,UAAU,EAAE,OAMxB,CAAC;AAEF,eAAO,MAAM,SAAS,EAAE,OAUvB,CAAC;AAGF,eAAO,MAAM,QAAQ,EAAE,OAEtB,CAAC;AAGF,eAAO,MAAM,UAAU,EAAE,OAExB,CAAC"}
|
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
import { type Extension, type EditorState } from '@codemirror/state';
|
|
2
|
-
import { Facet } from '@codemirror/state';
|
|
3
|
-
import { type SyntaxNode } from '@lezer/common';
|
|
4
|
-
import { type Range } from '../../types';
|
|
5
|
-
/**
|
|
6
|
-
* Represents a single item in the tree.
|
|
7
|
-
*/
|
|
8
|
-
export interface Item {
|
|
9
|
-
type: 'root' | 'bullet' | 'task' | 'unknown';
|
|
10
|
-
index: number;
|
|
11
|
-
level: number;
|
|
12
|
-
node: SyntaxNode;
|
|
13
|
-
parent?: Item;
|
|
14
|
-
nextSibling?: Item;
|
|
15
|
-
prevSibling?: Item;
|
|
16
|
-
children: Item[];
|
|
17
|
-
/**
|
|
18
|
-
* Actual range.
|
|
19
|
-
* Starts at the start of the line containing the item and ends at the end of the line before the
|
|
20
|
-
* first child or next sibling.
|
|
21
|
-
*/
|
|
22
|
-
lineRange: Range;
|
|
23
|
-
/**
|
|
24
|
-
* Range of the editable content.
|
|
25
|
-
* This doesn't include the list or task marker or indentation.
|
|
26
|
-
*/
|
|
27
|
-
contentRange: Range;
|
|
28
|
-
}
|
|
29
|
-
export declare const itemToJSON: ({ type, index, level, lineRange, contentRange, children }: Item) => any;
|
|
30
|
-
/**
|
|
31
|
-
* Tree assumes the entire document is a single contiguous well-formed hierarchy of markdown LiteItem nodes.
|
|
32
|
-
*/
|
|
33
|
-
export declare class Tree implements Item {
|
|
34
|
-
type: Item['type'];
|
|
35
|
-
index: number;
|
|
36
|
-
level: number;
|
|
37
|
-
node: Item['node'];
|
|
38
|
-
lineRange: Item['lineRange'];
|
|
39
|
-
contentRange: Item['contentRange'];
|
|
40
|
-
children: Item['children'];
|
|
41
|
-
constructor(node: SyntaxNode);
|
|
42
|
-
toJSON(): any;
|
|
43
|
-
get root(): Item;
|
|
44
|
-
traverse<T = any>(cb: (item: Item, level: number) => T | void): T | undefined;
|
|
45
|
-
traverse<T = any>(item: Item, cb: (item: Item, level: number) => T | void): T | undefined;
|
|
46
|
-
/**
|
|
47
|
-
* Return the closest item.
|
|
48
|
-
*/
|
|
49
|
-
find(pos: number): Item | undefined;
|
|
50
|
-
/**
|
|
51
|
-
* Return the first child, next sibling, or parent's next sibling.
|
|
52
|
-
*/
|
|
53
|
-
next(item: Item, enter?: boolean): Item | undefined;
|
|
54
|
-
/**
|
|
55
|
-
* Return the previous sibling, or parent.
|
|
56
|
-
*/
|
|
57
|
-
prev(item: Item): Item | undefined;
|
|
58
|
-
/**
|
|
59
|
-
* Return the last descendant of the item, or the item itself if it has no children.
|
|
60
|
-
*/
|
|
61
|
-
lastDescendant(item: Item): Item;
|
|
62
|
-
}
|
|
63
|
-
export declare const getRange: (tree: Tree, item: Item) => [number, number];
|
|
64
|
-
/**
|
|
65
|
-
* Traverse the tree, calling the callback for each item.
|
|
66
|
-
* If the callback returns a value, the traversal is stopped and the value is returned.
|
|
67
|
-
*/
|
|
68
|
-
export declare const traverse: <T = any>(root: Item, cb: (item: Item, level: number) => T | void) => T | undefined;
|
|
69
|
-
export declare const getListItemContent: (state: EditorState, item: Item) => string;
|
|
70
|
-
export declare const listItemToString: (item: Item, level?: number) => string;
|
|
71
|
-
export declare const treeFacet: Facet<Tree, Tree>;
|
|
72
|
-
export type TreeOptions = {};
|
|
73
|
-
/**
|
|
74
|
-
* Creates a shadow tree of `ListItem` nodes whenever the document changes.
|
|
75
|
-
* This adds overhead relative to the markdown AST, but allows for efficient traversal of the list items.
|
|
76
|
-
* NOTE: Requires markdown parser to be enabled.
|
|
77
|
-
*/
|
|
78
|
-
export declare const outlinerTree: (options?: TreeOptions) => Extension;
|
|
79
|
-
//# sourceMappingURL=tree.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"tree.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/outliner/tree.ts"],"names":[],"mappings":"AAKA,OAAO,EAAgC,KAAK,SAAS,EAAE,KAAK,WAAW,EAAE,MAAM,mBAAmB,CAAC;AACnG,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,eAAe,CAAC;AAIhD,OAAO,EAAE,KAAK,KAAK,EAAE,MAAM,aAAa,CAAC;AAEzC;;GAEG;AACH,MAAM,WAAW,IAAI;IACnB,IAAI,EAAE,MAAM,GAAG,QAAQ,GAAG,MAAM,GAAG,SAAS,CAAC;IAC7C,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,UAAU,CAAC;IACjB,MAAM,CAAC,EAAE,IAAI,CAAC;IACd,WAAW,CAAC,EAAE,IAAI,CAAC;IACnB,WAAW,CAAC,EAAE,IAAI,CAAC;IACnB,QAAQ,EAAE,IAAI,EAAE,CAAC;IACjB;;;;OAIG;IACH,SAAS,EAAE,KAAK,CAAC;IACjB;;;OAGG;IACH,YAAY,EAAE,KAAK,CAAC;CACrB;AAED,eAAO,MAAM,UAAU,GAAI,2DAA2D,IAAI,KAAG,GAE5F,CAAC;AAEF;;GAEG;AACH,qBAAa,IAAK,YAAW,IAAI;IAC/B,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC,CAAU;IAC5B,KAAK,SAAM;IACX,KAAK,SAAM;IACX,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC,CAAC;IACnB,SAAS,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;IAC7B,YAAY,EAAE,IAAI,CAAC,cAAc,CAAC,CAAC;IACnC,QAAQ,EAAE,IAAI,CAAC,UAAU,CAAC,CAAM;gBAEpB,IAAI,EAAE,UAAU;IAM5B,MAAM;IAIN,IAAI,IAAI,IAAI,IAAI,CAEf;IAED,QAAQ,CAAC,CAAC,GAAG,GAAG,EAAE,EAAE,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,KAAK,CAAC,GAAG,IAAI,GAAG,CAAC,GAAG,SAAS;IAC7E,QAAQ,CAAC,CAAC,GAAG,GAAG,EAAE,IAAI,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,KAAK,CAAC,GAAG,IAAI,GAAG,CAAC,GAAG,SAAS;IAYzF;;OAEG;IACH,IAAI,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS;IAInC;;OAEG;IACH,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,KAAK,UAAO,GAAG,IAAI,GAAG,SAAS;IAgBhD;;OAEG;IACH,IAAI,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,GAAG,SAAS;IAQlC;;OAEG;IACH,cAAc,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI;CAGjC;AAED,eAAO,MAAM,QAAQ,GAAI,MAAM,IAAI,EAAE,MAAM,IAAI,KAAG,CAAC,MAAM,EAAE,MAAM,CAGhE,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,QAAQ,GAAI,CAAC,GAAG,GAAG,EAAE,MAAM,IAAI,EAAE,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,KAAK,CAAC,GAAG,IAAI,KAAG,CAAC,GAAG,SAoB/F,CAAC;AAEF,eAAO,MAAM,kBAAkB,GAAI,OAAO,WAAW,EAAE,MAAM,IAAI,KAAG,MAEnE,CAAC;AAEF,eAAO,MAAM,gBAAgB,GAAI,MAAM,IAAI,EAAE,cAAS,WAerD,CAAC;AAUF,eAAO,MAAM,SAAS,mBAEpB,CAAC;AAEH,MAAM,MAAM,WAAW,GAAG,EAAE,CAAC;AAE7B;;;;GAIG;AACH,eAAO,MAAM,YAAY,GAAI,UAAS,WAAgB,KAAG,SAuHxD,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"tree.test.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/outliner/tree.test.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/preview/index.ts"],"names":[],"mappings":"AAIA,cAAc,WAAW,CAAC"}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import '@dxos/lit-ui/dx-ref-tag.pcss';
|
|
2
|
-
import { type EditorState, type Extension } from '@codemirror/state';
|
|
3
|
-
import { type SyntaxNode } from '@lezer/common';
|
|
4
|
-
export type PreviewLinkRef = {
|
|
5
|
-
suggest?: boolean;
|
|
6
|
-
block?: boolean;
|
|
7
|
-
label: string;
|
|
8
|
-
ref: string;
|
|
9
|
-
};
|
|
10
|
-
export type PreviewLinkTarget = {
|
|
11
|
-
label: string;
|
|
12
|
-
text?: string;
|
|
13
|
-
object?: any;
|
|
14
|
-
};
|
|
15
|
-
export type PreviewLookup = (link: PreviewLinkRef) => Promise<PreviewLinkTarget | null | undefined>;
|
|
16
|
-
export type PreviewOptions = {
|
|
17
|
-
addBlockContainer?: (link: PreviewLinkRef, el: HTMLElement) => void;
|
|
18
|
-
removeBlockContainer?: (link: PreviewLinkRef) => void;
|
|
19
|
-
};
|
|
20
|
-
/**
|
|
21
|
-
* Create preview decorations.
|
|
22
|
-
*/
|
|
23
|
-
export declare const preview: (options?: PreviewOptions) => Extension;
|
|
24
|
-
/**
|
|
25
|
-
* Link references.
|
|
26
|
-
*
|
|
27
|
-
* [Label][dxn:echo:123] Inline reference
|
|
28
|
-
* ![Label][dxn:echo:123] Block reference
|
|
29
|
-
* ![Label][?dxn:echo:123] Suggestion
|
|
30
|
-
*/
|
|
31
|
-
export declare const getLinkRef: (state: EditorState, node: SyntaxNode) => PreviewLinkRef | undefined;
|
|
32
|
-
//# sourceMappingURL=preview.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"preview.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/preview/preview.ts"],"names":[],"mappings":"AAIA,OAAO,8BAA8B,CAAC;AAGtC,OAAO,EACL,KAAK,WAAW,EAChB,KAAK,SAAS,EAKf,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,eAAe,CAAC;AAEhD,MAAM,MAAM,cAAc,GAAG;IAC3B,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,CAAC;CACb,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG;IAC9B,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,GAAG,CAAC;CACd,CAAC;AAIF,MAAM,MAAM,aAAa,GAAG,CAAC,IAAI,EAAE,cAAc,KAAK,OAAO,CAAC,iBAAiB,GAAG,IAAI,GAAG,SAAS,CAAC,CAAC;AAEpG,MAAM,MAAM,cAAc,GAAG;IAC3B,iBAAiB,CAAC,EAAE,CAAC,IAAI,EAAE,cAAc,EAAE,EAAE,EAAE,WAAW,KAAK,IAAI,CAAC;IACpE,oBAAoB,CAAC,EAAE,CAAC,IAAI,EAAE,cAAc,KAAK,IAAI,CAAC;CACvD,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,OAAO,GAAI,UAAS,cAAmB,KAAG,SAatD,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,UAAU,GAAI,OAAO,WAAW,EAAE,MAAM,UAAU,KAAG,cAAc,GAAG,SAYlF,CAAC"}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { type Extension, type TransactionSpec } from '@codemirror/state';
|
|
2
|
-
/**
|
|
3
|
-
* Currently edited document id as FQ string.
|
|
4
|
-
*/
|
|
5
|
-
export declare const documentId: import("@codemirror/state").Facet<string, string>;
|
|
6
|
-
export type EditorSelection = {
|
|
7
|
-
anchor: number;
|
|
8
|
-
head?: number;
|
|
9
|
-
};
|
|
10
|
-
export type EditorSelectionState = {
|
|
11
|
-
scrollTo?: number;
|
|
12
|
-
selection?: EditorSelection;
|
|
13
|
-
};
|
|
14
|
-
export type EditorStateStore = {
|
|
15
|
-
setState: (id: string, state: EditorSelectionState) => void;
|
|
16
|
-
getState: (id: string) => EditorSelectionState | undefined;
|
|
17
|
-
};
|
|
18
|
-
export declare const createEditorStateTransaction: ({ scrollTo, selection }: EditorSelectionState) => TransactionSpec;
|
|
19
|
-
export declare const createEditorStateStore: (keyPrefix: string) => EditorStateStore;
|
|
20
|
-
/**
|
|
21
|
-
* Track scrolling and selection state to be restored when switching to document.
|
|
22
|
-
*/
|
|
23
|
-
export declare const selectionState: ({ getState, setState }?: Partial<EditorStateStore>) => Extension;
|
|
24
|
-
//# sourceMappingURL=selection.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"selection.d.ts","sourceRoot":"","sources":["../../../../src/extensions/selection.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,SAAS,EAAe,KAAK,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAStF;;GAEG;AACH,eAAO,MAAM,UAAU,mDAA6B,CAAC;AAErD,MAAM,MAAM,eAAe,GAAG;IAC5B,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,MAAM,MAAM,oBAAoB,GAAG;IACjC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,eAAe,CAAC;CAC7B,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG;IAC7B,QAAQ,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,oBAAoB,KAAK,IAAI,CAAC;IAC5D,QAAQ,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,oBAAoB,GAAG,SAAS,CAAC;CAC5D,CAAC;AAIF,eAAO,MAAM,4BAA4B,GAAI,yBAAyB,oBAAoB,KAAG,eAO5F,CAAC;AAEF,eAAO,MAAM,sBAAsB,GAAI,WAAW,MAAM,KAAG,gBAWzD,CAAC;AAEH;;GAEG;AACH,eAAO,MAAM,cAAc,GAAI,yBAAwB,OAAO,CAAC,gBAAgB,CAAM,KAAG,SAuCvF,CAAC"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { type Extension } from '@codemirror/state';
|
|
2
|
-
export type DemoOptions = {
|
|
3
|
-
delay?: number;
|
|
4
|
-
items?: string[];
|
|
5
|
-
};
|
|
6
|
-
/**
|
|
7
|
-
* Configurable plugin that let's user cycle through pre-configured input script.
|
|
8
|
-
*/
|
|
9
|
-
export declare const typewriter: ({ delay, items }?: DemoOptions) => Extension;
|
|
10
|
-
//# sourceMappingURL=typewriter.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"typewriter.d.ts","sourceRoot":"","sources":["../../../../src/extensions/typewriter.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAKnD,MAAM,MAAM,WAAW,GAAG;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;CAClB,CAAC;AAIF;;GAEG;AACH,eAAO,MAAM,UAAU,GAAI,mBAAsC,WAAgB,KAAG,SAgDnF,CAAC"}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import '@dxos-theme';
|
|
2
|
-
import { type Meta } from '@dxos/storybook-utils';
|
|
3
|
-
import { EditorStory } from './components';
|
|
4
|
-
declare const meta: Meta<typeof EditorStory>;
|
|
5
|
-
export default meta;
|
|
6
|
-
export declare const Default: {};
|
|
7
|
-
//# sourceMappingURL=Command.stories.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Command.stories.d.ts","sourceRoot":"","sources":["../../../../src/stories/Command.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAMrB,OAAO,EAAyB,KAAK,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAEzE,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAsD3C,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,WAAW,CA0BlC,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,eAAO,MAAM,OAAO,IAAK,CAAC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import '@dxos-theme';
|
|
2
|
-
import { type StoryObj } from '@storybook/react-vite';
|
|
3
|
-
import { type Meta } from '@dxos/storybook-utils';
|
|
4
|
-
import { type UseCommandMenuOptions } from '../extensions';
|
|
5
|
-
type StoryProps = Omit<UseCommandMenuOptions, 'viewRef'> & {
|
|
6
|
-
text: string;
|
|
7
|
-
};
|
|
8
|
-
declare const meta: Meta<StoryProps>;
|
|
9
|
-
export default meta;
|
|
10
|
-
type Story = StoryObj<StoryProps>;
|
|
11
|
-
export declare const Slash: Story;
|
|
12
|
-
export declare const Link: Story;
|
|
13
|
-
//# sourceMappingURL=CommandMenu.stories.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"CommandMenu.stories.d.ts","sourceRoot":"","sources":["../../../../src/stories/CommandMenu.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAGrB,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAOtD,OAAO,EAAyB,KAAK,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAczE,OAAO,EAAkB,KAAK,qBAAqB,EAAE,MAAM,eAAe,CAAC;AAM3E,KAAK,UAAU,GAAG,IAAI,CAAC,qBAAqB,EAAE,SAAS,CAAC,GAAG;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC;AA+B5E,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,UAAU,CAO1B,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC,UAAU,CAAC,CAAC;AAGlC,eAAO,MAAM,KAAK,EAAE,KAmBnB,CAAC;AAEF,eAAO,MAAM,IAAI,EAAE,KA0DlB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/styles/index.ts"],"names":[],"mappings":"AAIA,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"markdown.d.ts","sourceRoot":"","sources":["../../../../src/styles/markdown.ts"],"names":[],"mappings":"AAMA,MAAM,MAAM,YAAY,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;AAYjD,eAAO,MAAM,KAAK;;;;qBAIC,YAAY;CAG9B,CAAC"}
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { type StyleSpec } from 'style-mod';
|
|
2
|
-
export type ThemeStyles = Record<string, StyleSpec>;
|
|
3
|
-
/**
|
|
4
|
-
* Minimal styles.
|
|
5
|
-
* https://codemirror.net/examples/styling
|
|
6
|
-
*
|
|
7
|
-
* Examples:
|
|
8
|
-
* - https://github.com/codemirror/view/blob/main/src/theme.ts
|
|
9
|
-
* - https://github.com/codemirror/theme-one-dark/blob/main/src/one-dark.ts
|
|
10
|
-
*
|
|
11
|
-
* Main layout:
|
|
12
|
-
* https://codemirror.net/examples/styling
|
|
13
|
-
* https://codemirror.net/docs/guide (DOM Structure).
|
|
14
|
-
*
|
|
15
|
-
* <div class="cm-editor [cm-focused] [generated classes]">
|
|
16
|
-
* <div class="cm-scroller">
|
|
17
|
-
* <div class="cm-gutters">
|
|
18
|
-
* <div class="cm-gutter [...]">
|
|
19
|
-
* <div class="cm-gutterElement">...</div>
|
|
20
|
-
* </div>
|
|
21
|
-
* </div>
|
|
22
|
-
* <div class="cm-content" role="textbox" contenteditable="true">
|
|
23
|
-
* <div class="cm-line"></div>
|
|
24
|
-
* </div>
|
|
25
|
-
* <div class="cm-selectionLayer">
|
|
26
|
-
* <div class="cm-selectionBackground"></div>
|
|
27
|
-
* </div>
|
|
28
|
-
* <div class="cm-cursorLayer">
|
|
29
|
-
* <div class="cm-cursor"></div>
|
|
30
|
-
* </div>
|
|
31
|
-
* </div>
|
|
32
|
-
* </div>
|
|
33
|
-
*
|
|
34
|
-
* NOTE: `light` and `dark` selectors are preprocessed by CodeMirror and can only be in the base theme.
|
|
35
|
-
* NOTE: Use 'unset' to remove default CM style.
|
|
36
|
-
*/
|
|
37
|
-
export declare const defaultTheme: ThemeStyles;
|
|
38
|
-
//# sourceMappingURL=theme.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../../../src/styles/theme.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,WAAW,CAAC;AAI3C,MAAM,MAAM,WAAW,GAAG,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;AAEpD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,eAAO,MAAM,YAAY,EAAE,WA4N1B,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"tokens.d.ts","sourceRoot":"","sources":["../../../../src/styles/tokens.ts"],"names":[],"mappings":"AAeA,eAAO,MAAM,QAAQ,QAA8B,CAAC;AACpD,eAAO,MAAM,QAAQ,QAA8B,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/testing/index.ts"],"names":[],"mappings":"AAIA,cAAc,QAAQ,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../../../../src/testing/util.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,GAAG,GAAI,GAAG,OAAO,MAAM,EAAE,WAAqB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/types/index.ts"],"names":[],"mappings":"AAIA,cAAc,SAAS,CAAC"}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { type EditorView } from '@codemirror/view';
|
|
2
|
-
import { Schema } from 'effect';
|
|
3
|
-
export type Range = {
|
|
4
|
-
from: number;
|
|
5
|
-
to: number;
|
|
6
|
-
};
|
|
7
|
-
export type Comment = {
|
|
8
|
-
id: string;
|
|
9
|
-
cursor?: string;
|
|
10
|
-
};
|
|
11
|
-
/**
|
|
12
|
-
* Callback that renders into a DOM element within the editor.
|
|
13
|
-
*/
|
|
14
|
-
export type RenderCallback<Props extends object> = (el: HTMLElement, props: Props, view: EditorView) => void;
|
|
15
|
-
export declare const EditorViewModes: readonly ["preview", "readonly", "source"];
|
|
16
|
-
export declare const EditorViewMode: Schema.Schema<"preview" | "readonly" | "source", "preview" | "readonly" | "source", never>;
|
|
17
|
-
export type EditorViewMode = Schema.Schema.Type<typeof EditorViewMode>;
|
|
18
|
-
export declare const EditorInputModes: readonly ["default", "vim", "vscode"];
|
|
19
|
-
export declare const EditorInputMode: Schema.Schema<"default" | "vim" | "vscode", "default" | "vim" | "vscode", never>;
|
|
20
|
-
export type EditorInputMode = Schema.Schema.Type<typeof EditorInputMode>;
|
|
21
|
-
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/types/types.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,kBAAkB,CAAC;AACnD,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAGhC,MAAM,MAAM,KAAK,GAAG;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,EAAE,EAAE,MAAM,CAAC;CACZ,CAAC;AAIF,MAAM,MAAM,OAAO,GAAG;IACpB,EAAE,EAAE,MAAM,CAAC;IACX,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,cAAc,CAAC,KAAK,SAAS,MAAM,IAAI,CAAC,EAAE,EAAE,WAAW,EAAE,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,UAAU,KAAK,IAAI,CAAC;AAE7G,eAAO,MAAM,eAAe,4CAA6C,CAAC;AAC1E,eAAO,MAAM,cAAc,4FAAuE,CAAC;AACnG,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,cAAc,CAAC,CAAC;AAEvE,eAAO,MAAM,gBAAgB,uCAAwC,CAAC;AACtE,eAAO,MAAM,eAAe,kFAAwE,CAAC;AACrG,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,eAAe,CAAC,CAAC"}
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import { type EditorState } from '@codemirror/state';
|
|
2
|
-
import { type Range } from '../types';
|
|
3
|
-
/**
|
|
4
|
-
* Determines if two ranges overlap.
|
|
5
|
-
* A range is considered to overlap if there is any intersection
|
|
6
|
-
* between the two ranges, inclusive of their boundaries.
|
|
7
|
-
*/
|
|
8
|
-
export declare const overlap: (a: Range, b: Range) => boolean;
|
|
9
|
-
/**
|
|
10
|
-
* Converts indexes into the text document into stable peer-independent cursors.
|
|
11
|
-
*
|
|
12
|
-
* See:
|
|
13
|
-
* - https://automerge.org/automerge/api-docs/js/functions/next.getCursor.html
|
|
14
|
-
* - https://github.com/yjs/yjs?tab=readme-ov-file#relative-positions
|
|
15
|
-
*
|
|
16
|
-
* @param {assoc} number Negative values will associate the cursor with the previous character
|
|
17
|
-
* while positive - with the next one.
|
|
18
|
-
*/
|
|
19
|
-
export interface CursorConverter {
|
|
20
|
-
toCursor(position: number, assoc?: -1 | 1 | undefined): string;
|
|
21
|
-
fromCursor(cursor: string): number;
|
|
22
|
-
}
|
|
23
|
-
export declare class Cursor {
|
|
24
|
-
static readonly converter: import("@codemirror/state").Facet<unknown, CursorConverter>;
|
|
25
|
-
static readonly getCursorFromRange: (state: EditorState, range: Range) => string;
|
|
26
|
-
static readonly getRangeFromCursor: (state: EditorState, cursor: string) => {
|
|
27
|
-
from: number;
|
|
28
|
-
to: number;
|
|
29
|
-
} | undefined;
|
|
30
|
-
}
|
|
31
|
-
//# sourceMappingURL=cursor.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"cursor.d.ts","sourceRoot":"","sources":["../../../../src/util/cursor.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAGrD,OAAO,EAAE,KAAK,KAAK,EAAE,MAAM,UAAU,CAAC;AAEtC;;;;GAIG;AACH,eAAO,MAAM,OAAO,GAAI,GAAG,KAAK,EAAE,GAAG,KAAK,KAAG,OAA2C,CAAC;AAEzF;;;;;;;;;GASG;AACH,MAAM,WAAW,eAAe;IAC9B,QAAQ,CAAC,QAAQ,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,CAAC,CAAC,GAAG,CAAC,GAAG,SAAS,GAAG,MAAM,CAAC;IAC/D,UAAU,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC;CACpC;AAOD,qBAAa,MAAM;IACjB,MAAM,CAAC,QAAQ,CAAC,SAAS,8DAA4C;IAErE,MAAM,CAAC,QAAQ,CAAC,kBAAkB,GAAI,OAAO,WAAW,EAAE,OAAO,KAAK,YAKpE;IAEF,MAAM,CAAC,QAAQ,CAAC,kBAAkB,GAAI,OAAO,WAAW,EAAE,QAAQ,MAAM;;;kBAOtE;CACH"}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { type Transaction } from '@codemirror/state';
|
|
2
|
-
import { type EditorView } from '@codemirror/view';
|
|
3
|
-
export declare const wrapWithCatch: (fn: (...args: any[]) => any) => (...args: any[]) => any;
|
|
4
|
-
/**
|
|
5
|
-
* CodeMirror callbacks swallow errors so wrap handlers.
|
|
6
|
-
*/
|
|
7
|
-
export declare const callbackWrapper: <T extends Function>(fn: T) => T;
|
|
8
|
-
/**
|
|
9
|
-
* Log all changes before dispatching them to the view.
|
|
10
|
-
* https://codemirror.net/docs/ref/#view.EditorView.dispatch
|
|
11
|
-
*/
|
|
12
|
-
export declare const debugDispatcher: (trs: readonly Transaction[], view: EditorView) => void;
|
|
13
|
-
/**
|
|
14
|
-
* Util to log transactions in update listener.
|
|
15
|
-
*/
|
|
16
|
-
export declare const logChanges: (trs: readonly Transaction[]) => void;
|
|
17
|
-
//# sourceMappingURL=debug.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"debug.d.ts","sourceRoot":"","sources":["../../../../src/util/debug.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,WAAW,EAAE,MAAM,mBAAmB,CAAC;AACrD,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAInD,eAAO,MAAM,aAAa,GAAI,IAAI,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,MAC/C,GAAG,MAAM,GAAG,EAAE,QAOvB,CAAC;AAEF;;GAEG;AAEH,eAAO,MAAM,eAAe,GAAI,CAAC,SAAS,QAAQ,EAAE,IAAI,CAAC,KAAG,CAOxC,CAAC;AAErB;;;GAGG;AACH,eAAO,MAAM,eAAe,GAAI,KAAK,SAAS,WAAW,EAAE,EAAE,MAAM,UAAU,SAG5E,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,UAAU,GAAI,KAAK,SAAS,WAAW,EAAE,SAmBrD,CAAC"}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
export interface Rect {
|
|
2
|
-
readonly left: number;
|
|
3
|
-
readonly right: number;
|
|
4
|
-
readonly top: number;
|
|
5
|
-
readonly bottom: number;
|
|
6
|
-
}
|
|
7
|
-
export declare const flattenRect: (rect: Rect, left: boolean) => {
|
|
8
|
-
left: number;
|
|
9
|
-
right: number;
|
|
10
|
-
top: number;
|
|
11
|
-
bottom: number;
|
|
12
|
-
};
|
|
13
|
-
export declare const textRange: (node: Text, from: number, to?: number) => Range;
|
|
14
|
-
export declare const clientRectsFor: (dom: Node) => DOMRectList;
|
|
15
|
-
export type ElementOptions = {
|
|
16
|
-
className?: string;
|
|
17
|
-
text?: string;
|
|
18
|
-
};
|
|
19
|
-
export declare const createElement: (tag: string, options?: ElementOptions, children?: HTMLElement[]) => HTMLElement;
|
|
20
|
-
//# sourceMappingURL=dom.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"dom.d.ts","sourceRoot":"","sources":["../../../../src/util/dom.ts"],"names":[],"mappings":"AAMA,MAAM,WAAW,IAAI;IACnB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;CACzB;AAED,eAAO,MAAM,WAAW,GAAI,MAAM,IAAI,EAAE,MAAM,OAAO;;;;;CAGpD,CAAC;AAIF,eAAO,MAAM,SAAS,GAAI,MAAM,IAAI,EAAE,MAAM,MAAM,EAAE,WAAS,UAK5D,CAAC;AAEF,eAAO,MAAM,cAAc,GAAI,KAAK,IAAI,gBAQvC,CAAC;AAEF,MAAM,MAAM,cAAc,GAAG;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,eAAO,MAAM,aAAa,GAAI,KAAK,MAAM,EAAE,UAAU,cAAc,EAAE,WAAW,WAAW,EAAE,KAAG,WAa/F,CAAC"}
|