Skip to content

Instantly share code, notes, and snippets.

@Marak
Created December 13, 2009 09:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Marak/255353 to your computer and use it in GitHub Desktop.
Save Marak/255353 to your computer and use it in GitHub Desktop.
drip.toolbar.HTML = '<div id = "{{id}}" class = "{{class}}"></div>';
drip.toolbar.rendered = Mustache.to_html(drip.toolbar.HTML,{
id:"drip-toolbar",
class:"drip-toolbar",
});
drip.toolbar.css = {
height:"100px",
width:"100px",
position:"absolute",
right: 0,
top: 0,
"background-color": "#CCC"
};
function parseCSS(id,css){
for(style in css){
$(id).css(style,css[style]);
}
};
drip.init = function(){
// create null drip toolbar
$('body').append(drip.toolbar.rendered);
parseCSS('#drip-toolbar', drip.toolbar.css);
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment