diff --git a/css/styles.css b/css/styles.css index 2f33d70857443a3252bdb9d0454ace6794ac6f43..cc8bfd99ccc0fb9fd459d790fd3f8731342f5363 100644 --- a/css/styles.css +++ b/css/styles.css @@ -349,7 +349,6 @@ iframe { text-align: center; color : white; display: block; - background-color: #008c8c; /*temporaire*/ font-family: 'Arial Gras', 'Arial Normal', 'Arial', sans-serif; font-weight: 700; font-style: normal; diff --git a/html/listeFrigos.html b/html/listeFrigos.html index 0d63488ae309175b4dc1acc66b99cfe873c48541..58a508406c0a8d499f65af6d210e6970eec218c7 100644 --- a/html/listeFrigos.html +++ b/html/listeFrigos.html @@ -13,12 +13,9 @@ font-weight: bold; } -body{ - background: #008c8c; -} - </style> <head> + <link rel="stylesheet" href="../css/styles.css"> <meta charset="UTF-8"> <title>Liste des frigos</title> </head> diff --git a/html/membres.html b/html/membres.html index cbf7e42452711e78078a2b34bfa231b654c24c9e..573f7d4654f85b322d926ee8234b7712bf21822e 100644 --- a/html/membres.html +++ b/html/membres.html @@ -23,6 +23,10 @@ display: inline; background-color: #53bdbd; } + + .memberTab button.active{ + background-color: #e6881a; + } .tealBackground{ height: 579px; background-color: #008C8C; @@ -47,22 +51,28 @@ </div> <div class="memberTab"> <button id="memberSectionTab" >Section membres</button> - <button class="tablinks active" onclick="openTab(event, 'mission')">Liste des frigos</button> - <button class="tablinks" onclick="openTab(event, 'stats')">Trouver un repas</button> - <button class="tablinks" onclick="openTab(event, 'reglement')">Mon profil</button> - <button class="tablinks" onclick="openTab(event, 'inscription')">Mon panier</button> + <button class="tablinks active" onclick="openTab(event, 'listeFrigos')">Liste des frigos</button> + <button class="tablinks" onclick="openTab(event, 'chercherUnRepas')">Trouver un repas</button> + <button class="tablinks" onclick="openTab(event, 'profil')">Mon profil</button> + <button class="tablinks" onclick="openTab(event, 'panier')">Mon panier</button> </div> - <div class="tealBackground"> - <div id="test"></div> + + + + <div class="tealBackground"> + <div id="listeFrigos" class="tabcontent active"> + <iframe id="mbrcontent" src="listeFrigos.html" width="98%" height="800"></iframe> + </div> </div> </div> </body> </html> +<script src="../scripts/tabsAndErrors.js"></script> <script> - var test = document.getElementById('test'); + /*var test = document.getElementById('test'); for (var i = 1; i < 15 ; i++) { test.innerHTML += "<div id=\"button_"+i+"\">" + i + "</div>"; - }; + };*/ </script> \ No newline at end of file diff --git a/scripts/tabsAndErrors.js b/scripts/tabsAndErrors.js index 5bdc32fc060237909ada0d4a748d83a71dfe70d9..26a9cf8f40bad403341fb61b30eea04a92cc627c 100644 --- a/scripts/tabsAndErrors.js +++ b/scripts/tabsAndErrors.js @@ -2,8 +2,14 @@ function openTab(evt, tabName) { let tabcontent; - tabcontent = document.getElementById("content"); - tabcontent.src = 'html/' + tabName + '.html'; + + if(document.getElementById("content")) { + tabcontent = document.getElementById("content"); + tabcontent.src = 'html/' + tabName + '.html'; + } else { + tabcontent = document.getElementById("mbrcontent"); + tabcontent.src = tabName + '.html'; + } //Set unactive to tab buttons tablinks = document.getElementsByClassName("tablinks");