Repository navigation
StrictModeでPortal経由のモーダルが表示されない問題を修正 - #6109
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 4.8 <[email protected]>
Contributor
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthrough
ChangesPortal アンマウント処理の StrictMode 対応
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Suggested labels
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
Merged
4 of 9 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
概要
React Compiler 導入(#6095)でルートに
<StrictMode>を追加して以降、開発ビルドで長押しメニューの「設定」など Portal 経由のモーダルが表示されなくなっていた問題を、@gorhom/portalへの patch-package パッチで修正します。変更の種類
変更内容
patches/@gorhom+portal+1.0.14.patchを追加。@gorhom/[email protected]のPortalコンポーネントは mount effect の cleanup でhandleOnMountRef/handleOnUnmountRef/handleOnUpdateRefをundefinedに潰していた。mount → unmount → remountでシミュレートするため、unmount で ref が破棄され、remount 時のhandleOnMountRef.current?.()が no-op 化 → Portal がホストへ再登録されず、モーダルが描画されなかった。src(Metro が読むreact-native/sourceエントリ)とlib/module/lib/commonjsの 3 経路すべてをパッチ。CustomModal(= Portal)経由で開く全モーダル(設定・種別選択・テーマ・フィードバック等)が StrictMode 有効のまま表示されるようになる。本番ビルドは StrictMode 無効のため元々非発生。テスト
npm run lintが通ることnpm testが通ることnpm run typecheckが通ること関連Issue
スクリーンショット(任意)
Summary by CodeRabbit
リリースノート