-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow privacy disclosure to scroll on small screens, closes getlanter…
…n/engineering#474
- Loading branch information
Showing
1 changed file
with
29 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,44 @@ | ||
import 'package:lantern/common/common.dart'; | ||
|
||
class PrivacyDisclosure extends StatelessWidget { | ||
const PrivacyDisclosure({super.key}); | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return FullScreenDialog( | ||
widget: Padding( | ||
padding: EdgeInsetsDirectional.only( | ||
start: 33, end: 33), | ||
padding: const EdgeInsetsDirectional.only(start: 33, end: 33), | ||
child: SingleChildScrollView( | ||
child: Column( | ||
mainAxisAlignment: MainAxisAlignment.spaceAround, | ||
crossAxisAlignment: CrossAxisAlignment.center, | ||
children: [ | ||
Container( | ||
margin: const EdgeInsetsDirectional.only(top: 38), | ||
mainAxisAlignment: MainAxisAlignment.spaceAround, | ||
crossAxisAlignment: CrossAxisAlignment.center, | ||
children: [ | ||
Container( | ||
margin: const EdgeInsetsDirectional.only(top: 38), | ||
child: CText( | ||
'privacy_disclosure_title'.i18n, | ||
style: tsSubtitle1.copiedWith(fontSize: 24.0), | ||
)), | ||
Padding( | ||
padding: EdgeInsetsDirectional.only(top: 24, bottom: 24), | ||
child: CText( | ||
'privacy_disclosure_body'.i18n, | ||
style: tsBody2.copiedWith(fontSize: 14.0, lineHeight: 24.0), | ||
), | ||
), | ||
const Spacer(), | ||
Container( | ||
margin: const EdgeInsetsDirectional.only(bottom: 38), | ||
child: Button( | ||
width: 200, | ||
text: 'privacy_disclosure_accept'.i18n, | ||
onPressed: () async => await sessionModel.acceptTerms(), | ||
)), | ||
])), | ||
), | ||
Padding( | ||
padding: const EdgeInsetsDirectional.only(top: 24, bottom: 24), | ||
child: CText( | ||
'privacy_disclosure_body'.i18n, | ||
style: tsBody2.copiedWith(fontSize: 14.0, lineHeight: 24.0), | ||
), | ||
), | ||
Container( | ||
margin: const EdgeInsetsDirectional.only(bottom: 38), | ||
child: Button( | ||
width: 200, | ||
text: 'privacy_disclosure_accept'.i18n, | ||
onPressed: () async => await sessionModel.acceptTerms(), | ||
), | ||
), | ||
], | ||
), | ||
), | ||
), | ||
); | ||
} | ||
} |