Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if (normalized.pixelY > 0) {
- if (this.scroll + normalized.pixelY > this.$refs.contentWork[0].offsetHeight - window.innerHeight) {
- this.scroll = this.$refs.contentWork[0].offsetHeight - window.innerHeight
- TweenLite.to('.content-work', 0.5, {
- y: -this.scroll
- })
- TweenLite.to('.content-next-project', 0.5, {
- y: this.scroll
- })
- } else {
- this.scroll += Math.floor((normalized.pixelY))
- TweenLite.to('.content-work', .5, {
- y: -this.scroll
- })
- TweenLite.to('.content-next-project', .5, {
- y: this.scroll
- })
- }
- } else {
- if (this.scroll + normalized.pixelY < 0) {
- this.scroll = 0
- TweenLite.to('.content-work', 0.5, {
- y: -this.scroll
- })
- TweenLite.to('.content-next-project', 0.5, {
- y: this.scroll
- })
- } else {
- this.scroll += Math.floor((normalized.pixelY))
- TweenLite.to('.content-work', .5, {
- y: -this.scroll
- })
- TweenLite.to('.content-next-project', 0.5, {
- y: this.scroll
- })
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement