Added emphasis on support section

This commit is contained in:
Viktor De Pasquale 2019-11-25 17:25:49 +01:00
parent cb59cc92a3
commit a20594ed48
4 changed files with 61 additions and 35 deletions

View File

@ -33,13 +33,14 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clipToPadding="false"
android:fillViewport="true"
android:paddingTop="@{viewModel.insets.top + (int) @dimen/internal_action_bar_size}"
android:paddingBottom="@{viewModel.insets.bottom + (int) @dimen/l2}"
tools:layout_marginTop="24dp">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_height="match_parent"
android:clipToPadding="false"
android:orientation="vertical"
android:paddingTop="@dimen/l1">
@ -739,40 +740,57 @@
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.appcompat.widget.AppCompatTextView
<com.google.android.material.card.MaterialCardView
style="@style/WidgetFoundation.Card.Primary"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="@dimen/l1"
android:layout_marginTop="@dimen/l2"
android:layout_marginEnd="@dimen/l1"
android:text="@string/home_support_title"
android:textAppearance="@style/AppearanceFoundation.Title" />
android:layout_gravity="bottom"
android:layout_margin="@dimen/l1">
<androidx.appcompat.widget.AppCompatTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="@dimen/l1"
android:layout_marginTop="@dimen/l_50"
android:layout_marginEnd="@dimen/l1"
android:text="@string/home_support_content"
android:textAppearance="@style/AppearanceFoundation.Caption.Variant" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingTop="@dimen/l1">
<androidx.recyclerview.widget.RecyclerView
dividerHorizontal="@{R.drawable.divider_l1}"
dividerVertical="@{R.drawable.divider_l1}"
itemBinding="@{viewModel.itemDeveloperBinding}"
items="@{viewModel.items}"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/l1"
android:clipToPadding="false"
android:orientation="horizontal"
android:overScrollMode="ifContentScrolls"
android:paddingStart="@dimen/l1"
app:layoutManager="androidx.recyclerview.widget.StaggeredGridLayoutManager"
app:spanCount="2"
tools:itemCount="3"
tools:listitem="@layout/item_developer" />
<androidx.appcompat.widget.AppCompatTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="@dimen/l1"
android:layout_marginEnd="@dimen/l1"
android:text="@string/home_support_title"
android:textAppearance="@style/AppearanceFoundation.Title.OnPrimary" />
<androidx.appcompat.widget.AppCompatTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="@dimen/l1"
android:layout_marginTop="@dimen/l_50"
android:layout_marginEnd="@dimen/l1"
android:text="@string/home_support_content"
android:textAppearance="@style/AppearanceFoundation.Caption.OnPrimary.Variant" />
<androidx.recyclerview.widget.RecyclerView
dividerHorizontal="@{R.drawable.divider_l1}"
dividerVertical="@{R.drawable.divider_l1}"
itemBinding="@{viewModel.itemDeveloperBinding}"
items="@{viewModel.items}"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/l1"
android:clipToPadding="false"
android:nestedScrollingEnabled="@{false}"
android:orientation="horizontal"
android:overScrollMode="ifContentScrolls"
android:paddingStart="@dimen/l1"
app:layoutManager="androidx.recyclerview.widget.StaggeredGridLayoutManager"
app:spanCount="2"
tools:itemCount="3"
tools:listitem="@layout/item_developer" />
</LinearLayout>
</com.google.android.material.card.MaterialCardView>
</LinearLayout>

View File

@ -21,7 +21,7 @@
tools:layout_gravity="center|start">
<com.google.android.material.card.MaterialCardView
style="@style/WidgetFoundation.Card"
style="@style/WidgetFoundation.Card.Secondary"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:layout_constrainedWidth="true"
@ -41,7 +41,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@{item.name}"
android:textAppearance="@style/AppearanceFoundation.Caption"
android:textAppearance="@style/AppearanceFoundation.Caption.OnPrimary"
android:textStyle="bold"
tools:text="\@topjohnwu" />

View File

@ -30,7 +30,7 @@
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:srcCompat="@{item.icon}"
app:tint="?colorOnSurface"
app:tint="?colorOnPrimary"
tools:srcCompat="@drawable/ic_paypal" />
<androidx.appcompat.widget.AppCompatImageView
@ -41,7 +41,7 @@
app:layout_constraintStart_toEndOf="@+id/developer_link"
app:layout_constraintTop_toTopOf="@+id/developer_link"
app:srcCompat="@drawable/ic_more"
app:tint="@color/color_text_transient" />
app:tint="?colorOnPrimary" />
</androidx.constraintlayout.widget.ConstraintLayout>

View File

@ -24,6 +24,14 @@
<item name="cardPreventCornerOverlap">true</item>
</style>
<style name="WidgetFoundation.Card.Primary">
<item name="cardBackgroundColor">?colorPrimary</item>
</style>
<style name="WidgetFoundation.Card.Secondary">
<item name="cardBackgroundColor">?colorSecondary</item>
</style>
<style name="WidgetFoundation.Card.Variant">
<item name="cardBackgroundColor">?colorSurface</item>
<item name="strokeColor">?colorSurfaceVariant</item>