feat(i18n): 라이브 룸 하드코딩 문구를 I18n 키로 통일한다

This commit is contained in:
Yu Sung
2026-04-01 13:52:02 +09:00
parent 540238eb48
commit bceec46ebc
36 changed files with 571 additions and 324 deletions

View File

@@ -25,7 +25,7 @@ struct LiveRoomDonationMessageDialog: View {
VStack(spacing: 0) {
HStack(spacing: 0) {
Text("후원 히스토리")
Text(I18n.CreateLive.donationHistoryTitle)
.appFont(size: 14.7, weight: .bold)
.foregroundColor(Color(hex: "eeeeee"))
@@ -35,7 +35,7 @@ struct LiveRoomDonationMessageDialog: View {
Spacer()
Text("닫기")
Text(I18n.CreateLive.closeAction)
.appFont(size: 14.7, weight: .light)
.foregroundColor(Color(hex: "eeeeee"))
.onTapGesture { isShowing = false }
@@ -52,14 +52,14 @@ struct LiveRoomDonationMessageDialog: View {
}
.onTapGesture {
UIPasteboard.general.string = donationMessage.donationMessage
self.viewModel.errorMessage = "후원 히스토리가 복사되었습니다."
self.viewModel.errorMessage = I18n.CreateLive.donationHistoryCopied
self.viewModel.isShowPopup = true
}
}
}
.padding(.top, 18.7)
} else {
Text("후원 히스토리가 없습니다.")
Text(I18n.CreateLive.donationHistoryEmpty)
.appFont(size: 14.7, weight: .medium)
.foregroundColor(Color(hex: "eeeeee"))
.padding(.top, 30)

View File

@@ -16,7 +16,7 @@ struct LiveRoomDonationMessageItemView: View {
var body: some View {
HStack(alignment: .top, spacing: 0) {
VStack(alignment: .leading, spacing: 8) {
Text("\(message.nickname)님이")
Text("\(message.nickname)\(I18n.LiveChat.donationMemberSuffix)")
.appFont(size: 13.3, weight: .medium)
.foregroundColor(.white)

View File

@@ -18,7 +18,7 @@ struct LiveRoomDonationRankingDialog: View {
ZStack {
VStack(spacing: 0) {
HStack(spacing: 0) {
Text("현재 라이브 후원랭킹")
Text(I18n.CreateLive.donationRankingTitle)
.appFont(size: 14.7, weight: .bold)
.foregroundColor(Color.grayee)
@@ -33,7 +33,7 @@ struct LiveRoomDonationRankingDialog: View {
.padding(.top, 25)
HStack(spacing: 0) {
Text("전체")
Text(I18n.CreateLive.totalLabel)
.appFont(size: 14.7, weight: .medium)
.foregroundColor(Color.grayee)
@@ -42,7 +42,7 @@ struct LiveRoomDonationRankingDialog: View {
.foregroundColor(Color.button)
.padding(.leading, 6.7)
Text("")
Text(I18n.CreateLive.peopleUnit)
.appFont(size: 12, weight: .medium)
.foregroundColor(Color.gray77)

View File

@@ -55,7 +55,7 @@ struct LiveRoomDonationRankingItemView: View {
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color.button)
Text("")
Text(I18n.CreateLive.canUnit)
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color(hex: "eeeeee"))
}
@@ -63,7 +63,7 @@ struct LiveRoomDonationRankingItemView: View {
if item.secretCan > 0 {
HStack(spacing: 4) {
Text("비밀")
Text(I18n.CreateLive.secretLabel)
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color.gray11)
.padding(.horizontal, 3.3)
@@ -75,7 +75,7 @@ struct LiveRoomDonationRankingItemView: View {
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color(hex: "fedc00"))
Text("")
Text(I18n.CreateLive.canUnit)
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color(hex: "eeeeee"))
}

View File

@@ -14,7 +14,7 @@ struct LiveRoomDonationRankingTotalCanView: View {
var body: some View {
HStack(alignment: .center, spacing: 0) {
Text("합계")
Text(I18n.CreateLive.sumLabel)
.appFont(size: 13.3, weight: .bold)
.foregroundColor(Color.grayd2)
@@ -23,7 +23,7 @@ struct LiveRoomDonationRankingTotalCanView: View {
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color.grayd2)
Text("일반")
Text(I18n.CreateLive.normalLabel)
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color.button)
@@ -31,7 +31,7 @@ struct LiveRoomDonationRankingTotalCanView: View {
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color.grayd2)
Text("비밀")
Text(I18n.CreateLive.secretLabel)
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color(hex: "fedc00"))
@@ -55,7 +55,7 @@ struct LiveRoomDonationRankingTotalCanView: View {
.foregroundColor(Color(hex: "fedc00"))
}
Text("")
Text(I18n.CreateLive.canUnit)
.appFont(size: 10.7, weight: .medium)
.foregroundColor(Color.graybb)
.padding(.leading, 4)

View File

@@ -22,7 +22,7 @@ struct LiveRoomHeartRankingDialog: View {
ZStack {
VStack(spacing: 0) {
HStack(spacing: 0) {
Text("현재 라이브 하트랭킹")
Text(I18n.CreateLive.heartRankingTitle)
.appFont(size: 14.7, weight: .bold)
.foregroundColor(Color.grayee)
@@ -34,7 +34,7 @@ struct LiveRoomHeartRankingDialog: View {
if let heartStatus = heartStatus {
HStack(alignment: .center, spacing: 0) {
Text("합계")
Text(I18n.CreateLive.sumLabel)
.appFont(size: 13.3, weight: .bold)
.foregroundColor(Color.grayd2)
@@ -44,7 +44,7 @@ struct LiveRoomHeartRankingDialog: View {
.appFont(size: 14, weight: .medium)
.foregroundColor(Color.button)
Text("하트")
Text(I18n.CreateLive.heartLabel)
.appFont(size: 10.7, weight: .medium)
.foregroundColor(Color.graybb)
.padding(.leading, 4)
@@ -56,7 +56,7 @@ struct LiveRoomHeartRankingDialog: View {
.padding(.top, 25)
HStack(spacing: 0) {
Text("전체")
Text(I18n.CreateLive.totalLabel)
.appFont(size: 14.7, weight: .medium)
.foregroundColor(Color.grayee)
@@ -65,7 +65,7 @@ struct LiveRoomHeartRankingDialog: View {
.foregroundColor(Color.button)
.padding(.leading, 6.7)
Text("")
Text(I18n.CreateLive.peopleUnit)
.appFont(size: 12, weight: .medium)
.foregroundColor(Color.gray77)

View File

@@ -55,7 +55,7 @@ struct LiveRoomHeartRankingItemView: View {
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color.button)
Text("하트")
Text(I18n.CreateLive.heartLabel)
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color.grayee)
}

View File

@@ -18,7 +18,7 @@ struct LiveRoomInfoEditDialog: View {
@State private var isAdult = false
@State private var isEntryMessageEnabled = true
let placeholder = "라이브 공지를 입력하세요"
let placeholder = I18n.CreateLive.noticePlaceholder
@StateObject var viewModel: LiveRoomViewModel
@@ -62,7 +62,7 @@ struct LiveRoomInfoEditDialog: View {
ScrollView(.vertical, showsIndicators: false) {
VStack(alignment: .leading, spacing: 0) {
HStack(spacing: 0) {
Text("라이브 수정")
Text(I18n.CreateLive.editLiveTitle)
.appFont(size: 18.3, weight: .bold)
.foregroundColor(Color.grayee)
@@ -131,12 +131,12 @@ struct LiveRoomInfoEditDialog: View {
if UserDefaults.bool(forKey: .auth) {
VStack(alignment: .leading, spacing: 8) {
Text("연령제한")
Text(I18n.CreateLive.ageRestrictionLabel)
.appFont(size: 16.7, weight: .bold)
.foregroundColor(Color.grayee)
HStack(spacing: 0) {
Text("19세 이상")
Text(I18n.CreateLive.over19)
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color.grayee)
@@ -163,7 +163,7 @@ struct LiveRoomInfoEditDialog: View {
.padding(.top, 33.3)
HStack(spacing: 0) {
Text("입장메시지")
Text(I18n.CreateLive.entryMessageLabel)
.appFont(size: 16.7, weight: .bold)
.foregroundColor(Color.grayee)
@@ -179,7 +179,7 @@ struct LiveRoomInfoEditDialog: View {
.padding(.top, 33.3)
HStack(spacing: 13.3) {
Text("취소")
Text(I18n.Common.cancel)
.appFont(size: 18.3, weight: .bold)
.foregroundColor(Color.button)
.padding(.vertical, 16)
@@ -195,7 +195,7 @@ struct LiveRoomInfoEditDialog: View {
isShowing = false
}
Text("수정하기")
Text(I18n.CreateLive.editAction)
.appFont(size: 18.3, weight: .bold)
.foregroundColor(.white)
.padding(.vertical, 16)
@@ -251,11 +251,11 @@ struct LiveRoomInfoEditDialog: View {
@ViewBuilder
func TitleInputView() -> some View {
VStack(alignment: .leading, spacing: 0) {
Text("제목")
Text(I18n.CreateLive.titleLabel)
.appFont(size: 16.7, weight: .bold)
.foregroundColor(Color.grayee)
TextField("라이브 제목을 입력하세요", text: $title)
TextField(I18n.CreateLive.titlePlaceholder, text: $title)
.autocapitalization(.none)
.disableAutocorrection(true)
.appFont(size: 13.3, weight: .medium)
@@ -276,16 +276,16 @@ struct LiveRoomInfoEditDialog: View {
func ContentInputView() -> some View {
VStack(spacing: 13.3) {
HStack(spacing: 0) {
Text("공지")
Text(I18n.CreateLive.noticeLabel)
.appFont(size: 16.7, weight: .bold)
.foregroundColor(Color.grayee)
Spacer()
Text("\(notice.count)")
Text(I18n.CreateLive.noticeCount(notice.count))
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color.mainRed)
Text(" / 1000자")
Text(I18n.CreateLive.noticeLimitSuffix)
.appFont(size: 13.3, weight: .medium)
.foregroundColor(Color.gray77)
}

View File

@@ -22,7 +22,7 @@ struct LiveRoomNoChattingDialogView: View {
.frame(width: screenSize().width, height: screenSize().height)
VStack(spacing: 21) {
Text("채팅금지")
Text(I18n.CreateLive.noChattingTitle)
.appFont(size: 18.3, weight: .bold)
.foregroundColor(Color(hex: "bbbbbb"))
@@ -43,12 +43,12 @@ struct LiveRoomNoChattingDialogView: View {
.foregroundColor(Color(hex: "bbbbbb"))
}
Text("3분간 채팅금지를 하겠습니까?")
Text(I18n.CreateLive.noChattingQuestion)
.appFont(size: 15, weight: .medium)
.foregroundColor(Color(hex: "bbbbbb"))
HStack(spacing: 13.3) {
Text("취소")
Text(I18n.Common.cancel)
.appFont(size: 15.3, weight: .bold)
.foregroundColor(Color.button)
.padding(.vertical, 16)
@@ -61,7 +61,7 @@ struct LiveRoomNoChattingDialogView: View {
)
.onTapGesture { cancelAction() }
Text("확인")
Text(I18n.Common.confirm)
.appFont(size: 15.3, weight: .bold)
.foregroundColor(Color(hex: "ffffff"))
.padding(.vertical, 16)

View File

@@ -51,7 +51,7 @@ struct LiveRoomProfileDialog: View {
if isSpeaker {
if profileInfo.role == .LISTENER, let onClickInviteSpeaker = onClickInviteSpeaker {
Text("스피커로 초대")
Text(I18n.CreateLive.inviteSpeakerAction)
.appFont(size: 10, weight: .medium)
.foregroundColor(.button)
.padding(.horizontal, 15.4)
@@ -66,7 +66,7 @@ struct LiveRoomProfileDialog: View {
if (memberId == creatorId || memberId == profileInfo.id) && profileInfo.id != creatorId && profileInfo.role == .SPEAKER,
let onClickChangeListener = onClickChangeListener {
Text("리스너로 변경")
Text(I18n.CreateLive.changeListenerAction)
.appFont(size: 10, weight: .medium)
.foregroundColor(.button)
.padding(.horizontal, 15.4)

View File

@@ -132,7 +132,7 @@ struct LiveRoomProfileItemUserView: View {
Spacer()
if role == .LISTENER && isStaff {
Text("스피커로 초대")
Text(I18n.CreateLive.inviteSpeakerAction)
.appFont(size: 10, weight: .medium)
.foregroundColor(.white)
.padding(.horizontal, 5.5)
@@ -149,7 +149,7 @@ struct LiveRoomProfileItemUserView: View {
}
if role == .SPEAKER && (userId == UserDefaults.int(forKey: .userId) || isStaff) {
Text("리스너로 변경")
Text(I18n.CreateLive.changeListenerAction)
.appFont(size: 10, weight: .medium)
.foregroundColor(.white)
.padding(.horizontal, 5.5)
@@ -162,7 +162,7 @@ struct LiveRoomProfileItemUserView: View {
}
if role != .MANAGER && creatorId == UserDefaults.int(forKey: .userId) {
Text("채금")
Text(I18n.CreateLive.shortNoChattingAction)
.appFont(size: 10, weight: .medium)
.foregroundColor(.white)
.padding(.horizontal, 5.5)
@@ -206,7 +206,7 @@ struct LiveRoomProfileRequestSpeakerView: View {
HStack(spacing: 6.7) {
Spacer()
Image("ic_request_speak")
Text("스피커 요청하기")
Text(I18n.CreateLive.requestSpeakerAction)
.appFont(size: 13.3, weight: .bold)
.foregroundColor(.white)
Spacer()

View File

@@ -35,7 +35,7 @@ struct LiveRoomProfilesDialogView: View {
self.profiles.append(
AnyView(
LiveRoomProfileItemTitleView(
title: "스탭",
title: I18n.CreateLive.staffTitle,
count: roomInfo.managerList.count,
totalCount: nil
)
@@ -71,7 +71,7 @@ struct LiveRoomProfilesDialogView: View {
self.profiles.append(
AnyView(
LiveRoomProfileItemTitleView(
title: "스피커",
title: I18n.CreateLive.speakerTitle,
count: roomInfo.speakerList.count - 1,
totalCount: roomInfo.totalAvailableParticipantsCount
)
@@ -127,7 +127,7 @@ struct LiveRoomProfilesDialogView: View {
self.profiles.append(
AnyView(
LiveRoomProfileItemTitleView(
title: "리스너",
title: I18n.CreateLive.listenerTitle,
count: nil,
totalCount: nil
)
@@ -150,10 +150,10 @@ struct LiveRoomProfilesDialogView: View {
onClickInviteSpeaker: {
if viewModel.liveRoomInfo!.speakerList.count <= 5 {
viewModel.inviteSpeaker(peerId: $0)
viewModel.popupContent = "스피커 요청을 보냈습니다.\n잠시만 기다려 주세요."
viewModel.popupContent = I18n.CreateLive.speakerRequestSent
viewModel.isShowPopup = true
} else {
viewModel.errorMessage = "스피커 정원을 초과했습니다."
viewModel.errorMessage = I18n.CreateLive.speakerCapacityExceeded
viewModel.isShowErrorPopup = true
}
},
@@ -173,7 +173,7 @@ struct LiveRoomProfilesDialogView: View {
ZStack {
VStack(spacing: 16.7) {
HStack(spacing: 0) {
Text("참여자")
Text(I18n.CreateLive.participantTitle)
.appFont(size: 15, weight: .bold)
.foregroundColor(Color.grayee)

View File

@@ -29,7 +29,7 @@ struct LiveRoomUserProfileDialogView: View {
ZStack {
VStack(spacing: 0) {
HStack(spacing: 0) {
Text("프로필")
Text(I18n.CreateLive.profileTitle)
.appFont(size: 15, weight: .bold)
.foregroundColor(Color.grayee)
@@ -91,7 +91,7 @@ struct LiveRoomUserProfileDialogView: View {
HStack(spacing: 8) {
if let isSpeaker = userProfile.isSpeaker {
Text(isSpeaker ? "리스너 변경" : "스피커 초대")
Text(isSpeaker ? I18n.CreateLive.changeListenerAction : I18n.CreateLive.inviteSpeakerAction)
.appFont(size: 15, weight: .bold)
.foregroundColor(Color.button)
.frame(maxWidth: .infinity)
@@ -114,7 +114,7 @@ struct LiveRoomUserProfileDialogView: View {
}
if let isManager = userProfile.isManager {
Text(isManager ? "스탭 해제" : "스탭 지정")
Text(isManager ? I18n.CreateLive.staffReleaseAction : I18n.CreateLive.staffAssignAction)
.appFont(size: 15, weight: .bold)
.foregroundColor(Color.button)
.frame(maxWidth: .infinity)
@@ -138,7 +138,7 @@ struct LiveRoomUserProfileDialogView: View {
if (userProfile.isSpeaker != nil && !viewModel.isEqualToStaffId(creatorId: userProfile.userId)) ||
(userProfile.isSpeaker != nil && userProfile.isManager != nil) {
Text("내보내기")
Text(I18n.CreateLive.kickOutAction)
.appFont(size: 15, weight: .bold)
.foregroundColor(Color.button)
.frame(maxWidth: .infinity)
@@ -159,7 +159,7 @@ struct LiveRoomUserProfileDialogView: View {
.padding(.top, 21.3)
if let _ = userProfile.isManager {
Text("3분간 채팅금지")
Text(I18n.CreateLive.noChattingAction)
.appFont(size: 15, weight: .bold)
.foregroundColor(Color.button)
.frame(maxWidth: .infinity)