Skip to content

Commit 5c7aea5

Browse files
Updated Dependency gem (#10)
* Support span tags in render_node method * Updated Dependency gem * Updated license year * Updated Gemfile.lock * Updated utils ruby SDK version * Added SDK version info in changelog file * Updated Change Log file --------- Co-authored-by: Michael Ginalick <michael.ginalick@gmail.com>
1 parent 7b02a2b commit 5c7aea5

File tree

7 files changed

+31
-16
lines changed

7 files changed

+31
-16
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Changelog
22

3+
## [1.1.2](https://github.com/contentstack/contentstack-utils-ruby/tree/v1.1.2) (2023-02-27)
4+
- Dependency gem updated (Activesupport gem)
5+
6+
## [1.1.1](https://github.com/contentstack/contentstack-utils-ruby/tree/v1.1.1) (2022-04-21)
7+
- Json RTE image, link and frame source url issue resolved
8+
39
## [1.1.0](https://github.com/contentstack/contentstack-utils-ruby/tree/v1.1.0) (2021-08-10)
410
- GQL Json rte to Html content support added
511

Gemfile.lock

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,37 +2,37 @@ PATH
22
remote: .
33
specs:
44
contentstack_utils (1.1.0)
5-
activesupport (>= 3.2, < 6.2)
5+
activesupport (>= 3.2, < 7.0.4)
66
nokogiri (~> 1.11, >= 1.11.0)
77

88
GEM
99
remote: https://rubygems.org/
1010
specs:
11-
activesupport (6.1.7)
11+
activesupport (6.1.7.2)
1212
concurrent-ruby (~> 1.0, >= 1.0.2)
1313
i18n (>= 1.6, < 2)
1414
minitest (>= 5.1)
1515
tzinfo (~> 2.0)
1616
zeitwerk (~> 2.3)
1717
addressable (2.8.1)
1818
public_suffix (>= 2.0.2, < 6.0)
19-
concurrent-ruby (1.1.10)
19+
concurrent-ruby (1.2.0)
2020
crack (0.4.5)
2121
rexml
2222
diff-lcs (1.5.0)
2323
docile (1.4.0)
2424
hashdiff (1.0.1)
2525
i18n (1.12.0)
2626
concurrent-ruby (~> 1.0)
27-
mini_portile2 (2.8.0)
28-
minitest (5.16.3)
29-
nokogiri (1.13.9)
27+
mini_portile2 (2.8.1)
28+
minitest (5.17.0)
29+
nokogiri (1.13.10)
3030
mini_portile2 (~> 2.8.0)
3131
racc (~> 1.4)
32-
nokogiri (1.13.9-x64-mingw32)
32+
nokogiri (1.13.10-x64-mingw32)
3333
racc (~> 1.4)
34-
public_suffix (5.0.0)
35-
racc (1.6.0)
34+
public_suffix (5.0.1)
35+
racc (1.6.2)
3636
rake (13.0.6)
3737
rexml (3.2.5)
3838
rspec (3.10.0)
@@ -54,7 +54,7 @@ GEM
5454
simplecov_json_formatter (~> 0.1)
5555
simplecov-html (0.12.3)
5656
simplecov_json_formatter (0.1.4)
57-
tzinfo (2.0.5)
57+
tzinfo (2.0.6)
5858
concurrent-ruby (~> 1.0)
5959
webmock (3.11.3)
6060
addressable (>= 2.3.6)
@@ -63,7 +63,7 @@ GEM
6363
webrick (1.7.0)
6464
yard (0.9.28)
6565
webrick (~> 1.7.0)
66-
zeitwerk (2.6.6)
66+
zeitwerk (2.6.7)
6767

6868
PLATFORMS
6969
ruby

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License (MIT)
22

3-
Copyright (c) 2012-2022 Contentstack. All Rights Reserved
3+
Copyright (c) 2012-2023 Contentstack. All Rights Reserved
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

contentstack_utils.gemspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ Gem::Specification.new do |s|
2121
s.test_files = s.files.grep(%r{^spec/})
2222
s.require_paths = ["lib"]
2323

24-
s.add_dependency 'activesupport', '>= 3.2', '< 6.2'
24+
s.add_dependency 'activesupport', '>= 3.2', '< 7.0.4'
2525
s.add_dependency 'nokogiri', '~> 1.11', '>= 1.11.0'
2626

2727
s.add_development_dependency 'rake', '~> 13.0.3'

lib/contentstack_utils/model/options.rb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,9 +105,11 @@ def render_node(node_type, node, inner_html)
105105
renderString = "<code>#{inner_html}</code>"
106106
when 'reference'
107107
renderString = ""
108+
when 'span'
109+
renderString = "<span>#{inner_html}</span>"
108110
end
109111
renderString
110112
end
111113
end
112114
end
113-
end
115+
end

lib/contentstack_utils/version.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
module ContentstackUtils
2-
VERSION = "1.1.0"
2+
VERSION = "1.1.2"
33
end

spec/lib/model/option_spec.rb

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -305,5 +305,12 @@ def getMetadata(itemType=nil, styleType=nil, linkText=nil)
305305
expect(result).to eq ""
306306
end
307307

308+
it 'Should return span string for span node type' do
309+
doc = getJson(BlankDocument)
310+
311+
result = subject.render_node('span', doc, linkText)
312+
expect(result).to eq "<span>#{linkText}</span>"
313+
end
314+
308315
end
309-
end
316+
end

0 commit comments

Comments
 (0)