@atlaskit/react-ufo 3.14.15 → 4.0.1
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 +17 -0
- package/dist/cjs/config/index.js +14 -48
- package/dist/cjs/create-payload/index.js +18 -13
- package/dist/cjs/create-post-interaction-log-payload/get-late-mutations.js +1 -1
- package/dist/cjs/create-post-interaction-log-payload/index.js +2 -2
- package/dist/cjs/interaction-metrics/post-interaction-log.js +0 -1
- package/dist/cjs/interaction-metrics-init/index.js +3 -3
- package/dist/cjs/placeholder/Placeholder.js +3 -3
- package/dist/cjs/suspense/Suspense.js +20 -0
- package/dist/cjs/suspense/index.js +9 -0
- package/dist/cjs/vc/vc-observer-new/metric-calculator/fy25_03/index.js +1 -1
- package/dist/es2019/config/index.js +5 -39
- package/dist/es2019/create-payload/index.js +17 -12
- package/dist/es2019/create-post-interaction-log-payload/get-late-mutations.js +1 -1
- package/dist/es2019/create-post-interaction-log-payload/index.js +3 -3
- package/dist/es2019/interaction-metrics/post-interaction-log.js +0 -1
- package/dist/es2019/interaction-metrics-init/index.js +3 -3
- package/dist/es2019/placeholder/Placeholder.js +3 -3
- package/dist/es2019/suspense/Suspense.js +14 -0
- package/dist/es2019/suspense/index.js +2 -0
- package/dist/es2019/vc/vc-observer-new/metric-calculator/fy25_03/index.js +1 -1
- package/dist/esm/config/index.js +13 -45
- package/dist/esm/create-payload/index.js +18 -13
- package/dist/esm/create-post-interaction-log-payload/get-late-mutations.js +1 -1
- package/dist/esm/create-post-interaction-log-payload/index.js +3 -3
- package/dist/esm/interaction-metrics/post-interaction-log.js +0 -1
- package/dist/esm/interaction-metrics-init/index.js +3 -3
- package/dist/esm/placeholder/Placeholder.js +3 -3
- package/dist/esm/suspense/Suspense.js +13 -0
- package/dist/esm/suspense/index.js +2 -0
- package/dist/esm/vc/vc-observer-new/metric-calculator/fy25_03/index.js +1 -1
- package/dist/types/common/assets/types.d.ts +1 -1
- package/dist/types/config/index.d.ts +16 -17
- package/dist/types/create-payload/index.d.ts +577 -577
- package/dist/types/create-post-interaction-log-payload/get-late-mutations.d.ts +1 -1
- package/dist/types/placeholder/Placeholder.d.ts +3 -3
- package/dist/types/suspense/Suspense.d.ts +7 -0
- package/dist/types/suspense/index.d.ts +2 -0
- package/dist/types-ts4.5/common/assets/types.d.ts +1 -1
- package/dist/types-ts4.5/config/index.d.ts +16 -17
- package/dist/types-ts4.5/create-payload/index.d.ts +577 -577
- package/dist/types-ts4.5/create-post-interaction-log-payload/get-late-mutations.d.ts +1 -1
- package/dist/types-ts4.5/placeholder/Placeholder.d.ts +3 -3
- package/dist/types-ts4.5/suspense/Suspense.d.ts +7 -0
- package/dist/types-ts4.5/suspense/index.d.ts +2 -0
- package/package.json +5 -4
- package/suspense/package.json +15 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { LastInteractionFinishInfo } from '../common';
|
|
2
2
|
import type { LateMutation } from '../common/react-ufo-payload-schema';
|
|
3
3
|
import type { RevisionPayloadVCDetails } from '../common/vc/types';
|
|
4
|
-
declare function getLateMutations(vcDetails: RevisionPayloadVCDetails, lastInteractionFinish: LastInteractionFinishInfo, postInteractionFinishVCRatios
|
|
4
|
+
declare function getLateMutations(vcDetails: RevisionPayloadVCDetails, lastInteractionFinish: LastInteractionFinishInfo, postInteractionFinishVCRatios?: Record<string, number>): LateMutation[];
|
|
5
5
|
export default getLateMutations;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { type LazySuspenseProps } from './loosely-lazy';
|
|
3
3
|
/**
|
|
4
|
-
*
|
|
4
|
+
* @private
|
|
5
|
+
* @deprecated Use `atlaskit/react-ufo/suspense` instead.
|
|
5
6
|
*
|
|
6
|
-
*
|
|
7
|
-
* in performance monitoring tools like Performance Portal.
|
|
7
|
+
* Provides a placeholder for lazily loaded content (via react-loosely-lazy), improving perceived performance.
|
|
8
8
|
*/
|
|
9
9
|
export default function Placeholder({ name, children, fallback, }: {
|
|
10
10
|
name: string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { AssetsConfig, InteractionMetrics, InteractionType } from '../common';
|
|
2
2
|
export interface AdditionalData {
|
|
3
3
|
[key: string]: null | string | number | boolean | undefined | AdditionalData | Record<string, AdditionalData> | Array<AdditionalData>;
|
|
4
4
|
}
|
|
@@ -27,7 +27,8 @@ type SelectorConfig = {
|
|
|
27
27
|
type Rates = {
|
|
28
28
|
readonly [key: string]: number;
|
|
29
29
|
};
|
|
30
|
-
type TTVCRevisions = 'fy25.01' | 'fy25.02' | 'fy25.03';
|
|
30
|
+
export type TTVCRevisions = 'fy25.01' | 'fy25.02' | 'fy25.03';
|
|
31
|
+
export declare const DEFAULT_TTVC_REVISION = "fy25.03";
|
|
31
32
|
export type Config = {
|
|
32
33
|
readonly enabled?: boolean;
|
|
33
34
|
readonly interactionTimeout?: Record<string, number>;
|
|
@@ -43,15 +44,21 @@ export type Config = {
|
|
|
43
44
|
readonly rate?: number;
|
|
44
45
|
}[];
|
|
45
46
|
readonly killswitch?: readonly string[];
|
|
47
|
+
/**
|
|
48
|
+
* @private
|
|
49
|
+
* @deprecated - remove on FG cleanup of platform_ufo_remove_deprecated_config_fields
|
|
50
|
+
*/
|
|
46
51
|
readonly killswitchNestedSegments?: boolean;
|
|
47
52
|
readonly typingMethod?: string;
|
|
53
|
+
/**
|
|
54
|
+
* @private
|
|
55
|
+
* @deprecated - remove on FG cleanup of platform_ufo_remove_deprecated_config_fields
|
|
56
|
+
*/
|
|
48
57
|
readonly capability?: Record<Capability, number>;
|
|
49
58
|
readonly kind?: Record<InteractionKind, number>;
|
|
50
59
|
readonly allowedResources?: Array<ResourceType>;
|
|
51
60
|
readonly allowedResourcesParams?: Array<string>;
|
|
52
61
|
readonly autoGeneratedRate?: number;
|
|
53
|
-
readonly removePageSegmentsUFOPrefixes?: boolean;
|
|
54
|
-
readonly removeInteractionsUFOPrefixes?: boolean;
|
|
55
62
|
readonly product: string;
|
|
56
63
|
readonly region: string;
|
|
57
64
|
readonly additionalPayloadData?: (interaction: InteractionMetrics) => AdditionalData;
|
|
@@ -59,12 +66,7 @@ export type Config = {
|
|
|
59
66
|
readonly getSSRTimings?: () => SSRTiming[];
|
|
60
67
|
readonly getSSRDoneTime?: () => number | undefined;
|
|
61
68
|
};
|
|
62
|
-
|
|
63
|
-
* @private
|
|
64
|
-
* @deprecated remove me with next major release
|
|
65
|
-
*/
|
|
66
|
-
readonly assetsClassification?: AssetsClassification;
|
|
67
|
-
readonly assetsConfig?: AssetsClassification;
|
|
69
|
+
readonly assetsConfig?: AssetsConfig;
|
|
68
70
|
readonly enableBetterPageVisibilityApi?: boolean;
|
|
69
71
|
readonly vc?: {
|
|
70
72
|
readonly enabled?: boolean;
|
|
@@ -106,14 +108,13 @@ export type Config = {
|
|
|
106
108
|
};
|
|
107
109
|
readonly enableSegmentHighlighting?: boolean;
|
|
108
110
|
readonly enableAdditionalPerformanceMarks?: boolean;
|
|
109
|
-
readonly shouldCalculateLighthouseMetricsFromTTAI?: boolean;
|
|
110
|
-
readonly timeWindowForLateMutationsInMilliseconds?: number;
|
|
111
|
-
readonly manuallyTrackReactProfilerMounts?: boolean;
|
|
112
111
|
/**
|
|
113
112
|
* @private
|
|
114
|
-
* @deprecated
|
|
113
|
+
* @deprecated - remove on FG cleanup of platform_ufo_remove_deprecated_config_fields
|
|
115
114
|
*/
|
|
116
|
-
readonly
|
|
115
|
+
readonly shouldCalculateLighthouseMetricsFromTTAI?: boolean;
|
|
116
|
+
readonly timeWindowForLateMutationsInMilliseconds?: number;
|
|
117
|
+
readonly manuallyTrackReactProfilerMounts?: boolean;
|
|
117
118
|
};
|
|
118
119
|
export declare function setUFOConfig(newConfig: Config): void;
|
|
119
120
|
export declare function getConfig(): Config | undefined;
|
|
@@ -132,8 +133,6 @@ declare const validTypingMethods: readonly [
|
|
|
132
133
|
type ValidTypingMethod = (typeof validTypingMethods)[number];
|
|
133
134
|
export declare function getTypingPerformanceTracingMethod(): ValidTypingMethod;
|
|
134
135
|
export declare function getAwaitBM3TTIList(): string[];
|
|
135
|
-
export declare function getRemovePageSegmentsUFOPrefixes(): boolean;
|
|
136
|
-
export declare function getRemoveInteractionsUFOPrefixes(): boolean;
|
|
137
136
|
export declare function getUfoNameOverrides(): UFONameOverride | undefined;
|
|
138
137
|
export declare function getDoNotAbortActivePressInteraction(): string[] | undefined;
|
|
139
138
|
export declare function getDoNotAbortActivePressInteractionOnTransition(): string[] | undefined;
|