A beautiful 60-minute analog timer application built with Tauri 2.0, React, and TypeScript. Works on desktop (macOS, Windows, Linux), Android, and iOS.
- 60-Minute Analog Clock Face: Visual circular timer with red arc showing remaining time
- Intuitive Drag Interface: Click and drag anywhere on the clock face to set time (0-60 minutes)
- Timer Controls: Start, Pause, Reset, and Stop buttons
- Alarm System: Toggle sound notifications on/off (persisted in localStorage)
- Visual Notifications: Flashing red screen and "TIME'S UP!" overlay when timer completes
- System Notifications: Native OS notifications when timer finishes
- Audio Alarm: Looping alarm sound (when enabled)
- Responsive Design: Optimized for desktop, tablets, and mobile devices
- Touch Support: Full touch interface for mobile platforms
- Cross-Platform: Runs natively on macOS, Windows, Linux, Android, and iOS
The app displays a classic analog clock face with:
- Black and white background
- Red arc showing remaining time
- Digital time display (MM:SS) in the center
- 5-minute tick marks (0, 15, 30, 45, 60)
- Draggable red knob for setting time
- Rust 1.70+ (https://rustup.rs/)
- Node.js 18+ and npm
- For mobile: See SETUP.md for platform-specific requirements
- Clone and install dependencies:
npm install- Add an alarm sound (Required for audio functionality):
- Download an alarm sound (MP3 or OGG format)
- Save it as
public/alarm.mp3 - Free sounds available at: https://freesound.org/
Desktop Development:
npm run tauri devDesktop Production Build:
npm run tauri buildAndroid:
npm run tauri android init # First time only
npm run tauri android dev # Run on device/emulatoriOS:
npm run tauri ios init # First time only
npm run tauri ios dev # Run on device/simulator- Set Time: Click and drag on the clock face to set desired time (0-60 minutes)
- Start Timer: Click the "Start" button to begin countdown
- Pause: Click "Pause" to pause the timer
- Resume: Click "Start" again to resume
- Reset: Click "Reset" to return to originally set time
- Stop: Click "Stop" to clear timer completely
- Toggle Alarm: Click the alarm button (🔊/🔇) to enable/disable sound
- Framework: Tauri 2.0
- Frontend: React 18 + TypeScript
- Build Tool: Vite 6
- Backend: Rust
- Styling: CSS3 with responsive design
- Plugins:
tauri-plugin-notification- System notificationstauri-plugin-opener- Open URLs
visual-timer-tauapp/
├── src/ # React frontend
│ ├── App.tsx # Main timer component
│ ├── App.css # Styles
│ └── main.tsx # React entry point
├── src-tauri/ # Rust backend
│ ├── src/
│ │ ├── lib.rs # Tauri app setup
│ │ └── main.rs # Entry point
│ ├── Cargo.toml # Rust dependencies
│ └── tauri.conf.json # App configuration
├── public/ # Static assets
│ └── alarm.mp3 # Alarm sound (add this)
├── SETUP.md # Detailed setup instructions
└── README.md # This file
- Default size: 500x700px
- Resizable: Yes
- Centered on screen
- Android: Minimum SDK 24 (Android 7.0)
- iOS: Minimum iOS 13.0
-
Timer Logic (src/App.tsx:30-81):
- Uses
setIntervalfor 1-second countdown - Automatically stops and triggers notifications at 00:00
- Uses
-
Drag Mechanism (src/App.tsx:105-163):
- Calculates angle from mouse/touch position
- Converts angle to minutes (0-60)
- Supports both mouse and touch events
-
Visual Feedback (src/App.css):
- SVG-based analog clock with arc drawing
- Flashing red animation on completion
- Responsive breakpoints for mobile
-
Notifications:
- System notifications via Tauri plugin
- Audio playback via HTML5 audio element
- Visual overlay with pulsing animation
npm run tauri buildOutput: src-tauri/target/release/bundle/
npm run tauri android buildOutput: src-tauri/gen/android/app/build/outputs/
npm run tauri ios buildOutput: src-tauri/gen/apple/build/
No alarm sound?
- Ensure
public/alarm.mp3exists - Check alarm toggle is ON (green)
- Verify device volume
Build errors?
- Run platform init commands first
- Check Rust and Node.js versions
- See SETUP.md for detailed help
Performance issues?
- Timer uses <5% CPU normally
- Ensure no other heavy processes running
This is based on the specification from /Users/gpalagan/source/visual-timer/SPECIFICATION.md
MIT