Skip to content

Instantly share code, notes, and snippets.

View guilherme-teodoro's full-sized avatar

Guilherme Teodoro guilherme-teodoro

View GitHub Profile
@guilherme-teodoro
guilherme-teodoro / xrandr.sh
Last active August 29, 2015 14:07
Configuração xrandr
#!/bin/sh
xrandr --newmode "1440x900_60.00" 106.50 1440 1528 1672 1904 900 903 909 934 -hsync +vsync && xrandr --addmode VGA1 "1440x900_60.00" && xrandr --output VGA1 --mode "1440x900_60.00"
xrandr --newmode "1368x768_60.00" 85.25 1368 1440 1576 1784 768 771 781 798 -hsync +vsync && xrandr --addmode DP1 "1368x768_60.00" && xrandr --output DP1 "1368x768_60.00"
@guilherme-teodoro
guilherme-teodoro / flash-message.cljs
Created June 15, 2016 22:39
Flash Message queue
(ns kitasato.components.flash-message
(:require-macros [cljs.core.async.macros :refer [alt! go-loop]])
(:require [reagent.core :as r]
[cljs.core.async :refer [close! chan <! timeout put!]]))
(defonce bus (chan))
(defonce current (r/atom [nil nil]))
(defonce main-loop
@guilherme-teodoro
guilherme-teodoro / Modal.js
Last active June 21, 2016 22:21
A Modal made with React and React Motion
import React, { Component, PropTypes } from 'react';
import { TransitionMotion, spring } from 'react-motion';
class Modal extends Component {
defaultStyles() {
return {
key: 'modal',
data: {},
style: {
opacity: spring(1), position: spring(0)
@guilherme-teodoro
guilherme-teodoro / todo-posh.cljs
Last active August 25, 2016 22:01
Todo list with CLJS + Reagent + Datascript + Posh
(ns todo.core
(:require [reagent.core :as r]
[reagent.ratom :refer-macros [reaction]]
[posh.reagent :refer [pull q posh!] :as p]
[datascript.core :as d]))
(def schema {:story/id {:db.unique :db.unique/identity}
:task/story {:db.valueType :db.type/long}})
(def conn (d/create-conn))
@guilherme-teodoro
guilherme-teodoro / pipeline.clj
Created September 9, 2016 14:46 — forked from JacobNinja/pipeline.clj
Clojure core.async pipeline example
(require '[clojure.core.async :as async]
'[clj-http.client :as client]
'[clojure.data.json :as json])
(def concurrency 5)
(let [in (async/chan)
out (async/chan)
request-handler (fn [url out*]
(async/go
(def sizes {:small (px 8)
:base (px 16)
:big (px 24)
:huge (px 32)})
(def colors {:primary "#1A8EFF"
:dangerous "red"})
(defn style [{:keys [type size]}]
[{:background (stylish/palette colors type :primary)
(defn debug
[text]
[{:position :relative,
:border [[(unit/px 1) :solid :red]]}
[:&:after
{:position :absolute,
:top 0,
:left 0,
:background :yellow,
:color :red,
@guilherme-teodoro
guilherme-teodoro / README.md
Last active January 18, 2017 16:01
Teste de Programação - Frontend - XERPA

Frontend - XERPA

Olá! Como parte do processo de seleção da Xerpa, gostaríamos que você fizesse uma pequena tarefa.

A ideia é olhar como é seu estilo de programação, quais decisões você toma ao resolver um problema e aplicar os estilos na página. Para isso, crie um projeto no seu Github para podermos acompanhar a árvore de commits!

Sinta-se à vontade para criar em cima do problema abaixo. Caso algo não esteja claro, pode assumir o que for para você, apenas indique suas suposições em documentação.

Qualquer dúvida maior pode nos perguntar, mas no geral, divirta-se!

<!DOCTYPE html>
<html lang="pt-BR">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no, shrink-to-fit=no">
<link rel="shortcut icon" type="image/png" href="/favicon.ico"/>
<title>Xerpa - Style Guide</title>
<link rel="stylesheet" href="app.css">
</head>
/*!
* React Tether 0.5.7
* https://github.com/souporserious/react-tether
* Copyright (c) 2017 React Tether Authors
*/
window["TetherComponent"] =
/******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};