<?xml version="1.0" encoding="utf-8"?>
<FrameLayout 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:id="@+id/root"
    android:layout_width="match_parent"
    android:layout_height="wrap_content">

    <com.anytypeio.anytype.core_ui.features.editor.decoration.EditorDecorationContainer
        android:id="@+id/decorationContainer"
        android:layout_width="match_parent"
        android:layout_height="match_parent" />

    <com.google.android.material.card.MaterialCardView
        android:id="@+id/card"
        style="@style/DefaultMediaPlaceholderBlockCardStyle"
        android:layout_width="match_parent"
        android:layout_height="52dp">

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

            <ImageView
                android:id="@+id/fileIcon"
                android:layout_width="@dimen/dp_32"
                android:layout_height="@dimen/dp_32"
                android:scaleType="center"
                android:layout_marginStart="@dimen/dp_12"
                app:layout_constraintBottom_toBottomOf="parent"
                app:layout_constraintStart_toStartOf="parent"
                app:layout_constraintTop_toTopOf="parent"
                tools:src="@drawable/ic_picture" />

            <TextView
                android:id="@+id/fileName"
                style="@style/TextView.ContentStyle.Body.Callout"
                android:layout_width="0dp"
                android:layout_height="wrap_content"
                android:layout_gravity="center_vertical"
                android:layout_marginStart="4dp"
                android:layout_marginEnd="8dp"
                android:drawablePadding="@dimen/default_media_placeholder_title_icon_padding"
                android:ellipsize="middle"
                android:gravity="center_vertical"
                android:maxLines="1"
                android:textColor="@color/text_tertiary"
                android:text="@string/loading_please_wait"
                app:layout_constraintBottom_toBottomOf="parent"
                app:layout_constraintEnd_toStartOf="@+id/progressBar"
                app:layout_constraintStart_toEndOf="@+id/fileIcon"
                app:layout_constraintTop_toTopOf="parent"
                tools:text="https://github.com/anyproto/anytype-kotlin"/>

            <TextView
                android:id="@+id/progressBar"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="@string/try_again"
                style="@style/TextView.UXStyle.Captions.1.Medium"
                android:textColor="@color/text_primary"
                app:layout_constraintBottom_toBottomOf="parent"
                app:layout_constraintEnd_toEndOf="parent"
                app:layout_constraintTop_toTopOf="parent"
                android:layout_marginEnd="@dimen/dp_12"/>

        </androidx.constraintlayout.widget.ConstraintLayout>

    </com.google.android.material.card.MaterialCardView>

    <TextView
        android:id="@+id/errorMessage"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_marginTop="66dp"
        android:layout_marginStart="20dp"
        android:textColor="@color/palette_system_red"
        style="@style/TextView.UXStyle.Captions.2.Regular"
        android:text="@string/block_media_error"/>

    <View
        android:id="@+id/selected"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:background="@drawable/item_block_multi_select_mode_selector"
        tools:background="@drawable/item_block_multi_select_selected" />
</FrameLayout>