introduce separate tonal selector backgrounds
This commit is contained in:
parent
59026286a1
commit
b5eae13a16
|
@ -34,7 +34,6 @@ import me.grishka.appkit.api.Callback;
|
||||||
import me.grishka.appkit.api.ErrorResponse;
|
import me.grishka.appkit.api.ErrorResponse;
|
||||||
import me.grishka.appkit.imageloader.ViewImageLoader;
|
import me.grishka.appkit.imageloader.ViewImageLoader;
|
||||||
import me.grishka.appkit.imageloader.requests.UrlImageLoaderRequest;
|
import me.grishka.appkit.imageloader.requests.UrlImageLoaderRequest;
|
||||||
import me.grishka.appkit.utils.CubicBezierInterpolator;
|
|
||||||
import me.grishka.appkit.utils.V;
|
import me.grishka.appkit.utils.V;
|
||||||
|
|
||||||
public class ReportDoneFragment extends MastodonToolbarFragment{
|
public class ReportDoneFragment extends MastodonToolbarFragment{
|
||||||
|
|
|
@ -3,19 +3,13 @@
|
||||||
android:color="@color/m3_primary_overlay">
|
android:color="@color/m3_primary_overlay">
|
||||||
<item android:gravity="center_vertical" android:height="40dp">
|
<item android:gravity="center_vertical" android:height="40dp">
|
||||||
<selector>
|
<selector>
|
||||||
<item android:state_enabled="true" android:state_selected="true">
|
<item android:state_enabled="true">
|
||||||
<shape>
|
<shape>
|
||||||
<solid android:color="?colorM3SecondaryContainer"/>
|
<solid android:color="?colorM3SecondaryContainer"/>
|
||||||
<corners android:radius="20dp"/>
|
<corners android:radius="20dp"/>
|
||||||
</shape>
|
</shape>
|
||||||
</item>
|
</item>
|
||||||
<item android:state_selected="false">
|
<item>
|
||||||
<shape>
|
|
||||||
<stroke android:color="@color/m3_on_surface_overlay" android:width="1dp"/>
|
|
||||||
<corners android:radius="20dp"/>
|
|
||||||
</shape>
|
|
||||||
</item>
|
|
||||||
<item android:state_enabled="false">
|
|
||||||
<shape>
|
<shape>
|
||||||
<solid android:color="?colorM3DisabledBackground"/>
|
<solid android:color="?colorM3DisabledBackground"/>
|
||||||
<corners android:radius="20dp"/>
|
<corners android:radius="20dp"/>
|
||||||
|
|
|
@ -3,19 +3,13 @@
|
||||||
android:color="@color/m3_primary_overlay">
|
android:color="@color/m3_primary_overlay">
|
||||||
<item android:gravity="center" android:height="40dp" android:width="40dp">
|
<item android:gravity="center" android:height="40dp" android:width="40dp">
|
||||||
<selector>
|
<selector>
|
||||||
<item android:state_enabled="true" android:state_selected="true">
|
<item android:state_enabled="true">
|
||||||
<shape>
|
<shape>
|
||||||
<solid android:color="?colorM3SecondaryContainer"/>
|
<solid android:color="?colorM3SecondaryContainer"/>
|
||||||
<corners android:radius="20dp"/>
|
<corners android:radius="20dp"/>
|
||||||
</shape>
|
</shape>
|
||||||
</item>
|
</item>
|
||||||
<item android:state_selected="false">
|
<item>
|
||||||
<shape>
|
|
||||||
<stroke android:color="@color/m3_on_surface_overlay" android:width="1dp"/>
|
|
||||||
<corners android:radius="20dp"/>
|
|
||||||
</shape>
|
|
||||||
</item>
|
|
||||||
<item android:state_enabled="false">
|
|
||||||
<shape>
|
<shape>
|
||||||
<solid android:color="?colorM3DisabledBackground"/>
|
<solid android:color="?colorM3DisabledBackground"/>
|
||||||
<corners android:radius="20dp"/>
|
<corners android:radius="20dp"/>
|
||||||
|
|
|
@ -0,0 +1,32 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:color="@color/m3_primary_overlay">
|
||||||
|
<item android:gravity="center" android:height="40dp" android:width="40dp">
|
||||||
|
<selector>
|
||||||
|
<item android:state_enabled="true" android:state_selected="true">
|
||||||
|
<shape>
|
||||||
|
<solid android:color="?colorM3SecondaryContainer"/>
|
||||||
|
<corners android:radius="20dp"/>
|
||||||
|
</shape>
|
||||||
|
</item>
|
||||||
|
<item android:state_selected="false">
|
||||||
|
<shape>
|
||||||
|
<stroke android:color="@color/m3_on_surface_overlay" android:width="1dp"/>
|
||||||
|
<corners android:radius="20dp"/>
|
||||||
|
</shape>
|
||||||
|
</item>
|
||||||
|
<item android:state_enabled="false">
|
||||||
|
<shape>
|
||||||
|
<solid android:color="?colorM3DisabledBackground"/>
|
||||||
|
<corners android:radius="20dp"/>
|
||||||
|
</shape>
|
||||||
|
</item>
|
||||||
|
</selector>
|
||||||
|
</item>
|
||||||
|
<item android:id="@android:id/mask" android:gravity="center" android:height="40dp" android:width="40dp">
|
||||||
|
<shape>
|
||||||
|
<solid android:color="#000"/>
|
||||||
|
<corners android:radius="20dp"/>
|
||||||
|
</shape>
|
||||||
|
</item>
|
||||||
|
</ripple>
|
|
@ -0,0 +1,32 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:color="@color/m3_primary_overlay">
|
||||||
|
<item android:gravity="center_vertical" android:height="40dp">
|
||||||
|
<selector>
|
||||||
|
<item android:state_enabled="true" android:state_selected="true">
|
||||||
|
<shape>
|
||||||
|
<solid android:color="?colorM3SecondaryContainer"/>
|
||||||
|
<corners android:radius="20dp"/>
|
||||||
|
</shape>
|
||||||
|
</item>
|
||||||
|
<item android:state_selected="false">
|
||||||
|
<shape>
|
||||||
|
<stroke android:color="@color/m3_on_surface_overlay" android:width="1dp"/>
|
||||||
|
<corners android:radius="20dp"/>
|
||||||
|
</shape>
|
||||||
|
</item>
|
||||||
|
<item android:state_enabled="false">
|
||||||
|
<shape>
|
||||||
|
<solid android:color="?colorM3DisabledBackground"/>
|
||||||
|
<corners android:radius="20dp"/>
|
||||||
|
</shape>
|
||||||
|
</item>
|
||||||
|
</selector>
|
||||||
|
</item>
|
||||||
|
<item android:id="@android:id/mask" android:gravity="center_vertical" android:height="40dp">
|
||||||
|
<shape>
|
||||||
|
<solid android:color="#000"/>
|
||||||
|
<corners android:radius="20dp"/>
|
||||||
|
</shape>
|
||||||
|
</item>
|
||||||
|
</ripple>
|
|
@ -30,7 +30,7 @@
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:minHeight="48dp"
|
android:minHeight="48dp"
|
||||||
android:minWidth="48dp"
|
android:minWidth="48dp"
|
||||||
android:background="@drawable/bg_button_m3_tonal_circle"
|
android:background="@drawable/bg_button_m3_tonal_circle_selector"
|
||||||
android:tooltipText="@string/sk_button_react"
|
android:tooltipText="@string/sk_button_react"
|
||||||
android:contentDescription="@string/sk_button_react"
|
android:contentDescription="@string/sk_button_react"
|
||||||
android:src="@drawable/ic_fluent_add_24_filled" />
|
android:src="@drawable/ic_fluent_add_24_filled" />
|
||||||
|
|
|
@ -49,7 +49,7 @@
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/advanced"
|
android:id="@+id/advanced"
|
||||||
style="@style/Widget.Mastodon.M3.Button.Outlined"
|
style="@style/Widget.Mastodon.M3.Button.Outlined"
|
||||||
android:background="@drawable/bg_button_m3_tonal"
|
android:background="@drawable/bg_button_m3_tonal_selector"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginHorizontal="24dp"
|
android:layout_marginHorizontal="24dp"
|
||||||
|
|
|
@ -366,6 +366,7 @@
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
style="@style/Widget.Mastodon.M3.Button.Tonal.Icon"
|
style="@style/Widget.Mastodon.M3.Button.Tonal.Icon"
|
||||||
|
android:background="@drawable/bg_button_m3_tonal_selector"
|
||||||
android:id="@+id/sensitive_item"
|
android:id="@+id/sensitive_item"
|
||||||
android:orientation="horizontal"
|
android:orientation="horizontal"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
|
|
|
@ -93,7 +93,7 @@
|
||||||
android:layout_width="48dp"
|
android:layout_width="48dp"
|
||||||
android:layout_height="48dp"
|
android:layout_height="48dp"
|
||||||
style="@style/Widget.Mastodon.M3.Button.Tonal"
|
style="@style/Widget.Mastodon.M3.Button.Tonal"
|
||||||
android:background="@drawable/bg_button_m3_tonal_circle"
|
android:background="@drawable/bg_button_m3_tonal_circle_selector"
|
||||||
android:paddingStart="12dp"
|
android:paddingStart="12dp"
|
||||||
android:drawableStart="@drawable/ic_fluent_alert_24_selector" />
|
android:drawableStart="@drawable/ic_fluent_alert_24_selector" />
|
||||||
|
|
||||||
|
|
|
@ -23,5 +23,5 @@
|
||||||
android:layout_marginEnd="8dp"
|
android:layout_marginEnd="8dp"
|
||||||
android:drawableTint="@null"
|
android:drawableTint="@null"
|
||||||
android:drawableStart="@drawable/image_placeholder"
|
android:drawableStart="@drawable/image_placeholder"
|
||||||
android:background="@drawable/bg_button_m3_tonal"/>
|
android:background="@drawable/bg_button_m3_tonal_selector"/>
|
||||||
</FrameLayout>
|
</FrameLayout>
|
||||||
|
|
Loading…
Reference in New Issue