From 230e5c0b4afa3c642bad0fb7ac4fdd02ab5d071b Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Tue, 23 Jun 2026 13:07:56 +0000 Subject: [PATCH] Add hover tooltips on Gantt bar resize ears Show Start and End dates when hovering the left and right ears, using the existing gtip overlay with a shorter reveal delay. Co-authored-by: Tanops --- src/app/main.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/app/main.js b/src/app/main.js index 3281b36..c0acea6 100644 --- a/src/app/main.js +++ b/src/app/main.js @@ -439,6 +439,7 @@ function renderGantt(){ const tip=`${n.title} · ${SIZE_NAMES[sz]} · ${fmtD(dayIso(e))}${late?' (late)':''}${hasKids?` · ${donePct}% done`:""}`+(ctx ?` — ${ctx.proj}${ctx.parent?" › "+ctx.parent:""} · ${({high:"high",med:"medium",low:"low"})[n.priority||"med"]} priority · ${person(n.owner).name}` :""); + const startTip=`Start · ${fmtD(dayIso(s))}`, endTip=`End · ${fmtD(dayIso(e))}`; return `
- + ${av(n.owner,"xs")} ${n.title} - +
${extra?`
${extra}
`:""}
`; }; @@ -1632,7 +1633,7 @@ function hoverOn(target){ const key=host.dataset.tid||host.dataset.full; if(key!==tipKey){ // moved onto a new bar → arm the reveal delay clearTimeout(tipTimer); tipKey=key; tipEl=host; TIP.style.display="none"; - tipTimer=setTimeout(revealTip,600); return; + tipTimer=setTimeout(revealTip,host.classList.contains("ear")?250:600); return; } tipEl=host; // same bar (may be a fresh node after a render) if(TIP.style.display==="block") placeTip(); // already shown → follow the cursor