@amplitude/plugin-session-replay-browser 1.24.0 → 1.25.0
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/lib/cjs/typings/session-replay.d.ts +27 -0
- package/lib/cjs/typings/session-replay.d.ts.map +1 -1
- package/lib/cjs/typings/session-replay.js.map +1 -1
- package/lib/cjs/version.d.ts +1 -1
- package/lib/cjs/version.js +1 -1
- package/lib/cjs/version.js.map +1 -1
- package/lib/esm/typings/session-replay.d.ts +27 -0
- package/lib/esm/typings/session-replay.d.ts.map +1 -1
- package/lib/esm/typings/session-replay.js.map +1 -1
- package/lib/esm/version.d.ts +1 -1
- package/lib/esm/version.js +1 -1
- package/lib/esm/version.js.map +1 -1
- package/lib/scripts/index-min.js +1 -1
- package/lib/scripts/index-min.js.gz +0 -0
- package/lib/scripts/index-min.js.map +1 -1
- package/lib/scripts/plugin-session-replay-browser-min.js +1 -1
- package/lib/scripts/plugin-session-replay-browser-min.js.gz +0 -0
- package/lib/scripts/plugin-session-replay-browser-min.js.map +1 -1
- package/package.json +6 -6
|
@@ -7,9 +7,36 @@ export interface SessionReplayPrivacyConfig {
|
|
|
7
7
|
maskSelector?: string[];
|
|
8
8
|
unmaskSelector?: string[];
|
|
9
9
|
}
|
|
10
|
+
/**
|
|
11
|
+
* Performance configuration for interaction tracking, specifically for CSS selector generation.
|
|
12
|
+
*/
|
|
13
|
+
export interface InteractionPerformanceConfig {
|
|
14
|
+
/**
|
|
15
|
+
* Maximum time in milliseconds allowed for CSS selector generation.
|
|
16
|
+
* If selector generation takes longer than this, it will throw a timeout error.
|
|
17
|
+
* Default: undefined (no timeout limit)
|
|
18
|
+
*/
|
|
19
|
+
timeoutMs?: number;
|
|
20
|
+
/**
|
|
21
|
+
* Maximum number of attempts to optimize/simplify the CSS selector path.
|
|
22
|
+
* Higher values may produce shorter selectors but take longer to compute.
|
|
23
|
+
* Default: 10000
|
|
24
|
+
*/
|
|
25
|
+
maxNumberOfTries?: number;
|
|
26
|
+
/**
|
|
27
|
+
* Maximum number of CSS selector combinations to test for uniqueness.
|
|
28
|
+
* If more combinations would be generated, falls back to a simpler strategy.
|
|
29
|
+
* Default: 1000
|
|
30
|
+
*/
|
|
31
|
+
threshold?: number;
|
|
32
|
+
}
|
|
10
33
|
export interface SessionReplayPerformanceConfig {
|
|
11
34
|
enabled: boolean;
|
|
12
35
|
timeout?: number;
|
|
36
|
+
/**
|
|
37
|
+
* Performance configuration for interaction tracking (clicks, scrolls).
|
|
38
|
+
*/
|
|
39
|
+
interaction?: InteractionPerformanceConfig;
|
|
13
40
|
}
|
|
14
41
|
/**
|
|
15
42
|
* UGC filter rule.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session-replay.d.ts","sourceRoot":"","sources":["../../../src/typings/session-replay.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;AAClD,OAAO,EACL,SAAS,EAGV,MAAM,mCAAmC,CAAC;AAE3C,MAAM,MAAM,SAAS,GACjB,OAAO,GACP,QAAQ,GACR,cAAc,CAAC;AAEnB,MAAM,WAAW,0BAA0B;IACzC,aAAa,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAClC,gBAAgB,CAAC,EAAE,SAAS,CAAC;IAC7B,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,cAAc,CAAC,EAAE,MAAM,EAAE,CAAC;CAC3B;AAED,MAAM,WAAW,8BAA8B;IAC7C,OAAO,EAAE,OAAO,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"session-replay.d.ts","sourceRoot":"","sources":["../../../src/typings/session-replay.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;AAClD,OAAO,EACL,SAAS,EAGV,MAAM,mCAAmC,CAAC;AAE3C,MAAM,MAAM,SAAS,GACjB,OAAO,GACP,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ACxB;;OAEG;IACH,sBAAsB,CAAC,EAAE,OAAO,CAAC;IACjC;;OAEG;IACH,iBAAiB,CAAC,EAAE,8BAA8B,CAAC;IACnD;;OAEG;IACH,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB;;;;;OAKG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;;;OAIG;IACH,eAAe,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,MAAM,GAAG,SAAS,CAAC;IACvD;;;OAGG;IACH,YAAY,CAAC,EAAE;QACb,YAAY,EAAE,OAAO,CAAC;KACvB,CAAC;IACF;;OAEG;IACH,eAAe,CAAC,EAAE;QAChB,MAAM,CAAC,EAAE,OAAO,CAAC;QACjB,OAAO,CAAC,EAAE,OAAO,CAAC;KACnB,CAAC;IACF;;OAEG;IACH,qCAAqC,CAAC,EAAE,OAAO,CAAC;IAEhD,iBAAiB,CAAC,EAAE,8BAA8B,CAAC;IAEnD;;;;;;;OAOG;IACH,sBAAsB,CAAC,EAAE,OAAO,CAAC;IACjC;;;;;OAKG;IACH,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC;;;;;OAKG;IACH,oBAAoB,CAAC,EAAE,OAAO,CAAC;CAChC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session-replay.js","sourceRoot":"","sources":["../../../src/typings/session-replay.ts"],"names":[],"mappings":"","sourcesContent":["import { Event } from '@amplitude/analytics-core';\nimport {\n StoreType,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n type SessionReplayOptions as StandaloneSessionReplayOptions, // used for documentation\n} from '@amplitude/session-replay-browser';\n\nexport type MaskLevel =\n | 'light' // only mask a subset of inputs that’s deemed sensitive - password, credit card, telephone #, email. These are information we never want to capture.\n | 'medium' // mask all inputs\n | 'conservative'; // mask all inputs and all texts\n\nexport interface SessionReplayPrivacyConfig {\n blockSelector?: string | string[];\n defaultMaskLevel?: MaskLevel;\n maskSelector?: string[];\n unmaskSelector?: string[];\n}\n\nexport interface SessionReplayPerformanceConfig {\n enabled: boolean;\n timeout?: number;\n}\n\n/**\n * UGC filter rule.\n */\nexport type UGCFilterRule = {\n /**\n * The selector of the UGC element.\n */\n selector: string;\n /**\n * The replacement text for the UGC element.\n */\n replacement: string;\n};\n\nexport interface SessionReplayInteractionConfig {\n trackEveryNms?: number;\n enabled: boolean; // defaults to false\n batch: boolean; // defaults to false\n /**\n * UGC filter rules.\n */\n ugcFilterRules?: UGCFilterRule[];\n}\n\nexport interface SessionReplayOptions {\n /**\n * @see {@link StandaloneSessionReplayOptions.sampleRate}\n */\n sampleRate?: number;\n /**\n * @see {@link StandaloneSessionReplayOptions.privacyConfig}\n */\n privacyConfig?: SessionReplayPrivacyConfig;\n /**\n * @see {@link StandaloneSessionReplayOptions.debugMode}\n */\n debugMode?: boolean;\n /**\n * If this is enabled we will force the browser SDK to also send start and end session events.\n */\n forceSessionTracking?: boolean;\n /**\n * @see {@link StandaloneSessionReplayOptions.configServerUrl}\n */\n configServerUrl?: string;\n /**\n * @see {@link StandaloneSessionReplayOptions.trackServerUrl}\n */\n trackServerUrl?: string;\n /**\n * @see {@link StandaloneSessionReplayOptions.shouldInlineStylesheet}\n */\n shouldInlineStylesheet?: boolean;\n /**\n * @see {@link StandaloneSessionReplayOptions.performanceConfig}\n */\n performanceConfig?: SessionReplayPerformanceConfig;\n /**\n * @see {@link StandaloneSessionReplayOptions.storeType}\n */\n storeType?: StoreType;\n /**\n * If true, the SDK will compress replay events using a web worker.\n * This offloads compression to a separate thread, improving performance on the main thread.\n *\n * @defaultValue false\n */\n useWebWorker?: boolean;\n /**\n * Override the device ID for session replay.\n */\n deviceId?: string;\n /**\n * Dynamically overrides the session ID for replay. Ensure stability to avoid frequent restarts.\n * @param event Browser SDK event\n * @returns The session ID for the session replay.\n */\n customSessionId?: (event: Event) => string | undefined;\n /**\n * @deprecated Use `useWebWorker` instead. This will be removed in a future version.\n * @see {@link StandaloneSessionReplayOptions.useWebWorker}\n */\n experimental?: {\n useWebWorker: boolean;\n };\n /**\n * @see {@link StandaloneSessionReplayOptions.omitElementTags}\n */\n omitElementTags?: {\n script?: boolean;\n comment?: boolean;\n };\n /**\n * If true, applies a background color to blocked elements for visual masking. Defaults to false.\n */\n applyBackgroundColorToBlockedElements?: boolean;\n\n interactionConfig?: SessionReplayInteractionConfig;\n\n /**\n * Enables URL change polling as a fallback for SPA route tracking.\n * When enabled, the SDK will periodically check for URL changes every second\n * in addition to patching the History API. This is useful for edge cases where\n * route changes might bypass the standard History API methods.\n *\n * @defaultValue false\n */\n enableUrlChangePolling?: boolean;\n /**\n * Specifies the interval in milliseconds for URL change polling when enableUrlChangePolling is true.\n * The SDK will check for URL changes at this interval as a fallback for SPA route tracking.\n *\n * @defaultValue 1000\n */\n urlChangePollingInterval?: number;\n /**\n * Whether to capture document title in URL change events.\n * When disabled, the title field will be empty in URL change events.\n *\n * @defaultValue false\n */\n captureDocumentTitle?: boolean;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"session-replay.js","sourceRoot":"","sources":["../../../src/typings/session-replay.ts"],"names":[],"mappings":"","sourcesContent":["import { Event } from '@amplitude/analytics-core';\nimport {\n StoreType,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n type SessionReplayOptions as StandaloneSessionReplayOptions, // used for documentation\n} from '@amplitude/session-replay-browser';\n\nexport type MaskLevel =\n | 'light' // only mask a subset of inputs that’s deemed sensitive - password, credit card, telephone #, email. These are information we never want to capture.\n | 'medium' // mask all inputs\n | 'conservative'; // mask all inputs and all texts\n\nexport interface SessionReplayPrivacyConfig {\n blockSelector?: string | string[];\n defaultMaskLevel?: MaskLevel;\n maskSelector?: string[];\n unmaskSelector?: string[];\n}\n\n/**\n * Performance configuration for interaction tracking, specifically for CSS selector generation.\n */\nexport interface InteractionPerformanceConfig {\n /**\n * Maximum time in milliseconds allowed for CSS selector generation.\n * If selector generation takes longer than this, it will throw a timeout error.\n * Default: undefined (no timeout limit)\n */\n timeoutMs?: number;\n /**\n * Maximum number of attempts to optimize/simplify the CSS selector path.\n * Higher values may produce shorter selectors but take longer to compute.\n * Default: 10000\n */\n maxNumberOfTries?: number;\n /**\n * Maximum number of CSS selector combinations to test for uniqueness.\n * If more combinations would be generated, falls back to a simpler strategy.\n * Default: 1000\n */\n threshold?: number;\n}\n\nexport interface SessionReplayPerformanceConfig {\n enabled: boolean;\n timeout?: number;\n /**\n * Performance configuration for interaction tracking (clicks, scrolls).\n */\n interaction?: InteractionPerformanceConfig;\n}\n\n/**\n * UGC filter rule.\n */\nexport type UGCFilterRule = {\n /**\n * The selector of the UGC element.\n */\n selector: string;\n /**\n * The replacement text for the UGC element.\n */\n replacement: string;\n};\n\nexport interface SessionReplayInteractionConfig {\n trackEveryNms?: number;\n enabled: boolean; // defaults to false\n batch: boolean; // defaults to false\n /**\n * UGC filter rules.\n */\n ugcFilterRules?: UGCFilterRule[];\n}\n\nexport interface SessionReplayOptions {\n /**\n * @see {@link StandaloneSessionReplayOptions.sampleRate}\n */\n sampleRate?: number;\n /**\n * @see {@link StandaloneSessionReplayOptions.privacyConfig}\n */\n privacyConfig?: SessionReplayPrivacyConfig;\n /**\n * @see {@link StandaloneSessionReplayOptions.debugMode}\n */\n debugMode?: boolean;\n /**\n * If this is enabled we will force the browser SDK to also send start and end session events.\n */\n forceSessionTracking?: boolean;\n /**\n * @see {@link StandaloneSessionReplayOptions.configServerUrl}\n */\n configServerUrl?: string;\n /**\n * @see {@link StandaloneSessionReplayOptions.trackServerUrl}\n */\n trackServerUrl?: string;\n /**\n * @see {@link StandaloneSessionReplayOptions.shouldInlineStylesheet}\n */\n shouldInlineStylesheet?: boolean;\n /**\n * @see {@link StandaloneSessionReplayOptions.performanceConfig}\n */\n performanceConfig?: SessionReplayPerformanceConfig;\n /**\n * @see {@link StandaloneSessionReplayOptions.storeType}\n */\n storeType?: StoreType;\n /**\n * If true, the SDK will compress replay events using a web worker.\n * This offloads compression to a separate thread, improving performance on the main thread.\n *\n * @defaultValue false\n */\n useWebWorker?: boolean;\n /**\n * Override the device ID for session replay.\n */\n deviceId?: string;\n /**\n * Dynamically overrides the session ID for replay. Ensure stability to avoid frequent restarts.\n * @param event Browser SDK event\n * @returns The session ID for the session replay.\n */\n customSessionId?: (event: Event) => string | undefined;\n /**\n * @deprecated Use `useWebWorker` instead. This will be removed in a future version.\n * @see {@link StandaloneSessionReplayOptions.useWebWorker}\n */\n experimental?: {\n useWebWorker: boolean;\n };\n /**\n * @see {@link StandaloneSessionReplayOptions.omitElementTags}\n */\n omitElementTags?: {\n script?: boolean;\n comment?: boolean;\n };\n /**\n * If true, applies a background color to blocked elements for visual masking. Defaults to false.\n */\n applyBackgroundColorToBlockedElements?: boolean;\n\n interactionConfig?: SessionReplayInteractionConfig;\n\n /**\n * Enables URL change polling as a fallback for SPA route tracking.\n * When enabled, the SDK will periodically check for URL changes every second\n * in addition to patching the History API. This is useful for edge cases where\n * route changes might bypass the standard History API methods.\n *\n * @defaultValue false\n */\n enableUrlChangePolling?: boolean;\n /**\n * Specifies the interval in milliseconds for URL change polling when enableUrlChangePolling is true.\n * The SDK will check for URL changes at this interval as a fallback for SPA route tracking.\n *\n * @defaultValue 1000\n */\n urlChangePollingInterval?: number;\n /**\n * Whether to capture document title in URL change events.\n * When disabled, the title field will be empty in URL change events.\n *\n * @defaultValue false\n */\n captureDocumentTitle?: boolean;\n}\n"]}
|
package/lib/cjs/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "1.
|
|
1
|
+
export declare const VERSION = "1.25.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/lib/cjs/version.js
CHANGED
package/lib/cjs/version.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":";;;AAAA,oDAAoD;AACvC,QAAA,OAAO,GAAG,QAAQ,CAAC","sourcesContent":["// Autogenerated by `yarn version-file`. DO NOT EDIT\nexport const VERSION = '1.
|
|
1
|
+
{"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":";;;AAAA,oDAAoD;AACvC,QAAA,OAAO,GAAG,QAAQ,CAAC","sourcesContent":["// Autogenerated by `yarn version-file`. DO NOT EDIT\nexport const VERSION = '1.25.0';\n"]}
|
|
@@ -7,9 +7,36 @@ export interface SessionReplayPrivacyConfig {
|
|
|
7
7
|
maskSelector?: string[];
|
|
8
8
|
unmaskSelector?: string[];
|
|
9
9
|
}
|
|
10
|
+
/**
|
|
11
|
+
* Performance configuration for interaction tracking, specifically for CSS selector generation.
|
|
12
|
+
*/
|
|
13
|
+
export interface InteractionPerformanceConfig {
|
|
14
|
+
/**
|
|
15
|
+
* Maximum time in milliseconds allowed for CSS selector generation.
|
|
16
|
+
* If selector generation takes longer than this, it will throw a timeout error.
|
|
17
|
+
* Default: undefined (no timeout limit)
|
|
18
|
+
*/
|
|
19
|
+
timeoutMs?: number;
|
|
20
|
+
/**
|
|
21
|
+
* Maximum number of attempts to optimize/simplify the CSS selector path.
|
|
22
|
+
* Higher values may produce shorter selectors but take longer to compute.
|
|
23
|
+
* Default: 10000
|
|
24
|
+
*/
|
|
25
|
+
maxNumberOfTries?: number;
|
|
26
|
+
/**
|
|
27
|
+
* Maximum number of CSS selector combinations to test for uniqueness.
|
|
28
|
+
* If more combinations would be generated, falls back to a simpler strategy.
|
|
29
|
+
* Default: 1000
|
|
30
|
+
*/
|
|
31
|
+
threshold?: number;
|
|
32
|
+
}
|
|
10
33
|
export interface SessionReplayPerformanceConfig {
|
|
11
34
|
enabled: boolean;
|
|
12
35
|
timeout?: number;
|
|
36
|
+
/**
|
|
37
|
+
* Performance configuration for interaction tracking (clicks, scrolls).
|
|
38
|
+
*/
|
|
39
|
+
interaction?: InteractionPerformanceConfig;
|
|
13
40
|
}
|
|
14
41
|
/**
|
|
15
42
|
* UGC filter rule.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session-replay.d.ts","sourceRoot":"","sources":["../../../src/typings/session-replay.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;AAClD,OAAO,EACL,SAAS,EAGV,MAAM,mCAAmC,CAAC;AAE3C,MAAM,MAAM,SAAS,GACjB,OAAO,GACP,QAAQ,GACR,cAAc,CAAC;AAEnB,MAAM,WAAW,0BAA0B;IACzC,aAAa,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAClC,gBAAgB,CAAC,EAAE,SAAS,CAAC;IAC7B,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,cAAc,CAAC,EAAE,MAAM,EAAE,CAAC;CAC3B;AAED,MAAM,WAAW,8BAA8B;IAC7C,OAAO,EAAE,OAAO,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"session-replay.d.ts","sourceRoot":"","sources":["../../../src/typings/session-replay.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;AAClD,OAAO,EACL,SAAS,EAGV,MAAM,mCAAmC,CAAC;AAE3C,MAAM,MAAM,SAAS,GACjB,OAAO,GACP,QAAQ,GACR,cAAc,CAAC;AAEnB,MAAM,WAAW,0BAA0B;IACzC,aAAa,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAClC,gBAAgB,CAAC,EAAE,SAAS,CAAC;IAC7B,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,cAAc,CAAC,EAAE,MAAM,EAAE,CAAC;CAC3B;AAED;;GAEG;AACH,MAAM,WAAW,4BAA4B;IAC3C;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM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ACF;;OAEG;IACH,eAAe,CAAC,EAAE;QAChB,MAAM,CAAC,EAAE,OAAO,CAAC;QACjB,OAAO,CAAC,EAAE,OAAO,CAAC;KACnB,CAAC;IACF;;OAEG;IACH,qCAAqC,CAAC,EAAE,OAAO,CAAC;IAEhD,iBAAiB,CAAC,EAAE,8BAA8B,CAAC;IAEnD;;;;;;;OAOG;IACH,sBAAsB,CAAC,EAAE,OAAO,CAAC;IACjC;;;;;OAKG;IACH,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC;;;;;OAKG;IACH,oBAAoB,CAAC,EAAE,OAAO,CAAC;CAChC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session-replay.js","sourceRoot":"","sources":["../../../src/typings/session-replay.ts"],"names":[],"mappings":"","sourcesContent":["import { Event } from '@amplitude/analytics-core';\nimport {\n StoreType,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n type SessionReplayOptions as StandaloneSessionReplayOptions, // used for documentation\n} from '@amplitude/session-replay-browser';\n\nexport type MaskLevel =\n | 'light' // only mask a subset of inputs that’s deemed sensitive - password, credit card, telephone #, email. These are information we never want to capture.\n | 'medium' // mask all inputs\n | 'conservative'; // mask all inputs and all texts\n\nexport interface SessionReplayPrivacyConfig {\n blockSelector?: string | string[];\n defaultMaskLevel?: MaskLevel;\n maskSelector?: string[];\n unmaskSelector?: string[];\n}\n\nexport interface SessionReplayPerformanceConfig {\n enabled: boolean;\n timeout?: number;\n}\n\n/**\n * UGC filter rule.\n */\nexport type UGCFilterRule = {\n /**\n * The selector of the UGC element.\n */\n selector: string;\n /**\n * The replacement text for the UGC element.\n */\n replacement: string;\n};\n\nexport interface SessionReplayInteractionConfig {\n trackEveryNms?: number;\n enabled: boolean; // defaults to false\n batch: boolean; // defaults to false\n /**\n * UGC filter rules.\n */\n ugcFilterRules?: UGCFilterRule[];\n}\n\nexport interface SessionReplayOptions {\n /**\n * @see {@link StandaloneSessionReplayOptions.sampleRate}\n */\n sampleRate?: number;\n /**\n * @see {@link StandaloneSessionReplayOptions.privacyConfig}\n */\n privacyConfig?: SessionReplayPrivacyConfig;\n /**\n * @see {@link StandaloneSessionReplayOptions.debugMode}\n */\n debugMode?: boolean;\n /**\n * If this is enabled we will force the browser SDK to also send start and end session events.\n */\n forceSessionTracking?: boolean;\n /**\n * @see {@link StandaloneSessionReplayOptions.configServerUrl}\n */\n configServerUrl?: string;\n /**\n * @see {@link StandaloneSessionReplayOptions.trackServerUrl}\n */\n trackServerUrl?: string;\n /**\n * @see {@link StandaloneSessionReplayOptions.shouldInlineStylesheet}\n */\n shouldInlineStylesheet?: boolean;\n /**\n * @see {@link StandaloneSessionReplayOptions.performanceConfig}\n */\n performanceConfig?: SessionReplayPerformanceConfig;\n /**\n * @see {@link StandaloneSessionReplayOptions.storeType}\n */\n storeType?: StoreType;\n /**\n * If true, the SDK will compress replay events using a web worker.\n * This offloads compression to a separate thread, improving performance on the main thread.\n *\n * @defaultValue false\n */\n useWebWorker?: boolean;\n /**\n * Override the device ID for session replay.\n */\n deviceId?: string;\n /**\n * Dynamically overrides the session ID for replay. Ensure stability to avoid frequent restarts.\n * @param event Browser SDK event\n * @returns The session ID for the session replay.\n */\n customSessionId?: (event: Event) => string | undefined;\n /**\n * @deprecated Use `useWebWorker` instead. This will be removed in a future version.\n * @see {@link StandaloneSessionReplayOptions.useWebWorker}\n */\n experimental?: {\n useWebWorker: boolean;\n };\n /**\n * @see {@link StandaloneSessionReplayOptions.omitElementTags}\n */\n omitElementTags?: {\n script?: boolean;\n comment?: boolean;\n };\n /**\n * If true, applies a background color to blocked elements for visual masking. Defaults to false.\n */\n applyBackgroundColorToBlockedElements?: boolean;\n\n interactionConfig?: SessionReplayInteractionConfig;\n\n /**\n * Enables URL change polling as a fallback for SPA route tracking.\n * When enabled, the SDK will periodically check for URL changes every second\n * in addition to patching the History API. This is useful for edge cases where\n * route changes might bypass the standard History API methods.\n *\n * @defaultValue false\n */\n enableUrlChangePolling?: boolean;\n /**\n * Specifies the interval in milliseconds for URL change polling when enableUrlChangePolling is true.\n * The SDK will check for URL changes at this interval as a fallback for SPA route tracking.\n *\n * @defaultValue 1000\n */\n urlChangePollingInterval?: number;\n /**\n * Whether to capture document title in URL change events.\n * When disabled, the title field will be empty in URL change events.\n *\n * @defaultValue false\n */\n captureDocumentTitle?: boolean;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"session-replay.js","sourceRoot":"","sources":["../../../src/typings/session-replay.ts"],"names":[],"mappings":"","sourcesContent":["import { Event } from '@amplitude/analytics-core';\nimport {\n StoreType,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n type SessionReplayOptions as StandaloneSessionReplayOptions, // used for documentation\n} from '@amplitude/session-replay-browser';\n\nexport type MaskLevel =\n | 'light' // only mask a subset of inputs that’s deemed sensitive - password, credit card, telephone #, email. These are information we never want to capture.\n | 'medium' // mask all inputs\n | 'conservative'; // mask all inputs and all texts\n\nexport interface SessionReplayPrivacyConfig {\n blockSelector?: string | string[];\n defaultMaskLevel?: MaskLevel;\n maskSelector?: string[];\n unmaskSelector?: string[];\n}\n\n/**\n * Performance configuration for interaction tracking, specifically for CSS selector generation.\n */\nexport interface InteractionPerformanceConfig {\n /**\n * Maximum time in milliseconds allowed for CSS selector generation.\n * If selector generation takes longer than this, it will throw a timeout error.\n * Default: undefined (no timeout limit)\n */\n timeoutMs?: number;\n /**\n * Maximum number of attempts to optimize/simplify the CSS selector path.\n * Higher values may produce shorter selectors but take longer to compute.\n * Default: 10000\n */\n maxNumberOfTries?: number;\n /**\n * Maximum number of CSS selector combinations to test for uniqueness.\n * If more combinations would be generated, falls back to a simpler strategy.\n * Default: 1000\n */\n threshold?: number;\n}\n\nexport interface SessionReplayPerformanceConfig {\n enabled: boolean;\n timeout?: number;\n /**\n * Performance configuration for interaction tracking (clicks, scrolls).\n */\n interaction?: InteractionPerformanceConfig;\n}\n\n/**\n * UGC filter rule.\n */\nexport type UGCFilterRule = {\n /**\n * The selector of the UGC element.\n */\n selector: string;\n /**\n * The replacement text for the UGC element.\n */\n replacement: string;\n};\n\nexport interface SessionReplayInteractionConfig {\n trackEveryNms?: number;\n enabled: boolean; // defaults to false\n batch: boolean; // defaults to false\n /**\n * UGC filter rules.\n */\n ugcFilterRules?: UGCFilterRule[];\n}\n\nexport interface SessionReplayOptions {\n /**\n * @see {@link StandaloneSessionReplayOptions.sampleRate}\n */\n sampleRate?: number;\n /**\n * @see {@link StandaloneSessionReplayOptions.privacyConfig}\n */\n privacyConfig?: SessionReplayPrivacyConfig;\n /**\n * @see {@link StandaloneSessionReplayOptions.debugMode}\n */\n debugMode?: boolean;\n /**\n * If this is enabled we will force the browser SDK to also send start and end session events.\n */\n forceSessionTracking?: boolean;\n /**\n * @see {@link StandaloneSessionReplayOptions.configServerUrl}\n */\n configServerUrl?: string;\n /**\n * @see {@link StandaloneSessionReplayOptions.trackServerUrl}\n */\n trackServerUrl?: string;\n /**\n * @see {@link StandaloneSessionReplayOptions.shouldInlineStylesheet}\n */\n shouldInlineStylesheet?: boolean;\n /**\n * @see {@link StandaloneSessionReplayOptions.performanceConfig}\n */\n performanceConfig?: SessionReplayPerformanceConfig;\n /**\n * @see {@link StandaloneSessionReplayOptions.storeType}\n */\n storeType?: StoreType;\n /**\n * If true, the SDK will compress replay events using a web worker.\n * This offloads compression to a separate thread, improving performance on the main thread.\n *\n * @defaultValue false\n */\n useWebWorker?: boolean;\n /**\n * Override the device ID for session replay.\n */\n deviceId?: string;\n /**\n * Dynamically overrides the session ID for replay. Ensure stability to avoid frequent restarts.\n * @param event Browser SDK event\n * @returns The session ID for the session replay.\n */\n customSessionId?: (event: Event) => string | undefined;\n /**\n * @deprecated Use `useWebWorker` instead. This will be removed in a future version.\n * @see {@link StandaloneSessionReplayOptions.useWebWorker}\n */\n experimental?: {\n useWebWorker: boolean;\n };\n /**\n * @see {@link StandaloneSessionReplayOptions.omitElementTags}\n */\n omitElementTags?: {\n script?: boolean;\n comment?: boolean;\n };\n /**\n * If true, applies a background color to blocked elements for visual masking. Defaults to false.\n */\n applyBackgroundColorToBlockedElements?: boolean;\n\n interactionConfig?: SessionReplayInteractionConfig;\n\n /**\n * Enables URL change polling as a fallback for SPA route tracking.\n * When enabled, the SDK will periodically check for URL changes every second\n * in addition to patching the History API. This is useful for edge cases where\n * route changes might bypass the standard History API methods.\n *\n * @defaultValue false\n */\n enableUrlChangePolling?: boolean;\n /**\n * Specifies the interval in milliseconds for URL change polling when enableUrlChangePolling is true.\n * The SDK will check for URL changes at this interval as a fallback for SPA route tracking.\n *\n * @defaultValue 1000\n */\n urlChangePollingInterval?: number;\n /**\n * Whether to capture document title in URL change events.\n * When disabled, the title field will be empty in URL change events.\n *\n * @defaultValue false\n */\n captureDocumentTitle?: boolean;\n}\n"]}
|
package/lib/esm/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "1.
|
|
1
|
+
export declare const VERSION = "1.25.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/lib/esm/version.js
CHANGED
package/lib/esm/version.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":"AAAA,oDAAoD;AACpD,MAAM,CAAC,IAAM,OAAO,GAAG,QAAQ,CAAC","sourcesContent":["// Autogenerated by `yarn version-file`. DO NOT EDIT\nexport const VERSION = '1.
|
|
1
|
+
{"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":"AAAA,oDAAoD;AACpD,MAAM,CAAC,IAAM,OAAO,GAAG,QAAQ,CAAC","sourcesContent":["// Autogenerated by `yarn version-file`. DO NOT EDIT\nexport const VERSION = '1.25.0';\n"]}
|