svg_sprite 0.1.1 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/svg_sprite/template/scss.erb +10 -1
- data/lib/svg_sprite/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c809954c826e615c638d11c6e5d45ca4c1433324
|
4
|
+
data.tar.gz: 2a621741fbca458404d7c788dd8a2e41fe57445f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ee627aee4e0a4d3bb5f2e89a17117a7443d7092f73bd2f91149e741808c7c7a701487ed0509a569a4b208ff4823f3799712229216b3cf6b19e2f2ab85398c0a2
|
7
|
+
data.tar.gz: 55a3a77f109683caab3e6ea155079f2fc9c00614216688170f027df6ec4b472045417e81fd4fc338341c86b22c476182cd7115c7d07bcaa147f249c0b4898063
|
@@ -1,5 +1,14 @@
|
|
1
1
|
// Generated by sprite_svg v<%= SvgSprite::VERSION %> at <%= Time.now %>
|
2
2
|
$<%= options[:name] %>-names: (<%= names(source) %>);
|
3
|
+
$<%= options[:name] %>-urls: (
|
4
|
+
<%- for svg in source -%>
|
5
|
+
<%= svg.name %>: "<%= svg.data_uri %>",
|
6
|
+
<%- end -%>
|
7
|
+
);
|
8
|
+
|
9
|
+
@function <%= options[:name] %>-url($name) {
|
10
|
+
@return map-get($<%= options[:name] %>-urls, $name);
|
11
|
+
}
|
3
12
|
|
4
13
|
@mixin <%= options[:name] %>-before($name) {
|
5
14
|
&:before {
|
@@ -15,7 +24,7 @@ $<%= options[:name] %>-names: (<%= names(source) %>);
|
|
15
24
|
|
16
25
|
<% for svg in source %>
|
17
26
|
%<%= options[:name] %>-<%= svg.name %> {
|
18
|
-
background-image: url(<%= svg.
|
27
|
+
background-image: url(<%= options[:name] %>-url("<%= svg.name %>"));
|
19
28
|
<%- if svg.has_dimensions? -%>
|
20
29
|
width: <%= svg.width %>;
|
21
30
|
height: <%= svg.height %>;
|
data/lib/svg_sprite/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: svg_sprite
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nando Vieira
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-03-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: svg_optimizer
|