-
Notifications
You must be signed in to change notification settings - Fork 3.8k
feat: allow renaming rule before creation #8793
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
Conversation
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.
2 issues found across 5 files
Prompt for AI agents (all 2 issues)
Understand the root cause of the following 2 issues and fix them.
<file name="gui/src/components/dialogs/AddRuleDialog.tsx">
<violation number="1" location="gui/src/components/dialogs/AddRuleDialog.tsx:32">
Leaving the dialog empty is supposed to fall back to the previous `new-rule.md`, but the submit handler rejects empty inputs so the fallback can never trigger. Default the trimmed value to `"new-rule.md"` instead of treating it as an error.</violation>
<violation number="2" location="gui/src/components/dialogs/AddRuleDialog.tsx:81">
The Create button is permanently disabled when the input is blank, so users can’t exercise the documented “leave empty to use new-rule.md” behavior. Allow submission when empty and only gate on `isSubmitting`.</violation>
</file>
Reply to cubic to teach it or ask questions. Re-run a review with @cubic-dev-ai review this PR
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
RomneyDa
left a comment
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.
See comments!
RomneyDa
left a comment
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!
|
🎉 This PR is included in version 1.36.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
|
🎉 This PR is included in version 1.7.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Description
Show a dialog when adding a new rule so that it can be renamed. When left empty, the previous "new-rule.md" is applied.
closes #8663
AI Code Review
@continue-reviewChecklist
Screen recording or screenshot
feat.mp4
Tests
[ What tests were added or updated to ensure the changes work as expected? ]
Summary by cubic
Let users name a rule file before creation via a new dialog. Works for both workspace and global rules, with sanitized filenames and updated core handling.
Written for commit ba64c1a. Summary will update automatically on new commits.