[#1174] Final not enough free space UI

- The UI has been updated according to the latest design

[#1174] Final not enough free space UI (#1175)

- tweaks

[#1174] Final not enough free space UI (#1175)

- removed mocked state of disk
This commit is contained in:
Lukas Korba 2024-04-04 13:07:27 +02:00
parent 215e745522
commit f73b6dc9e1
3 changed files with 19 additions and 8 deletions

View File

@ -25,13 +25,18 @@ public struct NotEnoughFreeSpaceView: View {
ZashiErrorIcon()
.padding(.vertical, 20)
Text(L10n.NotEnoughFreeSpace.message(store.freeSpaceRequiredForSync, store.freeSpace))
.font(.custom(FontFamily.Inter.regular.name, size: 14))
Text(L10n.NotEnoughFreeSpace.message1(store.freeSpaceRequiredForSync, store.freeSpace))
.font(.custom(FontFamily.Inter.bold.name, size: 22))
.multilineTextAlignment(.center)
.padding(.bottom, 20)
Text(L10n.NotEnoughFreeSpace.message2)
.font(.custom(FontFamily.Inter.regular.name, size: 17))
.multilineTextAlignment(.center)
Spacer()
}
.padding(.horizontal, 60)
.padding(.horizontal, 53)
.padding(.vertical, 1)
.onAppear { store.send(.onAppear) }
.navigationBarTitleDisplayMode(.inline)

View File

@ -236,10 +236,15 @@ public enum L10n {
public static let message = L10n.tr("Localizable", "nefs.message", fallback: "Not enough space on disk to do synchronisation!")
}
public enum NotEnoughFreeSpace {
/// Zashi requires at least %@ GB of space to operate but there is only %@ MB available. Go to your device settings and make more space available if you wish to use the Zashi app.
public static func message(_ p1: Any, _ p2: Any) -> String {
return L10n.tr("Localizable", "notEnoughFreeSpace.message", String(describing: p1), String(describing: p2), fallback: "Zashi requires at least %@ GB of space to operate but there is only %@ MB available. Go to your device settings and make more space available if you wish to use the Zashi app.")
/// Zashi requires at
/// least %@ GB of space to
/// operate but there is only
/// %@ MB available.
public static func message1(_ p1: Any, _ p2: Any) -> String {
return L10n.tr("Localizable", "notEnoughFreeSpace.message1", String(describing: p1), String(describing: p2), fallback: "Zashi requires at\nleast %@ GB of space to\noperate but there is only\n%@ MB available.")
}
/// Go to your device settings and make more space available if you wish to use the Zashi app.
public static let message2 = L10n.tr("Localizable", "notEnoughFreeSpace.message2", fallback: "Go to your device settings and make more space available if you wish to use the Zashi app.")
/// Not enough free space
public static let title = L10n.tr("Localizable", "notEnoughFreeSpace.title", fallback: "Not enough free space")
}

View File

@ -179,7 +179,8 @@
// MARK: - Not Enogh Free Space
"notEnoughFreeSpace.title" = "Not enough free space";
"notEnoughFreeSpace.message" = "Zashi requires at least %@ GB of space to operate but there is only %@ MB available. Go to your device settings and make more space available if you wish to use the Zashi app.";
"notEnoughFreeSpace.message1" = "Zashi requires at\nleast %@ GB of space to\noperate but there is only\n%@ MB available.";
"notEnoughFreeSpace.message2" = "Go to your device settings and make more space available if you wish to use the Zashi app.";
// MARK: - Settings
"settings.feedback" = "Send us feedback";