This file contains 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
// Сначала необходимо долистать до конца страницы: Fn + ↓ | |
total = 0; | |
$('.order-summary__sum').each(function() { | |
item = parseInt($(this).text().replace('₽', '').replace(' ', '')); | |
total += item; | |
}); | |
console.log(total); |
This file contains 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
Tabs: | |
[ | |
{"caption":"Tab Title", "fields": [ | |
{"field":"title","caption":"Name"}, | |
{"field":"description","caption":"Description","inputTVtype":"textarea"}, | |
{"field":"imageTV","caption":"Photo","inputTV":"imageTV"} | |
]} | |
] | |
Table: |
This file contains 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
var gulp = require('gulp'), | |
sass = require('gulp-ruby-sass'), | |
autoprefixer = require('gulp-autoprefixer'), | |
minifycss = require('gulp-minify-css'), | |
jshint = require('gulp-jshint'), | |
uglify = require('gulp-uglify'), | |
rename = require('gulp-rename'), | |
clean = require('gulp-clean'), | |
concat = require('gulp-concat'), | |
notify = require('gulp-notify'), |
This file contains 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
<div class="top" title="Наверх"><i class="fa fa-angle-double-up"></i></div> | |
.top | |
position: fixed | |
bottom: 25px | |
background-color: #E0E0E0 | |
border-radius: 10em | |
color: #666 | |
font-size: 26px | |
width: 50px |
This file contains 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
MODx Ace Material Theme | |
1. Системные настройки > Пространство имен "ace": | |
Размер шрифта: 13px | |
Высота области редактирования: 560 | |
Невидимые символы: Да | |
Мягкая табуляция: Нет | |
Размер табуляции: 2 | |
Тема редактора: tomorrow_night |
This file contains 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
// Keymap (Windows Users): | |
[ | |
{ "keys": ["alt+shift+f"], "command": "reindent" }, | |
] | |
// Settings: | |
{ | |
"auto_complete": false, | |
"bold_folder_labels": true, | |
"close_windows_when_empty": false, |
This file contains 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
//Resize Window | |
function onResize() { | |
}; | |
var doit; | |
doit = setTimeout(onResize, 400); | |
window.onresize = function() { | |
clearTimeout(doit); | |
doit = setTimeout(onResize, 400); | |
}; |
This file contains 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
// Lazy loading img & background images using intersection observer | |
// Reference: https://developers.google.com/web/fundamentals/performance/lazy-loading-guidance/images-and-video/ | |
// Using example: <img class="lazy" src="thumb.gif" data-src="real-img.jpg" data-srcset="real-img@1x.jpg 1x, real-img@2x.jpg 2x"> | |
// Background image class usign example: <div class="lazy-background"> with added class ".visible" for styling | |
// Background image style attribute lazy loading example: <div data-bg="image.jpg"> | |
// delete window.IntersectionObserver; // Fallback Testing | |
document.addEventListener('DOMContentLoaded', function() { |
This file contains 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
// Original | |
var hashLinks = document.querySelectorAll("a[href^='#']"); | |
[].forEach.call(hashLinks, function (link) { | |
link.addEventListener("click", function (event) { | |
event.preventDefault(); | |
history.pushState({}, "", link.href); | |
history.pushState({}, "", link.href); | |
history.back(); | |
}); | |
}); |
This file contains 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
/*========== Desktop First Method ==========*/ | |
/* Large Devices, Wide Screens */ | |
@media only screen and (max-width : 1200px) { | |
} | |
/* Medium Devices, Desktops */ | |
@media only screen and (max-width : 992px) { |