<?xml version="1.0" encoding="utf-8"?>

<layout 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">

    <data>

        <import type="android.text.Html" />

        <import type="it.integry.integrywmsnative.R" />

        <import type="it.integry.integrywmsnative.core.utility.UtilityString" />

        <import type="it.integry.integrywmsnative.core.utility.UtilityNumber" />

        <variable
            name="mContext"
            type="android.content.Context" />

        <variable
            name="view"
            type="it.integry.integrywmsnative.view.dialogs.input_peso_lu.DialogInputPesoLuView" />
    </data>

    <androidx.cardview.widget.CardView
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_gravity="center_horizontal"
        android:orientation="vertical"
        app:cardCornerRadius="12dp"
        app:cardElevation="0dp">

        <androidx.appcompat.widget.LinearLayoutCompat
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:orientation="vertical"
            android:paddingHorizontal="16dp"
            android:paddingVertical="16dp">


            <androidx.appcompat.widget.AppCompatImageView
                style="@style/MaterialAlertDialog.Material3.Title.Icon.CenterStacked"
                android:layout_width="36dp"
                android:layout_height="36dp"
                android:src="@drawable/ic_error_white_24dp"
                app:tint="?colorPrimary" />


            <androidx.appcompat.widget.AppCompatTextView
                android:id="@+id/title_text"
                style="@style/MaterialAlertDialog.Material3.Title.Text.CenterStacked"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:gravity="center_horizontal"
                android:text="@string/action_insert_weight" />


            <androidx.appcompat.widget.AppCompatTextView
                style="@style/MaterialAlertDialog.Material3.Body.Text.CenterStacked"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_marginTop="16dp"
                android:text="@string/dialog_input_peso_lu_description" />


            <androidx.appcompat.widget.LinearLayoutCompat
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_marginTop="16dp"
                android:orientation="vertical">


                <com.google.android.material.textfield.TextInputLayout
                    android:id="@+id/input_cod_tcol"
                    style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox.Dense.ExposedDropdownMenu"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:hint="@string/lu_type">

                    <androidx.appcompat.widget.AppCompatAutoCompleteTextView
                        android:id="@+id/filled_exposed_dropdown_cod_tcol"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:ellipsize="end"
                        android:imeOptions="actionNext"
                        android:inputType="textNoSuggestions"
                        android:nextFocusForward="@id/filled_exposed_dropdown_vettore"
                        android:singleLine="true"
                        app:binding="@{view.codTcol}" />

                </com.google.android.material.textfield.TextInputLayout>


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

                    <androidx.constraintlayout.widget.Guideline
                        android:id="@+id/guide_center_1"
                        android:layout_width="0dp"
                        android:layout_height="0dp"
                        android:orientation="vertical"
                        app:layout_constraintGuide_percent="0.49" />

                    <androidx.constraintlayout.widget.Guideline
                        android:id="@+id/guide_center_2"
                        android:layout_width="0dp"
                        android:layout_height="0dp"
                        android:orientation="vertical"
                        app:layout_constraintGuide_percent="0.51" />

                    <com.google.android.material.textfield.TextInputLayout
                        style="@style/TextInputLayout.OutlinePrimary"
                        android:layout_width="0dp"
                        android:layout_height="wrap_content"
                        android:layout_marginBottom="16dp"
                        app:layout_constraintEnd_toEndOf="@id/guide_center_1"
                        app:layout_constraintStart_toStartOf="parent"
                        app:layout_constraintTop_toTopOf="parent">

                        <com.google.android.material.textfield.TextInputEditText
                            style="@style/TextInputEditText.OutlinePrimary"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:hint="@string/gross_weight"
                            android:inputType="numberDecimal"
                            app:binding="@{view.grossWeight}" />

                    </com.google.android.material.textfield.TextInputLayout>

                    <com.google.android.material.textfield.TextInputLayout
                        style="@style/TextInputLayout.OutlinePrimary"
                        android:layout_width="0dp"
                        android:layout_height="wrap_content"
                        android:layout_marginBottom="16dp"
                        app:layout_constraintEnd_toEndOf="parent"
                        app:layout_constraintStart_toStartOf="@id/guide_center_2"
                        app:layout_constraintTop_toTopOf="parent">

                        <com.google.android.material.textfield.TextInputEditText
                            style="@style/TextInputEditText.OutlinePrimary"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:hint="@string/net_weight"
                            android:inputType="numberDecimal"
                            app:binding="@{view.netWeight}" />

                    </com.google.android.material.textfield.TextInputLayout>
                </androidx.constraintlayout.widget.ConstraintLayout>

            </androidx.appcompat.widget.LinearLayoutCompat>

        </androidx.appcompat.widget.LinearLayoutCompat>


    </androidx.cardview.widget.CardView>

</layout>