refactor(ui): migrate MapView dialog to Compose M3 + drop legacy material dependency#5988
Merged
Conversation
…terial dependency Replace the F-Droid MapView delete-waypoint dialog (the last MaterialAlertDialogBuilder call site) with a Compose Material 3 AlertDialog driven by a showDeleteWaypointDialog state, then drop the maintenance-only com.google.android.material:material View library entirely. - Convert showDeleteMarkerDialog into showDeleteWaypointDialog state + M3 AlertDialog - Preserve all actions: Cancel (dismiss), Delete for me, and Delete for everyone (the last gated on lock/connection as before) - Remove com.google.android.material:material from libs.versions.toml and androidApp - Declare androidx.appcompat directly (AppCompatActivity/AppCompatResources were previously satisfied transitively via material) - Swap the post-splash host theme from Theme.Material3.DynamicColors.DayNight to Theme.AppCompat.DayNight.NoActionBar; Compose already supplies dynamic color Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…flavor The dd-sdk-android-session-replay-material extension is only needed when Session Replay must record Material View components, but it was never registered (no addExtensionSupport(MaterialExtensionSupport()) call) and the app is fully Compose. It also pulled com.google.android.material transitively, re-introducing into the google flavor the very View library this PR removes. Removing it purges com.google.android.material from googleDebugRuntimeClasspath entirely, completing the legacy-material cleanup across both flavors. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Removes the maintenance-only
com.google.android.material:material(1.14.0) View library, whose only remaining use was a singleMaterialAlertDialogBuildercall in the F-DroidMapView. The app is otherwise fully Compose Multiplatform, so the legacy MDC dependency was pure dead weight. This purgescom.google.android.materialfrom both flavors' runtime classpaths.🛠️ Refactoring & Architecture
MaterialAlertDialogBuilderdelete-waypoint dialog inMapView.kt(F-Droid flavor) with a Compose Material 3AlertDialog, driven by a newshowDeleteWaypointDialogstate (mirrors the existingshowEditWaypointDialogpattern).locked_to/connection exactly as before.Theme.Material3.DynamicColors.DayNight.NoActionBartoTheme.AppCompat.DayNight.NoActionBar. The app is pure Compose (setContent), and dynamic color is already supplied by Compose'sdynamicColorScheme— the XML theme only governs the splash→Compose window handoff.🧹 Chores
materialfromgradle/libs.versions.tomlandandroidApp/build.gradle.kts.androidx.appcompatdirectly inandroidApp—AppCompatActivity/AppCompatResources/AppCompatDelegatewere previously satisfied transitively through the material library.dd-sdk-android-session-replay-materialDatadog extension (google flavor): Session Replay never registered it (addExtensionSupport(MaterialExtensionSupport())was never called) and it pulledcom.google.android.materialback in transitively. Removing it purges the View library fromgoogleDebugRuntimeClasspathentirely.Reviewer notes
MainActivityusessetContentwith nosetContentView/LayoutInflaterunder the activity theme, and the sole layout XML (a Glance widget preview, rendered outside the activity) references no?attr/...Material theme attributes — so nothing resolves Material3-only attrs at inflation time.com.google.android.materialno longer appears in:androidApp:dependencies --configuration googleDebugRuntimeClasspath.spotlessApply spotlessCheck detekt assembleDebug test allTests(both google + fdroid flavors assemble; full KMP test suite green);assembleGoogleDebugre-verified after the Datadog change.