Fix issue with balance loading appearance

During the implementation of the "hide balance" feature, the balance
view was refactored in a way that caused it to not be redacted anymore,
making it show the "??" instead of the intended skeleton loader.

This commit fixes that issue without reverting the hide balance feature.

Changelog-Fixed: Fixed issue where the text "??" would appear on the balance while loading
Signed-off-by: Daniel D’Aquino <daniel@daquino.me>
This commit is contained in:
Daniel D’Aquino
2025-06-16 16:38:05 -07:00
parent 99ae7de5eb
commit f4b1a504a5

View File

@@ -22,7 +22,12 @@ struct BalanceView: View {
else {
// Make sure we do not show any numeric value to the user when still loading (or when failed to load)
// This is important because if we show a numeric value like "zero" when things are not loaded properly, we risk scaring the user into thinking that they have lost funds.
self.numericalBalanceView(text: "??")
Text(verbatim: "??")
.lineLimit(1)
.minimumScaleFactor(0.70)
.font(.veryVeryLargeTitle)
.fontWeight(.heavy)
.foregroundStyle(PinkGradient)
.redacted(reason: .placeholder)
.shimmer(true)
}