Flutter:图片在弹窗外部的UI布局

图片在弹窗外部的UI布局

js 复制代码
// 签到
void signIn() async{
  if(signInStatus) return Loading.toast('今日已签到');
  signinAmount = await HomeApi.signin();
  if(signinAmount.amount == null) return;
  refreshController.requestRefresh();
  _initData();
  showGeneralDialog(
    context: Get.context!,
    pageBuilder: (BuildContext buildContext, Animation<double> animation, Animation<double> secondaryAnimation) {
      return TDAlertDialog(
        title: '',
        backgroundColor: Colors.transparent,
        padding: const EdgeInsets.all(0),
        buttonWidget:<Widget>[].toRow(),
        contentWidget:<Widget>[
          <Widget>[
            SizedBox(height: 200.w,),
            TextWidget.body('今日签到成功',size: 36.sp,color: AppTheme.colorfff,weight: FontWeight.bold,),
            <Widget>[
              TDImage(assetUrl: 'assets/img/home9.png',width: 44.w,height: 44.w,type: TDImageType.square,),
              SizedBox(width: 10.w,),
              TextWidget.body('星火+${signinAmount.amount}',size: 28.sp,color: AppTheme.colorfff,),
            ].toRow(mainAxisAlignment: MainAxisAlignment.center)
            .paddingHorizontal(30.w)
            .backgroundColor(AppTheme.blockTwoBgColor)
            .height(88.w)
            .marginOnly(top: 20.w,bottom: 30.w)
            .clipRRect(all: 10.w),

            TDButton(
            text: '确认',
            isBlock: true,
            width: 690.w,
            height: 76.w,
            padding: const EdgeInsets.all(0),
            margin: const EdgeInsets.all(0),
            style: TDButtonStyle(
              backgroundColor:  AppTheme.primary,
              textColor: Colors.white,
              radius: BorderRadius.circular(10.w),
            ),
            textStyle: TextStyle(
              fontSize: 28.sp,
              fontWeight: FontWeight.w600,
            ),
            onTap: () {
              Navigator.pop(Get.context!);
            },
          ),

          ].toColumn(crossAxisAlignment: CrossAxisAlignment.center)
          .paddingHorizontal(30.w)
          .tight(width: 550.w,height: 500.w)
          .decorated(
            borderRadius: BorderRadius.circular(20.w),
            border: Border.all(color: AppTheme.primary,width: 1),
          )
          .backgroundColor(AppTheme.blockBgColor).positioned(top: 170.w),

          TDImage(assetUrl: 'assets/img/home11.png',width: 368.w,height: 302.w,type: TDImageType.square,).positioned(left: 90.w),
        ].toStack().tight(width: 650.w,height: 700.w)
        .marginOnly(top: 20.w),
      );
    },
  );
  update(["sign_in"]);
}
相关推荐
阅文作家助手开发团队_山神3 小时前
第四章(下):Delta 到 HTML 转换的核心方法解析
flutter
叹一曲当时只道是寻常5 小时前
AI书签管理工具开发全记录(十三):TUI基本框架搭建
ui·go
xiaoyan20156 小时前
flutter3.32+deepseek+dio+markdown搭建windows版流式输出AI模板
flutter·openai·deepseek
阅文作家助手开发团队_山神6 小时前
第四章(上):HTML 到 Delta 转换的核心方法解析
flutter
stringwu7 小时前
Flutter高效开发利器:Riverpod框架简介及实践指南
flutter
耳東陈7 小时前
Flutter开箱即用一站式解决方案2.0-全局无需Context的Toast
flutter
海尔辛18 小时前
Unity UI 性能优化--Sprite 篇
ui·unity·性能优化
QQ676580081 天前
基于 PyTorch 的 VGG16 深度学习人脸识别检测系统的实现+ui界面
人工智能·pytorch·python·深度学习·ui·人脸识别
阅文作家助手开发团队_山神1 天前
第三章: Flutter-quill 数据格式Delta
flutter
阅文作家助手开发团队_山神1 天前
第二章:Document 模块与 DOM 树详解
flutter