modify copy/share for external profiles
Some checks failed
Some checks failed
This commit is contained in:
@ -335,16 +335,20 @@ const Header: React.FC<IHeader> = ({ account }) => {
|
||||
};
|
||||
|
||||
const handleShare = () => {
|
||||
const localDomain = window.location.hostname !== 'localhost' ? window.location.hostname : 'localhost:7312';
|
||||
const copyString = `${window.location.protocol}//${localDomain}/@${account.acct}`;
|
||||
navigator.share({
|
||||
text: `@${account.acct}`,
|
||||
url: account.url,
|
||||
url: copyString,
|
||||
}).catch((e) => {
|
||||
if (e.name !== 'AbortError') console.error(e);
|
||||
});
|
||||
};
|
||||
|
||||
const handleCopy: React.EventHandler<React.MouseEvent> = (e) => {
|
||||
copy(account.url);
|
||||
const localDomain = window.location.hostname !== 'localhost' ? window.location.hostname : 'localhost:7312';
|
||||
const copyString = `${window.location.protocol}//${localDomain}/@${account.acct}`;
|
||||
copy(copyString);
|
||||
};
|
||||
|
||||
const makeMenu = () => {
|
||||
|
||||
Reference in New Issue
Block a user