2017-03-06 17:35:08 +01:00
|
|
|
// Additionnal "utility" breakpoints aliases
|
|
|
|
// ex. @include respond-to("medium-up") {...}
|
|
|
|
breakpoint(bp)
|
|
|
|
if bp == 'tiny'
|
2017-03-07 17:43:34 +01:00
|
|
|
return '(max-width: %s)' % tiny
|
2017-03-06 17:35:08 +01:00
|
|
|
else if bp == 'small'
|
2017-03-07 17:43:34 +01:00
|
|
|
return '(max-width: %s)' % small
|
2017-03-06 17:35:08 +01:00
|
|
|
else if bp == 'medium'
|
2017-03-07 17:43:34 +01:00
|
|
|
return '(max-width: %s)' % medium
|
2017-03-06 17:35:08 +01:00
|
|
|
else if bp == 'large'
|
2017-03-07 17:43:34 +01:00
|
|
|
return '(max-width: %s)' % large
|
2017-03-06 17:35:08 +01:00
|
|
|
else if bp == 'extra-large'
|
2017-03-07 17:43:34 +01:00
|
|
|
return '(max-width: %s)' % extra-large
|
2017-03-06 17:35:08 +01:00
|
|
|
else if bp == 'tiny-up'
|
2017-03-07 17:43:34 +01:00
|
|
|
return '(min-width: %s + 1)' % tiny
|
2017-03-06 17:35:08 +01:00
|
|
|
else if bp == 'small-up'
|
2017-03-07 17:43:34 +01:00
|
|
|
return '(min-width: %s + 1)' % small
|
2017-03-06 17:35:08 +01:00
|
|
|
else if bp == 'medium-up'
|
2017-03-07 17:43:34 +01:00
|
|
|
return '(min-width: %s + 1)' % medium
|
2017-03-06 17:35:08 +01:00
|
|
|
else if bp == 'large-up'
|
2017-03-07 17:43:34 +01:00
|
|
|
return '(min-width: %s + 1)' % large
|
2017-03-06 17:35:08 +01:00
|
|
|
else if bp == 'extra-large-up'
|
2017-03-07 17:43:34 +01:00
|
|
|
return '(min-width: %s + 1)' % extra-large
|
2017-03-06 17:35:08 +01:00
|
|
|
else if bp == 'retina'
|
|
|
|
return '(-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi), (min-resolution: 2dppx)'
|
|
|
|
|
|
|
|
/*
|
|
|
|
respond-to(value)
|
|
|
|
string = breakpoint(value)
|
2017-03-07 17:43:34 +01:00
|
|
|
@media screen and string
|
2017-03-06 17:35:08 +01:00
|
|
|
{block}
|
|
|
|
*/
|
2017-03-07 17:43:34 +01:00
|
|
|
|
|
|
|
displayFlex()
|
|
|
|
display: -webkit-box
|
|
|
|
display: -ms-flexbox
|
|
|
|
display: flex
|
|
|
|
|
|
|
|
box-orient()
|
|
|
|
-webkit-box-orient arguments
|
|
|
|
|
|
|
|
box-direction()
|
|
|
|
-webkit-box-direction arguments
|
|
|
|
|
|
|
|
flex-direction()
|
|
|
|
-ms-flex-direction arguments
|
|
|
|
flex-direction arguments
|
|
|
|
|
|
|
|
flex-wrap()
|
|
|
|
-ms-flex-wrap arguments
|
|
|
|
flex-wrap arguments
|