How empty-developer/calculator-ios-app-swiftui works
This is a small SwiftUI calculator. The main workflow is button input in the calculator view, dispatch to the observable view model, calculation and state updates there, then reactive display of the result and expression. The README also documents adaptive button sizing and custom Orbitron styling. The sampled source supports the app’s state injection and view-model behavior; the resource asset contents and unsampled implementation details are not mapped.
Main entry points: Calculator.swift Calculator view · ViewModelCalculator.swift Calculator state · CalculatorApp.swift App entry · ExtensionFont.swift Font styling
Components 8
User interface
- App entry
Calculator/Calculator/Application/CalculatorApp.swift - Calculator view
Calculator/Calculator/View/Calculator.swift
Calculator logic
- Calculator state
Calculator/Calculator/ViewModel/ViewModelCalculator.swift
Presentation models
- Button symbols
Calculator/Calculator/Model/ModelSymbols.swift - Operation types
Calculator/Calculator/Model/ModelOperation.swift - Font styling
Calculator/Calculator/Extension/ExtensionFont.swift - Font names
Calculator/Calculator/Model/ModelFont.swift
Other components
- User
Connections 10
- App entry → Calculator state: creates and injects
- App entry → Calculator view: presents
- User → Calculator view: taps buttons
- Calculator view → Calculator state: dispatches taps
- Calculator view → Calculator state: reads published state
- Calculator state → Button symbols: uses button cases
- Calculator state → Operation types: tracks operation
- Calculator view → Button symbols: renders labels and colors
- Calculator view → Font styling: applies font modifier
- Font styling → Font names: selects font name