0

I am investigating Android Jetpack Compose in my current Android application.

I wish to have the main screen contain a backdrop and show selected options on the front layer.

I also require my application to support Dark Mode.

It seems to me that I must employ both androidx.compose.material3.MaterialTheme & androidx.compose.material.MaterialTheme to theme my application.

This is because androidx.compose.material.BackdropScaffold is a material component, which means it ignores my androidx.compose.material3.MaterialTheme values.

however i would like my application to take advantage of Material components as much as possible.

Is it possible to configure multiple MaterialTheme(s) in this case? Do I have to wait for a Material3 version of BackdropScaffold?

Gabriele Mariotti
  • 320,139
  • 94
  • 887
  • 841
Hector
  • 4,016
  • 21
  • 112
  • 211

1 Answers1

1

It will be Challenging! I am guessing you are using Android & NOT Compose

There is Not a direct correlation between the androidx.compose.material3.Typography also Material 3 ColorScheme is much extended, to make te colors work you will need to defind the colors to match, well those that can, and make use you import the correct library when using the MaterialTheme Libraries

Otherwise I see no reason why not to try migrate as material 3 comes to maturity!

My Compose/Material3 App have similar roblems because they disabled support for rememberScaffoldState() in the Scaffold, I had to implement that myself as seperate DrawerState and SnackbarHostState

CryptoCode
  • 945
  • 6
  • 19