Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions src/App/Backlog.Desktop.UI/wwwroot/app.css
Original file line number Diff line number Diff line change
Expand Up @@ -5207,11 +5207,22 @@ h1, h2, h3 {
/* The scrollbar goes where the rows are. A plan that fits shows none — `auto`, not
`scroll`. */
.roadmap-band__timeline .roadmap-timeline__frame {
align-items: flex-start;
min-height: 0;
overflow-y: auto;
scrollbar-width: thin;
}

/* The two columns are each the frame's height or their rows', whichever is taller.
Stretched, a flex line in a frame of fixed height is that height: the track clipped
its last lanes, and scrolled down its horizontal scrollbar sat mid-chart over them.
The frame's height as a floor keeps that scrollbar on the frame's bottom edge when
the plan is short. */
.roadmap-band__timeline .roadmap-timeline__sidebar,
.roadmap-band__timeline .roadmap-timeline__scroll {
min-height: 100%;
}

/* The chart's heading row, once it is carrying the view's own heading: the heading
and its add controls at one end, the filters at the other. */
.roadmap-band__timeline .roadmap-timeline__header {
Expand Down
21 changes: 21 additions & 0 deletions tests/Backlog.Desktop.UI.UnitTests/DevbookStackLayoutTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,27 @@ public void The_roadmap_fills_its_surface_and_scrolls_inside_the_chart()
Assert.Contains("overflow-y: auto;", frame, StringComparison.Ordinal);
}

/// <summary>
/// The chart's two columns are each as tall as the frame or their own rows, whichever
/// is taller. Stretched, both were clamped to the frame's visible height: the track
/// clipped its last lanes, and scrolled down the horizontal scrollbar sat mid-chart
/// over blank lanes. With the frame's height as a minimum, a short plan still puts the
/// scrollbar on the frame's bottom edge.
/// </summary>
[Fact]
public void The_roadmap_columns_grow_with_their_rows_and_keep_the_scrollbar_at_the_bottom()
{
var css = NormalizeLineEndings(File.ReadAllText(FindAppCss()));

var frame = RuleBody(css, ".roadmap-band__timeline .roadmap-timeline__frame {");
Assert.Contains("align-items: flex-start;", frame, StringComparison.Ordinal);

var columns = RuleBody(
css,
".roadmap-band__timeline .roadmap-timeline__sidebar,\n.roadmap-band__timeline .roadmap-timeline__scroll {");
Assert.Contains("min-height: 100%;", columns, StringComparison.Ordinal);
}

/// <summary>
/// The unplanned work is a column beside the chart while there is any, scrolling on
/// its own so neither can push the other off the surface — and under the chart,
Expand Down
Loading