@secrecy/lib 1.36.0 → 1.37.1
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.
|
@@ -162,13 +162,20 @@ export class SecrecyCloudClient {
|
|
|
162
162
|
dataContentCache.set(uploadData.id, dataBuffer);
|
|
163
163
|
return uploadData.id;
|
|
164
164
|
}
|
|
165
|
-
async uploadDataInCloud({ data, name, nodeId, encryptProgress, uploadProgress, signal, }) {
|
|
166
|
-
const dataId =
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
165
|
+
async uploadDataInCloud({ data, name, nodeId, encryptProgress, uploadProgress, signal, isLite, }) {
|
|
166
|
+
const dataId = isLite
|
|
167
|
+
? await this.uploadLiteData({
|
|
168
|
+
data,
|
|
169
|
+
encryptProgress,
|
|
170
|
+
uploadProgress,
|
|
171
|
+
signal,
|
|
172
|
+
})
|
|
173
|
+
: await this.uploadData({
|
|
174
|
+
data,
|
|
175
|
+
encryptProgress,
|
|
176
|
+
uploadProgress,
|
|
177
|
+
signal,
|
|
178
|
+
});
|
|
172
179
|
return await this.saveInCloud({
|
|
173
180
|
dataId,
|
|
174
181
|
name,
|
|
@@ -21,13 +21,14 @@ export declare class SecrecyCloudClient {
|
|
|
21
21
|
uploadProgress?: ProgressCallback;
|
|
22
22
|
signal?: AbortSignal;
|
|
23
23
|
}): Promise<string>;
|
|
24
|
-
uploadDataInCloud({ data, name, nodeId, encryptProgress, uploadProgress, signal, }: {
|
|
24
|
+
uploadDataInCloud({ data, name, nodeId, encryptProgress, uploadProgress, signal, isLite, }: {
|
|
25
25
|
data: globalThis.File | Uint8Array;
|
|
26
26
|
name: string;
|
|
27
27
|
nodeId?: string;
|
|
28
28
|
encryptProgress?: ProgressCallback;
|
|
29
29
|
uploadProgress?: ProgressCallback;
|
|
30
30
|
signal?: AbortSignal;
|
|
31
|
+
isLite?: boolean;
|
|
31
32
|
}): Promise<NodeFull>;
|
|
32
33
|
deletedNodes(): Promise<Node[]>;
|
|
33
34
|
sharedNodes(): Promise<Node[]>;
|
package/package.json
CHANGED