1<?xml version="1.0" encoding="utf-8"?>
2<!--
3    Copyright 2018 The Android Open Source Project
4
5    Licensed under the Apache License, Version 2.0 (the "License");
6    you may not use this file except in compliance with the License.
7    You may obtain a copy of the License at
8
9         http://www.apache.org/licenses/LICENSE-2.0
10
11    Unless required by applicable law or agreed to in writing, software
12    distributed under the License is distributed on an "AS IS" BASIS,
13    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14    See the License for the specific language governing permissions and
15    limitations under the License.
16-->
17
18<FrameLayout
19    xmlns:android="http://schemas.android.com/apk/res/android"
20    xmlns:app="http://schemas.android.com/apk/res-auto"
21    android:layout_width="match_parent"
22    android:layout_height="wrap_content"
23    android:layout_marginBottom="@dimen/suggestions_top_bottom_margin"
24    android:layout_marginTop="@dimen/suggestions_top_bottom_margin"
25    android:background="@android:color/transparent">
26    <androidx.cardview.widget.CardView
27        android:layout_width="match_parent"
28        android:layout_height="wrap_content"
29        android:foreground="?android:attr/selectableItemBackground"
30        app:cardCornerRadius="@dimen/suggestions_corner_radius">
31        <LinearLayout
32            android:layout_width="match_parent"
33            android:layout_height="wrap_content"
34            android:orientation="vertical">
35            <androidx.constraintlayout.widget.ConstraintLayout
36                android:layout_width="match_parent"
37                android:layout_height="wrap_content"
38                android:background="?attr/suggestionsPrimaryColor"
39                android:paddingBottom="@dimen/suggestions_text_padding_bottom"
40                android:paddingEnd="@dimen/suggestions_padding_end"
41                android:paddingStart="@dimen/suggestions_padding_start"
42                android:paddingTop="@dimen/suggestions_text_padding_top">
43                <TextView
44                    android:id="@android:id/title"
45                    android:layout_width="match_parent"
46                    android:layout_height="wrap_content"
47                    android:singleLine="true"
48                    android:textAppearance="?android:attr/textAppearanceLarge"
49                    app:layout_constraintStart_toStartOf="parent"
50                    app:layout_constraintTop_toTopOf="parent"/>
51                <TextView
52                    android:id="@android:id/summary"
53                    android:layout_width="match_parent"
54                    android:layout_height="wrap_content"
55                    android:layout_marginTop="@dimen/suggestions_subtext_margin_top"
56                    android:singleLine="true"
57                    android:textAppearance="?android:attr/textAppearanceMedium"
58                    app:layout_constraintStart_toStartOf="parent"
59                    app:layout_constraintTop_toBottomOf="@android:id/title"/>
60                <ImageView
61                    android:id="@android:id/icon"
62                    android:layout_width="@dimen/icon_size"
63                    android:layout_height="@dimen/icon_size"
64                    app:layout_constraintBottom_toBottomOf="parent"
65                    app:layout_constraintEnd_toEndOf="parent"
66                    app:layout_constraintTop_toTopOf="parent"/>
67            </androidx.constraintlayout.widget.ConstraintLayout>
68            <FrameLayout
69                android:layout_width="match_parent"
70                android:layout_height="@dimen/suggestions_action_bar_height"
71                android:background="?attr/suggestionsSecondaryColor"
72                android:paddingEnd="@dimen/suggestions_padding_end"
73                android:paddingStart="@dimen/suggestions_padding_start">
74                <Button
75                    android:id="@+id/dismiss_button"
76                    style="?android:attr/borderlessButtonStyle"
77                    android:layout_width="wrap_content"
78                    android:layout_height="wrap_content"
79                    android:layout_gravity="center_vertical"
80                    android:text="@string/suggestion_dismiss_button"
81                    android:textColor="?android:attr/textColorPrimary"/>
82            </FrameLayout>
83        </LinearLayout>
84    </androidx.cardview.widget.CardView>
85</FrameLayout>
86