From c0068f11c51bb587c16dfacb73629b3c6fb67fc8 Mon Sep 17 00:00:00 2001 From: Dustin Mierau Date: Wed, 6 Dec 2023 13:52:20 -0800 Subject: Further work on UI organization --- Hotline/HotlineState.swift | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 Hotline/HotlineState.swift (limited to 'Hotline/HotlineState.swift') diff --git a/Hotline/HotlineState.swift b/Hotline/HotlineState.swift new file mode 100644 index 0000000..9ae4940 --- /dev/null +++ b/Hotline/HotlineState.swift @@ -0,0 +1,24 @@ +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 + } +} -- cgit