Skip to content

Commit

Permalink
Update About screen for day/night theme.
Browse files Browse the repository at this point in the history
  • Loading branch information
nickbutcher committed Apr 26, 2019
1 parent e85e17d commit c9d6716
Show file tree
Hide file tree
Showing 10 changed files with 19 additions and 25 deletions.
4 changes: 2 additions & 2 deletions about/src/main/res/layout/about_icon.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:background="@color/background_light"
android:background="?attr/colorSurface"
android:elevation="@dimen/z_card">

<ImageView
Expand All @@ -50,7 +50,7 @@
android:paddingEnd="@dimen/padding_normal"
android:paddingBottom="@dimen/spacing_large"
android:textAppearance="@style/TextAppearance.About"
android:textColorHighlight="?android:colorPrimary"
android:textColorHighlight="?attr/colorPrimary"
android:textColorLink="@color/plaid_links" />

</LinearLayout>
Expand Down
2 changes: 1 addition & 1 deletion about/src/main/res/layout/about_libs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
android:id="@+id/libs_list_background"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/grey_200" />
android:background="?android:colorBackground" />

<androidx.recyclerview.widget.RecyclerView
android:id="@+id/libs_list"
Expand Down
6 changes: 3 additions & 3 deletions about/src/main/res/layout/about_plaid.xml
Original file line number Diff line number Diff line change
Expand Up @@ -35,21 +35,21 @@
android:layout_height="@dimen/about_header_height"
android:text="@string/app_name"
android:fontFamily="@font/roboto_mono"
app:foregroundColor="?android:colorPrimary" />
app:foregroundColor="?attr/colorPrimary" />

<io.plaidapp.core.ui.widget.BaselineGridTextView
android:id="@+id/about_description"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:background="@color/background_light"
android:background="?attr/colorSurface"
android:breakStrategy="simple"
android:paddingStart="@dimen/padding_normal"
android:paddingTop="@dimen/padding_normal"
android:paddingEnd="@dimen/padding_normal"
android:paddingBottom="@dimen/spacing_large"
android:textAppearance="@style/TextAppearance.About"
android:textColorHighlight="?android:colorPrimary"
android:textColorHighlight="?attr/colorPrimary"
android:textColorLink="@color/plaid_links" />

</LinearLayout>
Expand Down
4 changes: 2 additions & 2 deletions about/src/main/res/layout/activity_about.xml
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@
android:layout_height="wrap_content"
android:layout_gravity="top|center_horizontal"
android:layout_marginTop="@dimen/padding_normal"
app:pageIndicatorColor="@color/page_indicator_dark"
app:currentPageIndicatorColor="@color/page_indicator_dark_selected"/>
app:pageIndicatorColor="@color/page_indicators"
app:currentPageIndicatorColor="@color/page_indicator_selected"/>

</io.plaidapp.core.ui.widget.ElasticDragDismissFrameLayout>

Expand Down
4 changes: 2 additions & 2 deletions about/src/main/res/layout/library.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
android:paddingBottom="@dimen/spacing_normal"
android:foreground="?android:selectableItemBackground"
android:stateListAnimator="@animator/raise"
android:background="@color/background_card"
android:background="?attr/colorSurface"
android:elevation="@dimen/z_card">

<ImageView
Expand Down Expand Up @@ -60,7 +60,7 @@
android:layout_alignParentEnd="true"
android:maxLines="2"
android:ellipsize="end"
style="@style/Widget.Plaid.SecondaryText" />
android:textAppearance="@style/TextAppearance.Subhead" />

<Button
android:id="@+id/library_link"
Expand Down
4 changes: 2 additions & 2 deletions about/src/main/res/values/styles.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@
<item name="android:windowReturnTransition">@transition/about_return</item>
</style>

<style name="TextAppearance.About" parent="@android:style/TextAppearance.Material.Body1">
<style name="TextAppearance.About" parent="@style/TextAppearance.MaterialComponents.Body1">
<item name="android:textSize">16sp</item>
<item name="android:textColor">@color/text_secondary_dark</item>
<item name="android:textColor">?android:attr/textColorSecondary</item>
<item name="lineHeightHint">24sp</item>
</style>

Expand Down
9 changes: 2 additions & 7 deletions app/src/main/res/values/styles.xml
Original file line number Diff line number Diff line change
Expand Up @@ -84,17 +84,12 @@
<item name="android:textColor">?android:colorAccent</item>
</style>

<style name="TextAppearance.Subhead" parent="@android:style/TextAppearance.Material.Subhead">
<item name="android:textColor">@color/text_secondary_dark</item>
<style name="TextAppearance.Subhead" parent="@style/TextAppearance.MaterialComponents.Subtitle1">
<item name="android:textColor">?android:attr/textColorSecondary</item>
<item name="android:letterSpacing">0.01</item>
<item name="lineHeightHint">24sp</item>
</style>

<style name="Widget.Plaid.SecondaryText">
<item name="android:textAppearance">@style/TextAppearance.SecondaryText</item>
<item name="android:letterSpacing">0.01</item>
</style>

<style name="TextAppearance.SecondaryText" parent="@android:style/TextAppearance.Material.Body1">
<item name="android:textColor">@color/text_tertiary_dark</item>
</style>
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/res/color/plaid_links.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,6 @@
<selector xmlns:android="http://schemas.android.com/apk/res/android">

<item android:state_pressed="true" android:color="@color/text_primary_light" />
<item android:color="@color/primary_dark" />
<item android:color="?attr/colorPrimaryVariant" />

</selector>
4 changes: 2 additions & 2 deletions core/src/main/res/values-night/colors.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@
<color name="color_surface">@color/background_dark</color>
<color name="color_highlighted_surface">#ff404040</color>
<color name="color_background">#ff292929</color>
<color name="page_indicators">#80cccccc</color>
<color name="page_indicator_selected">#ffcccccc</color>

<!-- designer news -->
<!--<color name="designer_news">#0d47a1</color>--> <!-- blue 900 -->
<color name="designer_news">#003c8f</color>
<color name="designer_news_variant">#0b3c87</color>

<!-- product hunt-->
<!--<color name="product_hunt">#ffbf360c</color>--> <!--deep orange 900 -->
<color name="product_hunt">#7f311a</color>

</resources>
5 changes: 2 additions & 3 deletions core/src/main/res/values/colors.xml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@
<color name="ripple_light">#99ffffff</color>
<color name="ripple_dark">@color/mid_grey</color>
<color name="background_light">#fafafa</color> <!-- grey 50 -->
<color name="background_card">#ffffff</color>
<color name="background_dark">#ff333333</color>
<color name="immersive_bars">#99000000</color>
<color name="light_immersive_bars">#b3eeeeee</color> <!-- 70% grey 200 -->
Expand All @@ -55,8 +54,8 @@
<color name="inline_action_icon">#ff757575</color> <!-- grey 600 -->
<color name="light_icon">#ffffffff</color>
<color name="divider">#1f000000</color> <!-- 12% black -->
<color name="page_indicator_dark">#80333333</color>
<color name="page_indicator_dark_selected">#ff333333</color>
<color name="page_indicators">#80333333</color>
<color name="page_indicator_selected">#ff333333</color>
<color name="error">#ffdd2c00</color>
<color name="delete">#fff44336</color>
<color name="shadow">#4c000000</color>
Expand Down

0 comments on commit c9d6716

Please sign in to comment.