gretel-jsonld 0.3.0 → 0.3.1

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: 1e7bf55860ae8f21a3d5a931806e9c550cf4e1d31af9546703d86d125d14c00e
4
- data.tar.gz: 3286dab9d4dbcc9b9e61a7e4528359ada4e3cb63e59af75a40c765497d2e3c68
3
+ metadata.gz: c309e8f8e1f52c61386479f3def3a404d02dec42fa1376e50cf53efa2fe1e970
4
+ data.tar.gz: fbb12c4999cd45f56b2bb328b06026f5473cf86a484d9aba28918e392ff720f9
5
5
  SHA512:
6
- metadata.gz: 79b86b733f968da7bca93b29a9ca65486783bb814ebf396d3906ae7ca9646d3b952c36f65a26c99ba191d4edc954ce7af855999b51a320f46ce9d50d7472564c
7
- data.tar.gz: 16b507af8635110bece74b61f433cc401ae4bf2140414f0ab0ac3c73abb07c9eedc7cb7191b4988660c5d94b760f67c3f648c74cfcbe90530704ec1bafdae804
6
+ metadata.gz: 0f855cac532a19aa53147091fc9f2b3e22c262e64f75937cfbafe4d76614bb828e2ead55e9efff5732cf1ce045b05885136f20c57d64fa59fd938b718b3a7eb0
7
+ data.tar.gz: 9af48ed160ab9f896cdb9a2fdae9810e7d807d90d36cc414a08cd1986d03a38d183f4274f1f4bbd63c74819835d231fcf8f25f4f4d52a41e8c33bd6eeaccaed8
data/CHANGELOG.md CHANGED
@@ -1,15 +1,24 @@
1
1
  # CHANGELOG
2
+
3
+ ## [0.3.1](https://github.com/yasaichi/gretel-jsonld/releases/tag/v0.3.1) (August 4, 2026)
4
+
5
+ * [Prevent XSS in JSON-LD breadcrumb output](https://github.com/yasaichi/gretel-jsonld/pull/36)
6
+
2
7
  ## [0.3.0](https://github.com/yasaichi/gretel-jsonld/releases/tag/v0.3.0) (July 22, 2026)
8
+
3
9
  * [Test against Rails 6 through 8](https://github.com/yasaichi/gretel-jsonld/pull/18)
4
10
  * [Drop support for Ruby 2.4 and earlier](https://github.com/yasaichi/gretel-jsonld/pull/16)
5
11
 
6
12
  ## [0.2.0](https://github.com/yasaichi/gretel-jsonld/releases/tag/v0.2.0) (November 25, 2017)
13
+
7
14
  * [Write README](https://github.com/yasaichi/gretel-jsonld/pull/7)
8
15
  * [Use `JSONLD` as module name instead of `Jsonld`](https://github.com/yasaichi/gretel-jsonld/pull/6)
9
16
  * [Specify the required Ruby version](https://github.com/yasaichi/gretel-jsonld/pull/5)
10
17
 
11
18
  ## [0.1.1](https://github.com/yasaichi/gretel-jsonld/releases/tag/v0.1.1) (November 25, 2017)
19
+
12
20
  * [Cope with Rails 4.0 or former](https://github.com/yasaichi/gretel-jsonld/pull/4)
13
21
 
14
22
  ## [0.1.0](https://github.com/yasaichi/gretel-jsonld/releases/tag/v0.1.0) (November 23, 2017)
23
+
15
24
  * The initial release to reserve the gem name
@@ -17,7 +17,10 @@ module Gretel
17
17
 
18
18
  @view_context.content_tag(
19
19
  :script,
20
- JSON.generate(::Gretel::JSONLD::Breadcrumb::List.new(link_collection)).html_safe,
20
+ ::Gretel::JSONLD::Breadcrumb::List.new(link_collection)
21
+ .yield_self { |list| JSON.generate(list) }
22
+ .yield_self { |json| ::ERB::Util.json_escape(json) }
23
+ .html_safe,
21
24
  type: "application/ld+json",
22
25
  )
23
26
  end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Gretel
4
4
  module JSONLD
5
- VERSION = "0.3.0".freeze
5
+ VERSION = "0.3.1".freeze
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gretel-jsonld
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - yasaichi