@clevertask/scribe 0.1.28 → 0.1.29

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 (40) hide show
  1. package/dist/{BarMenu-BGWT4Oyk.js → BarMenu-BC8XoC6e.js} +1 -1
  2. package/dist/assets/index.css +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.js +2 -2
  7. package/dist/components/Menu/Mobile/ListOptionBar.js +1 -1
  8. package/dist/components/Menu/TableBubbleMenu.js +3 -3
  9. package/dist/components/Menu/TableHeightSettings.js +1 -1
  10. package/dist/components/Menu/linkBubbleMenuPlugin.js +1 -1
  11. package/dist/components/Scribe/extension/callout.js +7 -7
  12. package/dist/components/Scribe/extension/emoji/suggest.js +1 -1
  13. package/dist/components/Scribe/extension/extension-link.js +1 -1
  14. package/dist/components/Scribe/extension/extension-markdown-paste.js +1 -1
  15. package/dist/components/Scribe/extension/extension-selectedText.js +1 -1
  16. package/dist/components/Scribe/extension/external-link-preview/commands.js +1 -1
  17. package/dist/components/Scribe/extension/external-link-preview/index.js +1 -1
  18. package/dist/components/Scribe/extension/external-link-preview/node-view.js +1 -1
  19. package/dist/components/Scribe/extension/external-link-preview/render-html.js +1 -1
  20. package/dist/components/Scribe/extension/external-link-preview/schema.js +1 -1
  21. package/dist/components/Scribe/extension/index.js +1 -1
  22. package/dist/components/Scribe/extension/resizable-table.js +2 -2
  23. package/dist/components/Scribe/extension/slashCommand/index.js +2 -2
  24. package/dist/components/Scribe/extension/slashCommand/renderItems.js +1 -1
  25. package/dist/components/Scribe/extension/table-layout.js +1 -1
  26. package/dist/components/Scribe/extension/tableOfContents.js +1 -1
  27. package/dist/components/Scribe/index.js +3 -3
  28. package/dist/{dist-BiognBi4.js → dist-B0xwy1Q5.js} +175 -154
  29. package/dist/{dist-Dk0fXvrc.js → dist-CDJRm4fL.js} +2 -2
  30. package/dist/{dist-xjmWZ-oh.js → dist-DnVcys79.js} +632 -571
  31. package/dist/document-node-capabilities.js +1 -1
  32. package/dist/{extension-BU2USLV1.js → extension-BPeoqfHR.js} +2 -2
  33. package/dist/{extension-link-DmM_EJTn.js → extension-link-RvaqaDqr.js} +319 -294
  34. package/dist/{menus-BDXjZsFU.js → menus-scgppp2C.js} +25 -25
  35. package/dist/{schema-extensions-DyCk1Goa.js → schema-extensions-ITR9LEgX.js} +2025 -1898
  36. package/dist/schema-extensions.js +1 -1
  37. package/dist/schema.js +1 -1
  38. package/dist/{table-layout-BoDS50DR.js → table-layout-iVolql5p.js} +179 -128
  39. package/dist/utils/index.js +2 -2
  40. package/package.json +51 -51
@@ -1,11 +1,11 @@
1
- import { E as e, N as t, T as n, n as r, z as i } from "./dist-xjmWZ-oh.js";
1
+ import { E as e, H as t, P as n, T as r, n as i } from "./dist-DnVcys79.js";
2
2
  import { a, c as o, i as s, l as c, n as l, o as u, s as d, t as f, u as p } from "./floating-ui.dom-CmJ6iBdh.js";
3
- import { a as m } from "./dist-BiognBi4.js";
3
+ import { a as m } from "./dist-B0xwy1Q5.js";
4
4
  import { NodeSelection as h, Plugin as g, PluginKey as _ } from "@tiptap/pm/state";
5
5
  import { CellSelection as v } from "@tiptap/pm/tables";
6
6
  import y, { useEffect as b, useLayoutEffect as x, useRef as S, useState as C } from "react";
7
7
  import { createPortal as w } from "react-dom";
8
- //#region node_modules/.pnpm/@tiptap+extension-bubble-menu@3.31.3_@tiptap+core@3.31.3_@tiptap+pm@3.31.3__@tiptap+pm@3.31.3/node_modules/@tiptap/extension-bubble-menu/dist/index.js
8
+ //#region node_modules/.pnpm/@tiptap+extension-bubble-menu@3.31.4_@tiptap+core@3.31.4_@tiptap+pm@3.31.4__@tiptap+pm@3.31.4/node_modules/@tiptap/extension-bubble-menu/dist/index.js
9
9
  function T(e, t) {
10
10
  let n = Math.min(e.top, t.top), r = Math.max(e.bottom, t.bottom), i = Math.min(e.left, t.left), a = Math.max(e.right, t.right) - i, o = r - n;
11
11
  return new DOMRect(i, n, a, o);
@@ -17,22 +17,22 @@ var E = class {
17
17
  }
18
18
  get virtualElement() {
19
19
  var e;
20
- let { selection: t } = this.editor.state, n = this.getReferencedVirtualElement?.call(this);
21
- if (n) return n;
20
+ let { selection: n } = this.editor.state, r = this.getReferencedVirtualElement?.call(this);
21
+ if (r) return r;
22
22
  if (!((e = this.view) != null && (e = e.dom) != null && e.parentNode)) return;
23
- let r = i(this.view, t.from, t.to), a = {
24
- getBoundingClientRect: () => r,
25
- getClientRects: () => [r]
23
+ let i = t(this.view, n.from, n.to), a = {
24
+ getBoundingClientRect: () => i,
25
+ getClientRects: () => [i]
26
26
  };
27
- if (t instanceof h) {
28
- let e = this.view.nodeDOM(t.from), n = e.dataset.nodeViewWrapper ? e : e.querySelector("[data-node-view-wrapper]");
29
- n && (e = n), e && (a = {
27
+ if (n instanceof h) {
28
+ let e = this.view.nodeDOM(n.from), t = e.dataset.nodeViewWrapper ? e : e.querySelector("[data-node-view-wrapper]");
29
+ t && (e = t), e && (a = {
30
30
  getBoundingClientRect: () => e.getBoundingClientRect(),
31
31
  getClientRects: () => [e.getBoundingClientRect()]
32
32
  });
33
33
  }
34
- if (t instanceof v) {
35
- let { $anchorCell: e, $headCell: n } = t, r = e ? e.pos : n.pos, i = n ? n.pos : e.pos, o = this.view.nodeDOM(r), s = this.view.nodeDOM(i);
34
+ if (n instanceof v) {
35
+ let { $anchorCell: e, $headCell: t } = n, r = e ? e.pos : t.pos, i = t ? t.pos : e.pos, o = this.view.nodeDOM(r), s = this.view.nodeDOM(i);
36
36
  if (!o || !s) return;
37
37
  let c = o === s ? o.getBoundingClientRect() : T(o.getBoundingClientRect(), s.getBoundingClientRect());
38
38
  a = {
@@ -42,7 +42,7 @@ var E = class {
42
42
  }
43
43
  return a;
44
44
  }
45
- constructor({ editor: e, element: n, view: r, pluginKey: i = "bubbleMenu", updateDelay: a = 250, resizeDelay: o = 60, shouldShow: s, appendTo: c, getReferencedVirtualElement: l, options: u }) {
45
+ constructor({ editor: e, element: t, view: r, pluginKey: i = "bubbleMenu", updateDelay: a = 250, resizeDelay: o = 60, shouldShow: s, appendTo: c, getReferencedVirtualElement: l, options: u }) {
46
46
  this.preventHide = !1, this.isVisible = !1, this.scrollTarget = window, this.floatingUIOptions = {
47
47
  strategy: "absolute",
48
48
  placement: "top",
@@ -58,8 +58,8 @@ var E = class {
58
58
  onHide: void 0,
59
59
  onUpdate: void 0,
60
60
  onDestroy: void 0
61
- }, this.shouldShow = ({ view: e, state: n, from: r, to: i }) => {
62
- let { doc: a, selection: o } = n, { empty: s } = o, c = !a.textBetween(r, i).length && t(n.selection), l = this.element.contains(document.activeElement);
61
+ }, this.shouldShow = ({ view: e, state: t, from: r, to: i }) => {
62
+ let { doc: a, selection: o } = t, { empty: s } = o, c = !a.textBetween(r, i).length && n(t.selection), l = this.element.contains(document.activeElement);
63
63
  return !(!(e.hasFocus() || l) || s || c || !this.editor.isEditable);
64
64
  }, this.mousedownHandler = () => {
65
65
  this.preventHide = !0;
@@ -98,7 +98,7 @@ var E = class {
98
98
  }, this.transactionHandler = ({ transaction: e }) => {
99
99
  let t = e.getMeta(this.pluginKey);
100
100
  t === "updatePosition" ? this.updatePosition() : t && typeof t == "object" && t.type === "updateOptions" ? this.updateOptions(t.options) : t === "hide" ? this.hide() : t === "show" && (this.updatePosition(), this.show());
101
- }, this.editor = e, this.element = n, this.view = r, this.pluginKey = i, this.updateDelay = a, this.resizeDelay = o, this.appendTo = c, this.scrollTarget = u?.scrollTarget ?? window, this.getReferencedVirtualElement = l, this.floatingUIOptions = {
101
+ }, this.editor = e, this.element = t, this.view = r, this.pluginKey = i, this.updateDelay = a, this.resizeDelay = o, this.appendTo = c, this.scrollTarget = u?.scrollTarget ?? window, this.getReferencedVirtualElement = l, this.floatingUIOptions = {
102
102
  ...this.floatingUIOptions,
103
103
  ...u
104
104
  }, this.element.tabIndex = 0, s && (this.shouldShow = s), this.element.addEventListener("mousedown", this.mousedownHandler, { capture: !0 }), this.view.dom.addEventListener("dragstart", this.dragstartHandler), this.editor.on("focus", this.focusHandler), this.editor.on("blur", this.blurHandler), this.editor.on("transaction", this.transactionHandler), window.addEventListener("resize", this.resizeHandler), this.scrollTarget.addEventListener("scroll", this.resizeHandler), this.update(r, r.state), this.getShouldShow() && (this.show(), this.updatePosition());
@@ -167,7 +167,7 @@ var E = class {
167
167
  ...e
168
168
  })
169
169
  });
170
- r.create({
170
+ i.create({
171
171
  name: "bubbleMenu",
172
172
  addOptions() {
173
173
  return {
@@ -192,10 +192,10 @@ r.create({
192
192
  }
193
193
  });
194
194
  //#endregion
195
- //#region node_modules/.pnpm/@tiptap+extension-floating-menu@3.31.3_@floating-ui+dom@1.8.0_@tiptap+core@3.31.3_@tiptap+pm@3.31.3__@tiptap+pm@3.31.3/node_modules/@tiptap/extension-floating-menu/dist/index.js
195
+ //#region node_modules/.pnpm/@tiptap+extension-floating-menu@3.31.4_@floating-ui+dom@1.8.0_@tiptap+core@3.31.4_@tiptap+pm@3.31.4__@tiptap+pm@3.31.4/node_modules/@tiptap/extension-floating-menu/dist/index.js
196
196
  var O = class {
197
197
  getTextContent(t) {
198
- return n(t, { textSerializers: e(this.editor.schema) });
198
+ return r(t, { textSerializers: e(this.editor.schema) });
199
199
  }
200
200
  get middlewares() {
201
201
  let e = [];
@@ -270,10 +270,10 @@ var O = class {
270
270
  updatePosition() {
271
271
  var e;
272
272
  if (!((e = this.view) != null && (e = e.dom) != null && e.parentNode)) return;
273
- let { selection: t } = this.editor.state, n = i(this.view, t.from, t.to);
273
+ let { selection: n } = this.editor.state, r = t(this.view, n.from, n.to);
274
274
  s({
275
- getBoundingClientRect: () => n,
276
- getClientRects: () => [n]
275
+ getBoundingClientRect: () => r,
276
+ getClientRects: () => [r]
277
277
  }, this.element, {
278
278
  placement: this.floatingUIOptions.placement,
279
279
  strategy: this.floatingUIOptions.strategy,
@@ -307,7 +307,7 @@ var O = class {
307
307
  ...e
308
308
  })
309
309
  });
310
- r.create({
310
+ i.create({
311
311
  name: "floatingMenu",
312
312
  addOptions() {
313
313
  return {
@@ -337,7 +337,7 @@ r.create({
337
337
  }
338
338
  });
339
339
  //#endregion
340
- //#region node_modules/.pnpm/@tiptap+react@3.31.3_@floating-ui+dom@1.8.0_@tiptap+core@3.31.3_@tiptap+pm@3.31.3__@tip_2d9a4232cfdce73b845844c6e3920b12/node_modules/@tiptap/react/dist/menus/index.js
340
+ //#region node_modules/.pnpm/@tiptap+react@3.31.4_@floating-ui+dom@1.8.0_@tiptap+core@3.31.4_@tiptap+pm@3.31.4__@tip_a960cd7d357e8e15e820188dcbf9b60a/node_modules/@tiptap/react/dist/menus/index.js
341
341
  function A(e, t) {
342
342
  return e ?? new _(t);
343
343
  }