@ones-editor/editor 2.9.8-beta.71 → 2.9.8-beta.73
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.
|
@@ -64,6 +64,7 @@ export interface CommandBarOptions {
|
|
|
64
64
|
disableSelectedScroll?: boolean;
|
|
65
65
|
refuseOverflow?: boolean;
|
|
66
66
|
overflowBoundary?: Element;
|
|
67
|
+
overflowBoundaryPadding?: number;
|
|
67
68
|
header?: HTMLElement | (() => HTMLElement | null);
|
|
68
69
|
footer?: HTMLElement | (() => HTMLElement | null);
|
|
69
70
|
padding?: number;
|
|
@@ -75,6 +76,7 @@ export interface CommandBarOptions {
|
|
|
75
76
|
export type CreateManualCommandBarFunction = (parentItem: CommandItem, closeable: Closeable, options?: CommandBarOptions) => AbstractManualCommandBar;
|
|
76
77
|
export type PopoverOptions = {
|
|
77
78
|
overflowBoundary?: Element;
|
|
79
|
+
overflowBoundaryPadding?: number;
|
|
78
80
|
appendTo?: Element;
|
|
79
81
|
};
|
|
80
82
|
export type ObjectToolbarOptions = {
|
package/dist/index.js
CHANGED
|
@@ -41735,6 +41735,7 @@ ${codeText}
|
|
|
41735
41735
|
var _a, _b, _c, _d;
|
|
41736
41736
|
const popperOptions = { modifiers: [] };
|
|
41737
41737
|
const overflowBoundary = this.options.overflowBoundary;
|
|
41738
|
+
const overflowBoundaryPadding = this.options.overflowBoundaryPadding || 0;
|
|
41738
41739
|
const padding = this.options.padding;
|
|
41739
41740
|
if (overflowBoundary) {
|
|
41740
41741
|
if (flip) {
|
|
@@ -41754,8 +41755,8 @@ ${codeText}
|
|
|
41754
41755
|
const popper = state.elements.popper;
|
|
41755
41756
|
const popperRect = popper.getBoundingClientRect();
|
|
41756
41757
|
const overflowBoundaryRect = overflowBoundary.getBoundingClientRect();
|
|
41757
|
-
const topCheck = popperRect.top < overflowBoundaryRect.top;
|
|
41758
|
-
const bottomCheck = popperRect.bottom > overflowBoundaryRect.bottom;
|
|
41758
|
+
const topCheck = popperRect.top < overflowBoundaryRect.top - overflowBoundaryPadding;
|
|
41759
|
+
const bottomCheck = popperRect.bottom > overflowBoundaryRect.bottom + overflowBoundaryPadding;
|
|
41759
41760
|
if (topCheck || bottomCheck) {
|
|
41760
41761
|
popper.setAttribute("data-tippy-hidden", "");
|
|
41761
41762
|
} else {
|
|
@@ -54656,6 +54657,7 @@ ${codeText}
|
|
|
54656
54657
|
tooltipId: editor.clientId,
|
|
54657
54658
|
id: "editor-readonly-toolbar",
|
|
54658
54659
|
overflowBoundary: popover == null ? void 0 : popover.overflowBoundary,
|
|
54660
|
+
overflowBoundaryPadding: popover == null ? void 0 : popover.overflowBoundaryPadding,
|
|
54659
54661
|
refuseOverflow: true,
|
|
54660
54662
|
padding: 20
|
|
54661
54663
|
});
|
|
@@ -54901,6 +54903,7 @@ ${codeText}
|
|
|
54901
54903
|
tooltipId: editor.clientId,
|
|
54902
54904
|
id: "editor-toolbar",
|
|
54903
54905
|
overflowBoundary: popover == null ? void 0 : popover.overflowBoundary,
|
|
54906
|
+
overflowBoundaryPadding: popover == null ? void 0 : popover.overflowBoundaryPadding,
|
|
54904
54907
|
refuseOverflow: true,
|
|
54905
54908
|
showName: clientType.isMobile,
|
|
54906
54909
|
autoClose: clientType.isMobile ? true : void 0,
|
|
@@ -73220,6 +73223,7 @@ ${codeText}
|
|
|
73220
73223
|
this.toolbar = new ManualToolbar([], void 0, {
|
|
73221
73224
|
id: "table-row-column-toolbar",
|
|
73222
73225
|
overflowBoundary: popover == null ? void 0 : popover.overflowBoundary,
|
|
73226
|
+
overflowBoundaryPadding: popover == null ? void 0 : popover.overflowBoundaryPadding,
|
|
73223
73227
|
refuseOverflow: true,
|
|
73224
73228
|
tooltipId: this.editor.clientId
|
|
73225
73229
|
});
|
|
@@ -95942,7 +95946,7 @@ ${JSON.stringify(error2, null, 2)}`);
|
|
|
95942
95946
|
}
|
|
95943
95947
|
}
|
|
95944
95948
|
});
|
|
95945
|
-
editor.version = "2.9.8-beta.
|
|
95949
|
+
editor.version = "2.9.8-beta.73";
|
|
95946
95950
|
return editor;
|
|
95947
95951
|
}
|
|
95948
95952
|
function isDoc(doc2) {
|
|
@@ -96076,7 +96080,7 @@ ${JSON.stringify(error2, null, 2)}`);
|
|
|
96076
96080
|
OnesEditorDropTarget.register(editor);
|
|
96077
96081
|
OnesEditorTocProvider.register(editor);
|
|
96078
96082
|
OnesEditorExclusiveBlock.register(editor);
|
|
96079
|
-
editor.version = "2.9.8-beta.
|
|
96083
|
+
editor.version = "2.9.8-beta.73";
|
|
96080
96084
|
return editor;
|
|
96081
96085
|
}
|
|
96082
96086
|
async function showDocVersions(editor, options, serverUrl) {
|