prawn-markup 0.3.2 → 0.3.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/prawn/markup/processor/images.rb +9 -2
- data/lib/prawn/markup/version.rb +1 -1
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 064fb432004ce75eb3de1f626e08b1b5eba66de34fee0c1279eeb658d761a055
|
4
|
+
data.tar.gz: 0ea8ce592534b0b4f10480981374c66ff1ba09c9deb799f3e9f53214a9a3b831
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 534a234950b2df218bb111563730b18b9e1e2cb22c3393da53ae3d70412283139e9bec5e57e7aeb2ae0638132a6ab023b602c7cb9c9dcedf97e27e92371a8565
|
7
|
+
data.tar.gz: 8d7e1f43b928f9861b9b885eaf39692f8678b6e955845daf8859da60a95cdd76da72f1f2062dff8ef461dd0a9bd614509fb3903ba0ecada86546af7b1771460b
|
data/README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# Prawn::Markup
|
2
2
|
|
3
|
-
[![Build Status](https://
|
3
|
+
[![Build Status](https://github.com/puzzle/prawn-markup/actions/workflows/build.yml/badge.svg)](https://github.com/puzzle/prawn-markup/actions/workflows/build.yml)
|
4
4
|
[![Maintainability](https://api.codeclimate.com/v1/badges/52a462f9d65e33352d4e/maintainability)](https://codeclimate.com/github/puzzle/prawn-markup/maintainability)
|
5
5
|
[![Test Coverage](https://api.codeclimate.com/v1/badges/52a462f9d65e33352d4e/test_coverage)](https://codeclimate.com/github/puzzle/prawn-markup/test_coverage)
|
6
6
|
|
@@ -12,8 +12,11 @@ module Prawn
|
|
12
12
|
end
|
13
13
|
|
14
14
|
def start_img
|
15
|
+
src = current_attrs['src']
|
16
|
+
return if src.to_s.strip.empty?
|
17
|
+
|
15
18
|
add_current_text
|
16
|
-
add_image_or_placeholder(
|
19
|
+
add_image_or_placeholder(src)
|
17
20
|
end
|
18
21
|
|
19
22
|
def start_iframe
|
@@ -70,7 +73,11 @@ module Prawn
|
|
70
73
|
|
71
74
|
def load_remote_image(src)
|
72
75
|
if src =~ %r{^https?:/}
|
73
|
-
|
76
|
+
begin
|
77
|
+
URI.parse(src).open
|
78
|
+
rescue OpenURI::HTTPError, SocketError
|
79
|
+
nil
|
80
|
+
end
|
74
81
|
end
|
75
82
|
end
|
76
83
|
|
data/lib/prawn/markup/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: prawn-markup
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Pascal Zumkehr
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-11-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: nokogiri
|
@@ -187,7 +187,7 @@ homepage: https://github.com/puzzle/prawn-markup
|
|
187
187
|
licenses:
|
188
188
|
- MIT
|
189
189
|
metadata: {}
|
190
|
-
post_install_message:
|
190
|
+
post_install_message:
|
191
191
|
rdoc_options: []
|
192
192
|
require_paths:
|
193
193
|
- lib
|
@@ -202,8 +202,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
202
202
|
- !ruby/object:Gem::Version
|
203
203
|
version: '0'
|
204
204
|
requirements: []
|
205
|
-
rubygems_version: 3.1.
|
206
|
-
signing_key:
|
205
|
+
rubygems_version: 3.1.4
|
206
|
+
signing_key:
|
207
207
|
specification_version: 4
|
208
208
|
summary: Parse simple HTML markup to include in Prawn PDFs
|
209
209
|
test_files: []
|