diff --git a/app/build.gradle b/app/build.gradle
index da541b81d..c85287cf3 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -197,7 +197,6 @@ dependencies {
implementation 'androidx.compose.material:material-icons-extended'
implementation 'androidx.activity:activity-compose'
implementation 'androidx.compose.runtime:runtime-livedata'
- implementation "com.google.accompanist:accompanist-themeadapter-appcompat:0.36.0"
// Android Studio Preview support
implementation 'androidx.compose.ui:ui-tooling-preview'
diff --git a/app/src/main/java/com/geeksville/mesh/ui/ChannelFragment.kt b/app/src/main/java/com/geeksville/mesh/ui/ChannelFragment.kt
index 2a6ffeb1f..d2b020028 100644
--- a/app/src/main/java/com/geeksville/mesh/ui/ChannelFragment.kt
+++ b/app/src/main/java/com/geeksville/mesh/ui/ChannelFragment.kt
@@ -49,6 +49,7 @@ import androidx.compose.material.icons.twotone.Check
import androidx.compose.material.icons.twotone.Close
import androidx.compose.material.icons.twotone.ContentCopy
import androidx.compose.runtime.Composable
+import androidx.compose.runtime.CompositionLocalProvider
import androidx.compose.runtime.LaunchedEffect
import androidx.compose.runtime.getValue
import androidx.compose.runtime.mutableStateListOf
@@ -109,7 +110,7 @@ import com.geeksville.mesh.ui.components.config.EditChannelDialog
import com.geeksville.mesh.ui.components.dragContainer
import com.geeksville.mesh.ui.components.dragDropItemsIndexed
import com.geeksville.mesh.ui.components.rememberDragDropState
-import com.google.accompanist.themeadapter.appcompat.AppCompatTheme
+import com.geeksville.mesh.ui.theme.AppTheme
import com.google.android.material.dialog.MaterialAlertDialogBuilder
import com.journeyapps.barcodescanner.ScanContract
import com.journeyapps.barcodescanner.ScanOptions
@@ -128,8 +129,12 @@ class ChannelFragment : ScreenFragment("Channel"), Logging {
return ComposeView(requireContext()).apply {
setViewCompositionStrategy(ViewCompositionStrategy.DisposeOnViewTreeLifecycleDestroyed)
setContent {
- AppCompatTheme {
- ChannelScreen(model)
+ AppTheme {
+ CompositionLocalProvider(
+ LocalContentColor provides MaterialTheme.colors.onSurface
+ ) {
+ ChannelScreen(model)
+ }
}
}
}
diff --git a/app/src/main/java/com/geeksville/mesh/ui/NavGraph.kt b/app/src/main/java/com/geeksville/mesh/ui/NavGraph.kt
index 807d7edb1..992d14ec5 100644
--- a/app/src/main/java/com/geeksville/mesh/ui/NavGraph.kt
+++ b/app/src/main/java/com/geeksville/mesh/ui/NavGraph.kt
@@ -82,7 +82,6 @@ import com.geeksville.mesh.ui.components.NodeMapScreen
import com.geeksville.mesh.ui.components.PositionLogScreen
import com.geeksville.mesh.ui.components.SignalMetricsScreen
import com.geeksville.mesh.ui.components.TracerouteLogScreen
-import com.geeksville.mesh.util.UiText
import com.geeksville.mesh.ui.components.config.AmbientLightingConfigScreen
import com.geeksville.mesh.ui.components.config.AudioConfigScreen
import com.geeksville.mesh.ui.components.config.BluetoothConfigScreen
@@ -106,7 +105,8 @@ import com.geeksville.mesh.ui.components.config.SerialConfigScreen
import com.geeksville.mesh.ui.components.config.StoreForwardConfigScreen
import com.geeksville.mesh.ui.components.config.TelemetryConfigScreen
import com.geeksville.mesh.ui.components.config.UserConfigScreen
-import com.google.accompanist.themeadapter.appcompat.AppCompatTheme
+import com.geeksville.mesh.ui.theme.AppTheme
+import com.geeksville.mesh.util.UiText
import dagger.hilt.android.AndroidEntryPoint
import kotlinx.serialization.Serializable
@@ -146,7 +146,7 @@ class NavGraphFragment : ScreenFragment("NavGraph"), Logging {
setContent {
val node by model.destNode.collectAsStateWithLifecycle()
- AppCompatTheme {
+ AppTheme {
val navController: NavHostController = rememberNavController()
Scaffold(
topBar = {
diff --git a/app/src/main/java/com/geeksville/mesh/ui/theme/Shape.kt b/app/src/main/java/com/geeksville/mesh/ui/theme/Shape.kt
deleted file mode 100644
index 23b90bbae..000000000
--- a/app/src/main/java/com/geeksville/mesh/ui/theme/Shape.kt
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * Copyright (c) 2025 Meshtastic LLC
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see .
- */
-
-package com.geeksville.mesh.ui.theme
-
-import androidx.compose.foundation.shape.RoundedCornerShape
-import androidx.compose.material.Shapes
-import androidx.compose.ui.unit.dp
-
-val Shapes = Shapes(
- small = RoundedCornerShape(4.dp),
- medium = RoundedCornerShape(4.dp),
- large = RoundedCornerShape(0.dp)
-)
diff --git a/app/src/main/java/com/geeksville/mesh/ui/theme/Theme.kt b/app/src/main/java/com/geeksville/mesh/ui/theme/Theme.kt
index df4a464e4..8b80b583c 100644
--- a/app/src/main/java/com/geeksville/mesh/ui/theme/Theme.kt
+++ b/app/src/main/java/com/geeksville/mesh/ui/theme/Theme.kt
@@ -61,8 +61,6 @@ fun AppTheme(
MaterialTheme(
colors = colors,
- typography = Typography,
- shapes = Shapes,
content = content
)
-}
\ No newline at end of file
+}
diff --git a/app/src/main/java/com/geeksville/mesh/ui/theme/Type.kt b/app/src/main/java/com/geeksville/mesh/ui/theme/Type.kt
deleted file mode 100644
index 513a1f14a..000000000
--- a/app/src/main/java/com/geeksville/mesh/ui/theme/Type.kt
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Copyright (c) 2025 Meshtastic LLC
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see .
- */
-
-package com.geeksville.mesh.ui.theme
-
-import androidx.compose.material.Typography
-import androidx.compose.ui.text.TextStyle
-import androidx.compose.ui.text.font.FontFamily
-import androidx.compose.ui.text.font.FontWeight
-import androidx.compose.ui.unit.sp
-
-// Set of Material typography styles to start with
-val Typography = Typography(
- h3 = TextStyle(
- fontWeight = FontWeight.Bold,
- fontSize = 24.sp
- ),
- h4 = TextStyle(
- fontWeight = FontWeight.Bold,
- fontSize = 20.sp
- ),
- body1 = TextStyle(
- fontFamily = FontFamily.Default,
- fontWeight = FontWeight.Normal,
- fontSize = 16.sp
- ),
- body2 = TextStyle(
- fontFamily = FontFamily.Default,
- fontWeight = FontWeight.Bold,
- fontSize = 16.sp
- ),
- /* Other default text styles to override
- button = TextStyle(
- fontFamily = FontFamily.Default,
- fontWeight = FontWeight.W500,
- fontSize = 14.sp
- ),
- caption = TextStyle(
- fontFamily = FontFamily.Default,
- fontWeight = FontWeight.Normal,
- fontSize = 12.sp
- )
- */
-)