Skip to content

Commit

Permalink
Enable Elevation Overlays for Dark Themes and update surface colors t…
Browse files Browse the repository at this point in the history
…o match spec

PiperOrigin-RevId: 240425682
  • Loading branch information
dsn5ft authored and ikim24 committed Mar 26, 2019
1 parent 37a62a8 commit 760a99f
Show file tree
Hide file tree
Showing 6 changed files with 5 additions and 37 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,5 @@
<item name="catalogToolbarStyle">@style/Widget.Catalog.Toolbar</item>
<item name="catalogToolbarWithCloseButtonStyle">@style/Widget.Catalog.Toolbar.WithCloseButton</item>
<item name="windowActionModeOverlay">true</item>

<!-- TODO: Remove the following overrides once they are moved into the library. -->
<item name="elevationOverlaysEnabled">true</item>
<item name="colorSurface">#141414</item>
</style>
</resources>
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
<!-- Dark theme neutral colors. -->
<color name="design_dark_default_color_background">#141414</color>
<color name="design_dark_default_color_on_background">#FFFFFF</color>
<color name="design_dark_default_color_surface">#282828</color>
<color name="design_dark_default_color_surface">#141414</color>
<color name="design_dark_default_color_on_surface">#FFFFFF</color>
<color name="design_dark_default_color_error">#C26C7A</color>
<color name="design_dark_default_color_on_error">#000000</color>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,7 @@
</item>

<!-- Elevation Overlays -->
<!-- TODO: Enable once more components support elevation overlays. -->
<item name="elevationOverlaysEnabled">false</item>
<item name="elevationOverlaysEnabled">true</item>
<item name="elevationOverlaysColor">?attr/colorOnSurface</item>
</style>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,7 @@
</item>

<!-- Elevation Overlays -->
<!-- TODO: Enable once more components support elevation overlays. -->
<item name="elevationOverlaysEnabled">false</item>
<item name="elevationOverlaysEnabled">true</item>
<item name="elevationOverlaysColor">?attr/colorOnSurface</item>
</style>

Expand Down Expand Up @@ -187,8 +186,7 @@
</item>

<!-- Elevation Overlays -->
<!-- TODO: Enable once more components support elevation overlays. -->
<item name="elevationOverlaysEnabled">false</item>
<item name="elevationOverlaysEnabled">true</item>
<item name="elevationOverlaysColor">?attr/colorOnSurface</item>
</style>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public class ElevationOverlayProviderTest {

@Before
public void initContextThemeWithElevationOverlays() {
context.setTheme(R.style.Test_Theme_MaterialComponents_ElevationOverlays);
context.setTheme(R.style.Theme_MaterialComponents_NoActionBar);
}

@Test
Expand Down

This file was deleted.

0 comments on commit 760a99f

Please sign in to comment.