<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    tools:viewBindingIgnore="true"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content">

    <org.thoughtcrime.securesms.badges.BadgeImageView
        android:id="@+id/gift_message_view_badge"
        android:layout_width="64dp"
        android:layout_height="64dp"
        android:layout_marginStart="16dp"
        android:layout_marginTop="14dp"
        app:badge_size="xlarge"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toTopOf="parent"
        tools:src="@drawable/test_gradient" />

    <TextView
        android:id="@+id/gift_message_view_title"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_marginStart="12dp"
        android:layout_marginTop="24dp"
        android:layout_marginEnd="16dp"
        android:ellipsize="end"
        android:maxLines="1"
        android:textAppearance="@style/Signal.Text.Body"
        app:layout_constrainedWidth="true"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintHorizontal_bias="0"
        app:layout_constraintStart_toEndOf="@id/gift_message_view_badge"
        app:layout_constraintTop_toTopOf="parent"
        tools:text="Gift Badge" />

    <TextView
        android:id="@+id/gift_message_view_description"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_marginStart="12dp"
        android:layout_marginTop="4dp"
        android:layout_marginEnd="16dp"
        android:ellipsize="end"
        android:maxLines="1"
        android:textAppearance="@style/TextAppearance.Signal.Subtitle"
        app:layout_constrainedWidth="true"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintHorizontal_bias="0"
        app:layout_constraintStart_toEndOf="@id/gift_message_view_badge"
        app:layout_constraintTop_toBottomOf="@id/gift_message_view_title"
        tools:text="Lasts for 1 month" />

    <androidx.constraintlayout.widget.Barrier
        android:id="@+id/gift_message_view_barrier"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        app:barrierDirection="bottom"
        app:constraint_referenced_ids="gift_message_view_badge,gift_message_view_description" />

    <com.google.android.material.button.MaterialButton
        android:id="@+id/gift_message_view_action"
        style="@style/Signal.Widget.Button.Medium.Primary"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_marginHorizontal="12dp"
        android:layout_marginTop="15dp"
        android:layout_marginBottom="13dp"
        app:iconGravity="textStart"
        app:iconSize="20dp"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toBottomOf="@id/gift_message_view_barrier"
        tools:text="Redeem" />

</androidx.constraintlayout.widget.ConstraintLayout>