selfprivacy.org.app/lib/ui/pages/onboarding/views/onboarding_second_view.dart
aliaksei tratseuski dd81053f42 refactor(UI): Rewrite onboarding page
rewrote OnboardingPage:
* decomposed into separate widgets
* now content stays centered on wide screens (set so width won't expand further than 480px)
* pageController is now properly disposed
* added some more code changes to
    * main (error widget builder)
    * brand_header (centerTitle instead of empty actions list)
    * console_page (listener callback fix, used gaps instead of SizedBox'es, added keys to list items)
    * service_page (just cleaner build method)
	* removed some dead code

Co-authored-by: Aliaksei Tratseuski <aliaksei.tratseuski@gmail.com>
Reviewed-on: https://git.selfprivacy.org/SelfPrivacy/selfprivacy.org.app/pulls/444
Co-authored-by: aliaksei tratseuski <misterfourtytwo@noreply.git.selfprivacy.org>
Co-committed-by: aliaksei tratseuski <misterfourtytwo@noreply.git.selfprivacy.org>
2024-02-08 13:59:52 +02:00

61 lines
1.8 KiB
Dart

import 'package:easy_localization/easy_localization.dart';
import 'package:flutter/material.dart';
import 'package:gap/gap.dart';
import 'package:selfprivacy/ui/pages/onboarding/views/onboarding_view.dart';
class OnboardingSecondView extends StatelessWidget {
const OnboardingSecondView({
required this.onProceed,
super.key,
});
final VoidCallback onProceed;
@override
Widget build(final BuildContext context) => OnboardingView(
buttonTitle: 'basis.got_it',
onProceed: onProceed,
children: [
Text(
'onboarding.page2_title'.tr(),
style: Theme.of(context).textTheme.headlineSmall,
),
const Gap(16),
Text(
'onboarding.page2_text'.tr(),
style: Theme.of(context).textTheme.bodyMedium,
),
const Gap(16),
Text(
'onboarding.page2_server_provider_title'.tr(),
style: Theme.of(context).textTheme.titleLarge,
),
const Gap(16),
Text(
'onboarding.page2_server_provider_text'.tr(),
style: Theme.of(context).textTheme.bodyMedium,
),
const Gap(16),
Text(
'onboarding.page2_dns_provider_title'.tr(),
style: Theme.of(context).textTheme.titleLarge,
),
const Gap(16),
Text(
'onboarding.page2_dns_provider_text'.tr(),
style: Theme.of(context).textTheme.bodyMedium,
),
const Gap(16),
Text(
'onboarding.page2_backup_provider_title'.tr(),
style: Theme.of(context).textTheme.titleLarge,
),
const Gap(16),
Text(
'onboarding.page2_backup_provider_text'.tr(),
style: Theme.of(context).textTheme.bodyMedium,
),
],
);
}