From 3cf3f92150e93da3c40a33a36975d9839c51fc5f Mon Sep 17 00:00:00 2001 From: SrikanthV Date: Wed, 26 Aug 2026 18:03:12 +0530 Subject: [PATCH 1/2] Implemented presenting full screen longfrom quest. --- .../AccessibilityModeView.swift | 2 +- GoInfoGame/GoInfoGame/UI/Map/MapView.swift | 48 ++++--------------- .../quests/LongQuests/View/LongForm.swift | 9 ++++ 3 files changed, 18 insertions(+), 41 deletions(-) diff --git a/GoInfoGame/GoInfoGame/UI/Map/Accessibility Mode/AccessibilityModeView.swift b/GoInfoGame/GoInfoGame/UI/Map/Accessibility Mode/AccessibilityModeView.swift index 25859136..d038cb44 100644 --- a/GoInfoGame/GoInfoGame/UI/Map/Accessibility Mode/AccessibilityModeView.swift +++ b/GoInfoGame/GoInfoGame/UI/Map/Accessibility Mode/AccessibilityModeView.swift @@ -123,7 +123,7 @@ struct AccessibilityModeView: View { } .sheet(isPresented: $showLongFrom) { QuestSheetView(viewModel: mapViewModel, annotationCoordinate: viewModel.selectedQuest?.coordinateInfo) - .presentationDetents([.fraction(0.8), .fraction(0.5), .fraction(0.1)], selection: $selectedDetent) + .presentationDetents([.fraction(0.1), .fraction(0.5), .fraction(0.8), .large], selection: $selectedDetent) .presentationDragIndicator(.visible) .scrollDisabled(false) .interactiveDismissDisabled() diff --git a/GoInfoGame/GoInfoGame/UI/Map/MapView.swift b/GoInfoGame/GoInfoGame/UI/Map/MapView.swift index f78eea5d..c3c8b6a3 100644 --- a/GoInfoGame/GoInfoGame/UI/Map/MapView.swift +++ b/GoInfoGame/GoInfoGame/UI/Map/MapView.swift @@ -620,7 +620,7 @@ struct MapView: View { .sheet(isPresented: $isPresented) { QuestSheetView(viewModel: viewModel, annotationCoordinate: annotationCoordinate) .onAppear { shouldShowPolyline = true } - .presentationDetents([.fraction(0.7), .fraction(0.5), .fraction(0.1)], + .presentationDetents([.fraction(0.1), .fraction(0.5), .fraction(0.7), .large], selection: $selectedDetent) .presentationDragIndicator(.visible) .scrollDisabled(false) @@ -1009,7 +1009,13 @@ struct QuestSheetView: View { } .padding(24) } else if let selectedQuest = viewModel.getSelectedQuest() { - CustomSheetView { selectedQuest.parent?.form } + // Rendered directly (not through the old CustomSheetView/CustomSheetWrapper + // UIViewControllerRepresentable) so the sheet's native drag-vs-scroll + // gesture coordination can see LongForm's List directly and let it scroll + // before resizing the sheet — that extra UIKit hosting boundary was + // breaking that coordination, so any drag on the list moved the whole + // sheet instead of scrolling its content. + selectedQuest.parent?.form } else { EmptyView() } @@ -1211,44 +1217,6 @@ class ContextualInfo: ObservableObject { private init() {} } -struct CustomSheetView: View { - let content: () -> Content - init(@ViewBuilder content: @escaping () -> Content) { self.content = content } - var body: some View { - CustomSheetWrapper(content: content).ignoresSafeArea() - } -} - -struct CustomSheetWrapper: UIViewControllerRepresentable { - let content: () -> Content - init(@ViewBuilder content: @escaping () -> Content) { self.content = content } - - func makeUIViewController(context: Context) -> UIViewController { - let vc = UIViewController() - let hc = UIHostingController(rootView: content()) - hc.view.translatesAutoresizingMaskIntoConstraints = false - vc.view.addSubview(hc.view) - NSLayoutConstraint.activate([ - hc.view.topAnchor.constraint(equalTo: vc.view.topAnchor), - hc.view.bottomAnchor.constraint(equalTo: vc.view.bottomAnchor), - hc.view.leadingAnchor.constraint(equalTo: vc.view.leadingAnchor), - hc.view.trailingAnchor.constraint(equalTo: vc.view.trailingAnchor) - ]) - vc.view.backgroundColor = .clear - return vc - } - - func updateUIViewController(_ uiViewController: UIViewController, context: Context) {} - - static func dismantleUIViewController(_ uiViewController: UIViewController, coordinator: ()) { - if let sheet = uiViewController.sheetPresentationController { - sheet.detents = [.medium(), .large()] - sheet.prefersGrabberVisible = true - sheet.prefersScrollingExpandsWhenScrolledToEdge = false - } - } -} - struct MultiQuestSelectionBottomSheet: View { var selectedAnnotationType: String var selectedAnnotationImage: UIImage diff --git a/GoInfoGame/GoInfoGame/quests/LongQuests/View/LongForm.swift b/GoInfoGame/GoInfoGame/quests/LongQuests/View/LongForm.swift index f4010e2b..ed7039a3 100644 --- a/GoInfoGame/GoInfoGame/quests/LongQuests/View/LongForm.swift +++ b/GoInfoGame/GoInfoGame/quests/LongQuests/View/LongForm.swift @@ -176,6 +176,9 @@ struct LongForm: View, QuestForm { Text("No Quests available") } } + .listRowInsets(EdgeInsets(top: 4, leading: 20, bottom: 4, trailing: 20)) + .listRowBackground(Color.clear) + .listRowSeparator(.hidden) Section { submitButton @@ -184,6 +187,7 @@ struct LongForm: View, QuestForm { .listRowBackground(Color.clear) .listRowSeparator(.hidden) } + .scrollContentBackground(.hidden) .padding(.bottom, keyboardHeight) .onReceive(Publishers.keyboardHeight) { height in let safeAreaBottom = UIApplication.shared.safeAreaBottomInset @@ -251,6 +255,11 @@ struct LongForm: View, QuestForm { } } } + // Matches the background used everywhere else in the app (ManageQuestsView, + // UserSettingsView, AccessibilityModeView, etc.) instead of the system's default + // sheet background, so it looks consistent whether this sheet is a small preview + // or expanded to full screen. + .background(Color(red: 248 / 255, green: 248 / 255, blue: 248 / 255)) .alert(item: $activeAlert) { alertType in switch alertType { case .hideQuestConfirmation: From 81e9112c010ad27c5bd5b360180b0927c8d473ef Mon Sep 17 00:00:00 2001 From: SrikanthV Date: Wed, 26 Aug 2026 18:06:30 +0530 Subject: [PATCH 2/2] Updated version no to 1.2.10 --- GoInfoGame/GoInfoGame.xcodeproj/project.pbxproj | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/GoInfoGame/GoInfoGame.xcodeproj/project.pbxproj b/GoInfoGame/GoInfoGame.xcodeproj/project.pbxproj index 6b39758d..acf35d63 100644 --- a/GoInfoGame/GoInfoGame.xcodeproj/project.pbxproj +++ b/GoInfoGame/GoInfoGame.xcodeproj/project.pbxproj @@ -24,6 +24,7 @@ 171574E02FD1CC4A00AA6603 /* PhotoLookupResponse.swift in Sources */ = {isa = PBXBuildFile; fileRef = 171574DF2FD1CC4A00AA6603 /* PhotoLookupResponse.swift */; }; 188843AD2B5FA2DF0008DCF8 /* TactilePavingStepsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 188843AC2B5FA2DF0008DCF8 /* TactilePavingStepsTests.swift */; }; 188843AF2B5FB32D0008DCF8 /* WayLitTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 188843AE2B5FB32D0008DCF8 /* WayLitTests.swift */; }; + 2E71655C971839F8DAF42E67 /* CompassButtonView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 61CD36AA62170BAF936749E0 /* CompassButtonView.swift */; }; 342561966FC217124BD9CFE7 /* Pods_GoInfoGame_GoInfoGameUITests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2D539E22EFF6636F8CBA035A /* Pods_GoInfoGame_GoInfoGameUITests.framework */; }; 46B6E640D2414B20BBA4CBF0 /* FeatureSubmissionManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = C38242EA353F419D881E164C /* FeatureSubmissionManager.swift */; }; 4A89C70038014808B0E110A0 /* FeatureImageStorage.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8AF3DE0241AC4BAB9C051601 /* FeatureImageStorage.swift */; }; @@ -183,7 +184,6 @@ C77AAC9F2E4463ED006713B2 /* FirebaseCrashlytics in Frameworks */ = {isa = PBXBuildFile; productRef = C77AAC9E2E4463ED006713B2 /* FirebaseCrashlytics */; }; C77D48AA3036C434009E61F7 /* ZoomControlView.swift in Sources */ = {isa = PBXBuildFile; fileRef = C77D48A93036C434009E61F7 /* ZoomControlView.swift */; }; C77D48AC3036DF84009E61F7 /* ScaleBarView.swift in Sources */ = {isa = PBXBuildFile; fileRef = C77D48AB3036DF84009E61F7 /* ScaleBarView.swift */; }; - 2E71655C971839F8DAF42E67 /* CompassButtonView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 61CD36AA62170BAF936749E0 /* CompassButtonView.swift */; }; C77EEBCF2DE59D3200494CB4 /* UndoMerge.swift in Sources */ = {isa = PBXBuildFile; fileRef = C77EEBCE2DE59D3200494CB4 /* UndoMerge.swift */; }; C785DBD43010978800E5EA58 /* MapLibre in Frameworks */ = {isa = PBXBuildFile; productRef = C785DBD33010978800E5EA58 /* MapLibre */; }; C78737AF2E4C9E3B00289D13 /* FloatingLabelTextField.swift in Sources */ = {isa = PBXBuildFile; fileRef = C78737AE2E4C9E3200289D13 /* FloatingLabelTextField.swift */; }; @@ -390,6 +390,7 @@ 2D539E22EFF6636F8CBA035A /* Pods_GoInfoGame_GoInfoGameUITests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_GoInfoGame_GoInfoGameUITests.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 30877432D1026706D7E805DA /* map_theme */ = {isa = PBXFileReference; lastKnownFileType = folder; path = map_theme; sourceTree = ""; }; 3D797A45474D6135AFA24613 /* Pods-GoInfoGameTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-GoInfoGameTests.debug.xcconfig"; path = "Target Support Files/Pods-GoInfoGameTests/Pods-GoInfoGameTests.debug.xcconfig"; sourceTree = ""; }; + 61CD36AA62170BAF936749E0 /* CompassButtonView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CompassButtonView.swift; sourceTree = ""; }; 66BED441AF03CC04539E8D4A /* Pods_GoInfoGame.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_GoInfoGame.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 79F024C6DD9B31E354C41ED3 /* Pods-osmapi.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-osmapi.debug.xcconfig"; path = "Target Support Files/Pods-osmapi/Pods-osmapi.debug.xcconfig"; sourceTree = ""; }; 86C5ED636FC6D3C98650F231 /* NoteImageStorage.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NoteImageStorage.swift; sourceTree = ""; }; @@ -578,7 +579,6 @@ C77AACA52E447364006713B2 /* GoogleService-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "GoogleService-Info.plist"; sourceTree = ""; }; C77D48A93036C434009E61F7 /* ZoomControlView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ZoomControlView.swift; sourceTree = ""; }; C77D48AB3036DF84009E61F7 /* ScaleBarView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ScaleBarView.swift; sourceTree = ""; }; - 61CD36AA62170BAF936749E0 /* CompassButtonView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CompassButtonView.swift; sourceTree = ""; }; C77EEBCE2DE59D3200494CB4 /* UndoMerge.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UndoMerge.swift; sourceTree = ""; }; C78737AE2E4C9E3200289D13 /* FloatingLabelTextField.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FloatingLabelTextField.swift; sourceTree = ""; }; C787EF162E9676CC00BEF0A6 /* GoInfoGame.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = GoInfoGame.entitlements; sourceTree = ""; }; @@ -3106,7 +3106,7 @@ "$(inherited)", "@executable_path/Frameworks", ); - MARKETING_VERSION = 1.2.9; + MARKETING_VERSION = 1.2.10; MTL_HEADER_SEARCH_PATHS = "$(SRCROOT)/PointNMap $(SRCROOT)/PointNMapShaderTypes"; OTHER_CFLAGS = "-DACCELERATE_NEW_LAPACK"; OTHER_LDFLAGS = ( @@ -3182,7 +3182,7 @@ "$(inherited)", "@executable_path/Frameworks", ); - MARKETING_VERSION = 1.2.9; + MARKETING_VERSION = 1.2.10; MTL_HEADER_SEARCH_PATHS = "$(SRCROOT)/PointNMap $(SRCROOT)/PointNMapShaderTypes"; OTHER_CFLAGS = "-DACCELERATE_NEW_LAPACK"; OTHER_LDFLAGS = (