diff --git a/x-pack/plugins/security_solution/public/detections/components/rules/risk_score_mapping/index.tsx b/x-pack/plugins/security_solution/public/detections/components/rules/risk_score_mapping/index.tsx index f022560f9f50c..f70bd2a3c0e75 100644 --- a/x-pack/plugins/security_solution/public/detections/components/rules/risk_score_mapping/index.tsx +++ b/x-pack/plugins/security_solution/public/detections/components/rules/risk_score_mapping/index.tsx @@ -51,6 +51,7 @@ interface RiskScoreFieldProps { idAria: string; indices: DataViewBase; isDisabled: boolean; + isActive: boolean; placeholder?: string; } @@ -60,6 +61,7 @@ export const RiskScoreField = ({ idAria, indices, isDisabled, + isActive, placeholder, }: RiskScoreFieldProps) => { const { value, isMappingChecked, mapping } = field.value; @@ -147,29 +149,39 @@ export const RiskScoreField = ({ return ( - - - + { + // TODO: https://github.com/elastic/kibana/issues/161456 + // The About step page contains EuiRange component which does not work properly within memoized parents. + // EUI team suggested not to memoize EuiRange/EuiDualRange: https://github.com/elastic/eui/issues/6846 + // Workaround: We force EuiRange re-rendering by removeing/adding it into the DOM. + // NOTE: We should remove this workaround once EUI team fixed EuiRange. + // Related ticket: https://github.com/elastic/kibana/issues/160561 + } + {isActive && ( + + + + )} = ({ dataTestSubj: 'detectionEngineStepAboutRuleRiskScore', idAria: 'detectionEngineStepAboutRuleRiskScore', isDisabled: isLoading || indexPatternLoading, + isActive, indices: indexPattern, }} />