Skip to content

Instantly share code, notes, and snippets.

View kazzkiq's full-sized avatar

Claudio Holanda Jr. kazzkiq

View GitHub Profile
// Roda a função apenas após todo o HTML carregar
document.addEventListener('DOMContentLoaded', addMobileLinks);
function addMobileLinks() {
// Elementos que já existem na tela atualmente
var social_links = document.querySelectorAll('#menu-social-links-menu li');
var nav_mobile = document.getElementById('nav-mobile');
var nav_mobile_logo = document.querySelector('#nav-mobile .mobile-title-logo-in-header');
// Clona os links do desktop para replicá-los no mobile
@import url('https://fonts.googleapis.com/css?family=Lato:300,300i,400,400i');
.mce-content-body {
font-family: 'Lato', sans-serif;
font-size: 15px;
}
.mce-content-body p {
margin: 10px 0
}
@kazzkiq
kazzkiq / instructions.md
Last active September 13, 2018 09:35
Installing Node.js in 5 minutes: The Final Guide

Installing Node in 5 minutes: The Final Guide.

If you have a shitty internet, it may take a little longer.

First, access Node.js website and click the big green "Download" button.

Download finished? Now run the installation. While the installation goes by, grab yourself a coffee or drink some water, then get back at your chair. By now you should have Node.js and NPM (Node's package manager) installed.

Now, lets install n to manage (and update) Node versions in seconds on your machine. How to install it? Simply run:

@kazzkiq
kazzkiq / ppc.js
Last active May 12, 2017 16:39
PPC Chat Links Bar
(function (window) {
'use strict';
const TELEGRAM_LINK = 'https://t.me/peercoin';
const ROCKETCHAT_LINK = 'https://peercoin.chat/channel/general/';
const FIRST_SHOWUP_DELAY = 3500;
const STORAGE_KEY = 'PPC-Injector--USER-INTERACTED';
const HTML_ID = `INJECTOR-${Math.floor(Math.random()*1000*1000*1000)}`;
const COLOR_GREEN = '#3cb054';
const COLOR_GREEN_DARK = '#308d43';
@kazzkiq
kazzkiq / UNO_TEST.js
Created April 25, 2017 22:34
UNO_TEST
(function(){function v(a,b){b.appendChild(a)}function r(a){a.parentNode.removeChild(a)}function y(a,b,c){for(;c<a.length;c+=1)a[c].destroy(b)}function m(a){return document.createElement(a)}function p(a){return document.createTextNode(a)}function t(a){for(var b=arguments,c=1;c<arguments.length;c+=1){var d=b[c],e;for(e in d)a[e]=d[e]}return a}function z(a,b,c,d){for(var e in b)if(e in c){var g=c[e],f=d[e];if(g!==f||g&&"object"===typeof g||"function"===typeof g){var h=b[e];if(h)for(var k=0;k<h.length;k+=
1){var l=h[k];l.__calling||(l.__calling=!0,l.call(a,g,f),l.__calling=!1)}}}}function K(a,b){function c(a){a=b.get();b.toggleMenu(a.isOpen)}var d,e,g=m("div");g.setAttribute("svelte-3393754602","");g.className=d="Uno_MenuWidget__handler "+a.classOpen;g.addEventListener("click",c,!1);var f=m("div");g.appendChild(f);v(p("\n "),g);f=m("div");g.appendChild(f);v(p("\n "),g);f=m("div");g.appendChild(f);var h=p("\n"),k=m("div");k.setAttribute("svelte-3393754602","");k.className=e="Uno_MenuWidget "+a.classOpen;
f=m("ul
@kazzkiq
kazzkiq / MenuInjector.js
Created April 7, 2017 02:43
Discourse topbar menu
(function (window) {
'use strict';
const MOBILE_WIDTH_LIMIT = 768;
const MENU_BAR_HEIGHT = 45;
let headerElement = document.querySelector('.docked .d-header') || false;
let menuElement;
function hideOnMobile () {
@kazzkiq
kazzkiq / a.md
Last active March 23, 2017 23:39

1.0. Open NGINX config file (the one responsible for projects.peercoin.net)

1.1. Add this block as the first "location" block:

location ~ /.well-known {
	root /var/www/pc-showcase/;
	allow all;
}
# PWA (Application)
server {
listen 80;
listen [::]:80;
server_name app.cryptoholder.com www.app.cryptoholder.com;
return 301 https://app.cryptoholder.com$request_uri;
}
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
@kazzkiq
kazzkiq / view.php
Last active August 4, 2016 21:14 — forked from anonymous/view.php
<?php
// keep track post values
$coord = $_REQUEST['coord'];
//recupera as coordenadas e atribui ao X e Y
list($x,$y) = explode(":",$coord);
?>
<!DOCTYPE html>
<html lang="en">
<ac-popup>
<div class="popup-overlay" name="popup_overlay">
<div class="popup" name="popup">
<div class="header">
<h1 name="title">{ opts.title }</h1>
<h2 if="opts.subtitle">{ opts.subtitle }</h2>
<div class="close" onclick="{ closePopup }"></div>
</div>