@useparagon/connect 2.0.4-experimental.6 → 2.0.4
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.
|
@@ -39,10 +39,5 @@ export type Props = {
|
|
|
39
39
|
apiInstallationOptions?: ModalApiInstallationOptions;
|
|
40
40
|
connectionError?: ParagonError | undefined;
|
|
41
41
|
selectedCredentialId?: string;
|
|
42
|
-
/**
|
|
43
|
-
* This flag is used to show the portal after the oauth flow is complete
|
|
44
|
-
* This flag is set to true when the installIntegration method is called with showPortalAfterInstall option
|
|
45
|
-
*/
|
|
46
|
-
shouldShowPortalAfterInstall?: boolean;
|
|
47
42
|
};
|
|
48
43
|
export {};
|
package/dist/src/types/sdk.d.ts
CHANGED
|
@@ -387,27 +387,11 @@ export type FilePickerOptions = {
|
|
|
387
387
|
viewMode?: google.picker.DocsViewMode;
|
|
388
388
|
includeFolders?: boolean;
|
|
389
389
|
};
|
|
390
|
-
box?: {
|
|
391
|
-
container?: string;
|
|
392
|
-
maxSelectable?: number;
|
|
393
|
-
canUpload?: boolean;
|
|
394
|
-
canCreateNewFolder?: boolean;
|
|
395
|
-
canSetShareAccess?: boolean;
|
|
396
|
-
canDownload?: boolean;
|
|
397
|
-
canDelete?: boolean;
|
|
398
|
-
canRename?: boolean;
|
|
399
|
-
canPreview?: boolean;
|
|
400
|
-
canComment?: boolean;
|
|
401
|
-
canShare?: boolean;
|
|
402
|
-
canMove?: boolean;
|
|
403
|
-
canCopy?: boolean;
|
|
404
|
-
};
|
|
405
390
|
};
|
|
406
391
|
};
|
|
407
392
|
export type FilePickerInitOptions = {
|
|
408
393
|
developerKey: string;
|
|
409
394
|
appId?: string;
|
|
410
|
-
folderId?: string;
|
|
411
395
|
};
|
|
412
396
|
export declare enum FilePickerStatus {
|
|
413
397
|
LOADING = "loading",
|
package/package.json
CHANGED
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
import ConnectSDK from '../../ConnectSDK';
|
|
2
|
-
import { FilePickerInitOptions, FilePickerOptions, FilePickerStatus } from '../../types';
|
|
3
|
-
import { BaseFilePicker } from '../types/baseFilePicker';
|
|
4
|
-
export interface BoxPickerInstance {
|
|
5
|
-
addListener: (event: BoxPickerEvent, handler: BoxPickerEventHandler) => void;
|
|
6
|
-
removeAllListeners: () => void;
|
|
7
|
-
show: (folderId: string, accessToken: string, options: BoxPickerOptions) => void;
|
|
8
|
-
}
|
|
9
|
-
export type BoxPickerEvent = 'choose' | 'cancel' | 'close';
|
|
10
|
-
export type BoxPickerEventHandler = (items?: BoxPickerItem[]) => void;
|
|
11
|
-
export interface BoxPickerItem {
|
|
12
|
-
id: string;
|
|
13
|
-
name: string;
|
|
14
|
-
type: 'file' | 'folder';
|
|
15
|
-
size?: number;
|
|
16
|
-
extension?: string;
|
|
17
|
-
modified_at?: string;
|
|
18
|
-
description?: string;
|
|
19
|
-
path_collection?: {
|
|
20
|
-
entries: Array<{
|
|
21
|
-
id: string;
|
|
22
|
-
name: string;
|
|
23
|
-
type: string;
|
|
24
|
-
}>;
|
|
25
|
-
};
|
|
26
|
-
shared_link?: {
|
|
27
|
-
url: string;
|
|
28
|
-
download_url?: string;
|
|
29
|
-
permissions?: {
|
|
30
|
-
can_download?: boolean;
|
|
31
|
-
can_preview?: boolean;
|
|
32
|
-
};
|
|
33
|
-
};
|
|
34
|
-
}
|
|
35
|
-
export interface BoxPickerOptions {
|
|
36
|
-
container?: string;
|
|
37
|
-
maxSelectable?: number;
|
|
38
|
-
canUpload?: boolean;
|
|
39
|
-
canCreateNewFolder?: boolean;
|
|
40
|
-
canSetShareAccess?: boolean;
|
|
41
|
-
canDownload?: boolean;
|
|
42
|
-
canDelete?: boolean;
|
|
43
|
-
canRename?: boolean;
|
|
44
|
-
canPreview?: boolean;
|
|
45
|
-
canComment?: boolean;
|
|
46
|
-
canShare?: boolean;
|
|
47
|
-
canMove?: boolean;
|
|
48
|
-
canCopy?: boolean;
|
|
49
|
-
extensions?: string[];
|
|
50
|
-
canSelectFolder?: boolean;
|
|
51
|
-
}
|
|
52
|
-
export interface BoxConfig {
|
|
53
|
-
version: string;
|
|
54
|
-
scriptUrl: string;
|
|
55
|
-
cssUrl: string;
|
|
56
|
-
containerClass: string;
|
|
57
|
-
containerStyles: Partial<CSSStyleDeclaration>;
|
|
58
|
-
pickerOptions: BoxPickerOptions;
|
|
59
|
-
}
|
|
60
|
-
export declare class BoxFilePicker extends BaseFilePicker {
|
|
61
|
-
private config;
|
|
62
|
-
dependencyStatus: FilePickerStatus;
|
|
63
|
-
accessToken: string;
|
|
64
|
-
protected instance: BoxPickerInstance | undefined;
|
|
65
|
-
constructor(options: FilePickerOptions, connectSDKInstance: ConnectSDK, config?: Partial<BoxConfig>);
|
|
66
|
-
getInstance(): BoxPickerInstance;
|
|
67
|
-
private setupEventListeners;
|
|
68
|
-
private cleanup;
|
|
69
|
-
private createPickerContainer;
|
|
70
|
-
private injectCSS;
|
|
71
|
-
private injectGlobalBtnContentCSS;
|
|
72
|
-
open(): boolean;
|
|
73
|
-
init(options: FilePickerInitOptions): Promise<boolean>;
|
|
74
|
-
launch(): Promise<void>;
|
|
75
|
-
protected onScriptLoaded(): void;
|
|
76
|
-
protected onScriptError(): void;
|
|
77
|
-
}
|