From f11c2f96ba99ff6d7c1582c60718ab5d5dcf4cca Mon Sep 17 00:00:00 2001 From: MCHost Date: Wed, 9 Jul 2025 23:12:05 -0400 Subject: [PATCH] disable the particle system until I optimize --- public/css/main-site.min.css | 9 ---- public/css/style.min.css | 2 +- public/js/app.js | 88 ++++++++++++++++++------------------ 3 files changed, 45 insertions(+), 54 deletions(-) diff --git a/public/css/main-site.min.css b/public/css/main-site.min.css index 349a4f1..7f6d18c 100644 --- a/public/css/main-site.min.css +++ b/public/css/main-site.min.css @@ -226,9 +226,6 @@ .pointer-events-none { pointer-events: none; } - .visible { - visibility: visible; - } .absolute { position: absolute; } @@ -388,9 +385,6 @@ .h-48 { height: calc(var(--spacing) * 48); } - .h-\[7vh\] { - height: 7vh; - } .h-\[30vh\] { height: 30vh; } @@ -400,9 +394,6 @@ .h-\[40vh\] { height: 40vh; } - .h-\[75vh\] { - height: 75vh; - } .h-full { height: 100%; } diff --git a/public/css/style.min.css b/public/css/style.min.css index f2a6d20..961934d 100644 --- a/public/css/style.min.css +++ b/public/css/style.min.css @@ -2061,4 +2061,4 @@ --tw-translate-z: 0; } } -} +} \ No newline at end of file diff --git a/public/js/app.js b/public/js/app.js index e4c39e6..f63df6f 100644 --- a/public/js/app.js +++ b/public/js/app.js @@ -2442,58 +2442,58 @@ document.addEventListener('DOMContentLoaded', () => { observer.observe(section); }); - const PARTICLE_POOL_SIZE = 50; - const particlePool = []; - const activeParticles = new Set(); +// const PARTICLE_POOL_SIZE = 50; +// const particlePool = []; +// const activeParticles = new Set(); - function createParticleElement() { - const particle = document.createElement('div'); - particle.classList.add('particle'); - if (Math.random() > 0.6) particle.classList.add('large'); - return particle; - } +// function createParticleElement() { +// const particle = document.createElement('div'); +// particle.classList.add('particle'); +// if (Math.random() > 0.6) particle.classList.add('large'); +// return particle; +// } - function initializeParticlePool() { - for (let i = 0; i < PARTICLE_POOL_SIZE; i++) { - particlePool.push(createParticleElement()); - } - } +// function initializeParticlePool() { +// for (let i = 0; i < PARTICLE_POOL_SIZE; i++) { +// particlePool.push(createParticleElement()); +// } +// } - function resetParticle(particle) { - particle.style.left = `${Math.random() * 100}%`; - particle.style.top = `${Math.random() * 100}%`; - particle.style.animationDelay = `${Math.random() * 8}s`; - particle.style.animationDuration = `${8 + Math.random() * 6}s`; - particle.classList.remove('fade-out'); - return particle; - } +// function resetParticle(particle) { +// particle.style.left = `${Math.random() * 100}%`; +// particle.style.top = `${Math.random() * 100}%`; +// particle.style.animationDelay = `${Math.random() * 8}s`; +// particle.style.animationDuration = `${8 + Math.random() * 6}s`; +// particle.classList.remove('fade-out'); +// return particle; +// } - function spawnParticle() { - if (particlePool.length === 0 || activeParticles.size >= PARTICLE_POOL_SIZE) return; +// function spawnParticle() { +// if (particlePool.length === 0 || activeParticles.size >= PARTICLE_POOL_SIZE) return; - const particle = resetParticle(particlePool.pop()); - if (!particle.parentNode) document.body.appendChild(particle); - activeParticles.add(particle); +// const particle = resetParticle(particlePool.pop()); +// if (!particle.parentNode) document.body.appendChild(particle); +// activeParticles.add(particle); - setTimeout(() => { - particle.classList.add('fade-out'); - setTimeout(() => { - activeParticles.delete(particle); - particlePool.push(particle); - }, 500); - }, 14000); - } +// setTimeout(() => { +// particle.classList.add('fade-out'); +// setTimeout(() => { +// activeParticles.delete(particle); +// particlePool.push(particle); +// }, 500); +// }, 14000); +// } - function animate() { - if (Math.random() < 0.1) spawnParticle(); // Reduced spawn frequency - requestAnimationFrame(animate); - } +// function animate() { +// if (Math.random() < 0.1) spawnParticle(); // Reduced spawn frequency +// requestAnimationFrame(animate); +// } - // Initialize and start -setTimeout(() => { - initializeParticlePool(); - animate(); -}, 500); +// // Initialize and start +// setTimeout(() => { +// initializeParticlePool(); +// animate(); +// }, 500); }); \ No newline at end of file