|
|
|
@ -69,19 +69,25 @@ class _FeaturedActivity extends State<FeaturedActivity> {
|
|
|
|
|
child: Row( |
|
|
|
|
children: [ |
|
|
|
|
if (activityList != null && activityList.length > 0) |
|
|
|
|
Container( |
|
|
|
|
child: stackItem(18.sp, activityList[0]), |
|
|
|
|
margin: EdgeInsets.symmetric(horizontal: 5.w), |
|
|
|
|
width: (MediaQuery.of(context).size.width - 42) / 2, |
|
|
|
|
height: 190.h, |
|
|
|
|
decoration: BoxDecoration( |
|
|
|
|
borderRadius: BorderRadius.circular(4), |
|
|
|
|
color: Colors.red, |
|
|
|
|
image: DecorationImage( |
|
|
|
|
image: NetworkImage( |
|
|
|
|
activityList[0].coverImg, |
|
|
|
|
GestureDetector( |
|
|
|
|
onTap: () { |
|
|
|
|
Navigator.of(context).pushNamed('/router/web_page', |
|
|
|
|
arguments: {"activityId": activityList[0].id}); |
|
|
|
|
}, |
|
|
|
|
child: Container( |
|
|
|
|
child: stackItem(18.sp, activityList[0]), |
|
|
|
|
margin: EdgeInsets.symmetric(horizontal: 5.w), |
|
|
|
|
width: (MediaQuery.of(context).size.width - 42) / 2, |
|
|
|
|
height: 190.h, |
|
|
|
|
decoration: BoxDecoration( |
|
|
|
|
borderRadius: BorderRadius.circular(4), |
|
|
|
|
color: Colors.red, |
|
|
|
|
image: DecorationImage( |
|
|
|
|
image: NetworkImage( |
|
|
|
|
activityList[0].coverImg, |
|
|
|
|
), |
|
|
|
|
fit: BoxFit.cover, |
|
|
|
|
), |
|
|
|
|
fit: BoxFit.cover, |
|
|
|
|
), |
|
|
|
|
), |
|
|
|
|
), |
|
|
|
@ -90,41 +96,53 @@ class _FeaturedActivity extends State<FeaturedActivity> {
|
|
|
|
|
child: Column( |
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceEvenly, |
|
|
|
|
children: [ |
|
|
|
|
Container( |
|
|
|
|
child: stackItem(12.sp, activityList[1]), |
|
|
|
|
margin: EdgeInsets.symmetric(horizontal: 5.w), |
|
|
|
|
width: (MediaQuery.of(context).size.width - 42) / 2, |
|
|
|
|
height: 190.h / 2, |
|
|
|
|
decoration: BoxDecoration( |
|
|
|
|
borderRadius: BorderRadius.circular(4), |
|
|
|
|
color: Colors.green, |
|
|
|
|
image: DecorationImage( |
|
|
|
|
image: NetworkImage( |
|
|
|
|
activityList[2].coverImg, |
|
|
|
|
GestureDetector( |
|
|
|
|
onTap: () { |
|
|
|
|
Navigator.of(context).pushNamed('/router/web_page', |
|
|
|
|
arguments: {"activityId": activityList[1].id}); |
|
|
|
|
}, |
|
|
|
|
child: Container( |
|
|
|
|
child: stackItem(12.sp, activityList[1]), |
|
|
|
|
margin: EdgeInsets.symmetric(horizontal: 5.w), |
|
|
|
|
width: (MediaQuery.of(context).size.width - 42) / 2, |
|
|
|
|
height: 190.h / 2, |
|
|
|
|
decoration: BoxDecoration( |
|
|
|
|
borderRadius: BorderRadius.circular(4), |
|
|
|
|
color: Colors.green, |
|
|
|
|
image: DecorationImage( |
|
|
|
|
image: NetworkImage( |
|
|
|
|
activityList[1].coverImg, |
|
|
|
|
), |
|
|
|
|
fit: BoxFit.cover, |
|
|
|
|
), |
|
|
|
|
fit: BoxFit.cover, |
|
|
|
|
), |
|
|
|
|
), |
|
|
|
|
), |
|
|
|
|
SizedBox( |
|
|
|
|
height: 5, |
|
|
|
|
), |
|
|
|
|
Container( |
|
|
|
|
child: stackItem(12.sp, activityList[2]), |
|
|
|
|
margin: EdgeInsets.symmetric(horizontal: 5.w), |
|
|
|
|
width: (MediaQuery.of(context).size.width - 42) / 2, |
|
|
|
|
height: 190.h / 2, |
|
|
|
|
decoration: BoxDecoration( |
|
|
|
|
borderRadius: BorderRadius.circular(4), |
|
|
|
|
color: Colors.blue, |
|
|
|
|
image: DecorationImage( |
|
|
|
|
image: NetworkImage( |
|
|
|
|
activityList[2].coverImg, |
|
|
|
|
GestureDetector( |
|
|
|
|
onTap: () { |
|
|
|
|
Navigator.of(context).pushNamed('/router/web_page', |
|
|
|
|
arguments: {"activityId": activityList[2].id}); |
|
|
|
|
}, |
|
|
|
|
child: Container( |
|
|
|
|
child: stackItem(12.sp, activityList[2]), |
|
|
|
|
margin: EdgeInsets.symmetric(horizontal: 5.w), |
|
|
|
|
width: (MediaQuery.of(context).size.width - 42) / 2, |
|
|
|
|
height: 190.h / 2, |
|
|
|
|
decoration: BoxDecoration( |
|
|
|
|
borderRadius: BorderRadius.circular(4), |
|
|
|
|
color: Colors.blue, |
|
|
|
|
image: DecorationImage( |
|
|
|
|
image: NetworkImage( |
|
|
|
|
activityList[2].coverImg, |
|
|
|
|
), |
|
|
|
|
fit: BoxFit.cover, |
|
|
|
|
), |
|
|
|
|
fit: BoxFit.cover, |
|
|
|
|
), |
|
|
|
|
), |
|
|
|
|
) |
|
|
|
|
), |
|
|
|
|
], |
|
|
|
|
), |
|
|
|
|
), |
|
|
|
@ -184,13 +202,7 @@ class _FeaturedActivity extends State<FeaturedActivity> {
|
|
|
|
|
borderRadius: BorderRadius.circular(20), |
|
|
|
|
), |
|
|
|
|
alignment: Alignment.center, |
|
|
|
|
child: |
|
|
|
|
GestureDetector( |
|
|
|
|
onTap: (){ |
|
|
|
|
Navigator.of(context).pushNamed('/router/web_page', |
|
|
|
|
arguments: {"activityId": activity.id}); |
|
|
|
|
}, |
|
|
|
|
child:Row( |
|
|
|
|
child: Row( |
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center, |
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center, |
|
|
|
|
children: [ |
|
|
|
@ -208,7 +220,7 @@ class _FeaturedActivity extends State<FeaturedActivity> {
|
|
|
|
|
size: 12, |
|
|
|
|
), |
|
|
|
|
], |
|
|
|
|
)), |
|
|
|
|
), |
|
|
|
|
), |
|
|
|
|
], |
|
|
|
|
); |
|
|
|
|