Skip to content

Instantly share code, notes, and snippets.

import SwiftUI
import UIKit
struct Sunset: View {
@State var backgroundColor = Color.blue
@State var sunSetted = false
let skyGradientDay = [Color(#colorLiteral(red: 0.2196078449, green: 0.007843137719, blue: 0.8549019694, alpha: 1)), Color(#colorLiteral(red: 0.2392156869, green: 0.6745098233, blue: 0.9686274529, alpha: 1)), Color(#colorLiteral(red: 0.6254054655, green: 0.9221722869, blue: 0.9686274529, alpha: 1)), Color(#colorLiteral(red: 0.8345658875, green: 0.9221722869, blue: 0.9686274529, alpha: 1))]
let skyGradientNight = [Color(#colorLiteral(red: 0.2196078449, green: 0.007843137719, blue: 0.4246178452, alpha: 1)), Color(#colorLiteral(red: 0.8078431487, green: 0.02745098062, blue: 0.7072513187, alpha: 1)), Color(#colorLiteral(red: 0.8078431487, green: 0.02745098062, blue: 0.3333333433, alpha: 1)), Color(#colorLiteral(red: 0.8078431487, green: 0.2959635248, blue: 0.6193262317, alpha: 1))]