Generate pages, image descriptions

This commit is contained in:
Christoph Hagen
2024-12-06 21:59:36 +01:00
parent 18eb64f289
commit 5fb689ac7c
42 changed files with 1653 additions and 273 deletions

View File

@ -0,0 +1,19 @@
struct ContentPageVideo: HtmlProducer {
let filePath: String
let videoType: String
let options: [VideoOption]
func populate(_ result: inout String) {
result += "<video\(optionString)>Video not supported."
result += "<source src='\(filePath)' type='\(videoType)'>"
result += "</video>"
}
private var optionString: String {
options.map { " " + $0.rawValue }.joined()
}
}