전체 글
-
#20. 딥링크(DeepLink)SwiftUI 앱만들기 2022. 7. 12. 12:35
#1. App화일 수정 import SwiftUI @main struct _20_DeepLinkApp: App { @State var selectedTab = TabIdentifier.todos var body: some Scene { WindowGroup { TabView(selection: $selectedTab, content: { ToDosView().tabItem{ VStack{ Image(systemName: "list.bullet") Text("할일 목록") } }.tag(TabIdentifier.todos) ProfileView().tabItem{ Image(systemName: "person.circle.fill") Text("프로필") }.tag(TabIdentifier.profile)..
-
#19. 피커뷰(PickerView)SwiftUI 앱만들기 2022. 7. 11. 18:23
#1. ContentView import SwiftUI struct ContentView: View { @State private var selectionValue = 0 let myColorArray = ["Red","Green","Blue"] func changeColor(index: Int) -> Color { switch index{ case 0: return Color.red case 1: return Color.green case 2: return Color.blue default: return Color.red } } var body: some View { VStack(alignment: .center) { Circle() .foregroundColor(self.changeColor(inde..
-
#18. 토스트, 팝업(Toast, Popup)SwiftUI 앱만들기 2022. 7. 11. 17:22
#1.ContentView import SwiftUI import ExytePopupView struct ContentView: View { @State var shouldShowBottomSolidMessage: Bool = false @State var shouldShowBottomToastMessage: Bool = false @State var shouldShowTopSolidMessage: Bool = false @State var shouldShowTopToastMessage: Bool = false @State var shouldShowPopUpMessage: Bool = false //#1. Bottom Solid Message func createBottomSolidMessage() ->..