Skip to main content
The 2024 Developer Survey results are live! See the results

Questions tagged [material-components-android]

Material Components for Android (MDC-Android) help developers execute Material Design. Developed by a core team of engineers and UX designers at Google, these components enable a reliable development workflow to build beautiful and functional Android apps.

material-components-android
0 votes
0 answers
40 views

Why could not inflate Behavior subclass com.google.android.material.bottomsheet.BottomSheetBehavior?

My intention is: when I press the buttom labeled "STANDARD BOTTOM SHEET", I want the Standard sheet dialog to be shown. I'm trying to use a bottom sheet modal dialog, but for some reason, ...
-1 votes
0 answers
20 views

material3 TextInputLayout actual text overlaps with prefix when it's inside recycler view

I'm using TextInputLayout and TextInputEditText as item layout inside a recycler view. the recycler view has 9 items, the first 4 items that are shown have no problem, the problem is within items 5,6,...
0 votes
1 answer
19 views

How can i implement a tab selector for BottomNavigationView?

Hellow there, i just wanna implement a tab selector for BottomNavigation view like this: At the moment i don't care about the item animations, i only want to put the bottom rectangle for the selected ...
11 votes
6 answers
10k views

Does Jetpack Compose offer a Material AutoComplete TextView replacement?

In the process of migrating my app to Jetpack compose, I've come to a part of my app where a TextField needs autocompletion functionality. However, as of version 1.0.0-alpha05, I couldn't find any ...
0 votes
1 answer
34 views

Textfield hint in Android Studio is not positioned properly

When I type in the Material UI Textfield, the hint is not positioning itself properly. As you can see in this image, the hint is not properly positioned as it goes more left. I am just trying to do ...
1 vote
0 answers
18 views

How to change rounding of the Android Material range sliders

I haven't found any information on how to change both the active and inactive tracks corner rounding for Android Material range sliders ; how do I do that or work around it? I have read: Android ...
35 votes
3 answers
25k views

How to achieve a full-screen dialog as described in material guidelines?

Material guidelines describe the behavior of a full-screen dialog. Full-screen dialog | Dialogs - Material Design How can I achieve this in practice?
14 votes
5 answers
13k views

How to change color of the password toggle in TextInputLayout?

I need to change color of the password toggle in TextInputLayout if EditText is focused or not. I've done it this way but it's not working. The color is always equals color light grey (from state ...
0 votes
1 answer
27 views

How to show border on TextInputLayout in Android Kotlin without MaterialComponents support

How to show border on TextInputLayout in Android without MaterialComponents. I have an AppCompatActivity using AppTheme.DialogTheme to show the Activity as a Dialog, but this configuration does not ...
0 votes
1 answer
33 views

Must I use MaterialTheme.typography when using Jetpack Compose, or are there any alternatives?

Recently, I have switched to Jetpack Compose, I see that it's very convenient and faster when building UI with Compose. But I find it difficult and confusing to decide which style of Text should use ...
0 votes
0 answers
34 views

The default top app bar color changes after updating material version to 1.11.0

I designed my app to look like this: But after updating the material library version from com.google.android.material:material:1.10.0 to com.google.android.material:material:1.11.0 the top app bar ...
16 votes
4 answers
19k views

This material API is experimental and is likely to change or to be removed in the future. error in android when using new material3 card

How to set elevation for material3 card? I am using new material3 card and getting error This material API is experimental and is likely to change or to be removed in the future. Here is code -> ...
82 votes
10 answers
34k views

How to center icon in a MaterialButton which has no text?

I'm using the latest version of the com.google.android.material:material library (i.e. 1.1.0-alpha03) and I have a MaterialButton defined with an icon and no text as follows: I was hoping the ...
15 votes
2 answers
7k views

How to change MaterialAlertDialog text color properly?

I try to use widgets from Material Components only, but in many cases, it's not documented how styling can be achieved. Let's consider MaterialAlertDialog. Each time I want to show a dialog, I call ...
4 votes
1 answer
822 views

textColorPrimary is to colorOnBackground/colorOnSurface while textColorSecondary is to?

So I've been following the guidelines mentioned here https://material.io/develop/android/theming/color/ for Color Theming my application. Previously before this, there was an attribute called ...

15 30 50 per page
1
2 3 4 5
91