@twin.org/standards-ld-contexts 0.0.3-next.6 → 0.0.3-next.7
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.
- package/dist/es/ldContexts.js +5 -1
- package/dist/es/ldContexts.js.map +1 -1
- package/docs/changelog.md +7 -0
- package/package.json +1 -1
package/dist/es/ldContexts.js
CHANGED
|
@@ -31,21 +31,25 @@ export const LD_CONTEXTS = {
|
|
|
31
31
|
// W3C DCAT
|
|
32
32
|
"http://www.w3.org/ns/dcat#": w3cDcat,
|
|
33
33
|
"https://www.w3.org/ns/dcat.jsonld": w3cDcat,
|
|
34
|
+
"http://www.w3.org/ns/dcat.jsonld": w3cDcat,
|
|
34
35
|
// W3C ODRL
|
|
35
36
|
"http://www.w3.org/ns/odrl.jsonld": w3cOdrl,
|
|
36
37
|
// W3C Activity Streams
|
|
37
38
|
"https://www.w3.org/ns/activitystreams#": w3cActivityStreams,
|
|
39
|
+
"https://www.w3.org/ns/activitystreams": w3cActivityStreams,
|
|
38
40
|
// W3C Credentials
|
|
39
41
|
"https://www.w3.org/ns/credentials/v2": w3cVc,
|
|
40
42
|
"https://w3id.org/security/suites/jws-2020/v1": w3IdJws,
|
|
41
43
|
// UN/CEFACT
|
|
42
44
|
"https://vocabulary.uncefact.org": unCefact,
|
|
45
|
+
"https://vocabulary.uncefact.org/unece-context.jsonld": unCefact,
|
|
46
|
+
"https://vocabulary.uncefact.org/unece-context-D23B.jsonld": unCefact,
|
|
43
47
|
// Dublin Core
|
|
44
48
|
"http://purl.org/dc/terms/": dcTerms,
|
|
45
49
|
"http://purl.org/dc/dcmitype/": dcmitype,
|
|
46
50
|
"https://schema.twindev.org/dublin-core/terms.jsonld": dcTerms,
|
|
47
51
|
"https://schema.twindev.org/dublin-core/dcmitype.jsonld": dcmitype,
|
|
48
|
-
//
|
|
52
|
+
// Data Space Protocol
|
|
49
53
|
"https://w3id.org/dspace/2024/1/context.json": dataspaceProtocol,
|
|
50
54
|
"https://w3id.org/dspace/2025/1/context.jsonld": dataspaceProtocol,
|
|
51
55
|
// Foaf
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ldContexts.js","sourceRoot":"","sources":["../../src/ldContexts.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,uCAAuC;AACvC,OAAO,EAAE,YAAY,EAAE,EAAE,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,iBAAiB,MAAM,sCAAsC,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AAC3F,OAAO,QAAQ,MAAM,wCAAwC,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AACpF,OAAO,OAAO,MAAM,qCAAqC,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AAChF,OAAO,IAAI,MAAM,wBAAwB,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AAChE,OAAO,SAAS,MAAM,iCAAiC,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AAC9E,OAAO,SAAS,MAAM,8BAA8B,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AAC3E,OAAO,QAAQ,MAAM,mCAAmC,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AAC/E,OAAO,kBAAkB,MAAM,wCAAwC,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AAC9F,OAAO,OAAO,MAAM,4BAA4B,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AACvE,OAAO,OAAO,MAAM,4BAA4B,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AACvE,OAAO,MAAM,MAAM,2BAA2B,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AACrE,OAAO,KAAK,MAAM,wCAAwC,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAC;AACjF,OAAO,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C,8CAA8C,EAAE,IAAI;IACpD,4BAA4B,EAAE,IAAI;IAElC,UAAU;IACV,qCAAqC,EAAE,MAAM;IAC7C,iDAAiD,EAAE,MAAM;IACzD,uCAAuC,EAAE,MAAM;CAC/C,CAAC;AAEF;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,6BAA6B;IAClD,KAAK,MAAM,GAAG,IAAI,WAAW,EAAE,CAAC;QAC/B,MAAM,eAAe,CAAC,gBAAgB,CAAC,GAAG,EAAE,WAAW,CAAC,GAAG,CAAC,CAAC,CAAC;IAC/D,CAAC;AACF,CAAC;AAED;;;GAGG;AACH,MAAM,CAAC,KAAK,UAAU,yBAAyB,CAAC,GAAW;IAC1D,IAAI,EAAE,CAAC,KAAK,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC;QAChC,MAAM,IAAI,YAAY,CAAC,WAAW,EAAE,SAAS,EAAE,EAAE,GAAG,EAAE,CAAC,CAAC;IACzD,CAAC;IACD,MAAM,eAAe,CAAC,gBAAgB,CAAC,GAAG,EAAE,WAAW,CAAC,GAAG,CAAC,CAAC,CAAC;AAC/D,CAAC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport { GeneralError, Is } from \"@twin.org/core\";\nimport { JsonLdProcessor } from \"@twin.org/data-json-ld\";\nimport dataspaceProtocol from \"./ldContexts/dataspace-protocol.json\" with { type: \"json\" };\nimport dcmitype from \"./ldContexts/dublin-core-dcmitype.json\" with { type: \"json\" };\nimport dcTerms from \"./ldContexts/dublin-core-terms.json\" with { type: \"json\" };\nimport foaf from \"./ldContexts/foaf.json\" with { type: \"json\" };\nimport gaiaX2411 from \"./ldContexts/gaia-x-v24.11.json\" with { type: \"json\" };\nimport schemaOrg from \"./ldContexts/schema.org.json\" with { type: \"json\" };\nimport unCefact from \"./ldContexts/un-cefact-vocab.json\" with { type: \"json\" };\nimport w3cActivityStreams from \"./ldContexts/w3c-activity-streams.json\" with { type: \"json\" };\nimport w3cDcat from \"./ldContexts/w3c-dcat.json\" with { type: \"json\" };\nimport w3cOdrl from \"./ldContexts/w3c-odrl.json\" with { type: \"json\" };\nimport w3cRdf from \"./ldContexts/w3c-rdf.json\" with { type: \"json\" };\nimport w3cVc from \"./ldContexts/w3c-vc-data-model-v2.json\" with { type: \"json\" };\nimport w3IdJws from \"./ldContexts/w3id-jws-2020-v1.json\" with { type: \"json\" };\n\n/**\n * Map of all the ld contexts by their URL.\n */\nexport const LD_CONTEXTS: { [id: string]: unknown } = {\n\t// schema.org\n\t\"https://schema.org\": schemaOrg,\n\t\"http://schema.org\": schemaOrg,\n\t\"https://schema.org/docs/jsonldcontext.jsonld\": schemaOrg,\n\n\t// Gaia-X\n\t\"https://w3id.org/gaia-x/2411\": gaiaX2411,\n\t\"https://w3id.org/gaia-x/2411#\": gaiaX2411,\n\n\t\"https://schema.twindev.org/gaia-x-loire/\": gaiaX2411,\n\t\"https://schema.twindev.org/gaia-x-loire/types.jsonld\": gaiaX2411,\n\n\t// W3C DCAT\n\t\"http://www.w3.org/ns/dcat#\": w3cDcat,\n\t\"https://www.w3.org/ns/dcat.jsonld\": w3cDcat,\n\t\"http://www.w3.org/ns/dcat.jsonld\": w3cDcat,\n\n\t// W3C ODRL\n\t\"http://www.w3.org/ns/odrl.jsonld\": w3cOdrl,\n\n\t// W3C Activity Streams\n\t\"https://www.w3.org/ns/activitystreams#\": w3cActivityStreams,\n\t\"https://www.w3.org/ns/activitystreams\": w3cActivityStreams,\n\n\t// W3C Credentials\n\t\"https://www.w3.org/ns/credentials/v2\": w3cVc,\n\t\"https://w3id.org/security/suites/jws-2020/v1\": w3IdJws,\n\n\t// UN/CEFACT\n\t\"https://vocabulary.uncefact.org\": unCefact,\n\t\"https://vocabulary.uncefact.org/unece-context.jsonld\": unCefact,\n\t\"https://vocabulary.uncefact.org/unece-context-D23B.jsonld\": unCefact,\n\n\t// Dublin Core\n\t\"http://purl.org/dc/terms/\": dcTerms,\n\t\"http://purl.org/dc/dcmitype/\": dcmitype,\n\t\"https://schema.twindev.org/dublin-core/terms.jsonld\": dcTerms,\n\t\"https://schema.twindev.org/dublin-core/dcmitype.jsonld\": dcmitype,\n\n\t// Data Space Protocol\n\t\"https://w3id.org/dspace/2024/1/context.json\": dataspaceProtocol,\n\t\"https://w3id.org/dspace/2025/1/context.jsonld\": dataspaceProtocol,\n\n\t// Foaf\n\t\"https://schema.twindev.org/foaf/\": foaf,\n\t\"https://schema.twindev.org/foaf/types.jsonld\": foaf,\n\t\"http://xmlns.com/foaf/0.1/\": foaf,\n\n\t// W3C RDF\n\t\"https://schema.twindev.org/w3c-rdf/\": w3cRdf,\n\t\"https://schema.twindev.org/w3c-rdf/types.jsonld\": w3cRdf,\n\t\"http://www.w3.org/2000/01/rdf-schema#\": w3cRdf\n};\n\n/**\n * Add all the contexts to the document cache.\n */\nexport async function addAllContextsToDocumentCache(): Promise<void> {\n\tfor (const url in LD_CONTEXTS) {\n\t\tawait JsonLdProcessor.documentCacheAdd(url, LD_CONTEXTS[url]);\n\t}\n}\n\n/**\n * Add a context to the document cache.\n * @param url The URL of the context to add to the cache.\n */\nexport async function addContextToDocumentCache(url: string): Promise<void> {\n\tif (Is.empty(LD_CONTEXTS[url])) {\n\t\tthrow new GeneralError(\"ldContext\", \"missing\", { url });\n\t}\n\tawait JsonLdProcessor.documentCacheAdd(url, LD_CONTEXTS[url]);\n}\n"]}
|
package/docs/changelog.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# @twin.org/standards-ld-contexts - Changelog
|
|
2
2
|
|
|
3
|
+
## [0.0.3-next.7](https://github.com/twinfoundation/standards/compare/standards-ld-contexts-v0.0.3-next.6...standards-ld-contexts-v0.0.3-next.7) (2026-01-06)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Bug Fixes
|
|
7
|
+
|
|
8
|
+
* refine local LD Contexts ([#84](https://github.com/twinfoundation/standards/issues/84)) ([785e359](https://github.com/twinfoundation/standards/commit/785e359ad6895fcb97197ca707915651fe3ae79c))
|
|
9
|
+
|
|
3
10
|
## [0.0.3-next.6](https://github.com/twinfoundation/standards/compare/standards-ld-contexts-v0.0.3-next.5...standards-ld-contexts-v0.0.3-next.6) (2025-12-03)
|
|
4
11
|
|
|
5
12
|
|