<?xml version="1.0" encoding="utf-8"?>
<!--
  SPDX-FileCopyrightText: 2020 The Calyx Institute
  SPDX-License-Identifier: Apache-2.0
  -->
<androidx.constraintlayout.widget.ConstraintLayout 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">

    <ImageView
        android:id="@+id/imageView"
        style="@style/SudHeaderIcon"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toTopOf="parent"
        app:srcCompat="@drawable/ic_storage"
        app:tint="?android:colorAccent"
        tools:ignore="ContentDescription" />

    <TextView
        android:id="@+id/titleView"
        style="@style/SudHeaderTitle"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:text="@string/storage_fragment_backup_title"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toBottomOf="@+id/imageView"
        tools:text="Choose where to store backup (is a short title, but it can be longer)" />

    <androidx.recyclerview.widget.RecyclerView
        android:id="@+id/listView"
        style="@style/SudContent"
        android:layout_width="match_parent"
        android:layout_height="0dp"
        app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
        app:layout_constraintBottom_toTopOf="@+id/skipView"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toBottomOf="@+id/titleView"
        app:layout_goneMarginTop="16dp"
        tools:listitem="@layout/list_item_storage_root" />

    <ProgressBar
        android:id="@+id/progressBar"
        style="?android:progressBarStyleLarge"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        app:layout_constraintBottom_toTopOf="@+id/skipView"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toBottomOf="@+id/titleView" />

    <TextView
        android:id="@+id/skipView"
        style="@style/SudSecondaryButton"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_marginStart="40dp"
        android:background="?android:selectableItemBackground"
        android:text="@string/restore_skip"
        android:textColor="?android:colorAccent"
        android:visibility="gone"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toBottomOf="@+id/listView"
        tools:visibility="visible" />

</androidx.constraintlayout.widget.ConstraintLayout>
