"
`;
exports[`Canvas Shareable Workpad API Placed successfully with width and height specified 1`] = `""`;
@@ -45,7 +45,7 @@ exports[`Canvas Shareable Workpad API Placed successfully with width and height
markdown mock
markdown mock
My Canvas Workpad
Page 1
"
+
markdown mock
My Canvas Workpad
Page 1
"
`;
exports[`Canvas Shareable Workpad API Placed successfully with width specified 1`] = `""`;
@@ -57,5 +57,5 @@ exports[`Canvas Shareable Workpad API Placed successfully with width specified 2
"
`;
diff --git a/x-pack/plugins/canvas/shareable_runtime/components/footer/__stories__/__snapshots__/footer.stories.storyshot b/x-pack/plugins/canvas/shareable_runtime/components/footer/__stories__/__snapshots__/footer.stories.storyshot
index 6ff39b723a49a..2d3a9c460272c 100644
--- a/x-pack/plugins/canvas/shareable_runtime/components/footer/__stories__/__snapshots__/footer.stories.storyshot
+++ b/x-pack/plugins/canvas/shareable_runtime/components/footer/__stories__/__snapshots__/footer.stories.storyshot
@@ -1351,7 +1351,7 @@ exports[`Storyshots shareables/Footer contextual: austin 1`] = `
type="button"
>
can navigate Autoplay Settings 2`] = `
type="submit"
>
'RenderedElement');
+// Some of the code requires that this directory exists, but the tests don't actually require any css to be present
+const cssDir = path.resolve(__dirname, '../../../../built_assets/css');
+if (!fs.existsSync(cssDir)) {
+ fs.mkdirSync(cssDir, { recursive: true });
+}
+
addSerializer(styleSheetSerializer);
// Initialize Storyshots and build the Jest Snapshots
diff --git a/x-pack/plugins/canvas/types/renderers.ts b/x-pack/plugins/canvas/types/renderers.ts
index 772a16aa94c60..7dcb94507b632 100644
--- a/x-pack/plugins/canvas/types/renderers.ts
+++ b/x-pack/plugins/canvas/types/renderers.ts
@@ -47,3 +47,6 @@ export interface RendererSpec {
}
export type RendererFactory = () => RendererSpec;
+
+export type AnyRendererFactory = RendererFactory;
+export type AnyRendererSpec = RendererSpec;
diff --git a/x-pack/plugins/index_lifecycle_management/__jest__/components/__snapshots__/policy_table.test.js.snap b/x-pack/plugins/index_lifecycle_management/__jest__/components/__snapshots__/policy_table.test.js.snap
index 5edc5a9343fc3..ad3e0956fcf25 100644
--- a/x-pack/plugins/index_lifecycle_management/__jest__/components/__snapshots__/policy_table.test.js.snap
+++ b/x-pack/plugins/index_lifecycle_management/__jest__/components/__snapshots__/policy_table.test.js.snap
@@ -97,11 +97,10 @@ exports[`policy table should show empty state when there are not any policies 1`
type="button"
>
({
- phaseData: getPhase(state, PHASE_COLD),
- hotPhaseRolloverEnabled: getPhase(state, PHASE_HOT)[PHASE_ROLLOVER_ENABLED],
- }),
- {
- setPhaseData: (key, value) => setPhaseData(PHASE_COLD, key, value),
- }
-)(PresentationComponent);
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/cold_phase/index.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/cold_phase/index.js
deleted file mode 100644
index e0d70ceb57726..0000000000000
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/cold_phase/index.js
+++ /dev/null
@@ -1,7 +0,0 @@
-/*
- * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
- * or more contributor license agreements. Licensed under the Elastic License;
- * you may not use this file except in compliance with the Elastic License.
- */
-
-export { ColdPhase } from './cold_phase.container';
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/delete_phase/delete_phase.container.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/delete_phase/delete_phase.container.js
deleted file mode 100644
index 84bd17e3637e8..0000000000000
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/delete_phase/delete_phase.container.js
+++ /dev/null
@@ -1,21 +0,0 @@
-/*
- * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
- * or more contributor license agreements. Licensed under the Elastic License;
- * you may not use this file except in compliance with the Elastic License.
- */
-
-import { connect } from 'react-redux';
-import { getPhase } from '../../../../store/selectors';
-import { setPhaseData } from '../../../../store/actions';
-import { PHASE_DELETE, PHASE_HOT, PHASE_ROLLOVER_ENABLED } from '../../../../constants';
-import { DeletePhase as PresentationComponent } from './delete_phase';
-
-export const DeletePhase = connect(
- (state) => ({
- phaseData: getPhase(state, PHASE_DELETE),
- hotPhaseRolloverEnabled: getPhase(state, PHASE_HOT)[PHASE_ROLLOVER_ENABLED],
- }),
- {
- setPhaseData: (key, value) => setPhaseData(PHASE_DELETE, key, value),
- }
-)(PresentationComponent);
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/delete_phase/index.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/delete_phase/index.js
deleted file mode 100644
index 5f909ab2c0f79..0000000000000
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/delete_phase/index.js
+++ /dev/null
@@ -1,7 +0,0 @@
-/*
- * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
- * or more contributor license agreements. Licensed under the Elastic License;
- * you may not use this file except in compliance with the Elastic License.
- */
-
-export { DeletePhase } from './delete_phase.container';
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/form_errors.tsx b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/form_errors.tsx
similarity index 100%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/form_errors.tsx
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/form_errors.tsx
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/hot_phase/hot_phase.container.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/hot_phase/hot_phase.container.js
deleted file mode 100644
index 5f1451afdcc31..0000000000000
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/hot_phase/hot_phase.container.js
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
- * or more contributor license agreements. Licensed under the Elastic License;
- * you may not use this file except in compliance with the Elastic License.
- */
-
-import { connect } from 'react-redux';
-
-import { getPhase } from '../../../../store/selectors';
-import { setPhaseData } from '../../../../store/actions';
-import { PHASE_HOT, PHASE_WARM, WARM_PHASE_ON_ROLLOVER } from '../../../../constants';
-import { HotPhase as PresentationComponent } from './hot_phase';
-
-export const HotPhase = connect(
- (state) => ({
- phaseData: getPhase(state, PHASE_HOT),
- }),
- {
- setPhaseData: (key, value) => setPhaseData(PHASE_HOT, key, value),
- setWarmPhaseOnRollover: (value) => setPhaseData(PHASE_WARM, WARM_PHASE_ON_ROLLOVER, value),
- }
-)(PresentationComponent);
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/hot_phase/index.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/hot_phase/index.js
deleted file mode 100644
index 114e34c3ef4d0..0000000000000
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/hot_phase/index.js
+++ /dev/null
@@ -1,7 +0,0 @@
-/*
- * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
- * or more contributor license agreements. Licensed under the Elastic License;
- * you may not use this file except in compliance with the Elastic License.
- */
-
-export { HotPhase } from './hot_phase.container';
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/components/index.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/index.ts
similarity index 54%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/components/index.js
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/index.ts
index a2ae37780b9f9..e933c46e98491 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/components/index.js
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/index.ts
@@ -5,6 +5,13 @@
*/
export { ActiveBadge } from './active_badge';
+export { ErrableFormRow } from './form_errors';
export { LearnMoreLink } from './learn_more_link';
-export { PhaseErrorMessage } from './phase_error_message';
+export { MinAgeInput } from './min_age_input';
+export { NodeAllocation } from './node_allocation';
+export { NodeAttrsDetails } from './node_attrs_details';
export { OptionalLabel } from './optional_label';
+export { PhaseErrorMessage } from './phase_error_message';
+export { PolicyJsonFlyout } from './policy_json_flyout';
+export { SetPriorityInput } from './set_priority_input';
+export { SnapshotPolicies } from './snapshot_policies';
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/components/learn_more_link.tsx b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/learn_more_link.tsx
similarity index 92%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/components/learn_more_link.tsx
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/learn_more_link.tsx
index 623ff982438d7..5ada49b318018 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/components/learn_more_link.tsx
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/learn_more_link.tsx
@@ -8,7 +8,7 @@ import React, { ReactNode } from 'react';
import { EuiLink } from '@elastic/eui';
import { FormattedMessage } from '@kbn/i18n/react';
-import { createDocLink } from '../../services/documentation';
+import { createDocLink } from '../../../services/documentation';
interface Props {
docPath: string;
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/min_age_input.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/min_age_input.tsx
similarity index 91%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/min_age_input.js
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/min_age_input.tsx
index d90ad9378efd4..c9732f2311758 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/min_age_input.js
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/min_age_input.tsx
@@ -16,10 +16,10 @@ import {
PHASE_COLD,
PHASE_DELETE,
} from '../../../constants';
-import { LearnMoreLink } from '../../components';
-import { ErrableFormRow } from '../form_errors';
+import { LearnMoreLink } from './learn_more_link';
+import { ErrableFormRow } from './form_errors';
-function getTimingLabelForPhase(phase) {
+function getTimingLabelForPhase(phase: string) {
// NOTE: Hot phase isn't necessary, because indices begin in the hot phase.
switch (phase) {
case PHASE_WARM:
@@ -39,7 +39,7 @@ function getTimingLabelForPhase(phase) {
}
}
-function getUnitsAriaLabelForPhase(phase) {
+function getUnitsAriaLabelForPhase(phase: string) {
// NOTE: Hot phase isn't necessary, because indices begin in the hot phase.
switch (phase) {
case PHASE_WARM:
@@ -68,9 +68,24 @@ function getUnitsAriaLabelForPhase(phase) {
}
}
-export const MinAgeInput = (props) => {
- const { rolloverEnabled, errors, phaseData, phase, setPhaseData, isShowingErrors } = props;
+interface Props {
+ rolloverEnabled: boolean;
+ errors: Record;
+ phase: string;
+ // TODO add types for phaseData and setPhaseData after policy is typed
+ phaseData: any;
+ setPhaseData: (dataKey: string, value: any) => void;
+ isShowingErrors: boolean;
+}
+export const MinAgeInput: React.FunctionComponent = ({
+ rolloverEnabled,
+ errors,
+ phaseData,
+ phase,
+ setPhaseData,
+ isShowingErrors,
+}) => {
let daysOptionLabel;
let hoursOptionLabel;
let minutesOptionLabel;
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_allocation/node_allocation.tsx b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_allocation.tsx
similarity index 93%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_allocation/node_allocation.tsx
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_allocation.tsx
index 31261de45c743..576483a5ab9c2 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_allocation/node_allocation.tsx
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_allocation.tsx
@@ -16,17 +16,18 @@ import {
EuiButton,
} from '@elastic/eui';
-import { PHASE_NODE_ATTRS } from '../../../../constants';
-import { LearnMoreLink } from '../../../components/learn_more_link';
-import { ErrableFormRow } from '../../form_errors';
-import { useLoadNodes } from '../../../../services/api';
-import { NodeAttrsDetails } from '../node_attrs_details';
+import { PHASE_NODE_ATTRS } from '../../../constants';
+import { LearnMoreLink } from './learn_more_link';
+import { ErrableFormRow } from './form_errors';
+import { useLoadNodes } from '../../../services/api';
+import { NodeAttrsDetails } from './node_attrs_details';
interface Props {
phase: string;
- setPhaseData: (dataKey: string, value: any) => void;
- errors: any;
+ errors: Record;
+ // TODO add types for phaseData and setPhaseData after policy is typed
phaseData: any;
+ setPhaseData: (dataKey: string, value: any) => void;
isShowingErrors: boolean;
}
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_allocation/index.ts b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_allocation/index.ts
deleted file mode 100644
index 4675ab46ee501..0000000000000
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_allocation/index.ts
+++ /dev/null
@@ -1,7 +0,0 @@
-/*
- * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
- * or more contributor license agreements. Licensed under the Elastic License;
- * you may not use this file except in compliance with the Elastic License.
- */
-
-export { NodeAllocation } from './node_allocation';
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_attrs_details/node_attrs_details.tsx b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_attrs_details.tsx
similarity index 97%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_attrs_details/node_attrs_details.tsx
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_attrs_details.tsx
index 6fcbd94dc5e9a..cd87cc324a414 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_attrs_details/node_attrs_details.tsx
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_attrs_details.tsx
@@ -20,7 +20,7 @@ import {
EuiButton,
} from '@elastic/eui';
-import { useLoadNodeDetails } from '../../../../services/api';
+import { useLoadNodeDetails } from '../../../services/api';
interface Props {
close: () => void;
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/components/optional_label.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/optional_label.tsx
similarity index 100%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/components/optional_label.js
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/optional_label.tsx
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/components/phase_error_message.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/phase_error_message.tsx
similarity index 87%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/components/phase_error_message.js
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/phase_error_message.tsx
index 904ac7c25f2f9..750f68543f221 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/components/phase_error_message.js
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/phase_error_message.tsx
@@ -7,7 +7,7 @@ import React from 'react';
import { EuiBadge } from '@elastic/eui';
import { FormattedMessage } from '@kbn/i18n/react';
-export const PhaseErrorMessage = ({ isShowingErrors }) => {
+export const PhaseErrorMessage = ({ isShowingErrors }: { isShowingErrors: boolean }) => {
return isShowingErrors ? (
'}`;
- const request = `${endpoint}\n${this.getEsJson(lifecycle)}`;
-
- return (
-
-
-
-
- {policyName ? (
-
- ) : (
-
- )}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- {request}
-
-
-
-
-
-
-
-
-
- );
- }
-}
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/policy_json_flyout.tsx b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/policy_json_flyout.tsx
new file mode 100644
index 0000000000000..aaf4aa6e6222d
--- /dev/null
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/policy_json_flyout.tsx
@@ -0,0 +1,98 @@
+/*
+ * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
+ * or more contributor license agreements. Licensed under the Elastic License;
+ * you may not use this file except in compliance with the Elastic License.
+ */
+
+import React from 'react';
+import { FormattedMessage } from '@kbn/i18n/react';
+
+import {
+ EuiButtonEmpty,
+ EuiCodeBlock,
+ EuiFlyout,
+ EuiFlyoutBody,
+ EuiFlyoutFooter,
+ EuiFlyoutHeader,
+ EuiSpacer,
+ EuiText,
+ EuiTitle,
+} from '@elastic/eui';
+
+interface Props {
+ close: () => void;
+ // TODO add types for lifecycle after policy is typed
+ lifecycle: any;
+ policyName: string;
+}
+
+export const PolicyJsonFlyout: React.FunctionComponent = ({
+ close,
+ lifecycle,
+ policyName,
+}) => {
+ // @ts-ignore until store is typed
+ const getEsJson = ({ phases }) => {
+ return JSON.stringify(
+ {
+ policy: {
+ phases,
+ },
+ },
+ null,
+ 2
+ );
+ };
+
+ const endpoint = `PUT _ilm/policy/${policyName || ''}`;
+ const request = `${endpoint}\n${getEsJson(lifecycle)}`;
+
+ return (
+
+
+
+
+ {policyName ? (
+
+ ) : (
+
+ )}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {request}
+
+
+
+
+
+
+
+
+
+ );
+};
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/set_priority_input.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/set_priority_input.tsx
similarity index 80%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/set_priority_input.js
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/set_priority_input.tsx
index bdcc1e23b4230..0034de85fce17 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/set_priority_input.js
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/set_priority_input.tsx
@@ -8,12 +8,26 @@ import { FormattedMessage } from '@kbn/i18n/react';
import { EuiFieldNumber, EuiTextColor, EuiDescribedFormGroup } from '@elastic/eui';
import { PHASE_INDEX_PRIORITY } from '../../../constants';
-import { LearnMoreLink, OptionalLabel } from '../../components';
-import { ErrableFormRow } from '../form_errors';
-export const SetPriorityInput = (props) => {
- const { errors, phaseData, phase, setPhaseData, isShowingErrors } = props;
+import { LearnMoreLink } from './';
+import { OptionalLabel } from './';
+import { ErrableFormRow } from './';
+interface Props {
+ errors: Record;
+ // TODO add types for phaseData and setPhaseData after policy is typed
+ phase: string;
+ phaseData: any;
+ setPhaseData: (dataKey: string, value: any) => void;
+ isShowingErrors: boolean;
+}
+export const SetPriorityInput: React.FunctionComponent = ({
+ errors,
+ phaseData,
+ phase,
+ setPhaseData,
+ isShowingErrors,
+}) => {
return (
({
- phaseData: getPhase(state, PHASE_WARM),
- hotPhaseRolloverEnabled: getPhase(state, PHASE_HOT)[PHASE_ROLLOVER_ENABLED],
- }),
- {
- setPhaseData: (key, value) => setPhaseData(PHASE_WARM, key, value),
- }
-)(PresentationComponent);
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/edit_policy.container.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/edit_policy.container.js
index 1c6ced8953211..e7f20a66d09f0 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/edit_policy.container.js
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/edit_policy.container.js
@@ -15,6 +15,7 @@ import {
isPolicyListLoaded,
getIsNewPolicy,
getSelectedOriginalPolicyName,
+ getPhases,
} from '../../store/selectors';
import {
@@ -23,6 +24,7 @@ import {
setSaveAsNewPolicy,
saveLifecyclePolicy,
fetchPolicies,
+ setPhaseData,
} from '../../store/actions';
import { findFirstError } from '../../services/find_errors';
@@ -42,6 +44,7 @@ export const EditPolicy = connect(
isPolicyListLoaded: isPolicyListLoaded(state),
isNewPolicy: getIsNewPolicy(state),
originalPolicyName: getSelectedOriginalPolicyName(state),
+ phases: getPhases(state),
};
},
{
@@ -50,5 +53,6 @@ export const EditPolicy = connect(
setSaveAsNewPolicy,
saveLifecyclePolicy,
fetchPolicies,
+ setPhaseData,
}
)(PresentationComponent);
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/edit_policy.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/edit_policy.js
index d9d8866a2e2cc..a29ecd07c5e45 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/edit_policy.js
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/edit_policy.js
@@ -33,17 +33,15 @@ import {
PHASE_DELETE,
PHASE_WARM,
STRUCTURE_POLICY_NAME,
+ WARM_PHASE_ON_ROLLOVER,
+ PHASE_ROLLOVER_ENABLED,
} from '../../constants';
import { toasts } from '../../services/notification';
import { findFirstError } from '../../services/find_errors';
-import { LearnMoreLink } from '../components';
-import { PolicyJsonFlyout } from './components/policy_json_flyout';
-import { ErrableFormRow } from './form_errors';
-import { HotPhase } from './components/hot_phase';
-import { WarmPhase } from './components/warm_phase';
-import { DeletePhase } from './components/delete_phase';
-import { ColdPhase } from './components/cold_phase';
+import { LearnMoreLink, PolicyJsonFlyout, ErrableFormRow } from './components';
+
+import { HotPhase, WarmPhase, ColdPhase, DeletePhase } from './phases';
export class EditPolicy extends Component {
static propTypes = {
@@ -137,6 +135,8 @@ export class EditPolicy extends Component {
isNewPolicy,
lifecycle,
originalPolicyName,
+ phases,
+ setPhaseData,
} = this.props;
const selectedPolicyName = selectedPolicy.name;
const { isShowingErrors, isShowingPolicyJsonFlyout } = this.state;
@@ -275,9 +275,13 @@ export class EditPolicy extends Component {
setPhaseData(PHASE_HOT, key, value)}
+ phaseData={phases[PHASE_HOT]}
+ setWarmPhaseOnRollover={(value) =>
+ setPhaseData(PHASE_WARM, WARM_PHASE_ON_ROLLOVER, value)
+ }
/>
@@ -285,6 +289,9 @@ export class EditPolicy extends Component {
setPhaseData(PHASE_WARM, key, value)}
+ phaseData={phases[PHASE_WARM]}
+ hotPhaseRolloverEnabled={phases[PHASE_HOT][PHASE_ROLLOVER_ENABLED]}
/>
@@ -292,6 +299,9 @@ export class EditPolicy extends Component {
setPhaseData(PHASE_COLD, key, value)}
+ phaseData={phases[PHASE_COLD]}
+ hotPhaseRolloverEnabled={phases[PHASE_HOT][PHASE_ROLLOVER_ENABLED]}
/>
@@ -300,6 +310,9 @@ export class EditPolicy extends Component {
errors={errors[PHASE_DELETE]}
isShowingErrors={isShowingErrors && !!findFirstError(errors[PHASE_DELETE], false)}
getUrlForApp={this.props.getUrlForApp}
+ setPhaseData={(key, value) => setPhaseData(PHASE_DELETE, key, value)}
+ phaseData={phases[PHASE_DELETE]}
+ hotPhaseRolloverEnabled={phases[PHASE_HOT][PHASE_ROLLOVER_ENABLED]}
/>
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/cold_phase/cold_phase.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/cold_phase.tsx
similarity index 92%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/cold_phase/cold_phase.js
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/cold_phase.tsx
index 200bf0e767d9d..babbbf7638ebe 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/cold_phase/cold_phase.js
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/cold_phase.tsx
@@ -5,7 +5,6 @@
*/
import React, { PureComponent, Fragment } from 'react';
-import PropTypes from 'prop-types';
import { FormattedMessage } from '@kbn/i18n/react';
import { i18n } from '@kbn/i18n';
@@ -24,20 +23,27 @@ import {
PHASE_ENABLED,
PHASE_REPLICA_COUNT,
PHASE_FREEZE_ENABLED,
-} from '../../../../constants';
-import { LearnMoreLink, ActiveBadge, PhaseErrorMessage, OptionalLabel } from '../../../components';
-import { ErrableFormRow } from '../../form_errors';
-import { MinAgeInput } from '../min_age_input';
-import { NodeAllocation } from '../node_allocation';
-import { SetPriorityInput } from '../set_priority_input';
+} from '../../../constants';
+import {
+ LearnMoreLink,
+ ActiveBadge,
+ PhaseErrorMessage,
+ OptionalLabel,
+ ErrableFormRow,
+ MinAgeInput,
+ NodeAllocation,
+ SetPriorityInput,
+} from '../components';
-export class ColdPhase extends PureComponent {
- static propTypes = {
- setPhaseData: PropTypes.func.isRequired,
+interface Props {
+ setPhaseData: (key: string, value: any) => void;
+ phaseData: any;
+ isShowingErrors: boolean;
+ errors: Record;
+ hotPhaseRolloverEnabled: boolean;
+}
- isShowingErrors: PropTypes.bool.isRequired,
- errors: PropTypes.object.isRequired,
- };
+export class ColdPhase extends PureComponent {
render() {
const {
setPhaseData,
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/delete_phase/delete_phase.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/delete_phase.tsx
similarity index 88%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/delete_phase/delete_phase.js
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/delete_phase.tsx
index 2b12eec953e11..0143cc4af24e3 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/delete_phase/delete_phase.js
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/delete_phase.tsx
@@ -5,22 +5,35 @@
*/
import React, { PureComponent, Fragment } from 'react';
-import PropTypes from 'prop-types';
import { FormattedMessage } from '@kbn/i18n/react';
import { EuiDescribedFormGroup, EuiSwitch, EuiTextColor, EuiFormRow } from '@elastic/eui';
-import { PHASE_DELETE, PHASE_ENABLED, PHASE_WAIT_FOR_SNAPSHOT_POLICY } from '../../../../constants';
-import { ActiveBadge, LearnMoreLink, OptionalLabel, PhaseErrorMessage } from '../../../components';
-import { MinAgeInput } from '../min_age_input';
-import { SnapshotPolicies } from '../snapshot_policies';
+import { PHASE_DELETE, PHASE_ENABLED, PHASE_WAIT_FOR_SNAPSHOT_POLICY } from '../../../constants';
+import {
+ ActiveBadge,
+ LearnMoreLink,
+ OptionalLabel,
+ PhaseErrorMessage,
+ MinAgeInput,
+ SnapshotPolicies,
+} from '../components';
-export class DeletePhase extends PureComponent {
- static propTypes = {
- setPhaseData: PropTypes.func.isRequired,
- isShowingErrors: PropTypes.bool.isRequired,
- errors: PropTypes.object.isRequired,
- };
+interface Props {
+ setPhaseData: (key: string, value: any) => void;
+ phaseData: any;
+ isShowingErrors: boolean;
+ errors: Record;
+ hotPhaseRolloverEnabled: boolean;
+ getUrlForApp: (
+ appId: string,
+ options?: {
+ path?: string;
+ absolute?: boolean;
+ }
+ ) => string;
+}
+export class DeletePhase extends PureComponent {
render() {
const {
setPhaseData,
@@ -28,6 +41,7 @@ export class DeletePhase extends PureComponent {
errors,
isShowingErrors,
hotPhaseRolloverEnabled,
+ getUrlForApp,
} = this.props;
return (
@@ -123,7 +137,7 @@ export class DeletePhase extends PureComponent {
setPhaseData(PHASE_WAIT_FOR_SNAPSHOT_POLICY, value)}
- getUrlForApp={this.props.getUrlForApp}
+ getUrlForApp={getUrlForApp}
/>
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/hot_phase/hot_phase.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/hot_phase.tsx
similarity index 96%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/hot_phase/hot_phase.js
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/hot_phase.tsx
index b420442198712..dbd48f3a85634 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/hot_phase/hot_phase.js
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/hot_phase.tsx
@@ -5,7 +5,6 @@
*/
import React, { Fragment, PureComponent } from 'react';
-import PropTypes from 'prop-types';
import { FormattedMessage } from '@kbn/i18n/react';
import { i18n } from '@kbn/i18n';
@@ -28,18 +27,24 @@ import {
PHASE_ROLLOVER_MAX_SIZE_STORED,
PHASE_ROLLOVER_MAX_SIZE_STORED_UNITS,
PHASE_ROLLOVER_ENABLED,
-} from '../../../../constants';
-import { LearnMoreLink, ActiveBadge, PhaseErrorMessage } from '../../../components';
-import { ErrableFormRow } from '../../form_errors';
-import { SetPriorityInput } from '../set_priority_input';
+} from '../../../constants';
+import {
+ LearnMoreLink,
+ ActiveBadge,
+ PhaseErrorMessage,
+ ErrableFormRow,
+ SetPriorityInput,
+} from '../components';
-export class HotPhase extends PureComponent {
- static propTypes = {
- setPhaseData: PropTypes.func.isRequired,
- isShowingErrors: PropTypes.bool.isRequired,
- errors: PropTypes.object.isRequired,
- };
+interface Props {
+ errors: Record;
+ isShowingErrors: boolean;
+ phaseData: any;
+ setPhaseData: (key: string, value: any) => void;
+ setWarmPhaseOnRollover: (value: boolean) => void;
+}
+export class HotPhase extends PureComponent {
render() {
const { setPhaseData, phaseData, isShowingErrors, errors, setWarmPhaseOnRollover } = this.props;
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_attrs_details/index.ts b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/index.ts
similarity index 58%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_attrs_details/index.ts
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/index.ts
index 056d2f2f600f3..8d1ace5950497 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/node_attrs_details/index.ts
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/index.ts
@@ -4,4 +4,7 @@
* you may not use this file except in compliance with the Elastic License.
*/
-export { NodeAttrsDetails } from './node_attrs_details';
+export { HotPhase } from './hot_phase';
+export { WarmPhase } from './warm_phase';
+export { ColdPhase } from './cold_phase';
+export { DeletePhase } from './delete_phase';
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/warm_phase/warm_phase.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/warm_phase.tsx
similarity index 95%
rename from x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/warm_phase/warm_phase.js
rename to x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/warm_phase.tsx
index 60b5ab4781b6d..6ed81bf8f45d5 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/warm_phase/warm_phase.js
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/phases/warm_phase.tsx
@@ -5,7 +5,6 @@
*/
import React, { Fragment, PureComponent } from 'react';
-import PropTypes from 'prop-types';
import { FormattedMessage } from '@kbn/i18n/react';
import { i18n } from '@kbn/i18n';
import {
@@ -28,21 +27,26 @@ import {
PHASE_PRIMARY_SHARD_COUNT,
PHASE_REPLICA_COUNT,
PHASE_SHRINK_ENABLED,
-} from '../../../../constants';
-import { LearnMoreLink, ActiveBadge, PhaseErrorMessage, OptionalLabel } from '../../../components';
-import { ErrableFormRow } from '../../form_errors';
-import { SetPriorityInput } from '../set_priority_input';
-import { NodeAllocation } from '../node_allocation';
-import { MinAgeInput } from '../min_age_input';
-
-export class WarmPhase extends PureComponent {
- static propTypes = {
- setPhaseData: PropTypes.func.isRequired,
-
- isShowingErrors: PropTypes.bool.isRequired,
- errors: PropTypes.object.isRequired,
- };
+} from '../../../constants';
+import {
+ LearnMoreLink,
+ ActiveBadge,
+ PhaseErrorMessage,
+ OptionalLabel,
+ ErrableFormRow,
+ SetPriorityInput,
+ NodeAllocation,
+ MinAgeInput,
+} from '../components';
+interface Props {
+ setPhaseData: (key: string, value: any) => void;
+ phaseData: any;
+ isShowingErrors: boolean;
+ errors: Record;
+ hotPhaseRolloverEnabled: boolean;
+}
+export class WarmPhase extends PureComponent {
render() {
const {
setPhaseData,
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/policy_table/components/policy_table/add_policy_to_template_confirm_modal.js b/x-pack/plugins/index_lifecycle_management/public/application/sections/policy_table/components/policy_table/add_policy_to_template_confirm_modal.js
index 8e53569047d8f..47134ad097720 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/sections/policy_table/components/policy_table/add_policy_to_template_confirm_modal.js
+++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/policy_table/components/policy_table/add_policy_to_template_confirm_modal.js
@@ -23,7 +23,7 @@ import {
import { toasts } from '../../../../services/notification';
import { addLifecyclePolicyToTemplate, loadIndexTemplates } from '../../../../services/api';
import { showApiError } from '../../../../services/api_errors';
-import { LearnMoreLink } from '../../../components/learn_more_link';
+import { LearnMoreLink } from '../../../edit_policy/components';
export class AddPolicyToTemplateConfirmModal extends Component {
state = {
diff --git a/x-pack/plugins/index_lifecycle_management/public/application/store/actions/nodes.js b/x-pack/plugins/index_lifecycle_management/public/application/store/actions/nodes.js
index 3f1c00db621a7..45a8e63f70e83 100644
--- a/x-pack/plugins/index_lifecycle_management/public/application/store/actions/nodes.js
+++ b/x-pack/plugins/index_lifecycle_management/public/application/store/actions/nodes.js
@@ -4,8 +4,5 @@
* you may not use this file except in compliance with the Elastic License.
*/
import { createAction } from 'redux-actions';
-import { SET_SELECTED_NODE_ATTRS } from '../../constants';
-
-export const setSelectedNodeAttrs = createAction(SET_SELECTED_NODE_ATTRS);
export const setSelectedPrimaryShardCount = createAction('SET_SELECTED_PRIMARY_SHARED_COUNT');
export const setSelectedReplicaCount = createAction('SET_SELECTED_REPLICA_COUNT');
diff --git a/x-pack/plugins/ingest_manager/server/services/epm/elasticsearch/ingest_pipeline/index.ts b/x-pack/plugins/ingest_manager/server/services/epm/elasticsearch/ingest_pipeline/index.ts
index 6450f7303dd88..4f2c7c4c339f1 100644
--- a/x-pack/plugins/ingest_manager/server/services/epm/elasticsearch/ingest_pipeline/index.ts
+++ b/x-pack/plugins/ingest_manager/server/services/epm/elasticsearch/ingest_pipeline/index.ts
@@ -6,4 +6,4 @@
export { installPipelines } from './install';
-export { deletePipelines, deletePipeline } from './remove';
+export { deletePreviousPipelines, deletePipeline } from './remove';
diff --git a/x-pack/plugins/ingest_manager/server/services/epm/elasticsearch/ingest_pipeline/remove.ts b/x-pack/plugins/ingest_manager/server/services/epm/elasticsearch/ingest_pipeline/remove.ts
index 8be3a1beab392..836b53b5a9225 100644
--- a/x-pack/plugins/ingest_manager/server/services/epm/elasticsearch/ingest_pipeline/remove.ts
+++ b/x-pack/plugins/ingest_manager/server/services/epm/elasticsearch/ingest_pipeline/remove.ts
@@ -8,24 +8,32 @@ import { SavedObjectsClientContract } from 'src/core/server';
import { appContextService } from '../../../';
import { CallESAsCurrentUser, ElasticsearchAssetType } from '../../../../types';
import { getInstallation } from '../../packages/get';
-import { PACKAGES_SAVED_OBJECT_TYPE } from '../../../../../common';
+import { PACKAGES_SAVED_OBJECT_TYPE, EsAssetReference } from '../../../../../common';
-export const deletePipelines = async (
+export const deletePreviousPipelines = async (
callCluster: CallESAsCurrentUser,
savedObjectsClient: SavedObjectsClientContract,
pkgName: string,
- pkgVersion: string
+ previousPkgVersion: string
) => {
const logger = appContextService.getLogger();
- const previousPipelinesPattern = `*-${pkgName}.*-${pkgVersion}`;
-
+ const installation = await getInstallation({ savedObjectsClient, pkgName });
+ if (!installation) return;
+ const installedEsAssets = installation.installed_es;
+ const installedPipelines = installedEsAssets.filter(
+ ({ type, id }) =>
+ type === ElasticsearchAssetType.ingestPipeline && id.includes(previousPkgVersion)
+ );
+ const deletePipelinePromises = installedPipelines.map(({ type, id }) => {
+ return deletePipeline(callCluster, id);
+ });
try {
- await deletePipeline(callCluster, previousPipelinesPattern);
+ await Promise.all(deletePipelinePromises);
} catch (e) {
logger.error(e);
}
try {
- await deletePipelineRefs(savedObjectsClient, pkgName, pkgVersion);
+ await deletePipelineRefs(savedObjectsClient, installedEsAssets, pkgName, previousPkgVersion);
} catch (e) {
logger.error(e);
}
@@ -33,12 +41,10 @@ export const deletePipelines = async (
export const deletePipelineRefs = async (
savedObjectsClient: SavedObjectsClientContract,
+ installedEsAssets: EsAssetReference[],
pkgName: string,
pkgVersion: string
) => {
- const installation = await getInstallation({ savedObjectsClient, pkgName });
- if (!installation) return;
- const installedEsAssets = installation.installed_es;
const filteredAssets = installedEsAssets.filter(({ type, id }) => {
if (type !== ElasticsearchAssetType.ingestPipeline) return true;
if (!id.includes(pkgVersion)) return true;
diff --git a/x-pack/plugins/ingest_manager/server/services/epm/packages/install.ts b/x-pack/plugins/ingest_manager/server/services/epm/packages/install.ts
index 0911aaf248e7a..6bc461845f124 100644
--- a/x-pack/plugins/ingest_manager/server/services/epm/packages/install.ts
+++ b/x-pack/plugins/ingest_manager/server/services/epm/packages/install.ts
@@ -22,7 +22,7 @@ import * as Registry from '../registry';
import { getInstallation, getInstallationObject, isRequiredPackage } from './index';
import { installTemplates } from '../elasticsearch/template/install';
import { generateESIndexPatterns } from '../elasticsearch/template/template';
-import { installPipelines, deletePipelines } from '../elasticsearch/ingest_pipeline/';
+import { installPipelines, deletePreviousPipelines } from '../elasticsearch/ingest_pipeline/';
import { installILMPolicy } from '../elasticsearch/ilm/install';
import {
installKibanaAssets,
@@ -183,7 +183,7 @@ export async function installPackage({
// if this is an update, delete the previous version's pipelines
if (installedPkg && !reinstall) {
- await deletePipelines(
+ await deletePreviousPipelines(
callCluster,
savedObjectsClient,
pkgName,
diff --git a/x-pack/plugins/lens/public/indexpattern_datasource/layerpanel.test.tsx b/x-pack/plugins/lens/public/indexpattern_datasource/layerpanel.test.tsx
index f9a74ee477d57..560c48b2155ee 100644
--- a/x-pack/plugins/lens/public/indexpattern_datasource/layerpanel.test.tsx
+++ b/x-pack/plugins/lens/public/indexpattern_datasource/layerpanel.test.tsx
@@ -9,11 +9,16 @@ import { IndexPatternPrivateState } from './types';
import { IndexPatternLayerPanelProps, LayerPanel } from './layerpanel';
import { shallowWithIntl as shallow } from 'test_utils/enzyme_helpers';
import { ShallowWrapper } from 'enzyme';
-import { EuiSelectable, EuiSelectableList } from '@elastic/eui';
+import { EuiSelectable } from '@elastic/eui';
import { ChangeIndexPattern } from './change_indexpattern';
jest.mock('./state_helpers');
+interface IndexPatternPickerOption {
+ label: string;
+ checked?: 'on' | 'off';
+}
+
const initialState: IndexPatternPrivateState = {
indexPatternRefs: [
{ id: '1', title: 'my-fake-index-pattern' },
@@ -187,9 +192,9 @@ describe('Layer Data Panel', () => {
}
function selectIndexPatternPickerOption(instance: ShallowWrapper, selectedLabel: string) {
- const options: Array<{ label: string; checked?: 'on' | 'off' }> = getIndexPatternPickerOptions(
+ const options: IndexPatternPickerOption[] = getIndexPatternPickerOptions(
instance
- ).map((option) =>
+ ).map((option: IndexPatternPickerOption) =>
option.label === selectedLabel
? { ...option, checked: 'on' }
: { ...option, checked: undefined }
@@ -198,17 +203,17 @@ describe('Layer Data Panel', () => {
}
function getIndexPatternPickerOptions(instance: ShallowWrapper) {
- return getIndexPatternPickerList(instance).dive().find(EuiSelectableList).prop('options');
+ return getIndexPatternPickerList(instance).prop('options');
}
it('should list all index patterns', () => {
const instance = shallow();
- expect(getIndexPatternPickerOptions(instance)!.map((option) => option.label)).toEqual([
- 'my-fake-index-pattern',
- 'my-fake-restricted-pattern',
- 'my-compatible-pattern',
- ]);
+ expect(
+ getIndexPatternPickerOptions(instance)!.map(
+ (option: IndexPatternPickerOption) => option.label
+ )
+ ).toEqual(['my-fake-index-pattern', 'my-fake-restricted-pattern', 'my-compatible-pattern']);
});
it('should switch data panel to target index pattern', () => {
diff --git a/x-pack/plugins/license_management/__jest__/__snapshots__/add_license.test.js.snap b/x-pack/plugins/license_management/__jest__/__snapshots__/add_license.test.js.snap
index 28ce3c6c07501..768c7175e6edc 100644
--- a/x-pack/plugins/license_management/__jest__/__snapshots__/add_license.test.js.snap
+++ b/x-pack/plugins/license_management/__jest__/__snapshots__/add_license.test.js.snap
@@ -1,5 +1,5 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
-exports[`AddLicense component when license is active should display correct verbiage 1`] = `"
Update your license
If you already have a new license, upload it now.
"`;
+exports[`AddLicense component when license is active should display correct verbiage 1`] = `"
Update your license
If you already have a new license, upload it now.
"`;
-exports[`AddLicense component when license is expired should display with correct verbiage 1`] = `"
Update your license
If you already have a new license, upload it now.
"`;
+exports[`AddLicense component when license is expired should display with correct verbiage 1`] = `"
Update your license
If you already have a new license, upload it now.
"`;
diff --git a/x-pack/plugins/license_management/__jest__/__snapshots__/request_trial_extension.test.js.snap b/x-pack/plugins/license_management/__jest__/__snapshots__/request_trial_extension.test.js.snap
index 096f26eb22fe3..db37bc6cb98c4 100644
--- a/x-pack/plugins/license_management/__jest__/__snapshots__/request_trial_extension.test.js.snap
+++ b/x-pack/plugins/license_management/__jest__/__snapshots__/request_trial_extension.test.js.snap
@@ -1,9 +1,9 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
-exports[`RequestTrialExtension component should display when enterprise license is not active and trial has been used 1`] = `"
Extend your trial
If you’d like to continue using machine learning, advanced security, and our other awesome subscription features, request an extension now.
"`;
+exports[`RequestTrialExtension component should display when enterprise license is not active and trial has been used 1`] = `"
Extend your trial
If you’d like to continue using machine learning, advanced security, and our other awesome subscription features, request an extension now.
"`;
-exports[`RequestTrialExtension component should display when license is active and trial has been used 1`] = `"
Extend your trial
If you’d like to continue using machine learning, advanced security, and our other awesome subscription features, request an extension now.
"`;
+exports[`RequestTrialExtension component should display when license is active and trial has been used 1`] = `"
Extend your trial
If you’d like to continue using machine learning, advanced security, and our other awesome subscription features, request an extension now.
"`;
-exports[`RequestTrialExtension component should display when license is not active and trial has been used 1`] = `"
Extend your trial
If you’d like to continue using machine learning, advanced security, and our other awesome subscription features, request an extension now.
"`;
+exports[`RequestTrialExtension component should display when license is not active and trial has been used 1`] = `"
Extend your trial
If you’d like to continue using machine learning, advanced security, and our other awesome subscription features, request an extension now.
"`;
-exports[`RequestTrialExtension component should display when platinum license is not active and trial has been used 1`] = `"
Extend your trial
If you’d like to continue using machine learning, advanced security, and our other awesome subscription features, request an extension now.
"`;
+exports[`RequestTrialExtension component should display when platinum license is not active and trial has been used 1`] = `"
Extend your trial
If you’d like to continue using machine learning, advanced security, and our other awesome subscription features, request an extension now.
"`;
diff --git a/x-pack/plugins/license_management/__jest__/__snapshots__/revert_to_basic.test.js.snap b/x-pack/plugins/license_management/__jest__/__snapshots__/revert_to_basic.test.js.snap
index 0a5656aa266bc..24598635b28e3 100644
--- a/x-pack/plugins/license_management/__jest__/__snapshots__/revert_to_basic.test.js.snap
+++ b/x-pack/plugins/license_management/__jest__/__snapshots__/revert_to_basic.test.js.snap
@@ -1,7 +1,7 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
-exports[`RevertToBasic component should display when license is about to expire 1`] = `"
Revert to Basic license
You’ll revert to our free features and lose access to machine learning, advanced security, and other subscription features.
"`;
+exports[`RevertToBasic component should display when license is about to expire 1`] = `"
Revert to Basic license
You’ll revert to our free features and lose access to machine learning, advanced security, and other subscription features.
"`;
-exports[`RevertToBasic component should display when license is expired 1`] = `"
Revert to Basic license
You’ll revert to our free features and lose access to machine learning, advanced security, and other subscription features.
"`;
+exports[`RevertToBasic component should display when license is expired 1`] = `"
Revert to Basic license
You’ll revert to our free features and lose access to machine learning, advanced security, and other subscription features.
"`;
-exports[`RevertToBasic component should display when trial is active 1`] = `"
Revert to Basic license
You’ll revert to our free features and lose access to machine learning, advanced security, and other subscription features.
"`;
+exports[`RevertToBasic component should display when trial is active 1`] = `"
Revert to Basic license
You’ll revert to our free features and lose access to machine learning, advanced security, and other subscription features.
"`;
diff --git a/x-pack/plugins/license_management/__jest__/__snapshots__/start_trial.test.js.snap b/x-pack/plugins/license_management/__jest__/__snapshots__/start_trial.test.js.snap
index 9da8bb958941b..24872a888b090 100644
--- a/x-pack/plugins/license_management/__jest__/__snapshots__/start_trial.test.js.snap
+++ b/x-pack/plugins/license_management/__jest__/__snapshots__/start_trial.test.js.snap
@@ -1,9 +1,9 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
-exports[`StartTrial component when trial is allowed display for basic license 1`] = `"
Start a 30-day trial
Experience what machine learning, advanced security, and all our other subscription features have to offer.
"`;
+exports[`StartTrial component when trial is allowed display for basic license 1`] = `"
Start a 30-day trial
Experience what machine learning, advanced security, and all our other subscription features have to offer.
"`;
-exports[`StartTrial component when trial is allowed should display for expired enterprise license 1`] = `"
Start a 30-day trial
Experience what machine learning, advanced security, and all our other subscription features have to offer.
"`;
+exports[`StartTrial component when trial is allowed should display for expired enterprise license 1`] = `"
Start a 30-day trial
Experience what machine learning, advanced security, and all our other subscription features have to offer.
"`;
-exports[`StartTrial component when trial is allowed should display for expired platinum license 1`] = `"
Start a 30-day trial
Experience what machine learning, advanced security, and all our other subscription features have to offer.
"`;
+exports[`StartTrial component when trial is allowed should display for expired platinum license 1`] = `"
Start a 30-day trial
Experience what machine learning, advanced security, and all our other subscription features have to offer.
"`;
-exports[`StartTrial component when trial is allowed should display for gold license 1`] = `"
Start a 30-day trial
Experience what machine learning, advanced security, and all our other subscription features have to offer.
"`;
+exports[`StartTrial component when trial is allowed should display for gold license 1`] = `"
Start a 30-day trial
Experience what machine learning, advanced security, and all our other subscription features have to offer.
"`;
diff --git a/x-pack/plugins/license_management/__jest__/__snapshots__/upload_license.test.tsx.snap b/x-pack/plugins/license_management/__jest__/__snapshots__/upload_license.test.tsx.snap
index f0feb826f956d..32e4d116f0a06 100644
--- a/x-pack/plugins/license_management/__jest__/__snapshots__/upload_license.test.tsx.snap
+++ b/x-pack/plugins/license_management/__jest__/__snapshots__/upload_license.test.tsx.snap
@@ -297,11 +297,15 @@ exports[`UploadLicense should display a modal when license requires acknowledgem
class="euiOverlayMask euiOverlayMask--aboveHeader"
>
-
-
-
-
-
-
-
-
-
-
-
-
- Confirm License Upload
-
-
-
-
-
-
-
- Some functionality will be lost if you replace your TRIAL license with a BASIC license. Review the list of features below.
-