Server Offline Activity Indicator (#6314)

* Server Offline Activity Indicator

- implemented
This commit is contained in:
Gil Eluard
2022-07-05 14:04:52 +02:00
committed by GitHub
parent 4c84d1b15c
commit f91e84af00
15 changed files with 179 additions and 14 deletions
@@ -23,7 +23,7 @@ import MatrixSDK
/// It is managed by an `UserIndicator`, meaning the `present` and `dismiss` methods will be called when the parent `UserIndicator` starts or completes.
class ToastViewPresenter: UserIndicatorViewPresentable {
struct Constants {
static let navigationBarPatting = CGFloat(10)
static let navigationBarPatting = CGFloat(12)
}
private let viewState: ToastViewState
@@ -50,7 +50,7 @@ class ToastViewPresenter: UserIndicatorViewPresentable {
navigation.view.addSubview(view)
NSLayoutConstraint.activate([
view.centerXAnchor.constraint(equalTo: navigation.view.centerXAnchor),
view.topAnchor.constraint(equalTo: navigation.navigationBar.safeAreaLayoutGuide.bottomAnchor, constant: -Constants.navigationBarPatting)
view.topAnchor.constraint(equalTo: navigation.navigationBar.safeAreaLayoutGuide.bottomAnchor, constant: Constants.navigationBarPatting)
])
} else {
viewController.view.addSubview(view)