mirror of
https://github.com/9x/9x.github.io.git
synced 2026-09-02 09:04:33 +02:00
Add interactive particle animation background
This commit is contained in:
85
js/particles-config.js
Normal file
85
js/particles-config.js
Normal file
@@ -0,0 +1,85 @@
|
||||
particlesJS('particles-js', {
|
||||
particles: {
|
||||
number: {
|
||||
value: 50,
|
||||
density: {
|
||||
enable: true,
|
||||
value_area: 800
|
||||
}
|
||||
},
|
||||
color: {
|
||||
value: '#ffffff'
|
||||
},
|
||||
shape: {
|
||||
type: 'circle'
|
||||
},
|
||||
opacity: {
|
||||
value: 0.6,
|
||||
random: true,
|
||||
anim: {
|
||||
enable: true,
|
||||
speed: 1,
|
||||
opacity_min: 0.3,
|
||||
sync: false
|
||||
}
|
||||
},
|
||||
size: {
|
||||
value: 5,
|
||||
random: true,
|
||||
anim: {
|
||||
enable: true,
|
||||
speed: 2,
|
||||
size_min: 0.5,
|
||||
sync: false
|
||||
}
|
||||
},
|
||||
line_linked: {
|
||||
enable: true,
|
||||
distance: 150,
|
||||
color: '#ffffff',
|
||||
opacity: 0.4,
|
||||
width: 3
|
||||
},
|
||||
move: {
|
||||
enable: true,
|
||||
speed: 1,
|
||||
direction: 'none',
|
||||
random: true,
|
||||
straight: false,
|
||||
out_mode: 'out',
|
||||
bounce: false,
|
||||
attract: {
|
||||
enable: false,
|
||||
rotateX: 600,
|
||||
rotateY: 1200
|
||||
}
|
||||
}
|
||||
},
|
||||
interactivity: {
|
||||
detect_on: 'window',
|
||||
events: {
|
||||
onhover: {
|
||||
enable: true,
|
||||
mode: 'grab'
|
||||
},
|
||||
onclick: {
|
||||
enable: true,
|
||||
mode: 'repulse'
|
||||
},
|
||||
resize: true
|
||||
},
|
||||
modes: {
|
||||
grab: {
|
||||
distance: 200,
|
||||
line_linked: {
|
||||
opacity: 0.5
|
||||
}
|
||||
},
|
||||
repulse: {
|
||||
distance: 100,
|
||||
duration: 0.4
|
||||
}
|
||||
}
|
||||
},
|
||||
retina_detect: true
|
||||
});
|
||||
9
js/particles.min.js
vendored
Normal file
9
js/particles.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user