How zengs7991-a11y/today-money-printer works
今日印钞 is a native macOS menu-bar app that estimates and displays earnings accumulated today. The user configures pay, work hours, breaks, calendar rules, overtime, and a manual work state; the store computes live metrics that the menu-bar label and settings window present. The source is concentrated in two files, so the graph focuses on those runtime responsibilities. Holiday synchronization is documented and partially shown in WageStore; detailed parsing and data flow beyond the excerpt are not expanded.
Main entry points: WageStore.swift Wage store · WageBarApp.swift Menu and settings
Components 10
Menu-bar UI
- App entry
Sources/WageBarApp.swift - Menu and settings
Sources/WageBarApp.swift - Status-bar display
Sources/WageBarApp.swift
Wage calculation
- Wage store
Sources/WageStore.swift - Pay and schedule rules
Sources/WageStore.swift - Earnings metrics
Sources/WageStore.swift
Calendar and persistence
- Holiday synchronization
Sources/WageStore.swift - Local settings
Sources/WageStore.swift
Other components
- User
- Official holiday source
Connections 12
- User → Menu and settings: configures
Sources/WageBarApp.swift - App entry → Wage store: creates
Sources/WageBarApp.swift - App entry → Menu and settings: presents
Sources/WageBarApp.swift - App entry → Status-bar display: shows
Sources/WageBarApp.swift - Menu and settings → Wage store: updates state
Sources/WageBarApp.swift - Menu and settings → Earnings metrics: displays
Sources/WageBarApp.swift - Wage store → Pay and schedule rules: uses rules
Sources/WageStore.swift - Wage store → Earnings metrics: calculates
Sources/WageStore.swift - Wage store → Local settings: loads and saves
Sources/WageStore.swift - Wage store → Holiday synchronization: starts sync
Sources/WageStore.swift - Holiday synchronization → Official holiday source: fetches calendar
Sources/WageStore.swift - Status-bar display → Earnings metrics: renders metrics
Sources/WageBarApp.swift