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

const useTalasiclMarkersLayer = (map, oms, GisSystemStatic, priorityConfig) => {
  const [talasiclMarkers, setTalasiclMarkers] = useState([]);

  useEffect(() => {
    if (GisSystemStatic && GisSystemStatic.length && map) {
      createAndSetDevices(100, setTalasiclMarkers, GisSystemStatic, priorityConfig); // TALASICL
    }
  }, [GisSystemStatic, map, priorityConfig]);

  useEffect(() => {
    if (map && talasiclMarkers.length) {
      talasiclMarkers.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 = [];
    }
  }, [map, talasiclMarkers, oms]);

  return talasiclMarkers;
};

export default useTalasiclMarkersLayer;
 */
