Browse code

Initial commit (losing old history)

Dario Rodriguez authored on 08/04/2026 17:25:38
Showing 1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,192 @@
1
+<?xml version="1.0" encoding="utf-8"?><!--
2
+  ~ Copyright (c) 2023 Samson Achiaga
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
+<layout xmlns:android="http://schemas.android.com/apk/res/android"
18
+    xmlns:app="http://schemas.android.com/apk/res-auto"
19
+    xmlns:tools="http://schemas.android.com/tools">
20
+
21
+    <data>
22
+
23
+        <import type="androidx.databinding.ObservableField" />
24
+
25
+        <import type="com.certified.audionote.utils.UIState" />
26
+
27
+        <variable
28
+            name="uiState"
29
+            type="UIState" />
30
+
31
+        <variable
32
+            name="viewModel"
33
+            type="com.certified.audionote.ui.NotesViewModel" />
34
+    </data>
35
+
36
+    <androidx.coordinatorlayout.widget.CoordinatorLayout
37
+        android:layout_width="match_parent"
38
+        android:background="@color/fragment_background"
39
+        android:layout_height="match_parent">
40
+
41
+        <androidx.constraintlayout.widget.ConstraintLayout
42
+            android:layout_width="match_parent"
43
+            android:layout_height="match_parent"
44
+            tools:context=".ui.HomeFragment">
45
+
46
+                <androidx.appcompat.widget.AppCompatImageButton
47
+                    android:id="@+id/btn_settings"
48
+                    android:background="@null"
49
+                    android:padding="@dimen/_4sdp"
50
+                    android:layout_width="wrap_content"
51
+                    android:layout_height="wrap_content"
52
+                    android:layout_gravity="center"
53
+                    android:tint="@color/black_day_white_night"
54
+                    app:srcCompat="@drawable/ic_settings_black_24dp"
55
+                    app:layout_constraintBottom_toBottomOf="@+id/materialTextView3"
56
+                    app:layout_constraintEnd_toEndOf="@+id/fab_add_note"
57
+                    app:layout_constraintTop_toTopOf="@+id/materialTextView2" />
58
+
59
+            <com.google.android.material.textview.MaterialTextView
60
+                android:id="@+id/materialTextView2"
61
+                android:layout_width="wrap_content"
62
+                android:layout_height="wrap_content"
63
+                android:layout_marginStart="@dimen/_16sdp"
64
+                android:layout_marginTop="@dimen/_16sdp"
65
+                android:text="@string/hi_there"
66
+                android:textSize="@dimen/_18ssp"
67
+                android:textColor="@color/black_day_white_night"
68
+                android:fontFamily="@font/open_sans_bold"
69
+                app:layout_constraintStart_toStartOf="parent"
70
+                app:layout_constraintTop_toTopOf="parent" />
71
+
72
+            <com.google.android.material.textview.MaterialTextView
73
+                android:id="@+id/materialTextView3"
74
+                android:layout_width="wrap_content"
75
+                android:layout_height="wrap_content"
76
+                android:alpha=".7"
77
+                android:text="@string/welcome_back"
78
+                android:fontFamily="@font/open_sans_medium"
79
+                android:textSize="@dimen/_12ssp"
80
+                app:layout_constraintStart_toStartOf="@+id/materialTextView2"
81
+                app:layout_constraintTop_toBottomOf="@+id/materialTextView2" />
82
+
83
+            <androidx.recyclerview.widget.RecyclerView
84
+                android:id="@+id/recycler_view_notes"
85
+                android:layout_width="0dp"
86
+                android:layout_height="0dp"
87
+                android:layout_marginTop="@dimen/_16sdp"
88
+                android:layout_marginStart="@dimen/_8sdp"
89
+                android:layout_marginEnd="@dimen/_8sdp"
90
+                app:layout_constraintBottom_toBottomOf="parent"
91
+                app:layout_constraintEnd_toEndOf="parent"
92
+                app:layout_constraintStart_toStartOf="parent"
93
+                app:layout_constraintTop_toBottomOf="@+id/materialTextView3"
94
+                app:listItems="@{viewModel.notes}"
95
+                app:visible="@{viewModel.uiState == UIState.HAS_DATA}"
96
+                tools:listitem="@layout/item_note" />
97
+
98
+<!--            <com.google.android.material.textview.MaterialTextView-->
99
+<!--                android:id="@+id/materialTextView"-->
100
+<!--                android:layout_width="0dp"-->
101
+<!--                android:textColor="@color/titleText"-->
102
+<!--                android:layout_marginEnd="@dimen/_16sdp"-->
103
+<!--                android:layout_marginStart="@dimen/_16sdp"-->
104
+<!--                android:layout_height="wrap_content"-->
105
+<!--                android:text="“The more that you read, the more things you will know, the more that you learn, the more places you’ll go.”"-->
106
+<!--                android:textAlignment="center"-->
107
+<!--                android:alpha=".7"-->
108
+<!--                android:textSize="@dimen/_14ssp"-->
109
+<!--                android:fontFamily="@font/open_sans_medium_italic"-->
110
+<!--                app:layout_constraintBottom_toTopOf="@+id/materialTextView4"-->
111
+<!--                app:layout_constraintEnd_toEndOf="parent"-->
112
+<!--                app:layout_constraintHorizontal_bias="0.5"-->
113
+<!--                app:layout_constraintStart_toStartOf="parent"-->
114
+<!--                app:layout_constraintTop_toTopOf="parent"-->
115
+<!--                app:layout_constraintVertical_chainStyle="packed" />-->
116
+
117
+<!--            <com.google.android.material.textview.MaterialTextView-->
118
+<!--                android:id="@+id/materialTextView4"-->
119
+<!--                android:layout_width="wrap_content"-->
120
+<!--                android:layout_height="wrap_content"-->
121
+<!--                android:text="– Dr. Seuss"-->
122
+<!--                android:scrollbarSize="@dimen/_18ssp"-->
123
+<!--                android:textColor="@color/titleText"-->
124
+<!--                android:fontFamily="@font/open_sans_bold_italic"-->
125
+<!--                android:textSize="@dimen/_18ssp"-->
126
+<!--                app:layout_constraintBottom_toBottomOf="parent"-->
127
+<!--                app:layout_constraintEnd_toEndOf="@+id/materialTextView"-->
128
+<!--                app:layout_constraintHorizontal_bias="0.5"-->
129
+<!--                app:layout_constraintStart_toStartOf="@+id/materialTextView"-->
130
+<!--                app:layout_constraintTop_toBottomOf="@+id/materialTextView" />-->
131
+
132
+            <androidx.appcompat.widget.AppCompatImageView
133
+                android:id="@+id/iv_empty_notes"
134
+                android:layout_width="0dp"
135
+                android:layout_height="0dp"
136
+                android:layout_margin="@dimen/_16sdp"
137
+                android:src="@drawable/ic_undraw_empty"
138
+                app:layout_constraintBottom_toTopOf="@+id/fab_add_note"
139
+                app:layout_constraintEnd_toEndOf="@+id/fab_add_note"
140
+                app:layout_constraintHorizontal_bias="1.0"
141
+                app:layout_constraintStart_toStartOf="@+id/materialTextView3"
142
+                app:layout_constraintTop_toBottomOf="@+id/materialTextView3"
143
+                app:layout_constraintVertical_bias="1.0" />
144
+
145
+            <com.google.android.material.textview.MaterialTextView
146
+                android:id="@+id/tv_empty_notes"
147
+                android:layout_width="wrap_content"
148
+                android:layout_height="wrap_content"
149
+                android:layout_marginBottom="@dimen/_8sdp"
150
+                android:alpha=".7"
151
+                app:fontFamily="@font/open_sans_semi_bold"
152
+                android:textColor="@color/titleText"
153
+                android:paddingStart="@dimen/_16sdp"
154
+                android:paddingEnd="@dimen/_16sdp"
155
+                android:text="@string/your_record_list_is_empty_click_the_button_below_to_get_started"
156
+                android:textAlignment="center"
157
+                android:textSize="@dimen/_12ssp"
158
+                android:fontFamily="@font/open_sans_regular"
159
+                app:layout_constraintBottom_toBottomOf="@+id/iv_empty_notes"
160
+                app:layout_constraintEnd_toEndOf="@+id/iv_empty_notes"
161
+                app:layout_constraintStart_toStartOf="@+id/iv_empty_notes" />
162
+
163
+            <androidx.constraintlayout.widget.Group
164
+                android:id="@+id/group_empty_notes"
165
+                android:layout_width="wrap_content"
166
+                android:layout_height="wrap_content"
167
+                android:visibility="visible"
168
+                app:constraint_referenced_ids="iv_empty_notes, tv_empty_notes"
169
+                app:visible="@{viewModel.uiState == UIState.EMPTY}" />
170
+
171
+            <com.google.android.material.floatingactionbutton.FloatingActionButton
172
+                android:id="@+id/fab_add_note"
173
+                android:layout_width="wrap_content"
174
+                android:layout_height="wrap_content"
175
+                android:layout_marginEnd="@dimen/_16sdp"
176
+                android:layout_marginBottom="@dimen/_16sdp"
177
+                android:backgroundTint="@color/fab_background_tint"
178
+                android:contentDescription="@string/add_note_button"
179
+                app:iconSize="@dimen/_27sdp"
180
+                app:layout_constraintBottom_toBottomOf="parent"
181
+                app:layout_constraintEnd_toEndOf="parent"
182
+                app:srcCompat="@drawable/ic_mic_black_24dp" />
183
+
184
+        </androidx.constraintlayout.widget.ConstraintLayout>
185
+
186
+        <include
187
+            android:visibility="gone"
188
+            android:id="@+id/bottom_sheet_dialog_layout"
189
+            layout="@layout/bottom_sheet_dialog" />
190
+
191
+    </androidx.coordinatorlayout.widget.CoordinatorLayout>
192
+</layout>
0 193
\ No newline at end of file