@univerjs-pro/exchange-client 0.2.6 → 0.2.7

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.
@@ -5,5 +5,5 @@ export { IUploadProgressService, UploadProgressService } from './services/upload
5
5
  export { UploadNotificationContainer } from './views/UploadNotificationContainer';
6
6
  export { RequestService, IRequestService } from './services/request.service';
7
7
  export { EXCHANGE_UPLOAD_FILE_SERVER_URL_KEY, EXCHANGE_IMPORT_SERVER_URL_KEY, EXCHANGE_EXPORT_SERVER_URL_KEY, EXCHANGE_GET_TASK_SERVER_URL_KEY, EXCHANGE_SIGN_URL_SERVER_URL_KEY } from './services/request.service';
8
- export { IExchangeOperateService } from './services/operate.service';
8
+ export { IExchangeOperateService, ExchangeOperateService } from './services/operate.service';
9
9
  export { UniverExchangeClientPlugin } from './plugin';
@@ -10,8 +10,7 @@ export declare enum RequestState {
10
10
  GET_TASK = 3,
11
11
  SIGN_URL = 4,
12
12
  GET_JSON = 5,
13
- GET_FILE = 6,
14
- BINDING = 7
13
+ GET_FILE = 6
15
14
  }
16
15
  export interface IRequestState {
17
16
  error: IError | undefined;
@@ -84,5 +83,4 @@ export declare class ExchangeService extends Disposable implements IExchangeServ
84
83
  private _upload;
85
84
  private _import;
86
85
  private _signUrl;
87
- private _binding;
88
86
  }
@@ -40,7 +40,7 @@ export interface IExchangeOperateService {
40
40
  * Export docx file by unitId
41
41
  * @returns
42
42
  */
43
- exportDOCXByUnitId(unitId?: string, unitName?: string, unitType?: UniverInstanceType): Promise<void>;
43
+ exportDOCXByUnitId(unitId?: string, unitName?: string, unitType?: UniverType): Promise<void>;
44
44
  /**
45
45
  * Export docx file by snapshot
46
46
  * @returns
@@ -50,7 +50,10 @@ export interface IExchangeOperateService {
50
50
  * Upload file, supports multiple types
51
51
  * @param file
52
52
  */
53
- uploadFileToUnitId(types: UniverType[]): Promise<string | undefined>;
53
+ uploadFileToUnitId(types: UniverType[]): Promise<{
54
+ unitId: string;
55
+ type: UniverType;
56
+ } | undefined>;
54
57
  /**
55
58
  * Customize the imported Unit URL format according to the needs of your own scene
56
59
  * @param getLink
@@ -69,7 +72,10 @@ export declare class ExchangeOperateService extends Disposable implements IExcha
69
72
  private _interrupted;
70
73
  constructor(_univerInstanceService: IUniverInstanceService, _messageService: IMessageService, _localeService: LocaleService, _exchangeService: ExchangeService, _uploadNotificationService: UploadNotificationService, _uploadProgressService: IProgressService, _logService: ILogService);
71
74
  interrupt(): void;
72
- uploadFileToUnitId(types: UniverType[]): Promise<string | undefined>;
75
+ uploadFileToUnitId(types: UniverType[]): Promise<{
76
+ unitId: string;
77
+ type: UniverType;
78
+ } | undefined>;
73
79
  importDOCXToUnitId(): Promise<string | undefined>;
74
80
  importDOCXToSnapshot(): Promise<void>;
75
81
  exportDOCXByUnitId(unitId?: string, unitName?: string, unitType?: UniverInstanceType): Promise<void>;
@@ -8,7 +8,6 @@ export declare const EXCHANGE_IMPORT_SERVER_URL_KEY = "EXCHANGE_IMPORT_SERVER_UR
8
8
  export declare const EXCHANGE_EXPORT_SERVER_URL_KEY = "EXCHANGE_EXPORT_SERVER_URL_KEY";
9
9
  export declare const EXCHANGE_GET_TASK_SERVER_URL_KEY = "EXCHANGE_GET_TASK_SERVER_URL_KEY";
10
10
  export declare const EXCHANGE_SIGN_URL_SERVER_URL_KEY = "EXCHANGE_SIGN_URL_SERVER_URL_KEY";
11
- export declare const EXCHANGE_BINDING_SERVER_URL_KEY = "EXCHANGE_BINDING_SERVER_URL_KEY";
12
11
  export interface IFileUploadResponse {
13
12
  FileId: string;
14
13
  error: IError;
@@ -95,11 +94,9 @@ export declare class RequestService implements IRequestService, IDisposable {
95
94
  export(exportRequest: IExportRequest): Promise<IExportResponse | undefined>;
96
95
  getTask(taskID: string): Promise<IGetTaskResponse | undefined>;
97
96
  signUrl(fileID: string): Promise<ISignUrlResponse | undefined>;
98
- binding(unitId: string, type: UniverType): Promise<IBindingResponse | undefined>;
99
97
  private _getUploadFileURL;
100
98
  private _getImportURL;
101
99
  private _getExportURL;
102
100
  private _getTaskURL;
103
101
  private _getSignURL;
104
- private _getBindingURL;
105
102
  }