Sesame-iOS/Sesame-Watch Watch App/Settings/SettingsTextItemLink.swift
2023-08-09 16:29:18 +02:00

31 lines
721 B
Swift

import SwiftUI
struct SettingsTextItemLink: View {
let title: String
@Binding
var value: String
let footnote: String
var body: some View {
NavigationLink {
SettingsTextInputView(
title: title,
text: $value,
footnote: footnote
)
} label: {
SettingsListTextItem(title: title, value: value)
}
.buttonStyle(PlainButtonStyle())
}
}
struct SettingsTextItemLink_Previews: PreviewProvider {
static var previews: some View {
SettingsTextItemLink(title: "Title", value: .constant("Some value"), footnote: "Some more text explaining the purpose of the text field.")
}
}