[fenix] For https://github.com/mozilla-mobile/fenix/issues/24252 - Rename primaryText...
[gecko.git] / mobile / android / fenix / app / src / main / res / layout / component_collection_creation.xml
blob098f88496725518c2793e39190517a03a5b9488d
1 <?xml version="1.0" encoding="utf-8"?>
2 <!-- This Source Code Form is subject to the terms of the Mozilla Public
3    - License, v. 2.0. If a copy of the MPL was not distributed with this
4    - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
5 <androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
6     xmlns:app="http://schemas.android.com/apk/res-auto"
7     xmlns:tools="http://schemas.android.com/tools"
8     android:id="@+id/collection_constraint_layout"
9     android:layout_width="match_parent"
10     android:layout_height="match_parent"
11     android:clipToPadding="false">
13     <Button
14         android:id="@+id/back_button"
15         android:layout_width="0dp"
16         android:layout_height="wrap_content"
17         android:background="?android:attr/selectableItemBackgroundBorderless"
18         android:drawablePadding="8dp"
19         android:gravity="start|center_vertical"
20         android:paddingStart="16dp"
21         android:paddingTop="16dp"
22         android:paddingEnd="8dp"
23         android:paddingBottom="16dp"
24         android:text="@string/create_collection_select_tabs"
25         android:textAppearance="@style/HeaderTextStyle"
26         android:textColor="@color/fx_mobile_text_color_oncolor_primary"
27         android:textSize="20sp"
28         app:drawableStartCompat="@drawable/mozac_ic_back"
29         app:drawableTint="@color/fx_mobile_icon_color_oncolor"
30         app:layout_constraintEnd_toStartOf="@+id/guideline"
31         app:layout_constraintHorizontal_bias="0"
32         app:layout_constraintStart_toStartOf="parent"
33         app:layout_constraintTop_toTopOf="parent"
34         app:layout_constraintWidth_default="wrap"
35         tools:ignore="ButtonStyleXmlDetector" />
37     <Button
38         android:id="@+id/select_all_button"
39         android:layout_width="0dp"
40         android:layout_height="0dp"
41         android:background="?android:attr/selectableItemBackgroundBorderless"
42         android:fontFamily="@font/metropolis_bold"
43         android:gravity="start|center_vertical"
44         android:paddingStart="8dp"
45         android:paddingTop="16dp"
46         android:paddingEnd="16dp"
47         android:paddingBottom="16dp"
48         android:text="@string/create_collection_select_all"
49         android:textAllCaps="false"
50         android:textColor="@color/fx_mobile_text_color_oncolor_primary"
51         android:textSize="16sp"
52         app:layout_constraintBottom_toBottomOf="@id/back_button"
53         app:layout_constraintEnd_toEndOf="parent"
54         app:layout_constraintHorizontal_bias="1"
55         app:layout_constraintStart_toEndOf="@+id/guideline"
56         app:layout_constraintTop_toTopOf="parent"
57         app:layout_constraintWidth_default="wrap"
58         tools:ignore="ButtonStyleXmlDetector" />
60     <androidx.constraintlayout.widget.Guideline
61         android:id="@+id/guideline"
62         android:layout_width="wrap_content"
63         android:layout_height="wrap_content"
64         android:orientation="vertical"
65         app:layout_constraintGuide_percent="0.5" />
67     <androidx.recyclerview.widget.RecyclerView
68         android:id="@+id/collections_list"
69         android:layout_width="0dp"
70         android:layout_height="0dp"
71         android:layout_marginStart="@dimen/component_collection_creation_list_margin"
72         android:layout_marginTop="@dimen/component_collection_creation_list_margin"
73         android:layout_marginEnd="@dimen/component_collection_creation_list_margin"
74         android:visibility="gone"
75         app:layout_constraintBottom_toTopOf="@id/bottom_button_bar_layout"
76         app:layout_constraintEnd_toEndOf="parent"
77         app:layout_constraintStart_toStartOf="parent"
78         app:layout_constraintTop_toBottomOf="@id/back_button"
79         tools:listitem="@layout/collections_list_item" />
81     <androidx.recyclerview.widget.RecyclerView
82         android:id="@+id/tab_list"
83         android:layout_width="0dp"
84         android:layout_height="0dp"
85         android:layout_marginStart="@dimen/component_collection_creation_list_margin"
86         android:layout_marginTop="@dimen/component_collection_creation_list_margin"
87         android:layout_marginEnd="@dimen/component_collection_creation_list_margin"
88         app:layout_constraintBottom_toTopOf="@id/bottom_button_bar_layout"
89         app:layout_constraintEnd_toEndOf="parent"
90         app:layout_constraintStart_toStartOf="parent"
91         app:layout_constraintTop_toBottomOf="@id/back_button"
92         tools:listitem="@layout/collection_tab_list_row" />
94     <View
95         android:id="@+id/tab_list_dim"
96         android:layout_width="0dp"
97         android:layout_height="0dp"
98         android:alpha="0"
99         android:background="?scrim"
100         android:visibility="gone"
101         app:layout_constraintBottom_toBottomOf="@id/tab_list"
102         app:layout_constraintEnd_toEndOf="parent"
103         app:layout_constraintStart_toStartOf="parent"
104         app:layout_constraintTop_toTopOf="parent" />
106     <View
107         android:id="@+id/bottom_gradient"
108         android:layout_width="match_parent"
109         android:layout_height="102dp"
110         android:background="@drawable/simple_dark_grey_gradient"
111         android:focusable="false"
112         app:layout_constraintBottom_toBottomOf="parent" />
114     <EditText
115         android:id="@+id/name_collection_edittext"
116         android:layout_width="match_parent"
117         android:layout_height="wrap_content"
118         android:layout_gravity="bottom|center"
119         android:autofillHints="false"
120         android:background="?foundation"
121         android:focusedByDefault="true"
122         android:hint="@string/collection_name_hint"
123         android:imeOptions="actionDone"
124         android:importantForAutofill="no"
125         android:inputType="textCapSentences"
126         android:paddingStart="20dp"
127         android:paddingTop="12dp"
128         android:paddingEnd="20dp"
129         android:paddingBottom="12dp"
130         android:text="@string/create_collection_default_name"
131         android:textColor="?attr/textPrimary"
132         android:textSize="16sp"
133         android:visibility="gone"
134         app:layout_constraintBottom_toBottomOf="parent"
135         tools:targetApi="o" />
137     <androidx.constraintlayout.widget.ConstraintLayout
138         android:id="@+id/bottom_button_bar_layout"
139         android:layout_width="match_parent"
140         android:layout_height="wrap_content"
141         android:layout_margin="16dp"
142         android:background="@drawable/add_tabs_to_collection_background"
143         android:clipToPadding="false"
144         android:foreground="@drawable/rounded_ripple"
145         app:layout_constraintBottom_toBottomOf="parent"
146         app:layout_constraintEnd_toEndOf="parent"
147         app:layout_constraintStart_toStartOf="parent">
149         <ImageButton
150             android:id="@+id/bottom_bar_icon_button"
151             android:layout_width="wrap_content"
152             android:layout_height="wrap_content"
153             android:background="?android:attr/selectableItemBackground"
154             android:contentDescription="@string/create_collection_close"
155             android:padding="16dp"
156             app:layout_constraintBottom_toBottomOf="parent"
157             app:layout_constraintStart_toStartOf="parent"
158             app:layout_constraintTop_toTopOf="parent"
159             app:srcCompat="@drawable/ic_close"
160             app:tint="?iconOnColor" />
162         <TextView
163             android:id="@+id/bottom_bar_text"
164             android:layout_width="0dp"
165             android:layout_height="0dp"
166             android:fontFamily="@font/metropolis_semibold"
167             android:gravity="center_vertical"
168             android:text="@string/create_collection_save_to_collection_empty"
169             android:textColor="?textActionPrimary"
170             android:textSize="16sp"
171             app:layout_constraintBottom_toBottomOf="parent"
172             app:layout_constraintEnd_toStartOf="@id/save_button"
173             app:layout_constraintStart_toEndOf="@id/bottom_bar_icon_button"
174             app:layout_constraintTop_toTopOf="parent" />
176         <com.google.android.material.button.MaterialButton
177             android:id="@+id/save_button"
178             style="@style/Widget.MaterialComponents.Button.TextButton"
179             android:layout_width="wrap_content"
180             android:layout_height="wrap_content"
181             android:background="?android:attr/selectableItemBackground"
182             android:text="@string/create_collection_save"
183             android:textColor="?textActionPrimary"
184             app:fontFamily="@font/metropolis_medium"
185             app:layout_constraintBottom_toBottomOf="parent"
186             app:layout_constraintEnd_toEndOf="parent"
187             app:layout_constraintTop_toTopOf="parent" />
188     </androidx.constraintlayout.widget.ConstraintLayout>
189 </androidx.constraintlayout.widget.ConstraintLayout>