-
Notifications
You must be signed in to change notification settings - Fork 7
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
add: external link warning dialog #232
Conversation
When the user clicks on a link that is not apart of Trenova, display a warning dialog
for more information, see https://pre-commit.ci
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.
PR Type: Enhancement
PR Summary: This pull request introduces a new feature to the application by adding an external link warning dialog. It enhances the user experience by providing a cautionary step before navigating away from the application to an external website. Additionally, the PR includes refactoring within the server's report module, specifically moving the ALLOWED_MODELS dictionary to a separate constants file for better modularity and readability. It also includes a new management command for clearing out old reports, further improving the application's maintainability.
Decision: Comment
📝 Type: 'Enhancement' - not supported yet.
- Sourcery currently only approves 'Typo fix' PRs.
✅ Issue addressed: this change correctly addresses the issue or implements the desired feature.
No details provided.
📝 Complexity: the changes are too large or complex for Sourcery to approve.
- Big diff: the diff is too large to approve with confidence.
General suggestions:
- Ensure that the new external link warning dialog is consistently styled with the rest of the application to maintain a cohesive user interface.
- Consider adding unit tests for the new management command to ensure its functionality is reliable and works as expected.
- Review the accessibility of the new external link warning dialog to ensure it is fully accessible, including keyboard navigation and screen reader support.
- Verify that the refactoring of the ALLOWED_MODELS dictionary and its usage across the application does not introduce any regressions or unintended behavior.
Thanks for using Sourcery. We offer it for free for open source projects and would be very grateful if you could help us grow. If you like it, would you consider sharing Sourcery on your favourite social media? ✨
model = apps.get_model( | ||
constants.ALLOWED_MODELS[model_name]["app_label"], model_name | ||
) | ||
if not model: | ||
raise exceptions.InvalidModelException("Invalid model name") |
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.
issue (rule): Sourcery has identified the following issue:
- Use named expression to simplify assignment and conditional (
use-named-expression
) - Lift code into else after jump in control flow (
reintroduce-else
) - Swap if/else branches (
swap-if-else-branches
)
No description provided.