@clevertask/scribe 0.1.16 → 0.1.18

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 (47) hide show
  1. package/README.md +14 -1
  2. package/dist/{BarMenu-x4sf3ECS.js → BarMenu-C9tCdvyV.js} +1 -1
  3. package/dist/components/Menu/BarMenu.js +1 -1
  4. package/dist/components/Menu/BubbleMenu.js +2 -2
  5. package/dist/components/Menu/CalloutBubbleMenu.js +2 -2
  6. package/dist/components/Menu/LinkBubbleMenu.d.ts.map +1 -1
  7. package/dist/components/Menu/LinkBubbleMenu.js +2 -2
  8. package/dist/components/Menu/LinkEditor.d.ts.map +1 -1
  9. package/dist/components/Menu/Mobile/ListOptionBar.js +1 -1
  10. package/dist/components/Menu/TableBubbleMenu.js +2 -2
  11. package/dist/components/Menu/linkBubbleMenuPlugin.js +1 -1
  12. package/dist/components/Scribe/extension/callout.js +1 -1
  13. package/dist/components/Scribe/extension/emoji/suggest.js +1 -1
  14. package/dist/components/Scribe/extension/extension-link.js +1 -1
  15. package/dist/components/Scribe/extension/extension-markdown-paste.js +2 -2
  16. package/dist/components/Scribe/extension/extension-selectedText.js +1 -1
  17. package/dist/components/Scribe/extension/external-link-preview/commands.js +1 -1
  18. package/dist/components/Scribe/extension/external-link-preview/index.js +2 -2
  19. package/dist/components/Scribe/extension/external-link-preview/node-view.js +1 -1
  20. package/dist/components/Scribe/extension/external-link-preview/render-html.js +1 -1
  21. package/dist/components/Scribe/extension/index.d.ts.map +1 -1
  22. package/dist/components/Scribe/extension/index.js +1 -1
  23. package/dist/components/Scribe/extension/resizable-table.js +1 -1
  24. package/dist/components/Scribe/extension/slashCommand/index.js +1 -1
  25. package/dist/components/Scribe/extension/slashCommand/renderItems.js +1 -1
  26. package/dist/components/Scribe/extension/tableOfContents.js +1 -1
  27. package/dist/components/Scribe/index.d.ts +8 -0
  28. package/dist/components/Scribe/index.d.ts.map +1 -1
  29. package/dist/components/Scribe/index.js +4 -4
  30. package/dist/{dist-tNcpTcFT.js → dist-CkWsQ5Lj.js} +197 -185
  31. package/dist/{dist-DDjaA1Pn.js → dist-DRPH9MfF.js} +1 -1
  32. package/dist/{extension-dRUfQQo6.js → extension-DOo9QT6U.js} +1169 -1160
  33. package/dist/{extension-link-RYtPpHwt.js → extension-link-yMrg9JOz.js} +2 -2
  34. package/dist/{html-to-markdown-nbQ6qHyO.js → html-to-markdown-CnlA8pb8.js} +1 -1
  35. package/dist/main.js +2 -2
  36. package/dist/{markdown-to-html-B-KKCZRs.js → markdown-to-html-BLzYd3Fu.js} +10 -11
  37. package/dist/{menus-U2HdvQnu.js → menus-Dy2dj4QT.js} +5 -5
  38. package/dist/purify.es-DGv0-Lid.js +805 -0
  39. package/dist/{resizable-table-m0AzovsZ.js → resizable-table-D0mls3aB.js} +2 -2
  40. package/dist/{slashCommand-CtvgnL0Z.js → slashCommand-D35jcSNp.js} +2 -2
  41. package/dist/utils/create-scribe-editor.d.ts +6 -1
  42. package/dist/utils/create-scribe-editor.d.ts.map +1 -1
  43. package/dist/utils/html-to-markdown.js +1 -1
  44. package/dist/utils/index.js +10 -7
  45. package/dist/utils/markdown-to-html.js +1 -1
  46. package/package.json +51 -51
  47. package/dist/purify.es-BES4pJF7.js +0 -774
package/README.md CHANGED
@@ -38,7 +38,7 @@ A versatile, block-based rich text editor for diverse applications, built with T
38
38
  ## Installation
39
39
 
40
40
  ```bash
41
- npm install --save-exact @clevertask/scribe @tiptap/pm@3.30.1
41
+ npm install --save-exact @clevertask/scribe @tiptap/pm@3.30.2
42
42
  ```
43
43
 
44
44
  Scribe shares this exact ProseMirror runtime with consumer extensions. Keeping one
@@ -243,6 +243,18 @@ Block: $$\sum_{i=1}^{n} x_i$$
243
243
 
244
244
  If your content arrives as HTML (for example from a server), use the helper below to convert legacy delimiters into the HTML nodes that the math extension understands.
245
245
 
246
+ ## External Undo and Redo Ownership
247
+
248
+ Scribe enables its built-in undo and redo history by default. Set `enableUndoRedo={false}` when a different extension owns history, such as Tiptap Collaboration:
249
+
250
+ ```tsx
251
+ <Scribe enableUndoRedo={false} extensions={[Collaboration.configure({ document: ydoc })]} />
252
+ ```
253
+
254
+ Scribe reads this option when it creates the editor. Remount Scribe to change it. If you pass an `externalEditor`, configure history on that editor instead. Do not add another ordinary history extension through `extensions` when collaboration owns undo and redo.
255
+
256
+ The `createScribeEditor` helper accepts the same `enableUndoRedo` option.
257
+
246
258
  ## Props
247
259
 
248
260
  | Prop | Type | Default | Description |
@@ -254,6 +266,7 @@ If your content arrives as HTML (for example from a server), use the helper belo
254
266
  | `autoFocus` | `boolean` | `false` | Controls whether the editor should automatically focus when mounted. |
255
267
  | `extensions` | `Extension[]` | `undefined` | You can set your own extensions for the text editor. For more information, [check the tip tap extensions docs](https://tiptap.dev/docs/editor/core-concepts/extensions) |
256
268
  | `externalEditor` | `Editor` | `undefined` | Uses a caller-owned Tiptap editor. The caller remains responsible for its extension and plugin lifecycle, including table resizing, and for destroying it. |
269
+ | `enableUndoRedo` | `boolean` | `true` | Enables Scribe's built-in undo and redo history. Set it to `false` when another extension owns history. This creation-time option does not configure a caller-owned `externalEditor`. |
257
270
  | `externalLinkPreview` | `Partial<ExternalLinkPreviewOptions>` | `undefined` | Experimental. Opts into external-link metadata resolution and enhanced Compact/Card presentation. The consumer owns fetching and destination policy; automatic previews on paste default to disabled. |
258
271
  | `editorProps` | `EditorProps` | `undefined` | A tiptap-based prop to handle advanced use cases, you can read about it on their [documentation](https://tiptap.dev/docs/editor/api/editor#editorprops) |
259
272
  | `showBarMenu` | `boolean` | `true` | Determines whether to show the text editor top menu bar or not. This menu bar shows options to format the text |
@@ -1,4 +1,4 @@
1
- import { s as e } from "./dist-DDjaA1Pn.js";
1
+ import { s as e } from "./dist-DRPH9MfF.js";
2
2
  import { getPopupMountTarget as t } from "./components/Scribe/extension/getPopupMountTarget.js";
3
3
  import n from "./components/Menu/LinkEditor.js";
4
4
  import { hideLinkBubbleMenu as r } from "./components/Menu/linkBubbleMenuPlugin.js";
@@ -1,2 +1,2 @@
1
- import { t as e } from "../../BarMenu-x4sf3ECS.js";
1
+ import { t as e } from "../../BarMenu-C9tCdvyV.js";
2
2
  export { e as default };
@@ -1,6 +1,6 @@
1
- import { s as e } from "../../dist-DDjaA1Pn.js";
1
+ import { s as e } from "../../dist-DRPH9MfF.js";
2
2
  import { getPopupMountTarget as t } from "../Scribe/extension/getPopupMountTarget.js";
3
- import { t as n } from "../../menus-U2HdvQnu.js";
3
+ import { t as n } from "../../menus-Dy2dj4QT.js";
4
4
  import { Flex as r, IconButton as i } from "@radix-ui/themes";
5
5
  import { useCallback as a } from "react";
6
6
  import { jsx as o } from "react/jsx-runtime";
@@ -1,6 +1,6 @@
1
- import { s as e } from "../../dist-DDjaA1Pn.js";
1
+ import { s as e } from "../../dist-DRPH9MfF.js";
2
2
  import { getPopupMountTarget as t } from "../Scribe/extension/getPopupMountTarget.js";
3
- import { t as n } from "../../menus-U2HdvQnu.js";
3
+ import { t as n } from "../../menus-Dy2dj4QT.js";
4
4
  import { CalloutIcon as r, RemoveCalloutIcon as i } from "../../icons/CalloutIcon.js";
5
5
  import { CALLOUT_VARIANTS as a, CALLOUT_VARIANT_LABELS as o, isCalloutVariant as s } from "../Scribe/extension/callout.js";
6
6
  import { calloutBubbleMenuPluginKey as c, getSelectionCalloutContext as l } from "./calloutBubbleMenuPlugin.js";
@@ -1 +1 @@
1
- {"version":3,"file":"LinkBubbleMenu.d.ts","sourceRoot":"","sources":["../../../lib/components/Menu/LinkBubbleMenu.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAkB,MAAM,eAAe,CAAC;AAKvD,OAAO,EAAE,EAAE,EAA2E,MAAM,OAAO,CAAC;AAepG,MAAM,WAAW,mBAAmB;IAClC,MAAM,EAAE,MAAM,CAAC;CAChB;AAiCD,QAAA,MAAM,cAAc,EAAE,EAAE,CAAC,mBAAmB,CAia3C,CAAC;eAEa,cAAc"}
1
+ {"version":3,"file":"LinkBubbleMenu.d.ts","sourceRoot":"","sources":["../../../lib/components/Menu/LinkBubbleMenu.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAkB,MAAM,eAAe,CAAC;AAKvD,OAAO,EAAE,EAAE,EAA2E,MAAM,OAAO,CAAC;AAepG,MAAM,WAAW,mBAAmB;IAClC,MAAM,EAAE,MAAM,CAAC;CAChB;AAiCD,QAAA,MAAM,cAAc,EAAE,EAAE,CAAC,mBAAmB,CAma3C,CAAC;eAEa,cAAc"}
@@ -1,9 +1,9 @@
1
- import { s as e } from "../../dist-DDjaA1Pn.js";
1
+ import { s as e } from "../../dist-DRPH9MfF.js";
2
2
  import { getPopupMountTarget as t } from "../Scribe/extension/getPopupMountTarget.js";
3
3
  import n from "./LinkEditor.js";
4
4
  import { getExternalLinkPreviewHostname as r } from "../Scribe/extension/external-link-preview/attributes.js";
5
5
  import { consumeLinkBubbleMenuFocusTarget as i, getPlainLinkContextAtPosition as a, getSelectionLinkContext as o, hideLinkBubbleMenu as s, linkBubbleMenuPluginKey as c, showLinkBubbleMenu as l } from "./linkBubbleMenuPlugin.js";
6
- import { t as u } from "../../menus-U2HdvQnu.js";
6
+ import { t as u } from "../../menus-Dy2dj4QT.js";
7
7
  import { getSelectionContextualMenuOwner as d } from "./contextualMenuOwner.js";
8
8
  import { getExternalLinkPreviewResolutionStatus as f } from "../Scribe/extension/external-link-preview/resolver.js";
9
9
  import { Box as p } from "@radix-ui/themes";
@@ -1 +1 @@
1
- {"version":3,"file":"LinkEditor.d.ts","sourceRoot":"","sources":["../../../lib/components/Menu/LinkEditor.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AACvC,OAAO,EACL,EAAE,EAGF,SAAS,EAKV,MAAM,OAAO,CAAC;AACf,OAAO,KAAK,EAAE,mCAAmC,EAAE,MAAM,iDAAiD,CAAC;AAE3G,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AAG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EAAE,MAAM,IAAI,CAAC;IACpB,gBAAgB,CAAC,EAAE,MAAM,IAAI,CAAC;IAC9B,aAAa,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACvC,aAAa,CAAC,EAAE,mCAAmC,CAAC;IACpD,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,2BAA2B,CAAC,EAAE,OAAO,CAAC;IACtC,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,KAAK,EAAE,MAAM,CAAC;CACf;AAED,QAAA,MAAM,UAAU,EAAE,EAAE,CAAC,eAAe,CAoRnC,CAAC;eAEa,UAAU"}
@@ -1,4 +1,4 @@
1
- import { s as e } from "../../../dist-DDjaA1Pn.js";
1
+ import { s as e } from "../../../dist-DRPH9MfF.js";
2
2
  import { Button as t, Flex as n } from "@radix-ui/themes";
3
3
  import { useCallback as r } from "react";
4
4
  import { jsx as i, jsxs as a } from "react/jsx-runtime";
@@ -1,6 +1,6 @@
1
- import { s as e } from "../../dist-DDjaA1Pn.js";
1
+ import { s as e } from "../../dist-DRPH9MfF.js";
2
2
  import { getPopupMountTarget as t } from "../Scribe/extension/getPopupMountTarget.js";
3
- import { t as n } from "../../menus-U2HdvQnu.js";
3
+ import { t as n } from "../../menus-Dy2dj4QT.js";
4
4
  import { getSelectionTableContext as r, tableBubbleMenuPluginKey as i } from "./tableBubbleMenuPlugin.js";
5
5
  import { getSelectionContextualMenuOwner as a } from "./contextualMenuOwner.js";
6
6
  import { Flex as o, IconButton as s, Separator as c } from "@radix-ui/themes";
@@ -1,4 +1,4 @@
1
- import { v as e } from "../../dist-tNcpTcFT.js";
1
+ import { v as e } from "../../dist-CkWsQ5Lj.js";
2
2
  import { normalizeExternalLinkPreviewAttributes as t } from "../Scribe/extension/external-link-preview/attributes.js";
3
3
  import { NodeSelection as n, PluginKey as r } from "@tiptap/pm/state";
4
4
  //#region lib/components/Menu/linkBubbleMenuPlugin.ts
@@ -1,4 +1,4 @@
1
- import { A as e, L as t, a as n } from "../../../dist-tNcpTcFT.js";
1
+ import { A as e, L as t, a as n } from "../../../dist-CkWsQ5Lj.js";
2
2
  import { TextSelection as r } from "@tiptap/pm/state";
3
3
  //#region lib/components/Scribe/extension/callout.ts
4
4
  var i = [
@@ -1,4 +1,4 @@
1
- import { i as e } from "../../../../dist-DDjaA1Pn.js";
1
+ import { i as e } from "../../../../dist-DRPH9MfF.js";
2
2
  import { getPopupMountTarget as t } from "../getPopupMountTarget.js";
3
3
  import { t as n } from "../../../../tippy.esm-DOXqN1Qm.js";
4
4
  import { EmojiList as r } from "./EmojiList.js";
@@ -1,2 +1,2 @@
1
- import { t as e } from "../../../extension-link-RYtPpHwt.js";
1
+ import { t as e } from "../../../extension-link-yMrg9JOz.js";
2
2
  export { e as default };
@@ -1,5 +1,5 @@
1
- import { n as e } from "../../../dist-tNcpTcFT.js";
2
- import { n as t, t as n } from "../../../markdown-to-html-B-KKCZRs.js";
1
+ import { n as e } from "../../../dist-CkWsQ5Lj.js";
2
+ import { n as t, t as n } from "../../../markdown-to-html-BLzYd3Fu.js";
3
3
  import { Plugin as r, PluginKey as i } from "@tiptap/pm/state";
4
4
  //#region lib/components/Scribe/extension/extension-markdown-paste.ts
5
5
  var a = new i("markdownPaste"), o = /* @__PURE__ */ new Set([
@@ -1,4 +1,4 @@
1
- import { n as e } from "../../../dist-tNcpTcFT.js";
1
+ import { n as e } from "../../../dist-CkWsQ5Lj.js";
2
2
  //#region lib/components/Scribe/extension/extension-selectedText.ts
3
3
  var t = e.create({
4
4
  name: "SelectedText",
@@ -1,4 +1,4 @@
1
- import { v as e } from "../../../../dist-tNcpTcFT.js";
1
+ import { v as e } from "../../../../dist-CkWsQ5Lj.js";
2
2
  import { normalizeLinkUrl as t } from "../../../Menu/linkUrl.js";
3
3
  import { EXTERNAL_LINK_PREVIEW_NODE_NAME as n, hasExternalLinkPreviewMetadata as r, normalizeExternalLinkPreviewAttributes as i, normalizeExternalLinkPreviewHref as a } from "./attributes.js";
4
4
  import { startExternalLinkPreviewResolution as o } from "./resolver.js";
@@ -1,5 +1,5 @@
1
- import { r as e } from "../../../../dist-DDjaA1Pn.js";
2
- import { a as t } from "../../../../dist-tNcpTcFT.js";
1
+ import { r as e } from "../../../../dist-DRPH9MfF.js";
2
+ import { a as t } from "../../../../dist-CkWsQ5Lj.js";
3
3
  import { EXTERNAL_LINK_PREVIEW_DISPLAYS as n } from "./types.js";
4
4
  import { EXTERNAL_LINK_PREVIEW_NODE_NAME as r, isExternalLinkPreviewDisplay as i, normalizeExternalLinkPreviewAttributes as a, normalizeExternalLinkPreviewHref as o, normalizeExternalLinkPreviewLinkText as s, normalizeExternalLinkPreviewMediaUrl as c, normalizeExternalLinkPreviewMetadata as l } from "./attributes.js";
5
5
  import { createExternalLinkPreviewResolverPlugin as u } from "./resolver.js";
@@ -1,4 +1,4 @@
1
- import { n as e, s as t } from "../../../../dist-DDjaA1Pn.js";
1
+ import { n as e, s as t } from "../../../../dist-DRPH9MfF.js";
2
2
  import { getExternalLinkPreviewHostname as n, getExternalLinkPreviewTitle as r, normalizeExternalLinkPreviewAttributes as i } from "./attributes.js";
3
3
  import { showLinkBubbleMenu as a } from "../../../Menu/linkBubbleMenuPlugin.js";
4
4
  import { jsx as o, jsxs as s } from "react/jsx-runtime";
@@ -1,4 +1,4 @@
1
- import { L as e } from "../../../../dist-tNcpTcFT.js";
1
+ import { L as e } from "../../../../dist-CkWsQ5Lj.js";
2
2
  import { getExternalLinkPreviewHostname as t, getExternalLinkPreviewTitle as n } from "./attributes.js";
3
3
  import { getExternalLinkPreviewDataAttributes as r } from "./serialization.js";
4
4
  //#region lib/components/Scribe/extension/external-link-preview/render-html.ts
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../lib/components/Scribe/extension/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,IAAI,CAAC;AAwBtC,eAAO,MAAM,cAAc,UAAW,WAAW;;;;;;;;;;;;;;;;;4kCA0FhD,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../lib/components/Scribe/extension/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,IAAI,CAAC;AAwBtC,eAAO,MAAM,cAAc,UAAW,WAAW;;;;;;;;;;;;;;;;;4kCA2FhD,CAAC"}
@@ -1,2 +1,2 @@
1
- import { t as e } from "../../../extension-dRUfQQo6.js";
1
+ import { t as e } from "../../../extension-DOo9QT6U.js";
2
2
  export { e as initExtensions };
@@ -1,2 +1,2 @@
1
- import { t as e } from "../../../resizable-table-m0AzovsZ.js";
1
+ import { t as e } from "../../../resizable-table-D0mls3aB.js";
2
2
  export { e as ScribeTable };
@@ -1,2 +1,2 @@
1
- import { n as e, t } from "../../../../slashCommand-CtvgnL0Z.js";
1
+ import { n as e, t } from "../../../../slashCommand-D35jcSNp.js";
2
2
  export { t as SlashCommand, e as slashMenuPluginKey };
@@ -1,4 +1,4 @@
1
- import { i as e } from "../../../../dist-DDjaA1Pn.js";
1
+ import { i as e } from "../../../../dist-DRPH9MfF.js";
2
2
  import { getPopupMountTarget as t } from "../getPopupMountTarget.js";
3
3
  import { t as n } from "../../../../tippy.esm-DOXqN1Qm.js";
4
4
  import { SlashCommandList as r } from "./SlashCommandList.js";
@@ -1,4 +1,4 @@
1
- import { n as e } from "../../../dist-tNcpTcFT.js";
1
+ import { n as e } from "../../../dist-CkWsQ5Lj.js";
2
2
  import { Plugin as t, PluginKey as n } from "@tiptap/pm/state";
3
3
  //#region lib/components/Scribe/extension/tableOfContents.ts
4
4
  var r = "scribeTableOfContents", i = new n("scribeTableOfContents"), a = 10, o = (e) => e.trim().toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g, "").replace(/[^a-z0-9]+/g, "-").replace(/^-+|-+$/g, "") || "heading", s = (e, t) => {
@@ -67,6 +67,14 @@ export interface ScribeProps {
67
67
  * @experimental The link-preview API and built-in UI may change while this feature is tested.
68
68
  */
69
69
  externalLinkPreview?: Partial<ExternalLinkPreviewOptions>;
70
+ /**
71
+ * Enables Scribe's built-in undo and redo history. Disable this when another
72
+ * extension, such as Tiptap Collaboration, owns history for the editor.
73
+ *
74
+ * Scribe reads this option when it creates the editor. It does not configure
75
+ * a caller-owned `externalEditor`.
76
+ */
77
+ enableUndoRedo?: boolean;
70
78
  /** @experimental Enables Scribe's app-owned table-of-contents API. */
71
79
  enableTableOfContents?: boolean;
72
80
  /** @experimental Receives the current table-of-contents items when they change. */
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../lib/components/Scribe/index.tsx"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAK9B,OAAO,EAAE,UAAU,EAAQ,MAAM,MAAM,CAAC;AAGxC,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,0BAA0B,CAAC;AAC1E,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,mCAAmC,CAAC;AAEpF,OAAO,KAAK,EACV,kCAAkC,EAElC,iCAAiC,EAClC,MAAM,6BAA6B,CAAC;AAErC,OAAO,EACL,OAAO,EACP,MAAM,EAGN,SAAS,EACT,WAAW,EACX,gBAAgB,EAEjB,MAAM,eAAe,CAAC;AACvB,OAAO,EAEL,oBAAoB,EAMrB,MAAM,OAAO,CAAC;AAGf,YAAY,EACV,yBAAyB,EACzB,mBAAmB,EACnB,yBAAyB,EACzB,8BAA8B,EAC9B,cAAc,GACf,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AACpE,YAAY,EACV,kCAAkC,EAClC,yBAAyB,EACzB,iCAAiC,GAClC,MAAM,6BAA6B,CAAC;AACrC,YAAY,EACV,mBAAmB,EACnB,6BAA6B,EAC7B,0BAA0B,EAC1B,2BAA2B,EAC3B,0BAA0B,EAC1B,2BAA2B,EAC3B,kCAA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,CAAC,EAAE,oBAAoB,CAAC;IACjC,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB;;;OAGG;IACH,YAAY,CAAC,EAAE,yBAAyB,CAAC;IACzC;;;;;;;;;;OAUG;IACH,mBAAmB,CAAC,EAAE,OAAO,CAAC,0BAA0B,CAAC,CAAC;IAC1D;;;;;;OAMG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,sEAAsE;IACtE,qBAAqB,CAAC,EAAE,OAAO,CAAC;IAChC,mFAAmF;IACnF,uBAAuB,CAAC,EAAE,kCAAkC,CAAC;CAC9D;AAybD,eAAO,MAAM,MAAM,mGAMlB,CAAC"}
@@ -1,10 +1,10 @@
1
- import { n as e, t } from "../../BarMenu-x4sf3ECS.js";
2
- import { o as n, t as r } from "../../dist-DDjaA1Pn.js";
1
+ import { n as e, t } from "../../BarMenu-C9tCdvyV.js";
2
+ import { o as n, t as r } from "../../dist-DRPH9MfF.js";
3
3
  import i from "../Menu/CalloutBubbleMenu.js";
4
4
  import a from "../Menu/LinkBubbleMenu.js";
5
5
  import o from "../Menu/TableBubbleMenu.js";
6
- import { t as s } from "../../html-to-markdown-nbQ6qHyO.js";
7
- import { t as c } from "../../extension-dRUfQQo6.js";
6
+ import { t as s } from "../../html-to-markdown-CnlA8pb8.js";
7
+ import { t as c } from "../../extension-DOo9QT6U.js";
8
8
  import { SuggestionItemType as l } from "./extension/slashCommand/items.js";
9
9
  import "./extension/tableOfContents.js";
10
10
  import "../../utils/index.js";