Skip to content

Instantly share code, notes, and snippets.

View hongc-cc's full-sized avatar
🎯
Focusing

Hong C. hongc-cc

🎯
Focusing
View GitHub Profile
<form method="post" action="" id="login-form" accept-charset="UTF-8">
<input type="hidden" name="action" value="users/login">
<input type="hidden" name="redirect" value="{{redirect}}">
<div class="form-group">
<label for="email">Email</label>
<input id="email" type="text" name="loginName" class="form-control">
</div>
@hongc-cc
hongc-cc / transfade.js
Created December 10, 2015 05:54 — forked from haydenbleasel/transfade.js
Medium-style vertical fading parallax scroll modifier for Stellar.js
// Custom transform and opacity modifier for Stellar.js
$.stellar.positionProperty.transfade = {
setPosition: function(element, newLeft, originalLeft, newTop, originalTop) {
var distance = newTop - originalTop;
var rate = $(window).height() / 5;
element.css('transform', 'translate3d(0, ' + distance + 'px, 0').css('opacity', 1 - (distance / rate));
}
};
$.stellar({