scrivito_icon_box_widget 1.1.11 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/stylesheets/scrivito_icon_box_widget.css +0 -1
- data/app/assets/stylesheets/scrivito_icon_box_widget/base.css.scss +1 -1
- data/app/models/icon_box_widget.rb +20 -12
- data/app/views/icon_box_widget/details.html.erb +4 -4
- data/app/views/icon_box_widget/partials/_icons_picker.html.erb +3 -1
- data/app/views/icon_box_widget/show.html.erb +2 -2
- data/lib/scrivito_icon_box_widget/engine.rb +0 -1
- data/lib/scrivito_icon_box_widget/version.rb +1 -1
- metadata +2 -17
- data/app/assets/javascripts/scrivito_icon_box_widget.js +0 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fad4a41b40ad05278b267d862712b764363e7b6b
|
4
|
+
data.tar.gz: 03d4bb7f0196c28cb476cd7b8b1c045bcb7b27d5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2e1164ab0ce9af961794f9e43ee4c19a8f454061904154fe5e6dec0f8eca28c6f615bf9c73587d2fe5ae9abd6517c526489fade487730a2a4fc1b8d440280080
|
7
|
+
data.tar.gz: 64bd2b2116b43eb591631f08ab1f29ed0d1b7b8dd887d8689521fb61ae4f9f66b0981a337607778a1b31956a912a405ae85c0b527cca7ea081d8cbf5fc9b8bad
|
@@ -17,7 +17,7 @@
|
|
17
17
|
text-align: center;
|
18
18
|
}
|
19
19
|
|
20
|
-
.scrivito_dialog .
|
20
|
+
.scrivito_dialog .icon-select .toggle_button_list .scrivito-toggle-button {
|
21
21
|
padding: 6px 18px;
|
22
22
|
font-size: 10px;
|
23
23
|
line-height: 10px;
|
@@ -14,25 +14,33 @@ class IconBoxWidget < Widget
|
|
14
14
|
end
|
15
15
|
|
16
16
|
def self.icons
|
17
|
-
IconBoxWidget.icon_list
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
}
|
17
|
+
IconBoxWidget.icon_list
|
18
|
+
end
|
19
|
+
|
20
|
+
def self.caption
|
21
|
+
elems = {}
|
22
|
+
IconBoxWidget.icon_list.each do |elem|
|
23
|
+
elems[elem] = "<i class='fa fa-#{elem}'></i>#{elem}".html_safe
|
24
24
|
end
|
25
|
+
return elems
|
25
26
|
end
|
26
27
|
|
27
|
-
def
|
28
|
-
|
28
|
+
def background_classes
|
29
|
+
c = ["scrivito-icon-box"]
|
30
|
+
c << self.size
|
31
|
+
c << self.style
|
32
|
+
c << self.background_color
|
33
|
+
c.join(' ')
|
29
34
|
end
|
30
35
|
|
31
|
-
|
32
|
-
|
33
|
-
|
36
|
+
def icon_classes
|
37
|
+
c = ["fa"]
|
38
|
+
c << "fa-#{self.icon}"
|
39
|
+
c << self.color
|
40
|
+
c.join(' ')
|
34
41
|
end
|
35
42
|
|
43
|
+
private
|
36
44
|
def self.icon_list
|
37
45
|
["none", "plus","minus","warning","paw","send","car","sliders","tree","bell","certificate","cloud","comment","dashboard","female","male","flag","globe","heart","leaf","plane","refresh","rocket","question","star","unlock"]
|
38
46
|
end
|
@@ -3,17 +3,17 @@
|
|
3
3
|
<% end %>
|
4
4
|
|
5
5
|
<%= scrivito_details_for 'Size' do %>
|
6
|
-
<%=
|
6
|
+
<%= scrivito_tag(:div, widget, :size) %>
|
7
7
|
<% end %>
|
8
8
|
|
9
9
|
<%= scrivito_details_for 'Style' do %>
|
10
|
-
<%=
|
10
|
+
<%= scrivito_tag(:div, widget, :style) %>
|
11
11
|
<% end %>
|
12
12
|
|
13
13
|
<%= scrivito_details_for 'Icon Color' do %>
|
14
|
-
<%=
|
14
|
+
<%= scrivito_tag :div, widget, :color, data: {colors_list: scrivito_selectable_color_classes('icon_box_widget', 'color')} %>
|
15
15
|
<% end %>
|
16
16
|
|
17
17
|
<%= scrivito_details_for 'Background Color' do %>
|
18
|
-
<%=
|
18
|
+
<%= scrivito_tag :div, widget, :background_color, data: {colors_list: scrivito_selectable_color_classes('icon_box_widget', 'background_color')} %>
|
19
19
|
<% end %>
|
@@ -1,4 +1,6 @@
|
|
1
|
-
|
1
|
+
<div class="icon-select">
|
2
|
+
<%= scrivito_tag(:div, widget, attribute, data: {toggle_button_list: IconBoxWidget.icons, toggle_button_caption: IconBoxWidget.caption}) %>
|
3
|
+
</div>
|
2
4
|
<hr />
|
3
5
|
<h4>Icon not in List</h4>
|
4
6
|
<div class="alert alert-info">
|
@@ -1,3 +1,3 @@
|
|
1
|
-
<div class="
|
2
|
-
<i class="
|
1
|
+
<div class="<%= widget.background_classes %>">
|
2
|
+
<i class="<%= widget.icon_classes %>"></i>
|
3
3
|
</div>
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: scrivito_icon_box_widget
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Scrivito
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-12-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -38,20 +38,6 @@ dependencies:
|
|
38
38
|
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: scrivito_advanced_editors
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - ">="
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: '0'
|
48
|
-
type: :runtime
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - ">="
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: '0'
|
55
41
|
- !ruby/object:Gem::Dependency
|
56
42
|
name: font-awesome-rails
|
57
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -90,7 +76,6 @@ files:
|
|
90
76
|
- LICENSE
|
91
77
|
- Rakefile
|
92
78
|
- app/assets/images/widget_preview_icon.png
|
93
|
-
- app/assets/javascripts/scrivito_icon_box_widget.js
|
94
79
|
- app/assets/stylesheets/scrivito_icon_box_widget.css
|
95
80
|
- app/assets/stylesheets/scrivito_icon_box_widget/base.css.scss
|
96
81
|
- app/assets/stylesheets/scrivito_icon_box_widget/colors.css
|
@@ -1 +0,0 @@
|
|
1
|
-
//= require scrivito_advanced_editors
|