1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (C) 2022 The Android Open Source Project
3
4     Licensed under the Apache License, Version 2.0 (the "License");
5     you may not use this file except in compliance with the License.
6     You may obtain a copy of the License at
7
8          http://www.apache.org/licenses/LICENSE-2.0
9
10     Unless required by applicable law or agreed to in writing, software
11     distributed under the License is distributed on an "AS IS" BASIS,
12     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13     See the License for the specific language governing permissions and
14     limitations under the License.
15-->
16
17<androidx.constraintlayout.widget.ConstraintLayout
18    xmlns:android="http://schemas.android.com/apk/res/android"
19    xmlns:app="http://schemas.android.com/apk/res-auto"
20    xmlns:tools="http://schemas.android.com/tools"
21    android:id="@+id/notification_activity"
22    android:orientation="vertical"
23    android:layout_width="match_parent"
24    android:layout_height="match_parent" >
25    <ScrollView
26        android:id="@+id/notification_fragment_scrollview"
27        android:layout_width="match_parent"
28        android:layout_height="0dp"
29        android:scrollbars="vertical"
30        app:layout_constraintTop_toTopOf="parent"
31        app:layout_constraintBottom_toTopOf="@id/nav_buttons"
32        app:layout_constraintEnd_toEndOf="parent"
33        app:layout_constraintStart_toStartOf="parent" >
34        <LinearLayout
35            android:layout_height="wrap_content"
36            android:paddingStart="@dimen/adservices_content_horizontal_padding"
37            android:paddingEnd="@dimen/adservices_content_horizontal_padding"
38            android:paddingBottom="@dimen/adservices_content_padding"
39            android:orientation="vertical"
40            android:layout_gravity="center_horizontal"
41            style="@style/NotificationContainer">
42            <LinearLayout
43                android:layout_width="match_parent"
44                android:layout_height="wrap_content"
45                android:orientation="vertical">
46                <ImageView
47                    android:layout_width="wrap_content"
48                    android:layout_height="wrap_content"
49                    android:layout_marginTop="@dimen/adservices_content_3x_padding"
50                    android:layout_marginStart="0dp"
51                    android:src="@drawable/ic_android_icon"
52                    tools:ignore="ContentDescription" />
53                <TextView
54                    android:text="@string/notificationUI_header_ga_title"
55                    style="@style/MainStyle.H1" />
56
57            </LinearLayout>
58
59            <LinearLayout
60                android:id="@+id/container1"
61                android:layout_width="match_parent"
62                android:layout_height="wrap_content"
63                android:layout_marginTop="@dimen/adservices_content_two_thirds_padding"
64                android:orientation="vertical"
65                android:animateLayoutChanges="true">
66                <TextView
67                    android:layout_width="match_parent"
68                    android:layout_height="wrap_content"
69                    android:text="@string/notificationUI_container1_ga_introduction"
70                    style="@style/MainStyle.Body1"
71                    android:gravity="center_vertical" />
72                <TextView
73                    android:layout_width="match_parent"
74                    android:layout_height="wrap_content"
75                    android:text="@string/notificationUI_container2_ga_introduction"
76                    style="@style/MainStyle.Body1"
77                    android:gravity="center_vertical" />
78                <ImageView
79                    android:layout_width="match_parent"
80                    android:layout_height="wrap_content"
81                    android:layout_marginTop="@dimen/adservices_content_two_thirds_padding"
82                    android:src="@drawable/ic_consent_notification_ga_image"
83                    android:contentDescription="@string/ic_consent_notification_ga_image_description"/>
84                <TextView
85                    android:layout_width="match_parent"
86                    android:layout_height="wrap_content"
87                    android:layout_marginTop="@dimen/adservices_content_half_padding"
88                    android:text="@string/notificationUI_container3_ga_introduction"
89                    style="@style/MainStyle.Body1" />
90                <TextView
91                    android:id="@+id/how_it_works_expander"
92                    android:drawableEnd="@drawable/ic_expand"
93                    android:layout_marginTop="@dimen/adservices_content_two_thirds_padding"
94                    android:text="@string/notificationUI_ga_container1_control_text"
95                    style="@style/MainStyle.Body1" />
96                <LinearLayout
97                    android:id="@+id/how_it_works_expanded_text"
98                    android:layout_width="match_parent"
99                    android:layout_height="wrap_content"
100                    android:orientation="vertical"
101                    android:visibility="gone" >
102                    <TextView
103                        android:text="@string/notificationUI_how_it_works_row_subtitle1"
104                        style="@style/MainStyle.Body1Bold" />
105                    <TextView
106                        android:text="@string/notificationUI_how_it_works_row_body1"
107                        android:layout_marginTop="0dp"
108                        style="@style/MainStyle.Body1" />
109                    <TextView
110                        android:text="@string/notificationUI_how_it_works_row_body2"
111                        android:layout_marginTop="@dimen/adservices_content_three_quarter_padding"
112                        style="@style/MainStyle.Body1BulletSubtext" />
113                    <TextView
114                        android:text="@string/notificationUI_how_it_works_row_body3"
115                        android:layout_marginTop="@dimen/adservices_content_three_quarter_padding"
116                        style="@style/MainStyle.Body1BulletSubtext" />
117                    <TextView
118                        android:text="@string/notificationUI_how_it_works_row_body4"
119                        style="@style/MainStyle.Body1" />
120                    <TextView
121                        android:text="@string/notificationUI_how_it_works_row_body5"
122                        style="@style/MainStyle.Body1" />
123                    <TextView
124                        android:text="@string/notificationUI_how_it_works_subtitle2"
125                        style="@style/MainStyle.Body1Bold" />
126                    <TextView
127                        android:text="@string/notificationUI_how_it_works_row_body6"
128                        android:layout_marginTop="0dp"
129                        style="@style/MainStyle.Body1" />
130                    <TextView
131                        android:id="@+id/learn_more_from_privacy_policy"
132                        android:text="@string/notificationUI_how_it_works_row_body7"
133                        style="@style/MainStyle.Body1" />
134                </LinearLayout>
135            </LinearLayout>
136            <TextView
137                android:layout_width="match_parent"
138                android:layout_height="wrap_content"
139                android:layout_marginTop="@dimen/adservices_content_padding"
140                android:text="@string/notificationUI_you_can_change_in_privacy_settings"
141                style="@style/MainStyle.Body1" />
142        </LinearLayout>
143    </ScrollView>
144
145    <androidx.constraintlayout.widget.ConstraintLayout
146        android:id="@+id/nav_buttons"
147        android:layout_width="match_parent"
148        android:layout_height="wrap_content"
149        app:layout_constraintBottom_toBottomOf="parent"
150        app:layout_constraintEnd_toEndOf="parent"
151        app:layout_constraintStart_toStartOf="parent" >
152        <View
153            android:layout_width="match_parent"
154            android:layout_height="@dimen/adservices_divider_height"
155            android:background="@color/divider_color"
156            app:layout_constraintEnd_toEndOf="parent"
157            app:layout_constraintStart_toStartOf="parent"
158            app:layout_constraintTop_toTopOf="parent" />
159        <LinearLayout
160            style="@style/NotificationButtonContainer"
161            app:layout_constraintBottom_toBottomOf="parent"
162            app:layout_constraintEnd_toEndOf="parent"
163            app:layout_constraintStart_toStartOf="parent">
164            <Button
165                android:id="@+id/leftControlButton"
166                style="@style/MainStyle.PrimaryButtonNegative"
167                android:text="@string/notificationUI_left_control_button_text"
168                app:layout_constraintStart_toStartOf="parent"
169                app:layout_constraintTop_toTopOf="parent"/>
170            <Button
171                android:id="@+id/rightControlButton"
172                style="@style/MainStyle.PrimaryButton"
173                android:text="@string/notificationUI_right_control_button_text"
174                app:layout_constraintEnd_toEndOf="parent"
175                app:layout_constraintTop_toTopOf="parent" />
176        </LinearLayout>
177    </androidx.constraintlayout.widget.ConstraintLayout>
178</androidx.constraintlayout.widget.ConstraintLayout>
179