Repository navigation
Fix - clipped cards, dev-mode exit, limpet default, carrier names - #106
Merged
Merged
Conversation
…er names Closes #73, #74, #76, #90. **#73 — cards cut off.** An Avalonia ItemsControl has no scroll viewer of its own, so the MaxHeight on each dashboard list silently clipped every row past it with no way to reach them. Wrap all eight capped lists in a ScrollViewer and move the cap there. The colonisation shopping list is the one in the report, but materials, cargo, route, trade and market had the same defect. **#74 — exiting developer mode kept the fabricated data.** Turning dev mode off only updated the banner flag; the invented events had already gone through the real bus into the real CommanderState, so the cards kept showing them with nothing left to say they were fake. Route the transition through the existing reset-to-live path, which rebuilds the engine and re-warms from the journal. **#76 — limpets defaulted the trade finder.** The card guessed the commodity by tonnage, and a full limpet rack outweighs the actual haul. Skip them, and leave the field blank when limpets are all that is aboard. **#90 — market card showed a carrier callsign.** Docked/Location report a fleet carrier as its callsign; the name only ever arrives on CarrierStats. Capture the name and callsign there, record StationType, and resolve the two into a display name — substituting the name only when the docked callsign is our own carrier, since every other carrier reports a bare callsign too and labelling one of those with our carrier name would be worse than the bug. The market title becomes "Nomad's Reach (HIP 23759)" with the callsign in a tooltip; the location card and CLI use the same resolution. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
4 of 11 tasks
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.
What & why
Clears the four open bug reports against the dashboard. They are unrelated in cause but all small, so they ship together rather than as four one-line branches.
Closes #73, closes #74, closes #76, closes #90.
Changes
#73 — colonisation card is cut off. The cause is broader than the colonisation card: an Avalonia
ItemsControlhas no scroll viewer of its own, so theMaxHeighton each dashboard list clipped every row past it with no way to reach them. All eight capped lists are now wrapped in aScrollViewerwith the cap moved there — colonisation, materials, on-foot materials, on-foot mods, cargo, route, trade and market all had the identical defect.#74 — exiting developer mode doesn't reset to live data. Turning dev mode off in Settings only updated the banner flag. The fabricated events had already gone through the real bus into the real
CommanderState, so the cards kept showing invented systems and cargo — now with nothing on screen marking them as fake. The transition is routed through the existingResetToLivepath, which rebuilds the engine host and re-warms from the journal.#76 — limpets default the trade finder. The card guessed the commodity by tonnage, and a full limpet rack outweighs the actual haul. Added
CommodityName.IsLimpetin Core (coversdrones,$drones_name;, and the localised "Limpet") and skips it when guessing. The field is left blank when limpets are all that's aboard, as the issue asked.#90 — market card shows carrier callsign, not name.
Docked/Locationreport a fleet carrier as its callsign; the name only ever arrives onCarrierStats.StateTrackernow captures the carrier name and callsign from that event and recordsStationType, and a newStationDisplayhelper resolves the two into a display name.One judgment call worth a reviewer's attention: the issue notes that other commanders' carriers also report
StationType: FleetCarrier. The name is substituted only when the docked callsign matches our own carrier's. Labelling a stranger's carrier with our carrier's name would be worse than the original bug, so a carrier that isn't ours keeps its callsign — and so does ours, untilCarrierStatslands in the session.CommanderState.StationNamestill holds the raw journal value;StationDisplayNameis the new commander-facing one. Market title readsNomad's Reach (HIP 23759)with the callsign in a tooltip; the location card and CLI use the same resolution.How it was verified
14 new tests: six covering carrier naming (own carrier, another commander's carrier, docked before
CarrierStatsarrives, a normal station, and undocking) and four covering limpet recognition, plus theory cases.Not verified, and worth a reviewer's pass:
ItemsControlbehaviour, not by running the app against a long shopping list. Worth eyeballing before merge.EDNexus.Core; reachingMainWindowViewModelwould mean pulling Avalonia andBootstrapinto it, which is a larger structural change than the one-line fix warrants. Manual check: enter dev mode → randomize all → exit dev mode → cards should return to live data.CarrierStats/DockedJSON built to the documented event shapes, not a captured journal from a live carrier.Checklist
dotnet build EDNexus.slnx), no new warningsCommanderState; onlyStateTrackermutates it🤖 Generated with Claude Code