mirror of
https://github.com/mihonapp/mihon.git
synced 2024-11-10 20:57:24 +01:00
Don't set text colors when creating compose theme (#7316)
This avoids compose snackbar text color issue
This commit is contained in:
parent
017f6b22f0
commit
4ef337f1e9
@ -14,7 +14,6 @@ fun TachiyomiTheme(content: @Composable () -> Unit) {
|
|||||||
val (colorScheme, typography) = createMdc3Theme(
|
val (colorScheme, typography) = createMdc3Theme(
|
||||||
context = context,
|
context = context,
|
||||||
layoutDirection = layoutDirection,
|
layoutDirection = layoutDirection,
|
||||||
setTextColors = true,
|
|
||||||
)
|
)
|
||||||
|
|
||||||
MaterialTheme(
|
MaterialTheme(
|
||||||
|
@ -4,7 +4,10 @@ import android.os.Bundle
|
|||||||
import android.view.LayoutInflater
|
import android.view.LayoutInflater
|
||||||
import android.view.View
|
import android.view.View
|
||||||
import androidx.compose.foundation.layout.consumeWindowInsets
|
import androidx.compose.foundation.layout.consumeWindowInsets
|
||||||
|
import androidx.compose.material3.LocalContentColor
|
||||||
|
import androidx.compose.material3.MaterialTheme
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
|
import androidx.compose.runtime.CompositionLocalProvider
|
||||||
import androidx.compose.ui.input.nestedscroll.NestedScrollConnection
|
import androidx.compose.ui.input.nestedscroll.NestedScrollConnection
|
||||||
import androidx.compose.ui.platform.ViewCompositionStrategy
|
import androidx.compose.ui.platform.ViewCompositionStrategy
|
||||||
import androidx.compose.ui.platform.rememberNestedScrollInteropConnection
|
import androidx.compose.ui.platform.rememberNestedScrollInteropConnection
|
||||||
@ -32,7 +35,9 @@ abstract class ComposeController<P : Presenter<*>>(bundle: Bundle? = null) :
|
|||||||
setContent {
|
setContent {
|
||||||
val nestedScrollInterop = rememberNestedScrollInteropConnection()
|
val nestedScrollInterop = rememberNestedScrollInteropConnection()
|
||||||
TachiyomiTheme {
|
TachiyomiTheme {
|
||||||
ComposeContent(nestedScrollInterop)
|
CompositionLocalProvider(LocalContentColor provides MaterialTheme.colorScheme.onBackground) {
|
||||||
|
ComposeContent(nestedScrollInterop)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -58,7 +63,9 @@ abstract class BasicComposeController :
|
|||||||
setContent {
|
setContent {
|
||||||
val nestedScrollInterop = rememberNestedScrollInteropConnection()
|
val nestedScrollInterop = rememberNestedScrollInteropConnection()
|
||||||
TachiyomiTheme {
|
TachiyomiTheme {
|
||||||
ComposeContent(nestedScrollInterop)
|
CompositionLocalProvider(LocalContentColor provides MaterialTheme.colorScheme.onBackground) {
|
||||||
|
ComposeContent(nestedScrollInterop)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -81,7 +88,9 @@ abstract class SearchableComposeController<P : BasePresenter<*>>(bundle: Bundle?
|
|||||||
setContent {
|
setContent {
|
||||||
val nestedScrollInterop = rememberNestedScrollInteropConnection()
|
val nestedScrollInterop = rememberNestedScrollInteropConnection()
|
||||||
TachiyomiTheme {
|
TachiyomiTheme {
|
||||||
ComposeContent(nestedScrollInterop)
|
CompositionLocalProvider(LocalContentColor provides MaterialTheme.colorScheme.onBackground) {
|
||||||
|
ComposeContent(nestedScrollInterop)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user