2024-04-10 16:26:11 +08:00
|
|
|
|
2023-07-10 17:50:31 +08:00
|
|
|
import 'package:flutter/cupertino.dart';
|
2024-05-14 09:32:06 +08:00
|
|
|
import 'package:flutter/material.dart';
|
2023-07-10 17:50:31 +08:00
|
|
|
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
2023-11-28 13:47:49 +08:00
|
|
|
import 'package:get/get.dart';
|
2023-10-17 15:48:32 +08:00
|
|
|
import 'package:star_lock/app_settings/app_colors.dart';
|
2023-07-10 17:50:31 +08:00
|
|
|
|
|
|
|
|
class NoData extends StatelessWidget {
|
2024-01-25 17:40:41 +08:00
|
|
|
double? noDataHeight;
|
|
|
|
|
NoData({Key? key, this.noDataHeight}) : super(key: key);
|
2023-07-10 17:50:31 +08:00
|
|
|
|
|
|
|
|
@override
|
|
|
|
|
Widget build(BuildContext context) {
|
2024-01-25 17:40:41 +08:00
|
|
|
return SingleChildScrollView(
|
|
|
|
|
child: SizedBox(
|
|
|
|
|
width: 1.sw,
|
|
|
|
|
height: noDataHeight ?? 1.sh - ScreenUtil().statusBarHeight,
|
|
|
|
|
// height: 1.sw,
|
2024-05-14 09:32:06 +08:00
|
|
|
// color: Colors.red,
|
2024-01-25 17:40:41 +08:00
|
|
|
child: Center(
|
|
|
|
|
child: Column(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
|
children: [
|
2024-04-10 16:26:11 +08:00
|
|
|
Image.asset('images/icon_noData.png', width: 160.w, height: 180.h,),
|
2024-07-31 17:24:30 +08:00
|
|
|
Text('暂无数据'.tr,
|
2024-04-10 16:26:11 +08:00
|
|
|
style: TextStyle(color: AppColors.darkGrayTextColor, fontSize: 22.sp),
|
2024-01-25 17:40:41 +08:00
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
)),
|
|
|
|
|
),
|
2023-07-10 17:50:31 +08:00
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
}
|