mirror of
https://github.com/tachiyomiorg/tachiyomi.git
synced 2024-11-18 19:49:16 +01:00
Ripple overhaul (#5109)
* Create drawables for the ripples
Temporary colors in them to aid in unifying the ripples.
The 'ripple_circular' and 'ripple_normal' are probably going to be merge as one in the end.
* Change selectableItems to drawables
Changes 'selectableItemBackgroundBorderless' to 'ripple_circular' drawable.
Changes 'selectableItemBackground' to 'selectable_item_background' drawable.
* Add temporary colors to aid in finding unstyled ripples
* Fix button sizes to not make oval ripples
* Make the chip selectable follow ripple color
* Style using the built in rippleColor when possible
* Ripple away 💸
* Set ripple color for tabs
Main activity tabs as well as sheet tabs
* Set ripple color in seekbar buttons
* Fix ripple color for the toolbar
* Round off and start to finish the ripples
* Set custom colorful ripple for bottom navigation
Makes the app a little more fun than just black and white. Took inspiration from a ton of updated Google apps.
* Revert two layout changes
These were not necessary for the ripple as it is designed now, but it was before.
Co-authored-by: Andreas E <andreas.everos@gmail.com>
This commit is contained in:
parent
569df39fb8
commit
562dce60ee
7
app/src/main/res/color/background_color_chip_state.xml
Normal file
7
app/src/main/res/color/background_color_chip_state.xml
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<item android:color="?attr/rippleColor" android:state_selected="true" />
|
||||||
|
<item android:color="?attr/rippleColor" android:state_pressed="true" />
|
||||||
|
<item android:color="?attr/rippleColor" android:state_focused="true" />
|
||||||
|
<item android:color="@android:color/transparent" />
|
||||||
|
</selector>
|
@ -1,6 +1,6 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
|
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:color="?attr/colorOnPrimary">
|
android:color="?attr/rippleColor">
|
||||||
|
|
||||||
<item android:id="@android:id/mask">
|
<item android:id="@android:id/mask">
|
||||||
<shape android:shape="rectangle">
|
<shape android:shape="rectangle">
|
||||||
|
5
app/src/main/res/drawable/ripple_dark.xml
Normal file
5
app/src/main/res/drawable/ripple_dark.xml
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<ripple android:color="?attr/rippleColor"
|
||||||
|
xmlns:android="http://schemas.android.com/apk/res/android" >
|
||||||
|
<item android:drawable="@color/backgroundDark" />
|
||||||
|
</ripple>
|
5
app/src/main/res/drawable/ripple_light.xml
Normal file
5
app/src/main/res/drawable/ripple_light.xml
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<ripple android:color="?attr/rippleColor"
|
||||||
|
xmlns:android="http://schemas.android.com/apk/res/android" >
|
||||||
|
<item android:drawable="@color/backgroundLight" />
|
||||||
|
</ripple>
|
3
app/src/main/res/drawable/ripple_regular.xml
Normal file
3
app/src/main/res/drawable/ripple_regular.xml
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<ripple android:color="?attr/rippleColor"
|
||||||
|
xmlns:android="http://schemas.android.com/apk/res/android" />
|
3
app/src/main/res/drawable/selectable_item_background.xml
Normal file
3
app/src/main/res/drawable/selectable_item_background.xml
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<item android:drawable="@drawable/ripple_regular" />
|
||||||
|
</selector>
|
@ -5,7 +5,7 @@
|
|||||||
android:layout_width="42dp"
|
android:layout_width="42dp"
|
||||||
android:layout_height="42dp"
|
android:layout_height="42dp"
|
||||||
android:padding="8dp"
|
android:padding="8dp"
|
||||||
android:background="?selectableItemBackgroundBorderless">
|
android:background="@drawable/ripple_regular">
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/download_icon"
|
android:id="@+id/download_icon"
|
||||||
|
@ -21,6 +21,7 @@
|
|||||||
app:layout_constraintEnd_toStartOf="@+id/menu"
|
app:layout_constraintEnd_toStartOf="@+id/menu"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:tabRippleColor="?attr/rippleColor"
|
||||||
app:tabTextColor="@color/tabs_selector_background"
|
app:tabTextColor="@color/tabs_selector_background"
|
||||||
app:tabIndicatorColor="?attr/colorAccent"
|
app:tabIndicatorColor="?attr/colorAccent"
|
||||||
app:tabGravity="fill"
|
app:tabGravity="fill"
|
||||||
@ -30,7 +31,7 @@
|
|||||||
android:id="@+id/menu"
|
android:id="@+id/menu"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="?selectableItemBackgroundBorderless"
|
android:background="@drawable/ripple_regular"
|
||||||
android:contentDescription="@string/action_menu"
|
android:contentDescription="@string/action_menu"
|
||||||
android:paddingStart="10dp"
|
android:paddingStart="10dp"
|
||||||
android:paddingEnd="10dp"
|
android:paddingEnd="10dp"
|
||||||
|
@ -89,7 +89,7 @@
|
|||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_toEndOf="@id/download_progress_text"
|
android:layout_toEndOf="@id/download_progress_text"
|
||||||
android:background="?selectableItemBackgroundBorderless"
|
android:background="@drawable/ripple_regular"
|
||||||
android:contentDescription="@string/action_menu"
|
android:contentDescription="@string/action_menu"
|
||||||
android:paddingVertical="16dp"
|
android:paddingVertical="16dp"
|
||||||
android:paddingHorizontal="10dp"
|
android:paddingHorizontal="10dp"
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
android:id="@+id/title_wrapper"
|
android:id="@+id/title_wrapper"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="?attr/selectableItemBackground">
|
android:background="@drawable/selectable_item_background">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/title"
|
android:id="@+id/title"
|
||||||
|
@ -56,7 +56,7 @@
|
|||||||
android:id="@+id/remove"
|
android:id="@+id/remove"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="?selectableItemBackgroundBorderless"
|
android:background="@drawable/ripple_regular"
|
||||||
android:contentDescription="@string/action_resume"
|
android:contentDescription="@string/action_resume"
|
||||||
android:padding="8dp"
|
android:padding="8dp"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
@ -69,7 +69,7 @@
|
|||||||
android:id="@+id/resume"
|
android:id="@+id/resume"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="?selectableItemBackgroundBorderless"
|
android:background="@drawable/ripple_regular"
|
||||||
android:contentDescription="@string/action_resume"
|
android:contentDescription="@string/action_resume"
|
||||||
android:padding="8dp"
|
android:padding="8dp"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
@ -83,6 +83,7 @@
|
|||||||
android:layout_gravity="bottom"
|
android:layout_gravity="bottom"
|
||||||
app:itemIconTint="@color/nav_selector"
|
app:itemIconTint="@color/nav_selector"
|
||||||
app:itemTextColor="@color/nav_selector"
|
app:itemTextColor="@color/nav_selector"
|
||||||
|
app:itemRippleColor="?attr/rippleNavColor"
|
||||||
app:labelVisibilityMode="labeled"
|
app:labelVisibilityMode="labeled"
|
||||||
app:layout_insetEdge="bottom"
|
app:layout_insetEdge="bottom"
|
||||||
app:menu="@menu/main_nav" />
|
app:menu="@menu/main_nav" />
|
||||||
|
@ -19,7 +19,8 @@
|
|||||||
android:id="@+id/tabs"
|
android:id="@+id/tabs"
|
||||||
style="@style/Theme.Widget.Tabs"
|
style="@style/Theme.Widget.Tabs"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content" />
|
android:layout_height="wrap_content"
|
||||||
|
app:tabRippleColor="?attr/rippleColor" />
|
||||||
|
|
||||||
<FrameLayout
|
<FrameLayout
|
||||||
android:id="@+id/downloaded_only"
|
android:id="@+id/downloaded_only"
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="?attr/selectableItemBackground"
|
android:background="@drawable/selectable_item_background"
|
||||||
android:paddingStart="16dp"
|
android:paddingStart="16dp"
|
||||||
android:paddingTop="4dp"
|
android:paddingTop="4dp"
|
||||||
android:paddingEnd="12dp"
|
android:paddingEnd="12dp"
|
||||||
@ -28,7 +28,7 @@
|
|||||||
android:id="@+id/btn_chapters_filter"
|
android:id="@+id/btn_chapters_filter"
|
||||||
android:layout_width="28dp"
|
android:layout_width="28dp"
|
||||||
android:layout_height="28dp"
|
android:layout_height="28dp"
|
||||||
android:background="?selectableItemBackgroundBorderless"
|
android:background="@drawable/ripple_regular"
|
||||||
android:contentDescription="@string/action_filter"
|
android:contentDescription="@string/action_filter"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
@ -142,6 +142,7 @@
|
|||||||
android:layout_marginStart="16dp"
|
android:layout_marginStart="16dp"
|
||||||
android:text="@string/add_to_library"
|
android:text="@string/add_to_library"
|
||||||
app:icon="@drawable/ic_favorite_border_24dp"
|
app:icon="@drawable/ic_favorite_border_24dp"
|
||||||
|
app:rippleColor="?attr/rippleColor"
|
||||||
app:layout_constraintEnd_toStartOf="@+id/btn_tracking"
|
app:layout_constraintEnd_toStartOf="@+id/btn_tracking"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/manga_info" />
|
app:layout_constraintTop_toBottomOf="@+id/manga_info" />
|
||||||
@ -154,6 +155,7 @@
|
|||||||
android:text="@string/manga_tracking_tab"
|
android:text="@string/manga_tracking_tab"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
app:icon="@drawable/ic_sync_24dp"
|
app:icon="@drawable/ic_sync_24dp"
|
||||||
|
app:rippleColor="?attr/rippleColor"
|
||||||
app:layout_constraintEnd_toStartOf="@+id/btn_webview"
|
app:layout_constraintEnd_toStartOf="@+id/btn_webview"
|
||||||
app:layout_constraintStart_toEndOf="@+id/btn_favorite"
|
app:layout_constraintStart_toEndOf="@+id/btn_favorite"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/manga_info"
|
app:layout_constraintTop_toBottomOf="@+id/manga_info"
|
||||||
@ -168,6 +170,7 @@
|
|||||||
android:text="@string/action_web_view"
|
android:text="@string/action_web_view"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
app:icon="@drawable/ic_public_24dp"
|
app:icon="@drawable/ic_public_24dp"
|
||||||
|
app:rippleColor="?attr/rippleColor"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toEndOf="@+id/btn_tracking"
|
app:layout_constraintStart_toEndOf="@+id/btn_tracking"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/manga_info"
|
app:layout_constraintTop_toBottomOf="@+id/manga_info"
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="?attr/listPreferredItemHeightSmall"
|
android:layout_height="?attr/listPreferredItemHeightSmall"
|
||||||
android:background="?attr/selectableItemBackground"
|
android:background="@drawable/selectable_item_background"
|
||||||
android:focusable="true"
|
android:focusable="true"
|
||||||
android:paddingStart="?attr/listPreferredItemPaddingStart"
|
android:paddingStart="?attr/listPreferredItemPaddingStart"
|
||||||
android:paddingEnd="?attr/listPreferredItemPaddingEnd">
|
android:paddingEnd="?attr/listPreferredItemPaddingEnd">
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="?attr/listPreferredItemHeightSmall"
|
android:layout_height="?attr/listPreferredItemHeightSmall"
|
||||||
android:background="?attr/selectableItemBackground"
|
android:background="@drawable/selectable_item_background"
|
||||||
android:focusable="true"
|
android:focusable="true"
|
||||||
android:paddingStart="?attr/listPreferredItemPaddingStart"
|
android:paddingStart="?attr/listPreferredItemPaddingStart"
|
||||||
android:paddingEnd="?attr/listPreferredItemPaddingEnd">
|
android:paddingEnd="?attr/listPreferredItemPaddingEnd">
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="?attr/listPreferredItemHeightSmall"
|
android:layout_height="?attr/listPreferredItemHeightSmall"
|
||||||
android:background="?attr/selectableItemBackground"
|
android:background="@drawable/selectable_item_background"
|
||||||
android:focusable="true"
|
android:focusable="true"
|
||||||
android:paddingStart="?attr/listPreferredItemPaddingStart"
|
android:paddingStart="?attr/listPreferredItemPaddingStart"
|
||||||
android:paddingEnd="?attr/listPreferredItemPaddingEnd">
|
android:paddingEnd="?attr/listPreferredItemPaddingEnd">
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="?attr/listPreferredItemHeightSmall"
|
android:layout_height="?attr/listPreferredItemHeightSmall"
|
||||||
android:background="?attr/selectableItemBackground"
|
android:background="@drawable/selectable_item_background"
|
||||||
android:focusable="true"
|
android:focusable="true"
|
||||||
android:paddingStart="?attr/listPreferredItemPaddingStart"
|
android:paddingStart="?attr/listPreferredItemPaddingStart"
|
||||||
android:paddingEnd="?attr/listPreferredItemPaddingEnd">
|
android:paddingEnd="?attr/listPreferredItemPaddingEnd">
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="?attr/selectableItemBackground"
|
android:background="@drawable/selectable_item_background"
|
||||||
android:baselineAligned="false"
|
android:baselineAligned="false"
|
||||||
android:focusable="true"
|
android:focusable="true"
|
||||||
android:paddingStart="?attr/listPreferredItemPaddingStart"
|
android:paddingStart="?attr/listPreferredItemPaddingStart"
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginEnd="8dp"
|
android:layout_marginEnd="8dp"
|
||||||
android:background="?selectableItemBackgroundBorderless"
|
android:background="@drawable/ripple_regular"
|
||||||
android:contentDescription="@string/label_settings"
|
android:contentDescription="@string/label_settings"
|
||||||
android:padding="8dp"
|
android:padding="8dp"
|
||||||
app:srcCompat="@drawable/ic_settings_24dp"
|
app:srcCompat="@drawable/ic_settings_24dp"
|
||||||
|
@ -156,7 +156,7 @@
|
|||||||
android:id="@+id/action_reading_mode"
|
android:id="@+id/action_reading_mode"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:background="?selectableItemBackgroundBorderless"
|
android:background="@drawable/ripple_regular"
|
||||||
android:contentDescription="@string/viewer"
|
android:contentDescription="@string/viewer"
|
||||||
android:padding="@dimen/screen_edge_margin"
|
android:padding="@dimen/screen_edge_margin"
|
||||||
app:layout_constraintEnd_toStartOf="@id/action_crop_borders"
|
app:layout_constraintEnd_toStartOf="@id/action_crop_borders"
|
||||||
@ -169,7 +169,7 @@
|
|||||||
android:id="@+id/action_crop_borders"
|
android:id="@+id/action_crop_borders"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:background="?selectableItemBackgroundBorderless"
|
android:background="@drawable/ripple_regular"
|
||||||
android:contentDescription="@string/pref_crop_borders"
|
android:contentDescription="@string/pref_crop_borders"
|
||||||
android:padding="@dimen/screen_edge_margin"
|
android:padding="@dimen/screen_edge_margin"
|
||||||
app:layout_constraintEnd_toStartOf="@id/action_rotation"
|
app:layout_constraintEnd_toStartOf="@id/action_rotation"
|
||||||
@ -182,7 +182,7 @@
|
|||||||
android:id="@+id/action_rotation"
|
android:id="@+id/action_rotation"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:background="?selectableItemBackgroundBorderless"
|
android:background="@drawable/ripple_regular"
|
||||||
android:contentDescription="@string/pref_rotation_type"
|
android:contentDescription="@string/pref_rotation_type"
|
||||||
android:padding="@dimen/screen_edge_margin"
|
android:padding="@dimen/screen_edge_margin"
|
||||||
app:layout_constraintEnd_toStartOf="@id/action_settings"
|
app:layout_constraintEnd_toStartOf="@id/action_settings"
|
||||||
@ -195,7 +195,7 @@
|
|||||||
android:id="@+id/action_settings"
|
android:id="@+id/action_settings"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:background="?selectableItemBackgroundBorderless"
|
android:background="@drawable/ripple_regular"
|
||||||
android:contentDescription="@string/action_settings"
|
android:contentDescription="@string/action_settings"
|
||||||
android:padding="@dimen/screen_edge_margin"
|
android:padding="@dimen/screen_edge_margin"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
android:layout_height="56dp"
|
android:layout_height="56dp"
|
||||||
android:clickable="true"
|
android:clickable="true"
|
||||||
android:focusable="true"
|
android:focusable="true"
|
||||||
android:foreground="?attr/selectableItemBackground"
|
android:foreground="@drawable/selectable_item_background"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:paddingStart="16dp"
|
android:paddingStart="16dp"
|
||||||
android:paddingEnd="16dp">
|
android:paddingEnd="16dp">
|
||||||
@ -37,7 +37,7 @@
|
|||||||
android:layout_height="56dp"
|
android:layout_height="56dp"
|
||||||
android:clickable="true"
|
android:clickable="true"
|
||||||
android:focusable="true"
|
android:focusable="true"
|
||||||
android:foreground="?attr/selectableItemBackground"
|
android:foreground="@drawable/selectable_item_background"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:paddingStart="16dp"
|
android:paddingStart="16dp"
|
||||||
android:paddingEnd="16dp">
|
android:paddingEnd="16dp">
|
||||||
@ -63,7 +63,7 @@
|
|||||||
android:layout_height="56dp"
|
android:layout_height="56dp"
|
||||||
android:clickable="true"
|
android:clickable="true"
|
||||||
android:focusable="true"
|
android:focusable="true"
|
||||||
android:foreground="?attr/selectableItemBackground"
|
android:foreground="@drawable/selectable_item_background"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:paddingStart="16dp"
|
android:paddingStart="16dp"
|
||||||
android:paddingEnd="16dp">
|
android:paddingEnd="16dp">
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
android:id="@+id/title_wrapper"
|
android:id="@+id/title_wrapper"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="?attr/selectableItemBackground"
|
android:background="@drawable/selectable_item_background"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:padding="16dp">
|
android:padding="16dp">
|
||||||
|
|
||||||
|
@ -70,9 +70,9 @@
|
|||||||
<ImageButton
|
<ImageButton
|
||||||
android:id="@+id/pin"
|
android:id="@+id/pin"
|
||||||
android:layout_width="40dp"
|
android:layout_width="40dp"
|
||||||
android:layout_height="0dp"
|
android:layout_height="40dp"
|
||||||
android:layout_marginEnd="8dp"
|
android:layout_marginEnd="8dp"
|
||||||
android:background="?selectableItemBackgroundBorderless"
|
android:background="@drawable/ripple_regular"
|
||||||
android:contentDescription="@string/action_pin"
|
android:contentDescription="@string/action_pin"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="?attr/listPreferredItemHeightSmall"
|
android:layout_height="?attr/listPreferredItemHeightSmall"
|
||||||
android:background="?attr/selectableItemBackground"
|
android:background="@drawable/selectable_item_background"
|
||||||
android:paddingStart="16dp"
|
android:paddingStart="16dp"
|
||||||
android:paddingEnd="16dp">
|
android:paddingEnd="16dp">
|
||||||
|
|
||||||
|
@ -22,5 +22,6 @@
|
|||||||
<attr name="colorFilterActive" format="reference|integer"/>
|
<attr name="colorFilterActive" format="reference|integer"/>
|
||||||
<attr name="colorBackgroundSplash" format="reference|integer"/>
|
<attr name="colorBackgroundSplash" format="reference|integer"/>
|
||||||
<attr name="colorAccentOnPrimary" format="reference|integer"/>
|
<attr name="colorAccentOnPrimary" format="reference|integer"/>
|
||||||
|
<attr name="rippleNavColor" format="reference|integer"/>
|
||||||
|
|
||||||
</resources>
|
</resources>
|
||||||
|
@ -18,7 +18,8 @@
|
|||||||
<color name="textColorSecondaryLight">@color/md_black_1000_54</color>
|
<color name="textColorSecondaryLight">@color/md_black_1000_54</color>
|
||||||
<color name="textColorHintLight">@color/md_black_1000_38</color>
|
<color name="textColorHintLight">@color/md_black_1000_38</color>
|
||||||
<color name="dividerLight">@color/md_black_1000_12</color>
|
<color name="dividerLight">@color/md_black_1000_12</color>
|
||||||
<color name="rippleColorLight">@color/md_black_1000_12</color>
|
<color name="rippleColorLight">@color/md_black_1000_6</color>
|
||||||
|
<color name="rippleNavColorLight">@color/md_blue_A400_4</color>
|
||||||
<color name="backgroundLight">@color/md_grey_50</color>
|
<color name="backgroundLight">@color/md_grey_50</color>
|
||||||
<color name="dialogLight">@color/md_white_1000</color>
|
<color name="dialogLight">@color/md_white_1000</color>
|
||||||
<color name="selectorColorLight">@color/md_blue_A400_38</color>
|
<color name="selectorColorLight">@color/md_blue_A400_38</color>
|
||||||
@ -29,7 +30,8 @@
|
|||||||
<color name="textColorSecondaryDark">@color/md_white_1000_70</color>
|
<color name="textColorSecondaryDark">@color/md_white_1000_70</color>
|
||||||
<color name="textColorHintDark">@color/md_white_1000_50</color>
|
<color name="textColorHintDark">@color/md_white_1000_50</color>
|
||||||
<color name="dividerDark">@android:color/transparent</color>
|
<color name="dividerDark">@android:color/transparent</color>
|
||||||
<color name="rippleColorDark">@color/md_white_1000_20</color>
|
<color name="rippleColorDark">@color/md_white_1000_6</color>
|
||||||
|
<color name="rippleNavColorDark">#0A3399FF</color>
|
||||||
<color name="backgroundDark">@color/colorDarkPrimaryDark</color>
|
<color name="backgroundDark">@color/colorDarkPrimaryDark</color>
|
||||||
<color name="dialogDark">@color/colorDarkPrimary</color>
|
<color name="dialogDark">@color/colorDarkPrimary</color>
|
||||||
<color name="selectorColorDark">@color/md_blue_A200_50</color>
|
<color name="selectorColorDark">@color/md_blue_A200_50</color>
|
||||||
@ -47,6 +49,7 @@
|
|||||||
<color name="md_black_1000_54">#8A000000</color>
|
<color name="md_black_1000_54">#8A000000</color>
|
||||||
<color name="md_black_1000_38">#61000000</color>
|
<color name="md_black_1000_38">#61000000</color>
|
||||||
<color name="md_black_1000_12">#1F000000</color>
|
<color name="md_black_1000_12">#1F000000</color>
|
||||||
|
<color name="md_black_1000_6">#0F000000</color>
|
||||||
|
|
||||||
<color name="md_white_1000">#FFFFFFFF</color>
|
<color name="md_white_1000">#FFFFFFFF</color>
|
||||||
<color name="md_white_1000_70">#B3FFFFFF</color>
|
<color name="md_white_1000_70">#B3FFFFFF</color>
|
||||||
@ -54,6 +57,7 @@
|
|||||||
<color name="md_white_1000_50">#80FFFFFF</color>
|
<color name="md_white_1000_50">#80FFFFFF</color>
|
||||||
<color name="md_white_1000_20">#33FFFFFF</color>
|
<color name="md_white_1000_20">#33FFFFFF</color>
|
||||||
<color name="md_white_1000_12">#1FFFFFFF</color>
|
<color name="md_white_1000_12">#1FFFFFFF</color>
|
||||||
|
<color name="md_white_1000_6">#0FFFFFFF</color>
|
||||||
|
|
||||||
<!-- Material Design Colors -->
|
<!-- Material Design Colors -->
|
||||||
<color name="md_black_1000">#000000</color>
|
<color name="md_black_1000">#000000</color>
|
||||||
@ -71,6 +75,7 @@
|
|||||||
|
|
||||||
<color name="md_blue_A400">#2979FF</color>
|
<color name="md_blue_A400">#2979FF</color>
|
||||||
<color name="md_blue_A400_38">#612979FF</color>
|
<color name="md_blue_A400_38">#612979FF</color>
|
||||||
|
<color name="md_blue_A400_4">#0A2979FF</color>
|
||||||
|
|
||||||
<color name="md_blue_grey_900">#263238</color>
|
<color name="md_blue_grey_900">#263238</color>
|
||||||
<color name="md_blue_grey_800">#37474F</color>
|
<color name="md_blue_grey_800">#37474F</color>
|
||||||
|
@ -6,10 +6,14 @@
|
|||||||
<!--========-->
|
<!--========-->
|
||||||
<style name="Theme.Toolbar" parent="@style/ThemeOverlay.MaterialComponents.ActionBar" />
|
<style name="Theme.Toolbar" parent="@style/ThemeOverlay.MaterialComponents.ActionBar" />
|
||||||
|
|
||||||
<style name="Theme.Toolbar.Light" parent="@style/ThemeOverlay.MaterialComponents.Dark.ActionBar">
|
<style name="Theme.Toolbar.Light" parent="Theme.Toolbar.Custom">
|
||||||
<item name="popupTheme">@style/ThemeOverlay.MaterialComponents.Light</item>
|
<item name="popupTheme">@style/ThemeOverlay.MaterialComponents.Light</item>
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
<style name="Theme.Toolbar.Custom" parent="@style/ThemeOverlay.MaterialComponents.Dark.ActionBar">
|
||||||
|
<item name="android:colorControlHighlight">?attr/rippleColor</item>
|
||||||
|
</style>
|
||||||
|
|
||||||
<style name="Theme.Toolbar.Navigation" parent="Widget.AppCompat.Toolbar.Button.Navigation">
|
<style name="Theme.Toolbar.Navigation" parent="Widget.AppCompat.Toolbar.Button.Navigation">
|
||||||
<item name="tint">?attr/colorOnPrimary</item>
|
<item name="tint">?attr/colorOnPrimary</item>
|
||||||
</style>
|
</style>
|
||||||
@ -227,9 +231,13 @@
|
|||||||
<style name="Theme.Widget.Chip" parent="Widget.MaterialComponents.Chip.Action">
|
<style name="Theme.Widget.Chip" parent="Widget.MaterialComponents.Chip.Action">
|
||||||
<item name="chipStrokeWidth">1dp</item>
|
<item name="chipStrokeWidth">1dp</item>
|
||||||
<item name="chipStrokeColor">?attr/colorAccent</item>
|
<item name="chipStrokeColor">?attr/colorAccent</item>
|
||||||
<item name="chipBackgroundColor">@android:color/transparent</item>
|
<item name="chipBackgroundColor">@color/background_color_chip_state</item>
|
||||||
<item name="android:textColor">?attr/colorAccent</item>
|
<item name="android:textColor">?attr/colorAccent</item>
|
||||||
|
|
||||||
|
<!-- Custom chip states -->
|
||||||
|
<item name="android:clickable">true</item>
|
||||||
|
<item name="android:focusable">true</item>
|
||||||
|
|
||||||
<!-- Smaller text/height -->
|
<!-- Smaller text/height -->
|
||||||
<item name="chipCornerRadius">12dp</item>
|
<item name="chipCornerRadius">12dp</item>
|
||||||
<item name="chipMinHeight">24dp</item>
|
<item name="chipMinHeight">24dp</item>
|
||||||
@ -284,14 +292,14 @@
|
|||||||
<!--==============-->
|
<!--==============-->
|
||||||
<style name="Theme.Widget.Button" parent="Widget.MaterialComponents.Button.TextButton">
|
<style name="Theme.Widget.Button" parent="Widget.MaterialComponents.Button.TextButton">
|
||||||
<item name="android:textColor">?attr/colorAccent</item>
|
<item name="android:textColor">?attr/colorAccent</item>
|
||||||
<item name="rippleColor">?attr/colorAccent</item>
|
<item name="rippleColor">?attr/rippleColor</item>
|
||||||
<item name="android:textAllCaps">false</item>
|
<item name="android:textAllCaps">false</item>
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<style name="Theme.Widget.Button.FilledAccent" parent="Widget.MaterialComponents.Button">
|
<style name="Theme.Widget.Button.FilledAccent" parent="Widget.MaterialComponents.Button">
|
||||||
<item name="android:textColor">?attr/colorOnSecondary</item>
|
<item name="android:textColor">?attr/colorOnSecondary</item>
|
||||||
<item name="backgroundTint">?attr/colorAccent</item>
|
<item name="backgroundTint">?attr/colorAccent</item>
|
||||||
<item name="rippleColor">?attr/colorAccent</item>
|
<item name="rippleColor">?attr/rippleColor</item>
|
||||||
<item name="android:textAllCaps">false</item>
|
<item name="android:textAllCaps">false</item>
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
@ -358,4 +366,16 @@
|
|||||||
<item name="android:textSize">15sp</item>
|
<item name="android:textSize">15sp</item>
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
|
||||||
|
<!--===============-->
|
||||||
|
<!--Custom Selector-->
|
||||||
|
<!--===============-->
|
||||||
|
<style name="PreferenceThemeLight" parent="@style/PreferenceThemeOverlay">
|
||||||
|
<item name="android:selectableItemBackground">@drawable/ripple_light</item>
|
||||||
|
</style>
|
||||||
|
|
||||||
|
<style name="PreferenceThemeDark" parent="@style/PreferenceThemeOverlay">
|
||||||
|
<item name="android:selectableItemBackground">@drawable/ripple_dark</item>
|
||||||
|
</style>
|
||||||
|
|
||||||
</resources>
|
</resources>
|
||||||
|
@ -37,6 +37,7 @@
|
|||||||
<item name="android:textColorSecondaryInverse">@color/textColorSecondaryDark</item>
|
<item name="android:textColorSecondaryInverse">@color/textColorSecondaryDark</item>
|
||||||
<item name="android:textColorHintInverse">@color/textColorHintDark</item>
|
<item name="android:textColorHintInverse">@color/textColorHintDark</item>
|
||||||
<item name="rippleColor">@color/rippleColorLight</item>
|
<item name="rippleColor">@color/rippleColorLight</item>
|
||||||
|
<item name="rippleNavColor">@color/rippleNavColorLight</item>
|
||||||
<item name="android:colorEdgeEffect">?attr/colorAccent</item>
|
<item name="android:colorEdgeEffect">?attr/colorAccent</item>
|
||||||
|
|
||||||
<item name="android:divider">@color/dividerLight</item>
|
<item name="android:divider">@color/dividerLight</item>
|
||||||
@ -58,7 +59,7 @@
|
|||||||
<item name="actionModeCloseDrawable">@drawable/ic_close_24dp</item>
|
<item name="actionModeCloseDrawable">@drawable/ic_close_24dp</item>
|
||||||
<item name="actionBarPopupTheme">@style/ThemeOverlay.MaterialComponents</item>
|
<item name="actionBarPopupTheme">@style/ThemeOverlay.MaterialComponents</item>
|
||||||
<item name="toolbarNavigationButtonStyle">@style/Theme.Toolbar.Navigation</item>
|
<item name="toolbarNavigationButtonStyle">@style/Theme.Toolbar.Navigation</item>
|
||||||
<item name="preferenceTheme">@style/PreferenceThemeOverlay</item>
|
<item name="preferenceTheme">@style/PreferenceThemeLight</item>
|
||||||
<item name="dialogTheme">@style/Theme.AlertDialog.Light</item>
|
<item name="dialogTheme">@style/Theme.AlertDialog.Light</item>
|
||||||
<item name="materialAlertDialogTheme">@style/Theme.AlertDialog.Light</item>
|
<item name="materialAlertDialogTheme">@style/Theme.AlertDialog.Light</item>
|
||||||
<item name="bottomSheetDialogTheme">@style/Theme.BottomSheet</item>
|
<item name="bottomSheetDialogTheme">@style/Theme.BottomSheet</item>
|
||||||
@ -136,6 +137,7 @@
|
|||||||
<item name="android:textColorPrimaryInverse">@color/textColorPrimaryLight</item>
|
<item name="android:textColorPrimaryInverse">@color/textColorPrimaryLight</item>
|
||||||
<item name="android:textColorSecondaryInverse">@color/textColorSecondaryLight</item>
|
<item name="android:textColorSecondaryInverse">@color/textColorSecondaryLight</item>
|
||||||
<item name="android:textColorHintInverse">@color/textColorHintLight</item>
|
<item name="android:textColorHintInverse">@color/textColorHintLight</item>
|
||||||
|
<item name="rippleNavColor">@color/rippleNavColorDark</item>
|
||||||
<item name="rippleColor">@color/rippleColorDark</item>
|
<item name="rippleColor">@color/rippleColorDark</item>
|
||||||
<item name="android:colorEdgeEffect">?attr/colorAccent</item>
|
<item name="android:colorEdgeEffect">?attr/colorAccent</item>
|
||||||
|
|
||||||
@ -152,10 +154,10 @@
|
|||||||
<item name="actionModeStyle">@style/Theme.ActionMode</item>
|
<item name="actionModeStyle">@style/Theme.ActionMode</item>
|
||||||
<item name="actionModeCloseButtonStyle">@style/Theme.ActionMode.CloseButton</item>
|
<item name="actionModeCloseButtonStyle">@style/Theme.ActionMode.CloseButton</item>
|
||||||
<item name="actionModeCloseDrawable">@drawable/ic_close_24dp</item>
|
<item name="actionModeCloseDrawable">@drawable/ic_close_24dp</item>
|
||||||
<item name="actionBarTheme">@style/ThemeOverlay.MaterialComponents.Dark.ActionBar</item>
|
<item name="actionBarTheme">@style/Theme.Toolbar.Custom</item>
|
||||||
<item name="actionBarPopupTheme">@style/ThemeOverlay.MaterialComponents</item>
|
<item name="actionBarPopupTheme">@style/ThemeOverlay.MaterialComponents</item>
|
||||||
<item name="toolbarNavigationButtonStyle">@style/Theme.Toolbar.Navigation</item>
|
<item name="toolbarNavigationButtonStyle">@style/Theme.Toolbar.Navigation</item>
|
||||||
<item name="preferenceTheme">@style/PreferenceThemeOverlay</item>
|
<item name="preferenceTheme">@style/PreferenceThemeDark</item>
|
||||||
<item name="dialogTheme">@style/Theme.AlertDialog.Dark</item>
|
<item name="dialogTheme">@style/Theme.AlertDialog.Dark</item>
|
||||||
<item name="materialAlertDialogTheme">@style/Theme.AlertDialog.Dark</item>
|
<item name="materialAlertDialogTheme">@style/Theme.AlertDialog.Dark</item>
|
||||||
<item name="bottomSheetDialogTheme">@style/Theme.BottomSheet</item>
|
<item name="bottomSheetDialogTheme">@style/Theme.BottomSheet</item>
|
||||||
@ -221,7 +223,7 @@
|
|||||||
<item name="android:statusBarColor">?attr/colorPrimaryVariant</item>
|
<item name="android:statusBarColor">?attr/colorPrimaryVariant</item>
|
||||||
<item name="android:navigationBarColor">?attr/colorPrimaryVariant</item>
|
<item name="android:navigationBarColor">?attr/colorPrimaryVariant</item>
|
||||||
|
|
||||||
<item name="actionBarTheme">@style/ThemeOverlay.MaterialComponents.Dark.ActionBar</item>
|
<item name="actionBarTheme">@style/Theme.Toolbar.Custom</item>
|
||||||
<item name="actionBarPopupTheme">@style/ThemeOverlay.MaterialComponents</item>
|
<item name="actionBarPopupTheme">@style/ThemeOverlay.MaterialComponents</item>
|
||||||
<item name="switchStyle">@style/Theme.Widget.BasicSwitch</item>
|
<item name="switchStyle">@style/Theme.Widget.BasicSwitch</item>
|
||||||
<item name="bottomSheetDialogTheme">@style/Theme.BottomSheet</item>
|
<item name="bottomSheetDialogTheme">@style/Theme.BottomSheet</item>
|
||||||
@ -237,7 +239,7 @@
|
|||||||
<item name="android:statusBarColor">?attr/colorPrimaryVariant</item>
|
<item name="android:statusBarColor">?attr/colorPrimaryVariant</item>
|
||||||
<item name="android:navigationBarColor">?attr/colorPrimaryVariant</item>
|
<item name="android:navigationBarColor">?attr/colorPrimaryVariant</item>
|
||||||
|
|
||||||
<item name="actionBarTheme">@style/ThemeOverlay.MaterialComponents.Dark.ActionBar</item>
|
<item name="actionBarTheme">@style/Theme.Toolbar.Custom</item>
|
||||||
<item name="actionBarPopupTheme">@style/ThemeOverlay.MaterialComponents</item>
|
<item name="actionBarPopupTheme">@style/ThemeOverlay.MaterialComponents</item>
|
||||||
<item name="switchStyle">@style/Theme.Widget.BasicSwitch</item>
|
<item name="switchStyle">@style/Theme.Widget.BasicSwitch</item>
|
||||||
<item name="bottomSheetDialogTheme">@style/Theme.BottomSheet</item>
|
<item name="bottomSheetDialogTheme">@style/Theme.BottomSheet</item>
|
||||||
|
Loading…
Reference in New Issue
Block a user