Skip to content

Commit

Permalink
Remove Monitor Management tour.
Browse files Browse the repository at this point in the history
  • Loading branch information
awahab07 committed Feb 28, 2023
1 parent 7449b0a commit 82fd949
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 86 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export const ServiceAllowedWrapper: React.FC = ({ children }) => {
return (
<EuiEmptyPrompt
title={<h2>{MONITOR_MANAGEMENT_LABEL}</h2>}
body={<p>{PUBLIC_BETA_DESCRIPTION}</p>}
body={<p>{ACCESS_RESTRICTED_MESSAGE}</p>}
actions={[
<EuiButton color="primary" fill isDisabled={!signupUrl} href={signupUrl ?? undefined}>
{REQUEST_ACCESS_LABEL}
Expand Down Expand Up @@ -55,10 +55,9 @@ const LOADING_MONITOR_MANAGEMENT_LABEL = i18n.translate(
}
);

export const PUBLIC_BETA_DESCRIPTION = i18n.translate(
'xpack.synthetics.monitorManagement.publicBetaDescription',
export const ACCESS_RESTRICTED_MESSAGE = i18n.translate(
'xpack.synthetics.monitorManagement.accessRestricted',
{
defaultMessage:
"We've got a brand new app on the way. In the meantime, we're excited to give you early access to our globally managed testing infrastructure. This will allow you to upload synthetic monitors using our new point and click script recorder and manage your monitors with a new UI.",
defaultMessage: 'Your access to globally managed testing infrastructure is restricted.',
}
);
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,5 @@ export const useSyntheticsServiceAllowed = () => {

// return useSelector(syntheticsServiceAllowedSelector);
// TODO Implement for Synthetics App
return { isAllowed: true, signupUrl: 'https://example.com', loading: false };
return { isAllowed: true, signupUrl: undefined, loading: false };
};
Original file line number Diff line number Diff line change
Expand Up @@ -5,89 +5,34 @@
* 2.0.
*/

import { EuiButton, EuiHeaderLink, EuiLink, EuiSpacer, EuiTourStep, EuiText } from '@elastic/eui';
import { EuiHeaderLink } from '@elastic/eui';
import { FormattedMessage } from '@kbn/i18n-react';
import { i18n } from '@kbn/i18n';
import React from 'react';
import { useHistory } from 'react-router-dom';
import useLocalStorage from 'react-use/lib/useLocalStorage';

import { MONITOR_MANAGEMENT_ROUTE } from '../../../../../common/constants';
import { PUBLIC_BETA_DESCRIPTION } from '../../../pages/monitor_management/service_allowed_wrapper';

export const ManageMonitorsBtn = () => {
const [isOpen, setIsOpen] = useLocalStorage('xpack.synthetics.monitorManagement.openTour', true);

const history = useHistory();

return (
<EuiTourStep
content={
<>
<EuiText size="s">
<p>{PUBLIC_BETA_DESCRIPTION}</p>
</EuiText>
<EuiSpacer />
<EuiButton
color="primary"
fill
href={history.createHref({
pathname: MONITOR_MANAGEMENT_ROUTE,
})}
>
{MONITOR_MANAGEMENT_LABEL}
</EuiButton>
</>
}
isStepOpen={isOpen}
onFinish={() => setIsOpen(false)}
step={1}
stepsTotal={1}
subtitle={NEW_LABEL}
title={GETTING_STARTED_LABEL}
anchorPosition="upCenter"
maxWidth={416}
footerAction={
<EuiLink data-test-subj="syntheticsManagementTourDismiss" onClick={() => setIsOpen(false)}>
{DISMISS_LABEL}
</EuiLink>
}
<EuiHeaderLink
aria-label={NAVIGATE_LABEL}
color="text"
data-test-subj="syntheticsManagementPageLink"
href={history.createHref({
pathname: MONITOR_MANAGEMENT_ROUTE,
})}
>
<EuiHeaderLink
aria-label={NAVIGATE_LABEL}
color="text"
data-test-subj="syntheticsManagementPageLink"
href={history.createHref({
pathname: MONITOR_MANAGEMENT_ROUTE,
})}
>
<FormattedMessage
id="xpack.synthetics.page_header.manageMonitors"
defaultMessage="Monitor Management"
/>
</EuiHeaderLink>
</EuiTourStep>
<FormattedMessage
id="xpack.synthetics.page_header.manageMonitors"
defaultMessage="Monitor Management"
/>
</EuiHeaderLink>
);
};

const GETTING_STARTED_LABEL = i18n.translate(
'xpack.synthetics.monitorManagement.gettingStarted.label',
{
defaultMessage: 'Get started with Synthetic Monitoring',
}
);

const MONITOR_MANAGEMENT_LABEL = i18n.translate('xpack.synthetics.monitorManagement.try.label', {
defaultMessage: 'Try Monitor Management',
});
const DISMISS_LABEL = i18n.translate('xpack.synthetics.monitorManagement.try.dismiss', {
defaultMessage: 'Dismiss',
});

const NAVIGATE_LABEL = i18n.translate('xpack.synthetics.page_header.manageLink.label', {
defaultMessage: 'Navigate to the Uptime Monitor Management page',
});

const NEW_LABEL = i18n.translate('xpack.synthetics.monitorManagement.new.label', {
defaultMessage: 'New',
});
4 changes: 0 additions & 4 deletions x-pack/plugins/translations/translations/fr-FR.json
Original file line number Diff line number Diff line change
Expand Up @@ -33658,7 +33658,6 @@
"xpack.synthetics.monitorManagement.getAPIKeyLabel.label": "Clés d'API",
"xpack.synthetics.monitorManagement.getAPIKeyLabel.loading": "Génération d’une clé d’API",
"xpack.synthetics.monitorManagement.getAPIKeyReducedPermissions.description": "Utilisez une clé d’API pour transmettre des moniteurs à distance à partir d'un pipeline CLI ou CD. Pour générer une clé d’API, vous devez disposer des autorisations de gérer les clés d’API et d’un accès en écriture à Uptime. Veuillez contacter votre administrateur.",
"xpack.synthetics.monitorManagement.gettingStarted.label": "Lancez-vous avec Synthetic Monitoring",
"xpack.synthetics.monitorManagement.heading": "Gestion des moniteurs",
"xpack.synthetics.monitorManagement.hostFieldLabel": "Hôte",
"xpack.synthetics.monitorManagement.inProgress": "EN COURS",
Expand Down Expand Up @@ -33708,7 +33707,6 @@
"xpack.synthetics.monitorManagement.nameRequired": "Le nom de l’emplacement est requis",
"xpack.synthetics.monitorManagement.needFleetReadAgentPoliciesPermission": "Vous n'êtes pas autorisé à accéder à Fleet. Des autorisations Fleet sont nécessaires pour créer de nouveaux emplacements privés.",
"xpack.synthetics.monitorManagement.needPermissions": "Permissions requises",
"xpack.synthetics.monitorManagement.new.label": "Nouveauté",
"xpack.synthetics.monitorManagement.noLabel": "Annuler",
"xpack.synthetics.monitorManagement.overviewTab.title": "Aperçu",
"xpack.synthetics.monitorManagement.pageHeader.title": "Gestion des moniteurs",
Expand Down Expand Up @@ -33743,8 +33741,6 @@
"xpack.synthetics.monitorManagement.syntheticsEnableToolTip": "Activez la Gestion des moniteurs pour créer des moniteurs légers et basés sur un navigateur réel à partir d'emplacements du monde entier.",
"xpack.synthetics.monitorManagement.techPreviewLabel": "Préversion technique",
"xpack.synthetics.monitorManagement.testResult": "Résultat du test",
"xpack.synthetics.monitorManagement.try.dismiss": "Rejeter",
"xpack.synthetics.monitorManagement.try.label": "Essayer la Gestion des moniteurs",
"xpack.synthetics.monitorManagement.updateMonitorLabel": "Mettre à jour le moniteur",
"xpack.synthetics.monitorManagement.urlFieldLabel": "Url",
"xpack.synthetics.monitorManagement.urlRequiredLabel": "L'URL est requise",
Expand Down
4 changes: 0 additions & 4 deletions x-pack/plugins/translations/translations/ja-JP.json
Original file line number Diff line number Diff line change
Expand Up @@ -33629,7 +33629,6 @@
"xpack.synthetics.monitorManagement.getAPIKeyLabel.label": "API キー",
"xpack.synthetics.monitorManagement.getAPIKeyLabel.loading": "APIキーを生成しています",
"xpack.synthetics.monitorManagement.getAPIKeyReducedPermissions.description": "APIキーを使用して、CLIまたはCDパイプラインからリモートでモニターをプッシュします。APIキーを生成するには、APIキーを管理する権限とアップタイム書き込み権限が必要です。管理者にお問い合わせください。",
"xpack.synthetics.monitorManagement.gettingStarted.label": "Synthetic Monitoringの基本",
"xpack.synthetics.monitorManagement.heading": "モニター管理",
"xpack.synthetics.monitorManagement.hostFieldLabel": "ホスト",
"xpack.synthetics.monitorManagement.inProgress": "進行中",
Expand Down Expand Up @@ -33679,7 +33678,6 @@
"xpack.synthetics.monitorManagement.nameRequired": "場所名は必須です",
"xpack.synthetics.monitorManagement.needFleetReadAgentPoliciesPermission": "Fleet へのアクセスが許可されていません。新しい非公開の場所を作成するには、Fleet権限が必要です。",
"xpack.synthetics.monitorManagement.needPermissions": "権限が必要です",
"xpack.synthetics.monitorManagement.new.label": "新規",
"xpack.synthetics.monitorManagement.noLabel": "キャンセル",
"xpack.synthetics.monitorManagement.overviewTab.title": "概要",
"xpack.synthetics.monitorManagement.pageHeader.title": "モニター管理",
Expand Down Expand Up @@ -33714,8 +33712,6 @@
"xpack.synthetics.monitorManagement.syntheticsEnableToolTip": "モニター管理を有効にすると、世界中の場所から軽量でリアルなブラウザーモニターを作成できます。",
"xpack.synthetics.monitorManagement.techPreviewLabel": "テクニカルプレビュー",
"xpack.synthetics.monitorManagement.testResult": "テスト結果",
"xpack.synthetics.monitorManagement.try.dismiss": "閉じる",
"xpack.synthetics.monitorManagement.try.label": "モニター管理を試す",
"xpack.synthetics.monitorManagement.updateMonitorLabel": "モニターの更新",
"xpack.synthetics.monitorManagement.urlFieldLabel": "Url",
"xpack.synthetics.monitorManagement.urlRequiredLabel": "URLが必要です",
Expand Down
4 changes: 0 additions & 4 deletions x-pack/plugins/translations/translations/zh-CN.json
Original file line number Diff line number Diff line change
Expand Up @@ -33664,7 +33664,6 @@
"xpack.synthetics.monitorManagement.getAPIKeyLabel.label": "API 密钥",
"xpack.synthetics.monitorManagement.getAPIKeyLabel.loading": "正在生成 API 密钥",
"xpack.synthetics.monitorManagement.getAPIKeyReducedPermissions.description": "使用 API 密钥从 CLI 或 CD 管道远程推送监测。要生成 API 密钥,您必须有权管理 API 密钥并具有 Uptime 写入权限。请联系您的管理员。",
"xpack.synthetics.monitorManagement.gettingStarted.label": "开始使用 Synthetic 监测",
"xpack.synthetics.monitorManagement.heading": "监测管理",
"xpack.synthetics.monitorManagement.hostFieldLabel": "主机",
"xpack.synthetics.monitorManagement.inProgress": "进行中",
Expand Down Expand Up @@ -33714,7 +33713,6 @@
"xpack.synthetics.monitorManagement.nameRequired": "“位置名称”必填",
"xpack.synthetics.monitorManagement.needFleetReadAgentPoliciesPermission": "您无权访问 Fleet。需要 Fleet 权限才能创建新的专用位置。",
"xpack.synthetics.monitorManagement.needPermissions": "需要权限",
"xpack.synthetics.monitorManagement.new.label": "新建",
"xpack.synthetics.monitorManagement.noLabel": "取消",
"xpack.synthetics.monitorManagement.overviewTab.title": "概览",
"xpack.synthetics.monitorManagement.pageHeader.title": "监测管理",
Expand Down Expand Up @@ -33749,8 +33747,6 @@
"xpack.synthetics.monitorManagement.syntheticsEnableToolTip": "启用监测管理以在全球各个地点创建轻量级、真正的浏览器监测。",
"xpack.synthetics.monitorManagement.techPreviewLabel": "技术预览",
"xpack.synthetics.monitorManagement.testResult": "测试结果",
"xpack.synthetics.monitorManagement.try.dismiss": "关闭",
"xpack.synthetics.monitorManagement.try.label": "尝试监测管理",
"xpack.synthetics.monitorManagement.updateMonitorLabel": "更新监测",
"xpack.synthetics.monitorManagement.urlFieldLabel": "URL",
"xpack.synthetics.monitorManagement.urlRequiredLabel": "“URL”必填",
Expand Down

0 comments on commit 82fd949

Please sign in to comment.