mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
fix: 导入设置后首页标签无法修改
This commit is contained in:
@@ -20,8 +20,11 @@ class _TabbarSetPageState extends State<TabbarSetPage> {
|
|||||||
void initState() {
|
void initState() {
|
||||||
super.initState();
|
super.initState();
|
||||||
defaultTabs = tabsConfig;
|
defaultTabs = tabsConfig;
|
||||||
tabbarSort = settingStorage.get(SettingBoxKey.tabbarSort,
|
tabbarSort = settingStorage
|
||||||
defaultValue: ['live', 'rcmd', 'hot', 'rank', 'bangumi']);
|
.get(SettingBoxKey.tabbarSort,
|
||||||
|
defaultValue: ['live', 'rcmd', 'hot', 'rank', 'bangumi'])
|
||||||
|
.map<String>((i) => i.toString())
|
||||||
|
.toList();
|
||||||
// 对 tabData 进行排序
|
// 对 tabData 进行排序
|
||||||
defaultTabs.sort((a, b) {
|
defaultTabs.sort((a, b) {
|
||||||
int indexA = tabbarSort.indexOf((a['type'] as TabType).id);
|
int indexA = tabbarSort.indexOf((a['type'] as TabType).id);
|
||||||
@@ -89,6 +92,8 @@ class _TabbarSetPageState extends State<TabbarSetPage> {
|
|||||||
physics: const NeverScrollableScrollPhysics(),
|
physics: const NeverScrollableScrollPhysics(),
|
||||||
footer: SizedBox(
|
footer: SizedBox(
|
||||||
height: MediaQuery.of(context).padding.bottom + 30,
|
height: MediaQuery.of(context).padding.bottom + 30,
|
||||||
|
child: const Align(
|
||||||
|
alignment: Alignment.centerRight, child: Text('*长按拖动排序 ')),
|
||||||
),
|
),
|
||||||
children: listTiles,
|
children: listTiles,
|
||||||
),
|
),
|
||||||
|
|||||||
Reference in New Issue
Block a user