<?xml version="1.0" encoding="utf-8"?><!--
** Copyright (c) 2012 Todoroo Inc
**
** See the file "LICENSE" for the full license governing this code.
-->
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
  xmlns:app="http://schemas.android.com/apk/res-auto"
  android:layout_width="fill_parent"
  android:layout_height="fill_parent"
  android:orientation="vertical">

  <LinearLayout
    android:layout_width="fill_parent"
    android:layout_height="0dp"
    android:orientation="vertical">

    <FrameLayout
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:background="?attr/colorAccent">

      <androidx.appcompat.widget.AppCompatSpinner
        android:id="@+id/frequency"
        style="Widget.MaterialComponents.Spinner"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_marginTop="4dp"
        android:layout_marginBottom="4dp"
        android:layout_gravity="center_horizontal"
        android:paddingStart="@dimen/keyline_first"
        android:paddingEnd="@dimen/keyline_first"
        app:backgroundTint="?attr/colorOnSecondary"/>

    </FrameLayout>

    <LinearLayout
      android:layout_width="fill_parent"
      android:layout_height="wrap_content"
      android:layout_marginTop="8dp"
      android:focusableInTouchMode="true"
      android:orientation="horizontal">

      <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:paddingStart="@dimen/keyline_first"
        android:paddingEnd="0dp"
        android:text="@string/repeat_every"
        android:textAppearance="@style/TextAppearance"/>

      <EditText
        android:id="@+id/intervalValue"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:paddingStart="4dp"
        android:paddingEnd="4dp"
        android:ems="3"
        android:focusable="true"
        android:focusableInTouchMode="true"
        android:gravity="center_horizontal"
        android:imeOptions="flagNoExtractUi"
        android:inputType="number"
        android:maxLength="3"
        android:selectAllOnFocus="true"
        android:singleLine="true"
        android:textSize="15sp"/>

      <TextView
        android:id="@+id/intervalText"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:paddingStart="0dp"
        android:paddingEnd="@dimen/keyline_first"
        android:textAppearance="@style/TextAppearance"/>

    </LinearLayout>

    <include layout="@layout/week_buttons"/>

    <RadioGroup
      android:id="@+id/month_group"
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:paddingStart="@dimen/keyline_first"
      android:paddingEnd="@dimen/keyline_first"
      android:orientation="vertical"
      android:visibility="gone">

      <RadioButton
        android:id="@+id/repeat_monthly_same_day"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="@string/repeat_monthly_same_day_each_month"/>

      <RadioButton
        android:id="@+id/repeat_monthly_day_of_nth_week"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"/>

      <RadioButton
        android:id="@+id/repeat_monthly_day_of_last_week"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"/>
    </RadioGroup>

    <LinearLayout
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginTop="8dp"
      android:orientation="horizontal">

      <Spinner
        android:id="@+id/repeat_until"
        style="Widget.MaterialComponents.Spinner"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_marginStart="@dimen/keyline_first"
        android:layout_marginEnd="0dp"
        android:layout_gravity="center"/>

      <EditText
        android:id="@+id/repeatTimesValue"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:paddingStart="4dp"
        android:paddingEnd="4dp"
        android:ems="3"
        android:focusable="true"
        android:focusableInTouchMode="true"
        android:gravity="center"
        android:imeOptions="flagNoExtractUi"
        android:inputType="number"
        android:maxLength="3"
        android:selectAllOnFocus="true"
        android:singleLine="true"
        android:textSize="15sp"/>

      <TextView
        android:id="@+id/repeatTimesText"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_gravity="center"
        android:paddingStart="0dp"
        android:paddingEnd="@dimen/keyline_first"
        android:textAppearance="@style/TextAppearance"/>

    </LinearLayout>

  </LinearLayout>

</ScrollView>

