更新页面

This commit is contained in:
wyf
2025-04-16 14:27:10 +08:00
parent 146462b467
commit 1765403f21
58 changed files with 7821 additions and 433 deletions

View File

@@ -90,47 +90,56 @@ class MainPageBottomChange extends GetView<MainPageController> {
floatingActionButton: Container(),
);
} else {
return Scaffold(
backgroundColor: Colors.transparent,
body: arr[controller.model.currentIndex],
floatingActionButtonAnimator:
FloatingActionButtonAnimator.noAnimation,
floatingActionButtonLocation:
FloatingActionButtonLocation.centerDocked,
bottomNavigationBar: Theme(
data: ThemeData(
splashFactory: NoSplash.splashFactory,
highlightColor: Colors.transparent),
child: BottomNavigationBar(
unselectedItemColor: themeController.currentColor.sc4,
selectedItemColor: themeController.currentColor.sc1,
backgroundColor: themeController.currentColor.sc5,
selectedFontSize: 26.rpx,
unselectedFontSize: 26.rpx,
type: BottomNavigationBarType.fixed,
currentIndex: controller.model.currentIndex,
onTap: (index) {
Future.delayed(const Duration(milliseconds: 500), () {
if (controller.model.currentIndex != 1) {
globalController.model.hideBottomNavigationBar = false;
globalController.updateAll();
}
});
controller.model.currentIndex = index;
controller.updateAll();
},
items: [
getBottomNavigationBarItem("assets/img/menu/home.svg",
"assets/img/menu/n_home.svg", "菜单.首页".tr),
// getBottomNavigationBarItem("assets/img/menu/report.svg",
// "assets/img/menu/n_report.svg", "菜单.报告".tr),
getBottomNavigationBarItem("assets/img/menu/e.svg",
"assets/img/menu/n_e.svg", "菜单.小e".tr),
getBottomNavigationBarItem("assets/img/menu/message.svg",
"assets/img/menu/n_message.svg", "菜单.消息".tr),
getBottomNavigationBarItem("assets/img/menu/mine.svg",
"assets/img/menu/n_mine.svg", "菜单.我的".tr),
],
return Container(
decoration: BoxDecoration(
image: DecorationImage(
image: AssetImage('assets/img/bgImage.png'), // 本地图片
fit: BoxFit.fill, // 填满整个 Container
),
),
child: Scaffold(
backgroundColor: Colors.transparent,
body: arr[controller.model.currentIndex],
floatingActionButtonAnimator:
FloatingActionButtonAnimator.noAnimation,
floatingActionButtonLocation:
FloatingActionButtonLocation.centerDocked,
bottomNavigationBar: Theme(
data: ThemeData(
splashFactory: NoSplash.splashFactory,
highlightColor: Colors.transparent),
child: BottomNavigationBar(
unselectedItemColor: themeController.currentColor.sc4,
selectedItemColor: themeController.currentColor.sc1,
backgroundColor: themeController.currentColor.sc5,
selectedFontSize: 26.rpx,
unselectedFontSize: 26.rpx,
type: BottomNavigationBarType.fixed,
currentIndex: controller.model.currentIndex,
onTap: (index) {
Future.delayed(const Duration(milliseconds: 500), () {
if (controller.model.currentIndex != 1) {
globalController.model.hideBottomNavigationBar =
false;
globalController.updateAll();
}
});
controller.model.currentIndex = index;
controller.updateAll();
},
items: [
getBottomNavigationBarItem("assets/img/menu/home.svg",
"assets/img/menu/n_home.svg", "菜单.首页".tr),
// getBottomNavigationBarItem("assets/img/menu/report.svg",
// "assets/img/menu/n_report.svg", "菜单.报告".tr),
getBottomNavigationBarItem("assets/img/menu/e.svg",
"assets/img/menu/n_e.svg", "菜单.小e".tr),
getBottomNavigationBarItem("assets/img/menu/message.svg",
"assets/img/menu/n_message.svg", "菜单.消息".tr),
getBottomNavigationBarItem("assets/img/menu/mine.svg",
"assets/img/menu/n_mine.svg", "菜单.我的".tr),
],
),
),
),
);