Skip to content

Instantly share code, notes, and snippets.

View djalmaaraujo's full-sized avatar
🌊
Working from home

Djalma Araújo djalmaaraujo

🌊
Working from home
View GitHub Profile
require 'rubygems'
require 'sass'
require 'sass/exec'
files = Dir.glob($project.getProperty('scss'))
Dir.mkdir($project.getProperty('scss.build')) unless File.exists?($project.getProperty('scss.build'))
files.each do
| file |
puts '[SCSS] Compiling ' + File.basename(file, ".*") + '.css'
var NomeDaClasseExtension = function() {};
NomeDaClasseExtension.ATTRS = {
attr1: {
value: function() {}
},
attr2: {
value: [],
setter: ,
/*
* The Modernizr.touch test only indicates if the browser supports
* touch events, which does not necessarily reflect a touchscreen
* device, as evidenced by tablets running Windows 7 or, alas,
* the Palm Pre / WebOS (touch) phones.
*
* Additionally, Chrome (desktop) used to lie about its support on this,
* but that has since been rectified: crbug.com/36415
*
* We also test for Firefox 4 Multitouch Support.
<div class="container">
<div class="row">
<div style="background: #000; overflow:hidden; border-right:4px solid red; display: inline-block; position: relative; height: 100%; width: 15%;">
<p>testando</p>
</div>
<div style="background: #000; overflow:hidden; border-right:4px solid red; position: relative; height: 100%; width: 15%; display: inline-block;">
<p>testando</p>
</div>
<br clear="all" />
</div>
@djalmaaraujo
djalmaaraujo / gist:3450022
Created August 24, 2012 12:28
Testing gist.io

ZURB Foundation Features

Pros

  • Sass
  • The GRID system is very good (12 columns)

Cons

  • IE7 support was deprecated on 2.2.1 verson
  • Doesn't support IE8 with All features
AUI.add('aui-cep', function(A) {
/**
* The CEP informations to Brazil Addresses
*
* @module aui-cep
*
* TODO:
* - Escolher um webservice bem utilizado para usar como padrão;
*
*/
@djalmaaraujo
djalmaaraujo / konami-code
Created July 13, 2012 01:12
Konami Code for YUI3
YUI.add('konami', function (Y) {
Y.Event.define('konami', {
_konamiKeys: [38,38,40,40,37,39,37,39,66,65],
on: function (node, sub, notifier) {
var instance = this;
sub._firstIndexLenght = 0;
sub._index = 0;
sub._handle = Y.on('keydown', Y.rbind(instance._handleKeyDown, instance, sub, notifier));
YUI.add("konami", function (Y) {
Y.Event.define('konami', {
on: function (node, sub, notifier) {
var kkeys = [],
konami = "38,38,40,40,37,39,37,39,66,65";
Y.one(document).on('keydown', function(e) {
kkeys.push( e.keyCode );
if ( kkeys.toString().indexOf( konami ) >= 0 ){
Y.one(document).detach('keydown', arguments.callee);
@djalmaaraujo
djalmaaraujo / pagseguro_controller.php
Created July 9, 2012 18:17
Controller::Pagseguro
<?php
require_once APP . "/lib/PagSeguroLibrary/PagSeguroLibrary.php";
class PagseguroController extends AppController {
public $uses = array();
/**
* Método da Lib do Pagseguro
* para repassar os dados da
* transação.
@djalmaaraujo
djalmaaraujo / brazil-cities-states-en.json
Last active January 8, 2024 22:42
Cidades e estados brasileiros JSON & Javascript Object exported / Brazilian States and Cities in JSON or JS/Javascript
{
"states": [
{
"uf": "AC",
"name": "Acre",
"cities": [
"Acrelândia",
"Assis Brasil",
"Brasiléia",
"Bujari",