|
|
|
@ -25,26 +25,18 @@ class MarathonIntroScreen extends StatelessWidget {
|
|
|
|
|
MarathonProvider provider = context.watch<MarathonProvider>();
|
|
|
|
|
return Scaffold(
|
|
|
|
|
appBar: AppBarWidget(context, title: LocaleKeys.brainMarathon.tr()),
|
|
|
|
|
body: Stack(
|
|
|
|
|
body: Column(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
SingleChildScrollView(
|
|
|
|
|
child: Column(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
MarathonDetailsCard(provider: provider).paddingAll(15),
|
|
|
|
|
MarathonTimerCard(
|
|
|
|
|
provider: provider,
|
|
|
|
|
timeToMarathon: dummyEndTime,
|
|
|
|
|
).paddingOnly(left: 15, right: 15, bottom: 15),
|
|
|
|
|
const SizedBox(
|
|
|
|
|
height: 100,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
Align(
|
|
|
|
|
alignment: Alignment.bottomCenter,
|
|
|
|
|
child: MarathonFooter(provider: provider),
|
|
|
|
|
),
|
|
|
|
|
ListView(
|
|
|
|
|
padding: const EdgeInsets.all(21),
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
MarathonDetailsCard(provider: provider),
|
|
|
|
|
10.height,
|
|
|
|
|
MarathonTimerCard(provider: provider, timeToMarathon: dummyEndTime),
|
|
|
|
|
],
|
|
|
|
|
).expanded,
|
|
|
|
|
1.divider,
|
|
|
|
|
MarathonFooter(provider: provider),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
);
|
|
|
|
@ -61,52 +53,41 @@ class MarathonDetailsCard extends StatelessWidget {
|
|
|
|
|
return Container(
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
decoration: MyDecorations.shadowDecoration,
|
|
|
|
|
padding: const EdgeInsets.symmetric(vertical: 20, horizontal: 20),
|
|
|
|
|
padding: const EdgeInsets.symmetric(vertical: 18, horizontal: 14),
|
|
|
|
|
child: Column(
|
|
|
|
|
mainAxisSize: MainAxisSize.min,
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
LocaleKeys.contestTopicAbout.tr().toText16(color: MyColors.grey77Color),
|
|
|
|
|
"Saudi Arabia".toText20(color: MyColors.textMixColor, isBold: true),
|
|
|
|
|
Row(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Flexible(
|
|
|
|
|
child: "Nam suscipit turpis in pharetra euismsdef. Duis rutrum at nulla id aliquam".toText14(color: MyColors.grey77Color),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
if (provider.itsMarathonTime) ...<Widget>[
|
|
|
|
|
5.height,
|
|
|
|
|
Row(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
LocaleKeys.prize.tr().toText16(color: MyColors.grey77Color, isBold: true),
|
|
|
|
|
" LED 55\" Android TV".toText16(color: MyColors.greenColor, isBold: true),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
LocaleKeys.sponsoredBy.tr().toText16(color: MyColors.grey77Color),
|
|
|
|
|
" Extra".toText16(color: MyColors.darkTextColor, isBold: true),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
10.height,
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Image.asset(
|
|
|
|
|
"assets/images/logos/main_mohemm_logo.png",
|
|
|
|
|
height: 40,
|
|
|
|
|
fit: BoxFit.fill,
|
|
|
|
|
width: 150,
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
]
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
LocaleKeys.contestTopicAbout.tr().toText16(color: MyColors.grey57Color),
|
|
|
|
|
"Saudi Arabia".toText20(color: MyColors.textMixColor),
|
|
|
|
|
"Nam suscipit turpis in pharetra euismsdef. Duis rutrum at nulla id aliquam".toText14(color: MyColors.grey57Color, weight: FontWeight.w500),
|
|
|
|
|
if (provider.itsMarathonTime) ...<Widget>[
|
|
|
|
|
5.height,
|
|
|
|
|
Row(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
LocaleKeys.prize.tr().toText16(color: MyColors.grey57Color),
|
|
|
|
|
" LED 55\" Android TV".toText16(color: MyColors.greenColor, isBold: true),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
LocaleKeys.sponsoredBy.tr().toText16(color: MyColors.grey57Color),
|
|
|
|
|
" Extra".toText16(color: MyColors.darkTextColor),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
10.height,
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Image.asset(
|
|
|
|
|
"assets/images/logos/main_mohemm_logo.png",
|
|
|
|
|
height: 40,
|
|
|
|
|
fit: BoxFit.fill,
|
|
|
|
|
width: 150,
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
]
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
);
|
|
|
|
@ -128,30 +109,23 @@ class MarathonTimerCard extends StatelessWidget {
|
|
|
|
|
return Container(
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
decoration: MyDecorations.shadowDecoration,
|
|
|
|
|
padding: const EdgeInsets.symmetric(vertical: 20, horizontal: 20),
|
|
|
|
|
padding: const EdgeInsets.symmetric(vertical: 18, horizontal: 14),
|
|
|
|
|
child: Column(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Row(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
LocaleKeys.gameDate.tr().toText16(color: MyColors.grey77Color),
|
|
|
|
|
" 10 Oct, 2022".toText16(color: MyColors.darkTextColor, isBold: true),
|
|
|
|
|
LocaleKeys.gameDate.tr().toText16(color: MyColors.grey57Color),
|
|
|
|
|
" 10 Oct, 2022".toText16(color: MyColors.darkTextColor),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
LocaleKeys.gameTime.tr().toText16(color: MyColors.grey77Color),
|
|
|
|
|
" 3:00pm".toText16(color: MyColors.darkTextColor, isBold: true),
|
|
|
|
|
LocaleKeys.gameTime.tr().toText16(color: MyColors.grey57Color),
|
|
|
|
|
" 3:00 pm".toText16(color: MyColors.darkTextColor),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Lottie.asset(
|
|
|
|
|
MyLottieConsts.hourGlassLottie,
|
|
|
|
|
height: 200,
|
|
|
|
|
),
|
|
|
|
|
BuildCountdownTimer(
|
|
|
|
|
timeToMarathon: timeToMarathon,
|
|
|
|
|
provider: provider,
|
|
|
|
|
screenFlag: 1,
|
|
|
|
|
),
|
|
|
|
|
Lottie.asset(MyLottieConsts.hourGlassLottie, height: 200),
|
|
|
|
|
BuildCountdownTimer(timeToMarathon: timeToMarathon, provider: provider, screenFlag: 1),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
);
|
|
|
|
@ -172,38 +146,19 @@ class MarathonFooter extends StatelessWidget {
|
|
|
|
|
children: <InlineSpan>[
|
|
|
|
|
TextSpan(
|
|
|
|
|
text: LocaleKeys.note.tr(),
|
|
|
|
|
style: const TextStyle(
|
|
|
|
|
color: MyColors.darkTextColor,
|
|
|
|
|
fontSize: 17,
|
|
|
|
|
letterSpacing: -0.64,
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
),
|
|
|
|
|
style: const TextStyle(color: MyColors.darkTextColor, fontSize: 17, letterSpacing: -0.64, fontWeight: FontWeight.bold),
|
|
|
|
|
),
|
|
|
|
|
TextSpan(
|
|
|
|
|
text: " " + LocaleKeys.demoMarathonNoteP1.tr(),
|
|
|
|
|
style: const TextStyle(
|
|
|
|
|
color: MyColors.grey77Color,
|
|
|
|
|
fontSize: 17,
|
|
|
|
|
letterSpacing: -0.64,
|
|
|
|
|
fontWeight: FontWeight.w500,
|
|
|
|
|
),
|
|
|
|
|
style: const TextStyle(color: MyColors.grey77Color, fontSize: 17, letterSpacing: -0.64, fontWeight: FontWeight.w500),
|
|
|
|
|
),
|
|
|
|
|
TextSpan(
|
|
|
|
|
text: " " + LocaleKeys.demoMarathonNoteP2.tr(),
|
|
|
|
|
style: const TextStyle(
|
|
|
|
|
color: MyColors.darkTextColor,
|
|
|
|
|
fontSize: 17,
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
),
|
|
|
|
|
style: const TextStyle(color: MyColors.darkTextColor, fontSize: 17, fontWeight: FontWeight.bold),
|
|
|
|
|
),
|
|
|
|
|
TextSpan(
|
|
|
|
|
text: " " + LocaleKeys.demoMarathonNoteP3.tr(),
|
|
|
|
|
style: const TextStyle(
|
|
|
|
|
color: MyColors.grey77Color,
|
|
|
|
|
fontSize: 17,
|
|
|
|
|
letterSpacing: -0.64,
|
|
|
|
|
fontWeight: FontWeight.w500,
|
|
|
|
|
),
|
|
|
|
|
style: const TextStyle(color: MyColors.grey77Color, fontSize: 17, letterSpacing: -0.64, fontWeight: FontWeight.w500),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|