Skip to content

Commit d347069

Browse files
committed
Updated long form screen with Aviv design
1 parent 067d6f9 commit d347069

File tree

5 files changed

+17
-17
lines changed

5 files changed

+17
-17
lines changed

GoInfoGame/GoInfoGame/UI/Map/CreateNoteView.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ struct CreateNoteView: View {
5959
.foregroundColor(.white)
6060
.padding()
6161
.frame(maxWidth: .infinity)
62-
.background(Color.red)
62+
.background(Asset.Colors.accentPink.swiftUIColor)
6363
.cornerRadius(9)
6464
}
6565
}

GoInfoGame/GoInfoGame/UI/Utils/LoadingView.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ struct LongFormDismissButtonView: View {
6565
.resizable()
6666
.aspectRatio(contentMode: .fit)
6767
.frame(width: 25, height: 25)
68+
.foregroundStyle(Asset.Colors.accentPink.swiftUIColor)
6869
})
6970

7071
}

GoInfoGame/GoInfoGame/quests/LongQuests/Components/LongFormImageView.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ struct LongFormImageView: View {
1616
@State private var uiImage: UIImage?
1717

1818
var label: String? = nil
19-
var isSelected: Bool = false
2019

2120
var body: some View {
2221
Group {

GoInfoGame/GoInfoGame/quests/LongQuests/Components/QuestOptions.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -109,8 +109,7 @@ struct QuestOptions: View {
109109
urlString: imageUrl,
110110
width: 100,
111111
height: 100,
112-
label: option.choiceText,
113-
isSelected: currentAnswer == option.value
112+
label: option.choiceText
114113
)
115114
} else {
116115
ZStack {
@@ -155,7 +154,7 @@ struct QuestOptions: View {
155154
}
156155
.overlay(
157156
RoundedRectangle(cornerRadius: 8)
158-
.stroke(currentAnswer == option.value ? Color.blue : Color.clear, lineWidth: 3)
157+
.stroke(currentAnswer == option.value ? Asset.Colors.accentPink.swiftUIColor : Color.clear, lineWidth: 3)
159158
)
160159
.onLongPressGesture {
161160
if let imageUrl = option.imageURL, !imageUrl.isEmpty {
@@ -187,9 +186,10 @@ struct QuestOptions: View {
187186
.padding(.horizontal, 12)
188187
.padding(.vertical, 6)
189188
.background(
190-
LinearGradient(gradient: Gradient(colors: [Color.blue, Color.purple]), startPoint: .leading, endPoint: .trailing)
189+
LinearGradient(gradient: Gradient(colors: [Asset.Colors.huskyPurple.swiftUIColor, Asset.Colors.accentPink.swiftUIColor]), startPoint: .leading, endPoint: .trailing)
191190
)
192191
.shadow(color: Color.gray.opacity(0.5), radius: 4, x: 2, y: 2)
192+
.cornerRadius(9)
193193
}
194194
}
195195
}

GoInfoGame/GoInfoGame/quests/LongQuests/View/LongForm.swift

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -66,38 +66,38 @@ struct LongForm: View, QuestForm {
6666
HStack {
6767
Text(elementName ?? "")
6868
.font(.custom("Lato-Bold", size: 16))
69+
.foregroundStyle(Asset.Colors.huskyPurple.swiftUIColor)
6970
Spacer()
70-
Button("Hide this") {
71+
LongFormDismissButtonView {
7172
withAnimation {
72-
MapViewPublisher.shared.dismissSheet.send(.hideElement(questID ?? "0", elementName ?? ""))
7373
presentationMode.wrappedValue.dismiss()
7474
}
75-
7675
}
77-
}
78-
79-
.padding(EdgeInsets(top: 20, leading: 20, bottom: 10, trailing: 20))
76+
}.padding(EdgeInsets(top: 20, leading: 20, bottom: 10, trailing: 20))
8077

8178
Text("ID: \(questID ?? "0")")
8279
.font(.custom("Lato-Regular", size: 13))
8380
.padding([.leading], 20)
81+
.foregroundStyle(Asset.Colors.huskyPurple.swiftUIColor)
8482

8583
HStack {
8684
Button {
8785
showNotesBox = true
8886
} label: {
8987
Text(" Compose Note")
9088
.font(.custom("Lato-Bold", size: 15))
89+
.foregroundStyle(Asset.Colors.accentPink.swiftUIColor)
9190
}
9291
.padding(EdgeInsets(top: 0, leading: 14, bottom: 0, trailing: 20))
93-
94-
95-
LongFormDismissButtonView {
92+
Spacer()
93+
Button("Hide this") {
9694
withAnimation {
95+
MapViewPublisher.shared.dismissSheet.send(.hideElement(questID ?? "0", elementName ?? ""))
9796
presentationMode.wrappedValue.dismiss()
9897
}
9998
}
100-
.padding([.trailing], 20)
99+
.padding(.trailing, 20)
100+
.foregroundStyle(Asset.Colors.accentPink.swiftUIColor)
101101
}
102102

103103
if showCreateNoteMessage {
@@ -152,7 +152,7 @@ struct LongForm: View, QuestForm {
152152
.foregroundColor(.white)
153153
.padding()
154154
.frame(maxWidth: .infinity)
155-
.background(Color.red)
155+
.background(Asset.Colors.accentPink.swiftUIColor)
156156
.cornerRadius(9)
157157
}
158158
}

0 commit comments

Comments
 (0)