Minor UI updates

This commit is contained in:
M M Arif 2023-10-16 10:17:32 +05:00
parent 46d68cd971
commit 81bf40cbc2
6 changed files with 33 additions and 28 deletions

View File

@ -14,6 +14,7 @@ import androidx.annotation.NonNull;
import androidx.core.content.res.ResourcesCompat;
import androidx.core.text.HtmlCompat;
import androidx.recyclerview.widget.RecyclerView;
import com.google.android.material.card.MaterialCardView;
import com.vdurmont.emoji.EmojiParser;
import java.util.List;
import java.util.Locale;
@ -72,7 +73,7 @@ public class DashboardAdapter extends RecyclerView.Adapter<RecyclerView.ViewHold
loadMoreListener.onLoadMore();
}
((DashboardAdapter.DashboardHolder) holder).bindData(activityList.get(position));
((DashboardAdapter.DashboardHolder) holder).bindData(activityList.get(position), position);
}
@Override
@ -123,6 +124,8 @@ public class DashboardAdapter extends RecyclerView.Adapter<RecyclerView.ViewHold
private final ImageView typeIcon;
private final TextView dashText;
private final LinearLayout dashTextFrame;
private LinearLayout dashboardLayoutCardsFrame;
private MaterialCardView cardLayout;
private Activity activityObject;
@ -135,6 +138,8 @@ public class DashboardAdapter extends RecyclerView.Adapter<RecyclerView.ViewHold
createdTime = itemView.findViewById(R.id.created_time);
dashText = itemView.findViewById(R.id.text);
dashTextFrame = itemView.findViewById(R.id.dash_text_frame);
dashboardLayoutCardsFrame = itemView.findViewById(R.id.dashboardLayoutCardsFrame);
cardLayout = itemView.findViewById(R.id.cardLayout);
new Handler()
.postDelayed(
@ -353,7 +358,7 @@ public class DashboardAdapter extends RecyclerView.Adapter<RecyclerView.ViewHold
200);
}
void bindData(Activity activity) {
void bindData(Activity activity, int position) {
this.activityObject = activity;
Locale locale = context.getResources().getConfiguration().locale;

View File

@ -3,25 +3,25 @@
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="#00000000"
android:pathData="M3,12L21,12"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
<path
android:fillColor="#00000000"
android:pathData="M3,6L21,6"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
<path
android:fillColor="#00000000"
android:pathData="M3,18L21,18"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
<path
android:pathData="M5,3L19,3A2,2 0,0 1,21 5L21,19A2,2 0,0 1,19 21L5,21A2,2 0,0 1,3 19L3,5A2,2 0,0 1,5 3z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M9,3v18"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="m14,9 l3,3 -3,3"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
</vector>

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<solid android:color="?attr/primaryBackgroundColor"/>
<solid android:color="?attr/materialCardBackgroundColor"/>
<corners android:radius="18dp"/>
</shape>

View File

@ -29,6 +29,7 @@
app:title="@string/createRelease"
app:layout_collapseMode="pin"
app:menu="@menu/create_release_tag_menu"
app:popupTheme="@style/Widget.Material3.PopupMenu"
app:navigationIcon="@drawable/ic_close" />
</com.google.android.material.appbar.CollapsingToolbarLayout>

View File

@ -1,11 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.coordinatorlayout.widget.CoordinatorLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
xmlns:app="http://schemas.android.com/apk/res-auto"
tools:context=".activities.RepoDetailActivity">
xmlns:app="http://schemas.android.com/apk/res-auto">
<FrameLayout
android:layout_width="match_parent"

View File

@ -2,7 +2,7 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/relativeLayoutFrameIssuesList"
android:id="@+id/dashboardLayoutCardsFrame"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="@dimen/dimen4dp"
@ -10,6 +10,7 @@
android:orientation="vertical">
<com.google.android.material.card.MaterialCardView
android:id="@+id/cardLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
style="?attr/materialCardViewElevatedStyle"