Firebase Update
This commit is contained in:
32
express-server/node_modules/@firebase/util/README.md
generated
vendored
Normal file
32
express-server/node_modules/@firebase/util/README.md
generated
vendored
Normal file
@ -0,0 +1,32 @@
|
||||
# @firebase/util
|
||||
|
||||
_NOTE: This is specifically tailored for Firebase JS SDK usage, if you are not a
|
||||
member of the Firebase team, please avoid using this package_
|
||||
|
||||
This is a wrapper of some Webchannel Features for the Firebase JS SDK.
|
||||
|
||||
## Installation
|
||||
|
||||
You can install this wrapper by running the following in your project:
|
||||
|
||||
```bash
|
||||
$ npm install @firebase/util
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
**ES Modules**
|
||||
|
||||
```javascript
|
||||
import { Deferred } from '@firebase/util';
|
||||
|
||||
// Do stuff with Deferred or any of the other Utils you import
|
||||
```
|
||||
|
||||
**CommonJS Modules**
|
||||
|
||||
```javascript
|
||||
const utils = require('@firebase/util');
|
||||
|
||||
// Do stuff with any of the re-exported `utils`
|
||||
```
|
1776
express-server/node_modules/@firebase/util/dist/index.cjs.js
generated
vendored
Normal file
1776
express-server/node_modules/@firebase/util/dist/index.cjs.js
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
30
express-server/node_modules/@firebase/util/dist/index.d.ts
generated
vendored
Normal file
30
express-server/node_modules/@firebase/util/dist/index.d.ts
generated
vendored
Normal file
@ -0,0 +1,30 @@
|
||||
/**
|
||||
* Copyright 2017 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
export { assert, assertionError } from './src/assert';
|
||||
export { base64, base64Decode, base64Encode } from './src/crypt';
|
||||
export { CONSTANTS } from './src/constants';
|
||||
export { deepCopy, deepExtend, patchProperty } from './src/deepCopy';
|
||||
export { Deferred } from './src/deferred';
|
||||
export { getUA, isMobileCordova, isNodeSdk, isReactNative } from './src/environment';
|
||||
export { ErrorFactory, ErrorList, FirebaseError, patchCapture, StringLike } from './src/errors';
|
||||
export { jsonEval, stringify } from './src/json';
|
||||
export { decode, isAdmin, issuedAtTime, isValidFormat, isValidTimestamp } from './src/jwt';
|
||||
export { clone, contains, every, extend, findKey, findValue, forEach, getAnyKey, getCount, getValues, isEmpty, isNonNullObject, map, safeGet } from './src/obj';
|
||||
export { querystring, querystringDecode } from './src/query';
|
||||
export { Sha1 } from './src/sha1';
|
||||
export { async, CompleteFn, createSubscribe, ErrorFn, Executor, NextFn, Observable, Observer, PartialObserver, Subscribe, Unsubscribe } from './src/subscribe';
|
||||
export { errorPrefix, validateArgCount, validateCallback, validateContextObject, validateNamespace } from './src/validation';
|
||||
export { stringLength, stringToByteArray } from './src/utf8';
|
1723
express-server/node_modules/@firebase/util/dist/index.esm.js
generated
vendored
Normal file
1723
express-server/node_modules/@firebase/util/dist/index.esm.js
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
1778
express-server/node_modules/@firebase/util/dist/index.node.cjs.js
generated
vendored
Normal file
1778
express-server/node_modules/@firebase/util/dist/index.node.cjs.js
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
15
express-server/node_modules/@firebase/util/dist/index.node.d.ts
generated
vendored
Normal file
15
express-server/node_modules/@firebase/util/dist/index.node.d.ts
generated
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
export * from './src/assert';
|
||||
export * from './src/crypt';
|
||||
export * from './src/constants';
|
||||
export * from './src/deepCopy';
|
||||
export * from './src/deferred';
|
||||
export * from './src/environment';
|
||||
export * from './src/errors';
|
||||
export * from './src/json';
|
||||
export * from './src/jwt';
|
||||
export * from './src/obj';
|
||||
export * from './src/query';
|
||||
export * from './src/sha1';
|
||||
export * from './src/subscribe';
|
||||
export * from './src/validation';
|
||||
export * from './src/utf8';
|
12
express-server/node_modules/@firebase/util/dist/src/assert.d.ts
generated
vendored
Normal file
12
express-server/node_modules/@firebase/util/dist/src/assert.d.ts
generated
vendored
Normal file
@ -0,0 +1,12 @@
|
||||
/**
|
||||
* Throws an error if the provided assertion is falsy
|
||||
* @param {*} assertion The assertion to be tested for falsiness
|
||||
* @param {!string} message The message to display if the check fails
|
||||
*/
|
||||
export declare const assert: (assertion: any, message: any) => void;
|
||||
/**
|
||||
* Returns an Error object suitable for throwing.
|
||||
* @param {string} message
|
||||
* @return {!Error}
|
||||
*/
|
||||
export declare const assertionError: (message: any) => Error;
|
23
express-server/node_modules/@firebase/util/dist/src/constants.d.ts
generated
vendored
Normal file
23
express-server/node_modules/@firebase/util/dist/src/constants.d.ts
generated
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
/**
|
||||
* Copyright 2017 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
/**
|
||||
* @fileoverview Firebase constants. Some of these (@defines) can be overridden at compile-time.
|
||||
*/
|
||||
export declare const CONSTANTS: {
|
||||
NODE_CLIENT: boolean;
|
||||
NODE_ADMIN: boolean;
|
||||
SDK_VERSION: string;
|
||||
};
|
31
express-server/node_modules/@firebase/util/dist/src/crypt.d.ts
generated
vendored
Normal file
31
express-server/node_modules/@firebase/util/dist/src/crypt.d.ts
generated
vendored
Normal file
@ -0,0 +1,31 @@
|
||||
export declare const base64: {
|
||||
byteToCharMap_: any;
|
||||
charToByteMap_: any;
|
||||
byteToCharMapWebSafe_: any;
|
||||
charToByteMapWebSafe_: any;
|
||||
ENCODED_VALS_BASE: string;
|
||||
readonly ENCODED_VALS: string;
|
||||
readonly ENCODED_VALS_WEBSAFE: string;
|
||||
HAS_NATIVE_SUPPORT: boolean;
|
||||
encodeByteArray(input: any, opt_webSafe?: any): string;
|
||||
encodeString(input: any, opt_webSafe: any): any;
|
||||
decodeString(input: any, opt_webSafe: any): string;
|
||||
decodeStringToByteArray(input: any, opt_webSafe: any): any[];
|
||||
init_(): void;
|
||||
};
|
||||
/**
|
||||
* URL-safe base64 encoding
|
||||
* @param {!string} str
|
||||
* @return {!string}
|
||||
*/
|
||||
export declare const base64Encode: (str: string) => string;
|
||||
/**
|
||||
* URL-safe base64 decoding
|
||||
*
|
||||
* NOTE: DO NOT use the global atob() function - it does NOT support the
|
||||
* base64Url variant encoding.
|
||||
*
|
||||
* @param {string} str To be decoded
|
||||
* @return {?string} Decoded result, if possible
|
||||
*/
|
||||
export declare const base64Decode: (str: string) => string;
|
33
express-server/node_modules/@firebase/util/dist/src/deepCopy.d.ts
generated
vendored
Normal file
33
express-server/node_modules/@firebase/util/dist/src/deepCopy.d.ts
generated
vendored
Normal file
@ -0,0 +1,33 @@
|
||||
/**
|
||||
* Copyright 2017 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
/**
|
||||
* Do a deep-copy of basic JavaScript Objects or Arrays.
|
||||
*/
|
||||
export declare function deepCopy<T>(value: T): T;
|
||||
/**
|
||||
* Copy properties from source to target (recursively allows extension
|
||||
* of Objects and Arrays). Scalar values in the target are over-written.
|
||||
* If target is undefined, an object of the appropriate type will be created
|
||||
* (and returned).
|
||||
*
|
||||
* We recursively copy all child properties of plain Objects in the source- so
|
||||
* that namespace- like dictionaries are merged.
|
||||
*
|
||||
* Note that the target can be a function, in which case the properties in
|
||||
* the source Object are copied onto it as static properties of the Function.
|
||||
*/
|
||||
export declare function deepExtend(target: any, source: any): any;
|
||||
export declare function patchProperty(obj: any, prop: string, value: any): void;
|
29
express-server/node_modules/@firebase/util/dist/src/deferred.d.ts
generated
vendored
Normal file
29
express-server/node_modules/@firebase/util/dist/src/deferred.d.ts
generated
vendored
Normal file
@ -0,0 +1,29 @@
|
||||
/**
|
||||
* Copyright 2017 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
export declare class Deferred<R> {
|
||||
promise: Promise<R>;
|
||||
reject: any;
|
||||
resolve: any;
|
||||
constructor();
|
||||
/**
|
||||
* Our API internals are not promiseified and cannot because our callback APIs have subtle expectations around
|
||||
* invoking promises inline, which Promises are forbidden to do. This method accepts an optional node-style callback
|
||||
* and returns a node-style callback which will resolve or reject the Deferred's promise.
|
||||
* @param {((?function(?(Error)): (?|undefined))| (?function(?(Error),?=): (?|undefined)))=} callback
|
||||
* @return {!function(?(Error), ?=)}
|
||||
*/
|
||||
wrapCallback(callback?: any): (error: any, value?: any) => void;
|
||||
}
|
26
express-server/node_modules/@firebase/util/dist/src/environment.d.ts
generated
vendored
Normal file
26
express-server/node_modules/@firebase/util/dist/src/environment.d.ts
generated
vendored
Normal file
@ -0,0 +1,26 @@
|
||||
/**
|
||||
* Returns navigator.userAgent string or '' if it's not defined.
|
||||
* @return {string} user agent string
|
||||
*/
|
||||
export declare const getUA: () => string;
|
||||
/**
|
||||
* Detect Cordova / PhoneGap / Ionic frameworks on a mobile device.
|
||||
*
|
||||
* Deliberately does not rely on checking `file://` URLs (as this fails PhoneGap in the Ripple emulator) nor
|
||||
* Cordova `onDeviceReady`, which would normally wait for a callback.
|
||||
*
|
||||
* @return {boolean} isMobileCordova
|
||||
*/
|
||||
export declare const isMobileCordova: () => boolean;
|
||||
/**
|
||||
* Detect React Native.
|
||||
*
|
||||
* @return {boolean} True if ReactNative environment is detected.
|
||||
*/
|
||||
export declare const isReactNative: () => boolean;
|
||||
/**
|
||||
* Detect Node.js.
|
||||
*
|
||||
* @return {boolean} True if Node.js environment is detected.
|
||||
*/
|
||||
export declare const isNodeSdk: () => boolean;
|
85
express-server/node_modules/@firebase/util/dist/src/errors.d.ts
generated
vendored
Normal file
85
express-server/node_modules/@firebase/util/dist/src/errors.d.ts
generated
vendored
Normal file
@ -0,0 +1,85 @@
|
||||
/**
|
||||
* Copyright 2017 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
/**
|
||||
* @fileoverview Standardized Firebase Error.
|
||||
*
|
||||
* Usage:
|
||||
*
|
||||
* // Typescript string literals for type-safe codes
|
||||
* type Err =
|
||||
* 'unknown' |
|
||||
* 'object-not-found'
|
||||
* ;
|
||||
*
|
||||
* // Closure enum for type-safe error codes
|
||||
* // at-enum {string}
|
||||
* var Err = {
|
||||
* UNKNOWN: 'unknown',
|
||||
* OBJECT_NOT_FOUND: 'object-not-found',
|
||||
* }
|
||||
*
|
||||
* let errors: Map<Err, string> = {
|
||||
* 'generic-error': "Unknown error",
|
||||
* 'file-not-found': "Could not find file: {$file}",
|
||||
* };
|
||||
*
|
||||
* // Type-safe function - must pass a valid error code as param.
|
||||
* let error = new ErrorFactory<Err>('service', 'Service', errors);
|
||||
*
|
||||
* ...
|
||||
* throw error.create(Err.GENERIC);
|
||||
* ...
|
||||
* throw error.create(Err.FILE_NOT_FOUND, {'file': fileName});
|
||||
* ...
|
||||
* // Service: Could not file file: foo.txt (service/file-not-found).
|
||||
*
|
||||
* catch (e) {
|
||||
* assert(e.message === "Could not find file: foo.txt.");
|
||||
* if (e.code === 'service/file-not-found') {
|
||||
* console.log("Could not read file: " + e['file']);
|
||||
* }
|
||||
* }
|
||||
*/
|
||||
export declare type ErrorList<T> = {
|
||||
[code: string]: string;
|
||||
};
|
||||
export interface StringLike {
|
||||
toString: () => string;
|
||||
}
|
||||
export declare function patchCapture(captureFake?: any): any;
|
||||
export interface FirebaseError {
|
||||
code: string;
|
||||
message: string;
|
||||
name: string;
|
||||
stack: string;
|
||||
}
|
||||
export declare class FirebaseError implements FirebaseError {
|
||||
code: string;
|
||||
message: string;
|
||||
stack: string;
|
||||
name: string;
|
||||
constructor(code: string, message: string);
|
||||
}
|
||||
export declare class ErrorFactory<T extends string> {
|
||||
private service;
|
||||
private serviceName;
|
||||
private errors;
|
||||
pattern: RegExp;
|
||||
constructor(service: string, serviceName: string, errors: ErrorList<T>);
|
||||
create(code: T, data?: {
|
||||
[prop: string]: StringLike;
|
||||
}): FirebaseError;
|
||||
}
|
35
express-server/node_modules/@firebase/util/dist/src/hash.d.ts
generated
vendored
Normal file
35
express-server/node_modules/@firebase/util/dist/src/hash.d.ts
generated
vendored
Normal file
@ -0,0 +1,35 @@
|
||||
/**
|
||||
* Copyright 2017 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
/**
|
||||
* @fileoverview Abstract cryptographic hash interface.
|
||||
*
|
||||
* See Sha1 and Md5 for sample implementations.
|
||||
*
|
||||
*/
|
||||
/**
|
||||
* Create a cryptographic hash instance.
|
||||
*
|
||||
* @constructor
|
||||
* @struct
|
||||
*/
|
||||
export declare class Hash {
|
||||
/**
|
||||
* The block size for the hasher.
|
||||
* @type {number}
|
||||
*/
|
||||
blockSize: number;
|
||||
constructor();
|
||||
}
|
28
express-server/node_modules/@firebase/util/dist/src/json.d.ts
generated
vendored
Normal file
28
express-server/node_modules/@firebase/util/dist/src/json.d.ts
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
/**
|
||||
* Copyright 2017 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
/**
|
||||
* Evaluates a JSON string into a javascript object.
|
||||
*
|
||||
* @param {string} str A string containing JSON.
|
||||
* @return {*} The javascript object representing the specified JSON.
|
||||
*/
|
||||
export declare function jsonEval(str: any): any;
|
||||
/**
|
||||
* Returns JSON representing a javascript object.
|
||||
* @param {*} data Javascript object to be stringified.
|
||||
* @return {string} The JSON contents of the object.
|
||||
*/
|
||||
export declare function stringify(data: any): string;
|
61
express-server/node_modules/@firebase/util/dist/src/jwt.d.ts
generated
vendored
Normal file
61
express-server/node_modules/@firebase/util/dist/src/jwt.d.ts
generated
vendored
Normal file
@ -0,0 +1,61 @@
|
||||
/**
|
||||
* Decodes a Firebase auth. token into constituent parts.
|
||||
*
|
||||
* Notes:
|
||||
* - May return with invalid / incomplete claims if there's no native base64 decoding support.
|
||||
* - Doesn't check if the token is actually valid.
|
||||
*
|
||||
* @param {?string} token
|
||||
* @return {{header: *, claims: *, data: *, signature: string}}
|
||||
*/
|
||||
export declare const decode: (token: any) => {
|
||||
header: {};
|
||||
claims: {};
|
||||
data: {};
|
||||
signature: string;
|
||||
};
|
||||
/**
|
||||
* Decodes a Firebase auth. token and checks the validity of its time-based claims. Will return true if the
|
||||
* token is within the time window authorized by the 'nbf' (not-before) and 'iat' (issued-at) claims.
|
||||
*
|
||||
* Notes:
|
||||
* - May return a false negative if there's no native base64 decoding support.
|
||||
* - Doesn't check if the token is actually valid.
|
||||
*
|
||||
* @param {?string} token
|
||||
* @return {boolean}
|
||||
*/
|
||||
export declare const isValidTimestamp: (token: any) => boolean;
|
||||
/**
|
||||
* Decodes a Firebase auth. token and returns its issued at time if valid, null otherwise.
|
||||
*
|
||||
* Notes:
|
||||
* - May return null if there's no native base64 decoding support.
|
||||
* - Doesn't check if the token is actually valid.
|
||||
*
|
||||
* @param {?string} token
|
||||
* @return {?number}
|
||||
*/
|
||||
export declare const issuedAtTime: (token: any) => any;
|
||||
/**
|
||||
* Decodes a Firebase auth. token and checks the validity of its format. Expects a valid issued-at time.
|
||||
*
|
||||
* Notes:
|
||||
* - May return a false negative if there's no native base64 decoding support.
|
||||
* - Doesn't check if the token is actually valid.
|
||||
*
|
||||
* @param {?string} token
|
||||
* @return {boolean}
|
||||
*/
|
||||
export declare const isValidFormat: (token: any) => boolean;
|
||||
/**
|
||||
* Attempts to peer into an auth token and determine if it's an admin auth token by looking at the claims portion.
|
||||
*
|
||||
* Notes:
|
||||
* - May return a false negative if there's no native base64 decoding support.
|
||||
* - Doesn't check if the token is actually valid.
|
||||
*
|
||||
* @param {?string} token
|
||||
* @return {boolean}
|
||||
*/
|
||||
export declare const isAdmin: (token: any) => boolean;
|
62
express-server/node_modules/@firebase/util/dist/src/obj.d.ts
generated
vendored
Normal file
62
express-server/node_modules/@firebase/util/dist/src/obj.d.ts
generated
vendored
Normal file
@ -0,0 +1,62 @@
|
||||
/**
|
||||
* Copyright 2017 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
export declare const contains: (obj: any, key: any) => any;
|
||||
export declare const safeGet: (obj: any, key: any) => any;
|
||||
/**
|
||||
* Enumerates the keys/values in an object, excluding keys defined on the prototype.
|
||||
*
|
||||
* @param {?Object.<K,V>} obj Object to enumerate.
|
||||
* @param {!function(K, V)} fn Function to call for each key and value.
|
||||
* @template K,V
|
||||
*/
|
||||
export declare const forEach: (obj: any, fn: any) => void;
|
||||
/**
|
||||
* Copies all the (own) properties from one object to another.
|
||||
* @param {!Object} objTo
|
||||
* @param {!Object} objFrom
|
||||
* @return {!Object} objTo
|
||||
*/
|
||||
export declare const extend: (objTo: any, objFrom: any) => any;
|
||||
/**
|
||||
* Returns a clone of the specified object.
|
||||
* @param {!Object} obj
|
||||
* @return {!Object} cloned obj.
|
||||
*/
|
||||
export declare const clone: (obj: any) => any;
|
||||
/**
|
||||
* Returns true if obj has typeof "object" and is not null. Unlike goog.isObject(), does not return true
|
||||
* for functions.
|
||||
*
|
||||
* @param obj {*} A potential object.
|
||||
* @returns {boolean} True if it's an object.
|
||||
*/
|
||||
export declare const isNonNullObject: (obj: any) => boolean;
|
||||
export declare const isEmpty: (obj: any) => boolean;
|
||||
export declare const getCount: (obj: any) => number;
|
||||
export declare const map: (obj: any, f: any, opt_obj?: any) => {};
|
||||
export declare const findKey: (obj: any, fn: any, opt_this?: any) => string;
|
||||
export declare const findValue: (obj: any, fn: any, opt_this?: any) => any;
|
||||
export declare const getAnyKey: (obj: any) => string;
|
||||
export declare const getValues: (obj: any) => any[];
|
||||
/**
|
||||
* Tests whether every key/value pair in an object pass the test implemented
|
||||
* by the provided function
|
||||
*
|
||||
* @param {?Object.<K,V>} obj Object to test.
|
||||
* @param {!function(K, V)} fn Function to call for each key and value.
|
||||
* @template K,V
|
||||
*/
|
||||
export declare const every: <V>(obj: Object, fn: (k: string, v?: V) => boolean) => boolean;
|
16
express-server/node_modules/@firebase/util/dist/src/query.d.ts
generated
vendored
Normal file
16
express-server/node_modules/@firebase/util/dist/src/query.d.ts
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
/**
|
||||
* Returns a querystring-formatted string (e.g. &arg=val&arg2=val2) from a params
|
||||
* object (e.g. {arg: 'val', arg2: 'val2'})
|
||||
* Note: You must prepend it with ? when adding it to a URL.
|
||||
*
|
||||
* @param {!Object} querystringParams
|
||||
* @return {string}
|
||||
*/
|
||||
export declare const querystring: (querystringParams: any) => string;
|
||||
/**
|
||||
* Decodes a querystring (e.g. ?arg=val&arg2=val2) into a params object (e.g. {arg: 'val', arg2: 'val2'})
|
||||
*
|
||||
* @param {string} querystring
|
||||
* @return {!Object}
|
||||
*/
|
||||
export declare const querystringDecode: (querystring: any) => {};
|
88
express-server/node_modules/@firebase/util/dist/src/sha1.d.ts
generated
vendored
Normal file
88
express-server/node_modules/@firebase/util/dist/src/sha1.d.ts
generated
vendored
Normal file
@ -0,0 +1,88 @@
|
||||
/**
|
||||
* Copyright 2017 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
import { Hash } from './hash';
|
||||
/**
|
||||
* @fileoverview SHA-1 cryptographic hash.
|
||||
* Variable names follow the notation in FIPS PUB 180-3:
|
||||
* http://csrc.nist.gov/publications/fips/fips180-3/fips180-3_final.pdf.
|
||||
*
|
||||
* Usage:
|
||||
* var sha1 = new sha1();
|
||||
* sha1.update(bytes);
|
||||
* var hash = sha1.digest();
|
||||
*
|
||||
* Performance:
|
||||
* Chrome 23: ~400 Mbit/s
|
||||
* Firefox 16: ~250 Mbit/s
|
||||
*
|
||||
*/
|
||||
/**
|
||||
* SHA-1 cryptographic hash constructor.
|
||||
*
|
||||
* The properties declared here are discussed in the above algorithm document.
|
||||
* @constructor
|
||||
* @extends {Hash}
|
||||
* @final
|
||||
* @struct
|
||||
*/
|
||||
export declare class Sha1 extends Hash {
|
||||
/**
|
||||
* Holds the previous values of accumulated variables a-e in the compress_
|
||||
* function.
|
||||
* @type {!Array<number>}
|
||||
* @private
|
||||
*/
|
||||
private chain_;
|
||||
/**
|
||||
* A buffer holding the partially computed hash result.
|
||||
* @type {!Array<number>}
|
||||
* @private
|
||||
*/
|
||||
private buf_;
|
||||
/**
|
||||
* An array of 80 bytes, each a part of the message to be hashed. Referred to
|
||||
* as the message schedule in the docs.
|
||||
* @type {!Array<number>}
|
||||
* @private
|
||||
*/
|
||||
private W_;
|
||||
/**
|
||||
* Contains data needed to pad messages less than 64 bytes.
|
||||
* @type {!Array<number>}
|
||||
* @private
|
||||
*/
|
||||
private pad_;
|
||||
/**
|
||||
* @private {number}
|
||||
*/
|
||||
private inbuf_;
|
||||
/**
|
||||
* @private {number}
|
||||
*/
|
||||
private total_;
|
||||
constructor();
|
||||
reset(): void;
|
||||
/**
|
||||
* Internal compress helper function.
|
||||
* @param {!Array<number>|!Uint8Array|string} buf Block to compress.
|
||||
* @param {number=} opt_offset Offset of the block in the buffer.
|
||||
* @private
|
||||
*/
|
||||
compress_(buf: any, opt_offset?: any): void;
|
||||
update(bytes: any, opt_length?: any): void;
|
||||
/** @override */
|
||||
digest(): any[];
|
||||
}
|
48
express-server/node_modules/@firebase/util/dist/src/subscribe.d.ts
generated
vendored
Normal file
48
express-server/node_modules/@firebase/util/dist/src/subscribe.d.ts
generated
vendored
Normal file
@ -0,0 +1,48 @@
|
||||
/**
|
||||
* Copyright 2017 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
export declare type NextFn<T> = (value: T) => void;
|
||||
export declare type ErrorFn = (error: Error) => void;
|
||||
export declare type CompleteFn = () => void;
|
||||
export interface Observer<T> {
|
||||
next: NextFn<T>;
|
||||
error: ErrorFn;
|
||||
complete: CompleteFn;
|
||||
}
|
||||
export declare type PartialObserver<T> = Partial<Observer<T>>;
|
||||
export declare type Unsubscribe = () => void;
|
||||
/**
|
||||
* The Subscribe interface has two forms - passing the inline function
|
||||
* callbacks, or a object interface with callback properties.
|
||||
*/
|
||||
export interface Subscribe<T> {
|
||||
(next?: NextFn<T>, error?: ErrorFn, complete?: CompleteFn): Unsubscribe;
|
||||
(observer: PartialObserver<T>): Unsubscribe;
|
||||
}
|
||||
export interface Observable<T> {
|
||||
subscribe: Subscribe<T>;
|
||||
}
|
||||
export declare type Executor<T> = (observer: Observer<T>) => void;
|
||||
/**
|
||||
* Helper to make a Subscribe function (just like Promise helps make a
|
||||
* Thenable).
|
||||
*
|
||||
* @param executor Function which can make calls to a single Observer
|
||||
* as a proxy.
|
||||
* @param onNoObservers Callback when count of Observers goes to zero.
|
||||
*/
|
||||
export declare function createSubscribe<T>(executor: Executor<T>, onNoObservers?: Executor<T>): Subscribe<T>;
|
||||
/** Turn synchronous function into one called asynchronously. */
|
||||
export declare function async(fn: Function, onError?: ErrorFn): Function;
|
11
express-server/node_modules/@firebase/util/dist/src/utf8.d.ts
generated
vendored
Normal file
11
express-server/node_modules/@firebase/util/dist/src/utf8.d.ts
generated
vendored
Normal file
@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @param {string} str
|
||||
* @return {Array}
|
||||
*/
|
||||
export declare const stringToByteArray: (str: any) => any[];
|
||||
/**
|
||||
* Calculate length without actually converting; useful for doing cheaper validation.
|
||||
* @param {string} str
|
||||
* @return {number}
|
||||
*/
|
||||
export declare const stringLength: (str: any) => number;
|
43
express-server/node_modules/@firebase/util/dist/src/validation.d.ts
generated
vendored
Normal file
43
express-server/node_modules/@firebase/util/dist/src/validation.d.ts
generated
vendored
Normal file
@ -0,0 +1,43 @@
|
||||
/**
|
||||
* Copyright 2017 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
/**
|
||||
* Check to make sure the appropriate number of arguments are provided for a public function.
|
||||
* Throws an error if it fails.
|
||||
*
|
||||
* @param {!string} fnName The function name
|
||||
* @param {!number} minCount The minimum number of arguments to allow for the function call
|
||||
* @param {!number} maxCount The maximum number of argument to allow for the function call
|
||||
* @param {!number} argCount The actual number of arguments provided.
|
||||
*/
|
||||
export declare const validateArgCount: (fnName: any, minCount: any, maxCount: any, argCount: any) => void;
|
||||
/**
|
||||
* Generates a string to prefix an error message about failed argument validation
|
||||
*
|
||||
* @param {!string} fnName The function name
|
||||
* @param {!number} argumentNumber The index of the argument
|
||||
* @param {boolean} optional Whether or not the argument is optional
|
||||
* @return {!string} The prefix to add to the error thrown for validation.
|
||||
*/
|
||||
export declare function errorPrefix(fnName: any, argumentNumber: any, optional: any): string;
|
||||
/**
|
||||
* @param {!string} fnName
|
||||
* @param {!number} argumentNumber
|
||||
* @param {!string} namespace
|
||||
* @param {boolean} optional
|
||||
*/
|
||||
export declare function validateNamespace(fnName: any, argumentNumber: any, namespace: any, optional: any): void;
|
||||
export declare function validateCallback(fnName: any, argumentNumber: any, callback: any, optional: any): void;
|
||||
export declare function validateContextObject(fnName: any, argumentNumber: any, context: any, optional: any): void;
|
1
express-server/node_modules/@firebase/util/dist/test/base64.test.d.ts
generated
vendored
Normal file
1
express-server/node_modules/@firebase/util/dist/test/base64.test.d.ts
generated
vendored
Normal file
@ -0,0 +1 @@
|
||||
export {};
|
1
express-server/node_modules/@firebase/util/dist/test/deepCopy.test.d.ts
generated
vendored
Normal file
1
express-server/node_modules/@firebase/util/dist/test/deepCopy.test.d.ts
generated
vendored
Normal file
@ -0,0 +1 @@
|
||||
export {};
|
1
express-server/node_modules/@firebase/util/dist/test/errors.test.d.ts
generated
vendored
Normal file
1
express-server/node_modules/@firebase/util/dist/test/errors.test.d.ts
generated
vendored
Normal file
@ -0,0 +1 @@
|
||||
export {};
|
1
express-server/node_modules/@firebase/util/dist/test/subscribe.test.d.ts
generated
vendored
Normal file
1
express-server/node_modules/@firebase/util/dist/test/subscribe.test.d.ts
generated
vendored
Normal file
@ -0,0 +1 @@
|
||||
export {};
|
95
express-server/node_modules/@firebase/util/package.json
generated
vendored
Normal file
95
express-server/node_modules/@firebase/util/package.json
generated
vendored
Normal file
@ -0,0 +1,95 @@
|
||||
{
|
||||
"_from": "@firebase/util@0.2.3",
|
||||
"_id": "@firebase/util@0.2.3",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha512-ngAG4qYpcnnshUKbBlEiR9+j37U7dTrTVJlS4v7ahW1ROuyLT9xj6cWyHQANzcTR2yKLmEv3yfwoZwedz7V0oQ==",
|
||||
"_location": "/@firebase/util",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "version",
|
||||
"registry": true,
|
||||
"raw": "@firebase/util@0.2.3",
|
||||
"name": "@firebase/util",
|
||||
"escapedName": "@firebase%2futil",
|
||||
"scope": "@firebase",
|
||||
"rawSpec": "0.2.3",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "0.2.3"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/@firebase/app",
|
||||
"/@firebase/database",
|
||||
"/@firebase/messaging"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/@firebase/util/-/util-0.2.3.tgz",
|
||||
"_shasum": "ad5513cb35eeecabae5169e439d4e200f0d180ae",
|
||||
"_spec": "@firebase/util@0.2.3",
|
||||
"_where": "D:\\Desktop\\smartshopperNodeReworkFirebase\\node_modules\\@firebase\\app",
|
||||
"author": {
|
||||
"name": "Firebase",
|
||||
"email": "firebase-support@google.com",
|
||||
"url": "https://firebase.google.com/"
|
||||
},
|
||||
"browser": "dist/index.cjs.js",
|
||||
"bugs": {
|
||||
"url": "https://github.com/firebase/firebase-js-sdk/issues"
|
||||
},
|
||||
"bundleDependencies": false,
|
||||
"dependencies": {
|
||||
"tslib": "1.9.0"
|
||||
},
|
||||
"deprecated": false,
|
||||
"description": "_NOTE: This is specifically tailored for Firebase JS SDK usage, if you are not a member of the Firebase team, please avoid using this package_",
|
||||
"devDependencies": {
|
||||
"@types/chai": "4.1.2",
|
||||
"@types/mocha": "5.0.0",
|
||||
"@types/sinon": "4.3.1",
|
||||
"chai": "4.1.2",
|
||||
"karma": "2.0.0",
|
||||
"karma-chrome-launcher": "2.2.0",
|
||||
"karma-cli": "1.0.1",
|
||||
"karma-firefox-launcher": "1.1.0",
|
||||
"karma-mocha": "1.3.0",
|
||||
"karma-sauce-launcher": "1.2.0",
|
||||
"karma-spec-reporter": "0.0.32",
|
||||
"karma-webpack": "2.0.9",
|
||||
"mocha": "5.2.0",
|
||||
"npm-run-all": "4.1.2",
|
||||
"nyc": "11.6.0",
|
||||
"rollup": "0.57.1",
|
||||
"rollup-plugin-commonjs": "9.1.0",
|
||||
"rollup-plugin-node-resolve": "3.3.0",
|
||||
"rollup-plugin-typescript2": "0.12.0",
|
||||
"ts-loader": "3.5.0",
|
||||
"ts-node": "5.0.1",
|
||||
"typescript": "2.8.1",
|
||||
"webpack": "3.11.0"
|
||||
},
|
||||
"files": [
|
||||
"dist"
|
||||
],
|
||||
"license": "Apache-2.0",
|
||||
"main": "dist/index.node.cjs.js",
|
||||
"module": "dist/index.esm.js",
|
||||
"name": "@firebase/util",
|
||||
"nyc": {
|
||||
"extension": [
|
||||
".ts"
|
||||
],
|
||||
"reportDir": "./coverage/node"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/firebase/firebase-js-sdk/tree/master/packages/util"
|
||||
},
|
||||
"scripts": {
|
||||
"build": "rollup -c",
|
||||
"dev": "rollup -c -w",
|
||||
"prepare": "npm run build",
|
||||
"test": "run-p test:browser test:node",
|
||||
"test:browser": "karma start --single-run",
|
||||
"test:node": "TS_NODE_CACHE=NO nyc --reporter lcovonly -- mocha test/**/*.test.* --compilers ts:ts-node/register/type-check --exit"
|
||||
},
|
||||
"typings": "dist/index.d.ts",
|
||||
"version": "0.2.3"
|
||||
}
|
Reference in New Issue
Block a user