scrivito_icon_box_widget 1.1.6 → 1.1.7
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: b314b6252330847e606c79b428230f4b227d7e5f
|
4
|
+
data.tar.gz: 10ff19ba70761679a7f297b5f89c72d4cd10263c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7acd511545facc9089a18bcc6cafebb46d520df4ebe0b38d0584b8b0c9cb5afc22bdc1d10a0b9ad2c16cd8a8676a902204eeddf8b7c9a0d3e5be3896a5fd77dc
|
7
|
+
data.tar.gz: 22288a84c1478e9b22e6c6e7164c41125addf9d389c80d91640654d32148a1430d3ff1f2045489ea57ec3a6279429c6a9e76fffccbd49fdd84d40d20b3d98612
|
@@ -1,4 +1,9 @@
|
|
1
1
|
class IconBoxWidget < Widget
|
2
|
+
attribute :icon, :string
|
3
|
+
attribute :color, :string
|
4
|
+
attribute :background_color, :string
|
5
|
+
attribute :size, :enum, values: ["small","medium","large"]
|
6
|
+
attribute :style, :enum, values: ["circle","square","filled-circle","filled-square"]
|
2
7
|
|
3
8
|
def selectable_color_classes(class_name, attribute)
|
4
9
|
if Obj.respond_to?('selectable_color_classes')
|
@@ -1,4 +1,4 @@
|
|
1
|
-
<%= scrivito_toggle_button_editor(widget, attribute, widget.selectable_color_classes(widget.
|
1
|
+
<%= scrivito_toggle_button_editor(widget, attribute, widget.selectable_color_classes(widget.class.to_s, attribute)) do |elem|
|
2
2
|
scrivito_tag(:button, widget, attribute, class: "#{elem == widget.send(attribute) ? 'active' : ''} #{elem}", data: {editor: 'scrivito-toggle-button', content: elem}) do
|
3
3
|
elem
|
4
4
|
end
|
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.1.
|
4
|
+
version: 1.1.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Scrivito
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-04-
|
11
|
+
date: 2015-04-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|