jekyll-uj-powertools 1.0.9 → 1.0.11
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 +4 -4
- data/lib/jekyll-uj-powertools/version.rb +1 -1
- data/lib/jekyll-uj-powertools.rb +10 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a1907956be12ae593fade85fdb4e8384529f5be71f3654b553d5cc14bd534275
|
4
|
+
data.tar.gz: 151904a2c8f51bec63fa1fcd07a5c8f8d45073a2fb83ee7138123c3c9e1b05c6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 24b3318c735c5547bc5f7fa345f4c05fd1b0c9a02ce55c35fb8d7990b3e711ae1ba48aa9f4294df7cb10a4c69c3326bd037109b91863580cb97ca820c3dc63f9
|
7
|
+
data.tar.gz: e7b8d3fe31a73e0fa5bdfa9baabb7b2644c510f83870b94a527afedcd93ac73d2734bda2c2540bdf3fd8ff3515898dde689a4387408330a5839b8ef20341fa2e
|
data/lib/jekyll-uj-powertools.rb
CHANGED
@@ -4,7 +4,11 @@ module Jekyll
|
|
4
4
|
module UJPowertools
|
5
5
|
# Strip ads from the input
|
6
6
|
def uj_strip_ads(input)
|
7
|
-
input
|
7
|
+
input
|
8
|
+
# Remove HTML <ad-units>
|
9
|
+
.gsub(/\s*<ad-unit>[\s\S]*?<\/ad-unit>\s*/m, '')
|
10
|
+
# Remove includes starting with "/master/modules/adunits/"
|
11
|
+
.gsub(/\s*\{% include \/master\/modules\/adunits\/.*? %\}\s*/m, '')
|
8
12
|
end
|
9
13
|
|
10
14
|
# Escape a string for use in JSON
|
@@ -38,6 +42,11 @@ module Jekyll
|
|
38
42
|
def uj_random(input)
|
39
43
|
rand(input)
|
40
44
|
end
|
45
|
+
|
46
|
+
# Title case
|
47
|
+
def uj_title_case(input)
|
48
|
+
input.split(' ').map(&:capitalize).join(' ')
|
49
|
+
end
|
41
50
|
end
|
42
51
|
end
|
43
52
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jekyll-uj-powertools
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.11
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- ITW Creative Works
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-07-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: jekyll
|