-
Notifications
You must be signed in to change notification settings - Fork 364
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
refactor: [M3-8986] - Refactor VPCEditDrawer and SubnetEditDrawer to use react-hook-form
#11393
refactor: [M3-8986] - Refactor VPCEditDrawer and SubnetEditDrawer to use react-hook-form
#11393
Conversation
.max(64, LABEL_MESSAGE) | ||
.matches(/[a-zA-Z0-9-]+/, LABEL_REQUIREMENTS); | ||
.matches(/^[a-zA-Z0-9-]*$/, LABEL_REQUIREMENTS); | ||
|
||
export const updateVPCSchema = object({ | ||
label: labelValidation.notRequired(), | ||
description: string().notRequired(), | ||
label: labelValidation, | ||
description: string(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- fixes regex so that it checks against all characters, not just the first one, for non letter/number characters (besides dashes)
- removed the
notRequired()
since that led to type errors when using the schema:Type 'Maybe<string | undefined>' is not assignable to type 'string | undefined'. Type 'null' is not assignable to type 'string | undefined'.
Removing this makes the schema align better with the payload too, so I don't think this will be an issue
adding wait to merge label for this - some VPCCreate tests are currently failing due to validation punctuation changes, planning to merge #11357 first and then rebase this and fix any conflicts/tests that emerge after (still ready for review tho) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Solid refactor
- code refactor ✅
- VPCEditDrawer ✅
- SubnetEditDrawer ✅
- Error handling ✅
Approving pending test resolutions as noted in PR
1d9c73f
to
95e80e3
Compare
95e80e3
to
d4f1e72
Compare
Coverage Report: ✅ |
Cloud Manager UI test results🎉 469 passing tests on test run #5 ↗︎
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the udpates @coliu-akamai! 🎉
Cloud Manager E2E Run #6960
Run Properties:
|
Project |
Cloud Manager E2E
|
Branch Review |
develop
|
Run status |
Passed #6960
|
Run duration | 31m 02s |
Commit |
cf84950015: refactor: [M3-8986] - Refactor VPCEditDrawer and SubnetEditDrawer to use `react-...
|
Committer | Connie Liu |
View all properties for this run ↗︎ |
Test results | |
---|---|
Failures |
0
|
Flaky |
3
|
Pending |
2
|
Skipped |
0
|
Passing |
469
|
View all changes introduced in this branch ↗︎ |
Description 📝
Changes 🔄
How to test 🧪
Author Checklists
As an Author, to speed up the review process, I considered 🤔
👀 Doing a self review
❔ Our contribution guidelines
🤏 Splitting feature into small PRs
➕ Adding a changeset
🧪 Providing/improving test coverage
🔐 Removing all sensitive information from the code and PR description
🚩 Using a feature flag to protect the release
👣 Providing comprehensive reproduction steps
📑 Providing or updating our documentation
🕛 Scheduling a pair reviewing session
📱 Providing mobile support
♿ Providing accessibility support
As an Author, before moving this PR from Draft to Open, I confirmed ✅