Skip to content

Instantly share code, notes, and snippets.

View akella's full-sized avatar
🏠
Working from home

Yuri Artiukh akella

🏠
Working from home
View GitHub Profile
.bg-crop{
_filter : expression(
(runtimeStyle.filter == '') ? runtimeStyle.filter = 'progid:DXImageTransform.Microsoft.AlphaImageLoader(src='+currentStyle.backgroundImage.split('\"')[1]+', sizingMethod=crop)' : runtimeStyle.filter,
runtimeStyle.backgroundImage = 'none');
}
.bg-png-scale{
filter : expression(
(runtimeStyle.backgroundImage != 'none') ? runtimeStyle.filter = 'progid:DXImageTransform.Microsoft.AlphaImageLoader(src='+currentStyle.backgroundImage.split('\"')[1]+', sizingMethod=scale)' : runtimeStyle.filter,
runtimeStyle.backgroundImage = 'none');
}
.l-wrapper {
max-width: 1260px;
padding: 0 10px;
margin: 0 auto -525px;
position: relative;
min-height: 100%;
height: auto !important;
height: 100%;
@include respond-to(mob) {
width: 320px;
.l-wrapper {
max-width: 1260px;
padding: 0 10px;
margin: 0 auto -525px;
position: relative;
min-height: 100%;
height: auto !important;
height: 100%;
@include respond-to(mob) {
width: 320px;
.l-wrapper {
max-width: 1260px;
padding: 0 10px;
margin: 0 auto -525px;
position: relative;
min-height: 100%;
height: auto !important;
height: 100%;
@include respond-to(mob) {
@import "base";
// =======Sprites
// .whatever{
// @include sized-sprite($icons, badge_hit);
// @include retina{
// @include sized-sprite($icons, badge_new);
// }
// }
// =======animation setting example (set it anywehere)
// @include keyframes(rotate) {
@akella
akella / gist:4986096
Last active December 13, 2015 22:39
loop
a{
display: inline-block;
vertical-align: top;
@extend %hide-text;
//loop thru icons
@each $social in fb, vk, gp, rss{
&.social__#{$social}{
@include sized-sprite($icons, f-#{$social});
&:hover{@include sized-sprite($icons, f-#{$social}_hover);}
&:active{@include sized-sprite($icons, f-#{$social}_active);}
@import "base";
// =======Sprites
// .whatever{
// @include sized-sprite($icons, badge_hit);
// @include retina{
// @include sized-sprite($icons, badge_new);
// }
// }
// =======animation setting example (set it anywehere)
// @include keyframes(rotate) {
@viewport {
width: auto; // auto | device-width | length | percentage
// 'width' задаст сразу max и min-width.
max-width: auto;
min-width: auto;
// 'zoom' тоже что 'initial-scale' в meta
// Значения 1.0 или 100% означают что нет zoom.
zoom: auto; // auto | number | percentage
@akella
akella / gist:5016373
Created February 22, 2013 20:38
checking if it's touch device
if (!("ontouchstart" in document.documentElement)) {
document.documentElement.className += "no-touch";
}
@akella
akella / gist:5051873
Created February 27, 2013 21:24
ios bg problem
.container {
position: relative;
margin:77px 0;
height:2209px;
background: url(../images/bg.jpg) no-repeat 50% 0;
-webkit-background-size: 3000px 2209px;
font-family: 'Conv_Underdog', Tahoma, sans-serif;
font-size:14px;