fix(a11y): disabled nav side links (#529)

Co-authored-by: Daniel Roe <daniel@roe.dev>
zio/stable
Joaquín Sánchez 2022-12-28 21:35:26 +01:00 committed by GitHub
parent 732011b520
commit 347cfff358
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 9 additions and 1 deletions

View File

@ -44,7 +44,15 @@ const noUserVisual = computed(() => isMastoInitialised.value && props.userOnly &
</script>
<template>
<NuxtLink :to="to" :disabled="noUserDisable" :class="noUserVisual ? 'op25 pointer-events-none ' : ''" :active-class="activeClass" group focus:outline-none @click="$scrollToTop">
<NuxtLink
:to="to"
:disabled="noUserDisable"
:class="noUserVisual ? 'op25 pointer-events-none ' : ''"
:active-class="activeClass"
group focus:outline-none disabled:pointer-events-none
:tabindex="noUserDisable ? -1 : null"
@click="$scrollToTop"
>
<CommonTooltip :disabled="!isMediumScreen" :content="text" placement="right">
<div
flex items-center gap4