[Glitch] Change percentile label in year in review in web UI
Port 6cf87762a4
to glitch-soc
Signed-off-by: Claire <claire.github-309c@sitedethib.com>
pull/2921/head
parent
93631757b8
commit
062723cfb2
|
@ -1,6 +1,7 @@
|
||||||
/* eslint-disable react/jsx-no-useless-fragment */
|
/* eslint-disable react/jsx-no-useless-fragment */
|
||||||
import { FormattedMessage, FormattedNumber } from 'react-intl';
|
import { FormattedMessage, FormattedNumber } from 'react-intl';
|
||||||
|
|
||||||
|
import { domain } from 'flavours/glitch/initial_state';
|
||||||
import type { Percentiles } from 'flavours/glitch/models/annual_report';
|
import type { Percentiles } from 'flavours/glitch/models/annual_report';
|
||||||
|
|
||||||
export const Percentile: React.FC<{
|
export const Percentile: React.FC<{
|
||||||
|
@ -12,7 +13,7 @@ export const Percentile: React.FC<{
|
||||||
<div className='annual-report__bento__box annual-report__summary__percentile'>
|
<div className='annual-report__bento__box annual-report__summary__percentile'>
|
||||||
<FormattedMessage
|
<FormattedMessage
|
||||||
id='annual_report.summary.percentile.text'
|
id='annual_report.summary.percentile.text'
|
||||||
defaultMessage='<topLabel>That puts you in the top</topLabel><percentage></percentage><bottomLabel>of Mastodon users.</bottomLabel>'
|
defaultMessage='<topLabel>That puts you in the top</topLabel><percentage></percentage><bottomLabel>of {domain} users.</bottomLabel>'
|
||||||
values={{
|
values={{
|
||||||
topLabel: (str) => (
|
topLabel: (str) => (
|
||||||
<div className='annual-report__summary__percentile__label'>
|
<div className='annual-report__summary__percentile__label'>
|
||||||
|
@ -44,6 +45,8 @@ export const Percentile: React.FC<{
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
),
|
),
|
||||||
|
|
||||||
|
domain,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{(message) => <>{message}</>}
|
{(message) => <>{message}</>}
|
||||||
|
|
Loading…
Reference in New Issue