-
Notifications
You must be signed in to change notification settings - Fork 4
Refactor ReportPackageForm to use controlled form inputs and update logic #1608
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
base: master
Are you sure you want to change the base?
Refactor ReportPackageForm to use controlled form inputs and update logic #1608
Conversation
WalkthroughThe changes refactor form state management in ReportPackageForm from internal local state (useReducer) to external controlled inputs. The useReportPackage hook now manages formInputs state internally and passes it to the component via three new props: formInputs, updateFormInput, and resetFormInputs. The component delegates field updates (reason, description) to updateFormInput callbacks and triggers resetFormInputs on successful form submission. A createInitialFormInputs helper initializes default form state. Possibly related PRs
Pre-merge checks and finishing touches❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (1 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (2)
🧰 Additional context used🧬 Code graph analysis (2)apps/cyberstorm-remix/app/p/components/ReportPackage/ReportPackageForm.tsx (1)
apps/cyberstorm-remix/app/p/components/ReportPackage/useReportPackage.tsx (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
🔇 Additional comments (9)
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 |
This stack of pull requests is managed by Graphite. Learn more about stacking. |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1608 +/- ##
=========================================
- Coverage 9.86% 9.85% -0.01%
=========================================
Files 309 309
Lines 22555 22566 +11
Branches 405 405
=========================================
Hits 2224 2224
- Misses 20331 20342 +11 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|

No description provided.