import React, { useRef, useEffect, useState } from "react"; import Globe from "react-globe.gl"; import { motion } from "framer-motion"; const GlobalNetworkMap = () => { const globeEl = useRef(null); const [points, setPoints] = useState([]); const [arcs, setArcs] = useState([]); useEffect(() => { // Auto-rotate if (globeEl.current) { globeEl.current.controls().autoRotate = true; globeEl.current.controls().autoRotateSpeed = 0.5; } // Generate synthetic ride data const N = 20; const generatedPoints = [...Array(N).keys()].map(() => ({ lat: (Math.random() - 0.5) * 180, lng: (Math.random() - 0.5) * 360, size: Math.random() / 3, color: ['#00f3ff', '#bc13fe', '#ff0055'][Math.floor(Math.random() * 3)], })); setPoints(generatedPoints); // Generate arcs (connections) const generatedArcs = [...Array(N).keys()].map(() => ({ startLat: (Math.random() - 0.5) * 180, startLng: (Math.random() - 0.5) * 360, endLat: (Math.random() - 0.5) * 180, endLng: (Math.random() - 0.5) * 360, color: [['#00f3ff', '#bc13fe'][Math.floor(Math.random() * 2)]], })); setArcs(generatedArcs); }, []); return (

Global Ride Network

Math.random()} arcDashGap={() => Math.random()} arcDashAnimateTime={2000} /> {/* Overlay scanlines */}
); }; export default GlobalNetworkMap;