Widen the edge-tab tap target, split scroll from reposition #9

Merged
sulthan merged 5 commits from userscript-edge-tab-hitbox into main 2026-07-28 20:36:26 +07:00
Showing only changes of commit c0fbe4a13f - Show all commits
+7 -1
View File
@@ -1048,6 +1048,12 @@
reset(); reset();
if (didDrag) snapToEdge(); // OS claimed the gesture mid-drag — don't strand the FAB if (didDrag) snapToEdge(); // OS claimed the gesture mid-drag — don't strand the FAB
}); });
// touch-action: none stops panning and zooming but NOT Chromium's long-press
// gesture, which fires at ~500ms — just after ARM_MS — raises the context
// menu, and cancels the pointer stream. The hold armed the drag and the OS
// stole it back a frame later. Suppressing the menu keeps the pointer alive.
fab.addEventListener("contextmenu", (e) => e.preventDefault());
} }
// ============================================================ // ============================================================
@@ -1403,7 +1409,7 @@
border-radius: 4px 0 0 4px; border-radius: 4px 0 0 4px;
background: #6d28d9; opacity: .45; background: #6d28d9; opacity: .45;
box-shadow: 0 2px 8px rgba(0,0,0,.4); z-index: 2147483646; cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,.4); z-index: 2147483646; cursor: pointer;
touch-action: none; user-select: none; touch-action: none; user-select: none; -webkit-touch-callout: none;
} }
#fab.left { border-radius: 0 4px 4px 0; } #fab.left { border-radius: 0 4px 4px 0; }
#fab:active, #fab.armed { opacity: 1; } #fab:active, #fab.armed { opacity: 1; }