JSFiddle - React, Tailwind, and code Playground

by Manuel Gertrudix

HTML

<!DOCTYPE html>
<html>
  <head>
    <style>
      table {
        width:300px;
        height:100px;
      }
    
    </style>
    <script>
      function bgChange(bg) {
        document.body.style.background = bg;
      }
    </script>
  </head>

  <body>

    <h2>Cambia el color del fondo</h2>
    <p>Pasa con el puntero sobre los cuadros</p>

    <table>
      <tr>
        <td onmouseover="bgChange(this.style.backgroundColor)" 
            onmouseout="bgChange('transparent')"
            style="background-color:#452367">
        </td>
        <td onmouseover="bgChange(this.style.backgroundColor)" 
            onmouseout="bgChange('transparent')"
            style="background-color:PaleGreen">
        </td>
        <td onmouseover="bgChange(this.style.backgroundColor)" 
            onmouseout="bgChange('transparent')"
            style="background-color:Silver">
        </td>
      </tr>
    </table>

  </body>
</html>