Minor nits.

This commit is contained in:
Tosin Afolabi 2019-03-14 13:56:15 -07:00
parent 2b3029333e
commit ae78bd6f64
4 changed files with 5 additions and 5 deletions

View File

@ -809,12 +809,12 @@ private extension PanModalPresentationController {
drawAroundDragIndicator(currentPath: path, indicatorLeftEdgeXPos: indicatorLeftEdgeXPos)
}
// 6. Set path as a mask to display optional drag indicator view & rounded corners
// Set path as a mask to display optional drag indicator view & rounded corners
let mask = CAShapeLayer()
mask.path = path.cgPath
view.layer.mask = mask
// 7. Improve performance by rasterizing the layer
// Improve performance by rasterizing the layer
view.layer.shouldRasterize = true
view.layer.rasterizationScale = UIScreen.main.scale
}

View File

@ -78,7 +78,7 @@ public extension PanModalPresentable where Self: UIViewController {
}
var cornerRadius: CGFloat {
return 8
return 8.0
}
var showDragIndicator: Bool {

View File

@ -140,7 +140,7 @@ public protocol PanModalPresentable {
/**
The corner radius used when `shouldRoundTopCorners` is enabled.
Default Value is `8.0`
Default Value is 8.0
*/
var cornerRadius: CGFloat { get }

View File

@ -59,7 +59,7 @@ class PanModalTests: XCTestCase {
XCTAssertEqual(vc.shouldRoundTopCorners, false)
XCTAssertEqual(vc.showDragIndicator, false)
XCTAssertEqual(vc.shouldRoundTopCorners, false)
XCTAssertEqual(vc.cornerRadius, 8)
XCTAssertEqual(vc.cornerRadius, 8.0)
}
func testPresentableYValues() {