Skip to content

Instantly share code, notes, and snippets.

<div class="swiper-wrapper">
<!-- Slides -->
<div id="bronze" class="pick-tariff-item swiper-slide swiper-slide-active" style="width: 353.333px; margin-right: 25px;">
<h3 class="pick-tariff-item__title">Бронзовые</h3>
<span class="pick-tariff-item__coast">400 грн.</span>
<p class="pick-tariff-item__description">
Номер, в котором повторяются комбинации цифр, или зеркальные цифры
</p>
<ul class="pick-tariff-list" style="display: flex;">
1) nodesArray = [...someVariable];
2) nodesArray = [].slice.call(document.querySelectorAll("div"));
const $vacansies = $(".vacancies-section__holder");
let $bottom;
$(window).on('scroll', function () {
$bottom = $vacansies.offset().top + $vacansies.height();
if ($(window).scrollTop() - $bottom > 0 ) {
$('.filter-block').addClass('fixed');
} else $('.filter-block').removeClass('fixed');
});
function customGet ( url, cb ) {
var xmlhttp = new XMLHttpRequest();
xmlhttp.onreadystatechange = function() {
if (this.readyState == 4 && this.status == 200) {
var data = JSON.parse(xmlhttp.response);
cb(data);
}
};
xmlhttp.open("GET", url, true);
padding-left: 9999px;
margin-left: -9999px;
-webkit-box-shadow: 9999px 0 0 0 #f8f8f8;
// check element in viewport
document.addEventListener('scroll', function(el) {
var stage1 = document.querySelector('.stage1');
var stage2 = document.querySelector('.stage2');
var stage3 = document.querySelector('.stage3');
var stage4 = document.querySelector('.stage4');
var stage5 = document.querySelector('.stage5');
var stage6 = document.querySelector('.stage6');
// sticky heder
// When the user scrolls the page, execute myFunction
window.onscroll = function() {myFunction()};
// Get the header
var header = document.querySelector(".header");
// Get the offset position of the navbar
var sticky = header.offsetTop;
background: radial-gradient(ellipse at center,rgba(29,58,71,.75) 0,#13141c 80%);
@0632347878
0632347878 / underline from center
Created January 28, 2018 14:13
on hover underline from center
a::after {
position: absolute;
left: 50%;
right: 50%;
height: 3px;
bottom: -10px;
content: "";
background-color: #00e8bb;
-webkit-transition: 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
-o-transition: 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
@0632347878
0632347878 / toggle-checkbox.html
Created January 13, 2018 08:41 — forked from chrisdavies/toggle-checkbox.html
A CSS-only (no JS) checkbox toggle control. Might make the label text (yes/no) markkup rather than CSS injected content.
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Toggle Example</title>
<style>
body {
font-family: sans-serif;
}