@twin.org/immutable-proof-models 0.0.1-next.31 → 0.0.1-next.33

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.
@@ -2,6 +2,23 @@
2
2
 
3
3
  var dataCore = require('@twin.org/data-core');
4
4
 
5
+ // Copyright 2024 IOTA Stiftung.
6
+ // SPDX-License-Identifier: Apache-2.0.
7
+ /**
8
+ * The contexts of immutable proof data.
9
+ */
10
+ // eslint-disable-next-line @typescript-eslint/naming-convention
11
+ const ImmutableProofContexts = {
12
+ /**
13
+ * The context root for the immutable proof types.
14
+ */
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
+
5
22
  // Copyright 2024 IOTA Stiftung.
6
23
  // SPDX-License-Identifier: Apache-2.0.
7
24
  /**
@@ -105,7 +122,8 @@ class ImmutableProofDataTypes {
105
122
  * Register all the data types.
106
123
  */
107
124
  static registerTypes() {
108
- dataCore.DataTypeHandlerFactory.register(ImmutableProofTypes.ImmutableProof, () => ({
125
+ dataCore.DataTypeHandlerFactory.register(`${ImmutableProofContexts.ContextRoot}${ImmutableProofTypes.ImmutableProof}`, () => ({
126
+ context: ImmutableProofContexts.ContextRoot,
109
127
  type: ImmutableProofTypes.ImmutableProof,
110
128
  defaultValue: {},
111
129
  jsonSchema: async () => ImmutableProofSchema
@@ -113,23 +131,6 @@ class ImmutableProofDataTypes {
113
131
  }
114
132
  }
115
133
 
116
- // Copyright 2024 IOTA Stiftung.
117
- // SPDX-License-Identifier: Apache-2.0.
118
- /**
119
- * The contexts of immutable proof data.
120
- */
121
- // eslint-disable-next-line @typescript-eslint/naming-convention
122
- const ImmutableProofContexts = {
123
- /**
124
- * The context root for the immutable proof types.
125
- */
126
- ContextRoot: "https://schema.twindev.org/immutable-proof/",
127
- /**
128
- * The context root for the common types.
129
- */
130
- ContextRootCommon: "https://schema.twindev.org/common/"
131
- };
132
-
133
134
  // Copyright 2024 IOTA Stiftung.
134
135
  // SPDX-License-Identifier: Apache-2.0.
135
136
  /**
@@ -1,5 +1,22 @@
1
1
  import { DataTypeHandlerFactory } from '@twin.org/data-core';
2
2
 
3
+ // Copyright 2024 IOTA Stiftung.
4
+ // SPDX-License-Identifier: Apache-2.0.
5
+ /**
6
+ * The contexts of immutable proof data.
7
+ */
8
+ // eslint-disable-next-line @typescript-eslint/naming-convention
9
+ const ImmutableProofContexts = {
10
+ /**
11
+ * The context root for the immutable proof types.
12
+ */
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
+
3
20
  // Copyright 2024 IOTA Stiftung.
4
21
  // SPDX-License-Identifier: Apache-2.0.
5
22
  /**
@@ -103,7 +120,8 @@ class ImmutableProofDataTypes {
103
120
  * Register all the data types.
104
121
  */
105
122
  static registerTypes() {
106
- DataTypeHandlerFactory.register(ImmutableProofTypes.ImmutableProof, () => ({
123
+ DataTypeHandlerFactory.register(`${ImmutableProofContexts.ContextRoot}${ImmutableProofTypes.ImmutableProof}`, () => ({
124
+ context: ImmutableProofContexts.ContextRoot,
107
125
  type: ImmutableProofTypes.ImmutableProof,
108
126
  defaultValue: {},
109
127
  jsonSchema: async () => ImmutableProofSchema
@@ -111,23 +129,6 @@ class ImmutableProofDataTypes {
111
129
  }
112
130
  }
113
131
 
114
- // Copyright 2024 IOTA Stiftung.
115
- // SPDX-License-Identifier: Apache-2.0.
116
- /**
117
- * The contexts of immutable proof data.
118
- */
119
- // eslint-disable-next-line @typescript-eslint/naming-convention
120
- const ImmutableProofContexts = {
121
- /**
122
- * The context root for the immutable proof types.
123
- */
124
- ContextRoot: "https://schema.twindev.org/immutable-proof/",
125
- /**
126
- * The context root for the common types.
127
- */
128
- ContextRootCommon: "https://schema.twindev.org/common/"
129
- };
130
-
131
132
  // Copyright 2024 IOTA Stiftung.
132
133
  // SPDX-License-Identifier: Apache-2.0.
133
134
  /**
package/docs/changelog.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # @twin.org/immutable-proof-models - Changelog
2
2
 
3
+ ## [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)
4
+
5
+
6
+ ### Features
7
+
8
+ * update data types to use fully qualified names ([e94d0f5](https://github.com/twinfoundation/immutable-proof/commit/e94d0f5db93856b5b59cfd34e55252fa13a7f4e0))
9
+
10
+ ## [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)
11
+
12
+
13
+ ### Features
14
+
15
+ * use shared store mechanism ([#3](https://github.com/twinfoundation/immutable-proof/issues/3)) ([7042a40](https://github.com/twinfoundation/immutable-proof/commit/7042a40f0ef8b01463f07aeb1efae4f417162fa1))
16
+
3
17
  ## [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)
4
18
 
5
19
 
@@ -4,13 +4,13 @@ Handle all the data types for immutable proof.
4
4
 
5
5
  ## Constructors
6
6
 
7
- ### new ImmutableProofDataTypes()
7
+ ### Constructor
8
8
 
9
- > **new ImmutableProofDataTypes**(): [`ImmutableProofDataTypes`](ImmutableProofDataTypes.md)
9
+ > **new ImmutableProofDataTypes**(): `ImmutableProofDataTypes`
10
10
 
11
11
  #### Returns
12
12
 
13
- [`ImmutableProofDataTypes`](ImmutableProofDataTypes.md)
13
+ `ImmutableProofDataTypes`
14
14
 
15
15
  ## Methods
16
16
 
@@ -10,7 +10,7 @@ Interface describing an immutable proof contract.
10
10
 
11
11
  ### create()
12
12
 
13
- > **create**(`document`, `userIdentity`?, `nodeIdentity`?): `Promise`\<`string`\>
13
+ > **create**(`document`, `userIdentity?`, `nodeIdentity?`): `Promise`\<`string`\>
14
14
 
15
15
  Create a new proof.
16
16
 
@@ -96,7 +96,7 @@ NotFoundError if the proof is not found.
96
96
 
97
97
  ### removeVerifiable()
98
98
 
99
- > **removeVerifiable**(`id`, `nodeIdentity`?): `Promise`\<`void`\>
99
+ > **removeVerifiable**(`id`, `nodeIdentity?`): `Promise`\<`void`\>
100
100
 
101
101
  Remove the verifiable storage for the proof.
102
102
 
@@ -1,5 +1,5 @@
1
1
  # Type Alias: ImmutableProofContexts
2
2
 
3
- > **ImmutableProofContexts**: *typeof* [`ImmutableProofContexts`](../variables/ImmutableProofContexts.md)\[keyof *typeof* [`ImmutableProofContexts`](../variables/ImmutableProofContexts.md)\]
3
+ > **ImmutableProofContexts** = *typeof* [`ImmutableProofContexts`](../variables/ImmutableProofContexts.md)\[keyof *typeof* [`ImmutableProofContexts`](../variables/ImmutableProofContexts.md)\]
4
4
 
5
5
  The contexts of immutable proof data.
@@ -1,5 +1,5 @@
1
1
  # Type Alias: ImmutableProofFailure
2
2
 
3
- > **ImmutableProofFailure**: *typeof* [`ImmutableProofFailure`](../variables/ImmutableProofFailure.md)\[keyof *typeof* [`ImmutableProofFailure`](../variables/ImmutableProofFailure.md)\]
3
+ > **ImmutableProofFailure** = *typeof* [`ImmutableProofFailure`](../variables/ImmutableProofFailure.md)\[keyof *typeof* [`ImmutableProofFailure`](../variables/ImmutableProofFailure.md)\]
4
4
 
5
5
  The failure reason of the proof.
@@ -1,5 +1,5 @@
1
1
  # Type Alias: ImmutableProofTopics
2
2
 
3
- > **ImmutableProofTopics**: *typeof* [`ImmutableProofTopics`](../variables/ImmutableProofTopics.md)\[keyof *typeof* [`ImmutableProofTopics`](../variables/ImmutableProofTopics.md)\]
3
+ > **ImmutableProofTopics** = *typeof* [`ImmutableProofTopics`](../variables/ImmutableProofTopics.md)\[keyof *typeof* [`ImmutableProofTopics`](../variables/ImmutableProofTopics.md)\]
4
4
 
5
5
  The topics for immutable proof event bus notifications.
@@ -1,5 +1,5 @@
1
1
  # Type Alias: ImmutableProofTypes
2
2
 
3
- > **ImmutableProofTypes**: *typeof* [`ImmutableProofTypes`](../variables/ImmutableProofTypes.md)\[keyof *typeof* [`ImmutableProofTypes`](../variables/ImmutableProofTypes.md)\]
3
+ > **ImmutableProofTypes** = *typeof* [`ImmutableProofTypes`](../variables/ImmutableProofTypes.md)\[keyof *typeof* [`ImmutableProofTypes`](../variables/ImmutableProofTypes.md)\]
4
4
 
5
5
  The types of immutable proof data.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@twin.org/immutable-proof-models",
3
- "version": "0.0.1-next.31",
3
+ "version": "0.0.1-next.33",
4
4
  "description": "Models which define the structure of the immutable proof connectors and services",
5
5
  "repository": {
6
6
  "type": "git",