urbanairship / ios-library

Urban Airship iOS SDK
http://urbanairship.com
Apache License 2.0
478 stars 265 forks source link

Preference Center title disappears in the UIKit-based app #390

Closed ppluskota closed 6 months ago

ppluskota commented 7 months ago

Preliminary Info

What Airship dependencies are you using?

Airship Core, MessageCenter, Automation, PreferenceCenter - Version 17.7.3

What are the versions of any relevant development tools you are using?

Xcode 15.2 - iOS 16

Report

What unexpected behavior are you seeing?

Preference Center title disappears right after I open the screen on iOS 16 and 15. I have noticed that the issue was introduced in the 17.7.0 version. I'm not seeing the problem in 17.6.1

What is the expected behavior?

Preference Center title shouldn't disappear

What are the steps to reproduce the unexpected behavior?

I have an app with UIKit. I'm using a custom theme to set a title and fonts. Here is the code that you can use to reproduce the issue:

            var theme = PreferenceCenterTheme()
            theme.viewController = PreferenceCenterTheme.ViewController(
                navigationBar: PreferenceCenterTheme.NavigationBar(
                    title: "Settings",
                    backgroundColor: .label
                )
            )

            theme.contactSubscription = PreferenceCenterTheme.ContactSubscription(
                titleAppearance: PreferenceCenterTheme.TextAppearance(
                    font: .headline
                ),
                subtitleAppearance: PreferenceCenterTheme.TextAppearance(
                    font: .caption
                )
            )

            PreferenceCenter.shared.theme = theme
            PreferenceCenter.shared.open("some_valid_id")
rlepinski commented 6 months ago

This was fixed in 17.8