import SwiftUI

struct SettingsListTextItem: View {

    let title: String

    let value: String

    var body: some View {
        VStack(alignment: .leading) {
            HStack {
                Text(title)
                    .foregroundColor(.primary)
                Spacer()
            }
            Text(value)
                .font(.footnote)
                .foregroundColor(.secondary)
                .lineLimit(1)
        }
        .padding()
    }
}

struct SettingsListTextItem_Previews: PreviewProvider {
    static var previews: some View {
        SettingsListTextItem(
            title: "Title",
            value: "Some longer text")
    }
}
