mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-20 17:51:12 -05:00
52 lines
1.1 KiB
TypeScript
52 lines
1.1 KiB
TypeScript
import { MeasurementDisplay } from './measurement-display';
|
|
|
|
interface SpeedDisplayProps {
|
|
kmh: number;
|
|
showBothUnits?: boolean;
|
|
className?: string;
|
|
}
|
|
|
|
export function SpeedDisplay({ kmh, showBothUnits = false, className }: SpeedDisplayProps) {
|
|
return (
|
|
<MeasurementDisplay
|
|
value={kmh}
|
|
type="speed"
|
|
showBothUnits={showBothUnits}
|
|
className={className}
|
|
/>
|
|
);
|
|
}
|
|
|
|
interface DistanceDisplayProps {
|
|
meters: number;
|
|
showBothUnits?: boolean;
|
|
className?: string;
|
|
}
|
|
|
|
export function DistanceDisplay({ meters, showBothUnits = false, className }: DistanceDisplayProps) {
|
|
return (
|
|
<MeasurementDisplay
|
|
value={meters}
|
|
type="distance"
|
|
showBothUnits={showBothUnits}
|
|
className={className}
|
|
/>
|
|
);
|
|
}
|
|
|
|
interface HeightDisplayProps {
|
|
cm: number;
|
|
showBothUnits?: boolean;
|
|
className?: string;
|
|
}
|
|
|
|
export function HeightDisplay({ cm, showBothUnits = false, className }: HeightDisplayProps) {
|
|
return (
|
|
<MeasurementDisplay
|
|
value={cm}
|
|
type="height"
|
|
showBothUnits={showBothUnits}
|
|
className={className}
|
|
/>
|
|
);
|
|
} |