summaryrefslogtreecommitdiff
path: root/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova
diff options
context:
space:
mode:
authoraltaf-creator <dev@altafcreator.com>2025-11-09 11:15:19 +0800
committeraltaf-creator <dev@altafcreator.com>2025-11-09 11:15:19 +0800
commit8eff962cab608341a6f2fedc640a0e32d96f26e2 (patch)
tree05534d1a720ddc3691d346c69b4972555820a061 /frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova
pain
Diffstat (limited to 'frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova')
-rw-r--r--frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/plugins.d.ts42
-rw-r--r--frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/popup_redirect/events.d.ts39
-rw-r--r--frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/popup_redirect/popup_redirect.d.ts24
-rw-r--r--frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/popup_redirect/utils.d.ts47
-rw-r--r--frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/strategies/redirect.d.ts20
5 files changed, 172 insertions, 0 deletions
diff --git a/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/plugins.d.ts b/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/plugins.d.ts
new file mode 100644
index 0000000..d3e157d
--- /dev/null
+++ b/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/plugins.d.ts
@@ -0,0 +1,42 @@
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ *
+ * 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 interface CordovaWindow extends Window {
+ cordova: {
+ plugins: {
+ browsertab: {
+ isAvailable(cb: (available: boolean) => void): void;
+ openUrl(url: string): void;
+ close(): void;
+ };
+ };
+ InAppBrowser: {
+ open(url: string, target: string, options: string): InAppBrowserRef;
+ };
+ };
+ universalLinks: {
+ subscribe(n: null, cb: (event: Record<string, string> | null) => void): void;
+ };
+ BuildInfo: {
+ readonly packageName: string;
+ readonly displayName: string;
+ };
+ handleOpenURL(url: string): void;
+}
+export interface InAppBrowserRef {
+ close?: () => void;
+}
+export declare function _cordovaWindow(): CordovaWindow;
diff --git a/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/popup_redirect/events.d.ts b/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/popup_redirect/events.d.ts
new file mode 100644
index 0000000..0e5a406
--- /dev/null
+++ b/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/popup_redirect/events.d.ts
@@ -0,0 +1,39 @@
+/**
+ * @license
+ * Copyright 2020 Google LLC
+ *
+ * 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 { AuthEventManager } from '../../core/auth/auth_event_manager';
+import { AuthInternal } from '../../model/auth';
+import { AuthEvent, AuthEventType } from '../../model/popup_redirect';
+/** Custom AuthEventManager that adds passive listeners to events */
+export declare class CordovaAuthEventManager extends AuthEventManager {
+ private readonly passiveListeners;
+ private resolveInitialized;
+ private initPromise;
+ addPassiveListener(cb: (e: AuthEvent) => void): void;
+ removePassiveListener(cb: (e: AuthEvent) => void): void;
+ resetRedirect(): void;
+ /** Override the onEvent method */
+ onEvent(event: AuthEvent): boolean;
+ initialized(): Promise<void>;
+}
+/**
+ * Generates a (partial) {@link AuthEvent}.
+ */
+export declare function _generateNewEvent(auth: AuthInternal, type: AuthEventType, eventId?: string | null): AuthEvent;
+export declare function _savePartialEvent(auth: AuthInternal, event: AuthEvent): Promise<void>;
+export declare function _getAndRemoveEvent(auth: AuthInternal): Promise<AuthEvent | null>;
+export declare function _eventFromPartialAndUrl(partialEvent: AuthEvent, url: string): AuthEvent | null;
+export declare function _getDeepLinkFromCallback(url: string): string;
diff --git a/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/popup_redirect/popup_redirect.d.ts b/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/popup_redirect/popup_redirect.d.ts
new file mode 100644
index 0000000..2bbf02c
--- /dev/null
+++ b/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/popup_redirect/popup_redirect.d.ts
@@ -0,0 +1,24 @@
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ *
+ * 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 { PopupRedirectResolver } from '../../model/public_types';
+/**
+ * An implementation of {@link PopupRedirectResolver} suitable for Cordova
+ * based applications.
+ *
+ * @public
+ */
+export declare const cordovaPopupRedirectResolver: PopupRedirectResolver;
diff --git a/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/popup_redirect/utils.d.ts b/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/popup_redirect/utils.d.ts
new file mode 100644
index 0000000..b9feb06
--- /dev/null
+++ b/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/popup_redirect/utils.d.ts
@@ -0,0 +1,47 @@
+/**
+ * @license
+ * Copyright 2020 Google LLC
+ *
+ * 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 { AuthProvider } from '../../model/public_types';
+import { AuthInternal } from '../../model/auth';
+import { AuthEvent } from '../../model/popup_redirect';
+import { InAppBrowserRef } from '../plugins';
+/**
+ * Generates the URL for the OAuth handler.
+ */
+export declare function _generateHandlerUrl(auth: AuthInternal, event: AuthEvent, provider: AuthProvider): Promise<string>;
+/**
+ * Validates that this app is valid for this project configuration
+ */
+export declare function _validateOrigin(auth: AuthInternal): Promise<void>;
+export declare function _performRedirect(handlerUrl: string): Promise<InAppBrowserRef | null>;
+interface PassiveAuthEventListener {
+ addPassiveListener(cb: () => void): void;
+ removePassiveListener(cb: () => void): void;
+}
+/**
+ * This function waits for app activity to be seen before resolving. It does
+ * this by attaching listeners to various dom events. Once the app is determined
+ * to be visible, this promise resolves. AFTER that resolution, the listeners
+ * are detached and any browser tabs left open will be closed.
+ */
+export declare function _waitForAppResume(auth: AuthInternal, eventListener: PassiveAuthEventListener, iabRef: InAppBrowserRef | null): Promise<void>;
+/**
+ * Checks the configuration of the Cordova environment. This has no side effect
+ * if the configuration is correct; otherwise it throws an error with the
+ * missing plugin.
+ */
+export declare function _checkCordovaConfiguration(auth: AuthInternal): void;
+export {};
diff --git a/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/strategies/redirect.d.ts b/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/strategies/redirect.d.ts
new file mode 100644
index 0000000..9dbd547
--- /dev/null
+++ b/frontend-old/node_modules/@firebase/auth/dist/node-esm/src/platform_cordova/strategies/redirect.d.ts
@@ -0,0 +1,20 @@
+/**
+ * @license
+ * Copyright 2021 Google LLC
+ *
+ * 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 { Auth, AuthProvider, PopupRedirectResolver, User } from '../../model/public_types';
+export declare function signInWithRedirect(auth: Auth, provider: AuthProvider, resolver?: PopupRedirectResolver): Promise<void>;
+export declare function reauthenticateWithRedirect(user: User, provider: AuthProvider, resolver?: PopupRedirectResolver): Promise<void>;
+export declare function linkWithRedirect(user: User, provider: AuthProvider, resolver?: PopupRedirectResolver): Promise<void>;