mirror of
https://gitlab.com/ArkHost/HelixNotes.git
synced 2026-07-24 07:45:57 +02:00
v1.0.1 - Toolbar hotkeys, graph view improvements, close to tray, AI version snapshots, window resize fix
This commit is contained in:
@@ -21,11 +21,19 @@
|
||||
|
||||
let lastMouseDown = 0;
|
||||
|
||||
const RESIZE_EDGE = 6;
|
||||
|
||||
function handleMouseDown(e: MouseEvent) {
|
||||
if (e.button !== 0) return;
|
||||
const target = e.target as HTMLElement;
|
||||
if (target.closest('.titlebar-controls') || target.closest('.titlebar-actions')) return;
|
||||
|
||||
// Don't start dragging near window edges — let Tauri handle resize
|
||||
if (!maximized) {
|
||||
const rect = (e.currentTarget as HTMLElement).getBoundingClientRect();
|
||||
if (e.clientY - rect.top < RESIZE_EDGE || e.clientX - rect.left < RESIZE_EDGE) return;
|
||||
}
|
||||
|
||||
const now = Date.now();
|
||||
if (now - lastMouseDown < 300) {
|
||||
// Double-click detected — maximize/restore
|
||||
|
||||
Reference in New Issue
Block a user