habitica-android/Habitica/res/layout/fragment_subscription.xml

302 lines
14 KiB
XML
Raw Normal View History

2017-01-10 17:05:03 +00:00
<?xml version="1.0" encoding="utf-8"?>
2023-08-28 09:36:13 +00:00
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout 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"
2023-08-28 09:36:13 +00:00
android:id="@+id/refresh_layout"
android:layout_width="match_parent"
android:layout_height="match_parent">
2023-08-28 09:36:13 +00:00
<androidx.core.widget.NestedScrollView
android:id="@+id/scroll_view"
2017-01-12 10:42:36 +00:00
android:layout_width="match_parent"
2023-08-28 09:36:13 +00:00
android:layout_height="match_parent"
android:scrollbarSize="3dp"
android:scrollbarThumbVertical="@color/scrollbarThumb"
android:scrollbars="vertical">
<LinearLayout
2023-08-28 09:36:13 +00:00
android:layout_width="match_parent"
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:orientation="vertical">
2023-08-28 09:36:13 +00:00
<androidx.compose.ui.platform.ComposeView
android:id="@+id/promo_compose_view"
android:layout_width="match_parent"
2019-11-19 17:07:45 +00:00
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:visibility="gone" />
2019-11-19 17:07:45 +00:00
2023-08-28 09:36:13 +00:00
<RelativeLayout
android:id="@+id/promo_banner"
2019-11-19 17:07:45 +00:00
android:layout_width="match_parent"
2023-08-28 09:36:13 +00:00
android:layout_height="80dp"
android:layout_marginStart="10dp"
android:layout_marginEnd="10dp"
android:layout_marginBottom="8dp"
android:background="@drawable/g1g1_box"
android:clickable="true"
2023-12-21 13:17:06 +00:00
android:focusable="true"
2023-08-28 09:36:13 +00:00
android:clipChildren="true"
android:clipToOutline="true"
android:clipToPadding="true"
android:visibility="gone"
tools:visibility="visible">
2019-11-19 17:07:45 +00:00
2023-08-28 09:36:13 +00:00
<ImageView
android:id="@+id/promo_banner_left_image"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_alignParentStart="true"
android:layout_alignParentTop="true"
android:layout_alignParentBottom="false"
2023-12-21 13:17:06 +00:00
android:scaleType="center"
android:importantForAccessibility="no" />
2017-02-03 12:21:42 +00:00
<ImageView
2023-08-28 09:36:13 +00:00
android:id="@+id/promo_banner_right_image"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_alignParentTop="true"
android:layout_alignParentEnd="true"
2023-12-21 13:17:06 +00:00
android:scaleType="center"
android:importantForAccessibility="no" />
2023-08-28 09:36:13 +00:00
2019-11-19 17:07:45 +00:00
<LinearLayout
2017-02-03 12:21:42 +00:00
android:layout_width="wrap_content"
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:layout_centerInParent="true"
android:gravity="center"
android:orientation="vertical">
<ImageView
android:id="@+id/promo_banner_title_image"
2019-11-19 17:07:45 +00:00
android:layout_width="wrap_content"
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:layout_marginBottom="6dp" />
2019-11-19 17:07:45 +00:00
<TextView
2023-08-28 09:36:13 +00:00
android:id="@+id/promo_banner_title_text"
style="@style/SubHeader1"
2019-11-19 17:07:45 +00:00
android:layout_width="wrap_content"
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:layout_marginStart="84dp"
android:layout_marginEnd="84dp"
android:layout_marginBottom="6dp"
android:gravity="center"
android:textColor="@color/white"
android:visibility="gone" />
<TextView
android:id="@+id/promo_banner_duration_view"
style="@style/Overline"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
2019-11-19 17:07:45 +00:00
</LinearLayout>
2023-08-28 09:36:13 +00:00
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:layout_marginStart="60dp"
android:layout_marginEnd="60dp"
android:layout_marginBottom="12dp"
android:fontFamily="@string/font_family_medium"
android:gravity="center_horizontal"
android:textColor="@color/white"
android:textSize="16sp" />
</RelativeLayout>
2019-11-19 17:07:45 +00:00
<LinearLayout
2017-01-12 10:42:36 +00:00
android:layout_width="match_parent"
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:orientation="vertical"
android:padding="20dp">
<ImageView
2023-08-28 09:36:13 +00:00
android:id="@+id/header_image_view"
2017-02-03 12:21:42 +00:00
android:layout_width="wrap_content"
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:layout_gravity="center_horizontal"
android:layout_marginBottom="20dp"
2023-12-21 13:17:06 +00:00
android:src="@drawable/subscribe_header"
android:importantForAccessibility="no" />
2023-08-28 09:36:13 +00:00
<com.habitrpg.android.habitica.ui.views.subscriptions.SubscriptionDetailsView
android:id="@+id/subscriptionDetails"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
<com.habitrpg.android.habitica.ui.views.DayNightTextView
android:id="@+id/subscribeBenefitsTitle"
style="@style/SubHeader1"
android:layout_width="250dp"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginTop="8dp"
android:gravity="center"
android:lineSpacingExtra="4dp"
android:text="@string/subscribe_prompt"
app:dayTextColor="@color/text_brand"
app:nightTextColor="@color/gray_400" />
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginTop="20dp"
android:layout_marginBottom="20dp"
2023-12-21 13:17:06 +00:00
android:src="@drawable/separator_fancy"
android:importantForAccessibility="no" />
2023-08-28 09:36:13 +00:00
2023-09-14 09:19:19 +00:00
<com.habitrpg.android.habitica.ui.views.subscriptions.SubscriberBenefitView
android:id="@+id/subscriber_benefits"
2023-08-28 09:36:13 +00:00
android:layout_width="match_parent"
2023-09-14 09:19:19 +00:00
android:layout_height="wrap_content" />
2017-02-03 12:21:42 +00:00
2023-08-28 09:36:13 +00:00
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_marginTop="20dp"
android:layout_marginBottom="12dp"
2023-12-21 13:17:06 +00:00
android:src="@drawable/separator_fancy"
android:importantForAccessibility="no" />
2023-08-28 09:36:13 +00:00
<ProgressBar
android:id="@+id/loadingIndicator"
style="?android:attr/progressBarStyle"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
2017-02-03 12:21:42 +00:00
2019-11-19 17:07:45 +00:00
<TextView
2023-08-28 09:36:13 +00:00
android:layout_width="match_parent"
2019-11-19 17:07:45 +00:00
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:paddingTop="50dp"
android:paddingBottom="10dp"
android:text="@string/no_billing_subscriptions"
android:visibility="gone" />
2019-11-19 17:07:45 +00:00
2023-08-28 09:36:13 +00:00
<Button
style="@style/HabiticaButton.Purple"
android:layout_width="wrap_content"
2017-02-03 12:21:42 +00:00
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:layout_gravity="center"
android:layout_marginBottom="50dp"
android:text="@string/visit_habitica_website"
android:visibility="gone" />
2017-02-03 12:21:42 +00:00
2023-08-28 09:36:13 +00:00
<LinearLayout
android:id="@+id/subscriptionOptions"
2017-02-03 12:21:42 +00:00
android:layout_width="match_parent"
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:orientation="vertical">
<TextView
style="@style/SubHeader1"
android:layout_width="250dp"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginBottom="20dp"
android:gravity="center_horizontal"
android:text="@string/subscribe_options_title"
android:textColor="@color/text_brand" />
<com.habitrpg.android.habitica.ui.views.subscriptions.SubscriptionOptionView
android:id="@+id/subscription1month"
android:layout_width="match_parent"
android:layout_height="wrap_content"
2024-08-16 12:13:44 +00:00
app:gemCapText="25"
2023-08-28 09:36:13 +00:00
app:recurringText="@string/month" />
<com.habitrpg.android.habitica.ui.views.subscriptions.SubscriptionOptionView
android:id="@+id/subscription3month"
android:layout_width="match_parent"
android:layout_height="wrap_content"
2024-08-16 12:13:44 +00:00
app:gemCapText="25"
2023-08-28 09:36:13 +00:00
app:recurringText="@string/three_months" />
<com.habitrpg.android.habitica.ui.views.subscriptions.SubscriptionOptionView
android:id="@+id/subscription6month"
android:layout_width="match_parent"
android:layout_height="wrap_content"
2024-08-16 12:13:44 +00:00
app:gemCapText="25"
2023-08-28 09:36:13 +00:00
app:recurringText="@string/six_months" />
<com.habitrpg.android.habitica.ui.views.subscriptions.SubscriptionOptionView
android:id="@+id/subscription12month"
android:layout_width="match_parent"
android:layout_height="wrap_content"
2024-08-16 12:13:44 +00:00
app:flagText="@string/popular"
app:gemCapText="50"
2023-08-28 09:36:13 +00:00
app:recurringText="@string/twelve_months" />
<Button
android:id="@+id/subscribeButton"
style="@style/HabiticaButton.Purple.Small"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:text="@string/subscribe"
android:textAllCaps="false" />
2023-12-21 11:02:41 +00:00
<TextView
android:id="@+id/subscription_disclaimer_view"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textColor="@color/text_quad"
android:textSize="14sp"
tools:text="This will contain text explaining subscriptions."
android:layout_marginTop="8dp"
android:layout_marginBottom="8dp"/>
2023-08-28 09:36:13 +00:00
</LinearLayout>
<ImageView
android:layout_width="wrap_content"
2017-02-03 12:21:42 +00:00
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:layout_gravity="center_horizontal"
android:layout_marginTop="24dp"
android:layout_marginBottom="6dp"
2023-12-21 13:17:06 +00:00
android:src="@drawable/gift_sub_gift"
android:importantForAccessibility="no" />
2023-08-28 09:36:13 +00:00
<TextView
2017-02-03 12:21:42 +00:00
android:layout_width="match_parent"
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:layout_marginStart="@dimen/spacing_large"
android:layout_marginEnd="@dimen/spacing_large"
android:gravity="center_horizontal"
android:text="@string/subscribe_gift_description"
android:textColor="@color/text_quad" />
2017-02-03 12:21:42 +00:00
<Button
2023-08-28 09:36:13 +00:00
android:id="@+id/gift_subscription_button"
android:layout_width="match_parent"
2020-09-29 10:48:20 +00:00
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:background="@color/transparent"
android:text="@string/gift_subscription"
android:textAllCaps="false"
2023-08-28 09:36:13 +00:00
android:textColor="@color/text_brand_neon" />
</LinearLayout>
2023-08-28 09:36:13 +00:00
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
2023-08-28 09:36:13 +00:00
android:background="?attr/colorWindowBackground">
<TextView
android:id="@+id/supportTextView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginTop="16dp"
android:drawablePadding="@dimen/spacing_medium"
android:gravity="center"
android:lineSpacingExtra="4dp"
android:paddingStart="16dp"
android:paddingTop="16dp"
android:paddingEnd="16dp"
android:paddingBottom="16dp"
android:text="@string/subscribe_title"
android:textColor="@color/text_quad"
android:textSize="14sp" />
</LinearLayout>
</LinearLayout>
2023-08-28 09:36:13 +00:00
</androidx.core.widget.NestedScrollView>
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>