Синхронизация настроек Sublime Text 3
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
$size: 30px !default; | |
$toggler-part-height: 3px !default; | |
$toggler-part-bg-color: #000 !default; | |
.close { | |
$block-name: &; // #{$block-name}__element | |
position: relative; | |
z-index: 1; |
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
%container { | |
display: block; | |
width: 960px; | |
margin: 0 auto; | |
padding: 0 10px; | |
} | |
%block-center { | |
position: absolute; | |
top: 50%; |
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
$browser-context: $font-size--root; | |
@function rem($pixels, $context: $browser-context) { | |
@if (unitless($pixels)) { | |
$pixels: $pixels * 1px; | |
} | |
@if (unitless($context)) { | |
$context: $context * 1px; | |
} |
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
function animate(from, to, speed) { | |
// if not an animation, just reposition | |
if (!speed) { | |
element.style.left = to + 'px'; | |
return; | |
} | |
var start = +new Date(); |
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
// Modules | |
var cache = {}; | |
function importAll(r) { | |
r.keys().forEach(function(key) { | |
cache[ key ] = r(key); | |
}); | |
} | |
importAll(require.context('../../modules/', true, /^[^\_]*\.js/)); |
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 | |
// $( document ).ready(function() { | |
// // code | |
// }); | |
// Изоляция без jQuery | |
// (function(){ | |
// // code | |
// }()); |
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
//- | |
Include mixin to file: | |
include ../mixins/_svg | |
Syntax: | |
+icon(name, src, attrs) | |
Call: | |
+icon("cat") -> <svg ..class="icon-cat"><use xlink:href="#icon-cat"></use></svg> | |
+icon("cat", "../sprite.svg") -> <svg ..class="icon-dog"><use xlink:href="../sprite.svg#icon-dog"></use></svg> |
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
function isMobile() { | |
mobile = ['iphone', 'ipad', 'android', 'blackberry', 'nokia', 'opera mini', 'windows mobile']; | |
for (var i in mobile) if (navigator.userAgent.toLowerCase().indexOf(mobile[i]) > 0) return true; | |
return false; | |
} |
NewerOlder