Created
December 5, 2015 09:26
-
-
Save jlapitan/827abbd84a682488701f to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
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
// ---- | |
// libsass (v3.2.5) | |
// ---- | |
// Author: Rafal Bromirski | |
// www: http://rafalbromirski.com/ | |
// github: http://github.com/paranoida/sass-mediaqueries | |
// | |
// Licensed under a MIT License | |
// | |
// Version: | |
// 1.6.1 | |
// --- generator --------------------------------------------------------------- | |
@mixin mq($args...) { | |
$media-type: 'only screen'; | |
$media-type-key: 'media-type'; | |
$args: keywords($args); | |
$expr: ''; | |
@if map-has-key($args, $media-type-key) { | |
$media-type: map-get($args, $media-type-key); | |
$args: map-remove($args, $media-type-key); | |
} | |
@each $key, $value in $args { | |
@if $value { | |
$expr: "#{$expr} and (#{$key}: #{$value})"; | |
} | |
} | |
@media #{$media-type} #{$expr} { | |
@content; | |
} | |
} | |
// --- screen ------------------------------------------------------------------ | |
@mixin screen($min, $max, $orientation: false) { | |
@include mq($min-width: $min, $max-width: $max, $orientation: $orientation) { | |
@content; | |
} | |
} | |
@mixin max-screen($max) { | |
@include mq($max-width: $max) { | |
@content; | |
} | |
} | |
@mixin min-screen($min) { | |
@include mq($min-width: $min) { | |
@content; | |
} | |
} | |
@mixin screen-height($min, $max, $orientation: false) { | |
@include mq($min-height: $min, $max-height: $max, $orientation: $orientation) { | |
@content; | |
} | |
} | |
@mixin max-screen-height($max) { | |
@include mq($max-height: $max) { | |
@content; | |
} | |
} | |
@mixin min-screen-height($min) { | |
@include mq($min-height: $min) { | |
@content; | |
} | |
} | |
// --- hdpi -------------------------------------------------------------------- | |
@mixin hdpi($ratio: 1.3) { | |
@media only screen and (-webkit-min-device-pixel-ratio: $ratio), | |
only screen and (min-resolution: #{round($ratio*96)}dpi) { | |
@content; | |
} | |
} | |
// --- hdtv -------------------------------------------------------------------- | |
@mixin hdtv($standard: '1080') { | |
$min-width: false; | |
$min-height: false; | |
$standards: ('720p', 1280px, 720px) | |
('1080', 1920px, 1080px) | |
('2K', 2048px, 1080px) | |
('4K', 4096px, 2160px); | |
@each $s in $standards { | |
@if $standard == nth($s, 1) { | |
$min-width: nth($s, 2); | |
$min-height: nth($s, 3); | |
} | |
} | |
@include mq( | |
$min-device-width: $min-width, | |
$min-device-height: $min-height, | |
$min-width: $min-width, | |
$min-height: $min-height | |
) { | |
@content; | |
} | |
} | |
// --- iphone4 ----------------------------------------------------------------- | |
@mixin iphone4($orientation: false) { | |
$min: 320px; | |
$max: 480px; | |
$pixel-ratio: 2; | |
$aspect-ratio: '2/3'; | |
@include mq( | |
$min-device-width: $min, | |
$max-device-width: $max, | |
$orientation: $orientation, | |
$device-aspect-ratio: $aspect-ratio, | |
$-webkit-device-pixel-ratio: $pixel-ratio | |
) { | |
@content; | |
} | |
} | |
// --- iphone5 ----------------------------------------------------------------- | |
@mixin iphone5($orientation: false) { | |
$min: 320px; | |
$max: 568px; | |
$pixel-ratio: 2; | |
$aspect-ratio: '40/71'; | |
@include mq( | |
$min-device-width: $min, | |
$max-device-width: $max, | |
$orientation: $orientation, | |
$device-aspect-ratio: $aspect-ratio, | |
$-webkit-device-pixel-ratio: $pixel-ratio | |
) { | |
@content; | |
} | |
} | |
// --- iphone6 ----------------------------------------------------------------- | |
@mixin iphone6($orientation: false) { | |
$min: 375px; | |
$max: 667px; | |
$pixel-ratio: 2; | |
@include mq( | |
$min-device-width: $min, | |
$max-device-width: $max, | |
$orientation: $orientation, | |
$-webkit-device-pixel-ratio: $pixel-ratio | |
) { | |
@content; | |
} | |
} | |
// --- iphone6 plus ------------------------------------------------------------ | |
@mixin iphone6-plus($orientation: false) { | |
$min: 414px; | |
$max: 736px; | |
$pixel-ratio: 3; | |
@include mq( | |
$min-device-width: $min, | |
$max-device-width: $max, | |
$orientation: $orientation, | |
$-webkit-device-pixel-ratio: $pixel-ratio | |
) { | |
@content; | |
} | |
} | |
// --- ipad (all) -------------------------------------------------------------- | |
@mixin ipad($orientation: false) { | |
$min: 768px; | |
$max: 1024px; | |
@include mq( | |
$min-device-width: $min, | |
$max-device-width: $max, | |
$orientation: $orientation | |
) { | |
@content; | |
} | |
} | |
// --- ipad-retina ------------------------------------------------------------- | |
@mixin ipad-retina($orientation: false) { | |
$min: 768px; | |
$max: 1024px; | |
$pixel-ratio: 2; | |
@include mq( | |
$min-device-width: $min, | |
$max-device-width: $max, | |
$orientation: $orientation, | |
$-webkit-device-pixel-ratio: $pixel-ratio | |
) { | |
@content; | |
} | |
} | |
// --- orientation ------------------------------------------------------------- | |
@mixin landscape() { | |
@include mq($orientation: landscape) { | |
@content; | |
} | |
} | |
@mixin portrait() { | |
@include mq($orientation: portrait) { | |
@content; | |
} | |
} | |
////////////////////// | |
@mixin pageAbout{ | |
.page-about_us .container img{ | |
float:none !important; | |
width: 90%; | |
} | |
} | |
@mixin tableFont{ | |
.page-sitemap table td{ | |
font-size:80%; | |
} | |
} | |
$responsive:100% !important; | |
@include iphone4(){ | |
.page img | |
{ | |
padding:15px 5px!important; | |
} | |
.pxs_thumbnails | |
{ | |
display:none; | |
} | |
ul.pxs_slider li img | |
{ | |
width: $responsive; | |
} | |
.pxs_slider span{ | |
font-size:86%; | |
} | |
.fl { | |
margin-top: 20px; | |
width: 90%; | |
font-size:90%; | |
} | |
.beforeAndAfterContainer | |
{ | |
margin-top:20px; | |
} | |
.page-about_us .container.ten img{ | |
float:none !important; | |
width: 90%; | |
} | |
@include tableFont() | |
} | |
@include iphone5(){ | |
.page img | |
{ | |
padding:15px 5px!important; | |
} | |
.pxs_thumbnails | |
{ | |
display:none; | |
} | |
ul.pxs_slider li img | |
{ | |
width: $responsive; | |
} | |
.fl { | |
margin-top: 20px; | |
width: 90%; | |
font-size:90%; | |
} | |
.beforeAndAfterContainer | |
{ | |
margin-top:20px; | |
} | |
.featuredImg,.imgDesc, | |
.featuredImg2,.imgDesc2{ | |
width:90% !important; | |
} | |
@include pageAbout | |
} | |
@include iphone6(){ | |
.page img | |
{ | |
padding:15px 5px!important; | |
} | |
.pxs_thumbnails | |
{ | |
display:none; | |
} | |
ul.pxs_slider li img | |
{ | |
width: $responsive; | |
} | |
.fl { | |
margin-top: 20px; | |
width: 80%; | |
font-size:90%; | |
} | |
.beforeAndAfterContainer | |
{ | |
margin-top:10px; | |
} | |
.featuredImg,.imgDesc{ | |
width:45% !important; | |
} | |
@include pageAbout | |
} | |
@include iphone6-plus(){ | |
.page img | |
{ | |
padding:15px 5px!important; | |
} | |
.pxs_thumbnails | |
{ | |
display:none; | |
} | |
ul.pxs_slider li img | |
{ | |
width: $responsive; | |
} | |
.fl { | |
margin-top: 20px; | |
width: 80%; | |
font-size:90%; | |
} | |
.beforeAndAfterContainer | |
{ | |
margin-top:10px; | |
} | |
.featuredImg,.imgDesc{ | |
width:45% !important; | |
} | |
@include pageAbout | |
} |
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
@media only screen and (min-device-width: 320px) and (max-device-width: 480px) and (device-aspect-ratio: 2/3) and (-webkit-device-pixel-ratio: 2) { .page img { padding: 15px 5px !important; } | |
.pxs_thumbnails { display: none; } | |
ul.pxs_slider li img { width: 100% !important; } | |
.pxs_slider span { font-size: 86%; } | |
.fl { margin-top: 20px; width: 90%; font-size: 90%; } | |
.beforeAndAfterContainer { margin-top: 20px; } | |
.page-about_us .container.ten img { float: none !important; width: 90%; } | |
.page-sitemap table td { font-size: 80%; } } | |
@media only screen and (min-device-width: 320px) and (max-device-width: 568px) and (device-aspect-ratio: 40/71) and (-webkit-device-pixel-ratio: 2) { .page img { padding: 15px 5px !important; } | |
.pxs_thumbnails { display: none; } | |
ul.pxs_slider li img { width: 100% !important; } | |
.fl { margin-top: 20px; width: 90%; font-size: 90%; } | |
.beforeAndAfterContainer { margin-top: 20px; } | |
.featuredImg, .imgDesc, .featuredImg2, .imgDesc2 { width: 90% !important; } | |
.page-about_us .container img { float: none !important; width: 90%; } } | |
@media only screen and (min-device-width: 375px) and (max-device-width: 667px) and (-webkit-device-pixel-ratio: 2) { .page img { padding: 15px 5px !important; } | |
.pxs_thumbnails { display: none; } | |
ul.pxs_slider li img { width: 100% !important; } | |
.fl { margin-top: 20px; width: 80%; font-size: 90%; } | |
.beforeAndAfterContainer { margin-top: 10px; } | |
.featuredImg, .imgDesc { width: 45% !important; } | |
.page-about_us .container img { float: none !important; width: 90%; } } | |
@media only screen and (min-device-width: 414px) and (max-device-width: 736px) and (-webkit-device-pixel-ratio: 3) { .page img { padding: 15px 5px !important; } | |
.pxs_thumbnails { display: none; } | |
ul.pxs_slider li img { width: 100% !important; } | |
.fl { margin-top: 20px; width: 80%; font-size: 90%; } | |
.beforeAndAfterContainer { margin-top: 10px; } | |
.featuredImg, .imgDesc { width: 45% !important; } | |
.page-about_us .container img { float: none !important; width: 90%; } } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment