Difference between revisions of "Template:Sidebar"
Adelo Vieira (talk | contribs) |
Adelo Vieira (talk | contribs) |
||
Line 360: | Line 360: | ||
<div id="container-button-tap" style="margin-top:-9px;"> | <div id="container-button-tap" style="margin-top:-9px;"> | ||
− | <button id="button-pe" class="button izquierda | + | <button id="button-pe" class="button izquierda tablink bottom-selected" onclick="openCity(event,'PE')" > <i class="fas fa-atom"> </i> </button> |
− | <button id="button-menu" class="button izquierda | + | <button id="button-menu" class="button izquierda tablink" onclick="openCity(event,'Menu')" > <i class="fas fa-ellipsis-v"></i> </button> |
− | <button id="button-others" class="button izquierda | + | <button id="button-others" class="button izquierda tablink" onclick="openCity(event,'Others')"> <i class="fas fa-yin-yang"> </i> </button> |
− | <button id="button-tools" class="button izquierda | + | <button id="button-tools" class="button izquierda tablink" onclick="openCity(event,'Tools')" > <i class="fas fa-tools"></i> </button> |
− | <!-- <button id="button-others" class="button derecha | + | <!-- <button id="button-others" class="button derecha tablink" onclick="openCity(event,'Others')"> <i class="fas fa-info"> </i> </button> --> |
− | <!-- <button id="button-menu" class="button centrar | + | <!-- <button id="button-menu" class="button centrar tablink" onclick="openCity(event,'Menu')" > <i class="fas fa-tools"></i> </button> --> |
</div> | </div> | ||
Line 410: | Line 410: | ||
function openCity(evt, cityName) { | function openCity(evt, cityName) { | ||
− | var i, x, | + | var i, x, tablinks; |
x = document.getElementsByClassName("city"); | x = document.getElementsByClassName("city"); | ||
for (i = 0; i < x.length; i++) { | for (i = 0; i < x.length; i++) { | ||
x[i].style.display = "none"; | x[i].style.display = "none"; | ||
} | } | ||
− | + | tablinks = document.getElementsByClassName("tablink"); | |
for (i = 0; i < x.length; i++) { | for (i = 0; i < x.length; i++) { | ||
− | + | tablinks[i].className = tablinks[i].className.replace(" bottom-selected", ""); | |
} | } | ||
document.getElementById(cityName).style.display = "block"; | document.getElementById(cityName).style.display = "block"; |
Revision as of 17:32, 21 March 2021