I'd like to be able to place a background image behind the three sign-in buttons (for Google, Facebook, and Email) of the FirebaseUI login screen. FirebaseUI login is a drop-in authentication solution for iOS, Android, and Web. I'm having trouble with iOS.
There's a little bit of advice on Github, but not enough.
I first initialize my var customAuthPickerViewController : FIRAuthPickerViewController! near the top of the ViewController.swift file.
Then, this is the function in my ViewController.swift file, but it's not working. When I click the logout button, the app crashes, and no background image is ever shown.
// Customize the sign-in screen to have the Bizzy Books icon/background image
func authPickerViewController(for authUI: FIRAuthUI) -> FIRAuthPickerViewController {
customAuthPickerViewController = authPickerViewController(for: authUI)
backgroundImage = UIImageView(image: UIImage(named: "bizzybooksbee"))
backgroundImage.contentMode = UIViewContentMode.scaleAspectFill
customAuthPickerViewController.view.addSubview(backgroundImage)
return customAuthPickerViewController
}
The background image "bizzybooksbee" is a Universal Image Set with 1x, 2x, and 3x images already loaded in my Assets.xcassets folder.
Here's a picture of what the login screen looks like without trying to implement the background image.
UPDATE: I'm able to get the image to show, with the code I gave in the comments below, but it shows OVER the sign-in buttons, as in the pic below.
Here's an image of the "heirarchy," with Jeffrey's help:


