Skip to content

Commit

Permalink
button animation added
Browse files Browse the repository at this point in the history
  • Loading branch information
e-labInnovations committed Jul 14, 2022
1 parent 3710da1 commit 0e80146
Show file tree
Hide file tree
Showing 7 changed files with 27 additions and 20 deletions.
1 change: 1 addition & 0 deletions assets/scss/_home.scss
Original file line number Diff line number Diff line change
Expand Up @@ -473,6 +473,7 @@
grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
grid-gap: 20px;
margin: 10px;
padding-bottom: 30px;
.code-snippet-card {
background: rgba(0, 0, 0, 0.329);
box-shadow: 0 0 5px rgba(255, 255, 255, 0.25);
Expand Down
2 changes: 1 addition & 1 deletion build/index.asset.php
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<?php return array('dependencies' => array('jquery'), 'version' => 'b7c07b436c91f8485b46b6cc1dd5599d');
<?php return array('dependencies' => array('jquery'), 'version' => '062ad328e0638870eff8994ed87aaa75');
10 changes: 9 additions & 1 deletion build/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion build/index.js.map

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions build/style-index.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion build/style-index.css.map

Large diffs are not rendered by default.

29 changes: 13 additions & 16 deletions src/modules/zmain.js
Original file line number Diff line number Diff line change
Expand Up @@ -94,28 +94,25 @@ class zmain {
});

var t1 = gsap.timeline({defaults: {duration: 1}})
// var textSplit = SplitText.create('h1', { type: "chars,words" });

// const textWrapper = document.querySelector('.hero .title');
// textWrapper.innerHTML = textWrapper.textContent.replace(/\S/g, "<span class='letter'>$&</span>");

t1.from('.hero', { opacity: 0, y:-50 })
.from('.box-item', { opacity: 0, y:-50, ease: 'Power2.easeOut', stagger: 0.3 }, '-=0.3');

const postTitle = gsap.timeline({ yoyo: true });

postTitle.from(".post-title", {
duration: 1,
scaleX: 0,
transformOrigin: "left",
ease: "expo.inOut"
})
.from(
".post-title",
{
y: "100%",
duration: 0.8,
ease: "expo.out"
},
"-=0.2"
);
postTitle.from(".post-title", { duration: 1, scaleX: 0, transformOrigin: "left", ease: "expo.inOut" })
.from( ".post-title", { y: "100%", duration: 0.8, ease: "expo.out" }, "-=0.2");

gsap.fromTo(".pagination .buttons", {
boxShadow: "0 0 5px 0px rgba(255, 255, 255, 0.4)"
}, {
boxShadow: "0 0 5px 20px rgba(0, 0, 0, 0)",
repeat: -1,
duration: 1
});

}

Expand Down

0 comments on commit 0e80146

Please sign in to comment.