conversations-classic-ios/ConversationsClassic/View/Screens/Attachments/AttachmentPickerScreen.swift
2024-07-04 10:21:12 +02:00

40 lines
956 B
Swift

import SwiftUI
struct AttachmentPickerScreen: View {
@EnvironmentObject var store: AppStore
@State private var selectedTab: AttachmentTab = .media
var body: some View {
ZStack {
// Background color
Color.Material.Background.light
.ignoresSafeArea()
// Content
VStack(spacing: 0) {
// Header
AttachmentHeader()
// Pickers
switch selectedTab {
case .media:
AttachmentMediaPickerView()
case .files:
AttachmentFilesPickerView()
case .location:
AttachmentLocationPickerView()
case .contacts:
AttachmentContactsPickerView()
}
// Tab bar
AttachmentTabBar(selectedTab: $selectedTab)
}
}
}
}