diff --git a/SodaLive/Resources/Localizable.xcstrings b/SodaLive/Resources/Localizable.xcstrings index ddb053b..083d7fc 100644 --- a/SodaLive/Resources/Localizable.xcstrings +++ b/SodaLive/Resources/Localizable.xcstrings @@ -4049,6 +4049,22 @@ } } }, + "목" : { + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Thu" + } + }, + "ja" : { + "stringUnit" : { + "state" : "translated", + "value" : "木" + } + } + } + }, "모든 기기에서 로그아웃" : { "localizations" : { "en" : { @@ -4097,22 +4113,6 @@ } } }, - "목" : { - "localizations" : { - "en" : { - "stringUnit" : { - "state" : "translated", - "value" : "Thu" - } - }, - "ja" : { - "stringUnit" : { - "state" : "translated", - "value" : "木" - } - } - } - }, "무료" : { "localizations" : { "en" : { @@ -8513,22 +8513,6 @@ } } }, - "캔" : { - "localizations" : { - "en" : { - "stringUnit" : { - "state" : "translated", - "value" : "Cans" - } - }, - "ja" : { - "stringUnit" : { - "state" : "translated", - "value" : "キャン" - } - } - } - }, "캐릭터 정보" : { "localizations" : { "en" : { @@ -8545,6 +8529,22 @@ } } }, + "캔" : { + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Cans" + } + }, + "ja" : { + "stringUnit" : { + "state" : "translated", + "value" : "キャン" + } + } + } + }, "캔 충전" : { "localizations" : { "en" : { @@ -8625,6 +8625,22 @@ } } }, + "콘텐츠 등록" : { + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Register content" + } + }, + "ja" : { + "stringUnit" : { + "state" : "translated", + "value" : "コンテンツ登録" + } + } + } + }, "콘텐츠 마켓" : { "localizations" : { "en" : { diff --git a/SodaLive/Sources/Content/Create/ContentCreateView.swift b/SodaLive/Sources/Content/Create/ContentCreateView.swift index f007fc6..ee3b4b5 100644 --- a/SodaLive/Sources/Content/Create/ContentCreateView.swift +++ b/SodaLive/Sources/Content/Create/ContentCreateView.swift @@ -24,7 +24,7 @@ struct ContentCreateView: View { GeometryReader { proxy in ZStack { VStack(spacing: 0) { - DetailNavigationBar(title: "콘텐츠 등록") + DetailNavigationBar(title: String(localized: "콘텐츠 등록")) ScrollView(.vertical, showsIndicators: false) { VStack(spacing: 0) { @@ -67,7 +67,7 @@ struct ContentCreateView: View { .frame(maxWidth: .infinity, alignment: .leading) .padding(.top, 13.3) - Text(viewModel.fileName.trimmingCharacters(in: .whitespacesAndNewlines) == "" ? "파일선택" : viewModel.fileName) + Text(viewModel.fileName.trimmingCharacters(in: .whitespacesAndNewlines) == "" ? I18n.CreateContent.selectFile : viewModel.fileName) .font(.custom(Font.medium.rawValue, size: 16.7)) .foregroundColor(Color.button) .padding(.vertical, 10) @@ -126,7 +126,7 @@ struct ContentCreateView: View { TextViewWrapper( text: $viewModel.detail, - placeholder: viewModel.placeholder, + placeholder: I18n.CreateContent.uploadContentDescriptionHint, textColorHex: "eeeeee", backgroundColorHex: "222222" ) @@ -157,7 +157,7 @@ struct ContentCreateView: View { Text(viewModel.theme != nil ? viewModel.theme!.theme : - "테마 선택") + I18n.CreateContent.selectTheme) .font(.custom(Font.bold.rawValue, size: 16.7)) .foregroundColor(Color.button) } @@ -209,13 +209,13 @@ struct ContentCreateView: View { .frame(maxWidth: .infinity, alignment: .leading) HStack(spacing: 13.3) { - SelectButtonView(title: "무료", isChecked: viewModel.isFree) { + SelectButtonView(title: I18n.CreateContent.free, isChecked: viewModel.isFree) { if !viewModel.isFree { viewModel.isFree = true } } - - SelectButtonView(title: "유료", isChecked: !viewModel.isFree) { + + SelectButtonView(title: I18n.CreateContent.paid, isChecked: !viewModel.isFree) { if viewModel.isFree { viewModel.isFree = false } @@ -230,19 +230,19 @@ struct ContentCreateView: View { .frame(maxWidth: .infinity, alignment: .leading) HStack(spacing: 6.7) { - SelectButtonView(title: "소장/대여", isChecked: viewModel.purchaseOption == .BOTH) { + SelectButtonView(title: I18n.CreateContent.purchaseBoth, isChecked: viewModel.purchaseOption == .BOTH) { if viewModel.purchaseOption != .BOTH { viewModel.purchaseOption = .BOTH } } - SelectButtonView(title: "소장만", isChecked: viewModel.purchaseOption == .BUY_ONLY) { + SelectButtonView(title: I18n.CreateContent.purchaseBuyOnly, isChecked: viewModel.purchaseOption == .BUY_ONLY) { if viewModel.purchaseOption != .BUY_ONLY { viewModel.purchaseOption = .BUY_ONLY } } - SelectButtonView(title: "대여만", isChecked: viewModel.purchaseOption == .RENT_ONLY) { + SelectButtonView(title: I18n.CreateContent.purchaseRentOnly, isChecked: viewModel.purchaseOption == .RENT_ONLY) { if viewModel.purchaseOption != .RENT_ONLY { viewModel.purchaseOption = .RENT_ONLY } @@ -310,13 +310,13 @@ struct ContentCreateView: View { .frame(maxWidth: .infinity, alignment: .leading) HStack(spacing: 13.3) { - SelectButtonView(title: "무제한", isChecked: !viewModel.isLimited) { + SelectButtonView(title: I18n.CreateContent.unlimited, isChecked: !viewModel.isLimited) { if viewModel.isLimited { viewModel.isLimited = false } } - SelectButtonView(title: "한정판", isChecked: viewModel.isLimited) { + SelectButtonView(title: I18n.CreateContent.limitedEdition, isChecked: viewModel.isLimited) { if !viewModel.isLimited { viewModel.isLimited = true } @@ -347,13 +347,13 @@ struct ContentCreateView: View { .frame(maxWidth: .infinity, alignment: .leading) HStack(spacing: 13.3) { - SelectButtonView(title: "가능", isChecked: viewModel.isPointAvailable) { + SelectButtonView(title: I18n.CreateContent.available, isChecked: viewModel.isPointAvailable) { if !viewModel.isPointAvailable { viewModel.isPointAvailable = true } } - SelectButtonView(title: "불가능", isChecked: !viewModel.isPointAvailable) { + SelectButtonView(title: I18n.CreateContent.unavailable, isChecked: !viewModel.isPointAvailable) { if viewModel.isPointAvailable { viewModel.isPointAvailable = false } @@ -369,13 +369,13 @@ struct ContentCreateView: View { .frame(maxWidth: .infinity, alignment: .leading) HStack(spacing: 13.3) { - SelectButtonView(title: "생성", isChecked: viewModel.isGeneratePreview) { + SelectButtonView(title: I18n.CreateContent.generate, isChecked: viewModel.isGeneratePreview) { if !viewModel.isGeneratePreview { viewModel.isGeneratePreview = true } } - SelectButtonView(title: "생성 안 함", isChecked: !viewModel.isGeneratePreview) { + SelectButtonView(title: I18n.CreateContent.doNotGenerate, isChecked: !viewModel.isGeneratePreview) { if viewModel.isGeneratePreview { viewModel.isGeneratePreview = false } @@ -451,13 +451,13 @@ struct ContentCreateView: View { .frame(maxWidth: .infinity, alignment: .leading) HStack(spacing: 13.3) { - SelectButtonView(title: "전체 연령", isChecked: !viewModel.isAdult) { + SelectButtonView(title: I18n.CreateContent.allAges, isChecked: !viewModel.isAdult) { if viewModel.isAdult { viewModel.isAdult = false } } - - SelectButtonView(title: "19세 이상", isChecked: viewModel.isAdult) { + + SelectButtonView(title: I18n.CreateContent.over19, isChecked: viewModel.isAdult) { if !viewModel.isAdult { viewModel.isAdult = true } @@ -480,13 +480,13 @@ struct ContentCreateView: View { .frame(maxWidth: .infinity, alignment: .leading) HStack(spacing: 13.3) { - SelectButtonView(title: "댓글 가능", isChecked: viewModel.isAvailableComment) { + SelectButtonView(title: I18n.CreateContent.commentAllowed, isChecked: viewModel.isAvailableComment) { if !viewModel.isAvailableComment { viewModel.isAvailableComment = true } } - - SelectButtonView(title: "댓글 불가", isChecked: !viewModel.isAvailableComment) { + + SelectButtonView(title: I18n.CreateContent.commentNotAllowed, isChecked: !viewModel.isAvailableComment) { if viewModel.isAvailableComment { viewModel.isAvailableComment = false } @@ -497,19 +497,19 @@ struct ContentCreateView: View { .padding(.horizontal, 13.3) VStack(spacing: 13.3) { - Text("예약 공개") + Text(I18n.CreateContent.publishReserved) .font(.custom(Font.bold.rawValue, size: 16.7)) .foregroundColor(Color.grayee) .frame(maxWidth: .infinity, alignment: .leading) - + HStack(spacing: 13.3) { - SelectButtonView(title: "지금 공개", isChecked: !viewModel.isActiveReservation) { + SelectButtonView(title: I18n.CreateContent.publishNow, isChecked: !viewModel.isActiveReservation) { if viewModel.isActiveReservation { viewModel.isActiveReservation = false } } - - SelectButtonView(title: "예약 공개", isChecked: viewModel.isActiveReservation) { + + SelectButtonView(title: I18n.CreateContent.publishReserved, isChecked: viewModel.isActiveReservation) { if !viewModel.isActiveReservation { viewModel.isActiveReservation = true } diff --git a/SodaLive/Sources/Content/Create/ContentCreateViewModel.swift b/SodaLive/Sources/Content/Create/ContentCreateViewModel.swift index cf200d5..2d26cd2 100644 --- a/SodaLive/Sources/Content/Create/ContentCreateViewModel.swift +++ b/SodaLive/Sources/Content/Create/ContentCreateViewModel.swift @@ -116,8 +116,6 @@ final class ContentCreateViewModel: ObservableObject { } } - var placeholder = "내용을 입력하세요" - func uploadAudioContent() { if !isLoading && validateData() { isLoading = true diff --git a/SodaLive/Sources/I18n/I18n.swift b/SodaLive/Sources/I18n/I18n.swift index bf4e4bd..6c5160b 100644 --- a/SodaLive/Sources/I18n/I18n.swift +++ b/SodaLive/Sources/I18n/I18n.swift @@ -23,6 +23,51 @@ enum I18n { static var settings: String { pick(ko: "설정", en: "Settings", ja: "設定") } static var commonError: String { pick(ko: "다시 시도해 주세요.\n계속 같은 문제가 발생할 경우 고객센터로 문의 주시기 바랍니다.", en: "Settings", ja: "設定") } + + static var roulette1: String { pick(ko: "룰렛 1", en: "Roulette 1", ja: "ルーレット1") } + static var roulette2: String { pick(ko: "룰렛 2", en: "Roulette 2", ja: "ルーレット2") } + static var roulette3: String { pick(ko: "룰렛 3", en: "Roulette 3", ja: "ルーレット3") } + } + + enum MissionMenu { + static var menu1: String { pick(ko: "메뉴 1", en: "Menu 1", ja: "メニュー1") } + static var menu2: String { pick(ko: "메뉴 2", en: "Menu 2", ja: "メニュー2") } + static var menu3: String { pick(ko: "메뉴 3", en: "Menu 3", ja: "メニュー3") } + } + + enum CreateContent { + static var selectFile: String { pick(ko: "파일 선택", en: "Select file", ja: "ファイル選択") } + static var selectTheme: String { pick(ko: "테마 선택", en: "Select theme", ja: "テーマを選択") } + static var uploadContentDescriptionHint: String { pick(ko: "내용을 입력하세요", en: "Enter a description", ja: "内容を入力してください") } + + // 가격/구매 옵션 + static var free: String { pick(ko: "무료", en: "Free", ja: "無料") } + static var paid: String { pick(ko: "유료", en: "Paid", ja: "有料") } + static var purchaseBoth: String { pick(ko: "소장/대여", en: "Buy/Rent", ja: "購入/レンタル") } + static var purchaseBuyOnly: String { pick(ko: "소장만", en: "Buy only", ja: "購入のみ") } + static var purchaseRentOnly: String { pick(ko: "대여만", en: "Rent only", ja: "レンタルのみ") } + static var unlimited: String { pick(ko: "무제한", en: "Unlimited", ja: "無制限") } + static var limitedEdition: String { pick(ko: "한정판", en: "Limited", ja: "限定版") } + + // 포인트 사용 + static var available: String { pick(ko: "가능", en: "Available", ja: "可能") } + static var unavailable: String { pick(ko: "불가능", en: "Unavailable", ja: "不可") } + + // 미리듣기 + static var generate: String { pick(ko: "생성", en: "Generate", ja: "生成") } + static var doNotGenerate: String { pick(ko: "생성 안 함", en: "Do not generate", ja: "生成しない") } + + // 연령 제한 + static var allAges: String { pick(ko: "전체 연령", en: "All ages", ja: "全年齢") } + static var over19: String { pick(ko: "19세 이상", en: "19+", ja: "19歳以上") } + + // 댓글 가능 여부 + static var commentAllowed: String { pick(ko: "댓글 가능", en: "Comments allowed", ja: "コメント可") } + static var commentNotAllowed: String { pick(ko: "댓글 불가", en: "Comments not allowed", ja: "コメント不可") } + + // 공개 설정 + static var publishNow: String { pick(ko: "지금 공개", en: "Publish now", ja: "今すぐ公開") } + static var publishReserved: String { pick(ko: "예약 공개", en: "Scheduled", ja: "予約公開") } } enum Category { diff --git a/SodaLive/Sources/Live/Room/Menu/LiveRoomMenuSelectView.swift b/SodaLive/Sources/Live/Room/Menu/LiveRoomMenuSelectView.swift index bcb76f8..5061db9 100644 --- a/SodaLive/Sources/Live/Room/Menu/LiveRoomMenuSelectView.swift +++ b/SodaLive/Sources/Live/Room/Menu/LiveRoomMenuSelectView.swift @@ -43,7 +43,7 @@ struct LiveRoomMenuSelectView: View { VStack(spacing: 13.3) { HStack(spacing: 13.3) { SelectedButtonView( - title: "메뉴 1", + title: I18n.MissionMenu.menu1, isActive: true, isSelected: selectedMenu == .MENU_1 ) @@ -52,7 +52,7 @@ struct LiveRoomMenuSelectView: View { } SelectedButtonView( - title: "메뉴 2", + title: I18n.MissionMenu.menu2, isActive: menuCount > 0, isSelected: selectedMenu == .MENU_2 ) @@ -61,7 +61,7 @@ struct LiveRoomMenuSelectView: View { } SelectedButtonView( - title: "메뉴 3", + title: I18n.MissionMenu.menu3, isActive: menuCount > 1, isSelected: selectedMenu == .MENU_3 ) diff --git a/SodaLive/Sources/Live/Room/Menu/MenuSettingsView.swift b/SodaLive/Sources/Live/Room/Menu/MenuSettingsView.swift index 34bc04e..1afe132 100644 --- a/SodaLive/Sources/Live/Room/Menu/MenuSettingsView.swift +++ b/SodaLive/Sources/Live/Room/Menu/MenuSettingsView.swift @@ -22,7 +22,7 @@ struct MenuSettingsView: View { HStack(spacing: 13.3) { SelectedButtonView( - title: "메뉴 1", + title: I18n.MissionMenu.menu1, isActive: true, isSelected: viewModel.selectedMenu == .MENU_1 ) @@ -31,7 +31,7 @@ struct MenuSettingsView: View { } SelectedButtonView( - title: "메뉴 2", + title: I18n.MissionMenu.menu2, isActive: viewModel.menuList.count > 0, isSelected: viewModel.selectedMenu == .MENU_2 ) @@ -40,7 +40,7 @@ struct MenuSettingsView: View { } SelectedButtonView( - title: "메뉴 3", + title: I18n.MissionMenu.menu3, isActive: viewModel.menuList.count > 1, isSelected: viewModel.selectedMenu == .MENU_3 ) diff --git a/SodaLive/Sources/Live/Room/Routlette/Config/RouletteSettingsView.swift b/SodaLive/Sources/Live/Room/Routlette/Config/RouletteSettingsView.swift index 91efb08..f4a3060 100644 --- a/SodaLive/Sources/Live/Room/Routlette/Config/RouletteSettingsView.swift +++ b/SodaLive/Sources/Live/Room/Routlette/Config/RouletteSettingsView.swift @@ -21,7 +21,7 @@ struct RouletteSettingsView: View { GeometryReader { proxy in BaseView(isLoading: $viewModel.isLoading) { VStack(spacing: 0) { - DetailNavigationBar(title: "룰렛설정") { + DetailNavigationBar(title: String(localized: "룰렛 설정")) { isShowing = false } @@ -29,7 +29,7 @@ struct RouletteSettingsView: View { VStack(spacing: 0) { HStack(spacing: 13.3) { SelectedButtonView( - title: "룰렛 1", + title: I18n.Common.roulette1, isActive: true, isSelected: viewModel.selectedRoulette == .ROULETTE_1 ) @@ -38,7 +38,7 @@ struct RouletteSettingsView: View { } SelectedButtonView( - title: "룰렛 2", + title: I18n.Common.roulette2, isActive: viewModel.rouletteList.count > 0, isSelected: viewModel.selectedRoulette == .ROULETTE_2, checkImage: "ic_select_check_black", @@ -51,7 +51,7 @@ struct RouletteSettingsView: View { } SelectedButtonView( - title: "룰렛 3", + title: I18n.Common.roulette3, isActive: viewModel.rouletteList.count > 1, isSelected: viewModel.selectedRoulette == .ROULETTE_3, bgSelectedColor: Color(hex: "ff14d9"),