diff --git a/index.html b/index.html index 0e71230b..fa8f7b04 100644 --- a/index.html +++ b/index.html @@ -1514,7 +1514,8 @@

Algorithm

for prefix, return the result of concatenating the IRI mapping associated with prefix and suffix. -
  • Return value as it is already an absolute IRI.
  • +
  • If value has the form of an absolute IRI, + return value.
  • If vocab is true, and @@ -5510,6 +5511,11 @@

    Changes since JSON-LD Community Group Final Report

    to ensure that @type members are always represented as an array. This also allows a term to be defined for @type, where the value MUST be a dictionary with @container set to @set.
  • +
  • Updated the IRI Expansion algorithm so that + if value contains a colon (:), but + prefix is not a term, to only return value + if it has the form of an absolute IRI, otherwise fall through to + the rest of the algorithm.
  • diff --git a/tests/expand-manifest.jsonld b/tests/expand-manifest.jsonld index 350aa160..c9cd3162 100644 --- a/tests/expand-manifest.jsonld +++ b/tests/expand-manifest.jsonld @@ -802,6 +802,13 @@ "input": "expand/0108-in.jsonld", "expect": "expand/0108-out.jsonld", "option": {"processingMode": "json-ld-1.1", "specVersion": "json-ld-1.1"} + }, { + "@id": "#t0109", + "@type": ["jld:PositiveEvaluationTest", "jld:ExpandTest"], + "name": "IRI expansion of fragments including ':'", + "purpose": "Do not treat as absolute IRIs values that look like compact IRIs if they're not absolute", + "input": "expand/0109-in.jsonld", + "expect": "expand/0109-out.jsonld" }, { "@id": "#tc001", "@type": ["jld:PositiveEvaluationTest", "jld:ExpandTest"], diff --git a/tests/expand/0109-in.jsonld b/tests/expand/0109-in.jsonld new file mode 100644 index 00000000..7fa22658 --- /dev/null +++ b/tests/expand/0109-in.jsonld @@ -0,0 +1,7 @@ +{ + "@context": { + "@base": "https://ex.org/", + "u": {"@id": "urn:u:", "@type": "@id"} + }, + "u": ["#Test", "#Test:2"] +} \ No newline at end of file diff --git a/tests/expand/0109-out.jsonld b/tests/expand/0109-out.jsonld new file mode 100644 index 00000000..3a632e05 --- /dev/null +++ b/tests/expand/0109-out.jsonld @@ -0,0 +1,6 @@ +[{ + "urn:u:": [ + {"@id": "https://ex.org/#Test"}, + {"@id": "https://ex.org/#Test:2"} + ] +}] \ No newline at end of file