         super.traitCollectionDidChange(previousTraitCollection)
         font = UIFont.wmf_font(.body, compatibleWithTraitCollection: traitCollection)
         placeholderLabel.font = font
+    }
+
+    override func layoutSubviews() {
+        super.layoutSubviews()
+        guard !placeholderLabel.isHidden else {
+            return
+        }
+        let placeholderLabelHeight = placeholderLabel.sizeThatFits(CGSize(width: frame.width, height: UIView.noIntrinsicMetric)).height
+        if frame.size.height != placeholderLabelHeight {
+            frame.size.height = placeholderLabelHeight + textContainerInset.top + textContainerInset.bottom
+        }
+        let placeholderLabelSize = CGSize(width: frame.size.width, height: frame.size.height)
+        if placeholderLabel.frame.size != placeholderLabelSize {
+            placeholderLabel.frame.size = placeholderLabelSize
+        }
+    }
+
+    override var intrinsicContentSize: CGSize {
+        guard !placeholderLabel.isHidden else {
+            return super.intrinsicContentSize
+        }
+        let placeholderLabelHeight = placeholderLabel.sizeThatFits(CGSize(width: frame.width, height: UIView.noIntrinsicMetric)).height
+        let heightPlusInset = placeholderLabelHeight + textContainerInset.top + textContainerInset.bottom
+        return CGSize(width: super.intrinsicContentSize.width, height: heightPlusInset)
     }
 }
 

            delegate = self
            placeholderLabel.numberOfLines = 0
            addSubview(placeholderLabel)
            let placeholderLabelX: CGFloat
            if let selectedTextRange = selectedTextRange {
                let caretPosition = caretRect(for: selectedTextRange.start)
                placeholderLabelX = caretPosition.maxX
            } else {
                placeholderLabelX = 0
            }
            placeholderLabel.frame.origin = CGPoint(x: placeholderLabelX, y: (font?.pointSize)! / 2)
            placeholderLabel.isHidden = !text.isEmpty
        }
    }

    required public init?(coder aDecoder: NSCoder) {

        didSet {
            if usesPlaceholder {
                placeholderLabel.text = placeholder
                placeholderLabel.frame.size = placeholderLabel.sizeThatFits(frame.size)
            }
        }
    }
