JSFiddle - React, Tailwind, and code Playground

HTML

<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" width="250px" version="1.1" style="shape-rendering:geometricPrecision; text-rendering:geometricPrecision; image-rendering:optimizeQuality; fill-rule:evenodd; clip-rule:evenodd"
viewBox="0 0 4839 11595"
 xmlns:xlink="http://www.w3.org/1999/xlink">
 <defs>
  <style type="text/css">
   <![CDATA[
    .str0 {stroke:white;stroke-width:20}
    .fil0 {fill:#A0D8E8}
   ]]>
  </style>
 </defs>
 <g id="Capa_x0020_1">
  <metadata id="CorelCorpID_0Corel-Layer"/>
  <a id="Pizq" onClick="ala(this.id)" ><path id="Pizq" class="fil0 str0" d="M1412 6052c-10,182 -16,363 -16,521 0,360 48,820 146,1232 24,103 49,387 0,541 -49,180 -98,880 49,1215 48,129 195,1247 122,1479 -25,51 0,231 0,231 0,0 -49,129 -147,155 0,0 -73,128 147,103 219,-26 316,77 365,25 49,-51 98,-180 49,-257 -49,-77 24,-154 24,-206 0,-51 -48,-103 -73,-283 0,-26 -25,-1093 73,-1324 49,-460 -73,-752 -73,-984 0,-231 146,-852 146,-1418 0,-176 72,-448 108,-959 -141,24 -758,-31 -920,-71z"/></a>

  <a id="Pder" onClick="ala(this.id)" ><path id="Pder" class="fil0 str0" d="M3421 6067c11,183 17,364 17,521 0,360 -48,821 -146,1233 -24,103 -49,386 0,541 49,180 98,880 -49,1214 -49,129 -195,1247 -122,1479 25,52 0,232 0,232 0,0 49,128 147,154 0,0 73,129 -147,103 -219,-26 -317,77 -365,26 -49,-51 -98,-180 -49,-257 49,-78 -24,-155 -24,-206 0,-52 48,-103 73,-284 0,-25 25,-1092 -73,-1324 -49,-459 73,-751 73,-983 0,-232 -147,-852 -147,-1419 0,-176 -71,-448 -107,-958 141,24 758,-31 919,-72z"/></a>

  <a id="ingle" onClick="ala(this.id)" ><path id="ingle" class="fil0 str0" d="M3402 5451c-12,-118 -32,-223 -46,-285 5,-2 9,-5 12,-7 23,-15 0,-105 0,-105 0,0 -242,77 -886,112 -644,35 -992,-139 -992,-139 0,0 -18,44 -27,79 -1,6 5,13 16,19 -18,81 -55,261 -77,452 -35,306 -24,468 -5,482 62,44 957,126 983,73 27,-53 27,-53 27,-53l54 -5 8 31c0,0 17,80 317,53 300,-26 656,-71 655,-152 -2,-91 -12,-282 -39,-555z"/></a>

  <a id="abdomen" onClick="ala(this.id)" ><path id="abdomen" class="fil0 str0"...

CSS

.fil0:hover{
   fill: #E84949 !important;
   stroke:white;
   stroke-width:30;
}
.pollita{
    fill: #BA3548 !important;
}

JavaScript

function ala(X){
    /*$('path').attr('class','fil0 str0')*/
    var vale = $('path[id='+X+']').attr('class')

    if( vale == 'pollita' ){
        $('path[id='+X+']').attr('class','fil0 str0');  
    }else{
        $('path[id='+X+']').attr('class','pollita');
    }
    //$('path[id='+X+']').attr('class',' pollita');
}