scrivito_two_column_widget 1.0.2 → 1.0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/images/widgets/two_column_default_gutter.png +0 -0
- data/app/assets/images/widgets/two_column_large_gutter.png +0 -0
- data/app/assets/images/widgets/two_column_on_mobile_no.png +0 -0
- data/app/assets/images/widgets/two_column_on_mobile_yes.png +0 -0
- data/app/assets/images/widgets/two_column_small_gutter.png +0 -0
- data/app/assets/stylesheets/{scritivo_two_column_widget.scss → scrivito_two_column_widget.scss} +11 -0
- data/app/models/two_column_widget.rb +16 -0
- data/app/views/two_column_widget/details.html.erb +3 -6
- data/app/views/two_column_widget/thumbnail.html.erb +1 -1
- data/lib/scrivito_two_column_widget/version.rb +1 -1
- metadata +8 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9574a0e2ac8361950a3f854a86cf6746cd833cac
|
4
|
+
data.tar.gz: b66fff1d7dfdef86f91d28bb8c0fa82887d4e90b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3294e2de46814bb847ad413727608c36fc7b7f941fac631f43f806949fe45cd0f5589387b8ad301a057659401d6b6d97439d7cbe8192476eabe52371c8564d00
|
7
|
+
data.tar.gz: 0db029bc9ee12afeb43cf09d7d44e02832cfa27be4a1182c04aea90a390cd1666c44f743fd620a2f34055b13dc67f83a55cc3398181e64f3c164800f1b63de16
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -21,4 +21,20 @@ class TwoColumnWidget < Widget
|
|
21
21
|
def device_class
|
22
22
|
keep_columns == 'Yes' ? 'xs' : 'md'
|
23
23
|
end
|
24
|
+
|
25
|
+
def self.gutter_size_button_images
|
26
|
+
elems = {}
|
27
|
+
['small','default','large'].each do |elem|
|
28
|
+
elems[elem] = ActionController::Base.helpers.image_tag "widgets/two_column_#{elem}_gutter.png"
|
29
|
+
end
|
30
|
+
return elems
|
31
|
+
end
|
32
|
+
|
33
|
+
def self.column_on_mobile_button_images
|
34
|
+
elems = {}
|
35
|
+
['Yes','No'].each do |elem|
|
36
|
+
elems[elem] = ActionController::Base.helpers.image_tag "widgets/two_column_on_mobile_#{elem.downcase}.png"
|
37
|
+
end
|
38
|
+
return elems
|
39
|
+
end
|
24
40
|
end
|
@@ -1,14 +1,11 @@
|
|
1
|
-
<%= scrivito_details_for 'column 1' do %>
|
2
|
-
<%= scrivito_tag(:div, widget, :column_1_width) %>
|
3
|
-
<% end %>
|
4
1
|
<%= scrivito_details_for t('scrivito_two_column_widget.details.column_1_width', default: 'Width for column 1') do %>
|
5
2
|
<%= scrivito_tag(:div, widget, :column_1_width) %>
|
6
3
|
<% end %>
|
7
4
|
|
8
|
-
<%= scrivito_details_for t('scrivito_two_column_widget.details.grid_size', default: '
|
9
|
-
<%= scrivito_tag(:div, widget, :grid_size) %>
|
5
|
+
<%= scrivito_details_for t('scrivito_two_column_widget.details.grid_size', default: 'Gutter Size') do %>
|
6
|
+
<%= scrivito_tag(:div, widget, :grid_size, class: 'scrivito-image-button-small', data:{ toggle_button_caption: TwoColumnWidget.gutter_size_button_images }) %>
|
10
7
|
<% end %>
|
11
8
|
|
12
9
|
<%= scrivito_details_for t('scrivito_two_column_widget.details.keep_columns', default: 'Show columns on mobile') do %>
|
13
|
-
<%= scrivito_tag(:div, widget, :keep_columns) %>
|
10
|
+
<%= scrivito_tag(:div, widget, :keep_columns, class: 'scrivito-image-button', data:{ toggle_button_caption: TwoColumnWidget.column_on_mobile_button_images }) %>
|
14
11
|
<% end %>
|
@@ -1,3 +1,3 @@
|
|
1
|
-
<%= scrivito_thumbnail t('scrivito_two_column_widget.thumbnail.title', default: '
|
1
|
+
<%= scrivito_thumbnail t('scrivito_two_column_widget.thumbnail.title', default: 'Two Columns'), image_tag("widgets/scrivito_two_column_widget.png") do %>
|
2
2
|
<%= t('scrivito_two_column_widget.thumbnail.description', default: 'Two columns that can be filled with widgets') %>
|
3
3
|
<% end %>
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: scrivito_two_column_widget
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.3.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Scrivito
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-09-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: scrivito
|
@@ -35,7 +35,12 @@ files:
|
|
35
35
|
- README.md
|
36
36
|
- Rakefile
|
37
37
|
- app/assets/images/widgets/scrivito_two_column_widget.png
|
38
|
-
- app/assets/
|
38
|
+
- app/assets/images/widgets/two_column_default_gutter.png
|
39
|
+
- app/assets/images/widgets/two_column_large_gutter.png
|
40
|
+
- app/assets/images/widgets/two_column_on_mobile_no.png
|
41
|
+
- app/assets/images/widgets/two_column_on_mobile_yes.png
|
42
|
+
- app/assets/images/widgets/two_column_small_gutter.png
|
43
|
+
- app/assets/stylesheets/scrivito_two_column_widget.scss
|
39
44
|
- app/models/two_column_widget.rb
|
40
45
|
- app/views/two_column_widget/details.html.erb
|
41
46
|
- app/views/two_column_widget/show.html.erb
|