@tiptap/vue-2 3.0.6 → 3.0.8
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/menus/index.cjs
CHANGED
|
@@ -1786,8 +1786,10 @@ var BubbleMenuView = class {
|
|
|
1786
1786
|
}
|
|
1787
1787
|
updatePosition() {
|
|
1788
1788
|
const { selection } = this.editor.state;
|
|
1789
|
+
const domRect = (0, import_core3.posToDOMRect)(this.view, selection.from, selection.to);
|
|
1789
1790
|
let virtualElement = {
|
|
1790
|
-
getBoundingClientRect: () =>
|
|
1791
|
+
getBoundingClientRect: () => domRect,
|
|
1792
|
+
getClientRects: () => [domRect]
|
|
1791
1793
|
};
|
|
1792
1794
|
if (selection instanceof import_tables.CellSelection) {
|
|
1793
1795
|
const { $anchorCell, $headCell } = selection;
|
|
@@ -1803,7 +1805,8 @@ var BubbleMenuView = class {
|
|
|
1803
1805
|
toDOM.getBoundingClientRect()
|
|
1804
1806
|
);
|
|
1805
1807
|
virtualElement = {
|
|
1806
|
-
getBoundingClientRect: () => clientRect
|
|
1808
|
+
getBoundingClientRect: () => clientRect,
|
|
1809
|
+
getClientRects: () => [clientRect]
|
|
1807
1810
|
};
|
|
1808
1811
|
}
|
|
1809
1812
|
computePosition2(virtualElement, this.element, {
|
|
@@ -2124,8 +2127,10 @@ var FloatingMenuView = class {
|
|
|
2124
2127
|
}
|
|
2125
2128
|
updatePosition() {
|
|
2126
2129
|
const { selection } = this.editor.state;
|
|
2130
|
+
const domRect = (0, import_core5.posToDOMRect)(this.view, selection.from, selection.to);
|
|
2127
2131
|
const virtualElement = {
|
|
2128
|
-
getBoundingClientRect: () =>
|
|
2132
|
+
getBoundingClientRect: () => domRect,
|
|
2133
|
+
getClientRects: () => [domRect]
|
|
2129
2134
|
};
|
|
2130
2135
|
computePosition2(virtualElement, this.element, {
|
|
2131
2136
|
placement: this.floatingUIOptions.placement,
|