2019-02-23 12:32:00 -08:00
|
|
|
|
<a id={elementId}
|
|
|
|
|
class="status-relative-date {isStatusInNotification ? 'status-in-notification' : '' }"
|
2018-05-01 17:05:36 -07:00
|
|
|
|
href="/statuses/{originalStatusId}"
|
2019-02-13 18:40:02 -08:00
|
|
|
|
rel="prefetch"
|
2019-09-24 22:30:26 -07:00
|
|
|
|
{tabindex}
|
2018-02-10 13:57:04 -08:00
|
|
|
|
>
|
2019-01-13 15:56:39 -08:00
|
|
|
|
<time datetime={createdAtDate} title={absoluteFormattedDate}
|
2018-11-25 01:20:58 -08:00
|
|
|
|
aria-label="{timeagoFormattedDate} – click to show thread">
|
|
|
|
|
{timeagoFormattedDate}
|
2018-03-15 20:04:24 -07:00
|
|
|
|
</time>
|
2018-02-09 22:55:11 -08:00
|
|
|
|
</a>
|
|
|
|
|
<style>
|
|
|
|
|
.status-relative-date {
|
|
|
|
|
grid-area: relative-date;
|
|
|
|
|
align-self: center;
|
|
|
|
|
margin-left: 5px;
|
|
|
|
|
margin-right: 10px;
|
|
|
|
|
font-size: 1.1em;
|
|
|
|
|
text-align: right;
|
|
|
|
|
white-space: nowrap;
|
|
|
|
|
}
|
|
|
|
|
.status-relative-date, .status-relative-date:hover, .status-relative-date:visited {
|
|
|
|
|
color: var(--deemphasized-text-color);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.status-relative-date.status-in-notification,
|
|
|
|
|
.status-relative-date.status-in-notification:hover,
|
|
|
|
|
.status-relative-date.status-in-notification:visited {
|
|
|
|
|
color: var(--very-deemphasized-text-color);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
</style>
|
|
|
|
|
<script>
|
|
|
|
|
export default {
|
|
|
|
|
computed: {
|
2019-09-24 22:30:26 -07:00
|
|
|
|
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'
|
|
|
|
|
)
|
2018-02-09 22:55:11 -08:00
|
|
|
|
}
|
|
|
|
|
}
|
2019-01-13 15:56:39 -08:00
|
|
|
|
</script>
|