JSFiddle - React, Tailwind, and code Playground
HTML
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min.js"></script>
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/themes/smoothness/jquery-ui.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap-theme.min.css">
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js"></script>
<svg height="100%" width="100%" class="hover">
<polygon class="shape" points="0,0 513,0 0,513" style="fill :red;" />
</svg>
<svg height="100%" width="100%" class="click">
<polygon class="shape" points="0,0 513,0 0,513" style="fill :red;" />
</svg>
JavaScript
$('.hover').hover(function(){
$(this).find('polygon').css('fill', 'black');
},function(){
$(this).find('polygon').css('fill', 'red');
});
$('.click').click(function() {
$(this).find('polygon').css('fill', 'black');
});