Components

Settings

Grouped rows, toggles, pickers and an about section. Built in all 5 Effect UI styles, in light and dark mode.

Settings in Prism, light mode
Settings in Prism, dark mode
Prism ProLiquid Glass on living colour.
Settings in Ledger, light mode
Settings in Ledger, dark mode
Ledger FreeCalm, precise, trustworthy.
Settings in Bounce, light mode
Settings in Bounce, dark mode
Bounce ProChunky, tactile, joyful.
Settings in Folio, light mode
Settings in Folio, dark mode
Folio ProEditorial and literary.
Settings in Bloom, light mode
Settings in Bloom, dark mode
Bloom ProSoft, organic, calming.

Source: Ledger

SettingsView.swift in the free Ledger style. It needs Ledger's Theme.swift, which comes with the style: join early access on the home page and it's emailed to you.

import SwiftUI

private struct CurrencyOption: Identifiable, Hashable {
    let code: String
    let name: String
    var id: String { code }
}

private let currencies: [CurrencyOption] = [
    CurrencyOption(code: "USD", name: "US dollar"),
    CurrencyOption(code: "EUR", name: "Euro"),
    CurrencyOption(code: "GBP", name: "British pound"),
    CurrencyOption(code: "CAD", name: "Canadian dollar"),
    CurrencyOption(code: "JPY", name: "Japanese yen"),
]

private let autoLockOptions = ["Immediately", "After 1 minute", "After 5 minutes", "After 15 minutes"]
private let exportRanges = ["Last 30 days", "Last 12 months", "This year", "All time"]

struct SettingsView: View {
    @State private var currency = currencies[0]
    @State private var faceID = true
    @State private var autoLock = "After 1 minute"
    @State private var hideBalances = false
    @State private var budgetAlerts = true
    @State private var largeTransactions = true
    @State private var weeklySummary = false
    @State private var billReminders = true
    @State private var exportRange = "Last 12 months"

    var body: some View {
        ScrollView {
            VStack(alignment: .leading, spacing: Theme.Space.xxl) {
                ScreenHeader(eyebrow: "Preferences", title: "Settings")
                generalSection
                securitySection
                notificationsSection
                dataSection
                aboutSection
                footnote
            }
            .padding(.horizontal, Theme.Space.margin)
            .padding(.top, Theme.Space.sm)
            .padding(.bottom, Theme.Space.xxl)
        }
        .scrollIndicators(.hidden)
        .paperBackground()
    }

    // MARK: Sections

    private var generalSection: some View {
        VStack(alignment: .leading, spacing: 0) {
            SectionHeader(title: "Currency")
            RuledStack {
                LedgerRow(title: "Display currency", subtitle: "Shown as \(Money.format(1234.56, code: currency.code))") {
                    Menu {
                        Picker("Display currency", selection: $currency) {
                            ForEach(currencies) { c in
                                Text("\(c.code) · \(c.name)").tag(c)
                            }
                        }
                    } label: {
                        menuLabel("\(currency.code) · \(currency.name)")
                    }
                }
                .animation(Theme.Motion.stateChange, value: currency)
                LedgerRow(title: "Budget month starts") {
                    valueLabel("On the 1st")
                }
            }
        }
    }

    private var securitySection: some View {
        VStack(alignment: .leading, spacing: 0) {
            SectionHeader(title: "Security")
            RuledStack {
                LedgerToggleRow(title: "Face ID", subtitle: "Required to open Tilde", isOn: $faceID)
                LedgerRow(title: "Lock Tilde") {
                    Menu {
                        Picker("Lock Tilde", selection: $autoLock) {
                            ForEach(autoLockOptions, id: \.self) { Text($0).tag($0) }
                        }
                    } label: {
                        menuLabel(autoLock)
                    }
                }
                .opacity(faceID ? 1 : 0.4)
                .disabled(!faceID)
                .animation(Theme.Motion.stateChange, value: faceID)
                LedgerToggleRow(title: "Hide balances", subtitle: "Until you tap to reveal", isOn: $hideBalances)
            }
        }
    }

    private var notificationsSection: some View {
        VStack(alignment: .leading, spacing: 0) {
            SectionHeader(title: "Notifications")
            RuledStack {
                LedgerToggleRow(title: "Budget alerts", subtitle: "At 80% and 100% of a budget", isOn: $budgetAlerts)
                LedgerToggleRow(title: "Large transactions", subtitle: "Anything over $500.00", isOn: $largeTransactions)
                LedgerToggleRow(title: "Bill reminders", subtitle: "Three days before a bill is due", isOn: $billReminders)
                LedgerToggleRow(title: "Weekly summary", subtitle: "Sundays at 9:00 AM", isOn: $weeklySummary)
            }
        }
    }

    private var dataSection: some View {
        VStack(alignment: .leading, spacing: 0) {
            SectionHeader(title: "Data")
            RuledStack {
                LedgerRow(title: "Export range") {
                    Menu {
                        Picker("Export range", selection: $exportRange) {
                            ForEach(exportRanges, id: \.self) { Text($0).tag($0) }
                        }
                    } label: {
                        menuLabel(exportRange)
                    }
                }
                LedgerRow(title: "Last export", subtitle: "transactions-2025-11.csv") {
                    Text("Oct 31")
                        .ledgerType(.numeralMd)
                        .foregroundStyle(Theme.onSurfaceVariant)
                }
            }
            Hairline()
            Button {
            } label: {
                Label("Export 1,284 transactions as CSV", systemImage: "square.and.arrow.up")
            }
            .buttonStyle(TextButtonStyle(color: Theme.primaryInk))
            .padding(.top, Theme.Space.xs)
        }
    }

    private var aboutSection: some View {
        VStack(alignment: .leading, spacing: 0) {
            SectionHeader(title: "About")
            RuledStack {
                LedgerRow(title: "Version") {
                    Text("2.4.1 (318)")
                        .ledgerType(.numeralMd)
                        .foregroundStyle(Theme.onSurfaceVariant)
                }
                LedgerRow(title: "Privacy policy") { RowChevron() }
                LedgerRow(title: "Terms of service") { RowChevron() }
                LedgerRow(title: "Contact support", subtitle: "Replies within one business day") { RowChevron() }
            }
        }
    }

    private var footnote: some View {
        HStack(alignment: .firstTextBaseline, spacing: Theme.Space.sm) {
            Image(systemName: "lock.fill")
                .font(.system(size: 11, weight: .semibold))
            Text("Tilde connects to your bank with read-only access. Your bank credentials are never stored on our servers.")
                .ledgerType(.bodySm)
                .fixedSize(horizontal: false, vertical: true)
        }
        .foregroundStyle(Theme.onSurfaceMuted)
    }

    // MARK: Helpers

    private func valueLabel(_ text: String) -> some View {
        Text(text)
            .ledgerType(.bodyMd)
            .foregroundStyle(Theme.onSurfaceVariant)
    }

    private func menuLabel(_ text: String) -> some View {
        HStack(spacing: Theme.Space.xs) {
            Text(text)
                .ledgerType(.bodyMd)
                .contentTransition(.opacity)
            Image(systemName: "chevron.up.chevron.down")
                .font(.system(size: 11, weight: .semibold))
        }
        .foregroundStyle(Theme.onSurfaceVariant)
        .lineLimit(1)
    }
}

#Preview("Light") {
    SettingsView()
}

#Preview("Dark") {
    SettingsView().preferredColorScheme(.dark)
}

More screens