룰렛 프리셋 적용
This commit is contained in:
34
SodaLive/Sources/UI/Component/SelectedButtonView.swift
Normal file
34
SodaLive/Sources/UI/Component/SelectedButtonView.swift
Normal file
@@ -0,0 +1,34 @@
|
||||
//
|
||||
// SelectedButtonView.swift
|
||||
// SodaLive
|
||||
//
|
||||
// Created by klaus on 2/23/24.
|
||||
//
|
||||
|
||||
import SwiftUI
|
||||
|
||||
struct SelectedButtonView: View {
|
||||
|
||||
let title: String
|
||||
let isSelected: Bool
|
||||
|
||||
var body: some View {
|
||||
HStack(spacing: 6.7) {
|
||||
if isSelected {
|
||||
Image("ic_select_check")
|
||||
}
|
||||
|
||||
Text(title)
|
||||
.font(.custom(Font.bold.rawValue, size: 14.7))
|
||||
.foregroundColor(isSelected ? .white : Color.button)
|
||||
}
|
||||
.padding(.vertical, 14.3)
|
||||
.frame(maxWidth: .infinity)
|
||||
.background(isSelected ? Color.button : Color.bg)
|
||||
.cornerRadius(6.7)
|
||||
}
|
||||
}
|
||||
|
||||
#Preview {
|
||||
SelectedButtonView(title: "테스트", isSelected: true)
|
||||
}
|
Reference in New Issue
Block a user