ecm_news2 1.0.2 → 1.0.3

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: bfe2bb061335bad29daf124507abd7962c932da8
4
- data.tar.gz: 1916f68d81c518a486e9681c1b87a25fe107ae26
3
+ metadata.gz: 4f99b31cae81ab3fcb4583c1993b0eefacdfcf23
4
+ data.tar.gz: 06ccad532552eabe28431884860a2150faef1db3
5
5
  SHA512:
6
- metadata.gz: a6de097f72f00b3ab82dcad0fddab798ac2a4fa580aa8bd597012a0d729d35a09262aca9e4e810134262c8cc693263f688c5af3147afebbe6589e386b7d68122
7
- data.tar.gz: 0ef53e73917cd56301c47d07c9b7147c533a3d648ac1ec0fc280383ecaffc78b01c03892ad47c3c7d1baba734fdf656b1418bba0fdf588991231d43253490a9e
6
+ metadata.gz: 7d920f6548549adf6bb9628dd62b55cf44c2fd0fd00c13ff67b399f799d0137dad54ccb2a414fa10bbb4af330387e9fa75f87dfc436e1f99b44bf3acd13552a9
7
+ data.tar.gz: b048cb24a1633c1a87b3a7bdf594fc66e839ad683f4459b6ae507f707185141e9c46c9366cd2b37b631ab0d023e26a0523f433a7cd36934f8aba7980c1048149
@@ -1,11 +1,11 @@
1
- <div class="media">
1
+ <div class="<%= Ecm::News::Configuration.news_item_preview_div_classes %>" id="<%= item.class.name.underscore.gsub('/', '-') %>-<%= item.to_param %>">
2
2
  <div class="media-left">
3
3
  <% if item.preview_picture.present? %>
4
- <%= link_to(item, class: 'col-lg-2') do %>
4
+ <%= link_to(item, class: Ecm::News::Configuration.news_item_preview_thumbnail_link_classes) do %>
5
5
  <img class="media-object thumbnail img-responsive" src="<%= item.preview_picture.image.url(:default_thumb) %>" alt="...">
6
6
  <% end %>
7
7
  <% else %>
8
- <div class="col-lg-2"></div>
8
+ <%= content_tag(:div, nil, class: Ecm::News::Configuration.news_item_preview_thumbnail_link_classes) %>
9
9
  <% end %>
10
10
  </div>
11
11
  <div class="media-body">
@@ -6,3 +6,6 @@
6
6
 
7
7
  <%= paginate @items, :theme => 'twitter-bootstrap' %>
8
8
 
9
+ <div class="well page-actions">
10
+ <%= link_to(t('ecm.news.item.actions.back'), ecm_news_items_path, class: 'btn btn-default') %>
11
+ </div>
@@ -29,6 +29,14 @@ module Ecm
29
29
  true
30
30
  end
31
31
 
32
+ mattr_accessor :news_item_preview_thumbnail_link_classes do
33
+ 'col-lg-4'
34
+ end
35
+
36
+ mattr_accessor :news_item_preview_div_classes do
37
+ 'media ecm-news-item bottom-margin-2'
38
+ end
39
+
32
40
  mattr_accessor :base_controller do
33
41
  'ApplicationController'
34
42
  end
@@ -1,6 +1,6 @@
1
1
  module Ecm
2
2
  module News
3
- VERSION = "1.0.2"
3
+ VERSION = "1.0.3"
4
4
  end
5
5
  end
6
6
 
@@ -24,6 +24,18 @@ Ecm::News.configure do |config|
24
24
  # Default: config.show_publish_time = true
25
25
  config.show_publish_time = true
26
26
 
27
+ # CSS Classes for the preview container div
28
+ #
29
+ # Default: config.news_item_preview_div_classes = 'media ecm-news-item bottom-margin-2'
30
+ #
31
+ config.news_item_preview_div_classes = 'media ecm-news-item bottom-margin-2'
32
+
33
+ # CSS Classes for the preview thumbnail link
34
+ #
35
+ # Default: config.news_item_preview_thumbnail_link_classes = 'col-lg-4'
36
+ #
37
+ config.news_item_preview_thumbnail_link_classes = 'col-lg-4'
38
+
27
39
  # Set the base controller for the contact form
28
40
  #
29
41
  # Default: config.base_controller = 'ApplicationController'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ecm_news2
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
4
+ version: 1.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Roberto Vasquez Angel