Jelajahi Sumber

refactoring

polscm32 2 tahun lalu
induk
melakukan
87c4fde5ca
1 mengubah file dengan 6 tambahan dan 2 penghapusan
  1. 6 2
      FreeAPS/Sources/Modules/Home/View/HomeRootView.swift

+ 6 - 2
FreeAPS/Sources/Modules/Home/View/HomeRootView.swift

@@ -807,8 +807,8 @@ extension Home {
                         .ignoresSafeArea(edges: .all)
                         .ignoresSafeArea(edges: .all)
                 }
                 }
         }
         }
-
-        var body: some View {
+        
+        @ViewBuilder func mainView() -> some View {
             GeometryReader { geo in
             GeometryReader { geo in
                 ZStack(alignment: .trailing) {
                 ZStack(alignment: .trailing) {
                     VStack(spacing: 0) {
                     VStack(spacing: 0) {
@@ -912,6 +912,10 @@ extension Home {
             }
             }
         }
         }
 
 
+        var body: some View {
+            mainView()
+        }
+
         private var popup: some View {
         private var popup: some View {
             VStack(alignment: .leading, spacing: 4) {
             VStack(alignment: .leading, spacing: 4) {
                 Text(state.statusTitle).font(.headline).foregroundColor(.white)
                 Text(state.statusTitle).font(.headline).foregroundColor(.white)