|
|
@@ -5,6 +5,7 @@ import 'dart:ui';
|
|
|
import '../styles/totast.dart';
|
|
|
import 'LoginSecond.dart';
|
|
|
import '../utils/Utils.dart';
|
|
|
+import '../widget/LinearButton.dart';
|
|
|
|
|
|
class LoginFirst extends StatefulWidget {
|
|
|
@override
|
|
|
@@ -46,11 +47,7 @@ class LoginFirstState extends State<LoginFirst> {
|
|
|
Image.asset('images/icon_logo.png'),
|
|
|
Container(
|
|
|
margin: EdgeInsets.only(top: 30),
|
|
|
- child: Text('手机快捷登录',
|
|
|
- style: TextStyle(
|
|
|
- color: Colors.white,
|
|
|
- fontSize: 28,
|
|
|
- fontWeight: FontWeight.w500)),
|
|
|
+ child: Text('手机快捷登录', style: TextStyle(color: Colors.white, fontSize: 28, fontWeight: FontWeight.w500)),
|
|
|
),
|
|
|
Container(
|
|
|
margin: EdgeInsets.only(top: 20),
|
|
|
@@ -58,10 +55,7 @@ class LoginFirstState extends State<LoginFirst> {
|
|
|
autofocus: true,
|
|
|
keyboardType: TextInputType.phone,
|
|
|
maxLength: 11,
|
|
|
- style: TextStyle(
|
|
|
- color: Colors.white,
|
|
|
- fontSize: 18,
|
|
|
- fontWeight: FontWeight.w500),
|
|
|
+ style: TextStyle(color: Colors.white, fontSize: 18, fontWeight: FontWeight.w500),
|
|
|
decoration: InputDecoration(
|
|
|
hintText: '输入手机号',
|
|
|
hintStyle: TextStyle(
|
|
|
@@ -84,31 +78,17 @@ class LoginFirstState extends State<LoginFirst> {
|
|
|
// width: 20,
|
|
|
// ),
|
|
|
// ),
|
|
|
- counterStyle: TextStyle(
|
|
|
- color: BG_SUB_COLOR, fontSize: 0)),
|
|
|
+ counterStyle: TextStyle(color: BG_SUB_COLOR, fontSize: 0)),
|
|
|
onChanged: (value) {
|
|
|
inputVal = value;
|
|
|
})),
|
|
|
- Text('未注册的手机号验证后自动创建账户',
|
|
|
- style: TextStyle(
|
|
|
- color: Color(0xFF727785), fontSize: 13)),
|
|
|
- Container(
|
|
|
- margin: EdgeInsets.symmetric(vertical: 22),
|
|
|
- decoration: BoxDecoration(
|
|
|
- gradient: LinearGradient(
|
|
|
- begin: Alignment.topCenter,
|
|
|
- end: Alignment.bottomCenter,
|
|
|
- colors: [
|
|
|
- Color(0xFFFFC30F),
|
|
|
- Color(0xFFFFA54C)
|
|
|
- ])),
|
|
|
- width: double.infinity,
|
|
|
- height: 48,
|
|
|
- child: Material(
|
|
|
- color: Colors.transparent,
|
|
|
- child: InkWell(
|
|
|
- onTap: () {
|
|
|
- if (!checkPhone(inputVal)) {
|
|
|
+ Text('未注册的手机号验证后自动创建账户', style: TextStyle(color: Color(0xFF727785), fontSize: 13)),
|
|
|
+ Container(height: 20,),
|
|
|
+ LinearButton(
|
|
|
+ btntext: '下一步',
|
|
|
+ onTapHomeMenu: () {
|
|
|
+
|
|
|
+ if (!checkPhone(inputVal)) {
|
|
|
Toast.show(context, '手机号格式错误', 1500, 'info');
|
|
|
} else {
|
|
|
Navigator.push(
|
|
|
@@ -119,18 +99,9 @@ class LoginFirstState extends State<LoginFirst> {
|
|
|
),
|
|
|
);
|
|
|
}
|
|
|
- },
|
|
|
- child: Center(
|
|
|
- child: Text(
|
|
|
- '下一步',
|
|
|
- style: TextStyle(
|
|
|
- fontSize: 16,
|
|
|
- fontWeight: FontWeight.w500,
|
|
|
- color: Colors.white),
|
|
|
- )),
|
|
|
- ),
|
|
|
- ),
|
|
|
-
|
|
|
+ }
|
|
|
+ ),
|
|
|
+
|
|
|
// FlatButton(
|
|
|
// textColor: Colors.white,
|
|
|
// color: PRIMARY_COLOR,
|
|
|
@@ -149,7 +120,7 @@ class LoginFirstState extends State<LoginFirst> {
|
|
|
// }
|
|
|
// },
|
|
|
// ),
|
|
|
- )
|
|
|
+
|
|
|
],
|
|
|
),
|
|
|
),
|