AccountHeader: make profile share button work

This commit is contained in:
Alex Gleason 2021-10-15 09:45:03 -05:00
parent 7a89e1bb01
commit 013594444d
No known key found for this signature in database
GPG Key ID: 7211D1F99744FBB7
1 changed files with 9 additions and 0 deletions

View File

@ -158,6 +158,15 @@ class Header extends ImmutablePureComponent {
}
}
handleShare = () => {
navigator.share({
text: `@${this.props.account.get('acct')}`,
url: this.props.account.get('url'),
}).catch((e) => {
if (e.name !== 'AbortError') console.error(e);
});
}
makeMenu() {
const { account, intl, me, meAccount, features } = this.props;