@xyo-network/schema-payload-plugin 3.5.2 → 3.6.0-rc.10
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/neutral/Payload.d.ts +16 -48
- package/dist/neutral/Payload.d.ts.map +1 -1
- package/dist/neutral/Plugin.d.ts +6 -8
- package/dist/neutral/Plugin.d.ts.map +1 -1
- package/dist/neutral/index.mjs +0 -3
- package/dist/neutral/index.mjs.map +1 -1
- package/package.json +9 -8
- package/src/Payload.ts +1 -6
|
@@ -22,67 +22,35 @@ export type SchemaPayload = Payload<{
|
|
|
22
22
|
/**
|
|
23
23
|
* Identity function for determining if an object is an Schema
|
|
24
24
|
*/
|
|
25
|
-
export declare const isSchemaPayload: (x?: unknown | null) => x is import("@
|
|
26
|
-
|
|
27
|
-
* The schema definition
|
|
28
|
-
*/
|
|
29
|
-
definition: {
|
|
30
|
-
[key: string]: unknown;
|
|
31
|
-
$id?: string;
|
|
32
|
-
};
|
|
33
|
-
/**
|
|
34
|
-
* The schema this schema extends (if any)
|
|
35
|
-
*/
|
|
36
|
-
extends?: string;
|
|
37
|
-
/** @deprecated use definition.$id instead */
|
|
38
|
-
name?: string;
|
|
39
|
-
/**
|
|
40
|
-
* Identifies this payload as a Schema
|
|
41
|
-
*/
|
|
42
|
-
schema: SchemaSchema;
|
|
43
|
-
};
|
|
44
|
-
/**
|
|
45
|
-
* Identity function for determining if an object is an Schema with sources
|
|
46
|
-
*/
|
|
47
|
-
export declare const isSchemaPayloadWithSources: (x?: unknown | null) => x is import("@xyo-network/payload-model").WithSources<import("@xyo-network/payload-model").SchemaFields & import("@xyo-network/payload-model").PayloadFields & {
|
|
48
|
-
/**
|
|
49
|
-
* The schema definition
|
|
50
|
-
*/
|
|
25
|
+
export declare const isSchemaPayload: (x?: unknown | null) => x is import("@xylabs/object").DeepRestrictToStringKeys<{
|
|
26
|
+
schema: "network.xyo.schema";
|
|
51
27
|
definition: {
|
|
52
|
-
[
|
|
53
|
-
$id?: string;
|
|
28
|
+
[x: string]: unknown;
|
|
54
29
|
};
|
|
55
|
-
|
|
56
|
-
* The schema this schema extends (if any)
|
|
57
|
-
*/
|
|
58
|
-
extends?: string;
|
|
30
|
+
extends?: string
|
|
59
31
|
/** @deprecated use definition.$id instead */
|
|
60
|
-
|
|
32
|
+
| undefined;
|
|
33
|
+
name?: string
|
|
61
34
|
/**
|
|
62
35
|
* Identifies this payload as a Schema
|
|
63
36
|
*/
|
|
64
|
-
|
|
37
|
+
| undefined;
|
|
65
38
|
}>;
|
|
66
39
|
/**
|
|
67
|
-
* Identity function for determining if an object is an Schema with
|
|
40
|
+
* Identity function for determining if an object is an Schema with sources
|
|
68
41
|
*/
|
|
69
|
-
export declare const
|
|
70
|
-
|
|
71
|
-
* The schema definition
|
|
72
|
-
*/
|
|
42
|
+
export declare const isSchemaPayloadWithSources: (x?: unknown | null) => x is import("@xyo-network/payload-model").WithSources<import("@xylabs/object").DeepRestrictToStringKeys<{
|
|
43
|
+
schema: "network.xyo.schema";
|
|
73
44
|
definition: {
|
|
74
|
-
[
|
|
75
|
-
$id?: string;
|
|
45
|
+
[x: string]: unknown;
|
|
76
46
|
};
|
|
77
|
-
|
|
78
|
-
* The schema this schema extends (if any)
|
|
79
|
-
*/
|
|
80
|
-
extends?: string;
|
|
47
|
+
extends?: string
|
|
81
48
|
/** @deprecated use definition.$id instead */
|
|
82
|
-
|
|
49
|
+
| undefined;
|
|
50
|
+
name?: string
|
|
83
51
|
/**
|
|
84
52
|
* Identifies this payload as a Schema
|
|
85
53
|
*/
|
|
86
|
-
|
|
87
|
-
}
|
|
54
|
+
| undefined;
|
|
55
|
+
}>>;
|
|
88
56
|
//# sourceMappingURL=Payload.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Payload.d.ts","sourceRoot":"","sources":["../../src/Payload.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"Payload.d.ts","sourceRoot":"","sources":["../../src/Payload.ts"],"names":[],"mappings":"AAAA,OAAO,EACoD,KAAK,OAAO,EACtE,MAAM,4BAA4B,CAAA;AAEnC,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAE1C,MAAM,MAAM,aAAa,GAAG,OAAO,CAAC;IAClC;;OAEG;IACH,UAAU,EAAE;QACV,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAA;QACtB,GAAG,CAAC,EAAE,MAAM,CAAA;KACb,CAAA;IACD;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAA;IAEhB,6CAA6C;IAC7C,IAAI,CAAC,EAAE,MAAM,CAAA;IAEb;;OAEG;IACH,MAAM,EAAE,YAAY,CAAA;CACrB,CAAC,CAAA;AAEF;;GAEG;AACH,eAAO,MAAM,eAAe;;;;;cAdhB,MAAM;IAEhB,6CAA6C;;WACtC,MAAM;IAEb;;OAEG;;EAO4E,CAAA;AAEjF;;GAEG;AACH,eAAO,MAAM,0BAA0B;;;;;cAnB3B,MAAM;IAEhB,6CAA6C;;WACtC,MAAM;IAEb;;OAEG;;GAYkG,CAAA"}
|
package/dist/neutral/Plugin.d.ts
CHANGED
|
@@ -1,11 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
export declare const SchemaPayloadPlugin: () => import("@xyo-network/payload-plugin").PayloadPlugin<import("@xylabs/object").DeepRestrictToStringKeys<{
|
|
2
|
+
schema: "network.xyo.schema";
|
|
3
3
|
definition: {
|
|
4
|
-
[
|
|
5
|
-
$id?: string;
|
|
4
|
+
[x: string]: unknown;
|
|
6
5
|
};
|
|
7
|
-
extends?: string;
|
|
8
|
-
name?: string;
|
|
9
|
-
|
|
10
|
-
}>;
|
|
6
|
+
extends?: string | undefined;
|
|
7
|
+
name?: string | undefined;
|
|
8
|
+
}>>;
|
|
11
9
|
//# sourceMappingURL=Plugin.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,mBAAmB;;;;;;;GAI5B,CAAA"}
|
package/dist/neutral/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
// src/Payload.ts
|
|
2
2
|
import {
|
|
3
3
|
isPayloadOfSchemaType,
|
|
4
|
-
isPayloadOfSchemaTypeWithMeta,
|
|
5
4
|
isPayloadOfSchemaTypeWithSources
|
|
6
5
|
} from "@xyo-network/payload-model";
|
|
7
6
|
|
|
@@ -11,7 +10,6 @@ var SchemaSchema = "network.xyo.schema";
|
|
|
11
10
|
// src/Payload.ts
|
|
12
11
|
var isSchemaPayload = isPayloadOfSchemaType(SchemaSchema);
|
|
13
12
|
var isSchemaPayloadWithSources = isPayloadOfSchemaTypeWithSources(SchemaSchema);
|
|
14
|
-
var isSchemaPayloadWithMeta = isPayloadOfSchemaTypeWithMeta(SchemaSchema);
|
|
15
13
|
|
|
16
14
|
// src/Plugin.ts
|
|
17
15
|
import { createPayloadPlugin } from "@xyo-network/payload-plugin";
|
|
@@ -35,7 +33,6 @@ export {
|
|
|
35
33
|
SchemaSchema,
|
|
36
34
|
SchemaPayloadPlugin as default,
|
|
37
35
|
isSchemaPayload,
|
|
38
|
-
isSchemaPayloadWithMeta,
|
|
39
36
|
isSchemaPayloadWithSources,
|
|
40
37
|
schemaPayloadTemplate
|
|
41
38
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/Payload.ts","../../src/Schema.ts","../../src/Plugin.ts","../../src/Template.ts"],"sourcesContent":["import {\n isPayloadOfSchemaType,
|
|
1
|
+
{"version":3,"sources":["../../src/Payload.ts","../../src/Schema.ts","../../src/Plugin.ts","../../src/Template.ts"],"sourcesContent":["import {\n isPayloadOfSchemaType, isPayloadOfSchemaTypeWithSources, type Payload,\n} from '@xyo-network/payload-model'\n\nimport { SchemaSchema } from './Schema.ts'\n\nexport type SchemaPayload = Payload<{\n /**\n * The schema definition\n */\n definition: {\n [key: string]: unknown\n $id?: string\n }\n /**\n * The schema this schema extends (if any)\n */\n extends?: string\n\n /** @deprecated use definition.$id instead */\n name?: string\n\n /**\n * Identifies this payload as a Schema\n */\n schema: SchemaSchema\n}>\n\n/**\n * Identity function for determining if an object is an Schema\n */\nexport const isSchemaPayload = isPayloadOfSchemaType<SchemaPayload>(SchemaSchema)\n\n/**\n * Identity function for determining if an object is an Schema with sources\n */\nexport const isSchemaPayloadWithSources = isPayloadOfSchemaTypeWithSources<SchemaPayload>(SchemaSchema)\n","export type SchemaSchema = 'network.xyo.schema'\nexport const SchemaSchema: SchemaSchema = 'network.xyo.schema'\n","import { createPayloadPlugin } from '@xyo-network/payload-plugin'\n\nimport type { SchemaPayload } from './Payload.ts'\nimport { SchemaSchema } from './Schema.ts'\nimport { schemaPayloadTemplate } from './Template.ts'\n\nexport const SchemaPayloadPlugin = () =>\n createPayloadPlugin<SchemaPayload>({\n schema: SchemaSchema,\n template: schemaPayloadTemplate,\n })\n","import type { SchemaPayload } from './Payload.ts'\nimport { SchemaSchema } from './Schema.ts'\nexport const schemaPayloadTemplate = (): SchemaPayload => ({\n definition: {\n $id: '',\n $schema: 'http://json-schema.org/draft-07/schema#',\n },\n schema: SchemaSchema,\n})\n"],"mappings":";AAAA;AAAA,EACE;AAAA,EAAuB;AAAA,OAClB;;;ACDA,IAAM,eAA6B;;;AD8BnC,IAAM,kBAAkB,sBAAqC,YAAY;AAKzE,IAAM,6BAA6B,iCAAgD,YAAY;;;AEpCtG,SAAS,2BAA2B;;;ACE7B,IAAM,wBAAwB,OAAsB;AAAA,EACzD,YAAY;AAAA,IACV,KAAK;AAAA,IACL,SAAS;AAAA,EACX;AAAA,EACA,QAAQ;AACV;;;ADFO,IAAM,sBAAsB,MACjC,oBAAmC;AAAA,EACjC,QAAQ;AAAA,EACR,UAAU;AACZ,CAAC;","names":[]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xyo-network/schema-payload-plugin",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.6.0-rc.10",
|
|
4
4
|
"description": "Typescript/Javascript Plugins for XYO Platform",
|
|
5
5
|
"homepage": "https://xyo.network",
|
|
6
6
|
"bugs": {
|
|
@@ -29,17 +29,18 @@
|
|
|
29
29
|
"module": "dist/neutral/index.mjs",
|
|
30
30
|
"types": "dist/neutral/index.d.ts",
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@xyo-network/payload-model": "^3.
|
|
33
|
-
"@xyo-network/payload-plugin": "^3.
|
|
32
|
+
"@xyo-network/payload-model": "^3.6.0-rc.10",
|
|
33
|
+
"@xyo-network/payload-plugin": "^3.6.0-rc.10"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
36
|
-
"@xylabs/ts-scripts-yarn3": "^4.2.
|
|
37
|
-
"@xylabs/tsconfig": "^4.2.
|
|
38
|
-
"@xylabs/vitest-extended": "^4.4.
|
|
36
|
+
"@xylabs/ts-scripts-yarn3": "^4.2.6",
|
|
37
|
+
"@xylabs/tsconfig": "^4.2.6",
|
|
38
|
+
"@xylabs/vitest-extended": "^4.4.21",
|
|
39
39
|
"typescript": "^5.7.2",
|
|
40
|
-
"vitest": "^2.1.
|
|
40
|
+
"vitest": "^2.1.8"
|
|
41
41
|
},
|
|
42
42
|
"publishConfig": {
|
|
43
43
|
"access": "public"
|
|
44
|
-
}
|
|
44
|
+
},
|
|
45
|
+
"stableVersion": "3.5.2"
|
|
45
46
|
}
|
package/src/Payload.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import {
|
|
2
|
-
isPayloadOfSchemaType,
|
|
2
|
+
isPayloadOfSchemaType, isPayloadOfSchemaTypeWithSources, type Payload,
|
|
3
3
|
} from '@xyo-network/payload-model'
|
|
4
4
|
|
|
5
5
|
import { SchemaSchema } from './Schema.ts'
|
|
@@ -35,8 +35,3 @@ export const isSchemaPayload = isPayloadOfSchemaType<SchemaPayload>(SchemaSchema
|
|
|
35
35
|
* Identity function for determining if an object is an Schema with sources
|
|
36
36
|
*/
|
|
37
37
|
export const isSchemaPayloadWithSources = isPayloadOfSchemaTypeWithSources<SchemaPayload>(SchemaSchema)
|
|
38
|
-
|
|
39
|
-
/**
|
|
40
|
-
* Identity function for determining if an object is an Schema with meta
|
|
41
|
-
*/
|
|
42
|
-
export const isSchemaPayloadWithMeta = isPayloadOfSchemaTypeWithMeta<SchemaPayload>(SchemaSchema)
|