         }
         updateConstraintsIfNeeded()
     }
-  
+    
     @objc internal func didTap(_ recognizer: UITapGestureRecognizer) {
         if dismissesOnTap {
             dismiss()

        view.addSubview(self)
        forceUpdates()
        let (damping, velocity) = self.springiness.springValues
        let oldStatusBarStyle = UIApplication.shared.statusBarStyle
        if adjustsStatusBarStyle {
          UIApplication.shared.setStatusBarStyle(preferredStatusBarStyle, animated: true)
        }
        UIView.animate(withDuration: animationDuration, delay: 0.0, usingSpringWithDamping: damping, initialSpringVelocity: velocity, options: .allowUserInteraction, animations: {
            self.bannerState = .showing
            }, completion: { finished in
                guard let duration = duration else { return }
                DispatchQueue.main.asyncAfter(deadline: DispatchTime.now() + DispatchTimeInterval.milliseconds(Int(1000.0 * duration))) {
                    self.dismiss(self.adjustsStatusBarStyle ? oldStatusBarStyle : nil)
                }
        })
    }
  
    /// Dismisses the banner.
    open func dismiss(_ oldStatusBarStyle: UIStatusBarStyle? = nil) {
        guard bannerState == .showing else { return }
        let (damping, velocity) = self.springiness.springValues
        UIView.animate(withDuration: animationDuration, delay: 0.0, usingSpringWithDamping: damping, initialSpringVelocity: velocity, options: .allowUserInteraction, animations: {
            self.bannerState = .hidden
            if let oldStatusBarStyle = oldStatusBarStyle {
                UIApplication.shared.setStatusBarStyle(oldStatusBarStyle, animated: true)
            }
            }, completion: { finished in
                self.bannerState = .gone
                self.removeFromSuperview()
                self.didDismissBlock?()
        })
    }
}

        label.numberOfLines = 0
        label.translatesAutoresizingMaskIntoConstraints = false
        return label
    }()
    
    /// The label that displays the banner's subtitle.
    @objc public let detailLabel: UILabel = {
