/* // hooks/useCiscoRouterMarkersLayer.js
import { useEffect, useState } from "react";
import L from "leaflet";
import { createAndSetDevices } from "../../utils/createAndSetDevices";
import { addContextMenuToMarker } from "../../utils/addContextMenuToMarker";
import { checkOverlappingMarkers } from "../../utils/mapUtils";

const useCiscoRouterMarkersLayer = (map, oms, GisSystemStatic, priorityConfig) => {
  const [ciscoRouterMarkers, setCiscoRouterMarkers] = useState([]);

  useEffect(() => {
    if (GisSystemStatic && GisSystemStatic.length && map) {
      createAndSetDevices(6, setCiscoRouterMarkers, GisSystemStatic, priorityConfig); // Cisco Router
    }
  }, [GisSystemStatic, map, priorityConfig]);

  useEffect(() => {
    if (map && ciscoRouterMarkers.length) {
      ciscoRouterMarkers.forEach((marker) => {
        marker.addTo(map);
        oms.addMarker(marker);

        // Popup on mouseover and mouseout
        marker.on("mouseover", function () {
          this.openPopup();
        });
        marker.on("mouseout", function () {
          this.closePopup();
        });

        addContextMenuToMarker(marker);
      });

      // Disable map context menu
      map.options.contextmenu = false;
      map.options.contextmenuItems = [];

      oms.map.options.contextmenu = false;
      oms.map.options.contextmenuItems = [];

      // Call the function to check for overlapping markers
      checkOverlappingMarkers(oms, map);
    }
  }, [map, ciscoRouterMarkers]);

  return ciscoRouterMarkers;
};

export default useCiscoRouterMarkersLayer;
 */
