Skip to content

Commit

Permalink
Merge pull request #126 from sk66641/revert-125-particle-animation
Browse files Browse the repository at this point in the history
Revert "Implement Dynamic Particle Animation in Disco Light Simulator"
  • Loading branch information
sk66641 authored Jun 2, 2024
2 parents b4a4d79 + 2fa70ed commit d4c4d61
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 116 deletions.
114 changes: 0 additions & 114 deletions script.js
Original file line number Diff line number Diff line change
Expand Up @@ -339,118 +339,4 @@ document.getElementById('submit').addEventListener('click', function() {
document.getElementById(selectedMusic).play();
}
});
});

// Your Particles.js configuration goes here
document.addEventListener('DOMContentLoaded', () => {
particlesJS('particles-js', {
"particles": {
"number": {
"value": 80,
"density": {
"enable": true,
"value_area": 800
}
},
"color": {
"value": "#ffffff"
},
"shape": {
"type": "circle",
"stroke": {
"width": 0,
"color": "#000000"
},
"polygon": {
"nb_sides": 5
},
"image": {
"src": "img/github.svg",
"width": 100,
"height": 100
}
},
"opacity": {
"value": 0.5,
"random": false,
"anim": {
"enable": false,
"speed": 1,
"opacity_min": 0.1,
"sync": false
}
},
"size": {
"value": 3,
"random": true,
"anim": {
"enable": false,
"speed": 40,
"size_min": 0.1,
"sync": false
}
},
"line_linked": {
"enable": true,
"distance": 150,
"color": "#ffffff",
"opacity": 0.4,
"width": 1
},
"move": {
"enable": true,
"speed": 6,
"direction": "none",
"random": false,
"straight": false,
"out_mode": "out",
"bounce": false,
"attract": {
"enable": false,
"rotateX": 600,
"rotateY": 1200
}
}
},
"interactivity": {
"detect_on": "canvas",
"events": {
"onhover": {
"enable": true,
"mode": "repulse"
},
"onclick": {
"enable": true,
"mode": "push"
},
"resize": true
},
"modes": {
"grab": {
"distance": 400,
"line_linked": {
"opacity": 1
}
},
"bubble": {
"distance": 400,
"size": 40,
"duration": 2,
"opacity": 8,
"speed": 3
},
"repulse": {
"distance": 100,
"duration": 0.4
},
"push": {
"particles_nb": 4
},
"remove": {
"particles_nb": 2
}
}
},
"retina_detect": true
});
});
13 changes: 11 additions & 2 deletions style.css
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@ body {
position: absolute;
width: 100%;
height: 100%;
background-color: #000;
position: fixed;
z-index: -1;
}

::-webkit-scrollbar {
Expand Down Expand Up @@ -528,6 +527,16 @@ button:hover {
pointer-events: none;
}

@keyframes snowfall {
0% {
transform: translateY(-10px) rotate(0deg);
opacity: 1;
}
100% {
transform: translateY(100vh) rotate(360deg);
opacity: 0;
}
}

body,
ul {
Expand Down

0 comments on commit d4c4d61

Please sign in to comment.