Fix tradesummary avatars baseurl

This commit is contained in:
Reckless_Satoshi 2022-11-15 10:36:43 -08:00
parent 7f731dfb00
commit 9d80ca6fdb
No known key found for this signature in database
GPG Key ID: 9C4585B561315571
2 changed files with 9 additions and 1 deletions

View File

@ -48,6 +48,7 @@ interface Props {
takerSummary: Record<string, Item>; takerSummary: Record<string, Item>;
platformSummary: Record<string, Item>; platformSummary: Record<string, Item>;
orderId: number; orderId: number;
baseUrl: string;
} }
const TradeSummary = ({ const TradeSummary = ({
@ -59,6 +60,7 @@ const TradeSummary = ({
takerSummary, takerSummary,
platformSummary, platformSummary,
orderId, orderId,
baseUrl,
}: Props): JSX.Element => { }: Props): JSX.Element => {
const { t, i18n } = useTranslation(); const { t, i18n } = useTranslation();
const [buttonValue, setButtonValue] = useState<number>(isMaker ? 0 : 2); const [buttonValue, setButtonValue] = useState<number>(isMaker ? 0 : 2);
@ -94,7 +96,11 @@ const TradeSummary = ({
> >
<ToggleButtonGroup size='small' value={buttonValue} exclusive> <ToggleButtonGroup size='small' value={buttonValue} exclusive>
<ToggleButton value={0} disableRipple={true} onClick={() => setButtonValue(0)}> <ToggleButton value={0} disableRipple={true} onClick={() => setButtonValue(0)}>
<RobotAvatar style={{ height: 28, width: 28 }} nickname={makerNick} /> <RobotAvatar
baseUrl={baseUrl}
style={{ height: 28, width: 28 }}
nickname={makerNick}
/>
&nbsp; &nbsp;
{t('Maker')} {t('Maker')}
</ToggleButton> </ToggleButton>
@ -105,6 +111,7 @@ const TradeSummary = ({
{t('Taker')} {t('Taker')}
&nbsp; &nbsp;
<RobotAvatar <RobotAvatar
baseUrl={baseUrl}
avatarClass='smallAvatar' avatarClass='smallAvatar'
style={{ height: 28, width: 28 }} style={{ height: 28, width: 28 }}
nickname={takerNick} nickname={takerNick}

View File

@ -1681,6 +1681,7 @@ class TradeBox extends Component {
</Grid> </Grid>
<TradeSummary <TradeSummary
baseUrl={this.props.baseUrl}
isMaker={this.props.data.is_maker} isMaker={this.props.data.is_maker}
makerNick={this.props.data.maker_nick} makerNick={this.props.data.maker_nick}
takerNick={this.props.data.taker_nick} takerNick={this.props.data.taker_nick}