Permalink
Browse files

added rails/compass gem code

  • Loading branch information...
1 parent b3e6787 commit 774be8e364bd6047495f1a8cef3d82f0faf3b53f @mhayes mhayes committed Jun 26, 2012
Showing with 4,090 additions and 0 deletions.
  1. +4 −0 Gemfile
  2. +30 −0 Gemfile.lock
  3. +22 −0 LICENSE
  4. +29 −0 README.md
  5. +2 −0 Rakefile
  6. +23 −0 foundation.gemspec
  7. +12 −0 lib/foundation.rb
  8. +5 −0 lib/foundation/engine.rb
  9. +8 −0 lib/foundation/sass_script_functions.rb
  10. +3 −0 lib/foundation/version.rb
  11. BIN pkg/foundation-3.0.0.alpha1.gem
  12. BIN pkg/foundation-3.0.0.alpha2.gem
  13. BIN pkg/foundation-3.0.0.alpha3.gem
  14. BIN pkg/foundation-3.0.0.alpha4.gem
  15. BIN pkg/foundation-3.0.0.alpha5.gem
  16. BIN pkg/foundation-3.0.0.alpha6.gem
  17. BIN pkg/foundation-3.0.0.alpha7.gem
  18. BIN pkg/foundation-3.0.0.alpha8.gem
  19. +13 −0 stylesheets/_foundation.sass
  20. +134 −0 stylesheets/foundation/_buttons.sass
  21. +299 −0 stylesheets/foundation/_forms.sass
  22. +156 −0 stylesheets/foundation/_globals.sass
  23. +208 −0 stylesheets/foundation/_grid.sass
  24. +382 −0 stylesheets/foundation/_mobile.sass
  25. +208 −0 stylesheets/foundation/_orbit.sass
  26. +94 −0 stylesheets/foundation/_reveal.sass
  27. +3 −0 stylesheets/foundation/_shared.sass
  28. +137 −0 stylesheets/foundation/_typography.sass
  29. +544 −0 stylesheets/foundation/_ui.sass
  30. +13 −0 stylesheets/foundation/shared/_colors.sass
  31. +36 −0 stylesheets/foundation/shared/_mixins.sass
  32. +45 −0 stylesheets/foundation/shared/_settings.sass
  33. +44 −0 templates/project/.gitignore
  34. +20 −0 templates/project/MIT-LICENSE.txt
  35. +8 −0 templates/project/humans.txt
  36. BIN templates/project/images/misc/button-gloss.png
  37. BIN templates/project/images/misc/button-overlay.png
  38. BIN templates/project/images/misc/custom-form-sprites.png
  39. BIN templates/project/images/misc/input-bg-outset.png
  40. BIN templates/project/images/misc/input-bg.png
  41. BIN templates/project/images/misc/modal-gloss.png
  42. BIN templates/project/images/misc/table-sorter.png
  43. BIN templates/project/images/orbit/bullets.jpg
  44. BIN templates/project/images/orbit/left-arrow.png
  45. BIN templates/project/images/orbit/loading.gif
  46. BIN templates/project/images/orbit/mask-black.png
  47. BIN templates/project/images/orbit/pause-black.png
  48. BIN templates/project/images/orbit/right-arrow.png
  49. BIN templates/project/images/orbit/rotator-black.png
  50. BIN templates/project/images/orbit/timer-black.png
  51. +151 −0 templates/project/index.html
  52. +93 −0 templates/project/javascripts/app.js
  53. +256 −0 templates/project/javascripts/jquery.customforms.js
  54. +4 −0 templates/project/javascripts/jquery.min.js
  55. +629 −0 templates/project/javascripts/jquery.orbit-1.4.0.js
  56. +2 −0 templates/project/javascripts/jquery.placeholder.min.js
  57. +152 −0 templates/project/javascripts/jquery.reveal.js
  58. +150 −0 templates/project/javascripts/jquery.tooltips.js
  59. +4 −0 templates/project/javascripts/modernizr.foundation.js
  60. +52 −0 templates/project/manifest.rb
  61. +4 −0 templates/project/robots.txt
  62. +48 −0 templates/project/sass/_settings.sass
  63. +35 −0 templates/project/sass/app.sass
  64. +28 −0 templates/project/sass/ie.sass
  65. BIN vendor/assets/images/foundation/misc/button-gloss.png
  66. BIN vendor/assets/images/foundation/misc/button-overlay.png
  67. BIN vendor/assets/images/foundation/misc/custom-form-sprites.png
  68. BIN vendor/assets/images/foundation/misc/input-bg-outset.png
  69. BIN vendor/assets/images/foundation/misc/input-bg.png
  70. BIN vendor/assets/images/foundation/misc/modal-gloss.png
  71. BIN vendor/assets/images/foundation/misc/table-sorter.png
  72. BIN vendor/assets/images/foundation/orbit/bullets.jpg
  73. BIN vendor/assets/images/foundation/orbit/left-arrow.png
  74. BIN vendor/assets/images/foundation/orbit/loading.gif
  75. BIN vendor/assets/images/foundation/orbit/mask-black.png
  76. BIN vendor/assets/images/foundation/orbit/pause-black.png
  77. BIN vendor/assets/images/foundation/orbit/right-arrow.png
  78. BIN vendor/assets/images/foundation/orbit/rotator-black.png
  79. BIN vendor/assets/images/foundation/orbit/timer-black.png
View
@@ -0,0 +1,4 @@
+source 'https://rubygems.org'
+
+# Specify your gem's dependencies in foundation.gemspec
+gemspec
View
@@ -0,0 +1,30 @@
+PATH
+ remote: .
+ specs:
+ foundation (3.0.0.alpha8)
+ compass (~> 0.12.1)
+ linguistics (~> 1.0.9)
+ modular-scale (~> 0.0.5)
+ sass (~> 3.1.19)
+
+GEM
+ remote: https://rubygems.org/
+ specs:
+ chunky_png (1.2.5)
+ compass (0.12.2)
+ chunky_png (~> 1.2)
+ fssm (>= 0.2.7)
+ sass (~> 3.1)
+ fssm (0.2.9)
+ linguistics (1.0.9)
+ modular-scale (0.0.5)
+ compass (>= 0.11.5)
+ rake (0.9.2.2)
+ sass (3.1.19)
+
+PLATFORMS
+ ruby
+
+DEPENDENCIES
+ foundation!
+ rake
View
22 LICENSE
@@ -0,0 +1,22 @@
+Copyright (c) 2012 Mark Hayes
+
+MIT License
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
View
@@ -0,0 +1,29 @@
+# Foundation
+
+TODO: Write a gem description
+
+## Installation
+
+Add this line to your application's Gemfile:
+
+ gem 'foundation'
+
+And then execute:
+
+ $ bundle
+
+Or install it yourself as:
+
+ $ gem install foundation
+
+## Usage
+
+TODO: Write usage instructions here
+
+## Contributing
+
+1. Fork it
+2. Create your feature branch (`git checkout -b my-new-feature`)
+3. Commit your changes (`git commit -am 'Added some feature'`)
+4. Push to the branch (`git push origin my-new-feature`)
+5. Create new Pull Request
View
@@ -0,0 +1,2 @@
+#!/usr/bin/env rake
+require "bundler/gem_tasks"
View
@@ -0,0 +1,23 @@
+# -*- encoding: utf-8 -*-
+require File.expand_path('../lib/foundation/version', __FILE__)
+
+Gem::Specification.new do |gem|
+ gem.authors = ["Mark Hayes"]
+ gem.email = ["mark@zurb.com"]
+ gem.description = %q{ZURB Foundation on SASS/Compass}
+ gem.summary = %q{ZURB Foundation on SASS/Compass}
+ gem.homepage = "http://foundation.zurb.com"
+
+ gem.files = `git ls-files`.split($\)
+ gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
+ gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
+ gem.name = "foundation"
+ gem.require_paths = ["lib"]
+ gem.version = Foundation::VERSION
+
+ gem.add_runtime_dependency "compass", "~> 0.12.1"
+ gem.add_runtime_dependency "sass", "~> 3.1.19"
+ gem.add_runtime_dependency "linguistics", "~> 1.0.9"
+ gem.add_runtime_dependency "modular-scale", "~> 0.0.5"
+ gem.add_development_dependency "rake"
+end
View
@@ -0,0 +1,12 @@
+require "foundation/version"
+require "modular-scale"
+require "linguistics"
+Linguistics::use( :en )
+require "compass"
+extension_path = File.expand_path(File.dirname(File.dirname(__FILE__)))
+Compass::Frameworks.register("foundation", :path => extension_path)
+require "foundation/sass_script_functions"
+
+module Foundation
+ require "foundation/engine" if defined?(Rails)
+end
View
@@ -0,0 +1,5 @@
+module Foundation
+ class Engine < Rails::Engine
+ # auto wire assets
+ end
+end
@@ -0,0 +1,8 @@
+module Foundation
+ module Sass::Script::Functions
+ def convert_number_to_word(number)
+ Sass::Script::String.new(number.value.en.numwords)
+ end
+ declare :convert_number_to_word, :args => [:number]
+ end
+end
@@ -0,0 +1,3 @@
+module Foundation
+ VERSION = "3.0.0.alpha8"
+end
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,13 @@
+// Shared
+@import foundation/shared
+
+// Foundation parts
+@import foundation/globals
+@import foundation/grid
+@import foundation/typography
+@import foundation/buttons
+@import foundation/ui
+@import foundation/forms
+@import foundation/orbit
+@import foundation/reveal
+@import foundation/mobile
@@ -0,0 +1,134 @@
+// Buttons
+//-------------------------------------------------
+
+.button
+ background: $default-color
+ display: inline-block
+ text-align: center
+ padding: 9px 34px 11px
+ color: $white
+ text-decoration: none
+ font-weight: bold
+ +font-size(13)
+ line-height: 1
+ font-family: $helvetica-font-stack
+ position: relative
+ cursor: pointer
+ border: none
+ outline: none
+ margin: 0
+
+// Don't use native buttons on iOS
+input[type=submit].button, button.button
+ -webkit-appearance: none
+
+// Hide inner focus effect in Firefox
+button::-moz-focus-inner, input[type="reset"]::-moz-focus-inner, input[type="button"]::-moz-focus-inner, input[type="file"] > input[type="button"]::-moz-focus-inner
+ border: none
+
+// Nice button
+.button
+ &.nice
+ background-color: $default-color
+ +background-image(linear-gradient(rgba(255,255,255,0.2) 0%, rgba(255,255,255,0.2) 50%, rgba(0,0,0,0) 51%, rgba(0,0,0,0) 100%))
+ +box-shadow(inset rgba(255,255,255,0.5) 0 1px 0)
+ text-shadow: rgba(0,0,0,0.28) 0 -1px 1px
+ border: 1px solid darken($default-color, 7%)
+ +transition-property(background-color)
+ +transition-duration($button-transition-duration)
+ +transition-timing-function(ease-in-out)
+ &.radius
+ +border-radius(3px)
+ &.round
+ +border-radius(1000px)
+ &.full-width
+ width: 100%
+ padding-left: 0 !important
+ padding-right: 0 !important
+ text-align: center
+ &.left-align
+ text-align: left
+ text-indent: 12px
+
+ // Sizes
+ &.tiny
+ +font-size(10)
+ padding: 6px 14px 8px
+ width: auto
+ &.small
+ +font-size(11)
+ padding: 8px 20px 10px
+ width: auto
+ &.medium
+ +font-size(13)
+ width: auto
+ &.large
+ +font-size(18)
+ padding: 11px 48px 13px
+ width: auto
+
+ // Colors
+ &.blue
+ background-color: $blue
+ &.red
+ background-color: $red
+ &.white
+ background-color: darken($white, 6%)
+ color: #333
+ &.black
+ background-color: lighten($black, 10%)
+ &.green
+ background-color: $green
+
+ // Nice Colors
+ &.nice
+ &.blue
+ border: 1px solid darken($blue, 7%)
+ &.red
+ border: 1px solid darken($red, 7%)
+ &.white
+ border: 1px solid darken($white, 17%)
+ text-shadow: none !important
+ &.black
+ border: 1px solid lighten($black, 10%)
+ &.green
+ border: 1px solid darken($green, 7%)
+
+ // Hovers
+ &:hover, &:focus
+ background-color: darken($default-color, 6%)
+ color: $white
+ &.blue:hover, &.blue:focus
+ background-color: darken($blue, 6%)
+ &.red:hover, &.red:focus
+ background-color: darken($red, 6%)
+ &.white:hover, &.white:focus
+ background-color: darken($white, 13%)
+ color: #333
+ &.black:hover, &.black:focus
+ background-color: $black
+ &.green:hover, &.green:focus
+ background-color: darken($green, 6%)
+
+ // Active State for .nice.buttons
+ &.nice:active
+ +box-shadow(0 1px 0 rgba(0,0,0,0.15))
+
+ // Button disabled states
+ &.disabled, &[disabled]
+ opacity: 0.6
+ cursor: default
+
+// Correct FF button padding
+@-moz-document url-prefix("http://")
+ input[type=submit].button::-moz-focus-inner, button.button::-moz-focus-inner
+ border: 0
+ padding: 0
+ input[type=submit].tiny.button
+ padding: 5px 14px 7px
+ input[type=submit].small.button
+ padding: 7px 20px 8px
+ input[type=submit].medium.button
+ padding: 8px 34px 9px
+ input[type=submit].large.button
+ padding: 9px 48px 10px
Oops, something went wrong.

0 comments on commit 774be8e

Please sign in to comment.