@firebase/storage 0.7.0-canary.cdada6c68 → 0.7.1-2022028193537
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/CHANGELOG.md +6 -0
- package/dist/compat/cjs/compat/index.d.ts +49 -0
- package/dist/compat/cjs/compat/list.d.ts +29 -0
- package/dist/compat/cjs/compat/reference.d.ts +122 -0
- package/dist/compat/cjs/compat/service.d.ts +46 -0
- package/dist/compat/cjs/compat/task.d.ts +54 -0
- package/dist/compat/cjs/compat/tasksnapshot.d.ts +31 -0
- package/dist/{src → compat/cjs/exp}/api.d.ts +7 -11
- package/dist/{src → compat/cjs/exp}/constants.d.ts +1 -1
- package/dist/{src → compat/cjs/exp}/index.d.ts +0 -0
- package/dist/compat/cjs/exp/public-types.d.ts +433 -0
- package/dist/compat/cjs/index.d.ts +19 -0
- package/dist/compat/cjs/index.js +1863 -0
- package/dist/compat/cjs/index.js.map +1 -0
- package/dist/compat/cjs/register-module.d.ts +47 -0
- package/dist/compat/cjs/src/implementation/async.d.ts +22 -0
- package/dist/compat/cjs/src/implementation/backoff.d.ts +37 -0
- package/dist/compat/cjs/src/implementation/blob.d.ts +34 -0
- package/dist/compat/cjs/src/implementation/connection.d.ts +47 -0
- package/dist/compat/cjs/src/implementation/connectionPool.d.ts +26 -0
- package/dist/compat/cjs/src/implementation/constants.d.ts +44 -0
- package/dist/compat/cjs/src/implementation/error.d.ts +100 -0
- package/dist/compat/cjs/src/implementation/failrequest.d.ts +29 -0
- package/dist/compat/cjs/src/implementation/fs.d.ts +17 -0
- package/dist/compat/cjs/src/implementation/json.d.ts +7 -0
- package/dist/compat/cjs/src/implementation/list.d.ts +19 -0
- package/dist/compat/cjs/src/implementation/location.d.ts +32 -0
- package/dist/compat/cjs/src/implementation/metadata.d.ts +40 -0
- package/dist/compat/cjs/src/implementation/observer.d.ts +47 -0
- package/dist/compat/cjs/src/implementation/path.d.ts +31 -0
- package/dist/compat/cjs/src/implementation/request.d.ts +48 -0
- package/dist/compat/cjs/src/implementation/requestinfo.d.ts +57 -0
- package/dist/compat/cjs/src/implementation/requestmaker.d.ts +21 -0
- package/dist/compat/cjs/src/implementation/requests.d.ts +83 -0
- package/dist/compat/cjs/src/implementation/string.d.ts +70 -0
- package/dist/compat/cjs/src/implementation/taskenums.d.ts +73 -0
- package/dist/compat/cjs/src/implementation/type.d.ts +23 -0
- package/dist/compat/cjs/src/implementation/url.d.ts +22 -0
- package/dist/compat/cjs/src/list.d.ts +41 -0
- package/dist/compat/cjs/src/metadata.d.ts +27 -0
- package/dist/compat/cjs/src/platform/base64.d.ts +20 -0
- package/dist/compat/cjs/src/platform/browser/base64.d.ts +19 -0
- package/dist/compat/cjs/src/platform/browser/connection.d.ts +62 -0
- package/dist/compat/cjs/src/platform/connection.d.ts +18 -0
- package/dist/compat/cjs/src/platform/node/base64.d.ts +19 -0
- package/dist/compat/cjs/src/platform/node/connection.d.ts +43 -0
- package/dist/compat/cjs/src/reference.d.ts +197 -0
- package/dist/compat/cjs/src/service.d.ts +131 -0
- package/dist/compat/cjs/src/task.d.ts +143 -0
- package/dist/compat/cjs/src/tasksnapshot.d.ts +65 -0
- package/dist/compat/cjs/test/browser/blob.test.d.ts +17 -0
- package/dist/compat/cjs/test/integration/integration.compat.test.d.ts +23 -0
- package/dist/{test/integration/integration.test.d.ts → compat/cjs/test/integration/integration.exp.test.d.ts} +0 -0
- package/dist/compat/cjs/test/unit/connection.d.ts +45 -0
- package/dist/compat/cjs/test/unit/index.compat.test.d.ts +5 -0
- package/dist/{test/unit/index.test.d.ts → compat/cjs/test/unit/index.exp.test.d.ts} +0 -0
- package/dist/{test/unit/reference.test.d.ts → compat/cjs/test/unit/reference.compat.test.d.ts} +0 -0
- package/dist/{test/unit/service.test.d.ts → compat/cjs/test/unit/reference.exp.test.d.ts} +0 -0
- package/dist/compat/cjs/test/unit/request.test.d.ts +1 -0
- package/dist/compat/cjs/test/unit/requests.test.d.ts +1 -0
- package/dist/compat/cjs/test/unit/service.compat.test.d.ts +1 -0
- package/dist/compat/cjs/test/unit/service.exp.test.d.ts +1 -0
- package/dist/compat/cjs/test/unit/string.test.d.ts +1 -0
- package/dist/compat/cjs/test/unit/task.test.d.ts +1 -0
- package/dist/compat/cjs/test/unit/testshared.d.ts +50 -0
- package/dist/compat/esm2017/compat/index.d.ts +64 -0
- package/dist/compat/esm2017/compat/list.d.ts +29 -0
- package/dist/compat/esm2017/compat/reference.d.ts +122 -0
- package/dist/compat/esm2017/compat/service.d.ts +46 -0
- package/dist/compat/esm2017/compat/task.d.ts +54 -0
- package/dist/compat/esm2017/compat/tasksnapshot.d.ts +31 -0
- package/dist/compat/esm2017/exp/api.d.ts +177 -0
- package/dist/compat/esm2017/exp/constants.d.ts +20 -0
- package/dist/compat/esm2017/exp/index.d.ts +7 -0
- package/dist/compat/esm2017/exp/public-types.d.ts +433 -0
- package/dist/compat/esm2017/index.d.ts +19 -0
- package/dist/compat/esm2017/index.js +775 -0
- package/dist/compat/esm2017/index.js.map +1 -0
- package/dist/compat/esm2017/register-module.d.ts +47 -0
- package/dist/compat/esm2017/src/implementation/async.d.ts +22 -0
- package/dist/compat/esm2017/src/implementation/backoff.d.ts +37 -0
- package/dist/compat/esm2017/src/implementation/blob.d.ts +34 -0
- package/dist/compat/esm2017/src/implementation/connection.d.ts +47 -0
- package/dist/compat/esm2017/src/implementation/connectionPool.d.ts +26 -0
- package/dist/compat/esm2017/src/implementation/constants.d.ts +44 -0
- package/dist/compat/esm2017/src/implementation/error.d.ts +100 -0
- package/dist/compat/esm2017/src/implementation/failrequest.d.ts +29 -0
- package/dist/compat/esm2017/src/implementation/fs.d.ts +17 -0
- package/dist/compat/esm2017/src/implementation/json.d.ts +7 -0
- package/dist/compat/esm2017/src/implementation/list.d.ts +19 -0
- package/dist/compat/esm2017/src/implementation/location.d.ts +32 -0
- package/dist/compat/esm2017/src/implementation/metadata.d.ts +40 -0
- package/dist/compat/esm2017/src/implementation/observer.d.ts +47 -0
- package/dist/compat/esm2017/src/implementation/path.d.ts +31 -0
- package/dist/compat/esm2017/src/implementation/request.d.ts +48 -0
- package/dist/compat/esm2017/src/implementation/requestinfo.d.ts +57 -0
- package/dist/compat/esm2017/src/implementation/requestmaker.d.ts +21 -0
- package/dist/compat/esm2017/src/implementation/requests.d.ts +83 -0
- package/dist/compat/esm2017/src/implementation/string.d.ts +70 -0
- package/dist/compat/esm2017/src/implementation/taskenums.d.ts +73 -0
- package/dist/compat/esm2017/src/implementation/type.d.ts +23 -0
- package/dist/compat/esm2017/src/implementation/url.d.ts +22 -0
- package/dist/compat/esm2017/src/list.d.ts +41 -0
- package/dist/compat/esm2017/src/metadata.d.ts +27 -0
- package/dist/compat/esm2017/src/platform/base64.d.ts +20 -0
- package/dist/compat/esm2017/src/platform/browser/base64.d.ts +19 -0
- package/dist/compat/esm2017/src/platform/browser/connection.d.ts +62 -0
- package/dist/compat/esm2017/src/platform/connection.d.ts +18 -0
- package/dist/compat/esm2017/src/platform/node/base64.d.ts +19 -0
- package/dist/compat/esm2017/src/platform/node/connection.d.ts +43 -0
- package/dist/compat/esm2017/src/reference.d.ts +197 -0
- package/dist/compat/esm2017/src/service.d.ts +131 -0
- package/dist/compat/esm2017/src/task.d.ts +143 -0
- package/dist/compat/esm2017/src/tasksnapshot.d.ts +65 -0
- package/dist/compat/esm2017/test/browser/blob.test.d.ts +17 -0
- package/dist/compat/esm2017/test/integration/integration.compat.test.d.ts +23 -0
- package/dist/compat/esm2017/test/integration/integration.exp.test.d.ts +20 -0
- package/dist/compat/esm2017/test/unit/connection.d.ts +45 -0
- package/dist/compat/esm2017/test/unit/index.compat.test.d.ts +5 -0
- package/dist/compat/esm2017/test/unit/index.exp.test.d.ts +4 -0
- package/dist/compat/esm2017/test/unit/reference.compat.test.d.ts +1 -0
- package/dist/compat/esm2017/test/unit/reference.exp.test.d.ts +1 -0
- package/dist/compat/esm2017/test/unit/request.test.d.ts +1 -0
- package/dist/compat/esm2017/test/unit/requests.test.d.ts +1 -0
- package/dist/compat/esm2017/test/unit/service.compat.test.d.ts +1 -0
- package/dist/compat/esm2017/test/unit/service.exp.test.d.ts +1 -0
- package/dist/compat/esm2017/test/unit/string.test.d.ts +1 -0
- package/dist/compat/esm2017/test/unit/task.test.d.ts +1 -0
- package/dist/compat/esm2017/test/unit/testshared.d.ts +50 -0
- package/dist/compat/esm5/compat/index.d.ts +49 -0
- package/dist/compat/esm5/compat/list.d.ts +29 -0
- package/dist/compat/esm5/compat/reference.d.ts +122 -0
- package/dist/compat/esm5/compat/service.d.ts +46 -0
- package/dist/compat/esm5/compat/task.d.ts +54 -0
- package/dist/compat/esm5/compat/tasksnapshot.d.ts +31 -0
- package/dist/compat/esm5/exp/api.d.ts +177 -0
- package/dist/compat/esm5/exp/constants.d.ts +20 -0
- package/dist/compat/esm5/exp/index.d.ts +7 -0
- package/dist/compat/esm5/exp/public-types.d.ts +433 -0
- package/dist/compat/esm5/index.d.ts +19 -0
- package/dist/compat/esm5/index.js +1855 -0
- package/dist/compat/esm5/index.js.map +1 -0
- package/dist/compat/esm5/register-module.d.ts +47 -0
- package/dist/compat/esm5/src/implementation/async.d.ts +22 -0
- package/dist/compat/esm5/src/implementation/backoff.d.ts +37 -0
- package/dist/compat/esm5/src/implementation/blob.d.ts +34 -0
- package/dist/compat/esm5/src/implementation/connection.d.ts +47 -0
- package/dist/compat/esm5/src/implementation/connectionPool.d.ts +26 -0
- package/dist/compat/esm5/src/implementation/constants.d.ts +44 -0
- package/dist/compat/esm5/src/implementation/error.d.ts +100 -0
- package/dist/compat/esm5/src/implementation/failrequest.d.ts +29 -0
- package/dist/compat/esm5/src/implementation/fs.d.ts +17 -0
- package/dist/compat/esm5/src/implementation/json.d.ts +7 -0
- package/dist/compat/esm5/src/implementation/list.d.ts +19 -0
- package/dist/compat/esm5/src/implementation/location.d.ts +32 -0
- package/dist/compat/esm5/src/implementation/metadata.d.ts +40 -0
- package/dist/compat/esm5/src/implementation/observer.d.ts +47 -0
- package/dist/compat/esm5/src/implementation/path.d.ts +31 -0
- package/dist/compat/esm5/src/implementation/request.d.ts +48 -0
- package/dist/compat/esm5/src/implementation/requestinfo.d.ts +57 -0
- package/dist/compat/esm5/src/implementation/requestmaker.d.ts +21 -0
- package/dist/compat/esm5/src/implementation/requests.d.ts +83 -0
- package/dist/compat/esm5/src/implementation/string.d.ts +70 -0
- package/dist/compat/esm5/src/implementation/taskenums.d.ts +73 -0
- package/dist/compat/esm5/src/implementation/type.d.ts +23 -0
- package/dist/compat/esm5/src/implementation/url.d.ts +22 -0
- package/dist/compat/esm5/src/list.d.ts +41 -0
- package/dist/compat/esm5/src/metadata.d.ts +27 -0
- package/dist/compat/esm5/src/platform/base64.d.ts +20 -0
- package/dist/compat/esm5/src/platform/browser/base64.d.ts +19 -0
- package/dist/compat/esm5/src/platform/browser/connection.d.ts +62 -0
- package/dist/compat/esm5/src/platform/connection.d.ts +18 -0
- package/dist/compat/esm5/src/platform/node/base64.d.ts +19 -0
- package/dist/compat/esm5/src/platform/node/connection.d.ts +43 -0
- package/dist/compat/esm5/src/reference.d.ts +197 -0
- package/dist/compat/esm5/src/service.d.ts +131 -0
- package/dist/compat/esm5/src/task.d.ts +143 -0
- package/dist/compat/esm5/src/tasksnapshot.d.ts +65 -0
- package/dist/compat/esm5/test/browser/blob.test.d.ts +17 -0
- package/dist/compat/esm5/test/integration/integration.compat.test.d.ts +23 -0
- package/dist/compat/esm5/test/integration/integration.exp.test.d.ts +20 -0
- package/dist/compat/esm5/test/unit/connection.d.ts +45 -0
- package/dist/compat/esm5/test/unit/index.compat.test.d.ts +5 -0
- package/dist/compat/esm5/test/unit/index.exp.test.d.ts +4 -0
- package/dist/compat/esm5/test/unit/reference.compat.test.d.ts +1 -0
- package/dist/compat/esm5/test/unit/reference.exp.test.d.ts +1 -0
- package/dist/compat/esm5/test/unit/request.test.d.ts +1 -0
- package/dist/compat/esm5/test/unit/requests.test.d.ts +1 -0
- package/dist/compat/esm5/test/unit/service.compat.test.d.ts +1 -0
- package/dist/compat/esm5/test/unit/service.exp.test.d.ts +1 -0
- package/dist/compat/esm5/test/unit/string.test.d.ts +1 -0
- package/dist/compat/esm5/test/unit/task.test.d.ts +1 -0
- package/dist/compat/esm5/test/unit/testshared.d.ts +50 -0
- package/dist/compat/index.d.ts +49 -0
- package/dist/compat/list.d.ts +29 -0
- package/dist/compat/reference.d.ts +122 -0
- package/dist/compat/service.d.ts +46 -0
- package/dist/compat/task.d.ts +54 -0
- package/dist/compat/tasksnapshot.d.ts +31 -0
- package/dist/exp/api.d.ts +177 -0
- package/dist/exp/constants.d.ts +20 -0
- package/dist/exp/index.d.ts +7 -0
- package/dist/exp/public-types.d.ts +433 -0
- package/dist/index.browser.cjs.js +1046 -734
- package/dist/index.browser.cjs.js.map +1 -1
- package/dist/index.browser.esm.js +3935 -0
- package/dist/index.browser.esm.js.map +1 -0
- package/dist/index.browser.esm2017.js +3656 -0
- package/dist/index.browser.esm2017.js.map +1 -0
- package/dist/index.d.ts +19 -0
- package/dist/index.node.cjs.js +3651 -0
- package/dist/index.node.cjs.js.map +1 -0
- package/dist/register-module.d.ts +47 -0
- package/dist/src/implementation/error.d.ts +28 -33
- package/dist/src/implementation/failrequest.d.ts +2 -2
- package/dist/src/implementation/observer.d.ts +5 -5
- package/dist/src/implementation/requestinfo.d.ts +2 -2
- package/dist/src/implementation/requests.d.ts +4 -4
- package/dist/src/implementation/string.d.ts +5 -8
- package/dist/src/implementation/taskenums.d.ts +6 -10
- package/dist/src/metadata.d.ts +1 -1
- package/dist/src/reference.d.ts +2 -1
- package/dist/src/service.d.ts +3 -4
- package/dist/src/task.d.ts +7 -7
- package/dist/src/tasksnapshot.d.ts +65 -0
- package/dist/test/integration/integration.compat.test.d.ts +23 -0
- package/dist/test/integration/integration.exp.test.d.ts +20 -0
- package/dist/test/unit/index.compat.test.d.ts +5 -0
- package/dist/test/unit/index.exp.test.d.ts +4 -0
- package/dist/test/unit/reference.compat.test.d.ts +1 -0
- package/dist/test/unit/reference.exp.test.d.ts +1 -0
- package/dist/test/unit/service.compat.test.d.ts +1 -0
- package/dist/test/unit/service.exp.test.d.ts +1 -0
- package/dist/test/unit/testshared.d.ts +2 -2
- package/dist/{src/tsdoc-metadata.json → tsdoc-metadata.json} +0 -0
- package/exp/dist/compat/index.d.ts +49 -0
- package/exp/dist/compat/list.d.ts +29 -0
- package/exp/dist/compat/reference.d.ts +122 -0
- package/exp/dist/compat/service.d.ts +46 -0
- package/exp/dist/compat/task.d.ts +54 -0
- package/exp/dist/compat/tasksnapshot.d.ts +31 -0
- package/exp/dist/exp/api.d.ts +177 -0
- package/exp/dist/exp/constants.d.ts +20 -0
- package/exp/dist/exp/index.d.ts +7 -0
- package/{dist/src → exp/dist/exp}/public-types.d.ts +9 -9
- package/{dist/index.esm2017.js → exp/dist/index.browser.esm2017.js} +35 -65
- package/exp/dist/index.browser.esm2017.js.map +1 -0
- package/{dist/index.esm5.js → exp/dist/index.browser.esm5.js} +40 -70
- package/exp/dist/index.browser.esm5.js.map +1 -0
- package/exp/dist/index.d.ts +19 -0
- package/{dist/index.cjs.js → exp/dist/index.node.cjs.js} +34 -69
- package/exp/dist/index.node.cjs.js.map +1 -0
- package/exp/dist/register-module.d.ts +47 -0
- package/exp/dist/src/implementation/async.d.ts +22 -0
- package/exp/dist/src/implementation/backoff.d.ts +37 -0
- package/exp/dist/src/implementation/blob.d.ts +34 -0
- package/exp/dist/src/implementation/connection.d.ts +47 -0
- package/exp/dist/src/implementation/connectionPool.d.ts +26 -0
- package/exp/dist/src/implementation/constants.d.ts +44 -0
- package/exp/dist/src/implementation/error.d.ts +100 -0
- package/exp/dist/src/implementation/failrequest.d.ts +29 -0
- package/exp/dist/src/implementation/fs.d.ts +17 -0
- package/exp/dist/src/implementation/json.d.ts +7 -0
- package/exp/dist/src/implementation/list.d.ts +19 -0
- package/exp/dist/src/implementation/location.d.ts +32 -0
- package/exp/dist/src/implementation/metadata.d.ts +40 -0
- package/exp/dist/src/implementation/observer.d.ts +47 -0
- package/exp/dist/src/implementation/path.d.ts +31 -0
- package/exp/dist/src/implementation/request.d.ts +48 -0
- package/exp/dist/src/implementation/requestinfo.d.ts +57 -0
- package/exp/dist/src/implementation/requestmaker.d.ts +21 -0
- package/exp/dist/src/implementation/requests.d.ts +83 -0
- package/exp/dist/src/implementation/string.d.ts +70 -0
- package/exp/dist/src/implementation/taskenums.d.ts +73 -0
- package/exp/dist/src/implementation/type.d.ts +23 -0
- package/exp/dist/src/implementation/url.d.ts +22 -0
- package/exp/dist/src/list.d.ts +41 -0
- package/exp/dist/src/metadata.d.ts +27 -0
- package/exp/dist/src/platform/base64.d.ts +20 -0
- package/exp/dist/src/platform/browser/base64.d.ts +19 -0
- package/exp/dist/src/platform/browser/connection.d.ts +62 -0
- package/exp/dist/src/platform/connection.d.ts +18 -0
- package/exp/dist/src/platform/node/base64.d.ts +19 -0
- package/exp/dist/src/platform/node/connection.d.ts +43 -0
- package/exp/dist/src/reference.d.ts +197 -0
- package/exp/dist/src/service.d.ts +131 -0
- package/exp/dist/src/task.d.ts +143 -0
- package/exp/dist/src/tasksnapshot.d.ts +65 -0
- package/{dist → exp/dist}/storage-public.d.ts +27 -32
- package/{dist → exp/dist}/storage.d.ts +108 -104
- package/exp/dist/test/browser/blob.test.d.ts +17 -0
- package/exp/dist/test/integration/integration.compat.test.d.ts +23 -0
- package/exp/dist/test/integration/integration.exp.test.d.ts +20 -0
- package/exp/dist/test/unit/connection.d.ts +45 -0
- package/exp/dist/test/unit/index.compat.test.d.ts +5 -0
- package/exp/dist/test/unit/index.exp.test.d.ts +4 -0
- package/exp/dist/test/unit/reference.compat.test.d.ts +1 -0
- package/exp/dist/test/unit/reference.exp.test.d.ts +1 -0
- package/exp/dist/test/unit/request.test.d.ts +1 -0
- package/exp/dist/test/unit/requests.test.d.ts +1 -0
- package/exp/dist/test/unit/service.compat.test.d.ts +1 -0
- package/exp/dist/test/unit/service.exp.test.d.ts +1 -0
- package/exp/dist/test/unit/string.test.d.ts +1 -0
- package/exp/dist/test/unit/task.test.d.ts +1 -0
- package/exp/dist/test/unit/testshared.d.ts +50 -0
- package/exp/package.json +10 -0
- package/package.json +29 -19
- package/dist/index.cjs.js.map +0 -1
- package/dist/index.esm2017.js.map +0 -1
- package/dist/index.esm5.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
#Unreleased
|
|
2
2
|
|
|
3
|
+
## 0.7.1-2022028193537
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`2afff2b61`](https://github.com/firebase/firebase-js-sdk/commit/2afff2b61432561e7beffefb650c506522790f13) [#5948](https://github.com/firebase/firebase-js-sdk/pull/5948) - Update node-fetch version
|
|
8
|
+
|
|
3
9
|
## 0.7.0
|
|
4
10
|
|
|
5
11
|
### Minor Changes
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { _FirebaseNamespace } from '@firebase/app-types/private';
|
|
18
|
+
import * as types from '@firebase/storage-types';
|
|
19
|
+
export declare function registerStorage(instance: _FirebaseNamespace): void;
|
|
20
|
+
/**
|
|
21
|
+
* Define extension behavior for `registerStorage`
|
|
22
|
+
*/
|
|
23
|
+
declare module '@firebase/app-compat' {
|
|
24
|
+
interface FirebaseNamespace {
|
|
25
|
+
storage?: {
|
|
26
|
+
(app?: FirebaseApp, url?: string): types.FirebaseStorage;
|
|
27
|
+
Storage: typeof types.FirebaseStorage;
|
|
28
|
+
StringFormat: {
|
|
29
|
+
BASE64: types.StringFormat;
|
|
30
|
+
BASE64URL: types.StringFormat;
|
|
31
|
+
DATA_URL: types.StringFormat;
|
|
32
|
+
RAW: types.StringFormat;
|
|
33
|
+
};
|
|
34
|
+
TaskEvent: {
|
|
35
|
+
STATE_CHANGED: types.TaskEvent;
|
|
36
|
+
};
|
|
37
|
+
TaskState: {
|
|
38
|
+
CANCELED: types.TaskState;
|
|
39
|
+
ERROR: types.TaskState;
|
|
40
|
+
PAUSED: types.TaskState;
|
|
41
|
+
RUNNING: types.TaskState;
|
|
42
|
+
SUCCESS: types.TaskState;
|
|
43
|
+
};
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
interface FirebaseApp {
|
|
47
|
+
storage?(storageBucket?: string): types.FirebaseStorage;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { ListResult } from "@firebase/storage";
|
|
18
|
+
import * as types from '@firebase/storage-types';
|
|
19
|
+
import { ReferenceCompat } from './reference';
|
|
20
|
+
import { StorageServiceCompat } from './service';
|
|
21
|
+
import { Compat } from '@firebase/util';
|
|
22
|
+
export declare class ListResultCompat implements types.ListResult, Compat<ListResult> {
|
|
23
|
+
readonly _delegate: ListResult;
|
|
24
|
+
private readonly _service;
|
|
25
|
+
constructor(_delegate: ListResult, _service: StorageServiceCompat);
|
|
26
|
+
get prefixes(): ReferenceCompat[];
|
|
27
|
+
get items(): ReferenceCompat[];
|
|
28
|
+
get nextPageToken(): string | null;
|
|
29
|
+
}
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { StorageReference, StringFormat } from "@firebase/storage";
|
|
18
|
+
import { StorageServiceCompat } from './service';
|
|
19
|
+
import * as types from '@firebase/storage-types';
|
|
20
|
+
import { Metadata } from '../src/metadata';
|
|
21
|
+
import { Compat } from '@firebase/util';
|
|
22
|
+
export declare class ReferenceCompat implements types.Reference, Compat<StorageReference> {
|
|
23
|
+
readonly _delegate: StorageReference;
|
|
24
|
+
storage: StorageServiceCompat;
|
|
25
|
+
constructor(_delegate: StorageReference, storage: StorageServiceCompat);
|
|
26
|
+
get name(): string;
|
|
27
|
+
get bucket(): string;
|
|
28
|
+
get fullPath(): string;
|
|
29
|
+
toString(): string;
|
|
30
|
+
/**
|
|
31
|
+
* @returns A reference to the object obtained by
|
|
32
|
+
* appending childPath, removing any duplicate, beginning, or trailing
|
|
33
|
+
* slashes.
|
|
34
|
+
*/
|
|
35
|
+
child(childPath: string): types.Reference;
|
|
36
|
+
get root(): types.Reference;
|
|
37
|
+
/**
|
|
38
|
+
* @returns A reference to the parent of the
|
|
39
|
+
* current object, or null if the current object is the root.
|
|
40
|
+
*/
|
|
41
|
+
get parent(): types.Reference | null;
|
|
42
|
+
/**
|
|
43
|
+
* Uploads a blob to this object's location.
|
|
44
|
+
* @param data - The blob to upload.
|
|
45
|
+
* @returns An UploadTask that lets you control and
|
|
46
|
+
* observe the upload.
|
|
47
|
+
*/
|
|
48
|
+
put(data: Blob | Uint8Array | ArrayBuffer, metadata?: types.FullMetadata): types.UploadTask;
|
|
49
|
+
/**
|
|
50
|
+
* Uploads a string to this object's location.
|
|
51
|
+
* @param value - The string to upload.
|
|
52
|
+
* @param format - The format of the string to upload.
|
|
53
|
+
* @returns An UploadTask that lets you control and
|
|
54
|
+
* observe the upload.
|
|
55
|
+
*/
|
|
56
|
+
putString(value: string, format?: StringFormat, metadata?: Metadata): types.UploadTask;
|
|
57
|
+
/**
|
|
58
|
+
* List all items (files) and prefixes (folders) under this storage reference.
|
|
59
|
+
*
|
|
60
|
+
* This is a helper method for calling list() repeatedly until there are
|
|
61
|
+
* no more results. The default pagination size is 1000.
|
|
62
|
+
*
|
|
63
|
+
* Note: The results may not be consistent if objects are changed while this
|
|
64
|
+
* operation is running.
|
|
65
|
+
*
|
|
66
|
+
* Warning: listAll may potentially consume too many resources if there are
|
|
67
|
+
* too many results.
|
|
68
|
+
*
|
|
69
|
+
* @returns A Promise that resolves with all the items and prefixes under
|
|
70
|
+
* the current storage reference. `prefixes` contains references to
|
|
71
|
+
* sub-directories and `items` contains references to objects in this
|
|
72
|
+
* folder. `nextPageToken` is never returned.
|
|
73
|
+
*/
|
|
74
|
+
listAll(): Promise<types.ListResult>;
|
|
75
|
+
/**
|
|
76
|
+
* List items (files) and prefixes (folders) under this storage reference.
|
|
77
|
+
*
|
|
78
|
+
* List API is only available for Firebase Rules Version 2.
|
|
79
|
+
*
|
|
80
|
+
* GCS is a key-blob store. Firebase Storage imposes the semantic of '/'
|
|
81
|
+
* delimited folder structure. Refer to GCS's List API if you want to learn more.
|
|
82
|
+
*
|
|
83
|
+
* To adhere to Firebase Rules's Semantics, Firebase Storage does not
|
|
84
|
+
* support objects whose paths end with "/" or contain two consecutive
|
|
85
|
+
* "/"s. Firebase Storage List API will filter these unsupported objects.
|
|
86
|
+
* list() may fail if there are too many unsupported objects in the bucket.
|
|
87
|
+
*
|
|
88
|
+
* @param options - See ListOptions for details.
|
|
89
|
+
* @returns A Promise that resolves with the items and prefixes.
|
|
90
|
+
* `prefixes` contains references to sub-folders and `items`
|
|
91
|
+
* contains references to objects in this folder. `nextPageToken`
|
|
92
|
+
* can be used to get the rest of the results.
|
|
93
|
+
*/
|
|
94
|
+
list(options?: types.ListOptions | null): Promise<types.ListResult>;
|
|
95
|
+
/**
|
|
96
|
+
* A `Promise` that resolves with the metadata for this object. If this
|
|
97
|
+
* object doesn't exist or metadata cannot be retreived, the promise is
|
|
98
|
+
* rejected.
|
|
99
|
+
*/
|
|
100
|
+
getMetadata(): Promise<types.FullMetadata>;
|
|
101
|
+
/**
|
|
102
|
+
* Updates the metadata for this object.
|
|
103
|
+
* @param metadata - The new metadata for the object.
|
|
104
|
+
* Only values that have been explicitly set will be changed. Explicitly
|
|
105
|
+
* setting a value to null will remove the metadata.
|
|
106
|
+
* @returns A `Promise` that resolves
|
|
107
|
+
* with the new metadata for this object.
|
|
108
|
+
* @see firebaseStorage.Reference.prototype.getMetadata
|
|
109
|
+
*/
|
|
110
|
+
updateMetadata(metadata: types.SettableMetadata): Promise<types.FullMetadata>;
|
|
111
|
+
/**
|
|
112
|
+
* @returns A `Promise` that resolves with the download
|
|
113
|
+
* URL for this object.
|
|
114
|
+
*/
|
|
115
|
+
getDownloadURL(): Promise<string>;
|
|
116
|
+
/**
|
|
117
|
+
* Deletes the object at this location.
|
|
118
|
+
* @returns A `Promise` that resolves if the deletion succeeds.
|
|
119
|
+
*/
|
|
120
|
+
delete(): Promise<void>;
|
|
121
|
+
private _throwIfRoot;
|
|
122
|
+
}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import * as types from '@firebase/storage-types';
|
|
18
|
+
import { FirebaseApp } from '@firebase/app-types';
|
|
19
|
+
import { FirebaseStorage } from "@firebase/storage";
|
|
20
|
+
import { Compat, EmulatorMockTokenOptions } from '@firebase/util';
|
|
21
|
+
/**
|
|
22
|
+
* A service that provides firebaseStorage.Reference instances.
|
|
23
|
+
* @param opt_url gs:// url to a custom Storage Bucket
|
|
24
|
+
*/
|
|
25
|
+
export declare class StorageServiceCompat implements types.FirebaseStorage, Compat<FirebaseStorage> {
|
|
26
|
+
app: FirebaseApp;
|
|
27
|
+
readonly _delegate: FirebaseStorage;
|
|
28
|
+
constructor(app: FirebaseApp, _delegate: FirebaseStorage);
|
|
29
|
+
get maxOperationRetryTime(): number;
|
|
30
|
+
get maxUploadRetryTime(): number;
|
|
31
|
+
/**
|
|
32
|
+
* Returns a firebaseStorage.Reference for the given path in the default
|
|
33
|
+
* bucket.
|
|
34
|
+
*/
|
|
35
|
+
ref(path?: string): types.Reference;
|
|
36
|
+
/**
|
|
37
|
+
* Returns a firebaseStorage.Reference object for the given absolute URL,
|
|
38
|
+
* which must be a gs:// or http[s]:// URL.
|
|
39
|
+
*/
|
|
40
|
+
refFromURL(url: string): types.Reference;
|
|
41
|
+
setMaxUploadRetryTime(time: number): void;
|
|
42
|
+
setMaxOperationRetryTime(time: number): void;
|
|
43
|
+
useEmulator(host: string, port: number, options?: {
|
|
44
|
+
mockUserToken?: EmulatorMockTokenOptions | string;
|
|
45
|
+
}): void;
|
|
46
|
+
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { UploadTask, FirebaseStorageError, TaskEvent, StorageObserver } from "@firebase/storage";
|
|
18
|
+
import { UploadTaskSnapshotCompat } from './tasksnapshot';
|
|
19
|
+
import { ReferenceCompat } from './reference';
|
|
20
|
+
import * as types from '@firebase/storage-types';
|
|
21
|
+
import { Compat } from '@firebase/util';
|
|
22
|
+
export declare class UploadTaskCompat implements types.UploadTask, Compat<UploadTask> {
|
|
23
|
+
readonly _delegate: UploadTask;
|
|
24
|
+
private readonly _ref;
|
|
25
|
+
constructor(_delegate: UploadTask, _ref: ReferenceCompat);
|
|
26
|
+
get snapshot(): UploadTaskSnapshotCompat;
|
|
27
|
+
cancel: () => boolean;
|
|
28
|
+
catch: (onRejected: (error: FirebaseStorageError) => unknown) => Promise<unknown>;
|
|
29
|
+
pause: () => boolean;
|
|
30
|
+
resume: () => boolean;
|
|
31
|
+
then(onFulfilled?: ((a: UploadTaskSnapshotCompat) => unknown) | null, onRejected?: ((a: FirebaseStorageError) => unknown) | null): Promise<unknown>;
|
|
32
|
+
on(type: TaskEvent, nextOrObserver?: types.StorageObserver<UploadTaskSnapshotCompat> | null | ((a: UploadTaskSnapshotCompat) => unknown), error?: (error: FirebaseStorageError) => void | null, completed?: () => void | null): Unsubscribe | Subscribe<UploadTaskSnapshotCompat>;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Subscribes to an event stream.
|
|
36
|
+
*/
|
|
37
|
+
export declare type Subscribe<T> = (next?: NextFn<T> | StorageObserver<T>, error?: ErrorFn, complete?: CompleteFn) => Unsubscribe;
|
|
38
|
+
/**
|
|
39
|
+
* Unsubscribes from a stream.
|
|
40
|
+
*/
|
|
41
|
+
export declare type Unsubscribe = () => void;
|
|
42
|
+
/**
|
|
43
|
+
* Function that is called once for each value in a stream of values.
|
|
44
|
+
*/
|
|
45
|
+
export declare type NextFn<T> = (value: T) => void;
|
|
46
|
+
/**
|
|
47
|
+
* A function that is called with a `FirebaseStorageError`
|
|
48
|
+
* if the event stream ends due to an error.
|
|
49
|
+
*/
|
|
50
|
+
export declare type ErrorFn = (error: FirebaseStorageError) => void;
|
|
51
|
+
/**
|
|
52
|
+
* A function that is called if the event stream ends normally.
|
|
53
|
+
*/
|
|
54
|
+
export declare type CompleteFn = () => void;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { UploadTaskSnapshot } from "@firebase/storage";
|
|
18
|
+
import { ReferenceCompat } from './reference';
|
|
19
|
+
import { UploadTaskCompat } from './task';
|
|
20
|
+
import * as types from '@firebase/storage-types';
|
|
21
|
+
import { Compat } from '@firebase/util';
|
|
22
|
+
export declare class UploadTaskSnapshotCompat implements types.UploadTaskSnapshot, Compat<UploadTaskSnapshot> {
|
|
23
|
+
readonly _delegate: UploadTaskSnapshot;
|
|
24
|
+
readonly task: UploadTaskCompat;
|
|
25
|
+
readonly ref: ReferenceCompat;
|
|
26
|
+
constructor(_delegate: UploadTaskSnapshot, task: UploadTaskCompat, ref: ReferenceCompat);
|
|
27
|
+
get bytesTransferred(): number;
|
|
28
|
+
get metadata(): types.FullMetadata;
|
|
29
|
+
get state(): string;
|
|
30
|
+
get totalBytes(): number;
|
|
31
|
+
}
|
|
@@ -14,22 +14,18 @@
|
|
|
14
14
|
* See the License for the specific language governing permissions and
|
|
15
15
|
* limitations under the License.
|
|
16
16
|
*/
|
|
17
|
-
import { FirebaseApp } from '@firebase/app';
|
|
17
|
+
import { FirebaseApp } from '@firebase/app-exp';
|
|
18
18
|
import { StorageReference, FirebaseStorage, UploadResult, ListOptions, ListResult, UploadTask, SettableMetadata, UploadMetadata, FullMetadata } from './public-types';
|
|
19
|
-
import { Reference } from '
|
|
19
|
+
import { Reference } from '../src/reference';
|
|
20
20
|
import { EmulatorMockTokenOptions } from '@firebase/util';
|
|
21
21
|
/**
|
|
22
22
|
* Public types.
|
|
23
23
|
*/
|
|
24
24
|
export * from './public-types';
|
|
25
|
-
export { Location as _Location } from '
|
|
26
|
-
export { UploadTask as _UploadTask } from '
|
|
27
|
-
export type { Reference as _Reference } from '
|
|
28
|
-
export
|
|
29
|
-
export { FbsBlob as _FbsBlob } from './implementation/blob';
|
|
30
|
-
export { dataFromString as _dataFromString } from './implementation/string';
|
|
31
|
-
export { invalidRootOperation as _invalidRootOperation, invalidArgument as _invalidArgument } from './implementation/error';
|
|
32
|
-
export { TaskEvent as _TaskEvent, TaskState as _TaskState } from './implementation/taskenums';
|
|
25
|
+
export { Location as _Location } from '../src/implementation/location';
|
|
26
|
+
export { UploadTask as _UploadTask } from '../src/task';
|
|
27
|
+
export type { Reference as _Reference } from '../src/reference';
|
|
28
|
+
export { FbsBlob as _FbsBlob } from '../src/implementation/blob';
|
|
33
29
|
/**
|
|
34
30
|
* Uploads data to this object's location.
|
|
35
31
|
* The upload is not resumable.
|
|
@@ -157,7 +153,7 @@ export declare function ref(storageOrRef: FirebaseStorage | StorageReference, pa
|
|
|
157
153
|
* @internal
|
|
158
154
|
*/
|
|
159
155
|
export declare function _getChild(ref: StorageReference, childPath: string): Reference;
|
|
160
|
-
export { StringFormat } from '
|
|
156
|
+
export { StringFormat } from '../src/implementation/string';
|
|
161
157
|
/**
|
|
162
158
|
* Gets a {@link FirebaseStorage} instance for the given Firebase app.
|
|
163
159
|
* @public
|
|
File without changes
|