Update mode selector button style

This commit is contained in:
iKirby
2023-08-26 20:37:16 +08:00
committed by GitHub
parent c490011464
commit adfa128118
5 changed files with 43 additions and 17 deletions

View File

@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<solid android:color="@android:color/transparent" />
<stroke
android:width="1dp"
android:color="?colorOnPrimaryContainer" />
<corners android:radius="4dp" />
</shape>

View File

@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<solid android:color="?colorPrimary" />
<stroke
android:width="1dp"
android:color="?colorPrimary" />
<corners android:radius="4dp" />
</shape>

View File

@@ -424,13 +424,14 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:padding="16dp">
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Mode"
android:paddingTop="16dp"
android:paddingHorizontal="16dp"
android:textAppearance="?attr/textAppearanceTitleSmall">
</TextView>
@@ -440,7 +441,7 @@
android:id="@+id/clashModeList"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="16dp"
android:padding="8dp"
app:layoutManager="androidx.recyclerview.widget.GridLayoutManager"
app:spanCount="3"

View File

@@ -1,17 +1,20 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/clashModeButton"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="center">
android:layout_margin="8dp"
android:background="@drawable/bg_rounded_rectangle_active">
<Button
android:id="@+id/clashModeButton"
style="@style/Widget.MaterialComponents.Button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="?colorSurfaceContainer"
<TextView
android:id="@+id/clashModeButtonText"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?selectableItemBackground"
android:gravity="center"
android:paddingVertical="8dp"
android:textColor="?android:textColorPrimaryInverse"
tools:text="Direct" />
</LinearLayout>