diff options
| author | Fuwn <[email protected]> | 2026-05-19 00:26:50 +0000 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2026-05-19 00:26:50 +0000 |
| commit | b429cf8d3b566a6ec665cd4f2ec34f55c3138179 (patch) | |
| tree | 3306e2da318f5029867ca7af131d7d82665d3d51 | |
| parent | fix(a11y): scope focus-visible ring to header items (diff) | |
| download | due.moe-b429cf8d3b566a6ec665cd4f2ec34f55c3138179.tar.xz due.moe-b429cf8d3b566a6ec665cd4f2ec34f55c3138179.zip | |
fix(a11y): bump touch targets to 44px under pointer:coarse
Inputs, buttons, and selects baseline at 32px (2em), well below WCAG
2.5.5's 44x44 minimum. Adds a coarse-pointer media block that lifts
the standard height to 2.75rem, neutralises aggressive 0.75 scale on
.smaller-button / .button-square (transforms shrink hit-test rects),
and grows the checkbox from 1.15em to 1.5rem.
| -rw-r--r-- | src/styles/input.css | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/src/styles/input.css b/src/styles/input.css index a46c9b13..83512bab 100644 --- a/src/styles/input.css +++ b/src/styles/input.css @@ -173,3 +173,33 @@ button:disabled:active { .no-shadow { box-shadow: none; } + +@media (pointer: coarse) { + input, + button, + select { + height: 2.75rem; + } + + input[type="text"], + input[type="number"], + input[type="date"], + input[type="time"], + input[type="file"], + button, + select { + padding: 0.5em 0.75em; + } + + input[type="checkbox"] { + width: 1.5rem; + height: 1.5rem; + } + + .smaller-button, + .button-square { + transform: none; + min-height: 2.75rem; + min-width: 2.75rem; + } +} |