feat: query param based navigation

This commit is contained in:
2025-12-13 21:56:52 +01:00
parent 657f8630c3
commit 464277e58f
7 changed files with 18 additions and 56 deletions

View File

@@ -36,6 +36,7 @@ const { selectedButton: selected, selectorPosition } = useButtonNavigation({
if (isSubmenu(buttonName)) {
router.push({
query: {
screen: "settings",
menu: buttonName,
},
});
@@ -153,11 +154,12 @@ watch(
if (isSubmenu(newSelected)) {
router.push({
query: {
screen: "settings",
menu: newSelected.split(/[A-Z]/)[0],
},
});
} else {
router.push({ query: { menu: undefined } });
router.push({ query: { screen: "settings", menu: undefined } });
}
}
},