<?xml version="1.0" encoding="utf-8"?>
<androidx.core.widget.NestedScrollView xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@color/theme_white_color"
    android:clipChildren="true"
    android:fillViewport="true"
    android:orientation="vertical">

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

        <TextView
            android:id="@+id/login_title"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_gravity="center_horizontal"
            android:layout_marginTop="80dp"
            android:text="@string/user_login_welcome_login"
            android:textColor="@color/user_login_title_color"
            android:textSize="@dimen/title_text_size"
            app:layout_constraintLeft_toLeftOf="parent"
            app:layout_constraintRight_toRightOf="parent"
            app:layout_constraintTop_toTopOf="parent" />

        <ImageView
            android:id="@+id/login_icon"
            android:layout_width="40dp"
            android:layout_height="40dp"
            android:layout_marginLeft="10dp"
            android:layout_marginTop="100dp"
            android:background="@color/theme_color"
            android:padding="8dp"
            android:src="@mipmap/ic_user"
            app:layout_constraintLeft_toLeftOf="parent"
            app:layout_constraintTop_toBottomOf="@id/login_title" />

        <EditText
            android:id="@+id/ed_login_user_account"
            android:layout_width="0dp"
            android:layout_height="0dp"
            android:background="@null"
            android:hint="請輸入賬戶"
            android:maxLength="16"
            android:paddingLeft="@dimen/dp_10"
            android:paddingRight="@dimen/dp_10"
            android:singleLine="true"
            android:textColor="@color/theme_333_color"
            android:textColorHint="@color/user_login_edit_color"
            android:textSize="@dimen/edit_text_size"
            app:layout_constraintBottom_toBottomOf="@id/login_icon"
            app:layout_constraintLeft_toRightOf="@id/login_icon"
            app:layout_constraintRight_toLeftOf="@id/iv_clear_account"
            app:layout_constraintTop_toTopOf="@id/login_icon" />

        <ImageView
            android:id="@+id/iv_clear_account"
            android:layout_width="@dimen/dp_30"
            android:layout_height="@dimen/dp_30"
            android:padding="@dimen/dp_5"
            android:src="@drawable/ic_clear_text"
            android:visibility="gone"
            app:layout_constraintBottom_toBottomOf="@id/ed_login_user_account"
            app:layout_constraintLeft_toRightOf="@id/ed_login_user_account"
            app:layout_constraintRight_toRightOf="parent"
            app:layout_constraintTop_toTopOf="@id/ed_login_user_account" />

        <ImageView
            android:id="@+id/iv_login_pwd_icon"
            android:layout_width="40dp"
            android:layout_height="40dp"
            android:layout_marginLeft="10dp"
            android:layout_marginTop="10dp"
            android:background="@color/theme_color"
            android:padding="8dp"
            android:src="@mipmap/ic_pwd"
            app:layout_constraintLeft_toLeftOf="parent"
            app:layout_constraintTop_toBottomOf="@id/ed_login_user_account" />

        <EditText
            android:id="@+id/ed_login_user_pwd"
            android:layout_width="0dp"
            android:layout_height="0dp"
            android:background="#00000000"
            android:gravity="center_vertical"
            android:hint="請輸入密碼"
            android:inputType="textPassword"
            android:maxLength="16"
            android:paddingLeft="@dimen/dp_10"
            android:paddingRight="@dimen/dp_10"
            android:singleLine="true"
            android:textColor="@color/theme_333_color"
            android:textColorHint="@color/user_login_edit_color"
            android:textSize="@dimen/edit_text_size"
            app:layout_constraintBottom_toBottomOf="@id/iv_login_pwd_icon"
            app:layout_constraintLeft_toRightOf="@id/iv_login_pwd_icon"
            app:layout_constraintRight_toLeftOf="@id/ic_look_pwd"
            app:layout_constraintTop_toTopOf="@id/iv_login_pwd_icon" />


        <CheckBox
            android:id="@+id/rb_auto_login"
            android:layout_width="@dimen/dp_30"
            android:layout_height="@dimen/dp_30"
            android:layout_marginTop="@dimen/dp_15"
            app:layout_constraintLeft_toLeftOf="@id/iv_login_pwd_icon"
            app:layout_constraintTop_toBottomOf="@id/ed_login_user_pwd" />

        <TextView
            android:id="@+id/tv_auto_login_text"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginLeft="@dimen/dp_5"
            android:text="自動登陸"
            android:textColor="@color/theme_333_color"
            android:textSize="@dimen/sp_14"
            app:layout_constraintBottom_toBottomOf="@id/rb_auto_login"
            app:layout_constraintLeft_toRightOf="@id/rb_auto_login"
            app:layout_constraintTop_toTopOf="@id/rb_auto_login" />


        <CheckBox
            android:id="@+id/rb_remember_password"
            android:layout_width="@dimen/dp_30"
            android:layout_height="@dimen/dp_30"
            android:layout_marginLeft="@dimen/dp_15"
            android:layout_marginTop="@dimen/dp_15"
            app:layout_constraintLeft_toRightOf="@id/tv_auto_login_text"
            app:layout_constraintTop_toBottomOf="@id/ed_login_user_pwd" />

        <TextView
            android:id="@+id/tv_remember_pwd_text"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginLeft="@dimen/dp_5"
            android:text="記住密碼"
            android:textColor="@color/theme_333_color"
            android:textSize="@dimen/sp_14"
            app:layout_constraintBottom_toBottomOf="@id/rb_remember_password"
            app:layout_constraintLeft_toRightOf="@id/rb_remember_password"
            app:layout_constraintTop_toTopOf="@id/rb_remember_password" />

        <ImageView
            android:id="@+id/ic_look_pwd"
            android:layout_width="@dimen/dp_30"
            android:layout_height="@dimen/dp_30"
            android:padding="@dimen/dp_5"
            android:src="@mipmap/ic_password_hide"
            android:visibility="gone"
            app:layout_constraintBottom_toBottomOf="@id/ed_login_user_pwd"
            app:layout_constraintRight_toLeftOf="@id/iv_clear_pwd"
            app:layout_constraintTop_toTopOf="@id/ed_login_user_pwd" />

        <ImageView
            android:id="@+id/iv_clear_pwd"
            android:layout_width="@dimen/dp_30"
            android:layout_height="@dimen/dp_30"
            android:padding="@dimen/dp_5"
            android:src="@drawable/ic_clear_text"
            android:visibility="gone"
            app:layout_constraintBottom_toBottomOf="@id/ed_login_user_pwd"
            app:layout_constraintRight_toRightOf="parent"
            app:layout_constraintTop_toTopOf="@id/ed_login_user_pwd" />


        <TextView
            android:id="@+id/tv_forget_pwd"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="10dp"
            android:text="忘記密碼？"
            android:textSize="14dp"
            android:visibility="invisible"
            app:layout_constraintLeft_toLeftOf="parent"
            app:layout_constraintRight_toRightOf="parent"
            app:layout_constraintTop_toBottomOf="@id/rb_remember_password" />

        <com.qmuiteam.qmui.alpha.QMUIAlphaButton
            android:id="@+id/tv_gsa_user_login"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginLeft="10dp"
            android:layout_marginTop="20dp"
            android:layout_marginRight="10dp"
            android:background="@drawable/shape_app_btn"
            android:gravity="center"
            android:padding="10dp"
            android:text="登錄"
            android:textColor="#fff"
            android:textSize="16dp"
            app:layout_constraintTop_toBottomOf="@id/tv_forget_pwd" />


        <TextView
            android:id="@+id/tv_app_version"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginBottom="@dimen/dp_10"
            android:text="v1.0"
            android:textSize="@dimen/sp_16"
            app:layout_constraintBottom_toBottomOf="parent"
            app:layout_constraintLeft_toLeftOf="parent"
            app:layout_constraintRight_toRightOf="parent" />
    </androidx.constraintlayout.widget.ConstraintLayout>
</androidx.core.widget.NestedScrollView>

