Skip to content
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

[ResponseOps] Adds tooltip to time window selector in ES query rule flyout #125764

Merged
merged 13 commits into from
Feb 21, 2022
Merged
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,16 @@ import { XJsonMode } from '@kbn/ace';
import 'brace/theme/github';

import {
EuiFlexGroup,
EuiFlexItem,
EuiButtonEmpty,
EuiSpacer,
EuiFormRow,
EuiCallOut,
EuiText,
EuiTitle,
EuiLink,
EuiIconTip,
} from '@elastic/eui';
import { DocLinksStart, HttpSetup } from 'kibana/public';
import type * as estypes from '@elastic/elasticsearch/lib/api/typesWithBodyKey';
Expand Down Expand Up @@ -347,14 +350,31 @@ export const EsQueryAlertTypeExpression: React.FunctionComponent<
</EuiFormRow>
)}
<EuiSpacer />
<EuiTitle size="xs">
<h5>
<FormattedMessage
id="xpack.stackAlerts.esQuery.ui.conditionPrompt"
defaultMessage="When number of matches"
<EuiFlexGroup alignItems="center" responsive={false} gutterSize="none">
<EuiFlexItem grow={false}>
<EuiTitle size="xs">
<h5>
<FormattedMessage
id="xpack.stackAlerts.esQuery.ui.conditionPrompt"
defaultMessage="When number of matches"
/>
</h5>
</EuiTitle>
</EuiFlexItem>
<EuiFlexItem grow={false}>
<EuiIconTip
position="right"
color="subdued"
type="questionInCircle"
iconProps={{
className: 'eui-alignTop',
}}
content={i18n.translate('xpack.stackAlerts.esQuery.ui.conditionPrompt.toolTip', {
defaultMessage: 'The time window defined below applies only to the first rule check.',
})}
/>
</h5>
</EuiTitle>
</EuiFlexItem>
</EuiFlexGroup>
<EuiSpacer size="s" />
<ThresholdExpression
data-test-subj="thresholdExpression"
Expand Down