mirror of
https://github.com/yattee/yattee.git
synced 2024-12-13 13:50:32 +05:30
21 lines
438 B
Swift
21 lines
438 B
Swift
import SwiftUI
|
|
|
|
struct CoverSectionRowView<ControlContent: View>: View {
|
|
let label: String?
|
|
let controlView: ControlContent
|
|
|
|
init(_ label: String? = nil, @ViewBuilder controlView: @escaping () -> ControlContent) {
|
|
self.label = label
|
|
self.controlView = controlView()
|
|
}
|
|
|
|
var body: some View {
|
|
HStack {
|
|
Text(label ?? "")
|
|
|
|
Spacer()
|
|
controlView
|
|
}
|
|
}
|
|
}
|