txtodo

[DORMANT] a minimalist todo list app inspired by jeff huang
git clone git://git.figbert.com/txtodo.git
Log | Files | Refs | README

SettingsView.swift (1352B)


      1 //
      2 //  SettingsView.swift
      3 //  txtodo (macOS)
      4 //
      5 //  Created by FIGBERT on 8/6/20.
      6 //
      7 
      8 import SwiftUI
      9 
     10 struct SettingsView: View {
     11     @StateObject var storeManager: StoreManager
     12     
     13     var body: some View {
     14         TabView {
     15             VStack {
     16                 Text("txtodo by figbert - v\(Bundle.main.infoDictionary?["CFBundleShortVersionString"] as! String)")
     17                     .padding()
     18                 Link(destination: URL(string: "https://txtodo.app/")!) { Text("view site") }
     19                 Link(destination: URL(string: "https://jeffhuang.com/productivity_text_file/")!) { Text("view inspo") }
     20             }
     21                 .tabItem {
     22                     Text("about")
     23                     Image(systemName: "book")
     24                 }
     25             Form { NotificationSection() }
     26                 .padding()
     27                 .tabItem {
     28                     Text("notifications")
     29                     Image(systemName: "app.badge")
     30                 }
     31             DonationSection(storeManager: storeManager)
     32                 .tabItem {
     33                     Text("tip jar")
     34                     Image(systemName: "creditcard")
     35                 }
     36         }
     37             .frame(width: 300, height: 150)
     38     }
     39 }
     40 
     41 struct SettingsView_Previews: PreviewProvider {
     42     static var previews: some View {
     43         SettingsView(storeManager: StoreManager())
     44     }
     45 }