Skip to content

Instantly share code, notes, and snippets.

View jeremiecarlson's full-sized avatar

Jeremie Carlson jeremiecarlson

View GitHub Profile
@alexmahan
alexmahan / landscape-mediaquery.scss
Last active May 3, 2018 13:28
Landscape orientation media query mixin for Android. When the keyboard pops up in portrait mode, the window resize event is triggered and it thinks that the device is in landscape mode. This behavior is stupid (http://blog.abouthalf.com/development/orientation-media-query-challenges-in-android-browsers). This fixes that, mostly.
@mixin mobile-landscape() {
@media only screen and (max-height: 420px) and (max-width: 767px) and (orientation: landscape) and (min-aspect-ratio: 13/9) {
@content;
}
}
@joshuakemmerling
joshuakemmerling / index.html
Created March 29, 2013 13:45
Pure CSS horizontal scrolling shadows
<!DOCTYPE html>
<html>
<head>
<style>
.scrollbox {
overflow: auto;
width: 200px;
max-height: 200px;
margin: 50px auto;