When the app is brought to the foreground from an external action (e.g., tapping on the widget, opening from a notification), a notification is posted (with a slight delay).
`MasterFeedViewController` and `SettingsViewController` are observers. `MasterFeedViewController` will dismiss any `SFSafariViewController`s that are presented, while `SettingsViewController` will dismiss itself.
- `try` added where applicable to ArticleTheme inits
- `ArticleThemePlist` has fixed spelling of theme identifier and conforms to Equatable
- `ArticleTheme` now uses `ArticleThemePlist`
- `ArticleThemeDownloader` is now a class
- `ArticleThemeDownloader` will now download themes to Application Support/NetNewsWire/Downloads on macOS and iOS.
- `ArticleThemeDownloader` will remove downloaded themes from the Download folder when the application is closed.
- macOS app delegate now observes for theme download fails
- Error display code moved from SceneDelegate to SceneCoordinator so that it can use existing presentError on rootVC.
Fixes#2057
• On app launch, the app checks if notification permissions are granted and registers with APNS if that is the case. It will not request permissions as part of the app launch.
• When a user requests to be notified of new articles, the authorizationStatus is checked:
- if `notDetermined` or `provisional`, an authorization request is made, and if successful, the Notify of New Articles status is updated (otherwise it is reverted)
- if `denied`, an alert is thrown asking the user to enable in settings (and the change to notify of new articles is reverted)
- if `authorized` the update is made.
`WebFeedInspectorViewController` also monitors for the app entering the foreground so that it can get the latest notification auth settings.