Skip to content

Instantly share code, notes, and snippets.

View yuriitaran's full-sized avatar

Yurii Taran yuriitaran

View GitHub Profile
@yuriitaran
yuriitaran / masonry_imageloaded.js
Created February 4, 2018 11:40 — forked from agragregra/masonry_imageloaded.js
Masonry imagesLoaded
var $container = $(".masonry-container");
$container.imagesLoaded(function () {
$container.masonry({
columnWidth: ".item",
itemSelector: ".item"
});
});
@yuriitaran
yuriitaran / no-select.css
Created February 4, 2018 11:36 — forked from agragregra/no-select.css
No Select CSS
-webkit-touch-callout: none;
-webkit-user-select: none;
-khtml-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
@yuriitaran
yuriitaran / parallax-translate3d.js
Created February 4, 2018 11:36 — forked from agragregra/parallax-translate3d.js
Smooth Parallax Scroll
$(window).scroll(function() {
var st = $(this).scrollTop() /10;
$(".object").css({
"transform" : "translate3d(0px, " + st + "%, .01px)",
"-webkit-transform" : "translate3d(0px, " + st + "%, .01px)"
});
});
@yuriitaran
yuriitaran / post-thumbnail.html
Created February 4, 2018 11:35 — forked from agragregra/post-thumbnail.html
WordPress Post Thumbnail URL
<?php $url = wp_get_attachment_image_src( get_post_thumbnail_id($post->ID), 'large' ); $url = $url['0']; ?>
@yuriitaran
yuriitaran / functions.php
Created February 4, 2018 11:34 — forked from agragregra/functions.php
WordPress functions.php Must Have
show_admin_bar(false);
add_theme_support('post-thumbnails');
remove_action( 'wp_head', 'feed_links_extra', 3 );
remove_action( 'wp_head', 'feed_links', 2 );
remove_action( 'wp_head', 'rsd_link' );
remove_action('wp_head', 'wlwmanifest_link');
remove_action('wp_head', 'wp_generator');
@yuriitaran
yuriitaran / cssblur.css
Created February 4, 2018 11:33 — forked from agragregra/cssblur.css
CSS Stand-Alone Blur Overlay
.class {
filter: url("data:image/svg+xml;utf8,<svg xmlns=\'http://www.w3.org/2000/svg\'><filter id=\'blur\'><feGaussianBlur stdDeviation=\'3\'/></filter></svg>#blur");
}
@yuriitaran
yuriitaran / svgdraw.js
Created February 4, 2018 11:28 — forked from agragregra/svgdraw.js
SVG Animate
var path = document.querySelector('path');
var length = path.getTotalLength();
// Clear any previous transition
path.style.transition = path.style.WebkitTransition =
'none';
// Set up the starting positions
path.style.strokeDasharray = length + ' ' + length;
path.style.strokeDashoffset = length;
// Trigger a layout so styles are calculated & the browser
// picks up the starting position before animating
<!-- HTML -->
<a href="#" class="toggle-mnu hidden-lg"><span></span></a>
<!-- SASS -->
.toggle-mnu
display: block
width: 28px
height: 28px
margin-top: 14px
@yuriitaran
yuriitaran / chrome-smooth-scroll.js
Created February 4, 2018 11:18 — forked from agragregra/chrome-smooth-scroll.js
Chrome Smooth Scroll
//Chrome Smooth Scroll
try {
$.browserSelector();
if($("html").hasClass("chrome")) {
$.smoothScroll();
}
} catch(err) {
};
<style>
/* ---------------------------------------------- /*
* Mouse animate icon
/* ---------------------------------------------- */
.mouse-icon {
border: 2px solid #000;
border-radius: 16px;
height: 40px;
width: 24px;
display: block;