resource_renderer 1.2.4 → 1.2.5
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bb5d68013f9b4f727e286c0ec864006ae701bc0e
|
4
|
+
data.tar.gz: 0e336f96a7c31aaa7ffb95c9dd3cd06f16c5f40c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f3e3f2f87a9f9991462378d95c5111bd3ddaba6c10e4cfd4b51805293c370c31958f03eb2a745c07bfe626f033707cfc1e5d0a516e79d8d850a3f667ac7e2332
|
7
|
+
data.tar.gz: 334578e17d45e9fdaaeee478f815f7a021bf035af25fd7cd9fc4d0931c327a354a87aa14126b6bcc74573132b16279d81543d6db1a0a9700a9f15c0f2a56579c
|
@@ -22,10 +22,10 @@ class BootstrapMediaObjectResourceRenderer < ResourceRenderer::ResourceRenderer:
|
|
22
22
|
media_body_content_html_options = options.delete(:media_body_content_html_options)
|
23
23
|
|
24
24
|
locals = {
|
25
|
-
title: title
|
26
|
-
body: body
|
27
|
-
image_src: image_url || @resource.send(image_method).send(image_url_method),
|
28
|
-
link_url: link_url
|
25
|
+
title: title || @resource.send(title_method),
|
26
|
+
body: body || @resource.send(body_method),
|
27
|
+
image_src: image_url || @resource.send(image_method).send(:try, image_url_method),
|
28
|
+
link_url: link_url || helper.url_for(@resource),
|
29
29
|
link_to_more_url: link_to_more_url,
|
30
30
|
media_body_content_html_options: media_body_content_html_options
|
31
31
|
}
|
@@ -1,7 +1,8 @@
|
|
1
1
|
.media
|
2
2
|
.media-left
|
3
3
|
= link_to(link_url, class: 'col-lg-4') do
|
4
|
-
|
4
|
+
- if image_src
|
5
|
+
%img.media-object.thumbnail.img-responsive{alt: title, src: image_src}
|
5
6
|
.media-body
|
6
7
|
%h3.media-heading= title
|
7
8
|
%div{ media_body_content_html_options }
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: resource_renderer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Roberto Vasquez Angel
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-03-
|
11
|
+
date: 2016-03-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|