diff --git a/locales/en-US.yml b/locales/en-US.yml index 7f30959c12..28751cb7ef 100644 --- a/locales/en-US.yml +++ b/locales/en-US.yml @@ -55,6 +55,7 @@ addToAntenna: "Add to antenna" sendMessage: "Send a message" copyRSS: "Copy RSS" copyUsername: "Copy username" +openRemoteProfile: "Open remote profile" copyUserId: "Copy user ID" copyNoteId: "Copy note ID" copyFileId: "Copy file ID" diff --git a/locales/index.d.ts b/locales/index.d.ts index 8356046a6b..97fdd0f25e 100644 --- a/locales/index.d.ts +++ b/locales/index.d.ts @@ -58,6 +58,7 @@ export interface Locale { "sendMessage": string; "copyRSS": string; "copyUsername": string; + "openRemoteProfile": string; "copyUserId": string; "copyNoteId": string; "copyFileId": string; diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index 25ee9b1889..16d8d31694 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -55,6 +55,7 @@ addToAntenna: "アンテナに追加" sendMessage: "メッセージを送信" copyRSS: "RSSをコピー" copyUsername: "ユーザー名をコピー" +openRemoteProfile: "リモートプロファイルを開く" copyUserId: "ユーザーIDをコピー" copyNoteId: "ノートIDをコピー" copyFileId: "ファイルIDをコピー" diff --git a/packages/frontend/src/scripts/get-user-menu.ts b/packages/frontend/src/scripts/get-user-menu.ts index c8942314b2..41d0df1b72 100644 --- a/packages/frontend/src/scripts/get-user-menu.ts +++ b/packages/frontend/src/scripts/get-user-menu.ts @@ -176,7 +176,13 @@ export function getUserMenu(user: Misskey.entities.UserDetailed, router: Router const canonical = user.host === null ? `@${user.username}` : `@${user.username}@${toUnicode(user.host)}`; copyToClipboard(`${url}/${canonical}`); }, - }, { + }, ...(user.host ? [{ + icon: 'ph-share ph-bold ph-lg', + text: i18n.ts.openRemoteProfile, + action: () => { + open(`${user.uri}`, '_blank'); + }, + }] : []), { icon: 'ph-envelope ph-bold ph-lg', text: i18n.ts.sendMessage, action: () => {