diff --git a/src/components/panels/AveragesScatterPlot.tsx b/src/components/panels/ShotScatterPlot.tsx similarity index 98% rename from src/components/panels/AveragesScatterPlot.tsx rename to src/components/panels/ShotScatterPlot.tsx index 54364a9..4b05395 100644 --- a/src/components/panels/AveragesScatterPlot.tsx +++ b/src/components/panels/ShotScatterPlot.tsx @@ -11,7 +11,7 @@ import { getAllDataFromSession } from "../../utils/getAllDataFromSession"; import { BaseLabel } from "../base/BaseLabel"; import { BaseListbox } from "../base/BaseListbox"; -export const AveragesScatterPlot = () => { +export const ShotScatterPlot = () => { const { sessions } = useContext(SessionContext); const [xField, setXField] = useState("Backspin"); @@ -118,7 +118,7 @@ export const AveragesScatterPlot = () => { table: clubs[club].map((row) => ({ x: row[xField as keyof GolfSwingData], y: row[yField as keyof GolfSwingData], - date: row["Date"] || row["Datum"], + date: (row["Date"] || row["Datum"])?.split(" ")[0], })), }; } diff --git a/src/views/Visualization.tsx b/src/views/Visualization.tsx index 6391a77..7ce940a 100644 --- a/src/views/Visualization.tsx +++ b/src/views/Visualization.tsx @@ -1,7 +1,7 @@ import { BasePageLayout } from "../components/base/BasePageLayout"; import { AveragesPerSession } from "../components/panels/AveragesPerSession"; -import { AveragesScatterPlot } from "../components/panels/AveragesScatterPlot"; import { ShotDispersion } from "../components/panels/ShotDispersion"; +import { ShotScatterPlot } from "../components/panels/ShotScatterPlot"; export const Visualization = () => ( @@ -10,7 +10,7 @@ export const Visualization = () => (
- +
);