diff --git a/packages/client/src/components/notification.vue b/packages/client/src/components/notification.vue index 1a360f990..556df8863 100644 --- a/packages/client/src/components/notification.vue +++ b/packages/client/src/components/notification.vue @@ -60,6 +60,7 @@ + {{ $ts.youGotNewFollower }}
{{ $ts.followRequestAccepted }} {{ $ts.receiveFollowRequest }}
|
@@ -165,8 +166,19 @@ export default defineComponent({ }, {}, 'closed'); }); + function openRenoteDestination(remoteUser: User): void { + os.api('users/show', {userId: remoteUser.id}).then(user => { + if (user.host != null && user.followersCount === 0) { // リモートユーザーかつローカルの人間が誰もフォローしていない(最新の投稿が取得できない)ユーザー + window.open(user.url, '_blank', 'rel="nofollow noopener"'); + } else { + os.pageWindow('/@' + user.username + (user.host ? `@${user.host}` : '')); + } + }); + } + return { getNoteSummary: (note: misskey.entities.Note) => getNoteSummary(note), + openRenoteDestination: (remoteUser: misskey.entities.User) => openRenoteDestination(remoteUser), followRequestDone, groupInviteDone, notePage,