maj style html
This commit is contained in:
@@ -1,3 +1,14 @@
|
||||
<script>
|
||||
// Permet de sélectionner une ligne en cliquant dessus
|
||||
document.addEventListener('DOMContentLoaded', () => {
|
||||
document.querySelectorAll('table tr').forEach(row => {
|
||||
row.addEventListener('click', () => {
|
||||
document.querySelectorAll('tr').forEach(r => r.classList.remove('selected'));
|
||||
row.classList.add('selected');
|
||||
});
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
Reference in New Issue
Block a user