mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
feat: 侧边栏适配异形屏、分区子侧栏内边距优化
This commit is contained in:
@@ -39,10 +39,9 @@ class _MainAppState extends State<MainApp> with SingleTickerProviderStateMixin {
|
||||
_mainController.pageController =
|
||||
PageController(initialPage: _mainController.selectedIndex);
|
||||
enableMYBar = setting.get(SettingBoxKey.enableMYBar, defaultValue: true);
|
||||
useSideBar =
|
||||
setting.get(SettingBoxKey.useSideBar, defaultValue: false);
|
||||
enableGradientBg = setting.get(SettingBoxKey.enableGradientBg,
|
||||
defaultValue: true);
|
||||
useSideBar = setting.get(SettingBoxKey.useSideBar, defaultValue: false);
|
||||
enableGradientBg =
|
||||
setting.get(SettingBoxKey.enableGradientBg, defaultValue: true);
|
||||
}
|
||||
|
||||
void setIndex(int value) async {
|
||||
@@ -152,7 +151,7 @@ class _MainAppState extends State<MainApp> with SingleTickerProviderStateMixin {
|
||||
children: [
|
||||
if (useSideBar) ...[
|
||||
SizedBox(
|
||||
width: 55,
|
||||
width: 55 + MediaQuery.of(context).padding.left,
|
||||
child: NavigationRail(
|
||||
groupAlignment: 0.0,
|
||||
minWidth: 40.0,
|
||||
@@ -170,8 +169,11 @@ class _MainAppState extends State<MainApp> with SingleTickerProviderStateMixin {
|
||||
DynamicBadgeMode.number
|
||||
? Text(e['count'].toString())
|
||||
: null,
|
||||
padding:
|
||||
const EdgeInsets.fromLTRB(2, 0, 2, 0),
|
||||
padding: EdgeInsets.fromLTRB(
|
||||
2 + MediaQuery.of(context).padding.left,
|
||||
0,
|
||||
2,
|
||||
0),
|
||||
isLabelVisible:
|
||||
_mainController.dynamicBadgeType !=
|
||||
DynamicBadgeMode.hidden &&
|
||||
|
||||
Reference in New Issue
Block a user