Merge branch 'release/0.1.20
-fix: Applying learn UAT comments
This commit is contained in:
commit
a31e18748c
|
|
@ -151,7 +151,9 @@
|
|||
"phone_must_start_with": "የስልክ ቁጥር በ251 መጀመር አለበት",
|
||||
"phone_must_be": "የስልክ ቁጥር 12 አሃዞች መሆን አለበት",
|
||||
"what_should_we_call_you": "ምን ብለን እንጠራህ?",
|
||||
"use_for_personalization": "በመማር ጉዞህ ውስጥ ለግል ለማድረግ ስምህን እንጠቀማለን።"
|
||||
"name_for_personalization": "በመማር ጉዞህ ውስጥ ለግል ለማድረግ ስምህን እንጠቀማለን።",
|
||||
"choose_your_gender": "ጾታህን ምረጥ",
|
||||
"gender_for_personalization": "በጾታህ መሰረት የመማር ተሞክሮህን እናበጅለታለን።"
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -151,6 +151,9 @@
|
|||
"phone_must_start_with": "Phone number must start with 251",
|
||||
"phone_must_be": "Phone number must be 12 digits",
|
||||
"what_should_we_call_you": "What should we call you?",
|
||||
"use_for_personalization": "We’ll use your name to personalize your learning journey."
|
||||
"name_for_personalization": "We’ll use your name to personalize your learning journey.",
|
||||
"choose_your_gender": "Choose your gender?",
|
||||
"gender_for_personalization": "We’ll personalize your learning experience based on your gender."
|
||||
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -167,7 +167,9 @@ class CodegenLoader extends AssetLoader{
|
|||
"phone_must_start_with": "የስልክ ቁጥር በ251 መጀመር አለበት",
|
||||
"phone_must_be": "የስልክ ቁጥር 12 አሃዞች መሆን አለበት",
|
||||
"what_should_we_call_you": "ምን ብለን እንጠራህ?",
|
||||
"use_for_personalization": "በመማር ጉዞህ ውስጥ ለግል ለማድረግ ስምህን እንጠቀማለን።"
|
||||
"name_for_personalization": "በመማር ጉዞህ ውስጥ ለግል ለማድረግ ስምህን እንጠቀማለን።",
|
||||
"choose_your_gender": "ጾታህን ምረጥ",
|
||||
"gender_for_personalization": "በጾታህ መሰረት የመማር ተሞክሮህን እናበጅለታለን።"
|
||||
};
|
||||
static const Map<String,dynamic> _en = {
|
||||
"loading": "Loading",
|
||||
|
|
@ -322,7 +324,9 @@ static const Map<String,dynamic> _en = {
|
|||
"phone_must_start_with": "Phone number must start with 251",
|
||||
"phone_must_be": "Phone number must be 12 digits",
|
||||
"what_should_we_call_you": "What should we call you?",
|
||||
"use_for_personalization": "We’ll use your name to personalize your learning journey."
|
||||
"name_for_personalization": "We’ll use your name to personalize your learning journey.",
|
||||
"choose_your_gender": "Choose your gender?",
|
||||
"gender_for_personalization": "We’ll personalize your learning experience based on your gender."
|
||||
};
|
||||
static const Map<String, Map<String,dynamic>> mapLocales = {"am": _am, "en": _en};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -153,6 +153,8 @@ abstract class LocaleKeys {
|
|||
static const phone_must_start_with = 'phone_must_start_with';
|
||||
static const phone_must_be = 'phone_must_be';
|
||||
static const what_should_we_call_you = 'what_should_we_call_you';
|
||||
static const use_for_personalization = 'use_for_personalization';
|
||||
static const name_for_personalization = 'name_for_personalization';
|
||||
static const choose_your_gender = 'choose_your_gender';
|
||||
static const gender_for_personalization = 'gender_for_personalization';
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -62,12 +62,19 @@ class OnboardingViewModel extends ReactiveViewModel
|
|||
String? get selectedEducationalBackground => _selectedEducationalBackground;
|
||||
|
||||
// Gender
|
||||
final List<String> _genders = [
|
||||
final List<String> _gendersEn = [
|
||||
'Male',
|
||||
'Female',
|
||||
];
|
||||
|
||||
List<String> get genders => _genders;
|
||||
List<String> get gendersEn => _gendersEn;
|
||||
|
||||
final List<String> _gendersAm = [
|
||||
'ወንድ',
|
||||
'ሴት',
|
||||
];
|
||||
|
||||
List<String> get gendersAm => _gendersAm;
|
||||
|
||||
String? _selectedGender;
|
||||
|
||||
|
|
@ -78,7 +85,9 @@ class OnboardingViewModel extends ReactiveViewModel
|
|||
{
|
||||
'Under 13': 'UNDER_13',
|
||||
},
|
||||
{'13-17': '13_17'},
|
||||
{
|
||||
'13-17': '13_17',
|
||||
},
|
||||
{
|
||||
'18-24': '18_24',
|
||||
},
|
||||
|
|
|
|||
|
|
@ -100,7 +100,7 @@ class FullNameFormScreen extends ViewModelWidget<OnboardingViewModel> {
|
|||
);
|
||||
|
||||
Widget _buildSubtitle() => Text(
|
||||
LocaleKeys.use_for_personalization.tr(),
|
||||
LocaleKeys.name_for_personalization.tr(),
|
||||
style:style14MG400,
|
||||
);
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
import 'package:easy_localization/easy_localization.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:stacked/stacked.dart';
|
||||
import 'package:yimaru_app/ui/common/app_colors.dart';
|
||||
import 'package:yimaru_app/ui/common/translations/locale_keys.g.dart';
|
||||
import 'package:yimaru_app/ui/common/ui_helpers.dart';
|
||||
import 'package:yimaru_app/ui/widgets/custom_elevated_button.dart';
|
||||
import 'package:yimaru_app/ui/views/onboarding/onboarding_viewmodel.dart';
|
||||
|
|
@ -85,23 +87,25 @@ class GenderFormScreen extends ViewModelWidget<OnboardingViewModel> {
|
|||
);
|
||||
|
||||
Widget _buildTitle() => Text(
|
||||
'Choose your gender?',
|
||||
LocaleKeys.choose_your_gender.tr(),
|
||||
style: style25DG600,
|
||||
);
|
||||
|
||||
Widget _buildSubtitle() => Text(
|
||||
'We’ll personalize your learning experience based on your gender.',
|
||||
LocaleKeys.gender_for_personalization.tr(),
|
||||
style: style14MG400,
|
||||
);
|
||||
|
||||
Widget _buildAgeGroups(OnboardingViewModel viewModel) => ListView.builder(
|
||||
shrinkWrap: true,
|
||||
itemCount: viewModel.genders.length,
|
||||
itemCount: viewModel.selectedLanguage['code'] == 'am'
|
||||
? viewModel.gendersAm.length
|
||||
: viewModel.gendersEn.length,
|
||||
physics: const NeverScrollableScrollPhysics(),
|
||||
itemBuilder: (context, index) => _buildAgeGroup(
|
||||
title: viewModel.genders[index],
|
||||
selected: viewModel.isSelectedGender(viewModel.genders[index]),
|
||||
onTap: () => viewModel.setSelectedGender(viewModel.genders[index]),
|
||||
title:viewModel.selectedLanguage['code'] == 'am' ? viewModel.gendersAm[index]:viewModel.gendersEn[index],
|
||||
selected: viewModel.isSelectedGender(viewModel.selectedLanguage['code'] == 'am' ? viewModel.gendersAm[index]: viewModel.gendersEn[index]),
|
||||
onTap: () => viewModel.setSelectedGender(viewModel.selectedLanguage['code'] == 'am' ? viewModel.gendersAm[index]: viewModel.gendersEn[index]),
|
||||
),
|
||||
);
|
||||
|
||||
|
|
@ -123,9 +127,9 @@ class GenderFormScreen extends ViewModelWidget<OnboardingViewModel> {
|
|||
Widget _buildContinueButton(OnboardingViewModel viewModel) =>
|
||||
CustomElevatedButton(
|
||||
height: 55,
|
||||
text: 'Continue',
|
||||
borderRadius: 12,
|
||||
foregroundColor: kcWhite,
|
||||
text: LocaleKeys.cont.tr(),
|
||||
backgroundColor: viewModel.selectedGender != null
|
||||
? kcPrimaryColor
|
||||
: kcPrimaryColor.withOpacity(0.1),
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
name: yimaru_app
|
||||
version: 0.1.19+21
|
||||
version: 0.1.20+22
|
||||
publish_to: 'none'
|
||||
description: A new Flutter project.
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user