@twin.org/auditable-item-graph-models 0.0.2-next.3 → 0.0.2-next.5
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 +5 -0
- package/dist/esm/index.mjs +5 -0
- package/dist/types/models/IAuditableItemGraphComponent.d.ts +6 -1
- package/dist/types/models/IAuditableItemGraphEdge.d.ts +4 -0
- package/dist/types/models/api/IAuditableItemGraphCreateRequest.d.ts +2 -1
- package/dist/types/models/api/IAuditableItemGraphListRequest.d.ts +4 -0
- package/dist/types/models/api/IAuditableItemGraphUpdateRequest.d.ts +2 -0
- package/docs/changelog.md +14 -0
- package/docs/reference/interfaces/IAuditableItemGraphComponent.md +6 -0
- package/docs/reference/interfaces/IAuditableItemGraphEdge.md +8 -0
- package/docs/reference/interfaces/IAuditableItemGraphListRequest.md +6 -0
- package/package.json +1 -1
package/dist/cjs/index.cjs
CHANGED
|
@@ -250,6 +250,10 @@ var properties$4 = {
|
|
|
250
250
|
],
|
|
251
251
|
description: "JSON-LD Context."
|
|
252
252
|
},
|
|
253
|
+
targetId: {
|
|
254
|
+
type: "string",
|
|
255
|
+
description: "The target vertex id the edge connects to."
|
|
256
|
+
},
|
|
253
257
|
type: {
|
|
254
258
|
type: "string",
|
|
255
259
|
"const": "AuditableItemGraphEdge",
|
|
@@ -273,6 +277,7 @@ var properties$4 = {
|
|
|
273
277
|
var required$4 = [
|
|
274
278
|
"@context",
|
|
275
279
|
"id",
|
|
280
|
+
"targetId",
|
|
276
281
|
"type",
|
|
277
282
|
"edgeRelationships"
|
|
278
283
|
];
|
package/dist/esm/index.mjs
CHANGED
|
@@ -248,6 +248,10 @@ var properties$4 = {
|
|
|
248
248
|
],
|
|
249
249
|
description: "JSON-LD Context."
|
|
250
250
|
},
|
|
251
|
+
targetId: {
|
|
252
|
+
type: "string",
|
|
253
|
+
description: "The target vertex id the edge connects to."
|
|
254
|
+
},
|
|
251
255
|
type: {
|
|
252
256
|
type: "string",
|
|
253
257
|
"const": "AuditableItemGraphEdge",
|
|
@@ -271,6 +275,7 @@ var properties$4 = {
|
|
|
271
275
|
var required$4 = [
|
|
272
276
|
"@context",
|
|
273
277
|
"id",
|
|
278
|
+
"targetId",
|
|
274
279
|
"type",
|
|
275
280
|
"edgeRelationships"
|
|
276
281
|
];
|
|
@@ -24,6 +24,7 @@ export interface IAuditableItemGraphComponent extends IComponent {
|
|
|
24
24
|
aliases?: {
|
|
25
25
|
id: string;
|
|
26
26
|
aliasFormat?: string;
|
|
27
|
+
unique?: boolean;
|
|
27
28
|
annotationObject?: IJsonLdNodeObject;
|
|
28
29
|
}[];
|
|
29
30
|
resources?: {
|
|
@@ -31,7 +32,7 @@ export interface IAuditableItemGraphComponent extends IComponent {
|
|
|
31
32
|
resourceObject?: IJsonLdNodeObject;
|
|
32
33
|
}[];
|
|
33
34
|
edges?: {
|
|
34
|
-
|
|
35
|
+
targetId: string;
|
|
35
36
|
edgeRelationships: string[];
|
|
36
37
|
annotationObject?: IJsonLdNodeObject;
|
|
37
38
|
}[];
|
|
@@ -54,6 +55,7 @@ export interface IAuditableItemGraphComponent extends IComponent {
|
|
|
54
55
|
aliases?: {
|
|
55
56
|
id: string;
|
|
56
57
|
aliasFormat?: string;
|
|
58
|
+
unique?: boolean;
|
|
57
59
|
annotationObject?: IJsonLdNodeObject;
|
|
58
60
|
}[];
|
|
59
61
|
resources?: {
|
|
@@ -62,6 +64,7 @@ export interface IAuditableItemGraphComponent extends IComponent {
|
|
|
62
64
|
}[];
|
|
63
65
|
edges?: {
|
|
64
66
|
id: string;
|
|
67
|
+
targetId: string;
|
|
65
68
|
edgeRelationships: string[];
|
|
66
69
|
annotationObject?: IJsonLdNodeObject;
|
|
67
70
|
}[];
|
|
@@ -94,6 +97,7 @@ export interface IAuditableItemGraphComponent extends IComponent {
|
|
|
94
97
|
* @param options The query options.
|
|
95
98
|
* @param options.id The optional id to look for.
|
|
96
99
|
* @param options.idMode Look in id, alias or both, defaults to both.
|
|
100
|
+
* @param options.idExact Find only exact matches, default to false meaning partial matching.
|
|
97
101
|
* @param options.resourceTypes Include vertices with specific resource types.
|
|
98
102
|
* @param conditions Conditions to use in the query.
|
|
99
103
|
* @param orderBy The order for the results, defaults to dateCreated.
|
|
@@ -106,6 +110,7 @@ export interface IAuditableItemGraphComponent extends IComponent {
|
|
|
106
110
|
query(options?: {
|
|
107
111
|
id?: string;
|
|
108
112
|
idMode?: "id" | "alias" | "both";
|
|
113
|
+
idExact?: boolean;
|
|
109
114
|
resourceTypes?: string[];
|
|
110
115
|
}, conditions?: IComparator[], orderBy?: keyof Pick<IAuditableItemGraphVertex, "dateCreated" | "dateModified">, orderByDirection?: SortDirection, properties?: (keyof IAuditableItemGraphVertex)[], cursor?: string, pageSize?: number): Promise<IAuditableItemGraphVertexList>;
|
|
111
116
|
}
|
|
@@ -17,6 +17,7 @@ export interface IAuditableItemGraphCreateRequest {
|
|
|
17
17
|
aliases?: {
|
|
18
18
|
id: string;
|
|
19
19
|
aliasFormat?: string;
|
|
20
|
+
unique?: boolean;
|
|
20
21
|
annotationObject?: IJsonLdNodeObject;
|
|
21
22
|
}[];
|
|
22
23
|
/**
|
|
@@ -30,7 +31,7 @@ export interface IAuditableItemGraphCreateRequest {
|
|
|
30
31
|
* The edges connected to the vertex.
|
|
31
32
|
*/
|
|
32
33
|
edges?: {
|
|
33
|
-
|
|
34
|
+
targetId: string;
|
|
34
35
|
edgeRelationships: string[];
|
|
35
36
|
annotationObject?: IJsonLdNodeObject;
|
|
36
37
|
}[];
|
|
@@ -23,6 +23,10 @@ export interface IAuditableItemGraphListRequest {
|
|
|
23
23
|
* Which field to look in with the id, defaults to both.
|
|
24
24
|
*/
|
|
25
25
|
idMode?: "id" | "alias" | "both";
|
|
26
|
+
/**
|
|
27
|
+
* Find only exact matches, default to false meaning partial matching.
|
|
28
|
+
*/
|
|
29
|
+
idExact?: boolean;
|
|
26
30
|
/**
|
|
27
31
|
* Include vertices with specific resource types, comma separated.
|
|
28
32
|
*/
|
|
@@ -26,6 +26,7 @@ export interface IAuditableItemGraphUpdateRequest {
|
|
|
26
26
|
aliases?: {
|
|
27
27
|
id: string;
|
|
28
28
|
aliasFormat?: string;
|
|
29
|
+
unique?: boolean;
|
|
29
30
|
annotationObject?: IJsonLdNodeObject;
|
|
30
31
|
}[];
|
|
31
32
|
/**
|
|
@@ -40,6 +41,7 @@ export interface IAuditableItemGraphUpdateRequest {
|
|
|
40
41
|
*/
|
|
41
42
|
edges?: {
|
|
42
43
|
id: string;
|
|
44
|
+
targetId: string;
|
|
43
45
|
edgeRelationships: string[];
|
|
44
46
|
annotationObject?: IJsonLdNodeObject;
|
|
45
47
|
}[];
|
package/docs/changelog.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @twin.org/auditable-item-graph-models - Changelog
|
|
2
2
|
|
|
3
|
+
## [0.0.2-next.5](https://github.com/twinfoundation/auditable-item-graph/compare/auditable-item-graph-models-v0.0.2-next.4...auditable-item-graph-models-v0.0.2-next.5) (2025-09-26)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* update edges to use targetId instead of id ([6c5d0e3](https://github.com/twinfoundation/auditable-item-graph/commit/6c5d0e31b6e2ea74bfa2f3344e4be628e5f237af))
|
|
9
|
+
|
|
10
|
+
## [0.0.2-next.4](https://github.com/twinfoundation/auditable-item-graph/compare/auditable-item-graph-models-v0.0.2-next.3...auditable-item-graph-models-v0.0.2-next.4) (2025-09-24)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### Features
|
|
14
|
+
|
|
15
|
+
* add unique flag for alias, and exact match option for id query ([33dbd19](https://github.com/twinfoundation/auditable-item-graph/commit/33dbd19cabd9fbfaba81032f1d1a6527584c3f5a))
|
|
16
|
+
|
|
3
17
|
## [0.0.2-next.3](https://github.com/twinfoundation/auditable-item-graph/compare/auditable-item-graph-models-v0.0.2-next.2...auditable-item-graph-models-v0.0.2-next.3) (2025-08-29)
|
|
4
18
|
|
|
5
19
|
|
|
@@ -230,6 +230,12 @@ The optional id to look for.
|
|
|
230
230
|
|
|
231
231
|
Look in id, alias or both, defaults to both.
|
|
232
232
|
|
|
233
|
+
###### idExact?
|
|
234
|
+
|
|
235
|
+
`boolean`
|
|
236
|
+
|
|
237
|
+
Find only exact matches, default to false meaning partial matching.
|
|
238
|
+
|
|
233
239
|
###### resourceTypes?
|
|
234
240
|
|
|
235
241
|
`string`[]
|
|
@@ -34,6 +34,12 @@ The id or alias to try and find.
|
|
|
34
34
|
|
|
35
35
|
Which field to look in with the id, defaults to both.
|
|
36
36
|
|
|
37
|
+
#### idExact?
|
|
38
|
+
|
|
39
|
+
> `optional` **idExact**: `boolean`
|
|
40
|
+
|
|
41
|
+
Find only exact matches, default to false meaning partial matching.
|
|
42
|
+
|
|
37
43
|
#### resourceTypes?
|
|
38
44
|
|
|
39
45
|
> `optional` **resourceTypes**: `string`
|
package/package.json
CHANGED