wip: "send comments" interface

This commit is contained in:
aayush262 2024-02-12 21:43:29 +05:30
parent 4be4a0968d
commit b3de2f805f
8 changed files with 172 additions and 38 deletions

View file

@ -1,28 +1,95 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
<FrameLayout 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"
android:orientation="vertical">
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/commentsLayout">
<TextView
android:id="@+id/itemCommentTitle"
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="32dp"
android:layout_marginTop="8dp"
android:layout_marginEnd="32dp"
android:fontFamily="@font/poppins_bold"
android:text="@string/comments"
android:textSize="16sp" />
android:orientation="vertical">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/commentsList"
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_marginTop="8dp"
android:layout_marginStart="32dp"
android:layout_marginEnd="32dp"
tools:ignore="UseCompoundDrawables">
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="16dp"
android:src="@drawable/ic_round_comment_24"
tools:ignore="ContentDescription" />
<TextView
android:id="@+id/commentTitle"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:fontFamily="@font/poppins_bold"
android:text="@string/comments"
android:textSize="16sp" />
</LinearLayout>
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/commentsList"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
android:layout_marginTop="12dp"
android:layout_marginEnd="16dp"
android:layout_marginBottom="16dp"
tools:listitem="@layout/item_comments"
android:orientation="vertical"/>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
android:layout_marginTop="12dp"
android:layout_marginEnd="16dp"
android:layout_marginBottom="16dp"
tools:listitem="@layout/item_comments" />
</LinearLayout>
android:orientation="horizontal"
android:paddingBottom="8dp"
android:layout_gravity="bottom|end"
android:background="@color/nav_bg">
<com.google.android.material.imageview.ShapeableImageView
android:id="@+id/commentUserAvatar"
android:layout_width="42dp"
android:layout_height="42dp"
android:scaleType="center"
android:layout_marginStart="32dp"
app:srcCompat="@drawable/ic_round_add_circle_24"
tools:ignore="ContentDescription,ImageContrastCheck" />
<EditText
android:id="@+id/commentInput"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:textSize="12sp"
android:fontFamily="@font/poppins_semi_bold"
android:hint="Add a comment..."
android:inputType="text"
android:padding="8dp"
android:background="@drawable/card_outline"
android:layout_marginEnd="8dp"
android:layout_marginStart="8dp"
tools:ignore="HardcodedText"
android:autofillHints="The One Piece is real" />
<ImageButton
android:id="@+id/commentSend"
android:layout_width="42dp"
android:layout_height="42dp"
android:layout_marginEnd="32dp"
android:background="@drawable/ic_round_send_24"
tools:ignore="ContentDescription" />
</LinearLayout>
</FrameLayout>