更新登录页面布局

This commit is contained in:
wyf
2025-06-27 11:01:34 +08:00
parent 6d1d01edc6
commit 6e2875c6d8
2 changed files with 40 additions and 22 deletions

View File

@@ -382,7 +382,7 @@ var returnIconButtom = IconButton(
var returnIconButtomNew = ClickableContainer( var returnIconButtomNew = ClickableContainer(
backgroundColor: Colors.transparent, backgroundColor: Colors.transparent,
highlightColor: Colors.transparent, highlightColor: Colors.transparent,
padding: EdgeInsets.only(right: 0), padding: EdgeInsets.fromLTRB(20.rpx, 20.rpx, 20.rpx, 20.rpx),
onTap: () => Get.back(), onTap: () => Get.back(),
child: Container( child: Container(
// height: 42.rpx, // height: 42.rpx,

View File

@@ -144,7 +144,7 @@ class MHTLoginPage extends GetView<MHTLoginController> {
), ),
child: Scaffold( child: Scaffold(
backgroundColor: Colors.transparent, backgroundColor: Colors.transparent,
resizeToAvoidBottomInset: true, resizeToAvoidBottomInset: false,
appBar: AppBar( appBar: AppBar(
backgroundColor: Colors.transparent, backgroundColor: Colors.transparent,
automaticallyImplyLeading: false, automaticallyImplyLeading: false,
@@ -165,7 +165,7 @@ class MHTLoginPage extends GetView<MHTLoginController> {
// ), // ),
// ), // ),
Positioned( Positioned(
left: 20.rpx, left: 0.rpx,
child: returnIconButtomNew, child: returnIconButtomNew,
), ),
], ],
@@ -174,8 +174,6 @@ class MHTLoginPage extends GetView<MHTLoginController> {
actions: [], actions: [],
centerTitle: false, centerTitle: false,
), ),
// key: scaffoldKey,
body: PopScope( body: PopScope(
canPop: false, canPop: false,
onPopInvokedWithResult: (disposition, result) async { onPopInvokedWithResult: (disposition, result) async {
@@ -200,15 +198,18 @@ class MHTLoginPage extends GetView<MHTLoginController> {
mainAxisAlignment: MainAxisAlignment.spaceBetween, mainAxisAlignment: MainAxisAlignment.spaceBetween,
mainAxisSize: MainAxisSize.max, mainAxisSize: MainAxisSize.max,
children: [ children: [
SizedBox(
height: 50.rpx,
),
Expanded( Expanded(
child: Align(
alignment: AlignmentDirectional(0, 0),
child: Container( child: Container(
decoration: BoxDecoration(), decoration: BoxDecoration(),
child: Container( child: Container(
width: bodysize!.maxWidth, width: bodysize!.maxWidth,
decoration: BoxDecoration(), decoration: BoxDecoration(),
child: SingleChildScrollView(
child: Column( child: Column(
mainAxisAlignment: MainAxisAlignment.start,
mainAxisSize: MainAxisSize.max, mainAxisSize: MainAxisSize.max,
children: [ children: [
Obx(() { Obx(() {
@@ -1683,27 +1684,44 @@ class MHTLoginPage extends GetView<MHTLoginController> {
InkWell( InkWell(
onTap: () { onTap: () {
Get.toNamed( Get.toNamed(
"/findPasswordPage"); "/registerPage");
}, },
child: Text( child: Text.rich(
'找回密码'.tr, TextSpan(
children: [
TextSpan(
text: "还没有账号? ".tr,
style: TextStyle( style: TextStyle(
fontFamily: 'Readex Pro', color: Colors
color: stringToColor( .white, // 设置"还没有账号?"为白色
"#84F5FF"), fontFamily:
'Readex Pro',
fontSize: AppFontsize fontSize: AppFontsize
.small_text_size, .small_text_size,
letterSpacing: 0, ),
),
TextSpan(
text: '前往注册'.tr,
style: TextStyle(
color: stringToColor(
"#84F5FF"), // 保持"前往注册"为指定颜色
fontFamily:
'Readex Pro',
fontSize: AppFontsize
.small_text_size,
),
),
],
), ),
), ),
), ),
InkWell( InkWell(
onTap: () { onTap: () {
Get.toNamed( Get.toNamed(
"/registerPage"); "/findPasswordPage");
}, },
child: Text( child: Text(
'注册'.tr, '找回密码 '.tr,
style: TextStyle( style: TextStyle(
fontFamily: 'Readex Pro', fontFamily: 'Readex Pro',
color: stringToColor( color: stringToColor(