From 5f3c5c9a24f9b2f60284cee23ad6f9a1cc970eca Mon Sep 17 00:00:00 2001 From: Galen Guyer Date: Mon, 16 Nov 2020 20:26:41 -0500 Subject: use nicer date format in graph tooltip --- src/History.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/History.js') diff --git a/src/History.js b/src/History.js index 30e2fc4..7425b61 100644 --- a/src/History.js +++ b/src/History.js @@ -68,8 +68,10 @@ class CustomizedAxisTick extends PureComponent { const CustomTooltip = ({ active, payload, label }) => { if (active) { return ( -
-

{DateTime.fromSeconds(label).toLocaleString()}

+
+

+ {DateTime.fromSeconds(label).toLocaleString({ weekday: "long", month: "long", day: "2-digit" })} +

{payload[0].value}

); -- cgit v1.2.3