forked from elastic/kibana
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add LevelIconTips to be more explicit about the difference between cr…
…itical and warning issues. (elastic#115121)
- Loading branch information
1 parent
bed98ef
commit 1595af5
Showing
4 changed files
with
54 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
x-pack/plugins/upgrade_assistant/public/application/components/shared/level_info_tip.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License | ||
* 2.0; you may not use this file except in compliance with the Elastic License | ||
* 2.0. | ||
*/ | ||
|
||
import React, { FunctionComponent } from 'react'; | ||
import { i18n } from '@kbn/i18n'; | ||
import { EuiIconTip } from '@elastic/eui'; | ||
|
||
const i18nTexts = { | ||
critical: i18n.translate('xpack.upgradeAssistant.levelInfoTip.criticalLabel', { | ||
defaultMessage: 'Critical issues must be resolved before you upgrade', | ||
}), | ||
warning: i18n.translate('xpack.upgradeAssistant.levelInfoTip.warningLabel', { | ||
defaultMessage: 'Warning issues can be ignored at your discretion', | ||
}), | ||
}; | ||
|
||
interface Props { | ||
level: 'critical' | 'warning'; | ||
} | ||
|
||
export const LevelInfoTip: FunctionComponent<Props> = ({ level }) => { | ||
return <EuiIconTip content={i18nTexts[level]} position="top" type="iInCircle" />; | ||
}; |