aboutsummaryrefslogtreecommitdiff
path: root/Hotline
diff options
context:
space:
mode:
Diffstat (limited to 'Hotline')
-rw-r--r--Hotline/Application.swift3
-rw-r--r--Hotline/HotlineState.swift24
-rw-r--r--Hotline/iOS/NewsView.swift1
3 files changed, 0 insertions, 28 deletions
diff --git a/Hotline/Application.swift b/Hotline/Application.swift
index 2b25ba5..14717c2 100644
--- a/Hotline/Application.swift
+++ b/Hotline/Application.swift
@@ -3,8 +3,6 @@ import SwiftData
@main
struct Application: App {
- @State private var appState = HotlineState()
-
#if os(iOS)
private var model = Hotline(trackerClient: HotlineTrackerClient(), client: HotlineClient())
#endif
@@ -13,7 +11,6 @@ struct Application: App {
#if os(iOS)
WindowGroup {
TrackerView()
- .environment(appState)
.environment(model)
}
#elseif os(macOS)
diff --git a/Hotline/HotlineState.swift b/Hotline/HotlineState.swift
deleted file mode 100644
index 9ae4940..0000000
--- a/Hotline/HotlineState.swift
+++ /dev/null
@@ -1,24 +0,0 @@
-import Foundation
-import SwiftUI
-
-@Observable
-class HotlineState {
- var agreementPresented = false
- var trackerPresented = true
-
- func presentTracker() {
- self.trackerPresented = true
- }
-
- func dismissTracker() {
- self.trackerPresented = false
- }
-
- func presentAgreement() {
- self.agreementPresented = true
- }
-
- func dismissAgreement() {
- self.agreementPresented = false
- }
-}
diff --git a/Hotline/iOS/NewsView.swift b/Hotline/iOS/NewsView.swift
index 92e8303..6d3ad45 100644
--- a/Hotline/iOS/NewsView.swift
+++ b/Hotline/iOS/NewsView.swift
@@ -247,6 +247,5 @@ struct NewsView: View {
#Preview {
MessageBoardView()
- .environment(HotlineState())
.environment(Hotline(trackerClient: HotlineTrackerClient(), client: HotlineClient()))
}