pdfgen 0.2.0 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/VERSION +1 -1
  3. data/lib/pdfgen.rb +2 -3
  4. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a11f131adef22537c617dbbebbd341b532a0073e
4
- data.tar.gz: ba17d559c083c1295bd7bf5f6148ef498f0c1fff
3
+ metadata.gz: f2b31c30f68e868e766a5dce43b1a6b985dc9513
4
+ data.tar.gz: 8346bbe9d9cf548962e258af8b576d8f44dc03e5
5
5
  SHA512:
6
- metadata.gz: 0ea013f074727de44cca622a744e8c9f40d563d4b5e34ae120d4820d36ef71cc401bfb7f163e08c2f458acd7f632a68d36a0cf33ed966e9c2e6ec018ed9fce43
7
- data.tar.gz: 625a99d4b4a7f064998c655c31235dc6181de4a2dbf80c541f8d944b4d432e41ea6bfb27919cead776cbe3fd899fb551122e12c0d7eb85cc21431cee51ad2ee7
6
+ metadata.gz: f9213a73b14322c244572a0ff40daa606b47702714c6c0a59f8531410138d4d953fe47e1b36ec4516c8f561ab1f71ec6164040f4e669cff48260ffad90ae8cab
7
+ data.tar.gz: cbc262d33c7a48bff0f2e2788387abbce14e2f71514c06998f02908731a0da1b575fc3882e862bd51079116cb87cb7ba68471a2dd26e87c4100f82d04b90cc5a
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.2.0
1
+ 0.2.1
data/lib/pdfgen.rb CHANGED
@@ -13,7 +13,7 @@ class Pdfgen
13
13
  @html = html
14
14
  @viewport_options = nil
15
15
  @emulate_media = nil
16
- @launch_options = nil
16
+ @launch_options = Hash.new
17
17
  end
18
18
 
19
19
  def set_viewport(viewport_options)
@@ -32,10 +32,9 @@ class Pdfgen
32
32
  end
33
33
 
34
34
  def to_pdf(opts = {})
35
- stdin_options = { pdf_options: opts, current_path: Dir.pwd }
35
+ stdin_options = { pdf_options: opts, current_path: Dir.pwd, launch_options: @launch_options }
36
36
  stdin_options = stdin_options.merge(viewport_options: @viewport_options) if @viewport_options
37
37
  stdin_options = stdin_options.merge(emulate_media: @emulate_media) if @emulate_media
38
- stdin_options = stdin_options.merge(launch_options: @launch_options) if @launch_options
39
38
  file = Tempfile.new('input_html')
40
39
  file.write(@html)
41
40
  file.close
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pdfgen
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
  - Daniel Fox
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-04-15 00:00:00.000000000 Z
11
+ date: 2018-04-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: minitest