Browse Source

Move follower count to tab title. Closes #1698

pull/1706/head
Gabe Kangas 4 years ago
parent
commit
50b0bfbc4e
No known key found for this signature in database
GPG Key ID: 9A56337728BC81EA
  1. 5
      webroot/js/app.js
  2. 6
      webroot/js/components/fediverse-follow-modal.js

5
webroot/js/app.js

@ -831,7 +831,10 @@ export default class App extends Component {
if (federation.enabled) { if (federation.enabled) {
TAB_CONTENT.push({ TAB_CONTENT.push({
label: 'Followers', label: html`Followers
${federation.followerCount > 10
? `${' '}(${federation.followerCount})`
: null}`,
content: html`<${Followers} />`, content: html`<${Followers} />`,
}); });
} }

6
webroot/js/components/fediverse-follow-modal.js

@ -185,11 +185,7 @@ export function FediverseFollowButton({ serverName, federationInfo, onClick }) {
<${ExternalActionButton} <${ExternalActionButton}
onClick=${handleClick} onClick=${handleClick}
action=${fediverseFollowAction} action=${fediverseFollowAction}
label=${`Follow ${ label="Follow"
federationInfo.followerCount > 10
? ` (${federationInfo.followerCount})`
: ''
}`}
/> />
</span> </span>
`; `;

Loading…
Cancel
Save