Replace empty Contains with SizedBox.shrink
This commit is contained in:
parent
ce63fc6768
commit
e23c633511
9 changed files with 11 additions and 11 deletions
|
@ -101,7 +101,7 @@ class _PasswordEntryPageState extends State<PasswordEntryPage> {
|
|||
resizeToAvoidBottomInset: isKeypadOpen,
|
||||
appBar: AppBar(
|
||||
leading: widget.mode == PasswordEntryMode.reset
|
||||
? Container()
|
||||
? const SizedBox.shrink()
|
||||
: IconButton(
|
||||
icon: const Icon(Icons.arrow_back),
|
||||
color: Theme.of(context).iconTheme.color,
|
||||
|
@ -142,7 +142,7 @@ class _PasswordEntryPageState extends State<PasswordEntryPage> {
|
|||
passwordStrengthColor = Colors.orangeAccent;
|
||||
}
|
||||
if (_volatilePassword != null) {
|
||||
return Container();
|
||||
return const SizedBox.shrink();
|
||||
}
|
||||
return Column(
|
||||
children: [
|
||||
|
|
|
@ -143,7 +143,7 @@ class SlideFadeTransition extends StatelessWidget {
|
|||
return AnimatedBuilder(
|
||||
animation: animation!,
|
||||
builder: (context, child) =>
|
||||
animation!.value == 0.0 ? Container() : child!,
|
||||
animation!.value == 0.0 ? const SizedBox.shrink() : child!,
|
||||
child: SlideTransition(
|
||||
position: Tween(
|
||||
begin: const Offset(0.3, 0.0),
|
||||
|
|
|
@ -63,7 +63,7 @@ class _PaymentWebPageState extends State<PaymentWebPage> {
|
|||
children: <Widget>[
|
||||
(progress != 1.0)
|
||||
? LinearProgressIndicator(value: progress)
|
||||
: Container(),
|
||||
: const SizedBox.shrink(),
|
||||
Expanded(
|
||||
child: InAppWebView(
|
||||
initialUrlRequest: URLRequest(url: initPaymentUrl),
|
||||
|
|
|
@ -46,7 +46,7 @@ class _AppVersionWidgetState extends State<AppVersionWidget> {
|
|||
),
|
||||
);
|
||||
}
|
||||
return Container();
|
||||
return const SizedBox.shrink();
|
||||
},
|
||||
),
|
||||
);
|
||||
|
|
|
@ -109,7 +109,7 @@ class _BackupFolderSelectionPageState extends State<BackupFolderSelectionPage> {
|
|||
padding: EdgeInsets.all(10),
|
||||
),
|
||||
_deviceCollections == null
|
||||
? Container()
|
||||
? const SizedBox.shrink()
|
||||
: GestureDetector(
|
||||
behavior: HitTestBehavior.translucent,
|
||||
child: Padding(
|
||||
|
|
|
@ -90,7 +90,7 @@ class IncomingAlbumItem extends StatelessWidget {
|
|||
),
|
||||
);
|
||||
} else {
|
||||
return Container();
|
||||
return const SizedBox.shrink();
|
||||
}
|
||||
},
|
||||
),
|
||||
|
|
|
@ -80,11 +80,11 @@ class OutgoingAlbumItem extends StatelessWidget {
|
|||
color: warning500,
|
||||
)
|
||||
: const Icon(Icons.link))
|
||||
: Container(),
|
||||
: const SizedBox.shrink(),
|
||||
],
|
||||
),
|
||||
shareesName.isEmpty
|
||||
? Container()
|
||||
? const SizedBox.shrink()
|
||||
: Padding(
|
||||
padding: const EdgeInsets.fromLTRB(0, 4, 0, 0),
|
||||
child: Text(
|
||||
|
|
|
@ -309,7 +309,7 @@ class _DeduplicatePageState extends State<DeduplicatePage> {
|
|||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
crossAxisAlignment: CrossAxisAlignment.end,
|
||||
children: [
|
||||
Container(),
|
||||
const SizedBox.shrink(),
|
||||
PopupMenuButton(
|
||||
initialValue: sortKey.index,
|
||||
child: Padding(
|
||||
|
|
|
@ -111,7 +111,7 @@ class TrashPage extends StatelessWidget {
|
|||
),
|
||||
);
|
||||
} else {
|
||||
return Container();
|
||||
return const SizedBox.shrink();
|
||||
}
|
||||
},
|
||||
);
|
||||
|
|
Loading…
Add table
Reference in a new issue