We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 83e2811 commit 8796d27Copy full SHA for 8796d27
1 file changed
client/src/components/ContactCard.tsx
@@ -186,7 +186,11 @@ export function ContactCard({
186
<XAxis dataKey="timestamp" hide />
187
<YAxis domain={['auto', 'auto']} />
188
<Tooltip
189
- labelFormatter={(t: number) => new Date(t).toLocaleTimeString()}
+ labelFormatter={(label) => {
190
+ const t = typeof label === "number" ? label : Number(label);
191
+ if (!Number.isFinite(t)) return String(label ?? "");
192
+ return new Date(t).toLocaleTimeString();
193
+ }}
194
contentStyle={{ borderRadius: '8px', border: 'none', boxShadow: '0 4px 6px -1px rgb(0 0 0 / 0.1)' }}
195
/>
196
<Line type="monotone" dataKey="avg" stroke="#3b82f6" strokeWidth={2} dot={false} name="Avg RTT" isAnimationActive={false} />
0 commit comments