Proyectos de Subversion Iphone Microlearning - Nuevo Interface

Rev

Rev 11 | Rev 61 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 11 Rev 17
Línea 8... Línea 8...
8
import Foundation
8
import Foundation
Línea 9... Línea 9...
9
 
9
 
10
import Foundation
10
import Foundation
11
import SwiftUI
11
import SwiftUI
12
import PDFKit
-
 
13
import NavigationStack
12
import PDFKit
Línea 14... Línea 13...
14
import HTMLEntities
13
import HTMLEntities
-
 
14
 
Línea 15... Línea -...
15
 
-
 
16
 
-
 
17
struct WebViewerView: View {
-
 
18
 
15
 
19
    @State private var backToGallery : Bool = false
16
struct WebViewerView: View {
-
 
17
    @EnvironmentObject private var appNavigation : AppNavigation
Línea 20... Línea -...
20
    
-
 
21
    private let appDao = AppDao.sharedInstance
-
 
22
    private var slideModel : SlideModel
-
 
23
    private var slideTitle : String
18
 
24
 
19
    private var slideModel : SlideModel
25
 
20
    private var slideTitle : String
26
    
21
    private var appData = AppData.sharedInstance
Línea 27... Línea 22...
27
    
22
 
28
    init(slideUuid : String)
23
    init()
29
    {
24
    {
30
        let slideDao = SlideDao.sharedInstance
25
        let slideDao = SlideDao.sharedInstance
Línea 40... Línea 35...
40
    }
35
    }
Línea 41... Línea 36...
41
    
36
    
42
    var body: some View {
37
    var body: some View {
43
        VStack(spacing: 0)
38
        VStack(spacing: 0)
44
        {
-
 
45
            PopView(
-
 
46
                destination: .root,
-
 
47
                isActive: self.$backToGallery,
-
 
48
                label: {
-
 
49
                    Text("")
-
 
50
                    
-
 
51
                }
-
 
Línea 52... Línea 39...
52
            ).frame( height: 0)
39
        {
53
            
40
            
54
            HStack {
41
            HStack {
55
                Button(action: {
42
                Button(action: {
-
 
43
                    let dataService = DataService()
-
 
44
                    dataService.completeSlide(slide: slideModel)
56
                    let dataService = DataService()
45
                    
Línea 57... Línea 46...
57
                    dataService.completeSlide(slide: slideModel)
46
                    
Línea 58... Línea 47...
58
                    self.backToGallery.toggle()
47
                    appNavigation.pageActive = .home
Línea 95... Línea 84...
95
}
84
}
Línea 96... Línea 85...
96
 
85
 
97
 
86
 
98
struct WebViewerView_Previews: PreviewProvider {
87
struct WebViewerView_Previews: PreviewProvider {
99
    static var previews: some View {
88
    static var previews: some View {
100
        WebViewerView(slideUuid: "S123")
89
        WebViewerView()