forked from thijooree/android
MIB recipt redesign to mimick new MIB app and dark mode support
This commit is contained in:
@@ -80,6 +80,8 @@ class TransferFragment : Fragment() {
|
|||||||
private var resolvedAccountNumber = ""
|
private var resolvedAccountNumber = ""
|
||||||
private var resolvedRecipientName = ""
|
private var resolvedRecipientName = ""
|
||||||
private var resolvedBankName = ""
|
private var resolvedBankName = ""
|
||||||
|
/** Last real profile/contact photo loaded into the "To" card (not an initials placeholder). */
|
||||||
|
private var loadedToPhoto: Bitmap? = null
|
||||||
private var resolvedDestCurrency = "" // "MVR" / "USD" / "" if unknown
|
private var resolvedDestCurrency = "" // "MVR" / "USD" / "" if unknown
|
||||||
private var resolvedToOwnAccount: BankAccount? = null
|
private var resolvedToOwnAccount: BankAccount? = null
|
||||||
|
|
||||||
@@ -1168,6 +1170,8 @@ class TransferFragment : Fragment() {
|
|||||||
val destDisplay = binding.tvToAccountName.text?.toString() ?: resolvedAccountNumber
|
val destDisplay = binding.tvToAccountName.text?.toString() ?: resolvedAccountNumber
|
||||||
val bankNameCapture = resolvedBankName
|
val bankNameCapture = resolvedBankName
|
||||||
val capturedToAvatar = (binding.ivToPhoto.drawable as? android.graphics.drawable.BitmapDrawable)?.bitmap
|
val capturedToAvatar = (binding.ivToPhoto.drawable as? android.graphics.drawable.BitmapDrawable)?.bitmap
|
||||||
|
// The MIB receipt only takes a real photo; it draws its own initials placeholder otherwise
|
||||||
|
val capturedToPhoto = capturedToAvatar?.takeIf { it === loadedToPhoto }
|
||||||
|
|
||||||
val destCurrency = resolvedDestCurrency.ifBlank {
|
val destCurrency = resolvedDestCurrency.ifBlank {
|
||||||
allAccounts.firstOrNull { it.accountNumber == resolvedAccountNumber }
|
allAccounts.firstOrNull { it.accountNumber == resolvedAccountNumber }
|
||||||
@@ -1205,7 +1209,7 @@ class TransferFragment : Fragment() {
|
|||||||
val activity = requireActivity() as HomeActivity
|
val activity = requireActivity() as HomeActivity
|
||||||
activity.triggerRefresh()
|
activity.triggerRefresh()
|
||||||
dialog.dismiss()
|
dialog.dismiss()
|
||||||
activity.showWithBackStack(TransferReceiptFragment.newInstance(receipt, capturedToAvatar))
|
activity.showWithBackStack(TransferReceiptFragment.newInstance(receipt, capturedToPhoto))
|
||||||
} else if (!ok) {
|
} else if (!ok) {
|
||||||
dialog.dismiss()
|
dialog.dismiss()
|
||||||
if (msg == "CONNECTIVITY") {
|
if (msg == "CONNECTIVITY") {
|
||||||
@@ -1581,6 +1585,7 @@ class TransferFragment : Fragment() {
|
|||||||
if (_binding != null) {
|
if (_binding != null) {
|
||||||
binding.ivToPhoto.scaleType = android.widget.ImageView.ScaleType.CENTER_CROP
|
binding.ivToPhoto.scaleType = android.widget.ImageView.ScaleType.CENTER_CROP
|
||||||
binding.ivToPhoto.setImageBitmap(bitmap)
|
binding.ivToPhoto.setImageBitmap(bitmap)
|
||||||
|
loadedToPhoto = bitmap
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,6 +14,8 @@ data class TransferReceiptData(
|
|||||||
// MIB receipt fields
|
// MIB receipt fields
|
||||||
val mibReferenceNo: String = "",
|
val mibReferenceNo: String = "",
|
||||||
val mibTransactionDate: String = "",
|
val mibTransactionDate: String = "",
|
||||||
|
val mibFromProfileName: String = "",
|
||||||
|
val mibTransactionType: String = "", // "Own Transfer", "MIB Transfer", "Quick Transfer"
|
||||||
// BML receipt fields
|
// BML receipt fields
|
||||||
val bmlFromName: String = "",
|
val bmlFromName: String = "",
|
||||||
val bmlReference: String = "",
|
val bmlReference: String = "",
|
||||||
|
|||||||
@@ -63,6 +63,8 @@ class TransferReceiptFragment : Fragment() {
|
|||||||
private const val ARG_REMARKS = "remarks"
|
private const val ARG_REMARKS = "remarks"
|
||||||
private const val ARG_MIB_REF = "mib_ref"
|
private const val ARG_MIB_REF = "mib_ref"
|
||||||
private const val ARG_MIB_DATE = "mib_date"
|
private const val ARG_MIB_DATE = "mib_date"
|
||||||
|
private const val ARG_MIB_FROM_PROFILE = "mib_from_profile"
|
||||||
|
private const val ARG_MIB_TXN_TYPE = "mib_txn_type"
|
||||||
private const val ARG_BML_FROM_NAME = "bml_from_name"
|
private const val ARG_BML_FROM_NAME = "bml_from_name"
|
||||||
private const val ARG_BML_REFERENCE = "bml_reference"
|
private const val ARG_BML_REFERENCE = "bml_reference"
|
||||||
private const val ARG_BML_TIMESTAMP = "bml_timestamp"
|
private const val ARG_BML_TIMESTAMP = "bml_timestamp"
|
||||||
@@ -91,6 +93,8 @@ class TransferReceiptFragment : Fragment() {
|
|||||||
putString(ARG_REMARKS, data.remarks)
|
putString(ARG_REMARKS, data.remarks)
|
||||||
putString(ARG_MIB_REF, data.mibReferenceNo)
|
putString(ARG_MIB_REF, data.mibReferenceNo)
|
||||||
putString(ARG_MIB_DATE, data.mibTransactionDate)
|
putString(ARG_MIB_DATE, data.mibTransactionDate)
|
||||||
|
putString(ARG_MIB_FROM_PROFILE, data.mibFromProfileName)
|
||||||
|
putString(ARG_MIB_TXN_TYPE, data.mibTransactionType)
|
||||||
putString(ARG_BML_FROM_NAME, data.bmlFromName)
|
putString(ARG_BML_FROM_NAME, data.bmlFromName)
|
||||||
putString(ARG_BML_REFERENCE, data.bmlReference)
|
putString(ARG_BML_REFERENCE, data.bmlReference)
|
||||||
putString(ARG_BML_TIMESTAMP, data.bmlTimestamp)
|
putString(ARG_BML_TIMESTAMP, data.bmlTimestamp)
|
||||||
@@ -170,43 +174,64 @@ class TransferReceiptFragment : Fragment() {
|
|||||||
private fun bindMib(binding: FragmentReceiptMibBinding) {
|
private fun bindMib(binding: FragmentReceiptMibBinding) {
|
||||||
val args = requireArguments()
|
val args = requireArguments()
|
||||||
val fromLabel = args.getString(ARG_FROM_LABEL, "")
|
val fromLabel = args.getString(ARG_FROM_LABEL, "")
|
||||||
val fromColor = args.getString(ARG_FROM_COLOR, "#FE860E")
|
|
||||||
val fromProfileHash = args.getString(ARG_FROM_PROFILE_HASH)
|
val fromProfileHash = args.getString(ARG_FROM_PROFILE_HASH)
|
||||||
val toLabel = args.getString(ARG_TO_LABEL, "")
|
val toLabel = args.getString(ARG_TO_LABEL, "")
|
||||||
val currency = args.getString(ARG_CURRENCY, "MVR")
|
val currency = args.getString(ARG_CURRENCY, "MVR")
|
||||||
val amount = args.getString(ARG_AMOUNT, "")
|
val amount = args.getString(ARG_AMOUNT, "")
|
||||||
|
|
||||||
// From avatar: initials first, then load profile image if hash available
|
// From avatar: initials first, then load profile image if hash available
|
||||||
binding.ivFromAvatar.setImageBitmap(makeInitialsBitmap(fromLabel, fromColor))
|
binding.ivFromAvatar.setImageBitmap(makeMibInitialsBitmap(fromLabel))
|
||||||
binding.tvFromLabel.text = fromLabel
|
binding.tvFromLabel.text = fromLabel
|
||||||
if (fromProfileHash != null) {
|
if (fromProfileHash != null) {
|
||||||
loadProfileImage(fromProfileHash, isProfile = true) { binding.ivFromAvatar.setImageBitmap(it) }
|
loadProfileImage(fromProfileHash, isProfile = true) { binding.ivFromAvatar.setImageBitmap(circleCrop(it)) }
|
||||||
}
|
}
|
||||||
|
|
||||||
// To avatar: use already-rendered bitmap from TransferFragment if available
|
// To avatar: use already-rendered bitmap from TransferFragment if available
|
||||||
val toAvatar = pendingToAvatarBitmap
|
val toAvatar = pendingToAvatarBitmap
|
||||||
if (toAvatar != null) {
|
if (toAvatar != null) {
|
||||||
binding.ivToAvatar.setImageBitmap(toAvatar)
|
binding.ivToAvatar.setImageBitmap(circleCrop(toAvatar))
|
||||||
} else {
|
} else {
|
||||||
binding.ivToAvatar.setImageBitmap(makeInitialsBitmap(toLabel, "#607D8B"))
|
binding.ivToAvatar.setImageBitmap(makeMibInitialsBitmap(toLabel))
|
||||||
}
|
}
|
||||||
binding.tvToLabel.text = toLabel
|
binding.tvToLabel.text = toLabel
|
||||||
|
|
||||||
binding.tvAmount.text = "$currency $amount"
|
binding.tvAmount.text = "$currency $amount"
|
||||||
|
|
||||||
|
val toBank = args.getString(ARG_TO_BANK, "")
|
||||||
|
val rawDate = args.getString(ARG_MIB_DATE, "")
|
||||||
binding.tvReferenceNo.text = args.getString(ARG_MIB_REF, "")
|
binding.tvReferenceNo.text = args.getString(ARG_MIB_REF, "")
|
||||||
binding.tvToAccount.text = args.getString(ARG_TO_ACCOUNT, "")
|
binding.tvFromName.text = args.getString(ARG_MIB_FROM_PROFILE, "").ifBlank { fromLabel }
|
||||||
binding.tvToBank.text = args.getString(ARG_TO_BANK, "")
|
binding.tvToAccount.text = listOf(toLabel, args.getString(ARG_TO_ACCOUNT, ""))
|
||||||
binding.tvTransactionDate.text = args.getString(ARG_MIB_DATE, "")
|
.filter { it.isNotBlank() }.joinToString("\n")
|
||||||
binding.tvValueDate.text = args.getString(ARG_MIB_DATE, "")
|
binding.tvToBank.text = toBank
|
||||||
|
// Receipts saved before the type was recorded fall back to a guess from the bank
|
||||||
|
binding.tvTransactionType.text = args.getString(ARG_MIB_TXN_TYPE, "").ifBlank {
|
||||||
|
if (toBank == "MIB") "MIB Transfer" else "Quick Transfer"
|
||||||
|
}
|
||||||
|
binding.tvTransactionDate.text = formatMibDate(rawDate, "dd MMM yyyy HH:mm")
|
||||||
|
binding.tvValueDate.text = formatMibDate(rawDate, "dd MMM yyyy")
|
||||||
binding.tvPurpose.text = args.getString(ARG_REMARKS, "")
|
binding.tvPurpose.text = args.getString(ARG_REMARKS, "")
|
||||||
|
.takeUnless { it.isNullOrBlank() || it.trim() == "-" } ?: "N/A"
|
||||||
|
|
||||||
copyOnLongClick(
|
copyOnLongClick(
|
||||||
binding.tvFromLabel, binding.tvToLabel, binding.tvAmount,
|
binding.tvFromLabel, binding.tvToLabel, binding.tvAmount, binding.tvStatus,
|
||||||
binding.tvReferenceNo, binding.tvToAccount, binding.tvToBank,
|
binding.tvReferenceNo, binding.tvFromName, binding.tvToAccount, binding.tvToBank,
|
||||||
binding.tvTransactionDate, binding.tvValueDate, binding.tvPurpose
|
binding.tvTransactionType, binding.tvTransactionDate, binding.tvValueDate, binding.tvPurpose
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Reformats the MIB transfer date ("2026-05-16 15:10:25") to [pattern]; raw text if unparseable. */
|
||||||
|
private fun formatMibDate(raw: String, pattern: String): String {
|
||||||
|
if (raw.isBlank()) return ""
|
||||||
|
val out = DateTimeFormatter.ofPattern(pattern, Locale.US)
|
||||||
|
for (inPattern in listOf("yyyy-MM-dd HH:mm:ss", "yyyy-MM-dd HH:mm", "dd MMM yyyy HH:mm")) {
|
||||||
|
try {
|
||||||
|
return java.time.LocalDateTime.parse(raw.trim(), DateTimeFormatter.ofPattern(inPattern, Locale.US)).format(out)
|
||||||
|
} catch (_: Exception) { }
|
||||||
|
}
|
||||||
|
return raw
|
||||||
|
}
|
||||||
|
|
||||||
private fun loadProfileImage(hash: String, isProfile: Boolean, onLoaded: (Bitmap) -> Unit) {
|
private fun loadProfileImage(hash: String, isProfile: Boolean, onLoaded: (Bitmap) -> Unit) {
|
||||||
val app = requireActivity().application as BasedBankApp
|
val app = requireActivity().application as BasedBankApp
|
||||||
val sess = app.anyMibSession() ?: return
|
val sess = app.anyMibSession() ?: return
|
||||||
@@ -422,20 +447,38 @@ class TransferReceiptFragment : Fragment() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun makeInitialsBitmap(name: String, colorHex: String): Bitmap {
|
/** Center-crops [src] to a square and masks it to a circle. */
|
||||||
|
private fun circleCrop(src: Bitmap): Bitmap {
|
||||||
|
val size = minOf(src.width, src.height)
|
||||||
|
val out = Bitmap.createBitmap(size, size, Bitmap.Config.ARGB_8888)
|
||||||
|
val paint = Paint(Paint.ANTI_ALIAS_FLAG or Paint.FILTER_BITMAP_FLAG).apply {
|
||||||
|
shader = android.graphics.BitmapShader(src, android.graphics.Shader.TileMode.CLAMP, android.graphics.Shader.TileMode.CLAMP).apply {
|
||||||
|
setLocalMatrix(android.graphics.Matrix().apply {
|
||||||
|
setTranslate(-(src.width - size) / 2f, -(src.height - size) / 2f)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Canvas(out).drawCircle(size / 2f, size / 2f, size / 2f, paint)
|
||||||
|
return out
|
||||||
|
}
|
||||||
|
|
||||||
|
/** MIB receipt placeholder: up to two initials in #1168F3 on a #C6E1FD circle. */
|
||||||
|
private fun makeMibInitialsBitmap(name: String): Bitmap {
|
||||||
val sizePx = (resources.displayMetrics.density * 52).toInt()
|
val sizePx = (resources.displayMetrics.density * 52).toInt()
|
||||||
val bgColor = try { Color.parseColor(colorHex) } catch (_: Exception) { Color.GRAY }
|
|
||||||
val bm = Bitmap.createBitmap(sizePx, sizePx, Bitmap.Config.ARGB_8888)
|
val bm = Bitmap.createBitmap(sizePx, sizePx, Bitmap.Config.ARGB_8888)
|
||||||
val canvas = Canvas(bm)
|
val canvas = Canvas(bm)
|
||||||
val paint = Paint(Paint.ANTI_ALIAS_FLAG)
|
val paint = Paint(Paint.ANTI_ALIAS_FLAG)
|
||||||
paint.color = bgColor
|
paint.color = Color.parseColor("#C6E1FD")
|
||||||
canvas.drawCircle(sizePx / 2f, sizePx / 2f, sizePx / 2f, paint)
|
canvas.drawCircle(sizePx / 2f, sizePx / 2f, sizePx / 2f, paint)
|
||||||
paint.color = Color.WHITE
|
paint.color = Color.parseColor("#1168F3")
|
||||||
paint.textSize = sizePx * 0.42f
|
paint.textSize = sizePx * 0.36f
|
||||||
paint.textAlign = Paint.Align.CENTER
|
paint.textAlign = Paint.Align.CENTER
|
||||||
val letter = name.firstOrNull()?.uppercaseChar()?.toString() ?: "?"
|
paint.typeface = android.graphics.Typeface.DEFAULT_BOLD
|
||||||
|
val initials = name.split(Regex("\\s+"))
|
||||||
|
.mapNotNull { word -> word.firstOrNull { it.isLetterOrDigit() }?.uppercaseChar() }
|
||||||
|
.take(2).joinToString("").ifEmpty { "?" }
|
||||||
val metrics = paint.fontMetrics
|
val metrics = paint.fontMetrics
|
||||||
canvas.drawText(letter, sizePx / 2f, sizePx / 2f - (metrics.ascent + metrics.descent) / 2f, paint)
|
canvas.drawText(initials, sizePx / 2f, sizePx / 2f - (metrics.ascent + metrics.descent) / 2f, paint)
|
||||||
return bm
|
return bm
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -129,6 +129,15 @@ class MibTransferHandler(
|
|||||||
else -> bankName.ifBlank { "LOCAL" }
|
else -> bankName.ifBlank { "LOCAL" }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
val isOwnAccount = isDestMib && app.mibAccounts.any {
|
||||||
|
it.accountNumber == destAccount && it.loginTag == src.loginTag &&
|
||||||
|
(src.profileId.isBlank() || it.profileId == src.profileId)
|
||||||
|
}
|
||||||
|
val transactionType = when {
|
||||||
|
isOwnAccount -> "Own Transfer"
|
||||||
|
isDestMib -> "MIB Transfer"
|
||||||
|
else -> "Quick Transfer"
|
||||||
|
}
|
||||||
return try {
|
return try {
|
||||||
// Switch to the profile that owns the source account
|
// Switch to the profile that owns the source account
|
||||||
if (src.profileId.isNotBlank()) {
|
if (src.profileId.isNotBlank()) {
|
||||||
@@ -160,7 +169,9 @@ class MibTransferHandler(
|
|||||||
toBank = toBank,
|
toBank = toBank,
|
||||||
remarks = remarks,
|
remarks = remarks,
|
||||||
mibReferenceNo = result.trxId,
|
mibReferenceNo = result.trxId,
|
||||||
mibTransactionDate = result.date
|
mibTransactionDate = result.date,
|
||||||
|
mibFromProfileName = src.profileName,
|
||||||
|
mibTransactionType = transactionType
|
||||||
)
|
)
|
||||||
Triple(true, "BankTransaction ID: ${result.trxId}\n${result.date}", receipt)
|
Triple(true, "BankTransaction ID: ${result.trxId}\n${result.date}", receipt)
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -40,6 +40,8 @@ object ReceiptStore {
|
|||||||
remarks = o.optString("remarks"),
|
remarks = o.optString("remarks"),
|
||||||
mibReferenceNo = o.optString("mibReferenceNo"),
|
mibReferenceNo = o.optString("mibReferenceNo"),
|
||||||
mibTransactionDate = o.optString("mibTransactionDate"),
|
mibTransactionDate = o.optString("mibTransactionDate"),
|
||||||
|
mibFromProfileName = o.optString("mibFromProfileName"),
|
||||||
|
mibTransactionType = o.optString("mibTransactionType"),
|
||||||
bmlFromName = o.optString("bmlFromName"),
|
bmlFromName = o.optString("bmlFromName"),
|
||||||
bmlReference = o.optString("bmlReference"),
|
bmlReference = o.optString("bmlReference"),
|
||||||
bmlTimestamp = o.optString("bmlTimestamp"),
|
bmlTimestamp = o.optString("bmlTimestamp"),
|
||||||
@@ -76,6 +78,8 @@ object ReceiptStore {
|
|||||||
put("remarks", d.remarks)
|
put("remarks", d.remarks)
|
||||||
put("mibReferenceNo", d.mibReferenceNo)
|
put("mibReferenceNo", d.mibReferenceNo)
|
||||||
put("mibTransactionDate", d.mibTransactionDate)
|
put("mibTransactionDate", d.mibTransactionDate)
|
||||||
|
put("mibFromProfileName", d.mibFromProfileName)
|
||||||
|
put("mibTransactionType", d.mibTransactionType)
|
||||||
put("bmlFromName", d.bmlFromName)
|
put("bmlFromName", d.bmlFromName)
|
||||||
put("bmlReference", d.bmlReference)
|
put("bmlReference", d.bmlReference)
|
||||||
put("bmlTimestamp", d.bmlTimestamp)
|
put("bmlTimestamp", d.bmlTimestamp)
|
||||||
|
|||||||
@@ -1,9 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
|
||||||
<gradient
|
|
||||||
android:startColor="#2E7D32"
|
|
||||||
android:centerColor="#43A047"
|
|
||||||
android:endColor="#66BB6A"
|
|
||||||
android:angle="315"
|
|
||||||
android:type="linear" />
|
|
||||||
</shape>
|
|
||||||
@@ -0,0 +1,77 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!-- Full MIB logo (mark + "MALDIVES ISLAMIC BANK" wordmark); wordmark follows the receipt footer text color -->
|
||||||
|
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:width="187.6dp"
|
||||||
|
android:height="22dp"
|
||||||
|
android:viewportWidth="779.5"
|
||||||
|
android:viewportHeight="91.4">
|
||||||
|
<path
|
||||||
|
android:fillColor="#FFFFFF"
|
||||||
|
android:strokeColor="#A8AAAC"
|
||||||
|
android:strokeWidth="3.8833"
|
||||||
|
android:strokeMiterLimit="10"
|
||||||
|
android:pathData="M64.6,89.2H26.7c-13.5,0-24.5-11-24.5-24.5v-38c0-13.5,11-24.5,24.5-24.5h37.9c13.5,0,24.5,11,24.5,24.5v37.9 C89.1,78.2,78.2,89.2,64.6,89.2z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#1E2859"
|
||||||
|
android:pathData="M49.4,28.7c1.7-1.7,3.5-3.3,5.4-4.8c1.9,1.5,3.7,3.1,5.4,4.8c9,9.2,14.4,21.7,14.4,35.3c0,0.7,0,1.5-0.1,2.2 H57.6l10.9-6.8c-0.5-6-2.4-11.8-5.6-17.2c-2.2-3.7-5-7-8.2-9.7c-3.2,2.7-5.9,6-8.2,9.7c-3.2,5.3-5,11.2-5.6,17.2l4.6,6.8H35 c0-0.7-0.1-1.5-0.1-2.2C34.9,50.3,40.4,37.9,49.4,28.7z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#006A4D"
|
||||||
|
android:pathData="M41.9,28.7c-1.7-1.7-3.5-3.3-5.4-4.8c-1.9,1.5-3.7,3.1-5.4,4.8c-9,9.2-14.4,21.7-14.4,35.3 c0,0.7,0,1.5,0.1,2.2h16.9l-10.9-6.8c0.5-6,2.4-11.8,5.6-17.2c2.2-3.7,5-7,8.2-9.7c3.2,2.7,5.9,6,8.2,9.7c3.2,5.3,5,11.2,5.6,17.2 l-4.6,6.8h10.6c0-0.7,0.1-1.5,0.1-2.2C56.3,50.3,50.8,37.9,41.9,28.7z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M146.4,49.5c-0.2-5.3-0.5-11.7-0.5-17.2h-0.2c-1.3,5-3,10.5-4.9,15.7l-6,17.8h-5.8l-5.5-17.5 c-1.6-5.2-3-10.8-4.1-15.9h-0.1c-0.2,5.4-0.4,11.9-0.7,17.5l-0.9,16.5h-7l2.7-41h9.9l5.4,16.5c1.5,4.8,2.7,9.7,3.8,14.2h0.2 c1.1-4.4,2.5-9.5,4.1-14.3l5.7-16.4h9.7l2.4,41h-7.3L146.4,49.5z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M170,54.6l-3.5,11.6h-7.7l13.1-41h9.6l13.3,41h-8L183,54.6H170z M181.7,49l-3.2-10.1 c-0.8-2.5-1.5-5.3-2.1-7.7h-0.1c-0.6,2.4-1.2,5.2-1.9,7.7L171.2,49H181.7z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M200.5,25.2h7.5V60h16.9v6.3h-24.3V25.2z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M230.5,25.8c3.3-0.5,7.5-0.9,11.9-0.9c7.7,0,13,1.6,16.7,4.7c4,3.2,6.4,8.1,6.4,15.1c0,7.3-2.5,12.8-6.4,16.3 c-4.1,3.7-10.6,5.6-18.6,5.6c-4.4,0-7.7-0.2-10.1-0.5V25.8z M237.9,60.5c1,0.2,2.6,0.2,4.1,0.2c9.7,0.1,15.5-5.3,15.5-15.7 c0.1-9.1-5.2-14.2-14.5-14.2c-2.4,0-4.1,0.2-5.1,0.4V60.5z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M279.5,25.2v41H272v-41H279.5z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M297.4,66.2l-13.3-41h8.2l5.6,18.6c1.6,5.2,2.9,10,4,15h0.1c1.1-4.9,2.6-9.9,4.2-14.8l6-18.7h8l-14.2,41 H297.4z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M347.6,48.1h-15.5v12h17.3v6.1h-24.8v-41h23.8v6.1h-16.4V42h15.5V48.1z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M355.8,58.1c2.4,1.4,6.1,2.6,9.9,2.6c4.8,0,7.5-2.3,7.5-5.6c0-3.1-2.1-4.9-7.3-6.8c-6.8-2.4-11.1-6-11.1-11.9 c0-6.7,5.6-11.8,14.5-11.8c4.4,0,7.7,1,9.9,2.1l-1.8,6c-1.5-0.8-4.3-1.9-8.2-1.9c-4.7,0-6.8,2.6-6.8,4.9c0,3.2,2.4,4.6,7.8,6.8 c7.1,2.7,10.6,6.3,10.6,12.2c0,6.6-5,12.3-15.6,12.3c-4.3,0-8.8-1.2-11.1-2.6L355.8,58.1z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M407.6,25.2v41h-7.5v-41H407.6z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M416,58.1c2.4,1.4,6.1,2.6,9.9,2.6c4.8,0,7.5-2.3,7.5-5.6c0-3.1-2.1-4.9-7.3-6.8c-6.8-2.4-11.1-6-11.1-11.9 c0-6.7,5.6-11.8,14.5-11.8c4.4,0,7.7,1,9.9,2.1l-1.8,6c-1.5-0.8-4.3-1.9-8.2-1.9c-4.7,0-6.8,2.6-6.8,4.9c0,3.2,2.4,4.6,7.8,6.8 c7.1,2.7,10.6,6.3,10.6,12.2c0,6.6-5,12.3-15.6,12.3c-4.3,0-8.8-1.2-11.1-2.6L416,58.1z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M447.8,25.2h7.5V60h16.9v6.3h-24.3V25.2z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M486.2,54.6l-3.5,11.6H475l13.1-41h9.6l13.3,41h-8l-3.7-11.6H486.2z M498,49l-3.2-10.1 c-0.8-2.5-1.5-5.3-2.1-7.7h-0.1c-0.6,2.4-1.2,5.2-1.9,7.7L487.4,49H498z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M551.1,49.5c-0.2-5.3-0.5-11.7-0.5-17.2h-0.2c-1.3,5-3,10.5-4.9,15.7l-6,17.8h-5.8l-5.5-17.5 c-1.6-5.2-3-10.8-4.1-15.9h-0.1c-0.2,5.4-0.4,11.9-0.7,17.5l-0.9,16.5h-7l2.7-41h9.9l5.4,16.5c1.5,4.8,2.7,9.7,3.8,14.2h0.2 c1.1-4.4,2.5-9.5,4.1-14.3l5.7-16.4h9.7l2.4,41h-7.3L551.1,49.5z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M574.3,25.2v41h-7.5v-41H574.3z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M612.3,65c-1.8,0.9-5.7,1.8-10.6,1.8c-13,0-20.9-8.2-20.9-20.6c0-13.5,9.4-21.7,21.9-21.7c4.9,0,8.5,1,10,1.8 l-1.6,6c-1.9-0.9-4.6-1.6-8-1.6c-8.3,0-14.4,5.2-14.4,15.1c0,9,5.3,14.8,14.3,14.8c3,0,6.2-0.6,8.2-1.5L612.3,65z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M631.3,25.8c2.4-0.5,6.7-0.9,10.9-0.9c5.5,0,8.9,0.7,11.7,2.6c2.6,1.5,4.3,4.2,4.3,7.7c0,3.8-2.4,7.2-6.8,8.9 v0.1c4.3,1.1,8.3,4.5,8.3,10.2c0,3.7-1.6,6.5-4,8.5c-2.9,2.6-7.7,3.8-15.2,3.8c-4.1,0-7.3-0.3-9.2-0.5V25.8z M638.7,42h3.8 c5.2,0,8.1-2.4,8.1-5.9c0-3.8-2.9-5.6-7.7-5.6c-2.2,0-3.5,0.1-4.3,0.3V42z M638.7,60.8c1,0.1,2.3,0.2,4,0.2c4.8,0,9.1-1.8,9.1-6.9 c0-4.7-4.1-6.7-9.3-6.7h-3.7V60.8z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M674.3,54.6l-3.5,11.6h-7.7l13.1-41h9.6l13.3,41h-8l-3.7-11.6H674.3z M686.1,49l-3.2-10.1 c-0.8-2.5-1.5-5.3-2.1-7.7h-0.1c-0.6,2.4-1.2,5.2-1.9,7.7L675.5,49H686.1z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M704.8,66.2v-41h8.5l10.6,17.6c2.7,4.6,5.1,9.3,7,13.7h0.1c-0.5-5.5-0.7-10.8-0.7-17V25.2h6.9v41h-7.7 l-10.7-18c-2.6-4.5-5.4-9.6-7.4-14.2l-0.2,0.1c0.3,5.3,0.4,10.7,0.4,17.5v14.7H704.8z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="@color/mib_receipt_footer_text"
|
||||||
|
android:pathData="M745.9,25.2h7.4v18.9h0.2c1-1.6,2-3,3-4.4l10.7-14.4h9.2l-14.1,17.5l15,23.5h-8.8L757,47.5l-3.7,4.4v14.4 h-7.4V25.2z" />
|
||||||
|
</vector>
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!-- MIB receipt header: solid green under the official app's translucent palm texture -->
|
||||||
|
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<item android:drawable="@color/mib_receipt_amount" />
|
||||||
|
<item>
|
||||||
|
<bitmap
|
||||||
|
android:src="@drawable/mib_receipt_texture"
|
||||||
|
android:gravity="fill" />
|
||||||
|
</item>
|
||||||
|
</layer-list>
|
||||||
Binary file not shown.
|
After Width: | Height: | Size: 107 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 196 KiB |
@@ -15,7 +15,7 @@
|
|||||||
android:overScrollMode="never"
|
android:overScrollMode="never"
|
||||||
android:scrollbars="none">
|
android:scrollbars="none">
|
||||||
|
|
||||||
<!-- Renderable receipt card (header grows to fill remaining space) -->
|
<!-- Renderable receipt card -->
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/receiptCard"
|
android:id="@+id/receiptCard"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
@@ -23,76 +23,34 @@
|
|||||||
android:layout_marginHorizontal="40dp"
|
android:layout_marginHorizontal="40dp"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical">
|
||||||
|
|
||||||
<!-- Green header — fills all space not taken by body -->
|
<!-- Green header — from/to avatars and names -->
|
||||||
<FrameLayout
|
<FrameLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="200dp"
|
android:layout_height="160dp"
|
||||||
android:background="@drawable/trx_success_bg">
|
android:background="@drawable/mib_receipt_header_bg">
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_gravity="center"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:gravity="center">
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="TRANSACTION RECEIPT"
|
|
||||||
android:textColor="#FFFFFF"
|
|
||||||
android:textSize="14sp"
|
|
||||||
android:letterSpacing="0.08"
|
|
||||||
android:layout_marginBottom="22dp" />
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:layout_width="64dp"
|
|
||||||
android:layout_height="64dp"
|
|
||||||
android:src="@drawable/ic_receipt_check"
|
|
||||||
android:contentDescription="@null" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="SUCCESSFUL"
|
|
||||||
android:textColor="#FFFFFF"
|
|
||||||
android:textSize="16sp"
|
|
||||||
android:letterSpacing="0.05"
|
|
||||||
android:layout_marginTop="18dp" />
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
</FrameLayout>
|
|
||||||
|
|
||||||
<!-- White body — fixed size content -->
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:background="#FFFFFF"
|
|
||||||
android:paddingTop="16dp">
|
|
||||||
|
|
||||||
<!-- Avatars row -->
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_gravity="center"
|
||||||
android:orientation="horizontal"
|
android:orientation="horizontal"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:paddingHorizontal="24dp"
|
android:paddingHorizontal="24dp">
|
||||||
android:paddingBottom="14dp">
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="0dp"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_weight="1"
|
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:gravity="center">
|
android:gravity="center">
|
||||||
|
|
||||||
<com.google.android.material.imageview.ShapeableImageView
|
<!-- Plain ImageView: bitmaps are circle-cropped in code (ShapeableImageView's
|
||||||
|
hardware-layer mask doesn't render on the scaled card or in captures) -->
|
||||||
|
<ImageView
|
||||||
android:id="@+id/ivFromAvatar"
|
android:id="@+id/ivFromAvatar"
|
||||||
android:layout_width="52dp"
|
android:layout_width="52dp"
|
||||||
android:layout_height="52dp"
|
android:layout_height="52dp"
|
||||||
app:shapeAppearanceOverlay="@style/ShapeAppearance.Circle" />
|
android:scaleType="fitCenter"
|
||||||
|
android:contentDescription="@null" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tvFromLabel"
|
android:id="@+id/tvFromLabel"
|
||||||
@@ -100,7 +58,9 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="6dp"
|
android:layout_marginTop="6dp"
|
||||||
android:textSize="12sp"
|
android:textSize="12sp"
|
||||||
android:textColor="#565656"
|
android:maxWidth="110dp"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:textColor="#FFFFFF"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:maxLines="2" />
|
android:maxLines="2" />
|
||||||
|
|
||||||
@@ -109,22 +69,25 @@
|
|||||||
<ImageView
|
<ImageView
|
||||||
android:layout_width="24dp"
|
android:layout_width="24dp"
|
||||||
android:layout_height="24dp"
|
android:layout_height="24dp"
|
||||||
android:layout_marginHorizontal="12dp"
|
android:layout_marginHorizontal="10dp"
|
||||||
android:src="@drawable/ic_arrow_right"
|
android:src="@drawable/ic_arrow_right"
|
||||||
|
android:tint="#FFFFFF"
|
||||||
android:contentDescription="@null" />
|
android:contentDescription="@null" />
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="0dp"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_weight="1"
|
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:gravity="center">
|
android:gravity="center">
|
||||||
|
|
||||||
<com.google.android.material.imageview.ShapeableImageView
|
<!-- Plain ImageView: bitmaps are circle-cropped in code (ShapeableImageView's
|
||||||
|
hardware-layer mask doesn't render on the scaled card or in captures) -->
|
||||||
|
<ImageView
|
||||||
android:id="@+id/ivToAvatar"
|
android:id="@+id/ivToAvatar"
|
||||||
android:layout_width="52dp"
|
android:layout_width="52dp"
|
||||||
android:layout_height="52dp"
|
android:layout_height="52dp"
|
||||||
app:shapeAppearanceOverlay="@style/ShapeAppearance.Circle" />
|
android:scaleType="fitCenter"
|
||||||
|
android:contentDescription="@null" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tvToLabel"
|
android:id="@+id/tvToLabel"
|
||||||
@@ -132,7 +95,9 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="6dp"
|
android:layout_marginTop="6dp"
|
||||||
android:textSize="12sp"
|
android:textSize="12sp"
|
||||||
android:textColor="#565656"
|
android:maxWidth="110dp"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:textColor="#FFFFFF"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:maxLines="2" />
|
android:maxLines="2" />
|
||||||
|
|
||||||
@@ -140,81 +105,92 @@
|
|||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="#CAC4D0" android:layout_marginHorizontal="20dp" />
|
</FrameLayout>
|
||||||
|
|
||||||
<!-- Total Amount -->
|
<!-- Body -->
|
||||||
<TextView
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="TOTAL AMOUNT"
|
android:orientation="vertical"
|
||||||
android:textSize="13sp"
|
android:background="@color/mib_receipt_bg">
|
||||||
android:textColor="#a0a2a1"
|
|
||||||
android:letterSpacing="0.08"
|
|
||||||
android:gravity="center"
|
|
||||||
android:paddingTop="10dp"
|
|
||||||
android:paddingBottom="4dp" />
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tvAmount"
|
android:id="@+id/tvAmount"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textSize="34sp"
|
android:textSize="24sp"
|
||||||
android:textColor="#f14f0f"
|
android:textStyle="bold"
|
||||||
|
android:textColor="@color/mib_receipt_amount"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:paddingBottom="10dp" />
|
android:paddingTop="14dp" />
|
||||||
|
|
||||||
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="#CAC4D0" android:layout_marginHorizontal="20dp" />
|
<TextView
|
||||||
|
android:id="@+id/tvStatus"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="Success"
|
||||||
|
android:textSize="14sp"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:textColor="@color/mib_receipt_amount"
|
||||||
|
android:gravity="center"
|
||||||
|
android:paddingBottom="6dp" />
|
||||||
|
|
||||||
<!-- Reference # -->
|
<!-- Transaction # -->
|
||||||
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
||||||
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Reference #" android:textSize="15sp" android:textColor="#a0a2a1" />
|
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="16dp" android:text="Transaction#" android:textSize="15sp" android:textColor="@color/mib_receipt_label" />
|
||||||
<View android:layout_width="0dp" android:layout_height="1dp" android:layout_weight="1" />
|
<TextView android:id="@+id/tvReferenceNo" android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" android:gravity="end" android:textSize="15sp" android:textColor="@color/mib_receipt_value" />
|
||||||
<TextView android:id="@+id/tvReferenceNo" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textSize="15sp" android:textColor="#565656" />
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="#CAC4D0" android:layout_marginHorizontal="20dp" />
|
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="@color/mib_receipt_divider" android:layout_marginHorizontal="20dp" />
|
||||||
|
|
||||||
<!-- To Account -->
|
<!-- From (sender profile name) -->
|
||||||
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
||||||
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="To Account" android:textSize="15sp" android:textColor="#a0a2a1" />
|
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="16dp" android:text="From" android:textSize="15sp" android:textColor="@color/mib_receipt_label" />
|
||||||
<View android:layout_width="0dp" android:layout_height="1dp" android:layout_weight="1" />
|
<TextView android:id="@+id/tvFromName" android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" android:gravity="end" android:textSize="15sp" android:textColor="@color/mib_receipt_value" />
|
||||||
<TextView android:id="@+id/tvToAccount" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textSize="15sp" android:textColor="#565656" />
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="#CAC4D0" android:layout_marginHorizontal="20dp" />
|
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="@color/mib_receipt_divider" android:layout_marginHorizontal="20dp" />
|
||||||
|
|
||||||
<!-- To Bank -->
|
<!-- To Account (recipient name + account number) -->
|
||||||
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
||||||
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="To Bank" android:textSize="15sp" android:textColor="#a0a2a1" />
|
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="16dp" android:text="To Account" android:textSize="15sp" android:textColor="@color/mib_receipt_label" />
|
||||||
<View android:layout_width="0dp" android:layout_height="1dp" android:layout_weight="1" />
|
<TextView android:id="@+id/tvToAccount" android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" android:gravity="end" android:textSize="15sp" android:textColor="@color/mib_receipt_value" />
|
||||||
<TextView android:id="@+id/tvToBank" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textSize="15sp" android:textColor="#565656" />
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="#CAC4D0" android:layout_marginHorizontal="20dp" />
|
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="@color/mib_receipt_divider" android:layout_marginHorizontal="20dp" />
|
||||||
|
|
||||||
|
<!-- Bank -->
|
||||||
|
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
||||||
|
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="16dp" android:text="Bank" android:textSize="15sp" android:textColor="@color/mib_receipt_label" />
|
||||||
|
<TextView android:id="@+id/tvToBank" android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" android:gravity="end" android:textSize="15sp" android:textColor="@color/mib_receipt_value" />
|
||||||
|
</LinearLayout>
|
||||||
|
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="@color/mib_receipt_divider" android:layout_marginHorizontal="20dp" />
|
||||||
|
|
||||||
|
<!-- Transaction Type -->
|
||||||
|
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
||||||
|
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="16dp" android:text="Transaction Type" android:textSize="15sp" android:textColor="@color/mib_receipt_label" />
|
||||||
|
<TextView android:id="@+id/tvTransactionType" android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" android:gravity="end" android:textSize="15sp" android:textColor="@color/mib_receipt_value" />
|
||||||
|
</LinearLayout>
|
||||||
|
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="@color/mib_receipt_divider" android:layout_marginHorizontal="20dp" />
|
||||||
|
|
||||||
<!-- Transaction Date -->
|
<!-- Transaction Date -->
|
||||||
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
||||||
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Transaction Date" android:textSize="15sp" android:textColor="#a0a2a1" />
|
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="16dp" android:text="Transaction Date" android:textSize="15sp" android:textColor="@color/mib_receipt_label" />
|
||||||
<View android:layout_width="0dp" android:layout_height="1dp" android:layout_weight="1" />
|
<TextView android:id="@+id/tvTransactionDate" android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" android:gravity="end" android:textSize="15sp" android:textColor="@color/mib_receipt_value" />
|
||||||
<TextView android:id="@+id/tvTransactionDate" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textSize="15sp" android:textColor="#565656" />
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="#CAC4D0" android:layout_marginHorizontal="20dp" />
|
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="@color/mib_receipt_divider" android:layout_marginHorizontal="20dp" />
|
||||||
|
|
||||||
<!-- Value Date -->
|
<!-- Processed Date -->
|
||||||
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
||||||
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Value Date" android:textSize="15sp" android:textColor="#a0a2a1" />
|
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="16dp" android:text="Processed Date" android:textSize="15sp" android:textColor="@color/mib_receipt_label" />
|
||||||
<View android:layout_width="0dp" android:layout_height="1dp" android:layout_weight="1" />
|
<TextView android:id="@+id/tvValueDate" android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" android:gravity="end" android:textSize="15sp" android:textColor="@color/mib_receipt_value" />
|
||||||
<TextView android:id="@+id/tvValueDate" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textSize="15sp" android:textColor="#565656" />
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="#CAC4D0" android:layout_marginHorizontal="20dp" />
|
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="@color/mib_receipt_divider" android:layout_marginHorizontal="20dp" />
|
||||||
|
|
||||||
<!-- Purpose -->
|
<!-- Remarks -->
|
||||||
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:paddingHorizontal="20dp" android:paddingVertical="11dp">
|
||||||
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Purpose" android:textSize="15sp" android:textColor="#a0a2a1" />
|
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="16dp" android:text="Remarks" android:textSize="15sp" android:textColor="@color/mib_receipt_label" />
|
||||||
<View android:layout_width="0dp" android:layout_height="1dp" android:layout_weight="1" />
|
<TextView android:id="@+id/tvPurpose" android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" android:gravity="end" android:textSize="15sp" android:textColor="@color/mib_receipt_value" />
|
||||||
<TextView android:id="@+id/tvPurpose" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textSize="15sp" android:textColor="#565656" />
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<!-- MIB footer -->
|
<!-- MIB footer -->
|
||||||
<View android:layout_width="match_parent" android:layout_height="1dp" android:background="#CAC4D0" android:layout_marginHorizontal="20dp" />
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
@@ -224,19 +200,10 @@
|
|||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="28dp"
|
android:layout_height="22dp"
|
||||||
android:src="@drawable/mib_logo"
|
android:src="@drawable/mib_logo_full"
|
||||||
android:adjustViewBounds="true"
|
android:adjustViewBounds="true"
|
||||||
android:contentDescription="@null" />
|
android:contentDescription="Maldives Islamic Bank" />
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginStart="8dp"
|
|
||||||
android:text="MALDIVES ISLAMIC BANK"
|
|
||||||
android:textSize="13sp"
|
|
||||||
android:textColor="#000000"
|
|
||||||
android:letterSpacing="0.05" />
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
|||||||
@@ -8,4 +8,11 @@
|
|||||||
<color name="bml_receipt_footer">#000000</color>
|
<color name="bml_receipt_footer">#000000</color>
|
||||||
<color name="bml_receipt_divider">#3D3E40</color>
|
<color name="bml_receipt_divider">#3D3E40</color>
|
||||||
<color name="bml_receipt_bottom_divider">#1E1F21</color>
|
<color name="bml_receipt_bottom_divider">#1E1F21</color>
|
||||||
|
|
||||||
|
<!-- MIB receipt — dark mode -->
|
||||||
|
<color name="mib_receipt_bg">#1A1A3C</color>
|
||||||
|
<color name="mib_receipt_label">#FFFFFF</color>
|
||||||
|
<color name="mib_receipt_value">#FFFFFF</color>
|
||||||
|
<color name="mib_receipt_divider">#33335C</color>
|
||||||
|
<color name="mib_receipt_footer_text">#FFFFFF</color>
|
||||||
</resources>
|
</resources>
|
||||||
|
|||||||
@@ -15,4 +15,12 @@
|
|||||||
<color name="bml_receipt_divider">#E9E9E9</color>
|
<color name="bml_receipt_divider">#E9E9E9</color>
|
||||||
<color name="bml_receipt_bottom_divider">#EBEBEB</color>
|
<color name="bml_receipt_bottom_divider">#EBEBEB</color>
|
||||||
<color name="bml_red">#E21B23</color>
|
<color name="bml_red">#E21B23</color>
|
||||||
|
|
||||||
|
<!-- MIB receipt (dark variants in values-night/colors.xml) -->
|
||||||
|
<color name="mib_receipt_bg">#FFFFFF</color>
|
||||||
|
<color name="mib_receipt_label">#000000</color>
|
||||||
|
<color name="mib_receipt_value">#000000</color>
|
||||||
|
<color name="mib_receipt_divider">#CAC4D0</color>
|
||||||
|
<color name="mib_receipt_footer_text">#000000</color>
|
||||||
|
<color name="mib_receipt_amount">#1EA833</color>
|
||||||
</resources>
|
</resources>
|
||||||
|
|||||||
Reference in New Issue
Block a user