Releases: SwiftKickMobile/SwiftMessages
6.0.2
Swift 4.2
Fix Demo app
Fixes
- Remove debug code that broke the view controller's section of the Demo app.
View Controllers
Breaking Changes
- Removed support for iOS 8.
Features
- Add support for modal view controller presentation using
SwiftMessagesSegue
custom segue subclass. Try it out in the "View Controllers" section of the Demo app. In addition to the class documentation, more can be found in the View Controllers readme. - Update nib files to be more visually consistent with iPhone X:
- Introduce
CornerRoundingView
, which provides configurable corner rounding using squircles (the smoother method of rounding corners that you see on app icons). Nib files that feature rounded corners have theirbackgroundView
assigned to aCornerRoundingView
.CornerRoundingView
provides aroundsLeadingCorners
option to dynamically round only the leading corners of the view when presented from top or bottom (a feature used for the tab-style layouts). - Increased the default corner radius to 20. Corner radius can be changed by either modifying the nib file or
- Introduce
- Reworked the
MarginAdjustable
to improve configurability of layout margins. - Add rubber-banding to the interactive dismissal gesture. Rubber banding is automatically applied for views where
backgroundView
is inset from the message view's edges. - Added
showDuration
andhideDuration
properties to theAnimator
protocol (with default implementation that returnsnil
). These values enable animations to work for view controller presentation.
Fixes
Whoops
Support Extensions
Swift 4.1
4.1.0
Features
- Fix #134 add support for
CenterAnimation
displayed on top or bottom instead of center (renamed toPhysicsAnimation
).
Fixes
iOS 11 and iPhone X
Features
-
Swift 4.0 syntax
-
Added support for iOS 11 and iPhone X. From the readme:
SwiftMessages 4 supports iOS 11 out-of-the-box with built-in support for safe areas. To ensur that message view layouts look just right when overlapping safe areas, views that adopt the
MarginAdjustable
protocol (likeMessageView
) will have their layout margins automatically adjusted by SwiftMessages. However, there is no one-size-fits-all adjustment, so the following properties were added toMarginAdjustable
to allow for additional adjustments to be made to the layout margins:public protocol MarginAdjustable { ... /// Safe area top adjustment in iOS 11+ var safeAreaTopOffset: CGFloat { get set } /// Safe area bottom adjustment in iOS 11+ var safeAreaBottomOffset: CGFloat { get set } }
If you're using using custom nib files or view classes and your layouts don't look quite right, try adjusting the values of these properties.
BaseView
(the super class ofMessageView
) declares these properties to be@IBDesignable
and you can find sample values in the nib files included with SwiftMessages.
Bug Fixes
- Fix #100 memory leak.
- Change
Layout
enum capitalization to current Swift conventions.
3.5.1: Fix nib file class reference
Bug Fixes
- Undo change that broke
MessageView
class reference on nib files copied out of the SwiftMessages framework.