<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright 2020 The Chromium Authors
Use of this source code is governed by a BSD-style license that can be
found in the LICENSE file.
-->
<org.chromium.components.browser_ui.widget.promo.PromoCardView
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="wrap_content"
style="@style/MaterialCardStyle">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingTop="@dimen/promo_compact_padding"
android:paddingHorizontal="@dimen/promo_compact_padding"
android:paddingBottom="@dimen/promo_compact_padding_bottom">
<!-- Promo Header-->
<LinearLayout
android:id="@+id/promo_header"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_marginBottom="@dimen/promo_compact_header_margin_vertical">
<ImageView
android:id="@+id/promo_image"
android:layout_width="@dimen/promo_image_size"
android:layout_height="@dimen/promo_image_size"
android:layout_gravity="top"
android:scaleType="fitCenter"
android:importantForAccessibility="no" />
<LinearLayout
android:id="@+id/promo_text_group"
android:layout_height="wrap_content"
android:layout_width="match_parent"
android:layout_marginStart="@dimen/promo_compact_header_margin_vertical"
android:orientation="vertical">
<org.chromium.ui.widget.TextViewWithLeading
android:id="@+id/promo_title"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textAppearance="@style/TextAppearance.TextLarge.Primary"
android:layout_marginBottom="@dimen/promo_between_text_margin"
app:leading="@dimen/text_size_large_leading"/>
<org.chromium.ui.widget.TextViewWithLeading
android:id="@+id/promo_description"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textAppearance="@style/TextAppearance.TextSmall.Secondary"
app:leading="@dimen/text_size_small_leading"/>
</LinearLayout>
</LinearLayout>
<org.chromium.components.browser_ui.widget.DualControlLayout
android:id="@+id/promo_button_group"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:buttonAlignment="end">
<org.chromium.ui.widget.ButtonCompat
android:id="@+id/promo_primary_button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:singleLine="true"
android:ellipsize="end"
android:layout_gravity="top|end"
style="@style/FilledButton" />
<org.chromium.ui.widget.ButtonCompat
android:id="@+id/promo_secondary_button"
style="@style/TextButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:ellipsize="end"
android:singleLine="true"/>
</org.chromium.components.browser_ui.widget.DualControlLayout>
</LinearLayout>
</org.chromium.components.browser_ui.widget.promo.PromoCardView>