Closed godlygeek closed 10 months ago
In fixing the bug that caused two data points like 50, 100 to show up as
⠀⢸
⠀⢸
⢸⣿
⢸⣿
instead of as
⢸
⢸
⣿
⣿
I also removed some caching inside of MemoryGraph
. It seemed like overkill, considering we're only dealing with 100 data points and 200 Unicode characters. If you object to removing the caching, though, I can re-add it - the trick will be that we need to bounce between two previously rendered versions, one for even ticks and one for odd ticks.
I think that's probably overkill, but I don't think it's hard to add if you want it.
All modified and coverable lines are covered by tests :white_check_mark:
Comparison is base (
1cce4cb
) 92.30% compared to head (bc029c3
) 92.27%.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
This is easier to read than our previous braille version, and looks nicer when rendered in a browser or VS Code. It's less granular, unfortunately. The braille version added a new dot for each ~6%, and this implementation adds a new half block for each ~11%.
This also fixes a longstanding bug: the graph was only showing half of the data points it should have been showing. Each data point would become the right braille column of one cell as well as the left braille column of the next cell, so we only had half the horizontal granularity we should have had.