fix(roadtrip): the rail passes the strict and lint gates, and its tests describe the new markup

The day head falls back to metric when no distance unit is set, VISIT_BOX is no longer exported, the day head is split into smaller parts and the booking icon is created once. The component tests now check the pill badges, the day tile and the ride cards instead of the old boxes, and both baselines are lowered to the new counts.
This commit is contained in:
Maurice
2026-10-11 14:01:18 +02:00
parent e8fd41b9b4
commit 32606d20a6
13 changed files with 458 additions and 267 deletions
@@ -217,6 +217,8 @@ describe('DayPlanSidebar day header', () => {
render(<DayPlanSidebar {...makeDefaultProps({ days, accommodations })} />);
expect(dayHeader('Day 1').style.alignItems).toBe('center');
expect(dayHeader('Day 1').querySelector('[data-dp="day-pill"]')).toBeNull();
expect(dayHeader('Day 2').style.alignItems).toBe('flex-start');
// The head is a grid now, so the pills can sit on a row of their own under the name.
expect(dayHeader('Day 2').style.display).toBe('grid');
expect(dayHeader('Day 2').style.alignItems).toBe('start');
});
});
+1 -1
View File
@@ -79,7 +79,7 @@ export function MoreButton({ label, items, size = 26, alwaysVisible = false, cla
/** A time or time range as a white badge, like the other facts on a card. */
/** A small white badge on a row's second line, for what the row says about when. */
export function WhiteBadge({ children, icon, className = '', quiet = false }: {
export function WhiteBadge({ children, icon, className = '' }: {
children: ReactNode
icon?: ReactNode
className?: string