compass-string2base64 1.0.0 → 1.0.1

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: 2adf62d9370aa67e650b5e7ee90dabb1d4ffdc43
4
- data.tar.gz: eccc89b6c8a2116d79c99016956aaa670c0ecfec
3
+ metadata.gz: 538686826a1727a6616b53b7ab7ce9aa19ff8675
4
+ data.tar.gz: d5555790bfaa06296a88282af8040a368cc2ec13
5
5
  SHA512:
6
- metadata.gz: fb133f3902cabb1eecc276170f4e4ca9ef2abffa34cb8afe5528ad45bd474c79cc4e7083cb57e99236d3b5be1b2d44f6b36e856cbfc7819f007df55f1f5cd733
7
- data.tar.gz: 942cc3d92a098e8f9eccf32b563a05e892db22d136f0270bff2fdeecbc99eda120600fa7043aa9bad680539515b1c2f6db108bf677ffcb123905d23e5766d7ee
6
+ metadata.gz: 5eed5d0eec8bf52bc02c008269505a81bb70166e33569430c0456dcf952fb178c63a363cb23065af10ab86fccac775602fa020a871f3813a4868c53c3fddb901
7
+ data.tar.gz: 1de08df0546075ee08a674c3ca52a8240c50981dc2ae668a5c5ca098ec74d076736fb6fd93b8682f0b0ad612f95e81d60c70844778b06788fafb00933f470182
@@ -1,25 +1,23 @@
1
- # Compass::String2base64
1
+ = Compass::String2base64
2
2
 
3
3
  Sass/Compass extension to convert string (for example SVG) to base64, use via background or background-images with MIME-type image/svg+xml.
4
4
 
5
5
  Data URI via base64 hash in css usage:
6
- ```
7
- some-css-selector {
8
- background-image: url(data:[MIME-type][; charset];base64,_base64_hash_string_goes_here_)
9
- }
10
- ```
6
+ some-css-selector {
7
+ background-image: url(data:[MIME-type][; charset];base64,_base64_hash_string_goes_here_)
8
+ }
9
+
11
10
  As you can see, you can not specify the encoding.
12
11
 
13
12
  SVG in background in css usage:
14
- ```
15
- some-css-selector {
16
- background-image: url(data:image/svg+xml;charset=utf-8;base64,_SVG_base64_hash_string_goes_here_)
17
- }
18
- ```
19
- Support of SVG via backgrounds http://caniuse.com/#feat=svg-css
13
+ some-css-selector {
14
+ background-image: url(data:image/svg+xml;charset=utf-8;base64,_SVG_base64_hash_string_goes_here_)
15
+ }
16
+
17
+ Support of SVG via backgrounds http://caniuse.com/=feat=svg-css
20
18
 
21
19
 
22
- ## Installation
20
+ == Installation
23
21
 
24
22
  Add this line to your application's Gemfile:
25
23
 
@@ -33,15 +31,14 @@ Or install it yourself as:
33
31
 
34
32
  $ gem install compass-string2base64
35
33
 
36
- ## Usage
34
+ == Usage
35
+
36
+ background-image: url('data:image/svg+xml;charset=utf-8;base64,'
37
+ + string2base64('<svg width="100%" height="100%" xmlns="http://www.w3.org/2000/svg"></svg>'));
37
38
 
38
- ```
39
- background-image: url('data:image/svg+xml;charset=utf-8;base64,'
40
- + string2base64('<svg width="100%" height="100%" xmlns="http://www.w3.org/2000/svg"></svg>'));
41
- ```
42
39
  See example folder and run `compass compile --force` in this folder to see the result
43
40
 
44
- ## Contributing
41
+ == Contributing
45
42
 
46
43
  1. Fork it
47
44
  2. Create your feature branch (`git checkout -b my-new-feature`)
@@ -1,3 +1,3 @@
1
1
  module String2base64
2
- VERSION = "1.0.0"
2
+ VERSION = "1.0.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: compass-string2base64
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexander Pinchuk
@@ -63,7 +63,7 @@ files:
63
63
  - .gitignore
64
64
  - Gemfile
65
65
  - LICENSE.txt
66
- - README.md
66
+ - README.rdoc
67
67
  - Rakefile
68
68
  - compass-string2base64.gemspec
69
69
  - example/config.rb