# Aurora Core -- SwiftUI Reference Source-only SwiftUI implementation of the Aurora Core v5.4.0 design system. Requires **SwiftUI** and **iOS 17+** (or equivalent Apple platform). ## Files | File | Description | |------|-------------| | `AuroraTheme.swift` | Color tokens, spacing, radius, typography, glass-depth constants, duration/easing/leading constants, badge/alert tone enums | | `AuroraButtonStyle.swift` | Custom `ButtonStyle` with 7 variants (primary, secondary, tertiary, ghost, success, warning, danger) | | `AuroraToggleStyle.swift` | Purple-to-blue liquid toggle (never gold on toggles) | | `AuroraSliderStyle.swift` | Custom slider with tinted track, gradient fill, shimmer, and drag thumb | | `AuroraBadge.swift` | Tone-colored badge with optional status dot (gold glows, amber does not) | | `AuroraProgressBar.swift` | Determinate progress bar with tinted track and gradient fill | | `AuroraCard.swift` | Glass card with 3 depth tiers (8/20/32px blur) | | `AuroraTextInput.swift` | Text field with gold focus ring, red error border, disabled state | | `AuroraAlert.swift` | Inline alert banner with 5 tones (gold glows, amber is matte) | | `AuroraTabs.swift` | Segmented tab bar with gold active underline and glass track | | `ExampleView.swift` | Full showcase of all components with interactive state | ## Integration 1. Copy all `.swift` files into your Xcode project or Swift package. 2. Ensure your target imports `SwiftUI` and links `UIKit` (required for dynamic color support). 3. Set your deployment target to iOS 17.0 or later. 4. Use `ExampleView()` as a starting point or reference for wiring up components. ## Design Rules These rules are enforced across all components: - **Gold emits light.** Gold is the hero accent -- primary actions, focus rings, active indicators always glow. - **Amber does not glow.** Amber is for matte warnings only. - **Depth is optical.** Glass blur at 8/20/32px tiers. `.shadow()` is supplementary glow at low alpha, never primary elevation. - **Toggles use purple-to-blue.** Never gold on toggles. - **Tinted tracks.** Progress bars and sliders use a faint tint of their fill color, never neutral grey. - **No hardcoded hex.** Always reference `AuroraColor.*` constants. ## Tokens All color, spacing, radius, typography, glass-depth, duration, easing, and leading values are defined in `AuroraTheme.swift` and map 1:1 to the canonical `tokens/aurora-core.tokens.json` dataset.