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(
reverse: true,
slivers: [
SliverFillRemaining(
hasScrollBody: false,
child: ColoredBox(
color: Colors.white,
child: Padding(
padding: const EdgeInsets.symmetric(
horizontal: 16.0,
vertical: 16.0,
),
child: Column(
children: <Widget>[
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(),
],
),
Spacer(),
Column(
children: <Widget>[
_buildLogo(),
const SizedBox(height: 4.0),
_buildCopyRight(),
_buildTextButtons(context),
],
)
],
),
),
),
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.