mirror of
https://github.com/irislib/iris-messenger.git
synced 2024-10-18 22:23:23 +00:00
fix search box followers & profile button update
This commit is contained in:
parent
7f1eb8cd15
commit
ff7e06c1d6
@ -120,11 +120,11 @@ class SearchBox extends Component {
|
||||
if (i.followDistance === 1) {
|
||||
followText = 'Following';
|
||||
}
|
||||
if (i.followDistance === 2) {
|
||||
if (i.followDistance > 1) {
|
||||
if (i.followers.size === 1 && Session.getFollows()[[...i.followers][0]] && Session.getFollows()[[...i.followers][0]].name) {
|
||||
followText = `Followed by ${ Session.getFollows()[[...i.followers][0]].name}`;
|
||||
} else {
|
||||
followText = `Followed by ${ i.followers.size } users you follow`;
|
||||
followText = `${ i.followers.size } followers`;
|
||||
}
|
||||
}
|
||||
return html`
|
||||
|
@ -144,14 +144,14 @@ class Profile extends View {
|
||||
`: this.props.id === SMS_VERIFIER_PUB ? html`
|
||||
<p><a href="https://iris-sms-auth.herokuapp.com/?pub=${Session.getPubKey()}">${t('ask_for_verification')}</a></p>
|
||||
` : ''}
|
||||
${this.isMyProfile ? '' : html`<${FollowButton} id=${this.props.id}/>`}
|
||||
${this.isMyProfile ? '' : html`<${FollowButton} key=${`${this.props.id}follow`} id=${this.props.id}/>`}
|
||||
<button onClick=${() => route(`/chat/${ this.props.id}`)}>${t('send_message')}</button>
|
||||
<${CopyButton} text=${t('copy_link')} title=${this.state.name} copyStr=${`https://iris.to${ window.location.pathname}`}/>
|
||||
<${CopyButton} key=${`${this.props.id}copy`} text=${t('copy_link')} title=${this.state.name} copyStr=${`https://iris.to${ window.location.pathname}`}/>
|
||||
<button onClick=${() => $(this.qrRef.current).toggle()}>${t('show_qr_code')}</button>
|
||||
${this.isMyProfile ? '' : html`
|
||||
<button class="show-settings" onClick=${() => this.onClickSettings()}>${t('settings')}</button>
|
||||
`}
|
||||
${this.isMyProfile ? '' : html`<${BlockButton} id=${this.props.id}/>`}
|
||||
${this.isMyProfile ? '' : html`<${BlockButton} key=${`${this.props.id}block`} id=${this.props.id}/>`}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
Loading…
Reference in New Issue
Block a user