fix(central-ui): rail nav scrolls in its own pane so the footer stays pinned
NavMenu wraps its items in .rail-scroll; site.css fills the sticky rail on lg+ and lets that wrapper scroll. Kit untouched. Claude-Session: https://claude.ai/code/session_01Y5ef34iUUMjmwnMpL9xgmB
This commit is contained in:
@@ -241,4 +241,25 @@ public class NavMenuTests : BunitContext
|
||||
Assert.DoesNotContain("/audit/log", cut.Markup);
|
||||
});
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// ThemeShell's <c>nav.side-rail</c> never fills the sticky 100vh rail, so
|
||||
/// a long expanded nav grows past the viewport and pushes
|
||||
/// <c>.rail-foot</c> off-screen. <c>NavMenu</c> wraps its items in a
|
||||
/// <c>div.rail-scroll</c> pane that <c>site.css</c> makes scroll on its
|
||||
/// own (lg+), leaving the brand bar and rail footer pinned. This asserts
|
||||
/// the wrapper exists and actually contains the nav sections, not just
|
||||
/// that the class string appears somewhere in the markup.
|
||||
/// </summary>
|
||||
[Fact]
|
||||
public void NavItems_RenderInsideTheRailScrollPane()
|
||||
{
|
||||
var cut = RenderWithRoles("Administrator", "Designer", "Deployer");
|
||||
|
||||
cut.WaitForAssertion(() =>
|
||||
{
|
||||
Assert.Contains("class=\"rail-scroll\"", cut.Markup);
|
||||
Assert.NotEmpty(cut.FindAll("div.rail-scroll details.rail-section"));
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user