refactored system settings
This commit is contained in:
@@ -5,15 +5,8 @@ import { useOverviewOverlay } from "../../hooks/useOverviewOverlay";
|
||||
import { useSightingFeedContext } from "../../context/SightingFeedContext";
|
||||
import { useHiDPICanvas } from "../../hooks/useHiDPICanvas";
|
||||
import NavigationArrow from "../UI/NavigationArrow";
|
||||
// import { useSwipeable } from "react-swipeable";
|
||||
// import { useNavigate } from "react-router";
|
||||
|
||||
const SightingOverview = () => {
|
||||
// const navigate = useNavigate();
|
||||
// const handlers = useSwipeable({
|
||||
// onSwipedRight: () => navigate("/front-camera-settings"),
|
||||
// trackMouse: true,
|
||||
// });
|
||||
const [overlayMode, setOverlayMode] = useState<0 | 1 | 2>(0);
|
||||
|
||||
const imgRef = useRef<HTMLImageElement | null>(null);
|
||||
@@ -23,7 +16,7 @@ const SightingOverview = () => {
|
||||
setOverlayMode((m) => ((m + 1) % 3) as 0 | 1 | 2);
|
||||
}, []);
|
||||
|
||||
const { effectiveSelected, side, mostRecent } = useSightingFeedContext();
|
||||
const { side, mostRecent } = useSightingFeedContext();
|
||||
|
||||
useOverviewOverlay(mostRecent, overlayMode, imgRef, canvasRef);
|
||||
|
||||
@@ -67,7 +60,7 @@ const SightingOverview = () => {
|
||||
(click image to toggle)
|
||||
</div>
|
||||
</div>
|
||||
<SightingWidgetDetails effectiveSelected={effectiveSelected} />
|
||||
<SightingWidgetDetails effectiveSelected={mostRecent} />
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user