maglove-widgets 1.1.3 → 1.1.4

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: 5dd44a759e79cf41bc4504dcae15e5ae6fec1ee4
4
- data.tar.gz: f5054243b2298daa87c271d37cc9b8259c1ea80b
3
+ metadata.gz: 162b24807ca4b9e465826ca0c456453e5ff1f057
4
+ data.tar.gz: e9962fe7c600b162ff949cd9739574c0aea546a4
5
5
  SHA512:
6
- metadata.gz: b00d7207bb1b45734650985d93e4441b024dfb28f6936725098d7b0ec25d10e57c12ee8a87d7143fedbf191289616d336f3b74322c79f97698f2d958836d52f2
7
- data.tar.gz: 0e2518a79589f9c47b580f7e789485526e74a1555670b7133d284699b876f872e8cc65dd8d106c6e83fe654d4fbac886a69c85e070bb8b0208dac41283b6498a
6
+ metadata.gz: affd28cbb5c8978be9cdb2e13237f2d7ac67df66005260345911c54e45b23ef6b6e037b76bb7c79abb1f426ae0e490b9a2d0e7ce6c24b76cc130998cb643d893
7
+ data.tar.gz: 555c79bc97a6420e46e8c3ea6de6e05fde5d49c743d2e0a50db81a302683b16fdbcc174688bbf445b362b9c0bb80f410935230475fb2fddba5289c107642bd44
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- maglove-widgets (1.1.3)
4
+ maglove-widgets (1.1.4)
5
5
  bundler (~> 1.14)
6
6
  hamloft (~> 0.2)
7
7
 
@@ -27,4 +27,4 @@ DEPENDENCIES
27
27
  maglove-widgets!
28
28
 
29
29
  BUNDLED WITH
30
- 1.15.1
30
+ 1.15.4
@@ -26,8 +26,10 @@ module Maglove
26
26
  widget_block(Widgets::Paragraph.new(options)) do |widget|
27
27
  haml_tag :div, style: style_string(widget.options, :margin, :padding), class: "paragraph #{widget.options[:style]} align-#{widget.options[:align]} size-#{widget.options[:size]}" do
28
28
  unless widget.options[:drop_cap].empty?
29
- haml_tag :span, class: "__dropcap", style: "color: #{widget.options[:drop_cap_color]};" do
30
- haml_concat(widget.options[:drop_cap])
29
+ if widget.options[:style].include?('inverse-dropcap')
30
+ set_dropcap widget, "background-color"
31
+ else
32
+ set_dropcap widget, "color"
31
33
  end
32
34
  end
33
35
 
@@ -38,6 +40,12 @@ module Maglove
38
40
  end
39
41
  end
40
42
  end
43
+
44
+ def set_dropcap widget, color_attribute
45
+ haml_tag :span, class: "__dropcap", style: "#{color_attribute}: #{widget.options[:drop_cap_color]};" do
46
+ haml_concat(widget.options[:drop_cap])
47
+ end
48
+ end
41
49
  end
42
50
  end
43
51
  end
@@ -3,7 +3,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
3
3
 
4
4
  Gem::Specification.new do |s|
5
5
  s.name = "maglove-widgets"
6
- s.version = "1.1.3"
6
+ s.version = "1.1.4"
7
7
  s.licenses = ["BSD-3-Clause"]
8
8
  s.platform = Gem::Platform::RUBY
9
9
  s.authors = ["Tobias Strebitzer"]
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: maglove-widgets
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.3
4
+ version: 1.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tobias Strebitzer
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-09-25 00:00:00.000000000 Z
11
+ date: 2017-09-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -87,7 +87,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
87
87
  version: '0'
88
88
  requirements: []
89
89
  rubyforge_project:
90
- rubygems_version: 2.6.10
90
+ rubygems_version: 2.5.2
91
91
  signing_key:
92
92
  specification_version: 4
93
93
  summary: MagLove Widgets Repository