Add clickable icons to timeline

This commit is contained in:
Tim
2025-07-09 18:03:50 +08:00
parent 5554594123
commit 8feb488c0e
4 changed files with 23 additions and 5 deletions

View File

@@ -59,6 +59,7 @@
<script>
import { ref, onMounted } from 'vue'
import { useRouter } from 'vue-router'
import { API_BASE_URL } from '../main'
import BaseTimeline from '../components/BaseTimeline.vue'
import { getToken } from '../utils/auth'
@@ -71,6 +72,7 @@ export default {
name: 'MessagePageView',
components: { BaseTimeline },
setup() {
const router = useRouter()
const notifications = ref([])
const isLoadingMessage = ref(false)
@@ -112,6 +114,7 @@ export default {
notifications.value.push({
...n,
src: n.comment.author.avatar,
iconClick: () => router.push(`/users/${n.comment.author.id}`)
})
} else {
notifications.value.push({