From fa641fa181cf55d816d902b94591fef4e99b83ed Mon Sep 17 00:00:00 2001 From: Hari-egov Date: Fri, 10 May 2024 12:45:21 +0530 Subject: [PATCH] WhatsApp Share Logo Alignment Issue Fixed https://digit-discuss.atlassian.net/browse/ISTE-25 --- .../household_register.dart | 36 ++++++++++++++----- 1 file changed, 27 insertions(+), 9 deletions(-) diff --git a/frontend/mgramseva/lib/screeens/household_register/household_register.dart b/frontend/mgramseva/lib/screeens/household_register/household_register.dart index 36d7d699f..f8fe27fb7 100644 --- a/frontend/mgramseva/lib/screeens/household_register/household_register.dart +++ b/frontend/mgramseva/lib/screeens/household_register/household_register.dart @@ -1,4 +1,6 @@ +import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; +import 'package:flutter/widgets.dart'; import 'package:flutter_focus_watcher/flutter_focus_watcher.dart'; import 'package:mgramseva/components/household_register/household_card.dart'; import 'package:mgramseva/providers/household_register_provider.dart'; @@ -44,6 +46,7 @@ class _HouseholdRegister extends State @override Widget build(BuildContext context) { + Size size = MediaQuery.of(context).size; var householdRegisterProvider = Provider.of(context, listen: false); @@ -76,14 +79,25 @@ class _HouseholdRegister extends State child: CustomScrollView(slivers: [ SliverList( delegate: SliverChildListDelegate([ - Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - HomeBack(), - Row( - mainAxisAlignment: MainAxisAlignment.end, - children: [_buildDownload, _buildShare]) - ], + SizedBox( + width: size.width, + child: Row( + children: [ + HomeBack(), + Expanded( + child: Row( + mainAxisAlignment: MainAxisAlignment.end, + children: [ + Expanded( + child: Align( + alignment: Alignment.centerRight, + child: _buildDownload)), + _buildShare + ], + ), + ) + ], + ), ), Container(key: key, child: HouseholdCard()), ])), @@ -130,7 +144,11 @@ class _HouseholdRegister extends State onPressed: () => showDownloadList(Constants.DOWNLOAD_OPTIONS, context), icon: Icon(Icons.download_sharp), label: Text( - ApplicationLocalizations.of(context).translate(i18.common.DOWNLOAD))); + ApplicationLocalizations.of(context).translate(i18.common.DOWNLOAD), + maxLines: 1, + softWrap: false, + overflow: TextOverflow.ellipsis, + )); } showDownloadList(List result, BuildContext context) {