mirror of
				https://github.com/yattee/yattee.git
				synced 2025-11-04 14:42:05 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			27 lines
		
	
	
		
			702 B
		
	
	
	
		
			Swift
		
	
	
	
	
	
			
		
		
	
	
			27 lines
		
	
	
		
			702 B
		
	
	
	
		
			Swift
		
	
	
	
	
	
import Defaults
 | 
						|
import SwiftUI
 | 
						|
 | 
						|
struct VideoDetailsOverlay: View {
 | 
						|
    @EnvironmentObject<PlayerControlsModel> private var controls
 | 
						|
 | 
						|
    var body: some View {
 | 
						|
        VideoDetails(sidebarQueue: .constant(false), fullScreen: fullScreenBinding)
 | 
						|
            .clipShape(RoundedRectangle(cornerRadius: 4))
 | 
						|
    }
 | 
						|
 | 
						|
    var fullScreenBinding: Binding<Bool> {
 | 
						|
        .init(get: {
 | 
						|
            controls.presentingDetailsOverlay
 | 
						|
        }, set: { newValue in
 | 
						|
            controls.presentingDetailsOverlay = newValue
 | 
						|
        })
 | 
						|
    }
 | 
						|
}
 | 
						|
 | 
						|
struct VideoDetailsOverlay_Previews: PreviewProvider {
 | 
						|
    static var previews: some View {
 | 
						|
        VideoDetailsOverlay()
 | 
						|
            .injectFixtureEnvironmentObjects()
 | 
						|
    }
 | 
						|
}
 |