start scene animation
This commit is contained in:
parent
b3f626a15b
commit
d10a4293ad
@ -130,7 +130,7 @@ main section h2 {
|
||||
|
||||
position: absolute;
|
||||
width: 100vw;
|
||||
min-height: 100vh;
|
||||
height: 1300px;
|
||||
left: 1px;
|
||||
top: -2px;
|
||||
|
||||
@ -184,6 +184,9 @@ main section h2 {
|
||||
#welcome img {
|
||||
position: absolute;
|
||||
}
|
||||
.phones-land{
|
||||
z-index:-1;
|
||||
}
|
||||
|
||||
#phone-watches-1 {
|
||||
width: 345px;
|
||||
|
@ -43,10 +43,12 @@
|
||||
</section>
|
||||
<section id="welcome">
|
||||
|
||||
<div class="phones-land">
|
||||
<img src="/img/phone_watches.png" alt="phone watches" id="phone-watches-1">
|
||||
<img src="/img/phone_watches.png" alt="phone watches" id="phone-watches-2">
|
||||
<img src="/img/phone_watches.png" alt="phone watches" id="phone-watches-3">
|
||||
<img src="/img/phone_watches.png" alt="phone watches" id="phone-watches-4">
|
||||
</div>
|
||||
<h2 class="margin-auto container-text-lg">
|
||||
We come from
|
||||
<span class="color-emphasis">
|
||||
|
17
js/main.js
17
js/main.js
@ -7,8 +7,7 @@ anime({
|
||||
|
||||
anime({
|
||||
targets: '#hand',
|
||||
backgroundPosition: ['50px', '0px'],
|
||||
opacity: ['0.5', '1'],
|
||||
top: ['0px', '100px'],
|
||||
easing: 'easeInOut'
|
||||
});
|
||||
|
||||
@ -29,17 +28,13 @@ anime({
|
||||
let tl1 = anime.timeline({autoplay: false});
|
||||
|
||||
let s1a2 = {
|
||||
targets: '#cover',
|
||||
backgroundColor: ['#000', '#ddd'],
|
||||
borderRadius: function (el) {
|
||||
return anime.random(2, 10);
|
||||
},
|
||||
delay: function (el) {
|
||||
return anime.random(0, 800);
|
||||
}
|
||||
targets: '#hand',
|
||||
top: ['0px', '100px'],
|
||||
easing: 'easeInOut'
|
||||
};
|
||||
|
||||
// Add children
|
||||
tl1.add(s1a2, '-=1300');
|
||||
tl1.add(s1a2, '-=10');
|
||||
|
||||
let controller = new ScrollMagic.Controller();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user