Skip to content

Commit e3fdd78

Browse files
Merge pull request #1 from proyectosingenieriauninorte/UX-change
Ux change
2 parents eb4e456 + bdd959f commit e3fdd78

File tree

3 files changed

+98
-93
lines changed

3 files changed

+98
-93
lines changed

app/index.html

Lines changed: 13 additions & 67 deletions
Original file line numberDiff line numberDiff line change
@@ -21,20 +21,16 @@
2121
<header>
2222
<div class="header-container">
2323
<h1><a href="index.html">BixCalculator</a></h1> <!--Direcciona a la pagina Principal-->
24-
<nav>
25-
<ul> <!--Main menu-->
26-
<li><a href="#aboutus">Sobre nosotros</a></li>
27-
</ul>
28-
</nav>
24+
2925
</div>
3026
</header>
3127
<!--Web main presentation-->
3228
<section class="presentation" id="presentation">
3329
<div class="presentation-paragraph">
3430
<h2>Calculadora de Binarios</h2>
31+
<h3>Ingresa solo números binarios (1s y 0s) en los campos</h3>
3532
</div>
3633
<div class="input-container">
37-
<div id="alertaBinaria" class="alerta-binaria">Ingresa solo números binarios (1s y 0s) en este campo.</div>
3834
<!-- Primera línea -->
3935
<label for="linea1">Primer Numero</label>
4036
<input type="text" id="linea1" placeholder="Escribe algo..." oninput="validarBinario(this)">
@@ -61,10 +57,10 @@ <h2>Calculadora de Binarios</h2>
6157
<div id="pasosDiv">
6258
</div>
6359
<!-- Botón Anterior -->
64-
<button onclick="mostrarAnterior()">Anterior</button>
60+
<button id="calcularButton" onclick="mostrarAnterior()">Anterior</button>
6561

6662
<!-- Botón Siguiente -->
67-
<button onclick="mostrarSiguiente()">Siguiente</button>
63+
<button id="calcularButton" onclick="mostrarSiguiente()">Siguiente</button>
6864
</div>
6965

7066
<script>
@@ -135,69 +131,19 @@ <h2>Calculadora de Binarios</h2>
135131
</script>
136132
</div>
137133

138-
</section>
139-
140-
141-
142-
<!--About us section-->
143-
<section class="aboutus" id="aboutus">
144-
<h2>Sobre Nosotros</h2>
145-
<br>
146-
<h3>BixCalculator</h3>
147-
<br>
148-
<br>
149-
<br>
150-
<p>En BixCalculator, visualizamos un mundo donde la comprensión de los fundamentos de la informática es accesible y
151-
emocionante para todos. Nos esforzamos por ser líderes en la revolución educativa digital
152-
,proporcionando una calculadora de binarios innovadora que no solo simplifica los conceptos complejos, sino que
153-
también inspira la curiosidad y el descubrimiento. Nuestra visión es empoderar a las mentes del futuro,
154-
transformando la educación en una experiencia interactiva y cautivadora, donde cada usuario pueda dominar los
155-
secretos del lenguaje binario y desbloquear un mundo de posibilidades tecnológicas.
156-
</p>
157-
<br>
158-
<br>
159-
<p>
160-
</p>
161-
<br>
162-
<br>
163-
<br>
164-
<h2>Nuestro equipo</h2>
165-
<br>
166-
<br>
167134
<footer>
168-
<div class="footer-container">
169-
<div class="footer-content">
170-
<h3>Contacto</h3>
171-
<p>Dirección: 123 Calle Principal, Ciudad</p>
172-
<p>Email: info@bixcalculator.com</p>
173-
<p>Teléfono: (123) 456-7890</p>
174-
<ul>
175-
<li><a href="https://github.com/proyectosuninorte/BIXA.git" target="_blank">Respositorio Github</a></li>
176-
177-
</ul>
178-
</div>
135+
<p>
136+
This is an open-source project by
137+
<a id="repo-link" href="#" target="_blank">Proyectos Ingenieria Uninorte</a>.
138+
</p>
139+
<p>Developed by:</p>
140+
<div id="contributors"></div>
141+
</footer>
179142

180-
<div class="footer-content">
181-
<h3>Enlaces</h3>
182-
<ul>
183-
184-
<li><a href="#">Sobre nosotros</a></li>
185-
<li><a href="#">Contacto</a></li>
186-
</ul>
187-
</div>
143+
</section>
188144

189-
<div class="footer-content">
190-
<h3>Redes Sociales</h3>
191-
<ul>
192-
<li><a href="#" target="_blank">Facebook</a></li>
193-
<li><a href="#" target="_blank">Twitter</a></li>
194-
<li><a href="#" target="_blank">Instagram</a></li>
195-
</ul>
196-
</div>
197-
</div>
145+
198146

199-
<p class="copyright">BixCalculator &copy; Todos los derechos reservados</p>
200-
</footer>
201147

202148
</body>
203149

app/main.css

Lines changed: 27 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -164,29 +164,35 @@ select {
164164
}
165165

166166

167+
/* Contributors section */
168+
#contributors img {
169+
width: 40px;
170+
height: 40px;
171+
border-radius: 50%;
172+
margin: 5px;
173+
cursor: pointer;
174+
}
167175

168176

169-
/*Footer*/
170-
171-
footer {
172-
background-color: #1eae42;
173-
color: white;
174-
padding: 20px 0;
175-
}
176-
177-
.footer-container {
178-
display: flex;
179-
justify-content: space-around;
180-
}
181-
182-
.footer-content {
183-
margin-bottom: 20px;
184-
}
185-
186-
.footer-content h3 {
187-
font-size: 1.2em;
188-
margin-bottom: 10px;
189-
}
177+
* Top Right Link */
178+
.top-link {
179+
position: fixed;
180+
top: 10px;
181+
right: 10px;
182+
text-decoration: none;
183+
color: #007bff;
184+
font-weight: bold;
185+
background: #fff;
186+
padding: 5px 10px;
187+
border: 1px solid #007bff;
188+
border-radius: 3px;
189+
transition: background-color 0.3s;
190+
}
191+
192+
.top-link:hover {
193+
background-color: #007bff;
194+
color: #fff;
195+
}
190196

191197
ul {
192198
list-style: none;
@@ -206,11 +212,6 @@ a:hover {
206212
text-decoration: underline;
207213
}
208214

209-
.copyright {
210-
margin-top: 20px;
211-
text-align: center;
212-
}
213-
214215

215216
@media screen and (max-width: 768px) {
216217
#linea1, #linea2, #opciones {

app/main.js

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1171,3 +1171,61 @@ function validarBinario(input) {
11711171
}
11721172
}
11731173

1174+
///////////////////////
1175+
// Contributor Loader
1176+
///////////////////////
1177+
document.addEventListener("DOMContentLoaded", async function () {
1178+
// Use the UnCodeGenerator repository for the footer
1179+
const repoName = "proyectosingenieriauninorte/bixa";
1180+
const repoUrl = `https://github.com/${repoName}`;
1181+
const contributorsUrl = `https://api.github.com/repos/${repoName}/contributors`;
1182+
1183+
// Set the repository link in the footer
1184+
document.getElementById("repo-link").href = repoUrl;
1185+
document.getElementById("repo-link").textContent = repoUrl.replace("https://github.com/", "");
1186+
1187+
try {
1188+
const response = await fetch(contributorsUrl);
1189+
if (!response.ok) throw new Error("Failed to fetch contributors");
1190+
1191+
const contributors = await response.json();
1192+
const contributorsDiv = document.getElementById("contributors");
1193+
1194+
if (contributors.length === 0) {
1195+
contributorsDiv.innerHTML = "<p>No contributors found.</p>";
1196+
return;
1197+
}
1198+
1199+
contributors.forEach(user => {
1200+
const contributorElement = document.createElement("div");
1201+
contributorElement.style.display = "inline-block";
1202+
contributorElement.style.margin = "5px";
1203+
contributorElement.style.textAlign = "center";
1204+
1205+
// Create contributor avatar image
1206+
const img = document.createElement("img");
1207+
img.src = user.avatar_url;
1208+
img.alt = user.login;
1209+
img.title = user.login;
1210+
img.width = 40;
1211+
img.height = 40;
1212+
img.style.borderRadius = "50%";
1213+
img.style.cursor = "pointer";
1214+
img.onclick = () => window.open(user.html_url, "_blank");
1215+
1216+
// Contributor username
1217+
const name = document.createElement("p");
1218+
name.textContent = user.login;
1219+
name.style.fontSize = "12px";
1220+
1221+
contributorElement.appendChild(img);
1222+
contributorElement.appendChild(name);
1223+
contributorsDiv.appendChild(contributorElement);
1224+
});
1225+
} catch (error) {
1226+
console.error("Error fetching contributors:", error);
1227+
document.getElementById("contributors").innerHTML =
1228+
"<p style='color: red;'>❌ Failed to load contributors.</p>";
1229+
}
1230+
});
1231+

0 commit comments

Comments
 (0)