@useparagon/connect 2.0.1 → 2.0.2
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/src/ConnectSDK.d.ts +4 -13
- package/dist/src/ConnectSDK.js +1 -1
- package/dist/src/index.js +1 -1
- package/dist/src/types/action.d.ts +23 -2
- package/dist/src/types/sdk.d.ts +4 -13
- package/package.json +1 -1
|
@@ -38,6 +38,25 @@ export declare enum SidebarInputType {
|
|
|
38
38
|
CopyableButtonInput = "COPYABLE_BUTTON_INPUT",
|
|
39
39
|
Permission = "PERMISSION"
|
|
40
40
|
}
|
|
41
|
+
export declare enum VariableInputType {
|
|
42
|
+
MultiSelect = "multi",
|
|
43
|
+
String = "string",
|
|
44
|
+
Dropdown = "dropdown",
|
|
45
|
+
MultiSelectCheckbox = "multiCheckbox",
|
|
46
|
+
Number = "number"
|
|
47
|
+
}
|
|
48
|
+
export type DynamicDefaultInput = {
|
|
49
|
+
required: boolean;
|
|
50
|
+
id: string;
|
|
51
|
+
title: string;
|
|
52
|
+
type: VariableInputType;
|
|
53
|
+
items: EnumInputValue[];
|
|
54
|
+
supportDifferentTextFormat: boolean;
|
|
55
|
+
textFormat: string;
|
|
56
|
+
identifierKey: string;
|
|
57
|
+
supportAddItem?: boolean;
|
|
58
|
+
returnsArrayStrings?: boolean;
|
|
59
|
+
};
|
|
41
60
|
interface BaseInput {
|
|
42
61
|
id: string;
|
|
43
62
|
title: string;
|
|
@@ -156,7 +175,7 @@ type EnumSection<T = any> = {
|
|
|
156
175
|
title: string;
|
|
157
176
|
items: EnumInputValue<T>[];
|
|
158
177
|
};
|
|
159
|
-
type EnumInputValue<T = any> = {
|
|
178
|
+
export type EnumInputValue<T = any> = {
|
|
160
179
|
value: T;
|
|
161
180
|
label: string;
|
|
162
181
|
/**
|
|
@@ -292,10 +311,12 @@ type StaticEnumDataSource = BasicDataSource & {
|
|
|
292
311
|
* A FieldMapperDataSource refers to a source that is able to drive an input that is responsible
|
|
293
312
|
* for mapping remote/integration fields to local/project fields.
|
|
294
313
|
*/
|
|
295
|
-
type FieldMapperDataSource = BasicDataSource & {
|
|
314
|
+
export type FieldMapperDataSource = BasicDataSource & {
|
|
296
315
|
id: string;
|
|
297
316
|
type: DataSourceType.FIELD_MAPPER;
|
|
298
317
|
recordSource: DynamicDataSource<(EnumSection | EnumInputValue)[]>;
|
|
318
|
+
dependentInputSource?: DynamicDataSource<(EnumSection | EnumInputValue)[]>;
|
|
319
|
+
dependentFieldInputSource?: DynamicDataSource<(EnumSection | EnumInputValue)[]>;
|
|
299
320
|
fieldSource: DynamicDataSource<(EnumSection | EnumInputValue)[]>;
|
|
300
321
|
};
|
|
301
322
|
/**
|
package/dist/src/types/sdk.d.ts
CHANGED
|
@@ -8,7 +8,7 @@ import { PersonaMeta } from '../entities/persona.interface';
|
|
|
8
8
|
import { IConnectUserContext } from '../helpers/ConnectUserContext';
|
|
9
9
|
import { ConnectSdkEnvironments } from '../server.types';
|
|
10
10
|
import { AuthenticatedConnectUser, DisableWorkflowOptions, DynamicMappingField, DynamicMappingOptions, GetIntegrationAccountOptions, IntegrationWorkflowMeta, IntegrationWorkflowState, SerializedConnectInput, UninstallOptions } from '../types/connect';
|
|
11
|
-
import {
|
|
11
|
+
import { DataSource, DynamicDefaultInput, EnumInputValue } from './action';
|
|
12
12
|
import { Props as ConnectModalProps } from './connectModal';
|
|
13
13
|
import { DataType, KeyedSource } from './resolvers';
|
|
14
14
|
export type ConnectUser = {
|
|
@@ -229,20 +229,11 @@ export interface IConnectSDK {
|
|
|
229
229
|
cursor?: string | number | false;
|
|
230
230
|
parameters?: KeyedSource<DataType.ANY>[];
|
|
231
231
|
}): Promise<{
|
|
232
|
-
data:
|
|
233
|
-
|
|
234
|
-
label: string;
|
|
235
|
-
}[];
|
|
236
|
-
nestedData: {
|
|
237
|
-
title: string;
|
|
238
|
-
items: {
|
|
239
|
-
value: string;
|
|
240
|
-
label: string;
|
|
241
|
-
}[];
|
|
242
|
-
}[];
|
|
232
|
+
data: EnumInputValue[];
|
|
233
|
+
nestedData: DynamicDefaultInput[];
|
|
243
234
|
nextPageCursor: string | null;
|
|
244
235
|
}>;
|
|
245
|
-
getDataSourceOptions(integrationName: string, action: string): Promise<
|
|
236
|
+
getDataSourceOptions(integrationName: string, action: string): Promise<DataSource | undefined>;
|
|
246
237
|
installFlow: InstallFlow;
|
|
247
238
|
}
|
|
248
239
|
/**
|