// // LegalDocumentView.swift // Bible-Week // // Renderiza documentos legais em HTML usando o WebView nativo do SwiftUI/WebKit. // import SwiftUI import WebKit struct LegalDocumentView: View { let title: String let htmlFileName: String private var fileURL: URL? { Bundle.main.url(forResource: htmlFileName, withExtension: "html") } var body: some View { Group { if let url = fileURL { WebView(url: url) } else { ContentUnavailableView( "Documento não encontrado", systemImage: "doc.slash", description: Text("O documento não pôde ser carregado.") ) } } .navigationTitle(title) .navigationBarTitleDisplayMode(.inline) } }