Skip to content

Render the Gantt chart with @tasknotes/calendar's timeline - #16

Merged
callumalpass merged 4 commits into
mainfrom
calendar/tnc-timeline
Oct 26, 2026
Merged

callumalpass merged 4 commits into
mainfrom
calendar/tnc-timeline

Conversation

@callumalpass

Copy link
Copy Markdown
Owner
  • Render Planner's Gantt with the shared TaskNotes calendar timeline engine (@tasknotes/calendar@0.1.0).
  • Keep grouped task ledgers, inclusive due dates, milestones and timed schedules.
  • Support drag/resize, unscheduled placement, keyboard edits and edge-based dependency links.
  • Preserve pointer-anchored zoom, phone row alignment, completion and inspector workflows.
  • Use the published calendar and model (@tasknotes/model@0.3.0-rc.17) packages.

Verified locally: pnpm install --frozen-lockfile, pnpm run verify (format, typecheck, lint, 199 unit tests, production build), Planner e2e 13/13 on desktop and phone.

…line

Replace the hand-built Gantt surface with the timeline view of the vendored
@tasknotes/calendar 0.1.0-dev.0. Rows, grouping, bars, milestones, dependency
arrows, drag/resize writes, link creation, scales, the today line and
selection now come from the library; Planner keeps its ledger (rendered into
the row labels), domain mapping and write handling.

- gantt.ts: map tasks to timeline items (exclusive end = due + 1 day) and
  map drops/resizes/placements back to scheduled and inclusive due values.
- Ctrl/Cmd+wheel zoom stays in the chart and keeps the pointer date anchored.
- Theme the calendar through --tnc-theme-* tokens from Planner's palette.
… in the Gantt

Update @tasknotes/calendar and drop Planner-side workarounds:

- Links are made by dragging start/finish handles. The edge pair sets
  the relationship (FS/SS/FF/SF). canLink and onLinkDrag drive the
  refusal message while dragging.
- Dependencies are passed with their type (timelineDependencies), so
  start-to-start and other non-FS links draw correctly and are no longer
  flagged as conflicts.
- Unscheduled tasks can be dropped on group headings and the date header
  again. The calendar's hit areas replace Planner's own bounds check, and
  drops that miss report "Schedule unchanged".
- The zoom scale passes dayWidth instead of copying the unit table.
  Ctrl/Cmd+wheel zoom anchors on the pointer through setOptions, and
  Today uses scrollToDate with smooth scrolling. The manual scroll math
  is removed.
- Ledger portals mount through rowLabelDidMount/WillUnmount. The
  calendar now suppresses the click after a drag, so Planner's own
  ignore logic is removed.
- Selection, today label and focusable scheduled/due resize grips come
  from the calendar.
@callumalpass
callumalpass merged commit 923ecd1 into main Oct 26, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant