fix(association): a figure counted as none comes off the band - #1182
Merged
Conversation
The membership page read `0 Events in the past year` wherever the api counted none. A page selling the association is the last place to print a zero. The published floor is not the answer either: a floor stands for a number nobody has counted yet, and a counted zero has been counted. The figure comes off the band instead and the ones either side of it close up, so the band draws what it is given rather than a fixed four.
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
The number band leaves out a figure the api counted as zero. Found while checking main's renders:
/membershipread0 Events in the past year, because the dev database holds no events at all and/statistics/associationanswerseventsLastYear: 0.Why not the floor
FLOORSalready covers the case where the api has not answered — the page stands on a number the association publishes about itself and marks it20+. A counted zero is a different thing: it has been counted, and printing20+there would be a claim the api has just contradicted. So the figure comes off the band rather than falling back.The band now draws what it is given rather than a fixed four; the grid closes up around the gap.
Checks
254 unit tests across the association domain and the pages pass, including two new cases: a figure counted as none is left out, and one nobody has counted yet keeps its floor. Verified live — the band shows
200+ Members,11 Esports teams this season,16 Member-run committees, with the zero gone.The membership e2e suite passes 24/25; the failure is
does not animate the pitch in for a visitor who asked for less motion, which fails identically on stock main and is what #1151 is open for.Diff breakdown —
█added░removed, scaled to the largest row.