code quality
Some checks failed
CI / lint-typecheck (pull_request) Failing after 13s
CI / tests (pull_request) Has been skipped
CI / contract-tests (pull_request) Has been skipped
CI / e2e-tests (pull_request) Has been skipped
CI / comment-pr (pull_request) Has been skipped
CI / commit-types (pull_request) Has been skipped
Some checks failed
CI / lint-typecheck (pull_request) Failing after 13s
CI / tests (pull_request) Has been skipped
CI / contract-tests (pull_request) Has been skipped
CI / e2e-tests (pull_request) Has been skipped
CI / comment-pr (pull_request) Has been skipped
CI / commit-types (pull_request) Has been skipped
This commit is contained in:
@@ -54,16 +54,21 @@ export function DriverLeaderboardPreview({
|
||||
<LeaderboardRow
|
||||
key={driver.id}
|
||||
onClick={() => onDriverClick(driver.id)}
|
||||
rank={<RankBadge rank={position} />}
|
||||
rank={
|
||||
<Group gap={4} data-testid={`standing-position-${position}`}>
|
||||
<RankBadge rank={position} />
|
||||
</Group>
|
||||
}
|
||||
identity={
|
||||
<Group gap={4}>
|
||||
<Group gap={4} data-testid={`standing-driver-${driver.id}`}>
|
||||
<Avatar src={driver.avatarUrl} alt={driver.name} size="sm" />
|
||||
<Group direction="column" align="start" gap={0}>
|
||||
<Text
|
||||
weight="bold"
|
||||
<Text
|
||||
weight="bold"
|
||||
variant="high"
|
||||
truncate
|
||||
truncate
|
||||
block
|
||||
data-testid="driver-name"
|
||||
>
|
||||
{driver.name}
|
||||
</Text>
|
||||
@@ -77,8 +82,8 @@ export function DriverLeaderboardPreview({
|
||||
</Group>
|
||||
}
|
||||
stats={
|
||||
<Group gap={8}>
|
||||
<Group direction="column" align="end" gap={0}>
|
||||
<Group gap={8} data-testid="standing-stats">
|
||||
<Group direction="column" align="end" gap={0} data-testid="stat-rating">
|
||||
<Text variant="primary" font="mono" weight="bold" block size="md" align="right">
|
||||
{RatingFormatter.format(driver.rating)}
|
||||
</Text>
|
||||
@@ -86,7 +91,7 @@ export function DriverLeaderboardPreview({
|
||||
Rating
|
||||
</Text>
|
||||
</Group>
|
||||
<Group direction="column" align="end" gap={0}>
|
||||
<Group direction="column" align="end" gap={0} data-testid="stat-wins">
|
||||
<Text variant="success" font="mono" weight="bold" block size="md" align="right">
|
||||
{driver.wins}
|
||||
</Text>
|
||||
|
||||
Reference in New Issue
Block a user