-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
test: Shadow PR for 36320 (external contribution test) #36381
test: Shadow PR for 36320 (external contribution test) #36381
Conversation
…-error-does-not-disappear
…-error-does-not-disappear
… of https://github.com/a6hishekpandey/appsmith into fix/35949-duplicate-page-name-error-does-not-disappear
…-error-does-not-disappear
WalkthroughThe changes in the pull request focus on enhancing the validation logic for the page name input within the Changes
Assessment against linked issues
Suggested labels
Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
Documentation and Community
|
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.
Actionable comments posted: 1
Review details
Configuration used: .coderabbit.yaml
Review profile: CHILL
Files selected for processing (1)
- app/client/src/pages/Editor/AppSettingsPane/AppSettings/PageSettings.tsx (4 hunks)
Additional comments not posted (4)
app/client/src/pages/Editor/AppSettingsPane/AppSettings/PageSettings.tsx (4)
74-74
: Good work on initializing thepageNameError
state variable!Using a
string | null
type allows for more informative error messages compared to just a boolean flag. This will provide a better user experience when displaying validation errors.
127-130
: Excellent use of theuseEffect
hook to reset thepageNameError
state!Clearing the error state when the
page
prop changes is a thoughtful touch. It ensures that stale error messages from previous pages don't linger and confuse the user. This enhances the overall user experience when navigating between pages. Well done!
132-132
: Great job with thesavePageName
condition!The condition checks are in the perfect order. First, it confirms the user has permission to manage pages. Then it verifies there are no page name errors. Finally, it checks if the page name has actually changed before initiating a save. This sequence of checks optimizes both security and performance. Nicely done!
188-188
: Nice use of conditional CSS classes based on thepageNameError
state!Adjusting the padding when there is no error message is a subtle but impactful UI enhancement. It maintains a consistent and polished look in the page settings form. The negation check on
pageNameError
is also logically sound. Good attention to detail!
app/client/src/pages/Editor/AppSettingsPane/AppSettings/PageSettings.tsx
Outdated
Show resolved
Hide resolved
…-name-error-does-not-disappear' into external-contri/fix/35949-duplicate-page-name-error-does-not-disappear
…name-error-does-not-disappear
Description
Duplicate page name error does not disappear on navigating to other pages.
This PR addresses issue #35949 by resetting the isPageNameValid state to undefined using useEffect hook when the Page settings loads.
Fixes #35949
Warning
If no issue exists, please create an issue first, and check with the maintainers if the issue is valid.
Automation
/ok-to-test tags="@tag.All"
🔍 Cypress test results
Tip
🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
Workflow run: https://github.com/appsmithorg/appsmith/actions/runs/10941077447
Commit: f2a4c6f
Cypress dashboard.
Tags:
@tag.All
Spec:
Thu, 19 Sep 2024 15:59:24 UTC
Communication
Should the DevRel and Marketing teams inform users about this change?
Summary by CodeRabbit