File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
DJSemiModalViewController/Classes Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -77,7 +77,7 @@ open class DJSemiModalViewController: UIViewController {
7777 /**
7878 * Adjust content height automatically
7979 */
80- public var automaticallyAdjustsContentHeight : Bool = false
80+ public var automaticallyAdjustsContentHeight : Bool = true
8181
8282 /**
8383 * The title label for the view
@@ -271,6 +271,10 @@ extension DJSemiModalViewController {
271271 scrollViewHeightLayoutConstraint. constant = automaticallyAdjustsContentHeight ? size. height : stackView. frame. height
272272 scrollViewHeightLayoutConstraint. isActive = scrollViewHeightLayoutConstraint. constant > 0.0
273273
274+
275+ contentView. setNeedsUpdateConstraints ( )
276+ contentView. layoutIfNeeded ( )
277+
274278 view. setNeedsUpdateConstraints ( )
275279
276280 UIView . animate ( withDuration: 0.25 , animations: {
You can’t perform that action at this time.
0 commit comments