This file contains hidden or 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
jQuery(window).resize(function(){ | |
resizeNav(); | |
}); | |
resizeNav(); | |
function resizeNav(){ | |
var windowWidth = Math.max(document.documentElement.clientWidth, window.innerWidth || 0); | |
if(windowWidth < 767) { |
This file contains hidden or 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
<a href="#url1">When the crisis was over, | |
<object><a href="#url2>Hello world</a></object> | |
</a> | |
ref: https://speakerdeck.com/smashingmag/dirty-tricks-from-the-dark-corners-of-front-end |
This file contains hidden or 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
.video-wrapper { | |
position: relative; | |
padding-bottom: 56.25%; | |
} | |
.video-wrapper iframe { | |
position: absolute; | |
width: 100%; | |
height: 100%; | |
top: 0; |
This file contains hidden or 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
div[class*="layer-"] { | |
position: absolute; | |
top: -10px; left: -10px; | |
right: -10px; bottom: -10px; | |
background-size: 100% auto; | |
background-repeat: no-repeat; | |
background-position: 0 0; | |
transition:0.1s; | |
} |
This file contains hidden or 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
<div class="container"> | |
<video poster="poster.png" autoplay="true" loop> | |
<source src="video.mp4" type="video/mp4"> | |
<source src="video.webm" type="video/webm"> | |
</video> | |
<div class="overlay">lorem </div> | |
</div> |
NewerOlder