@bobfrankston/rmfmail 1.2.95 → 1.2.96
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/client/app.bundle.js +17 -4
- package/client/app.bundle.js.map +2 -2
- package/client/components/folder-tree.js +31 -6
- package/client/components/folder-tree.js.map +1 -1
- package/client/components/folder-tree.ts +29 -5
- package/package.json +9 -9
- package/chk-search-tmp.mjs +0 -14
- package/cleanup-sent-tmp.mjs +0 -43
package/client/app.bundle.js
CHANGED
|
@@ -6434,6 +6434,14 @@ var refreshDebounceTimer = null;
|
|
|
6434
6434
|
var DRAG_HOVER_EXPAND_MS = 600;
|
|
6435
6435
|
var dragAutoExpanded = /* @__PURE__ */ new Set();
|
|
6436
6436
|
var dragInFlight = false;
|
|
6437
|
+
function collapseDragExpanded() {
|
|
6438
|
+
if (dragAutoExpanded.size === 0)
|
|
6439
|
+
return false;
|
|
6440
|
+
for (const key of dragAutoExpanded)
|
|
6441
|
+
delete expandState[key];
|
|
6442
|
+
dragAutoExpanded.clear();
|
|
6443
|
+
return true;
|
|
6444
|
+
}
|
|
6437
6445
|
var expandState = JSON.parse(localStorage.getItem("mailx-folders-expanded") || "{}");
|
|
6438
6446
|
function saveExpandState() {
|
|
6439
6447
|
localStorage.setItem("mailx-folders-expanded", JSON.stringify(expandState));
|
|
@@ -6812,6 +6820,14 @@ function renderNode(node, container, depth) {
|
|
|
6812
6820
|
clearTimeout(dragExpandTimer);
|
|
6813
6821
|
dragExpandTimer = null;
|
|
6814
6822
|
}
|
|
6823
|
+
const springCollapsed = collapseDragExpanded();
|
|
6824
|
+
const rerenderTree = () => {
|
|
6825
|
+
const tc = document.getElementById("folder-tree");
|
|
6826
|
+
if (tc)
|
|
6827
|
+
loadFolderTree(tc);
|
|
6828
|
+
};
|
|
6829
|
+
if (springCollapsed)
|
|
6830
|
+
rerenderTree();
|
|
6815
6831
|
const folderData = e.dataTransfer.getData("application/x-mailx-folder");
|
|
6816
6832
|
if (folderData) {
|
|
6817
6833
|
let src;
|
|
@@ -6920,11 +6936,8 @@ document.addEventListener("dragend", () => {
|
|
|
6920
6936
|
if (!dragInFlight)
|
|
6921
6937
|
return;
|
|
6922
6938
|
dragInFlight = false;
|
|
6923
|
-
if (
|
|
6939
|
+
if (!collapseDragExpanded())
|
|
6924
6940
|
return;
|
|
6925
|
-
for (const key of dragAutoExpanded)
|
|
6926
|
-
delete expandState[key];
|
|
6927
|
-
dragAutoExpanded.clear();
|
|
6928
6941
|
const treeContainer = document.getElementById("folder-tree");
|
|
6929
6942
|
if (treeContainer)
|
|
6930
6943
|
loadFolderTree(treeContainer);
|