Skip to content

Commit

Permalink
fix: schedule shown twice, overflow on small device
Browse files Browse the repository at this point in the history
  • Loading branch information
snaoyam committed Jul 31, 2023
1 parent 524fa07 commit d3d99e1
Showing 1 changed file with 79 additions and 34 deletions.
113 changes: 79 additions & 34 deletions lib/pages/main_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -153,42 +153,87 @@ class _MainPageState extends State<MainPage> {
borderRadius:
BorderRadius.vertical(top: Radius.circular(16.0)),
child: Container(
constraints: const BoxConstraints.expand(),
child: ColoredBox(
color: Colors.white,
child: Padding(
padding: const EdgeInsets.symmetric(
horizontal: 16.0,
vertical: 16.0,
),
child: Column(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Column(
children: <Widget>[
_buildTimetable(infoModel.user, semester, now),
const SizedBox(height: 24.0),
_buildDivider(),
const SizedBox(height: 24.0),
_buildSchedule(now, infoModel.currentSchedule),
_buildSchedule(now, infoModel.currentSchedule),
const SizedBox(height: 24.0),
_buildDivider(),
],
constraints: const BoxConstraints.expand(),
child: CustomScrollView(

Check warning on line 157 in lib/pages/main_page.dart

View check run for this annotation

Codecov / codecov/patch

lib/pages/main_page.dart#L157

Added line #L157 was not covered by tests
reverse: true,
slivers: [
SliverFillRemaining(

Check warning on line 160 in lib/pages/main_page.dart

View check run for this annotation

Codecov / codecov/patch

lib/pages/main_page.dart#L159-L160

Added lines #L159 - L160 were not covered by tests
hasScrollBody: false,
child: ColoredBox(

Check warning on line 162 in lib/pages/main_page.dart

View check run for this annotation

Codecov / codecov/patch

lib/pages/main_page.dart#L162

Added line #L162 was not covered by tests
color: Colors.white,
child: Padding(

Check warning on line 164 in lib/pages/main_page.dart

View check run for this annotation

Codecov / codecov/patch

lib/pages/main_page.dart#L164

Added line #L164 was not covered by tests
padding: const EdgeInsets.symmetric(
horizontal: 16.0,
vertical: 16.0,
),
child: Column(
children: <Widget>[
Column(
children: <Widget>[
_buildTimetable(
infoModel.user, semester, now),

Check warning on line 174 in lib/pages/main_page.dart

View check run for this annotation

Codecov / codecov/patch

lib/pages/main_page.dart#L169-L174

Added lines #L169 - L174 were not covered by tests
const SizedBox(height: 24.0),
_buildDivider(),

Check warning on line 176 in lib/pages/main_page.dart

View check run for this annotation

Codecov / codecov/patch

lib/pages/main_page.dart#L176

Added line #L176 was not covered by tests
const SizedBox(height: 24.0),
_buildSchedule(
now, infoModel.currentSchedule),

Check warning on line 179 in lib/pages/main_page.dart

View check run for this annotation

Codecov / codecov/patch

lib/pages/main_page.dart#L178-L179

Added lines #L178 - L179 were not covered by tests
const SizedBox(height: 24.0),
_buildDivider(),

Check warning on line 181 in lib/pages/main_page.dart

View check run for this annotation

Codecov / codecov/patch

lib/pages/main_page.dart#L181

Added line #L181 was not covered by tests
],
),
Spacer(),
Column(
children: <Widget>[
_buildLogo(),

Check warning on line 187 in lib/pages/main_page.dart

View check run for this annotation

Codecov / codecov/patch

lib/pages/main_page.dart#L184-L187

Added lines #L184 - L187 were not covered by tests
const SizedBox(height: 4.0),
_buildCopyRight(),
_buildTextButtons(context),

Check warning on line 190 in lib/pages/main_page.dart

View check run for this annotation

Codecov / codecov/patch

lib/pages/main_page.dart#L189-L190

Added lines #L189 - L190 were not covered by tests
],
)
],
),
),
),
Column(
children: <Widget>[
_buildLogo(),
const SizedBox(height: 4.0),
_buildCopyRight(),
_buildTextButtons(context),
],
)
],
),
),
],
)

// SingleChildScrollView(
// child: ColoredBox(
// color: Colors.white,
// child: Padding(
// padding: const EdgeInsets.symmetric(
// horizontal: 16.0,
// vertical: 16.0,
// ),
// child: Column(
// mainAxisAlignment: MainAxisAlignment.spaceBetween,
// children: [
// Column(
// children: <Widget>[
// _buildTimetable(infoModel.user, semester, now),
// const SizedBox(height: 24.0),
// _buildDivider(),
// const SizedBox(height: 24.0),
// _buildSchedule(now, infoModel.currentSchedule),
// const SizedBox(height: 24.0),
// _buildDivider(),
// ],
// ),
// Column(
// children: <Widget>[
// _buildLogo(),
// const SizedBox(height: 4.0),
// _buildCopyRight(),
// _buildTextButtons(context),
// ],
// )
// ],
// ),
// ),
// ),
// ),
),
),
),
),
),
],
Expand Down

0 comments on commit d3d99e1

Please sign in to comment.