Add Text and button on banner
This commit is contained in:
parent
e2e788b68c
commit
cae095f701
5 changed files with 111 additions and 59 deletions
BIN
assets/slider_1.webp
Normal file
BIN
assets/slider_1.webp
Normal file
Binary file not shown.
After Width: | Height: | Size: 54 KiB |
|
@ -7,13 +7,55 @@ class Bannerimage extends StatelessWidget {
|
|||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Container(
|
||||
return ClipRRect(
|
||||
borderRadius: BorderRadius.all(Radius.circular(5.0)),
|
||||
child: Stack(
|
||||
children: [
|
||||
Container(
|
||||
padding: EdgeInsets.all(0.0),
|
||||
child: new Image.asset(
|
||||
'assets/Carousel_1.webp',
|
||||
'assets/slider_1.webp',
|
||||
width: 600.0,
|
||||
height: 200.0,
|
||||
height: 180.0,
|
||||
fit: BoxFit.fill,
|
||||
)),
|
||||
Padding(
|
||||
padding: EdgeInsets.only(top: 25.0, left: 10.0),
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Text(
|
||||
'SPRING / SUMMER COLLECTION 2022',
|
||||
style: TextStyle(
|
||||
color: Colors.black,
|
||||
fontSize: 10.5,
|
||||
fontWeight: FontWeight.bold),
|
||||
),
|
||||
SizedBox(
|
||||
height: 8.0,
|
||||
),
|
||||
Text(
|
||||
'Get up to 30% off \nNow Arrivals',
|
||||
style: TextStyle(
|
||||
color: Colors.black,
|
||||
fontSize: 20.0,
|
||||
fontWeight: FontWeight.bold),
|
||||
),
|
||||
SizedBox(
|
||||
height: 8.0,
|
||||
),
|
||||
ElevatedButton(
|
||||
child: Text('SHOP NOW'),
|
||||
onPressed: () {},
|
||||
style: ElevatedButton.styleFrom(
|
||||
primary: Colors.red,
|
||||
textStyle: TextStyle(
|
||||
fontSize: 14, fontWeight: FontWeight.bold)),
|
||||
),
|
||||
]),
|
||||
)
|
||||
],
|
||||
));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -18,7 +18,7 @@ class PopularProducts extends StatelessWidget {
|
|||
Padding(
|
||||
padding: const EdgeInsets.symmetric(vertical: defaultPadding),
|
||||
child: SectionTitle(
|
||||
title: "Popular",
|
||||
title: "Best Seller",
|
||||
pressSeeAll: () {},
|
||||
),
|
||||
),
|
||||
|
@ -40,7 +40,8 @@ class PopularProducts extends StatelessWidget {
|
|||
padding: const EdgeInsets.only(right: defaultPadding),
|
||||
child: ProductCard(
|
||||
title: data[index]['TITLE'],
|
||||
imageUrl: "https://nekoya.moe.team/img/${data[index]['IMAGE']}",
|
||||
imageUrl:
|
||||
"https://nekoya.moe.team/img/${data[index]['IMAGE']}",
|
||||
price: 99,
|
||||
bgColor: const Color(0xFFFEFBF9),
|
||||
press: () {
|
||||
|
@ -48,7 +49,8 @@ class PopularProducts extends StatelessWidget {
|
|||
isScrollControlled: true,
|
||||
backgroundColor: Colors.transparent,
|
||||
context: context,
|
||||
builder: (context) => productDetail(context, data[index]['ID']),
|
||||
builder: (context) =>
|
||||
productDetail(context, data[index]['ID']),
|
||||
);
|
||||
},
|
||||
),
|
||||
|
@ -68,7 +70,8 @@ class PopularProducts extends StatelessWidget {
|
|||
padding: const EdgeInsets.only(right: defaultPadding),
|
||||
child: ProductCard(
|
||||
title: 'Loading...',
|
||||
imageUrl: "https://i.ibb.co/QJFLZC4/La-Darknesss-Portrait.webp",
|
||||
imageUrl:
|
||||
"https://i.ibb.co/QJFLZC4/La-Darknesss-Portrait.webp",
|
||||
price: 99,
|
||||
bgColor: const Color(0xFFFEFBF9),
|
||||
press: () {},
|
||||
|
@ -78,8 +81,7 @@ class PopularProducts extends StatelessWidget {
|
|||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
)
|
||||
})
|
||||
],
|
||||
);
|
||||
}
|
||||
|
|
|
@ -8,6 +8,13 @@ packages:
|
|||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.2.0"
|
||||
app:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: app
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.0.3"
|
||||
archive:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
|
|
@ -44,6 +44,7 @@ dependencies:
|
|||
shared_preferences: ^2.0.13
|
||||
universal_html: ^2.0.8
|
||||
carousel_slider: ^4.1.1
|
||||
app: ^0.0.3
|
||||
|
||||
dev_dependencies:
|
||||
flutter_lints: ^2.0.1
|
||||
|
|
Loading…
Reference in a new issue