Avoid selector parsing for drag paths

This commit is contained in:
Mikei386
2026-06-23 06:45:08 +02:00
parent e0a61c074e
commit 11b76f4572
5 changed files with 7 additions and 12 deletions
+1 -1
View File
@@ -2,7 +2,7 @@
set -eu set -eu
PLUGIN="u-navigator" PLUGIN="u-navigator"
VERSION="2026.06.23.r002" VERSION="2026.06.23.r003"
PKG_DIR="packages" PKG_DIR="packages"
WORK_DIR=".plugin-build" WORK_DIR=".plugin-build"
PKG_NAME="${PLUGIN}-${VERSION}.tgz" PKG_NAME="${PLUGIN}-${VERSION}.tgz"
Binary file not shown.
Binary file not shown.
+3 -8
View File
@@ -655,9 +655,11 @@ function findPointerDropTarget(event) {
} }
function markDraggingRow(path, dragging) { function markDraggingRow(path, dragging) {
for (const row of workspace.querySelectorAll(`.file-row[data-path="${cssEscape(path)}"]`)) { for (const row of workspace.querySelectorAll('.file-row')) {
if (row.dataset.path === path) {
row.classList.toggle('dragging', dragging); row.classList.toggle('dragging', dragging);
} }
}
} }
function lockExplorerScroll(win, body) { function lockExplorerScroll(win, body) {
@@ -792,13 +794,6 @@ function escapeAttr(value) {
return escapeHtml(value); return escapeHtml(value);
} }
function cssEscape(value) {
if (window.CSS?.escape) {
return CSS.escape(String(value));
}
return String(value).replace(/["\\]/g, '\\$&');
}
function clamp(value, min, max) { function clamp(value, min, max) {
return Math.max(min, Math.min(max, value)); return Math.max(min, Math.min(max, value));
} }
+2 -2
View File
@@ -1,7 +1,7 @@
<!DOCTYPE PLUGIN [ <!DOCTYPE PLUGIN [
<!ENTITY name "u-navigator"> <!ENTITY name "u-navigator">
<!ENTITY author "michael"> <!ENTITY author "michael">
<!ENTITY version "2026.06.23.r002"> <!ENTITY version "2026.06.23.r003">
<!ENTITY package "&name;-&version;.tgz"> <!ENTITY package "&name;-&version;.tgz">
]> ]>
<PLUGIN name="&name;" author="&author;" version="&version;" pluginURL="https://git.casaderoll.de/michael/Unraid-Navigator/raw/branch/main/u-navigator.plg"> <PLUGIN name="&name;" author="&author;" version="&version;" pluginURL="https://git.casaderoll.de/michael/Unraid-Navigator/raw/branch/main/u-navigator.plg">
@@ -14,7 +14,7 @@
<FILE Name="/boot/config/plugins/&name;/&package;"> <FILE Name="/boot/config/plugins/&name;/&package;">
<URL>https://git.casaderoll.de/michael/Unraid-Navigator/raw/branch/main/packages/&package;</URL> <URL>https://git.casaderoll.de/michael/Unraid-Navigator/raw/branch/main/packages/&package;</URL>
<MD5>0a9e56a6a4ddf7648388b25a3dedb264</MD5> <MD5>c1ad74583e3a83dae808677aceb76d79</MD5>
</FILE> </FILE>
<FILE Run="/bin/bash"> <FILE Run="/bin/bash">