title: Custom styling of com.google.android.material.tabs.TabLayout
body: <p>I am using the new <a href="https://github.com/material-components/material-components-android/blob/master/docs/getting-started.md" rel="noreferrer">Google Material Components</a> for Android </p>
  
  <p>Currently, I am trying to give a custom look for Tablayout (com.google.android.material.tabs.TabLayout).</p>
  
  <p>I have created a style as follows:</p>
  
  <pre><code>&lt;style name="AppTheme.TabLayout" parent="Widget.MaterialComponents.TabLayout"&gt;
      &lt;item name="android:background"&gt;@color/colorPrimary&lt;/item&gt;
  &lt;/style&gt;
  </code></pre>
  
  <p>However, upon applying this theme, the <strong>tab indicator becomes invisible</strong>.</p>
  
  <p><strong>Without theme:</strong></p>
  
  <p><a href="https://i.stack.imgur.com/mSkDf.png" rel="noreferrer"><img src="https://i.stack.imgur.com/mSkDf.png" alt="enter image description here"></a></p>
  
  <p><strong>With theme:</strong></p>
  
  <p><a href="https://i.stack.imgur.com/baRsI.png" rel="noreferrer"><img src="https://i.stack.imgur.com/baRsI.png" alt="enter image description here"></a></p>
  
  <p>Also, I tried other things like changing tabIndicatorColor and still not working!</p>
  
  <p>How do I fix this? Which is the correct way to change the colors/theme of Material Components?</p>