         initialNavigationBarPercentHidden = navigationBar.navigationBarPercentHidden
     }
 
+    // This is used by OnThisDayViewController to fix a problem with the UnderbarView
     public func setIsProgramaticallyScrolling(_ isProgramaticallyScrolling: Bool, yOffset: CGFloat, topContentInset: CGFloat) {
         guard navigationBar?.isInteractiveHidingEnabled == true else {
             return

        setDataForScroll(yOffset: scrollView.contentOffset.y, topContentInset: scrollView.contentInset.top)
    }

    @objc public func scrollViewDidScroll(_ scrollView: UIScrollView) {
        guard let navigationBar = navigationBar else {
            return

    fileprivate var isUserScrolling: Bool = false
    fileprivate var isScrollingToTop: Bool = false
    fileprivate var isProgramaticallyScrolling: Bool = false
    fileprivate var initialScrollY: CGFloat = 0
    fileprivate var initialNavigationBarPercentHidden: CGFloat = 0

    private func setDataForScroll(yOffset: CGFloat, topContentInset: CGFloat) {
        guard let navigationBar = navigationBar else {
