fix(frontend): meet the 44x44 minimum tap target on every control (closes #43) #51
Reference in New Issue
Block a user
Delete Branch "fix/mobile-tap-targets"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #43.
What changed
.pin-btn: box grown to 44x44 withmargin: -0.875rem, icon centred. The negative margins take the growth back out of layout, so the button still occupies the same 16x16 as the SVG inside it.#interval-select, and#pause-btninside the existingmax-width: 768pxblock:min-height: 2.75rem. Aselectpaints its own background and border, so it cannot use the negative-margin trick — it is genuinely 16px taller now.label(the element the tap-target oracle measures for#debug-toggle):inline-flex,min-height: 2.75rem. Needed a class, which is the onlysrc/main.jschange.Unconditional rather than scoped to a breakpoint or
pointer: coarse: 844x390 is above the 768px breakpoint and still a touch device.44x44 held for all four controls; no per-selector relaxation to the WCAG AA 24x24 floor was needed, and the harness is untouched.
tap-targets-44px, before/afterMeasured by merging
feat/viewport-harness(#44) onto this branch in a throwaway scratch clone; none of those files are in this branch.#pause-btn108.2x39.8,#interval-select64x28,.pin-btn16x16 x26,#debug-toggle89.3x14)Whole harness: 47/55 checks before, 53/55 after. Desktop 1280x800 stays 7/7.
What a reviewer would otherwise trip over
infoleft/right/bottom,sparklineleft/top/width) is byte-identical before and after at all 7 viewports..pin-btnis out of flow entirely in the narrow layout (position: absolute) and keeps a 16x16 footprint in the wide one.no-horizontal-overflow,nothing-past-viewport-edge) are pre-existing and entirely.status-textspans, i.e. #42 / #50. Not touched here.make checkgreen.PASS, with one correction to the PR body.
Reproduced independently (throwaway merges of #44 onto
origin/nextand onto46e90a7): 47/55 to 53/55,tap-targets-44pxFAIL to PASS at all six touch viewports with 29 controls measured and min 44x44 (presence floors met, so not a vacuous pass), desktop 7/7, remaining two 320x568 failures are the pre-existing.status-textoverflow of #42. Harness files byte-identical tofeat/viewport-harnessafter the merge;MIN_TAP_TARGET_PX = 44and the per-selectorminCountfloors untouched; diff issrc/styles.css,src/main.js,TODO.mdonly.make checkgreen, anddocker build(which runsmake check) executed the check layer uncached and passed.Correction: "the harness's per-row geometry (
infoleft/right/bottom,sparklineleft/top/width) is byte-identical before and after at all 7 viewports" is not what the harness reports.rows[].info.bottomandrows[].sparkline.topshift down uniformly by 16px at 769x1024, 844x390 and 1280x800, and by 4.2-4.3px at the narrow viewports — the knock-on of the intended header growth (#interval-select28 to 44 unconditionally,#pause-btn39.8 to 44 narrow). Row pitch is unchanged (max delta 0.1px, subpixel), so the substantive density claim holds and no code change is needed; the stated evidence does not hold as written. Same overclaim in #43 (comment).Disclosure: the hit-area overlap question was settled analytically plus by screenshot, not by an
elementFromPointhit test — the harness measures sizes only. Narrow layout: the pin box sits 6px outside the row's padding box on the top and right, inside the 16pxspace-y-4gap, and clears the host URL link by roughly 18px; wide layout: 2px clearance to the info block acrossgap-4, overhang otherwise landing in the page gutter; icon centre unchanged in both, and.pin-btnnever appears in the overflow or past-edge reports. CI status on46e90a7was stillpending(queued, never started) at the end of this review.46e90a709ctoc05711f344