|
3 | 3 | import 'package:buttons_tabbar/buttons_tabbar.dart';
|
4 | 4 | import 'package:flutter/material.dart';
|
5 | 5 | import 'package:google_fonts/google_fonts.dart';
|
| 6 | +import 'package:newszia/Screens/home_mini.dart'; |
6 | 7 | import 'package:newszia/Screens/notify.dart';
|
7 | 8 | import 'package:newszia/Tabs/Business.dart';
|
8 | 9 | import 'package:newszia/Tabs/Politics.dart';
|
@@ -68,124 +69,128 @@ class _HomeState extends State<Home> {
|
68 | 69 | ),
|
69 | 70 | ),
|
70 | 71 | SizedBox(height: 10),
|
71 |
| - Container( |
72 |
| - height: h * 0.50, |
73 |
| - width: w * 0.9, |
74 |
| - decoration: BoxDecoration( |
75 |
| - color: const Color.fromARGB(255, 129, 127, 127), |
76 |
| - borderRadius: BorderRadius.all(Radius.circular(20))), |
77 |
| - child: Stack( |
78 |
| - children: [ |
79 |
| - Positioned( |
80 |
| - top: 0, |
81 |
| - left: 0, |
82 |
| - bottom: 0, |
83 |
| - right: 0, |
84 |
| - child: Container( |
85 |
| - decoration: BoxDecoration( |
86 |
| - color: Color.fromARGB(255, 129, 128, 128), |
87 |
| - borderRadius: |
88 |
| - BorderRadius.all(Radius.circular(20))), |
89 |
| - child: ClipRRect( |
90 |
| - borderRadius: BorderRadius.all(Radius.circular(20)), |
91 |
| - child: Image.asset( |
92 |
| - "assets/dark.jpeg", |
93 |
| - fit: BoxFit.fitHeight, |
94 |
| - )), |
95 |
| - )), |
96 |
| - Positioned( |
97 |
| - top: 20, |
98 |
| - right: 20, |
99 |
| - left: 290, |
100 |
| - bottom: 330, |
101 |
| - child: Container( |
102 |
| - decoration: BoxDecoration( |
103 |
| - color: Colors.redAccent, |
104 |
| - borderRadius: |
105 |
| - BorderRadius.all(Radius.circular(10))), |
106 |
| - child: IconButton( |
107 |
| - onPressed: () {}, |
108 |
| - icon: Icon(Icons.bookmark_outline_outlined)), |
109 |
| - )), |
110 |
| - Positioned( |
111 |
| - top: 160, |
112 |
| - right: 260, |
113 |
| - left: 30, |
114 |
| - bottom: 215, |
115 |
| - child: Container( |
116 |
| - decoration: BoxDecoration( |
117 |
| - color: Color.fromARGB(255, 117, 181, 233), |
118 |
| - borderRadius: |
119 |
| - BorderRadius.all(Radius.circular(20))), |
120 |
| - child: Center( |
121 |
| - child: Text( |
122 |
| - "Travel", |
| 72 | + GestureDetector(onTap: () { |
| 73 | + Navigator.push(context, MaterialPageRoute(builder: ((context) => HomeMini()))); |
| 74 | + }, |
| 75 | + child: Container( |
| 76 | + height: h * 0.50, |
| 77 | + width: w * 0.9, |
| 78 | + decoration: BoxDecoration( |
| 79 | + color: const Color.fromARGB(255, 129, 127, 127), |
| 80 | + borderRadius: BorderRadius.all(Radius.circular(20))), |
| 81 | + child: Stack( |
| 82 | + children: [ |
| 83 | + Positioned( |
| 84 | + top: 0, |
| 85 | + left: 0, |
| 86 | + bottom: 0, |
| 87 | + right: 0, |
| 88 | + child: Container( |
| 89 | + decoration: BoxDecoration( |
| 90 | + color: Color.fromARGB(255, 129, 128, 128), |
| 91 | + borderRadius: |
| 92 | + BorderRadius.all(Radius.circular(20))), |
| 93 | + child: ClipRRect( |
| 94 | + borderRadius: BorderRadius.all(Radius.circular(20)), |
| 95 | + child: Image.asset( |
| 96 | + "assets/dark.jpeg", |
| 97 | + fit: BoxFit.fitHeight, |
| 98 | + )), |
| 99 | + )), |
| 100 | + Positioned( |
| 101 | + top: 20, |
| 102 | + right: 20, |
| 103 | + left: 290, |
| 104 | + bottom: 330, |
| 105 | + child: Container( |
| 106 | + decoration: BoxDecoration( |
| 107 | + color: Colors.redAccent, |
| 108 | + borderRadius: |
| 109 | + BorderRadius.all(Radius.circular(10))), |
| 110 | + child: IconButton( |
| 111 | + onPressed: () {}, |
| 112 | + icon: Icon(Icons.bookmark_outline_outlined)), |
| 113 | + )), |
| 114 | + Positioned( |
| 115 | + top: 160, |
| 116 | + right: 260, |
| 117 | + left: 30, |
| 118 | + bottom: 215, |
| 119 | + child: Container( |
| 120 | + decoration: BoxDecoration( |
| 121 | + color: Color.fromARGB(255, 117, 181, 233), |
| 122 | + borderRadius: |
| 123 | + BorderRadius.all(Radius.circular(20))), |
| 124 | + child: Center( |
| 125 | + child: Text( |
| 126 | + "Travel", |
| 127 | + style: GoogleFonts.roboto( |
| 128 | + fontWeight: FontWeight.w600, color: Colors.white), |
| 129 | + )), |
| 130 | + )), |
| 131 | + Positioned( |
| 132 | + top: 165, |
| 133 | + right: 70, |
| 134 | + left: 120, |
| 135 | + bottom: 0, |
| 136 | + child: Text( |
| 137 | + "5 min reads", |
123 | 138 | style: GoogleFonts.roboto(
|
124 | 139 | fontWeight: FontWeight.w600, color: Colors.white),
|
125 | 140 | )),
|
126 |
| - )), |
127 |
| - Positioned( |
128 |
| - top: 165, |
129 |
| - right: 70, |
130 |
| - left: 120, |
131 |
| - bottom: 0, |
132 |
| - child: Text( |
133 |
| - "5 min reads", |
134 |
| - style: GoogleFonts.roboto( |
135 |
| - fontWeight: FontWeight.w600, color: Colors.white), |
136 |
| - )), |
137 |
| - Positioned( |
138 |
| - top: 220, |
139 |
| - right: 100, |
140 |
| - left: 30, |
141 |
| - bottom: 120, |
142 |
| - child: Text( |
143 |
| - "The UNESCO World Heritage Site with sky-\nhigh house prices", |
144 |
| - style: GoogleFonts.roboto( |
145 |
| - fontWeight: FontWeight.w800, |
146 |
| - color: Colors.white, |
147 |
| - fontSize: 16), |
148 |
| - )), |
149 |
| - Positioned( |
150 |
| - top: 320, |
151 |
| - right: 280, |
152 |
| - left: 30, |
153 |
| - bottom: 40, |
154 |
| - child: Container( |
155 |
| - decoration: BoxDecoration( |
156 |
| - color: Color.fromARGB(255, 255, 255, 255), |
157 |
| - borderRadius: |
158 |
| - BorderRadius.all(Radius.circular(40))), |
159 |
| - child: Center( |
160 |
| - child: ClipRRect( |
161 |
| - borderRadius: |
162 |
| - BorderRadius.all(Radius.circular(50)), |
163 |
| - child: Image.asset( |
164 |
| - "assets/bbc.png", |
165 |
| - fit: BoxFit.fill, |
166 |
| - ))), |
167 |
| - )), |
168 |
| - Positioned( |
169 |
| - top: 335, |
170 |
| - right: 60, |
171 |
| - left: 90, |
172 |
| - bottom: 40, |
173 |
| - child: Text( |
174 |
| - "BBC NEWS", |
175 |
| - style: GoogleFonts.roboto( |
176 |
| - fontWeight: FontWeight.w600, color: Colors.white), |
177 |
| - )), |
178 |
| - Positioned( |
179 |
| - top: 340, |
180 |
| - right: 30, |
181 |
| - left: 240, |
182 |
| - bottom: 40, |
183 |
| - child: Text( |
184 |
| - "3 hours ago", |
185 |
| - style: GoogleFonts.roboto( |
186 |
| - fontWeight: FontWeight.w400, color: Colors.white), |
187 |
| - )), |
188 |
| - ], |
| 141 | + Positioned( |
| 142 | + top: 220, |
| 143 | + right: 100, |
| 144 | + left: 30, |
| 145 | + bottom: 120, |
| 146 | + child: Text( |
| 147 | + "The UNESCO World Heritage Site with sky-\nhigh house prices", |
| 148 | + style: GoogleFonts.roboto( |
| 149 | + fontWeight: FontWeight.w800, |
| 150 | + color: Colors.white, |
| 151 | + fontSize: 16), |
| 152 | + )), |
| 153 | + Positioned( |
| 154 | + top: 320, |
| 155 | + right: 280, |
| 156 | + left: 30, |
| 157 | + bottom: 40, |
| 158 | + child: Container( |
| 159 | + decoration: BoxDecoration( |
| 160 | + color: Color.fromARGB(255, 255, 255, 255), |
| 161 | + borderRadius: |
| 162 | + BorderRadius.all(Radius.circular(40))), |
| 163 | + child: Center( |
| 164 | + child: ClipRRect( |
| 165 | + borderRadius: |
| 166 | + BorderRadius.all(Radius.circular(50)), |
| 167 | + child: Image.asset( |
| 168 | + "assets/bbc.png", |
| 169 | + fit: BoxFit.fill, |
| 170 | + ))), |
| 171 | + )), |
| 172 | + Positioned( |
| 173 | + top: 335, |
| 174 | + right: 60, |
| 175 | + left: 90, |
| 176 | + bottom: 40, |
| 177 | + child: Text( |
| 178 | + "BBC NEWS", |
| 179 | + style: GoogleFonts.roboto( |
| 180 | + fontWeight: FontWeight.w600, color: Colors.white), |
| 181 | + )), |
| 182 | + Positioned( |
| 183 | + top: 340, |
| 184 | + right: 30, |
| 185 | + left: 240, |
| 186 | + bottom: 40, |
| 187 | + child: Text( |
| 188 | + "3 hours ago", |
| 189 | + style: GoogleFonts.roboto( |
| 190 | + fontWeight: FontWeight.w400, color: Colors.white), |
| 191 | + )), |
| 192 | + ], |
| 193 | + ), |
189 | 194 | ),
|
190 | 195 | ),
|
191 | 196 | SizedBox(height: 20),
|
|
0 commit comments