Repository navigation
Draw the container the row is actually holding - #134
Merged
Merged
Conversation
Every Stock row drew a vial. A pack of tablets drew a vial above a count of tablets, and a nasal spray bottle drew one above a count of presses, which is the kind of small lie that makes a reader distrust the rest of the screen. A pack is a blister, because that is the thing in the drawer and because the quantity it has to show is a count. Ten slots whatever the pack holds, emptying from the top as they are pressed out. A liquid level would be the wrong picture for something nobody pours. Sealed is unbroken foil rather than a full strip of ten. The two are the same quantity and not the same state, and the row offers different actions for each, so the picture has to tell them apart. It is the pack's answer to the lyophilised cake in a sealed vial. A spray keeps the vial's liquid level, since that is what it is, and spends its pixels on the pump stem and the finger flange, which are the only parts that read at this size. blisterDots is in calc with a test, because the two roundings matter more than the arithmetic. One tablet left of sixty rounds to no slots and would draw an empty strip with something still in it, so anything above empty keeps a slot. One tablet gone of sixty rounds back to full and would make a started pack look untouched, so anything below full loses one. Imprecise in the middle, never at the ends. One viewBox for all three, so a column lines up and swapping one for another does not move the row.
|
Someone is attempting to deploy a commit to the Arun's projects Team on Vercel. A member of the Team first needs to authorize it. |
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.
Every Stock row drew a vial. A pack of tablets drew a vial above a count of tablets; a nasal spray bottle drew one above a count of presses. It is the kind of small lie that makes a reader distrust the rest of the screen.
A pack is a blister
Because that is the thing in the drawer, and because the quantity it has to show is a count. Ten slots whatever the pack holds, emptying from the top as they are pressed out. A liquid level would be the wrong picture for something nobody pours.
Sealed is unbroken foil, not a full strip of ten. The two are the same quantity and not the same state, and the row offers different actions for each, so the picture has to tell them apart. It is the pack's answer to the lyophilised cake in a sealed vial.
A spray keeps the level
It is a liquid in a container, so it keeps the vial's fluid level. What it drops is the crimp cap: the pump stem and the finger flange are the only parts of a spray bottle that read at this size, so that is where the drawing spends its pixels.
The rounding is the interesting part
blisterDotsis incalc/tablet.tswith a test, because the two ends matter more than the arithmetic:Imprecise in the middle, never at the ends.
One viewBox for all three, so a column of rows lines up and swapping one glyph for another does not move anything.
Checks
npx tsc --noEmitclean,npx next lintclean, 1704 tests pass (6 new).