improve_typography 0.1.8 → 0.1.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/improve_typography/processors/nbsp.rb +3 -3
- data/lib/improve_typography/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 15de4945fe7e742d77f6bab3f6899c8311ea9b28
|
4
|
+
data.tar.gz: da8c36060a8b50d0771f123668baa62b4f12b3c6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cf287039ae45d750ce6995d0b4ddd6cf6d04402d26dbabd2500e71c059ad6c59300ad21812d1c563fe88eeac9f2869a77f1f72280e1b5d54a86fcae012223392
|
7
|
+
data.tar.gz: 4c9e35546556bfb94514115542bba1e800b60452452eb242751c0991df158d6ae96be6d2e9da054f209a3dadd934f2968e26d8735b120ae4cbd21ed4c0960e15
|
data/CHANGELOG.md
CHANGED
@@ -3,9 +3,9 @@ module ImproveTypography
|
|
3
3
|
class Nbsp < Processor
|
4
4
|
def call
|
5
5
|
str
|
6
|
-
.gsub(/(\s+)(
|
7
|
-
.gsub(/\A(
|
8
|
-
.gsub(/(\
|
6
|
+
.gsub(/(\s+)(\S|\d+|\S\.)(\s+)(\S)/, '\1\2 \4') # in the middle of string
|
7
|
+
.gsub(/\A(\w|\d+|\w\.)(\s+)(\S)/, '\1 \3') # at the beginning of string
|
8
|
+
.gsub(/([^\S\n])(\S|\d+|\S\.)(\z|[\.?!]\z|[\.?!]\s)/, ' \2\3') # at the end of string!!
|
9
9
|
.gsub(/(\A|\s+)(©)(\s+)(\d+)/, '\1\2 \3')
|
10
10
|
.gsub(/(\A|\s+)(No\.|Vol\.)(\s+)(\d+)/, '\1\2 \3')
|
11
11
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: improve_typography
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tomas Celizna
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-06
|
11
|
+
date: 2017-10-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: i18n
|