Skip to content

A small package that provides a picture in picture modifier for SwiftUI

Notifications You must be signed in to change notification settings

kemkriszt/SwiftUIPiP

Repository files navigation

SwiftUIPiP

version

A small package that provides a picture in picture modifier for SwiftUI

The pip view can be moved by the user to all four corners and can be resized to three different sizes

Usage

VStack {
    Text("Hello, World!")
}
.frame(minWidth: 0,
       maxWidth: .infinity, 
       minHeight: 0, 
       maxHeight: .infinity)
.background(Color.red)
.pip {
    Color.yellow
        .clipShape(RoundedRectangle(cornerRadius: 15.0))
}

Output

Preview

About

A small package that provides a picture in picture modifier for SwiftUI

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages