From 923d76cf699b863d29590a090514e62e58205dc6 Mon Sep 17 00:00:00 2001 From: 21pages Date: Tue, 15 Aug 2023 10:11:04 +0800 Subject: [PATCH] opt add ab id and delete file dialog ui Signed-off-by: 21pages --- flutter/lib/common/widgets/address_book.dart | 10 ++++++---- flutter/lib/models/file_model.dart | 6 ++++-- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/flutter/lib/common/widgets/address_book.dart b/flutter/lib/common/widgets/address_book.dart index fd4694a8b..9530e851d 100644 --- a/flutter/lib/common/widgets/address_book.dart +++ b/flutter/lib/common/widgets/address_book.dart @@ -346,6 +346,7 @@ class _AddressBookState extends State { close(); } + double marginBottom = 4; return CustomAlertDialog( title: Text(translate("Add ID")), content: Column( @@ -367,7 +368,7 @@ class _AddressBookState extends State { ), ], ), - ), + ).marginOnly(bottom: marginBottom), TextField( controller: idController, inputFormatters: [IDTextInputFormatter()], @@ -379,7 +380,7 @@ class _AddressBookState extends State { translate('Alias'), style: style, ), - ).marginOnly(top: 8, bottom: 2), + ).marginOnly(top: 8, bottom: marginBottom), TextField( controller: aliasController, ), @@ -389,8 +390,9 @@ class _AddressBookState extends State { translate('Tags'), style: style, ), - ).marginOnly(top: 8), - Container( + ).marginOnly(top: 8, bottom: marginBottom), + Align( + alignment: Alignment.centerLeft, child: Wrap( children: tags .map((e) => AddressBookTag( diff --git a/flutter/lib/models/file_model.dart b/flutter/lib/models/file_model.dart index 95a4cad0c..35c0d020d 100644 --- a/flutter/lib/models/file_model.dart +++ b/flutter/lib/models/file_model.dart @@ -556,8 +556,10 @@ class FileController { mainAxisAlignment: MainAxisAlignment.center, children: [ const Icon(Icons.warning_rounded, color: Colors.red), - Text(title).paddingOnly( - left: 10, + Expanded( + child: Text(title).paddingOnly( + left: 10, + ), ), ], ),