JSFiddle - React, Tailwind, and code Playground

by ojarnaoui

HTML

<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/5.0.0/normalize.min.css">
<script src="https://fonts.googleapis.com/css?family=Nunito:400,300&#39; rel=&#39;stylesheet&#39; type=&#39;text/css"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
 <form action="index.html" method="post" id="formName" name="calculeForm">
      <h1>Calculateur Photovoltaique</h1>
      <fieldset>
          <legend>Localisation</legend>
        <input type="text" id="lat" class="local" name="lat" placeholder="Veuillez indiquer Latitude" pattern="-?\d+(,\d{2})?">
        <input type="text" id="long" class="local" name="long" placeholder="Veuillez indiquer longtitude" pattern="-?\d+(,\d{2})?"   >

        <legend>Système <br> <small> Veuillez modifier les entrées ci-dessous pour exécuter la simulation</small> </legend>
        <label for="Local">Surface disponible (m<sup>2</sup>):</label>
        <input type="text" id="surface" name="surface" placeholder="60" >

       <div id="selecttype" >
           <legend>Type de panneau : </legend>
                 <select id="mySelect" name="typeP"  >
                   <optgroup label="Votre Type De Panneau">
                     <option value="silicium polycristallin">Silicium polycristallin</option>
                     <option value="silicium monocristallin">Silicium monocristallin</option>
                   </optgroup>
                 </select>
       </div>
       <table class="table table-bordered table-hover table-condensed">
<thead><tr><th title="Field #1"></th>
<th title="Field #2">Fournisseur</th>
<th title="Field #3">Modèle</th>
<th title="Field #4">Puissance maximale (STC)</th>
<th title="Field #5">Rendement du panneau (STC)...

CSS

*, *:before, *:after {
  -moz-box-sizing: border-box;
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
}

body {
  font-family: 'Nunito', sans-serif;
  color: #384047;
}

form {
  max-width: 300px;
  margin: 10px auto;
  padding: 10px 20px;
  background: #f4f7f8;
  border-radius: 8px;
}
small
{
  font-size: 12px;
  color: red;
}
.error {
  color: #a94442;
  background-color: #f2dede;
  border-color: #ebccd1;

}
.local
{
  display: block;
}
#local
{
  font-size: 13px;
  color: red;

}

h1 {
  margin: 0 0 30px 0;
  text-align: center;
  color: #3498db;
}

input[type="text"],
input[type="password"],
input[type="date"],
input[type="datetime"],
input[type="email"],
input[type="number"],
input[type="search"],
input[type="tel"],
input[type="time"],
input[type="url"],
textarea,
select {
  background: rgba(255,255,255,0.1);
  border: none;
  font-size: 16px;
  height: auto;
  margin: 0;
  outline: 0;
  padding: 15px;
  width: 100%;
  background-color: #e8eeef;
  color: #202529;
  box-shadow: 0 1px 0 rgba(0,0,0,0.03) inset;
  margin-bottom: 30px;
}

input[type="radio"],
input[type="checkbox"] {
  position : absolute;
}

select {
  padding: 6px;
  height: 32px;
  border-radius: 2px;
}


button {
  padding: 19px 39px 18px 39px;
  color: #FFF;
  background-color: #3498db;
  font-size: 18px;
  text-align: center;
  font-style: normal;
  border-radius: 5px;
  width: 100%;
  border: 1px solid #2980b9 ;
  border-width: 1px 1px 3px;
  box-shadow: 0 -1px 0 rgba(255,255,255,0.1) inset;
  margin-bottom: 20px;
  }
fieldset {
  margin-bottom: 30px;
  border: none;
}

legend {
  font-size: 1.4em;
  margin-bottom: 10px;
}

label {
  display: block;
  margin-bottom: 8px;
}

label.light {
  display : block;
  position : relative;
  padding-left : 30px;
  margin-bottom :15px;
  cursor : pointer;
  font-size :18px;
}
table {
border: 1px solid #ccc;
border-collapse: collapse;
margin: 0;
padding: 0;
width: 100%;
table-layout: fixed;
}
.rad
{width:1em;
height:1em;}
table thead,
table...

JavaScript

var elements= document.getElementsByTagName('tr');
for(var i=0; i<elements.length;i++)
{
(elements)[i].addEventListener("click", function(){
   alert(this.innerHTML);
});
}