JavaScript preprocessors can help make authoring JavaScript easier and more convenient. For instance, CoffeeScript can help prevent easy-to-make mistakes and offer a cleaner syntax and Babel can bring ECMAScript 6 features to browsers that only support ECMAScript 5.
Any URL's added here will be added as <script>
s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.
You can apply a script from anywhere on the web to your Pen. Just put a URL to it here and we'll add it, in the order you have them, before the JavaScript in the Pen itself.
If the script you link to has the file extension of a preprocessor, we'll attempt to process it before applying.
You can also link to another Pen here, and we'll pull the JavaScript from that Pen and include it. If it's using a matching preprocessor, we'll combine the code before preprocessing, so you can use the linked Pen as a true dependency.
HTML Settings
Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.
<div id="fullscreen">
</div>
<section class="main">
<div class="container align-center">
<button class="btn btn-ghost center-block wow zoomIn" data-wow-duration="4s" data-wow-delay="1s"><i class="fa fa-play"><span class="mask"></span></i> Start digital experience</button>
</div>
</section>
<div id="meta">
<div id="winSize">850px</div>
<div id="winMid">850px</div>
<div id="btnSize">850px</div>
<div id="mTop">850px</div>
</div>
<script>
</script>
html, body {
position:relative;
height:100%;
color:#fff;
font-family: 'Roboto', sans-serif;
font-size:16px;
font-weight:100;
}
#fullscreen {
width:100%;
height:100%;
background:url('http://cdn.paper4pc.com/images/dark-forest-wallpaper-5.jpg') center center no-repeat;
background-size:cover;
position:fixed;
z-index:-1;
}
#fullscreen:after {
content:"";
position:absolute;
top:20px; bottom:20px;
left:20px; right:20px;
background:transparent;
border:1px solid #fff;
z-index:999;
}
.main { padding:50px 0;}
.btn-ghost {
border-radius:0;
background:transparent;
border:1px solid #fff;
font-size:18px;
font-weight:100;
text-transform:uppercase;
padding:1em;
display:block;
transition:all .4s ease;
color:#fff;
position:relative;
/*box-shadow:0 0 20px 2px rgba(255,255,255,.2);*/
}
.btn-ghost:before {
content:"";
background:rgba(255,255,255,.2);
width:calc(100% - 3.9em);
height:2.85em;
position:absolute;
bottom:.27em;
right:.25em;
transition:all .2s ease;
}
.btn-ghost:hover:before {
height:0em;
}
.btn-ghost:hover { color:#fff;
box-shadow:0 0 20px 2px rgba(255,255,255,.2);}
.btn-ghost i {position:relative;
margin-right:2em;
margin-left:.25em;
}
.btn-ghost i .mask {
position:absolute;
width:2.8em;
height:2.8em;
background:rgba(255,255,255,.2);
top:-.925em;
left:-1em;
transition:all .2s ease;
}
.btn-ghost:hover i .mask {
height:0em;
}
.btn-ghost i:after {
content:"";
width:1px;
height:3.4em;
background:#fff;
position:absolute;
margin-top:-1.25em;
margin-left:1.25em;
}
#meta {position:fixed;
right:40px;
top:40px;
background:rgba(255,255,255,.2);
padding:10px;
font-size:10px;
opacity:.3;
transition:all .4s ease;
cursor:help;
}
#meta:hover {opacity:1;}
var winSize = $(window).height(),
winMid = winSize /2,
btnSize = $(".btn-ghost").height(),
btnMid = btnSize /2,
mTop = winMid - btnSize - 57;
// META
$('#winSize').text("Taille de la fenêtre : " + winSize + "px");
$('#winMid').text("Moitié de la fenêtre : " + winMid + "px");
$('#btnSize').text("Hauteur du bouton : " + btnSize + "px");
$('#mTop').text("Hauteur de la marge : " + mTop + "px");
// CENTER TOP
$('.btn-ghost').css({"margin-top":mTop});
$(window).resize(function(){
var winSize = $(window).height(),
winMid = winSize /2,
btnSize = $(".btn-ghost").height(),
btnMid = btnSize /2,
mTop = winMid - btnSize - 57;
// META
$('#winSize').text("Taille de la fenêtre : " + winSize + "px");
$('#winMid').text("Moitié de la fenêtre : " + winMid + "px");
$('#btnSize').text("Hauteur du bouton : " + btnSize + "px");
$('#mTop').text("Hauteur de la marge : " + mTop + "px");
// CENTER TOP
$('.btn-ghost').css({"margin-top":mTop});
});
new WOW().init();
Also see: Tab Triggers