-
-
Notifications
You must be signed in to change notification settings - Fork 10
add help text to contact form and aws integration setup #35
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.
Pull Request Overview
This PR adds two user-facing improvements: a reminder in the contact form success message to check spam folders, and context-specific warnings in the AWS integration setup when the S3 key prefix contains "AWSLogs".
- Updated success message in the contact form to help users identify missing emails.
- Added conditional warnings in the integrations page based on regex tests for AWSLogs in the S3 key prefix.
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| frontend/src/app/(user-area)/teams/[teamId]/settings/integrations/page.tsx | Introduces new regex validations and corresponding warning messages for AWSLogs usage in the S3 key prefix. |
| frontend/src/app/(public-area)/contact/ContactForm.tsx | Updates the success message with an added reminder to check the spam folder. |
Comments suppressed due to low confidence (1)
frontend/src/app/(public-area)/contact/ContactForm.tsx:44
- Consider adding tests to verify that the updated success message correctly includes the spam folder reminder.
<SuccessMessage>
| {s3KeyPrefix && | ||
| (startsWithAwsLogsRegex.test(s3KeyPrefix) ? ( | ||
| <p className="text-xs text-indian-red"> | ||
| Cloud Snitch will automatically search for the "AWSLogs" directory in your S3 | ||
| bucket. This field is only necessary if you have a custom prefix for your CloudTrail | ||
| logs. Otherwise, you should leave it empty. | ||
| </p> | ||
| ) : includesAwsLogsRegex.test(s3KeyPrefix) ? ( | ||
| <p className="text-xs text-indian-red"> | ||
| Cloud Snitch will automatically search for the "AWSLogs" directory in your S3 | ||
| bucket. This field should only contain the custom prefix that you specified when | ||
| creating the trail, if any. | ||
| </p> | ||
| ) : null)} |
Copilot
AI
May 15, 2025
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.
[nitpick] The nested ternary conditions for rendering warnings make the code harder to read; consider refactoring the conditional logic into a clearer structure or helper functions.
| {s3KeyPrefix && | |
| (startsWithAwsLogsRegex.test(s3KeyPrefix) ? ( | |
| <p className="text-xs text-indian-red"> | |
| Cloud Snitch will automatically search for the "AWSLogs" directory in your S3 | |
| bucket. This field is only necessary if you have a custom prefix for your CloudTrail | |
| logs. Otherwise, you should leave it empty. | |
| </p> | |
| ) : includesAwsLogsRegex.test(s3KeyPrefix) ? ( | |
| <p className="text-xs text-indian-red"> | |
| Cloud Snitch will automatically search for the "AWSLogs" directory in your S3 | |
| bucket. This field should only contain the custom prefix that you specified when | |
| creating the trail, if any. | |
| </p> | |
| ) : null)} | |
| {getS3KeyPrefixWarning(s3KeyPrefix)} |
What It Does