import React from "react"; import { ComposableMap, Geographies, Geography, Marker } from…
- User
import React from "react"; import { ComposableMap, Geographies, Geography, Marker } from "react-simple-maps";
const geoUrl = "https://raw.githubusercontent.com/deldersveld/topojson/master/world-countries.json" const markers = [ { markerOffset: -30, name: "Buenos Aires", coordinates: [-58.3816, -34.6037] }, { markerOffset: 15, name: "La Paz", coordinates: [-68.1193, -16.4897] }, { markerOffset: 15, name: "Brasilia", coordinates: [-47.8825, -15.7942] }, { markerOffset: 15, name: "Santiago", coordinates: [-70.6693, -33.4489] }, { markerOffset: 15, name: "Bogota", coordinates: [-74.0721, 4.711] }, { markerOffset: 15, name: "Quito", coordinates: [-78.4678, -0.1807] }, { markerOffset: -30, name: "Georgetown", coordinates: [-58.1551, 6.8013] }, { markerOffset: -30, name: "Asuncion", coordinates: [-57.5759, -25.2637] }, { markerOffset: 15, name: "Paramaribo", coordinates: [-55.2038, 5.852] }, { markerOffset: 15, name: "Montevideo", coordinates: [-56.1645, -34.9011] }, { markerOffset: 15, name: "Caracas", coordinates: [-66.9036, 10.4806] }, { markerOffset: 15, name: "Lima", coordinates: [-77.0428, -12.0464] } ];
const MapChart = () => { return ( <ComposableMap projection="geoNaturalEarth1" projectionConfig={{ rotate: [0, 0, 0], scale: 0 }} > {({ geographies }) => geographies.map((geo) => ( )) } {markers.map(({ name, coordinates, markerOffset }) => ( <text textAnchor="middle" y={markerOffset} style={{ fontFamily: "system-ui", fill: "#5D5A6D" }} > {name} ))} ); };
export default MapChart;
нужно сделать, чтобы когда я наводил мышкой на страну, она подсвечивалась. нужно убрать антарктиду с карты
- Assistant
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.