Skip to content

Commit

Permalink
Fix linter warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
vishnuravi committed Jul 13, 2024
1 parent fec961e commit 8e81ce0
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 27 deletions.
12 changes: 6 additions & 6 deletions LifeSpace.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -804,9 +804,9 @@
CODE_SIGN_ENTITLEMENTS = "LifeSpace/Supporting Files/LifeSpace.entitlements";
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 10;
CURRENT_PROJECT_VERSION = 11;
DEVELOPMENT_ASSET_PATHS = "";
DEVELOPMENT_TEAM = "";
DEVELOPMENT_TEAM = B2Q3T3P8HP;
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = "LifeSpace/Supporting Files/Info.plist";
Expand Down Expand Up @@ -1008,9 +1008,9 @@
CODE_SIGN_ENTITLEMENTS = "LifeSpace/Supporting Files/LifeSpace.entitlements";
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 10;
CURRENT_PROJECT_VERSION = 11;
DEVELOPMENT_ASSET_PATHS = "";
DEVELOPMENT_TEAM = "";
DEVELOPMENT_TEAM = B2Q3T3P8HP;
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = "LifeSpace/Supporting Files/Info.plist";
Expand Down Expand Up @@ -1055,9 +1055,9 @@
CODE_SIGN_ENTITLEMENTS = "LifeSpace/Supporting Files/LifeSpace.entitlements";
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 10;
CURRENT_PROJECT_VERSION = 11;
DEVELOPMENT_ASSET_PATHS = "";
DEVELOPMENT_TEAM = "";
DEVELOPMENT_TEAM = B2Q3T3P8HP;
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = "LifeSpace/Supporting Files/Info.plist";
Expand Down
23 changes: 12 additions & 11 deletions LifeSpace/Map/OptionsPanel.swift
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,17 @@ import ResearchKitSwiftUI
import Spezi
import SwiftUI


struct ButtonGroupBoxStyle: GroupBoxStyle {
func makeBody(configuration: Self.Configuration) -> some View {
configuration.content
.frame(maxWidth: .infinity)
.padding()
.background(RoundedRectangle(cornerRadius: 8).fill(Color("AccentColor")))
}
}


struct OptionsPanel: View {
@AppStorage(StorageKeys.trackingPreference) private var trackingOn = true
@Environment(LocationModule.self) private var locationModule
Expand Down Expand Up @@ -75,12 +86,11 @@ struct OptionsPanel: View {
})
.padding()
.buttonStyle(.bordered)

}
}

private func launchSurvey() {
if SurveyModule.currentHour > 7 && !SurveyModule.surveyAlreadyTaken {
if SurveyModule.shouldShowSurvey && !SurveyModule.surveyAlreadyTaken {
self.showingStartSurveyModal = true
}
}
Expand All @@ -89,12 +99,3 @@ struct OptionsPanel: View {
#Preview {
OptionsPanel()
}

struct ButtonGroupBoxStyle: GroupBoxStyle {
func makeBody(configuration: Self.Configuration) -> some View {
configuration.content
.frame(maxWidth: .infinity)
.padding()
.background(RoundedRectangle(cornerRadius: 8).fill(Color("AccentColor")))
}
}
20 changes: 10 additions & 10 deletions LifeSpace/Survey/DailySurveyTaskView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -64,51 +64,51 @@ struct DailySurveyTaskView: View {
private var surveyTakenView: some View {
VStack {
Spacer()

Image(systemName: "exclamationmark.triangle.fill")
.resizable()
.frame(width: 50, height: 50)
.accessibilityLabel("SURVEY_TAKEN_NOTICE")

Text("SURVEY_TAKEN_NOTICE")
.font(.largeTitle)
.padding()
.multilineTextAlignment(.center)

Button(action: {
self.showingSurvey = false
}, label: {
Text("OK")
.padding()
})
.buttonStyle(.borderedProminent)

Spacer()
}
}

private var previousDaySurveyView: some View {
VStack {
Spacer ()
Spacer()

Image(systemName: "exclamationmark.triangle.fill")
.resizable()
.frame(width: 50, height: 50)
.accessibilityLabel("PREVIOUS_DAY_SURVEY_LABEL")

Text("PREVIOUS_DAY_SURVEY_NOTICE")
.font(.largeTitle)
.padding()
.multilineTextAlignment(.center)

Button(action: {
self.acknowledgedPreviousDaySurvey = true
}, label: {
Text("CONTINUE")
.padding()
})
.buttonStyle(.borderedProminent)

Spacer()
}
}
Expand All @@ -126,7 +126,7 @@ struct DailySurveyTaskView: View {
.font(.largeTitle)
.padding()
.multilineTextAlignment(.center)

Spacer()

Button(action: {
Expand Down

0 comments on commit 8e81ce0

Please sign in to comment.