simplificator-activist 0.0.2 → 0.0.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -9,7 +9,8 @@ module Activist
9
9
  end
10
10
  end
11
11
  end
12
-
12
+
13
+ # :block_class : a class applied to the outermost div
13
14
  def section_block(title, options = {})
14
15
  builder = Builder.new(self)
15
16
  yield builder
@@ -21,5 +22,15 @@ module Activist
21
22
  :class => :content),
22
23
  :class => [:block, options[:block_class]])
23
24
  end
25
+
26
+ def sidebar_block(title, &block)
27
+ content = capture(&block)
28
+ content_for(:sidebar) do
29
+ content_tag(:div, :class => ['sidebar-block']) do
30
+ content_tag(:h4, title) + content_tag(:p, content)
31
+ end
32
+ end
33
+ end
34
+
24
35
  end
25
36
  end
@@ -16,7 +16,11 @@ module Activist
16
16
 
17
17
  def delete_button_link(path, text = 'Delete', confirmation = 'Are you sure')
18
18
  link_to((image_tag('icons/application_delete.png', :class => :medium) + text).html_safe, path, :method => :delete, :class => 'button', :confirm => confirmation)
19
-
20
19
  end
20
+
21
+ def add_button_link(path, text = 'Add')
22
+ link_to((image_tag('icons/application_add.png', :class => :medium) + text).html_safe, path, :class => 'button')
23
+ end
24
+
21
25
  end
22
26
  end
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{simplificator-activist}
5
- s.version = "0.0.2"
5
+ s.version = "0.0.4"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["pascalbetz"]
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 2
9
- version: 0.0.2
8
+ - 4
9
+ version: 0.0.4
10
10
  platform: ruby
11
11
  authors:
12
12
  - pascalbetz