File tree Expand file tree Collapse file tree 3 files changed +28
-7
lines changed Expand file tree Collapse file tree 3 files changed +28
-7
lines changed Original file line number Diff line number Diff line change @@ -35,6 +35,10 @@ src/core/auth/ConnectTokenProvider.ts
35
35
src/core/auth/StaticTokenProvider.ts
36
36
src/core/auth/TokenProvider.ts
37
37
38
+ # Custom configuration props files
39
+ src/api/types/ConfiguredProps.ts
40
+ src/serialization/types/ConfiguredProps.ts
41
+
38
42
# Custom Proxy files
39
43
src/api/resources/proxy/client/requests/ProxyPutRequest.ts
40
44
src/api/resources/proxy/client/requests/ProxyGetRequest.ts
Original file line number Diff line number Diff line change 1
- /**
2
- * This file was auto-generated by Fern from our API Definition.
3
- */
1
+ import type * as Pipedream from "./index.js" ;
2
+
3
+ export type ConfigurableProps = Readonly < Pipedream . ConfigurableProp [ ] > ;
4
4
5
- import * as Pipedream from "../index.js" ;
5
+ export type PropTypeMap = {
6
+ alert : never ;
7
+ any : Pipedream . ConfiguredPropValueAny ;
8
+ app : Pipedream . ConfiguredPropValueApp ;
9
+ boolean : Pipedream . ConfiguredPropValueBoolean ;
10
+ integer : Pipedream . ConfiguredPropValueInteger ;
11
+ object : Pipedream . ConfiguredPropValueObject ;
12
+ string : Pipedream . ConfiguredPropValueString ;
13
+ "string[]" : Pipedream . ConfiguredPropValueStringArray ;
14
+ sql : Pipedream . ConfiguredPropValueSql ;
15
+ } ;
16
+ export type PropValue < T extends Pipedream . ConfigurableProp [ "type" ] > = T extends keyof PropTypeMap
17
+ ? PropTypeMap [ T ]
18
+ : never ;
6
19
7
20
/**
8
21
* The configured properties of the component
9
22
*/
10
- export type ConfiguredProps = Record < string , Pipedream . ConfiguredPropValue > ;
23
+ export type ConfiguredProps < T extends ConfigurableProps = ConfigurableProps > = {
24
+ [ K in T [ number ] as K [ "name" ] ] ?: PropValue < K [ "type" ] > ;
25
+ } ;
Original file line number Diff line number Diff line change @@ -7,8 +7,10 @@ import * as Pipedream from "../../api/index.js";
7
7
import * as core from "../../core/index.js" ;
8
8
import { ConfiguredPropValue } from "./ConfiguredPropValue.js" ;
9
9
10
- export const ConfiguredProps : core . serialization . Schema < serializers . ConfiguredProps . Raw , Pipedream . ConfiguredProps > =
11
- core . serialization . record ( core . serialization . string ( ) , ConfiguredPropValue ) ;
10
+ export const ConfiguredProps : core . serialization . Schema <
11
+ serializers . ConfiguredProps . Raw ,
12
+ Pipedream . ConfiguredProps < any >
13
+ > = core . serialization . record ( core . serialization . string ( ) , ConfiguredPropValue ) as any ;
12
14
13
15
export declare namespace ConfiguredProps {
14
16
export type Raw = Record < string , ConfiguredPropValue . Raw > ;
You can’t perform that action at this time.
0 commit comments