NativeScript / NativeScript/angular

Modal route issue - route runs twice when returning from second modal containing route outlet

オープン
#96 コメント 1 件 リアクション 2 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

主要言語
TypeScript
スター
55
フォーク
13
平均マージ
16分
マージ済み PR(30日)
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.

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

NSRouteReuseStrategy.shouldDetach メソッドから始め、commit beb cde23c4d6a392638c23ec1e2bc63b06a9b43e の以前の実装と比較してください。リンク先の StackBlitz デモの番号付きフローを iOS 上で再現し、route outlet を含む 2 番目のモーダルから戻る操作も含めてください。完了条件は、5 番目のステップの戻るナビゲーションでアニメーションが逆方向と順方向に実行されるのではなく、1 回だけ実行されることです。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
angular, typescript
領域
frontend, mobile-dev
issue の種類
バグ
難易度
4/5
見積もり時間
3〜5日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
35/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。