victor 0.2.0 → 0.2.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: 3333d626e4dc11a717da2f915ead15331fae87c0
4
- data.tar.gz: 562d059c2c3596c1f7f890554459f821b0714cdf
3
+ metadata.gz: 6c9b02320dd3fe0061bf8d703b4a50b9c5ef1928
4
+ data.tar.gz: 6ab896856bff9033cb81b0593520c02fc508cd3c
5
5
  SHA512:
6
- metadata.gz: 5e1c3fc3bb74ffab341c3b572c286a15493a4a32136f1c9169b8c155cc0c2ef0218008fd3fdedf517d82d40123ae80fbff7f765a06f34734fce761b1c0ea0304
7
- data.tar.gz: 9537eb2500737b43fa4cb6ea8192d9f67e5828045f184a7352f16da7fd8795d8a53823285ec4e16b4c53eb44592e882515c780b1252e2b18420b0dbb45a67243
6
+ metadata.gz: bbb2d3dbb6567ccdf49e5aefe3719c44f2ebb347ada557b9ae3ef39a3621a8b6dfffbe533879b4d2556d44e28aad038905c940452b67f507e9f72ed134eb2cde
7
+ data.tar.gz: c611c5b2923a98c731c08371358cda94559fbea12e290dc38a2368d864ada2813e3b434df305f0bbd650f0ebfff54edd8f692bfcf16f14b1e4bc8794321ace9c
data/README.md CHANGED
@@ -32,7 +32,7 @@ Examples
32
32
  ```ruby
33
33
  require 'victor'
34
34
 
35
- svg = SVG.new width: 140, height: 100, style: { background: '#ddd' }
35
+ svg = Victor::SVG.new width: 140, height: 100, style: { background: '#ddd' }
36
36
 
37
37
  svg.build do
38
38
  rect x: 10, y: 10, width: 120, height: 80, rx: 10, fill: '#666'
@@ -65,17 +65,17 @@ Initialize your SVG image:
65
65
 
66
66
  ```ruby
67
67
  require 'victor'
68
- svg = SVG.new
68
+ svg = Victor::SVG.new
69
69
  ```
70
70
 
71
71
  Any option you provide to `SVG.new` will be added as an attribute to the
72
72
  main `<svg>` element. By default, `height` and `width` are set to 100%.
73
73
 
74
74
  ```ruby
75
- svg = SVG.new width: '100%', height: '100%'
76
- # same as just SVG.new
75
+ svg = Victor::SVG.new width: '100%', height: '100%'
76
+ # same as just Victor::SVG.new
77
77
 
78
- svg = SVG.new width: '100%', height: '100%', viewBox: "0 0 200 100"
78
+ svg = Victor::SVG.new width: '100%', height: '100%', viewBox: "0 0 200 100"
79
79
  ```
80
80
 
81
81
  Victor uses a single method (`element`) to generate all SVG elements:
@@ -179,14 +179,14 @@ a standalone SVG image). If you wish to use the output as an SVG element
179
179
  inside HTML, you can change the SVG template:
180
180
 
181
181
  ```ruby
182
- svg = SVG.new template: :html
182
+ svg = Victor::SVG.new template: :html
183
183
  # accepts :html, :default or a filename
184
184
  ```
185
185
 
186
186
  You can also point it to any other template file:
187
187
 
188
188
  ```ruby
189
- svg = SVG.new template: 'path/to/template.svg'
189
+ svg = Victor::SVG.new template: 'path/to/template.svg'
190
190
  ```
191
191
 
192
192
  See the [templates] folder for an understanding of how templates are
@@ -200,7 +200,7 @@ To add a CSS to your SVG, simply use the `css` command inside your `build`
200
200
  block, like this:
201
201
 
202
202
  ```ruby
203
- svg = SVG.new
203
+ svg = Victor::SVG.new
204
204
 
205
205
  svg.build do
206
206
  css['.main'] = {
@@ -2,5 +2,3 @@ require 'victor/version'
2
2
  require 'victor/svg'
3
3
  require 'victor/attributes'
4
4
  require 'victor/css'
5
-
6
- include Victor
@@ -1,3 +1,3 @@
1
1
  module Victor
2
- VERSION = "0.2.0"
2
+ VERSION = "0.2.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: victor
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Danny Ben Shitrit
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-02-04 00:00:00.000000000 Z
11
+ date: 2017-02-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: runfile