81826589d8bf9d64a1efa8d0286431d13178c3a2
Every control in the settings sheet calls resetClocks(), so opening it mid-match could throw away two live clocks. The gear now only appears on an untouched match: before the first tap, or after a two-tap reset. "Untouched" is derived rather than tracked — phase, turn, moves, score and both reserves matching matchTime() — so it cannot fall out of sync the way a stored flag could. The phase alone would be wrong: a score change runs newGame(), which returns to IDLE waiting for the next game's first tap while the match is still very much on. The reserve check also catches a clock corrected through the score sheet. The button uses visibility rather than [hidden], so its slot stays put and the rest of the bar doesn't jump the instant the clock starts; verified pixel-for-pixel that reset, play/pause, score and sound do not move. visibility:hidden also drops it from the tab order and the accessibility tree. The rule is enforced in the click handler as well, because a programmatic click still reaches a visibility:hidden button — CSS is the affordance, the guard is the rule. The trade, deliberately: a mistake in the time or delay now costs a reset and a restarted match. Correcting a clock mid-match is the score sheet's job. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Description
A backgammon clock: both a Progressise Web App (PWA) and an Android App.
https://bgclock.hansdezwart.nl
1.2 MiB
Languages
HTML
81%
Python
9.2%
Java
8.5%
JavaScript
1.3%