Move settings + generation to sheets

This commit is contained in:
Christoph Hagen
2025-02-05 15:40:09 +01:00
parent 5abe6e1a9f
commit 156bbf77d1
32 changed files with 402 additions and 852 deletions

View File

@ -0,0 +1,26 @@
import SwiftUI
struct SelectableListItem<Content>: View where Content: View {
let content: Content
let selected: Bool
public init(selected: Bool, @ViewBuilder content: () -> Content) {
self.selected = selected
self.content = content()
}
var body: some View {
HStack {
content
Spacer()
}
.foregroundStyle(selected ? Color.white : Color.primary)
.listRowBackground(RoundedRectangle(cornerRadius: 5)
.fill(selected ? Color.blue : Color.clear)
.padding(.horizontal, 10)
)
.contentShape(Rectangle())
}
}