@xyo-network/diviner-payload-model 3.0.7 → 3.0.9

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.
@@ -0,0 +1,11 @@
1
+ import type { EmptyObject, WithAdditional } from '@xylabs/object';
2
+ import type { DivinerConfig } from '@xyo-network/diviner-model';
3
+ import type { Schema } from '@xyo-network/payload-model';
4
+ import { PayloadDivinerSchema } from './Schema.ts';
5
+ export type PayloadDivinerConfigSchema = `${PayloadDivinerSchema}.config`;
6
+ export declare const PayloadDivinerConfigSchema: PayloadDivinerConfigSchema;
7
+ export type PayloadDivinerConfig<TAdditional extends EmptyObject | void = void, TSchema extends Schema | void = void> = DivinerConfig<WithAdditional<{
8
+ indexBatchSize?: number;
9
+ maxIndexSize?: number;
10
+ }, TAdditional>, TSchema extends void ? PayloadDivinerConfigSchema : TSchema>;
11
+ //# sourceMappingURL=Config.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Config.d.ts","sourceRoot":"","sources":["../../src/Config.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAA;AACjE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAA;AAC/D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,4BAA4B,CAAA;AAExD,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAElD,MAAM,MAAM,0BAA0B,GAAG,GAAG,oBAAoB,SAAS,CAAA;AACzE,eAAO,MAAM,0BAA0B,EAAE,0BAA6D,CAAA;AAEtG,MAAM,MAAM,oBAAoB,CAAC,WAAW,SAAS,WAAW,GAAG,IAAI,GAAG,IAAI,EAAE,OAAO,SAAS,MAAM,GAAG,IAAI,GAAG,IAAI,IAAI,aAAa,CACnI,cAAc,CACZ;IACE,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,YAAY,CAAC,EAAE,MAAM,CAAA;CACtB,EACD,WAAW,CACZ,EACD,OAAO,SAAS,IAAI,GAAG,0BAA0B,GAAG,OAAO,CAC5D,CAAA"}
@@ -0,0 +1,2 @@
1
+ export type Order = 'asc' | 'desc';
2
+ //# sourceMappingURL=Order.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Order.d.ts","sourceRoot":"","sources":["../../src/Order.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,KAAK,GAAG,KAAK,GAAG,MAAM,CAAA"}
@@ -0,0 +1,5 @@
1
+ import type { DivinerParams } from '@xyo-network/diviner-model';
2
+ import type { AnyConfigSchema } from '@xyo-network/module-model';
3
+ import type { PayloadDivinerConfig } from './Config.ts';
4
+ export type PayloadDivinerParams<T extends AnyConfigSchema<PayloadDivinerConfig> | void = void> = DivinerParams<T extends AnyConfigSchema<PayloadDivinerConfig> ? T : AnyConfigSchema<PayloadDivinerConfig>>;
5
+ //# sourceMappingURL=Params.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Params.d.ts","sourceRoot":"","sources":["../../src/Params.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAA;AAC/D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAA;AAEhE,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAEvD,MAAM,MAAM,oBAAoB,CAAC,CAAC,SAAS,eAAe,CAAC,oBAAoB,CAAC,GAAG,IAAI,GAAG,IAAI,IAAI,aAAa,CAC7G,CAAC,SAAS,eAAe,CAAC,oBAAoB,CAAC,GAAG,CAAC,GAAG,eAAe,CAAC,oBAAoB,CAAC,CAC5F,CAAA"}
@@ -0,0 +1,14 @@
1
+ import type { Address, Hash } from '@xylabs/hex';
2
+ import type { EmptyObject } from '@xylabs/object';
3
+ import type { Schema } from '@xyo-network/payload-model';
4
+ import type { Order } from './Order.ts';
5
+ export type PayloadDivinerPredicate<T extends EmptyObject = EmptyObject, TOffset = number> = Partial<{
6
+ address: Address | Address[];
7
+ hash: Hash;
8
+ limit: number;
9
+ offset: TOffset;
10
+ order: Order;
11
+ schemas: Schema[];
12
+ timestamp?: number;
13
+ } & T>;
14
+ //# sourceMappingURL=Predicate.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Predicate.d.ts","sourceRoot":"","sources":["../../src/Predicate.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;AAChD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AACjD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,4BAA4B,CAAA;AAExD,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,YAAY,CAAA;AAIvC,MAAM,MAAM,uBAAuB,CAAC,CAAC,SAAS,WAAW,GAAG,WAAW,EAAE,OAAO,GAAG,MAAM,IAAI,OAAO,CAClG;IAKE,OAAO,EAAE,OAAO,GAAG,OAAO,EAAE,CAAA;IAC5B,IAAI,EAAE,IAAI,CAAA;IACV,KAAK,EAAE,MAAM,CAAA;IACb,MAAM,EAAE,OAAO,CAAA;IACf,KAAK,EAAE,KAAK,CAAA;IACZ,OAAO,EAAE,MAAM,EAAE,CAAA;IACjB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,GAAG,CAAC,CACN,CAAA"}
@@ -0,0 +1,11 @@
1
+ import type { EmptyObject } from '@xylabs/object';
2
+ import type { Payload, Query } from '@xyo-network/payload-model';
3
+ import type { PayloadDivinerPredicate } from './Predicate.ts';
4
+ import { PayloadDivinerSchema } from './Schema.ts';
5
+ export type PayloadDivinerQuerySchema = `${PayloadDivinerSchema}.query`;
6
+ export declare const PayloadDivinerQuerySchema: PayloadDivinerQuerySchema;
7
+ export type PayloadDivinerQueryPayload<T extends EmptyObject = EmptyObject, O = number> = Query<{
8
+ schema: PayloadDivinerQuerySchema;
9
+ } & PayloadDivinerPredicate<T, O>>;
10
+ export declare const isPayloadDivinerQueryPayload: <T extends EmptyObject = object>(x?: Payload | null) => x is PayloadDivinerQueryPayload<T>;
11
+ //# sourceMappingURL=Query.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Query.d.ts","sourceRoot":"","sources":["../../src/Query.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AACjD,OAAO,KAAK,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,4BAA4B,CAAA;AAEhE,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,gBAAgB,CAAA;AAC7D,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAElD,MAAM,MAAM,yBAAyB,GAAG,GAAG,oBAAoB,QAAQ,CAAA;AACvE,eAAO,MAAM,yBAAyB,EAAE,yBAA2D,CAAA;AAEnG,MAAM,MAAM,0BAA0B,CAAC,CAAC,SAAS,WAAW,GAAG,WAAW,EAAE,CAAC,GAAG,MAAM,IAAI,KAAK,CAC7F;IAAE,MAAM,EAAE,yBAAyB,CAAA;CAAE,GAAG,uBAAuB,CAAC,CAAC,EAAE,CAAC,CAAC,CACtE,CAAA;AACD,eAAO,MAAM,4BAA4B,GAAI,CAAC,SAAS,WAAW,eAAoB,OAAO,GAAG,IAAI,KAAG,CAAC,IAAI,0BAA0B,CAAC,CAAC,CAC/F,CAAA"}
@@ -0,0 +1,3 @@
1
+ export type PayloadDivinerSchema = 'network.xyo.diviner.payload';
2
+ export declare const PayloadDivinerSchema: PayloadDivinerSchema;
3
+ //# sourceMappingURL=Schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Schema.d.ts","sourceRoot":"","sources":["../../src/Schema.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,oBAAoB,GAAG,6BAA6B,CAAA;AAChE,eAAO,MAAM,oBAAoB,EAAE,oBAAoD,CAAA"}
@@ -0,0 +1,2 @@
1
+ export type SortDirection = 'asc' | 'desc';
2
+ //# sourceMappingURL=SortDirection.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SortDirection.d.ts","sourceRoot":"","sources":["../../src/SortDirection.ts"],"names":[],"mappings":"AACA,MAAM,MAAM,aAAa,GAAG,KAAK,GAAG,MAAM,CAAA"}
@@ -1,40 +1,8 @@
1
- import { EmptyObject, WithAdditional } from '@xylabs/object';
2
- import { DivinerConfig, DivinerParams } from '@xyo-network/diviner-model';
3
- import { Schema, Query, Payload } from '@xyo-network/payload-model';
4
- import { AnyConfigSchema } from '@xyo-network/module-model';
5
- import { Address, Hash } from '@xylabs/hex';
6
-
7
- type PayloadDivinerSchema = 'network.xyo.diviner.payload';
8
- declare const PayloadDivinerSchema: PayloadDivinerSchema;
9
-
10
- type PayloadDivinerConfigSchema = `${PayloadDivinerSchema}.config`;
11
- declare const PayloadDivinerConfigSchema: PayloadDivinerConfigSchema;
12
- type PayloadDivinerConfig<TAdditional extends EmptyObject | void = void, TSchema extends Schema | void = void> = DivinerConfig<WithAdditional<{
13
- indexBatchSize?: number;
14
- maxIndexSize?: number;
15
- }, TAdditional>, TSchema extends void ? PayloadDivinerConfigSchema : TSchema>;
16
-
17
- type Order = 'asc' | 'desc';
18
-
19
- type PayloadDivinerParams<T extends AnyConfigSchema<PayloadDivinerConfig> | void = void> = DivinerParams<T extends AnyConfigSchema<PayloadDivinerConfig> ? T : AnyConfigSchema<PayloadDivinerConfig>>;
20
-
21
- type PayloadDivinerPredicate<T extends EmptyObject = EmptyObject, TOffset = number> = Partial<{
22
- address: Address | Address[];
23
- hash: Hash;
24
- limit: number;
25
- offset: TOffset;
26
- order: Order;
27
- schemas: Schema[];
28
- timestamp?: number;
29
- } & T>;
30
-
31
- type PayloadDivinerQuerySchema = `${PayloadDivinerSchema}.query`;
32
- declare const PayloadDivinerQuerySchema: PayloadDivinerQuerySchema;
33
- type PayloadDivinerQueryPayload<T extends EmptyObject = EmptyObject, O = number> = Query<{
34
- schema: PayloadDivinerQuerySchema;
35
- } & PayloadDivinerPredicate<T, O>>;
36
- declare const isPayloadDivinerQueryPayload: <T extends EmptyObject = object>(x?: Payload | null) => x is PayloadDivinerQueryPayload<T>;
37
-
38
- type SortDirection = 'asc' | 'desc';
39
-
40
- export { type Order, type PayloadDivinerConfig, PayloadDivinerConfigSchema, type PayloadDivinerParams, type PayloadDivinerPredicate, type PayloadDivinerQueryPayload, PayloadDivinerQuerySchema, PayloadDivinerSchema, type SortDirection, isPayloadDivinerQueryPayload };
1
+ export * from './Config.ts';
2
+ export * from './Order.ts';
3
+ export * from './Params.ts';
4
+ export * from './Predicate.ts';
5
+ export * from './Query.ts';
6
+ export * from './Schema.ts';
7
+ export * from './SortDirection.ts';
8
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAA;AAC3B,cAAc,YAAY,CAAA;AAC1B,cAAc,aAAa,CAAA;AAC3B,cAAc,gBAAgB,CAAA;AAC9B,cAAc,YAAY,CAAA;AAC1B,cAAc,aAAa,CAAA;AAC3B,cAAc,oBAAoB,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xyo-network/diviner-payload-model",
3
- "version": "3.0.7",
3
+ "version": "3.0.9",
4
4
  "description": "Primary SDK for using XYO Protocol 2.0",
5
5
  "homepage": "https://xyo.network",
6
6
  "bugs": {
@@ -29,15 +29,15 @@
29
29
  "module": "dist/neutral/index.mjs",
30
30
  "types": "dist/neutral/index.d.ts",
31
31
  "dependencies": {
32
- "@xylabs/hex": "^4.0.2",
33
- "@xylabs/object": "^4.0.2",
34
- "@xyo-network/diviner-model": "^3.0.7",
35
- "@xyo-network/module-model": "^3.0.7",
36
- "@xyo-network/payload-model": "^3.0.7"
32
+ "@xylabs/hex": "^4.0.3",
33
+ "@xylabs/object": "^4.0.3",
34
+ "@xyo-network/diviner-model": "^3.0.9",
35
+ "@xyo-network/module-model": "^3.0.9",
36
+ "@xyo-network/payload-model": "^3.0.9"
37
37
  },
38
38
  "devDependencies": {
39
- "@xylabs/ts-scripts-yarn3": "^4.0.0",
40
- "@xylabs/tsconfig": "^4.0.0",
39
+ "@xylabs/ts-scripts-yarn3": "^4.0.7",
40
+ "@xylabs/tsconfig": "^4.0.7",
41
41
  "typescript": "^5.5.4"
42
42
  },
43
43
  "publishConfig": {
package/xy.config.ts CHANGED
@@ -2,9 +2,7 @@ import type { XyTsupConfig } from '@xylabs/ts-scripts-yarn3'
2
2
  const config: XyTsupConfig = {
3
3
  compile: {
4
4
  browser: {},
5
- neutral: {
6
- src: true,
7
- },
5
+ neutral: { src: true },
8
6
  node: {},
9
7
  },
10
8
  }