🐛 fix frustration animation in session replay #1999
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
Frustration records used to reference MouseInteraction/Click records. Since Click Actions are now generated based on mouseup events, we broke this reference. There is no MouseInteraction/PointerUp record that Frustration can reference.
Changes
This commit is a quick fix. It changes how we are generating MouseInteraction/MouseUp records: instead of listening to mouseup DOM events, we now listen to pointerup events, allowing Frustration records to reference MouseInteraction/MouseUp records.
This works on the player side without any modification.
In the context of supporting Mobile Session Replay, we introduced
PointerInteraction
records used by the Mobile SDKs in place ofMouseInteraction
. In the future, it would be great to replaceMouseInteraction
byPointerInteraction
in the Browser SDK so we have an uniform way to convey such interaction. This would cleanly solve the issue since we would havePointerInteraction/Up
records that we could reference fromFrustration
records.Testing
I have gone over the contributing documentation.