splash_view.dart 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141
  1. import 'package:clean/base/base_page.dart';
  2. import 'package:clean/module/main/main_view.dart';
  3. import 'package:clean/module/splash/splash_controller.dart';
  4. import 'package:clean/resource/assets.gen.dart';
  5. import 'package:clean/resource/string.gen.dart';
  6. import 'package:flutter/Material.dart';
  7. import 'package:flutter/cupertino.dart';
  8. import 'package:flutter/src/widgets/framework.dart';
  9. import 'package:flutter_screenutil/flutter_screenutil.dart';
  10. import 'package:get/get_core/src/get_main.dart';
  11. import 'package:lottie/lottie.dart';
  12. class SplashPage extends BasePage<SplashController> {
  13. const SplashPage({super.key});
  14. @override
  15. bool immersive() {
  16. return true;
  17. }
  18. @override
  19. bool statusBarDarkFont() {
  20. return false;
  21. }
  22. @override
  23. Widget buildBody(BuildContext context) {
  24. return Stack(children: [
  25. Container(
  26. width: double.infinity,
  27. height: double.infinity,
  28. child: SafeArea(
  29. child: Container(
  30. child: Column(
  31. crossAxisAlignment: CrossAxisAlignment.center,
  32. mainAxisAlignment: MainAxisAlignment.center,
  33. children: [
  34. SizedBox(
  35. child: Lottie.asset(
  36. Assets.anim.animSplash,
  37. controller: controller.animation,
  38. width: 150.w,
  39. height: 150.w,
  40. repeat: true,
  41. )),
  42. Text(
  43. StringName.appName,
  44. textAlign: TextAlign.center,
  45. style: TextStyle(
  46. color: Colors.white,
  47. fontSize: 24.sp,
  48. fontWeight: FontWeight.w900,
  49. ),
  50. ),
  51. ],
  52. ),
  53. )),
  54. ),
  55. IgnorePointer(
  56. child: Assets.images.bgPhotoSelectedPreviewFinish.image(
  57. width: 360.w,
  58. height: 335.h,
  59. ),
  60. ),
  61. ]);
  62. }
  63. // Widget _finishCleanCard() {
  64. // return Container(
  65. // width: 360.w,
  66. // child: Column(
  67. // mainAxisAlignment: MainAxisAlignment.start,
  68. // children: [
  69. // Spacer(
  70. // flex: 3,
  71. // ),
  72. // Text(
  73. // 'Great!',
  74. // textAlign: TextAlign.center,
  75. // style: TextStyle(
  76. // color: Colors.white,
  77. // fontSize: 32.sp,
  78. // fontWeight: FontWeight.w700,
  79. // ),
  80. // ),
  81. // SizedBox(height: 14.h),
  82. // Text(
  83. // "You've completed 1 photo review",
  84. // textAlign: TextAlign.center,
  85. // style: TextStyle(
  86. // color: Colors.white.withValues(alpha: 0.8),
  87. // fontSize: 16.sp,
  88. // fontWeight: FontWeight.w400,
  89. // ),
  90. // ),
  91. // SizedBox(height: 47.h),
  92. // // Assets.images.iconPhotoSelectedPreviewFireworks.image(
  93. // // width: 158.w,
  94. // // height: 158.h,
  95. // // ),
  96. //
  97. // SizedBox(
  98. // child: Lottie.asset(
  99. // Assets.anim.animPhotoSelectedPreviewFireworks,
  100. // width: 158.w,
  101. // height: 158.w,
  102. // repeat: false,
  103. // )),
  104. //
  105. // Spacer(
  106. // flex: 5,
  107. // ),
  108. // ],
  109. // ),
  110. // );
  111. // }
  112. // Stack(children: [
  113. // Container(
  114. // child: SafeArea(
  115. // child: Column(
  116. // children: [
  117. // SizedBox(
  118. // child: Lottie.asset(
  119. // Assets.anim.animPhotoSelectedPreviewFireworks,
  120. // width: 150.w,
  121. // height: 150.w,
  122. // repeat: true,
  123. // )),
  124. // ],
  125. // )),
  126. // ),
  127. // IgnorePointer(
  128. // child: Assets.images.bgPhotoSelectedPreviewFinish.image(
  129. // width: 360.w,
  130. // height: 335.h,
  131. // ),
  132. // ),
  133. // ]);
  134. }