iOS 15适配

    let baImage = UIImage.init(color: .init(hex: 0x171717))
    tabBar.backgroundImage = baImage
    let appearance = UITabBarAppearance()
        let effectView = UIVisualEffectView.init(effect: UIBlurEffect.init(style: .light))
        appearance.backgroundImage = baImage
        if #available(iOS 15.0, *) {
            self.tabBar.standardAppearance = appearance
            self.tabBar.scrollEdgeAppearance = appearance
        } else {
            // Fallback on earlier versions
        }

你可能感兴趣的:(iOS 15适配)