so_social 0.2.1 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/so_social/view_helpers.rb +17 -1
- metadata +6 -5
@@ -34,6 +34,22 @@ module SoSocial
|
|
34
34
|
data-onstartinteraction='#{options[:on_start_interaction]}' data-onendinteraction='#{options[:on_end_interaction]}'></div>
|
35
35
|
eos
|
36
36
|
)
|
37
|
-
end
|
37
|
+
end
|
38
|
+
|
39
|
+
def reddit_button(options = {})
|
40
|
+
options[:type] = 1 unless options[:type] && options[:type].between?(1,3)
|
41
|
+
raw(
|
42
|
+
<<-eos
|
43
|
+
<script type="text/javascript">
|
44
|
+
reddit_url='#{options[:url]}';
|
45
|
+
reddit_target='#{options[:target]}';
|
46
|
+
reddit_title='#{options[:title]}';
|
47
|
+
reddit_bgcolor='#{options[:color]}';
|
48
|
+
reddit_bordercolor='#{options[:border_color]}';
|
49
|
+
</script>
|
50
|
+
<script type="text/javascript" src="http://www.reddit.com/static/button/button#{options[:type]}.js"></script>
|
51
|
+
eos
|
52
|
+
)
|
53
|
+
end
|
38
54
|
end
|
39
55
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: so_social
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,10 +9,11 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-
|
12
|
+
date: 2012-06-02 00:00:00.000000000 Z
|
13
13
|
dependencies: []
|
14
|
-
description: This Gem provides simple methods to add sharing functionality to your
|
15
|
-
page. Currently supporting Facebook, Twitter and
|
14
|
+
description: ! "This Gem provides simple methods to add sharing functionality to your
|
15
|
+
page. Currently supporting Facebook, Twitter Google+ and Reddit. \n Feel free to
|
16
|
+
contact me if you want any features/services included!"
|
16
17
|
email:
|
17
18
|
- dre@fidrelity.at
|
18
19
|
executables: []
|
@@ -45,5 +46,5 @@ rubyforge_project:
|
|
45
46
|
rubygems_version: 1.8.16
|
46
47
|
signing_key:
|
47
48
|
specification_version: 3
|
48
|
-
summary: Simple Sharing Buttons for Facebook, Twitter, Google
|
49
|
+
summary: Simple Sharing Buttons for Facebook, Twitter, Google+, Reddit
|
49
50
|
test_files: []
|