@firebase/storage 0.12.6-dataconnect-preview.d986d4bf2 → 0.13.0-20240814182916

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.
@@ -14,7 +14,6 @@
14
14
  * See the License for the specific language governing permissions and
15
15
  * limitations under the License.
16
16
  */
17
- /// <reference types="node" />
18
17
  import { StorageReference } from './public-types';
19
18
  /**
20
19
  * Downloads the data at the object's location. Returns an error if the object
@@ -45,4 +44,4 @@ export declare function getBlob(ref: StorageReference, maxDownloadSizeBytes?: nu
45
44
  * retrieve.
46
45
  * @returns A stream with the object's data as bytes
47
46
  */
48
- export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): NodeJS.ReadableStream;
47
+ export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): ReadableStream;
@@ -14,7 +14,6 @@
14
14
  * See the License for the specific language governing permissions and
15
15
  * limitations under the License.
16
16
  */
17
- /// <reference types="node" />
18
17
  import { StorageReference } from './public-types';
19
18
  /**
20
19
  * Downloads the data at the object's location. Returns an error if the object
@@ -45,4 +44,4 @@ export declare function getBlob(ref: StorageReference, maxDownloadSizeBytes?: nu
45
44
  * retrieve.
46
45
  * @returns A stream with the object's data as bytes
47
46
  */
48
- export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): NodeJS.ReadableStream;
47
+ export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): ReadableStream;
@@ -14,11 +14,10 @@
14
14
  * See the License for the specific language governing permissions and
15
15
  * limitations under the License.
16
16
  */
17
- /// <reference types="node" />
18
17
  /** Network headers */
19
18
  export declare type Headers = Record<string, string>;
20
19
  /** Response type exposed by the networking APIs. */
21
- export declare type ConnectionType = string | ArrayBuffer | Blob | NodeJS.ReadableStream;
20
+ export declare type ConnectionType = string | ArrayBuffer | Blob | ReadableStream<Uint8Array>;
22
21
  /**
23
22
  * A lightweight wrapper around XMLHttpRequest with a
24
23
  * goog.net.XhrIo-like interface.
@@ -14,7 +14,6 @@
14
14
  * See the License for the specific language governing permissions and
15
15
  * limitations under the License.
16
16
  */
17
- /// <reference types="node" />
18
17
  import { Connection, ConnectionType, ErrorCode, Headers } from '../../implementation/connection';
19
18
  /**
20
19
  * Network layer for browsers. We use this instead of goog.net.XhrIo because
@@ -51,6 +50,6 @@ export declare class XhrBlobConnection extends XhrConnection<Blob> {
51
50
  initXhr(): void;
52
51
  }
53
52
  export declare function newBlobConnection(): Connection<Blob>;
54
- export declare function newStreamConnection(): Connection<NodeJS.ReadableStream>;
53
+ export declare function newStreamConnection(): Connection<ReadableStream>;
55
54
  export declare function injectTestConnection(factory: (() => Connection<string>) | null): void;
56
55
  export {};
@@ -1,4 +1,3 @@
1
- /// <reference types="node" />
2
1
  /**
3
2
  * @license
4
3
  * Copyright 2020 Google LLC
@@ -20,4 +19,4 @@ export declare function injectTestConnection(factory: (() => Connection<string>)
20
19
  export declare function newTextConnection(): Connection<string>;
21
20
  export declare function newBytesConnection(): Connection<ArrayBuffer>;
22
21
  export declare function newBlobConnection(): Connection<Blob>;
23
- export declare function newStreamConnection(): Connection<NodeJS.ReadableStream>;
22
+ export declare function newStreamConnection(): Connection<ReadableStream<Uint8Array>>;
@@ -32,7 +32,7 @@ declare abstract class FetchConnection<T extends ConnectionType> implements Conn
32
32
  protected sent_: boolean;
33
33
  protected fetch_: typeof undiciFetch;
34
34
  constructor();
35
- send(url: string, method: string, body?: ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
35
+ send(url: string, method: string, body?: NodeJS.ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
36
36
  getErrorCode(): ErrorCode;
37
37
  getStatus(): number;
38
38
  abstract getResponse(): T;
@@ -50,12 +50,12 @@ export declare class FetchBytesConnection extends FetchConnection<ArrayBuffer> {
50
50
  getResponse(): ArrayBuffer;
51
51
  }
52
52
  export declare function newBytesConnection(): Connection<ArrayBuffer>;
53
- export declare class FetchStreamConnection extends FetchConnection<NodeJS.ReadableStream> {
53
+ export declare class FetchStreamConnection extends FetchConnection<ReadableStream<Uint8Array>> {
54
54
  private stream_;
55
- send(url: string, method: string, body?: ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
56
- getResponse(): NodeJS.ReadableStream;
55
+ send(url: string, method: string, body?: NodeJS.ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
56
+ getResponse(): ReadableStream;
57
57
  }
58
- export declare function newStreamConnection(): Connection<NodeJS.ReadableStream>;
58
+ export declare function newStreamConnection(): Connection<ReadableStream<Uint8Array>>;
59
59
  export declare function newBlobConnection(): Connection<Blob>;
60
60
  export declare function injectTestConnection(factory: (() => Connection<string>) | null): void;
61
61
  export {};
@@ -14,7 +14,6 @@
14
14
  * See the License for the specific language governing permissions and
15
15
  * limitations under the License.
16
16
  */
17
- /// <reference types="node" />
18
17
  import { Location } from './implementation/location';
19
18
  import { ListOptions, UploadResult } from './public-types';
20
19
  import { StringFormat } from './implementation/string';
@@ -87,7 +86,7 @@ export declare function getBytesInternal(ref: Reference, maxDownloadSizeBytes?:
87
86
  */
88
87
  export declare function getBlobInternal(ref: Reference, maxDownloadSizeBytes?: number): Promise<Blob>;
89
88
  /** Stream the bytes at the object's location. */
90
- export declare function getStreamInternal(ref: Reference, maxDownloadSizeBytes?: number): NodeJS.ReadableStream;
89
+ export declare function getStreamInternal(ref: Reference, maxDownloadSizeBytes?: number): ReadableStream;
91
90
  /**
92
91
  * Uploads data to this object's location.
93
92
  * The upload is not resumable.
@@ -14,7 +14,6 @@
14
14
  * See the License for the specific language governing permissions and
15
15
  * limitations under the License.
16
16
  */
17
- /// <reference types="node" />
18
17
  import { StorageReference } from './public-types';
19
18
  /**
20
19
  * Downloads the data at the object's location. Returns an error if the object
@@ -45,4 +44,4 @@ export declare function getBlob(ref: StorageReference, maxDownloadSizeBytes?: nu
45
44
  * retrieve.
46
45
  * @returns A stream with the object's data as bytes
47
46
  */
48
- export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): NodeJS.ReadableStream;
47
+ export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): ReadableStream;
@@ -14,7 +14,6 @@
14
14
  * See the License for the specific language governing permissions and
15
15
  * limitations under the License.
16
16
  */
17
- /// <reference types="node" />
18
17
  import { StorageReference } from './public-types';
19
18
  /**
20
19
  * Downloads the data at the object's location. Returns an error if the object
@@ -45,4 +44,4 @@ export declare function getBlob(ref: StorageReference, maxDownloadSizeBytes?: nu
45
44
  * retrieve.
46
45
  * @returns A stream with the object's data as bytes
47
46
  */
48
- export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): NodeJS.ReadableStream;
47
+ export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): ReadableStream;
@@ -14,11 +14,10 @@
14
14
  * See the License for the specific language governing permissions and
15
15
  * limitations under the License.
16
16
  */
17
- /// <reference types="node" />
18
17
  /** Network headers */
19
18
  export declare type Headers = Record<string, string>;
20
19
  /** Response type exposed by the networking APIs. */
21
- export declare type ConnectionType = string | ArrayBuffer | Blob | NodeJS.ReadableStream;
20
+ export declare type ConnectionType = string | ArrayBuffer | Blob | ReadableStream<Uint8Array>;
22
21
  /**
23
22
  * A lightweight wrapper around XMLHttpRequest with a
24
23
  * goog.net.XhrIo-like interface.
@@ -14,7 +14,6 @@
14
14
  * See the License for the specific language governing permissions and
15
15
  * limitations under the License.
16
16
  */
17
- /// <reference types="node" />
18
17
  import { Connection, ConnectionType, ErrorCode, Headers } from '../../implementation/connection';
19
18
  /**
20
19
  * Network layer for browsers. We use this instead of goog.net.XhrIo because
@@ -51,6 +50,6 @@ export declare class XhrBlobConnection extends XhrConnection<Blob> {
51
50
  initXhr(): void;
52
51
  }
53
52
  export declare function newBlobConnection(): Connection<Blob>;
54
- export declare function newStreamConnection(): Connection<NodeJS.ReadableStream>;
53
+ export declare function newStreamConnection(): Connection<ReadableStream>;
55
54
  export declare function injectTestConnection(factory: (() => Connection<string>) | null): void;
56
55
  export {};
@@ -1,4 +1,3 @@
1
- /// <reference types="node" />
2
1
  /**
3
2
  * @license
4
3
  * Copyright 2020 Google LLC
@@ -20,4 +19,4 @@ export declare function injectTestConnection(factory: (() => Connection<string>)
20
19
  export declare function newTextConnection(): Connection<string>;
21
20
  export declare function newBytesConnection(): Connection<ArrayBuffer>;
22
21
  export declare function newBlobConnection(): Connection<Blob>;
23
- export declare function newStreamConnection(): Connection<NodeJS.ReadableStream>;
22
+ export declare function newStreamConnection(): Connection<ReadableStream<Uint8Array>>;
@@ -32,7 +32,7 @@ declare abstract class FetchConnection<T extends ConnectionType> implements Conn
32
32
  protected sent_: boolean;
33
33
  protected fetch_: typeof undiciFetch;
34
34
  constructor();
35
- send(url: string, method: string, body?: ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
35
+ send(url: string, method: string, body?: NodeJS.ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
36
36
  getErrorCode(): ErrorCode;
37
37
  getStatus(): number;
38
38
  abstract getResponse(): T;
@@ -50,12 +50,12 @@ export declare class FetchBytesConnection extends FetchConnection<ArrayBuffer> {
50
50
  getResponse(): ArrayBuffer;
51
51
  }
52
52
  export declare function newBytesConnection(): Connection<ArrayBuffer>;
53
- export declare class FetchStreamConnection extends FetchConnection<NodeJS.ReadableStream> {
53
+ export declare class FetchStreamConnection extends FetchConnection<ReadableStream<Uint8Array>> {
54
54
  private stream_;
55
- send(url: string, method: string, body?: ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
56
- getResponse(): NodeJS.ReadableStream;
55
+ send(url: string, method: string, body?: NodeJS.ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
56
+ getResponse(): ReadableStream;
57
57
  }
58
- export declare function newStreamConnection(): Connection<NodeJS.ReadableStream>;
58
+ export declare function newStreamConnection(): Connection<ReadableStream<Uint8Array>>;
59
59
  export declare function newBlobConnection(): Connection<Blob>;
60
60
  export declare function injectTestConnection(factory: (() => Connection<string>) | null): void;
61
61
  export {};
@@ -14,7 +14,6 @@
14
14
  * See the License for the specific language governing permissions and
15
15
  * limitations under the License.
16
16
  */
17
- /// <reference types="node" />
18
17
  import { Location } from './implementation/location';
19
18
  import { ListOptions, UploadResult } from './public-types';
20
19
  import { StringFormat } from './implementation/string';
@@ -87,7 +86,7 @@ export declare function getBytesInternal(ref: Reference, maxDownloadSizeBytes?:
87
86
  */
88
87
  export declare function getBlobInternal(ref: Reference, maxDownloadSizeBytes?: number): Promise<Blob>;
89
88
  /** Stream the bytes at the object's location. */
90
- export declare function getStreamInternal(ref: Reference, maxDownloadSizeBytes?: number): NodeJS.ReadableStream;
89
+ export declare function getStreamInternal(ref: Reference, maxDownloadSizeBytes?: number): ReadableStream;
91
90
  /**
92
91
  * Uploads data to this object's location.
93
92
  * The upload is not resumable.
@@ -3,7 +3,6 @@
3
3
  *
4
4
  * @packageDocumentation
5
5
  */
6
- /// <reference types="node" />
7
6
  import { CompleteFn , EmulatorMockTokenOptions , FirebaseError , NextFn , Subscribe , Unsubscribe } from '@firebase/util';
8
7
  import { FirebaseApp } from '@firebase/app';
9
8
  /**
@@ -169,7 +168,7 @@ export declare function getStorage(app?: FirebaseApp, bucketUrl?: string): Fireb
169
168
  * retrieve.
170
169
  * @returns A stream with the object's data as bytes
171
170
  */
172
- export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): NodeJS.ReadableStream;
171
+ export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): ReadableStream;
173
172
  /* Excluded from this release type: _invalidArgument */
174
173
  /* Excluded from this release type: _invalidRootOperation */
175
174
  /**
package/dist/storage.d.ts CHANGED
@@ -4,7 +4,6 @@
4
4
  * @packageDocumentation
5
5
  */
6
6
 
7
- /// <reference types="node" />
8
7
  import { AppCheckInternalComponentName } from '@firebase/app-check-interop-types';
9
8
  import { CompleteFn } from '@firebase/util';
10
9
  import { EmulatorMockTokenOptions } from '@firebase/util';
@@ -52,7 +51,7 @@ declare interface Connection<T extends ConnectionType> {
52
51
  }
53
52
 
54
53
  /** Response type exposed by the networking APIs. */
55
- declare type ConnectionType = string | ArrayBuffer | Blob | NodeJS.ReadableStream;
54
+ declare type ConnectionType = string | ArrayBuffer | Blob | ReadableStream<Uint8Array>;
56
55
 
57
56
  /**
58
57
  * Modify this {@link FirebaseStorage} instance to communicate with the Cloud Storage emulator.
@@ -368,7 +367,7 @@ export declare function getStorage(app?: FirebaseApp, bucketUrl?: string): Fireb
368
367
  * retrieve.
369
368
  * @returns A stream with the object's data as bytes
370
369
  */
371
- export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): NodeJS.ReadableStream;
370
+ export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): ReadableStream;
372
371
 
373
372
  /**
374
373
  * @license
@@ -386,7 +385,6 @@ export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?:
386
385
  * See the License for the specific language governing permissions and
387
386
  * limitations under the License.
388
387
  */
389
- /// <reference types="node" />
390
388
  /** Network headers */
391
389
  declare type Headers_2 = Record<string, string>;
392
390
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@firebase/storage",
3
- "version": "0.12.6-dataconnect-preview.d986d4bf2",
3
+ "version": "0.13.0-20240814182916",
4
4
  "description": "",
5
5
  "author": "Firebase <firebase-support@google.com> (https://firebase.google.com/)",
6
6
  "main": "dist/index.node.cjs.js",
@@ -47,17 +47,17 @@
47
47
  },
48
48
  "license": "Apache-2.0",
49
49
  "dependencies": {
50
- "@firebase/util": "1.9.7-dataconnect-preview.d986d4bf2",
51
- "@firebase/component": "0.6.8-dataconnect-preview.d986d4bf2",
50
+ "@firebase/util": "1.9.7",
51
+ "@firebase/component": "0.6.8",
52
52
  "undici": "5.28.4",
53
53
  "tslib": "^2.1.0"
54
54
  },
55
55
  "peerDependencies": {
56
- "@firebase/app": "0.10.7-dataconnect-preview.d986d4bf2"
56
+ "@firebase/app": "0.10.9-20240814182916"
57
57
  },
58
58
  "devDependencies": {
59
- "@firebase/app": "0.10.7-dataconnect-preview.d986d4bf2",
60
- "@firebase/auth": "1.7.5-dataconnect-preview.d986d4bf2",
59
+ "@firebase/app": "0.10.9-20240814182916",
60
+ "@firebase/auth": "1.7.7-20240814182916",
61
61
  "rollup": "2.79.1",
62
62
  "@rollup/plugin-alias": "5.1.0",
63
63
  "@rollup/plugin-json": "4.1.0",