What the Sessions grid does today, run against different mixes of interview lengths. Written 9 Nov 2026.
Commentary
This page is a diagram of the scale logic, not the product UI. Bars are drawn flat, without the real clip colours or the closed strip. The three functions below are copied from frontend/src/utils/tapestryScale.ts (fitScale, zoomScale, the 82 px gutter and 14 px right margin). Nothing here is a proposal yet.
The opening view. Every open timeline in the grid shares one scale, in seconds per pixel, chosen from the durations of all sessions in the project:
Throw out outliers. Drop sessions shorter than ¼ of the median or longer than 4× the median. They are still drawn, at the same scale.
Fit the shortest of the rest to the usable width (grid width − 96 px), so no kept session opens with white space on its right.
Cap the longest of the rest at four usable widths. If fitting the shortest would make the longest wider than that, the scale loosens until the longest is exactly four widths and the shortest is left with white space.
Hard ceiling of 4 s/px, which beats everything. It binds whenever the shortest kept session is longer than 4 × usable seconds: about 60 minutes at a 1000 px table, 34 minutes at 600 px, 114 minutes at 1800 px. The code comment that says it "bites only below a ~220 px table" is wrong for projects of hour-long sessions.
So the opening scale is min(4, max(shortest / usable, longest / (4 × usable))). The slider's far-left stop is that same scale. There is nothing to the left of it, so you can never zoom out to see a session that opens wider than the table.
The slider. 0–100, log-spaced. 0 is the opening scale (“1×”). 100 is min(0.25, fit / 4) s/px, which is 0.25 s/px (4 px per second) unless the opening scale is already finer than 1 s/px, in which case it is four times finer than the opening scale. The last column of each summary shows the width of the longest session at that stop.
usable = width − 82 − 14
kept: sets the scaleleft out as an outlier, still drawnduration unknown (0)→ 3.6× runs off the right edge, reached by scrolling sideways
This page is a diagram of the scale logic, not the product UI. Bars are drawn flat, without the real clip colours or the closed strip. The three functions below are copied from
frontend/src/utils/tapestryScale.ts(fitScale,zoomScale, the 82 px gutter and 14 px right margin). Nothing here is a proposal yet.The opening view. Every open timeline in the grid shares one scale, in seconds per pixel, chosen from the durations of all sessions in the project:
So the opening scale is
min(4, max(shortest / usable, longest / (4 × usable))). The slider's far-left stop is that same scale. There is nothing to the left of it, so you can never zoom out to see a session that opens wider than the table.The slider. 0–100, log-spaced. 0 is the opening scale (“1×”). 100 is
min(0.25, fit / 4)s/px, which is 0.25 s/px (4 px per second) unless the opening scale is already finer than 1 s/px, in which case it is four times finer than the opening scale. The last column of each summary shows the width of the longest session at that stop.