|
@@ -14,100 +14,102 @@ class WelComePage extends StatefulWidget {
|
|
|
class _WelComePageState extends State<WelComePage> {
|
|
|
@override
|
|
|
Widget build(BuildContext context) {
|
|
|
- return Stack(
|
|
|
- children: [
|
|
|
- Container(
|
|
|
- child: Image.asset(
|
|
|
- "assets/images/home.jpg",
|
|
|
- fit: BoxFit.cover,
|
|
|
- width: double.infinity,
|
|
|
- height: double.infinity,
|
|
|
+ return Scaffold(
|
|
|
+ body: Stack(
|
|
|
+ children: [
|
|
|
+ Container(
|
|
|
+ child: Image.asset(
|
|
|
+ "assets/images/home.jpg",
|
|
|
+ fit: BoxFit.cover,
|
|
|
+ width: double.infinity,
|
|
|
+ height: double.infinity,
|
|
|
+ ),
|
|
|
),
|
|
|
- ),
|
|
|
- Positioned(
|
|
|
- bottom: 80,
|
|
|
- child: Container(
|
|
|
- width: MediaQuery.of(context).size.width,
|
|
|
- alignment: Alignment.center,
|
|
|
- child: Row(
|
|
|
- mainAxisAlignment: MainAxisAlignment.center,
|
|
|
- children: [
|
|
|
- Container(
|
|
|
- width: 150,
|
|
|
- child: InkWell(
|
|
|
- onTap: () {
|
|
|
-
|
|
|
- Navigator.of(context).push(
|
|
|
- MaterialPageRoute(builder: (context) => LoginPage()));
|
|
|
- },
|
|
|
- child: Container(
|
|
|
- width: double.infinity,
|
|
|
- height: AppUtil.height(100),
|
|
|
- padding: EdgeInsets.only(
|
|
|
- right: AppUtil.width(20), left: AppUtil.width(20)),
|
|
|
- decoration: BoxDecoration(
|
|
|
- gradient: LinearGradient(colors: [
|
|
|
- ThemeColor.loignColor,
|
|
|
- ThemeColor.loignColor
|
|
|
- ]),
|
|
|
- borderRadius: BorderRadius.circular(10),
|
|
|
- boxShadow: [
|
|
|
- BoxShadow(
|
|
|
- offset: Offset(1.0, 5.0),
|
|
|
- color: ThemeColor.loignColor,
|
|
|
- blurRadius: 5.0,
|
|
|
- )
|
|
|
- ]),
|
|
|
- child: Center(
|
|
|
- child: Text(
|
|
|
- "登录",
|
|
|
- style: TextStyle(fontSize: 20, color: Colors.white),
|
|
|
+ Positioned(
|
|
|
+ bottom: 100,
|
|
|
+ child: Container(
|
|
|
+ width: MediaQuery.of(context).size.width,
|
|
|
+ alignment: Alignment.center,
|
|
|
+ child: Row(
|
|
|
+ mainAxisAlignment: MainAxisAlignment.center,
|
|
|
+ children: [
|
|
|
+ Container(
|
|
|
+ width: 150,
|
|
|
+ child: InkWell(
|
|
|
+ onTap: () {
|
|
|
+
|
|
|
+ Navigator.of(context).push(MaterialPageRoute(
|
|
|
+ builder: (context) => LoginPage()));
|
|
|
+ },
|
|
|
+ child: Container(
|
|
|
+ width: double.infinity,
|
|
|
+ height: AppUtil.height(100),
|
|
|
+ padding: EdgeInsets.only(
|
|
|
+ right: AppUtil.width(20), left: AppUtil.width(20)),
|
|
|
+ decoration: BoxDecoration(
|
|
|
+ gradient: const LinearGradient(colors: [
|
|
|
+ ThemeColor.loignColor,
|
|
|
+ ThemeColor.loignColor
|
|
|
+ ]),
|
|
|
+ borderRadius: BorderRadius.circular(10),
|
|
|
+ boxShadow: const [
|
|
|
+ BoxShadow(
|
|
|
+ offset: Offset(1.0, 5.0),
|
|
|
+ color: ThemeColor.loignColor,
|
|
|
+ blurRadius: 5.0,
|
|
|
+ )
|
|
|
+ ]),
|
|
|
+ child: const Center(
|
|
|
+ child: Text(
|
|
|
+ "登录",
|
|
|
+ style: TextStyle(fontSize: 20, color: Colors.white),
|
|
|
+ ),
|
|
|
),
|
|
|
),
|
|
|
),
|
|
|
),
|
|
|
- ),
|
|
|
- Container(
|
|
|
- width: 150,
|
|
|
- child: InkWell(
|
|
|
- onTap: () {
|
|
|
-
|
|
|
- Navigator.of(context).push(MaterialPageRoute(
|
|
|
- builder: (context) => RegisterPage()));
|
|
|
- },
|
|
|
- child: Container(
|
|
|
- margin: EdgeInsets.only(left: 20.0),
|
|
|
- width: double.infinity,
|
|
|
- height: AppUtil.height(100),
|
|
|
- padding: EdgeInsets.only(
|
|
|
- right: AppUtil.width(20), left: AppUtil.width(20)),
|
|
|
- decoration: BoxDecoration(
|
|
|
- gradient: LinearGradient(colors: [
|
|
|
- ThemeColor.loignColor,
|
|
|
- ThemeColor.loignColor
|
|
|
- ]),
|
|
|
- borderRadius: BorderRadius.circular(10),
|
|
|
- boxShadow: [
|
|
|
- BoxShadow(
|
|
|
- offset: Offset(1.0, 5.0),
|
|
|
- color: ThemeColor.loignColor,
|
|
|
- blurRadius: 5.0,
|
|
|
- )
|
|
|
- ]),
|
|
|
- child: Center(
|
|
|
- child: Text(
|
|
|
- "注册",
|
|
|
- style: TextStyle(fontSize: 20, color: Colors.white),
|
|
|
+ Container(
|
|
|
+ width: 200,
|
|
|
+ child: InkWell(
|
|
|
+ onTap: () {
|
|
|
+
|
|
|
+ Navigator.of(context).push(MaterialPageRoute(
|
|
|
+ builder: (context) => RegisterPage()));
|
|
|
+ },
|
|
|
+ child: Container(
|
|
|
+ margin: EdgeInsets.only(left: 20.0),
|
|
|
+ width: double.infinity,
|
|
|
+ height: AppUtil.height(100),
|
|
|
+ padding: EdgeInsets.only(
|
|
|
+ right: AppUtil.width(20), left: AppUtil.width(20)),
|
|
|
+ decoration: BoxDecoration(
|
|
|
+ gradient: const LinearGradient(colors: [
|
|
|
+ ThemeColor.loignColor,
|
|
|
+ ThemeColor.loignColor
|
|
|
+ ]),
|
|
|
+ borderRadius: BorderRadius.circular(10),
|
|
|
+ boxShadow: const [
|
|
|
+ BoxShadow(
|
|
|
+ offset: Offset(1.0, 5.0),
|
|
|
+ color: ThemeColor.loignColor,
|
|
|
+ blurRadius: 5.0,
|
|
|
+ )
|
|
|
+ ]),
|
|
|
+ child: const Center(
|
|
|
+ child: Text(
|
|
|
+ "新用户注册",
|
|
|
+ style: TextStyle(fontSize: 20, color: Colors.white),
|
|
|
+ ),
|
|
|
),
|
|
|
),
|
|
|
),
|
|
|
),
|
|
|
- ),
|
|
|
- ],
|
|
|
+ ],
|
|
|
+ ),
|
|
|
),
|
|
|
- ),
|
|
|
- )
|
|
|
- ],
|
|
|
+ )
|
|
|
+ ],
|
|
|
+ ),
|
|
|
);
|
|
|
}
|
|
|
}
|