mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-09-10 11:40:16 +08:00
Update angularfire / firebase.
This commit is contained in:
Vendored
+32
-3
@@ -9,6 +9,11 @@ interface FirebaseAuthResult {
|
||||
}
|
||||
|
||||
interface FirebaseDataSnapshot {
|
||||
/**
|
||||
* Returns true if this DataSnapshot contains any data.
|
||||
* It is slightly more efficient than using snapshot.val() !== null.
|
||||
*/
|
||||
exists(): boolean;
|
||||
/**
|
||||
* Gets the JavaScript object representation of the DataSnapshot.
|
||||
*/
|
||||
@@ -108,6 +113,10 @@ interface FirebaseQuery {
|
||||
* Generates a new Query object ordered by key name.
|
||||
*/
|
||||
orderByKey(): FirebaseQuery;
|
||||
/**
|
||||
* Generates a new Query object ordered by child values.
|
||||
*/
|
||||
orderByValue(): FirebaseQuery;
|
||||
/**
|
||||
* Generates a new Query object ordered by priority.
|
||||
*/
|
||||
@@ -255,10 +264,14 @@ interface Firebase extends FirebaseQuery {
|
||||
* Creates a new user account using an email / password combination.
|
||||
*/
|
||||
createUser(credentials: FirebaseCredentials, onComplete: (error: any) => void): void;
|
||||
/**
|
||||
* Updates the email associated with an email / password user account.
|
||||
*/
|
||||
changeEmail(credentials: FirebaseNewUserCredentials, onComplete: (error: any) => void): void;
|
||||
/**
|
||||
* Change the password of an existing user using an email / password combination.
|
||||
*/
|
||||
changePassword(credentials: { email: string; oldPassword: string; newPassword: string }, onComplete: (error: any) => void): void;
|
||||
changePassword(credentials: FirebaseNewPasswordCredentials, onComplete: (error: any) => void): void;
|
||||
/**
|
||||
* Removes an existing user account using an email / password combination.
|
||||
*/
|
||||
@@ -266,7 +279,7 @@ interface Firebase extends FirebaseQuery {
|
||||
/**
|
||||
* Sends a password-reset email to the owner of the account, containing a token that may be used to authenticate and change the user password.
|
||||
*/
|
||||
resetPassword(credentials: { email: string }, onComplete: (error: any) => void): void;
|
||||
resetPassword(credentials: FirebaseResetPasswordCredentials, onComplete: (error: any) => void): void;
|
||||
onDisconnect(): FirebaseOnDisconnect;
|
||||
}
|
||||
interface FirebaseStatic {
|
||||
@@ -305,4 +318,20 @@ interface FirebaseAuthData {
|
||||
interface FirebaseCredentials {
|
||||
email: string;
|
||||
password: string;
|
||||
}
|
||||
}
|
||||
|
||||
interface FirebaseNewPasswordCredentials {
|
||||
email: string;
|
||||
oldPassword: string;
|
||||
newPassword: string;
|
||||
}
|
||||
|
||||
interface FirebaseNewUserCredentials {
|
||||
oldEmail: string;
|
||||
newEmail: string;
|
||||
password: string;
|
||||
}
|
||||
|
||||
interface FirebaseResetPasswordCredentials {
|
||||
email: string;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user