From 6b32eae5209d38a04771984851e5391f63f610ed Mon Sep 17 00:00:00 2001 From: limepotato Date: Wed, 10 Jul 2024 21:21:38 -0600 Subject: [PATCH] make visible always on mobile --- packages/client/src/ui/universal.vue | 47 ++-------------------------- 1 file changed, 2 insertions(+), 45 deletions(-) diff --git a/packages/client/src/ui/universal.vue b/packages/client/src/ui/universal.vue index 86d4ab01f..7e8368a21 100644 --- a/packages/client/src/ui/universal.vue +++ b/packages/client/src/ui/universal.vue @@ -93,7 +93,7 @@ - @@ -217,11 +206,7 @@ function updateButtonState(): void { buttonAnimIndex.value = 1; return; } - if (routerState.includes("/my/messaging")) { - buttonAnimIndex.value = 2; - return; - } - buttonAnimIndex.value = 3; + buttonAnimIndex.value = 2; } updateButtonState(); @@ -277,34 +262,6 @@ function messagingStart(ev) { ); } -async function startUser(): void { - os.selectUser().then((user) => { - mainRouter.push(`/my/messaging/${Acct.toString(user)}`); - }); -} - -async function startGroup(): void { - const groups1 = await os.api("users/groups/owned"); - const groups2 = await os.api("users/groups/joined"); - if (groups1.length === 0 && groups2.length === 0) { - os.alert({ - type: "warning", - title: i18n.ts.youHaveNoGroups, - text: i18n.ts.joinOrCreateGroup, - }); - return; - } - const { canceled, result: group } = await os.select({ - title: i18n.ts.group, - items: groups1.concat(groups2).map((group) => ({ - value: group, - text: group.name, - })), - }); - if (canceled) return; - mainRouter.push(`/my/messaging/group/${group.id}`); -} - onMounted(() => { if (!isDesktop.value) { matchMedia(`(min-width: ${DESKTOP_THRESHOLD - 1}px)`).onchange = (