NativeScript / NativeScript/angular
Modal route issue - route runs twice when returning from second modal containing route outlet
還沒有人認領這個 Issue。
- 主要語言
- TypeScript
- 星號
- 55
- 分支
- 13
- 平均合併
- 16 分鐘
- 30 天內合併 PR
- 1
描述
This is most evident in iOS. I've set up a demo app:
https://stackblitz.com/edit/nativescript-stackblitz-templates-vwcmqt
In iOS, if you follow the steps (they're numbered) you'll see that when you navigate back on step five, the animation runs twice—backwards then forwards. This appears to come from the shouldDetach method NSRouteReuseStrategy. If I use the previous code for shouldDetatch that was altered here:
https://github.com/NativeScript/angular/commit/bebcde23c4d6a392638c23ec1e2bc63b06a9b43e
then it works without problem.
NOTE: For this demo, I've used 14.2.6-alpha.0 because without it, I can't use modals with ModalDialogParams because of injector scope issues. However, this router problem described above also occurs in 14.2.5 when the modal corrections are in place. Either way, something isn't working as it should.
貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
研究方向
從 NSRouteReuseStrategy.shouldDetach 方法開始,並將它與 commit beb cde23c4d6a392638c23ec1e2bc63b06a9b43e 中較早的實作進行比較。在 iOS 上重現連結的 StackBlitz 示範中的編號流程,包括從包含 route outlet 的第二個 modal 返回。完成的標準是:第五步的返回導覽只執行一次動畫,而不是先反向執行再正向執行。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- angular, typescript
- 領域
- frontend, mobile-dev
- Issue 類型
- 缺陷
- 難度
- 4/5
- 預估耗時
- 3-5 天
- 活躍度
- 停滯
- 描述清晰度
- 基本清楚
- 新手友好度
- 35/100