         closeButton.setContentHuggingPriority(UILayoutPriority.required, for: .horizontal)
         closeButton.addTarget(self, action: #selector(closeButtonTapped), for: .touchUpInside)
 
-        let titleLabel = UILabel.label(withText: title ?? "", font: titleFont, alignment: .center)
+        let titleLabel = UILabel.label(withText: title ?? "", font: titleFont, textColor: tintColor, alignment: .center)
         titleLabel.minimumScaleFactor = 0.5
         titleLabel.adjustsFontSizeToFitWidth = true
         titleLabel.allowsDefaultTighteningForTruncation = true


        let titleAndCloseButtonView = UIView(frame: .zero)

        let closeButton = UIButton.button(withImageSetName: "close", emphasisSuffix: "-filled", tintColor: .black)
        titleAndCloseButtonView.addSubview(closeButton)
        closeButton.topAnchor == titleAndCloseButtonView.topAnchor
        closeButton.bottomAnchor == titleAndCloseButtonView.bottomAnchor


    private var closeBlock: (() -> ())?

    public init(childViewController: UIViewController, titleFont: UIFont, backgroundColor: UIColor = .clear, tintColor: UIColor = .white, onClose closeBlock: (() -> ())? = nil) {
        super.init(nibName: nil, bundle: nil)

        view.backgroundColor = backgroundColor
