merge: upstream
This commit is contained in:
commit
11628e4b6a
285 changed files with 3413 additions and 1913 deletions
|
|
@ -15,7 +15,7 @@ import { defaultStore, userActions } from '@/store.js';
|
|||
import { $i, iAmModerator } from '@/account.js';
|
||||
import { IRouter } from '@/nirax.js';
|
||||
import { antennasCache, rolesCache, userListsCache } from '@/cache.js';
|
||||
import { mainRouter } from '@/global/router/main.js';
|
||||
import { mainRouter } from '@/router/main.js';
|
||||
|
||||
export function getUserMenu(user: Misskey.entities.UserDetailed, router: IRouter = mainRouter) {
|
||||
const meId = $i ? $i.id : null;
|
||||
|
|
@ -170,20 +170,21 @@ export function getUserMenu(user: Misskey.entities.UserDetailed, router: IRouter
|
|||
action: () => {
|
||||
copyToClipboard(`${user.host ?? host}/@${user.username}.atom`);
|
||||
},
|
||||
}, {
|
||||
}, ...(user.host != null && user.url != null ? [{
|
||||
icon: 'ph-share ph-bold ph-lg',
|
||||
text: i18n.ts.showOnRemote,
|
||||
action: () => {
|
||||
if (user.url == null) return;
|
||||
window.open(user.url, '_blank', 'noopener');
|
||||
},
|
||||
}] : []), {
|
||||
icon: 'ph-share-network ph-bold ph-lg',
|
||||
text: i18n.ts.copyProfileUrl,
|
||||
action: () => {
|
||||
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: () => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue