fix(render): mute banner band and rail interchange interior when their lines go inactive - #1940
Merged
Merged
Conversation
The banner strip drawn across a terminus file/files icon read its fill and text colour from hardcoded module constants, so it stayed full-strength black with white text even when every line touching the icon was inactive and the rest of the map had greyed. Thread the existing muted flag from the terminus icon render chain into the banner band and grey fill and text together as one unit, so the strip recedes with its surroundings rather than leaving a stark black band on an otherwise muted map. Closes #1895 (banner-band half).
Resolve the banner band's fill/text pair once at the terminus icon call site and hand the colours to the icon renderers, matching how fill, stroke, and font colour are already resolved there. The muted band fill now reads theme.muted_line_color instead of a second constant duplicating it, so a theme overriding the muted colour greys the banner along with everything else.
A rail interchange carrying a %%metro marker: colour tinted its interior link bar and knob cores with that declared colour, and the tint bypassed muting, so a muted interchange kept a full-strength interior while its outer casing and the rest of the map greyed. Thread the station's muted state through _render_rail_pill and _render_interchange so the interior tint resolves to theme.muted_line_color when the station is muted, overriding the marker-fill exemption. An untinted interchange keeps its background station fill, and the outer casing is unchanged. Closes #1895 (rail-interchange half).
…ix for #1895 The interior link bar was the only layer of the interchange glyph drawn without a class or station id, while the outline bar and both knob layers already carry them. Tag it with nf-metro-rail-connector-interior and the station data like its outline sibling, so it is addressable by station id and the muting test can match it the same way as every other glyph layer rather than guessing by path coordinates.
Contributor
|
Render preview is ready for review: This preview shows only the renders that changed compared to |
…iff corpus The inactive_lines gallery example now routes its two inactive subworkflows through a shared cross-track interchange carrying a declared marker colour and ends one of them at a banner file icon. Rendered with no CLI flags, both the interchange interior and the banner band render muted, so the render-diff corpus covers this muting on every PR rather than only the unit tests. Reconcile the corpus topology digest for the changed fixture. Refs #1895.
The muted band fill resolves from the theme's muted_line_color at the render call site, so pair the muted label colour with that rather than a constant.
…topology Adding the shared interchange and banner terminus to the inactive_lines example grew its guard trace (23 -> 398 guard calls) and gave it the bypass, icon_sole_continuation, and sole_continuation layout features. Regenerate the guard-trace golden and register the three feature memberships in the hand-kept manifest so both gates match the fixture's settled geometry.
pinin4fjords
marked this pull request as ready for review
September 5, 2026 22:30
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes #1895. Inactive-line muting was incomplete in two places:
theme.muted_line_colorand mute as a coherent unit.%%metro marker:glyph fills, which are intentionally exempt from muting elsewhere - stayed at its declared colour. After confirming with rendered before/after/mockup comparisons, the interior is now muted as a special case overriding the general marker-fill exemption for this piece of hardware, since a literal "mute strokes only" reading would leave a grey bar between two saturated knobs.Test plan
tests/test_inactive_lines.py)ruff check,ruff format --checkclean🤖 Generated with Claude Code