-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathscript.js
More file actions
38 lines (35 loc) · 893 Bytes
/
script.js
File metadata and controls
38 lines (35 loc) · 893 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
const scroll = new LocomotiveScroll({
el: document.querySelector('main'),
//el ka mtlb konse element pr ye effect lgna hai
smooth: true
});
(function myCircle(){
window.addEventListener('mousemove',(dets)=>{
console.log(dets.x , dets.y);
document.querySelector("#circle").style.transform = `translate(${dets.x}px , ${dets.y}px )`
})
})()
function firstPageAnim() {
var tl = gsap.timeline();
tl.from("#nav", {
y: "-10",
opacity: 0,
duration: 1.5,
ease: Expo.easeInOut,
})
.to(".boundingElem", {
y: 0,
ease: Expo.easeInOut,
duration: 2,
delay: -1,
stagger: 0.2,
})
.from(".links", {
y: -10,
opacity: 0,
duration: 1.5,
delay: -1,
ease: Expo.easeInOut,
});
}
firstPageAnim();