feat: cleanup locale conf and add some RTL stuff (#564)
This commit is contained in:
parent
29b7cb3838
commit
6412127283
8 changed files with 47 additions and 17 deletions
|
@ -10,7 +10,17 @@ const { notification } = defineProps<{
|
|||
<article flex flex-col relative>
|
||||
<template v-if="notification.type === 'follow'">
|
||||
<NuxtLink :to="getAccountRoute(notification.account)">
|
||||
<div flex items-center absolute pl-3 pr-4 py-3 bg-base rounded-br-3 top-0 left-0>
|
||||
<div
|
||||
flex items-center absolute
|
||||
pl-3 pr-4 lrt-left-0
|
||||
rounded-br-3
|
||||
rtl="pr-3 pl-4 right-0"
|
||||
rtl-rounded-bl-3
|
||||
rtl-rounded-br-0
|
||||
py-3 bg-base top-0
|
||||
:lang="notification.status?.language ?? undefined"
|
||||
:dir="notification.status?.language ? 'auto' : 'ltr'"
|
||||
>
|
||||
<div i-ri:user-follow-fill mr-1 color-primary />
|
||||
<ContentRich
|
||||
text-primary mr-1 font-bold line-clamp-1 ws-pre-wrap break-all
|
||||
|
@ -21,7 +31,11 @@ const { notification } = defineProps<{
|
|||
{{ $t('notification.followed_you') }}
|
||||
</span>
|
||||
</div>
|
||||
<AccountBigCard :account="notification.account" />
|
||||
<AccountBigCard
|
||||
:account="notification.account"
|
||||
:lang="notification.status?.language ?? undefined"
|
||||
:dir="notification.status?.language ? 'auto' : 'ltr'"
|
||||
/>
|
||||
</NuxtLink>
|
||||
</template>
|
||||
<template v-else-if="notification.type === 'admin.sign_up'">
|
||||
|
|
|
@ -10,10 +10,16 @@ const { formatHumanReadableNumber, forSR } = useHumanReadableNumber()
|
|||
const count = $computed(() => items.items.length)
|
||||
const addSR = $computed(() => forSR(count))
|
||||
const isExpanded = ref(false)
|
||||
const lang = $computed(() => {
|
||||
return count > 1 || count === 0 ? undefined : items.items[0].status?.language
|
||||
})
|
||||
const dir = $computed(() => {
|
||||
return lang ? 'auto' : 'ltr'
|
||||
})
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<article flex flex-col relative>
|
||||
<article flex flex-col relative :lang="lang ?? undefined" :dir="dir">
|
||||
<div flex items-center top-0 left-2 pt-2 px-3>
|
||||
<div i-ri:user-follow-fill mr-3 color-primary aria-hidden="true" />
|
||||
<template v-if="count > 1">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue