Skip to content

Commit

Permalink
♻️ (LekaApp): Refactor titles and texts
Browse files Browse the repository at this point in the history
  • Loading branch information
HPezz committed Feb 14, 2024
1 parent 54bc084 commit b233604
Show file tree
Hide file tree
Showing 13 changed files with 43 additions and 54 deletions.
32 changes: 16 additions & 16 deletions Apps/LekaApp/Resources/Localizable.xcstrings
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,13 @@
"en": {
"stringUnit": {
"state": "new",
"value": "Profil of "
"value": "Edit my profile"
}
},
"fr": {
"stringUnit": {
"state": "translated",
"value": "Profil de "
"value": "Editer mon profil"
}
}
}
Expand Down Expand Up @@ -117,13 +117,13 @@
"en": {
"stringUnit": {
"state": "new",
"value": "Profil of "
"value": "Edit profil"
}
},
"fr": {
"stringUnit": {
"state": "translated",
"value": "Profil de "
"value": "Editer le profil"
}
}
}
Expand Down Expand Up @@ -243,13 +243,13 @@
"en": {
"stringUnit": {
"state": "new",
"value": "A verification email has been sent.\nPlease check your inbox.\n\nWe will now guide you throught\nthe creation of your account\nand the different steps.\nReady?"
"value": "We will now guide you throught\nthe creation of your account\nand the different steps.\nReady?"
}
},
"fr": {
"stringUnit": {
"state": "translated",
"value": "L'email de v\u00e9rification a \u00e9t\u00e9 envoy\u00e9. Veuillez v\u00e9rifier votre bo\u00eete de r\u00e9ception.\u2028\u2028Nous allons maintenant vous guider\n\u00e0 travers la cr\u00e9ation de votre compte\net les diff\u00e9rentes \u00e9tapes.\nPr\u00eat(e)?"
"value": "Nous allons maintenant vous guider\n\u00e0 travers la cr\u00e9ation de votre compte\net les diff\u00e9rentes \u00e9tapes.\nPr\u00eat(e)?"
}
}
}
Expand Down Expand Up @@ -405,13 +405,13 @@
"en": {
"stringUnit": {
"state": "new",
"value": "You have completed process brilliantly:\n\n- Create your caregiver profile \u2705\n- Create your first care receiver profile \u2705\n\nYou can now discover the Leka App and dive deep in our educational content!"
"value": "You have just completed:\n\n\u2705 Your caregiver profile\n\u2705 Your first care receiver profile\n\nYou can now discover the Leka App and dive deep in our educational content!"
}
},
"fr": {
"stringUnit": {
"state": "translated",
"value": "Vous avez brillamment compl\u00e9t\u00e9 le processus :\n\n- Cr\u00e9er votre profil d'accompagnant \u2705\n- Cr\u00e9er votre premier profil de personne accompagn\u00e9e \u2705\n\nVous pouvez maintenant d\u00e9couvrir l'appli Leka et approfondir notre contenu \u00e9ducatif !"
"value": "Vous venez de cr\u00e9er :\n\n\u2705 Un profil d'accompagnant\n\u2705 Un profil de personne accompagn\u00e9e \n\nVous pouvez maintenant d\u00e9couvrir l'appli Leka et approfondir notre contenu \u00e9ducatif !"
}
}
}
Expand Down Expand Up @@ -495,13 +495,13 @@
"en": {
"stringUnit": {
"state": "new",
"value": "What's your avatar ?"
"value": "Avatar choice"
}
},
"fr": {
"stringUnit": {
"state": "translated",
"value": "Quel est ton avatar ?"
"value": "Choix de l'avatar"
}
}
}
Expand Down Expand Up @@ -693,13 +693,13 @@
"en": {
"stringUnit": {
"state": "new",
"value": "Name"
"value": "Username"
}
},
"fr": {
"stringUnit": {
"state": "translated",
"value": "Nom"
"value": "Nom d'utilisateur"
}
}
}
Expand Down Expand Up @@ -765,13 +765,13 @@
"en": {
"stringUnit": {
"state": "new",
"value": "Care receivers list"
"value": "Care receivers"
}
},
"fr": {
"stringUnit": {
"state": "translated",
"value": "Liste des personnes accompagn\u00e9es"
"value": "Personnes accompagn\u00e9es"
}
}
}
Expand Down Expand Up @@ -855,13 +855,13 @@
"en": {
"stringUnit": {
"state": "new",
"value": "Select your professions"
"value": "Profession choice"
}
},
"fr": {
"stringUnit": {
"state": "translated",
"value": "S\u00e9lectionnez vos professions"
"value": "Choix de(s) profession(s)"
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,6 @@ extension AccountCreationProcess {

var body: some View {
VStack(spacing: 30) {
Image(
DesignKitAsset.Images.welcome.name,
bundle: Bundle(for: DesignKitResources.self)
)
.resizable()
.renderingMode(.original)
.aspectRatio(contentMode: .fit)
.frame(height: 80)
.padding()

Text(l10n.AccountCreationProcess.Step1.title)
.font(.headline)
.foregroundColor(.orange)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,11 @@ extension AccountCreationProcess {

var body: some View {
VStack(spacing: 30) {
Image(
DesignKitAsset.Images.accompagnantPicto.name,
bundle: Bundle(for: DesignKitResources.self)
)
.resizable()
.renderingMode(.original)
.aspectRatio(contentMode: .fit)
.frame(height: 80)
Image(systemName: "person.3.fill")
.resizable()
.renderingMode(.original)
.aspectRatio(contentMode: .fit)
.frame(height: 80)

Text(l10n.AccountCreationProcess.Step2.title)
.font(.headline)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,11 @@ extension AccountCreationProcess {

var body: some View {
VStack(spacing: 30) {
Image(
DesignKitAsset.Images.user.name,
bundle: Bundle(for: DesignKitResources.self)
)
.resizable()
.renderingMode(.original)
.aspectRatio(contentMode: .fit)
.frame(height: 80)
Image(systemName: "figure.2.arms.open")
.resizable()
.renderingMode(.original)
.aspectRatio(contentMode: .fit)
.frame(height: 80)

Text(l10n.AccountCreationProcess.Step3.title)
.font(.headline)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,6 @@ extension l10n {

static let message = LocalizedString("lekaapp.account_creation_process.step_1.message",
value: """
A verification email has been sent.
Please check your inbox.
We will now guide you throught
the creation of your account
and the different steps.
Expand Down Expand Up @@ -56,10 +53,10 @@ extension l10n {

static let message = LocalizedString("lekaapp.account_creation_process.step_4.message",
value: """
You have completed process brilliantly:
You have just completed:
- Create your caregiver profile
- Create your first care receiver profile
✅ Your caregiver profile
✅ Your first care receiver profile
You can now discover the Leka App and dive deep in our educational content!
""",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import LocalizationKit

extension l10n {
enum AvatarPicker {
static let title = LocalizedString("lekaapp.avatar_picker.title", value: "What's your avatar ?", comment: "Avatar picker title")
static let title = LocalizedString("lekaapp.avatar_picker.title", value: "Avatar choice", comment: "Avatar picker title")

static let validateButton = LocalizedString("lekaapp.avatar_picker.validate_button", value: "Validate selection", comment: "Avatar picker validate button")
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ extension l10n {
static let title = LocalizedString("edit_caregiver_view.appearance_section.accent_color_row.title", value: "Color Theme", comment: "AccentColor Row title")
}

static let navigationTitle = LocalizedString("edit_caregiver_view.navigation_title", value: "Profil of ", comment: "The navigation title of Edit Caregiver View")
static let navigationTitle = LocalizedString("edit_caregiver_view.navigation_title", value: "Edit my profile", comment: "The navigation title of Edit Caregiver View")

static let saveButtonLabel = LocalizedString("edit_caregiver_view.save_button_label", value: "Save", comment: "Save button label of Edit Caregiver View")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import LocalizationKit

extension l10n {
enum EditCarereceiverView {
static let navigationTitle = LocalizedString("edit_carereceiver_view.navigation_title", value: "Profil of ", comment: "The navigation title of Edit Carereceiver View")
static let navigationTitle = LocalizedString("edit_carereceiver_view.navigation_title", value: "Edit profil", comment: "The navigation title of Edit Carereceiver View")

static let saveButtonLabel = LocalizedString("edit_carereceiver_view.save_button_label", value: "Save", comment: "Save button label of Edit Carereceiver View")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ struct EditCaregiverLabel: View {
.frame(maxWidth: 80)
}

Divider()

Button {
self.rootOwnerViewModel.isCaregiverPickerViewPresented = true
} label: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import LocalizationKit

extension l10n {
enum ProfessionPicker {
static let title = LocalizedString("lekaapp.profession_picker.title", value: "Select your professions", comment: "Profession picker title")
static let title = LocalizedString("lekaapp.profession_picker.title", value: "Profession choice", comment: "Profession picker title")

static let otherLabel = LocalizedString("lekaapp.profession_picker.other_label", value: "Other (specify)", comment: "Profession picker other profession label")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ struct CarereceiverPicker: View {
extension l10n {
enum CarereceiverPicker {
static let title = LocalizedString("lekaapp.carereceiver_picker.title",
value: "Care receivers list",
value: "Care receivers",
comment: "Carereceiver picker title")

static let addButtonLabel = LocalizedString("lekaapp.carereceiver_picker.addButtonLabel",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ struct CreateCaregiverView: View {
self.isPresented.toggle()
self.onDismissAction()
}
if self.newCaregiver.avatar.isEmpty {
self.newCaregiver.avatar = AvatarSets.weather.content.images.randomElement()!
}
// TODO: (@team) : add the caregiver profile to the account

Check warning on line 46 in Apps/LekaApp/Sources/_NEWCodeBase/Views/Profiles/CreateCaregiverView.swift

View workflow job for this annotation

GitHub Actions / swiftlint

TODOs should be resolved ((@team) : add the caregiver pr...) (todo)
// TODO: (@team) : assign the caregiver profile as the current selected one

Check warning on line 47 in Apps/LekaApp/Sources/_NEWCodeBase/Views/Profiles/CreateCaregiverView.swift

View workflow job for this annotation

GitHub Actions / swiftlint

TODOs should be resolved ((@team) : assign the caregiver...) (todo)
self.rootOwnerViewModel.mockCaregiversSet.append(self.newCaregiver)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ struct CreateCarereceiverView: View {
self.isPresented.toggle()
self.onDismissAction()
}
if self.newCarereceiver.avatar.isEmpty {
self.newCarereceiver.avatar = AvatarSets.sunglasses.content.images.randomElement()!
}
// TODO: (@team) : add the carereceiver profile to the account

Check warning on line 42 in Apps/LekaApp/Sources/_NEWCodeBase/Views/Profiles/CreateCarereceiverView.swift

View workflow job for this annotation

GitHub Actions / swiftlint

TODOs should be resolved ((@team) : add the carereceiver...) (todo)
// TODO: (@team) : assign the carereceiver profile as the current selected one

Check warning on line 43 in Apps/LekaApp/Sources/_NEWCodeBase/Views/Profiles/CreateCarereceiverView.swift

View workflow job for this annotation

GitHub Actions / swiftlint

TODOs should be resolved ((@team) : assign the carerecei...) (todo)
self.rootOwnerViewModel.mockCarereceiversSet.append(self.newCarereceiver)
Expand Down Expand Up @@ -83,7 +86,7 @@ extension l10n {

static let avatarChoiceButton = LocalizedString("lekaapp.carereceiver_creation.avatar_choice_button", value: "Choose an avatar", comment: " Carereceiver creation avatar choice button label")

static let carereceiverNameLabel = LocalizedString("lekaapp.carereceiver_creation.carereceiver_name_label", value: "Name", comment: " Carereceiver creation carereceiver name textfield label")
static let carereceiverNameLabel = LocalizedString("lekaapp.carereceiver_creation.carereceiver_name_label", value: "Username", comment: " Carereceiver creation carereceiver name textfield label")

static let registerProfilButton = LocalizedString("lekaapp.carereceiver_creation.register_profil_button", value: "Register profile", comment: " Carereceiver creation register profil button label")
}
Expand Down

0 comments on commit b233604

Please sign in to comment.