Skip to content

Instantly share code, notes, and snippets.

View lipelopeslage's full-sized avatar

Felipe Lopes Lage lipelopeslage

View GitHub Profile
@lipelopeslage
lipelopeslage / parallax-secret.js
Created November 21, 2012 18:30
My parallax secret
/*########################################################################*/
/*###### using jQuery selector for a fast/cross-browser resolution #######*/
/*########################################################################*/
var totalAreas = 6, // this value is obviously arbitrary
winH = $(window).height, // the window height
top = $(window).scrollTop(), // the current scroll value
maxScroll = $(document).height() - winH, // the maximum scroll value
scrollPerc = top/maxScroll, // the current scroll percentage
areaPercent = 0; // init variable
@lipelopeslage
lipelopeslage / gist:5061789
Last active December 14, 2015 08:59
Resolução Ex. 19 - Prof. Chiara FATEC Baixada Santista - Sistemas para Internet
algoritmo "exercicio_19"
var x1, x2, x3, y1, y2, y3, a, b, c, area, perimetro : Real
tipo : caracter
inicio
escreva("Insira o valor de x1: ")
leia(x1)
escreva("Insira o valor de x2: ")
leia(x2)
escreva("Insira o valor de x3: ")
leia(x3)
algoritmo "lista2_13"
var i,a,s,p:real
inicio
a <- 1
i <- 1
s <- 0
repita
@lipelopeslage
lipelopeslage / style.css
Created September 1, 2014 14:59
estilo
@import "utils.scss";
.joyride-modal-bg{
z-index: 9999;
}
.joyride-tip-guide{
z-index: 10000;
}
@lipelopeslage
lipelopeslage / tabela.html
Created September 18, 2015 12:10
Tabela + querySelectors
<!doctype html>
<html>
<head></head>
<body>
<script>
// CRIAR UMA TABELA E ADICIONAR NO DOM
// criar tabela com o conteúdo de uma lista
var alunos = [{nome:'Deni', ra:'1420088-1'},
@lipelopeslage
lipelopeslage / relogio.html
Created September 18, 2015 12:11
Relógio (setTimeout/setInterval)
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<p id="relogio"></p>
@lipelopeslage
lipelopeslage / valida_cor.html
Created September 18, 2015 23:02
Validar cor hexadecimal
<!doctype html>
<html>
<head></head>
<body>
Hexadecimal vai de 0-9 e de A-F,
para ser válido, a conversão de um hexadecimal em inteiro deve
ser entre 0(0) e 255(F).<br>
Para validar o hexadecimal, é preciso checar caractere por caractere.
<div id="formulario">
<!--
@lipelopeslage
lipelopeslage / exercicio01.html
Last active October 4, 2015 21:24
Gabarito - Simulado P1 [Javascript]
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Exercício 1</title>
</head>
<body>
<script>
@lipelopeslage
lipelopeslage / resolucao_joao.html
Last active October 6, 2015 03:24
resolucao_joao.html
<html lang="pt-BR">
<head>
<meta charset="UTF-8" />
<title></title>
</head>
<body>
n1: <input id="n1" type="text"><br>
n2: <input id="n2" type="text"><br>
<ul>
@lipelopeslage
lipelopeslage / ex1.html
Last active November 22, 2015 16:08
Resolução simulado P2 - Javascript
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Ex.01</title>
<script src="jquery-1.11.3.min.js"></script>
</head>
<body>
seletores:
tr:odd - ímpar (vermelho)