[Observability] Update AlertsSearchBar placeholder (#110192)
* [Observability] Update AlertsSearchBar placeholder (#108179) * [Observability] Remove default search query from Alerts page (#110242) This is done to align with other placeholder texts found within the Observability solution.
This commit is contained in:
parent
ed7beee634
commit
02538b6b41
|
@ -46,7 +46,7 @@ export function AlertsSearchBar({
|
|||
<SearchBar
|
||||
indexPatterns={compatibleIndexPatterns}
|
||||
placeholder={i18n.translate('xpack.observability.alerts.searchBarPlaceholder', {
|
||||
defaultMessage: 'kibana.alert.evaluation.threshold > 75',
|
||||
defaultMessage: 'Search alerts (e.g. kibana.alert.evaluation.threshold > 75)',
|
||||
})}
|
||||
query={{ query: query ?? '', language: queryLanguage }}
|
||||
timeHistory={timeHistory}
|
||||
|
|
|
@ -8,7 +8,6 @@
|
|||
import { EuiButtonEmpty, EuiCallOut, EuiFlexGroup, EuiFlexItem, EuiLink } from '@elastic/eui';
|
||||
import { IndexPatternBase } from '@kbn/es-query';
|
||||
import { i18n } from '@kbn/i18n';
|
||||
import { ALERT_STATUS, ALERT_STATUS_ACTIVE } from '@kbn/rule-data-utils';
|
||||
import React, { useCallback, useRef } from 'react';
|
||||
import { useHistory } from 'react-router-dom';
|
||||
import useAsync from 'react-use/lib/useAsync';
|
||||
|
@ -43,12 +42,7 @@ export function AlertsPage({ routeParams }: AlertsPageProps) {
|
|||
const history = useHistory();
|
||||
const refetch = useRef<() => void>();
|
||||
const {
|
||||
query: {
|
||||
rangeFrom = 'now-15m',
|
||||
rangeTo = 'now',
|
||||
kuery = `${ALERT_STATUS}: "${ALERT_STATUS_ACTIVE}"`,
|
||||
workflowStatus = 'open',
|
||||
},
|
||||
query: { rangeFrom = 'now-15m', rangeTo = 'now', kuery = '', workflowStatus = 'open' },
|
||||
} = routeParams;
|
||||
|
||||
useBreadcrumbs([
|
||||
|
|
Loading…
Reference in a new issue