Timeline: draw stage-period ranges from activities, milestones on top
Each stage-transition activity now becomes a horizontal range on its lane: start = the activity's date, end = the next activity with a higher stage rank, or extending to today if still in effect. Milestone date-field dots overlay on top of the ranges. Activity dots at each range start carry a tooltip with the activity subject. Added computeStageRanges in lib/stageRank.ts and switched DateTimeline to take activities directly (deriving both the rank resolver and the ranges internally). Wide year-spanning timelines now show their full extent even when no milestone dates have been entered.
This commit is contained in:
@@ -757,7 +757,13 @@ function StaffDateTimeline({ data }: { data: StaffReportPayload }) {
|
||||
{ rank: 0, id: "all", label: "All dated events", fields: fieldConfigs },
|
||||
];
|
||||
|
||||
return <DateTimeline sections={sections} fieldHistory={fieldHistory} />;
|
||||
return (
|
||||
<DateTimeline
|
||||
sections={sections}
|
||||
fieldHistory={fieldHistory}
|
||||
activities={data.activities}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
// formatLongDate retained for symmetry with other report views; unused here
|
||||
|
||||
Reference in New Issue
Block a user