Skip to content

Instantly share code, notes, and snippets.

Rasmus Thulstrup thulstrup

Block or report user

Report or block thulstrup

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
cubiq / select-reset.html
Created May 27, 2014
How to reset a select tag
View select-reset.html
<!DOCTYPE html>
<meta charset="utf-8">
<title>Styled Select</title>
* {
View percentage_grid.sass
// How I would approach a fluid grid:
// [1] Let the name reflect the % width,
// eliminating "1 of 12" guesswork.
// [2] Also, put 10px of padding to either
// side, to stack and make a 20px gutter.
// [3] Make the box-sizing = border-box, so that
bastianallgeier / dabblet.css
Created Jan 5, 2012
PE to use SVG as CSS background image with fallback for IE8/7/6
View dabblet.css
* PE to use SVG as CSS background image with fallback for IE8/7/6
* Using SVG as CSS background image to display
* resolution-independent logos or icons is pretty
* awesome but does completely fail on IE8/7/6
* The trick:
* All three IE versions don't support rgba color values.
* By defining a rgba background color together with the
chriseppstein / 0_usage.scss
Created Feb 29, 2012
This is code that runs using Sass 3.2 prerelease and something like this will be in compass soon.
View 0_usage.scss
@include keyframes(appear-and-roundify) {
0% { opacity: 0; @include border-radius(2px); }
100% { opacity: 1; @include border-radius(10px); }
scottkellum / _grid.sass
Created Mar 10, 2012
Singularity grid file
View _grid.sass
// Grid types to work on -- column, scale
$grid-type: column !default
$scale-grid-direction: rtl !default
$scale-grid-style: incremental !default
$base-size: 16px !default
$line-height: 1.3em !default
codingdesigner / breakpoint.sass
Created May 21, 2012
View breakpoint.sass
// breakpoint($breakpoint, $media: 'screen')
$breakpoint-default-feature: min-width !default
// create $breakpoint variables like so
// assume $breakpoint-default-feature if only a number
$breakpoint1: 500px
View demo.html
<!DOCTYPE html>
<!--[if lt IE 7 ]> <html lang="en" class="ie ie6"> <![endif]-->
<!--[if IE 7 ]> <html lang="en" class="ie ie7"> <![endif]-->
<!--[if IE 8 ]> <html lang="en" class="ie ie8"> <![endif]-->
<!--[if IE 9 ]> <html lang="en" class="ie ie9"> <![endif]-->
<!--[if (gt IE 9)|!(IE)]><!--> <html lang="en"> <!--<![endif]-->
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
KuraFire / rgbaa.scss
Created Sep 13, 2012
More dynamic, oldIE-compatible SCSS function for rgba
View rgbaa.scss
@function rgbaa($args...) {
// rgbaa(#FFF, .5)
@if length($args) == 2 {
$hex: nth($args, 1);
$alpha: nth($args, 2);
@if $oldIE == 1 {
@return rgb(red($hex), green($hex), blue($hex));
} @else {
@return rgba(red($hex), green($hex), blue($hex), $alpha);
micahgodbolt / SassMeister-input.scss
Created Jun 24, 2013
Another stab at Filament Group's Element Query challenge.
View SassMeister-input.scss
// ---
// Sass (v3.2.9)
// ---
@mixin respond-to($queries...) {
$length: length($queries);
@for $i from 1 through $length{
@if $i % 2 == 1 {
@media screen and (min-width: nth($queries, $i)) {
Snugug / server.bash
Created Oct 26, 2013
OS X 10.9 (Mavericks) comes with PHP 5.4.17 out of the box, allowing you to start a PHP development server in any directory by running `php -S localhost:8888` with `8888` being the port number you'd like to use. This is a little bash/zsh function to reduce that to `server 8888`. Simply add this to `bash_profile` or `zshconfig`. For more on the P…
View server.bash
server() {
php -S localhost:"$*";
You can’t perform that action at this time.