[auth] fix content not show when font size set to large from device settings

This commit is contained in:
Aman Raj Singh Mourya 2025-01-13 16:58:41 +05:30
parent 1190b570ac
commit c79400c6d5
4 changed files with 34 additions and 7 deletions

View File

@ -496,7 +496,7 @@ ElevatedButtonThemeData buildElevatedButtonThemeData({
fontFamily: 'Inter-SemiBold', fontFamily: 'Inter-SemiBold',
fontSize: 18, fontSize: 18,
), ),
padding: const EdgeInsets.symmetric(vertical: 18), padding: const EdgeInsets.symmetric(vertical: 8),
shape: const RoundedRectangleBorder( shape: const RoundedRectangleBorder(
borderRadius: BorderRadius.all(Radius.circular(4)), borderRadius: BorderRadius.all(Radius.circular(4)),
), ),

View File

@ -90,8 +90,10 @@ class _OnboardingPageState extends State<OnboardingPage> {
child: SingleChildScrollView( child: SingleChildScrollView(
child: Center( child: Center(
child: ConstrainedBox( child: ConstrainedBox(
constraints: constraints: BoxConstraints(
const BoxConstraints.tightFor(height: 800, width: 450), minHeight: MediaQuery.of(context).size.height,
maxWidth: 450,
),
child: Padding( child: Padding(
padding: const EdgeInsets.symmetric( padding: const EdgeInsets.symmetric(
vertical: 40.0, vertical: 40.0,
@ -197,6 +199,7 @@ class _OnboardingPageState extends State<OnboardingPage> {
child: Center( child: Center(
child: Text( child: Text(
l10n.useOffline, l10n.useOffline,
textAlign: TextAlign.center,
style: body.copyWith( style: body.copyWith(
color: Theme.of(context) color: Theme.of(context)
.colorScheme .colorScheme

View File

@ -318,6 +318,9 @@ class _SetupEnterSecretKeyPageState extends State<SetupEnterSecretKeyPage> {
SizedBox( SizedBox(
width: 400, width: 400,
child: OutlinedButton( child: OutlinedButton(
style: OutlinedButton.styleFrom(
padding: const EdgeInsets.symmetric(vertical: 8),
),
onPressed: () async { onPressed: () async {
if ((_accountController.text.trim().isEmpty && if ((_accountController.text.trim().isEmpty &&
_issuerController.text.trim().isEmpty) || _issuerController.text.trim().isEmpty) ||

View File

@ -25,7 +25,10 @@ class HomeEmptyStateWidget extends StatelessWidget {
return SingleChildScrollView( return SingleChildScrollView(
child: Center( child: Center(
child: ConstrainedBox( child: ConstrainedBox(
constraints: const BoxConstraints.tightFor(height: 800, width: 450), constraints: BoxConstraints(
minHeight: MediaQuery.of(context).size.height,
minWidth: 450,
),
child: Padding( child: Padding(
padding: const EdgeInsets.symmetric(vertical: 40.0, horizontal: 40), padding: const EdgeInsets.symmetric(vertical: 40.0, horizontal: 40),
child: Column( child: Column(
@ -49,7 +52,13 @@ class HomeEmptyStateWidget extends StatelessWidget {
width: 400, width: 400,
child: OutlinedButton( child: OutlinedButton(
onPressed: onScanTap, onPressed: onScanTap,
child: Text(l10n.importScanQrCode), style: OutlinedButton.styleFrom(
padding: const EdgeInsets.symmetric(vertical: 8),
),
child: Text(
l10n.importScanQrCode,
textAlign: TextAlign.center,
),
), ),
), ),
const SizedBox(height: 18), const SizedBox(height: 18),
@ -60,7 +69,13 @@ class HomeEmptyStateWidget extends StatelessWidget {
width: 400, width: 400,
child: OutlinedButton( child: OutlinedButton(
onPressed: onImportFromGallery, onPressed: onImportFromGallery,
child: const Text("Import from gallery"), style: OutlinedButton.styleFrom(
padding: const EdgeInsets.symmetric(vertical: 8),
),
child: const Text(
"Import from gallery",
textAlign: TextAlign.center,
),
), ),
), ),
const SizedBox(height: 18), const SizedBox(height: 18),
@ -68,7 +83,13 @@ class HomeEmptyStateWidget extends StatelessWidget {
width: 400, width: 400,
child: OutlinedButton( child: OutlinedButton(
onPressed: onManuallySetupTap, onPressed: onManuallySetupTap,
child: Text(l10n.importEnterSetupKey), style: OutlinedButton.styleFrom(
padding: const EdgeInsets.symmetric(vertical: 8),
),
child: Text(
l10n.importEnterSetupKey,
textAlign: TextAlign.center,
),
), ),
), ),
const SizedBox(height: 54), const SizedBox(height: 54),