Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IOS-7990: [Markets] Fix navigation issues on iOS 18 #3881

Merged

Conversation

m3g0byt3
Copy link
Contributor

@m3g0byt3 m3g0byt3 commented Sep 18, 2024

IOS-7990

Причина - при убирании из иерархии вьюх и последующем добавлении обратно nav view с уже открытым чилдом (деталкой маркетсов в данном случае) nav view восстанавливает весь навигационный стек с анимациями (на ios 17 и ниже было без анимаций, стек сразу восстанавливался).

Дело не в модельном слое, никакие координаторы/vm не умирают, то есть navigation links не меняют своего стейта - а в SUI

Поэтому нормальное и красивое убираение шита через published item пришлось заменить на флажок и скрытие вьюхи

Comment on lines 151 to +158
mainBottomSheetUIManager
.isShownPublisher
.filter { $0 }
.withWeakCaptureOf(self)
.map { coordinator, isShown in
return isShown ? coordinator.__marketsCoordinator : nil
.sink { coordinator, _ in
coordinator.setupMainBottomSheetCoordinatorIfNeeded()
}
.assign(to: \.marketsCoordinator, on: self, ownership: .weak)
.store(in: &bag)
Copy link
Contributor Author

@m3g0byt3 m3g0byt3 Sep 18, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Надо лениво создавать координатор, чтобы шторка не была видима на экране логина

Этого можно было бы избежать, если бы AppCoordinatorView дергала onChange(of: coordinator.isOverlayContentContainerShown) для initial state, но это ios 17+

Проверил - при разлогине у меня на 17 все ок, но надо проверить разлогин и на 18
оранжевый цвет - для дебага

Untitled.mp4

@m3g0byt3 m3g0byt3 added the release ASAP to look label Sep 18, 2024
@m3g0byt3 m3g0byt3 marked this pull request as ready for review September 18, 2024 11:08
@m3g0byt3 m3g0byt3 requested review from tureck1y and a team as code owners September 18, 2024 11:08
@m3g0byt3 m3g0byt3 changed the title IOS-7990: Fix navigation issues on iOS 18 IOS-7990: [Markets] Fix navigation issues on iOS 18 Sep 18, 2024
… ones are broken on iOS 18+

Signed-off-by: Andrey Fedorov <[email protected]>
Comment on lines -65 to -68
.animation(
.easeInOut(duration: viewModel.overlayContentHidingAnimationDuration),
value: viewModel.overlayContentHidingProgress
)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

implicit animations сломались на 18 оси

@m3g0byt3 m3g0byt3 force-pushed the bugfix/IOS-7990_fix_navigation_issues_on_ios_18 branch from e0d8780 to 3b66800 Compare September 18, 2024 13:51
Copy link
Collaborator

@tureck1y tureck1y left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

проверил на 18 - ок

@tureck1y tureck1y merged commit f73350a into releases/5.15 Sep 18, 2024
2 of 3 checks passed
@tureck1y tureck1y deleted the bugfix/IOS-7990_fix_navigation_issues_on_ios_18 branch September 18, 2024 15:49
Balashov152 pushed a commit that referenced this pull request Sep 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release ASAP to look
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants