From 51a290e9e58c7eeff188f96c74a3a5e43f6d7650 Mon Sep 17 00:00:00 2001 From: Kshitij Tandon Date: Thu, 29 Aug 2024 15:14:55 +0530 Subject: [PATCH] Worked on review Signed-off-by: Kshitij Tandon --- .../containers/IndexDetail/IndexDetail.tsx | 12 ++++--- .../NotificationModal/NotificationModal.tsx | 31 ++++++++++++++++--- .../Indices/containers/Indices/Indices.tsx | 9 +++--- .../TransformEmptyPrompt.tsx | 4 +-- .../Transforms/TransformSettings.tsx | 3 +- .../containers/Transforms/Transforms.tsx | 2 +- .../__snapshots__/Transforms.test.tsx.snap | 2 +- 7 files changed, 44 insertions(+), 19 deletions(-) diff --git a/public/pages/IndexDetail/containers/IndexDetail/IndexDetail.tsx b/public/pages/IndexDetail/containers/IndexDetail/IndexDetail.tsx index d2b582d1b..bfaeee2bf 100644 --- a/public/pages/IndexDetail/containers/IndexDetail/IndexDetail.tsx +++ b/public/pages/IndexDetail/containers/IndexDetail/IndexDetail.tsx @@ -212,7 +212,6 @@ export default function IndexDetail(props: IndexDetailModalProps) {

Index alias

- @@ -270,7 +269,7 @@ export default function IndexDetail(props: IndexDetailModalProps) { - +
{OVERVIEW_DISPLAY_INFO.map((item) => { let valueContent = null; @@ -282,11 +281,16 @@ export default function IndexDetail(props: IndexDetailModalProps) { } return (
- {item.label} + + + {" "} +

{item.label}

{" "} +
+
{valueContent} diff --git a/public/pages/Indices/components/NotificationModal/NotificationModal.tsx b/public/pages/Indices/components/NotificationModal/NotificationModal.tsx index 7bab02f0a..48512ec72 100644 --- a/public/pages/Indices/components/NotificationModal/NotificationModal.tsx +++ b/public/pages/Indices/components/NotificationModal/NotificationModal.tsx @@ -13,6 +13,7 @@ import { EuiPanel, EuiEmptyPrompt, EuiSmallButton, + EuiText, } from "@elastic/eui"; import { ServicesContext } from "../../../../services"; import { BrowserServices } from "../../../../models/interfaces"; @@ -182,7 +183,12 @@ const Notifications = ({ onClose, visible }: NotificationsProps) => { return ( - Notification settings + + + {" "} +

Notification settings

{" "} +
+
Manage channels @@ -196,8 +202,18 @@ const Notifications = ({ onClose, visible }: NotificationsProps) => { Error loading Notification settings} - body={

You do not have permissions to view Notification settings. Contact your administrator to request permissions.

} + title={ + + {" "} +

Error loading Notification settings

{" "} +
+ } + body={ + + {" "} +

You do not have permissions to view Notification settings. Contact your administrator to request permissions.

+
+ } /> ) : ( @@ -253,7 +269,14 @@ const Notifications = ({ onClose, visible }: NotificationsProps) => { }); return ( {record.title}
} + label={ +
+ + {" "} +

{record.title}

{" "} +
+
+ } helpText={ActionTypeMapDescription[getKeyByValue(ActionTypeMapTitle, record.title) as ActionType]} direction="hoz" key={record.action_name} diff --git a/public/pages/Indices/containers/Indices/Indices.tsx b/public/pages/Indices/containers/Indices/Indices.tsx index 436886880..87084e037 100644 --- a/public/pages/Indices/containers/Indices/Indices.tsx +++ b/public/pages/Indices/containers/Indices/Indices.tsx @@ -20,7 +20,7 @@ import { ArgsWithError, ArgsWithQuery, Query, - EuiTitle, + EuiPanel, } from "@elastic/eui"; import { ContentPanel, ContentPanelActions } from "../../../../components/ContentPanel"; import IndexControls from "../../components/IndexControls"; @@ -41,8 +41,7 @@ import "./index.scss"; import { DataSourceMenuContext, DataSourceMenuProperties } from "../../../../services/DataSourceMenuContext"; import MDSEnabledComponent from "../../../../components/MDSEnabledComponent"; import { getApplication, getNavigationUI, getUISettings } from "../../../../services/Services"; -import { TopNavControlButtonData, TopNavControlIconData, TopNavControlTextData } from "src/plugins/navigation/public"; -import { EuiSpacer } from "@opensearch-project/oui"; +import { TopNavControlButtonData } from "src/plugins/navigation/public"; import NotificationModal from "../../components/NotificationModal"; interface IndicesProps extends RouteComponentProps, DataSourceMenuProperties { @@ -316,7 +315,7 @@ export class Indices extends MDSEnabledComponent { ]} />
- + { selection={selection} sorting={sorting} /> - +
{this.state.isNotificationModalVisible && ( diff --git a/public/pages/Transforms/components/TransformEmptyPrompt/TransformEmptyPrompt.tsx b/public/pages/Transforms/components/TransformEmptyPrompt/TransformEmptyPrompt.tsx index 98b5cbbf1..4f751535b 100644 --- a/public/pages/Transforms/components/TransformEmptyPrompt/TransformEmptyPrompt.tsx +++ b/public/pages/Transforms/components/TransformEmptyPrompt/TransformEmptyPrompt.tsx @@ -43,7 +43,7 @@ const getActions: React.SFC = ({ filterIsApplied, loa } return ( - + Create transform ); @@ -53,7 +53,7 @@ const TransformEmptyPrompt: React.SFC = (props) => ( +

{getMessagePrompt(props)}

} diff --git a/public/pages/Transforms/containers/Transforms/TransformSettings.tsx b/public/pages/Transforms/containers/Transforms/TransformSettings.tsx index effe9a844..46f134076 100644 --- a/public/pages/Transforms/containers/Transforms/TransformSettings.tsx +++ b/public/pages/Transforms/containers/Transforms/TransformSettings.tsx @@ -101,7 +101,7 @@ export default class TransformSettings extends Component
-
+
Preview result based on sample data
- {}} previewTransform={this.state.previewTransform} diff --git a/public/pages/Transforms/containers/Transforms/Transforms.tsx b/public/pages/Transforms/containers/Transforms/Transforms.tsx index 62fd63a83..c417447b2 100644 --- a/public/pages/Transforms/containers/Transforms/Transforms.tsx +++ b/public/pages/Transforms/containers/Transforms/Transforms.tsx @@ -271,7 +271,7 @@ export class Transforms extends MDSEnabledComponent - +
diff --git a/public/pages/Transforms/containers/Transforms/__snapshots__/Transforms.test.tsx.snap b/public/pages/Transforms/containers/Transforms/__snapshots__/Transforms.test.tsx.snap index c33fb832c..12c975a56 100644 --- a/public/pages/Transforms/containers/Transforms/__snapshots__/Transforms.test.tsx.snap +++ b/public/pages/Transforms/containers/Transforms/__snapshots__/Transforms.test.tsx.snap @@ -474,7 +474,7 @@ exports[` spec renders the component 1`] = ` class="euiText euiText--medium" >

Loading transform jobs...