From 420154c395387cc9b27f74db1b6508a659efdbba Mon Sep 17 00:00:00 2001 From: luyi Date: Tue, 24 Sep 2024 14:11:11 +0200 Subject: [PATCH] RUM-6316: Remove Session Replay button mapper border --- .../internal/recorder/mapper/ButtonMapper.kt | 15 +-------------- .../internal/recorder/mapper/ButtonMapperTest.kt | 5 +---- 2 files changed, 2 insertions(+), 18 deletions(-) diff --git a/features/dd-sdk-android-session-replay/src/main/kotlin/com/datadog/android/sessionreplay/internal/recorder/mapper/ButtonMapper.kt b/features/dd-sdk-android-session-replay/src/main/kotlin/com/datadog/android/sessionreplay/internal/recorder/mapper/ButtonMapper.kt index a7974b50b1..6bbd6c9225 100644 --- a/features/dd-sdk-android-session-replay/src/main/kotlin/com/datadog/android/sessionreplay/internal/recorder/mapper/ButtonMapper.kt +++ b/features/dd-sdk-android-session-replay/src/main/kotlin/com/datadog/android/sessionreplay/internal/recorder/mapper/ButtonMapper.kt @@ -37,19 +37,6 @@ internal class ButtonMapper( asyncJobStatusCallback: AsyncJobStatusCallback, internalLogger: InternalLogger ): List { - return super.map(view, mappingContext, asyncJobStatusCallback, internalLogger).map { - if (it is MobileSegment.Wireframe.TextWireframe && - it.shapeStyle == null && it.border == null - ) { - // we were not able to resolve the background for this button so just add a border - it.copy(border = MobileSegment.ShapeBorder(BLACK_COLOR, 1)) - } else { - it - } - } - } - - companion object { - internal const val BLACK_COLOR = "#000000ff" + return super.map(view, mappingContext, asyncJobStatusCallback, internalLogger) } } diff --git a/features/dd-sdk-android-session-replay/src/test/kotlin/com/datadog/android/sessionreplay/internal/recorder/mapper/ButtonMapperTest.kt b/features/dd-sdk-android-session-replay/src/test/kotlin/com/datadog/android/sessionreplay/internal/recorder/mapper/ButtonMapperTest.kt index 29f6be7934..855d68addb 100644 --- a/features/dd-sdk-android-session-replay/src/test/kotlin/com/datadog/android/sessionreplay/internal/recorder/mapper/ButtonMapperTest.kt +++ b/features/dd-sdk-android-session-replay/src/test/kotlin/com/datadog/android/sessionreplay/internal/recorder/mapper/ButtonMapperTest.kt @@ -187,10 +187,7 @@ internal abstract class ButtonMapperTest : BaseAsyncBackgroundWireframeMapperTes height = fakeViewGlobalBounds.height, clip = null, shapeStyle = null, - border = MobileSegment.ShapeBorder( - color = "#000000ff", - width = 1L - ), + border = null, text = expectedPrivacyCompliantText(""), textStyle = MobileSegment.TextStyle( family = TextViewMapper.SANS_SERIF_FAMILY_NAME,