非ASCIIなドメインへのメンションの修正 (#2903)

* punycodeでされたmentionのラベルをunicodeとして表示する

* post-form mentionはpunycodeにする

* mentionの表示はURLもAPI向けもunicodeにする
This commit is contained in:
MeiMei
2018-10-14 16:56:19 +09:00
committed by syuilo
parent be82d845a4
commit 5dce81c0db
6 changed files with 27 additions and 13 deletions

View File

@@ -116,16 +116,16 @@ export default Vue.component('misskey-flavored-markdown', {
case 'mention': {
return (createElement as any)('a', {
attrs: {
href: `${url}/@${getAcct(token)}`,
href: `${url}/${token.canonical}`,
target: '_blank',
dataIsMe: (this as any).i && getAcct((this as any).i) == getAcct(token),
style: 'color:var(--mfmMention);'
},
directives: [{
name: 'user-preview',
value: token.content
value: token.canonical
}]
}, token.content);
}, token.canonical);
}
case 'hashtag': {