css3buttons 0.9.5 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
data/Gemfile.lock CHANGED
@@ -13,7 +13,7 @@ GIT
13
13
  PATH
14
14
  remote: .
15
15
  specs:
16
- css3buttons (0.9.5)
16
+ css3buttons (1.0.0)
17
17
  actionpack (>= 3.0.0)
18
18
 
19
19
  GEM
@@ -0,0 +1,5 @@
1
+ /*
2
+ *= require ./reset
3
+ *= require ./styles.css
4
+ *= provide ./../../images
5
+ */
@@ -81,7 +81,7 @@ http://github.com/necolas/css3-github-buttons
81
81
  width: 12px;
82
82
  height: 12px;
83
83
  margin: 0 0.75em 0 -0.25em;
84
- background: url(/images/css3buttons/css3-github-buttons-icons.png) 0 99px no-repeat;
84
+ background: url(css3buttons/icons.png) 0 99px no-repeat;
85
85
  }
86
86
 
87
87
  .button.arrowup.icon:before { background-position: 0 0; }
@@ -278,6 +278,40 @@ http://github.com/necolas/css3-github-buttons
278
278
  background-image: linear-gradient(#b33630, #dc5f59);
279
279
  }
280
280
 
281
+ /* ............................................................................................................. safe */
282
+
283
+ .button.safe {
284
+ color: #fff;
285
+ border-color: #6b9640;
286
+ border-bottom-color: #747d4a;
287
+ text-decoration: none;
288
+ text-shadow: -1px -1px 0 rgba(0,0,0,0.3);
289
+ background-color: #7bac4c;
290
+ background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#aed36c), to(#7bac4c));
291
+ background-image: -moz-linear-gradient(#aed36c, #7bac4c);
292
+ background-image: -o-linear-gradient(#aed36c, #7bac4c);
293
+ background-image: linear-gradient(#aed36c, #7bac4c);
294
+ }
295
+
296
+ .button.safe:hover,
297
+ .button.safe:focus,
298
+ .button.safe:active {
299
+ background-color: #a2c581;
300
+ background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#bddb89), to(#96bd71));
301
+ background-image: -moz-linear-gradient(#bddb89, #96bd71);
302
+ background-image: -o-linear-gradient(#bddb89, #96bd71);
303
+ background-image: linear-gradient(#bddb89, #96bd71);
304
+ }
305
+
306
+ .button.safe:active,
307
+ .button.safe.active {
308
+ background-color: #a2c581;
309
+ background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#96bd71), to(#bddb89));
310
+ background-image: -moz-linear-gradient(#96bd71, #bddb89);
311
+ background-image: -o-linear-gradient(#96bd71, #bddb89);
312
+ background-image: linear-gradient(#96bd71, #bddb89);
313
+ }
314
+
281
315
  /* ............................................................................................................. Pill */
282
316
 
283
317
  .button.pill {
@@ -0,0 +1,4 @@
1
+ /*
2
+ *= require ./styles.css
3
+ *= provide ./../../images
4
+ */
data/lib/css3buttons.rb CHANGED
@@ -1,7 +1,7 @@
1
1
  require 'action_controller'
2
2
  require 'action_view'
3
3
 
4
- module Css3buttons
4
+ module Css3buttons
5
5
  module Helpers
6
6
  autoload :ButtonHelper, 'css3buttons/helpers/button_helper'
7
7
  end
@@ -0,0 +1,5 @@
1
+ module Css3buttons
2
+ class Engine < ::Rails::Engine
3
+
4
+ end
5
+ end
@@ -1,3 +1,3 @@
1
1
  module Css3buttons
2
- VERSION = "0.9.5"
2
+ VERSION = "1.0.0"
3
3
  end
data/readme.md CHANGED
@@ -1,35 +1,39 @@
1
- # css3buttons gem - helper methods for css3buttons
1
+ # css3buttons
2
2
 
3
- The css3buttons gem is a small set of helper methods designed to work in
3
+ The __css3buttons__ gem is a small set of helper methods designed to work in
4
4
  conjunction with the __amazing__ [css3 github buttons by Nicolas Gallagher](http://nicolasgallagher.com/lab/css3-github-buttons/).
5
5
 
6
6
  The helpers allow rails developers to quickly and easily leverage this
7
7
  fantastic CSS library - without cluttering up your views and calls to
8
8
  `link_to`, `button_to` and `submit_tag`.
9
9
 
10
- # What's new in version this version?
10
+ # Version 1.0 is finally here!
11
11
 
12
- ## 0.9.5
12
+ And with it brings support for the Rails 3.1 asset pipeline. __Please note:__ as of version 1.0.0, Rails 3.0.x is no longer supported. If you're wanting to use the css3buttons on a Rails 3.0.x project, please install version 0.9.5 (see below for full instructions).
13
13
 
14
- Not a whole lot, mainly just fixes for bad paths in the CSS that crept
15
- through in the last update. As well as prepping for version 1.0.0 with
16
- will be compaitible with the Rails 3.1 asset pipeline.
14
+ # Getting started - Rails 3.1
17
15
 
18
- ## 0.9.4
16
+ Include the gem in your gemfile and run `bundle install`
19
17
 
20
- In this version we've updated the css to now work with the [css3 github buttons](http://nicolasgallagher.com/lab/css3-github-buttons/) as standard, instead of the original css3buttons, in order to take advantage of a few of the features not included in the original library.
18
+ gem 'css3buttons'
21
19
 
22
- Additionally, there was some serious re-tooling of the helper methods to make them more usable, more dynamic and less prone to error.
20
+ Require the stylesheets in `app/assets/stylesheets/application.css`:
23
21
 
24
- __Please note__: as part of changes, calls to `link_button_to` will need
25
- to be updated to `button_link_to`. Everything else should work expected.
22
+ *= require css3buttons
23
+ *= require_self
24
+ ...
25
+
26
+ By default, css3buttons comes with a reset stylesheet built in. Because of this, you should load it before any other stylesheets. However, if you don't want to use reset, or already have your own, just require this instead:
26
27
 
28
+ *= require css3buttons/without-reset
29
+ *= require_self
30
+ ...
27
31
 
28
- # Getting started
32
+ # Getting started - Rails 3.0.x
29
33
 
30
- Include the gem in your gemfile:
34
+ Include the gem in your gemfile and run 'bundle install`
31
35
 
32
- gem 'css3buttons'
36
+ gem 'css3buttons', '0.9.5'
33
37
 
34
38
  Run the generators:
35
39
 
@@ -45,10 +49,7 @@ In your layout, add the following:
45
49
  Which will add both the `reset.css` and the `css3buttons.css` stylesheet
46
50
  link tags.
47
51
 
48
- _Please note_ since this helper includes the css3buttons
49
- reset stylesheet, it's advisable to place this helper before all your
50
- other stylsheet declarations. However, if you'd like to use your own
51
- reset, you can skip it with:
52
+ By default, css3buttons comes with a reset stylesheet built in. Because of this, you should load it before any other stylesheets. However, if you'd like to use your own reset, you can skip it with:
52
53
 
53
54
  <%= css3buttons_stylesheets :include_reset => false %>
54
55
 
metadata CHANGED
@@ -1,8 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: css3buttons
3
3
  version: !ruby/object:Gem::Version
4
+ hash: 23
4
5
  prerelease:
5
- version: 0.9.5
6
+ segments:
7
+ - 1
8
+ - 0
9
+ - 0
10
+ version: 1.0.0
6
11
  platform: ruby
7
12
  authors:
8
13
  - Nicholas Bruning
@@ -10,7 +15,7 @@ autorequire:
10
15
  bindir: bin
11
16
  cert_chain: []
12
17
 
13
- date: 2011-06-04 00:00:00 Z
18
+ date: 2011-08-05 00:00:00 Z
14
19
  dependencies:
15
20
  - !ruby/object:Gem::Dependency
16
21
  name: actionpack
@@ -20,6 +25,11 @@ dependencies:
20
25
  requirements:
21
26
  - - ">="
22
27
  - !ruby/object:Gem::Version
28
+ hash: 7
29
+ segments:
30
+ - 3
31
+ - 0
32
+ - 0
23
33
  version: 3.0.0
24
34
  type: :runtime
25
35
  version_requirements: *id001
@@ -41,18 +51,16 @@ files:
41
51
  - LICENSE
42
52
  - Rakefile
43
53
  - css3buttons.gemspec
54
+ - lib/assets/images/css3buttons/icons.png
55
+ - lib/assets/stylesheets/css3buttons/index.css
56
+ - lib/assets/stylesheets/css3buttons/reset.css
57
+ - lib/assets/stylesheets/css3buttons/styles.css
58
+ - lib/assets/stylesheets/css3buttons/without-reset.css
44
59
  - lib/css3buttons.rb
45
- - lib/css3buttons/.DS_Store
46
60
  - lib/css3buttons/button_group.rb
61
+ - lib/css3buttons/engine.rb
47
62
  - lib/css3buttons/helpers/button_helper.rb
48
63
  - lib/css3buttons/version.rb
49
- - lib/generators/css3buttons/USAGE
50
- - lib/generators/css3buttons/css3buttons_generator.rb
51
- - lib/generators/css3buttons/templates/public/images/.DS_Store
52
- - lib/generators/css3buttons/templates/public/images/gh-icons.png
53
- - lib/generators/css3buttons/templates/public/stylesheets/.DS_Store
54
- - lib/generators/css3buttons/templates/public/stylesheets/css3-github-buttons.css
55
- - lib/generators/css3buttons/templates/public/stylesheets/reset.css
56
64
  - readme.md
57
65
  - spec/button_group_spec.rb
58
66
  - spec/button_helper_spec.rb
@@ -70,17 +78,23 @@ required_ruby_version: !ruby/object:Gem::Requirement
70
78
  requirements:
71
79
  - - ">="
72
80
  - !ruby/object:Gem::Version
81
+ hash: 3
82
+ segments:
83
+ - 0
73
84
  version: "0"
74
85
  required_rubygems_version: !ruby/object:Gem::Requirement
75
86
  none: false
76
87
  requirements:
77
88
  - - ">="
78
89
  - !ruby/object:Gem::Version
90
+ hash: 3
91
+ segments:
92
+ - 0
79
93
  version: "0"
80
94
  requirements: []
81
95
 
82
96
  rubyforge_project: css3buttons
83
- rubygems_version: 1.8.3
97
+ rubygems_version: 1.8.5
84
98
  signing_key:
85
99
  specification_version: 3
86
100
  summary: Easy, beautiful buttons, the CSS3 way.
@@ -1,3 +0,0 @@
1
- To add the latest css3buttons stylsheets and icon images to your rails app, just do the following:
2
-
3
- rails generate css3buttons:assets
@@ -1,10 +0,0 @@
1
- class Css3buttonsGenerator < Rails::Generators::Base
2
- desc "Copies css3buttons stylesheets and images"
3
- source_root File.expand_path('../templates', __FILE__)
4
-
5
- def copy_stylesheets_and_images
6
- copy_file "public/images/gh-icons.png", "public/images/css3buttons/css3-github-buttons-icons.png"
7
- copy_file "public/stylesheets/css3-github-buttons.css", "public/stylesheets/css3buttons/css3-github-buttons.css"
8
- copy_file "public/stylesheets/reset.css", "public/stylesheets/css3buttons/reset.css"
9
- end
10
- end