bootstrap-email 1.1.6 → 1.1.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8874cd9676dffa70b594e1d0b19f94439a5b5a1d56d4c4625f70af5dfcbaf627
4
- data.tar.gz: 314113fdcd77f3d7bf7ad4936dd710c804a89644997f4478dc7deb02455fef19
3
+ metadata.gz: 1145fbba3e6a8db2d8fe571b8f5a4d05ff78ba0ddd4c40dea9ce317e06e5f1fe
4
+ data.tar.gz: f2aa2c03962d575448af829b381f18cfde6bacee0a2caf03b66a9ae0f218824f
5
5
  SHA512:
6
- metadata.gz: d09179eaa28c1091c59449c2a22368e9c877c23a11cc8682f949d72f0207c0f081e7d32955c070dbcdb69902cf54bc262c9fedcd907901b329f20d0354624e13
7
- data.tar.gz: bf27de1b4a6d6965583f8f4112c25fccf12c07ca10473a5eed7595dd11bdff34741e81039d76c1b23874aff702b76f02d6ee52edd47de8254774db2240d21709
6
+ metadata.gz: 150353d9f8a03a0b8fe0434013c5c814a97dc2eb1b03287517174c95d9df30fa22e1564d3dc8d2fc7cc9bc33734da0d845341cc4d8e07bfee1ca23db84490a9e
7
+ data.tar.gz: ce8b05c478d2bda5a46518d90a2bb3c8c6c8a1fe01bf197524b95c2b3182d5ca9f9b24e08bce6022f3af68779d7b087c54605dbe3b861b32bd601a1f551f5e8d
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.1.6
1
+ 1.1.7
@@ -7,11 +7,19 @@ module BootstrapEmail
7
7
  CLOSE_BRACKETS = CGI.escape('}}').freeze
8
8
 
9
9
  def self.replace(html)
10
- regex = /((href|src)=("|').*?)((#{Regexp.quote(OPEN_BRACKETS)}).*?(#{Regexp.quote(CLOSE_BRACKETS)}))(.*?("|'))/
10
+ regex = /((href|src)=("|'))(.*?((#{Regexp.quote(OPEN_BRACKETS)}).*?(#{Regexp.quote(CLOSE_BRACKETS)})).*?)("|')/
11
11
  return unless regex.match?(html)
12
12
 
13
+ inner_regex = /((#{Regexp.quote(OPEN_BRACKETS)}).*?(#{Regexp.quote(CLOSE_BRACKETS)}))/
14
+
13
15
  html.gsub!(regex) do |_match|
14
- "#{Regexp.last_match(1)}#{CGI.unescape(Regexp.last_match(4))}#{Regexp.last_match(7)}"
16
+ start_text = Regexp.last_match(1)
17
+ middle_text = Regexp.last_match(4)
18
+ end_text = Regexp.last_match(8)
19
+ middle_text.gsub!(inner_regex) do |match|
20
+ CGI.unescape(match)
21
+ end
22
+ "#{start_text}#{middle_text}#{end_text}"
15
23
  end
16
24
  end
17
25
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bootstrap-email
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.6
4
+ version: 1.1.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stuart Yamartino
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-05-18 00:00:00.000000000 Z
11
+ date: 2022-06-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: htmlbeautifier
@@ -66,7 +66,7 @@ dependencies:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
68
  version: '2.1'
69
- description:
69
+ description:
70
70
  email: stu@stuyam.com
71
71
  executables:
72
72
  - bootstrap-email
@@ -157,7 +157,7 @@ licenses:
157
157
  - MIT
158
158
  metadata:
159
159
  rubygems_mfa_required: 'true'
160
- post_install_message:
160
+ post_install_message:
161
161
  rdoc_options: []
162
162
  require_paths:
163
163
  - lib
@@ -172,8 +172,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
172
172
  - !ruby/object:Gem::Version
173
173
  version: '0'
174
174
  requirements: []
175
- rubygems_version: 3.0.3.1
176
- signing_key:
175
+ rubygems_version: 3.2.3
176
+ signing_key:
177
177
  specification_version: 4
178
178
  summary: 'Bootstrap 5+ stylesheet, compiler, and inliner for responsive and consistent
179
179
  emails with the Bootstrap syntax you know and love. Support: command line, ruby,