@twin.org/immutable-proof-models 0.0.1-next.9 → 0.0.2-next.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.
- package/dist/cjs/index.cjs +60 -22
- package/dist/esm/index.mjs +59 -23
- package/dist/types/index.d.ts +4 -1
- package/dist/types/models/IImmutableProof.d.ts +17 -4
- package/dist/types/models/IImmutableProofComponent.d.ts +9 -10
- package/dist/types/models/IImmutableProofVerification.d.ts +2 -1
- package/dist/types/models/api/IImmutableProofCreateRequest.d.ts +2 -2
- package/dist/types/models/api/IImmutableProofVerifyRequest.d.ts +0 -10
- package/dist/types/models/eventBus/IImmutableProofEventBusProofCreated.d.ts +9 -0
- package/dist/types/models/immutableProofContexts.d.ts +17 -0
- package/dist/types/models/immutableProofFailure.d.ts +1 -1
- package/dist/types/models/immutableProofTopics.d.ts +13 -0
- package/dist/types/models/immutableProofTypes.d.ts +0 -4
- package/docs/changelog.md +60 -1
- package/docs/reference/classes/ImmutableProofDataTypes.md +3 -3
- package/docs/reference/index.md +5 -0
- package/docs/reference/interfaces/IImmutableProof.md +18 -2
- package/docs/reference/interfaces/IImmutableProofComponent.md +31 -21
- package/docs/reference/interfaces/IImmutableProofCreateRequest.md +3 -3
- package/docs/reference/interfaces/IImmutableProofEventBusProofCreated.md +11 -0
- package/docs/reference/interfaces/IImmutableProofVerifyRequest.md +0 -14
- package/docs/reference/type-aliases/ImmutableProofContexts.md +5 -0
- package/docs/reference/type-aliases/ImmutableProofFailure.md +1 -1
- package/docs/reference/type-aliases/ImmutableProofTopics.md +5 -0
- package/docs/reference/type-aliases/ImmutableProofTypes.md +1 -1
- package/docs/reference/variables/ImmutableProofContexts.md +19 -0
- package/docs/reference/variables/ImmutableProofFailure.md +1 -1
- package/docs/reference/variables/ImmutableProofTopics.md +13 -0
- package/docs/reference/variables/ImmutableProofTypes.md +0 -6
- package/package.json +3 -3
package/dist/cjs/index.cjs
CHANGED
|
@@ -5,14 +5,27 @@ var dataCore = require('@twin.org/data-core');
|
|
|
5
5
|
// Copyright 2024 IOTA Stiftung.
|
|
6
6
|
// SPDX-License-Identifier: Apache-2.0.
|
|
7
7
|
/**
|
|
8
|
-
* The
|
|
8
|
+
* The contexts of immutable proof data.
|
|
9
9
|
*/
|
|
10
10
|
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
11
|
-
const
|
|
11
|
+
const ImmutableProofContexts = {
|
|
12
12
|
/**
|
|
13
13
|
* The context root for the immutable proof types.
|
|
14
14
|
*/
|
|
15
15
|
ContextRoot: "https://schema.twindev.org/immutable-proof/",
|
|
16
|
+
/**
|
|
17
|
+
* The context root for the common types.
|
|
18
|
+
*/
|
|
19
|
+
ContextRootCommon: "https://schema.twindev.org/common/"
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
// Copyright 2024 IOTA Stiftung.
|
|
23
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
24
|
+
/**
|
|
25
|
+
* The types of immutable proof data.
|
|
26
|
+
*/
|
|
27
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
28
|
+
const ImmutableProofTypes = {
|
|
16
29
|
/**
|
|
17
30
|
* Represents Immutable Proof.
|
|
18
31
|
*/
|
|
@@ -23,29 +36,28 @@ const ImmutableProofTypes = {
|
|
|
23
36
|
ImmutableProofVerification: "ImmutableProofVerification"
|
|
24
37
|
};
|
|
25
38
|
|
|
39
|
+
var $schema = "https://json-schema.org/draft/2020-12/schema";
|
|
40
|
+
var $id = "https://schema.twindev.org/immutable-proof/ImmutableProof";
|
|
41
|
+
var description = "Interface describing an immutable proof state.";
|
|
26
42
|
var type = "object";
|
|
27
43
|
var properties = {
|
|
28
44
|
"@context": {
|
|
29
|
-
|
|
45
|
+
type: "array",
|
|
46
|
+
minItems: 2,
|
|
47
|
+
items: {
|
|
48
|
+
$ref: "https://schema.twindev.org/json-ld/JsonLdContextDefinitionElement"
|
|
49
|
+
},
|
|
50
|
+
description: "JSON-LD Context.",
|
|
51
|
+
prefixItems: [
|
|
30
52
|
{
|
|
31
53
|
type: "string",
|
|
32
54
|
"const": "https://schema.twindev.org/immutable-proof/"
|
|
33
55
|
},
|
|
34
56
|
{
|
|
35
|
-
type: "
|
|
36
|
-
|
|
37
|
-
items: [
|
|
38
|
-
{
|
|
39
|
-
type: "string",
|
|
40
|
-
"const": "https://schema.twindev.org/immutable-proof/"
|
|
41
|
-
}
|
|
42
|
-
],
|
|
43
|
-
additionalItems: {
|
|
44
|
-
type: "string"
|
|
45
|
-
}
|
|
57
|
+
type: "string",
|
|
58
|
+
"const": "https://schema.twindev.org/common/"
|
|
46
59
|
}
|
|
47
|
-
]
|
|
48
|
-
description: "JSON-LD Context."
|
|
60
|
+
]
|
|
49
61
|
},
|
|
50
62
|
type: {
|
|
51
63
|
type: "string",
|
|
@@ -56,6 +68,10 @@ var properties = {
|
|
|
56
68
|
type: "string",
|
|
57
69
|
description: "The id of the proof."
|
|
58
70
|
},
|
|
71
|
+
nodeIdentity: {
|
|
72
|
+
type: "string",
|
|
73
|
+
description: "The id of the node who created the proof."
|
|
74
|
+
},
|
|
59
75
|
userIdentity: {
|
|
60
76
|
type: "string",
|
|
61
77
|
description: "The id of the user who created the proof."
|
|
@@ -68,8 +84,12 @@ var properties = {
|
|
|
68
84
|
type: "string",
|
|
69
85
|
description: "The hash of the object associated with the proof."
|
|
70
86
|
},
|
|
87
|
+
verifiableStorageId: {
|
|
88
|
+
type: "string",
|
|
89
|
+
description: "The verifiable storage id for where the proof is stored."
|
|
90
|
+
},
|
|
71
91
|
proof: {
|
|
72
|
-
$ref: "https://schema.twindev.org/did/
|
|
92
|
+
$ref: "https://schema.twindev.org/w3c-did/DataIntegrityProof",
|
|
73
93
|
description: "The proof which can be undefined if it has not yet been issued."
|
|
74
94
|
},
|
|
75
95
|
immutableReceipt: {
|
|
@@ -81,17 +101,19 @@ var required = [
|
|
|
81
101
|
"@context",
|
|
82
102
|
"type",
|
|
83
103
|
"id",
|
|
104
|
+
"nodeIdentity",
|
|
84
105
|
"userIdentity",
|
|
85
106
|
"proofObjectHash"
|
|
86
107
|
];
|
|
87
108
|
var additionalProperties = false;
|
|
88
|
-
var description = "Interface describing an immutable proof state.";
|
|
89
109
|
var ImmutableProofSchema = {
|
|
110
|
+
$schema: $schema,
|
|
111
|
+
$id: $id,
|
|
112
|
+
description: description,
|
|
90
113
|
type: type,
|
|
91
114
|
properties: properties,
|
|
92
115
|
required: required,
|
|
93
|
-
additionalProperties: additionalProperties
|
|
94
|
-
description: description
|
|
116
|
+
additionalProperties: additionalProperties
|
|
95
117
|
};
|
|
96
118
|
|
|
97
119
|
// Copyright 2024 IOTA Stiftung.
|
|
@@ -104,7 +126,8 @@ class ImmutableProofDataTypes {
|
|
|
104
126
|
* Register all the data types.
|
|
105
127
|
*/
|
|
106
128
|
static registerTypes() {
|
|
107
|
-
dataCore.DataTypeHandlerFactory.register(ImmutableProofTypes.ImmutableProof
|
|
129
|
+
dataCore.DataTypeHandlerFactory.register(`${ImmutableProofContexts.ContextRoot}${ImmutableProofTypes.ImmutableProof}`, () => ({
|
|
130
|
+
context: ImmutableProofContexts.ContextRoot,
|
|
108
131
|
type: ImmutableProofTypes.ImmutableProof,
|
|
109
132
|
defaultValue: {},
|
|
110
133
|
jsonSchema: async () => ImmutableProofSchema
|
|
@@ -120,7 +143,7 @@ class ImmutableProofDataTypes {
|
|
|
120
143
|
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
121
144
|
const ImmutableProofFailure = {
|
|
122
145
|
/**
|
|
123
|
-
* Proof not
|
|
146
|
+
* Proof not yet issued.
|
|
124
147
|
*/
|
|
125
148
|
NotIssued: "notIssued",
|
|
126
149
|
/**
|
|
@@ -141,6 +164,21 @@ const ImmutableProofFailure = {
|
|
|
141
164
|
SignatureMismatch: "signatureMismatch"
|
|
142
165
|
};
|
|
143
166
|
|
|
167
|
+
// Copyright 2024 IOTA Stiftung.
|
|
168
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
169
|
+
/**
|
|
170
|
+
* The topics for immutable proof event bus notifications.
|
|
171
|
+
*/
|
|
172
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
173
|
+
const ImmutableProofTopics = {
|
|
174
|
+
/**
|
|
175
|
+
* A proof was created.
|
|
176
|
+
*/
|
|
177
|
+
ProofCreated: "immutable-proof:proof-created"
|
|
178
|
+
};
|
|
179
|
+
|
|
180
|
+
exports.ImmutableProofContexts = ImmutableProofContexts;
|
|
144
181
|
exports.ImmutableProofDataTypes = ImmutableProofDataTypes;
|
|
145
182
|
exports.ImmutableProofFailure = ImmutableProofFailure;
|
|
183
|
+
exports.ImmutableProofTopics = ImmutableProofTopics;
|
|
146
184
|
exports.ImmutableProofTypes = ImmutableProofTypes;
|
package/dist/esm/index.mjs
CHANGED
|
@@ -3,14 +3,27 @@ import { DataTypeHandlerFactory } from '@twin.org/data-core';
|
|
|
3
3
|
// Copyright 2024 IOTA Stiftung.
|
|
4
4
|
// SPDX-License-Identifier: Apache-2.0.
|
|
5
5
|
/**
|
|
6
|
-
* The
|
|
6
|
+
* The contexts of immutable proof data.
|
|
7
7
|
*/
|
|
8
8
|
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
9
|
-
const
|
|
9
|
+
const ImmutableProofContexts = {
|
|
10
10
|
/**
|
|
11
11
|
* The context root for the immutable proof types.
|
|
12
12
|
*/
|
|
13
13
|
ContextRoot: "https://schema.twindev.org/immutable-proof/",
|
|
14
|
+
/**
|
|
15
|
+
* The context root for the common types.
|
|
16
|
+
*/
|
|
17
|
+
ContextRootCommon: "https://schema.twindev.org/common/"
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
// Copyright 2024 IOTA Stiftung.
|
|
21
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
22
|
+
/**
|
|
23
|
+
* The types of immutable proof data.
|
|
24
|
+
*/
|
|
25
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
26
|
+
const ImmutableProofTypes = {
|
|
14
27
|
/**
|
|
15
28
|
* Represents Immutable Proof.
|
|
16
29
|
*/
|
|
@@ -21,29 +34,28 @@ const ImmutableProofTypes = {
|
|
|
21
34
|
ImmutableProofVerification: "ImmutableProofVerification"
|
|
22
35
|
};
|
|
23
36
|
|
|
37
|
+
var $schema = "https://json-schema.org/draft/2020-12/schema";
|
|
38
|
+
var $id = "https://schema.twindev.org/immutable-proof/ImmutableProof";
|
|
39
|
+
var description = "Interface describing an immutable proof state.";
|
|
24
40
|
var type = "object";
|
|
25
41
|
var properties = {
|
|
26
42
|
"@context": {
|
|
27
|
-
|
|
43
|
+
type: "array",
|
|
44
|
+
minItems: 2,
|
|
45
|
+
items: {
|
|
46
|
+
$ref: "https://schema.twindev.org/json-ld/JsonLdContextDefinitionElement"
|
|
47
|
+
},
|
|
48
|
+
description: "JSON-LD Context.",
|
|
49
|
+
prefixItems: [
|
|
28
50
|
{
|
|
29
51
|
type: "string",
|
|
30
52
|
"const": "https://schema.twindev.org/immutable-proof/"
|
|
31
53
|
},
|
|
32
54
|
{
|
|
33
|
-
type: "
|
|
34
|
-
|
|
35
|
-
items: [
|
|
36
|
-
{
|
|
37
|
-
type: "string",
|
|
38
|
-
"const": "https://schema.twindev.org/immutable-proof/"
|
|
39
|
-
}
|
|
40
|
-
],
|
|
41
|
-
additionalItems: {
|
|
42
|
-
type: "string"
|
|
43
|
-
}
|
|
55
|
+
type: "string",
|
|
56
|
+
"const": "https://schema.twindev.org/common/"
|
|
44
57
|
}
|
|
45
|
-
]
|
|
46
|
-
description: "JSON-LD Context."
|
|
58
|
+
]
|
|
47
59
|
},
|
|
48
60
|
type: {
|
|
49
61
|
type: "string",
|
|
@@ -54,6 +66,10 @@ var properties = {
|
|
|
54
66
|
type: "string",
|
|
55
67
|
description: "The id of the proof."
|
|
56
68
|
},
|
|
69
|
+
nodeIdentity: {
|
|
70
|
+
type: "string",
|
|
71
|
+
description: "The id of the node who created the proof."
|
|
72
|
+
},
|
|
57
73
|
userIdentity: {
|
|
58
74
|
type: "string",
|
|
59
75
|
description: "The id of the user who created the proof."
|
|
@@ -66,8 +82,12 @@ var properties = {
|
|
|
66
82
|
type: "string",
|
|
67
83
|
description: "The hash of the object associated with the proof."
|
|
68
84
|
},
|
|
85
|
+
verifiableStorageId: {
|
|
86
|
+
type: "string",
|
|
87
|
+
description: "The verifiable storage id for where the proof is stored."
|
|
88
|
+
},
|
|
69
89
|
proof: {
|
|
70
|
-
$ref: "https://schema.twindev.org/did/
|
|
90
|
+
$ref: "https://schema.twindev.org/w3c-did/DataIntegrityProof",
|
|
71
91
|
description: "The proof which can be undefined if it has not yet been issued."
|
|
72
92
|
},
|
|
73
93
|
immutableReceipt: {
|
|
@@ -79,17 +99,19 @@ var required = [
|
|
|
79
99
|
"@context",
|
|
80
100
|
"type",
|
|
81
101
|
"id",
|
|
102
|
+
"nodeIdentity",
|
|
82
103
|
"userIdentity",
|
|
83
104
|
"proofObjectHash"
|
|
84
105
|
];
|
|
85
106
|
var additionalProperties = false;
|
|
86
|
-
var description = "Interface describing an immutable proof state.";
|
|
87
107
|
var ImmutableProofSchema = {
|
|
108
|
+
$schema: $schema,
|
|
109
|
+
$id: $id,
|
|
110
|
+
description: description,
|
|
88
111
|
type: type,
|
|
89
112
|
properties: properties,
|
|
90
113
|
required: required,
|
|
91
|
-
additionalProperties: additionalProperties
|
|
92
|
-
description: description
|
|
114
|
+
additionalProperties: additionalProperties
|
|
93
115
|
};
|
|
94
116
|
|
|
95
117
|
// Copyright 2024 IOTA Stiftung.
|
|
@@ -102,7 +124,8 @@ class ImmutableProofDataTypes {
|
|
|
102
124
|
* Register all the data types.
|
|
103
125
|
*/
|
|
104
126
|
static registerTypes() {
|
|
105
|
-
DataTypeHandlerFactory.register(ImmutableProofTypes.ImmutableProof
|
|
127
|
+
DataTypeHandlerFactory.register(`${ImmutableProofContexts.ContextRoot}${ImmutableProofTypes.ImmutableProof}`, () => ({
|
|
128
|
+
context: ImmutableProofContexts.ContextRoot,
|
|
106
129
|
type: ImmutableProofTypes.ImmutableProof,
|
|
107
130
|
defaultValue: {},
|
|
108
131
|
jsonSchema: async () => ImmutableProofSchema
|
|
@@ -118,7 +141,7 @@ class ImmutableProofDataTypes {
|
|
|
118
141
|
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
119
142
|
const ImmutableProofFailure = {
|
|
120
143
|
/**
|
|
121
|
-
* Proof not
|
|
144
|
+
* Proof not yet issued.
|
|
122
145
|
*/
|
|
123
146
|
NotIssued: "notIssued",
|
|
124
147
|
/**
|
|
@@ -139,4 +162,17 @@ const ImmutableProofFailure = {
|
|
|
139
162
|
SignatureMismatch: "signatureMismatch"
|
|
140
163
|
};
|
|
141
164
|
|
|
142
|
-
|
|
165
|
+
// Copyright 2024 IOTA Stiftung.
|
|
166
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
167
|
+
/**
|
|
168
|
+
* The topics for immutable proof event bus notifications.
|
|
169
|
+
*/
|
|
170
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
171
|
+
const ImmutableProofTopics = {
|
|
172
|
+
/**
|
|
173
|
+
* A proof was created.
|
|
174
|
+
*/
|
|
175
|
+
ProofCreated: "immutable-proof:proof-created"
|
|
176
|
+
};
|
|
177
|
+
|
|
178
|
+
export { ImmutableProofContexts, ImmutableProofDataTypes, ImmutableProofFailure, ImmutableProofTopics, ImmutableProofTypes };
|
package/dist/types/index.d.ts
CHANGED
|
@@ -4,8 +4,11 @@ export * from "./models/api/IImmutableProofGetRequest";
|
|
|
4
4
|
export * from "./models/api/IImmutableProofGetResponse";
|
|
5
5
|
export * from "./models/api/IImmutableProofVerifyRequest";
|
|
6
6
|
export * from "./models/api/IImmutableProofVerifyResponse";
|
|
7
|
+
export * from "./models/eventBus/IImmutableProofEventBusProofCreated";
|
|
7
8
|
export * from "./models/IImmutableProof";
|
|
8
|
-
export * from "./models/IImmutableProofVerification";
|
|
9
9
|
export * from "./models/IImmutableProofComponent";
|
|
10
|
+
export * from "./models/IImmutableProofVerification";
|
|
11
|
+
export * from "./models/immutableProofContexts";
|
|
10
12
|
export * from "./models/immutableProofFailure";
|
|
13
|
+
export * from "./models/immutableProofTopics";
|
|
11
14
|
export * from "./models/immutableProofTypes";
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import type { IJsonLdNodeObject } from "@twin.org/data-json-ld";
|
|
2
|
-
import type {
|
|
1
|
+
import type { IJsonLdContextDefinitionElement, IJsonLdNodeObject } from "@twin.org/data-json-ld";
|
|
2
|
+
import type { IDataIntegrityProof } from "@twin.org/standards-w3c-did";
|
|
3
|
+
import type { ImmutableProofContexts } from "./immutableProofContexts";
|
|
3
4
|
import type { ImmutableProofTypes } from "./immutableProofTypes";
|
|
4
5
|
/**
|
|
5
6
|
* Interface describing an immutable proof state.
|
|
@@ -8,7 +9,11 @@ export interface IImmutableProof {
|
|
|
8
9
|
/**
|
|
9
10
|
* JSON-LD Context.
|
|
10
11
|
*/
|
|
11
|
-
"@context":
|
|
12
|
+
"@context": [
|
|
13
|
+
typeof ImmutableProofContexts.ContextRoot,
|
|
14
|
+
typeof ImmutableProofContexts.ContextRootCommon,
|
|
15
|
+
...IJsonLdContextDefinitionElement[]
|
|
16
|
+
];
|
|
12
17
|
/**
|
|
13
18
|
* JSON-LD Type.
|
|
14
19
|
*/
|
|
@@ -17,6 +22,10 @@ export interface IImmutableProof {
|
|
|
17
22
|
* The id of the proof.
|
|
18
23
|
*/
|
|
19
24
|
id: string;
|
|
25
|
+
/**
|
|
26
|
+
* The id of the node who created the proof.
|
|
27
|
+
*/
|
|
28
|
+
nodeIdentity: string;
|
|
20
29
|
/**
|
|
21
30
|
* The id of the user who created the proof.
|
|
22
31
|
*/
|
|
@@ -29,10 +38,14 @@ export interface IImmutableProof {
|
|
|
29
38
|
* The hash of the object associated with the proof.
|
|
30
39
|
*/
|
|
31
40
|
proofObjectHash: string;
|
|
41
|
+
/**
|
|
42
|
+
* The verifiable storage id for where the proof is stored.
|
|
43
|
+
*/
|
|
44
|
+
verifiableStorageId?: string;
|
|
32
45
|
/**
|
|
33
46
|
* The proof which can be undefined if it has not yet been issued.
|
|
34
47
|
*/
|
|
35
|
-
proof?:
|
|
48
|
+
proof?: IDataIntegrityProof;
|
|
36
49
|
/**
|
|
37
50
|
* The immutable receipt detail for where the proof is stored.
|
|
38
51
|
*/
|
|
@@ -7,34 +7,33 @@ import type { IImmutableProofVerification } from "./IImmutableProofVerification"
|
|
|
7
7
|
*/
|
|
8
8
|
export interface IImmutableProofComponent extends IComponent {
|
|
9
9
|
/**
|
|
10
|
-
* Create a new
|
|
11
|
-
* @param
|
|
10
|
+
* Create a new proof.
|
|
11
|
+
* @param document The document to create the proof for.
|
|
12
12
|
* @param userIdentity The identity to create the immutable proof operation with.
|
|
13
13
|
* @param nodeIdentity The node identity to use for vault operations.
|
|
14
|
-
* @returns The id of the new
|
|
14
|
+
* @returns The id of the new proof.
|
|
15
15
|
*/
|
|
16
|
-
create(
|
|
16
|
+
create(document: IJsonLdNodeObject, userIdentity?: string, nodeIdentity?: string): Promise<string>;
|
|
17
17
|
/**
|
|
18
|
-
* Get
|
|
18
|
+
* Get a proof.
|
|
19
19
|
* @param id The id of the proof to get.
|
|
20
20
|
* @returns The proof.
|
|
21
21
|
* @throws NotFoundError if the proof is not found.
|
|
22
22
|
*/
|
|
23
23
|
get(id: string): Promise<IImmutableProof>;
|
|
24
24
|
/**
|
|
25
|
-
* Verify
|
|
25
|
+
* Verify a proof.
|
|
26
26
|
* @param id The id of the proof to verify.
|
|
27
|
-
* @param proofObject The object to verify as JSON-LD.
|
|
28
27
|
* @returns The result of the verification and any failures.
|
|
29
28
|
* @throws NotFoundError if the proof is not found.
|
|
30
29
|
*/
|
|
31
|
-
verify(id: string
|
|
30
|
+
verify(id: string): Promise<IImmutableProofVerification>;
|
|
32
31
|
/**
|
|
33
|
-
* Remove the
|
|
32
|
+
* Remove the verifiable storage for the proof.
|
|
34
33
|
* @param id The id of the proof to remove the storage from.
|
|
35
34
|
* @param nodeIdentity The node identity to use for vault operations.
|
|
36
35
|
* @returns Nothing.
|
|
37
36
|
* @throws NotFoundError if the proof is not found.
|
|
38
37
|
*/
|
|
39
|
-
|
|
38
|
+
removeVerifiable(id: string, nodeIdentity?: string): Promise<void>;
|
|
40
39
|
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { ImmutableProofContexts } from "./immutableProofContexts";
|
|
1
2
|
import type { ImmutableProofFailure } from "./immutableProofFailure";
|
|
2
3
|
import type { ImmutableProofTypes } from "./immutableProofTypes";
|
|
3
4
|
/**
|
|
@@ -7,7 +8,7 @@ export interface IImmutableProofVerification {
|
|
|
7
8
|
/**
|
|
8
9
|
* JSON-LD Context.
|
|
9
10
|
*/
|
|
10
|
-
"@context": typeof
|
|
11
|
+
"@context": typeof ImmutableProofContexts.ContextRoot;
|
|
11
12
|
/**
|
|
12
13
|
* JSON-LD Type.
|
|
13
14
|
*/
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import type { IJsonLdNodeObject } from "@twin.org/data-json-ld";
|
|
2
1
|
import type { HeaderTypes, MimeTypes } from "@twin.org/web";
|
|
3
2
|
/**
|
|
4
3
|
* Verify a proof.
|
|
@@ -19,13 +18,4 @@ export interface IImmutableProofVerifyRequest {
|
|
|
19
18
|
*/
|
|
20
19
|
id: string;
|
|
21
20
|
};
|
|
22
|
-
/**
|
|
23
|
-
* The parameters from the body.
|
|
24
|
-
*/
|
|
25
|
-
body: {
|
|
26
|
-
/**
|
|
27
|
-
* The proof object to verify.
|
|
28
|
-
*/
|
|
29
|
-
proofObject: IJsonLdNodeObject;
|
|
30
|
-
};
|
|
31
21
|
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The contexts of immutable proof data.
|
|
3
|
+
*/
|
|
4
|
+
export declare const ImmutableProofContexts: {
|
|
5
|
+
/**
|
|
6
|
+
* The context root for the immutable proof types.
|
|
7
|
+
*/
|
|
8
|
+
readonly ContextRoot: "https://schema.twindev.org/immutable-proof/";
|
|
9
|
+
/**
|
|
10
|
+
* The context root for the common types.
|
|
11
|
+
*/
|
|
12
|
+
readonly ContextRootCommon: "https://schema.twindev.org/common/";
|
|
13
|
+
};
|
|
14
|
+
/**
|
|
15
|
+
* The contexts of immutable proof data.
|
|
16
|
+
*/
|
|
17
|
+
export type ImmutableProofContexts = (typeof ImmutableProofContexts)[keyof typeof ImmutableProofContexts];
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The topics for immutable proof event bus notifications.
|
|
3
|
+
*/
|
|
4
|
+
export declare const ImmutableProofTopics: {
|
|
5
|
+
/**
|
|
6
|
+
* A proof was created.
|
|
7
|
+
*/
|
|
8
|
+
readonly ProofCreated: "immutable-proof:proof-created";
|
|
9
|
+
};
|
|
10
|
+
/**
|
|
11
|
+
* The topics for immutable proof event bus notifications.
|
|
12
|
+
*/
|
|
13
|
+
export type ImmutableProofTopics = (typeof ImmutableProofTopics)[keyof typeof ImmutableProofTopics];
|
|
@@ -2,10 +2,6 @@
|
|
|
2
2
|
* The types of immutable proof data.
|
|
3
3
|
*/
|
|
4
4
|
export declare const ImmutableProofTypes: {
|
|
5
|
-
/**
|
|
6
|
-
* The context root for the immutable proof types.
|
|
7
|
-
*/
|
|
8
|
-
readonly ContextRoot: "https://schema.twindev.org/immutable-proof/";
|
|
9
5
|
/**
|
|
10
6
|
* Represents Immutable Proof.
|
|
11
7
|
*/
|
package/docs/changelog.md
CHANGED
|
@@ -1,5 +1,64 @@
|
|
|
1
1
|
# @twin.org/immutable-proof-models - Changelog
|
|
2
2
|
|
|
3
|
-
##
|
|
3
|
+
## [0.0.2-next.1](https://github.com/twinfoundation/immutable-proof/compare/immutable-proof-models-v0.0.2-next.0...immutable-proof-models-v0.0.2-next.1) (2025-08-20)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* update data types to use fully qualified names ([e94d0f5](https://github.com/twinfoundation/immutable-proof/commit/e94d0f5db93856b5b59cfd34e55252fa13a7f4e0))
|
|
9
|
+
* update dependencies ([7d6b321](https://github.com/twinfoundation/immutable-proof/commit/7d6b321928ca0434ee530816b1440f1687b94a6e))
|
|
10
|
+
* update framework core ([e708d4d](https://github.com/twinfoundation/immutable-proof/commit/e708d4dd3febcfbcd64663d5be004eab1d26c0fb))
|
|
11
|
+
* update ts-to-schema generation ([c4fc864](https://github.com/twinfoundation/immutable-proof/commit/c4fc8646e7b8ee040d356f7f0f3b2d6f4ac63e40))
|
|
12
|
+
* update twindev schemas ([d2bb94b](https://github.com/twinfoundation/immutable-proof/commit/d2bb94b31e61f899e41dbca1b1aeb2b3bb70b229))
|
|
13
|
+
* use shared store mechanism ([#3](https://github.com/twinfoundation/immutable-proof/issues/3)) ([7042a40](https://github.com/twinfoundation/immutable-proof/commit/7042a40f0ef8b01463f07aeb1efae4f417162fa1))
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
### Bug Fixes
|
|
17
|
+
|
|
18
|
+
* Missing user and node identity on create ([#1](https://github.com/twinfoundation/immutable-proof/issues/1)) ([80ea2f9](https://github.com/twinfoundation/immutable-proof/commit/80ea2f901afc7531f4a522227a61e6fa1482484d))
|
|
19
|
+
|
|
20
|
+
## 0.0.1 (2025-07-09)
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
### Features
|
|
24
|
+
|
|
25
|
+
* release to production ([cb7ecff](https://github.com/twinfoundation/immutable-proof/commit/cb7ecff3e9a1ec8b4391d7efea4a58057b8b66c6))
|
|
26
|
+
|
|
27
|
+
## [0.0.1-next.35](https://github.com/twinfoundation/immutable-proof/compare/immutable-proof-models-v0.0.1-next.34...immutable-proof-models-v0.0.1-next.35) (2025-06-12)
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
### Features
|
|
31
|
+
|
|
32
|
+
* update dependencies ([7d6b321](https://github.com/twinfoundation/immutable-proof/commit/7d6b321928ca0434ee530816b1440f1687b94a6e))
|
|
33
|
+
|
|
34
|
+
## [0.0.1-next.34](https://github.com/twinfoundation/immutable-proof/compare/immutable-proof-models-v0.0.1-next.33...immutable-proof-models-v0.0.1-next.34) (2025-06-03)
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
### Features
|
|
38
|
+
|
|
39
|
+
* update ts-to-schema generation ([c4fc864](https://github.com/twinfoundation/immutable-proof/commit/c4fc8646e7b8ee040d356f7f0f3b2d6f4ac63e40))
|
|
40
|
+
|
|
41
|
+
## [0.0.1-next.33](https://github.com/twinfoundation/immutable-proof/compare/immutable-proof-models-v0.0.1-next.32...immutable-proof-models-v0.0.1-next.33) (2025-05-28)
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
### Features
|
|
45
|
+
|
|
46
|
+
* update data types to use fully qualified names ([e94d0f5](https://github.com/twinfoundation/immutable-proof/commit/e94d0f5db93856b5b59cfd34e55252fa13a7f4e0))
|
|
47
|
+
|
|
48
|
+
## [0.0.1-next.32](https://github.com/twinfoundation/immutable-proof/compare/immutable-proof-models-v0.0.1-next.31...immutable-proof-models-v0.0.1-next.32) (2025-04-17)
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
### Features
|
|
52
|
+
|
|
53
|
+
* use shared store mechanism ([#3](https://github.com/twinfoundation/immutable-proof/issues/3)) ([7042a40](https://github.com/twinfoundation/immutable-proof/commit/7042a40f0ef8b01463f07aeb1efae4f417162fa1))
|
|
54
|
+
|
|
55
|
+
## [0.0.1-next.31](https://github.com/twinfoundation/immutable-proof/compare/immutable-proof-models-v0.0.1-next.30...immutable-proof-models-v0.0.1-next.31) (2025-03-28)
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
### Bug Fixes
|
|
59
|
+
|
|
60
|
+
* Missing user and node identity on create ([#1](https://github.com/twinfoundation/immutable-proof/issues/1)) ([80ea2f9](https://github.com/twinfoundation/immutable-proof/commit/80ea2f901afc7531f4a522227a61e6fa1482484d))
|
|
61
|
+
|
|
62
|
+
## v0.0.1-next.30
|
|
4
63
|
|
|
5
64
|
- Initial Release
|
|
@@ -4,13 +4,13 @@ Handle all the data types for immutable proof.
|
|
|
4
4
|
|
|
5
5
|
## Constructors
|
|
6
6
|
|
|
7
|
-
###
|
|
7
|
+
### Constructor
|
|
8
8
|
|
|
9
|
-
> **new ImmutableProofDataTypes**():
|
|
9
|
+
> **new ImmutableProofDataTypes**(): `ImmutableProofDataTypes`
|
|
10
10
|
|
|
11
11
|
#### Returns
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
`ImmutableProofDataTypes`
|
|
14
14
|
|
|
15
15
|
## Methods
|
|
16
16
|
|
package/docs/reference/index.md
CHANGED
|
@@ -14,13 +14,18 @@
|
|
|
14
14
|
- [IImmutableProofGetResponse](interfaces/IImmutableProofGetResponse.md)
|
|
15
15
|
- [IImmutableProofVerifyRequest](interfaces/IImmutableProofVerifyRequest.md)
|
|
16
16
|
- [IImmutableProofVerifyResponse](interfaces/IImmutableProofVerifyResponse.md)
|
|
17
|
+
- [IImmutableProofEventBusProofCreated](interfaces/IImmutableProofEventBusProofCreated.md)
|
|
17
18
|
|
|
18
19
|
## Type Aliases
|
|
19
20
|
|
|
21
|
+
- [ImmutableProofContexts](type-aliases/ImmutableProofContexts.md)
|
|
20
22
|
- [ImmutableProofFailure](type-aliases/ImmutableProofFailure.md)
|
|
23
|
+
- [ImmutableProofTopics](type-aliases/ImmutableProofTopics.md)
|
|
21
24
|
- [ImmutableProofTypes](type-aliases/ImmutableProofTypes.md)
|
|
22
25
|
|
|
23
26
|
## Variables
|
|
24
27
|
|
|
28
|
+
- [ImmutableProofContexts](variables/ImmutableProofContexts.md)
|
|
25
29
|
- [ImmutableProofFailure](variables/ImmutableProofFailure.md)
|
|
30
|
+
- [ImmutableProofTopics](variables/ImmutableProofTopics.md)
|
|
26
31
|
- [ImmutableProofTypes](variables/ImmutableProofTypes.md)
|
|
@@ -6,7 +6,7 @@ Interface describing an immutable proof state.
|
|
|
6
6
|
|
|
7
7
|
### @context
|
|
8
8
|
|
|
9
|
-
> **@context**: `"https://schema.twindev.org/immutable-proof/"
|
|
9
|
+
> **@context**: \[`"https://schema.twindev.org/immutable-proof/"`, `"https://schema.twindev.org/common/"`, `...IJsonLdContextDefinitionElement[]`\]
|
|
10
10
|
|
|
11
11
|
JSON-LD Context.
|
|
12
12
|
|
|
@@ -28,6 +28,14 @@ The id of the proof.
|
|
|
28
28
|
|
|
29
29
|
***
|
|
30
30
|
|
|
31
|
+
### nodeIdentity
|
|
32
|
+
|
|
33
|
+
> **nodeIdentity**: `string`
|
|
34
|
+
|
|
35
|
+
The id of the node who created the proof.
|
|
36
|
+
|
|
37
|
+
***
|
|
38
|
+
|
|
31
39
|
### userIdentity
|
|
32
40
|
|
|
33
41
|
> **userIdentity**: `string`
|
|
@@ -52,9 +60,17 @@ The hash of the object associated with the proof.
|
|
|
52
60
|
|
|
53
61
|
***
|
|
54
62
|
|
|
63
|
+
### verifiableStorageId?
|
|
64
|
+
|
|
65
|
+
> `optional` **verifiableStorageId**: `string`
|
|
66
|
+
|
|
67
|
+
The verifiable storage id for where the proof is stored.
|
|
68
|
+
|
|
69
|
+
***
|
|
70
|
+
|
|
55
71
|
### proof?
|
|
56
72
|
|
|
57
|
-
> `optional` **proof**: `
|
|
73
|
+
> `optional` **proof**: `IDataIntegrityProof`
|
|
58
74
|
|
|
59
75
|
The proof which can be undefined if it has not yet been issued.
|
|
60
76
|
|
|
@@ -10,21 +10,27 @@ Interface describing an immutable proof contract.
|
|
|
10
10
|
|
|
11
11
|
### create()
|
|
12
12
|
|
|
13
|
-
> **create**(`
|
|
13
|
+
> **create**(`document`, `userIdentity?`, `nodeIdentity?`): `Promise`\<`string`\>
|
|
14
14
|
|
|
15
|
-
Create a new
|
|
15
|
+
Create a new proof.
|
|
16
16
|
|
|
17
17
|
#### Parameters
|
|
18
18
|
|
|
19
|
-
|
|
19
|
+
##### document
|
|
20
20
|
|
|
21
|
-
|
|
21
|
+
`IJsonLdNodeObject`
|
|
22
22
|
|
|
23
|
-
|
|
23
|
+
The document to create the proof for.
|
|
24
|
+
|
|
25
|
+
##### userIdentity?
|
|
26
|
+
|
|
27
|
+
`string`
|
|
24
28
|
|
|
25
29
|
The identity to create the immutable proof operation with.
|
|
26
30
|
|
|
27
|
-
|
|
31
|
+
##### nodeIdentity?
|
|
32
|
+
|
|
33
|
+
`string`
|
|
28
34
|
|
|
29
35
|
The node identity to use for vault operations.
|
|
30
36
|
|
|
@@ -32,7 +38,7 @@ The node identity to use for vault operations.
|
|
|
32
38
|
|
|
33
39
|
`Promise`\<`string`\>
|
|
34
40
|
|
|
35
|
-
The id of the new
|
|
41
|
+
The id of the new proof.
|
|
36
42
|
|
|
37
43
|
***
|
|
38
44
|
|
|
@@ -40,11 +46,13 @@ The id of the new authentication proof.
|
|
|
40
46
|
|
|
41
47
|
> **get**(`id`): `Promise`\<[`IImmutableProof`](IImmutableProof.md)\>
|
|
42
48
|
|
|
43
|
-
Get
|
|
49
|
+
Get a proof.
|
|
44
50
|
|
|
45
51
|
#### Parameters
|
|
46
52
|
|
|
47
|
-
|
|
53
|
+
##### id
|
|
54
|
+
|
|
55
|
+
`string`
|
|
48
56
|
|
|
49
57
|
The id of the proof to get.
|
|
50
58
|
|
|
@@ -62,19 +70,17 @@ NotFoundError if the proof is not found.
|
|
|
62
70
|
|
|
63
71
|
### verify()
|
|
64
72
|
|
|
65
|
-
> **verify**(`id
|
|
73
|
+
> **verify**(`id`): `Promise`\<[`IImmutableProofVerification`](IImmutableProofVerification.md)\>
|
|
66
74
|
|
|
67
|
-
Verify
|
|
75
|
+
Verify a proof.
|
|
68
76
|
|
|
69
77
|
#### Parameters
|
|
70
78
|
|
|
71
|
-
|
|
79
|
+
##### id
|
|
72
80
|
|
|
73
|
-
|
|
81
|
+
`string`
|
|
74
82
|
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
The object to verify as JSON-LD.
|
|
83
|
+
The id of the proof to verify.
|
|
78
84
|
|
|
79
85
|
#### Returns
|
|
80
86
|
|
|
@@ -88,19 +94,23 @@ NotFoundError if the proof is not found.
|
|
|
88
94
|
|
|
89
95
|
***
|
|
90
96
|
|
|
91
|
-
###
|
|
97
|
+
### removeVerifiable()
|
|
92
98
|
|
|
93
|
-
> **
|
|
99
|
+
> **removeVerifiable**(`id`, `nodeIdentity?`): `Promise`\<`void`\>
|
|
94
100
|
|
|
95
|
-
Remove the
|
|
101
|
+
Remove the verifiable storage for the proof.
|
|
96
102
|
|
|
97
103
|
#### Parameters
|
|
98
104
|
|
|
99
|
-
|
|
105
|
+
##### id
|
|
106
|
+
|
|
107
|
+
`string`
|
|
100
108
|
|
|
101
109
|
The id of the proof to remove the storage from.
|
|
102
110
|
|
|
103
|
-
|
|
111
|
+
##### nodeIdentity?
|
|
112
|
+
|
|
113
|
+
`string`
|
|
104
114
|
|
|
105
115
|
The node identity to use for vault operations.
|
|
106
116
|
|
|
@@ -10,8 +10,8 @@ Create a proof.
|
|
|
10
10
|
|
|
11
11
|
The parameters from the body.
|
|
12
12
|
|
|
13
|
-
####
|
|
13
|
+
#### document
|
|
14
14
|
|
|
15
|
-
> **
|
|
15
|
+
> **document**: `IJsonLdNodeObject`
|
|
16
16
|
|
|
17
|
-
The
|
|
17
|
+
The document to create the proof for.
|
|
@@ -27,17 +27,3 @@ The parameters from the path.
|
|
|
27
27
|
> **id**: `string`
|
|
28
28
|
|
|
29
29
|
The id of the immutable proof to verify.
|
|
30
|
-
|
|
31
|
-
***
|
|
32
|
-
|
|
33
|
-
### body
|
|
34
|
-
|
|
35
|
-
> **body**: `object`
|
|
36
|
-
|
|
37
|
-
The parameters from the body.
|
|
38
|
-
|
|
39
|
-
#### proofObject
|
|
40
|
-
|
|
41
|
-
> **proofObject**: `IJsonLdNodeObject`
|
|
42
|
-
|
|
43
|
-
The proof object to verify.
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
# Type Alias: ImmutableProofContexts
|
|
2
|
+
|
|
3
|
+
> **ImmutableProofContexts** = *typeof* [`ImmutableProofContexts`](../variables/ImmutableProofContexts.md)\[keyof *typeof* [`ImmutableProofContexts`](../variables/ImmutableProofContexts.md)\]
|
|
4
|
+
|
|
5
|
+
The contexts of immutable proof data.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
# Type Alias: ImmutableProofFailure
|
|
2
2
|
|
|
3
|
-
> **ImmutableProofFailure
|
|
3
|
+
> **ImmutableProofFailure** = *typeof* [`ImmutableProofFailure`](../variables/ImmutableProofFailure.md)\[keyof *typeof* [`ImmutableProofFailure`](../variables/ImmutableProofFailure.md)\]
|
|
4
4
|
|
|
5
5
|
The failure reason of the proof.
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
# Type Alias: ImmutableProofTopics
|
|
2
|
+
|
|
3
|
+
> **ImmutableProofTopics** = *typeof* [`ImmutableProofTopics`](../variables/ImmutableProofTopics.md)\[keyof *typeof* [`ImmutableProofTopics`](../variables/ImmutableProofTopics.md)\]
|
|
4
|
+
|
|
5
|
+
The topics for immutable proof event bus notifications.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
# Type Alias: ImmutableProofTypes
|
|
2
2
|
|
|
3
|
-
> **ImmutableProofTypes
|
|
3
|
+
> **ImmutableProofTypes** = *typeof* [`ImmutableProofTypes`](../variables/ImmutableProofTypes.md)\[keyof *typeof* [`ImmutableProofTypes`](../variables/ImmutableProofTypes.md)\]
|
|
4
4
|
|
|
5
5
|
The types of immutable proof data.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Variable: ImmutableProofContexts
|
|
2
|
+
|
|
3
|
+
> `const` **ImmutableProofContexts**: `object`
|
|
4
|
+
|
|
5
|
+
The contexts of immutable proof data.
|
|
6
|
+
|
|
7
|
+
## Type declaration
|
|
8
|
+
|
|
9
|
+
### ContextRoot
|
|
10
|
+
|
|
11
|
+
> `readonly` **ContextRoot**: `"https://schema.twindev.org/immutable-proof/"` = `"https://schema.twindev.org/immutable-proof/"`
|
|
12
|
+
|
|
13
|
+
The context root for the immutable proof types.
|
|
14
|
+
|
|
15
|
+
### ContextRootCommon
|
|
16
|
+
|
|
17
|
+
> `readonly` **ContextRootCommon**: `"https://schema.twindev.org/common/"` = `"https://schema.twindev.org/common/"`
|
|
18
|
+
|
|
19
|
+
The context root for the common types.
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# Variable: ImmutableProofTopics
|
|
2
|
+
|
|
3
|
+
> `const` **ImmutableProofTopics**: `object`
|
|
4
|
+
|
|
5
|
+
The topics for immutable proof event bus notifications.
|
|
6
|
+
|
|
7
|
+
## Type declaration
|
|
8
|
+
|
|
9
|
+
### ProofCreated
|
|
10
|
+
|
|
11
|
+
> `readonly` **ProofCreated**: `"immutable-proof:proof-created"` = `"immutable-proof:proof-created"`
|
|
12
|
+
|
|
13
|
+
A proof was created.
|
|
@@ -6,12 +6,6 @@ The types of immutable proof data.
|
|
|
6
6
|
|
|
7
7
|
## Type declaration
|
|
8
8
|
|
|
9
|
-
### ContextRoot
|
|
10
|
-
|
|
11
|
-
> `readonly` **ContextRoot**: `"https://schema.twindev.org/immutable-proof/"` = `"https://schema.twindev.org/immutable-proof/"`
|
|
12
|
-
|
|
13
|
-
The context root for the immutable proof types.
|
|
14
|
-
|
|
15
9
|
### ImmutableProof
|
|
16
10
|
|
|
17
11
|
> `readonly` **ImmutableProof**: `"ImmutableProof"` = `"ImmutableProof"`
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@twin.org/immutable-proof-models",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.2-next.1",
|
|
4
4
|
"description": "Models which define the structure of the immutable proof connectors and services",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -27,9 +27,9 @@
|
|
|
27
27
|
"types": "./dist/types/index.d.ts",
|
|
28
28
|
"exports": {
|
|
29
29
|
".": {
|
|
30
|
+
"types": "./dist/types/index.d.ts",
|
|
30
31
|
"require": "./dist/cjs/index.cjs",
|
|
31
|
-
"import": "./dist/esm/index.mjs"
|
|
32
|
-
"types": "./dist/types/index.d.ts"
|
|
32
|
+
"import": "./dist/esm/index.mjs"
|
|
33
33
|
},
|
|
34
34
|
"./locales/*.json": "./locales/*.json"
|
|
35
35
|
},
|