diff --git a/Projects/App/Resources/Assets.xcassets/ButtonX.imageset/ButtonX.svg b/Projects/App/Resources/Assets.xcassets/ButtonX.imageset/ButtonX.svg
new file mode 100644
index 0000000..1277fc0
--- /dev/null
+++ b/Projects/App/Resources/Assets.xcassets/ButtonX.imageset/ButtonX.svg
@@ -0,0 +1,5 @@
+
diff --git a/Projects/App/Resources/Assets.xcassets/testimage.imageset/Contents.json b/Projects/App/Resources/Assets.xcassets/ButtonX.imageset/Contents.json
similarity index 75%
rename from Projects/App/Resources/Assets.xcassets/testimage.imageset/Contents.json
rename to Projects/App/Resources/Assets.xcassets/ButtonX.imageset/Contents.json
index d1b96f4..92ba266 100644
--- a/Projects/App/Resources/Assets.xcassets/testimage.imageset/Contents.json
+++ b/Projects/App/Resources/Assets.xcassets/ButtonX.imageset/Contents.json
@@ -1,7 +1,7 @@
{
"images" : [
{
- "filename" : "스크린샷 2024-11-11 오후 4.14.24.png",
+ "filename" : "ButtonX.svg",
"idiom" : "universal",
"scale" : "1x"
},
diff --git a/Projects/App/Resources/Assets.xcassets/imageTest.imageset/Contents.json b/Projects/App/Resources/Assets.xcassets/imageTest.imageset/Contents.json
new file mode 100644
index 0000000..29a328f
--- /dev/null
+++ b/Projects/App/Resources/Assets.xcassets/imageTest.imageset/Contents.json
@@ -0,0 +1,21 @@
+{
+ "images" : [
+ {
+ "filename" : "imageTest.png",
+ "idiom" : "universal",
+ "scale" : "1x"
+ },
+ {
+ "idiom" : "universal",
+ "scale" : "2x"
+ },
+ {
+ "idiom" : "universal",
+ "scale" : "3x"
+ }
+ ],
+ "info" : {
+ "author" : "xcode",
+ "version" : 1
+ }
+}
diff --git a/Projects/App/Resources/Assets.xcassets/imageTest.imageset/imageTest.png b/Projects/App/Resources/Assets.xcassets/imageTest.imageset/imageTest.png
new file mode 100644
index 0000000..3e96cd0
Binary files /dev/null and b/Projects/App/Resources/Assets.xcassets/imageTest.imageset/imageTest.png differ
diff --git "a/Projects/App/Resources/Assets.xcassets/testimage.imageset/\354\212\244\355\201\254\353\246\260\354\203\267 2024-11-11 \354\230\244\355\233\204 4.14.24.png" "b/Projects/App/Resources/Assets.xcassets/testimage.imageset/\354\212\244\355\201\254\353\246\260\354\203\267 2024-11-11 \354\230\244\355\233\204 4.14.24.png"
deleted file mode 100644
index ac993ee..0000000
Binary files "a/Projects/App/Resources/Assets.xcassets/testimage.imageset/\354\212\244\355\201\254\353\246\260\354\203\267 2024-11-11 \354\230\244\355\233\204 4.14.24.png" and /dev/null differ
diff --git a/Projects/App/Sources/DesignSystem/Button/ExpoButton.swift b/Projects/App/Sources/DesignSystem/Button/ExpoButton.swift
index 5e63111..b848ab4 100644
--- a/Projects/App/Sources/DesignSystem/Button/ExpoButton.swift
+++ b/Projects/App/Sources/DesignSystem/Button/ExpoButton.swift
@@ -12,6 +12,8 @@ public struct ExpoButton: View {
var text: String
var horizontalPadding: CGFloat
var verticalPadding: CGFloat
+ var backColor: Color
+ var actionColor: Color
var action: () -> Void
@State private var isPressed = false
@@ -20,11 +22,15 @@ public struct ExpoButton: View {
text: String,
horizontalPadding: CGFloat = 16,
verticalPadding: CGFloat = 8,
+ backColor: Color,
+ actionColor: Color,
action: @escaping () -> Void = {}
) {
self.text = text
self.horizontalPadding = horizontalPadding
self.verticalPadding = verticalPadding
+ self.backColor = backColor
+ self.actionColor = actionColor
self.action = action
}
@@ -39,7 +45,7 @@ public struct ExpoButton: View {
.padding(.vertical, verticalPadding)
.background(
RoundedRectangle(cornerRadius: 6)
- .fill(isPressed ? ExpoColor.main300.swiftUIColor : ExpoColor.main.swiftUIColor)
+ .fill(isPressed ? actionColor : backColor)
)
.scaleEffect(isPressed ? 0.9 : 1.0)
}
diff --git a/Projects/App/Sources/Feature/PostDetailFeature/Sources/PostDetailView.swift b/Projects/App/Sources/Feature/PostDetailFeature/Sources/PostDetailView.swift
index 44b2f25..ad01bb3 100644
--- a/Projects/App/Sources/Feature/PostDetailFeature/Sources/PostDetailView.swift
+++ b/Projects/App/Sources/Feature/PostDetailFeature/Sources/PostDetailView.swift
@@ -14,6 +14,7 @@ struct PostDetailView: View {
@State private var postImageCount: Bool = false
@State private var dateLine: String = "09.10 ~09.20"
@State private var drawMap: Bool = true
+ @State private var showMessageSheet = false
@State private var location = Location(
locationX: 126.800771954215,
locationY: 35.1427689679488,
@@ -49,7 +50,7 @@ struct PostDetailView: View {
.resizable()
.tag(false)
- ExpoIOSAsset.Assets.testimage.swiftUIImage
+ ExpoIOSAsset.Assets.imageTest.swiftUIImage
.resizable()
.tag(true)
}
@@ -131,9 +132,9 @@ struct PostDetailView: View {
.frame(height: 178)
.cornerRadius(6)
.overlay(
- RoundedRectangle(cornerRadius: 6)
- .stroke(Color.gray, lineWidth: 0.3)
- )
+ RoundedRectangle(cornerRadius: 6)
+ .stroke(Color.gray, lineWidth: 0.3)
+ )
.padding(.horizontal, 16)
.padding(.top, 8)
@@ -141,13 +142,19 @@ struct PostDetailView: View {
ExpoButton(
text: "문자 보내기",
horizontalPadding: 50,
- verticalPadding: 14
- )
+ verticalPadding: 14,
+ backColor: ExpoColor.main.swiftUIColor,
+ actionColor: ExpoColor.main300.swiftUIColor
+ ) {
+ showMessageSheet.toggle()
+ }
Spacer()
ExpoButton(
text: "QR 생성하기",
horizontalPadding: 47,
- verticalPadding: 14
+ verticalPadding: 14,
+ backColor: ExpoColor.main.swiftUIColor,
+ actionColor: ExpoColor.main300.swiftUIColor
)
}
.padding(.horizontal, 16)
@@ -177,16 +184,74 @@ struct PostDetailView: View {
)
.padding(.top, 2)
-
-
Spacer()
}
}
.navigationBarBackButtonHidden(true)
+ .overlay(
+ Group {
+ if showMessageSheet {
+ popup(showMessageSheet: $showMessageSheet)
+ }
+ }
+ )
}
}
}
+@ViewBuilder
+func popup(showMessageSheet: Binding) -> some View {
+ Color.black.opacity(0.4)
+ .edgesIgnoringSafeArea(.all)
+ .overlay(
+ RoundedRectangle(cornerRadius: 6)
+ .frame(height: 150)
+ .foregroundColor(.white)
+ .overlay(
+ VStack {
+ HStack(spacing: 0) {
+ Text("누구에게 문자를 전송하시겠습니까?")
+ .expoFont(.body2B)
+ Spacer()
+
+ Button {
+ showMessageSheet.wrappedValue = false
+ } label: {
+ ExpoIOSAsset.Assets.buttonX.swiftUIImage
+ }
+ }
+ .padding(.horizontal, 12)
+
+ Spacer()
+
+ HStack(spacing: 20) {
+ ExpoButton(
+ text: "참가자",
+ horizontalPadding: 47,
+ verticalPadding: 14,
+ backColor: ExpoColor.main500.swiftUIColor,
+ actionColor: ExpoColor.main200.swiftUIColor
+ )
+
+ ExpoButton(
+ text: "연수자",
+ horizontalPadding: 47,
+ verticalPadding: 14,
+ backColor: ExpoColor.main300.swiftUIColor,
+ actionColor: ExpoColor.main100.swiftUIColor
+ )
+ }
+ .padding(.top, 16)
+ }
+ .padding(.vertical, 16)
+ )
+ .padding(.horizontal, 32)
+ )
+
+}
+
+
+
#Preview {
PostDetailView()
}
diff --git a/Projects/App/Sources/Feature/SigninFeature/Sources/SigninView.swift b/Projects/App/Sources/Feature/SigninFeature/Sources/SigninView.swift
index 4401338..5f8b836 100644
--- a/Projects/App/Sources/Feature/SigninFeature/Sources/SigninView.swift
+++ b/Projects/App/Sources/Feature/SigninFeature/Sources/SigninView.swift
@@ -84,7 +84,9 @@ struct SigninView: View {
ExpoButton(
text: "로그인",
horizontalPadding: 160,
- verticalPadding: 14
+ verticalPadding: 14,
+ backColor: ExpoColor.main.swiftUIColor,
+ actionColor: ExpoColor.main300.swiftUIColor
){
viewModel.setupEmail(email: emailTextField)
viewModel.setupPassword(password: passwordTextField)
diff --git a/Projects/App/Sources/Feature/SignupFeature/Sources/SignupView.swift b/Projects/App/Sources/Feature/SignupFeature/Sources/SignupView.swift
index cbd7fd9..f3da073 100644
--- a/Projects/App/Sources/Feature/SignupFeature/Sources/SignupView.swift
+++ b/Projects/App/Sources/Feature/SignupFeature/Sources/SignupView.swift
@@ -129,7 +129,9 @@ struct SignupView: View {
ExpoButton(
text: "확인",
horizontalPadding: 22,
- verticalPadding: 12
+ verticalPadding: 12,
+ backColor: ExpoColor.main.swiftUIColor,
+ actionColor: ExpoColor.main300.swiftUIColor
){
viewModel.setupCode(code: codeTextField)
viewModel.setupPhoneNumber(phoneNumber: userNumberTextField)
@@ -179,7 +181,9 @@ struct SignupView: View {
ExpoButton(
text: "회원가입 완료",
horizontalPadding: 142,
- verticalPadding: 14
+ verticalPadding: 14,
+ backColor: ExpoColor.main.swiftUIColor,
+ actionColor: ExpoColor.main300.swiftUIColor
){
viewModel.setupName(name: nameTextField)
viewModel.setupEmail(email: emailTextField)