@datapos/datapos-shared 0.3.528 → 0.3.529

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.
@@ -1,9 +1,9 @@
1
- async function a(e, o) {
2
- const n = `datapos-tool-${o}`, t = e.find((r) => r.id === n);
3
- if (!t) throw new Error(`Connector could not load unknown tool '${o}'.`);
4
- const l = await import(`https://engine-eu.datapos.app/tools/${o}_v${t.version}/${n}.es.js`);
5
- return new l.Tool();
1
+ async function e(t, o) {
2
+ const n = t.find((l) => l.id === o);
3
+ if (!n) throw new Error(`Connector could not load unknown tool '${o}'.`);
4
+ const r = await import(`https://engine-eu.datapos.app/tools/${o}_v${n.version}/${o}.es.js`);
5
+ return new r.Tool();
6
6
  }
7
7
  export {
8
- a as loadTool
8
+ e as loadTool
9
9
  };
@@ -4,5 +4,4 @@ import { moduleConfigSchema, moduleTypeIdSchema } from './moduleConfig.schema';
4
4
  type ModuleConfig = InferOutput<typeof moduleConfigSchema>;
5
5
  /** Module type identifier. */
6
6
  type ModuleTypeId = InferOutput<typeof moduleTypeIdSchema>;
7
- /** Exports. */
8
7
  export type { ModuleConfig, ModuleTypeId };
@@ -1,10 +1,13 @@
1
1
  import { ModuleConfig } from '../module';
2
- /** Tool configuration. */
2
+ /**
3
+ * Tool configuration.
4
+ */
3
5
  interface ToolConfig extends ModuleConfig {
4
6
  typeId: 'tool';
5
7
  }
6
- /** Load tool. */
7
- declare function loadTool<T>(toolConfigs: ToolConfig[], toolId: string): Promise<T>;
8
- /** Exports. */
8
+ /**
9
+ * Load tool.
10
+ */
11
+ declare function loadTool<T>(toolConfigs: ToolConfig[], toolName: string): Promise<T>;
9
12
  export { loadTool };
10
13
  export type { ToolConfig };
@@ -85,7 +85,6 @@ declare function serialiseError(error?: unknown): SerialisedError[];
85
85
  * - Returns `undefined` if the input array is empty.
86
86
  */
87
87
  declare function unserialiseError(serialisedErrors: SerialisedError[]): Error | undefined;
88
- /** Exports. */
89
88
  export type { SerialisedError };
90
89
  export { ApplicationError, APIError, EngineError, FetchError, OperationalError, VueHandledError, WindowHandledRuntimeError, WindowHandledPromiseRejectionError };
91
90
  export { buildFetchError, concatenateSerialisedErrorMessages, ignoreErrors, normalizeToError, serialiseError, unserialiseError };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@datapos/datapos-shared",
3
- "version": "0.3.528",
3
+ "version": "0.3.529",
4
4
  "description": "A library containing common constants, types and utilities used across all Data Positioning projects.",
5
5
  "license": "MIT",
6
6
  "author": "Jonathan Terrell <terrell.jm@gmail.com>",