diff --git a/app/src/main/java/com/example/nerbos/MainActivity.kt b/app/src/main/java/com/example/nerbos/MainActivity.kt index 7e20fe6bb5a6d5518bf8d2ec0cc7b3ee1ed679c2..9f596d308b126b1401bb36e5282a9fe325827998 100644 --- a/app/src/main/java/com/example/nerbos/MainActivity.kt +++ b/app/src/main/java/com/example/nerbos/MainActivity.kt @@ -85,7 +85,7 @@ class MainActivity : AppCompatActivity() { val item = binding.bottomNavigationView?.menu?.findItem(itemId) ?: binding.navigationView?.menu?.findItem(itemId) item?.let { - supportActionBar?.title = it.title + supportActionBar?.title = it.title.toString() + " " + getString(R.string.page) replaceFragment(fragments[itemId]!!) selectedItemId = itemId } diff --git a/app/src/main/java/com/example/nerbos/fragments/scan/ScanFragment.kt b/app/src/main/java/com/example/nerbos/fragments/scan/ScanFragment.kt index 81bedaa9f664cf07f7ec62551c6b819aba39ffb5..4af81759cb40252a0f6830f7ee81b691cd0e401f 100644 --- a/app/src/main/java/com/example/nerbos/fragments/scan/ScanFragment.kt +++ b/app/src/main/java/com/example/nerbos/fragments/scan/ScanFragment.kt @@ -200,7 +200,7 @@ class ScanFragment : Fragment() { private fun showImagePopup(imageBitmap: Bitmap?) { if (imageBitmap != null) { - MaterialAlertDialogBuilder(requireContext()) + MaterialAlertDialogBuilder(requireContext(), R.style.AlertDialogTheme) .setTitle("Use this picture?") .setPositiveButton("Yes") { dialog, _ -> val imageFile = File.createTempFile("image", ".jpg", requireContext().cacheDir) @@ -265,7 +265,7 @@ class ScanFragment : Fragment() { } } - val dialog = AlertDialog.Builder(requireContext()) + val dialog = AlertDialog.Builder(requireContext(), R.style.AlertDialogTheme) .setTitle("Transaction Input") .setView(dialogView) .setPositiveButton("OK") { _, _ -> @@ -297,7 +297,7 @@ class ScanFragment : Fragment() { } private fun showTransactionConfirmationDialog(responseBody: String?, transactionName: String, selectedTransactionType: String, totalNominal: Float, location: String, callback: (Boolean) -> Unit) { - val builder = AlertDialog.Builder(requireContext()) + val builder = AlertDialog.Builder(requireContext(), R.style.AlertDialogTheme) builder.setTitle("Confirm Transaction Details") // Parse the JSON response body to extract item details diff --git a/app/src/main/java/com/example/nerbos/fragments/transaction/TransactionAdapter.kt b/app/src/main/java/com/example/nerbos/fragments/transaction/TransactionAdapter.kt index ed2a20fef4bfa240321c5695349f046bcd3744a3..ce87d5fde0ec005e9cc355c7fa52943d276e59d7 100644 --- a/app/src/main/java/com/example/nerbos/fragments/transaction/TransactionAdapter.kt +++ b/app/src/main/java/com/example/nerbos/fragments/transaction/TransactionAdapter.kt @@ -5,6 +5,7 @@ import android.graphics.Color import android.view.LayoutInflater import android.view.View import android.view.ViewGroup +import android.widget.ImageButton import android.widget.TextView import androidx.recyclerview.widget.RecyclerView import com.example.nerbos.R @@ -21,7 +22,8 @@ class TransactionAdapter : RecyclerView.Adapter<TransactionAdapter.TransactionVi val name: TextView = itemView.findViewById(R.id.transactionName) val date: TextView = itemView.findViewById(R.id.transactionDate) val nominal: TextView = itemView.findViewById(R.id.transactionNominal) - val location: TextView = itemView.findViewById(R.id.transactionLocation) + val locationText: TextView = itemView.findViewById(R.id.transactionLocationText) + val locationButton: ImageButton = itemView.findViewById(R.id.transactionLocationButton) } override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): TransactionViewHolder { @@ -39,7 +41,9 @@ class TransactionAdapter : RecyclerView.Adapter<TransactionAdapter.TransactionVi val dateString = currentItem.date.toString() holder.name.text = currentItem.name holder.date.text = Utils.formatDate(dateString) - holder.location.text = currentItem.location + holder.locationText.text = currentItem.location + holder. locationButton.contentDescription = currentItem.location + "Button" + if (currentItem.category == TransactionCategory.INCOME){ holder.nominal.text = buildString { append("+ IDR ") @@ -59,8 +63,8 @@ class TransactionAdapter : RecyclerView.Adapter<TransactionAdapter.TransactionVi onItemClick?.invoke(transactionList[position]) } - holder.location.setOnClickListener { - onLocationClick?.invoke(holder.location.text.toString()) + holder.locationButton.setOnClickListener { + onLocationClick?.invoke(holder.locationText.text.toString()) } } diff --git a/app/src/main/res/layout-land/activity_login.xml b/app/src/main/res/layout-land/activity_login.xml index 8cec55bdce2e8b79f834234837b900355e2d1d6f..82c3e951633de70051f2a8bfe1443bbcd33fa4bd 100644 --- a/app/src/main/res/layout-land/activity_login.xml +++ b/app/src/main/res/layout-land/activity_login.xml @@ -47,7 +47,7 @@ android:layout_marginTop="15dp" android:gravity="center_horizontal" android:text="@string/login_description" - android:textColor="@color/text_secondary" + android:textColor="@color/grey" android:textSize="20sp" android:visibility="visible" app:layout_constraintEnd_toEndOf="parent" diff --git a/app/src/main/res/layout-land/activity_main.xml b/app/src/main/res/layout-land/activity_main.xml index 8990f7d29bc6aed64acbd43bd1a02296e23fddd8..1f3925c2946c34d6d6202d457bdcc82dff7a43f0 100644 --- a/app/src/main/res/layout-land/activity_main.xml +++ b/app/src/main/res/layout-land/activity_main.xml @@ -41,7 +41,7 @@ <com.google.android.material.navigation.NavigationView android:id="@+id/navigationView" - android:layout_width="80dp" + android:layout_width="85dp" android:layout_height="0dp" android:orientation="vertical" android:paddingTop="40dp" @@ -51,7 +51,8 @@ app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintTop_toBottomOf="@+id/appBarLayout" - app:menu="@menu/bottom_navbar"> + app:menu="@menu/bottom_navbar" + app:itemTextColor="@color/transparent"> </com.google.android.material.navigation.NavigationView> diff --git a/app/src/main/res/layout-land/add_transaction.xml b/app/src/main/res/layout-land/add_transaction.xml index 2e356f9aa79a7a8b5f75e20a4de70467429cf5dd..b51d0902d270bc41e7ecdb0001567a101ce8e15b 100644 --- a/app/src/main/res/layout-land/add_transaction.xml +++ b/app/src/main/res/layout-land/add_transaction.xml @@ -32,7 +32,7 @@ android:textSize="15sp" android:textStyle="bold" android:gravity="center" - android:textColor="@color/date_text" + android:textColor="@color/base_bg" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintHorizontal_bias="0.5" app:layout_constraintStart_toStartOf="parent" @@ -53,11 +53,11 @@ <EditText android:id="@+id/nameInput" android:layout_width="0dp" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="1" android:layout_marginEnd="20sp" android:autofillHints="Name Input" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" android:ems="10" android:hint="@string/name" android:inputType="text" @@ -78,13 +78,13 @@ <RadioButton android:id="@+id/incomeInput" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="0.5" android:background="@drawable/round_corner_input_category_income" android:buttonTint="@color/white" android:checked="true" android:text="@string/income" - android:textColor="@color/white" + android:textColor="@color/primary_bg" android:textSize="18sp" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" @@ -93,13 +93,13 @@ <RadioButton android:id="@+id/outcomeInput" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="0.5" android:layout_marginStart="20dp" android:background="@drawable/round_corner_input_category_outcome" android:buttonTint="@color/white" android:text="@string/outcome" - android:textColor="@color/white" + android:textColor="@color/primary_bg" android:textSize="18sp" /> </RadioGroup> @@ -109,7 +109,7 @@ <LinearLayout android:id="@+id/bottomHorizontalLayout" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:orientation="horizontal" app:layout_constraintTop_toBottomOf="@id/topHorizontalLayout" app:layout_constraintStart_toStartOf="parent" @@ -121,10 +121,10 @@ <EditText android:id="@+id/nominalInput" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="1" android:autofillHints="Nominal Input" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" android:ems="100" android:hint="@string/nominal" android:inputType="number" @@ -146,11 +146,11 @@ <EditText android:id="@+id/locationInput" android:layout_width="0dp" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="1" android:layout_marginEnd="20dp" android:autofillHints="Location Input" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" android:ems="10" android:hint="@string/location" android:inputType="text" @@ -164,9 +164,10 @@ <ImageView android:id="@+id/autoFillLocationButton" - android:layout_width="45dp" - android:layout_height="45dp" - android:background="@drawable/ic_location" + android:layout_width="48dp" + android:layout_height="48dp" + android:src="@drawable/ic_location" + android:background="@drawable/round_corner_input_transaction" android:contentDescription="@string/autofill_location_button" /> </LinearLayout> @@ -182,7 +183,7 @@ android:layout_marginTop="40dp" android:layout_marginBottom="20dp" android:layout_marginStart="20dp" - android:background="@drawable/round_corner_button_weak" + android:background="@drawable/round_corner_input_transaction" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toBottomOf="@+id/bottomHorizontalLayout" app:layout_constraintBottom_toBottomOf="parent" /> diff --git a/app/src/main/res/layout-land/fragment_transaction.xml b/app/src/main/res/layout-land/fragment_transaction.xml index cc6bc3bedd002737478377fb00ff9b14ef61c6d3..42d9b8720096e72eb2703c4c5c8305083bcc8f52 100644 --- a/app/src/main/res/layout-land/fragment_transaction.xml +++ b/app/src/main/res/layout-land/fragment_transaction.xml @@ -19,7 +19,7 @@ <ImageView android:id="@+id/saveTransactionsButton" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:src="@drawable/button_save" android:layout_marginStart="10dp" @@ -30,7 +30,7 @@ <ImageView android:id="@+id/sendTransactionsButton" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:src="@drawable/button_send" android:layout_marginEnd="10dp" @@ -54,8 +54,8 @@ <ImageView android:id="@+id/randomizeTransactionButton" - android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_width="48dp" + android:layout_height="48dp" android:layout_marginTop="30dp" android:layout_marginEnd="10dp" android:background="@drawable/random" @@ -65,8 +65,8 @@ <ImageView android:id="@+id/addTransactionButton" - android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_width="48dp" + android:layout_height="48dp" android:background="@drawable/plus" android:layout_marginTop="30dp" app:layout_constraintTop_toBottomOf="@id/sendTransactionsButton" @@ -93,8 +93,9 @@ <TextView android:id="@+id/xlsSave" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:text="@string/xls" + android:contentDescription="@string/save_xls" android:background="@drawable/border_save_selection" android:textSize="18sp" android:textColor="@color/base_bg" @@ -103,19 +104,24 @@ android:paddingBottom="4dp" android:paddingEnd="30dp" android:visibility="gone" + android:textAlignment="center" + android:gravity="center" /> <TextView android:id="@+id/xlsxSave" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:textSize="18sp" android:textColor="@color/base_bg" + android:contentDescription="@string/save_xlsx" android:text="@string/xlsx" android:paddingBottom="3dp" android:paddingStart="26dp" android:paddingEnd="30dp" android:visibility="gone" + android:textAlignment="center" + android:gravity="center" /> </LinearLayout> @@ -131,8 +137,9 @@ <TextView android:id="@+id/xlsSend" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:text="@string/xls" + android:contentDescription="@string/send_xls" android:background="@drawable/border_save_selection" android:textSize="18sp" android:textColor="@color/base_bg" @@ -141,19 +148,24 @@ android:paddingBottom="4dp" android:paddingEnd="30dp" android:visibility="gone" + android:textAlignment="center" + android:gravity="center" /> <TextView android:id="@+id/xlsxSend" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:textSize="18sp" + android:contentDescription="@string/send_xlsx" android:textColor="@color/base_bg" android:text="@string/xlsx" android:paddingBottom="3dp" android:paddingStart="26dp" android:paddingEnd="30dp" android:visibility="gone" + android:textAlignment="center" + android:gravity="center" /> </LinearLayout> diff --git a/app/src/main/res/layout-land/fragment_twibbon.xml b/app/src/main/res/layout-land/fragment_twibbon.xml index aecb60af05e93f8c3fdb0092731bb556e97adb3d..65e23dca42131fd321a8e0af9712ae55da221a13 100644 --- a/app/src/main/res/layout-land/fragment_twibbon.xml +++ b/app/src/main/res/layout-land/fragment_twibbon.xml @@ -22,13 +22,12 @@ app:layout_constraintStart_toStartOf="parent" app:layout_constraintEnd_toStartOf="@id/captureButton" app:layout_constraintBottom_toBottomOf="parent" - android:layout_marginStart="50dp" android:layout_gravity="center"> <ImageButton android:id="@+id/leftButton" android:layout_width="0dp" - android:layout_height="35dp" + android:layout_height="55dp" android:layout_weight="1" android:layout_gravity="start|center" app:layout_constraintStart_toStartOf="parent" @@ -67,7 +66,7 @@ <ImageButton android:id="@+id/rightButton" android:layout_width="0dp" - android:layout_height="35dp" + android:layout_height="55dp" android:layout_weight="1" android:layout_gravity="end|center" app:layout_constraintEnd_toEndOf="parent" diff --git a/app/src/main/res/layout-land/fragment_user.xml b/app/src/main/res/layout-land/fragment_user.xml index 05f64b5008a810ea923ad11127399d146e39a86d..4edc39f3924234f520a078e0da633961077464dd 100644 --- a/app/src/main/res/layout-land/fragment_user.xml +++ b/app/src/main/res/layout-land/fragment_user.xml @@ -57,7 +57,7 @@ android:layout_marginTop="5dp" android:gravity="center_horizontal" android:text="@string/app_name_full" - android:textColor="@color/text_secondary" + android:textColor="@color/grey" android:textSize="20sp" android:visibility="visible" app:layout_constraintEnd_toEndOf="parent" diff --git a/app/src/main/res/layout-land/modify_transaction.xml b/app/src/main/res/layout-land/modify_transaction.xml index 9a6077be612a45d57d48da44f511cb4ac62a3a29..775a34070131d152f34d48a06bc551a210f5d317 100644 --- a/app/src/main/res/layout-land/modify_transaction.xml +++ b/app/src/main/res/layout-land/modify_transaction.xml @@ -32,7 +32,7 @@ android:textSize="15sp" android:textStyle="bold" android:gravity="center" - android:textColor="@color/date_text" + android:textColor="@color/base_bg" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintHorizontal_bias="0.5" app:layout_constraintStart_toStartOf="parent" @@ -53,11 +53,11 @@ <EditText android:id="@+id/nameInput" android:layout_width="0dp" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="1" android:layout_marginEnd="20sp" android:autofillHints="Name Input" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" android:ems="10" android:hint="@string/name" android:inputType="text" @@ -78,13 +78,13 @@ <RadioButton android:id="@+id/incomeInput" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="0.5" android:background="@drawable/round_corner_input_category_income" android:buttonTint="@color/white" android:checked="true" android:text="@string/income" - android:textColor="@color/white" + android:textColor="@color/primary_bg" android:textSize="18sp" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" @@ -93,13 +93,13 @@ <RadioButton android:id="@+id/outcomeInput" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="0.5" android:layout_marginStart="20dp" android:background="@drawable/round_corner_input_category_outcome" android:buttonTint="@color/white" android:text="@string/outcome" - android:textColor="@color/white" + android:textColor="@color/primary_bg" android:textSize="18sp" /> </RadioGroup> @@ -109,7 +109,7 @@ <LinearLayout android:id="@+id/bottomHorizontalLayout" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:orientation="horizontal" app:layout_constraintTop_toBottomOf="@id/topHorizontalLayout" app:layout_constraintStart_toStartOf="parent" @@ -121,10 +121,10 @@ <EditText android:id="@+id/nominalInput" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="1" android:autofillHints="Nominal Input" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" android:ems="100" android:hint="@string/nominal" android:inputType="number" @@ -138,14 +138,14 @@ <TextView android:id="@+id/transactionDateDialog" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="1" android:layout_marginStart="20dp" android:ems="10" android:padding="10sp" android:paddingStart="20sp" android:paddingEnd="20sp" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" android:textSize="18sp" android:textColor="@color/white" android:textColorHint="@color/base_blur" @@ -156,7 +156,7 @@ <LinearLayout android:id="@+id/bottomRightHorizontalLayout" android:layout_width="match_parent" - android:layout_height="match_parent" + android:layout_height="48dp" android:layout_weight="1" android:layout_marginStart="20dp" android:orientation="horizontal"> @@ -164,11 +164,11 @@ <EditText android:id="@+id/locationInput" android:layout_width="0dp" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="1" android:layout_marginEnd="20dp" android:autofillHints="Location Input" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" android:ems="10" android:hint="@string/location" android:inputType="text" @@ -182,9 +182,10 @@ <ImageView android:id="@+id/autoFillLocationButton" - android:layout_width="45dp" - android:layout_height="45dp" - android:background="@drawable/ic_location" + android:layout_width="48dp" + android:layout_height="48dp" + android:src="@drawable/ic_location" + android:background="@drawable/round_corner_input_transaction" android:contentDescription="@string/autofill_location_button" /> </LinearLayout> diff --git a/app/src/main/res/layout/activity_login.xml b/app/src/main/res/layout/activity_login.xml index 0e2f7acae30887ed87cc5deb1cfc47bc6477702a..5ecc5dbb8f3a325297a46c60f45d5b2da3f073d9 100644 --- a/app/src/main/res/layout/activity_login.xml +++ b/app/src/main/res/layout/activity_login.xml @@ -59,7 +59,7 @@ android:layout_marginTop="15dp" android:gravity="center_horizontal" android:text="@string/login_description" - android:textColor="@color/text_secondary" + android:textColor="@color/grey" android:textSize="20sp" android:visibility="visible" app:layout_constraintEnd_toEndOf="parent" diff --git a/app/src/main/res/layout/add_scan_transaction.xml b/app/src/main/res/layout/add_scan_transaction.xml index 69e8f8e38369a7ff387fd736ad3c2bfb0eaab457..554179255a54a9fd2172541fa466c3efc0a80169 100644 --- a/app/src/main/res/layout/add_scan_transaction.xml +++ b/app/src/main/res/layout/add_scan_transaction.xml @@ -10,8 +10,15 @@ <EditText android:id="@+id/nameInput" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:hint="@string/name" + android:padding="10sp" + android:paddingStart="20sp" + android:paddingEnd="20sp" + android:textColor="@color/white" + android:textColorHint="@color/base_blur" + android:textSize="18sp" + android:background="@drawable/round_corner_input_transaction" android:inputType="text" android:autofillHints="Transaction Name" /> @@ -20,21 +27,36 @@ android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_gravity="center_horizontal" - android:orientation="horizontal"> + android:orientation="horizontal" + android:layout_marginTop="20dp" + android:layout_marginBottom="20dp"> <RadioButton android:id="@+id/incomeRadioButton" - android:layout_width="0dp" - android:layout_height="wrap_content" - android:layout_weight="1" - android:text="@string/income" /> + android:layout_width="wrap_content" + android:layout_height="48dp" + android:layout_weight="0.5" + android:text="@string/income" + android:checked="true" + android:buttonTint="@color/white" + android:textColor="@color/primary_bg" + android:background="@drawable/round_corner_input_category_income" + android:textSize="18sp" + app:layout_constraintEnd_toStartOf="@id/outcomeInput" + app:layout_constraintStart_toStartOf="parent" + app:layout_constraintTop_toBottomOf="@+id/nameInput" /> <RadioButton android:id="@+id/outcomeRadioButton" - android:layout_width="0dp" - android:layout_height="wrap_content" - android:layout_weight="1" - android:text="@string/outcome" /> + android:layout_width="wrap_content" + android:layout_height="48dp" + android:layout_weight="0.5" + android:buttonTint="@color/white" + android:textColor="@color/primary_bg" + android:layout_marginStart="20dp" + android:background="@drawable/round_corner_input_category_outcome" + android:text="@string/outcome" + android:textSize="18sp" /> </RadioGroup> @@ -47,8 +69,15 @@ <EditText android:id="@+id/locationInput" android:layout_width="0dp" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="1" + android:padding="10sp" + android:paddingStart="20sp" + android:paddingEnd="10sp" + android:textColor="@color/white" + android:textColorHint="@color/base_blur" + android:textSize="18sp" + android:background="@drawable/round_corner_input_transaction" android:autofillHints="Location Name" android:hint="@string/location" android:inputType="text" @@ -57,8 +86,8 @@ <ImageButton android:id="@+id/mapButton" - android:layout_width="40dp" - android:layout_height="40dp" + android:layout_width="48dp" + android:layout_height="48dp" android:scaleType="fitCenter" android:contentDescription="@string/maps" android:background="@color/transparent" diff --git a/app/src/main/res/layout/add_transaction.xml b/app/src/main/res/layout/add_transaction.xml index 254e496d6c25eb67421041f5e0d6042b795d37e0..0192bb3e17c8b770ea52f65f905768fce2aeda47 100644 --- a/app/src/main/res/layout/add_transaction.xml +++ b/app/src/main/res/layout/add_transaction.xml @@ -31,7 +31,7 @@ android:textSize="18sp" android:textStyle="bold" android:gravity="center" - android:textColor="@color/date_text" + android:textColor="@color/base_bg" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintHorizontal_bias="0.5" app:layout_constraintStart_toStartOf="parent" @@ -40,11 +40,11 @@ <EditText android:id="@+id/nameInput" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_marginStart="20sp" android:layout_marginTop="40sp" android:layout_marginEnd="20sp" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" android:ems="10" android:hint="@string/name" android:inputType="text" @@ -75,12 +75,12 @@ <RadioButton android:id="@+id/incomeInput" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="0.5" android:text="@string/income" android:checked="true" android:buttonTint="@color/white" - android:textColor="@color/white" + android:textColor="@color/primary_bg" android:background="@drawable/round_corner_input_category_income" android:textSize="18sp" app:layout_constraintEnd_toStartOf="@id/outcomeInput" @@ -90,10 +90,10 @@ <RadioButton android:id="@+id/outcomeInput" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="0.5" android:buttonTint="@color/white" - android:textColor="@color/white" + android:textColor="@color/primary_bg" android:layout_marginStart="20dp" android:background="@drawable/round_corner_input_category_outcome" android:text="@string/outcome" @@ -107,7 +107,7 @@ android:paddingStart="20dp" android:paddingEnd="20dp" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_marginStart="20dp" android:layout_marginTop="15dp" android:layout_marginEnd="20dp" @@ -117,7 +117,7 @@ android:textColorHint="@color/base_blur" android:inputType="number" android:textSize="18sp" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toBottomOf="@+id/categoryInput" @@ -126,23 +126,23 @@ <LinearLayout android:id="@+id/horizontalLayout" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:orientation="horizontal" app:layout_constraintTop_toBottomOf="@id/nominalInput" app:layout_constraintStart_toStartOf="parent" app:layout_constraintEnd_toEndOf="parent" - android:layout_marginTop="20dp" + android:layout_marginTop="15dp" android:layout_marginStart="20dp" android:layout_marginEnd="20dp"> <EditText android:id="@+id/locationInput" android:layout_width="0dp" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="1" android:layout_marginEnd="10dp" android:autofillHints="Location Input" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" android:ems="10" android:hint="@string/location" android:inputType="text" @@ -155,9 +155,10 @@ <ImageView android:id="@+id/autoFillLocationButton" - android:layout_width="40dp" - android:layout_height="40dp" - android:background="@drawable/ic_location" + android:layout_width="48dp" + android:layout_height="48dp" + android:src="@drawable/ic_location" + android:background="@drawable/round_corner_input_transaction" android:contentDescription="@string/autofill_location_button" /> </LinearLayout> @@ -171,7 +172,7 @@ android:layout_marginTop="40dp" android:layout_marginBottom="20dp" android:layout_marginStart="20dp" - android:background="@drawable/round_corner_button_weak" + android:background="@drawable/round_corner_input_transaction" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toBottomOf="@+id/horizontalLayout" app:layout_constraintBottom_toBottomOf="parent" /> diff --git a/app/src/main/res/layout/fragment_transaction.xml b/app/src/main/res/layout/fragment_transaction.xml index c39600afca809239bcef28901cdd7687e01bf3ac..d3e9a018051288b32001c3614e68747460849888 100644 --- a/app/src/main/res/layout/fragment_transaction.xml +++ b/app/src/main/res/layout/fragment_transaction.xml @@ -16,7 +16,7 @@ <ImageView android:id="@+id/saveTransactionsButton" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:src="@drawable/button_save" android:layout_marginStart="10dp" @@ -27,7 +27,7 @@ <ImageView android:id="@+id/sendTransactionsButton" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:src="@drawable/button_send" android:layout_marginEnd="10dp" @@ -51,8 +51,8 @@ <ImageView android:id="@+id/randomizeTransactionButton" - android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_width="48dp" + android:layout_height="48dp" android:layout_marginTop="30dp" android:layout_marginEnd="10dp" android:background="@drawable/random" @@ -62,8 +62,8 @@ <ImageView android:id="@+id/addTransactionButton" - android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_width="48dp" + android:layout_height="48dp" android:background="@drawable/plus" android:layout_marginTop="30dp" app:layout_constraintTop_toBottomOf="@id/sendTransactionsButton" @@ -90,8 +90,9 @@ <TextView android:id="@+id/xlsSave" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:text="@string/xls" + android:contentDescription="@string/save_xls" android:background="@drawable/border_save_selection" android:textSize="18sp" android:textColor="@color/base_bg" @@ -100,12 +101,15 @@ android:paddingBottom="4dp" android:paddingEnd="30dp" android:visibility="gone" + android:textAlignment="center" + android:gravity="center" /> <TextView android:id="@+id/xlsxSave" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" + android:contentDescription="@string/save_xlsx" android:textSize="18sp" android:textColor="@color/base_bg" android:text="@string/xlsx" @@ -113,6 +117,8 @@ android:paddingStart="26dp" android:paddingEnd="30dp" android:visibility="gone" + android:textAlignment="center" + android:gravity="center" /> </LinearLayout> @@ -128,9 +134,10 @@ <TextView android:id="@+id/xlsSend" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:text="@string/xls" android:background="@drawable/border_save_selection" + android:contentDescription="@string/send_xls" android:textSize="18sp" android:textColor="@color/base_bg" android:paddingTop="2dp" @@ -138,19 +145,24 @@ android:paddingBottom="4dp" android:paddingEnd="30dp" android:visibility="gone" + android:textAlignment="center" + android:gravity="center" /> <TextView android:id="@+id/xlsxSend" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:textSize="18sp" android:textColor="@color/base_bg" + android:contentDescription="@string/send_xlsx" android:text="@string/xlsx" android:paddingBottom="3dp" android:paddingStart="26dp" android:paddingEnd="30dp" android:visibility="gone" + android:textAlignment="center" + android:gravity="center" /> </LinearLayout> diff --git a/app/src/main/res/layout/fragment_twibbon.xml b/app/src/main/res/layout/fragment_twibbon.xml index 950dfce9f19885a8431162842db0f3837d29dc81..880806c7e5d9f5537e62487bb888a51d006a4876 100644 --- a/app/src/main/res/layout/fragment_twibbon.xml +++ b/app/src/main/res/layout/fragment_twibbon.xml @@ -28,8 +28,8 @@ <ImageButton android:id="@+id/leftButton" - android:layout_width="0dp" - android:layout_height="35dp" + android:layout_width="48dp" + android:layout_height="48dp" android:layout_weight="1" android:layout_gravity="start|center" app:layout_constraintStart_toStartOf="parent" @@ -41,8 +41,9 @@ android:contentDescription="@string/left_arrow" /> <FrameLayout - android:layout_width="300dp" - android:layout_height="300dp" + android:layout_width="250dp" + android:layout_height="250dp" + android:layout_weight="1" app:layout_constraintStart_toStartOf="parent" app:layout_constraintEnd_toEndOf="parent" android:layout_gravity="center" > @@ -65,8 +66,8 @@ <ImageButton android:id="@+id/rightButton" - android:layout_width="0dp" - android:layout_height="35dp" + android:layout_width="48dp" + android:layout_height="48dp" android:layout_weight="1" android:layout_gravity="end|center" app:layout_constraintEnd_toEndOf="parent" diff --git a/app/src/main/res/layout/fragment_user.xml b/app/src/main/res/layout/fragment_user.xml index d910d464d9ce2777981906805760a6e496e94e6c..159c9afebc47a21dcf763115c85106fa275eda40 100644 --- a/app/src/main/res/layout/fragment_user.xml +++ b/app/src/main/res/layout/fragment_user.xml @@ -57,7 +57,7 @@ android:layout_marginTop="5dp" android:gravity="center_horizontal" android:text="@string/app_name_full" - android:textColor="@color/text_secondary" + android:textColor="@color/grey" android:textSize="20sp" android:visibility="visible" app:layout_constraintEnd_toEndOf="parent" diff --git a/app/src/main/res/layout/modify_transaction.xml b/app/src/main/res/layout/modify_transaction.xml index e83cbb0f126668e70a076e6368aaa7f1b186ea2b..abc9ef856c326c13dc5f57c7ec6dc9e7ddecb994 100644 --- a/app/src/main/res/layout/modify_transaction.xml +++ b/app/src/main/res/layout/modify_transaction.xml @@ -31,7 +31,7 @@ android:textSize="18sp" android:textStyle="bold" android:gravity="center" - android:textColor="@color/date_text" + android:textColor="@color/base_bg" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintHorizontal_bias="0.5" app:layout_constraintStart_toStartOf="parent" @@ -40,11 +40,11 @@ <EditText android:id="@+id/nameInput" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_marginStart="20sp" android:layout_marginTop="40sp" android:layout_marginEnd="20sp" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" android:ems="10" android:hint="@string/name" android:inputType="text" @@ -74,12 +74,12 @@ <RadioButton android:id="@+id/incomeInput" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="0.5" android:text="@string/income" android:checked="true" android:buttonTint="@color/white" - android:textColor="@color/white" + android:textColor="@color/primary_bg" android:background="@drawable/round_corner_input_category_income" android:textSize="18sp" app:layout_constraintEnd_toStartOf="@id/outcomeInput" @@ -89,10 +89,10 @@ <RadioButton android:id="@+id/outcomeInput" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="0.5" android:buttonTint="@color/white" - android:textColor="@color/white" + android:textColor="@color/primary_bg" android:layout_marginStart="20dp" android:background="@drawable/round_corner_input_category_outcome" android:text="@string/outcome" @@ -106,7 +106,7 @@ android:paddingStart="20dp" android:paddingEnd="20dp" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_marginStart="20dp" android:layout_marginTop="15dp" android:layout_marginEnd="20dp" @@ -116,7 +116,7 @@ android:textColorHint="@color/base_blur" android:inputType="number" android:textSize="18sp" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toBottomOf="@+id/categoryInput" @@ -125,7 +125,7 @@ <LinearLayout android:id="@+id/horizontalLayout" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:orientation="horizontal" app:layout_constraintTop_toBottomOf="@id/nominalInput" app:layout_constraintStart_toStartOf="parent" @@ -137,11 +137,11 @@ <EditText android:id="@+id/locationInput" android:layout_width="0dp" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_weight="1" android:layout_marginEnd="10dp" android:autofillHints="Location Input" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" android:ems="10" android:hint="@string/location" android:inputType="text" @@ -154,16 +154,17 @@ <ImageView android:id="@+id/autoFillLocationButton" - android:layout_width="40dp" - android:layout_height="40dp" - android:background="@drawable/ic_location" + android:layout_width="48dp" + android:layout_height="48dp" + android:src="@drawable/ic_location" + android:background="@drawable/round_corner_input_transaction" android:contentDescription="@string/autofill_location_button" /> </LinearLayout> <TextView android:id="@+id/transactionDateDialog" android:layout_width="match_parent" - android:layout_height="wrap_content" + android:layout_height="48dp" android:layout_marginStart="20dp" android:layout_marginTop="20dp" android:layout_marginEnd="20dp" @@ -171,7 +172,7 @@ android:padding="10sp" android:paddingStart="20sp" android:paddingEnd="20sp" - android:background="@drawable/round_corner_input_transaction" + android:background="@drawable/round_corner_transaction_item" android:textSize="18sp" android:textColor="@color/white" android:textColorHint="@color/base_blur" diff --git a/app/src/main/res/layout/transaction_item.xml b/app/src/main/res/layout/transaction_item.xml index a622e44d0e75a1205e64fb00a502f21c654f9c63..a94d83e36ff198df504ac2465c357361034b5905 100644 --- a/app/src/main/res/layout/transaction_item.xml +++ b/app/src/main/res/layout/transaction_item.xml @@ -4,8 +4,8 @@ android:layout_height="wrap_content" android:layout_marginBottom="20dp" android:padding="20dp" - android:paddingStart="40dp" - android:paddingEnd="40dp" + android:paddingStart="25dp" + android:paddingEnd="20dp" android:background="@drawable/round_corner_transaction_item" xmlns:app="http://schemas.android.com/apk/res-auto"> @@ -31,7 +31,7 @@ android:maxWidth="130dp" android:maxLines="1" android:ellipsize="end" - android:textColor="@color/date_text" + android:textColor="@color/grey" android:textSize="16sp" android:textStyle="normal" android:layout_marginTop="5sp" @@ -40,7 +40,7 @@ /> <TextView - android:id="@+id/transactionLocation" + android:id="@+id/transactionLocationText" android:layout_width="wrap_content" android:layout_height="wrap_content" android:maxWidth="130dp" @@ -49,9 +49,8 @@ android:textColor="@color/white" android:textSize="16sp" android:textStyle="normal" - app:layout_constraintEnd_toEndOf="parent" + app:layout_constraintEnd_toStartOf="@id/transactionLocationButton" app:layout_constraintTop_toTopOf="parent" - app:drawableStartCompat="@drawable/ic_location" /> <TextView @@ -65,8 +64,21 @@ android:textSize="16sp" android:textStyle="normal" android:layout_marginTop="5dp" - app:layout_constraintEnd_toEndOf="parent" - app:layout_constraintTop_toBottomOf="@id/transactionLocation" + app:layout_constraintEnd_toStartOf="@id/transactionLocationButton" + app:layout_constraintTop_toBottomOf="@id/transactionLocationText" /> + <ImageButton + android:id="@+id/transactionLocationButton" + android:layout_width="48dp" + android:layout_height="48dp" + app:layout_constraintEnd_toEndOf="parent" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintTop_toTopOf="parent" + android:contentDescription="@string/location" + android:background="@color/transparent" + android:src="@drawable/ic_location" + android:scaleType="fitCenter"/> + + </androidx.constraintlayout.widget.ConstraintLayout> \ No newline at end of file diff --git a/app/src/main/res/layout/twibbon_filename.xml b/app/src/main/res/layout/twibbon_filename.xml index b149e2a22d81053dba6a40198bd65da98ffa4511..37c5b5e7b756ad9cc53614b986a56e78274c454c 100644 --- a/app/src/main/res/layout/twibbon_filename.xml +++ b/app/src/main/res/layout/twibbon_filename.xml @@ -3,7 +3,8 @@ android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="vertical" - android:padding="16dp"> + android:padding="16dp" + android:background="@drawable/round_corner_input_transaction_form"> <EditText android:id="@+id/filenameInput" @@ -11,6 +12,13 @@ android:layout_height="wrap_content" android:hint="@string/name" android:inputType="text" - android:autofillHints="Twibbon Filename" /> + android:autofillHints="Twibbon Filename" + android:padding="10sp" + android:paddingStart="20sp" + android:paddingEnd="20sp" + android:textColor="@color/white" + android:textColorHint="@color/base_blur" + android:textSize="18sp" + android:background="@drawable/round_corner_input_transaction"/> </LinearLayout> \ No newline at end of file diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 0fdc113eb07c5459bf6fe24290ecbd1b1a226c42..93a893675312ae0777bb2df9f397045efe80f0f4 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -50,29 +50,34 @@ <string name="title_activity_maps">MapsActivity</string> <string name="maps">Maps</string> <string name="network_sensing_string">No Internet Connection Please check your connection and try again.</string> - <string name="close_button">Close Button</string> + <string name="close_button">Close</string> <string name="pie_chart">Pie Chart</string> <string name="my_transaction">My Transaction</string> - <string name="add_transaction_button">Add Transaction Button</string> + <string name="add_transaction_button">Add Transaction</string> <string name="send">Send</string> - <string name="save_transactions_button">Save Transactions Button</string> - <string name="send_transactions_button">Send Transactions Button</string> + <string name="save_transactions_button">Save Transactions</string> + <string name="send_transactions_button">Send Transactions</string> <string name="xls">.xls</string> <string name="xlsx">.xlsx</string> <string name="pie_chart_title">Income vs Outcome Chart</string> <string name="language_code">id</string> <string name="country_code">ID</string> - <string name="capture_button">Capture Button</string> - <string name="gallery_button">Gallery Button</string> + <string name="capture_button">Capture</string> + <string name="gallery_button">Gallery</string> <string name="email_subject">NerbOS - Transaction Report</string> <string name="email_message">Here is your transaction report</string> <string name="logo">Logo</string> <string name="back_button">Back Button</string> - <string name="autofill_location_button">AutoFill Location Button</string> - <string name="randomize_transaction_button">Randomize Transaction Button</string> + <string name="autofill_location_button">AutoFill Location</string> + <string name="randomize_transaction_button">Randomize Transaction</string> <string name="navbar_twibbon">Twibbon</string> <string name="left_arrow">Left Arrow</string> <string name="right_arrow">Right Arrow</string> <string name="twibbon_preview">Twibbon Preview</string> + <string name="page">Page</string> + <string name="save_xls">Save xls</string> + <string name="save_xlsx">Save xlsx</string> + <string name="send_xls">Send xls</string> + <string name="send_xlsx">Send xlsx</string> </resources> \ No newline at end of file diff --git a/app/src/main/res/values/styles.xml b/app/src/main/res/values/styles.xml new file mode 100644 index 0000000000000000000000000000000000000000..344efafdba8f79fcda002f0fc60badfd7b9d4c1d --- /dev/null +++ b/app/src/main/res/values/styles.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8"?> +<resources> + + <style name="AlertDialogTheme"> + <item name="android:background"> + @color/navbar_bg + </item> + </style> +</resources> \ No newline at end of file diff --git a/screenshot/accessibility_after.png b/screenshot/accessibility_after.png new file mode 100644 index 0000000000000000000000000000000000000000..5569a538716b7f8f1b70d7b3b419d3703492c758 Binary files /dev/null and b/screenshot/accessibility_after.png differ diff --git a/screenshot/accessibility_category_before.png b/screenshot/accessibility_category_before.png new file mode 100644 index 0000000000000000000000000000000000000000..fbfea09024394a7a89b1962e969b2a6000a50d49 Binary files /dev/null and b/screenshot/accessibility_category_before.png differ diff --git a/screenshot/accessibility_screen_before.png b/screenshot/accessibility_screen_before.png new file mode 100644 index 0000000000000000000000000000000000000000..8151466b82cfaa68097e44a93f7ebac7e6b562e4 Binary files /dev/null and b/screenshot/accessibility_screen_before.png differ