constraindWidth
Signed-off-by: Matt Bruce <matt.bruce@verizon.com>
This commit is contained in:
parent
ae460b8e4f
commit
b5f3e37a4c
@ -647,7 +647,14 @@ public enum LayoutDistribution: String, CaseIterable {
|
||||
case fillProportionally
|
||||
}
|
||||
|
||||
extension LayoutConstraintable where Self: UIView {
|
||||
public var constrainedWidth: CGFloat {
|
||||
horizontalPinnedWidth() ?? (superview?.frame.size.width ?? frame.size.width)
|
||||
}
|
||||
}
|
||||
|
||||
extension LayoutConstraintable {
|
||||
|
||||
public func removeConstraints() {
|
||||
guard let view = self as? UIView, let superview = view.superview else { return }
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user