corn_starch 1.1.33 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: baa8c54b829b1e5f33c3f710db2d6bdea9cb7057
4
- data.tar.gz: 80ee50eac115325648b528c8803c9975ed2a079a
3
+ metadata.gz: 77b0aeaf14f8983dc7649222ef445fb8e2980011
4
+ data.tar.gz: 81b0df91816c77176503800b0787624afc5faa15
5
5
  SHA512:
6
- metadata.gz: 7fab3760cdf0d088dfe4cc050619389ea441e9ad2836cb06c01cef78f18bdbc6421caee3df84c0b2290b7f33ab1d13b19a3f70f7612866f975992597078c3709
7
- data.tar.gz: 1a56999a225b931ddc25df354abae7ea198f6fb918a42ae97a04b4a0bf544b21de44339f2dd368419f61021292784446a80d7e308db415c478c1aeddb1fc4525
6
+ metadata.gz: 72d8dad648fb24cbb8a9727feae71499e6e1511e144e8bcc946c127d1d59fd3c39b78995cc173187f4210afb8e3bda685b694c0f2ba6dfc1c01e807196433311
7
+ data.tar.gz: 99961224fc0d1d79a23372e70a76f74b757770494a266cd1fc63e5196b0f50c7ad90e037875db2dd98b8caf52b81095ada9350311c5a9178ee134da28f1ae2e5
@@ -11,6 +11,17 @@ module CornStarch
11
11
  extend ActionView::Helpers
12
12
  extend ActionView::Context
13
13
 
14
+ # Gravatar Image
15
+ def gravatar_img email, size = 64, options = {}
16
+ image_tag gravatar_url(email, size), options
17
+ end
18
+
19
+ # Gravatar URL
20
+ def gravatar_url email, size = 64
21
+ gravatar_id = Digest::MD5.hexdigest(email.downcase)
22
+ "http://gravatar.com/avatar/#{gravatar_id}.png?s=#{size}"
23
+ end
24
+
14
25
  # Icon Link
15
26
  def icon_link_to target, icon
16
27
  link_to target do
@@ -1,3 +1,3 @@
1
1
  module CornStarch
2
- VERSION = '1.1.33'
2
+ VERSION = '1.2.0'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: corn_starch
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.33
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eresse