import React, { useMemo, useState } from "react"; import styles from "./index.module.scss"; import classNames from "classnames"; import { baseUrl } from "@/index"; import { useSelector } from "react-redux"; import { RootState } from "@/store"; import history from "@/utils/history"; function A1Home() { const { dianOut, dianIn } = useSelector( (state: RootState) => state.A0Layout.dataAll.home ); const [mapShow, setMapShow] = useState(false); const hoverData = useMemo(() => { const arr = dianOut.map((v) => ({ name: v.name, id: v.id, ...v.hover })); return arr; }, [dianOut]); // 鼠标移入的变量 const [hoverAc, setHoverAc] = useState(0); return (
{v.name}
{/* 信息盒子 */} {v.txtLoc ? ({v.txt}