kopia lustrzana https://github.com/elk-zone/elk
feat: show `quote` type notification
rodzic
83d1f5c66c
commit
37ec9e0f73
|
|
@ -25,6 +25,7 @@ const supportedNotificationTypes: NotificationType[] = [
|
|||
'update',
|
||||
'status',
|
||||
'annual_report',
|
||||
'quote',
|
||||
]
|
||||
|
||||
// well-known emoji reactions types Elk does not support yet
|
||||
|
|
@ -130,7 +131,14 @@ const timeAgo = useTimeAgo(() => notification.createdAt, timeAgoOptions)
|
|||
</template>
|
||||
</StatusCard>
|
||||
</template>
|
||||
<template v-else-if="notification.type === 'mention' || notification.type === 'poll' || notification.type === 'status'">
|
||||
<template
|
||||
v-else-if="
|
||||
notification.type === 'mention'
|
||||
|| notification.type === 'poll'
|
||||
|| notification.type === 'status'
|
||||
|| notification.type === 'quote'
|
||||
"
|
||||
>
|
||||
<StatusCard :status="notification.status!" />
|
||||
</template>
|
||||
<template v-else-if="notification.type === 'annual_report'">
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ const virtualScroller = false // TODO: fix flickering issue with virtual scroll
|
|||
|
||||
const groupCapacity = Number.MAX_VALUE // No limit
|
||||
|
||||
const includeNotificationTypes: mastodon.v1.NotificationType[] = ['update', 'mention', 'poll', 'status']
|
||||
const includeNotificationTypes: mastodon.v1.NotificationType[] = ['update', 'mention', 'poll', 'status', 'quote']
|
||||
|
||||
let id = 0
|
||||
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ export const STORAGE_KEY_BOTTOM_NAV_BUTTONS = 'elk-bottom-nav-buttons'
|
|||
|
||||
export const HANDLED_MASTO_URLS = /^(https?:\/\/)?([\w\-]+\.)+\w+\/(@[@\w\-.]+)(\/objects)?(\/\d+)?$/
|
||||
|
||||
export const NOTIFICATION_FILTER_TYPES: mastodon.v1.NotificationType[] = ['status', 'reblog', 'follow', 'follow_request', 'favourite', 'poll', 'update', 'admin.sign_up', 'admin.report']
|
||||
export const NOTIFICATION_FILTER_TYPES: mastodon.v1.NotificationType[] = ['status', 'reblog', 'follow', 'follow_request', 'favourite', 'poll', 'update', 'admin.sign_up', 'admin.report', 'quote']
|
||||
|
||||
export const THEME_COLORS = {
|
||||
defaultTheme: '#cc7d24',
|
||||
|
|
|
|||
|
|
@ -49,6 +49,7 @@ const filterIconMap: Record<mastodon.v1.NotificationType, string> = {
|
|||
'admin.report': 'i-ri:flag-line',
|
||||
'severed_relationships': 'i-ri:user-unfollow-line',
|
||||
'moderation_warning': 'i-ri:error-warning-line',
|
||||
'quote': 'i-ri:double-quotes-l',
|
||||
}
|
||||
|
||||
const filterText = computed(() => `${t('tab.notifications_more_tooltip')}${filter.value ? `: ${t(`tab.notifications_${filter.value}`)}` : ''}`)
|
||||
|
|
|
|||
|
|
@ -676,6 +676,7 @@
|
|||
"notifications_mention": "Mentions",
|
||||
"notifications_more_tooltip": "Filter notifications by type",
|
||||
"notifications_poll": "Poll",
|
||||
"notifications_quote": "Quote",
|
||||
"notifications_reblog": "Boost",
|
||||
"notifications_status": "Status",
|
||||
"notifications_update": "Update",
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
// I just copy/paste any entry from masto api and convert it to snake case, reusing types not including camel case props
|
||||
import type { mastodon } from 'masto'
|
||||
|
||||
export type NotificationType = 'mention' | 'status' | 'reblog' | 'follow' | 'follow_request' | 'favourite' | 'poll' | 'update' | 'admin.sign_up' | 'admin.report'
|
||||
export type NotificationType = 'mention' | 'status' | 'reblog' | 'follow' | 'follow_request' | 'favourite' | 'poll' | 'update' | 'admin.sign_up' | 'admin.report' | 'quote'
|
||||
|
||||
export interface PushPayload {
|
||||
access_token: string
|
||||
|
|
|
|||
Ładowanie…
Reference in New Issue