<?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"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:fillViewport="true">

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

        <androidx.appcompat.widget.AppCompatImageView
            android:id="@+id/delete_account_fragment_warning"
            android:layout_width="40dp"
            android:layout_height="40dp"
            android:layout_marginTop="16dp"
            app:layout_constraintEnd_toEndOf="parent"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toTopOf="parent"
            app:srcCompat="@drawable/ic_warning_40"
            app:tint="@color/signal_alert_primary" />

        <TextView
            android:id="@+id/delete_account_fragment_notice"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginStart="16dp"
            android:layout_marginTop="16dp"
            android:layout_marginEnd="16dp"
            android:text="@string/DeleteAccountFragment__deleting_your_account_will"
            android:textAppearance="@style/Signal.Text.Body"
            app:layout_constraintEnd_toEndOf="parent"
            app:layout_constraintHorizontal_bias="0"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/delete_account_fragment_warning" />

        <TextView
            android:id="@+id/delete_account_fragment_bullets"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginStart="16dp"
            android:layout_marginTop="8dp"
            android:layout_marginEnd="16dp"
            android:textAppearance="@style/TextAppearance.Signal.Body2"
            app:layout_constraintTop_toBottomOf="@id/delete_account_fragment_notice"
            tools:text="Some\nbullets\nhere" />

        <TextView
            android:id="@+id/delete_account_fragment_enter_phone_number"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="30dp"
            android:text="@string/DeleteAccountFragment__enter_your_phone_number"
            android:textAppearance="@style/TextAppearance.Signal.Body1.Bold"
            app:layout_constraintEnd_toEndOf="parent"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/delete_account_fragment_bullets" />

        <FrameLayout
            android:id="@+id/delete_account_fragment_country_spinner_frame"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginStart="32dp"
            android:layout_marginTop="16dp"
            android:layout_marginEnd="32dp"
            android:background="@drawable/labeled_edit_text_background_inactive"

            app:layout_constraintEnd_toEndOf="parent"
            app:layout_constraintHorizontal_bias="0.5"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@+id/delete_account_fragment_enter_phone_number">

            <Spinner
                android:id="@+id/delete_account_fragment_country_spinner"
                android:layout_width="fill_parent"
                android:layout_height="wrap_content"
                android:padding="16dp"
                android:textAlignment="viewStart" />

        </FrameLayout>

        <LinearLayout
            android:id="@+id/delete_account_fragment_linearLayout"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginStart="32dp"
            android:layout_marginTop="12dp"
            android:layout_marginEnd="32dp"
            android:layoutDirection="ltr"
            android:orientation="horizontal"
            android:weightSum="4"
            app:layout_constraintEnd_toEndOf="parent"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@+id/delete_account_fragment_country_spinner_frame">

            <org.thoughtcrime.securesms.components.LabeledEditText
                android:id="@+id/delete_account_fragment_country_code"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginEnd="12dp"
                android:layout_weight="1"
                app:labeledEditText_background="@color/white"
                app:labeledEditText_textLayout="@layout/delete_account_country_code_text" />

            <org.thoughtcrime.securesms.components.LabeledEditText
                android:id="@+id/delete_account_fragment_number"
                android:layout_width="0dp"
                android:layout_height="wrap_content"
                android:layout_weight="3"
                app:labeledEditText_background="?android:windowBackground"
                app:labeledEditText_label="@string/RegistrationActivity_phone_number_description"
                app:labeledEditText_textLayout="@layout/phone_text" />
        </LinearLayout>

        <com.google.android.material.button.MaterialButton
            android:id="@+id/delete_account_fragment_delete"
            style="@style/Signal.Widget.Button.Large.Danger"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginStart="32dp"
            android:layout_marginTop="16dp"
            android:layout_marginEnd="32dp"
            android:text="@string/DeleteAccountFragment__delete_account"
            app:layout_constraintEnd_toEndOf="parent"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/delete_account_fragment_linearLayout" />

    </androidx.constraintlayout.widget.ConstraintLayout>
</ScrollView>