mirror of
https://github.com/elastic/kibana.git
synced 2025-04-23 09:19:04 -04:00
[Security Solution] Add "Rule Preview" title before the rule preview section (#138286)
* [Security Solution] Add "Rule Preview" title before the rule preview section (#138165) * Review feedback: naming according to guidelines
This commit is contained in:
parent
ab5a726f85
commit
a0cb2608fb
3 changed files with 38 additions and 30 deletions
|
@ -236,7 +236,6 @@ const RulePreviewComponent: React.FC<RulePreviewProps> = ({
|
|||
|
||||
return (
|
||||
<>
|
||||
<EuiSpacer />
|
||||
<EuiButtonGroup
|
||||
legend="Quick query or advanced query preview selector"
|
||||
data-test-subj="quickAdvancedToggleButtonGroup"
|
||||
|
@ -245,7 +244,7 @@ const RulePreviewComponent: React.FC<RulePreviewProps> = ({
|
|||
options={quickAdvancedToggleButtonOptions}
|
||||
color="primary"
|
||||
/>
|
||||
<EuiSpacer />
|
||||
<EuiSpacer size="s" />
|
||||
{showAdvancedOptions && showInvocationCountWarning && (
|
||||
<>
|
||||
<EuiCallOut
|
||||
|
|
|
@ -830,34 +830,36 @@ const StepDefineRuleComponent: FC<StepDefineRuleProps> = ({
|
|||
}}
|
||||
/>
|
||||
</Form>
|
||||
<EuiSpacer size="s" />
|
||||
<RulePreview
|
||||
index={index}
|
||||
dataViewId={formDataViewId}
|
||||
isDisabled={getIsRulePreviewDisabled({
|
||||
ruleType,
|
||||
isQueryBarValid,
|
||||
isThreatQueryBarValid,
|
||||
index,
|
||||
dataViewId: formDataViewId,
|
||||
threatIndex,
|
||||
threatMapping: formThreatMapping,
|
||||
machineLearningJobId,
|
||||
queryBar: formQuery ?? initialState.queryBar,
|
||||
newTermsFields: formNewTermsFields,
|
||||
})}
|
||||
query={formQuery}
|
||||
ruleType={ruleType}
|
||||
threatIndex={threatIndex}
|
||||
threatQuery={formThreatQuery}
|
||||
threatMapping={formThreatMapping}
|
||||
threshold={formThreshold}
|
||||
machineLearningJobId={machineLearningJobId}
|
||||
anomalyThreshold={anomalyThreshold}
|
||||
eqlOptions={optionsSelected}
|
||||
newTermsFields={newTermsFields}
|
||||
historyWindowSize={historyWindowSize}
|
||||
/>
|
||||
<EuiSpacer size="m" />
|
||||
<RuleTypeEuiFormRow label={i18n.RULE_PREVIEW_TITLE} $isVisible={true} fullWidth>
|
||||
<RulePreview
|
||||
index={index}
|
||||
dataViewId={formDataViewId}
|
||||
isDisabled={getIsRulePreviewDisabled({
|
||||
ruleType,
|
||||
isQueryBarValid,
|
||||
isThreatQueryBarValid,
|
||||
index,
|
||||
dataViewId: formDataViewId,
|
||||
threatIndex,
|
||||
threatMapping: formThreatMapping,
|
||||
machineLearningJobId,
|
||||
queryBar: formQuery ?? initialState.queryBar,
|
||||
newTermsFields: formNewTermsFields,
|
||||
})}
|
||||
query={formQuery}
|
||||
ruleType={ruleType}
|
||||
threatIndex={threatIndex}
|
||||
threatQuery={formThreatQuery}
|
||||
threatMapping={formThreatMapping}
|
||||
threshold={formThreshold}
|
||||
machineLearningJobId={machineLearningJobId}
|
||||
anomalyThreshold={anomalyThreshold}
|
||||
eqlOptions={optionsSelected}
|
||||
newTermsFields={newTermsFields}
|
||||
historyWindowSize={historyWindowSize}
|
||||
/>
|
||||
</RuleTypeEuiFormRow>
|
||||
</StepContentWrapper>
|
||||
|
||||
{!isUpdateView && (
|
||||
|
|
|
@ -98,3 +98,10 @@ export const SOURCE = i18n.translate(
|
|||
defaultMessage: 'Source',
|
||||
}
|
||||
);
|
||||
|
||||
export const RULE_PREVIEW_TITLE = i18n.translate(
|
||||
'xpack.securitySolution.detectionEngine.createRule.stepDefineRule.rulePreviewTitle',
|
||||
{
|
||||
defaultMessage: 'Rule Preview',
|
||||
}
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue