Meshtastic-Apple/Meshtastic/Views/Messages/TextMessageField/TextMessageSize.swift

21 lines
465 B
Swift
Raw Normal View History

import SwiftUI
struct TextMessageSize: View {
let maxbytes: Int
let totalBytes: Int
var body: some View {
2025-02-15 12:17:22 -08:00
ProgressView("\("Bytes".localized): \(totalBytes) / \(maxbytes)", value: Double(totalBytes), total: Double(maxbytes))
.frame(width: 130)
.padding(5)
.font(.subheadline)
.accentColor(.accentColor)
}
}
struct TextMessageSizePreview: PreviewProvider {
static var previews: some View {
TextMessageSize(maxbytes: 200, totalBytes: 100)
}
}