Advertisement
Hitesh_jadhav

shopapp_img

Feb 19th, 2022
18
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.75 KB | None | 0 0
  1. import 'package:flutter/material.dart';
  2. import 'package:carousel_pro/carousel_pro.dart';
  3. import 'new_greeks.dart';
  4. void main() {
  5. runApp(MaterialApp(
  6. debugShowCheckedModeBanner: false,
  7. home: Homepage(),
  8. ));
  9. }
  10.  
  11. class Homepage extends StatefulWidget {
  12. const Homepage({Key? key}) : super(key: key);
  13.  
  14. @override
  15. _HomepageState createState() => _HomepageState();
  16. }
  17.  
  18. class _HomepageState extends State<Homepage> {
  19. @override
  20. Widget build(BuildContext context) {
  21. Widget image_carousel = new Container(
  22. height: 200,
  23. child: Carousel(
  24. boxFit: BoxFit.cover,
  25. images: [
  26. Image.asset("images/c1.jpg"),
  27. Image.asset("images/m1.jpeg"),
  28. Image.asset("images/m2.jpg"),
  29. Image.asset("images/w1.jpeg"),
  30. Image.asset("images/w3.jpeg"),
  31. Image.asset("images/w4.jpeg"),
  32. ],
  33. autoplay: false,
  34. animationCurve: Curves.fastOutSlowIn,
  35. animationDuration: Duration(milliseconds: 1000),
  36. ),
  37. );
  38. return Scaffold(
  39. appBar: AppBar(
  40. elevation: 0,
  41. backgroundColor: Colors.red,
  42. title: Text('Fashapp'),
  43. actions: <Widget>[
  44. IconButton(
  45. onPressed: () {},
  46. icon: Icon(
  47. Icons.search,
  48. color: Colors.white,
  49. )),
  50. IconButton(
  51. onPressed: () {},
  52. icon: Icon(
  53. Icons.shopping_cart,
  54. color: Colors.white,
  55. )),
  56. ],
  57. ),
  58. drawer: Drawer(
  59. child: ListView(
  60. children: <Widget>[
  61. UserAccountsDrawerHeader(
  62. accountName: Text('Hitesh'),
  63. accountEmail: Text('jadhavhitesh207@gmail.com'),
  64. currentAccountPicture: GestureDetector(
  65. child: CircleAvatar(
  66. backgroundColor: Colors.grey,
  67. child: Icon(
  68. Icons.person,
  69. color: Colors.white,
  70. ),
  71. ),
  72. ),
  73. decoration: BoxDecoration(color: Colors.red),
  74. ),
  75. InkWell(
  76. onTap: () {},
  77. child: ListTile(
  78. title: Text('Home page'),
  79. leading: Icon(Icons.home),
  80. ),
  81. ),
  82. InkWell(
  83. onTap: () {},
  84. child: ListTile(
  85. title: Text('My account'),
  86. leading: Icon(Icons.person),
  87. ),
  88. ),
  89. InkWell(
  90. onTap: () {},
  91. child: ListTile(
  92. title: Text('My orders'),
  93. leading: Icon(Icons.shopping_basket),
  94. ),
  95. ),
  96. InkWell(
  97. onTap: () {},
  98. child: ListTile(
  99. title: Text('Categories'),
  100. leading: Icon(Icons.grid_3x3),
  101. ),
  102. ),
  103. InkWell(
  104. onTap: () {},
  105. child: ListTile(
  106. title: Text('Favourites'),
  107. leading: Icon(Icons.favorite),
  108. ),
  109. ),
  110. Divider(),
  111. InkWell(
  112. onTap: () {},
  113. child: ListTile(
  114. title: Text('Settings'),
  115. leading: Icon(Icons.settings),
  116. ),
  117. ),
  118. InkWell(
  119. onTap: () {},
  120. child: ListTile(
  121. title: Text('About'),
  122. leading: Icon(Icons.help, color: Colors.green),
  123. ),
  124. ),
  125. ],
  126. ),
  127. ),
  128. body: ListView(
  129. children: <Widget>[
  130. image_carousel
  131. ],
  132. ),
  133. );
  134. }
  135. }
  136.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement