has_breadcrumbs 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/{has_breadcrumb.gemspec → has_breadcrumbs.gemspec} +6 -4
- data/init.rb +1 -3
- data/lib/breadcrumb.rb +2 -3
- data/lib/has_breadcrumbs.rb +6 -2
- metadata +3 -3
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.1.
|
1
|
+
0.1.2
|
@@ -4,12 +4,12 @@
|
|
4
4
|
# -*- encoding: utf-8 -*-
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
|
-
s.name = %q{
|
8
|
-
s.version = "0.1.
|
7
|
+
s.name = %q{has_breadcrumbs}
|
8
|
+
s.version = "0.1.2"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Gabriel Sobrinho", "Daniel Lopes", "Nando Vieira"]
|
12
|
-
s.date = %q{2010-01-
|
12
|
+
s.date = %q{2010-01-20}
|
13
13
|
s.email = %q{gabriel.sobrinho@gmail.com}
|
14
14
|
s.extra_rdoc_files = [
|
15
15
|
"README.textile"
|
@@ -17,17 +17,19 @@ Gem::Specification.new do |s|
|
|
17
17
|
s.files = [
|
18
18
|
"MIT-LICENSE",
|
19
19
|
"README.textile",
|
20
|
+
"Rakefile",
|
20
21
|
"VERSION",
|
21
22
|
"examples/images/crumbs.gif",
|
22
23
|
"examples/index.html",
|
23
24
|
"examples/styles.css",
|
25
|
+
"has_breadcrumbs.gemspec",
|
24
26
|
"init.rb",
|
25
27
|
"lib/breadcrumb.rb",
|
26
28
|
"lib/has_breadcrumbs.rb",
|
27
29
|
"spec/has_breadcrumbs_spec.rb",
|
28
30
|
"spec/spec_helper.rb"
|
29
31
|
]
|
30
|
-
s.homepage = %q{http://github.com/sobrinho/
|
32
|
+
s.homepage = %q{http://github.com/sobrinho/has_breadcrumbs}
|
31
33
|
s.rdoc_options = ["--charset=UTF-8"]
|
32
34
|
s.require_paths = ["lib"]
|
33
35
|
s.rubygems_version = %q{1.3.5}
|
data/init.rb
CHANGED
data/lib/breadcrumb.rb
CHANGED
@@ -7,12 +7,12 @@ class Breadcrumb
|
|
7
7
|
@items = []
|
8
8
|
end
|
9
9
|
|
10
|
-
alias :<<, :add
|
11
|
-
|
12
10
|
def add(name, url=nil, options={})
|
13
11
|
@items << [name, url, options]
|
14
12
|
end
|
15
13
|
|
14
|
+
alias :<< :add
|
15
|
+
|
16
16
|
def display
|
17
17
|
size = @items.size
|
18
18
|
|
@@ -33,5 +33,4 @@ class Breadcrumb
|
|
33
33
|
|
34
34
|
content_tag(:ul, "\n#{crumbs}\n", :id=>"breadcrumbs")
|
35
35
|
end
|
36
|
-
|
37
36
|
end
|
data/lib/has_breadcrumbs.rb
CHANGED
@@ -1,6 +1,7 @@
|
|
1
|
+
require "breadcrumb"
|
2
|
+
|
1
3
|
module Breadcrumbs
|
2
4
|
module ActionController
|
3
|
-
|
4
5
|
def self.included(base)
|
5
6
|
base.send :helper_method, :breadcrumb
|
6
7
|
end
|
@@ -8,6 +9,9 @@ module Breadcrumbs
|
|
8
9
|
def breadcrumb
|
9
10
|
@breadcrumb ||= Breadcrumb.new
|
10
11
|
end
|
11
|
-
|
12
12
|
end
|
13
13
|
end
|
14
|
+
|
15
|
+
ActionController::Base.class_eval do
|
16
|
+
include Breadcrumbs::ActionController
|
17
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: has_breadcrumbs
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gabriel Sobrinho
|
@@ -11,7 +11,7 @@ autorequire:
|
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
13
|
|
14
|
-
date: 2010-01-
|
14
|
+
date: 2010-01-20 00:00:00 -02:00
|
15
15
|
default_executable:
|
16
16
|
dependencies: []
|
17
17
|
|
@@ -31,7 +31,7 @@ files:
|
|
31
31
|
- examples/images/crumbs.gif
|
32
32
|
- examples/index.html
|
33
33
|
- examples/styles.css
|
34
|
-
-
|
34
|
+
- has_breadcrumbs.gemspec
|
35
35
|
- init.rb
|
36
36
|
- lib/breadcrumb.rb
|
37
37
|
- lib/has_breadcrumbs.rb
|