<?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"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:background="?riotx_background"
    android:foreground="?attr/selectableItemBackground"
    android:minHeight="@dimen/item_form_min_height">

    <TextView
        android:id="@+id/formSwitchTitle"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_marginStart="@dimen/layout_horizontal_margin"
        android:layout_marginEnd="@dimen/layout_horizontal_margin"
        android:duplicateParentState="true"
        android:textColor="?riotx_text_primary"
        android:textSize="15sp"
        app:layout_constraintBottom_toTopOf="@+id/formSwitchSummary"
        app:layout_constraintEnd_toStartOf="@+id/formSwitchSwitch"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toTopOf="parent"
        app:layout_constraintVertical_chainStyle="packed"
        tools:text="@string/create_room_public_title" />

    <TextView
        android:id="@+id/formSwitchSummary"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_marginEnd="8dp"
        android:textColor="?riotx_text_secondary"
        android:textSize="14sp"
        app:layout_constraintBottom_toTopOf="@+id/formSwitchDivider"
        app:layout_constraintEnd_toStartOf="@+id/formSwitchSwitch"
        app:layout_constraintStart_toStartOf="@+id/formSwitchTitle"
        app:layout_constraintTop_toBottomOf="@+id/formSwitchTitle"
        tools:text="@string/create_room_public_description" />

    <com.google.android.material.switchmaterial.SwitchMaterial
        android:id="@+id/formSwitchSwitch"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_marginEnd="19dp"
        app:layout_constraintBottom_toTopOf="@+id/formSwitchDivider"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintTop_toTopOf="parent" />

    <View
        android:id="@+id/formSwitchDivider"
        android:layout_width="0dp"
        android:layout_height="1dp"
        android:background="?riotx_header_panel_border_mobile"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toStartOf="parent" />

</androidx.constraintlayout.widget.ConstraintLayout>
