activity_main.xml 9.52 KB
Newer Older
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
<?xml version="1.0" encoding="utf-8"?>
<androidx.core.widget.NestedScrollView xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    tools:context=".MainActivity">

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:orientation="vertical"
        android:padding="20dp">

        <com.google.android.material.textfield.TextInputLayout
Javokhir's avatar
2.1.1    
Javokhir committed
16
17
18
            style="@style/Widget.Material3.TextInputLayout.OutlinedBox"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
19
20
21
22
23
24
            android:hint="@string/client_id"
            app:helperText="* Required"
            app:helperTextEnabled="true">

            <com.google.android.material.textfield.TextInputEditText
                android:id="@+id/inputClientId"
Javokhir's avatar
2.1.1    
Javokhir committed
25
26
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
27
                android:importantForAutofill="no"
Javokhir's avatar
2.1.1    
Javokhir committed
28
29
                android:inputType="textMultiLine"
                android:textAppearance="@style/TextAppearance.Material3.BodyLarge" />
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
30
31
32
        </com.google.android.material.textfield.TextInputLayout>

        <com.google.android.material.textfield.TextInputLayout
Javokhir's avatar
2.1.1    
Javokhir committed
33
34
35
            style="@style/Widget.Material3.TextInputLayout.OutlinedBox"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
36
37
38
39
40
41
42
            android:layout_marginTop="12dp"
            android:hint="@string/passport"
            app:helperText="* Optional"
            app:helperTextEnabled="true">

            <com.google.android.material.textfield.TextInputEditText
                android:id="@+id/inputPassportData"
Javokhir's avatar
2.1.1    
Javokhir committed
43
44
45
46
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:importantForAutofill="no"
                android:textAppearance="@style/TextAppearance.Material3.BodyLarge" />
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
47
48
49
        </com.google.android.material.textfield.TextInputLayout>

        <com.google.android.material.textfield.TextInputLayout
Javokhir's avatar
2.1.1    
Javokhir committed
50
51
52
            style="@style/Widget.Material3.TextInputLayout.OutlinedBox"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
53
54
55
56
57
58
59
60
            android:layout_marginTop="12dp"
            android:hint="@string/birth_date"
            app:helperText="* Optional"
            app:helperTextEnabled="true"
            app:placeholderText="дд.мм.гггг">

            <com.google.android.material.textfield.TextInputEditText
                android:id="@+id/inputDate"
Javokhir's avatar
2.1.1    
Javokhir committed
61
62
63
64
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:importantForAutofill="no"
                android:textAppearance="@style/TextAppearance.Material3.BodyLarge" />
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
65
66
67
        </com.google.android.material.textfield.TextInputLayout>

        <com.google.android.material.textfield.TextInputLayout
Javokhir's avatar
2.1.1    
Javokhir committed
68
69
70
            style="@style/Widget.Material3.TextInputLayout.OutlinedBox"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
71
72
73
74
75
76
77
            android:layout_marginTop="12dp"
            android:hint="@string/external_id"
            app:helperText="* Optional"
            app:helperTextEnabled="true">

            <com.google.android.material.textfield.TextInputEditText
                android:id="@+id/inputExternalId"
Javokhir's avatar
2.1.1    
Javokhir committed
78
79
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
80
                android:importantForAutofill="no"
Javokhir's avatar
2.1.1    
Javokhir committed
81
82
                android:inputType="textMultiLine"
                android:textAppearance="@style/TextAppearance.Material3.BodyLarge" />
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
83
84
        </com.google.android.material.textfield.TextInputLayout>

Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
85
        <com.google.android.material.textfield.TextInputLayout
Javokhir's avatar
2.1.1    
Javokhir committed
86
87
88
            style="@style/Widget.Material3.TextInputLayout.OutlinedBox"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
89
90
91
92
93
94
95
            android:layout_marginTop="12dp"
            android:hint="@string/organization_phone_number"
            app:helperText="* Optional"
            app:helperTextEnabled="true">

            <com.google.android.material.textfield.TextInputEditText
                android:id="@+id/inputPhoneNumber"
Javokhir's avatar
2.1.1    
Javokhir committed
96
97
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
98
                android:importantForAutofill="no"
Javokhir's avatar
2.1.1    
Javokhir committed
99
100
                android:inputType="phone"
                android:textAppearance="@style/TextAppearance.Material3.BodyLarge" />
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
        </com.google.android.material.textfield.TextInputLayout>

        <TextView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="16dp"
            android:text="@string/threshold"
            android:textSize="16sp" />

        <com.google.android.material.slider.Slider
            android:id="@+id/thresholdSlider"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:stepSize="0.01"
            android:valueFrom="0.50"
            android:valueTo="0.99"
            app:labelBehavior="floating" />

Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
119
120
121
122
        <RadioGroup
            android:id="@+id/radioGroupLang"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
123
            android:layout_marginTop="8dp"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
124
            android:checkedButton="@id/radioEn"
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
125
            android:orientation="horizontal">
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
126
127
128
129
130
131
132
133
134
135
136

            <RadioButton
                android:id="@+id/radioUz"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="@string/uzbek" />

            <RadioButton
                android:id="@+id/radioEn"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
137
                android:layout_marginStart="12dp"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
138
139
140
141
142
143
                android:text="@string/english" />

            <RadioButton
                android:id="@+id/radioRu"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
144
                android:layout_marginStart="12dp"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
145
146
147
148
                android:text="@string/russian" />
        </RadioGroup>

        <RadioGroup
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
149
            android:id="@+id/radioGroupEntryType"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
150
151
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
152
            android:layout_marginTop="8dp"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
153
154
155
156
157
158
159
160
161
162
163
164
165
            android:checkedButton="@id/radioAuth"
            android:orientation="horizontal">

            <RadioButton
                android:id="@+id/radioAuth"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="@string/auth" />

            <RadioButton
                android:id="@+id/radioFace"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
166
                android:layout_marginStart="12dp"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
167
168
169
170
                android:text="@string/face" />
        </RadioGroup>

        <RadioGroup
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
171
            android:id="@+id/radioGroupBuildMode"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
172
173
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
174
            android:layout_marginTop="8dp"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
            android:checkedButton="@id/radioProd"
            android:orientation="horizontal">

            <RadioButton
                android:id="@+id/radioProd"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="@string/prod" />

            <RadioButton
                android:id="@+id/radioDev"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginStart="16dp"
                android:text="@string/dev" />
        </RadioGroup>

Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
192
193
194
        <CheckBox
            android:id="@+id/checkboxWithPhoto"
            android:layout_width="match_parent"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
195
            android:layout_height="wrap_content"
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
196
197
198
            android:layout_marginTop="8dp"
            android:checked="true"
            android:text="@string/with_photo" />
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
199
200
201

        <com.google.android.material.button.MaterialButton
            android:id="@+id/buttonStart"
Javokhir's avatar
2.1.1    
Javokhir committed
202
            style="@style/Widget.Material3.Button.UnelevatedButton"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
203
204
205
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_gravity="center"
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
206
            android:layout_marginTop="20dp"
Javokhir's avatar
2.1.1    
Javokhir committed
207
208
            android:text="@string/scan_face_data"
            android:textAppearance="@style/TextAppearance.Material3.BodyLarge" />
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
209
210
211
212
213

        <TextView
            android:id="@+id/textResult"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
214
            android:layout_marginTop="20dp"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
215
216
217
218
219
            android:textSize="20sp" />

        <TextView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
Javohir Savriy's avatar
2.0.9    
Javohir Savriy committed
220
            android:layout_marginTop="20dp"
Javokhir Savriev's avatar
2.0.7  
Javokhir Savriev committed
221
222
223
224
225
226
227
228
229
230
231
            android:text="@string/result_image"
            android:textSize="20sp" />

        <ImageView
            android:id="@+id/imageResult"
            android:layout_width="200dp"
            android:layout_height="200dp"
            android:layout_marginTop="16dp"
            android:contentDescription="@string/image" />
    </LinearLayout>
</androidx.core.widget.NestedScrollView>