From 2caf020dde3828f736bc68d364c412d22dd23545 Mon Sep 17 00:00:00 2001 From: Lin Wang Date: Fri, 7 Jul 2023 08:53:38 +0800 Subject: [PATCH] Revert "Revert remove experiment banner and enable by default (#203)" (#229) * Revert "Revert remove experiment banner and enable by default (#203)" This reverts commit 31df7d45893e933999f9d97db2d5c606159f9e6b. Signed-off-by: Lin Wang * doc: remove release update for 2.8.0 Signed-off-by: Lin Wang --------- Signed-off-by: Lin Wang --- .../__tests__/index.test.tsx | 25 --------------- .../components/experiment_warning/index.tsx | 32 ------------------- public/components/monitoring/index.tsx | 2 -- server/index.ts | 2 +- 4 files changed, 1 insertion(+), 60 deletions(-) delete mode 100644 public/components/experiment_warning/__tests__/index.test.tsx delete mode 100644 public/components/experiment_warning/index.tsx diff --git a/public/components/experiment_warning/__tests__/index.test.tsx b/public/components/experiment_warning/__tests__/index.test.tsx deleted file mode 100644 index b9ccd3fa..00000000 --- a/public/components/experiment_warning/__tests__/index.test.tsx +++ /dev/null @@ -1,25 +0,0 @@ -/* - * Copyright OpenSearch Contributors - * SPDX-License-Identifier: Apache-2.0 - */ -import React from 'react'; -import { render, screen } from '../../../../test/test_utils'; -import { ExperimentalWarning } from '..'; - -describe('', () => { - it('should navigate to # when clicking link of "Machine Learning Documentation"', () => { - render(); - const link = screen.getByText('Machine Learning Documentation'); - expect(link.getAttribute('href')).toBe( - 'https://opensearch.org/docs/latest/ml-commons-plugin/ml-dashboard/' - ); - }); - - it('should navigate to # when clicking forum.opensearch.org', () => { - render(); - const link = screen.getByText('forum.opensearch.org'); - expect(link.getAttribute('href')).toBe( - 'https://forum.opensearch.org/t/feedback-ml-commons-ml-model-health-dashboard-for-admins-experimental-release/12494' - ); - }); -}); diff --git a/public/components/experiment_warning/index.tsx b/public/components/experiment_warning/index.tsx deleted file mode 100644 index 3952b79d..00000000 --- a/public/components/experiment_warning/index.tsx +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright OpenSearch Contributors - * SPDX-License-Identifier: Apache-2.0 - */ -import React from 'react'; - -import { EuiCallOut, EuiLink } from '@elastic/eui'; - -export const ExperimentalWarning = () => { - return ( - - The feature is experimental and should not be used in a production environment. For more - information, see{' '} - - Machine Learning Documentation - - . To leave feedback, visit{' '} - - forum.opensearch.org - - . - - ); -}; diff --git a/public/components/monitoring/index.tsx b/public/components/monitoring/index.tsx index 8d163063..e218a0c9 100644 --- a/public/components/monitoring/index.tsx +++ b/public/components/monitoring/index.tsx @@ -18,7 +18,6 @@ import { useUiSetting } from '../../../../../src/plugins/opensearch_dashboards_r import { ModelDeploymentProfile } from '../../apis/profile'; import { RefreshInterval } from '../common/refresh_interval'; import { PreviewPanel } from '../preview_panel'; -import { ExperimentalWarning } from '../experiment_warning'; import { ModelDeploymentItem, ModelDeploymentTable } from './model_deployment_table'; import { useMonitoring } from './use_monitoring'; @@ -72,7 +71,6 @@ export const Monitoring = () => { return (
-