Changed membership settings dialogs to controlled components - #30016
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: QUIET Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan includes up to 10 reviews per rolling hour; 4 remain after this review. 📜 Recent review details⏰ Context from checks skipped due to timeout. (2)
🧰 Additional context used📓 Path-based instructions (6)**/*.{ts,tsx}📄 CodeRabbit inference engine (Custom checks)
Files:
**/*📄 CodeRabbit inference engine (AGENTS.md)
Files:
⚙️ CodeRabbit configuration file
Files:
apps/admin/**/*.{js,jsx,ts,tsx}📄 CodeRabbit inference engine (AGENTS.md)
Files:
**/*.{ts,tsx,mts,cts}⚙️ CodeRabbit configuration file
Files:
apps/{admin,activitypub,admin-x-framework,shade}/**/*.{ts,tsx}⚙️ CodeRabbit configuration file
Files:
**/*{.,-}{test,spec}.{js,jsx,ts,tsx}⚙️ CodeRabbit configuration file
Files:
🧠 Learnings (4)📚 Learning: 2026-04-30T10:51:48.759ZApplied to files:
📚 Learning: 2026-07-21T19:57:01.324ZApplied to files:
📚 Learning: 2026-06-04T15:15:20.265ZApplied to files:
📚 Learning: 2026-08-08T20:30:54.860ZApplied to files:
🔇 Additional comments (1)
WalkthroughSettings email and membership screens replace NiceModal with local React state. Converted modals receive explicit Suggested reviewers: Merge Risk: ⚪ Minimal · up to This change localizes membership and email settings dialogs as controlled components, with reported acceptance, TypeScript, and lint checks passing; no actionable merge-blocking risk remains beyond normal review. 🚥 Pre-merge checks | ✅ 6✅ Passed checks (6 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
| Command | Status | Duration | Result |
|---|---|---|---|
nx run @tryghost/admin:test:acceptance |
✅ Succeeded | 6m 47s | View ↗ |
nx run-many -t test:unit -p @tryghost/admin |
✅ Succeeded | 2m 39s | View ↗ |
nx run ghost-monorepo:lint:boundaries |
✅ Succeeded | 21s | View ↗ |
nx run @tryghost/admin:build |
✅ Succeeded | 17s | View ↗ |
nx run-many -t lint -p @tryghost/admin,ghost-mo... |
✅ Succeeded | 1m 14s | View ↗ |
nx run-many --target=build --projects=tag:publi... |
✅ Succeeded | <1s | View ↗ |
💡 Verify your cache is correct by running tasks in a sandbox. Read docs ↗
☁️ Nx Cloud last updated this comment at 2026-08-18 14:49:53 UTC
no ref The custom field, welcome email and welcome email customize dialogs were the last NiceModal.create dialogs in the membership and email settings areas. They now take an onClose prop and are rendered by the component that opens them: the two SettingsModal dialogs through the settings dialog portal so they paint above the settings chrome, and the customize dialog directly, since its EmailDesignModal is already a portalled Shade Dialog. With these converted, no settings dialog is created or shown through NiceModal any more, which clears the way to remove the provider, the dependency and the compatibility bridges.
6c473c7 to
ad184ce
Compare
no ref The modal now closes through parent-controlled state, so the old NiceModal cleanup rationale no longer describes the assertion.
|
Reviewed in two independent passes (dialog lifecycle/stacking and tests/accessibility/async behavior), followed by a final re-review cycle after the fix. One maintenance issue was found and fixed in No remaining actionable findings. Verification:
|

no ref
Uses the settings
DialogPortalfrom #30014.The custom field, welcome email and welcome email customize dialogs were the last
NiceModal.createdialogs in the membership and email settings areas. They now take anonCloseprop and are rendered by the component that opens them: the twoSettingsModaldialogs through the settings dialog portal so they paint above the settings chrome, and the customize dialog directly, since itsEmailDesignModalis already a portalled ShadeDialog.With these converted (plus #30014 and #30015), no settings dialog is created or shown through NiceModal any more, which clears the way to remove the provider, the dependency and the compatibility bridges.
Verification
pnpm test:acceptance src/settings/membership src/settings/email— 114/114 (custom fields, welcome emails and the customize dialog already had thorough coverage; the welcome-email save test is what caught the stacking-context problem the portal fixes)tsc --noEmitand eslint clean onapps/admin