@threadlabs/looma 0.28.3 → 0.28.4
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/package.json +1 -1
- package/vue/editor/index.js +15 -4
package/package.json
CHANGED
package/vue/editor/index.js
CHANGED
|
@@ -3640,6 +3640,11 @@ var LoomaEditor = defineComponent({
|
|
|
3640
3640
|
const tableToolbarRef = popupRef(tableToolbarShell);
|
|
3641
3641
|
const codeLanguageRef = popupRef(codeLanguageShell, true);
|
|
3642
3642
|
const mobileToolbarRef = popupRef(mobileToolbarShell, true);
|
|
3643
|
+
const presentTableOverlay = popupRef(tableOverlayShell);
|
|
3644
|
+
const tableOverlayRef = (node) => {
|
|
3645
|
+
presentTableOverlay(node);
|
|
3646
|
+
if (node instanceof HTMLElement) node.hidden = !tableUi.overlayOpen;
|
|
3647
|
+
};
|
|
3643
3648
|
const onDocumentPointerDown = (event) => {
|
|
3644
3649
|
const path = typeof event.composedPath === "function" ? event.composedPath() : [];
|
|
3645
3650
|
const inElement = (element) => Boolean(element && (path.includes(element) || event.target instanceof Node && element.contains(event.target)));
|
|
@@ -4315,6 +4320,7 @@ var LoomaEditor = defineComponent({
|
|
|
4315
4320
|
}, [h(ImageControls, { editor: instance })])]) : null,
|
|
4316
4321
|
instance ? h(EditorSurface, { density: props.editable ? "comfortable" : props.contentDensity }, () => h("div", { ref: attachDocument })) : null,
|
|
4317
4322
|
codeUi.open ? h("div", {
|
|
4323
|
+
key: "looma-code-language-shell",
|
|
4318
4324
|
ref: codeLanguageRef,
|
|
4319
4325
|
class: "looma-editor__code-language",
|
|
4320
4326
|
style: codeUi.style,
|
|
@@ -4329,6 +4335,7 @@ var LoomaEditor = defineComponent({
|
|
|
4329
4335
|
onValueChange: (event) => chooseCodeLanguage(event.detail)
|
|
4330
4336
|
}, () => codeLanguageOptions.value.map((option) => h("option", { value: option.value }, option.label)))]) : null,
|
|
4331
4337
|
instance && (props.editable || props.selectionActions.length && !instance.state.selection.empty || activeRangeActions(instance).length > 0) && mobile.value && (editorFocused.value || linkOpen.value || !props.editable) ? h("div", {
|
|
4338
|
+
key: "looma-mobile-toolbar-shell",
|
|
4332
4339
|
ref: mobileToolbarRef,
|
|
4333
4340
|
class: "looma-editor__mobile-toolbar-shell",
|
|
4334
4341
|
"data-mode": mobileToolbarMode.value,
|
|
@@ -4509,17 +4516,20 @@ var LoomaEditor = defineComponent({
|
|
|
4509
4516
|
}
|
|
4510
4517
|
}) : null,
|
|
4511
4518
|
tableUi.toolbarOpen ? h("div", {
|
|
4519
|
+
key: "looma-table-toolbar-shell",
|
|
4512
4520
|
ref: tableToolbarRef,
|
|
4513
4521
|
class: "looma-editor__table-toolbar-shell",
|
|
4514
4522
|
style: tableUi.toolbarStyle
|
|
4515
4523
|
}, [h(EditorTableToolbar, tableProps)]) : null,
|
|
4516
|
-
|
|
4517
|
-
|
|
4524
|
+
instance && props.editable && !mobile.value ? h("div", {
|
|
4525
|
+
key: "looma-table-overlay-shell",
|
|
4526
|
+
ref: tableOverlayRef,
|
|
4518
4527
|
class: "looma-editor__table-overlay-shell",
|
|
4519
4528
|
style: tableUi.overlayStyle,
|
|
4529
|
+
hidden: !tableUi.overlayOpen,
|
|
4520
4530
|
onMousedown: onTableOverlayMouseDown,
|
|
4521
4531
|
onPointerleave: onTableOverlayPointerLeave
|
|
4522
|
-
}, [h(EditorTableOverlay, {
|
|
4532
|
+
}, [tableUi.overlayOpen ? h(EditorTableOverlay, {
|
|
4523
4533
|
open: true,
|
|
4524
4534
|
geometry: tableUi.geometry,
|
|
4525
4535
|
onAddRowBefore: (event) => runOverlayAction({
|
|
@@ -4566,8 +4576,9 @@ var LoomaEditor = defineComponent({
|
|
|
4566
4576
|
action: "open-column-menu",
|
|
4567
4577
|
...event.detail
|
|
4568
4578
|
})
|
|
4569
|
-
})]) : null,
|
|
4579
|
+
}) : null]) : null,
|
|
4570
4580
|
tableUi.menuOpen ? h("div", {
|
|
4581
|
+
key: "looma-table-menu-shell",
|
|
4571
4582
|
ref: tableMenuShell,
|
|
4572
4583
|
class: "looma-editor__table-menu-shell"
|
|
4573
4584
|
}, [h(EditorTableContextMenu, {
|