https://github.com/wintersolid/tiplit
https://github.com/wintersolid/tiplit
Last synced: 10 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/wintersolid/tiplit
- Owner: WinterSolid
- Created: 2025-06-30T18:07:52.000Z (11 months ago)
- Default Branch: main
- Last Pushed: 2025-06-30T19:35:45.000Z (11 months ago)
- Last Synced: 2025-06-30T19:41:44.032Z (11 months ago)
- Language: Swift
- Size: 10.7 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# TipLit
**TipLit** is a simple SwiftUI-based iOS app that helps users quickly calculate how much to tip and how to split a bill between multiple people.
## Features
- Input a check amount using currency formatting
- Choose the number of people to split the bill with
- Select a tip percentage from common U.S. tipping rates (10%, 15%, 18%, 20%, 25%) or No tip
- View the total amount each person needs to pay
- Simple and clean UI built with SwiftUI
- Dynamic keyboard handling with focus management
## Screenshots

### New Feature - Tip amount by percentage.

## Technologies
- Swift
- SwiftUI
- State management using `@State` and `@FocusState`
- Navigation using `NavigationStack`
- Forms and Pickers for user input
- Swift Testing (optional unit tests with Apple’s modern framework)
## Tip Calculation Logic
The per-person total is calculated with the following formula:
- Total per person = (checkAmount + tipAmount) / numberOfPeople
- tipAmount = checkAmount * (tipPercentage / 100)
## How to Run
1. Clone this repository:
git clone https://github.com/WinterSolid/TipLit.git
2. Open `TipLit.xcodeproj` or `TipLit.xcworkspace` in Xcode 16+.
3. Build and run the app in the simulator or on a real device.
## Testing
If using Apple’s Swift Testing framework:
- Run tests with `Cmd + U` to verify tip calculation logic.
- Unit tests are located in the `TipLitTests` target.
## License
This project is open source and available under the MIT License.