This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%screen-hide { | |
border: 0; | |
clip: rect(0 0 0 0); | |
height: 1px; | |
margin: -1px; | |
overflow: hidden; | |
padding: 0; | |
position: absolute; | |
width: 1px; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Animal extends Component { | |
render() { | |
return <div>Animal: {this.props.name}</div>; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@charset "UTF-8"; | |
/* ============================================================================ | |
MAIN STYLES | |
========================================================================= */ | |
/** | |
* Main styles. | |
* | |
* The structure is based on ITCSS and modified: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* https://github.com/gre/bezier-easing | |
* BezierEasing - use bezier curve for transition easing function | |
* by Gaëtan Renaudeau 2014 - 2015 – MIT License | |
*/ | |
// These values are established by empiricism with tests (tradeoff: performance VS precision) | |
var NEWTON_ITERATIONS = 4; | |
var NEWTON_MIN_SLOPE = 0.001; | |
var SUBDIVISION_PRECISION = 0.0000001; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.selector { | |
//transform: translateY(calc(100% - 170px)); | |
transform: translateY(100%) translateY(-170px); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<nav>Nav goes here</nav> | |
<div class="hero> | |
<img src="images/hero-10x10.jpg" class="hero__img" alt="" data-src="original-hero.jpg" data-webp="original-hero.webp"> | |
<section class="hero__section"> | |
<div class="hero__content"> | |
<h1>Title goes here</h1> | |
<p>Description goes here</p> | |
<a href="#">CTA button</a> | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<body> | |
<header> | |
<h1>My wonderful blog</h1> | |
<p>My tagline</p> | |
</header> | |
<aside> | |
<!-- this aside contains two sections that are tangentially related | |
to the page, namely, links to other blogs, and links to blog posts | |
from this blog --> | |
<nav> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var $graphLink = $('.graph__link'), | |
$graphBarRed = $('.graph__bar--red'), | |
$graphBarGreen = $('.graph__bar--green'), | |
$graphBarYellow = $('.graph__bar--yellow'), | |
$graphStarYellow = $('.graph__star--yellow'), | |
$graphStarRed = $('.graph__star--red'), | |
$graphStarGreen = $('.graph__star--green'); | |
var graphTFOrigin = '50% bottom', | |
graphDuration = 1.2; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var $graphLink = $('.graph__link'), | |
$graphBarRed = $('.graph__bar--red'), | |
$graphBarGreen = $('.graph__bar--green'), | |
$graphBarYellow = $('.graph__bar--yellow'), | |
$graphStarRed = $('.graph__star--red'), | |
$graphStarGreen = $('.graph__star--green'), | |
$graphStarYellow = $('.graph__star--yellow'); | |
$graphLink.hover(function() { | |
TweenMax.to($graphBarRed, 1.2, { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var $graphStarRed = $('.graph__star--red'), | |
$graphStarGreen = $('.graph__star--green'), | |
$graphStarYellow = $('.graph__star--yellow'); | |
// hover over | |
TweenMax.to($graphStarRed, 1.2, { | |
y: -25, | |
ease: Elastic.easeOut.config(1, 0.2) | |
}); |
NewerOlder