Increased padding around content in views

This increased padding is roughly the same as the padding around native iOS components like lists, which makes it look a lot more uniform. The increased padding also makes everything feel a little less cramped.
This commit is contained in:
2026-01-28 00:13:10 -05:00
parent e761b7ab8a
commit 1902870e03
9 changed files with 46 additions and 29 deletions

View File

@@ -0,0 +1,27 @@
//
// BackgroundRefresh.swift
// TigerDine
//
// Created by Campbell on 1/9/26.
//
import SwiftUI
import BackgroundTasks
/// This is the global function used to tell iOS that we want to schedule a new instance of the background refresh task. It's used both in the main app to automatically reschedule a task when one completes, and also within the dining model to schedule a task when a refresh finishes.
func scheduleNextRefresh() {
let request = BGAppRefreshTaskRequest(
identifier: "dev.ninjacheetah.RIT-Dining.refresh"
)
// Refresh NO SOONER than 6 hours from now. That's not super important since the task will exit pretty much immediately
// if the cache is still fresh, but we really don't need to try more frequently than this so don't bother.
request.earliestBeginDate = Date(timeIntervalSinceNow: 6 * 60 * 60)
do {
try BGTaskScheduler.shared.submit(request)
print("background refresh scheduled successfully")
} catch {
print("failed to schedule background refresh: ", error)
}
}