diff options
| author | altaf-creator <dev@altafcreator.com> | 2025-11-09 11:15:19 +0800 |
|---|---|---|
| committer | altaf-creator <dev@altafcreator.com> | 2025-11-09 11:15:19 +0800 |
| commit | 8eff962cab608341a6f2fedc640a0e32d96f26e2 (patch) | |
| tree | 05534d1a720ddc3691d346c69b4972555820a061 /frontend-old/node_modules/@firebase/performance/dist/src/services | |
pain
Diffstat (limited to 'frontend-old/node_modules/@firebase/performance/dist/src/services')
8 files changed, 219 insertions, 0 deletions
diff --git a/frontend-old/node_modules/@firebase/performance/dist/src/services/api_service.d.ts b/frontend-old/node_modules/@firebase/performance/dist/src/services/api_service.d.ts new file mode 100644 index 0000000..e576c29 --- /dev/null +++ b/frontend-old/node_modules/@firebase/performance/dist/src/services/api_service.d.ts @@ -0,0 +1,55 @@ +/** + * @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 { CLSMetricWithAttribution, INPMetricWithAttribution, LCPMetricWithAttribution } from 'web-vitals/attribution'; +declare global { + interface Window { + PerformanceObserver: typeof PerformanceObserver; + perfMetrics?: { + onFirstInputDelay(fn: (fid: number) => void): void; + }; + } +} +export type EntryType = 'mark' | 'measure' | 'paint' | 'resource' | 'frame' | 'navigation'; +/** + * This class holds a reference to various browser related objects injected by + * set methods. + */ +export declare class Api { + readonly window?: Window | undefined; + private readonly performance; + /** PerformanceObserver constructor function. */ + private readonly PerformanceObserver; + private readonly windowLocation; + readonly onFirstInputDelay?: (fn: (fid: number) => void) => void; + readonly onLCP: (fn: (metric: LCPMetricWithAttribution) => void) => void; + readonly onINP: (fn: (metric: INPMetricWithAttribution) => void) => void; + readonly onCLS: (fn: (metric: CLSMetricWithAttribution) => void) => void; + readonly localStorage?: Storage; + readonly document: Document; + readonly navigator: Navigator; + constructor(window?: Window | undefined); + getUrl(): string; + mark(name: string): void; + measure(measureName: string, mark1: string, mark2: string): void; + getEntriesByType(type: EntryType): PerformanceEntry[]; + getEntriesByName(name: string): PerformanceEntry[]; + getTimeOrigin(): number; + requiredApisAvailable(): boolean; + setupObserver(entryType: EntryType, callback: (entry: PerformanceEntry) => void): void; + static getInstance(): Api; +} +export declare function setupApi(window: Window): void; diff --git a/frontend-old/node_modules/@firebase/performance/dist/src/services/iid_service.d.ts b/frontend-old/node_modules/@firebase/performance/dist/src/services/iid_service.d.ts new file mode 100644 index 0000000..c3387d7 --- /dev/null +++ b/frontend-old/node_modules/@firebase/performance/dist/src/services/iid_service.d.ts @@ -0,0 +1,21 @@ +/** + * @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 { _FirebaseInstallationsInternal } from '@firebase/installations'; +export declare function getIidPromise(installationsService: _FirebaseInstallationsInternal): Promise<string>; +export declare function getIid(): string | undefined; +export declare function getAuthTokenPromise(installationsService: _FirebaseInstallationsInternal): Promise<string>; +export declare function getAuthenticationToken(): string | undefined; diff --git a/frontend-old/node_modules/@firebase/performance/dist/src/services/initialization_service.d.ts b/frontend-old/node_modules/@firebase/performance/dist/src/services/initialization_service.d.ts new file mode 100644 index 0000000..3e16a52 --- /dev/null +++ b/frontend-old/node_modules/@firebase/performance/dist/src/services/initialization_service.d.ts @@ -0,0 +1,19 @@ +/** + * @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 { PerformanceController } from '../controllers/perf'; +export declare function getInitializationPromise(performanceController: PerformanceController): Promise<void>; +export declare function isPerfInitialized(): boolean; diff --git a/frontend-old/node_modules/@firebase/performance/dist/src/services/oob_resources_service.d.ts b/frontend-old/node_modules/@firebase/performance/dist/src/services/oob_resources_service.d.ts new file mode 100644 index 0000000..2109a59 --- /dev/null +++ b/frontend-old/node_modules/@firebase/performance/dist/src/services/oob_resources_service.d.ts @@ -0,0 +1,23 @@ +/** + * @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 { PerformanceController } from '../controllers/perf'; +export declare function setupOobResources(performanceController: PerformanceController): void; +/** + * This service will only export the page load trace once. This function allows + * resetting it for unit tests + */ +export declare function resetForUnitTests(): void; diff --git a/frontend-old/node_modules/@firebase/performance/dist/src/services/perf_logger.d.ts b/frontend-old/node_modules/@firebase/performance/dist/src/services/perf_logger.d.ts new file mode 100644 index 0000000..f9dc083 --- /dev/null +++ b/frontend-old/node_modules/@firebase/performance/dist/src/services/perf_logger.d.ts @@ -0,0 +1,21 @@ +/** + * @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 { NetworkRequest } from '../resources/network_request'; +import { Trace } from '../resources/trace'; +export declare function logTrace(trace: Trace): void; +export declare function flushLogs(): void; +export declare function logNetworkRequest(networkRequest: NetworkRequest): void; diff --git a/frontend-old/node_modules/@firebase/performance/dist/src/services/remote_config_service.d.ts b/frontend-old/node_modules/@firebase/performance/dist/src/services/remote_config_service.d.ts new file mode 100644 index 0000000..22aeb58 --- /dev/null +++ b/frontend-old/node_modules/@firebase/performance/dist/src/services/remote_config_service.d.ts @@ -0,0 +1,18 @@ +/** + * @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 { PerformanceController } from '../controllers/perf'; +export declare function getConfig(performanceController: PerformanceController, iid: string): Promise<void>; diff --git a/frontend-old/node_modules/@firebase/performance/dist/src/services/settings_service.d.ts b/frontend-old/node_modules/@firebase/performance/dist/src/services/settings_service.d.ts new file mode 100644 index 0000000..c343189 --- /dev/null +++ b/frontend-old/node_modules/@firebase/performance/dist/src/services/settings_service.d.ts @@ -0,0 +1,33 @@ +/** + * @license + * Copyright 2019 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 declare class SettingsService { + instrumentationEnabled: boolean; + dataCollectionEnabled: boolean; + loggingEnabled: boolean; + tracesSamplingRate: number; + networkRequestsSamplingRate: number; + logEndPointUrl: string; + flTransportEndpointUrl: string; + transportKey: string; + logSource: number; + logTraceAfterSampling: boolean; + logNetworkAfterSampling: boolean; + configTimeToLive: number; + logMaxFlushSize: number; + getFlTransportFullUrl(): string; + static getInstance(): SettingsService; +} diff --git a/frontend-old/node_modules/@firebase/performance/dist/src/services/transport_service.d.ts b/frontend-old/node_modules/@firebase/performance/dist/src/services/transport_service.d.ts new file mode 100644 index 0000000..d204a91 --- /dev/null +++ b/frontend-old/node_modules/@firebase/performance/dist/src/services/transport_service.d.ts @@ -0,0 +1,29 @@ +/** + * @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. + */ +export declare function setupTransportService(): void; +/** + * Utilized by testing to clean up message queue and un-initialize transport service. + */ +export declare function resetTransportService(): void; +/** Log handler for cc service to send the performance logs to the server. */ +export declare function transportHandler(serializer: (...args: any[]) => string): (...args: unknown[]) => void; +/** + * Force flush the queued events. Useful at page unload time to ensure all events are uploaded. + * Flush will attempt to use sendBeacon to send events async and defaults back to fetch as soon as a + * sendBeacon fails. Firefox + */ +export declare function flushQueuedEvents(): void; |
