<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:padding="24dp"
    android:scrollbarStyle="outsideOverlay">

    <androidx.constraintlayout.widget.ConstraintLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content">

        <TextView
            android:id="@+id/tvMessage"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="@string/title_send"
            android:textAppearance="@style/TextAppearance.AppCompat.Large"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toTopOf="parent" />

        <TextView
            android:id="@+id/tvRemindSubject"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="12dp"
            android:text="@string/title_subject_reminder"
            android:textAppearance="@style/TextAppearance.AppCompat.Medium"
            android:textColor="?attr/colorWarning"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/tvMessage" />

        <TextView
            android:id="@+id/tvRemindText"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="12dp"
            android:text="@string/title_text_reminder"
            android:textAppearance="@style/TextAppearance.AppCompat.Medium"
            android:textColor="?attr/colorWarning"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/tvRemindSubject" />

        <TextView
            android:id="@+id/tvRemindAttachment"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="12dp"
            android:text="@string/title_attachment_reminder"
            android:textAppearance="@style/TextAppearance.AppCompat.Medium"
            android:textColor="?attr/colorWarning"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/tvRemindText" />

        <TextView
            android:id="@+id/tvToTitle"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="24dp"
            android:text="@string/title_to"
            android:textAppearance="@style/TextAppearance.AppCompat.Medium"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/tvRemindAttachment" />

        <TextView
            android:id="@+id/tvViaTitle"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="12dp"
            android:text="@string/title_via_identity"
            android:textAppearance="@style/TextAppearance.AppCompat.Medium"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/tvTo" />

        <androidx.constraintlayout.widget.Barrier
            android:id="@+id/barrier"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            app:barrierDirection="end"
            app:constraint_referenced_ids="tvToTitle,tvViaTitle" />

        <TextView
            android:id="@+id/tvTo"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginStart="6dp"
            android:text="recipients"
            android:textAppearance="@style/TextAppearance.AppCompat.Medium"
            android:textColor="?android:attr/textColorPrimary"
            app:layout_constraintStart_toEndOf="@+id/barrier"
            app:layout_constraintTop_toTopOf="@+id/tvToTitle" />

        <TextView
            android:id="@+id/tvVia"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginStart="6dp"
            android:text="via"
            android:textAppearance="@style/TextAppearance.AppCompat.Medium"
            android:textColor="?android:attr/textColorPrimary"
            app:layout_constraintStart_toEndOf="@+id/barrier"
            app:layout_constraintTop_toTopOf="@+id/tvViaTitle" />

        <CheckBox
            android:id="@+id/cbPlainOnly"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="12dp"
            android:text="@string/title_send_plain_text"
            android:textAppearance="@style/TextAppearance.AppCompat.Medium"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/tvVia" />

        <CheckBox
            android:id="@+id/cbEncrypt"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="12dp"
            android:text="@string/title_encrypt"
            android:textAppearance="@style/TextAppearance.AppCompat.Medium"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/cbPlainOnly" />

        <CheckBox
            android:id="@+id/cbReceipt"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="12dp"
            android:text="@string/title_send_receipt"
            android:textAppearance="@style/TextAppearance.AppCompat.Medium"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/cbEncrypt" />

        <TextView
            android:id="@+id/tvReceipt"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="@string/title_send_receipt_remark"
            android:textAppearance="@style/TextAppearance.AppCompat.Small"
            android:textStyle="italic"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/cbReceipt" />

        <TextView
            android:id="@+id/tvPriority"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="12dp"
            android:text="@string/title_send_priority"
            android:textAppearance="@style/TextAppearance.AppCompat.Medium"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/tvReceipt" />

        <Spinner
            android:id="@+id/spPriority"
            android:layout_width="0dp"
            android:layout_height="wrap_content"
            android:layout_marginTop="6dp"
            android:entries="@array/priorityNames"
            app:layout_constraintEnd_toEndOf="parent"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/tvPriority" />

        <TextView
            android:id="@+id/tvSendTitle"
            android:layout_width="0dp"
            android:layout_height="wrap_content"
            android:layout_marginTop="12dp"
            android:text="@string/title_send_at"
            android:textAppearance="@style/TextAppearance.AppCompat.Medium"
            app:layout_constraintEnd_toStartOf="@+id/ibSendAt"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@+id/spPriority" />

        <TextView
            android:id="@+id/tvSendAt"
            android:layout_width="0dp"
            android:layout_height="wrap_content"
            android:layout_marginTop="6dp"
            android:gravity="center_vertical"
            android:text="now"
            android:textAppearance="@style/TextAppearance.AppCompat.Medium"
            android:textColor="?android:attr/textColorPrimary"
            app:layout_constraintEnd_toStartOf="@+id/ibSendAt"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/tvSendTitle" />

        <ImageButton
            android:id="@+id/ibSendAt"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:contentDescription="@string/title_send_at"
            android:tag="disable"
            android:tooltipText="@string/title_send_at"
            app:layout_constraintBottom_toBottomOf="@id/tvSendAt"
            app:layout_constraintEnd_toEndOf="parent"
            app:srcCompat="@drawable/baseline_timelapse_24" />

        <CheckBox
            android:id="@+id/cbNotAgain"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="12dp"
            android:text="@string/title_no_ask_again"
            android:textAppearance="@style/TextAppearance.AppCompat.Small"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/ibSendAt" />

        <TextView
            android:id="@+id/tvNotAgain"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="6dp"
            android:text="@string/title_send_dialog_hint"
            android:textAppearance="@style/TextAppearance.AppCompat.Small"
            android:textStyle="italic"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/cbNotAgain" />
    </androidx.constraintlayout.widget.ConstraintLayout>
</ScrollView>