Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 84256152dc |
@@ -1,6 +1,7 @@
|
||||
Pod::Spec.new do |s|
|
||||
|
||||
s.name = "SPStorkController"
|
||||
s.version = "1.5.8"
|
||||
s.version = "1.6"
|
||||
s.summary = "Modal controller as mail or Apple music application"
|
||||
s.homepage = "https://github.com/IvanVorobei/SPStorkController"
|
||||
s.source = { :git => "https://github.com/IvanVorobei/SPStorkController.git", :tag => s.version }
|
||||
@@ -8,11 +9,11 @@ Pod::Spec.new do |s|
|
||||
|
||||
s.author = { "Ivan Vorobei" => "hello@ivanvorobei.by" }
|
||||
|
||||
s.swift_version = '4.2'
|
||||
s.swift_version = '4.2', '5.0'
|
||||
s.platform = :ios
|
||||
s.ios.framework = 'UIKit'
|
||||
s.ios.deployment_target = "10.0"
|
||||
|
||||
s.source_files = "Source/SPStorkController/**/*.swift"
|
||||
end
|
||||
|
||||
|
||||
end
|
||||
@@ -68,24 +68,6 @@ class SPStorkPresentationController: UIPresentationController, UIGestureRecogniz
|
||||
|
||||
override var frameOfPresentedViewInContainerView: CGRect {
|
||||
guard let containerView = containerView else { return .zero }
|
||||
/*var customHeight = self.customHeight ?? containerView.bounds.height
|
||||
print(customHeight "\(customHeight)")
|
||||
print("containerView.bounds.height \(containerView.bounds.height)")
|
||||
if customHeight > containerView.bounds.height {
|
||||
customHeight = containerView.bounds.height
|
||||
print("SPStorkController - Custom height change to default value. Your height more maximum value")
|
||||
}
|
||||
let additionTranslate = containerView.bounds.height - customHeight
|
||||
let yOffset: CGFloat = {
|
||||
if customHeight < containerView.bounds.height {
|
||||
return additionTranslate
|
||||
} else {
|
||||
return self.topSpace + 13 + additionTranslate
|
||||
}
|
||||
}()
|
||||
print("yOffset \(yOffset)")
|
||||
return CGRect(x: 0, y: yOffset, width: containerView.bounds.width, height: containerView.bounds.height - yOffset)*/
|
||||
|
||||
let baseY: CGFloat = self.topSpace + 13
|
||||
let maxHeight: CGFloat = containerView.bounds.height - baseY
|
||||
var height: CGFloat = maxHeight
|
||||
@@ -97,7 +79,6 @@ class SPStorkPresentationController: UIPresentationController, UIGestureRecogniz
|
||||
print("SPStorkController - Custom height change to default value. Your height more maximum value")
|
||||
}
|
||||
}
|
||||
|
||||
return CGRect(x: 0, y: containerView.bounds.height - height, width: containerView.bounds.width, height: height)
|
||||
}
|
||||
|
||||
@@ -369,7 +350,7 @@ extension SPStorkPresentationController {
|
||||
if self.indicatorView.alpha == newAlpha {
|
||||
return
|
||||
}
|
||||
UIView.animate(withDuration: 0.22, animations: {
|
||||
UIView.animate(withDuration: 0.18, animations: {
|
||||
self.indicatorView.alpha = newAlpha
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user