From 24bada26a408acbeed2085aaf19ce0efa3eb7551 Mon Sep 17 00:00:00 2001 From: "Tanner Collin (aider)" Date: Thu, 3 Jul 2025 22:21:34 +0000 Subject: [PATCH] refactor: Abstract DumbCaneSoil to generic SoilMoisture component --- client/src/App.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/client/src/App.js b/client/src/App.js index 72259bc..3e7dd92 100644 --- a/client/src/App.js +++ b/client/src/App.js @@ -1221,12 +1221,12 @@ function BedroomLux({end, duration}) { } -function DumbCaneSoil({end, duration}) { - const [data, loading, tickFormatter] = useSensor('soil', 'Dumb Cane', end, duration); +function SoilMoisture({name, sensorName, sensorId, end, duration}) { + const [data, loading, tickFormatter] = useSensor(sensorId, sensorName, end, duration); return ( x.soil?.toFixed(1)} loading={loading} @@ -1295,7 +1295,7 @@ function Graphs({end, duration}) { - + {!!api_key ||