@sdlcworks/components 0.0.16 → 0.0.18

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/index.d.ts CHANGED
@@ -149,6 +149,13 @@ export type ConnectionHandlerEntry<S, ConnectionType extends string, C extends C
149
149
  interface: C;
150
150
  handler: (ctx: ConnectionHandlerCtx<S, InferConnectionData<C>, ConnectionType>) => Promise<ConnectionHandlerResult>;
151
151
  };
152
+ export declare function connectionHandler<C extends ConnectionInterfaceClass>(entry: {
153
+ interface: C;
154
+ handler: (ctx: ConnectionHandlerCtx<any, InferConnectionData<C>, any>) => Promise<ConnectionHandlerResult>;
155
+ }): {
156
+ interface: C;
157
+ handler: (ctx: ConnectionHandlerCtx<any, InferConnectionData<C>, any>) => Promise<ConnectionHandlerResult>;
158
+ };
152
159
  export type ProviderDeployCtx<D, S> = {
153
160
  state: S;
154
161
  } & Record<string, DeploymentInfo>;
package/dist/index.js CHANGED
@@ -58,6 +58,9 @@ var InfraComponentOptsSchema = z.object({
58
58
  deploymentInputSchema: z.custom(),
59
59
  outputSchema: z.custom()
60
60
  });
61
+ function connectionHandler(entry) {
62
+ return entry;
63
+ }
61
64
  var emptyStateSchema = z.object({});
62
65
 
63
66
  class InfraComponent {
@@ -102,6 +105,7 @@ class InfraComponent {
102
105
  }
103
106
  export {
104
107
  createConnectionInterface,
108
+ connectionHandler,
105
109
  InfraComponent,
106
110
  DeploymentArtifactType,
107
111
  ConnectionInterface,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sdlcworks/components",
3
- "version": "0.0.16",
3
+ "version": "0.0.18",
4
4
  "module": "dist/index.js",
5
5
  "files": [
6
6
  "dist"