JSFiddle - React, Tailwind, and code Playground

HTML

<script src="https://code.jquery.com/jquery-3.2.1.min.js"></script>
<map name="simple" id="mapCoord">
  <area href="#" shape="poly" id="room-1" class="rectCoords" coords="16,65,162,65,162,315,198,315,198,390,161,390,161,687,16,687" alt="" data-maphilight="{&quot;strokeColor&quot;:&quot;ffde00&quot;,&quot;strokeWidth&quot;:3,&quot;fillOpacity&quot;:0,&quot;shadow&quot;:true,&quot;shadowPosition&quot;:&quot;outside&quot;,&quot;shadowRadius&quot;:20,&quot;shadowColor&quot;:&quot;000000&quot;,&quot;shadowX&quot;:0,&quot;shadowY&quot;:0,&quot;wrapClass&quot;:true,&quot;fade&quot;:false}" title="">
  <area href="#" shape="poly" id="room-2" class="rectCoords" coords="153,66,153,323,230,323,230,313,269,313,269,324,401,324,401,66,396,66,396,16,254,16,254,66"  alt="" data-maphilight="{&quot;strokeColor&quot;:&quot;ffde00&quot;,&quot;strokeWidth&quot;:3,&quot;fillOpacity&quot;:0,&quot;shadow&quot;:true,&quot;shadowPosition&quot;:&quot;outside&quot;,&quot;shadowRadius&quot;:20,&quot;shadowColor&quot;:&quot;000000&quot;,&quot;shadowX&quot;:0,&quot;shadowY&quot;:0,&quot;wrapClass&quot;:true,&quot;fade&quot;:false}" title="">
  <area href="#" shape="poly" id="room-3" class="rectCoords" coords="154,687,154,378,273,378,273,390,312,390,312,379,400,379,401,637,396,637,396,687"  alt="" data-maphilight="{&quot;strokeColor&quot;:&quot;ffde00&quot;,&quot;strokeWidth&quot;:3,&quot;fillOpacity&quot;:0,&quot;shadow&quot;:true,&quot;shadowPosition&quot;:&quot;outside&quot;,&quot;shadowRadius&quot;:20,&quot;shadowColor&quot;:&quot;000000&quot;,&quot;shadowX&quot;:0,&quot;shadowY&quot;:0,&quot;wrapClass&quot;:true,&quot;fade&quot;:false}" title="">
</map>

CSS

map {
  width: 400px; 
  height: 400px;
}

area {
  border: 1px solid red;
}

JavaScript

var map = document.getElementById('mapCoord'); // получаю нашу Карту
  var elems = map.getElementsByTagName('area'); // Создаю массив нужных нам элементом

 $('.rectCoords').on('mouseover', function(e) {
  for(var i=0; i<elems.length; i++){
  	console.log($("#"+elems[i].id));
    $("#"+elems[i].id).attr('data-maphilight', '{&quot;strokeColor&quot;:&quot;000000&quot;}');
}
});