This commit is contained in:
syuilo 2018-04-09 19:23:52 +09:00
parent 2560d3d1c1
commit 48d540e9f4
4 changed files with 6 additions and 6 deletions

View File

@ -10,6 +10,6 @@ Vue.filter('userName', user => {
return getUserName(user);
});
Vue.filter('userPage', user => {
return '/@' + Vue.filter('acct')(user);
Vue.filter('userPage', (user, path?) => {
return '/@' + Vue.filter('acct')(user) + (path ? '/' + path : '');
});

View File

@ -57,7 +57,7 @@ init(async (launch) => {
{ path: '/othello', component: MkOthello },
{ path: '/othello/:game', component: MkOthello },
{ path: '/@:user', component: MkUser },
{ path: '/@:user/:note', component: MkNote }
{ path: '/notes/:note', component: MkNote }
]
});

View File

@ -68,7 +68,7 @@ init((launch) => {
{ path: '/@:user', component: MkUser },
{ path: '/@:user/followers', component: MkFollowers },
{ path: '/@:user/following', component: MkFollowing },
{ path: '/@:user/:note', component: MkNote }
{ path: '/notes/:note', component: MkNote }
]
});

View File

@ -30,11 +30,11 @@
<b>{{ user.notesCount | number }}</b>
<i>%i18n:mobile.tags.mk-user.notes%</i>
</a>
<a :href="`${user | userPage}/following`">
<a :href="user | userPage('following')">
<b>{{ user.followingCount | number }}</b>
<i>%i18n:mobile.tags.mk-user.following%</i>
</a>
<a :href="`${user | userPage}/followers`">
<a :href="user | userPage('followers')">
<b>{{ user.followersCount | number }}</b>
<i>%i18n:mobile.tags.mk-user.followers%</i>
</a>