diff --git a/.assets/demo_thumbnail.png b/.assets/demo_thumbnail.png index 52c9646..da54e98 100644 Binary files a/.assets/demo_thumbnail.png and b/.assets/demo_thumbnail.png differ diff --git a/CHANGELOG.md b/CHANGELOG.md index 7d6cd69..e11005f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,14 @@ # _BulletinBoard_ Changelog +## 🔖 v1.3.0 + +- Add customizable bulletin backgrounds +- Refactor swipe-to-dismiss: use animation controllers +- Add interactive dismissal (animated background blur radius / opacity) +- Improve iPhone X support: display a blurred bar at the bottom of the safe area to highlight the home indicator +- Simplify layout +- Various documentation and codebase improvements + ## 🔖 v1.2.0 - Dismiss the bulletin by swiping down @@ -13,4 +22,4 @@ ## 🔖 v1.0.0 -- Inital Release \ No newline at end of file +- Inital Release diff --git a/README.md b/README.md index 4266058..93e95e7 100644 --- a/README.md +++ b/README.md @@ -35,7 +35,7 @@ Build and run the `Instanimal` scheme to use it. Here's a video showing it in action: -[![Watch Demo on YouTube](https://raw.githubusercontent.com/alexaubry/BulletinBoard/master/.assets/demo_thumbnail.png)](https://youtu.be/36pFHov7MTE) +[![Watch Demo on YouTube](https://raw.githubusercontent.com/alexaubry/BulletinBoard/master/.assets/demo_thumbnail.png)](https://youtu.be/DT58Lz7qpTA) ## Installation @@ -46,7 +46,7 @@ BulletinBoard is available via CocoaPods and Carthage. To install BulletinBoard using [CocoaPods](https://cocoapods.org), add this line to your `Podfile`: ~~~ruby -pod "BulletinBoard" +pod 'BulletinBoard' ~~~ ### Carthage @@ -212,7 +212,7 @@ This creates the following interaction: ![Next Item](https://raw.githubusercontent.com/alexaubry/BulletinBoard/master/.assets/demo_segue.png) -## +## Displaying an Activity Indicator If you need to perform a task between the moment the user taps a button and the moment you'll be able to change the presented item, you can call `displayActivityIndicator()` method on the item manager to hide the current card and display an activity indicator. @@ -236,6 +236,25 @@ This creates the following interaction: ![Activity Indicator](https://raw.githubusercontent.com/alexaubry/BulletinBoard/master/.assets/demo_activity.png) +## Customizing the Background View + +By default, the content behind the card is covered with a semi-opaque view (known as the `.dimming` style). + +You can customize the background view by changing the `backgroundViewStyle` property of the manager before calling `prepare()`. + +**Example**: + +~~~swift +manager.backgroundViewStyle = .blurredExtraLight +manager.prepare() +~~~ + +Several styles are available in the `BulletinBackgroundViewStyle` enum: + +![Dimming View](https://raw.githubusercontent.com/alexaubry/BulletinBoard/master/.assets/demo_background_styles.png) + +> Note: blurred backgrounds are available in iOS 10.0 and later. + ## Dismissal If you set the `isDismissable` property to `true`, the user will be able to dismiss the bulletin by tapping outside of the card or by swiping the card down. @@ -266,7 +285,7 @@ Even though you are creating a custom card, you may still want to display some s To generate standard elements, use the methods of `BulletinInterfaceFactory`: -- `makeTitleLabel()` to create a title label +- `makeTitleLabel(reading:)` to create a title label with the given title - `makeDescriptionLabel(isCompact:)` to create a description label - `makeActionButton(title:)` to create an action button - `makeAlternativeButton(title:)` to create an alternative button