Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 14 additions & 14 deletions app.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,10 @@ class NeuronNavigation {

this.nodes.forEach(node => {
node.addEventListener('click', (e) => {
e.stopPropagation();
e.stopImmediatePropagation();
const targetSection = node.getAttribute('data-section');
this.navigateToSection(targetSection, node);
});
}, true);
});

document.querySelectorAll('[data-node]').forEach(btn => {
Expand Down Expand Up @@ -228,7 +228,7 @@ class NeuronNavigation {
this.controls.forEach(control => {
control.addEventListener('click', (e) => {
const action = e.target.getAttribute('data-action');

switch(action) {
case 'rotate':
rotation += 45;
Expand All @@ -241,7 +241,7 @@ class NeuronNavigation {
scale = 1;
break;
}

this.heartModel.style.transform = `rotateY(${rotation}deg) scale(${scale})`;
});
});
Expand All @@ -251,7 +251,7 @@ class NeuronNavigation {
part.addEventListener('click', (e) => {
const partInfo = e.target.getAttribute('data-info');
this.showPartInfo(partInfo);

// Resaltar la parte clickeada
this.heartParts.forEach(p => p.classList.remove('active'));
e.target.classList.add('active');
Expand Down Expand Up @@ -340,16 +340,16 @@ class NeuronNavigation {
const audioContext = new (window.AudioContext || window.webkitAudioContext)();
const oscillator = audioContext.createOscillator();
const gainNode = audioContext.createGain();

oscillator.connect(gainNode);
gainNode.connect(audioContext.destination);

oscillator.frequency.setValueAtTime(400, audioContext.currentTime);
oscillator.frequency.exponentialRampToValueAtTime(600, audioContext.currentTime + 0.1);

gainNode.gain.setValueAtTime(0.1, audioContext.currentTime);
gainNode.gain.exponentialRampToValueAtTime(0.01, audioContext.currentTime + 0.3);

oscillator.start();
oscillator.stop(audioContext.currentTime + 0.3);
}
Expand All @@ -361,7 +361,7 @@ class NeuronNavigation {

this.ctx.strokeStyle = 'rgba(147, 185, 224, 0.2)';
this.ctx.lineWidth = 1;

this.nodes.forEach((node1, i) => {
const rect1 = node1.getBoundingClientRect();
const x1 = rect1.left + rect1.width / 2;
Expand All @@ -372,18 +372,18 @@ class NeuronNavigation {
const rect2 = node2.getBoundingClientRect();
const x2 = rect2.left + rect2.width / 2;
const y2 = rect2.top + rect2.height / 2;

const distance = Math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2);

if (distance < 400) {
this.ctx.beginPath();
this.ctx.moveTo(x1, y1);
this.ctx.lineTo(x2, y2);
this.ctx.stroke();

const pulseSpeed = 0.001;
const pulse = (Date.now() * pulseSpeed) % distance;

this.ctx.fillStyle = 'rgba(196, 162, 252, 0.8)';
this.ctx.beginPath();
this.ctx.arc(
Expand Down
10 changes: 5 additions & 5 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -119,19 +119,19 @@ <h2>Tecnología Avanzada</h2>

<div class="tech-grid">
<div class="tech-item connectivity-item">

<h3>Conectividad</h3>
<p>Ecosistema de sensores, datos y alertas que se adaptan a cada usuario.</p>
<div class="tech-overlay"></div>
</div>
<div class="tech-item functionality-item">

<h3>Funcionalidad</h3>
<p>Control de alta precisión con respuesta a impulsos neuronales.</p>
<div class="precision-arm"></div>
</div>
<div class="tech-item aesthetic-item">

<h3>Estética</h3>
<p>Diseño fluido que respira con el cuerpo y el movimiento.</p>
</div>
Expand All @@ -155,7 +155,7 @@ <h3>Valeria Fanning — 19</h3>
</div>
<div class="prosthesis-glow" data-limb="leg"></div>
</div>

<div class="story-card guadalupe-card" data-person="guadalupe">
<div class="story-image"></div>
<div class="story-content">
Expand All @@ -165,7 +165,7 @@ <h3>Guadalupe del Rey — 33</h3>
</div>
<div class="heartbeat-glow" data-organ="heart"></div>
</div>

<div class="story-card fermin-card" data-person="fermin">
<div class="story-image"></div>
<div class="story-content">
Expand Down
14 changes: 11 additions & 3 deletions styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ body {
width: 100%;
height: 100%;
z-index: 1;
pointer-events: none;
}

/* Nodos de la Red Neuronal */
Expand All @@ -72,9 +73,14 @@ body {
left: var(--x);
transform: translate(-50%, -50%);
cursor: pointer;
z-index: 10;
z-index: 100;
transition: var(--transition);
filter: drop-shadow(0 0 10px rgba(147, 185, 224, 0.3));
pointer-events: none;
}

.neuron-main:not(.zoomed) .neuron-node {
pointer-events: auto;
}

.node-core {
Expand Down Expand Up @@ -190,13 +196,15 @@ body {
visibility: hidden;
transform: scale(0.8) translateZ(-100px);
transition: var(--transition);
z-index: 5;
z-index: 50;
pointer-events: none;
}

.content-section.active {
opacity: 1;
visibility: visible;
transform: scale(1) translateZ(0);
pointer-events: auto;
}

.section-background {
Expand Down Expand Up @@ -236,7 +244,7 @@ body {
.neuron-main.zoomed .neuron-node.active-node {
opacity: 1;
transform: translate(-50%, -50%) scale(1.5);
z-index: 20;
z-index: 200;
pointer-events: all;
}

Expand Down