I would like to add some space on top of the TabView() elements, since I feel like the top of the Label images is too close to the edge of the TabView().
I'm posting here because I've already tried to add .padding(.top, value) // where value is an int like 20. The thing is, this acts weirdly and adds padding to the top of the screen (see comment in code block below).
This is the entire ContentView.swift file:
import SwiftUI
import WidgetKit
import UserNotifications
import UIKit
struct ContentView: View {
@StateObject var sharedVars = SharedVarsBetweenTabs()
var body: some View {
TabView {
HomeView()
.tabItem {
Label("Home", systemImage: "house.fill")
}
AppearanceView()
.tabItem {
Label("Appearance", systemImage: "paintbrush.fill")
}
QuotesView()
.tabItem {
Label("Quotes", systemImage: "quote.bubble.fill")
}
}
// This is where I tried putting .padding(.top, 20)
.environmentObject(sharedVars)
.accentColor(.blue)
.onAppear {
UITabBar.appearance().backgroundColor = UIColor.black
UITabBar.appearance().unselectedItemTintColor = UIColor.white
}
}
}
class SharedVarsBetweenTabs: ObservableObject {
@Published var colorPaletteIndex = 0
}
Inside of the views, they all have a VStack with these same attributes:
.frame(maxWidth: .infinity)
.padding()
.background(ColorPaletteView(colors: [colorPalettes[safe: sharedVars.colorPaletteIndex]?[0] ?? Color.clear])) // This corresponds to the blue int he screenshot
This is currently what it looks like:

A few days ago, I met someone who wanted to edit the text, and the idea came into use.
\(^o^)/
Solution: reduce the size + leave the top blank
Others: Text Process: https://stackoverflow.com/a/78169838/23574168
Function:
Complete: