Standard Folder View: Align the title with the time correctly

As suggested by the docs it's better to use a Row and align it based on
the baseline.
This commit is contained in:
Vishesh Handa
2020-03-05 19:03:05 +01:00
parent f31e42ecef
commit c87e6c7884

View File

@ -58,10 +58,16 @@ class StandardView extends StatelessWidget {
), ),
]; ];
var titleRow = Row(
children: <Widget>[Expanded(child: titleWidget), trailing],
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.baseline,
textBaseline: TextBaseline.alphabetic,
);
var tile = ListTile( var tile = ListTile(
isThreeLine: true, isThreeLine: true,
title: titleWidget, title: titleRow,
trailing: trailing,
subtitle: Column( subtitle: Column(
children: children, children: children,
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,