mirror of
https://github.com/elastic/kibana.git
synced 2025-04-23 17:28:26 -04:00
[Security solution] [Endpoint] Unify subtitle text in flyout and modal for event filters (#106401)
* Unify subtitle text in flyout and modal for event filters * Change variable name and make it more consistent with trusted apps showing subtitle only when adding event filters Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
This commit is contained in:
parent
2905aed6fb
commit
7f758731ae
4 changed files with 16 additions and 22 deletions
|
@ -31,16 +31,10 @@ import { ExceptionBuilder } from '../../../../../../shared_imports';
|
|||
|
||||
import { useEventFiltersSelector } from '../../hooks';
|
||||
import { getFormEntryStateMutable, getHasNameError, getNewComment } from '../../../store/selector';
|
||||
import {
|
||||
FORM_DESCRIPTION,
|
||||
NAME_LABEL,
|
||||
NAME_ERROR,
|
||||
NAME_PLACEHOLDER,
|
||||
OS_LABEL,
|
||||
RULE_NAME,
|
||||
} from './translations';
|
||||
import { NAME_LABEL, NAME_ERROR, NAME_PLACEHOLDER, OS_LABEL, RULE_NAME } from './translations';
|
||||
import { OS_TITLES } from '../../../../../common/translations';
|
||||
import { ENDPOINT_EVENT_FILTERS_LIST_ID, EVENT_FILTER_LIST_TYPE } from '../../../constants';
|
||||
import { ABOUT_EVENT_FILTERS } from '../../translations';
|
||||
|
||||
const OPERATING_SYSTEMS: readonly OperatingSystem[] = [
|
||||
OperatingSystem.MAC,
|
||||
|
@ -205,8 +199,12 @@ export const EventFiltersForm: React.FC<EventFiltersFormProps> = memo(
|
|||
|
||||
return !isIndexPatternLoading && exception ? (
|
||||
<EuiForm component="div">
|
||||
<EuiText size="s">{FORM_DESCRIPTION}</EuiText>
|
||||
<EuiSpacer size="m" />
|
||||
{!exception || !exception.item_id ? (
|
||||
<EuiText color="subdued" size="xs">
|
||||
{ABOUT_EVENT_FILTERS}
|
||||
<EuiSpacer size="m" />
|
||||
</EuiText>
|
||||
) : null}
|
||||
{nameInputMemo}
|
||||
<EuiSpacer size="m" />
|
||||
{allowSelectOs ? (
|
||||
|
|
|
@ -7,13 +7,6 @@
|
|||
|
||||
import { i18n } from '@kbn/i18n';
|
||||
|
||||
export const FORM_DESCRIPTION = i18n.translate(
|
||||
'xpack.securitySolution.eventFilter.modal.description',
|
||||
{
|
||||
defaultMessage: "Events are filtered when the rule's conditions are met:",
|
||||
}
|
||||
);
|
||||
|
||||
export const NAME_PLACEHOLDER = i18n.translate(
|
||||
'xpack.securitySolution.eventFilter.form.name.placeholder',
|
||||
{
|
||||
|
|
|
@ -44,6 +44,7 @@ import { EventFilterDeleteModal } from './components/event_filter_delete_modal';
|
|||
|
||||
import { SearchBar } from '../../../components/search_bar';
|
||||
import { BackToExternalAppButton } from '../../../components/back_to_external_app_button';
|
||||
import { ABOUT_EVENT_FILTERS } from './translations';
|
||||
|
||||
type EventListPaginatedContent = PaginatedContentProps<
|
||||
Immutable<ExceptionListItemSchema>,
|
||||
|
@ -195,11 +196,7 @@ export const EventFiltersListPage = memo(() => {
|
|||
defaultMessage="Event Filters"
|
||||
/>
|
||||
}
|
||||
subtitle={i18n.translate('xpack.securitySolution.eventFilters.aboutInfo', {
|
||||
defaultMessage:
|
||||
'Add an event filter to exclude high volume or unwanted events from being written to Elasticsearch. Event ' +
|
||||
'filters are processed by the Endpoint Security integration, and are applied to hosts running this integration on their agents.',
|
||||
})}
|
||||
subtitle={ABOUT_EVENT_FILTERS}
|
||||
actions={
|
||||
doesDataExist && (
|
||||
<EuiButton
|
||||
|
|
|
@ -51,3 +51,9 @@ export const getGetErrorMessage = (getError: ServerApiError) => {
|
|||
values: { error: getError.message },
|
||||
});
|
||||
};
|
||||
|
||||
export const ABOUT_EVENT_FILTERS = i18n.translate('xpack.securitySolution.eventFilters.aboutInfo', {
|
||||
defaultMessage:
|
||||
'Add an event filter to exclude high volume or unwanted events from being written to Elasticsearch. Event ' +
|
||||
'filters are processed by the Endpoint Security integration, and are applied to hosts running this integration on their agents.',
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue