feat: add support for the Web Share Target API (#1100)
Co-authored-by: userquin <userquin@gmail.com>
This commit is contained in:
parent
a6a825e553
commit
bede92404b
11 changed files with 221 additions and 7 deletions
|
@ -5,8 +5,12 @@ export default defineNuxtRouteMiddleware((to) => {
|
|||
return
|
||||
|
||||
onMastoInit(() => {
|
||||
if (!currentUser.value)
|
||||
return navigateTo(`/${currentServer.value}/public/local`)
|
||||
if (!currentUser.value) {
|
||||
if (to.path === '/home' && to.query['share-target'] !== undefined)
|
||||
return navigateTo('/share-target')
|
||||
else
|
||||
return navigateTo(`/${currentServer.value}/public/local`)
|
||||
}
|
||||
if (to.path === '/')
|
||||
return navigateTo('/home')
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue