esvg 4.3.2 → 4.3.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: 051d0f7f2d698b4e1514aac9c3aa45701db91c4e
4
- data.tar.gz: 9e6c581c464a7f931992f3598cab24b98ac6e2eb
3
+ metadata.gz: 0653d64743d2e579be45c0f0bf03adfa72a6ed5c
4
+ data.tar.gz: 39c51eeeafbd2f4a5d26a04cde954aa00c41fd33
5
5
  SHA512:
6
- metadata.gz: 7ab57771920663c7b14891349355ef96d19aaf874491d566eea8842865954e4b0bb8914caabbb2548ddade85b4d7ba5184cd43ee3e3f1621a1402cc41e951084
7
- data.tar.gz: a2b94f14a41c831b61ab49be31ac9c89cefe7ca59954f92a7ae97cd497e390bf64d83e454d7d5af057ae00a3b8c309434f8aa4219d3e21fad87fcc375cbeac32
6
+ metadata.gz: 5bdc9f7881b15cdab822db515c7727184055e0d76cd679c70c7d2df1c09df5ef41b5640cc348dbe22e81fe88705367bdb888fe39cc4681be01e75746331961fa
7
+ data.tar.gz: 7608a22e619e3185a84df6f0ec8f3ac65e8bddde8a097234ff124044b33afe0f83674a03112487a7e32d5a2196bce436391f6b08b721d0095082cbaf48d44442
data/lib/esvg/svgs.rb CHANGED
@@ -17,6 +17,7 @@ module Esvg
17
17
  core: true,
18
18
  optimize: false,
19
19
  gzip: false,
20
+ scale: false,
20
21
  fingerprint: true,
21
22
  throttle_read: 4,
22
23
  flatten: [],
data/lib/esvg/symbol.rb CHANGED
@@ -77,11 +77,7 @@ module Esvg
77
77
  content = "<title>#{title}</title>#{content}"
78
78
  end
79
79
 
80
- use_attr = {
81
- height: options[:height],
82
- width: options[:width],
83
- scale: options[:scale],
84
- }.merge(options.delete(:use) || {})
80
+ use_attr = options.delete(:use) || {}
85
81
 
86
82
  svg_attr = {
87
83
  class: [@config[:class], @config[:prefix]+"-"+@name, options.delete(:class)].compact.join(' '),
@@ -104,7 +100,7 @@ module Esvg
104
100
  options["xlink:href"] = "##{@id}"
105
101
 
106
102
  # If user doesn't pass a size or set scale: true
107
- if options[:width].nil? && options[:height].nil? && options[:scale].nil?
103
+ if options[:width].nil? && options[:height].nil? && !options[:scale] && !@config[:scale]
108
104
  options[:width] ||= width
109
105
  options[:height] ||= height
110
106
  end
data/lib/esvg/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Esvg
2
- VERSION = "4.3.2"
2
+ VERSION = "4.3.3"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: esvg
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.3.2
4
+ version: 4.3.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brandon Mathis
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-06-06 00:00:00.000000000 Z
11
+ date: 2017-06-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler