forked from eatvio/eatvio_app
feat(order info): added order info screen
This commit is contained in:
@@ -18,9 +18,9 @@ class _ChangeEmailScreenState extends State<ChangeEmailScreen> {
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: Text('Смена Email-a'),
|
||||
title: const Text('Смена Email-a'),
|
||||
),
|
||||
body: Center(
|
||||
body: const Center(
|
||||
child: Text('Coming soon...'),
|
||||
),
|
||||
);
|
||||
|
||||
@@ -18,9 +18,9 @@ class _ChangePasswordScreenState extends State<ChangePasswordScreen> {
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: Text('Смена пароля'),
|
||||
title: const Text('Смена пароля'),
|
||||
),
|
||||
body: Center(
|
||||
body: const Center(
|
||||
child: Text('Coming soon...'),
|
||||
),
|
||||
);
|
||||
|
||||
@@ -33,13 +33,13 @@ class _GeneralInfoScreenState extends State<GeneralInfoScreen> {
|
||||
late SelectionPopupModel isPublicProfile;
|
||||
|
||||
final List<SelectionPopupModel> genderSelectionPopupList = [
|
||||
SelectionPopupModel(id: 0, title: 'Женский', value: 'female'),
|
||||
SelectionPopupModel(id: 1, title: 'Мужской', value: 'male'),
|
||||
const SelectionPopupModel(id: 0, title: 'Женский', value: 'female'),
|
||||
const SelectionPopupModel(id: 1, title: 'Мужской', value: 'male'),
|
||||
];
|
||||
|
||||
final List<SelectionPopupModel> isPublicProfileSelectionPopupList = [
|
||||
SelectionPopupModel(id: 0, title: 'Только зарегистрированным', value: false),
|
||||
SelectionPopupModel(id: 1, title: 'Всем', value: true),
|
||||
const SelectionPopupModel(id: 0, title: 'Только зарегистрированным', value: false),
|
||||
const SelectionPopupModel(id: 1, title: 'Всем', value: true),
|
||||
];
|
||||
|
||||
@override
|
||||
@@ -63,49 +63,49 @@ class _GeneralInfoScreenState extends State<GeneralInfoScreen> {
|
||||
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: Text('Общая информация'),
|
||||
title: const Text('Общая информация'),
|
||||
),
|
||||
bottomSheet: _saveButton(),
|
||||
body: SingleChildScrollView(
|
||||
physics: const BouncingScrollPhysics(),
|
||||
padding: EdgeInsets.all(16) + EdgeInsets.only(bottom: 64),
|
||||
padding: const EdgeInsets.all(16) + const EdgeInsets.only(bottom: 64),
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Text(s.first_name),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
controller: firstNameController,
|
||||
hintText: 'Введите имя',
|
||||
onChanged: (newValue) {},
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
const SizedBox(height: 16),
|
||||
Text(s.last_name),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
controller: lastNameController,
|
||||
hintText: 'Введите фамилию',
|
||||
onChanged: (newValue) {},
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
const SizedBox(height: 16),
|
||||
Text(s.date_of_birth),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
ListTile(
|
||||
onTap: onTapCalendar(context),
|
||||
trailing: Icon(
|
||||
Icons.keyboard_arrow_down_rounded,
|
||||
color: Colors.grey.shade700,
|
||||
),
|
||||
contentPadding: EdgeInsets.symmetric(horizontal: 12),
|
||||
contentPadding: const EdgeInsets.symmetric(horizontal: 12),
|
||||
title: Text(selectedDate.format('dd MMMM yyyy', 'ru')),
|
||||
tileColor: Color(0xFFF6F6F6),
|
||||
tileColor: const Color(0xFFF6F6F6),
|
||||
shape: RoundedRectangleBorder(
|
||||
borderRadius: BorderRadius.circular(20),
|
||||
),
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
Text('Пол'),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 16),
|
||||
const Text('Пол'),
|
||||
const SizedBox(height: 4),
|
||||
CustomDropDown(
|
||||
items: genderSelectionPopupList,
|
||||
value: gender,
|
||||
@@ -115,27 +115,27 @@ class _GeneralInfoScreenState extends State<GeneralInfoScreen> {
|
||||
});
|
||||
},
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
Text('Страна'),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 16),
|
||||
const Text('Страна'),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
controller: countryController,
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
Text('Город'),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 16),
|
||||
const Text('Город'),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
controller: cityController,
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
Text('Предпочтительный язык общения'),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 16),
|
||||
const Text('Предпочтительный язык общения'),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
controller: languageController,
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
Text('Показывать анкету'),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 16),
|
||||
const Text('Показывать анкету'),
|
||||
const SizedBox(height: 4),
|
||||
CustomDropDown(
|
||||
items: isPublicProfileSelectionPopupList,
|
||||
value: isPublicProfile,
|
||||
@@ -216,7 +216,7 @@ class _GeneralInfoScreenState extends State<GeneralInfoScreen> {
|
||||
borderRadius: BorderRadius.circular(20),
|
||||
color: appTheme.blueA400,
|
||||
),
|
||||
child: Center(
|
||||
child: const Center(
|
||||
child: Text(
|
||||
'Сохранить',
|
||||
style: TextStyle(
|
||||
|
||||
@@ -43,16 +43,16 @@ class _OtherInfoScreenState extends State<OtherInfoScreen> {
|
||||
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: Text('Прочая информаиця'),
|
||||
title: const Text('Прочая информаиця'),
|
||||
),
|
||||
bottomSheet: _saveButton(),
|
||||
body: SingleChildScrollView(
|
||||
padding: EdgeInsets.all(16) + EdgeInsets.only(bottom: 64),
|
||||
padding: const EdgeInsets.all(16) + const EdgeInsets.only(bottom: 64),
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Text(s.allergies_presence),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
controller: aboutAllergyController,
|
||||
hintText: 'Например: орехи, мёд и т.д.',
|
||||
@@ -62,9 +62,9 @@ class _OtherInfoScreenState extends State<OtherInfoScreen> {
|
||||
maxLength: 250,
|
||||
onChanged: (newValue) {},
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
const SizedBox(height: 16),
|
||||
Text(s.do_you_take_pills),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
controller: aboutTakingPillsController,
|
||||
hintText: s.enter_information,
|
||||
@@ -74,9 +74,9 @@ class _OtherInfoScreenState extends State<OtherInfoScreen> {
|
||||
maxLines: 8,
|
||||
onChanged: (newValue) {},
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
const SizedBox(height: 16),
|
||||
Text(s.your_favorite_sports),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
controller: aboutSportHobbiesController,
|
||||
hintText:
|
||||
@@ -86,9 +86,9 @@ class _OtherInfoScreenState extends State<OtherInfoScreen> {
|
||||
maxLength: 250,
|
||||
onChanged: (newValue) {},
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
const SizedBox(height: 16),
|
||||
Text(s.favorite_foods),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
controller: favoriteFoodsController,
|
||||
hintText: s.enter_information,
|
||||
@@ -97,9 +97,9 @@ class _OtherInfoScreenState extends State<OtherInfoScreen> {
|
||||
maxLength: 250,
|
||||
onChanged: (newValue) {},
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
const SizedBox(height: 16),
|
||||
Text(s.unfavorite_foods),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
controller: unFavouriteFoodsController,
|
||||
hintText: s.enter_information,
|
||||
@@ -108,14 +108,14 @@ class _OtherInfoScreenState extends State<OtherInfoScreen> {
|
||||
maxLength: 250,
|
||||
onChanged: (newValue) {},
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
Text(
|
||||
const SizedBox(height: 16),
|
||||
const Text(
|
||||
'Дополнительная информация',
|
||||
maxLines: 2,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
textAlign: TextAlign.start,
|
||||
),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
controller: additionalInfoController,
|
||||
maxLength: 250,
|
||||
@@ -152,7 +152,7 @@ class _OtherInfoScreenState extends State<OtherInfoScreen> {
|
||||
borderRadius: BorderRadius.circular(20),
|
||||
color: appTheme.blueA400,
|
||||
),
|
||||
child: Center(
|
||||
child: const Center(
|
||||
child: Text(
|
||||
'Сохранить',
|
||||
style: TextStyle(
|
||||
|
||||
@@ -47,7 +47,7 @@ class _PhysicalActivityScreenState extends State<PhysicalActivityScreen> {
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: Text('Физическая нагрузка'),
|
||||
title: const Text('Физическая нагрузка'),
|
||||
),
|
||||
bottomSheet: _saveButton(),
|
||||
body: SingleChildScrollView(
|
||||
@@ -56,7 +56,7 @@ class _PhysicalActivityScreenState extends State<PhysicalActivityScreen> {
|
||||
child: Column(
|
||||
children: [
|
||||
RadioListTile<PhysicalActivity>(
|
||||
contentPadding: EdgeInsets.only(left: 8, right: 16),
|
||||
contentPadding: const EdgeInsets.only(left: 8, right: 16),
|
||||
title: const Text('1,2 — минимальный (сидячая работа, отсутствие физических нагрузок);'),
|
||||
value: PhysicalActivity.minimum,
|
||||
groupValue: _physicalActivity,
|
||||
@@ -67,7 +67,7 @@ class _PhysicalActivityScreenState extends State<PhysicalActivityScreen> {
|
||||
},
|
||||
),
|
||||
RadioListTile<PhysicalActivity>(
|
||||
contentPadding: EdgeInsets.only(left: 8, right: 16),
|
||||
contentPadding: const EdgeInsets.only(left: 8, right: 16),
|
||||
title: const Text('1,375 — низкий (тренировки не менее 20 мин 1–3 раза в неделю);'),
|
||||
value: PhysicalActivity.low,
|
||||
groupValue: _physicalActivity,
|
||||
@@ -78,7 +78,7 @@ class _PhysicalActivityScreenState extends State<PhysicalActivityScreen> {
|
||||
},
|
||||
),
|
||||
RadioListTile<PhysicalActivity>(
|
||||
contentPadding: EdgeInsets.only(left: 8, right: 16),
|
||||
contentPadding: const EdgeInsets.only(left: 8, right: 16),
|
||||
title: const Text('1,55 — умеренный (тренировки 30–60 мин 3–4 раза в неделю);'),
|
||||
value: PhysicalActivity.medium,
|
||||
groupValue: _physicalActivity,
|
||||
@@ -89,7 +89,7 @@ class _PhysicalActivityScreenState extends State<PhysicalActivityScreen> {
|
||||
},
|
||||
),
|
||||
RadioListTile<PhysicalActivity>(
|
||||
contentPadding: EdgeInsets.only(left: 8, right: 16),
|
||||
contentPadding: const EdgeInsets.only(left: 8, right: 16),
|
||||
title: const Text('1,7 — высокий (тренировки 30–60 мин 5–7 раза в неделю; тяжёлая физическая работа);'),
|
||||
value: PhysicalActivity.high,
|
||||
groupValue: _physicalActivity,
|
||||
@@ -100,7 +100,7 @@ class _PhysicalActivityScreenState extends State<PhysicalActivityScreen> {
|
||||
},
|
||||
),
|
||||
RadioListTile<PhysicalActivity>(
|
||||
contentPadding: EdgeInsets.only(left: 8, right: 16),
|
||||
contentPadding: const EdgeInsets.only(left: 8, right: 16),
|
||||
title: const Text('1,9 — экстремальный (несколько интенсивных тренировок в день'),
|
||||
value: PhysicalActivity.extreme,
|
||||
groupValue: _physicalActivity,
|
||||
@@ -154,7 +154,7 @@ class _PhysicalActivityScreenState extends State<PhysicalActivityScreen> {
|
||||
borderRadius: BorderRadius.circular(20),
|
||||
color: appTheme.blueA400,
|
||||
),
|
||||
child: Center(
|
||||
child: const Center(
|
||||
child: Text(
|
||||
'Сохранить',
|
||||
style: TextStyle(
|
||||
|
||||
@@ -43,51 +43,51 @@ class _PhysicalFormScreenState extends State<PhysicalFormScreen> {
|
||||
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: Text('Физическая форма'),
|
||||
title: const Text('Физическая форма'),
|
||||
),
|
||||
bottomSheet: _saveButton(),
|
||||
body: SingleChildScrollView(
|
||||
physics: const BouncingScrollPhysics(),
|
||||
padding: EdgeInsets.all(16) + EdgeInsets.only(bottom: 64),
|
||||
padding: const EdgeInsets.all(16) + const EdgeInsets.only(bottom: 64),
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Text(s.chest_circumference),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
inputFormatters: [digitsOnly],
|
||||
controller: chestCircumferenceController,
|
||||
hintText: 'см',
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
const SizedBox(height: 16),
|
||||
Text(s.waist_circumference),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
inputFormatters: [digitsOnly],
|
||||
controller: waistCircumferenceController,
|
||||
hintText: 'см',
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
const SizedBox(height: 16),
|
||||
Text(s.hip_circumference),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
inputFormatters: [digitsOnly],
|
||||
controller: hipCircumferenceController,
|
||||
hintText: 'см',
|
||||
textInputAction: TextInputAction.done,
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
Text('Рост'),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 16),
|
||||
const Text('Рост'),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
inputFormatters: [digitsOnly],
|
||||
controller: heightController,
|
||||
hintText: 'см',
|
||||
textInputAction: TextInputAction.done,
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
Text('Вес'),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 16),
|
||||
const Text('Вес'),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
inputFormatters: [digitsOnly],
|
||||
controller: weightController,
|
||||
@@ -122,7 +122,7 @@ class _PhysicalFormScreenState extends State<PhysicalFormScreen> {
|
||||
borderRadius: BorderRadius.circular(20),
|
||||
color: appTheme.blueA400,
|
||||
),
|
||||
child: Center(
|
||||
child: const Center(
|
||||
child: Text(
|
||||
'Сохранить',
|
||||
style: TextStyle(
|
||||
|
||||
@@ -38,8 +38,8 @@ class _PressureScreenState extends State<PressureScreen> {
|
||||
}
|
||||
|
||||
final List<SelectionPopupModel> selectionPopupList = [
|
||||
SelectionPopupModel(id: 0, title: 'Нет', value: false),
|
||||
SelectionPopupModel(id: 1, title: 'Да', value: true),
|
||||
const SelectionPopupModel(id: 0, title: 'Нет', value: false),
|
||||
const SelectionPopupModel(id: 1, title: 'Да', value: true),
|
||||
];
|
||||
|
||||
@override
|
||||
@@ -48,35 +48,35 @@ class _PressureScreenState extends State<PressureScreen> {
|
||||
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: Text('Давление'),
|
||||
title: const Text('Давление'),
|
||||
),
|
||||
bottomSheet: _saveButton(),
|
||||
body: SingleChildScrollView(
|
||||
physics: const BouncingScrollPhysics(),
|
||||
padding: EdgeInsets.all(16) + EdgeInsets.only(bottom: 64),
|
||||
padding: const EdgeInsets.all(16) + const EdgeInsets.only(bottom: 64),
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Text(s.up_pressure),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
controller: bloodPressureUpController,
|
||||
inputFormatters: [digitsOnly],
|
||||
hintText: "90",
|
||||
onChanged: (newValue) {},
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
const SizedBox(height: 16),
|
||||
Text(s.down_pressure),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomTextFormField(
|
||||
controller: bloodPressureDownController,
|
||||
inputFormatters: [digitsOnly],
|
||||
hintText: '90',
|
||||
onChanged: (newValue) {},
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
const SizedBox(height: 16),
|
||||
Text(s.do_you_have_hypotension_tendency),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomDropDown(
|
||||
items: selectionPopupList,
|
||||
value: hypo,
|
||||
@@ -87,9 +87,9 @@ class _PressureScreenState extends State<PressureScreen> {
|
||||
});
|
||||
},
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
const SizedBox(height: 16),
|
||||
Text(s.do_you_have_hypertension_tendency),
|
||||
SizedBox(height: 4),
|
||||
const SizedBox(height: 4),
|
||||
CustomDropDown(
|
||||
items: selectionPopupList,
|
||||
value: hyper,
|
||||
@@ -127,7 +127,7 @@ class _PressureScreenState extends State<PressureScreen> {
|
||||
borderRadius: BorderRadius.circular(20),
|
||||
color: appTheme.blueA400,
|
||||
),
|
||||
child: Center(
|
||||
child: const Center(
|
||||
child: Text(
|
||||
'Сохранить',
|
||||
style: TextStyle(
|
||||
|
||||
@@ -44,10 +44,10 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
if (state is SettingsStateLoaded) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: Text('Настройки'),
|
||||
title: const Text('Настройки'),
|
||||
),
|
||||
body: SingleChildScrollView(
|
||||
padding: EdgeInsets.symmetric(vertical: 16),
|
||||
padding: const EdgeInsets.symmetric(vertical: 16),
|
||||
physics: const BouncingScrollPhysics(),
|
||||
child: Column(
|
||||
children: [
|
||||
@@ -71,16 +71,16 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
if (state is SettingsStateError) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: Text('Настройки'),
|
||||
title: const Text('Настройки'),
|
||||
),
|
||||
body: DataErrorWidget(onReload: () => settingsCubit.init()),
|
||||
);
|
||||
}
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: Text('Настройки'),
|
||||
title: const Text('Настройки'),
|
||||
),
|
||||
body: Loader(),
|
||||
body: const Loader(),
|
||||
);
|
||||
},
|
||||
),
|
||||
@@ -91,8 +91,8 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
return Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16),
|
||||
const Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16),
|
||||
child: Text(
|
||||
'Дополнительаная информация',
|
||||
style: TextStyle(
|
||||
@@ -194,8 +194,8 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
return Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16),
|
||||
const Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16),
|
||||
child: Text(
|
||||
'Уведомления',
|
||||
style: TextStyle(
|
||||
@@ -206,7 +206,7 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
),
|
||||
),
|
||||
_tile(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16),
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16),
|
||||
onTap: () {
|
||||
setState(() {
|
||||
updatesNotificationsSwitchState = !updatesNotificationsSwitchState;
|
||||
@@ -235,7 +235,7 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
),
|
||||
_divider(context),
|
||||
_tile(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16),
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16),
|
||||
onTap: () {
|
||||
setState(() {
|
||||
fillDiaryNotificationsSwitchState = !fillDiaryNotificationsSwitchState;
|
||||
@@ -264,7 +264,7 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
),
|
||||
_divider(context),
|
||||
_tile(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16),
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16),
|
||||
onTap: () {
|
||||
setState(() {
|
||||
moodSwitchState = !moodSwitchState;
|
||||
@@ -293,7 +293,7 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
),
|
||||
_divider(context),
|
||||
_tile(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16),
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16),
|
||||
onTap: () {
|
||||
setState(() {
|
||||
bedTimeSwitchState = !bedTimeSwitchState;
|
||||
@@ -328,8 +328,8 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
return Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16),
|
||||
const Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16),
|
||||
child: Text(
|
||||
'О Eatvio',
|
||||
style: TextStyle(
|
||||
@@ -341,12 +341,12 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
),
|
||||
_tile(
|
||||
title: 'О компании',
|
||||
onTap: () async => await launchUrl(Uri.parse(baseUrl + '/ru/company-details')),
|
||||
onTap: () async => await launchUrl(Uri.parse('$baseUrl/ru/company-details')),
|
||||
),
|
||||
_divider(context),
|
||||
_tile(
|
||||
title: 'Пользовательское соглашение',
|
||||
onTap: () async => await launchUrl(Uri.parse(baseUrl + '/oferta_bs.pdf')),
|
||||
onTap: () async => await launchUrl(Uri.parse('$baseUrl/oferta_bs.pdf')),
|
||||
),
|
||||
],
|
||||
);
|
||||
@@ -354,7 +354,7 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
|
||||
_becomeConsultantButton(SettingsStateLoaded state) {
|
||||
return Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16),
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16),
|
||||
child: InkWell(
|
||||
onTap: () => GoRouter.of(context).pushNamed('becomeConsultantScreen'),
|
||||
borderRadius: BorderRadius.circular(20),
|
||||
@@ -365,7 +365,7 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
borderRadius: BorderRadius.circular(20),
|
||||
color: appTheme.blueA400,
|
||||
),
|
||||
child: Center(
|
||||
child: const Center(
|
||||
child: Text(
|
||||
'Стать консультантом',
|
||||
style: TextStyle(
|
||||
@@ -382,7 +382,7 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
|
||||
_deleteAccountButton(SettingsStateLoaded state) {
|
||||
return Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16),
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16),
|
||||
child: InkWell(
|
||||
onTap: () {},
|
||||
borderRadius: BorderRadius.circular(20),
|
||||
@@ -391,9 +391,9 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
width: MediaQuery.of(context).size.width - 16,
|
||||
decoration: BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(20),
|
||||
color: Color(0xFFEAEAEA),
|
||||
color: const Color(0xFFEAEAEA),
|
||||
),
|
||||
child: Center(
|
||||
child: const Center(
|
||||
child: Text(
|
||||
'Удалить аккаунт',
|
||||
style: TextStyle(
|
||||
@@ -419,14 +419,14 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
onTap: onTap,
|
||||
title: Text(
|
||||
title,
|
||||
style: TextStyle(
|
||||
style: const TextStyle(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
height: 1,
|
||||
),
|
||||
),
|
||||
trailing: trailing ??
|
||||
Icon(
|
||||
const Icon(
|
||||
Icons.arrow_forward_ios_rounded,
|
||||
size: 12,
|
||||
color: Colors.black38,
|
||||
|
||||
Reference in New Issue
Block a user