Skip to content
SwiftUIBlurView lets you use UIBlurEffect in SwiftUI.
Swift Ruby
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.swiftpm/xcode Commit uncommited version changes Oct 7, 2019
Fastlane Update version script and update podspec with Swift version Oct 7, 2019
Resources Update icon and readme Sep 14, 2019
Sources/SwiftUIBlurView Create new correctly configured SPM Xcode project Oct 7, 2019
SwiftUIBlurView.xcodeproj Update version script and update podspec with Swift version Oct 7, 2019
SwiftUIBlurViewDemo Create new correctly configured SPM Xcode project Oct 7, 2019
Tests Create new correctly configured SPM Xcode project Oct 7, 2019
.gitignore Add accidentally ignored project files Oct 1, 2019
.swiftlint.yml Create new correctly configured SPM Xcode project Oct 7, 2019
LICENSE Add tested SwiftUI blur view Sep 12, 2019
Package.swift Add tested SwiftUI blur view Sep 12, 2019
README.md
SwiftUIBlurView.podspec Update version script and update podspec with Swift version Oct 7, 2019

README.md

Version Swift UI Swift 5.1 License Twitter: @danielsaidi

About SwiftUIBlurView

SwiftUIBlurView lets you use UIBlurEffect in SwiftUI. This gives you access to all system blur effects, like .regular, .prominent, .systemMaterial and many more.

To blur any SwiftUI view, just place a BlurView above it:

ZStack {
    Image("photo").frame(width: 200, height: 200)   // This is blurred
    BlurView(.prominent)
    Image("photo").frame(width: 100, height: 100)   // This is not blurred
}

The result looks like this:

The demo application embedded in this project lets you see all system blur effects in action in light and dark mode.

Installation

Swift Package Manager

The easiest way to add SwiftUIBlurView to your project is to use Swift Package Manager:

https://github.com/danielsaidi/SwiftUIBlurView.git

CocoaPods

pod "SwiftUIBlurView"

Carthage

github "danielsaidi/SwiftUIBlurView"

Demo App

This project contains a demo app that shows all available blur styles in dark and light mode. To run the demo app, open and run the SwiftUIBlurView.xcodeproj project.

Contact me

Feel free to reach out if you have questions or if you want to contribute in any way:

License

SwiftUIBlurView is available under the MIT license. See LICENSE file for more info.

You can’t perform that action at this time.