Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Show user card on discussion page user link #11772

Merged
merged 2 commits into from
Jan 14, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions resources/js/beatmap-discussions/user-card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

import UserAvatar from 'components/user-avatar';
import UserGroupBadge from 'components/user-group-badge';
import UserLink from 'components/user-link';
import UserGroupJson from 'interfaces/user-group-json';
import UserJson from 'interfaces/user-json';
import { route } from 'laroute';
Expand Down Expand Up @@ -32,12 +33,12 @@ export class UserCard extends React.PureComponent<Props> {
<UserAvatar modifiers='full-rounded' user={this.props.user} />
</span>
) : (
<a
<UserLink
className={`${bn}__user-link`}
href={route('users.show', { user: this.props.user.id })}
user={this.props.user}
>
<UserAvatar modifiers='full-rounded' user={this.props.user} />
</a>
</UserLink>
)}
</div>

Expand All @@ -49,12 +50,12 @@ export class UserCard extends React.PureComponent<Props> {
</span>

) : (
<a
<UserLink
className={`${bn}__user-link`}
href={route('users.show', { user: this.props.user.id })}
user={this.props.user}
>
{this.renderUsername()}
</a>
</UserLink>
)}
{!this.props.user.is_bot && !this.props.user.is_deleted && (
<a
Expand Down
Loading