@xyo-network/location-plugin 2.84.5 → 2.85.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.
@@ -2,7 +2,6 @@ import { CurrentLocationWitness } from './CurrentLocationWitness';
2
2
  export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugin").PayloadSetWitnessPlugin<CurrentLocationWitness<import("@xyo-network/object").BaseParamsFields & {
3
3
  account?: import("@xyo-network/account-model").AccountInstance | "random" | undefined;
4
4
  config: import("@xyo-network/payload-model").SchemaFields & object & Omit<{
5
- accountDerivationPath?: string | undefined;
6
5
  readonly archivist?: string | undefined;
7
6
  readonly labels?: import("@xyo-network/module-model").Labels | undefined;
8
7
  readonly name?: string | undefined;
@@ -19,7 +18,6 @@ export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugi
19
18
  readonly storeQueries?: boolean | undefined;
20
19
  readonly timestamp?: boolean | undefined;
21
20
  } & import("@xyo-network/module-model").ArchivingModuleConfig & import("@xyo-network/payload-model").SchemaFields & object & {
22
- accountDerivationPath?: string | undefined;
23
21
  readonly archivist?: string | undefined;
24
22
  readonly labels?: import("@xyo-network/module-model").Labels | undefined;
25
23
  readonly name?: string | undefined;
@@ -43,7 +41,6 @@ export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugi
43
41
  schema: string;
44
42
  };
45
43
  ephemeralQueryAccountEnabled?: boolean | undefined;
46
- wallet?: import("@xyo-network/wallet-model").WalletInstance | undefined;
47
44
  } & {
48
45
  geolocation?: Geolocation | undefined;
49
46
  }>>;
@@ -1 +1 @@
1
- {"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAQxB,CAAA"}
1
+ {"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAQxB,CAAA"}
@@ -2,7 +2,6 @@ import { CurrentLocationWitness } from './CurrentLocationWitness';
2
2
  export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugin").PayloadSetWitnessPlugin<CurrentLocationWitness<import("@xyo-network/object").BaseParamsFields & {
3
3
  account?: import("@xyo-network/account-model").AccountInstance | "random" | undefined;
4
4
  config: import("@xyo-network/payload-model").SchemaFields & object & Omit<{
5
- accountDerivationPath?: string | undefined;
6
5
  readonly archivist?: string | undefined;
7
6
  readonly labels?: import("@xyo-network/module-model").Labels | undefined;
8
7
  readonly name?: string | undefined;
@@ -19,7 +18,6 @@ export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugi
19
18
  readonly storeQueries?: boolean | undefined;
20
19
  readonly timestamp?: boolean | undefined;
21
20
  } & import("@xyo-network/module-model").ArchivingModuleConfig & import("@xyo-network/payload-model").SchemaFields & object & {
22
- accountDerivationPath?: string | undefined;
23
21
  readonly archivist?: string | undefined;
24
22
  readonly labels?: import("@xyo-network/module-model").Labels | undefined;
25
23
  readonly name?: string | undefined;
@@ -43,7 +41,6 @@ export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugi
43
41
  schema: string;
44
42
  };
45
43
  ephemeralQueryAccountEnabled?: boolean | undefined;
46
- wallet?: import("@xyo-network/wallet-model").WalletInstance | undefined;
47
44
  } & {
48
45
  geolocation?: Geolocation | undefined;
49
46
  }>>;
@@ -1 +1 @@
1
- {"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAQxB,CAAA"}
1
+ {"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAQxB,CAAA"}
@@ -2,7 +2,6 @@ import { CurrentLocationWitness } from './CurrentLocationWitness';
2
2
  export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugin").PayloadSetWitnessPlugin<CurrentLocationWitness<import("@xyo-network/object").BaseParamsFields & {
3
3
  account?: import("@xyo-network/account-model").AccountInstance | "random" | undefined;
4
4
  config: import("@xyo-network/payload-model").SchemaFields & object & Omit<{
5
- accountDerivationPath?: string | undefined;
6
5
  readonly archivist?: string | undefined;
7
6
  readonly labels?: import("@xyo-network/module-model").Labels | undefined;
8
7
  readonly name?: string | undefined;
@@ -19,7 +18,6 @@ export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugi
19
18
  readonly storeQueries?: boolean | undefined;
20
19
  readonly timestamp?: boolean | undefined;
21
20
  } & import("@xyo-network/module-model").ArchivingModuleConfig & import("@xyo-network/payload-model").SchemaFields & object & {
22
- accountDerivationPath?: string | undefined;
23
21
  readonly archivist?: string | undefined;
24
22
  readonly labels?: import("@xyo-network/module-model").Labels | undefined;
25
23
  readonly name?: string | undefined;
@@ -43,7 +41,6 @@ export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugi
43
41
  schema: string;
44
42
  };
45
43
  ephemeralQueryAccountEnabled?: boolean | undefined;
46
- wallet?: import("@xyo-network/wallet-model").WalletInstance | undefined;
47
44
  } & {
48
45
  geolocation?: Geolocation | undefined;
49
46
  }>>;
@@ -1 +1 @@
1
- {"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAQxB,CAAA"}
1
+ {"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAQxB,CAAA"}
@@ -24,24 +24,30 @@ __export(src_exports, {
24
24
  CurrentLocationWitness: () => CurrentLocationWitness,
25
25
  CurrentLocationWitnessConfigSchema: () => CurrentLocationWitnessConfigSchema,
26
26
  LocationPlugin: () => LocationPlugin,
27
- default: () => src_default
27
+ default: () => LocationPlugin
28
28
  });
29
29
  module.exports = __toCommonJS(src_exports);
30
30
 
31
- // src/Plugin.ts
32
- var import_location_payload_plugin2 = require("@xyo-network/location-payload-plugin");
31
+ // src/Config.ts
32
+ var CurrentLocationWitnessConfigSchema = "network.xyo.location.current.config";
33
+
34
+ // src/CurrentLocationPayloadSet.ts
35
+ var import_location_payload_plugin = require("@xyo-network/location-payload-plugin");
33
36
  var import_payload_model = require("@xyo-network/payload-model");
34
- var import_payloadset_plugin = require("@xyo-network/payloadset-plugin");
37
+ var CurrentLocationPayloadSet = {
38
+ optional: {
39
+ [import_location_payload_plugin.LocationHeadingSchema]: 1
40
+ },
41
+ required: {
42
+ [import_location_payload_plugin.LocationSchema]: 1
43
+ },
44
+ schema: import_payload_model.PayloadSetSchema
45
+ };
35
46
 
36
47
  // src/CurrentLocationWitness.ts
37
48
  var import_assert = require("@xylabs/assert");
38
49
  var import_abstract_witness = require("@xyo-network/abstract-witness");
39
- var import_location_payload_plugin = require("@xyo-network/location-payload-plugin");
40
-
41
- // src/Config.ts
42
- var CurrentLocationWitnessConfigSchema = "network.xyo.location.current.config";
43
-
44
- // src/CurrentLocationWitness.ts
50
+ var import_location_payload_plugin2 = require("@xyo-network/location-payload-plugin");
45
51
  var CurrentLocationWitness = class extends import_abstract_witness.AbstractWitness {
46
52
  static configSchemas = [CurrentLocationWitnessConfigSchema];
47
53
  get geolocation() {
@@ -66,12 +72,12 @@ var CurrentLocationWitness = class extends import_abstract_witness.AbstractWitne
66
72
  altitudeAccuracy: location.coords.altitudeAccuracy ?? void 0,
67
73
  latitude: location.coords.latitude,
68
74
  longitude: location.coords.longitude,
69
- schema: import_location_payload_plugin.LocationSchema
75
+ schema: import_location_payload_plugin2.LocationSchema
70
76
  };
71
77
  const heading = location.coords.heading ? [
72
78
  {
73
79
  heading: location.coords.heading ?? void 0,
74
- schema: import_location_payload_plugin.LocationHeadingSchema,
80
+ schema: import_location_payload_plugin2.LocationHeadingSchema,
75
81
  speed: location.coords.speed ?? void 0
76
82
  }
77
83
  ] : [];
@@ -80,28 +86,15 @@ var CurrentLocationWitness = class extends import_abstract_witness.AbstractWitne
80
86
  };
81
87
 
82
88
  // src/Plugin.ts
89
+ var import_location_payload_plugin3 = require("@xyo-network/location-payload-plugin");
90
+ var import_payload_model2 = require("@xyo-network/payload-model");
91
+ var import_payloadset_plugin = require("@xyo-network/payloadset-plugin");
83
92
  var LocationPlugin = () => (0, import_payloadset_plugin.createPayloadSetWitnessPlugin)(
84
- { required: { [import_location_payload_plugin2.LocationSchema]: 1 }, schema: import_payload_model.PayloadSetSchema },
93
+ { required: { [import_location_payload_plugin3.LocationSchema]: 1 }, schema: import_payload_model2.PayloadSetSchema },
85
94
  {
86
95
  witness: async (params) => {
87
96
  return await CurrentLocationWitness.create(params);
88
97
  }
89
98
  }
90
99
  );
91
-
92
- // src/CurrentLocationPayloadSet.ts
93
- var import_location_payload_plugin3 = require("@xyo-network/location-payload-plugin");
94
- var import_payload_model2 = require("@xyo-network/payload-model");
95
- var CurrentLocationPayloadSet = {
96
- optional: {
97
- [import_location_payload_plugin3.LocationHeadingSchema]: 1
98
- },
99
- required: {
100
- [import_location_payload_plugin3.LocationSchema]: 1
101
- },
102
- schema: import_payload_model2.PayloadSetSchema
103
- };
104
-
105
- // src/index.ts
106
- var src_default = LocationPlugin;
107
100
  //# sourceMappingURL=index.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/index.ts","../../src/Plugin.ts","../../src/CurrentLocationWitness.ts","../../src/Config.ts","../../src/CurrentLocationPayloadSet.ts"],"sourcesContent":["import { LocationPlugin } from './Plugin'\n\nexport * from './Config'\nexport * from './CurrentLocationPayloadSet'\nexport * from './CurrentLocationWitness'\n\nexport { LocationPlugin }\n\n// eslint-disable-next-line import/no-default-export\nexport default LocationPlugin\n","import { LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetSchema } from '@xyo-network/payload-model'\nimport { createPayloadSetWitnessPlugin } from '@xyo-network/payloadset-plugin'\n\nimport { CurrentLocationWitness } from './CurrentLocationWitness'\n\nexport const LocationPlugin = () =>\n createPayloadSetWitnessPlugin<CurrentLocationWitness>(\n { required: { [LocationSchema]: 1 }, schema: PayloadSetSchema },\n {\n witness: async (params) => {\n return await CurrentLocationWitness.create(params)\n },\n },\n )\n","import { assertEx } from '@xylabs/assert'\nimport { AbstractWitness } from '@xyo-network/abstract-witness'\nimport { LocationHeadingPayload, LocationHeadingSchema, LocationPayload, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { Payload } from '@xyo-network/payload-model'\n\nimport { CurrentLocationWitnessConfigSchema, CurrentLocationWitnessParams } from './Config'\n\nexport class CurrentLocationWitness<TParams extends CurrentLocationWitnessParams = CurrentLocationWitnessParams> extends AbstractWitness<TParams> {\n static override configSchemas = [CurrentLocationWitnessConfigSchema]\n\n get geolocation(): Geolocation {\n return assertEx(this.params.geolocation, 'No geolocation provided')\n }\n\n getCurrentPosition() {\n return new Promise<GeolocationPosition>((resolve, reject) => {\n this.geolocation?.getCurrentPosition(\n (position: GeolocationPosition) => {\n resolve(position)\n },\n (error: GeolocationPositionError) => {\n reject(error)\n },\n )\n })\n }\n\n protected override async observeHandler(): Promise<Payload[]> {\n const location = await this.getCurrentPosition()\n const locationPayload: LocationPayload = {\n altitude: location.coords.altitude ?? undefined,\n altitudeAccuracy: location.coords.altitudeAccuracy ?? undefined,\n latitude: location.coords.latitude,\n longitude: location.coords.longitude,\n schema: LocationSchema,\n }\n const heading: LocationHeadingPayload[] = location.coords.heading\n ? [\n {\n heading: location.coords.heading ?? undefined,\n schema: LocationHeadingSchema,\n speed: location.coords.speed ?? undefined,\n },\n ]\n : []\n return [locationPayload, ...heading]\n }\n}\n","import { AnyConfigSchema, ModuleParams } from '@xyo-network/module-model'\nimport { WitnessConfig } from '@xyo-network/witness-model'\n\nexport type CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\nexport const CurrentLocationWitnessConfigSchema: CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\n\nexport type CurrentLocationWitnessConfig = WitnessConfig<{\n schema: CurrentLocationWitnessConfigSchema\n}>\n\nexport type CurrentLocationWitnessParams = ModuleParams<AnyConfigSchema<CurrentLocationWitnessConfig>, { geolocation?: Geolocation }>\n","import { LocationHeadingSchema, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetPayload, PayloadSetSchema } from '@xyo-network/payload-model'\n\nexport const CurrentLocationPayloadSet: PayloadSetPayload = {\n optional: {\n [LocationHeadingSchema]: 1,\n },\n required: {\n [LocationSchema]: 1,\n },\n schema: PayloadSetSchema,\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,IAAAA,kCAA+B;AAC/B,2BAAiC;AACjC,+BAA8C;;;ACF9C,oBAAyB;AACzB,8BAAgC;AAChC,qCAA+F;;;ACExF,IAAM,qCAAyE;;;ADG/E,IAAM,yBAAN,cAAkH,wCAAyB;AAAA,EAChJ,OAAgB,gBAAgB,CAAC,kCAAkC;AAAA,EAEnE,IAAI,cAA2B;AAC7B,eAAO,wBAAS,KAAK,OAAO,aAAa,yBAAyB;AAAA,EACpE;AAAA,EAEA,qBAAqB;AACnB,WAAO,IAAI,QAA6B,CAAC,SAAS,WAAW;AAC3D,WAAK,aAAa;AAAA,QAChB,CAAC,aAAkC;AACjC,kBAAQ,QAAQ;AAAA,QAClB;AAAA,QACA,CAAC,UAAoC;AACnC,iBAAO,KAAK;AAAA,QACd;AAAA,MACF;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,MAAyB,iBAAqC;AAC5D,UAAM,WAAW,MAAM,KAAK,mBAAmB;AAC/C,UAAM,kBAAmC;AAAA,MACvC,UAAU,SAAS,OAAO,YAAY;AAAA,MACtC,kBAAkB,SAAS,OAAO,oBAAoB;AAAA,MACtD,UAAU,SAAS,OAAO;AAAA,MAC1B,WAAW,SAAS,OAAO;AAAA,MAC3B,QAAQ;AAAA,IACV;AACA,UAAM,UAAoC,SAAS,OAAO,UACtD;AAAA,MACE;AAAA,QACE,SAAS,SAAS,OAAO,WAAW;AAAA,QACpC,QAAQ;AAAA,QACR,OAAO,SAAS,OAAO,SAAS;AAAA,MAClC;AAAA,IACF,IACA,CAAC;AACL,WAAO,CAAC,iBAAiB,GAAG,OAAO;AAAA,EACrC;AACF;;;ADzCO,IAAM,iBAAiB,UAC5B;AAAA,EACE,EAAE,UAAU,EAAE,CAAC,8CAAc,GAAG,EAAE,GAAG,QAAQ,sCAAiB;AAAA,EAC9D;AAAA,IACE,SAAS,OAAO,WAAW;AACzB,aAAO,MAAM,uBAAuB,OAAO,MAAM;AAAA,IACnD;AAAA,EACF;AACF;;;AGdF,IAAAC,kCAAsD;AACtD,IAAAC,wBAAoD;AAE7C,IAAM,4BAA+C;AAAA,EAC1D,UAAU;AAAA,IACR,CAAC,qDAAqB,GAAG;AAAA,EAC3B;AAAA,EACA,UAAU;AAAA,IACR,CAAC,8CAAc,GAAG;AAAA,EACpB;AAAA,EACA,QAAQ;AACV;;;AJFA,IAAO,cAAQ;","names":["import_location_payload_plugin","import_location_payload_plugin","import_payload_model"]}
1
+ {"version":3,"sources":["../../src/index.ts","../../src/Config.ts","../../src/CurrentLocationPayloadSet.ts","../../src/CurrentLocationWitness.ts","../../src/Plugin.ts"],"sourcesContent":["export * from './Config'\nexport * from './CurrentLocationPayloadSet'\nexport * from './CurrentLocationWitness'\nexport { LocationPlugin as default, LocationPlugin } from './Plugin'\n","import { AnyConfigSchema, ModuleParams } from '@xyo-network/module-model'\nimport { WitnessConfig } from '@xyo-network/witness-model'\n\nexport type CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\nexport const CurrentLocationWitnessConfigSchema: CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\n\nexport type CurrentLocationWitnessConfig = WitnessConfig<{\n schema: CurrentLocationWitnessConfigSchema\n}>\n\nexport type CurrentLocationWitnessParams = ModuleParams<AnyConfigSchema<CurrentLocationWitnessConfig>, { geolocation?: Geolocation }>\n","import { LocationHeadingSchema, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetPayload, PayloadSetSchema } from '@xyo-network/payload-model'\n\nexport const CurrentLocationPayloadSet: PayloadSetPayload = {\n optional: {\n [LocationHeadingSchema]: 1,\n },\n required: {\n [LocationSchema]: 1,\n },\n schema: PayloadSetSchema,\n}\n","import { assertEx } from '@xylabs/assert'\nimport { AbstractWitness } from '@xyo-network/abstract-witness'\nimport { LocationHeadingPayload, LocationHeadingSchema, LocationPayload, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { Payload } from '@xyo-network/payload-model'\n\nimport { CurrentLocationWitnessConfigSchema, CurrentLocationWitnessParams } from './Config'\n\nexport class CurrentLocationWitness<TParams extends CurrentLocationWitnessParams = CurrentLocationWitnessParams> extends AbstractWitness<TParams> {\n static override configSchemas = [CurrentLocationWitnessConfigSchema]\n\n get geolocation(): Geolocation {\n return assertEx(this.params.geolocation, 'No geolocation provided')\n }\n\n getCurrentPosition() {\n return new Promise<GeolocationPosition>((resolve, reject) => {\n this.geolocation?.getCurrentPosition(\n (position: GeolocationPosition) => {\n resolve(position)\n },\n (error: GeolocationPositionError) => {\n reject(error)\n },\n )\n })\n }\n\n protected override async observeHandler(): Promise<Payload[]> {\n const location = await this.getCurrentPosition()\n const locationPayload: LocationPayload = {\n altitude: location.coords.altitude ?? undefined,\n altitudeAccuracy: location.coords.altitudeAccuracy ?? undefined,\n latitude: location.coords.latitude,\n longitude: location.coords.longitude,\n schema: LocationSchema,\n }\n const heading: LocationHeadingPayload[] = location.coords.heading\n ? [\n {\n heading: location.coords.heading ?? undefined,\n schema: LocationHeadingSchema,\n speed: location.coords.speed ?? undefined,\n },\n ]\n : []\n return [locationPayload, ...heading]\n }\n}\n","import { LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetSchema } from '@xyo-network/payload-model'\nimport { createPayloadSetWitnessPlugin } from '@xyo-network/payloadset-plugin'\n\nimport { CurrentLocationWitness } from './CurrentLocationWitness'\n\nexport const LocationPlugin = () =>\n createPayloadSetWitnessPlugin<CurrentLocationWitness>(\n { required: { [LocationSchema]: 1 }, schema: PayloadSetSchema },\n {\n witness: async (params) => {\n return await CurrentLocationWitness.create(params)\n },\n },\n )\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACIO,IAAM,qCAAyE;;;ACJtF,qCAAsD;AACtD,2BAAoD;AAE7C,IAAM,4BAA+C;AAAA,EAC1D,UAAU;AAAA,IACR,CAAC,oDAAqB,GAAG;AAAA,EAC3B;AAAA,EACA,UAAU;AAAA,IACR,CAAC,6CAAc,GAAG;AAAA,EACpB;AAAA,EACA,QAAQ;AACV;;;ACXA,oBAAyB;AACzB,8BAAgC;AAChC,IAAAA,kCAA+F;AAKxF,IAAM,yBAAN,cAAkH,wCAAyB;AAAA,EAChJ,OAAgB,gBAAgB,CAAC,kCAAkC;AAAA,EAEnE,IAAI,cAA2B;AAC7B,eAAO,wBAAS,KAAK,OAAO,aAAa,yBAAyB;AAAA,EACpE;AAAA,EAEA,qBAAqB;AACnB,WAAO,IAAI,QAA6B,CAAC,SAAS,WAAW;AAC3D,WAAK,aAAa;AAAA,QAChB,CAAC,aAAkC;AACjC,kBAAQ,QAAQ;AAAA,QAClB;AAAA,QACA,CAAC,UAAoC;AACnC,iBAAO,KAAK;AAAA,QACd;AAAA,MACF;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,MAAyB,iBAAqC;AAC5D,UAAM,WAAW,MAAM,KAAK,mBAAmB;AAC/C,UAAM,kBAAmC;AAAA,MACvC,UAAU,SAAS,OAAO,YAAY;AAAA,MACtC,kBAAkB,SAAS,OAAO,oBAAoB;AAAA,MACtD,UAAU,SAAS,OAAO;AAAA,MAC1B,WAAW,SAAS,OAAO;AAAA,MAC3B,QAAQ;AAAA,IACV;AACA,UAAM,UAAoC,SAAS,OAAO,UACtD;AAAA,MACE;AAAA,QACE,SAAS,SAAS,OAAO,WAAW;AAAA,QACpC,QAAQ;AAAA,QACR,OAAO,SAAS,OAAO,SAAS;AAAA,MAClC;AAAA,IACF,IACA,CAAC;AACL,WAAO,CAAC,iBAAiB,GAAG,OAAO;AAAA,EACrC;AACF;;;AC/CA,IAAAC,kCAA+B;AAC/B,IAAAC,wBAAiC;AACjC,+BAA8C;AAIvC,IAAM,iBAAiB,UAC5B;AAAA,EACE,EAAE,UAAU,EAAE,CAAC,8CAAc,GAAG,EAAE,GAAG,QAAQ,uCAAiB;AAAA,EAC9D;AAAA,IACE,SAAS,OAAO,WAAW;AACzB,aAAO,MAAM,uBAAuB,OAAO,MAAM;AAAA,IACnD;AAAA,EACF;AACF;","names":["import_location_payload_plugin","import_location_payload_plugin","import_payload_model"]}
@@ -1,7 +1,5 @@
1
- import { LocationPlugin } from './Plugin';
2
1
  export * from './Config';
3
2
  export * from './CurrentLocationPayloadSet';
4
3
  export * from './CurrentLocationWitness';
5
- export { LocationPlugin };
6
- export default LocationPlugin;
4
+ export { LocationPlugin as default, LocationPlugin } from './Plugin';
7
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA;AAEzC,cAAc,UAAU,CAAA;AACxB,cAAc,6BAA6B,CAAA;AAC3C,cAAc,0BAA0B,CAAA;AAExC,OAAO,EAAE,cAAc,EAAE,CAAA;AAGzB,eAAe,cAAc,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAA;AACxB,cAAc,6BAA6B,CAAA;AAC3C,cAAc,0BAA0B,CAAA;AACxC,OAAO,EAAE,cAAc,IAAI,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA"}
@@ -1,7 +1,5 @@
1
- import { LocationPlugin } from './Plugin';
2
1
  export * from './Config';
3
2
  export * from './CurrentLocationPayloadSet';
4
3
  export * from './CurrentLocationWitness';
5
- export { LocationPlugin };
6
- export default LocationPlugin;
4
+ export { LocationPlugin as default, LocationPlugin } from './Plugin';
7
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA;AAEzC,cAAc,UAAU,CAAA;AACxB,cAAc,6BAA6B,CAAA;AAC3C,cAAc,0BAA0B,CAAA;AAExC,OAAO,EAAE,cAAc,EAAE,CAAA;AAGzB,eAAe,cAAc,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAA;AACxB,cAAc,6BAA6B,CAAA;AAC3C,cAAc,0BAA0B,CAAA;AACxC,OAAO,EAAE,cAAc,IAAI,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA"}
@@ -1,7 +1,5 @@
1
- import { LocationPlugin } from './Plugin';
2
1
  export * from './Config';
3
2
  export * from './CurrentLocationPayloadSet';
4
3
  export * from './CurrentLocationWitness';
5
- export { LocationPlugin };
6
- export default LocationPlugin;
4
+ export { LocationPlugin as default, LocationPlugin } from './Plugin';
7
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA;AAEzC,cAAc,UAAU,CAAA;AACxB,cAAc,6BAA6B,CAAA;AAC3C,cAAc,0BAA0B,CAAA;AAExC,OAAO,EAAE,cAAc,EAAE,CAAA;AAGzB,eAAe,cAAc,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAA;AACxB,cAAc,6BAA6B,CAAA;AAC3C,cAAc,0BAA0B,CAAA;AACxC,OAAO,EAAE,cAAc,IAAI,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA"}
@@ -1,17 +1,23 @@
1
- // src/Plugin.ts
2
- import { LocationSchema as LocationSchema2 } from "@xyo-network/location-payload-plugin";
1
+ // src/Config.ts
2
+ var CurrentLocationWitnessConfigSchema = "network.xyo.location.current.config";
3
+
4
+ // src/CurrentLocationPayloadSet.ts
5
+ import { LocationHeadingSchema, LocationSchema } from "@xyo-network/location-payload-plugin";
3
6
  import { PayloadSetSchema } from "@xyo-network/payload-model";
4
- import { createPayloadSetWitnessPlugin } from "@xyo-network/payloadset-plugin";
7
+ var CurrentLocationPayloadSet = {
8
+ optional: {
9
+ [LocationHeadingSchema]: 1
10
+ },
11
+ required: {
12
+ [LocationSchema]: 1
13
+ },
14
+ schema: PayloadSetSchema
15
+ };
5
16
 
6
17
  // src/CurrentLocationWitness.ts
7
18
  import { assertEx } from "@xylabs/assert";
8
19
  import { AbstractWitness } from "@xyo-network/abstract-witness";
9
- import { LocationHeadingSchema, LocationSchema } from "@xyo-network/location-payload-plugin";
10
-
11
- // src/Config.ts
12
- var CurrentLocationWitnessConfigSchema = "network.xyo.location.current.config";
13
-
14
- // src/CurrentLocationWitness.ts
20
+ import { LocationHeadingSchema as LocationHeadingSchema2, LocationSchema as LocationSchema2 } from "@xyo-network/location-payload-plugin";
15
21
  var CurrentLocationWitness = class extends AbstractWitness {
16
22
  static configSchemas = [CurrentLocationWitnessConfigSchema];
17
23
  get geolocation() {
@@ -36,12 +42,12 @@ var CurrentLocationWitness = class extends AbstractWitness {
36
42
  altitudeAccuracy: location.coords.altitudeAccuracy ?? void 0,
37
43
  latitude: location.coords.latitude,
38
44
  longitude: location.coords.longitude,
39
- schema: LocationSchema
45
+ schema: LocationSchema2
40
46
  };
41
47
  const heading = location.coords.heading ? [
42
48
  {
43
49
  heading: location.coords.heading ?? void 0,
44
- schema: LocationHeadingSchema,
50
+ schema: LocationHeadingSchema2,
45
51
  speed: location.coords.speed ?? void 0
46
52
  }
47
53
  ] : [];
@@ -50,35 +56,22 @@ var CurrentLocationWitness = class extends AbstractWitness {
50
56
  };
51
57
 
52
58
  // src/Plugin.ts
59
+ import { LocationSchema as LocationSchema3 } from "@xyo-network/location-payload-plugin";
60
+ import { PayloadSetSchema as PayloadSetSchema2 } from "@xyo-network/payload-model";
61
+ import { createPayloadSetWitnessPlugin } from "@xyo-network/payloadset-plugin";
53
62
  var LocationPlugin = () => createPayloadSetWitnessPlugin(
54
- { required: { [LocationSchema2]: 1 }, schema: PayloadSetSchema },
63
+ { required: { [LocationSchema3]: 1 }, schema: PayloadSetSchema2 },
55
64
  {
56
65
  witness: async (params) => {
57
66
  return await CurrentLocationWitness.create(params);
58
67
  }
59
68
  }
60
69
  );
61
-
62
- // src/CurrentLocationPayloadSet.ts
63
- import { LocationHeadingSchema as LocationHeadingSchema2, LocationSchema as LocationSchema3 } from "@xyo-network/location-payload-plugin";
64
- import { PayloadSetSchema as PayloadSetSchema2 } from "@xyo-network/payload-model";
65
- var CurrentLocationPayloadSet = {
66
- optional: {
67
- [LocationHeadingSchema2]: 1
68
- },
69
- required: {
70
- [LocationSchema3]: 1
71
- },
72
- schema: PayloadSetSchema2
73
- };
74
-
75
- // src/index.ts
76
- var src_default = LocationPlugin;
77
70
  export {
78
71
  CurrentLocationPayloadSet,
79
72
  CurrentLocationWitness,
80
73
  CurrentLocationWitnessConfigSchema,
81
74
  LocationPlugin,
82
- src_default as default
75
+ LocationPlugin as default
83
76
  };
84
77
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/Plugin.ts","../../src/CurrentLocationWitness.ts","../../src/Config.ts","../../src/CurrentLocationPayloadSet.ts","../../src/index.ts"],"sourcesContent":["import { LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetSchema } from '@xyo-network/payload-model'\nimport { createPayloadSetWitnessPlugin } from '@xyo-network/payloadset-plugin'\n\nimport { CurrentLocationWitness } from './CurrentLocationWitness'\n\nexport const LocationPlugin = () =>\n createPayloadSetWitnessPlugin<CurrentLocationWitness>(\n { required: { [LocationSchema]: 1 }, schema: PayloadSetSchema },\n {\n witness: async (params) => {\n return await CurrentLocationWitness.create(params)\n },\n },\n )\n","import { assertEx } from '@xylabs/assert'\nimport { AbstractWitness } from '@xyo-network/abstract-witness'\nimport { LocationHeadingPayload, LocationHeadingSchema, LocationPayload, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { Payload } from '@xyo-network/payload-model'\n\nimport { CurrentLocationWitnessConfigSchema, CurrentLocationWitnessParams } from './Config'\n\nexport class CurrentLocationWitness<TParams extends CurrentLocationWitnessParams = CurrentLocationWitnessParams> extends AbstractWitness<TParams> {\n static override configSchemas = [CurrentLocationWitnessConfigSchema]\n\n get geolocation(): Geolocation {\n return assertEx(this.params.geolocation, 'No geolocation provided')\n }\n\n getCurrentPosition() {\n return new Promise<GeolocationPosition>((resolve, reject) => {\n this.geolocation?.getCurrentPosition(\n (position: GeolocationPosition) => {\n resolve(position)\n },\n (error: GeolocationPositionError) => {\n reject(error)\n },\n )\n })\n }\n\n protected override async observeHandler(): Promise<Payload[]> {\n const location = await this.getCurrentPosition()\n const locationPayload: LocationPayload = {\n altitude: location.coords.altitude ?? undefined,\n altitudeAccuracy: location.coords.altitudeAccuracy ?? undefined,\n latitude: location.coords.latitude,\n longitude: location.coords.longitude,\n schema: LocationSchema,\n }\n const heading: LocationHeadingPayload[] = location.coords.heading\n ? [\n {\n heading: location.coords.heading ?? undefined,\n schema: LocationHeadingSchema,\n speed: location.coords.speed ?? undefined,\n },\n ]\n : []\n return [locationPayload, ...heading]\n }\n}\n","import { AnyConfigSchema, ModuleParams } from '@xyo-network/module-model'\nimport { WitnessConfig } from '@xyo-network/witness-model'\n\nexport type CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\nexport const CurrentLocationWitnessConfigSchema: CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\n\nexport type CurrentLocationWitnessConfig = WitnessConfig<{\n schema: CurrentLocationWitnessConfigSchema\n}>\n\nexport type CurrentLocationWitnessParams = ModuleParams<AnyConfigSchema<CurrentLocationWitnessConfig>, { geolocation?: Geolocation }>\n","import { LocationHeadingSchema, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetPayload, PayloadSetSchema } from '@xyo-network/payload-model'\n\nexport const CurrentLocationPayloadSet: PayloadSetPayload = {\n optional: {\n [LocationHeadingSchema]: 1,\n },\n required: {\n [LocationSchema]: 1,\n },\n schema: PayloadSetSchema,\n}\n","import { LocationPlugin } from './Plugin'\n\nexport * from './Config'\nexport * from './CurrentLocationPayloadSet'\nexport * from './CurrentLocationWitness'\n\nexport { LocationPlugin }\n\n// eslint-disable-next-line import/no-default-export\nexport default LocationPlugin\n"],"mappings":";AAAA,SAAS,kBAAAA,uBAAsB;AAC/B,SAAS,wBAAwB;AACjC,SAAS,qCAAqC;;;ACF9C,SAAS,gBAAgB;AACzB,SAAS,uBAAuB;AAChC,SAAiC,uBAAwC,sBAAsB;;;ACExF,IAAM,qCAAyE;;;ADG/E,IAAM,yBAAN,cAAkH,gBAAyB;AAAA,EAChJ,OAAgB,gBAAgB,CAAC,kCAAkC;AAAA,EAEnE,IAAI,cAA2B;AAC7B,WAAO,SAAS,KAAK,OAAO,aAAa,yBAAyB;AAAA,EACpE;AAAA,EAEA,qBAAqB;AACnB,WAAO,IAAI,QAA6B,CAAC,SAAS,WAAW;AAC3D,WAAK,aAAa;AAAA,QAChB,CAAC,aAAkC;AACjC,kBAAQ,QAAQ;AAAA,QAClB;AAAA,QACA,CAAC,UAAoC;AACnC,iBAAO,KAAK;AAAA,QACd;AAAA,MACF;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,MAAyB,iBAAqC;AAC5D,UAAM,WAAW,MAAM,KAAK,mBAAmB;AAC/C,UAAM,kBAAmC;AAAA,MACvC,UAAU,SAAS,OAAO,YAAY;AAAA,MACtC,kBAAkB,SAAS,OAAO,oBAAoB;AAAA,MACtD,UAAU,SAAS,OAAO;AAAA,MAC1B,WAAW,SAAS,OAAO;AAAA,MAC3B,QAAQ;AAAA,IACV;AACA,UAAM,UAAoC,SAAS,OAAO,UACtD;AAAA,MACE;AAAA,QACE,SAAS,SAAS,OAAO,WAAW;AAAA,QACpC,QAAQ;AAAA,QACR,OAAO,SAAS,OAAO,SAAS;AAAA,MAClC;AAAA,IACF,IACA,CAAC;AACL,WAAO,CAAC,iBAAiB,GAAG,OAAO;AAAA,EACrC;AACF;;;ADzCO,IAAM,iBAAiB,MAC5B;AAAA,EACE,EAAE,UAAU,EAAE,CAACC,eAAc,GAAG,EAAE,GAAG,QAAQ,iBAAiB;AAAA,EAC9D;AAAA,IACE,SAAS,OAAO,WAAW;AACzB,aAAO,MAAM,uBAAuB,OAAO,MAAM;AAAA,IACnD;AAAA,EACF;AACF;;;AGdF,SAAS,yBAAAC,wBAAuB,kBAAAC,uBAAsB;AACtD,SAA4B,oBAAAC,yBAAwB;AAE7C,IAAM,4BAA+C;AAAA,EAC1D,UAAU;AAAA,IACR,CAACF,sBAAqB,GAAG;AAAA,EAC3B;AAAA,EACA,UAAU;AAAA,IACR,CAACC,eAAc,GAAG;AAAA,EACpB;AAAA,EACA,QAAQC;AACV;;;ACFA,IAAO,cAAQ;","names":["LocationSchema","LocationSchema","LocationHeadingSchema","LocationSchema","PayloadSetSchema"]}
1
+ {"version":3,"sources":["../../src/Config.ts","../../src/CurrentLocationPayloadSet.ts","../../src/CurrentLocationWitness.ts","../../src/Plugin.ts"],"sourcesContent":["import { AnyConfigSchema, ModuleParams } from '@xyo-network/module-model'\nimport { WitnessConfig } from '@xyo-network/witness-model'\n\nexport type CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\nexport const CurrentLocationWitnessConfigSchema: CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\n\nexport type CurrentLocationWitnessConfig = WitnessConfig<{\n schema: CurrentLocationWitnessConfigSchema\n}>\n\nexport type CurrentLocationWitnessParams = ModuleParams<AnyConfigSchema<CurrentLocationWitnessConfig>, { geolocation?: Geolocation }>\n","import { LocationHeadingSchema, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetPayload, PayloadSetSchema } from '@xyo-network/payload-model'\n\nexport const CurrentLocationPayloadSet: PayloadSetPayload = {\n optional: {\n [LocationHeadingSchema]: 1,\n },\n required: {\n [LocationSchema]: 1,\n },\n schema: PayloadSetSchema,\n}\n","import { assertEx } from '@xylabs/assert'\nimport { AbstractWitness } from '@xyo-network/abstract-witness'\nimport { LocationHeadingPayload, LocationHeadingSchema, LocationPayload, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { Payload } from '@xyo-network/payload-model'\n\nimport { CurrentLocationWitnessConfigSchema, CurrentLocationWitnessParams } from './Config'\n\nexport class CurrentLocationWitness<TParams extends CurrentLocationWitnessParams = CurrentLocationWitnessParams> extends AbstractWitness<TParams> {\n static override configSchemas = [CurrentLocationWitnessConfigSchema]\n\n get geolocation(): Geolocation {\n return assertEx(this.params.geolocation, 'No geolocation provided')\n }\n\n getCurrentPosition() {\n return new Promise<GeolocationPosition>((resolve, reject) => {\n this.geolocation?.getCurrentPosition(\n (position: GeolocationPosition) => {\n resolve(position)\n },\n (error: GeolocationPositionError) => {\n reject(error)\n },\n )\n })\n }\n\n protected override async observeHandler(): Promise<Payload[]> {\n const location = await this.getCurrentPosition()\n const locationPayload: LocationPayload = {\n altitude: location.coords.altitude ?? undefined,\n altitudeAccuracy: location.coords.altitudeAccuracy ?? undefined,\n latitude: location.coords.latitude,\n longitude: location.coords.longitude,\n schema: LocationSchema,\n }\n const heading: LocationHeadingPayload[] = location.coords.heading\n ? [\n {\n heading: location.coords.heading ?? undefined,\n schema: LocationHeadingSchema,\n speed: location.coords.speed ?? undefined,\n },\n ]\n : []\n return [locationPayload, ...heading]\n }\n}\n","import { LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetSchema } from '@xyo-network/payload-model'\nimport { createPayloadSetWitnessPlugin } from '@xyo-network/payloadset-plugin'\n\nimport { CurrentLocationWitness } from './CurrentLocationWitness'\n\nexport const LocationPlugin = () =>\n createPayloadSetWitnessPlugin<CurrentLocationWitness>(\n { required: { [LocationSchema]: 1 }, schema: PayloadSetSchema },\n {\n witness: async (params) => {\n return await CurrentLocationWitness.create(params)\n },\n },\n )\n"],"mappings":";AAIO,IAAM,qCAAyE;;;ACJtF,SAAS,uBAAuB,sBAAsB;AACtD,SAA4B,wBAAwB;AAE7C,IAAM,4BAA+C;AAAA,EAC1D,UAAU;AAAA,IACR,CAAC,qBAAqB,GAAG;AAAA,EAC3B;AAAA,EACA,UAAU;AAAA,IACR,CAAC,cAAc,GAAG;AAAA,EACpB;AAAA,EACA,QAAQ;AACV;;;ACXA,SAAS,gBAAgB;AACzB,SAAS,uBAAuB;AAChC,SAAiC,yBAAAA,wBAAwC,kBAAAC,uBAAsB;AAKxF,IAAM,yBAAN,cAAkH,gBAAyB;AAAA,EAChJ,OAAgB,gBAAgB,CAAC,kCAAkC;AAAA,EAEnE,IAAI,cAA2B;AAC7B,WAAO,SAAS,KAAK,OAAO,aAAa,yBAAyB;AAAA,EACpE;AAAA,EAEA,qBAAqB;AACnB,WAAO,IAAI,QAA6B,CAAC,SAAS,WAAW;AAC3D,WAAK,aAAa;AAAA,QAChB,CAAC,aAAkC;AACjC,kBAAQ,QAAQ;AAAA,QAClB;AAAA,QACA,CAAC,UAAoC;AACnC,iBAAO,KAAK;AAAA,QACd;AAAA,MACF;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,MAAyB,iBAAqC;AAC5D,UAAM,WAAW,MAAM,KAAK,mBAAmB;AAC/C,UAAM,kBAAmC;AAAA,MACvC,UAAU,SAAS,OAAO,YAAY;AAAA,MACtC,kBAAkB,SAAS,OAAO,oBAAoB;AAAA,MACtD,UAAU,SAAS,OAAO;AAAA,MAC1B,WAAW,SAAS,OAAO;AAAA,MAC3B,QAAQC;AAAA,IACV;AACA,UAAM,UAAoC,SAAS,OAAO,UACtD;AAAA,MACE;AAAA,QACE,SAAS,SAAS,OAAO,WAAW;AAAA,QACpC,QAAQC;AAAA,QACR,OAAO,SAAS,OAAO,SAAS;AAAA,MAClC;AAAA,IACF,IACA,CAAC;AACL,WAAO,CAAC,iBAAiB,GAAG,OAAO;AAAA,EACrC;AACF;;;AC/CA,SAAS,kBAAAC,uBAAsB;AAC/B,SAAS,oBAAAC,yBAAwB;AACjC,SAAS,qCAAqC;AAIvC,IAAM,iBAAiB,MAC5B;AAAA,EACE,EAAE,UAAU,EAAE,CAACC,eAAc,GAAG,EAAE,GAAG,QAAQC,kBAAiB;AAAA,EAC9D;AAAA,IACE,SAAS,OAAO,WAAW;AACzB,aAAO,MAAM,uBAAuB,OAAO,MAAM;AAAA,IACnD;AAAA,EACF;AACF;","names":["LocationHeadingSchema","LocationSchema","LocationSchema","LocationHeadingSchema","LocationSchema","PayloadSetSchema","LocationSchema","PayloadSetSchema"]}
@@ -2,7 +2,6 @@ import { CurrentLocationWitness } from './CurrentLocationWitness';
2
2
  export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugin").PayloadSetWitnessPlugin<CurrentLocationWitness<import("@xyo-network/object").BaseParamsFields & {
3
3
  account?: import("@xyo-network/account-model").AccountInstance | "random" | undefined;
4
4
  config: import("@xyo-network/payload-model").SchemaFields & object & Omit<{
5
- accountDerivationPath?: string | undefined;
6
5
  readonly archivist?: string | undefined;
7
6
  readonly labels?: import("@xyo-network/module-model").Labels | undefined;
8
7
  readonly name?: string | undefined;
@@ -19,7 +18,6 @@ export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugi
19
18
  readonly storeQueries?: boolean | undefined;
20
19
  readonly timestamp?: boolean | undefined;
21
20
  } & import("@xyo-network/module-model").ArchivingModuleConfig & import("@xyo-network/payload-model").SchemaFields & object & {
22
- accountDerivationPath?: string | undefined;
23
21
  readonly archivist?: string | undefined;
24
22
  readonly labels?: import("@xyo-network/module-model").Labels | undefined;
25
23
  readonly name?: string | undefined;
@@ -43,7 +41,6 @@ export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugi
43
41
  schema: string;
44
42
  };
45
43
  ephemeralQueryAccountEnabled?: boolean | undefined;
46
- wallet?: import("@xyo-network/wallet-model").WalletInstance | undefined;
47
44
  } & {
48
45
  geolocation?: Geolocation | undefined;
49
46
  }>>;
@@ -1 +1 @@
1
- {"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAQxB,CAAA"}
1
+ {"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAQxB,CAAA"}
@@ -2,7 +2,6 @@ import { CurrentLocationWitness } from './CurrentLocationWitness';
2
2
  export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugin").PayloadSetWitnessPlugin<CurrentLocationWitness<import("@xyo-network/object").BaseParamsFields & {
3
3
  account?: import("@xyo-network/account-model").AccountInstance | "random" | undefined;
4
4
  config: import("@xyo-network/payload-model").SchemaFields & object & Omit<{
5
- accountDerivationPath?: string | undefined;
6
5
  readonly archivist?: string | undefined;
7
6
  readonly labels?: import("@xyo-network/module-model").Labels | undefined;
8
7
  readonly name?: string | undefined;
@@ -19,7 +18,6 @@ export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugi
19
18
  readonly storeQueries?: boolean | undefined;
20
19
  readonly timestamp?: boolean | undefined;
21
20
  } & import("@xyo-network/module-model").ArchivingModuleConfig & import("@xyo-network/payload-model").SchemaFields & object & {
22
- accountDerivationPath?: string | undefined;
23
21
  readonly archivist?: string | undefined;
24
22
  readonly labels?: import("@xyo-network/module-model").Labels | undefined;
25
23
  readonly name?: string | undefined;
@@ -43,7 +41,6 @@ export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugi
43
41
  schema: string;
44
42
  };
45
43
  ephemeralQueryAccountEnabled?: boolean | undefined;
46
- wallet?: import("@xyo-network/wallet-model").WalletInstance | undefined;
47
44
  } & {
48
45
  geolocation?: Geolocation | undefined;
49
46
  }>>;
@@ -1 +1 @@
1
- {"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAQxB,CAAA"}
1
+ {"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAQxB,CAAA"}
@@ -2,7 +2,6 @@ import { CurrentLocationWitness } from './CurrentLocationWitness';
2
2
  export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugin").PayloadSetWitnessPlugin<CurrentLocationWitness<import("@xyo-network/object").BaseParamsFields & {
3
3
  account?: import("@xyo-network/account-model").AccountInstance | "random" | undefined;
4
4
  config: import("@xyo-network/payload-model").SchemaFields & object & Omit<{
5
- accountDerivationPath?: string | undefined;
6
5
  readonly archivist?: string | undefined;
7
6
  readonly labels?: import("@xyo-network/module-model").Labels | undefined;
8
7
  readonly name?: string | undefined;
@@ -19,7 +18,6 @@ export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugi
19
18
  readonly storeQueries?: boolean | undefined;
20
19
  readonly timestamp?: boolean | undefined;
21
20
  } & import("@xyo-network/module-model").ArchivingModuleConfig & import("@xyo-network/payload-model").SchemaFields & object & {
22
- accountDerivationPath?: string | undefined;
23
21
  readonly archivist?: string | undefined;
24
22
  readonly labels?: import("@xyo-network/module-model").Labels | undefined;
25
23
  readonly name?: string | undefined;
@@ -43,7 +41,6 @@ export declare const LocationPlugin: () => import("@xyo-network/payloadset-plugi
43
41
  schema: string;
44
42
  };
45
43
  ephemeralQueryAccountEnabled?: boolean | undefined;
46
- wallet?: import("@xyo-network/wallet-model").WalletInstance | undefined;
47
44
  } & {
48
45
  geolocation?: Geolocation | undefined;
49
46
  }>>;
@@ -1 +1 @@
1
- {"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAQxB,CAAA"}
1
+ {"version":3,"file":"Plugin.d.ts","sourceRoot":"","sources":["../../src/Plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAQxB,CAAA"}
@@ -24,24 +24,30 @@ __export(src_exports, {
24
24
  CurrentLocationWitness: () => CurrentLocationWitness,
25
25
  CurrentLocationWitnessConfigSchema: () => CurrentLocationWitnessConfigSchema,
26
26
  LocationPlugin: () => LocationPlugin,
27
- default: () => src_default
27
+ default: () => LocationPlugin
28
28
  });
29
29
  module.exports = __toCommonJS(src_exports);
30
30
 
31
- // src/Plugin.ts
32
- var import_location_payload_plugin2 = require("@xyo-network/location-payload-plugin");
31
+ // src/Config.ts
32
+ var CurrentLocationWitnessConfigSchema = "network.xyo.location.current.config";
33
+
34
+ // src/CurrentLocationPayloadSet.ts
35
+ var import_location_payload_plugin = require("@xyo-network/location-payload-plugin");
33
36
  var import_payload_model = require("@xyo-network/payload-model");
34
- var import_payloadset_plugin = require("@xyo-network/payloadset-plugin");
37
+ var CurrentLocationPayloadSet = {
38
+ optional: {
39
+ [import_location_payload_plugin.LocationHeadingSchema]: 1
40
+ },
41
+ required: {
42
+ [import_location_payload_plugin.LocationSchema]: 1
43
+ },
44
+ schema: import_payload_model.PayloadSetSchema
45
+ };
35
46
 
36
47
  // src/CurrentLocationWitness.ts
37
48
  var import_assert = require("@xylabs/assert");
38
49
  var import_abstract_witness = require("@xyo-network/abstract-witness");
39
- var import_location_payload_plugin = require("@xyo-network/location-payload-plugin");
40
-
41
- // src/Config.ts
42
- var CurrentLocationWitnessConfigSchema = "network.xyo.location.current.config";
43
-
44
- // src/CurrentLocationWitness.ts
50
+ var import_location_payload_plugin2 = require("@xyo-network/location-payload-plugin");
45
51
  var CurrentLocationWitness = class extends import_abstract_witness.AbstractWitness {
46
52
  static configSchemas = [CurrentLocationWitnessConfigSchema];
47
53
  get geolocation() {
@@ -67,12 +73,12 @@ var CurrentLocationWitness = class extends import_abstract_witness.AbstractWitne
67
73
  altitudeAccuracy: location.coords.altitudeAccuracy ?? void 0,
68
74
  latitude: location.coords.latitude,
69
75
  longitude: location.coords.longitude,
70
- schema: import_location_payload_plugin.LocationSchema
76
+ schema: import_location_payload_plugin2.LocationSchema
71
77
  };
72
78
  const heading = location.coords.heading ? [
73
79
  {
74
80
  heading: location.coords.heading ?? void 0,
75
- schema: import_location_payload_plugin.LocationHeadingSchema,
81
+ schema: import_location_payload_plugin2.LocationHeadingSchema,
76
82
  speed: location.coords.speed ?? void 0
77
83
  }
78
84
  ] : [];
@@ -81,30 +87,17 @@ var CurrentLocationWitness = class extends import_abstract_witness.AbstractWitne
81
87
  };
82
88
 
83
89
  // src/Plugin.ts
90
+ var import_location_payload_plugin3 = require("@xyo-network/location-payload-plugin");
91
+ var import_payload_model2 = require("@xyo-network/payload-model");
92
+ var import_payloadset_plugin = require("@xyo-network/payloadset-plugin");
84
93
  var LocationPlugin = () => (0, import_payloadset_plugin.createPayloadSetWitnessPlugin)(
85
- { required: { [import_location_payload_plugin2.LocationSchema]: 1 }, schema: import_payload_model.PayloadSetSchema },
94
+ { required: { [import_location_payload_plugin3.LocationSchema]: 1 }, schema: import_payload_model2.PayloadSetSchema },
86
95
  {
87
96
  witness: async (params) => {
88
97
  return await CurrentLocationWitness.create(params);
89
98
  }
90
99
  }
91
100
  );
92
-
93
- // src/CurrentLocationPayloadSet.ts
94
- var import_location_payload_plugin3 = require("@xyo-network/location-payload-plugin");
95
- var import_payload_model2 = require("@xyo-network/payload-model");
96
- var CurrentLocationPayloadSet = {
97
- optional: {
98
- [import_location_payload_plugin3.LocationHeadingSchema]: 1
99
- },
100
- required: {
101
- [import_location_payload_plugin3.LocationSchema]: 1
102
- },
103
- schema: import_payload_model2.PayloadSetSchema
104
- };
105
-
106
- // src/index.ts
107
- var src_default = LocationPlugin;
108
101
  // Annotate the CommonJS export names for ESM import in node:
109
102
  0 && (module.exports = {
110
103
  CurrentLocationPayloadSet,
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/index.ts","../../src/Plugin.ts","../../src/CurrentLocationWitness.ts","../../src/Config.ts","../../src/CurrentLocationPayloadSet.ts"],"sourcesContent":["import { LocationPlugin } from './Plugin'\n\nexport * from './Config'\nexport * from './CurrentLocationPayloadSet'\nexport * from './CurrentLocationWitness'\n\nexport { LocationPlugin }\n\n// eslint-disable-next-line import/no-default-export\nexport default LocationPlugin\n","import { LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetSchema } from '@xyo-network/payload-model'\nimport { createPayloadSetWitnessPlugin } from '@xyo-network/payloadset-plugin'\n\nimport { CurrentLocationWitness } from './CurrentLocationWitness'\n\nexport const LocationPlugin = () =>\n createPayloadSetWitnessPlugin<CurrentLocationWitness>(\n { required: { [LocationSchema]: 1 }, schema: PayloadSetSchema },\n {\n witness: async (params) => {\n return await CurrentLocationWitness.create(params)\n },\n },\n )\n","import { assertEx } from '@xylabs/assert'\nimport { AbstractWitness } from '@xyo-network/abstract-witness'\nimport { LocationHeadingPayload, LocationHeadingSchema, LocationPayload, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { Payload } from '@xyo-network/payload-model'\n\nimport { CurrentLocationWitnessConfigSchema, CurrentLocationWitnessParams } from './Config'\n\nexport class CurrentLocationWitness<TParams extends CurrentLocationWitnessParams = CurrentLocationWitnessParams> extends AbstractWitness<TParams> {\n static override configSchemas = [CurrentLocationWitnessConfigSchema]\n\n get geolocation(): Geolocation {\n return assertEx(this.params.geolocation, 'No geolocation provided')\n }\n\n getCurrentPosition() {\n return new Promise<GeolocationPosition>((resolve, reject) => {\n this.geolocation?.getCurrentPosition(\n (position: GeolocationPosition) => {\n resolve(position)\n },\n (error: GeolocationPositionError) => {\n reject(error)\n },\n )\n })\n }\n\n protected override async observeHandler(): Promise<Payload[]> {\n const location = await this.getCurrentPosition()\n const locationPayload: LocationPayload = {\n altitude: location.coords.altitude ?? undefined,\n altitudeAccuracy: location.coords.altitudeAccuracy ?? undefined,\n latitude: location.coords.latitude,\n longitude: location.coords.longitude,\n schema: LocationSchema,\n }\n const heading: LocationHeadingPayload[] = location.coords.heading\n ? [\n {\n heading: location.coords.heading ?? undefined,\n schema: LocationHeadingSchema,\n speed: location.coords.speed ?? undefined,\n },\n ]\n : []\n return [locationPayload, ...heading]\n }\n}\n","import { AnyConfigSchema, ModuleParams } from '@xyo-network/module-model'\nimport { WitnessConfig } from '@xyo-network/witness-model'\n\nexport type CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\nexport const CurrentLocationWitnessConfigSchema: CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\n\nexport type CurrentLocationWitnessConfig = WitnessConfig<{\n schema: CurrentLocationWitnessConfigSchema\n}>\n\nexport type CurrentLocationWitnessParams = ModuleParams<AnyConfigSchema<CurrentLocationWitnessConfig>, { geolocation?: Geolocation }>\n","import { LocationHeadingSchema, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetPayload, PayloadSetSchema } from '@xyo-network/payload-model'\n\nexport const CurrentLocationPayloadSet: PayloadSetPayload = {\n optional: {\n [LocationHeadingSchema]: 1,\n },\n required: {\n [LocationSchema]: 1,\n },\n schema: PayloadSetSchema,\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,IAAAA,kCAA+B;AAC/B,2BAAiC;AACjC,+BAA8C;;;ACF9C,oBAAyB;AACzB,8BAAgC;AAChC,qCAA+F;;;ACExF,IAAM,qCAAyE;;;ADG/E,IAAM,yBAAN,cAAkH,wCAAyB;AAAA,EAChJ,OAAgB,gBAAgB,CAAC,kCAAkC;AAAA,EAEnE,IAAI,cAA2B;AAC7B,eAAO,wBAAS,KAAK,OAAO,aAAa,yBAAyB;AAAA,EACpE;AAAA,EAEA,qBAAqB;AACnB,WAAO,IAAI,QAA6B,CAAC,SAAS,WAAW;AAfjE;AAgBM,iBAAK,gBAAL,mBAAkB;AAAA,QAChB,CAAC,aAAkC;AACjC,kBAAQ,QAAQ;AAAA,QAClB;AAAA,QACA,CAAC,UAAoC;AACnC,iBAAO,KAAK;AAAA,QACd;AAAA;AAAA,IAEJ,CAAC;AAAA,EACH;AAAA,EAEA,MAAyB,iBAAqC;AAC5D,UAAM,WAAW,MAAM,KAAK,mBAAmB;AAC/C,UAAM,kBAAmC;AAAA,MACvC,UAAU,SAAS,OAAO,YAAY;AAAA,MACtC,kBAAkB,SAAS,OAAO,oBAAoB;AAAA,MACtD,UAAU,SAAS,OAAO;AAAA,MAC1B,WAAW,SAAS,OAAO;AAAA,MAC3B,QAAQ;AAAA,IACV;AACA,UAAM,UAAoC,SAAS,OAAO,UACtD;AAAA,MACE;AAAA,QACE,SAAS,SAAS,OAAO,WAAW;AAAA,QACpC,QAAQ;AAAA,QACR,OAAO,SAAS,OAAO,SAAS;AAAA,MAClC;AAAA,IACF,IACA,CAAC;AACL,WAAO,CAAC,iBAAiB,GAAG,OAAO;AAAA,EACrC;AACF;;;ADzCO,IAAM,iBAAiB,UAC5B;AAAA,EACE,EAAE,UAAU,EAAE,CAAC,8CAAc,GAAG,EAAE,GAAG,QAAQ,sCAAiB;AAAA,EAC9D;AAAA,IACE,SAAS,OAAO,WAAW;AACzB,aAAO,MAAM,uBAAuB,OAAO,MAAM;AAAA,IACnD;AAAA,EACF;AACF;;;AGdF,IAAAC,kCAAsD;AACtD,IAAAC,wBAAoD;AAE7C,IAAM,4BAA+C;AAAA,EAC1D,UAAU;AAAA,IACR,CAAC,qDAAqB,GAAG;AAAA,EAC3B;AAAA,EACA,UAAU;AAAA,IACR,CAAC,8CAAc,GAAG;AAAA,EACpB;AAAA,EACA,QAAQ;AACV;;;AJFA,IAAO,cAAQ;","names":["import_location_payload_plugin","import_location_payload_plugin","import_payload_model"]}
1
+ {"version":3,"sources":["../../src/index.ts","../../src/Config.ts","../../src/CurrentLocationPayloadSet.ts","../../src/CurrentLocationWitness.ts","../../src/Plugin.ts"],"sourcesContent":["export * from './Config'\nexport * from './CurrentLocationPayloadSet'\nexport * from './CurrentLocationWitness'\nexport { LocationPlugin as default, LocationPlugin } from './Plugin'\n","import { AnyConfigSchema, ModuleParams } from '@xyo-network/module-model'\nimport { WitnessConfig } from '@xyo-network/witness-model'\n\nexport type CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\nexport const CurrentLocationWitnessConfigSchema: CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\n\nexport type CurrentLocationWitnessConfig = WitnessConfig<{\n schema: CurrentLocationWitnessConfigSchema\n}>\n\nexport type CurrentLocationWitnessParams = ModuleParams<AnyConfigSchema<CurrentLocationWitnessConfig>, { geolocation?: Geolocation }>\n","import { LocationHeadingSchema, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetPayload, PayloadSetSchema } from '@xyo-network/payload-model'\n\nexport const CurrentLocationPayloadSet: PayloadSetPayload = {\n optional: {\n [LocationHeadingSchema]: 1,\n },\n required: {\n [LocationSchema]: 1,\n },\n schema: PayloadSetSchema,\n}\n","import { assertEx } from '@xylabs/assert'\nimport { AbstractWitness } from '@xyo-network/abstract-witness'\nimport { LocationHeadingPayload, LocationHeadingSchema, LocationPayload, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { Payload } from '@xyo-network/payload-model'\n\nimport { CurrentLocationWitnessConfigSchema, CurrentLocationWitnessParams } from './Config'\n\nexport class CurrentLocationWitness<TParams extends CurrentLocationWitnessParams = CurrentLocationWitnessParams> extends AbstractWitness<TParams> {\n static override configSchemas = [CurrentLocationWitnessConfigSchema]\n\n get geolocation(): Geolocation {\n return assertEx(this.params.geolocation, 'No geolocation provided')\n }\n\n getCurrentPosition() {\n return new Promise<GeolocationPosition>((resolve, reject) => {\n this.geolocation?.getCurrentPosition(\n (position: GeolocationPosition) => {\n resolve(position)\n },\n (error: GeolocationPositionError) => {\n reject(error)\n },\n )\n })\n }\n\n protected override async observeHandler(): Promise<Payload[]> {\n const location = await this.getCurrentPosition()\n const locationPayload: LocationPayload = {\n altitude: location.coords.altitude ?? undefined,\n altitudeAccuracy: location.coords.altitudeAccuracy ?? undefined,\n latitude: location.coords.latitude,\n longitude: location.coords.longitude,\n schema: LocationSchema,\n }\n const heading: LocationHeadingPayload[] = location.coords.heading\n ? [\n {\n heading: location.coords.heading ?? undefined,\n schema: LocationHeadingSchema,\n speed: location.coords.speed ?? undefined,\n },\n ]\n : []\n return [locationPayload, ...heading]\n }\n}\n","import { LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetSchema } from '@xyo-network/payload-model'\nimport { createPayloadSetWitnessPlugin } from '@xyo-network/payloadset-plugin'\n\nimport { CurrentLocationWitness } from './CurrentLocationWitness'\n\nexport const LocationPlugin = () =>\n createPayloadSetWitnessPlugin<CurrentLocationWitness>(\n { required: { [LocationSchema]: 1 }, schema: PayloadSetSchema },\n {\n witness: async (params) => {\n return await CurrentLocationWitness.create(params)\n },\n },\n )\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACIO,IAAM,qCAAyE;;;ACJtF,qCAAsD;AACtD,2BAAoD;AAE7C,IAAM,4BAA+C;AAAA,EAC1D,UAAU;AAAA,IACR,CAAC,oDAAqB,GAAG;AAAA,EAC3B;AAAA,EACA,UAAU;AAAA,IACR,CAAC,6CAAc,GAAG;AAAA,EACpB;AAAA,EACA,QAAQ;AACV;;;ACXA,oBAAyB;AACzB,8BAAgC;AAChC,IAAAA,kCAA+F;AAKxF,IAAM,yBAAN,cAAkH,wCAAyB;AAAA,EAChJ,OAAgB,gBAAgB,CAAC,kCAAkC;AAAA,EAEnE,IAAI,cAA2B;AAC7B,eAAO,wBAAS,KAAK,OAAO,aAAa,yBAAyB;AAAA,EACpE;AAAA,EAEA,qBAAqB;AACnB,WAAO,IAAI,QAA6B,CAAC,SAAS,WAAW;AAfjE;AAgBM,iBAAK,gBAAL,mBAAkB;AAAA,QAChB,CAAC,aAAkC;AACjC,kBAAQ,QAAQ;AAAA,QAClB;AAAA,QACA,CAAC,UAAoC;AACnC,iBAAO,KAAK;AAAA,QACd;AAAA;AAAA,IAEJ,CAAC;AAAA,EACH;AAAA,EAEA,MAAyB,iBAAqC;AAC5D,UAAM,WAAW,MAAM,KAAK,mBAAmB;AAC/C,UAAM,kBAAmC;AAAA,MACvC,UAAU,SAAS,OAAO,YAAY;AAAA,MACtC,kBAAkB,SAAS,OAAO,oBAAoB;AAAA,MACtD,UAAU,SAAS,OAAO;AAAA,MAC1B,WAAW,SAAS,OAAO;AAAA,MAC3B,QAAQ;AAAA,IACV;AACA,UAAM,UAAoC,SAAS,OAAO,UACtD;AAAA,MACE;AAAA,QACE,SAAS,SAAS,OAAO,WAAW;AAAA,QACpC,QAAQ;AAAA,QACR,OAAO,SAAS,OAAO,SAAS;AAAA,MAClC;AAAA,IACF,IACA,CAAC;AACL,WAAO,CAAC,iBAAiB,GAAG,OAAO;AAAA,EACrC;AACF;;;AC/CA,IAAAC,kCAA+B;AAC/B,IAAAC,wBAAiC;AACjC,+BAA8C;AAIvC,IAAM,iBAAiB,UAC5B;AAAA,EACE,EAAE,UAAU,EAAE,CAAC,8CAAc,GAAG,EAAE,GAAG,QAAQ,uCAAiB;AAAA,EAC9D;AAAA,IACE,SAAS,OAAO,WAAW;AACzB,aAAO,MAAM,uBAAuB,OAAO,MAAM;AAAA,IACnD;AAAA,EACF;AACF;","names":["import_location_payload_plugin","import_location_payload_plugin","import_payload_model"]}
@@ -1,7 +1,5 @@
1
- import { LocationPlugin } from './Plugin';
2
1
  export * from './Config';
3
2
  export * from './CurrentLocationPayloadSet';
4
3
  export * from './CurrentLocationWitness';
5
- export { LocationPlugin };
6
- export default LocationPlugin;
4
+ export { LocationPlugin as default, LocationPlugin } from './Plugin';
7
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA;AAEzC,cAAc,UAAU,CAAA;AACxB,cAAc,6BAA6B,CAAA;AAC3C,cAAc,0BAA0B,CAAA;AAExC,OAAO,EAAE,cAAc,EAAE,CAAA;AAGzB,eAAe,cAAc,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAA;AACxB,cAAc,6BAA6B,CAAA;AAC3C,cAAc,0BAA0B,CAAA;AACxC,OAAO,EAAE,cAAc,IAAI,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA"}
@@ -1,7 +1,5 @@
1
- import { LocationPlugin } from './Plugin';
2
1
  export * from './Config';
3
2
  export * from './CurrentLocationPayloadSet';
4
3
  export * from './CurrentLocationWitness';
5
- export { LocationPlugin };
6
- export default LocationPlugin;
4
+ export { LocationPlugin as default, LocationPlugin } from './Plugin';
7
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA;AAEzC,cAAc,UAAU,CAAA;AACxB,cAAc,6BAA6B,CAAA;AAC3C,cAAc,0BAA0B,CAAA;AAExC,OAAO,EAAE,cAAc,EAAE,CAAA;AAGzB,eAAe,cAAc,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAA;AACxB,cAAc,6BAA6B,CAAA;AAC3C,cAAc,0BAA0B,CAAA;AACxC,OAAO,EAAE,cAAc,IAAI,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA"}
@@ -1,7 +1,5 @@
1
- import { LocationPlugin } from './Plugin';
2
1
  export * from './Config';
3
2
  export * from './CurrentLocationPayloadSet';
4
3
  export * from './CurrentLocationWitness';
5
- export { LocationPlugin };
6
- export default LocationPlugin;
4
+ export { LocationPlugin as default, LocationPlugin } from './Plugin';
7
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA;AAEzC,cAAc,UAAU,CAAA;AACxB,cAAc,6BAA6B,CAAA;AAC3C,cAAc,0BAA0B,CAAA;AAExC,OAAO,EAAE,cAAc,EAAE,CAAA;AAGzB,eAAe,cAAc,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAA;AACxB,cAAc,6BAA6B,CAAA;AAC3C,cAAc,0BAA0B,CAAA;AACxC,OAAO,EAAE,cAAc,IAAI,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA"}
@@ -1,17 +1,23 @@
1
- // src/Plugin.ts
2
- import { LocationSchema as LocationSchema2 } from "@xyo-network/location-payload-plugin";
1
+ // src/Config.ts
2
+ var CurrentLocationWitnessConfigSchema = "network.xyo.location.current.config";
3
+
4
+ // src/CurrentLocationPayloadSet.ts
5
+ import { LocationHeadingSchema, LocationSchema } from "@xyo-network/location-payload-plugin";
3
6
  import { PayloadSetSchema } from "@xyo-network/payload-model";
4
- import { createPayloadSetWitnessPlugin } from "@xyo-network/payloadset-plugin";
7
+ var CurrentLocationPayloadSet = {
8
+ optional: {
9
+ [LocationHeadingSchema]: 1
10
+ },
11
+ required: {
12
+ [LocationSchema]: 1
13
+ },
14
+ schema: PayloadSetSchema
15
+ };
5
16
 
6
17
  // src/CurrentLocationWitness.ts
7
18
  import { assertEx } from "@xylabs/assert";
8
19
  import { AbstractWitness } from "@xyo-network/abstract-witness";
9
- import { LocationHeadingSchema, LocationSchema } from "@xyo-network/location-payload-plugin";
10
-
11
- // src/Config.ts
12
- var CurrentLocationWitnessConfigSchema = "network.xyo.location.current.config";
13
-
14
- // src/CurrentLocationWitness.ts
20
+ import { LocationHeadingSchema as LocationHeadingSchema2, LocationSchema as LocationSchema2 } from "@xyo-network/location-payload-plugin";
15
21
  var CurrentLocationWitness = class extends AbstractWitness {
16
22
  static configSchemas = [CurrentLocationWitnessConfigSchema];
17
23
  get geolocation() {
@@ -37,12 +43,12 @@ var CurrentLocationWitness = class extends AbstractWitness {
37
43
  altitudeAccuracy: location.coords.altitudeAccuracy ?? void 0,
38
44
  latitude: location.coords.latitude,
39
45
  longitude: location.coords.longitude,
40
- schema: LocationSchema
46
+ schema: LocationSchema2
41
47
  };
42
48
  const heading = location.coords.heading ? [
43
49
  {
44
50
  heading: location.coords.heading ?? void 0,
45
- schema: LocationHeadingSchema,
51
+ schema: LocationHeadingSchema2,
46
52
  speed: location.coords.speed ?? void 0
47
53
  }
48
54
  ] : [];
@@ -51,35 +57,22 @@ var CurrentLocationWitness = class extends AbstractWitness {
51
57
  };
52
58
 
53
59
  // src/Plugin.ts
60
+ import { LocationSchema as LocationSchema3 } from "@xyo-network/location-payload-plugin";
61
+ import { PayloadSetSchema as PayloadSetSchema2 } from "@xyo-network/payload-model";
62
+ import { createPayloadSetWitnessPlugin } from "@xyo-network/payloadset-plugin";
54
63
  var LocationPlugin = () => createPayloadSetWitnessPlugin(
55
- { required: { [LocationSchema2]: 1 }, schema: PayloadSetSchema },
64
+ { required: { [LocationSchema3]: 1 }, schema: PayloadSetSchema2 },
56
65
  {
57
66
  witness: async (params) => {
58
67
  return await CurrentLocationWitness.create(params);
59
68
  }
60
69
  }
61
70
  );
62
-
63
- // src/CurrentLocationPayloadSet.ts
64
- import { LocationHeadingSchema as LocationHeadingSchema2, LocationSchema as LocationSchema3 } from "@xyo-network/location-payload-plugin";
65
- import { PayloadSetSchema as PayloadSetSchema2 } from "@xyo-network/payload-model";
66
- var CurrentLocationPayloadSet = {
67
- optional: {
68
- [LocationHeadingSchema2]: 1
69
- },
70
- required: {
71
- [LocationSchema3]: 1
72
- },
73
- schema: PayloadSetSchema2
74
- };
75
-
76
- // src/index.ts
77
- var src_default = LocationPlugin;
78
71
  export {
79
72
  CurrentLocationPayloadSet,
80
73
  CurrentLocationWitness,
81
74
  CurrentLocationWitnessConfigSchema,
82
75
  LocationPlugin,
83
- src_default as default
76
+ LocationPlugin as default
84
77
  };
85
78
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/Plugin.ts","../../src/CurrentLocationWitness.ts","../../src/Config.ts","../../src/CurrentLocationPayloadSet.ts","../../src/index.ts"],"sourcesContent":["import { LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetSchema } from '@xyo-network/payload-model'\nimport { createPayloadSetWitnessPlugin } from '@xyo-network/payloadset-plugin'\n\nimport { CurrentLocationWitness } from './CurrentLocationWitness'\n\nexport const LocationPlugin = () =>\n createPayloadSetWitnessPlugin<CurrentLocationWitness>(\n { required: { [LocationSchema]: 1 }, schema: PayloadSetSchema },\n {\n witness: async (params) => {\n return await CurrentLocationWitness.create(params)\n },\n },\n )\n","import { assertEx } from '@xylabs/assert'\nimport { AbstractWitness } from '@xyo-network/abstract-witness'\nimport { LocationHeadingPayload, LocationHeadingSchema, LocationPayload, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { Payload } from '@xyo-network/payload-model'\n\nimport { CurrentLocationWitnessConfigSchema, CurrentLocationWitnessParams } from './Config'\n\nexport class CurrentLocationWitness<TParams extends CurrentLocationWitnessParams = CurrentLocationWitnessParams> extends AbstractWitness<TParams> {\n static override configSchemas = [CurrentLocationWitnessConfigSchema]\n\n get geolocation(): Geolocation {\n return assertEx(this.params.geolocation, 'No geolocation provided')\n }\n\n getCurrentPosition() {\n return new Promise<GeolocationPosition>((resolve, reject) => {\n this.geolocation?.getCurrentPosition(\n (position: GeolocationPosition) => {\n resolve(position)\n },\n (error: GeolocationPositionError) => {\n reject(error)\n },\n )\n })\n }\n\n protected override async observeHandler(): Promise<Payload[]> {\n const location = await this.getCurrentPosition()\n const locationPayload: LocationPayload = {\n altitude: location.coords.altitude ?? undefined,\n altitudeAccuracy: location.coords.altitudeAccuracy ?? undefined,\n latitude: location.coords.latitude,\n longitude: location.coords.longitude,\n schema: LocationSchema,\n }\n const heading: LocationHeadingPayload[] = location.coords.heading\n ? [\n {\n heading: location.coords.heading ?? undefined,\n schema: LocationHeadingSchema,\n speed: location.coords.speed ?? undefined,\n },\n ]\n : []\n return [locationPayload, ...heading]\n }\n}\n","import { AnyConfigSchema, ModuleParams } from '@xyo-network/module-model'\nimport { WitnessConfig } from '@xyo-network/witness-model'\n\nexport type CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\nexport const CurrentLocationWitnessConfigSchema: CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\n\nexport type CurrentLocationWitnessConfig = WitnessConfig<{\n schema: CurrentLocationWitnessConfigSchema\n}>\n\nexport type CurrentLocationWitnessParams = ModuleParams<AnyConfigSchema<CurrentLocationWitnessConfig>, { geolocation?: Geolocation }>\n","import { LocationHeadingSchema, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetPayload, PayloadSetSchema } from '@xyo-network/payload-model'\n\nexport const CurrentLocationPayloadSet: PayloadSetPayload = {\n optional: {\n [LocationHeadingSchema]: 1,\n },\n required: {\n [LocationSchema]: 1,\n },\n schema: PayloadSetSchema,\n}\n","import { LocationPlugin } from './Plugin'\n\nexport * from './Config'\nexport * from './CurrentLocationPayloadSet'\nexport * from './CurrentLocationWitness'\n\nexport { LocationPlugin }\n\n// eslint-disable-next-line import/no-default-export\nexport default LocationPlugin\n"],"mappings":";AAAA,SAAS,kBAAAA,uBAAsB;AAC/B,SAAS,wBAAwB;AACjC,SAAS,qCAAqC;;;ACF9C,SAAS,gBAAgB;AACzB,SAAS,uBAAuB;AAChC,SAAiC,uBAAwC,sBAAsB;;;ACExF,IAAM,qCAAyE;;;ADG/E,IAAM,yBAAN,cAAkH,gBAAyB;AAAA,EAChJ,OAAgB,gBAAgB,CAAC,kCAAkC;AAAA,EAEnE,IAAI,cAA2B;AAC7B,WAAO,SAAS,KAAK,OAAO,aAAa,yBAAyB;AAAA,EACpE;AAAA,EAEA,qBAAqB;AACnB,WAAO,IAAI,QAA6B,CAAC,SAAS,WAAW;AAfjE;AAgBM,iBAAK,gBAAL,mBAAkB;AAAA,QAChB,CAAC,aAAkC;AACjC,kBAAQ,QAAQ;AAAA,QAClB;AAAA,QACA,CAAC,UAAoC;AACnC,iBAAO,KAAK;AAAA,QACd;AAAA;AAAA,IAEJ,CAAC;AAAA,EACH;AAAA,EAEA,MAAyB,iBAAqC;AAC5D,UAAM,WAAW,MAAM,KAAK,mBAAmB;AAC/C,UAAM,kBAAmC;AAAA,MACvC,UAAU,SAAS,OAAO,YAAY;AAAA,MACtC,kBAAkB,SAAS,OAAO,oBAAoB;AAAA,MACtD,UAAU,SAAS,OAAO;AAAA,MAC1B,WAAW,SAAS,OAAO;AAAA,MAC3B,QAAQ;AAAA,IACV;AACA,UAAM,UAAoC,SAAS,OAAO,UACtD;AAAA,MACE;AAAA,QACE,SAAS,SAAS,OAAO,WAAW;AAAA,QACpC,QAAQ;AAAA,QACR,OAAO,SAAS,OAAO,SAAS;AAAA,MAClC;AAAA,IACF,IACA,CAAC;AACL,WAAO,CAAC,iBAAiB,GAAG,OAAO;AAAA,EACrC;AACF;;;ADzCO,IAAM,iBAAiB,MAC5B;AAAA,EACE,EAAE,UAAU,EAAE,CAACC,eAAc,GAAG,EAAE,GAAG,QAAQ,iBAAiB;AAAA,EAC9D;AAAA,IACE,SAAS,OAAO,WAAW;AACzB,aAAO,MAAM,uBAAuB,OAAO,MAAM;AAAA,IACnD;AAAA,EACF;AACF;;;AGdF,SAAS,yBAAAC,wBAAuB,kBAAAC,uBAAsB;AACtD,SAA4B,oBAAAC,yBAAwB;AAE7C,IAAM,4BAA+C;AAAA,EAC1D,UAAU;AAAA,IACR,CAACF,sBAAqB,GAAG;AAAA,EAC3B;AAAA,EACA,UAAU;AAAA,IACR,CAACC,eAAc,GAAG;AAAA,EACpB;AAAA,EACA,QAAQC;AACV;;;ACFA,IAAO,cAAQ;","names":["LocationSchema","LocationSchema","LocationHeadingSchema","LocationSchema","PayloadSetSchema"]}
1
+ {"version":3,"sources":["../../src/Config.ts","../../src/CurrentLocationPayloadSet.ts","../../src/CurrentLocationWitness.ts","../../src/Plugin.ts"],"sourcesContent":["import { AnyConfigSchema, ModuleParams } from '@xyo-network/module-model'\nimport { WitnessConfig } from '@xyo-network/witness-model'\n\nexport type CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\nexport const CurrentLocationWitnessConfigSchema: CurrentLocationWitnessConfigSchema = 'network.xyo.location.current.config'\n\nexport type CurrentLocationWitnessConfig = WitnessConfig<{\n schema: CurrentLocationWitnessConfigSchema\n}>\n\nexport type CurrentLocationWitnessParams = ModuleParams<AnyConfigSchema<CurrentLocationWitnessConfig>, { geolocation?: Geolocation }>\n","import { LocationHeadingSchema, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetPayload, PayloadSetSchema } from '@xyo-network/payload-model'\n\nexport const CurrentLocationPayloadSet: PayloadSetPayload = {\n optional: {\n [LocationHeadingSchema]: 1,\n },\n required: {\n [LocationSchema]: 1,\n },\n schema: PayloadSetSchema,\n}\n","import { assertEx } from '@xylabs/assert'\nimport { AbstractWitness } from '@xyo-network/abstract-witness'\nimport { LocationHeadingPayload, LocationHeadingSchema, LocationPayload, LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { Payload } from '@xyo-network/payload-model'\n\nimport { CurrentLocationWitnessConfigSchema, CurrentLocationWitnessParams } from './Config'\n\nexport class CurrentLocationWitness<TParams extends CurrentLocationWitnessParams = CurrentLocationWitnessParams> extends AbstractWitness<TParams> {\n static override configSchemas = [CurrentLocationWitnessConfigSchema]\n\n get geolocation(): Geolocation {\n return assertEx(this.params.geolocation, 'No geolocation provided')\n }\n\n getCurrentPosition() {\n return new Promise<GeolocationPosition>((resolve, reject) => {\n this.geolocation?.getCurrentPosition(\n (position: GeolocationPosition) => {\n resolve(position)\n },\n (error: GeolocationPositionError) => {\n reject(error)\n },\n )\n })\n }\n\n protected override async observeHandler(): Promise<Payload[]> {\n const location = await this.getCurrentPosition()\n const locationPayload: LocationPayload = {\n altitude: location.coords.altitude ?? undefined,\n altitudeAccuracy: location.coords.altitudeAccuracy ?? undefined,\n latitude: location.coords.latitude,\n longitude: location.coords.longitude,\n schema: LocationSchema,\n }\n const heading: LocationHeadingPayload[] = location.coords.heading\n ? [\n {\n heading: location.coords.heading ?? undefined,\n schema: LocationHeadingSchema,\n speed: location.coords.speed ?? undefined,\n },\n ]\n : []\n return [locationPayload, ...heading]\n }\n}\n","import { LocationSchema } from '@xyo-network/location-payload-plugin'\nimport { PayloadSetSchema } from '@xyo-network/payload-model'\nimport { createPayloadSetWitnessPlugin } from '@xyo-network/payloadset-plugin'\n\nimport { CurrentLocationWitness } from './CurrentLocationWitness'\n\nexport const LocationPlugin = () =>\n createPayloadSetWitnessPlugin<CurrentLocationWitness>(\n { required: { [LocationSchema]: 1 }, schema: PayloadSetSchema },\n {\n witness: async (params) => {\n return await CurrentLocationWitness.create(params)\n },\n },\n )\n"],"mappings":";AAIO,IAAM,qCAAyE;;;ACJtF,SAAS,uBAAuB,sBAAsB;AACtD,SAA4B,wBAAwB;AAE7C,IAAM,4BAA+C;AAAA,EAC1D,UAAU;AAAA,IACR,CAAC,qBAAqB,GAAG;AAAA,EAC3B;AAAA,EACA,UAAU;AAAA,IACR,CAAC,cAAc,GAAG;AAAA,EACpB;AAAA,EACA,QAAQ;AACV;;;ACXA,SAAS,gBAAgB;AACzB,SAAS,uBAAuB;AAChC,SAAiC,yBAAAA,wBAAwC,kBAAAC,uBAAsB;AAKxF,IAAM,yBAAN,cAAkH,gBAAyB;AAAA,EAChJ,OAAgB,gBAAgB,CAAC,kCAAkC;AAAA,EAEnE,IAAI,cAA2B;AAC7B,WAAO,SAAS,KAAK,OAAO,aAAa,yBAAyB;AAAA,EACpE;AAAA,EAEA,qBAAqB;AACnB,WAAO,IAAI,QAA6B,CAAC,SAAS,WAAW;AAfjE;AAgBM,iBAAK,gBAAL,mBAAkB;AAAA,QAChB,CAAC,aAAkC;AACjC,kBAAQ,QAAQ;AAAA,QAClB;AAAA,QACA,CAAC,UAAoC;AACnC,iBAAO,KAAK;AAAA,QACd;AAAA;AAAA,IAEJ,CAAC;AAAA,EACH;AAAA,EAEA,MAAyB,iBAAqC;AAC5D,UAAM,WAAW,MAAM,KAAK,mBAAmB;AAC/C,UAAM,kBAAmC;AAAA,MACvC,UAAU,SAAS,OAAO,YAAY;AAAA,MACtC,kBAAkB,SAAS,OAAO,oBAAoB;AAAA,MACtD,UAAU,SAAS,OAAO;AAAA,MAC1B,WAAW,SAAS,OAAO;AAAA,MAC3B,QAAQC;AAAA,IACV;AACA,UAAM,UAAoC,SAAS,OAAO,UACtD;AAAA,MACE;AAAA,QACE,SAAS,SAAS,OAAO,WAAW;AAAA,QACpC,QAAQC;AAAA,QACR,OAAO,SAAS,OAAO,SAAS;AAAA,MAClC;AAAA,IACF,IACA,CAAC;AACL,WAAO,CAAC,iBAAiB,GAAG,OAAO;AAAA,EACrC;AACF;;;AC/CA,SAAS,kBAAAC,uBAAsB;AAC/B,SAAS,oBAAAC,yBAAwB;AACjC,SAAS,qCAAqC;AAIvC,IAAM,iBAAiB,MAC5B;AAAA,EACE,EAAE,UAAU,EAAE,CAACC,eAAc,GAAG,EAAE,GAAG,QAAQC,kBAAiB;AAAA,EAC9D;AAAA,IACE,SAAS,OAAO,WAAW;AACzB,aAAO,MAAM,uBAAuB,OAAO,MAAM;AAAA,IACnD;AAAA,EACF;AACF;","names":["LocationHeadingSchema","LocationSchema","LocationSchema","LocationHeadingSchema","LocationSchema","PayloadSetSchema","LocationSchema","PayloadSetSchema"]}
package/package.json CHANGED
@@ -10,13 +10,13 @@
10
10
  "url": "https://github.com/XYOracleNetwork/plugins/issues"
11
11
  },
12
12
  "dependencies": {
13
- "@xylabs/assert": "^2.13.20",
14
- "@xyo-network/abstract-witness": "^2.84.18",
15
- "@xyo-network/location-payload-plugin": "~2.84.5",
16
- "@xyo-network/module-model": "^2.84.18",
17
- "@xyo-network/payload-model": "^2.84.18",
18
- "@xyo-network/payloadset-plugin": "^2.84.18",
19
- "@xyo-network/witness-model": "^2.84.18"
13
+ "@xylabs/assert": "^2.13.22",
14
+ "@xyo-network/abstract-witness": "^2.85.3",
15
+ "@xyo-network/location-payload-plugin": "~2.85.1",
16
+ "@xyo-network/module-model": "^2.85.3",
17
+ "@xyo-network/payload-model": "^2.85.3",
18
+ "@xyo-network/payloadset-plugin": "^2.85.3",
19
+ "@xyo-network/witness-model": "^2.85.3"
20
20
  },
21
21
  "devDependencies": {
22
22
  "@xylabs/ts-scripts-yarn3": "^3.2.25",
@@ -63,6 +63,6 @@
63
63
  "url": "https://github.com/XYOracleNetwork/plugins.git"
64
64
  },
65
65
  "sideEffects": false,
66
- "version": "2.84.5",
66
+ "version": "2.85.1",
67
67
  "type": "module"
68
68
  }
package/src/index.ts CHANGED
@@ -1,10 +1,4 @@
1
- import { LocationPlugin } from './Plugin'
2
-
3
1
  export * from './Config'
4
2
  export * from './CurrentLocationPayloadSet'
5
3
  export * from './CurrentLocationWitness'
6
-
7
- export { LocationPlugin }
8
-
9
- // eslint-disable-next-line import/no-default-export
10
- export default LocationPlugin
4
+ export { LocationPlugin as default, LocationPlugin } from './Plugin'