26 lines
598 B
Swift
26 lines
598 B
Swift
|
import SwiftUI
|
||
|
|
||
|
struct KeyView: View {
|
||
|
|
||
|
@Binding
|
||
|
var keyManager: KeyManagement
|
||
|
|
||
|
var body: some View {
|
||
|
GeometryReader { geo in
|
||
|
VStack(alignment: .leading, spacing: 16) {
|
||
|
ForEach(KeyManagement.KeyType.allCases) { keyType in
|
||
|
SingleKeyView(
|
||
|
keyManager: $keyManager,
|
||
|
type: keyType)
|
||
|
}
|
||
|
}.padding()
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
|
||
|
struct KeyView_Previews: PreviewProvider {
|
||
|
static var previews: some View {
|
||
|
KeyView(keyManager: .constant(KeyManagement()))
|
||
|
}
|
||
|
}
|