Skip to content

Instantly share code, notes, and snippets.

View nonlinear's full-sized avatar

Nicholas Frota nonlinear

View GitHub Profile
@nonlinear
nonlinear / gist:3882005
Created October 12, 2012 22:32
CSS: media query for orientation
@media all and (orientation:portrait) {
/* Style adjustments for portrait mode goes here */
}
@media all and (orientation:landscape) {
/* Style adjustments for landscape mode goes here */
}
@nonlinear
nonlinear / gist:3882027
Created October 12, 2012 22:36
CSS: base CSS
html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, font, img, ins, kbd, q, s, samp, small, strike, strong, sub, sup, tt, var, b, u, i, center, dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td {
margin: 0;
padding: 0;
border: 0;
outline: 0;
font-size: 100%;
vertical-align: baseline;
background: transparent;
}
* {
@nonlinear
nonlinear / gist:3882033
Created October 12, 2012 22:37
HTML: automatic QR code
<img src="http://chart.apis.google.com/chart?chs=150x150&cht=qr&chl=
<!-- insert code here, no more than 255 characters -->
&choe=UTF-8">
@nonlinear
nonlinear / gist:3882036
Created October 12, 2012 22:38
HTML: apple favicon script
<!-- TODO: Place favicon.ico and apple-touch-icon.png in the root of your domain -->
<link rel="shortcut icon" href="/favicon.ico">
<link rel="apple-touch-icon" href="/apple-touch-icon.png">
@nonlinear
nonlinear / gist:3882051
Created October 12, 2012 22:39
HTML: chrome iframe enabled
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
@nonlinear
nonlinear / bootstrap_modal.html
Last active October 11, 2015 15:47
bootstrap_modal
<!--
TODO:
1. add trigger: <button data-toggle="modal" data-target="#myModal">Trigger</button>
2. rename myModal id and trigger
OPTIONS:
for persistent modal, add data-backdrop="static" to trigger
-->
<div id="myModal" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
@nonlinear
nonlinear / gist:3882103
Created October 12, 2012 22:53
HTML: iOS WebApp-capable
<meta name=”apple-mobile-web-app-capable” content=”yes” />
@nonlinear
nonlinear / Preferences.sublime-settings
Created October 13, 2012 23:18 — forked from robcowie/Preferences.sublime-settings
SUBLIME: SublimeTODO config
// add before end of brackets
"todo":
{
"file_exclude_patterns":[
"*.po", "*.log", "*.scssc", "*.mo"
],
"folder_exclude_patterns": [
"static", "vendor", "tmp"
],
"patterns":
@nonlinear
nonlinear / gist:3886783
Created October 14, 2012 00:53
SUBLIME: project.sublime-project
// TODO: update path for actual project.
{
"url": "http://localhost:3000/",
"folders":
[
{
"path": "/Users/nonlinear/Documents/Projects/bins/app/assets/"
},
{
"path": "/Users/nonlinear/Documents/Projects/bins/app/views/"
@nonlinear
nonlinear / gist:3890343
Created October 15, 2012 01:05
SUBLIME: sublime.keymap - User
[
{ "keys": ["ctrl+s"], "command": "toggle_side_bar" },
{ "keys": ["ctrl+i"], "command": "reindent" },
{
"keys": ["super+alt+left"],
"command": "set_layout",
"args":
{
"cols": [0.0, 0.33, 1.0],
"rows": [0.0, 1.0],