Permalink
Browse files

initial commit

  • Loading branch information...
1 parent fcb05dc commit c0cd937fff999fd70e378ef030806f1422b35972 @grosser committed Feb 11, 2009
View
@@ -0,0 +1 @@
+spec/*.min
View
@@ -0,0 +1,20 @@
+desc "Run all specs in spec directory"
+task :default do |t|
+ options = "--colour --format progress --loadby --reverse"
+ files = FileList['spec/**/*_spec.rb']
+ system("spec #{options} #{files}")
+end
+
+begin
+ require 'jeweler'
+ Jeweler::Tasks.new do |gem|
+ gem.name = "reduce"
+ gem.summary = "Reduce your assets: minify javascript + stylesheets, optimize images lossless"
+ gem.email = "grosser.michael@gmail.com"
+ gem.homepage = "http://github.com/grosser/reduce"
+ gem.authors = ["Michael Grosser"]
+ gem.add_dependency ['grosser-smusher']
+ end
+rescue LoadError
+ puts "Jeweler, or one of its dependencies, is not available. Install it with: sudo gem install technicalpickles-jeweler -s http://gems.github.com"
+end
View
@@ -0,0 +1,19 @@
+gem 'grosser-smusher', '>=0.3.3'
+require 'smusher'
+
+module Reduce
+ extend self
+ def reduce(input,output=nil)
+ extension = File.extname(input).downcase.sub('.','')
+ case extension
+ when 'js','css'
+ compressor = File.join(File.dirname(__FILE__),'..','vendor','yuicompressor*.jar')
+ `java -jar #{compressor} --type #{extension} #{input} > #{output}`
+ when 'jpg','jpeg','png'
+ FileUtils.cp(input,output)
+ Smusher.optimize_image(output,:quiet=>true)
+ else
+ raise "WTF? a .#{extension} file...."
+ end
+ end
+end
@@ -0,0 +1,99 @@
+#facebox .b {
+ background:url(/images/facebox/b.png);
+}
+
+#facebox .tl {
+ background:url(/images/facebox/tl.png);
+}
+
+#facebox .tr {
+ background:url(/images/facebox/tr.png);
+}
+
+#facebox .bl {
+ background:url(/images/facebox/bl.png);
+}
+
+#facebox .br {
+ background:url(/images/facebox/br.png);
+}
+
+#facebox {
+ position: absolute;
+ top: 0;
+ left: 0;
+ z-index: 100;
+ text-align: left;
+}
+
+#facebox .popup {
+ position: relative;
+}
+
+#facebox table {
+ border-collapse: collapse;
+}
+
+#facebox td {
+ border-bottom: 0;
+ padding: 0;
+}
+
+#facebox .body {
+ padding: 10px;
+ background: #fff;
+ width: 370px;
+}
+
+#facebox .loading {
+ text-align: center;
+}
+
+#facebox .image {
+ text-align: center;
+}
+
+#facebox img {
+ border: 0;
+ margin: 0;
+}
+
+#facebox .footer {
+ border-top: 1px solid #DDDDDD;
+ padding-top: 5px;
+ margin-top: 10px;
+ text-align: right;
+}
+
+#facebox .footer img {
+ vertical-align: middle;
+}
+
+#facebox .tl, #facebox .tr, #facebox .bl, #facebox .br {
+ height: 10px;
+ width: 10px;
+ overflow: hidden;
+ padding: 0;
+}
+
+#facebox_overlay {
+ position: fixed;
+ top: 0px;
+ left: 0px;
+ height:100%;
+ width:100%;
+}
+
+.facebox_hide {
+ z-index:-100;
+}
+
+.facebox_overlayBG {
+ background-color: #000;
+ z-index: 99;
+}
+
+* html #facebox_overlay { /* ie6 hack */
+ position: absolute;
+ height: expression(document.body.scrollHeight > document.body.offsetHeight ? document.body.scrollHeight : document.body.offsetHeight + 'px');
+}
Oops, something went wrong.

0 comments on commit c0cd937

Please sign in to comment.