feat(centralui): adopt Theme 0.5.3 ScrollNav rail scroll pane (#61)
Bump ZB.MOM.WW.Theme 0.5.0 -> 0.5.3, set ThemeShell ScrollNav=true, drop NavMenu's own .rail-scroll wrapper and the site.css rail scroll block (keeps .rail-updates*). NavMenu test now asserts no local wrapper. Claude-Session: https://claude.ai/code/session_01GT67ACmpMR7b9LGRPLijMi
This commit is contained in:
@@ -254,23 +254,19 @@ public class NavMenuTests : BunitContext
|
||||
}
|
||||
|
||||
/// <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.
|
||||
/// The rail scroll pane is owned by the kit (ThemeShell ScrollNav="true",
|
||||
/// Theme 0.5.3). NavMenu must not add its own <c>.rail-scroll</c> wrapper,
|
||||
/// or the rail gets two nested scroll panes.
|
||||
/// </summary>
|
||||
[Fact]
|
||||
public void NavItems_RenderInsideTheRailScrollPane()
|
||||
public void NavItems_DoNotCarryTheirOwnRailScrollWrapper()
|
||||
{
|
||||
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"));
|
||||
Assert.NotEmpty(cut.FindAll("details.rail-section"));
|
||||
Assert.DoesNotContain("rail-scroll", cut.Markup);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user