Skip to content

Instantly share code, notes, and snippets.

View crazyrohila's full-sized avatar
🏠
Working from home

Sanjay Rohila crazyrohila

🏠
Working from home
View GitHub Profile
@crazyrohila
crazyrohila / _mixins.scss
Created August 3, 2013 11:08
Some Mixins
/**
* Some mixins I use when not including compass/bourbon in project.
*/
@mixin vendor($property, $value) {
-webkit-#{$property}:$value;
-moz-#{$property}:$value;
-ms-#{$property}:$value;
-o-#{$property}:$value;
#{$property}:$value;
@crazyrohila
crazyrohila / resizetocover.js
Last active December 18, 2015 13:29
html image scaled and cropped to behave like background cover in a div.
(function($) {
$.fn.resizeToCover = function () {
this.each(function() {
if($(this).is('img')) {
var viewport = $(this).parent();
var img = $(this);
var org_img = new Image();
org_img.src = img.attr("src");
var image_original_width = org_img.width;
var image_original_height = org_img.height;
/**
* F A L T U
*/
@keyframes move {
50% {
text-shadow:
0 0 20px #fefcc9,
10px -10px 30px #feec85,
-20px -20px 40px #ffae34,
@crazyrohila
crazyrohila / dabblet.css
Created March 25, 2013 07:24
Google Drive icon.
/**
* Google Drive icon.
*/
#main {
position:relative;
width:250px;
height: 250px;
transform:rotate(-60deg);
}
@crazyrohila
crazyrohila / dabblet.css
Created March 8, 2013 15:09
image and css comparison.
/**
* image and css comparison.
*/
div {background: #01476b; padding: 7px 10px; width: 882px;}
span {
font-family: verdana;
font-style: italic;
font-weight: 700;
text-shadow: 3px 4px 3px #222;
font-size: 18px;
@crazyrohila
crazyrohila / dabblet.css
Created March 2, 2013 21:47
CSS3 start-stop button.
/**
* CSS3 start-stop button.
*/
input.cbox {display:none;}
.label {
cursor:pointer;
position: absolute;
top: 50%;
left: 50%;
@crazyrohila
crazyrohila / dabblet.css
Created March 2, 2013 19:24
car steering
/**
* car steering
*/
#circle {
width: 300px;
height: 300px;
border: 25px solid #2F4F4F;
border-radius: 50%;
position: relative;
@crazyrohila
crazyrohila / dabblet.css
Created March 1, 2013 20:50
coming through.
/**
* coming through.
*/
@keyframes gola {
0%{ transform: rotate(0deg) scale(.01) skew(0,0); top:0;}
15%{ transform: rotate(0deg) scale(.01) skew(0,0); top:0;}
100%{ transform: rotate(720deg) scale(7) skew(10deg,10deg); top:90%;}
}
@crazyrohila
crazyrohila / dabblet.css
Created March 1, 2013 12:47
moving man.
/**
* moving man.
*/
#man {
position: relative;
width:350px;
transform: scale(.4);
left: -15%;
}
@crazyrohila
crazyrohila / dabblet.css
Created March 1, 2013 11:37
The first commented line is your dabblet’s title
/**
* The first commented line is your dabblet’s title
*/
@keyframes pump {
0% {
top: 0;
left: 0;
font-size: 100px;
transform: rotate(0deg);
}