fix: remove relative timestamp from tab focus order (#1534)

fixes #1533
pull/1541/head
Nolan Lawson 2019-09-24 22:30:26 -07:00 zatwierdzone przez GitHub
rodzic b8b6556a14
commit af27c8b26b
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
1 zmienionych plików z 7 dodań i 1 usunięć

Wyświetl plik

@ -2,6 +2,7 @@
class="status-relative-date {isStatusInNotification ? 'status-in-notification' : '' }"
href="/statuses/{originalStatusId}"
rel="prefetch"
{tabindex}
>
<time datetime={createdAtDate} title={absoluteFormattedDate}
aria-label="{timeagoFormattedDate} – click to show thread">
@ -32,7 +33,12 @@
<script>
export default {
computed: {
elementId: ({ uuid }) => `status-relative-date-${uuid}`
elementId: ({ uuid }) => `status-relative-date-${uuid}`,
tabindex: ({ $disableTapOnStatus }) => (
// If you can't tap on the entire status, then you need some way to click on it. Otherwise it's
// just a duplicate link in the focus order.
$disableTapOnStatus ? '0' : '-1'
)
}
}
</script>