EyeHack
EyeHack — 1
EyeHack — 2
EyeHack icon

EyeHack

MacOS menubar app for 20-20-20 eye break rule

Apr 2026
  • rust
  • tauri
  • react
  • macos
  • menubar

EyeHack

A macOS menubar app that enforces the 20-20-20 rule: every 20 minutes it hijacks every display for 20 seconds so your eyes get an unavoidable break.

What it does

  • Sits silently in the menubar — invisible while you work.
  • Every 20 minutes triggers a full-screen overlay across all connected displays.
  • Overlay randomly rotates between three break modules (never repeats the same one twice in a row):
    • Distance Illusion — a hybrid optical illusion whose image shifts depending on viewing distance, training the eye to refocus.
    • Sci-Zen — a minimal breathing prompt.
    • Brain Reset — a riddle with a delayed answer reveal.
  • Skips breaks automatically when the screen is recording, the camera is active, or a meeting app is holding the display awake.
  • Resets its timer after sleep, so there's no surprise break at 9 a.m.
  • Plays a completion sound when the break ends.
  • No dismiss-early button.

Stack

LayerTech
BackendRust, Tauri v2
FrontendReact 19, TypeScript, Vite
StylingTailwind CSS
Package managerpnpm

Meeting / recording detection

Breaks are skipped when any of these are true:

SignalDetection
Screen recording activeioregCGSIsCapturing key present
Camera in usepgrep -x VDCAssistant succeeds
Meeting app holding display awakepmset -g assertions contains PreventUserIdleDisplaySleep + a known app name

Apps checked: Zoom, Google Chrome, Brave Browser, Teams, Slack.

Sleep awareness

The 20-minute timer uses SystemTime (wall clock) rather than Instant (monotonic, which pauses during sleep). If the gap between ticks exceeds 3 minutes the system was asleep — the accumulator resets and gives a fresh 20-minute window after wake.

Auto-updates

Install once and forget. New versions arrive on their own — the app quietly checks at launch and offers to update. There's a "Check for Updates…" item in the tray menu if you're impatient.

Comments