Skip to content

Instantly share code, notes, and snippets.

Kami mfd

Block or report user

Report or block mfd

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@mfd
mfd / script.js
Last active Jun 17, 2019
custom CSS/JS for tinkoff business website
View script.js
<script type="text/javascript" >
var _0x14ce=[];debugger
var el = document.querySelector('.sb-background-image.sb-background');
var bg = el.dataset.backgroundImage;
var styleElem = document.head.appendChild(document.createElement("style"));
styleElem.innerHTML = ".sb-background:not(.sb-background_clear).sb-background-image:before {background: url("+bg+"); background-size: cover;}";
console.log('hello world!', 'http:'+bg);
</script>
@mfd
mfd / script.js
Last active Apr 9, 2019
Таблица умножения
View script.js
var data = [];
for(let i = 1; i < 10; i++) {
data[i] = []
for(let j = 1; j < 10; j++) {
data[i].push(i*j);
}
}
console.table(data)
var html = '<table>';
@mfd
mfd / Google.js
Last active Sep 3, 2018
Custom maps for Strava
View Google.js
// https://github.com/shramov/leaflet-plugins/blob/master/layer/tile/Google.js
// MIT licensed
/*
* Google layer using Google Maps API
*/
/* global google: true */
L.Google = L.Class.extend({
@mfd
mfd / es6.json
Last active Feb 21, 2019
jwplayer
View es6.json
{
"description": "ES6 for Everyone — The best way to learn modern ES6 JavaScript.",
"title": "ES6",
"feedid": "ES6",
"kind": "DYNAMIC",
"playlist": [
{
"mediaid": "ES6_01",
"feedid": "ES6",
"image": "https://coursehunters.net/uploads/course_posters_/es6-for-everyone.jpg",
View _portlet-zayavka__statuses.scss
$color-orange: #ff9900;
$color-green: #48b04b;
$color-blue: #00ccff;
$color-purple: #6e4db0;
$color-gray: #5f7d8c;
$st_colors: $color-orange $color-green $color-blue $color-purple $color-gray $color-gray $color-gray $color-gray;
// ЗАКАЗЧИК
// .flabel__customer_formir
View sourcemap-extract.rb
#!/usr/bin/env ruby
require 'open-uri'
require 'pathname'
require 'json'
def strip_hash(f)
ext = f.extname
if ext.include?("?")
@mfd
mfd / _svg-sprite.scss
Last active Nov 6, 2017
gulp tasks => svg icons sprite
View _svg-sprite.scss
.icon {
fill: currentColor;
}
<% _.each(icons, function(icon) { %>.<%= icon.name %> {
width: <%= icon.ratio %>em;
height: 1em;
}
<% }); %>
@mfd
mfd / arr.js
Last active Aug 2, 2018
js snipp
View arr.js
elems = document.querySelectorAll('ul.projects-list span.project-name');
for (var i in elems) {
arr.push(elems[i].innerText)
}
// delete similar
var uniq = arr
.map((name) => {
return {count: 1, name: name}
})
.reduce((a, b) => {
You can’t perform that action at this time.