[fenix] For https://github.com/mozilla-mobile/fenix/issues/24252 - Rename primaryText...
[gecko.git] / mobile / android / fenix / app / src / main / res / layout / fragment_search_dialog.xml
blob002fa2ef258d0d6db5060a0a36e290448cbee876
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 <org.mozilla.fenix.perf.SearchDialogFragmentConstraintLayout
6     xmlns:android="http://schemas.android.com/apk/res/android"
7     xmlns:tools="http://schemas.android.com/tools"
8     xmlns:app="http://schemas.android.com/apk/res-auto"
9     android:id="@+id/search_wrapper"
10     android:layout_width="match_parent"
11     android:layout_height="match_parent"
12     android:fitsSystemWindows="true"
13     android:background="?attr/scrimBackground">
14     <mozilla.components.browser.toolbar.BrowserToolbar
15         android:id="@+id/toolbar"
16         android:layout_width="0dp"
17         android:layout_height="@dimen/browser_toolbar_height"
18         android:background="@drawable/toolbar_background_top"
19         android:clickable="true"
20         android:focusable="true"
21         android:focusableInTouchMode="true"
22         app:layout_scrollFlags="scroll|enterAlways|snap|exitUntilCollapsed"
23         app:browserToolbarClearColor="?attr/textPrimary"
24         app:browserToolbarInsecureColor="?attr/textPrimary"
25         app:browserToolbarMenuColor="?attr/textPrimary"
26         app:browserToolbarProgressBarGravity="bottom"
27         app:browserToolbarSecureColor="?attr/textPrimary"
28         app:browserToolbarTrackingProtectionAndSecurityIndicatorSeparatorColor="?borderPrimary"
29         app:layout_constraintEnd_toEndOf="parent"
30         app:layout_constraintStart_toStartOf="parent"
31         app:layout_constraintTop_toTopOf="parent"/>
33     <ViewStub
34         android:id="@+id/search_suggestions_hint"
35         android:layout_width="0dp"
36         android:layout_height="0dp"
37         android:inflatedId="@id/search_suggestions_hint"
38         android:layout="@layout/search_suggestions_hint"
39         app:layout_constraintBottom_toTopOf="@id/search_hint_bottom_barrier"
40         app:layout_constraintEnd_toEndOf="parent"
41         app:layout_constraintStart_toStartOf="parent"
42         app:layout_constraintTop_toBottomOf="@id/toolbar"
43         app:layout_constraintHeight_default="wrap"/>
45     <View
46         android:id="@+id/search_suggestions_hint_divider"
47         android:layout_width="match_parent"
48         android:layout_height="1dp"
49         android:background="?borderPrimary"
50         android:visibility="gone"
51         app:layout_constraintBottom_toBottomOf="@id/search_suggestions_hint"
52         app:layout_constraintEnd_toEndOf="parent"
53         app:layout_constraintStart_toStartOf="parent" />
55     <androidx.constraintlayout.widget.Barrier
56         android:id="@+id/search_hint_bottom_barrier"
57         android:layout_width="wrap_content"
58         android:layout_height="wrap_content"
59         app:barrierDirection="top"
60         app:constraint_referenced_ids="awesome_bar,pill_wrapper"/>
62     <org.mozilla.fenix.search.awesomebar.AwesomeBarWrapper
63         android:id="@+id/awesome_bar"
64         android:layout_width="0dp"
65         android:layout_height="0dp"
66         android:fadingEdge="horizontal"
67         android:fadingEdgeLength="40dp"
68         android:nestedScrollingEnabled="false"
69         android:requiresFadingEdge="vertical"
70         android:background="?attr/foundation"
71         android:visibility="invisible"
72         app:layout_constraintBottom_toTopOf="@+id/pill_wrapper"
73         app:layout_constraintEnd_toEndOf="parent"
74         app:layout_constraintStart_toStartOf="parent"
75         app:layout_constraintTop_toBottomOf="@id/search_suggestions_hint" />
77     <View
78         android:id="@+id/fill_link_from_clipboard"
79         android:layout_width="0dp"
80         android:layout_height="@dimen/search_fragment_clipboard_item_height"
81         android:background="?foundation"
82         android:clickable="true"
83         android:focusable="true"
84         android:visibility="gone"
85         app:layout_constraintEnd_toEndOf="parent"
86         app:layout_constraintStart_toStartOf="parent"
87         app:layout_constraintTop_toBottomOf="@+id/toolbar"
88         tools:visibility="visible" />
90     <ImageView
91         android:id="@+id/link_icon"
92         android:layout_width="wrap_content"
93         android:layout_height="wrap_content"
94         android:layout_marginStart="@dimen/search_fragment_clipboard_item_horizontal_margin"
95         android:clickable="false"
96         android:focusable="false"
97         android:importantForAccessibility="no"
98         android:visibility="gone"
99         app:layout_constraintBottom_toBottomOf="@+id/fill_link_from_clipboard"
100         app:layout_constraintStart_toStartOf="@+id/fill_link_from_clipboard"
101         app:layout_constraintTop_toTopOf="@+id/fill_link_from_clipboard"
102         app:srcCompat="@drawable/ic_link"
103         tools:visibility="visible" />
105     <TextView
106         android:id="@+id/clipboard_title"
107         style="@style/SearchClipboardTitleStyle"
108         android:layout_width="0dp"
109         android:layout_height="wrap_content"
110         android:layout_marginStart="@dimen/search_fragment_clipboard_item_title_margin_start"
111         android:layout_marginEnd="@dimen/search_fragment_clipboard_item_horizontal_margin"
112         android:clickable="false"
113         android:focusable="false"
114         android:importantForAccessibility="no"
115         android:text="@string/awesomebar_clipboard_title"
116         android:visibility="gone"
117         app:layout_constraintBottom_toTopOf="@id/clipboard_url"
118         app:layout_constraintEnd_toEndOf="@+id/fill_link_from_clipboard"
119         app:layout_constraintStart_toEndOf="@id/link_icon"
120         app:layout_constraintTop_toTopOf="@id/fill_link_from_clipboard"
121         app:layout_constraintVertical_chainStyle="packed"
122         tools:text="Title"
123         tools:visibility="visible" />
125     <TextView
126         android:id="@+id/clipboard_url"
127         style="@style/SearchClipboardUrlStyle"
128         android:layout_width="0dp"
129         android:layout_height="wrap_content"
130         android:layout_marginStart="@dimen/search_fragment_clipboard_item_title_margin_start"
131         android:layout_marginEnd="@dimen/search_fragment_clipboard_item_horizontal_margin"
132         android:clickable="false"
133         android:focusable="false"
134         android:importantForAccessibility="no"
135         android:visibility="gone"
136         app:layout_constraintBottom_toBottomOf="@+id/fill_link_from_clipboard"
137         app:layout_constraintEnd_toEndOf="@+id/fill_link_from_clipboard"
138         app:layout_constraintStart_toEndOf="@id/link_icon"
139         app:layout_constraintTop_toBottomOf="@id/clipboard_title"
140         app:layout_constraintVertical_chainStyle="packed"
141         tools:text="url"
142         tools:visibility="visible" />
144     <View
145         android:id="@+id/fill_link_divider"
146         android:layout_width="match_parent"
147         android:layout_height="1dp"
148         android:background="?borderPrimary"
149         app:layout_constraintTop_toBottomOf="@id/fill_link_from_clipboard" />
151     <View
152         android:id="@+id/pill_wrapper_divider"
153         android:layout_width="match_parent"
154         android:layout_height="1dp"
155         android:background="?borderPrimary"
156         app:layout_constraintBottom_toTopOf="@id/pill_wrapper" />
158     <View
159         android:id="@+id/pill_wrapper"
160         android:layout_width="0dp"
161         android:layout_height="@dimen/search_fragment_pill_height"
162         android:background="?foundation"
163         android:importantForAccessibility="no"
164         android:paddingStart="@dimen/search_fragment_pill_padding_start"
165         android:paddingTop="@dimen/search_fragment_pill_padding_vertical"
166         android:paddingEnd="@dimen/search_fragment_pill_padding_end"
167         android:paddingBottom="@dimen/search_fragment_pill_padding_vertical"
168         app:layout_constraintBottom_toBottomOf="parent"
169         app:layout_constraintEnd_toEndOf="parent"
170         app:layout_constraintStart_toStartOf="parent" />
172     <ToggleButton
173         android:id="@+id/qr_scan_button"
174         style="@style/search_pill"
175         android:layout_marginEnd="@dimen/search_fragment_scan_button_margin_end"
176         android:textOff="@string/search_scan_button"
177         android:textOn="@string/search_scan_button"
178         app:drawableStartCompat="@drawable/ic_qr"
179         app:layout_constraintBottom_toBottomOf="@id/pill_wrapper"
180         app:layout_constraintStart_toStartOf="@id/pill_wrapper"
181         app:layout_constraintTop_toTopOf="@id/pill_wrapper" />
183     <ToggleButton
184         android:id="@+id/search_engines_shortcut_button"
185         style="@style/search_pill"
186         android:textOff="@string/search_engine_button"
187         android:textOn="@string/search_engine_button"
188         app:drawableStartCompat="@drawable/ic_search"
189         app:layout_constraintBottom_toBottomOf="@id/pill_wrapper"
190         app:layout_constraintStart_toEndOf="@id/qr_scan_button"
191         app:layout_constraintTop_toTopOf="@id/pill_wrapper" />
192 </org.mozilla.fenix.perf.SearchDialogFragmentConstraintLayout>