-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
[Security Solution] Add "Customized Elastic rule" badge to Rule Details page #186914
[Security Solution] Add "Customized Elastic rule" badge to Rule Details page #186914
Conversation
Pinging @elastic/security-detections-response (Team:Detections and Resp) |
Pinging @elastic/security-solution (Team: SecuritySolution) |
Pinging @elastic/security-detection-rule-management (Team:Detection Rule Management) |
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.
LGTM thanks @nikitaindik!
...ugins/security_solution/public/detection_engine/rule_details_ui/pages/rule_details/index.tsx
Outdated
Show resolved
Hide resolved
...ugins/security_solution/public/detection_engine/rule_details_ui/pages/rule_details/index.tsx
Outdated
Show resolved
Hide resolved
<> | ||
<EuiFlexGroup gutterSize="xs" alignItems="center" justifyContent="flexStart"> | ||
<EuiFlexGroup gutterSize="m" alignItems="center" justifyContent="flexStart"> | ||
{rule?.rule_source?.type === 'external' && rule.rule_source.is_customized && ( |
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.
We might also need to check for the rule customization feature flag before showing this badge. Our users could already have customized rules before we release this feature.
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.
You're right! I forgot that rules can be modified via API. Added the feature flag check.
2034003
to
d5fdc48
Compare
…ication-rule-details-page
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, thank you @nikitaindik 👍 ✅
💛 Build succeeded, but was flaky
Failed CI StepsMetrics [docs]Module Count
Async chunks
History
To update your PR or re-run it, just comment with: cc @nikitaindik |
Resolves: #180170
Summary
This PR adds a "Customized Elastic rule" badge to the Rule Details page. This badge is only displayed if a rule has
rule_source.is_customized
set totrue
and the feature flag is turned on.Tests for this feature will be added later under a separate ticket (#186916).
Screenshots
Customized Elastic rule – has badge
Custom rule – no badge