Skip to content

Commit

Permalink
travel_cards_list: Update layout, vertically center align items
Browse files Browse the repository at this point in the history
  • Loading branch information
esDotDev committed Apr 30, 2024
1 parent 5da3d4e commit 055406a
Showing 1 changed file with 23 additions and 19 deletions.
42 changes: 23 additions & 19 deletions vignettes/parallax_travel_cards_list/lib/demo.dart
Original file line number Diff line number Diff line change
Expand Up @@ -22,28 +22,32 @@ class _TravelCardDemoState extends State<TravelCardDemo> {
return Scaffold(
appBar: _buildAppBar(),
body: Container(
alignment: Alignment.center,
color: Colors.white,
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: <Widget>[
Padding(
padding: EdgeInsets.symmetric(horizontal: Styles.hzScreenPadding),
child: Text(
'Where are you going next?',
overflow: TextOverflow.ellipsis,
style: Styles.appHeader,
maxLines: 2,
child: SingleChildScrollView(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: <Widget>[
Padding(
padding: EdgeInsets.symmetric(horizontal: Styles.hzScreenPadding),
child: Text(
'Where are you going next?',
overflow: TextOverflow.ellipsis,
style: Styles.appHeader,
maxLines: 2,
),
),
),
Expanded(
child: TravelCardList(
cities: _cityList,
onCityChange: _handleCityChange,
Padding(
padding: const EdgeInsets.symmetric(vertical: 16),
child: TravelCardList(
cities: _cityList,
onCityChange: _handleCityChange,
),
),
),
HotelList(_currentCity.hotels),
],
HotelList(_currentCity.hotels),
],
),
),
),
);
Expand Down

0 comments on commit 055406a

Please sign in to comment.