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:
@@ -8,25 +8,28 @@ interface KpiItem {
|
||||
|
||||
interface DashboardKpiRowProps {
|
||||
items: KpiItem[];
|
||||
'data-testid'?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* DashboardKpiRow
|
||||
*
|
||||
*
|
||||
* A horizontal row of key performance indicators with telemetry styling.
|
||||
*/
|
||||
export function DashboardKpiRow({ items }: DashboardKpiRowProps) {
|
||||
export function DashboardKpiRow({ items, 'data-testid': testId }: DashboardKpiRowProps) {
|
||||
return (
|
||||
<StatGrid
|
||||
variant="card"
|
||||
cardVariant="dark"
|
||||
font="mono"
|
||||
columns={{ base: 2, md: 3, lg: 6 }}
|
||||
stats={items.map(item => ({
|
||||
stats={items.map((item, index) => ({
|
||||
label: item.label,
|
||||
value: item.value,
|
||||
intent: item.intent as any
|
||||
intent: item.intent as any,
|
||||
'data-testid': `stat-${item.label.toLowerCase()}`
|
||||
}))}
|
||||
data-testid={testId}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -43,8 +43,8 @@ export function RecentActivityTable({ items }: RecentActivityTableProps) {
|
||||
</TableHead>
|
||||
<TableBody>
|
||||
{items.map((item) => (
|
||||
<TableRow key={item.id}>
|
||||
<TableCell>
|
||||
<TableRow key={item.id} data-testid={`activity-item-${item.id}`}>
|
||||
<TableCell data-testid="activity-race-result-link">
|
||||
<Text font="mono" variant="telemetry" size="xs">{item.type}</Text>
|
||||
</TableCell>
|
||||
<TableCell>
|
||||
|
||||
@@ -5,16 +5,17 @@ import React from 'react';
|
||||
interface TelemetryPanelProps {
|
||||
title: string;
|
||||
children: React.ReactNode;
|
||||
'data-testid'?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* TelemetryPanel
|
||||
*
|
||||
*
|
||||
* A dense, instrument-grade panel for displaying data and controls.
|
||||
*/
|
||||
export function TelemetryPanel({ title, children }: TelemetryPanelProps) {
|
||||
export function TelemetryPanel({ title, children, 'data-testid': testId }: TelemetryPanelProps) {
|
||||
return (
|
||||
<Panel title={title} variant="dark" padding={4}>
|
||||
<Panel title={title} variant="dark" padding={4} data-testid={testId}>
|
||||
<Text size="sm" variant="med">
|
||||
{children}
|
||||
</Text>
|
||||
|
||||
Reference in New Issue
Block a user