honey_badger 0.0.2 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/README.markdown CHANGED
@@ -6,19 +6,19 @@ Get a nice, clean badge displaying your Rails Environment or other helpful info.
6
6
 
7
7
  Add to your Gemfile:
8
8
 
9
- gem "honey_badger", :group => [:development, :test, :staging]
9
+ gem "honey_badger", :group => [:development, :test, :staging]
10
10
 
11
11
  In your application view somewhere, just render the honey_badger helper:
12
12
 
13
- = honey_badger
13
+ <%= honey_badger %>
14
14
 
15
15
  If you want to display something other than the current environment name, just pass it in:
16
16
 
17
- = honey_badger "Don't Care!"
17
+ <%= honey_badger "Don't Care" %>
18
18
 
19
19
  Or pass in an array to display more than one interesting fact in your badge (each will be displayed on its own line):
20
20
 
21
- = honey_badger ["eats larva", "skin is loose"]
21
+ <%= honey_badger ["eats larva", "skin is loose"] %>
22
22
 
23
23
  In your stylesheet (using Rails 3.1 sprockets awesomeness):
24
24
 
@@ -0,0 +1,11 @@
1
+ // This is a manifest file that'll be compiled into including all the files listed below.
2
+ // Add new JavaScript/Coffee code in separate files in this directory and they'll automatically
3
+ // be included in the compiled file accessible from http://example.com/assets/application.js
4
+ // It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
5
+ // the compiled file.
6
+ //
7
+ <% unless options[:skip_javascript] -%>
8
+ //= require <%= options[:javascript] %>
9
+ //= require <%= options[:javascript] %>_ujs
10
+ <% end -%>
11
+ //= require_tree .
@@ -0,0 +1,7 @@
1
+ /*
2
+ * This is a manifest file that'll automatically include all the stylesheets available in this directory
3
+ * and any sub-directories. You're free to add application-wide styles to this file and they'll appear at
4
+ * the top of the compiled file, but it's generally better to create a new file per style scope.
5
+ *= require_self
6
+ *= require_tree .
7
+ */
@@ -0,0 +1,39 @@
1
+ @mixin corner-banner($color: #333) {
2
+ &.corner-banner.honey-badger {
3
+ position: absolute;
4
+ left: -55px;
5
+ top: 30px;
6
+ display: block;
7
+ width: 200px;
8
+ background: $color;
9
+ background: -moz-linear-gradient(top, $color 0%, darken($color, 20) 100%);
10
+ background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, $color), color-stop(100%, darken($color, 20)));
11
+ text-align:center;
12
+ font-size:11px;
13
+ line-height:13px;
14
+ padding:4px 3px 4px 3px;
15
+ text-shadow: darken($color, 20) 1px 1px 0;
16
+ -webkit-transform: rotate(-45deg);
17
+ -moz-transform: rotate(-45deg);
18
+ transform: rotate(-45deg);
19
+ box-shadow: rgba(0,0,0, 0.2) 0px 0px 6px;
20
+ -moz-box-shadow: rgba(0,0,0, 0.2) 0px 0px 6px;
21
+ -webkit-box-shadow: rgba(0,0,0, 0.2) 0px 0px 6px;
22
+ z-index: 1000;
23
+ letter-spacing:1px;
24
+ font-style:normal;
25
+ font-size:8px !important;
26
+ color:#fff;
27
+ text-transform:uppercase;
28
+ line-height:12px;
29
+ display:block;
30
+ font-family: Arial;
31
+
32
+ a:link,
33
+ a:visited {color:#FFF0B7;text-decoration: none;}
34
+ a:hover,
35
+ a:focus {color:#FFF;text-decoration: none;}
36
+ }
37
+ }
38
+
39
+ .development { @include corner-banner(#933720) }
@@ -0,0 +1,7 @@
1
+ module HoneyBadger
2
+ class ApplicationController < ActionController::Base
3
+ def index
4
+ render :text => "hello from application controller"
5
+ end
6
+ end
7
+ end
@@ -0,0 +1,10 @@
1
+ module HoneyBadger
2
+ module ApplicationHelper
3
+ def honey_badger(text=Rails.env)
4
+ content_tag :div, :class => "corner-banner honey-badger #{Rails.env}" do
5
+ text = text.join('<br/>') if text.instance_of?(Array)
6
+ text.html_safe
7
+ end
8
+ end
9
+ end
10
+ end
@@ -0,0 +1,14 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>HoneyBadger</title>
5
+ <%= stylesheet_link_tag "application" %>
6
+ <%= javascript_include_tag "application" %>
7
+ <%= csrf_meta_tags %>
8
+ </head>
9
+ <body>
10
+
11
+ <%= yield %>
12
+
13
+ </body>
14
+ </html>
@@ -1,3 +1,3 @@
1
1
  module HoneyBadger
2
- VERSION = "0.0.2"
2
+ VERSION = "0.0.3"
3
3
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: honey_badger
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.0.2
5
+ version: 0.0.3
6
6
  platform: ruby
7
7
  authors:
8
8
  - Rob Sanheim
@@ -24,6 +24,12 @@ extensions: []
24
24
  extra_rdoc_files: []
25
25
 
26
26
  files:
27
+ - app/assets/javascripts/application.js
28
+ - app/assets/stylesheets/application.css
29
+ - app/assets/stylesheets/honey_badger.css.scss
30
+ - app/controllers/honey_badger/application_controller.rb
31
+ - app/helpers/honey_badger/application_helper.rb
32
+ - app/views/layouts/honey_badger/application.html.erb
27
33
  - lib/honey_badger/engine.rb
28
34
  - lib/honey_badger/version.rb
29
35
  - lib/honey_badger.rb
@@ -45,7 +51,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
45
51
  requirements:
46
52
  - - ">="
47
53
  - !ruby/object:Gem::Version
48
- hash: -386139221835634446
54
+ hash: 745516221216455174
49
55
  segments:
50
56
  - 0
51
57
  version: "0"